:root {
  color-scheme: dark;
  --bg: #110e0d;
  --panel: #282321;
  --line: #51463f;
  --cream: #f4e8d1;
  --muted: #a99b8c;
  --amber: #ffb000;
  --red: #ff3b2f;
  --green: #42e88d;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 20px; }
body { margin: 0; background: radial-gradient(circle at 50% -10%, #33251e 0, var(--bg) 42%); color: var(--cream); font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif; }
a { color: inherit; text-decoration: none; }
.page-shell { width: min(1120px, calc(100% - 40px)); margin: auto; }
.topbar { min-height: 92px; display: flex; align-items: center; justify-content: space-between; border-bottom: 1px solid #342c28; }
.wordmark { display: inline-flex; align-items: center; gap: 10px; font-weight: 950; letter-spacing: .28em; }
.wordmark i { width: 8px; height: 8px; border-radius: 50%; background: var(--red); box-shadow: 0 0 13px var(--red); }
.wordmark--small { font-size: 18px; }
.nav-links { display: flex; gap: 28px; color: var(--muted); font-size: 13px; font-weight: 800; }
.nav-links a:hover { color: var(--amber); }
.nav-links .nav-download { color: var(--amber); }
.download-page .topbar { min-height: 76px; }
.hero { max-width: 820px; margin: auto; padding: 48px 0 58px; text-align: center; }
.app-intro { display: flex; align-items: center; justify-content: center; gap: 20px; margin-bottom: 28px; text-align: left; }
.app-icon { display: block; flex: 0 0 auto; width: 96px; height: 96px; border-radius: 22px; box-shadow: 0 12px 35px #0006; }
.app-intro .eyebrow { margin-bottom: 8px; font-size: 10px; letter-spacing: .2em; }
.app-name { margin: 0; font-size: 25px; font-weight: 850; letter-spacing: -.03em; }
.eyebrow { margin: 0 0 18px; color: var(--amber); font-size: 12px; font-weight: 950; letter-spacing: .28em; }
h1 { max-width: 700px; margin: 0; font-size: clamp(54px, 7vw, 92px); line-height: .94; letter-spacing: -.055em; }
h1 span { color: var(--green); }
.hero h1 { margin-inline: auto; font-size: clamp(42px, 6vw, 74px); line-height: 1.04; }
.lead { margin: 20px 0 28px; color: var(--muted); font-size: 19px; line-height: 1.5; }
.lead strong { color: var(--cream); font-weight: 650; }
.store-row { width: 100%; max-width: 610px; margin-inline: auto; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
.store-button { min-width: 0; min-height: 112px; padding: 20px 25px; border: 2px solid var(--cream); border-radius: 16px; background: var(--cream); color: var(--bg); display: flex; align-items: center; justify-content: space-between; gap: 16px; text-align: left; box-shadow: 0 9px 30px #0004; transition: background .15s ease, border-color .15s ease; }
.store-copy { display: grid; gap: 3px; }
.store-copy small { font-size: 12px; font-weight: 650; }
.store-copy b { font-size: 28px; line-height: 1.1; letter-spacing: -.035em; }
.store-copy > span { color: #66584a; font-size: 12px; }
.store-download-icon { width: 28px; height: 28px; flex: 0 0 auto; }
.store-button:hover { border-color: var(--amber); background: #ffe0a4; }
.store-button:focus-visible { outline: 2px solid var(--amber); outline-offset: 4px; }
.download-note { margin: 18px 0 0; color: var(--muted); font-size: 14px; line-height: 1.5; }
.discover-link { display: inline-flex; gap: 12px; align-items: center; margin-top: 34px; padding: 8px 0; color: var(--cream); font-size: 13px; }
.discover-link:hover { color: var(--amber); }
.gameplay { padding-top: 48px; border-top: 1px solid #342c28; }
.section-heading h2 { margin: 0; font-size: clamp(28px, 4vw, 42px); letter-spacing: -.035em; }
.steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; padding: 30px 0 40px; }
.steps article { min-height: 220px; padding: 28px; border: 1px solid var(--line); border-radius: 24px; background: #211c1a; }
.steps span { color: var(--red); font: 900 14px monospace; }
.steps h3 { margin: 45px 0 8px; font-size: 25px; }
.steps p, .friends-copy p { color: var(--muted); line-height: 1.55; }
.friends-callout { margin: 30px 0 100px; padding: 50px; border-radius: 30px; background: var(--amber); color: #21140b; display: grid; grid-template-columns: 1fr 1fr; gap: 55px; align-items: end; }
.friends-callout .eyebrow { color: #6b3900; }
.friends-callout h2 { margin: 0; font-size: clamp(32px, 4vw, 50px); line-height: 1.05; }
.friends-copy p { color: #51300f; font-weight: 700; }
.callout-link { display: inline-flex; gap: 20px; align-items: center; padding: 12px 0 6px; border-bottom: 2px solid currentColor; font-weight: 850; }
footer { min-height: 90px; padding: 30px max(20px, calc((100% - 1120px) / 2)); border-top: 1px solid #342c28; display: flex; gap: 24px; color: #786c64; font-size: 12px; }
footer span { margin-right: auto; }
.legal { width: min(760px, calc(100% - 40px)); margin: 70px auto 110px; }
.legal h1 { font-size: clamp(42px, 7vw, 70px); }
.legal h2 { margin-top: 42px; color: var(--amber); font-size: 20px; }
.legal p, .legal li { color: var(--muted); line-height: 1.7; }
.invite-shell { min-height: calc(100vh - 180px); display: grid; place-items: center; padding: 60px 20px; }
.invite-card { width: min(520px, 100%); padding: 42px; border: 3px solid var(--line); border-radius: 32px; background: var(--panel); box-shadow: 0 30px 70px #0008; text-align: center; }
.invite-card h1 { margin: 28px 0 14px; font-size: clamp(38px, 8vw, 58px); }
.invite-card p { color: var(--muted); line-height: 1.6; }
.invite-card .app-icon { width: 64px; height: 64px; margin: 0 auto 20px; border-radius: 16px; }
.invite-card .store-row { grid-template-columns: 1fr; margin-top: 24px; }
.invite-card .store-button { min-height: 90px; padding: 14px 20px; }
.invite-card .invitation-details { margin-top: 30px; padding-top: 22px; border-top: 1px solid var(--line); }
.invitation-details .invite-code { margin: 16px 0; }
.invite-code { margin: 28px 0; padding: 18px; border: 2px dashed #4f7d63; border-radius: 16px; color: var(--green); background: #14251b; font: 900 28px monospace; letter-spacing: .18em; }
.primary-link { display: block; margin-top: 12px; padding: 18px; border-radius: 14px; background: var(--amber); color: #21140b; font-weight: 950; }
.secondary-link { display: block; margin-top: 12px; padding: 16px; color: var(--muted); font-weight: 800; }
@media (max-width: 760px) {
  .nav-links { display: none; }
  .download-page .topbar { min-height: 64px; }
  .download-page .nav-links { display: flex; }
  .download-page .nav-links a:not(.nav-download) { display: none; }
  .nav-download { font-size: 12px; }
  .wordmark--small { font-size: 16px; letter-spacing: .2em; }
  .hero { padding: 28px 0 36px; }
  .app-intro { gap: 14px; margin-bottom: 20px; }
  .app-icon { width: 64px; height: 64px; border-radius: 16px; }
  .app-intro .eyebrow { max-width: 200px; font-size: 8px; letter-spacing: .13em; }
  .app-name { font-size: 20px; }
  .hero h1 { font-size: clamp(34px, 8vw, 54px); }
  .lead { margin: 16px 0 22px; font-size: 16px; }
  .store-row { grid-template-columns: 1fr; max-width: 420px; gap: 10px; }
  .store-button { min-height: 86px; padding: 13px 22px; border-radius: 14px; }
  .store-copy b { font-size: 25px; }
  .store-copy small, .store-copy > span { font-size: 11px; }
  .download-note { max-width: 300px; margin: 16px auto 0; font-size: 12px; }
  .discover-link { margin-top: 22px; }
  .gameplay { padding-top: 34px; }
  .steps { grid-template-columns: 1fr; }
  .steps article { min-height: 170px; }
  .steps h3 { margin-top: 28px; }
  .friends-callout { grid-template-columns: 1fr; padding: 34px; gap: 18px; }
  .invite-shell { padding: 28px 20px; }
  .invite-card { padding: 24px; }
  .invite-card h1 { font-size: 34px; }
  .invite-card .invite-code { font-size: clamp(16px, 5.5vw, 28px); }
  footer { flex-wrap: wrap; }
  footer span { width: 100%; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .store-button { transition: none; }
}
