:root {
    --bg: #08111f;
    --bg-accent: #122b4d;
    --panel: rgba(10, 4, 16, 0.9);
    --panel-strong: #12081b;
    --line: rgba(92, 160, 255, 0.2);
    --text: #f4f8ff;
    --muted: #9fb7d7;
    --accent: #4da3ff;
    --accent-strong: #1877f2;
    --danger: #ff5a5f;
    --warning: #ffd84e;
    --shadow: 0 30px 80px rgba(0, 0, 0, 0.32);
}

* {
    box-sizing: border-box;
}

html,
body {
    margin: 0;
    min-height: 100%;
}

body {
    --page-character-left-image: none;
    --page-character-right-image: none;
    position: relative;
    font-family: "Space Grotesk", sans-serif;
    color: var(--text);
    background: var(--bg);
    overflow-x: hidden;
}

body::before {
    content: "";
    position: fixed;
    inset: 0;
    z-index: 0;
    pointer-events: none;
    background-image:
        linear-gradient(rgba(255, 255, 255, 0.03) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 255, 255, 0.03) 1px, transparent 1px);
    background-size: 42px 42px;
    mask-image: radial-gradient(circle at center, black, transparent 82%);
}

.page-characters {
    position: fixed;
    inset: 0;
    z-index: 0;
    pointer-events: none;
}

.page-characters::before,
.page-characters::after {
    content: "";
    position: absolute;
    top: 0;
    bottom: 0;
    width: clamp(250px, 28vw, 440px);
    opacity: 0.34;
    background-repeat: no-repeat;
    background-size: 100% 100%, 100% 100%, auto 100%;
    background-position: center, center, center;
    filter: drop-shadow(0 24px 50px rgba(0, 0, 0, 0.34));
}

.page-characters::before {
    left: min(-36px, calc((100vw - 1240px) / 2 - 138px));
    background-image:
        linear-gradient(to top, rgba(8, 17, 31, 0.92) 0%, rgba(8, 17, 31, 0.78) 12%, rgba(8, 17, 31, 0.4) 24%, rgba(8, 17, 31, 0) 42%),
        linear-gradient(to right, rgba(8, 17, 31, 0.88) 0%, rgba(8, 17, 31, 0.42) 14%, rgba(8, 17, 31, 0.12) 26%, rgba(8, 17, 31, 0) 38%, rgba(8, 17, 31, 0) 52%, rgba(8, 17, 31, 0.38) 66%, rgba(8, 17, 31, 0.78) 82%, rgba(8, 17, 31, 0.98) 100%),
        var(--page-character-left-image);
}

.page-characters::after {
    right: min(-36px, calc((100vw - 1240px) / 2 - 138px));
    background-image:
        linear-gradient(to top, rgba(8, 17, 31, 0.92) 0%, rgba(8, 17, 31, 0.78) 12%, rgba(8, 17, 31, 0.4) 24%, rgba(8, 17, 31, 0) 42%),
        linear-gradient(to left, rgba(8, 17, 31, 0.88) 0%, rgba(8, 17, 31, 0.42) 14%, rgba(8, 17, 31, 0.12) 26%, rgba(8, 17, 31, 0) 38%, rgba(8, 17, 31, 0) 52%, rgba(8, 17, 31, 0.38) 66%, rgba(8, 17, 31, 0.78) 82%, rgba(8, 17, 31, 0.98) 100%),
        var(--page-character-right-image);
}

.auth-page--login {
    --page-character-left-image: url("../img/characters/hero-2.jpg");
    --page-character-right-image: url("../img/characters/hero-6.jpg");
}

.auth-page--set-password {
    --page-character-left-image: url("../img/characters/hero-5.jpg");
    --page-character-right-image: url("../img/characters/hero-3.jpg");
}

.app-page--dashboard {
    --page-character-left-image: url("../img/characters/hero-5.jpg");
    --page-character-right-image: url("../img/characters/hero-6.jpg");
}

.app-page--matches {
    --page-character-left-image: url("../img/characters/hero-4.jpg");
    --page-character-right-image: url("../img/characters/hero-3.jpg");
}

.app-page--predictions {
    --page-character-left-image: url("../img/characters/hero-2.jpg");
    --page-character-right-image: url("../img/characters/hero-4.jpg");
}

.app-page--leaderboard {
    --page-character-left-image: url("../img/characters/hero-6.jpg");
    --page-character-right-image: url("../img/characters/hero-3.jpg");
}

.app-page--match-detail {
    --page-character-left-image: url("../img/characters/hero-5.jpg");
    --page-character-right-image: url("../img/characters/hero-2.jpg");
}

.error-page--404 {
    --page-character-left-image: url("../img/characters/hero-3.jpg");
    --page-character-right-image: url("../img/characters/hero-5.jpg");
}

.error-page--500 {
    --page-character-left-image: url("../img/characters/hero-6.jpg");
    --page-character-right-image: url("../img/characters/hero-4.jpg");
}

a {
    color: inherit;
    text-decoration: none;
}

.auth-shell,
.dashboard-shell {
    position: relative;
    z-index: 1;
    width: min(1120px, calc(100% - 32px));
    margin: 0 auto;
    min-height: 100vh;
    display: grid;
    align-items: center;
    gap: 28px;
    padding: 32px 0;
}

.auth-shell {
    grid-template-columns: minmax(0, 1.1fr) minmax(320px, 430px);
}

.error-shell {
    position: relative;
    z-index: 1;
}

.app-page .dashboard-shell {
    min-height: auto;
    padding-top: 8px;
    padding-bottom: 36px;
}

.site-header {
    position: sticky;
    top: 0;
    z-index: 10;
    padding: 18px 16px 0;
}

.flash-stack {
    position: sticky;
    top: 102px;
    z-index: 9;
    width: min(1240px, calc(100% - 32px));
    margin: 12px auto 0;
    display: grid;
    gap: 10px;
}

.flash-message {
    padding: 14px 18px;
    border-radius: 18px;
    border: 1px solid rgba(92, 160, 255, 0.18);
    backdrop-filter: blur(18px);
    box-shadow: var(--shadow);
}

.flash-message--success {
    background: rgba(18, 81, 158, 0.78);
}

.flash-message--error {
    background: rgba(128, 24, 38, 0.82);
}

.flash-message--info {
    background: rgba(11, 28, 56, 0.82);
}

.legal-notice-modal {
    position: fixed;
    inset: 0;
    z-index: 40;
    display: grid;
    place-items: center;
    padding: 24px 16px;
    background: rgba(3, 8, 17, 0.76);
    backdrop-filter: blur(12px);
}

.legal-notice-modal__card {
    width: min(860px, 100%);
    max-height: min(88vh, 900px);
    overflow-y: auto;
    border-radius: 30px;
    border: 1px solid rgba(92, 160, 255, 0.2);
    box-shadow: var(--shadow);
    background:
        radial-gradient(circle at top right, rgba(77, 163, 255, 0.18), transparent 30%),
        linear-gradient(180deg, rgba(255, 255, 255, 0.035), rgba(255, 255, 255, 0.01)),
        rgba(10, 4, 16, 0.96);
    padding: 30px;
}

.legal-notice-modal__card h2 {
    margin: 10px 0 0;
    font-size: clamp(2rem, 4vw, 3rem);
    line-height: 0.98;
    letter-spacing: -0.05em;
}

.legal-notice-modal__content {
    display: grid;
    gap: 22px;
    margin-top: 24px;
}

.legal-notice-modal__section {
    padding: 22px;
    border-radius: 24px;
    border: 1px solid rgba(92, 160, 255, 0.16);
    background: rgba(255, 255, 255, 0.03);
}

.legal-notice-modal__section h3 {
    margin: 0 0 12px;
    font-size: 1.2rem;
    letter-spacing: -0.02em;
}

.legal-notice-modal__section p {
    margin: 0;
    color: var(--muted);
    line-height: 1.75;
}

.legal-notice-modal__section p + p {
    margin-top: 12px;
}

.legal-notice-modal__actions {
    display: flex;
    justify-content: flex-end;
    margin-top: 24px;
}

.legal-notice-modal__button {
    min-width: 220px;
}

.site-header__inner {
    width: min(1240px, 100%);
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
    padding: 14px 18px;
    border: 1px solid var(--line);
    border-radius: 26px;
    backdrop-filter: blur(20px);
    background: rgba(8, 4, 13, 0.82);
    box-shadow: var(--shadow);
}

.brand-mark {
    display: inline-flex;
    align-items: center;
    gap: 12px;
}

.brand-mark__logo {
    display: block;
    width: auto;
    height: 34px;
    flex-shrink: 0;
}

.brand-mark__text {
    display: grid;
    gap: 2px;
}

.brand-mark__text strong,
.profile-chip strong {
    font-size: 0.96rem;
}

.brand-mark__text small,
.profile-chip__meta,
.leaderboard-row__user small,
.result-row small {
    color: var(--muted);
}

.site-nav {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 6px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(92, 160, 255, 0.12);
}

.site-nav__link {
    padding: 10px 16px;
    border-radius: 999px;
    color: var(--muted);
    font-size: 0.95rem;
}

.site-nav__link--active {
    color: var(--text);
    background: rgba(77, 163, 255, 0.18);
}

.site-nav__link.is-disabled {
    opacity: 0.65;
}

.site-header__actions {
    display: flex;
    align-items: center;
    gap: 12px;
}

.profile-chip {
    display: grid;
    gap: 2px;
    text-align: right;
}

.ghost-button {
    border: 1px solid rgba(92, 160, 255, 0.22);
    background: rgba(255, 255, 255, 0.015);
    color: var(--text);
    padding: 12px 16px;
    border-radius: 14px;
    font: inherit;
    cursor: pointer;
}

.auth-hero,
.auth-card,
.dashboard-card {
    backdrop-filter: blur(18px);
    border: 1px solid var(--line);
    box-shadow: var(--shadow);
}

.auth-hero,
.dashboard-card {
    border-radius: 32px;
    padding: 40px;
    background:
        linear-gradient(180deg, rgba(255, 255, 255, 0.035), rgba(255, 255, 255, 0.012)),
        rgba(12, 5, 18, 0.78);
}

.auth-hero h1,
.dashboard-card h1 {
    margin: 16px 0 12px;
    max-width: 10ch;
    font-size: clamp(2.5rem, 6vw, 5.5rem);
    line-height: 0.95;
    letter-spacing: -0.05em;
}

.eyebrow,
.card-kicker {
    margin: 0;
    color: var(--accent);
    text-transform: uppercase;
    letter-spacing: 0.18em;
    font-size: 0.78rem;
    font-weight: 700;
}

.auth-copy,
.card-copy {
    margin: 0;
    max-width: 52ch;
    color: var(--muted);
    font-size: 1.02rem;
    line-height: 1.7;
}

.hero-badges {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-top: 28px;
}

.hero-badges span {
    border: 1px solid rgba(77, 163, 255, 0.24);
    background: rgba(13, 6, 20, 0.86);
    border-radius: 999px;
    padding: 10px 14px;
    color: var(--text);
    font-size: 0.92rem;
}

.hero-link-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 1px solid rgba(255, 216, 78, 0.3);
    background: rgba(255, 216, 78, 0.12);
    border-radius: 999px;
    padding: 10px 14px;
    color: var(--warning);
    font-size: 0.92rem;
}

.auth-card {
    border-radius: 28px;
    padding: 30px;
    background: var(--panel);
}

.error-hero h1 {
    max-width: 12ch;
}

.error-card {
    position: relative;
    overflow: hidden;
}

.error-card::before {
    content: "";
    position: absolute;
    inset: auto -80px -80px auto;
    width: 180px;
    height: 180px;
    border-radius: 999px;
    background: radial-gradient(circle, rgba(77, 163, 255, 0.22) 0%, rgba(77, 163, 255, 0) 72%);
}

.error-card__code {
    margin: 0 0 18px;
    font-size: clamp(4rem, 10vw, 7rem);
    line-height: 0.88;
    letter-spacing: -0.08em;
    font-weight: 700;
    color: rgba(244, 248, 255, 0.18);
}

.error-card__actions {
    position: relative;
    z-index: 1;
    display: grid;
    gap: 12px;
}

.error-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 100%;
}

.card-header {
    margin-bottom: 24px;
}

.card-header h2 {
    margin: 10px 0 10px;
    font-size: 2rem;
    line-height: 1.05;
    letter-spacing: -0.04em;
}

.auth-form {
    display: grid;
    gap: 18px;
}

.form-field {
    display: grid;
    gap: 8px;
}

.form-field label {
    font-size: 0.92rem;
    color: var(--text);
}

.form-input {
    width: 100%;
    border: 1px solid rgba(92, 160, 255, 0.18);
    background: rgba(255, 255, 255, 0.03);
    color: var(--text);
    border-radius: 16px;
    padding: 16px 18px;
    font: inherit;
    transition: border-color 0.2s ease, transform 0.2s ease, background-color 0.2s ease;
}

.form-input::placeholder {
    color: #a98cc7;
}

.form-input:focus {
    outline: none;
    border-color: var(--accent);
    background: rgba(255, 255, 255, 0.05);
    transform: translateY(-1px);
}

.form-alert,
.field-error {
    color: var(--danger);
    font-size: 0.9rem;
}

.form-alert {
    border: 1px solid rgba(255, 90, 95, 0.3);
    background: rgba(92, 18, 30, 0.3);
    border-radius: 14px;
    padding: 12px 14px;
}

.form-alert p,
.field-error {
    margin: 0;
}

.form-help {
    color: var(--muted);
    font-size: 0.88rem;
    line-height: 1.5;
}

.form-help ul {
    margin: 0;
    padding-left: 20px;
}

.auth-actions {
    display: flex;
    align-items: center;
    gap: 12px;
}

.primary-button {
    border: 0;
    border-radius: 16px;
    padding: 16px 20px;
    font: inherit;
    font-weight: 700;
    color: #fff7db;
    background: linear-gradient(135deg, var(--accent) 0%, var(--accent-strong) 100%);
    cursor: pointer;
    box-shadow: 0 18px 40px rgba(24, 119, 242, 0.34);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.primary-button:hover,
.primary-button:focus-visible {
    transform: translateY(-2px);
    box-shadow: 0 24px 48px rgba(24, 119, 242, 0.42);
}

.dashboard-shell {
    grid-template-columns: 1fr;
}

.panel,
.dashboard-card {
    backdrop-filter: blur(18px);
    border: 1px solid var(--line);
    box-shadow: var(--shadow);
    background:
        linear-gradient(180deg, rgba(255, 255, 255, 0.035), rgba(255, 255, 255, 0.012)),
        rgba(12, 5, 18, 0.78);
    border-radius: 30px;
}

.dashboard-hero {
    display: grid;
    grid-template-columns: minmax(0, 1.6fr) minmax(280px, 360px);
    gap: 24px;
    padding: 30px;
}

.dashboard-hero h1 {
    margin: 14px 0 12px;
    max-width: 10ch;
    font-size: clamp(2.6rem, 6vw, 5.4rem);
    line-height: 0.92;
    letter-spacing: -0.06em;
}

.hero-scorecard {
    padding: 24px;
    border-radius: 24px;
    background:
        radial-gradient(circle at top right, rgba(77, 163, 255, 0.24), transparent 36%),
        linear-gradient(180deg, rgba(77, 163, 255, 0.08), rgba(255, 255, 255, 0.02)),
        rgba(10, 4, 16, 0.96);
    border: 1px solid rgba(77, 163, 255, 0.2);
}

.hero-scorecard__header,
.match-card__meta,
.match-card__footer,
.section-heading,
.result-row,
.leaderboard-row,
.prediction-card,
.match-card__teams,
.site-header__inner {
    display: flex;
    align-items: center;
}

.hero-scorecard__header,
.match-card__meta,
.match-card__footer,
.section-heading,
.result-row,
.leaderboard-row,
.prediction-card {
    justify-content: space-between;
}

.hero-scorecard__value {
    margin-top: 18px;
    font-size: clamp(4rem, 8vw, 6rem);
    line-height: 0.9;
    letter-spacing: -0.08em;
    font-weight: 700;
}

.hero-scorecard__label {
    margin: 10px 0 20px;
    color: var(--muted);
    max-width: 18ch;
}

.hero-scorecard__meta {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.hero-scorecard__meta span,
.section-badge {
    padding: 8px 12px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.04);
    color: var(--text);
    font-size: 0.85rem;
}

.live-dot {
    width: 10px;
    height: 10px;
    border-radius: 999px;
    background: var(--danger);
    box-shadow: 0 0 0 6px rgba(255, 90, 95, 0.18);
}

.dashboard-kpis {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 18px;
}

.kpi-card {
    padding: 24px;
}

.kpi-card__label,
.section-kicker {
    color: var(--muted);
    text-transform: uppercase;
    letter-spacing: 0.16em;
    font-size: 0.74rem;
}

.kpi-card__value {
    display: block;
    margin-top: 12px;
    font-size: clamp(2rem, 4vw, 3.2rem);
    letter-spacing: -0.06em;
}

.kpi-card__hint {
    margin: 10px 0 0;
    color: var(--muted);
}

.dashboard-grid {
    display: grid;
    grid-template-columns: minmax(0, 1.35fr) minmax(320px, 0.9fr);
    gap: 20px;
}

.dashboard-section {
    padding: 24px;
}

.dashboard-section--primary {
    padding: 26px;
}

.section-heading {
    gap: 16px;
    margin-bottom: 18px;
}

.section-heading h2 {
    margin: 8px 0 0;
    font-size: 1.5rem;
    letter-spacing: -0.04em;
}

.dashboard-rail {
    display: grid;
    gap: 20px;
}

.match-stack,
.prediction-list,
.leaderboard-list,
.result-list {
    display: grid;
    gap: 14px;
}

.match-card,
.prediction-card,
.leaderboard-row,
.result-row,
.empty-state {
    border-radius: 22px;
    border: 1px solid rgba(92, 160, 255, 0.12);
    background: rgba(10, 4, 16, 0.82);
}

.match-card {
    position: relative;
    padding: 18px;
}

.prediction-card--match,
.result-row--match {
    position: relative;
}

.match-card__overlay,
.prediction-match-card__overlay,
.card-link-overlay {
    display: block;
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    border-radius: inherit;
    z-index: 2;
    pointer-events: auto;
}

.match-card > :not(.match-card__overlay),
.prediction-match-card > :not(.prediction-match-card__overlay),
.prediction-card--match > :not(.card-link-overlay),
.result-row--match > :not(.card-link-overlay) {
    position: relative;
    z-index: 1;
}

.prediction-match-card button,
.prediction-match-card input,
.prediction-match-card label {
    position: relative;
    z-index: 3;
}

.prediction-match-card .prediction-choice-form {
    position: relative;
    z-index: auto;
}

.match-card:hover,
.prediction-match-card:hover,
.prediction-card--match:hover,
.result-row--match:hover {
    border-color: rgba(77, 163, 255, 0.36);
    cursor: pointer;
}

.match-card--live {
    background:
        radial-gradient(circle at top right, rgba(255, 90, 95, 0.18), transparent 34%),
        rgba(14, 4, 14, 0.92);
}

.status-pill {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 7px 11px;
    border-radius: 999px;
    font-size: 0.8rem;
    color: var(--text);
    background: rgba(255, 255, 255, 0.05);
}

.status-pill--live {
    background: rgba(255, 90, 95, 0.18);
    color: #ffd8da;
}

.status-pill--finished {
    background: rgba(77, 163, 255, 0.16);
    color: #e6ccff;
}

.status-pill--cancelled {
    background: rgba(255, 255, 255, 0.04);
    color: var(--muted);
}

.status-pill--postponed {
    background: rgba(255, 196, 102, 0.16);
    color: #ffe3ad;
}

.status-pill--abandoned {
    background: rgba(255, 120, 120, 0.14);
    color: #ffc6c6;
}

.match-card__teams {
    gap: 12px;
    margin: 16px 0;
}

.team-line {
    flex: 1;
    display: flex;
    align-items: center;
    gap: 10px;
    min-width: 0;
    font-weight: 500;
}

.team-line--right {
    justify-content: flex-end;
    text-align: right;
}

.team-line__flag {
    font-size: 1.2rem;
}

.team-line__flag--logo {
    width: 26px;
    height: 26px;
    object-fit: contain;
    flex-shrink: 0;
}

.match-card__score {
    font-size: 1.5rem;
    letter-spacing: -0.05em;
    white-space: nowrap;
}

.match-card__kickoff-row {
    display: flex;
    justify-content: center;
    margin-top: 14px;
    margin-bottom: -4px;
    text-align: center;
}

.match-card__kickoff {
    color: var(--muted);
    font-size: 0.78rem;
    line-height: 1.2;
    white-space: nowrap;
}

.match-card__score--vs {
    color: var(--accent);
}

.match-card__footer {
    gap: 12px;
    color: var(--muted);
    font-size: 0.88rem;
}

.prediction-card,
.leaderboard-row,
.result-row {
    padding: 16px 18px;
    gap: 12px;
}

.prediction-card p {
    margin: 6px 0 0;
    color: var(--muted);
    font-size: 0.88rem;
}

.filter-form {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 18px;
}

.filter-form__input {
    flex: 1;
}

.filter-form__button,
.filter-form__clear {
    flex-shrink: 0;
}

.filter-form__summary {
    margin: -6px 0 18px;
    color: var(--muted);
    font-size: 0.92rem;
}

.pagination-nav {
    display: grid;
    grid-template-columns: minmax(120px, 1fr) auto minmax(120px, 1fr);
    align-items: center;
    gap: 16px;
    max-width: 520px;
    margin: 28px auto 0;
    color: var(--muted);
}

.pagination-nav__button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 120px;
    padding: 12px 18px;
    border-radius: 999px;
    border: 1px solid rgba(77, 163, 255, 0.72);
    background: linear-gradient(180deg, #4da3ff, #2e7de1);
    color: #f8fbff;
    text-decoration: none;
    font-weight: 700;
    box-shadow: 0 14px 30px rgba(46, 125, 225, 0.28);
    transition: transform 0.18s ease, box-shadow 0.18s ease, filter 0.18s ease;
}

.pagination-nav__button:hover {
    transform: translateY(-1px);
    box-shadow: 0 18px 34px rgba(46, 125, 225, 0.34);
    filter: brightness(1.05);
}

.pagination-nav__button:first-child {
    justify-self: start;
}

.pagination-nav__button:last-child {
    justify-self: end;
}

.pagination-nav__button--ghost {
    visibility: hidden;
    pointer-events: none;
}

.pagination-nav__status {
    text-align: center;
    font-size: 0.92rem;
    white-space: nowrap;
}

.leaderboard-row__rank {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 46px;
    min-width: 46px;
    height: 46px;
    border-radius: 14px;
    background: rgba(77, 163, 255, 0.14);
    color: var(--accent);
    font-weight: 700;
}

.leaderboard-row__user {
    flex: 1;
    display: grid;
    gap: 4px;
}

.leaderboard-row__user small {
    color: var(--muted);
}

.leaderboard-row__points {
    white-space: nowrap;
    font-size: 1.05rem;
}

.leaderboard-row--me {
    position: relative;
    border-color: rgba(255, 216, 78, 0.46);
    box-shadow:
        inset 0 0 0 1px rgba(255, 216, 78, 0.14),
        0 10px 26px rgba(255, 216, 78, 0.08);
    background:
        radial-gradient(circle at left center, rgba(255, 216, 78, 0.12), transparent 30%),
        linear-gradient(90deg, rgba(255, 216, 78, 0.08), rgba(77, 163, 255, 0.03) 36%, rgba(10, 4, 16, 0.82)),
        rgba(10, 4, 16, 0.88);
}

.leaderboard-row--me::before {
    content: "";
    position: absolute;
    inset: 10px auto 10px 10px;
    width: 4px;
    border-radius: 999px;
    background: linear-gradient(180deg, #ffd84e, #ffb347);
}

.leaderboard-row--me .leaderboard-row__rank {
    background: linear-gradient(135deg, rgba(255, 216, 78, 0.24), rgba(255, 179, 71, 0.24));
    color: #fff4c7;
    box-shadow: inset 0 0 0 1px rgba(255, 216, 78, 0.18);
}

.leaderboard-row--me .leaderboard-row__user strong,
.leaderboard-row--me .leaderboard-row__points {
    color: #fff7db;
}

.leaderboard-row__badge {
    display: inline-flex;
    align-items: center;
    margin-right: 8px;
    padding: 2px 8px;
    border-radius: 999px;
    background: rgba(255, 216, 78, 0.18);
    border: 1px solid rgba(255, 216, 78, 0.24);
    color: #fff1b5;
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    vertical-align: middle;
}

.leaderboard-row--focus {
    position: relative;
    border-color: rgba(77, 163, 255, 0.52);
    box-shadow:
        inset 0 0 0 1px rgba(77, 163, 255, 0.16),
        0 14px 34px rgba(24, 119, 242, 0.18);
    background:
        radial-gradient(circle at left center, rgba(255, 216, 78, 0.14), transparent 28%),
        linear-gradient(90deg, rgba(77, 163, 255, 0.16), rgba(77, 163, 255, 0.04) 28%, rgba(77, 163, 255, 0.02)),
        rgba(10, 4, 16, 0.88);
}

.leaderboard-row--focus::before {
    content: "";
    position: absolute;
    inset: 10px auto 10px 10px;
    width: 4px;
    border-radius: 999px;
    background: linear-gradient(180deg, #ffd84e, #4da3ff);
}

.leaderboard-row--focus .leaderboard-row__rank {
    background: linear-gradient(135deg, rgba(255, 216, 78, 0.22), rgba(77, 163, 255, 0.3));
    color: #fff4c7;
    box-shadow: inset 0 0 0 1px rgba(255, 216, 78, 0.14);
}

.leaderboard-row--focus .leaderboard-row__user strong,
.leaderboard-row--focus .leaderboard-row__points {
    color: #fff7db;
}

.leaderboard-row--focus .leaderboard-row__user small {
    color: #d7cfff;
}

.result-row__teams {
    display: flex;
    align-items: center;
    gap: 10px;
    font-weight: 700;
}

.result-row__logo {
    width: 22px;
    height: 22px;
    object-fit: contain;
    flex-shrink: 0;
}

.empty-state {
    padding: 22px;
}

.empty-state h3 {
    margin: 0 0 8px;
    font-size: 1rem;
}

.empty-state p {
    margin: 0;
    color: var(--muted);
    line-height: 1.6;
}

.empty-state--compact {
    padding: 18px;
}

.leaderboard-page {
    padding: 24px;
}

.matches-page {
    padding: 24px;
}

.matches-board {
    display: grid;
    gap: 24px;
}

.matches-board__section {
    display: grid;
    gap: 14px;
}

.matches-board__heading {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding: 0 4px;
}

.matches-board__heading h3 {
    margin: 0;
    font-size: 1.08rem;
    letter-spacing: -0.03em;
}

.matches-board__heading span {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 34px;
    height: 34px;
    padding: 0 10px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.04);
    color: var(--muted);
    font-size: 0.86rem;
}

.match-card--schedule {
    background:
        radial-gradient(circle at top right, rgba(77, 163, 255, 0.08), transparent 30%),
        rgba(10, 4, 16, 0.82);
}

.predictions-layout {
    display: grid;
    gap: 20px;
}

.predictions-bottom-grid {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    gap: 20px;
}

.prediction-match-stack {
    display: grid;
    gap: 18px;
}

.prediction-match-card {
    position: relative;
    padding: 20px;
    border-radius: 24px;
    border: 1px solid rgba(92, 160, 255, 0.12);
    background:
        radial-gradient(circle at top right, rgba(77, 163, 255, 0.1), transparent 32%),
        rgba(10, 4, 16, 0.82);
}

.match-detail-hero h1 {
    max-width: 12ch;
}

.match-detail-scorecard {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
    gap: 16px;
    align-items: center;
    padding: 24px;
    border-radius: 24px;
    background:
        radial-gradient(circle at top right, rgba(77, 163, 255, 0.2), transparent 36%),
        rgba(10, 4, 16, 0.96);
    border: 1px solid rgba(77, 163, 255, 0.18);
}

.match-detail-team {
    display: grid;
    gap: 6px;
}

.match-detail-team span {
    font-size: 2.4rem;
}

.match-detail-team__flag {
    width: 56px;
    height: 56px;
    object-fit: contain;
}

.match-detail-team small,
.team-action-card small {
    color: var(--muted);
}

.match-detail-team--right {
    justify-items: end;
    text-align: right;
}

.match-detail-score {
    display: grid;
    place-items: center;
    min-width: 86px;
    height: 86px;
    padding: 0 14px;
    border-radius: 26px;
    background: rgba(255, 255, 255, 0.04);
    color: var(--text);
    font-size: 1.65rem;
    font-weight: 700;
    letter-spacing: -0.05em;
}

.match-detail-score--vs {
    color: var(--accent);
}

.match-detail-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 20px;
}

.match-predict-panel {
    display: grid;
    gap: 18px;
}

.match-predict-panel--wide {
    grid-column: 1 / -1;
}

.team-action-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
}

.team-action-card {
    display: grid;
    gap: 14px;
    padding: 18px;
    border-radius: 22px;
    border: 1px solid rgba(92, 160, 255, 0.12);
    background: rgba(10, 4, 16, 0.82);
}

.team-action-card__flag {
    display: block;
    margin-bottom: 8px;
    font-size: 2rem;
    width: 40px;
    height: 40px;
    object-fit: contain;
}

.team-action-card--form {
    align-content: start;
}

.prediction-match-card__top,
.prediction-match-card__meta,
.prediction-match-card__teams,
.prediction-match-card__footer,
.bonus-form__split {
    display: flex;
    align-items: center;
}

.prediction-match-card__top,
.prediction-match-card__footer {
    justify-content: space-between;
    gap: 14px;
}

.prediction-match-card__teams {
    gap: 16px;
    margin: 18px 0;
}

.prediction-team {
    flex: 1;
    display: grid;
    gap: 6px;
    justify-items: start;
}

.prediction-team--right {
    justify-items: end;
    text-align: right;
}

.prediction-team__flag {
    font-size: 2rem;
    width: 40px;
    height: 40px;
    object-fit: contain;
}

.prediction-versus {
    display: grid;
    place-items: center;
    width: 62px;
    height: 62px;
    border-radius: 18px;
    background: rgba(255, 255, 255, 0.04);
    color: var(--accent);
    font-weight: 700;
}

.prediction-points-pill {
    padding: 9px 12px;
    border-radius: 999px;
    background: rgba(255, 216, 78, 0.14);
    color: var(--warning);
    font-size: 0.84rem;
    white-space: nowrap;
}

.prediction-choice-form {
    display: grid;
    gap: 16px;
}

.prediction-choice-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 12px;
}

.prediction-choice {
    position: relative;
    display: block;
    cursor: pointer;
}

.prediction-choice input {
    position: absolute;
    opacity: 0;
    pointer-events: none;
}

.prediction-choice span {
    display: block;
    padding: 16px 14px;
    text-align: center;
    border-radius: 18px;
    border: 1px solid rgba(92, 160, 255, 0.14);
    background: rgba(255, 255, 255, 0.03);
    transition: border-color 0.2s ease, background-color 0.2s ease, transform 0.2s ease;
}

.prediction-choice input:checked + span,
.prediction-choice--selected span,
.prediction-choice:hover span {
    border-color: rgba(77, 163, 255, 0.42);
    background: rgba(77, 163, 255, 0.14);
    transform: translateY(-1px);
}

.prediction-match-card__footer p {
    margin: 6px 0 0;
    color: var(--muted);
}

.prediction-save-button {
    min-width: 150px;
    padding: 14px 18px;
}

.ghost-note {
    color: var(--muted);
    font-size: 0.92rem;
}

.bonus-panel,
.scoring-panel {
    display: grid;
    gap: 18px;
}

.bonus-stats {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
}

.bonus-stat-card {
    display: grid;
    gap: 8px;
    padding: 18px;
    border-radius: 20px;
    border: 1px solid rgba(92, 160, 255, 0.12);
    background: rgba(255, 255, 255, 0.03);
}

.bonus-stat-card strong {
    font-size: 1.6rem;
    color: var(--warning);
}

.bonus-stat-card span,
.bonus-deadlines p {
    color: var(--muted);
    line-height: 1.5;
}

.bonus-deadlines {
    padding: 16px 18px;
    border-radius: 18px;
    background: rgba(255, 216, 78, 0.12);
    border: 1px solid rgba(255, 216, 78, 0.28);
}

.bonus-deadlines p {
    margin: 0;
}

.bonus-deadlines p + p {
    margin-top: 10px;
}

.bonus-form {
    display: grid;
    gap: 12px;
}

.bonus-form__split {
    gap: 12px;
}

.bonus-form__split > div {
    flex: 1;
}

.bonus-form__label {
    display: inline-block;
    margin-bottom: 8px;
    font-size: 0.92rem;
}

.prediction-select {
    width: 100%;
    border: 1px solid rgba(92, 160, 255, 0.18);
    background: rgba(255, 255, 255, 0.035);
    color: var(--text);
    border-radius: 18px;
    padding: 16px 18px;
    font: inherit;
}

.scoring-rules {
    display: grid;
    gap: 12px;
}

.scoring-rule {
    display: flex;
    justify-content: space-between;
    gap: 16px;
    padding: 16px 18px;
    border-radius: 18px;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(92, 160, 255, 0.1);
}

.scoring-rule span {
    color: var(--muted);
    text-align: right;
}

.scoring-rule--danger strong,
.scoring-rule--danger span {
    color: var(--danger);
}

.leaderboard-table {
    display: grid;
    gap: 12px;
}

.leaderboard-table__head,
.leaderboard-table__row {
    display: grid;
    grid-template-columns: 90px minmax(180px, 1.4fr) 110px 110px 110px minmax(220px, 1.6fr);
    gap: 14px;
    align-items: center;
}

.leaderboard-table__head {
    padding: 0 8px 8px;
    color: var(--muted);
    font-size: 0.84rem;
    text-transform: uppercase;
    letter-spacing: 0.12em;
}

.leaderboard-table__row {
    position: relative;
    padding: 18px;
    border-radius: 22px;
    border: 1px solid rgba(92, 160, 255, 0.12);
    background: rgba(10, 4, 16, 0.82);
}

.leaderboard-table__row--me {
    border-color: rgba(255, 216, 78, 0.46);
    box-shadow:
        inset 0 0 0 1px rgba(255, 216, 78, 0.14),
        0 10px 26px rgba(255, 216, 78, 0.08);
    background:
        radial-gradient(circle at left center, rgba(255, 216, 78, 0.12), transparent 28%),
        linear-gradient(90deg, rgba(255, 216, 78, 0.08), rgba(77, 163, 255, 0.03) 36%, rgba(10, 4, 16, 0.82)),
        rgba(10, 4, 16, 0.88);
}

.leaderboard-table__row--me::before {
    content: "";
    position: absolute;
    inset: 10px auto 10px 10px;
    width: 4px;
    border-radius: 999px;
    background: linear-gradient(180deg, #ffd84e, #ffb347);
}

.leaderboard-table__row--focus {
    background:
        radial-gradient(circle at left center, rgba(255, 216, 78, 0.14), transparent 28%),
        linear-gradient(90deg, rgba(77, 163, 255, 0.16), rgba(77, 163, 255, 0.04) 28%, rgba(77, 163, 255, 0.02)),
        rgba(10, 4, 16, 0.88);
}

.leaderboard-table__row--me .leaderboard-table__rank {
    background: linear-gradient(135deg, rgba(255, 216, 78, 0.24), rgba(255, 179, 71, 0.24));
    color: #fff4c7;
    box-shadow: inset 0 0 0 1px rgba(255, 216, 78, 0.18);
    padding: 12px 14px;
    border-radius: 14px;
    justify-self: start;
}

.leaderboard-table__row--me .leaderboard-table__player strong,
.leaderboard-table__row--me .leaderboard-table__total {
    color: #fff7db;
}

.leaderboard-table__row--focus .leaderboard-table__player small {
    color: #d7cfff;
}

.leaderboard-table__rank,
.leaderboard-table__total {
    font-weight: 700;
}

.leaderboard-table__player {
    display: grid;
    gap: 4px;
}

.leaderboard-table__player small {
    color: var(--muted);
}

.leaderboard-table__meta {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.leaderboard-table__meta span {
    padding: 7px 10px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.035);
    font-size: 0.82rem;
    color: var(--muted);
}

@media (max-width: 900px) {
    .auth-shell,
    .dashboard-grid,
    .dashboard-hero,
    .dashboard-kpis,
    .match-detail-grid,
    .team-action-grid {
        grid-template-columns: 1fr;
    }

    .auth-hero h1,
    .dashboard-card h1,
    .dashboard-hero h1 {
        max-width: none;
    }

    .page-characters::before,
    .page-characters::after {
        width: clamp(180px, 24vw, 280px);
        opacity: 0.22;
    }

    .site-header__inner,
    .site-header__actions {
        flex-wrap: wrap;
    }

    .site-nav {
        order: 3;
        width: 100%;
        overflow-x: auto;
    }

    .prediction-choice-grid,
    .bonus-stats,
    .bonus-form__split,
    .predictions-bottom-grid {
        grid-template-columns: 1fr;
        display: grid;
    }

    .leaderboard-table__head {
        display: none;
    }

    .leaderboard-table__row {
        grid-template-columns: 1fr;
    }

    .match-predict-panel--wide {
        grid-column: auto;
    }
}

@media (max-width: 640px) {
    .auth-shell,
    .dashboard-shell {
        width: min(100% - 20px, 1120px);
        padding: 18px 0;
    }

    .auth-hero,
    .auth-card,
    .dashboard-card,
    .dashboard-hero,
    .dashboard-section,
    .kpi-card {
        padding: 24px;
        border-radius: 24px;
    }

    .legal-notice-modal__card {
        padding: 22px;
        border-radius: 24px;
    }

    .legal-notice-modal__section {
        padding: 18px;
        border-radius: 20px;
    }

    .legal-notice-modal__actions {
        justify-content: stretch;
    }

    .legal-notice-modal__button {
        width: 100%;
    }

    .card-header h2 {
        font-size: 1.65rem;
    }

    .form-input,
    .primary-button {
        padding: 14px 16px;
    }

    .site-header {
        padding: 12px 10px 0;
    }

    .site-header__inner {
        padding: 14px;
        border-radius: 22px;
    }

    .page-characters::before,
    .page-characters::after {
        display: none;
    }

    .brand-mark__logo {
        height: 28px;
    }

    .brand-mark__text small {
        display: none;
    }

    .match-card__teams,
    .match-card__footer,
    .match-detail-scorecard,
    .prediction-card,
    .leaderboard-row,
    .result-row,
    .prediction-match-card__top,
    .prediction-match-card__teams,
    .prediction-match-card__footer,
    .scoring-rule {
        align-items: flex-start;
        flex-direction: column;
    }

    .filter-form {
        align-items: stretch;
        flex-direction: column;
    }

    .team-line,
    .team-line--right,
    .match-detail-team--right,
    .prediction-team--right {
        justify-content: flex-start;
        text-align: left;
        justify-items: start;
    }

    .match-detail-scorecard {
        grid-template-columns: 1fr;
    }
}
