/* ============================================================
   Ratings (Hall of Fame) — 블루/퍼플 네온 톤
   ============================================================ */

.page-ratings {
    background:
        radial-gradient(ellipse 1100px 700px at 12% 0%, rgba(0, 130, 255, 0.13) 0%, transparent 60%),
        radial-gradient(ellipse 900px 600px at 88% 18%, rgba(160, 107, 255, 0.12) 0%, transparent 60%),
        #06070d;
    color: #fff;
    font-family: 'Inter', 'Noto Sans KR', system-ui, sans-serif;
}

/* ===== HERO ===== */
.rt-hero {
    position: relative;
    margin-top: var(--fixed-header-h, 96px);
    padding: 72px 0 60px;
    overflow: hidden;
    isolation: isolate;
    border-bottom: 1px solid rgba(160, 107, 255, 0.16);
}
.rt-hero-bg {
    position: absolute; inset: 0; z-index: -2;
    background:
        radial-gradient(ellipse 70% 100% at 0% 0%, rgba(0, 198, 255, 0.18) 0%, transparent 55%),
        radial-gradient(ellipse 80% 100% at 100% 100%, rgba(201, 92, 255, 0.16) 0%, transparent 60%),
        linear-gradient(135deg, #050714 0%, #0a0b18 50%, #0d0a1a 100%);
}
.rt-hero-bg::after {
    content: ""; position: absolute; inset: 0;
    background-image: repeating-linear-gradient(135deg, rgba(91, 139, 255, 0.04) 0 2px, transparent 2px 14px);
    opacity: 0.55;
}
.rt-hero-orbs { position: absolute; inset: 0; z-index: -1; pointer-events: none; }
.rt-hero-orb {
    position: absolute;
    border-radius: 50%;
    filter: blur(80px);
    opacity: 0.3;
    animation: rt-orb-drift 18s ease-in-out infinite alternate;
}
.rt-hero-orb--cyan {
    width: 360px; height: 360px;
    top: -110px; left: -70px;
    background: radial-gradient(circle, #00d4ff 0%, transparent 70%);
}
.rt-hero-orb--violet {
    width: 440px; height: 440px;
    bottom: -150px; right: -90px;
    background: radial-gradient(circle, #c95cff 0%, transparent 70%);
    animation-delay: -9s;
}
@keyframes rt-orb-drift {
    from { transform: translate(0, 0) scale(1); }
    to   { transform: translate(36px, 28px) scale(1.06); }
}

.rt-hero-content { max-width: 900px; }
.rt-hero-eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    font-family: 'Inter', 'Noto Sans KR', system-ui, sans-serif;
    font-size: 0.8rem;
    font-weight: 800;
    letter-spacing: 0.08em;
    color: #c5b8ff;
    margin-bottom: 16px;
    padding: 6px 16px;
    border: 1px solid rgba(139, 92, 255, 0.45);
    background: rgba(91, 139, 255, 0.12);
    border-radius: 999px;
    text-transform: uppercase;
    backdrop-filter: blur(8px);
    box-shadow: 0 4px 14px rgba(123, 92, 255, 0.18);
}
.rt-hero-eyebrow i {
    color: #ffd24c;
    filter: drop-shadow(0 0 6px rgba(255, 210, 76, 0.6));
}
.rt-hero-title {
    font-size: clamp(2.4rem, 5.5vw, 4rem);
    font-weight: 800;
    line-height: 1.04;
    letter-spacing: -0.02em;
    margin: 0 0 14px;
    color: #fff;
}
.rt-hero-title-grad {
    background: linear-gradient(135deg, #5fd9ff 0%, #8b5cff 60%, #c95cff 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    filter: drop-shadow(0 6px 30px rgba(160, 107, 255, 0.4));
}
.rt-hero-sub {
    max-width: 620px;
    font-size: 1rem;
    line-height: 1.7;
    color: rgba(255, 255, 255, 0.7);
    margin: 0;
}

/* ===== STATS STRIP ===== */
.rt-stats-strip {
    position: relative;
    z-index: 3;
    margin-top: -32px;
    margin-bottom: 30px;
}
.rt-stats-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 14px;
}
@media (max-width: 768px) {
    .rt-stats-grid { grid-template-columns: 1fr; }
}

.rt-stat-card {
    position: relative;
    padding: 16px 18px;
    border-radius: 14px;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.04) 0%, rgba(255, 255, 255, 0.01) 100%);
    border: 1px solid rgba(255, 255, 255, 0.07);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.06), 0 10px 24px rgba(0, 0, 0, 0.28);
    overflow: hidden;
    display: flex;
    align-items: center;
    gap: 14px;
    min-height: 84px;
    transition: transform 0.22s ease, border-color 0.22s ease, box-shadow 0.22s ease;
}
.rt-stat-card::before {
    content: "";
    position: absolute; inset: 0;
    border-radius: inherit;
    padding: 1px;
    background: linear-gradient(135deg, transparent 0%, transparent 55%, var(--stat-c, #5b8bff) 100%);
    -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    -webkit-mask-composite: xor;
    mask-composite: exclude;
    opacity: 0.55;
    pointer-events: none;
}
.rt-stat-card::after {
    content: "";
    position: absolute;
    top: -40%; right: -30%;
    width: 140px; height: 140px;
    border-radius: 50%;
    background: radial-gradient(circle, var(--stat-c, #5b8bff) 0%, transparent 70%);
    opacity: 0.14;
    pointer-events: none;
    transition: opacity 0.22s ease, transform 0.22s ease;
}
.rt-stat-card:hover {
    transform: translateY(-3px);
    border-color: rgba(255, 255, 255, 0.14);
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.08),
        0 14px 30px rgba(0, 0, 0, 0.36),
        0 0 22px color-mix(in srgb, var(--stat-c, #5b8bff) 22%, transparent);
}
.rt-stat-card:hover::after { opacity: 0.28; transform: scale(1.1); }

.rt-stat-card--cyan   { --stat-c: #00d4ff; }
.rt-stat-card--blue   { --stat-c: #5b8bff; }
.rt-stat-card--purple { --stat-c: #a06bff; }

.rt-stat-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 44px; height: 44px;
    border-radius: 12px;
    flex-shrink: 0;
    background: color-mix(in srgb, var(--stat-c, #5b8bff) 14%, rgba(255, 255, 255, 0.02));
    border: 1px solid color-mix(in srgb, var(--stat-c, #5b8bff) 36%, transparent);
    color: var(--stat-c, #5b8bff);
    font-size: 1.15rem;
    box-shadow: 0 0 16px color-mix(in srgb, var(--stat-c, #5b8bff) 30%, transparent);
}
.rt-stat-body { display: flex; flex-direction: column; min-width: 0; flex: 1; }
.rt-stat-value {
    font-family: 'Inter', 'Noto Sans KR', system-ui, sans-serif;
    font-size: 1.5rem;
    font-weight: 800;
    line-height: 1.05;
    letter-spacing: -0.01em;
    color: #fff;
    font-variant-numeric: tabular-nums;
    text-shadow: 0 0 16px color-mix(in srgb, var(--stat-c, #5b8bff) 50%, transparent);
    margin-bottom: 2px;
}
.rt-stat-label {
    font-family: 'Inter', 'Noto Sans KR', system-ui, sans-serif;
    font-size: 0.74rem;
    font-weight: 800;
    letter-spacing: 0.06em;
    color: rgba(255, 255, 255, 0.6);
    text-transform: uppercase;
}

/* ===== MAIN ===== */
.rt-main { padding-bottom: 80px; }

/* ===== TABS ===== */
.rt-tabs {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
    margin-bottom: 20px;
}
@media (max-width: 540px) {
    .rt-tabs { grid-template-columns: 1fr; }
}
.rt-tab {
    position: relative;
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 16px 20px;
    border-radius: 14px;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.025) 0%, rgba(255, 255, 255, 0.008) 100%);
    border: 1px solid rgba(255, 255, 255, 0.07);
    text-decoration: none;
    color: rgba(255, 255, 255, 0.65);
    transition: all 0.22s ease;
    overflow: hidden;
}
.rt-tab:hover {
    color: #fff;
    border-color: rgba(139, 92, 255, 0.35);
    transform: translateY(-2px);
    box-shadow: 0 10px 24px rgba(0, 0, 0, 0.28), 0 0 18px rgba(123, 92, 255, 0.18);
}
.rt-tab i {
    font-size: 1.4rem;
    color: rgba(255, 255, 255, 0.4);
    transition: color 0.22s ease, filter 0.22s ease;
}
.rt-tab-label {
    font-family: 'Inter', 'Noto Sans KR', system-ui, sans-serif;
    font-size: 0.95rem;
    font-weight: 800;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    line-height: 1.1;
}
.rt-tab-sub {
    display: block;
    font-size: 0.78rem;
    color: rgba(255, 255, 255, 0.45);
    margin-top: 3px;
    font-weight: 500;
    letter-spacing: 0;
}

.rt-tab.is-active {
    background: linear-gradient(135deg, rgba(31, 155, 255, 0.16), rgba(139, 92, 255, 0.22));
    border-color: rgba(139, 92, 255, 0.6);
    color: #fff;
    box-shadow:
        0 0 0 1px rgba(139, 92, 255, 0.45) inset,
        0 8px 24px rgba(123, 92, 255, 0.32);
}
.rt-tab.is-active i {
    color: #c5a8ff;
    filter: drop-shadow(0 0 8px rgba(160, 107, 255, 0.6));
}
.rt-tab.is-active .rt-tab-sub { color: rgba(255, 255, 255, 0.7); }

/* ===== PANEL ===== */
.rt-panel {
    position: relative;
    padding: 22px 22px 24px;
    border-radius: 18px;
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.025) 0%, rgba(255, 255, 255, 0.008) 100%);
    border: 1px solid rgba(255, 255, 255, 0.07);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.05),
        0 12px 32px rgba(0, 0, 0, 0.28);
    overflow: hidden;
}
.rt-panel::before {
    content: "";
    position: absolute; inset: 0;
    border-radius: inherit;
    padding: 1px;
    background: linear-gradient(135deg, transparent 0%, transparent 50%, #a06bff 100%);
    -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    -webkit-mask-composite: xor;
    mask-composite: exclude;
    opacity: 0.5;
    pointer-events: none;
}

.rt-panel-head {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    flex-wrap: wrap;
    gap: 16px;
    margin-bottom: 18px;
    padding-bottom: 16px;
    border-bottom: 1px solid rgba(160, 107, 255, 0.18);
}
.rt-panel-head-left { min-width: 0; flex: 1 1 280px; }
.rt-panel-head-right {
    display: flex;
    align-items: center;
    gap: 14px;
    flex-wrap: wrap;
}
.rt-panel-title {
    display: inline-flex;
    align-items: center;
    gap: 9px;
    margin: 0 0 4px;
    font-family: 'Inter', 'Noto Sans KR', system-ui, sans-serif;
    font-size: 1rem;
    font-weight: 800;
    letter-spacing: 0.04em;
    color: #fff;
    text-transform: uppercase;
}
.rt-panel-title i {
    color: #a06bff;
    filter: drop-shadow(0 0 6px rgba(160, 107, 255, 0.5));
}
.rt-panel-desc {
    font-size: 0.86rem;
    color: rgba(255, 255, 255, 0.55);
    margin: 0;
    line-height: 1.6;
}

.rt-meta {
    font-size: 0.84rem;
    color: rgba(255, 255, 255, 0.55);
    white-space: nowrap;
}
.rt-meta-num {
    color: #c5a8ff;
    font-weight: 800;
    font-variant-numeric: tabular-nums;
}

/* ===== SEARCH ===== */
.rt-search-wrap {
    position: relative;
    display: inline-flex;
    align-items: center;
    width: 240px;
    max-width: 100%;
}
.rt-search-icon {
    position: absolute;
    left: 12px;
    top: 50%;
    transform: translateY(-50%);
    color: rgba(255, 255, 255, 0.35);
    font-size: 0.85rem;
    pointer-events: none;
}
.rt-search-input {
    width: 100%;
    padding: 8px 36px 8px 34px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.08);
    color: #fff;
    font-family: 'Inter', 'Noto Sans KR', system-ui, sans-serif;
    font-size: 0.86rem;
    transition: border-color 0.18s ease, background 0.18s ease;
}
.rt-search-input::placeholder { color: rgba(255, 255, 255, 0.35); }
.rt-search-input:focus {
    outline: none;
    border-color: rgba(139, 92, 255, 0.55);
    background: rgba(255, 255, 255, 0.06);
    box-shadow: 0 0 12px rgba(123, 92, 255, 0.22);
}
.rt-search-clear {
    position: absolute;
    right: 10px;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: 0;
    color: rgba(255, 255, 255, 0.45);
    cursor: pointer;
    padding: 4px 6px;
    border-radius: 6px;
    display: none;
    font-size: 0.8rem;
    transition: color 0.18s ease, background 0.18s ease;
}
.rt-search-clear:hover { color: #fff; background: rgba(255, 255, 255, 0.06); }

/* ===== TABLE ===== */
.rt-table-wrap { overflow-x: auto; }
.rt-table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
    table-layout: fixed;
}
.rt-table thead th {
    font-family: 'Inter', 'Noto Sans KR', system-ui, sans-serif;
    font-size: 0.78rem;
    font-weight: 800;
    letter-spacing: 0.04em;
    color: rgba(255, 255, 255, 0.5);
    text-transform: uppercase;
    padding: 12px 12px;
    border-bottom: 1px solid rgba(160, 107, 255, 0.18);
    background: transparent;
    white-space: nowrap;
}
.rt-table tbody td {
    padding: 12px 12px;
    vertical-align: middle;
    border-bottom: 1px solid rgba(255, 255, 255, 0.04);
}
.rt-table tbody tr {
    cursor: pointer;
    transition: background 0.18s ease;
}
.rt-table tbody tr:hover {
    background: color-mix(in srgb, #a06bff 6%, transparent);
}
.rt-table tbody tr:last-child td { border-bottom: none; }

.rt-rank-cell { text-align: center; }
.rt-rank-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 30px;
    height: 30px;
    padding: 0 9px;
    border-radius: 8px;
    font-family: 'Inter', 'Noto Sans KR', system-ui, sans-serif;
    font-weight: 800;
    font-size: 0.92rem;
    color: rgba(255, 255, 255, 0.55);
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.07);
    font-variant-numeric: tabular-nums;
}
.rt-rank-1 { color: #ffd24c; background: rgba(255, 210, 76, 0.1); border-color: rgba(255, 210, 76, 0.45); text-shadow: 0 0 12px rgba(255, 210, 76, 0.5); }
.rt-rank-2 { color: #dcdcdc; background: rgba(220, 220, 220, 0.08); border-color: rgba(220, 220, 220, 0.35); text-shadow: 0 0 10px rgba(220, 220, 220, 0.4); }
.rt-rank-3 { color: #e09558; background: rgba(224, 149, 88, 0.1); border-color: rgba(224, 149, 88, 0.4); text-shadow: 0 0 10px rgba(224, 149, 88, 0.45); }

.rt-table tbody tr.rt-row-rank-1 { background: linear-gradient(90deg, rgba(255, 210, 76, 0.08), transparent 60%); }
.rt-table tbody tr.rt-row-rank-2 { background: linear-gradient(90deg, rgba(220, 220, 220, 0.05), transparent 60%); }
.rt-table tbody tr.rt-row-rank-3 { background: linear-gradient(90deg, rgba(224, 149, 88, 0.05), transparent 60%); }
.rt-table tbody tr.rt-row-rank-1:hover { background: linear-gradient(90deg, rgba(255, 210, 76, 0.14), color-mix(in srgb, #a06bff 6%, transparent) 60%); }
.rt-table tbody tr.rt-row-rank-2:hover { background: linear-gradient(90deg, rgba(220, 220, 220, 0.1), color-mix(in srgb, #a06bff 6%, transparent) 60%); }
.rt-table tbody tr.rt-row-rank-3:hover { background: linear-gradient(90deg, rgba(224, 149, 88, 0.1), color-mix(in srgb, #a06bff 6%, transparent) 60%); }

.rt-driver {
    font-family: 'Inter', 'Noto Sans KR', system-ui, sans-serif;
    font-weight: 800;
    font-size: 0.96rem;
    color: #fff;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.rt-driver i {
    margin-left: 5px;
    font-size: 0.78rem;
    color: rgba(255, 255, 255, 0.32);
    transition: color 0.18s ease, transform 0.18s ease;
}
.rt-table tbody tr:hover .rt-driver i {
    color: #a06bff;
    transform: translate(2px, -2px);
}

.rt-rating {
    font-family: 'Inter', 'Noto Sans KR', system-ui, sans-serif;
    font-weight: 800;
    font-size: 1.04rem;
    line-height: 1;
    margin-bottom: 6px;
    font-variant-numeric: tabular-nums;
    text-shadow: 0 0 10px currentColor;
}
.rt-rating--high { color: #00ffaa; }
.rt-rating--mid  { color: #ffaa00; }
.rt-rating--low  { color: #ff5b5b; }
.rt-rating-bar-wrap {
    height: 4px;
    border-radius: 4px;
    background: rgba(255, 255, 255, 0.05);
    overflow: hidden;
    max-width: 160px;
    margin: 0 auto;
}
.rt-rating-bar {
    height: 100%;
    border-radius: 4px;
    box-shadow: 0 0 8px currentColor;
    transition: width 0.5s ease;
}

.rt-race-pts {
    font-family: 'Inter', 'Noto Sans KR', system-ui, sans-serif;
    font-weight: 800;
    font-size: 1.05rem;
    background: linear-gradient(135deg, #fff 0%, #c5a8ff 60%, #d77dff 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    letter-spacing: 0;
    font-variant-numeric: tabular-nums;
    filter: drop-shadow(0 0 8px rgba(160, 107, 255, 0.55));
}
.rt-race-pts-unit { font-size: 0.7rem; opacity: 0.7; margin-left: 3px; -webkit-text-fill-color: #c5a8ff; }

.rt-meta-cell {
    font-size: 0.84rem;
    color: rgba(255, 255, 255, 0.55);
    font-variant-numeric: tabular-nums;
}

/* ===== SKELETON ===== */
.rt-skeleton-row td { background: transparent !important; }
.rt-skeleton {
    display: inline-block;
    height: 14px;
    border-radius: 6px;
    background: linear-gradient(90deg, rgba(255, 255, 255, 0.04) 0%, rgba(91, 139, 255, 0.14) 50%, rgba(255, 255, 255, 0.04) 100%);
    background-size: 200% 100%;
    animation: rt-skeleton-shimmer 1.4s ease-in-out infinite;
}
.rt-skeleton--rank { width: 30px; height: 30px; border-radius: 8px; }
.rt-skeleton--driver { width: 80%; max-width: 200px; }
.rt-skeleton--rating { width: 80%; max-width: 160px; height: 22px; border-radius: 6px; }
.rt-skeleton--meta { width: 60px; }
.rt-skeleton--date { width: 90px; }
@keyframes rt-skeleton-shimmer {
    0%   { background-position: 200% 0; }
    100% { background-position: -200% 0; }
}

.rt-summary-skeleton {
    display: inline-block;
    height: 1.5rem;
    width: 80px;
    border-radius: 6px;
    background: linear-gradient(90deg, rgba(255, 255, 255, 0.04) 0%, rgba(91, 139, 255, 0.14) 50%, rgba(255, 255, 255, 0.04) 100%);
    background-size: 200% 100%;
    animation: rt-skeleton-shimmer 1.4s ease-in-out infinite;
}

/* 빈 / 검색 결과 없음 */
.rt-empty {
    text-align: center;
    padding: 64px 16px;
    color: rgba(255, 255, 255, 0.4);
}
.rt-empty i {
    display: block;
    font-size: 2.4rem;
    margin-bottom: 12px;
    color: rgba(160, 107, 255, 0.4);
}

.rt-search-count {
    margin-top: 4px;
    font-size: 0.78rem;
    color: rgba(255, 255, 255, 0.55);
}
.rt-search-count strong {
    color: #c5a8ff;
    font-weight: 800;
}

/* ===== PAGINATION ===== */
.rt-pagination {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;
    gap: 6px;
    margin-top: 18px;
    padding-top: 16px;
    border-top: 1px dashed rgba(160, 107, 255, 0.18);
}
.rt-pg-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 34px;
    height: 34px;
    padding: 0 10px;
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.07);
    color: rgba(255, 255, 255, 0.65);
    font-family: 'Inter', 'Noto Sans KR', system-ui, sans-serif;
    font-weight: 700;
    font-size: 0.86rem;
    text-decoration: none;
    transition: all 0.18s ease;
    cursor: pointer;
}
.rt-pg-btn:hover {
    background: rgba(139, 92, 255, 0.12);
    border-color: rgba(139, 92, 255, 0.35);
    color: #fff;
}
.rt-pg-btn.is-active {
    background: linear-gradient(135deg, #1f9bff 0%, #8b5cff 100%);
    border-color: rgba(139, 92, 255, 0.6);
    color: #fff;
    box-shadow: 0 4px 14px rgba(123, 92, 255, 0.42);
}
.rt-pg-btn.is-disabled {
    opacity: 0.35;
    pointer-events: none;
}
.rt-pg-info {
    margin-left: 8px;
    color: rgba(255, 255, 255, 0.42);
    font-size: 0.78rem;
}

/* ===== 모바일 ===== */
@media (max-width: 768px) {
    .rt-hero { padding: 56px 0 44px; }
    .rt-stats-strip { margin-top: -20px; }
    .rt-stat-card { padding: 13px 14px; min-height: 72px; }
    .rt-stat-icon { width: 38px; height: 38px; font-size: 1rem; }
    .rt-stat-value { font-size: 1.25rem; }
    .rt-tab { padding: 14px 16px; gap: 10px; }
    .rt-tab i { font-size: 1.2rem; }
    .rt-table thead th, .rt-table tbody td { padding: 10px 8px; }
    .rt-panel-head-right { width: 100%; }
    .rt-search-wrap { flex: 1; }
}
