/* The website of the app. It borrows the app's own paper, ink and terracotta (DESIGN.md, section 2) and keeps its manner:
   type set on paper, hairlines, no cards, quiet motion. Day and evening follow the visitor's system. */

:root {
  color-scheme: light dark;
  --paper: #F7ECDD; --paper-deep: #EFDDC6; --paper-light: #FBF4E9;
  --ink: #2A251F; --ink-soft: #675C51; --ink-faint: #A89A89; --hairline: rgba(42,37,31,.13);
  --sage: #8FA283; --green: #6E8465; --peach: #F1CDA9; --apricot: #E68C3F;
  --terracotta: #C8502F; --clay: #9C4A2C; --blue: #56748A; --ochre: #B9822B;
  --on-fill: #fff; --thread: #2B2926; --shade: 42,37,31;
  --serif: "New York", ui-serif, "Iowan Old Style", "Palatino Linotype", Georgia, serif;
  --sans: -apple-system, system-ui, "SF Pro Text", "Segoe UI", Roboto, sans-serif;
  --gutter: clamp(20px, 5vw, 56px);
}
@media (prefers-color-scheme: dark) {
  :root {
    --paper: #1F1B17; --paper-deep: #181411; --paper-light: #2A251F;
    --ink: #EFDDC6; --ink-soft: #BBAE9D; --ink-faint: #7D7163; --hairline: rgba(239,221,198,.14);
    --sage: #71856A; --green: #93AD88; --peach: #B88F6B; --apricot: #E39248;
    --terracotta: #E4744F; --clay: #D69370; --blue: #8FB0C6; --ochre: #D9A24A;
    --on-fill: #1F1B17; --thread: #CBC4B8; --shade: 5,4,3;
  }
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0; color: var(--ink); font: 17px/1.6 var(--sans);
  background: linear-gradient(180deg, var(--paper-light) 0, var(--paper) 520px, var(--paper-deep) 100%) fixed var(--paper);
  overflow-x: hidden;
}
a { color: var(--terracotta); text-underline-offset: 3px; }
a:hover { color: var(--clay); }
:focus-visible { outline: 2px solid var(--terracotta); outline-offset: 3px; border-radius: 4px; }
::selection { background: color-mix(in srgb, var(--terracotta) 28%, transparent); }
.wrap { width: min(1080px, 100% - 2 * var(--gutter)); margin-inline: auto; }
.skip { position: absolute; left: -999px; top: 8px; background: var(--ink); color: var(--paper); padding: 8px 14px; border-radius: 8px; z-index: 50; }
.skip:focus { left: 8px; }

h1, h2, h3 { font-family: var(--serif); font-weight: 500; letter-spacing: -.012em; margin: 0; }
h1 em, h2 em { color: var(--terracotta); font-style: italic; }
.eyebrow { font: 600 11px/1.3 var(--sans); letter-spacing: .13em; text-transform: uppercase; color: var(--clay); margin: 0 0 18px; }

/* ---------- top bar ---------- */
.bar { position: relative; z-index: 5; display: flex; align-items: center; justify-content: space-between; padding: 22px 0; }
.bar .name { font: 500 21px/1 var(--serif); color: var(--ink); text-decoration: none; display: inline-flex; align-items: center; gap: 10px; }
.bar .mark { width: 26px; height: 20px; flex: none; }
.bar nav { display: flex; gap: clamp(14px, 3vw, 30px); font-size: 14.5px; }
.bar nav a { color: var(--ink-soft); text-decoration: none; }
.bar nav a:hover, .bar nav a[aria-current] { color: var(--ink); }

/* ---------- the drifting circles behind the first screen ---------- */
.field { position: absolute; inset: 0 0 auto 0; height: 980px; overflow: hidden; pointer-events: none; z-index: 0; }
.orb { position: absolute; border-radius: 50%; filter: blur(2px); will-change: transform; animation: drift var(--t, 26s) ease-in-out infinite alternate; }
.orb.a { width: 440px; height: 440px; left: -140px; top: 90px; background: radial-gradient(circle at 35% 35%, color-mix(in srgb, var(--sage) 55%, transparent), transparent 70%); --t: 31s; }
.orb.b { width: 360px; height: 360px; right: -90px; top: 40px; background: radial-gradient(circle at 60% 40%, color-mix(in srgb, var(--peach) 75%, transparent), transparent 70%); --t: 24s; animation-delay: -9s; }
.orb.c { width: 240px; height: 240px; right: 22%; top: 520px; background: radial-gradient(circle at 50% 50%, color-mix(in srgb, var(--apricot) 32%, transparent), transparent 70%); --t: 28s; animation-delay: -4s; }
.orb.d { width: 520px; height: 520px; left: 18%; top: 560px; background: radial-gradient(circle, rgba(var(--shade), .07), transparent 68%); --t: 36s; animation-delay: -15s; }
@keyframes drift { from { transform: translate3d(0, 0, 0) scale(1); } to { transform: translate3d(34px, -26px, 0) scale(1.07); } }
.thread { position: absolute; left: 0; top: 150px; width: 100%; height: 520px; opacity: .5; }
.thread path { fill: none; stroke: var(--thread); stroke-width: .8; stroke-dasharray: 1600; stroke-dashoffset: 1600; animation: draw 14s ease-out .6s forwards; }
@keyframes draw { to { stroke-dashoffset: 0; } }

/* ---------- first screen ---------- */
.hero { position: relative; padding: clamp(24px, 5vw, 64px) 0 clamp(56px, 9vw, 120px); }
.hero .wrap { position: relative; z-index: 1; display: grid; gap: clamp(36px, 6vw, 72px); align-items: center; }
@media (min-width: 900px) { .hero .wrap { grid-template-columns: 1.05fr .95fr; } }
.hero h1 { font-size: clamp(46px, 7.4vw, 86px); line-height: 1.02; }
.hero h1 span { display: block; }
.lead { font-size: clamp(17px, 2vw, 19.5px); color: var(--ink-soft); max-width: 33em; margin: 26px 0 0; }
.soon { display: flex; flex-wrap: wrap; align-items: center; gap: 14px 22px; margin-top: 34px; }
.pill { display: inline-flex; align-items: center; gap: 10px; padding: 14px 24px; border-radius: 999px; background: var(--ink); color: var(--paper); font: 600 15.5px/1 var(--sans); }
.pill i { width: 8px; height: 8px; border-radius: 50%; background: var(--apricot); animation: breathe 2.8s ease-in-out infinite; }
@keyframes breathe { 50% { transform: scale(1.5); opacity: .55; } }
.small { font-size: 14px; color: var(--ink-soft); margin: 0; }

/* ---------- the phone ---------- */
.stage { display: grid; gap: 22px; justify-items: center; }
.phone-wrap { width: 300px; height: 625px; }
/* The frame is drawn to the measures of an iPhone 18 Pro (body 436 x 908 pt, screen 402 x 874 pt, corners 80 pt; the action
   key, two volume keys and the side key where they sit), at 300 px wide. It is dark titanium in both appearances. */
.phone {
  position: relative; width: 300px; height: 625px; border-radius: 55px; padding: 12px;
  background: linear-gradient(145deg, #6b6660 0%, #3a3733 18%, #24221f 50%, #33302c 82%, #5a554f 100%);
  box-shadow: 0 40px 70px -28px rgba(var(--shade), .5), 0 8px 18px -8px rgba(var(--shade), .35),
    inset 0 0 0 1px rgba(255,255,255,.22), inset 0 0 0 3px #2a2825, inset 0 0 0 4px rgba(0,0,0,.55);
  transform: rotate(1.5deg); transition: transform .8s ease;
}
.phone:hover { transform: rotate(0); }
.key { position: absolute; z-index: -1; width: 5px; border-radius: 2px; background: linear-gradient(180deg, #5f5a54, #34312d 22%, #2b2926 78%, #4d4944); }
.key.action { left: -2.5px; top: 110px; height: 23px; }
.key.up { left: -2.5px; top: 152px; height: 44px; }
.key.down { left: -2.5px; top: 206px; height: 44px; }
.key.side { right: -2.5px; top: 180px; height: 69px; }
.screen { position: relative; height: 100%; border-radius: 43px; overflow: hidden; background: #1F1B17; box-shadow: 0 0 0 1.5px #0a0908; }
.scene { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; opacity: 0; visibility: hidden; transition: opacity .6s ease, visibility 0s .6s; }
.scene.on { opacity: 1; visibility: visible; transition: opacity .6s ease; }

.steps { display: grid; grid-template-columns: repeat(4, 1fr); gap: 6px; width: 300px; }
.steps button { all: unset; box-sizing: border-box; cursor: pointer; position: relative; padding: 10px 2px 0; font: 600 11.5px/1.25 var(--sans); color: var(--ink-faint); transition: color .3s; }
.steps button::before { content: ""; position: absolute; left: 0; right: 0; top: 0; height: 2px; border-radius: 2px; background: var(--hairline); }
.steps button::after { content: ""; position: absolute; left: 0; top: 0; height: 2px; width: 0; border-radius: 2px; background: var(--terracotta); }
.steps button[aria-current="true"] { color: var(--ink); }
.steps button[aria-current="true"]::after { animation: fill var(--dur, 6s) linear forwards; }
.steps.paused button[aria-current="true"]::after { animation: none; width: 100%; }
@keyframes fill { to { width: 100%; } }
.steps button:focus-visible { outline: 2px solid var(--terracotta); outline-offset: 4px; }
.fine { font-size: 12.5px; color: var(--ink-faint); margin: 0; text-align: center; }

/* ---------- sections ---------- */
section { position: relative; z-index: 1; }
.block { padding: clamp(56px, 8vw, 104px) 0; border-top: 1px solid var(--hairline); }
.block h2 { font-size: clamp(34px, 5vw, 56px); line-height: 1.06; max-width: 14em; }
.block .lead { margin-top: 20px; }
.cols { display: grid; gap: clamp(28px, 5vw, 64px); margin-top: clamp(32px, 5vw, 56px); }
@media (min-width: 820px) { .cols.three { grid-template-columns: repeat(3, 1fr); } .cols.two { grid-template-columns: 1fr 1fr; align-items: start; } }
.step { border-top: 1px solid var(--hairline); padding-top: 18px; }
.step .num { font: 600 13px/1 var(--sans); letter-spacing: .1em; color: var(--apricot); }
.step h3 { font-size: 26px; line-height: 1.15; margin: 14px 0 10px; }
.step p { margin: 0; color: var(--ink-soft); font-size: 16px; }
.marked { list-style: none; margin: 0; padding: 0; }
.marked li { display: grid; grid-template-columns: 22px 1fr; gap: 6px; padding: 16px 0; border-top: 1px solid var(--hairline); font: 500 21px/1.3 var(--serif); }
.marked li::before { content: ""; width: 9px; height: 9px; margin-top: 10px; border-radius: 50%; background: var(--terracotta); }
.marked li:nth-child(2)::before { background: var(--green); }
.marked li:nth-child(3)::before { background: var(--blue); }
.marked small { display: block; margin-top: 4px; font: 400 15px/1.5 var(--sans); color: var(--ink-soft); }
.notes { margin: 0; padding: 0; list-style: none; }
.notes li { display: flex; gap: 14px; align-items: baseline; padding: 14px 0; border-top: 1px solid var(--hairline); font-size: 16.5px; color: var(--ink-soft); }
.notes li::before { content: ""; width: 8px; height: 8px; flex: none; border-radius: 50%; background: var(--sage); transform: translateY(-1px); }
.notes .tag { margin-top: 14px; border: 0; font: italic 18px/1.4 var(--serif); color: var(--terracotta); }
.notes .tag::before { display: none; }
.promise { list-style: none; margin: 28px 0 0; padding: 0; }
.promise li { padding: 14px 0; border-top: 1px solid var(--hairline); font: 500 21px/1.3 var(--serif); }
.promise li:last-child { border-bottom: 1px solid var(--hairline); }
.quiet { font-size: 15px; color: var(--ink-soft); max-width: 40em; margin: 26px 0 0; }

.close { padding: clamp(64px, 9vw, 120px) 0; border-top: 1px solid var(--hairline); text-align: center; }
.close h2 { font-size: clamp(34px, 5vw, 56px); line-height: 1.08; margin-inline: auto; }
.close .soon { justify-content: center; }
footer { border-top: 1px solid var(--hairline); padding: 30px 0 56px; color: var(--ink-soft); font-size: 14px; }
footer .wrap { display: flex; flex-wrap: wrap; gap: 10px 28px; justify-content: space-between; }
footer nav { display: flex; gap: 22px; }
footer a { color: var(--ink-soft); }
footer p { margin: 0; }

/* ---------- reveal on scroll ---------- */
.js .reveal { opacity: 0; transform: translateY(22px); transition: opacity .9s ease, transform .9s cubic-bezier(.2,.7,.2,1); }
.js .reveal.in { opacity: 1; transform: none; }
.js .reveal.in.d1 { transition-delay: .1s; } .js .reveal.in.d2 { transition-delay: .2s; }

/* ---------- the legal pages ---------- */
.doc { max-width: 680px; margin: 0 auto; padding: clamp(24px, 5vw, 56px) 0 96px; }
.doc h1 { font-size: clamp(40px, 6vw, 58px); line-height: 1.05; margin-bottom: 10px; }
.doc h2 { font-size: 24px; line-height: 1.25; margin: 42px 0 8px; padding-top: 26px; border-top: 1px solid var(--hairline); }
.doc p, .doc li { color: var(--ink-soft); }
.doc ul { padding-left: 22px; }
.doc li { margin: 6px 0; }
.doc .note { font-size: 14px; color: var(--ink-faint); }
.doc code { font-size: 13.5px; background: var(--hairline); padding: 2px 6px; border-radius: 5px; }

@media (max-width: 340px) { .phone-wrap { height: 565px; } .phone { transform: scale(.9) rotate(1.5deg); transform-origin: top center; } }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .orb, .thread path, .pill i { animation: none !important; }
  .thread path { stroke-dashoffset: 0; }
  .js .reveal { opacity: 1; transform: none; transition: none; }
  .phone, .phone:hover { transform: none; }
}
