/* Emergency Scene Simulator — marketing site.
   Palette matches the product's eula.html so the site and the app agree. */

:root {
    --bg: #1e1e1e;
    --bg-alt: #232323;
    --card: #282828;
    --text: #f0f0f0;
    --muted: #a8b6c4;
    --line: rgba(140, 155, 170, 0.28);
    --steel: #4f657f;
    --link: #64b4ff;
    --ember: #e4572e;
    --focus: #ffcf5c;
    --measure: 68ch;
}

* { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
    margin: 0;
    background: var(--bg);
    color: var(--text);
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    font-size: 18px;
    line-height: 1.65;
}

img, svg { max-width: 100%; height: auto; }

a { color: var(--link); }

a:hover { color: #8ecbff; }

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

.wrap {
    width: 100%;
    max-width: 1080px;
    margin: 0 auto;
    padding: 0 24px;
}

.wrap.narrow { max-width: 760px; }

.skip {
    position: absolute;
    left: -9999px;
    top: 0;
    background: var(--card);
    color: var(--text);
    padding: 12px 20px;
    z-index: 10;
}

.skip:focus {
    left: 0;
}

/* Header ------------------------------------------------------------------ */

.site-header {
    border-bottom: 1px solid var(--line);
    background: var(--bg);
    position: sticky;
    top: 0;
    z-index: 5;
}

.header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    flex-wrap: wrap;
    padding-top: 14px;
    padding-bottom: 14px;
}

.wordmark {
    display: flex;
    align-items: center;
    gap: 12px;
    color: var(--text);
    text-decoration: none;
    font-weight: 600;
    font-size: 17px;
    letter-spacing: 0.01em;
}

.wordmark img { border-radius: 6px; }

.site-header nav {
    display: flex;
    align-items: center;
    gap: 22px;
    flex-wrap: wrap;
    font-size: 15px;
}

.site-header nav a {
    color: var(--muted);
    text-decoration: none;
}

.site-header nav a:hover {
    color: var(--text);
    text-decoration: underline;
}

.nav-cta {
    border: 1px solid var(--steel);
    border-radius: 6px;
    padding: 7px 16px;
    color: var(--text) !important;
}

.nav-cta:hover {
    background: var(--steel);
    text-decoration: none !important;
}

/* Sections ---------------------------------------------------------------- */

.section { padding: 72px 0; }

.section-alt {
    background: var(--bg-alt);
    border-top: 1px solid var(--line);
    border-bottom: 1px solid var(--line);
}

h1, h2, h3 {
    line-height: 1.2;
    margin: 0 0 16px;
    color: #fff;
}

h1 { font-size: clamp(2rem, 5vw, 3.1rem); letter-spacing: -0.02em; }

h2 { font-size: clamp(1.5rem, 3vw, 2.1rem); letter-spacing: -0.01em; }

h3 { font-size: 1.2rem; }

p { margin: 0 0 18px; max-width: var(--measure); }

.hero {
    padding: 96px 0 80px;
    border-bottom: 1px solid var(--line);
    background:
        radial-gradient(120% 90% at 78% 8%, rgba(228, 87, 46, 0.16), transparent 62%),
        radial-gradient(90% 80% at 8% 0%, rgba(79, 101, 127, 0.24), transparent 60%);
}

.lede {
    font-size: clamp(1.05rem, 2.2vw, 1.35rem);
    color: var(--muted);
    max-width: 60ch;
}

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

.section-lede {
    color: var(--muted);
    margin-bottom: 36px;
}

.button {
    display: inline-block;
    background: var(--steel);
    color: #fff;
    border: 1px solid var(--steel);
    border-radius: 7px;
    padding: 13px 26px;
    font-size: 1rem;
    font-weight: 600;
    font-family: inherit;
    text-decoration: none;
    cursor: pointer;
}

.button:hover {
    background: #5f7a99;
    border-color: #5f7a99;
    color: #fff;
}

.button[disabled] { opacity: 0.55; cursor: default; }

.button-quiet {
    display: inline-block;
    padding: 13px 22px;
    border: 1px solid var(--line);
    border-radius: 7px;
    color: var(--text);
    text-decoration: none;
    font-weight: 500;
}

.button-quiet:hover { border-color: var(--muted); color: #fff; }

/* Cards ------------------------------------------------------------------- */

.cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(270px, 1fr));
    gap: 22px;
}

.card {
    background: var(--card);
    border: 1px solid var(--line);
    border-radius: 10px;
    padding: 28px 26px;
}

/* Icon and heading on one line; the body runs the full card width beneath
   them rather than indenting under the heading. */
.card-head {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 16px;
}

.card-icon { flex: none; display: block; }

.card-head h3 { margin: 0; }

.card p { margin: 0; color: var(--muted); }

.cards + .note { margin-top: 30px; }

/* Screenshots ------------------------------------------------------------- */

/* Two-up. Screenshots are wide and detailed; three across makes the UI in them
   unreadable, so the grid drops straight from two columns to one. */
.shots {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(420px, 1fr));
    gap: 20px;
}

.shots figure {
    margin: 0;
    background: var(--card);
    border: 1px solid var(--line);
    border-radius: 10px;
    overflow: hidden;
}

.shots img { display: block; width: 100%; }

.shots figcaption {
    padding: 14px 18px;
    font-size: 0.9rem;
    color: var(--muted);
}

/* Limits ------------------------------------------------------------------ */

.limits {
    max-width: var(--measure);
    margin: 0 0 22px;
    padding-left: 22px;
}

.limits li { margin-bottom: 10px; color: var(--muted); }

.limits strong { color: var(--text); }

.note {
    border-left: 3px solid var(--steel);
    padding: 4px 0 4px 18px;
    color: var(--muted);
    font-size: 0.95rem;
}

/* Form -------------------------------------------------------------------- */

/* Two-column form. Short answers pair up rather than each claiming a full row;
   `wide` spans both columns, `short` caps the control at the width its answer
   actually needs. Collapses to one column on a narrow screen. */
form { max-width: 760px; }

.form-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px 24px;
    align-items: start;
}

.field { margin-bottom: 0; min-width: 0; }

.field.wide { grid-column: 1 / -1; }

.field.short input { max-width: 150px; }

.field.medium input { max-width: 260px; }

@media (max-width: 700px) {
    .form-grid { grid-template-columns: 1fr; }
    .field.short input, .field.medium input { max-width: none; }
}

label {
    display: block;
    margin-bottom: 6px;
    font-weight: 600;
    font-size: 0.95rem;
}

.optional { font-weight: 400; color: var(--muted); }

input, textarea {
    width: 100%;
    background: #191919;
    color: var(--text);
    border: 1px solid var(--line);
    border-radius: 7px;
    padding: 11px 13px;
    font: inherit;
    font-size: 1rem;
}

input:hover, textarea:hover { border-color: var(--muted); }

textarea { resize: vertical; }

/* Radio group. `input` above sets width:100%, which would stretch a radio across
   the row, so the control is reset explicitly here. */
fieldset.field {
    border: 0;
    padding: 0;
    margin: 0;
}

legend {
    padding: 0;
    margin-bottom: 6px;
    font-weight: 600;
    font-size: 0.95rem;
}

.choices {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

/* The radio itself is hidden and the label span becomes the control, so there is
   no dot. Kept focusable and in the accessibility tree — never display:none. */
.choice {
    position: relative;
    display: inline-flex;
    margin-bottom: 0;
    font-weight: 400;
    cursor: pointer;
}

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

.choice span {
    display: block;
    padding: 10px 14px;
    border: 1px solid var(--line);
    border-radius: 7px;
}

.choice:hover span { border-color: var(--muted); }

.choice input:checked + span {
    border-color: var(--steel);
    background: var(--steel);
    color: #fff;
    font-weight: 600;
}

.choice input:focus-visible + span {
    outline: 3px solid var(--focus);
    outline-offset: 2px;
}

.hint {
    font-size: 0.875rem;
    color: var(--muted);
    margin: 8px 0 0;
}

.field .hint { margin-top: 6px; }

/* Honeypot: off-screen but still focusable-by-bot and not display:none,
   which some bots skip. Never remove aria-hidden or tabindex in the markup. */
.hp {
    position: absolute;
    left: -9999px;
    width: 1px;
    height: 1px;
    overflow: hidden;
}

form .button { margin-top: 26px; }

.form-status {
    margin-top: 16px;
    font-weight: 600;
    max-width: 520px;
}

.form-status.ok { color: #7fd18b; }

.form-status.bad { color: #ff9a8a; }

/* Footer ------------------------------------------------------------------ */

.site-footer {
    border-top: 1px solid var(--line);
    padding: 40px 0;
    color: var(--muted);
    font-size: 0.9rem;
}

.footer-inner p { margin: 0 0 10px; max-width: none; }

.site-footer nav {
    display: flex;
    gap: 20px;
    flex-wrap: wrap;
    margin-bottom: 10px;
}

.copyright { color: #7d8b99; }

/* Legal pages ------------------------------------------------------------- */

.legal { padding: 56px 0 80px; }

.legal h2 { font-size: 1.25rem; margin-top: 36px; }

/* Matches the EULA's dateline (WebGLTemplates/PWA/eula.html) — italic, small,
   muted. Keep the two in step; they are read as one set of legal pages. */
.last-updated {
    font-style: italic;
    font-size: 0.8rem;
    color: var(--muted);
    margin: -6px 0 28px;
}

.legal ul { max-width: var(--measure); color: var(--muted); }

.legal li { margin-bottom: 8px; }

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