/* Last Hat Standing landing page. Values come from docs/design/mexican-standoff/v3/tokens.md.
   CSP is default-src 'self': keep every style in this file, no style="" attributes, no <style>, no data: URIs. */

@font-face { font-family: "Lilita One"; src: url(fonts/LilitaOne-Regular.woff2) format("woff2"); font-weight: 400; font-display: swap; }
@font-face { font-family: "Fredoka"; src: url(fonts/Fredoka-Medium.woff2) format("woff2"); font-weight: 500; font-display: swap; }
@font-face { font-family: "Fredoka"; src: url(fonts/Fredoka-SemiBold.woff2) format("woff2"); font-weight: 600; font-display: swap; }

:root {
  /* Colour: tokens.md section 1 */
  --ink: #3a1f14;
  --night: #2b1f3d;
  --night-2: #21172f;
  --night-2-rgb: 33, 23, 47;
  --wall-dk: #3d2a52;
  --cream: #fff3dc;
  --cream-2: #f6e4c2;
  --cream-3: #f0d7ad;
  --gold: #ffc83d;
  --lamp: 255, 242, 176;              /* #fff2b0, lamp light */
  --shadow: 20, 10, 30;               /* #140a1e, vignette and drop shadow */
  --text: #fff7ea;                    /* text.primary on night */
  --text-2: #dcc9ee;                  /* text.secondary on night */
  --text-cream-2: #7a5a46;            /* text.secondary on cream */
  --danger-cream: #b8281e;            /* focus ring on cream */

  /* Type: tokens.md section 2. Scale is mobile first, clamp() covers 320 to 430 pt and up */
  --display: "Lilita One", "Arial Rounded MT Bold", ui-rounded, system-ui, sans-serif;
  --body: "Fredoka", ui-rounded, system-ui, -apple-system, sans-serif;
  --size-h1: clamp(2.25rem, 11vw, 3.5rem);    /* 36 / 43 / 47 / 56 pt */
  --size-h2: clamp(1.75rem, 8vw, 2.5rem);     /* 28 / 31 / 34 / 40 pt */
  --size-h3: 1.3125rem;                       /* 21 pt */
  --size-lede: 1.125rem;                      /* 18 pt */
  --size-body: 1rem;                          /* 16 pt */
  --size-fine: .875rem;                       /* 14 pt */
  --size-small: .75rem;                       /* 12 pt, smallest text on the site */

  /* Space: 4 pt scale, screen edge 16 pt */
  --gutter: 16px;
  --section-y: 56px;
  --col: 680px;
  --radius-panel: 20px;
  --radius-inset: 16px;
  --radius-sheet: 28px;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; color-scheme: dark; background: var(--night-2); scroll-padding-top: 100px; }
@media (prefers-reduced-motion: no-preference) { html { scroll-behavior: smooth; } }
body { margin: 0; font: 500 var(--size-body)/1.5 var(--body); color: var(--text); background: var(--night-2); overflow-wrap: break-word; }
h1, h2, h3, p, ol, ul, dl, dd { margin: 0; padding: 0; }
img { display: block; max-width: 100%; height: auto; }
a { color: inherit; text-decoration-thickness: 2px; text-underline-offset: 3px; }
:focus-visible { outline: 3px solid var(--gold); outline-offset: 3px; border-radius: 4px; }

/* Sticker headings: fill + ink outline + hard drop, light from the top left */
h1, h2 { font-family: var(--display); font-weight: 400; -webkit-text-stroke: var(--stroke) var(--ink); paint-order: stroke fill; text-shadow: 0 var(--drop) 0 var(--ink); }
h1 { --stroke: 6px; --drop: 4px; font-size: var(--size-h1); line-height: 1.08; }
h1 span { display: block; }
h1 span:last-child { color: var(--gold); }
h2 { --stroke: 5px; --drop: 3px; font-size: var(--size-h2); line-height: 1.12; }
h3 { font: 400 var(--size-h3)/1.2 var(--display); }

/* Sticky menu bar. No JavaScript: on a phone the links sit in a second row that scrolls sideways; from 760 pt everything is one row */
.nav { position: sticky; top: 0; z-index: 10; background: var(--night-2); border-bottom: 2px solid var(--wall-dk); }
.nav__bar { display: flex; flex-wrap: wrap; align-items: center; column-gap: 12px; max-width: 1180px; margin-inline: auto; padding: 4px var(--gutter) 0; }
.nav__brand { display: flex; align-items: center; gap: 8px; min-height: 44px; font: 400 .9375rem/1.1 var(--display); text-decoration: none; }
.nav__brand img { width: 36px; height: auto; }
.nav .cta { order: 2; margin-left: auto; padding: 6px 14px; font-size: .9375rem; box-shadow: 0 3px 0 var(--ink); }
.nav__links { order: 3; flex: 1 0 100%; display: flex; margin-inline: calc(var(--gutter) * -1); padding-inline: 4px 32px; overflow-x: auto; scrollbar-width: none; -webkit-mask-image: linear-gradient(to right, #000 calc(100% - 32px), transparent); mask-image: linear-gradient(to right, #000 calc(100% - 32px), transparent); }
.nav__links::-webkit-scrollbar { display: none; }
.nav__links a { flex: none; padding: 10px 12px; font-size: var(--size-fine); font-weight: 600; text-decoration: none; color: var(--text-2); }
.nav__links a:hover { color: var(--text); text-decoration: underline; }

/* Download button. At S0 it is a span, not a link: nothing to tap yet. s1.sh swaps it for the App Store link */
.cta { display: inline-block; padding: 10px 20px; font: 400 1.0625rem/1.2 var(--display); text-align: center; text-decoration: none; white-space: nowrap; color: var(--ink); background: linear-gradient(to bottom, #ffdc6b, var(--gold)); border: 3px solid var(--ink); border-radius: 999px; box-shadow: 0 4px 0 var(--ink); }
.cta--big { padding: 14px 26px; font-size: clamp(1.0625rem, 5.6vw, 1.375rem); white-space: normal; box-shadow: 0 5px 0 var(--ink), 0 0 28px rgba(255, 200, 61, .35); }
a.cta:hover { background: #ffe08a; }
a.cta:active { transform: translateY(2px); box-shadow: 0 2px 0 var(--ink); }
.cta-row { margin-top: 24px; }

/* Hero */
.hero__stage { position: relative; height: clamp(260px, 46vh, 560px); height: clamp(260px, 46svh, 560px); max-width: 620px; margin-inline: auto; overflow: hidden; }
.hero__scene { width: 100%; height: 100%; object-fit: cover; object-position: center top; }
.hero__stage::after { content: ""; position: absolute; inset: 0; pointer-events: none;
  background:
    linear-gradient(to top, var(--night-2), rgba(33, 23, 47, 0) 30%),
    linear-gradient(to bottom, var(--night-2), rgba(33, 23, 47, 0) 8%),
    linear-gradient(to right, var(--night-2), rgba(33, 23, 47, 0) 6%, rgba(33, 23, 47, 0) 94%, var(--night-2)); }
.hero__logo { position: absolute; z-index: 1; left: 11%; top: 6%; width: 78%; height: 56%; object-fit: contain; }
.hero__copy { position: relative; z-index: 1; margin-top: -24px; padding: 0 var(--gutter) 48px; text-align: center; }
.lede { max-width: 30rem; margin: 16px auto 0; font-size: var(--size-lede); line-height: 1.45; }
.badge { display: block; width: fit-content; margin: 28px auto 14px; }                      /* S1: official Apple file, 1/4 height clear space */
.badge img { height: 54px; width: auto; }                                                   /* height only: the file keeps its own ratio */
.fine { margin-top: 16px; font-size: var(--size-fine); font-weight: 600; line-height: 1.45; color: var(--text-2); }
.fine b { font: 400 1rem/1 var(--display); color: var(--text); }
.fine span { white-space: nowrap; }
.social { margin-top: 4px; }
.social a { display: inline-block; padding: 12px 8px; font-weight: 600; }

/* Sections */
.section { padding: var(--section-y) var(--gutter); }
.section--alt { background: var(--night); }
.wrap { max-width: var(--col); margin-inline: auto; }
.section p + p { margin-top: 16px; }
.intro { margin-top: 16px; color: var(--text); }
.aside { font-weight: 600; color: var(--gold); }

/* Screens: flat image, rounded corners, sticker edge. No device frame */
.shot { width: 100%; border-radius: var(--radius-panel); box-shadow: 0 0 0 3px var(--ink), 0 0 0 6px var(--text), 0 10px 24px rgba(var(--shadow), .55); }
.shots { display: grid; gap: 28px; margin-top: 32px; }
.intro + .intro { margin-top: 12px; }
.eyes { margin-top: 28px; }

/* Bir el: numbered steps */
.steps { list-style: none; counter-reset: step; display: grid; gap: 24px; margin-top: 32px; }
.steps li { counter-increment: step; display: grid; grid-template-columns: 44px 1fr; column-gap: 12px; align-content: start; }
.steps li::before { content: counter(step); grid-row: span 2; font: 400 2.5rem/1 var(--display); color: var(--gold); -webkit-text-stroke: 4px var(--ink); paint-order: stroke fill; text-shadow: 0 3px 0 var(--ink); text-align: center; }
.steps p { margin-top: 4px; color: var(--text-2); }

/* Geri gelme sebepleri: panels have no lip, because nothing here can be tapped */
.cards { list-style: none; display: grid; gap: 20px; margin-top: 32px; }
.card { overflow: hidden; color: var(--ink); background: var(--cream); border: 3px solid var(--ink); border-radius: var(--radius-panel); box-shadow: inset 0 -4px 0 var(--cream-3), 0 6px 16px rgba(var(--shadow), .35); }
.card img { width: 100%; aspect-ratio: 3 / 2; object-fit: cover; border-bottom: 3px solid var(--ink); }
.card__text { padding: 16px 16px 20px; }
.card p { margin-top: 6px; }

/* Good to know */
.faq { margin-top: 24px; }
.faq div { padding-block: 20px; border-top: 2px solid var(--wall-dk); }
.faq dt { font: 400 1.1875rem/1.25 var(--display); }
.faq dd { margin-top: 6px; color: var(--text-2); }

/* Closing and footer: the page ends under the one lamp */
.close { padding: 72px var(--gutter) 40px; text-align: center; background: radial-gradient(70% 280px at 50% 0, rgba(var(--lamp), .16), rgba(var(--lamp), 0)), var(--night-2); }
.close h2 { color: var(--gold); }
.close .cta-row { margin-top: 20px; }
.close .store-link { display: inline-block; margin-top: 12px; padding: 12px 8px; font: 400 1.375rem/1.25 var(--display); color: var(--gold); }
.footer { padding: 0 var(--gutter) 32px; text-align: center; font-size: var(--size-fine); line-height: 1.45; color: var(--text-2); }
.footer .wrap { padding-top: 24px; border-top: 2px solid var(--wall-dk); }
.legal { max-width: 36rem; margin-inline: auto; text-align: left; }
.foot-links { margin-top: 12px; font-weight: 600; color: var(--text); }
.foot-links a { display: inline-block; padding: 12px 8px; }
.imprint { margin-top: 4px; }
.apple-line { max-width: 36rem; margin: 12px auto 0; font-size: var(--size-small); line-height: 1.4; }

/* /privacy and /support: a cream sheet, dark ink on paper reads better than light on night for long text */
.doc { max-width: 800px; margin-inline: auto; padding: 28px var(--gutter) 48px; color: var(--ink); background: var(--cream); border-top: 4px solid var(--ink); border-radius: var(--radius-sheet) var(--radius-sheet) 0 0; font-size: clamp(1rem, 4.4vw, 1.0625rem); line-height: 1.6; }   /* 16 / 26 at 320 pt, 17 / 27 from 390 pt */
.doc :focus-visible { outline-color: var(--danger-cream); }
.doc h1, .doc h2 { color: var(--ink); -webkit-text-stroke: 0; text-shadow: none; }
.doc h1 { font-size: 2rem; line-height: 1.15; }
.doc h2 { margin-top: 36px; font-size: 1.3125rem; line-height: 1.25; }
.doc > p, .doc > ul, .doc > ol { max-width: 40rem; }
.doc > * + p, .doc > * + ul, .doc > * + ol { margin-top: 12px; }
.doc h2 + p, .doc h2 + ul, .doc h2 + table { margin-top: 8px; }
.doc ul, .doc ol { padding-left: 1.15em; }
.doc li + li { margin-top: 6px; }
.doc li::marker { color: var(--text-cream-2); font-weight: 600; }
.doc strong { font-weight: 600; }
.doc-meta { margin-top: 8px; font-size: .9375rem; color: var(--text-cream-2); }
.doc-callout { max-width: 40rem; margin-top: 24px; padding: 14px 14px 16px; background: var(--cream-2); border: 2.5px solid var(--ink); border-radius: var(--radius-inset); }
.doc-callout h2 { margin-top: 0; }
.doc-callout ul { margin-top: 8px; }
.doc table { width: 100%; margin-top: 12px; border-collapse: collapse; font-size: 1rem; line-height: 1.45; }

/* Tables become one card per row below 720 pt, so 320 pt never scrolls sideways. Roles keep the table meaning for VoiceOver. */
@media (max-width: 719px) {
  .doc table, .doc tbody, .doc tr, .doc th, .doc td { display: block; }
  .doc thead { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); }
  .doc tr { padding: 12px 14px; background: var(--cream-2); border: 2.5px solid var(--ink); border-radius: var(--radius-inset); }
  .doc tr + tr { margin-top: 12px; }
  .doc td { padding-top: 8px; }
  .doc td:first-child { padding-top: 0; font: 400 1.0625rem/1.25 var(--display); }
  .doc td + td::before { content: attr(data-label); display: block; font-size: var(--size-small); font-weight: 600; line-height: 1.35; letter-spacing: .08em; text-transform: uppercase; color: var(--text-cream-2); }
}
@media (min-width: 720px) {
  .doc th, .doc td { padding: 10px 12px 10px 0; text-align: left; vertical-align: top; border-bottom: 2px solid var(--cream-3); }
  .doc th { font-size: var(--size-small); font-weight: 600; letter-spacing: .08em; text-transform: uppercase; color: var(--text-cream-2); border-bottom-color: var(--ink); }
  .doc td:first-child { font-weight: 600; }
}

@media (min-width: 600px) {
  .hero__stage::after { background:
    linear-gradient(to top, var(--night-2), rgba(33, 23, 47, 0) 30%),
    linear-gradient(to bottom, var(--night-2), rgba(33, 23, 47, 0) 8%),
    linear-gradient(to right, var(--night-2), rgba(33, 23, 47, 0) 16%, rgba(33, 23, 47, 0) 84%, var(--night-2)); }
  .shots { grid-template-columns: 1fr 1fr; align-items: start; }
  .shots--style img:first-child { grid-row: span 2; }
  .nav__bar { padding-top: 0; }
}
@media (min-width: 760px) {
  .nav__bar { flex-wrap: nowrap; column-gap: 24px; padding-block: 4px; }
  .nav__brand { font-size: 1.0625rem; }
  .nav__links { order: 0; flex: 1; justify-content: center; margin: 0; padding: 0; overflow: visible; -webkit-mask-image: none; mask-image: none; }
  .nav .cta { order: 0; margin-left: 0; }
}
@media (min-width: 720px) {
  .steps { grid-template-columns: repeat(3, 1fr); }
  .steps li { grid-template-columns: 1fr; }
  .steps li::before { grid-row: auto; margin-bottom: 8px; text-align: left; }
  .cards { grid-template-columns: 1fr 1fr; }
  .doc { margin-bottom: 40px; padding: 48px 48px 56px; border: 3px solid var(--ink); border-top-width: 4px; border-radius: var(--radius-sheet); }
}
@media (min-width: 960px) {
  :root { --section-y: 88px; }
  .hero { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr); column-gap: 24px; align-items: center; max-width: 1180px; margin-inline: auto; padding: 16px 32px 40px; }
  .hero__stage { width: 100%; max-width: none; height: auto; aspect-ratio: 1227 / 1305; }
  .hero__copy { margin-top: 0; padding: 0; text-align: left; }
  .lede { margin-inline: 0; }
  .badge { margin-inline: 0; }
}
