.raid-rankings {
    --raid-border: #29282c;
    --raid-muted: #a7a6af;
    --raid-orange: #ff811d;
    background: radial-gradient(ellipse at 0 0, #17100d 0, transparent 38rem), #0d0d0e;
    color: #f7f5f4;
    min-height: 70vh;
    padding: clamp(2.5rem, 5.3vw, 4.4rem) 1rem 4.5rem;
    font-family: Inter, "Noto Sans Georgian", sans-serif;
}
.raid-rankings [hidden] { display: none !important; }
.raid-rankings-shell { width: min(100%, 980px); margin-inline: auto; }
.raid-rankings-intro { text-align: center; margin-bottom: 1.55rem; }
.raid-rankings-intro h1 {
    margin: 0 0 1rem;
    font: 800 clamp(2rem, 4.2vw, 2.85rem)/1.2 "Noto Serif Georgian", Georgia, serif;
    color: #fff9f4;
}
.raid-rankings-intro p { margin: 0; color: var(--raid-muted); font-size: .94rem; line-height: 1.65; }

.raid-class-cards {
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: .75rem;
    padding-inline: .6rem;
}
.raid-class-dk { --class-color: #f0484c; --class-shade: #582025; }
.raid-class-dw { --class-color: #428cfa; --class-shade: #163762; }
.raid-class-fe { --class-color: #38d878; --class-shade: #164c3c; }
.raid-class-mg { --class-color: #ae61f8; --class-shade: #41255f; }
.raid-class-dl { --class-color: #ffbd30; --class-shade: #544021; }
.raid-class-card {
    position: relative;
    display: grid;
    align-items: end;
    aspect-ratio: 3 / 4;
    overflow: hidden;
    isolation: isolate;
    border: 1px solid #ffffff24;
    border-radius: .8rem;
    text-align: center;
    text-decoration: none;
    background: radial-gradient(ellipse at 54% 22%, var(--class-shade), #131215 80%);
}
.raid-class-card img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: 50% 15%;
    transition: transform .24s ease;
}
.raid-class-card::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, transparent 47%, #08080b7a 76%, #070709f2 100%);
}
.raid-class-card:hover, .raid-class-card.is-selected { border-color: var(--class-color); }
.raid-class-card:hover img { transform: scale(1.045); }
.raid-class-card-label { position: relative; z-index: 1; display: grid; gap: .2rem; padding: .6rem .25rem; line-height: 1.35; }
.raid-class-card-label strong { color: #fff; font-size: .94rem; font-weight: 800; }
.raid-class-card-label span { color: #ffb16a; font-size: .8rem; font-weight: 700; }

.raid-server-tag { display: flex; justify-content: center; margin: 2rem 0 1rem; }
.raid-server-tag span {
    padding: .68rem 1.4rem;
    border: 4px solid #33261d;
    border-radius: 99rem;
    background: #ff801b;
    box-shadow: 0 3px 12px #ff801b26;
    color: #17100c;
    font-weight: 800;
    font-size: .86rem;
}
.raid-ranking-tabs { display: flex; flex-wrap: wrap; justify-content: center; gap: .45rem; margin-bottom: 1.25rem; }
.raid-ranking-tabs a, .raid-class-filters button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: .45rem;
    min-height: 2.5rem;
    padding: .52rem .95rem;
    border: 1px solid #3b3b41;
    border-radius: 99rem;
    background: transparent;
    color: #f0eeee;
    font-family: inherit;
    font-weight: 700;
    font-size: .84rem;
    line-height: 1.3;
    text-decoration: none;
    cursor: pointer;
}
.raid-ranking-tabs a:hover, .raid-class-filters button:hover { border-color: #b9835b; }
.raid-ranking-tabs a[aria-selected="true"], .raid-class-filters button[aria-pressed="true"] {
    border-color: var(--raid-orange);
    background: #ff811d18;
    color: #ffe6d0;
}
.raid-rankings :is(a, button, input):focus-visible { outline: 2px solid #ffb16a; outline-offset: 3px; }
.raid-online-dot, .raid-class-filters i { width: .46rem; height: .46rem; border-radius: 50%; background: var(--class-color); flex: none; }
.raid-online-dot { --class-color: #38d878; box-shadow: 0 0 7px #38d87888; }

.raid-ranking-board { border: 1px solid var(--raid-border); border-radius: 1.05rem; overflow: hidden; background: #18181b; }
.raid-board-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: .9rem;
    padding: 1.05rem 1.5rem;
    background: linear-gradient(110deg, #2e221b, transparent 70%);
}
.raid-board-head h2 { margin: 0; color: #fff8f4; font-size: 1.28rem; font-weight: 800; }
.raid-rank-search {
    display: flex;
    align-items: center;
    gap: .55rem;
    width: min(100%, 14rem);
    min-height: 2.65rem;
    padding: 0 .75rem;
    border: 1px solid #414047;
    border-radius: 99rem;
    background: #101012;
}
.raid-rank-search:focus-within { border-color: #ffad70; }
.raid-rank-search svg { width: .92rem; height: .92rem; flex: none; fill: none; stroke: #9d9ca5; stroke-width: 1.5; }
.raid-rank-search input {
    width: 100%;
    min-width: 0;
    padding: .3rem 0;
    border: 0;
    border-radius: 0;
    background: transparent;
    color: #f8f5f2;
    font: inherit;
    font-size: .83rem;
}
.raid-rank-search input::placeholder { color: #a19faa; }
.raid-rank-search input:focus { outline: none; }
.raid-class-filters { display: flex; flex-wrap: wrap; gap: .45rem; padding: .9rem 1.5rem; border-top: 1px solid var(--raid-border); }
.raid-class-filters button { min-height: 2.12rem; padding: .4rem .8rem; font-size: .78rem; }

.raid-table-wrap { overflow: auto; }
.raid-rank-table { width: 100%; border-collapse: collapse; text-align: left; font-variant-numeric: tabular-nums; }
.raid-rank-table th, .raid-rank-table td { padding: .85rem 1.5rem; border-top: 1px solid var(--raid-border); }
.raid-rank-table th { color: var(--raid-muted); font-size: .73rem; letter-spacing: .05em; }
.raid-rank-table td { color: #f0e9e4; font-size: .88rem; }
.raid-rank-table :is(th, td):not(:first-child) { white-space: nowrap; }
.raid-rank-table tr:hover td { background: #ffffff04; }
.raid-rank-table th:first-child:not(:last-child) { width: 5rem; }
.raid-ranking-board[data-ranking-panel="online"] .raid-rank-table th:first-child { width: auto; }
.raid-rank-table td:last-child, .raid-rank-table th:last-child { text-align: right; }
.raid-rank-number { color: #c8c3c1; }
.raid-rank-identity { display: flex; gap: .65rem; align-items: center; white-space: normal; overflow-wrap: anywhere; }
.raid-rank-identity > :first-child { flex-shrink: 0; }
.raid-rank-identity strong { font-weight: 750; }
.raid-rank-identity small { display: block; color: var(--raid-muted); font-size: .73rem; line-height: 1.4; }
.raid-rank-portrait { width: 36px; height: 36px; object-fit: cover; border-radius: .42rem; background: #302726; }
.raid-rankings .mu-rank-online { display: inline-flex; align-items: center; gap: .35em; margin-inline-start: .4em; color: #70eaa1; font: 700 .72rem/1.25 Inter, sans-serif; white-space: nowrap; }
.raid-ranking-message { margin: 0; padding: 1.4rem 1.5rem; border-top: 1px solid var(--raid-border); color: var(--raid-muted); font-size: .9rem; }
.raid-board-footer { display: flex; justify-content: space-between; gap: .65rem; flex-wrap: wrap; border-top: 1px solid var(--raid-border); padding: .95rem 1.5rem; color: var(--raid-muted); font-size: .76rem; }
@media (max-width: 660px) {
    .raid-class-cards { grid-template-columns: repeat(6, minmax(0, 1fr)); gap: .5rem; padding: 0; }
    .raid-class-card { grid-column: span 2; }
    .raid-class-card:nth-child(4) { grid-column: 2 / span 2; }
    .raid-class-card-label span { font-size: .72rem; }
    .raid-board-head, .raid-class-filters, .raid-board-footer, .raid-rank-table th, .raid-rank-table td { padding-inline: .85rem; }
    .raid-rank-table th:first-child:not(:last-child) { width: auto; }
}
@media (max-width: 390px) {
    .raid-rank-table th, .raid-rank-table td { padding-inline: .5rem; }
    .raid-rank-portrait { width: 28px; height: 28px; }
}
@media (prefers-reduced-motion: reduce) {
    .raid-class-card img { transition: none; }
}
