:root {
    --bg-top: #06233d;
    --bg-bottom: #04111d;
    --surface: rgba(7, 31, 53, 0.82);
    --surface-strong: #0b2e4d;
    --surface-soft: rgba(13, 46, 74, 0.72);
    --text: #edf7ff;
    --muted: #b2d3ea;
    --accent: #ffd166;
    --accent-strong: #ff9f1c;
    --line: rgba(186, 225, 255, 0.18);
    --shadow: 0 20px 60px rgba(0, 0, 0, 0.28);
    --radius-xl: 28px;
    --radius-lg: 20px;
    --radius-md: 14px;
    --max-width: 1180px;
    --nav-height: 88px;
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    color: var(--text);
    font-family: "Avenir Next", "Segoe UI", "PingFang SC", "Hiragino Sans GB", sans-serif;
    background:
        radial-gradient(circle at top, rgba(38, 145, 207, 0.28), transparent 30%),
        linear-gradient(180deg, var(--bg-top), var(--bg-bottom) 55%, #020912 100%);
    min-height: 100vh;
}

body::before {
    content: "";
    position: fixed;
    inset: 0;
    pointer-events: none;
    background:
        linear-gradient(120deg, rgba(255, 255, 255, 0.05), transparent 24%),
        radial-gradient(circle at 10% 20%, rgba(255, 209, 102, 0.08), transparent 18%),
        radial-gradient(circle at 80% 10%, rgba(0, 180, 216, 0.10), transparent 22%);
}

a {
    color: inherit;
}

.site-header {
    position: sticky;
    top: 0;
    z-index: 20;
    backdrop-filter: blur(14px);
    background: rgba(4, 17, 29, 0.74);
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.nav-inner,
.footer-inner,
.page-shell {
    width: min(calc(100% - 32px), var(--max-width));
    margin: 0 auto;
}

.nav-inner {
    min-height: var(--nav-height);
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    padding: 18px 0;
}

.brand {
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 14px;
    min-width: 0;
}

.brand-mark {
    width: 44px;
    height: 44px;
    border-radius: 14px;
    background: linear-gradient(135deg, var(--accent), var(--accent-strong));
    color: #08233a;
    display: grid;
    place-items: center;
    font-weight: 800;
    box-shadow: 0 10px 24px rgba(255, 159, 28, 0.25);
}

.brand-copy strong,
.brand-copy span {
    display: block;
}

.brand-copy strong {
    font-size: 1rem;
}

.brand-copy span {
    color: var(--muted);
    font-size: 0.86rem;
}

.nav-toggle {
    display: none;
    border: 1px solid var(--line);
    background: rgba(255, 255, 255, 0.04);
    color: var(--text);
    border-radius: 12px;
    padding: 10px 14px;
    font: inherit;
}

.site-nav {
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-end;
    gap: 10px;
}

.site-nav a {
    text-decoration: none;
    padding: 10px 14px;
    border-radius: 999px;
    color: var(--muted);
    transition: background-color 0.2s ease, color 0.2s ease, transform 0.2s ease;
}

.site-nav a:hover,
.site-nav a:focus-visible,
.site-nav a.is-active {
    color: var(--text);
    background: rgba(255, 255, 255, 0.08);
    transform: translateY(-1px);
}

.page-shell {
    padding: 48px 0 72px;
}

.page-shell-game {
    padding-top: 40px;
}

.hero,
.page-intro {
    display: grid;
    gap: 24px;
}

.hero {
    grid-template-columns: 1.3fr 0.9fr;
    align-items: center;
    padding: 36px 0 20px;
}

.hero-copy,
.hero-card,
.panel,
.mini-card {
    position: relative;
    z-index: 1;
}

.hero-copy h1,
.page-intro h1 {
    font-size: clamp(2.3rem, 5vw, 4.6rem);
    line-height: 0.94;
    margin: 0 0 14px;
    letter-spacing: -0.04em;
}

.eyebrow {
    margin: 0 0 12px;
    color: var(--accent);
    text-transform: uppercase;
    letter-spacing: 0.18em;
    font-size: 0.82rem;
    font-weight: 700;
}

.lead {
    max-width: 760px;
    font-size: 1.05rem;
    color: var(--muted);
    line-height: 1.8;
}

.hero-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 14px;
    margin-top: 28px;
}

.button {
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 48px;
    padding: 0 20px;
    border-radius: 999px;
    font-weight: 700;
}

.button-primary {
    background: linear-gradient(135deg, var(--accent), var(--accent-strong));
    color: #09253c;
    box-shadow: 0 18px 30px rgba(255, 159, 28, 0.2);
}

.button-secondary {
    border: 1px solid var(--line);
    background: rgba(255, 255, 255, 0.04);
}

.hero-card,
.panel,
.mini-card {
    background: linear-gradient(180deg, rgba(14, 52, 82, 0.88), rgba(7, 31, 53, 0.9));
    border: 1px solid var(--line);
    border-radius: var(--radius-xl);
    box-shadow: var(--shadow);
}

.hero-card,
.panel {
    padding: 28px;
}

.panel + .panel,
.panel + .ad-slot,
.ad-slot + .panel {
    margin-top: 28px;
}

.content-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 24px;
    margin-top: 16px;
}

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

.card-row-tight {
    grid-template-columns: repeat(3, minmax(0, 1fr));
}

.feature-list,
.faq-list,
.legal-copy h2,
.legal-copy p {
    margin: 0;
}

.feature-list {
    padding-left: 20px;
    color: var(--muted);
    line-height: 1.8;
}

.panel h2,
.hero-card h2,
.mini-card h3,
.faq-item h3 {
    margin-top: 0;
}

.panel p,
.mini-card p,
.faq-item p,
.legal-copy p {
    color: var(--muted);
    line-height: 1.8;
}

.mini-card {
    padding: 20px;
    border-radius: var(--radius-lg);
    background: linear-gradient(180deg, rgba(10, 41, 66, 0.95), rgba(6, 25, 42, 0.95));
}

.game-stage-panel h2 {
    margin-bottom: 20px;
}

.game-frame {
    padding: 18px;
    border-radius: 24px;
    background: rgba(0, 0, 0, 0.22);
    border: 1px solid rgba(255, 255, 255, 0.08);
}

.game-container {
    width: 100%;
    height: min(70vw, 72vh);
    min-height: 340px;
    max-height: 760px;
    aspect-ratio: 16 / 9;
    border-radius: 20px;
    overflow: hidden;
    background:
        radial-gradient(circle at top, rgba(79, 195, 247, 0.28), transparent 32%),
        #020812;
    box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.08);
}

.game-container canvas {
    display: block;
    width: 100%;
    height: 100%;
}

.ad-slot {
    margin-top: 28px;
}

.ad-slot-spaced {
    margin-top: 170px;
}

.ad-label {
    margin: 0 0 12px;
    color: var(--muted);
    font-size: 0.8rem;
    letter-spacing: 0.12em;
    text-transform: uppercase;
}

.ad-box {
    min-height: 130px;
    display: grid;
    place-items: center;
    padding: 22px;
    text-align: center;
    color: var(--muted);
    border: 1px dashed rgba(255, 209, 102, 0.4);
    border-radius: var(--radius-lg);
    background: rgba(255, 209, 102, 0.06);
}

.faq-list {
    display: grid;
    gap: 18px;
}

.faq-item {
    padding: 20px;
    border-radius: var(--radius-lg);
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.legal-copy h2 {
    margin-bottom: 10px;
    margin-top: 28px;
}

.legal-copy h2:first-child {
    margin-top: 0;
}

.license-block {
    white-space: pre-wrap;
    word-break: break-word;
    margin: 0;
    padding: 20px;
    border-radius: 18px;
    background: rgba(0, 0, 0, 0.22);
    border: 1px solid rgba(255, 255, 255, 0.08);
    color: var(--muted);
    font-family: "SFMono-Regular", "Consolas", monospace;
    line-height: 1.7;
}

.site-footer {
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    background: rgba(1, 8, 14, 0.6);
}

.footer-inner {
    display: grid;
    gap: 16px;
    padding: 30px 0 48px;
}

.footer-links {
    display: flex;
    flex-wrap: wrap;
    gap: 12px 18px;
}

.footer-links a {
    color: var(--muted);
    text-decoration: none;
}

.footer-note,
.footer-meta {
    color: var(--muted);
    line-height: 1.8;
}

@media (max-width: 980px) {
    .hero,
    .content-grid,
    .card-row,
    .card-row-tight {
        grid-template-columns: 1fr;
    }

    .hero {
        padding-top: 16px;
    }

    .game-container {
        height: min(74vw, 62vh);
    }
}

@media (max-width: 760px) {
    :root {
        --nav-height: 72px;
    }

    .nav-inner {
        align-items: flex-start;
        flex-direction: column;
    }

    .nav-toggle {
        display: inline-flex;
        align-self: flex-end;
        margin-top: -52px;
    }

    .site-nav {
        display: none;
        width: 100%;
        flex-direction: column;
        align-items: stretch;
        padding-top: 14px;
    }

    .site-nav.is-open {
        display: flex;
    }

    .site-nav a {
        border-radius: 14px;
    }

    .page-shell {
        width: min(calc(100% - 24px), var(--max-width));
        padding-top: 28px;
    }

    .hero-copy h1,
    .page-intro h1 {
        font-size: 2.3rem;
    }

    .hero-card,
    .panel {
        padding: 22px;
        border-radius: 22px;
    }

    .game-frame {
        padding: 12px;
    }

    .game-container {
        min-height: 240px;
        height: min(78vw, 52vh);
    }

    .ad-slot-spaced {
        margin-top: 150px;
    }
}
