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

:root {
    --color-bg: #0e0e0e;
    --color-bg-elevated: #161616;
    --color-bg-card: #1a1a1a;
    --color-bg-card-hover: #222;
    --color-bg-dark: #0a0a0a;
    --color-border: #2a2a2a;
    --color-border-subtle: #1e1e1e;
    --color-text: #e8e5e0;
    --color-text-muted: #9a9a9a;
    --color-text-dim: #5a5a5a;
    --color-text-on-dark: #e8e5e0;
    --color-text-muted-on-dark: #9a9a9a;
    --color-accent: #b91c1c;
    --color-accent-hover: #dc2626;
    --color-accent-dim: #991b1b;
    --color-accent-glow: rgba(185, 28, 28, 0.15);
    --font-display: 'Cinzel', serif;
    --font-body: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    --container-max: 1140px;
    --section-padding: 6rem 0;
}

html {
    scroll-behavior: smooth;
    font-size: 16px;
}

body {
    font-family: var(--font-body);
    background-color: var(--color-bg);
    color: var(--color-text);
    line-height: 1.7;
    -webkit-font-smoothing: antialiased;
    overflow-x: hidden;
}

/* Film-grain overlay — unifies every section with a subtle analog texture */
body::after {
    content: '';
    position: fixed;
    inset: 0;
    pointer-events: none;
    z-index: 2000;
    opacity: 0.05;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='180' height='180'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

.container {
    max-width: var(--container-max);
    margin: 0 auto;
    padding: 0 2rem;
}

a {
    color: var(--color-accent);
    text-decoration: none;
    transition: color 0.2s;
}

a:hover {
    color: var(--color-accent-hover);
}

/* ── Navigation ── */

.nav {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 100;
    padding: 1rem 0;
    transition: background-color 0.3s, padding 0.3s, backdrop-filter 0.3s;
}

.nav.scrolled {
    background-color: rgba(14, 14, 14, 0.92);
    backdrop-filter: blur(12px);
    padding: 0.6rem 0;
    border-bottom: 1px solid var(--color-border-subtle);
}

.nav-inner {
    max-width: var(--container-max);
    margin: 0 auto;
    padding: 0 2rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.nav-logo {
    font-family: var(--font-display);
    font-size: 1.25rem;
    font-weight: 700;
    color: #fff;
    letter-spacing: 0.02em;
    display: inline-flex;
    align-items: center;
    gap: 0.55rem;
}

.nav-logo:hover {
    color: var(--color-accent);
}

.nav-mark {
    color: var(--color-accent);
    flex-shrink: 0;
}

.nav-links {
    display: flex;
    list-style: none;
    gap: 2rem;
    align-items: center;
}

.nav-links a {
    color: rgba(255, 255, 255, 0.7);
    font-size: 0.9rem;
    font-weight: 500;
    letter-spacing: 0.03em;
    text-transform: uppercase;
    transition: color 0.2s;
}

.nav-links a:hover {
    color: #fff;
}

.nav-cta {
    background: var(--color-accent);
    color: #fff !important;
    padding: 0.5rem 1.25rem;
    border-radius: 4px;
    font-weight: 600 !important;
    transition: background-color 0.2s, transform 0.2s !important;
}

.nav-cta:hover {
    background: var(--color-accent-hover);
    color: #fff !important;
    transform: translateY(-1px);
}

.nav-toggle {
    display: none;
    flex-direction: column;
    gap: 5px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 4px;
}

.nav-toggle span {
    display: block;
    width: 24px;
    height: 2px;
    background: rgba(255, 255, 255, 0.7);
    transition: transform 0.3s, opacity 0.3s;
}

/* ── Hero ── */

.hero {
    position: relative;
    min-height: 100vh;
    min-height: 100svh; /* mobile browsers: ignore the collapsing URL bar */
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    overflow: hidden;
}

.hero-bg {
    position: absolute;
    inset: 0;
    background:
        radial-gradient(ellipse 80% 60% at 50% 40%, rgba(185, 28, 28, 0.08) 0%, transparent 70%),
        radial-gradient(ellipse 60% 50% at 50% 100%, rgba(185, 28, 28, 0.05) 0%, transparent 60%),
        linear-gradient(180deg, #0a0a0a 0%, #111 100%);
}

.hero-bg::before {
    content: '';
    position: absolute;
    inset: 0;
    background-image:
        repeating-linear-gradient(
            0deg,
            transparent,
            transparent 50px,
            rgba(255, 255, 255, 0.015) 50px,
            rgba(255, 255, 255, 0.015) 51px
        ),
        repeating-linear-gradient(
            90deg,
            transparent,
            transparent 50px,
            rgba(255, 255, 255, 0.015) 50px,
            rgba(255, 255, 255, 0.015) 51px
        );
    mask-image: radial-gradient(ellipse 70% 50% at 50% 50%, black 20%, transparent 70%);
}

/* Torchlight flicker — an extra light layer that breathes */
.hero-bg::after {
    content: '';
    position: absolute;
    inset: 0;
    background: radial-gradient(ellipse 55% 42% at 50% 45%, rgba(220, 38, 38, 0.10) 0%, transparent 70%);
    animation: torch-flicker 4.5s ease-in-out infinite;
}

@keyframes torch-flicker {
    0%, 100% { opacity: 0.55; }
    12% { opacity: 0.9; }
    23% { opacity: 0.6; }
    38% { opacity: 1; }
    51% { opacity: 0.7; }
    66% { opacity: 0.95; }
    82% { opacity: 0.6; }
}

/* Rising embers */
.embers {
    position: absolute;
    inset: 0;
    overflow: hidden;
    pointer-events: none;
}

.embers span {
    position: absolute;
    bottom: -10px;
    width: 4px;
    height: 4px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(252, 165, 165, 0.9) 0%, rgba(185, 28, 28, 0.6) 55%, transparent 100%);
    opacity: 0;
    animation: ember-rise linear infinite;
}

@keyframes ember-rise {
    0%   { transform: translateY(0) translateX(0) scale(1); opacity: 0; }
    8%   { opacity: 0.55; }
    60%  { opacity: 0.45; }
    100% { transform: translateY(-92vh) translateX(var(--drift, 30px)) scale(0.35); opacity: 0; }
}

.embers span:nth-child(1)  { left: 6%;  animation-duration: 11s; animation-delay: 0s;    --drift: 44px; }
.embers span:nth-child(2)  { left: 16%; animation-duration: 14s; animation-delay: 3.2s;  --drift: -30px; width: 3px; height: 3px; }
.embers span:nth-child(3)  { left: 27%; animation-duration: 9s;  animation-delay: 1.4s;  --drift: 22px; }
.embers span:nth-child(4)  { left: 38%; animation-duration: 13s; animation-delay: 5.6s;  --drift: -48px; width: 5px; height: 5px; }
.embers span:nth-child(5)  { left: 49%; animation-duration: 10s; animation-delay: 2.1s;  --drift: 36px; width: 3px; height: 3px; }
.embers span:nth-child(6)  { left: 58%; animation-duration: 15s; animation-delay: 0.8s;  --drift: -20px; }
.embers span:nth-child(7)  { left: 68%; animation-duration: 12s; animation-delay: 4.4s;  --drift: 52px; width: 3px; height: 3px; }
.embers span:nth-child(8)  { left: 78%; animation-duration: 9.5s; animation-delay: 6.7s; --drift: -36px; }
.embers span:nth-child(9)  { left: 87%; animation-duration: 13.5s; animation-delay: 1.9s; --drift: 26px; width: 5px; height: 5px; }
.embers span:nth-child(10) { left: 94%; animation-duration: 11.5s; animation-delay: 3.8s; --drift: -42px; width: 3px; height: 3px; }

.hero-content {
    position: relative;
    z-index: 1;
    padding: 2rem;
}

.hero-tagline {
    font-family: var(--font-body);
    font-size: 0.85rem;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.25em;
    color: var(--color-text-muted-on-dark);
    margin-bottom: 1.5rem;
}

.hero-title {
    font-family: var(--font-display);
    line-height: 1.1;
    margin-bottom: 1rem;
}

.hero-title-the {
    display: block;
    font-size: clamp(1.2rem, 3vw, 1.8rem);
    font-weight: 400;
    color: var(--color-text-muted-on-dark);
    letter-spacing: 0.3em;
    margin-bottom: 0.25rem;
}

.hero-title-main {
    display: block;
    font-size: clamp(3rem, 8vw, 6rem);
    font-weight: 900;
    color: var(--color-accent);
    letter-spacing: 0.02em;
    text-shadow: 0 0 60px rgba(185, 28, 28, 0.3);
}

.hero-thesis {
    font-family: var(--font-display);
    font-size: clamp(1.05rem, 2.2vw, 1.35rem);
    font-weight: 400;
    color: var(--color-text-on-dark);
    letter-spacing: 0.02em;
    line-height: 1.6;
    max-width: 620px;
    margin: 0 auto 1.5rem;
}

.hero-description {
    font-size: 1.05rem;
    color: var(--color-text-muted-on-dark);
    max-width: 640px;
    margin: 0 auto 2.5rem;
    line-height: 1.85;
}

.hero-description em {
    color: var(--color-text-on-dark);
    font-style: italic;
}

.hero-actions {
    display: flex;
    gap: 1rem;
    justify-content: center;
    flex-wrap: wrap;
}

.hero .btn-secondary {
    color: var(--color-text-on-dark);
    border-color: rgba(255, 255, 255, 0.3);
}

.hero .btn-secondary:hover {
    border-color: var(--color-accent);
    color: var(--color-accent);
}

.hero-scroll-hint {
    position: absolute;
    bottom: 2rem;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
    color: rgba(255, 255, 255, 0.3);
    font-size: 0.75rem;
    letter-spacing: 0.15em;
    text-transform: uppercase;
    animation: float 3s ease-in-out infinite;
}

@keyframes float {
    0%, 100% { transform: translateX(-50%) translateY(0); }
    50% { transform: translateX(-50%) translateY(8px); }
}

/* ── Buttons ── */

.btn {
    display: inline-block;
    padding: 0.85rem 2rem;
    font-family: var(--font-body);
    font-size: 0.9rem;
    font-weight: 600;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    border-radius: 4px;
    border: none;
    cursor: pointer;
    transition: all 0.25s;
}

.btn-primary {
    background: var(--color-accent);
    color: #fff;
}

.btn-primary:hover {
    background: var(--color-accent-hover);
    color: #fff;
    transform: translateY(-2px);
    box-shadow: 0 8px 30px rgba(185, 28, 28, 0.3);
}

.btn-secondary {
    background: transparent;
    color: var(--color-text);
    border: 1px solid var(--color-border);
}

.btn-secondary:hover {
    border-color: var(--color-accent);
    color: var(--color-accent);
    transform: translateY(-2px);
}

.btn-lg {
    padding: 1rem 2.5rem;
    font-size: 1rem;
}

/* ── Sections ── */

.section {
    padding: var(--section-padding);
    position: relative;
    scroll-margin-top: 4rem; /* keep anchored headings clear of the fixed nav */
}

.section-title {
    font-family: var(--font-display);
    font-size: clamp(1.8rem, 4vw, 2.5rem);
    font-weight: 700;
    text-align: center;
    margin-bottom: 1rem;
    color: var(--color-text);
}

/* Ornamental divider under section titles (landing-page sections only) */
.section .section-title::after {
    content: '';
    display: block;
    width: 130px;
    height: 9px;
    margin: 1rem auto 0;
    background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 130 9'%3E%3Cline x1='0' y1='4.5' x2='52' y2='4.5' stroke='%23b91c1c' stroke-width='1' opacity='0.55'/%3E%3Cline x1='78' y1='4.5' x2='130' y2='4.5' stroke='%23b91c1c' stroke-width='1' opacity='0.55'/%3E%3Crect x='61.5' y='1' width='7' height='7' transform='rotate(45 65 4.5)' fill='%23b91c1c'/%3E%3C/svg%3E") center / contain no-repeat;
}

.section-subtitle {
    text-align: center;
    color: var(--color-text-muted);
    font-size: 1.05rem;
    margin-bottom: 3.5rem;
}

.section-title + .section-subtitle {
    margin-top: -0.25rem;
}

/* ── Pillars ── */

.pillars {
    border-top: 1px solid var(--color-border-subtle);
}

.pillars-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1.5rem;
}

/* Let the 5th card span full width centered */
.pillars-grid .pillar-card:last-child:nth-child(odd) {
    grid-column: 1 / -1;
    max-width: 560px;
    justify-self: center;
}

.pillar-card {
    padding: 2.25rem 2rem;
    background: var(--color-bg-card);
    border: 1px solid var(--color-border-subtle);
    border-radius: 8px;
    transition: border-color 0.3s, transform 0.3s, box-shadow 0.3s;
    position: relative;
}

.pillar-card:hover {
    border-color: var(--color-accent-dim);
    transform: translateY(-3px);
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.15);
}

.pillar-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    margin-bottom: 0.5rem;
}

.pillar-icon {
    width: 38px;
    height: 38px;
    color: var(--color-accent);
    opacity: 0.7;
    transition: opacity 0.3s, transform 0.3s;
}

.pillar-card:hover .pillar-icon {
    opacity: 1;
    transform: scale(1.08);
}

.pillar-number {
    font-family: var(--font-display);
    font-size: 2.2rem;
    font-weight: 900;
    color: var(--color-accent);
    opacity: 0.15;
    margin-bottom: 0.5rem;
    line-height: 1;
}

.pillar-head .pillar-number {
    margin-bottom: 0;
}

.pillar-card h3 {
    font-family: var(--font-display);
    font-size: 1.2rem;
    margin-bottom: 1rem;
    color: var(--color-text);
}

.pillar-card > p {
    color: var(--color-text-muted);
    font-size: 0.95rem;
    line-height: 1.75;
    margin-bottom: 0.75rem;
}

.pillar-card strong {
    color: var(--color-accent);
    font-weight: 600;
}

.pillar-punch {
    font-family: var(--font-display);
    font-size: 0.85rem;
    color: var(--color-accent) !important;
    letter-spacing: 0.02em;
    margin-top: 0.75rem;
    margin-bottom: 0 !important;
    padding-top: 0.75rem;
    border-top: 1px solid var(--color-border-subtle);
    line-height: 1.5 !important;
}

/* ── Kickstarter ── */

.kickstarter {
    background:
        radial-gradient(ellipse 60% 70% at 22% 50%, rgba(185, 28, 28, 0.07) 0%, transparent 70%),
        var(--color-bg-elevated);
    border-top: 1px solid var(--color-border-subtle);
    border-bottom: 1px solid var(--color-border-subtle);
}

.ks-grid {
    display: grid;
    grid-template-columns: 320px 1fr;
    gap: 4rem;
    align-items: center;
}

.ks-clock-wrap {
    text-align: center;
}

.doomclock {
    width: 100%;
    max-width: 300px;
    height: auto;
    display: block;
    margin: 0 auto;
}

/* The hand ticks — one chunky doom-step every 2 seconds */
.doomclock-hand {
    transform-origin: 100px 100px;
    animation: doomtick 24s steps(12, end) infinite;
}

@keyframes doomtick {
    to { transform: rotate(360deg); }
}

.doomclock .seg.spent {
    stroke: rgba(232, 229, 224, 0.10);
}

.doomclock .seg.lit {
    stroke: var(--color-accent);
    filter: drop-shadow(0 0 4px rgba(185, 28, 28, 0.55));
    animation: doom-pulse 3.2s ease-in-out infinite;
}

.doomclock .seg.lit:nth-of-type(9)  { animation-delay: 0.5s; }
.doomclock .seg.lit:nth-of-type(10) { animation-delay: 1.0s; }
.doomclock .seg.lit:nth-of-type(11) { animation-delay: 1.5s; }
.doomclock .seg.lit:nth-of-type(12) { animation-delay: 2.0s; }

@keyframes doom-pulse {
    0%, 100% { opacity: 0.8; }
    50%      { opacity: 1; }
}

.ks-clock-caption {
    margin-top: 1.25rem;
    font-family: var(--font-display);
    font-size: 0.9rem;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--color-text-muted);
}

.ks-kicker {
    font-size: 0.8rem;
    font-weight: 600;
    letter-spacing: 0.25em;
    text-transform: uppercase;
    color: var(--color-accent);
    margin-bottom: 0.75rem;
}

.kickstarter .section-title {
    text-align: left;
    margin-bottom: 1.25rem;
}

.kickstarter .section-title::after {
    margin-left: 0;
}

.ks-lead {
    font-size: 1.1rem;
    color: var(--color-text-muted);
    line-height: 1.8;
    margin-bottom: 1.5rem;
}

.ks-lead em {
    color: var(--color-text);
}

.ks-lead strong {
    color: var(--color-accent);
    font-weight: 600;
}

.ks-points {
    list-style: none;
    margin: 0 0 2rem;
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.ks-points li {
    position: relative;
    padding-left: 1.6rem;
    color: var(--color-text-muted);
    font-size: 0.98rem;
    line-height: 1.6;
}

.ks-points li::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0.32em;
    width: 0.8rem;
    height: 0.8rem;
    background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M9 2 H15 V9 L12.4 11.2 L15 13.4 V16 L12 22 L9 16 Z' fill='%23b91c1c'/%3E%3C/svg%3E") center / contain no-repeat;
}

.ks-note {
    font-size: 0.85rem;
    color: var(--color-text-dim);
    margin-top: 1rem;
}

/* ── Try It ── */

.try-it {
    background: var(--color-bg-elevated);
}

.try-it-box {
    max-width: 700px;
    margin: 0 auto;
    text-align: center;
    padding: 3.5rem 3rem;
    background: linear-gradient(135deg, rgba(185, 28, 28, 0.08) 0%, rgba(10, 10, 10, 0.6) 100%);
    border: 1px solid var(--color-border);
    border-radius: 12px;
}

.try-it-content .section-title {
    margin-bottom: 1.5rem;
}

.try-it-content .lead {
    font-size: 1.1rem;
    color: var(--color-text-muted);
    line-height: 1.8;
    margin-bottom: 1rem;
}

.try-it-note {
    font-family: var(--font-display);
    font-size: 0.9rem;
    color: var(--color-accent);
    letter-spacing: 0.02em;
    margin-bottom: 2rem;
}

/* ── Who It's For ── */

.who-for-content {
    max-width: 740px;
    margin: 2rem auto 0;
}

.who-for-content .lead {
    font-size: 1.2rem;
    color: var(--color-text);
    line-height: 1.8;
    margin-bottom: 1.5rem;
}

.who-for-content .lead em {
    color: var(--color-accent);
    font-style: italic;
}

.who-for-content p {
    color: var(--color-text-muted);
    font-size: 1.05rem;
    line-height: 1.8;
    margin-bottom: 1.25rem;
}

/* ── Designer ── */

.designer {
    background: var(--color-bg-elevated);
}

.designer-content {
    max-width: 680px;
    margin: 2rem auto 0;
}

.designer-text p {
    color: var(--color-text-muted);
    font-size: 1.05rem;
    line-height: 1.85;
    margin-bottom: 1.25rem;
}

.designer-text em {
    color: var(--color-text);
    font-style: italic;
}

.designer-text p:nth-last-child(2) {
    /* "This is that game." — make it stand out */
    color: var(--color-text);
    font-size: 1.15rem;
    font-weight: 500;
}

.designer-signature {
    font-family: var(--font-display);
    font-size: 1rem;
    color: var(--color-accent);
    margin-top: 0.5rem;
}

/* ── Signup ── */

.signup {
    background: var(--color-bg-elevated);
}

.signup-box {
    max-width: 640px;
    margin: 0 auto;
    text-align: center;
}

.signup-description {
    color: var(--color-text-muted);
    font-size: 1.1rem;
    margin-bottom: 2.5rem;
    line-height: 1.7;
}

.signup-form {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.signup-fields {
    display: flex;
    gap: 1rem;
}

.signup-fields input {
    flex: 1;
    padding: 0.9rem 1.25rem;
    font-family: var(--font-body);
    font-size: 0.95rem;
    color: var(--color-text);
    background: var(--color-bg);
    border: 1px solid var(--color-border);
    border-radius: 4px;
    outline: none;
    transition: border-color 0.2s, box-shadow 0.2s;
}

.signup-fields input::placeholder {
    color: var(--color-text-dim);
}

.signup-fields input:focus {
    border-color: var(--color-accent);
    box-shadow: 0 0 0 3px var(--color-accent-glow);
}

.btn-submit {
    align-self: center;
    min-width: 220px;
}

.signup-note {
    margin-top: 1rem;
    font-size: 0.8rem;
    color: var(--color-text-dim);
}

.signup-error {
    margin-top: 1rem;
    font-size: 0.9rem;
    color: var(--color-accent-hover);
    line-height: 1.6;
}

.signup-error a {
    color: var(--color-accent-hover);
    text-decoration: underline;
}

[hidden] {
    display: none !important;
}

.signup-success {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
    padding: 2rem 0;
    animation: fadeUp 0.4s ease;
}

.success-icon {
    color: var(--color-accent);
}

.success-message {
    font-size: 1.1rem;
    color: var(--color-text);
}

@keyframes fadeUp {
    from { opacity: 0; transform: translateY(10px); }
    to   { opacity: 1; transform: translateY(0); }
}

@media (max-width: 640px) {
    .signup-fields {
        flex-direction: column;
    }

    .btn-submit {
        width: 100%;
    }
}

/* ── Footer ── */

.footer {
    border-top: 1px solid var(--color-border-subtle);
    padding: 3rem 0 2rem;
    background: var(--color-bg-dark);
    color: var(--color-text);
}

.footer-inner {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 2rem;
    margin-bottom: 2rem;
}

.footer-logo {
    font-family: var(--font-display);
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--color-accent);
    margin-bottom: 0.5rem;
}

.footer-brand p {
    color: var(--color-text-muted);
    font-size: 0.85rem;
    max-width: 340px;
    line-height: 1.6;
}

.footer-links h4 {
    font-family: var(--font-display);
    font-size: 0.85rem;
    color: var(--color-text-muted);
    text-transform: uppercase;
    letter-spacing: 0.1em;
    margin-bottom: 1rem;
}

.footer-links ul {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.footer-links a {
    color: var(--color-text-dim);
    font-size: 0.9rem;
    transition: color 0.2s;
}

.footer-links a:hover {
    color: var(--color-accent);
}

.footer-bottom {
    border-top: 1px solid var(--color-border-subtle);
    padding-top: 1.5rem;
}

.footer-bottom p {
    color: var(--color-text-dim);
    font-size: 0.8rem;
    text-align: center;
}

/* ── Scroll Animations ── */

.fade-in {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.6s ease, transform 0.6s ease;
}

.fade-in.visible {
    opacity: 1;
    transform: translateY(0);
}

/* ── Responsive ── */

@media (max-width: 900px) {
    :root {
        --section-padding: 4rem 0;
    }

    .pillars-grid {
        grid-template-columns: 1fr;
        gap: 1.25rem;
    }

    .pillars-grid .pillar-card:last-child:nth-child(odd) {
        max-width: none;
    }

    .ks-grid {
        grid-template-columns: 1fr;
        gap: 2.5rem;
    }

    .doomclock {
        max-width: 210px;
    }

    .kickstarter .section-title {
        text-align: center;
    }

    .kickstarter .section-title::after {
        margin-left: auto;
    }

    .ks-content {
        text-align: center;
    }

    .ks-points li {
        text-align: left;
    }

    .try-it-box {
        padding: 2.5rem 1.5rem;
    }

    .footer-inner {
        flex-direction: column;
    }
}

@media (max-width: 640px) {
    /* Tighter rhythm on phones: 40px section padding instead of 64px,
       and no half-screen gaps between blocks of copy. */
    :root {
        --section-padding: 2.5rem 0;
    }

    .nav-toggle {
        display: flex;
    }

    .nav-links {
        position: fixed;
        top: 0;
        right: -100%;
        width: 280px;
        height: 100vh;
        flex-direction: column;
        background: var(--color-bg-elevated);
        padding: 5rem 2rem 2rem;
        gap: 1.5rem;
        border-left: 1px solid var(--color-border-subtle);
        transition: right 0.3s ease;
    }

    .nav-links.open {
        right: 0;
    }

    .nav-cta {
        text-align: center;
        width: 100%;
    }

    .hero-title-main {
        font-size: clamp(2.4rem, 12vw, 3.5rem);
    }

    /* Keep the first screen tight enough that the CTA is above the fold:
       clear the fixed nav, trim the pitch to its hook (the full version
       stays visible on tablet/desktop), and drop the scroll hint — the
       hero used to overflow 100vh and the hint sat on top of the
       "See the Game" button. */
    .hero-content {
        padding-top: 5.5rem;
    }

    .hero-description {
        margin-bottom: 1.75rem;
    }

    .hero-description-more {
        display: none;
    }

    .hero-scroll-hint {
        display: none;
    }

    .hero-actions {
        flex-direction: column;
        align-items: center;
        gap: 0.75rem;
    }

    .btn {
        width: 100%;
        max-width: 280px;
        text-align: center;
    }

    .section-subtitle {
        margin-bottom: 1.5rem;
    }

    .section .section-title::after {
        margin-top: 0.75rem;
    }

    /* Pillars: phones get the hook, not the essay. The body paragraph
       is hidden; number + icon + title + punchline carry the pitch.
       Full copy still shows ≥640px. */
    .pillar-card {
        padding: 1.5rem 1.25rem;
    }

    .pillar-card > p:not(.pillar-punch) {
        display: none;
    }

    .pillar-card h3 {
        margin-bottom: 0.5rem;
    }

    .pillar-punch {
        margin-top: 0 !important;
    }

    /* Kickstarter: smaller clock, tighter stack */
    .ks-grid {
        gap: 1.5rem;
    }

    .doomclock {
        max-width: 150px;
    }

    .ks-clock-caption {
        margin-top: 0.75rem;
    }

    .ks-lead {
        font-size: 1rem;
        margin-bottom: 1rem;
    }

    .ks-points {
        gap: 0.5rem;
        margin-bottom: 1.5rem;
    }

    .try-it-box {
        padding: 2rem 1.25rem;
    }

    .try-it-note {
        margin-bottom: 1.25rem;
    }

    .who-for-content,
    .designer-content {
        margin-top: 1rem;
    }

    .signup-description {
        margin-bottom: 1.5rem;
    }

    /* Footer: two-column link list instead of a long stack */
    .footer {
        padding: 2rem 0 1.5rem;
    }

    .footer-inner {
        gap: 1.5rem;
        margin-bottom: 1.5rem;
    }

    .footer-links ul {
        display: grid;
        grid-template-columns: 1fr 1fr;
        column-gap: 1.5rem;
        row-gap: 0.5rem;
    }
}

/* ── Reduced Motion ── */

@media (prefers-reduced-motion: reduce) {
    .doomclock-hand,
    .doomclock .seg.lit,
    .embers span,
    .hero-bg::after,
    .hero-scroll-hint {
        animation: none;
    }

    .embers {
        display: none;
    }

    html {
        scroll-behavior: auto;
    }
}
