:root {
    color-scheme: dark;
    --cream: #fff2db;
    --cream-muted: #ddcdb9;
    --ember: #f08b48;
    --red: #a9212d;
    --red-bright: #d23b46;
    --ink: #130709;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
    margin: 0;
    min-width: 320px;
    background: var(--ink);
    color: var(--cream);
    font-family: "DM Sans", system-ui, sans-serif;
    -webkit-font-smoothing: antialiased;
}

.site-header {
    position: fixed;
    z-index: 10;
    top: 0;
    left: 0;
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 22px clamp(22px, 5vw, 72px);
    background: linear-gradient(to bottom, rgba(11, 3, 4, .78), transparent);
}

.brand {
    display: flex;
    align-items: center;
    gap: 11px;
    color: var(--cream);
    text-decoration: none;
}

.brand-mark {
    display: grid;
    width: 42px;
    height: 42px;
    place-items: center;
    border: 2px solid rgba(255, 242, 219, .72);
    border-radius: 50%;
    background: rgba(122, 19, 29, .72);
    font: 400 1.18rem/1 "Bebas Neue", Impact, sans-serif;
    letter-spacing: .05em;
    box-shadow: 0 5px 20px rgba(0, 0, 0, .35);
}

.brand-name {
    font: 400 1.5rem/1 "Bebas Neue", Impact, sans-serif;
    letter-spacing: .08em;
    text-transform: uppercase;
}

.launch-note {
    color: rgba(255, 242, 219, .72);
    font-size: .7rem;
    font-weight: 700;
    letter-spacing: .19em;
    text-transform: uppercase;
}

.hero {
    position: relative;
    isolation: isolate;
    min-height: 100vh;
    min-height: 100svh;
    overflow: hidden;
    display: grid;
    place-items: start center;
    text-align: center;
    background: #190709;
}

.hero-backdrop {
    position: absolute;
    z-index: -3;
    inset: 0;
    background-image: url("../images/tailgate-hero.png");
    background-position: center center;
    background-size: cover;
    filter: saturate(.94) contrast(1.03);
    animation: settle 1.2s ease-out both;
}

.hero::before {
    content: "";
    position: absolute;
    z-index: -2;
    inset: 0;
    background:
        linear-gradient(to bottom, rgba(8, 2, 3, .78) 0%, rgba(12, 3, 5, .4) 31%, rgba(10, 2, 3, .04) 55%, rgba(7, 2, 2, .5) 100%),
        radial-gradient(ellipse at 50% 23%, rgba(105, 10, 23, .18), transparent 45%);
}

.hero::after {
    content: "";
    position: absolute;
    z-index: -1;
    inset: 0;
    pointer-events: none;
    box-shadow: inset 0 0 180px 35px rgba(0, 0, 0, .54);
}

.hero-content {
    width: min(91%, 780px);
    padding-top: clamp(100px, 12vh, 132px);
    animation: reveal .9s .15s ease-out both;
}

.eyebrow {
    margin: 0 0 8px;
    color: #f0cda8;
    font-size: clamp(.68rem, 1.25vw, .82rem);
    font-weight: 700;
    letter-spacing: .27em;
    text-transform: uppercase;
}

h1 {
    margin: 0;
    color: var(--cream);
    font: 400 clamp(5.2rem, 11vw, 9.3rem)/.78 "Bebas Neue", Impact, sans-serif;
    letter-spacing: .015em;
    text-transform: uppercase;
    text-shadow: 0 5px 0 rgba(31, 4, 6, .75), 0 15px 42px rgba(0, 0, 0, .8);
}

h1 span { color: var(--red-bright); }

.tagline {
    margin: clamp(16px, 2.3vh, 24px) 0 0;
    color: #fff8ea;
    font-family: Georgia, serif;
    font-size: clamp(1.35rem, 3.1vw, 2.1rem);
    font-weight: 700;
    letter-spacing: .035em;
    text-shadow: 0 3px 18px #000;
}

.intro {
    max-width: 610px;
    margin: 14px auto 0;
    color: var(--cream-muted);
    font-size: clamp(.9rem, 1.5vw, 1.05rem);
    line-height: 1.55;
    text-shadow: 0 2px 12px #000;
    text-wrap: balance;
}

.waitlist-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    margin-top: clamp(20px, 3vh, 30px);
    padding: 16px 26px 16px 31px;
    border: 1px solid rgba(255, 238, 214, .7);
    border-radius: 999px;
    background: linear-gradient(135deg, #7d111c, var(--red-bright));
    color: #fff;
    font-weight: 700;
    letter-spacing: .035em;
    text-decoration: none;
    font: inherit;
    cursor: pointer;
    box-shadow: 0 13px 35px rgba(58, 3, 9, .7), 0 0 0 5px rgba(210, 59, 70, .13), inset 0 1px rgba(255, 255, 255, .24);
    transition: transform .2s ease, filter .2s ease, box-shadow .2s ease;
}

.waitlist-dialog {
    width: min(92%, 610px);
    max-height: min(90vh, 760px);
    overflow-y: auto;
    border: 1px solid rgba(255, 242, 219, .25);
    border-radius: 24px;
    padding: clamp(28px, 5vw, 46px);
    background: linear-gradient(145deg, #281014, #100709 70%);
    color: var(--cream);
    box-shadow: 0 30px 90px rgba(0, 0, 0, .75);
}

.waitlist-dialog::backdrop {
    background: rgba(7, 2, 3, .78);
    backdrop-filter: blur(7px);
}

.dialog-close {
    position: absolute;
    top: 13px;
    right: 17px;
    border: 0;
    background: transparent;
    color: rgba(255, 242, 219, .72);
    font-size: 2rem;
    line-height: 1;
    cursor: pointer;
}

.dialog-header { text-align: center; }
.dialog-header .eyebrow { margin-bottom: 10px; }

.dialog-header h2,
.form-success h2 {
    margin: 0;
    font: 400 clamp(2.2rem, 6vw, 3.4rem)/.95 "Bebas Neue", Impact, sans-serif;
    letter-spacing: .025em;
    text-transform: uppercase;
}

.dialog-header > p:last-child,
.form-success p {
    margin: 12px auto 0;
    color: var(--cream-muted);
    line-height: 1.5;
}

.waitlist-form { margin-top: 28px; }

.waitlist-form label:not(.check-row):not(.honeypot) {
    display: grid;
    gap: 7px;
    margin-bottom: 17px;
    color: #f7e8d4;
    font-size: .78rem;
    font-weight: 700;
    letter-spacing: .06em;
    text-transform: uppercase;
}

.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }

.waitlist-form input[type="text"],
.waitlist-form input[type="email"] {
    width: 100%;
    border: 1px solid rgba(255, 242, 219, .2);
    border-radius: 11px;
    padding: 13px 14px;
    background: rgba(255, 255, 255, .07);
    color: #fff;
    font: 400 1rem/1.2 "DM Sans", system-ui, sans-serif;
    outline: none;
}

.waitlist-form input:focus { border-color: var(--ember); box-shadow: 0 0 0 3px rgba(240, 139, 72, .16); }
.waitlist-form small { color: rgba(255, 242, 219, .48); font-size: .67rem; letter-spacing: 0; text-transform: none; }

.check-row { display: flex; align-items: flex-start; gap: 10px; color: var(--cream-muted); font-size: .82rem; line-height: 1.45; }
.check-row input { width: 18px; height: 18px; margin-top: 1px; accent-color: var(--red-bright); }
.honeypot { position: absolute !important; left: -9999px !important; }

.form-submit,
.form-success button {
    width: 100%;
    margin-top: 22px;
    border: 1px solid rgba(255, 238, 214, .58);
    border-radius: 999px;
    padding: 14px 22px;
    background: linear-gradient(135deg, #83131e, var(--red-bright));
    color: #fff;
    font: 700 1rem/1.2 "DM Sans", system-ui, sans-serif;
    cursor: pointer;
}

.form-submit:disabled { cursor: wait; opacity: .68; }
.form-status { min-height: 1.3em; margin: 12px 0 0; color: #ffad9c; font-size: .82rem; text-align: center; }
.privacy-note { margin: 9px 0 0; color: rgba(255, 242, 219, .42); font-size: .68rem; line-height: 1.45; text-align: center; }

.form-success { padding: 25px 0 10px; text-align: center; }
.form-success > span { display: grid; width: 64px; height: 64px; margin: 0 auto 22px; place-items: center; border: 2px solid #f2ad72; border-radius: 50%; color: #f2ad72; font-size: 1.8rem; }

.waitlist-button svg {
    width: 21px;
    fill: none;
    stroke: currentColor;
    stroke-linecap: round;
    stroke-linejoin: round;
    stroke-width: 2;
    transition: transform .2s ease;
}

.waitlist-button:hover {
    transform: translateY(-3px);
    filter: brightness(1.13);
    box-shadow: 0 16px 42px rgba(58, 3, 9, .8), 0 0 0 6px rgba(240, 139, 72, .17);
}

.waitlist-button:hover svg { transform: translateX(3px); }
.waitlist-button:focus-visible { outline: 3px solid var(--cream); outline-offset: 5px; }

.fine-print {
    margin: 17px 0 0;
    color: rgba(255, 242, 219, .67);
    font-size: .71rem;
    font-weight: 700;
    letter-spacing: .08em;
    text-transform: uppercase;
}

.fine-print span {
    color: var(--ember);
    font-size: .62em;
    vertical-align: .12em;
}

.scroll-cue {
    position: absolute;
    bottom: 20px;
    left: 50%;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    color: rgba(255, 242, 219, .7);
    font-size: .62rem;
    font-weight: 700;
    letter-spacing: .2em;
    text-transform: uppercase;
    transform: translateX(-50%);
}

.scroll-cue b { width: 1px; height: 22px; background: linear-gradient(var(--ember), transparent); }

.embers i {
    position: absolute;
    bottom: 5%;
    left: var(--x);
    width: 3px;
    height: 3px;
    border-radius: 50%;
    background: #ffd180;
    box-shadow: 0 0 8px 2px #f47635;
    animation: ember-rise var(--speed) var(--delay) infinite ease-out;
}

.embers i:nth-child(1) { --x: 45%; --speed: 4.4s; --delay: -1s; }
.embers i:nth-child(2) { --x: 48%; --speed: 5.1s; --delay: -3s; }
.embers i:nth-child(3) { --x: 51%; --speed: 4.7s; --delay: -2s; }
.embers i:nth-child(4) { --x: 54%; --speed: 5.4s; --delay: -4s; }
.embers i:nth-child(5) { --x: 49%; --speed: 4.2s; --delay: -.5s; }
.embers i:nth-child(6) { --x: 53%; --speed: 5.8s; --delay: -3.6s; }

@keyframes ember-rise {
    0% { opacity: 0; transform: translate(0, 0) scale(.7); }
    15% { opacity: 1; }
    100% { opacity: 0; transform: translate(25px, -230px) scale(0); }
}

@keyframes settle { from { opacity: .4; transform: scale(1.04); } to { opacity: 1; transform: scale(1); } }
@keyframes reveal { from { opacity: 0; transform: translateY(-16px); } to { opacity: 1; transform: none; } }

@media (max-width: 700px) {
    .site-header { padding: 16px 18px; }
    .brand-mark { width: 36px; height: 36px; font-size: 1rem; }
    .brand-name { font-size: 1.25rem; }
    .launch-note { display: none; }
    .hero { place-items: start center; }
    .hero-backdrop { background-position: center bottom; }
    .hero::before { background: linear-gradient(to bottom, rgba(8, 2, 3, .85) 0%, rgba(10, 2, 3, .55) 39%, rgba(6, 1, 2, .04) 66%, rgba(6, 1, 2, .45)); }
    .hero-content { width: min(92%, 520px); padding-top: 104px; }
    h1 { font-size: clamp(4.6rem, 25vw, 7rem); }
    .tagline { margin-top: 14px; }
    .intro { max-width: 440px; font-size: .9rem; }
    .waitlist-button { width: min(100%, 300px); padding-block: 15px; }
    .scroll-cue { display: none; }
    .waitlist-dialog { padding: 34px 20px 24px; border-radius: 18px; }
    .form-row { grid-template-columns: 1fr; gap: 0; }
}

@media (max-height: 690px) and (min-width: 701px) {
    .hero-content { padding-top: 82px; }
    h1 { font-size: clamp(5rem, 15vh, 7.2rem); }
    .tagline { margin-top: 12px; }
    .intro { margin-top: 9px; }
    .waitlist-button { margin-top: 17px; padding-block: 13px; }
    .fine-print { margin-top: 11px; }
}

@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; scroll-behavior: auto !important; }
}
