:root {
    --rk-bg: #1b2632;
    --rk-card: #212630;
    --rk-card-2: #2c3444;
    --rk-border: #2b303c;
    --rk-text: #d7e0ea;
    --rk-dim: #91a0b3;
    --rk-accent: #ffd666;
    --rk-shadow: 0 8px 24px rgba(0, 0, 0, .35);
    --rk-success: #1e8c55
}

.page-header {
    background-image: url('/assets/images/slider/2025062583_aoujf.png');
    position: relative;
    -webkit-mask-image: -webkit-gradient(linear, left top, left bottom, from(rgba(0, 0, 0, 1)), to(rgba(0, 0, 0, 0)));
    mask-image: linear-gradient(to bottom, rgb(0 0 0) 0%, rgb(255 255 255 / 0%) 80%);
    height: 500px;
}

.page-header::after {
    content: "";
    position: absolute;
    inset: 0;
    background: radial-gradient(60% 60% at 50% 30%, rgba(0, 0, 0, .25), rgb(0 0 0 / 32%));
    pointer-events: none;
}

.guild-profile {
    margin-top: -29rem;
    z-index: 1;
    position: relative;
}

.page-header h1 {
    text-align: center;
    position: relative;
    z-index: 1;
}

.rank-list {
    margin-top: 6px;
    display: flex;
    flex-direction: column;
    gap: 10px;
    width: 100%
}

.rank-item {
    background: linear-gradient(180deg, var(--rk-card), var(--rk-card-2));
    border: 1px solid var(--rk-border);
    border-radius: 10px;
    padding: 5px;
    display: grid;
    grid-template-columns: 40px 250px 100px 150px 150px 150px 1fr;
    align-items: center;
    gap: 14px;
    justify-content: space-between;
    transition: transform .15s, box-shadow .15s, border-color .15s;
    font-size: 11px
}

.rank-list.guild .rank-item {
    grid-template-columns: 40px 60px 200px 150px 1fr
}

.symbol {
    display: flex;
    align-items: center;
    gap: .5rem
}

.rank-item:hover {
    transform: translateY(-1px);
    box-shadow: var(--rk-shadow);
    border-color: #2a3f56
}

.rank-left {
    display: flex;
    align-items: center;
    gap: 12px;
    min-width: 240px
}

.rank-badge {
    width: 35px;
    height: 35px;
    border-radius: 12px;
    display: grid;
    place-items: center;
    font-weight: 700;
    color: #0f141b;
    background: #94a3b8;
    font-size: 13px
}

.rank-badge.rank-1 {
    background: linear-gradient(135deg, gold, #ffb224);
    color: #3a2d00
}

.rank-badge.rank-2 {
    background: linear-gradient(135deg, #d6dae1, #aeb8c4);
    color: #1c2430
}

.rank-badge.rank-3 {
    background: linear-gradient(135deg, #eab08c, #d58542);
    color: #3b2412
}

.rank-id .rank-name {
    color: var(--rk-text);
    font-weight: 600;
    font-size: 13px
}

.rank-id .rank-clan {
    color: var(--rk-dim);
    font-size: 11px;
    display: flex;
    gap: 6px;
    align-items: center
}

.rank-meta {
    display: flex;
    gap: 8px;
    flex-wrap: wrap
}

.chip {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 10px;
    border-radius: 999px;
    font-size: 12px;
    color: var(--rk-text)
}

.chip-points {
    background: rgba(32, 114, 74, .12);
    border-color: rgba(30, 140, 85, .35);
    color: #bff3d6;
    font-weight: 600
}

.rank-footer {
    display: flex;
    justify-content: flex-end;
    align-items: center;
    gap: 8px;
    margin-top: 12px
}

.rank-perpage {
    width: auto;
    background: var(--rk-card-2);
    color: var(--rk-text);
    border-color: var(--rk-border);
    border-radius: 10px;
    padding: 4px 28px 4px 10px
}

.rank-empty {
    display: flex;
    gap: 8px;
    align-items: center;
    justify-content: center;
    color: var(--rk-dim);
    background: var(--rk-card);
    border: 1px dashed var(--rk-border);
    border-radius: 16px;
    padding: 20px
}

.guild-info {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 1.5rem;
}

.guild-info h1 {
    font-size: 18px;
    font-weight: 600;
    margin: 0;
}

.guild-info .guild-details {
    display: flex;
    flex-direction: column;
    text-align: end;
}

@media (max-width:768px) {
    .rank-item {
        flex-direction: row;
        flex-wrap: wrap;
        gap: 12px;
        display: flex;
        justify-content: normal;
        align-items: center;
    }

    .rank-left {
        min-width: unset;
        width: 36px;
    }

    .rank-left:nth-child(2) {
        width: calc(100% - 56px);
    }

    .rank-right {
        width: calc((100% - 18px) / 2);
    }

    .chip-points {
        width: 100%;
        justify-content: center;
    }

    .rank-footer {
        flex-wrap: wrap;
        justify-content: space-between;
    }

    .rank-lookup {
        flex-direction: column;
    }

    .rank-links {
        width: 100%;
        position: relative;
        top: unset;
    }

    .guild-info {
        flex-direction: column;
    }
}
