/* ww2battleforces.com. Colours and fonts follow the game's UITheme.gd: dark olive ground,
   cream text, gold and brass accents, Black Ops One for titles, Barlow Condensed for labels. */

/* === Fonts === */
@font-face {
    font-family: "Black Ops One";
    src: url("/fonts/black-ops-one-latin.woff") format("woff");
    font-weight: 400;
    font-display: swap;
}

@font-face {
    font-family: "Barlow Condensed";
    src: url("/fonts/barlow-condensed-600-latin.woff") format("woff");
    font-weight: 600;
    font-display: swap;
}

/* === Tokens === */
:root {
    color-scheme: dark;

    --bg: #1a1c16;
    --bg-deep: #12140e;
    --card: #23271d;
    --card-2: #2b3024;
    --edge: #b7b39a;
    --edge-dim: #4a4f44;
    --text: #f2ecd8;
    --muted: #cfc7a6;
    --dim: #8d8b7a;
    --gold: #f0c060;
    --brass: #d9a441;

    --font-stencil: "Black Ops One", Impact, "Arial Black", sans-serif;
    --font-cond: "Barlow Condensed", "Arial Narrow", "Roboto Condensed", sans-serif;
    --font-body: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;

    --wrap: 1120px;
    --gutter: 20px;
    --radius: 6px;
    --header-h: 60px;
}

/* === Base === */
*, *::before, *::after { box-sizing: border-box; }

html {
    scroll-behavior: smooth;
    scroll-padding-top: calc(var(--header-h) + 12px);
    -webkit-text-size-adjust: 100%;
}

body {
    margin: 0;
    background: var(--bg);
    color: var(--text);
    font-family: var(--font-body);
    font-size: 17px;
    line-height: 1.6;
    overflow-x: hidden;
}

img { max-width: 100%; height: auto; display: block; }

a { color: var(--gold); text-underline-offset: 3px; }
a:hover { color: var(--text); }

:focus-visible { outline: 2px solid var(--gold); outline-offset: 3px; }

h1, h2, h3 { margin: 0; font-weight: 400; line-height: 1.05; }

h2 {
    font-family: var(--font-stencil);
    font-size: clamp(30px, 5vw, 46px);
    letter-spacing: 0.01em;
    color: var(--text);
}

h3 {
    font-family: var(--font-stencil);
    font-size: clamp(22px, 3vw, 28px);
    color: var(--text);
}

p { margin: 0 0 1em; }

.wrap {
    width: 100%;
    max-width: var(--wrap);
    margin: 0 auto;
    padding: 0 var(--gutter);
}

.narrow { max-width: 760px; }

.eyebrow {
    font-family: var(--font-cond);
    font-weight: 600;
    font-size: 15px;
    letter-spacing: 0.22em;
    text-transform: uppercase;
    color: var(--gold);
    margin: 0 0 10px;
}

.lead {
    font-family: var(--font-cond);
    font-weight: 600;
    font-size: clamp(19px, 2.4vw, 22px);
    line-height: 1.35;
    color: var(--muted);
}

.gold-rule {
    width: 100%;
    max-width: 330px;
    height: 3px;
    margin: 18px 0 20px;
    border: 0;
    background: var(--brass);
}

.visually-hidden {
    position: absolute;
    width: 1px;
    height: 1px;
    margin: -1px;
    padding: 0;
    overflow: hidden;
    clip: rect(0 0 0 0);
    white-space: nowrap;
    border: 0;
}

.skip-link {
    position: absolute;
    left: -9999px;
    top: 0;
    z-index: 100;
    padding: 8px 14px;
    background: var(--gold);
    color: var(--bg-deep);
}
.skip-link:focus { left: 8px; top: 8px; }

/* === Buttons === */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    min-height: 48px;
    padding: 10px 24px;
    border: 2px solid var(--brass);
    border-radius: var(--radius);
    font-family: var(--font-cond);
    font-weight: 600;
    font-size: 19px;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    text-decoration: none;
    white-space: nowrap;
    cursor: pointer;
    transition: background-color 0.15s, color 0.15s, border-color 0.15s;
}

.btn-gold { background: var(--gold); border-color: var(--gold); color: var(--bg-deep); }
.btn-gold:hover { background: var(--text); border-color: var(--text); color: var(--bg-deep); }

.btn-ghost { background: rgba(18, 20, 14, 0.55); color: var(--text); border-color: var(--edge); }
.btn-ghost:hover { background: var(--text); color: var(--bg-deep); border-color: var(--text); }

.btn-small { min-height: 38px; padding: 6px 16px; font-size: 16px; }

/* === Header === */
.site-header {
    position: sticky;
    top: 0;
    z-index: 50;
    height: var(--header-h);
    background: rgba(18, 20, 14, 0.92);
    -webkit-backdrop-filter: blur(8px);
    backdrop-filter: blur(8px);
    border-bottom: 1px solid var(--edge-dim);
}

.header-inner {
    height: 100%;
    display: flex;
    align-items: center;
    gap: 24px;
}

.brand {
    display: inline-flex;
    align-items: baseline;
    gap: 8px;
    font-family: var(--font-stencil);
    font-size: 21px;
    color: var(--text);
    text-decoration: none;
    white-space: nowrap;
}
.brand:hover { color: var(--text); }
.brand-ww2 { color: var(--gold); font-size: 0.8em; letter-spacing: 0.12em; }

.nav-links {
    display: flex;
    gap: 22px;
    margin-left: auto;
}

.nav-links a {
    font-family: var(--font-cond);
    font-weight: 600;
    font-size: 17px;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--muted);
    text-decoration: none;
}
.nav-links a:hover, .nav-links a[aria-current="page"] { color: var(--gold); }

.header-cta { margin-left: 4px; gap: 0.32em; }

/* === Hero === */
.hero {
    position: relative;
    display: flex;
    align-items: center;
    min-height: clamp(560px, 88vh, 820px);
    overflow: hidden;
    background: var(--bg-deep);
}

.hero-art img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: 72% 40%;
}

.hero::after {
    content: "";
    position: absolute;
    inset: 0;
    background:
        linear-gradient(90deg, rgba(18, 20, 14, 0.82) 0%, rgba(18, 20, 14, 0.45) 42%, rgba(18, 20, 14, 0) 66%),
        linear-gradient(0deg, var(--bg) 0%, rgba(26, 28, 22, 0) 22%);
    pointer-events: none;
}

.hero-copy {
    position: relative;
    z-index: 1;
    padding-top: 48px;
    padding-bottom: 72px;
}

.hero-copy > * { max-width: 560px; }

.logo-type { font-family: var(--font-stencil); color: var(--text); }

.logo-ww2 {
    display: block;
    font-size: clamp(22px, 3vw, 30px);
    letter-spacing: 0.5em;
    color: var(--gold);
    margin-bottom: 6px;
}

.logo-main {
    display: block;
    font-size: clamp(64px, 10vw, 118px);
    line-height: 0.92;
    letter-spacing: 0.02em;
    text-transform: uppercase;
    text-shadow: 0 4px 18px rgba(0, 0, 0, 0.45);
}

.hero-tag {
    font-family: var(--font-cond);
    font-weight: 600;
    font-size: clamp(23px, 3vw, 30px);
    line-height: 1.2;
    color: var(--text);
    margin-bottom: 12px;
}

.hero-sub { color: var(--muted); font-size: 18px; }

.hero-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin: 26px 0 18px;
}

.hero-note {
    font-family: var(--font-cond);
    font-weight: 600;
    font-size: 16px;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: var(--dim);
}

/* === Stats strip === */
.stats {
    background: var(--bg-deep);
    border-top: 1px solid var(--edge-dim);
    border-bottom: 1px solid var(--edge-dim);
}

.stats ul {
    list-style: none;
    margin: 0 auto;
    padding: 26px var(--gutter);
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 16px;
    text-align: center;
}

.stat-num {
    display: block;
    font-family: var(--font-stencil);
    font-size: clamp(30px, 4.5vw, 44px);
    color: var(--gold);
    line-height: 1.1;
}

.stat-label {
    font-family: var(--font-cond);
    font-weight: 600;
    font-size: 16px;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--muted);
}

/* === Sections === */
.section { padding: clamp(64px, 9vw, 110px) 0; }
.section-alt { background: var(--bg-deep); }
.section-head { margin-bottom: clamp(28px, 4vw, 44px); }
.section-head p:last-child { margin-bottom: 0; }
.section-head .lead { margin-top: 14px; }
.center { text-align: center; }
.center .gold-rule { margin-left: auto; margin-right: auto; }

/* === Trailer === */
.video-frame {
    position: relative;
    aspect-ratio: 16 / 9;
    border: 1px solid var(--brass);
    border-radius: var(--radius);
    overflow: hidden;
    background: #000;
}

.video-frame img,
.video-frame iframe {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    border: 0;
    object-fit: cover;
}

.video-frame::after {
    content: "";
    position: absolute;
    inset: 0;
    background: rgba(18, 20, 14, 0.35);
    pointer-events: none;
}
.video-frame.is-playing::after { display: none; }

.video-play {
    position: absolute;
    inset: 0;
    z-index: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 12px;
    width: 100%;
    border: 0;
    background: transparent;
    color: var(--text);
    cursor: pointer;
    font-family: var(--font-cond);
    font-weight: 600;
    font-size: 18px;
    letter-spacing: 0.14em;
    text-transform: uppercase;
}

.video-play-icon {
    width: 84px;
    height: 84px;
    border-radius: 50%;
    background: var(--gold);
    display: grid;
    place-items: center;
    box-shadow: 0 6px 24px rgba(0, 0, 0, 0.5);
    transition: transform 0.15s;
}
.video-play-icon::before {
    content: "";
    margin-left: 6px;
    border-style: solid;
    border-width: 15px 0 15px 25px;
    border-color: transparent transparent transparent var(--bg-deep);
}
.video-play:hover .video-play-icon { transform: scale(1.06); }
.video-play[disabled] { cursor: default; }
.video-play[disabled] .video-play-icon { display: none; }

.video-soon {
    padding: 8px 18px;
    background: rgba(18, 20, 14, 0.85);
    border: 1px solid var(--edge-dim);
    border-radius: 999px;
}

/* === Features === */
.feature {
    display: grid;
    grid-template-columns: 7fr 5fr;
    align-items: center;
    gap: clamp(28px, 5vw, 64px);
}
.feature + .feature { margin-top: clamp(56px, 8vw, 96px); }
.feature-flip .feature-shot { order: 2; }

.shot {
    border: 1px solid var(--brass);
    border-radius: var(--radius);
    overflow: hidden;
    background: var(--bg-deep);
    box-shadow: 0 14px 40px rgba(0, 0, 0, 0.4);
}

.feature-copy h3 { margin-bottom: 14px; }
.feature-copy p { color: var(--muted); }
.feature-copy p:last-child { margin-bottom: 0; }

.feature-num {
    font-family: var(--font-stencil);
    color: var(--brass);
    font-size: 20px;
    margin-bottom: 8px;
}

/* === Roster cards === */
.roster-grid {
    list-style: none;
    margin: 0;
    padding: 0;
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 18px;
}

.unit-card {
    height: 100%;
    background: var(--card);
    border: 1px solid var(--edge-dim);
    border-radius: var(--radius);
    overflow: hidden;
}

.unit-card img { width: 100%; aspect-ratio: 1; object-fit: cover; }

.unit-card-body { padding: 12px 14px 16px; }

.unit-name {
    font-family: var(--font-stencil);
    font-size: 20px;
    line-height: 1.15;
    color: var(--text);
    margin: 0 0 2px;
}

.unit-meta {
    font-family: var(--font-cond);
    font-weight: 600;
    font-size: 14px;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--gold);
    margin: 0 0 8px;
}

.unit-desc { font-size: 15px; line-height: 1.45; color: var(--muted); margin: 0; }

.roster-more {
    margin-top: 26px;
    text-align: center;
    font-family: var(--font-cond);
    font-weight: 600;
    font-size: 19px;
    color: var(--muted);
}

/* === Battle note === */
.battle-note {
    position: relative;
    margin: 0;
    padding: clamp(26px, 4vw, 40px) clamp(24px, 5vw, 56px);
    background: #e9e1c6;
    color: #2b2a22;
    border-radius: 4px;
    box-shadow: 0 14px 40px rgba(0, 0, 0, 0.45);
}

.battle-note-label {
    font-family: var(--font-cond);
    font-weight: 600;
    font-size: 15px;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    color: #8a3a2c;
    margin-bottom: 10px;
}

.battle-note blockquote {
    margin: 0;
    font-family: Georgia, "Times New Roman", serif;
    font-size: clamp(20px, 2.6vw, 26px);
    line-height: 1.45;
}

.battle-note figcaption {
    margin-top: 16px;
    font-family: var(--font-cond);
    font-weight: 600;
    font-size: 17px;
    color: #5a574a;
}

/* === Gallery === */
.gallery {
    list-style: none;
    margin: 0;
    padding: 0;
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 14px;
}

.gallery button {
    display: block;
    width: 100%;
    padding: 0;
    border: 1px solid var(--edge-dim);
    border-radius: var(--radius);
    overflow: hidden;
    background: var(--bg-deep);
    cursor: zoom-in;
    transition: border-color 0.15s, transform 0.15s;
}
.gallery button:hover { border-color: var(--gold); transform: translateY(-2px); }
.gallery img { width: 100%; aspect-ratio: 16 / 9; object-fit: cover; }

.lightbox {
    width: min(1280px, 96vw);
    max-width: none;
    padding: 0;
    border: 1px solid var(--brass);
    border-radius: var(--radius);
    background: var(--bg-deep);
    color: var(--text);
}
.lightbox::backdrop { background: rgba(8, 9, 6, 0.88); }
.lightbox img { width: 100%; aspect-ratio: 16 / 9; object-fit: contain; background: #000; }

.lightbox-bar {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 12px;
}

.lightbox-caption {
    flex: 1;
    margin: 0;
    font-family: var(--font-cond);
    font-weight: 600;
    font-size: 18px;
    color: var(--muted);
}

.lightbox-bar button {
    min-width: 44px;
    min-height: 44px;
    border: 1px solid var(--edge-dim);
    border-radius: var(--radius);
    background: var(--card-2);
    color: var(--text);
    font-size: 20px;
    cursor: pointer;
}
.lightbox-bar button:hover { border-color: var(--gold); color: var(--gold); }

/* === Respect statement === */
.respect p { color: var(--muted); }
.respect .lead { color: var(--text); }

/* === Waitlist === */
.waitlist {
    background:
        linear-gradient(0deg, rgba(18, 20, 14, 0.94), rgba(18, 20, 14, 0.94)),
        url("/images/hero-1280.jpg") center 40% / cover no-repeat;
    border-top: 1px solid var(--edge-dim);
}

.form-embed {
    margin-top: 28px;
    border: 1px solid var(--brass);
    border-radius: var(--radius);
    overflow: hidden;
    background: var(--card);
}

.form-embed iframe {
    display: block;
    width: 100%;
    height: 980px;
    border: 0;
    background: #fff;
}

.form-pending {
    margin: 0;
    padding: 40px 24px;
    text-align: center;
    font-family: var(--font-cond);
    font-weight: 600;
    font-size: 20px;
    color: var(--muted);
}

.store-links {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 12px;
    margin-top: 24px;
}
.store-links[hidden] { display: none; }
.store-links .btn { white-space: normal; text-align: center; }

.fineprint {
    margin-top: 18px;
    font-size: 14px;
    color: var(--dim);
}

/* === Page (FAQ, press, support, privacy) === */
.page-head {
    padding: clamp(48px, 7vw, 80px) 0 clamp(28px, 4vw, 40px);
    border-bottom: 1px solid var(--edge-dim);
    background: var(--bg-deep);
}
.page-head h1 {
    font-family: var(--font-stencil);
    font-size: clamp(38px, 6vw, 60px);
}
.page-head .lead { margin: 14px 0 0; }

.prose { padding-top: clamp(36px, 5vw, 56px); padding-bottom: clamp(64px, 8vw, 96px); }
.prose .gallery { padding: 0; margin-bottom: 1em; }
.prose h2 { font-size: clamp(26px, 3.6vw, 34px); margin: 44px 0 14px; }
.prose h2:first-child { margin-top: 0; }
.prose h3 { font-size: 22px; margin: 30px 0 10px; }
.prose p, .prose li { color: var(--muted); }
.prose strong { color: var(--text); font-weight: 600; }
.prose ul { padding-left: 1.2em; margin: 0 0 1em; }
.prose li { margin-bottom: 6px; }
.prose .updated { font-size: 15px; color: var(--dim); }

.faq-item {
    border-bottom: 1px solid var(--edge-dim);
}
.faq-item summary {
    list-style: none;
    display: flex;
    justify-content: space-between;
    gap: 16px;
    padding: 18px 0;
    cursor: pointer;
    font-family: var(--font-cond);
    font-weight: 600;
    font-size: 22px;
    line-height: 1.25;
    color: var(--text);
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::after {
    content: "+";
    flex: none;
    font-family: var(--font-stencil);
    color: var(--gold);
}
.faq-item[open] summary::after { content: "\2013"; }
.faq-item summary:hover { color: var(--gold); }
.faq-answer { padding-bottom: 18px; }
.faq-answer p:last-child { margin-bottom: 0; }

.fact-sheet {
    display: grid;
    grid-template-columns: max-content 1fr;
    gap: 10px 28px;
    margin: 0 0 8px;
    padding: 22px 24px;
    background: var(--card);
    border: 1px solid var(--edge-dim);
    border-radius: var(--radius);
}
.fact-sheet dt {
    font-family: var(--font-cond);
    font-weight: 600;
    font-size: 16px;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--gold);
    padding-top: 2px;
}
.fact-sheet dd { margin: 0; color: var(--text); }

.download-list {
    list-style: none;
    padding: 0 !important;
    display: grid;
    gap: 10px;
}
.download-list a {
    display: flex;
    justify-content: space-between;
    gap: 16px;
    padding: 14px 18px;
    background: var(--card);
    border: 1px solid var(--edge-dim);
    border-radius: var(--radius);
    color: var(--text);
    text-decoration: none;
    font-family: var(--font-cond);
    font-weight: 600;
    font-size: 19px;
}
.download-list a:hover { border-color: var(--gold); color: var(--gold); }
.download-list span { color: var(--dim); font-size: 16px; white-space: nowrap; }

.contact-card {
    margin: 8px 0 24px;
    padding: 24px;
    background: var(--card);
    border: 1px solid var(--brass);
    border-radius: var(--radius);
}
.contact-card p:last-child { margin-bottom: 0; }
.contact-email {
    font-family: var(--font-cond);
    font-weight: 600;
    font-size: clamp(22px, 4vw, 28px);
    word-break: break-word;
}

/* === Footer === */
.site-footer {
    padding: 40px 0 48px;
    background: var(--bg-deep);
    border-top: 1px solid var(--edge-dim);
}

.footer-inner {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 18px 32px;
}

.footer-links {
    display: flex;
    flex-wrap: wrap;
    gap: 8px 22px;
}
.footer-links a {
    font-family: var(--font-cond);
    font-weight: 600;
    font-size: 17px;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--muted);
    text-decoration: none;
}
.footer-links a:hover { color: var(--gold); }

.footer-small {
    flex-basis: 100%;
    margin: 6px 0 0;
    font-size: 14px;
    color: var(--dim);
}
.footer-small a { color: var(--muted); }

/* === 404 === */
.not-found {
    min-height: 60vh;
    display: flex;
    align-items: center;
    padding: 64px 0;
}

/* === Responsive Design === */
@media (max-width: 960px) {
    .roster-grid { grid-template-columns: repeat(2, 1fr); }
    .gallery { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 860px) {
    .nav-links { display: none; }
    .header-cta { margin-left: auto; }

    .feature { grid-template-columns: 1fr; }
    .feature-flip .feature-shot { order: 0; }
}

@media (max-width: 720px) {
    :root { --gutter: 16px; --header-h: 56px; }
    body { font-size: 16px; }

    .brand { font-size: 18px; }

    .hero {
        display: block;
        min-height: 0;
    }
    .hero-art { position: relative; display: block; aspect-ratio: 5 / 4; }
    .hero-art img { object-position: 96% 35%; }
    .hero::after { display: none; }
    .hero-art::after {
        content: "";
        position: absolute;
        inset: 0;
        background: linear-gradient(0deg, var(--bg-deep) 2%, rgba(18, 20, 14, 0.2) 45%, rgba(18, 20, 14, 0) 70%);
    }
    .hero-copy { margin-top: -96px; padding-top: 0; padding-bottom: 48px; }
    .hero-actions .btn { flex: 1 1 100%; }

    .stats ul { grid-template-columns: repeat(2, 1fr); gap: 22px 12px; }

    .roster-grid { gap: 12px; }
    .unit-card-body { padding: 10px 10px 14px; }
    .unit-name { font-size: 17px; }
    .unit-desc { font-size: 14px; }

    .gallery { gap: 10px; }

    .fact-sheet { grid-template-columns: 1fr; gap: 2px; }
    .fact-sheet dd { margin-bottom: 12px; }
    .fact-sheet dd:last-child { margin-bottom: 0; }

    .form-embed iframe { height: 1060px; }
}

@media (max-width: 520px) {
    .cta-long { display: none; }
}

@media (max-width: 340px) {
    .header-cta { padding: 6px 12px; font-size: 15px; }
    .brand { font-size: 16px; }
}

@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }
    * { transition: none !important; }
}
