:root {
    --fu-bg: #0b0d0f;
    --fu-navy: #08131a;
    --fu-panel: linear-gradient(rgba(14, 22, 30, 0.92), rgba(8, 12, 17, 0.94));
    --fu-cell: rgba(8, 19, 26, 0.72);
    --fu-line: rgba(238, 242, 244, 0.14);
    --fu-line-soft: rgba(238, 242, 244, 0.08);
    --fu-blue: #6fb2c9;
    --fu-blue-soft: rgba(111, 178, 201, 0.14);
    --fu-blue-glow: rgba(111, 178, 201, 0.3);
    --fu-blue-dim: #2f5c6b;
    --fu-gold: #c8b273;
    --fu-gold-line: rgba(200, 178, 115, 0.6);
    --fu-red: #e5432c;
    --fu-ink: #eef2f4;
    --fu-text: #bcc4c8;
    --fu-dim: #8b9aa1;
    --fu-discord: #8b93e8;
    --fu-head: 'Oswald', sans-serif;
    --fu-body: 'Inter', sans-serif;
    --fu-mono: ui-monospace, "Cascadia Mono", "Consolas", "Courier New", monospace;
    --m-in: 150ms;
    --m-out: 120ms;
    --m-press: 90ms;
    --m-ease: cubic-bezier(.2, 0, 0, 1);
    --m-ease-enter: cubic-bezier(.22, 1, .36, 1);
    --fu-noise: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='240' height='240'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='2'/%3E%3C/filter%3E%3Crect width='240' height='240' filter='url(%23n)'/%3E%3C/svg%3E");
}

html, body {
    background-color: var(--fu-bg);
}

body {
    font-family: var(--fu-body);
    color: var(--fu-text);
    background:
        linear-gradient(180deg, rgba(8, 19, 26, 0.55) 0%, rgba(11, 13, 15, 0.92) 55%, var(--fu-bg) 100%),
        var(--stats-background-image, none) center top / cover no-repeat fixed,
        var(--fu-bg);
}

body::before {
    background-image: var(--fu-noise);
    opacity: 0.05;
    mix-blend-mode: overlay;
}

body::after {
    background: radial-gradient(ellipse at 50% 30%, transparent 40%, rgba(0, 0, 0, 0.6) 100%);
}

.dashboard-split {
    gap: 28px;
}

.stats-card,
.chart-card,
.right-panel .chart-card,
.dashboard-split .right-panel .chart-card {
    position: relative;
    background: var(--fu-panel);
    border: 1px solid var(--fu-line);
    border-radius: 0;
    box-shadow: 0 30px 60px rgba(0, 0, 0, 0.45);
    backdrop-filter: blur(6px);
}

.stats-card::before,
.chart-card::before {
    content: '';
    position: absolute;
    top: -1px;
    left: -1px;
    right: -1px;
    height: 2px;
    background: linear-gradient(90deg, var(--fu-gold-line), rgba(200, 178, 115, 0.15) 60%, transparent);
    pointer-events: none;
}

.stats-card:hover,
.chart-card:hover {
    transform: none;
    box-shadow: 0 30px 60px rgba(0, 0, 0, 0.45);
}

.stats-icon i {
    color: var(--fu-blue);
    filter: drop-shadow(0 0 18px var(--fu-blue-glow));
}

.stats-number {
    font-family: var(--fu-head);
    font-weight: 600;
    color: #ffffff;
    letter-spacing: 4px;
    text-shadow: 0 0 40px rgba(111, 178, 201, 0.35);
    animation: none;
}

.stats-label {
    font-family: var(--fu-mono);
    font-size: 13px;
    font-weight: 400;
    letter-spacing: 4px;
    color: var(--fu-blue);
    text-shadow: none;
}

.stats-section-title {
    display: flex;
    align-items: center;
    gap: 14px;
}

.stats-section-title h2 {
    display: flex;
    align-items: center;
    gap: 14px;
    flex: 1;
    font-family: var(--fu-head);
    font-size: 22px;
    font-weight: 500;
    letter-spacing: 5px;
    color: var(--fu-ink);
    text-shadow: none;
}

.stats-section-title h2::after {
    content: '';
    flex: 1;
    height: 1px;
    background: linear-gradient(90deg, var(--fu-line), transparent);
}

.stats-section-subtitle {
    font-family: var(--fu-body);
    color: var(--fu-dim);
}

.game-stats-separator {
    background: var(--fu-line-soft);
}

.stat-card {
    --fu-accent: var(--fu-blue);
    background: var(--fu-cell);
    border: 1px solid var(--fu-line);
    border-left: 2px solid var(--fu-accent);
    border-radius: 0;
    box-shadow: none;
    backdrop-filter: none;
    font-family: var(--fu-body);
}

.stat-card:hover {
    transform: none;
    border-color: var(--fu-line);
    border-left-color: var(--fu-accent);
    box-shadow: none;
}

.stat-card--bg-tactical-blue { --fu-accent: var(--fu-blue); }
.stat-card--bg-tactical-gold { --fu-accent: var(--fu-gold); }
.stat-card--bg-tactical-red { --fu-accent: var(--fu-red); }
.stat-card--bg-tactical-orange { --fu-accent: #d9894a; }
.stat-card--bg-tactical-green { --fu-accent: #7fb88a; }
.stat-card--bg-tactical-purple { --fu-accent: #9a8ed1; }

.stat-card[class*="stat-card--bg-tactical"] {
    background: var(--fu-cell);
}

.stat-card__icon-wrapper,
.stat-card__icon-wrapper[class*="stat-card--bg-dark-tactical"] {
    background: transparent;
    border-right: 1px solid var(--fu-line-soft);
}

.stat-card__icon {
    color: var(--fu-accent);
}

.stat-card__header {
    font-family: var(--fu-head);
    font-weight: 600;
    letter-spacing: 3px;
    color: #ffffff;
    text-shadow: none;
}

.stat-card__subheader {
    font-family: var(--fu-mono);
    font-size: 10.5px;
    letter-spacing: 2.4px;
    color: var(--fu-dim);
    opacity: 1;
}

.chart-header {
    border-bottom: 1px solid var(--fu-line-soft);
}

.graph-tabs {
    gap: 6px;
}

.graph-tab {
    padding: 8px 13px;
    font-family: var(--fu-mono);
    font-size: 10.5px;
    font-weight: 400;
    letter-spacing: 2.4px;
    color: var(--fu-text);
    background: transparent;
    border: 1px solid var(--fu-line);
    border-radius: 0;
}

.graph-tab:hover {
    color: var(--fu-ink);
    background: var(--fu-blue-soft);
    border: 1px solid rgba(111, 178, 201, 0.55);
}

.graph-tab.active,
.graph-tab.active:hover {
    color: #061016;
    background: var(--fu-blue);
    border: 1px solid var(--fu-blue);
    box-shadow: none;
}

.graph-tab.active::after,
.graph-tab.active::before {
    display: none;
}

.auto-rotate-toggle {
    font-family: var(--fu-mono);
    font-size: 10.5px;
    letter-spacing: 2.4px;
    color: var(--fu-dim);
}

.auto-rotate-toggle:hover {
    color: var(--fu-ink);
}

.toggle-slider {
    border-radius: 0;
    background: transparent;
    border: 1px solid var(--fu-line);
}

.toggle-slider::before {
    border-radius: 0;
    background: var(--fu-dim);
    box-shadow: none;
}

.auto-rotate-toggle input:checked + .toggle-slider {
    background: var(--fu-blue-soft);
    border-color: var(--fu-blue);
}

.auto-rotate-toggle input:checked + .toggle-slider::before {
    background: var(--fu-blue);
}

.chart-container {
    background: rgba(6, 12, 17, 0.55);
    border: 1px solid var(--fu-line-soft);
    border-radius: 0;
}

.chart-loading {
    font-family: var(--fu-mono);
    letter-spacing: 2.4px;
    color: var(--fu-dim);
    background: rgba(6, 12, 17, 0.85);
}

.loading-spinner {
    border-color: var(--fu-line);
    border-top-color: var(--fu-blue);
}

.chart-time-range {
    font-family: var(--fu-mono);
    font-size: 10.5px;
    letter-spacing: 1.8px;
    text-transform: uppercase;
    color: var(--fu-dim);
    background: var(--fu-cell);
    border: 1px solid var(--fu-line);
    border-radius: 0;
}

.chart-time-range:hover {
    color: var(--fu-ink);
    background: var(--fu-cell);
    border-color: rgba(111, 178, 201, 0.55);
}

.chart-time-range .range-value {
    color: var(--fu-blue);
}

.time-range-dropdown,
.overflow-dropdown {
    background: #141618;
    border: 1px solid var(--fu-line);
    border-radius: 0;
    box-shadow: 0 24px 60px rgba(0, 0, 0, 0.8);
}

.time-range-option,
.overflow-tab {
    font-family: var(--fu-mono);
    font-size: 10.5px;
    letter-spacing: 1.8px;
    color: var(--fu-text);
    border-radius: 0;
}

.time-range-option:hover,
.overflow-tab:hover {
    color: var(--fu-ink);
    background: var(--fu-blue-soft);
}

.time-range-option.selected {
    color: #061016;
    background: var(--fu-blue);
}

footer .tactical-progress .loading-text,
.tactical-progress .loading-text {
    font-family: var(--fu-mono);
    font-size: 10.5px;
    font-weight: 400;
    letter-spacing: 2.4px;
    color: var(--fu-dim);
    text-shadow: none;
}

.tactical-progress .progress-bar {
    background: var(--fu-line-soft);
    border: none;
    border-radius: 0;
}

.tactical-progress .progress-fill {
    background: linear-gradient(90deg, var(--fu-blue-dim), var(--fu-blue));
    border-radius: 0;
    box-shadow: 0 0 12px var(--fu-blue-glow);
}

.embed-page-bg {
    background: transparent;
}

.stats-card-heading__title {
    font-family: var(--fu-head);
    font-weight: 500;
    letter-spacing: 5px;
    color: var(--fu-ink);
}

.stats-card-heading__logo {
    filter: none;
}

*:not(.loading-spinner),
*:not(.loading-spinner)::before,
*:not(.loading-spinner)::after {
    border-radius: 0 !important;
}

.stats-card .stats-icon i {
    color: var(--fu-blue) !important;
}

.stats-cards-container {
    background: var(--fu-panel);
    border: 1px solid var(--fu-line);
}

footer .tactical-progress .progress-bar {
    background: var(--fu-line-soft) !important;
}

footer .tactical-progress .progress-fill {
    background: linear-gradient(90deg, var(--fu-blue-dim), var(--fu-blue)) !important;
}

.embed-page-bg .stats-card {
    padding: 2rem 2rem 1.5rem;
    align-items: center;
}

.embed-page-bg .stats-number {
    margin: 0 !important;
    line-height: 1;
}

.embed-page-bg .stats-label {
    margin: 1rem 0 0;
    padding: 0;
    background: none;
    color: var(--fu-blue);
}

.embed-page-bg .stats-card-heading__title {
    margin-top: 10px;
    font-size: 14px;
    color: var(--fu-blue);
}

.embed-page-bg .stat-card__icon,
.embed-page-bg .platform-cards-row .stat-card__icon {
    color: var(--fu-accent);
}

.embed-page-bg .platform-cards-row .stat-card__subheader {
    padding: 0;
    background: none;
    color: var(--fu-dim);
}

.graph-tab,
.chart-time-range,
.time-range-option,
.overflow-tab {
    transition:
        color var(--m-out) var(--m-ease),
        background-color var(--m-out) var(--m-ease),
        border-color var(--m-out) var(--m-ease),
        transform var(--m-out) var(--m-ease);
}

@media (hover: hover) and (pointer: fine) {
    .graph-tab:hover,
    .chart-time-range:hover {
        transform: translateY(-1px);
        transition-duration: var(--m-in);
    }
}

.graph-tab:active,
.chart-time-range:active,
.time-range-option:active,
.overflow-tab:active {
    transform: translateY(1px) scale(.985);
    transition-duration: var(--m-press);
}

.graph-tab:focus-visible,
.chart-time-range:focus-visible,
.time-range-option:focus-visible,
.overflow-tab:focus-visible,
.auto-rotate-toggle input:focus-visible + .toggle-slider {
    outline: 2px solid var(--fu-blue);
    outline-offset: 2px;
    transition: none;
}

.auto-rotate-toggle {
    position: relative;
}

.auto-rotate-toggle input {
    display: block;
    position: absolute;
    width: 1px;
    height: 1px;
    margin: 0;
    opacity: 0;
    pointer-events: none;
}

@keyframes fu-enter {
    from {
        opacity: 0;
        transform: translateY(14px) scale(.985);
    }
    to {
        opacity: 1;
        transform: none;
    }
}

.dashboard-split > .left-panel,
.dashboard-split > .right-panel {
    animation: fu-enter 1.1s var(--m-ease-enter) both;
}

.dashboard-split > .left-panel {
    animation-delay: 60ms;
}

.dashboard-split > .right-panel {
    animation-delay: 220ms;
}

@media (prefers-reduced-motion: reduce) {
    .dashboard-split > .left-panel,
    .dashboard-split > .right-panel {
        animation: none;
    }

    .graph-tab,
    .chart-time-range,
    .time-range-option,
    .overflow-tab {
        transition-property: color, background-color, border-color;
    }

    .graph-tab:hover,
    .graph-tab:active,
    .chart-time-range:hover,
    .chart-time-range:active,
    .time-range-option:active,
    .overflow-tab:active {
        transform: none;
    }
}

.page > .container .left-panel > .stats-card {
    flex: 1 1 auto;
    justify-content: center;
}

.page > .container .stats-cards-container {
    flex: 0 0 auto;
    box-sizing: border-box;
    width: 100%;
    height: auto;
    padding: 20px !important;
}

.page > .container .platform-cards-row {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)) !important;
    gap: 14px !important;
}

.page > .container .stat-card__subheader {
    display: block;
    overflow: visible;
    white-space: normal;
    text-overflow: clip;
    -webkit-line-clamp: unset;
}

.page > .container .platform-cards-row .stat-card {
    width: auto !important;
    min-width: 0 !important;
    max-width: none !important;
    margin: 0;
}

@media (max-width: 1279px) {
    html:has(.page > .container),
    body:has(.page > .container) {
        position: relative !important;
        height: auto !important;
        min-height: 100% !important;
        overflow-x: hidden !important;
        overflow-y: auto !important;
    }

    .page > .container {
        height: auto !important;
        min-height: 100vh !important;
        max-height: none !important;
        overflow: visible !important;
        padding-bottom: 48px !important;
    }

    .page > .container .dashboard {
        transform: none !important;
        box-sizing: border-box !important;
        width: 100% !important;
        min-width: 0 !important;
        max-width: 100% !important;
        height: auto !important;
        margin: 0 !important;
        padding: 24px !important;
    }

    .page > .container .dashboard-split {
        display: flex !important;
        flex-direction: column !important;
        gap: 20px !important;
        height: auto !important;
    }

    .page > .container .left-panel,
    .page > .container .right-panel {
        width: 100% !important;
        max-width: none !important;
        height: auto !important;
        min-height: 0 !important;
    }

    .page > .container .left-panel {
        display: grid !important;
        grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
        gap: 20px !important;
    }

    .page > .container .left-panel > .stats-card,
    .page > .container .stats-cards-container {
        margin: 0 !important;
        height: auto !important;
    }

    .page > .container .left-panel > .stats-card {
        padding: 28px 20px !important;
    }

    .page > .container .stats-number {
        font-size: clamp(56px, 9vw, 112px) !important;
        line-height: 1 !important;
        margin: 8px 0 !important;
    }

    .page > .container .stats-icon i {
        font-size: clamp(32px, 5vw, 52px) !important;
    }

    .page > .container .stats-label {
        font-size: 13px !important;
        letter-spacing: 4px !important;
    }

    .page > .container .right-panel .chart-card {
        height: auto !important;
        margin: 0 !important;
    }

    .page > .container .chart-container {
        height: clamp(340px, 56vh, 520px) !important;
    }
}

@media (max-width: 767px) {
    .page > .container .dashboard {
        padding: 16px !important;
    }

    .page > .container .left-panel {
        grid-template-columns: minmax(0, 1fr);
        gap: 16px !important;
    }

    .page > .container .dashboard-split {
        gap: 16px !important;
    }


    .page > .container .stats-section-title h2 {
        font-size: 18px !important;
        letter-spacing: 4px;
    }

    .page > .container .chart-header {
        flex-direction: column-reverse;
        align-items: stretch;
        gap: 12px;
    }

    .page > .container .graph-tabs {
        display: grid !important;
        grid-template-columns: repeat(auto-fit, minmax(0, 1fr));
        overflow: visible !important;
    }

    .page > .container .graph-tab {
        min-height: 44px !important;
        text-align: center;
    }

    .page > .container .chart-controls {
        align-self: flex-end;
    }

    .page > .container .chart-container {
        height: 400px !important;
    }
}
