:root {
    --ink: #0b0d12;
    --ink-mid: #151820;
    --ink-soft: #1e2230;
    --ink-muted: #2a2f42;

    --chalk: #f5f2ec;
    --chalk-dim: #a8a49c;
    --chalk-ghost: #4a4a55;

    --neon-draw: #c8f53a;
    --neon-guess: #38d4f5;
    --neon-warn: #f5803a;
    --neon-win: #a3f53a;

    --gold: #f5c842;
    --rose: #f5425a;

    --surface-1: rgba(21, 24, 32, 0.92);
    --surface-2: rgba(30, 34, 48, 0.85);
    --surface-3: rgba(42, 47, 66, 0.6);

    --glow-draw: 0 0 24px rgba(200, 245, 58, 0.25);
    --glow-guess: 0 0 24px rgba(56, 212, 245, 0.25);

    --r-xs: 6px;
    --r-sm: 12px;
    --r-md: 20px;
    --r-lg: 32px;

    --ease-out-expo: cubic-bezier(0.16, 1, 0.3, 1);
    --ease-spring: cubic-bezier(0.34, 1.56, 0.64, 1);

    --transition-smooth: all 0.35s var(--ease-out-expo);
}

*,
*::before,
*::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    background-color: var(--ink);
    color: var(--chalk);
    font-family: 'DM Sans', sans-serif;
    font-size: 15px;
    line-height: 1.6;
    min-height: 100vh;
    overflow-x: hidden;
    position: relative;
    -webkit-font-smoothing: antialiased;
}

body::before {
    content: '';
    position: fixed;
    inset: 0;
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noise'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noise)' opacity='1'/%3E%3C/svg%3E");
    opacity: 0.025;
    pointer-events: none;
    z-index: 999;
}

::-webkit-scrollbar {
    width: 6px;
}

::-webkit-scrollbar-track {
    background: var(--ink-soft);
}

::-webkit-scrollbar-thumb {
    background: var(--ink-muted);
    border-radius: 3px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--chalk-ghost);
}

[hidden] {
    display: none !important;
}

.bg-animation {
    position: fixed;
    inset: 0;
    z-index: 0;
    overflow: hidden;
    pointer-events: none;
}

.blob-1,
.blob-2,
.blob-3 {
    position: absolute;
    border-radius: 50%;
    filter: blur(100px);
    animation: drift 25s ease-in-out infinite;
}

.blob-1 {
    width: 700px;
    height: 700px;
    background: radial-gradient(circle, rgba(200, 245, 58, 0.07) 0%, transparent 70%);
    top: -20%;
    left: -15%;
    animation-duration: 28s;
}

.blob-2 {
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, rgba(56, 212, 245, 0.06) 0%, transparent 70%);
    bottom: -15%;
    right: -10%;
    animation-duration: 22s;
    animation-delay: -8s;
}

.blob-3 {
    width: 400px;
    height: 400px;
    background: radial-gradient(circle, rgba(245, 66, 90, 0.05) 0%, transparent 70%);
    top: 40%;
    left: 50%;
    animation-duration: 35s;
    animation-delay: -15s;
}

@keyframes drift {

    0%,
    100% {
        transform: translate(0, 0) scale(1);
    }

    25% {
        transform: translate(40px, -60px) scale(1.08);
    }

    50% {
        transform: translate(-30px, 40px) scale(0.94);
    }

    75% {
        transform: translate(60px, 20px) scale(1.05);
    }
}

.home-button {
    position: absolute;
    top: 24px;
    left: 24px;
    display: flex;
    align-items: center;
    gap: 8px;
    color: var(--chalk);
    text-decoration: none;
    font-weight: 700;
    font-size: 13px;
    opacity: 0.6;
    transition: var(--transition-smooth);
    z-index: 2000;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.home-button:hover {
    opacity: 1;
    transform: translateX(-5px);
}

.home-button svg {
    transition: transform 0.3s var(--ease-spring);
}

.home-button:hover svg {
    transform: scale(1.1);
}

.container {
    position: relative;
    z-index: 1;
    max-width: 1000px;
    margin: 0 auto;
    padding: 0 24px;
}

.main-menu {
    max-width: 900px !important;
    padding-top: 0;
    text-align: center;
}

.gs-menu {
    max-width: 1000px !important;
}

h1,
h2,
h3 {
    font-family: 'DM Serif Display', serif;
    line-height: 1.15;
    font-weight: 400;
}

h1 {
    font-size: clamp(2rem, 5vw, 3.5rem);
}

h2 {
    font-size: clamp(1.5rem, 3vw, 2.2rem);
}

h3 {
    font-size: 1.3rem;
}

.subtitle {
    color: var(--chalk-dim);
    font-size: 1.05rem;
    font-weight: 300;
    font-style: italic;
    letter-spacing: 0.01em;
}

.header {
    text-align: center;
    padding: 60px 0 40px;
}

.logo {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 16px;
    margin-bottom: 12px;
}

.logo-icon {
    font-size: 2.5rem;
    filter: drop-shadow(0 0 12px rgba(200, 245, 58, 0.4));
    animation: wcBob 3s ease-in-out infinite;
}

@keyframes wcBob {

    0%,
    100% {
        transform: rotate(-5deg) scale(1);
    }

    50% {
        transform: rotate(5deg) scale(1.05);
    }
}

@keyframes fadeInUp {
    from {
        transform: translateY(24px);
        opacity: 0;
    }

    to {
        transform: translateY(0);
        opacity: 1;
    }
}

.animate-up {
    animation: fadeInUp 0.5s var(--ease-out-expo) both;
}

.animate-up-2 {
    animation: fadeInUp 0.5s var(--ease-out-expo) 0.1s both;
}

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 12px 28px;
    border-radius: 100px;
    font-family: 'DM Sans', sans-serif;
    font-weight: 700;
    font-size: 13px;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    cursor: pointer;
    border: none;
    text-decoration: none;
    color: var(--ink);
    transition: transform 0.2s var(--ease-spring), filter 0.2s, box-shadow 0.2s;
    position: relative;
    overflow: hidden;
    white-space: nowrap;
}

.btn::after {
    content: '';
    position: absolute;
    inset: 0;
    background: rgba(255, 255, 255, 0.15);
    opacity: 0;
    transition: opacity 0.2s;
}

.btn:hover {
    transform: translateY(-3px);
    filter: brightness(1.08);
}

.btn:hover::after {
    opacity: 1;
}

.btn:active {
    transform: translateY(0) scale(0.97);
}

.btn-primary {
    background: var(--neon-draw);
    box-shadow: 0 6px 20px rgba(200, 245, 58, 0.3), var(--glow-draw);
}

.btn:disabled {
    opacity: 0.45;
    cursor: not-allowed;
    pointer-events: none;
    filter: grayscale(0.4);
}

.gs-options {
    background: var(--surface-1);
    border: 1px solid var(--ink-muted);
    border-radius: var(--r-lg);
    padding: 32px;
    display: flex;
    flex-direction: column;
    gap: 28px;
    margin-bottom: 40px;
    animation: fadeInUp 0.4s var(--ease-out-expo) both;
}

.gs-head {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.gs-head h2 {
    color: var(--chalk);
}

.gs-head p {
    color: var(--chalk-dim);
    font-size: 14px;
}

.gs-name-row {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.gq-option-label {
    margin-top: 0;
    font-size: 14px;
    font-weight: 700;
    color: var(--chalk-dim);
    text-transform: uppercase;
    letter-spacing: 0.08em;
}

.gs-hint {
    font-size: 12px;
    color: var(--chalk-ghost);
    font-style: italic;
}

.gs-subtabs {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    justify-content: center;
}

.gs-choice {
    flex: 1;
    min-width: 120px;
    max-width: 220px;
    display: flex;
    position: relative;
    cursor: pointer;
}

.gs-choice input {
    position: absolute;
    opacity: 0;
    width: 1px;
    height: 1px;
    pointer-events: none;
}

.gs-subtab {
    flex: 1;
    display: inline-flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 4px;
    padding: 11px 18px;
    border-radius: 100px;
    border: 1.5px solid var(--ink-muted);
    background: var(--ink-soft);
    color: var(--chalk-dim);
    font-family: 'DM Sans', sans-serif;
    font-size: 14px;
    font-weight: 700;
    cursor: pointer;
    transition: all .2s var(--ease-spring);
}

.gs-choice .gs-subtab {
    border-radius: var(--r-md);
    padding: 14px 16px;
    min-height: 52px;
}

.gs-subtab:hover {
    border-color: var(--chalk-ghost);
    color: var(--chalk);
}

.gs-choice input:checked+.gs-subtab {
    border-color: var(--neon-guess);
    background: rgba(56, 212, 245, .12);
    color: var(--neon-guess);
    box-shadow: 0 0 14px rgba(56, 212, 245, .15);
}

.gs-choice input:focus-visible+.gs-subtab {
    outline: 2px solid var(--neon-guess);
    outline-offset: 2px;
}

.gs-choice input:disabled+.gs-subtab {
    opacity: .6;
    cursor: not-allowed;
}

.gs-choice-desc {
    font-size: 12px;
    font-weight: 400;
    color: var(--chalk-dim);
}

.gs-choice input:disabled+.gs-subtab .gs-choice-desc,

.gs-range {
    display: flex;
    align-items: center;
    gap: 16px;
    width: 100%;
    max-width: 520px;
    margin: 0 auto;
}

.gs-slider {
    flex: 1;
    height: 8px;
    padding: 0;
    border: none;
    border-radius: 100px;
    background: var(--ink-muted);
    outline: none;
    -webkit-appearance: none;
    appearance: none;
    cursor: pointer;
}

.gs-slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: var(--neon-guess);
    border: 3px solid var(--ink);
    box-shadow: 0 0 0 1.5px var(--neon-guess), var(--glow-guess);
    cursor: pointer;
    transition: transform .2s var(--ease-spring);
}

.gs-slider::-moz-range-thumb {
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: var(--neon-guess);
    border: 3px solid var(--ink);
    box-shadow: 0 0 0 1.5px var(--neon-guess), var(--glow-guess);
    cursor: pointer;
}

.gs-slider::-moz-range-track {
    height: 8px;
    border-radius: 100px;
    background: var(--ink-muted);
}

.gs-slider::-webkit-slider-thumb:hover {
    transform: scale(1.15);
}

.gs-slider:focus-visible {
    outline: 2px solid var(--neon-guess);
    outline-offset: 6px;
}

.gs-range-value {
    min-width: 64px;
    padding: 6px 14px;
    border-radius: 100px;
    border: 1.5px solid var(--neon-guess);
    background: rgba(56, 212, 245, .12);
    color: var(--neon-guess);
    font-weight: 700;
    font-size: 15px;
    text-align: center;
}

.gs-preview {
    background: var(--ink-soft);
    border: 1px solid var(--ink-muted);
    border-radius: var(--r-md);
    padding: 24px 28px;
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.gs-preview h3 {
    color: var(--chalk);
    font-size: 1.3rem;
}

.preview-grid {
    --cols: 10;
    --bw: 30px;
    --bh: 15px;
    display: grid;
    grid-template-columns: repeat(var(--cols), var(--bw));
    gap: 4px;
    justify-content: center;
    padding: 15px;
    background: var(--ink);
    border: 1.5px dashed var(--ink-muted);
    border-radius: var(--r-sm);
    overflow-x: auto;
}

.preview-brick {
    width: var(--bw);
    height: var(--bh);
    border-radius: 3px;
    transition: background 0.3s ease;
}

.preview-brick.lives-1 {
    background: #ff9696;
}

.preview-brick.lives-2 {
    background: #ffe273;
}

.preview-brick.lives-3 {
    background: #96e2c4;
}

.preview-brick.lives-4 {
    background: #86d0f4;
}

.preview-brick.lives-5 {
    background: #b9a6f5;
}

.preview-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 12px;
}

.stat-preview {
    padding: 10px 12px;
    background: var(--ink-mid);
    border: 1px solid var(--ink-muted);
    border-radius: var(--r-sm);
    text-align: center;
    color: var(--chalk-dim);
    font-size: 13px;
}

.stat-preview strong {
    color: var(--neon-guess);
    font-size: 18px;
}

.gs-start-btn {
    align-self: center;
    padding: 14px 40px;
    font-size: 15px;
    gap: 10px;
    margin-top: 12px;
    background: var(--neon-draw);
    box-shadow: 0 6px 20px rgba(200, 245, 58, 0.3), var(--glow-draw);
    color: var(--ink);
    font-weight: 700;
}

.menu-footer {
    padding: 0 0 40px;
    text-align: center;
    color: var(--chalk-dim);
    font-size: 14px;
}

@media (max-width: 640px) {
    .gs-menu {
        padding: 20px;
    }

    .gs-options {
        padding: 24px;
        gap: 20px;
    }

    .header {
        padding: 48px 0 28px;
    }

    .gs-preview {
        padding: 20px;
    }

    .gs-choice {
        min-width: calc(50% - 5px);
        max-width: none;
    }
}

@media (max-aspect-ratio: 1/1) {
    .preview-grid {
        --bw: 13px;
        --bh: 8px;
    }
}

@media (prefers-reduced-motion: reduce) {

    .blob-1,
    .blob-2,
    .blob-3,
    .logo-icon {
        animation: none;
    }
}
