/* RAW Freestyle. Colors are the app's own (factory/app/Shared/Theme.swift). */
:root {
  --ink: #0C0B0B;
  --panel: #171616;
  --line: rgba(245, 240, 230, 0.12);
  --bone: #F5F0E6;
  --bone-dim: rgba(245, 240, 230, 0.62);
  --bone-faint: rgba(245, 240, 230, 0.38);
  --rec: #FF3B30;
  --display: "Anton", "Impact", "Haettenschweiler", "Arial Narrow Bold", sans-serif;
  --body: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --gutter: clamp(16px, 5vw, 56px);
  --max: 1160px;
  color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--ink);
  color: var(--bone);
  font: 400 17px/1.55 var(--body);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
h1, h2, h3, p { margin: 0; }
a { color: inherit; }
strong { font-weight: 600; }

.skip { position: absolute; left: -999px; top: 8px; background: var(--bone); color: var(--ink); padding: 8px 12px; z-index: 10; }
.skip:focus { left: 8px; }
:focus-visible { outline: 2px solid var(--rec); outline-offset: 3px; }

main > section { max-width: var(--max); margin: 0 auto; padding: clamp(64px, 10vw, 120px) var(--gutter); }

.display { font-family: var(--display); font-weight: 400; text-transform: uppercase; letter-spacing: 0.005em; line-height: 0.92; }
.red { color: var(--rec); }
.muted { color: var(--bone-faint); }
.center { text-align: center; }
.eyebrow { display: inline-flex; align-items: center; gap: 10px; font-size: 13px; font-weight: 600; letter-spacing: 0.14em; text-transform: uppercase; color: var(--bone-dim); }
.section-title { font-family: var(--display); font-weight: 400; text-transform: uppercase; font-size: clamp(40px, 7vw, 76px); line-height: 0.95; }
.lede { font-size: clamp(18px, 2.1vw, 21px); color: var(--bone-dim); max-width: 34ch; }

/* NAV */
.nav {
  position: sticky; top: 0; z-index: 5;
  display: flex; align-items: center; justify-content: space-between;
  padding: 14px var(--gutter);
  padding-top: max(14px, env(safe-area-inset-top));
  background: rgba(12, 11, 11, 0.82);
  backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--line);
}
.wordmark { position: relative; font-family: var(--display); font-size: 30px; line-height: 1; text-decoration: none; padding-right: 12px; }
.wordmark .dot { position: absolute; right: 0; top: -2px; width: 9px; height: 9px; border-radius: 50%; background: var(--rec); }
.wordmark.small { font-size: 22px; }

/* BUTTONS */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  min-height: 48px; padding: 0 22px;
  background: var(--rec); color: #fff;
  font: 800 15px/1 var(--body); letter-spacing: 0.06em; text-transform: uppercase; text-decoration: none;
  border-radius: 999px; border: 0; cursor: pointer;
  transition: transform .15s ease, background .15s ease;
}
.btn:hover { transform: translateY(-1px); background: #ff5249; }
.btn-small { min-height: 40px; padding: 0 16px; font-size: 13px; }
.btn-big { min-height: 60px; padding: 0 36px; font-size: 17px; }
.btn-ghost { background: transparent; color: var(--bone); box-shadow: inset 0 0 0 1.5px var(--bone-faint); }
.btn-ghost:hover { background: rgba(245, 240, 230, 0.06); }
.btn[aria-disabled="true"] { background: rgba(245, 240, 230, 0.08); color: var(--bone-faint); cursor: default; transform: none; }

/* HERO */
.hero {
  display: grid; grid-template-columns: 1.1fr 0.9fr; gap: clamp(32px, 6vw, 80px); align-items: center;
  padding-top: clamp(40px, 7vw, 96px) !important;
}
.hero h1 { font-size: clamp(60px, 8.2vw, 112px); margin: 18px 0 22px; }
.hero h1 .line { display: block; white-space: nowrap; }
.rec-dot { width: 10px; height: 10px; border-radius: 50%; background: var(--rec); box-shadow: 0 0 0 0 rgba(255, 59, 48, .6); animation: pulse 1.6s ease-out infinite; }
@keyframes pulse { 0% { box-shadow: 0 0 0 0 rgba(255,59,48,.55); } 80%, 100% { box-shadow: 0 0 0 10px rgba(255,59,48,0); } }

.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; opacity: 0; }

/* WAITLIST */
.waitlist { margin-top: 32px; max-width: 520px; scroll-margin-top: 110px; }
.waitlist-row { display: flex; gap: 8px; padding: 6px; border-radius: 999px; background: var(--panel); box-shadow: inset 0 0 0 1.5px var(--line); transition: box-shadow .15s ease; }
.waitlist-row:focus-within { box-shadow: inset 0 0 0 1.5px var(--rec); }
.waitlist input[type="email"] { flex: 1; min-width: 0; height: 48px; padding: 0 16px; border: 0; background: transparent; color: var(--bone); font: 500 16px/1 var(--body); outline: none; }
.waitlist input::placeholder { color: var(--bone-faint); }
.waitlist .btn { flex: none; }
.waitlist-note { margin-top: 10px; padding-left: 18px; font-size: 14px; color: var(--bone-faint); }
.waitlist-note.ok { color: var(--bone); }
.waitlist-note.ok::before { content: "\25CF  "; color: var(--rec); }
.waitlist-note.err { color: #ff8a82; }
.waitlist.done .waitlist-row { opacity: .5; pointer-events: none; }

.stores { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 28px; scroll-margin-top: 96px; }
.store {
  display: inline-flex; align-items: center; gap: 12px;
  min-width: 196px; min-height: 60px; padding: 8px 20px 8px 16px;
  background: var(--bone); color: var(--ink);
  border-radius: 14px; text-decoration: none;
  transition: transform .15s ease;
}
.store:hover { transform: translateY(-1px); }
.store-icon { width: 28px; height: 28px; flex: none; }
.store-text { display: flex; flex-direction: column; line-height: 1.15; }
.store-text small { font-size: 11px; font-weight: 500; letter-spacing: 0.02em; }
.store-text strong { font-size: 19px; font-weight: 800; letter-spacing: -0.01em; }
.store[aria-disabled="true"] { background: transparent; color: var(--bone-dim); box-shadow: inset 0 0 0 1.5px var(--line); cursor: default; transform: none; }

.browser-play { display: inline-flex; align-items: center; gap: 12px; margin-top: 18px; font-size: 15px; color: var(--bone-dim); text-decoration: none; }
.browser-play-icon { display: grid; place-items: center; width: 32px; height: 32px; border-radius: 50%; box-shadow: inset 0 0 0 1.5px var(--bone-faint); font-size: 11px; padding-left: 2px; }
.browser-play:not([aria-disabled="true"]) { color: var(--bone); }
.browser-play:not([aria-disabled="true"]):hover strong { text-decoration: underline; }
.tag { display: inline-block; margin-left: 6px; padding: 2px 8px; border-radius: 999px; background: rgba(245,240,230,0.08); font-size: 12px; font-weight: 600; letter-spacing: 0.04em; text-transform: uppercase; color: var(--bone-faint); vertical-align: 1px; }
.browser-play:not([aria-disabled="true"]) .tag { display: none; }

/* PHONE MOCK */
.hero-phone { display: flex; justify-content: center; }
.phone {
  position: relative; width: min(330px, 78vw); aspect-ratio: 9 / 19.5;
  border-radius: 46px; padding: 10px; background: #1f1d1d;
  box-shadow: 0 0 0 1px rgba(255,255,255,.07), 0 40px 120px -20px rgba(255, 59, 48, .28), 0 30px 60px -30px #000;
  display: grid; grid-template-rows: 60% 40%; overflow: hidden;
}
.phone-cam { position: relative; border-radius: 37px 37px 0 0; overflow: hidden; background: radial-gradient(120% 90% at 50% 30%, #3a3433 0%, #1c1918 55%, #0f0d0d 100%); }
.cam-figure {
  position: absolute; left: 50%; bottom: -6%; width: 64%; aspect-ratio: 1 / 1.1; transform: translateX(-50%);
  background:
    radial-gradient(circle at 50% 30%, #4a4240 0 24%, transparent 24.5%),
    radial-gradient(ellipse 50% 40% at 50% 100%, #3d3634 0 99%, transparent 100%);
  filter: blur(0.4px); opacity: .9;
}
.cam-bar { position: absolute; z-index: 2; top: 18px; left: 18px; right: 18px; display: flex; justify-content: space-between; align-items: center; }
.cam-stamp { font: 800 11px/1 var(--body); letter-spacing: 0.04em; color: var(--bone); text-shadow: 0 1px 4px rgba(0,0,0,.6); }
.cam-rec { display: inline-flex; align-items: center; gap: 6px; padding: 5px 9px; border-radius: 999px; background: rgba(255,59,48,.16); color: var(--rec); font: 800 11px/1 var(--body); letter-spacing: .08em; }
.cam-rec i { width: 7px; height: 7px; border-radius: 50%; background: var(--rec); animation: blink 1.2s steps(2) infinite; }
@keyframes blink { 50% { opacity: .25; } }
.cam-frame { position: absolute; inset: 52px 22px 22px; }
.cam-frame b { position: absolute; width: 18px; height: 18px; border-color: rgba(245,240,230,.4); border-style: solid; }
.cam-frame b:nth-child(1) { top: 0; left: 0; border-width: 2px 0 0 2px; }
.cam-frame b:nth-child(2) { top: 0; right: 0; border-width: 2px 2px 0 0; }
.cam-frame b:nth-child(3) { bottom: 0; left: 0; border-width: 0 0 2px 2px; }
.cam-frame b:nth-child(4) { bottom: 0; right: 0; border-width: 0 2px 2px 0; }
.cam-mode { position: absolute; z-index: 2; bottom: 14px; right: 18px; font: 800 11px/1 var(--body); letter-spacing: .1em; color: #FAC721; text-shadow: 0 1px 4px rgba(0,0,0,.6); }
.phone-panel { background: var(--ink); border-radius: 0 0 37px 37px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 8px; padding: 16px; text-align: center; }
.beat-dots { display: flex; gap: 14px; }
.beat-dots i { width: 13px; height: 13px; border-radius: 50%; background: var(--bone); opacity: .2; transition: opacity .08s linear; }
.beat-dots i:last-child { background: #FAC721; }
.beat-dots i.on { opacity: 1; }
.bar-count { font: 600 11px/1 var(--body); letter-spacing: .12em; text-transform: uppercase; color: var(--bone-faint); }
.prompt { font-family: var(--display); font-size: clamp(42px, 13vw, 56px); line-height: 1; letter-spacing: .01em; margin-top: 4px; }
.prompt.drop { animation: drop .35s cubic-bezier(.2,.9,.3,1.3); }
@keyframes drop { from { transform: translateY(-14px) scale(1.08); opacity: 0; } to { transform: none; opacity: 1; } }
.next { font-size: 12px; color: var(--bone-faint); letter-spacing: .04em; }
.next span { font-weight: 700; color: var(--bone-dim); }

/* HOW */
.steps { list-style: none; padding: 0; margin: 40px 0 0; display: grid; grid-template-columns: repeat(4, 1fr); gap: 1px; background: var(--line); border: 1px solid var(--line); border-radius: 20px; overflow: hidden; }
.steps li { background: var(--ink); padding: 28px 24px 32px; }
.step-n { font-family: var(--display); font-size: 22px; color: var(--rec); }
.steps h3 { font-size: 20px; font-weight: 800; margin: 14px 0 8px; letter-spacing: -0.01em; }
.steps p { color: var(--bone-dim); font-size: 15px; }

/* MODES */
.mode-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 16px; margin-top: 40px; }
.mode {
  position: relative; overflow: hidden;
  padding: clamp(24px, 3.5vw, 40px); border-radius: 22px;
  background: var(--panel); border: 1px solid var(--line);
  display: flex; flex-direction: column; gap: 14px; min-height: 260px;
}
.mode::before { content: ""; position: absolute; inset: 0 0 auto 0; height: 4px; background: var(--tint); }
.mode::after { content: ""; position: absolute; right: -60px; bottom: -60px; width: 200px; height: 200px; border-radius: 50%; background: var(--tint); opacity: .08; filter: blur(10px); }
.mode-chip { font: 700 12px/1 var(--body); letter-spacing: .14em; text-transform: uppercase; color: var(--tint); }
.mode-name { font-family: var(--display); font-weight: 400; text-transform: uppercase; font-size: clamp(36px, 5vw, 54px); line-height: .95; }
.mode-rule { font-size: clamp(17px, 1.9vw, 20px); line-height: 1.45; max-width: 30ch; }
.mode-score { margin-top: auto; font-size: 13px; color: var(--bone-faint); letter-spacing: .02em; }

/* CLIP */
.clip { display: grid; grid-template-columns: 1fr auto; gap: clamp(32px, 7vw, 96px); align-items: center; }
.clip-copy { display: flex; flex-direction: column; gap: 18px; align-items: flex-start; }
.clip-copy .section-title { margin-top: -4px; }
.clip-copy p:not(.eyebrow) { color: var(--bone-dim); max-width: 46ch; font-size: 18px; }
.clip-copy strong { color: var(--bone); }
.clip-copy .btn { margin-top: 8px; }
.clip-frame { width: min(260px, 64vw); aspect-ratio: 9 / 16; border-radius: 18px; overflow: hidden; display: grid; grid-template-rows: 60% 40%; box-shadow: 0 0 0 1px var(--line), 0 30px 80px -30px rgba(51,199,255,.35); transform: rotate(3deg); }
.clip-cam { position: relative; background: radial-gradient(120% 90% at 40% 30%, #33302f, #141212); }
.clip-cam .cam-figure { width: 70%; }
.clip-stamp { position: absolute; z-index: 2; top: 12px; left: 12px; font: 800 10px/1 var(--body); color: var(--bone); letter-spacing: .04em; }
.clip-mode { position: absolute; z-index: 2; top: 12px; right: 12px; font: 800 10px/1 var(--body); color: #33C7FF; letter-spacing: .08em; }
.clip-panel { background: var(--ink); display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 6px; }
.clip-bpm { font-family: var(--display); font-size: 58px; line-height: 1; color: #33C7FF; }
.clip-bpm small { font-size: 22px; }
.clip-note { font: 700 11px/1 var(--body); letter-spacing: .16em; text-transform: uppercase; color: var(--bone-faint); }

/* STREAK */
.streak { display: grid; grid-template-columns: 1.15fr 0.85fr; gap: clamp(32px, 6vw, 80px); align-items: center; }
.streak-copy { display: flex; flex-direction: column; gap: 18px; }
.streak-copy p { color: var(--bone-dim); font-size: 18px; max-width: 44ch; }
.streak-copy p.muted { color: var(--bone-faint); font-size: 15px; }
.grid-demo { display: grid; grid-template-columns: repeat(15, 1fr); grid-template-rows: repeat(7, 1fr); grid-auto-flow: column; gap: 4px; padding: 22px; border-radius: 20px; background: var(--panel); border: 1px solid var(--line); }
.grid-demo i { aspect-ratio: 1; border-radius: 3px; background: rgba(255,255,255,.08); }
.grid-demo i[data-l="1"] { background: rgba(255,59,48,.3); }
.grid-demo i[data-l="2"] { background: rgba(255,59,48,.55); }
.grid-demo i[data-l="3"] { background: rgba(255,59,48,.8); }
.grid-demo i[data-l="4"] { background: var(--rec); }
.grid-demo i.today { box-shadow: 0 0 0 1px rgba(245,240,230,.9); }
.grid-demo i.future { background: transparent; }

/* PRICING */
.pricing { text-align: center; }
.pricing .lede { margin: 14px auto 0; }
.plans { display: grid; grid-template-columns: repeat(2, minmax(0, 360px)); justify-content: center; gap: 16px; margin-top: 40px; text-align: left; }
.plan { display: flex; flex-direction: column; gap: 16px; padding: 32px; border-radius: 22px; background: var(--panel); border: 1px solid var(--line); }
.plan-pro { box-shadow: inset 0 0 0 1.5px rgba(255,59,48,.5); }
.plan-name { font: 800 14px/1 var(--body); letter-spacing: .14em; text-transform: uppercase; color: var(--bone-dim); }
.plan-pro .plan-name { color: var(--rec); }
.plan-price { font-family: var(--display); font-size: 56px; line-height: 1; }
.placeholder-price { font-size: 40px; color: var(--bone-faint); }
.plan-list { list-style: none; padding: 0; margin: 0 0 8px; display: grid; gap: 10px; }
.plan-list li { font-size: 15px; }
.placeholder { padding: 8px 12px; border-radius: 10px; border: 1.5px dashed rgba(250, 199, 33, .55); color: #FAC721; font: 600 12px/1.3 var(--body); letter-spacing: .04em; }
.plan .btn { align-self: stretch; }

/* FINAL */
.final { text-align: center; display: flex; flex-direction: column; align-items: center; gap: 36px; padding-bottom: clamp(80px, 12vw, 140px) !important; }
.final-title { font-size: clamp(56px, 11vw, 128px); }

/* FOOTER */
.footer { display: flex; flex-wrap: wrap; gap: 12px 28px; align-items: center; justify-content: space-between; padding: 28px var(--gutter); padding-bottom: max(28px, env(safe-area-inset-bottom)); border-top: 1px solid var(--line); color: var(--bone-faint); font-size: 14px; }

/* PHONE WIDTHS */
@media (max-width: 900px) {
  .hero { grid-template-columns: 1fr; text-align: left; }
  .hero-phone { order: 2; }
  .steps { grid-template-columns: repeat(2, 1fr); }
  .clip, .streak { grid-template-columns: 1fr; }
  .clip-frame { justify-self: center; }
}
@media (max-width: 600px) {
  body { font-size: 16px; }
  .steps { grid-template-columns: 1fr; }
  .mode-grid { grid-template-columns: 1fr; }
  .mode { min-height: 0; }
  .phone { width: min(280px, 74vw); border-radius: 40px; }
  .phone-cam { border-radius: 31px 31px 0 0; }
  .phone-panel { border-radius: 0 0 31px 31px; }
  .plans { grid-template-columns: 1fr; }
  .stores { flex-direction: column; align-items: stretch; }
  .waitlist-row { flex-direction: column; border-radius: 22px; padding: 8px; }
  .waitlist input[type="email"] { text-align: center; }
  .waitlist-note { padding-left: 0; text-align: center; }
  .store { min-width: 0; }
  .grid-demo { padding: 14px; gap: 3px; }
  .footer { justify-content: flex-start; }
}

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