/* Ravel. The app's tokens: Linen canvas, ink, signal; Onest for all text. */
@font-face {
  font-family: "Onest";
  src: url("/fonts/Onest.ttf") format("truetype");
  font-weight: 100 900;
  font-display: swap;
}

:root {
  --canvas: #EFE8DC;
  --ink: #4A4037;
  --ink2: #5E544A;
  --ink3: #655A4E;
  --fill: #E5DCCE;
  --sheet: #FCF9F3;
  --signal: #D9622F;
  --signal-ink: #A9441A;
  --hair: rgb(74 64 55 / 0.12);
  --lift: color-mix(in srgb, var(--canvas) 40%, white);
  --shadow: 74 64 55;
  --bezel: #121113;
  --grain: 0.045;
  --gutter: max(clamp(20px, 5vw, 56px), env(safe-area-inset-left), env(safe-area-inset-right));
  --wrap: 1040px;
  --ease: cubic-bezier(0.32, 0.72, 0, 1);
  --section: 80px;
  --rim: #3A3734;
  color-scheme: light dark;
}
@media (prefers-color-scheme: dark) {
  :root {
    --canvas: #1E1A16;
    --ink: #EEE6DA;
    --ink2: #CFC5B7;
    --ink3: #A49A8C;
    --fill: #2A251F;
    --sheet: #26211C;
    --signal: #E8703C;
    --signal-ink: #F0874F;
    --hair: rgb(238 230 218 / 0.14);
    --lift: color-mix(in srgb, var(--canvas) 93%, white);
    --shadow: 0 0 0;
    --bezel: #0A0909;
    --grain: 0.06;
    --rim: #4A4642;
  }
}
@media (min-width: 960px) { :root { --section: 136px; } }

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: 80px; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
body {
  margin: 0;
  background: var(--canvas);
  color: var(--ink);
  font: 400 18px/1.55 "Onest", ui-sans-serif, system-ui, -apple-system, sans-serif;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  overflow-x: clip;
}
/* A fine paper grain over the page. */
body::after {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 100;
  opacity: var(--grain);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0.9 0'/%3E%3C/filter%3E%3Crect width='160' height='160' filter='url(%23n)'/%3E%3C/svg%3E");
  mix-blend-mode: multiply;
}
@media (prefers-color-scheme: dark) { body::after { mix-blend-mode: screen; filter: invert(1); } }

img { display: block; max-width: 100%; height: auto; }
a { color: inherit; }
a:focus-visible, summary:focus-visible { outline: 2px solid var(--signal); outline-offset: 3px; border-radius: 6px; }
h1, h2, h3 { margin: 0; font-weight: 600; text-wrap: balance; }
p, dd, dt, li { margin: 0; text-wrap: pretty; }

.skip { position: absolute; left: 12px; top: -60px; z-index: 200; background: var(--ink); color: var(--canvas); padding: 10px 14px; border-radius: 10px; text-decoration: none; }
.skip:focus { top: 12px; }

/* The wordmark. */
.wordmark { display: block; width: 100%; height: auto; color: var(--ink); overflow: visible; }
.wordmark .dot, .intro-word .dot { fill: var(--signal); }

/* Navigation. */
.nav { position: fixed; inset: 0 0 auto; z-index: 50; padding-top: env(safe-area-inset-top); transition: background-color 0.4s, box-shadow 0.4s; }
.nav-in { max-width: calc(var(--wrap) + 2 * var(--gutter)); margin: 0 auto; padding: 14px var(--gutter); display: flex; align-items: center; justify-content: space-between; }
.brand { display: block; width: 88px; padding: 8px 0; }
.brand-word { display: block; }
.js:not(.intro-done) .brand-word { visibility: hidden; }
.nav nav { display: flex; gap: 24px; transition: opacity 0.8s var(--ease) 0.2s; }
.nav nav a { display: inline-flex; align-items: center; min-height: 44px; font-size: 15px; font-weight: 500; color: var(--ink2); text-decoration: none; text-underline-offset: 4px; text-decoration-thickness: 1px; transition: color 0.2s; }
.nav nav a:hover { color: var(--ink); text-decoration-line: underline; }
.js:not(.copy-in) .nav nav { opacity: 0; }
.nav.scrolled { background: color-mix(in srgb, var(--canvas) 92%, transparent); -webkit-backdrop-filter: blur(12px); backdrop-filter: blur(12px); box-shadow: 0 1px 0 var(--hair); }

/* Hero: the intro, then the copy. */
.hero { position: relative; padding: calc(env(safe-area-inset-top) + clamp(132px, 20svh, 210px)) var(--gutter) 0; isolation: isolate; }
.stage { position: absolute; inset: 0 0 auto; height: 100svh; min-height: 560px; overflow: hidden; z-index: -1; display: none; }
.js .stage { display: block; }
.intro-done .stage { pointer-events: none; }
/* The stage stops at one screen height, so it goes once the intro hands over. */
.stage.handed { opacity: 0; visibility: hidden; transition: opacity 0.7s var(--ease), visibility 0s 0.7s; }
.cam { position: absolute; inset: 0; transform-origin: 50% 46%; will-change: transform, filter; }
.intro-word { position: absolute; color: var(--ink); overflow: visible; }
.intro-word path { visibility: hidden; }
.penlight, .bokeh { position: absolute; left: 0; top: 0; border-radius: 50%; opacity: 0; will-change: transform; }
.penlight, .bokeh { background: radial-gradient(closest-side, var(--lift), color-mix(in srgb, var(--lift) 0%, transparent)); }
.bokeh.signal { background: radial-gradient(closest-side, var(--signal), color-mix(in srgb, var(--signal) 0%, transparent)); }
.tagline { position: absolute; left: 50%; margin: 0; white-space: nowrap; font-weight: 500; color: var(--ink3); opacity: 0; }
.depth { position: absolute; inset: 0; }
.handing .tagline, .handing .penlight, .handing .bokeh { transition: opacity 0.7s var(--ease); opacity: 0 !important; }
.handed .intro-word { visibility: hidden; }

.hero-copy { max-width: 880px; margin: 0 auto; }
.hero h1 { font-size: clamp(48px, 13vw, 116px); line-height: 0.96; letter-spacing: -0.045em; }
.hero h1 br { display: none; }
.lead { max-width: 34ch; margin: 24px 0 0; font-size: clamp(18px, 1.6vw, 21px); line-height: 1.5; color: var(--ink2); }
.soon { margin-top: 28px; font-size: 17px; font-weight: 500; color: var(--ink); }
.hero-phone { --pw: min(340px, 76vw); width: var(--pw); margin: 64px auto 0; }
@media (min-width: 960px) {
  .hero { padding: calc(env(safe-area-inset-top) + 88px) var(--gutter) 40px; }
  .hero-in { max-width: var(--wrap); min-height: calc(100svh - 128px); margin: 0 auto; display: grid; grid-template-columns: minmax(0, 1fr) auto; column-gap: clamp(48px, 7vw, 112px); align-items: center; }
  .hero-copy { margin: 0; max-width: 600px; }
  .hero h1 br { display: inline; }
  .hero .lead { margin-top: 28px; }
  .hero-phone { --pw: min(340px, calc((100svh - 150px) * 0.46)); margin: 0; }
}

.js:not(.copy-in) .hero-copy > *, .js:not(.copy-in) .hero-phone { opacity: 0; transform: translateY(20px); }
.hero-copy > *, .hero-phone { transition: opacity 1s var(--ease), transform 1.3s var(--ease); }
.copy-in .hero-copy > :nth-child(1) { transition-delay: 0.1s; }
.copy-in .hero-copy > :nth-child(2) { transition-delay: 0.22s; }
.copy-in .hero-copy > :nth-child(3) { transition-delay: 0.34s; }
.copy-in .hero-phone { transition-delay: 0.46s; }

/* The phone: a real screen in a thin black frame with the iPhone's corner radius. */
.phone { position: relative; margin: 0; padding: calc(var(--pw, 320px) * 0.024); border-radius: calc(var(--pw, 320px) * 0.178); background: var(--bezel);
  box-shadow:
    inset 0 0 0 1px rgb(255 255 255 / 0.08),
    0 0 0 1.5px var(--rim),
    0 0 0 2px rgb(255 255 255 / 0.06),
    0 1px 2px rgb(var(--shadow) / 0.12),
    0 30px 60px -30px rgb(var(--shadow) / 0.28); }
.phone picture, .phone img { display: block; width: 100%; border-radius: calc(var(--pw, 320px) * 0.152); }
.phone img { aspect-ratio: 1179 / 2563; object-fit: cover; background: var(--fill); }
.phone::after { content: ""; position: absolute; z-index: 2; left: 50%; top: calc(var(--pw, 320px) * 0.046); width: calc(var(--pw, 320px) * 0.30); height: calc(var(--pw, 320px) * 0.088); transform: translateX(-50%); border-radius: 999px; background: #000; }

/* Ask and To-dos, as cards in the same style as the example note. */
.shots { padding: var(--section) var(--gutter) 0; }
.shots-in { max-width: var(--wrap); margin: 0 auto; display: grid; gap: 56px; }
.shots figure { margin: 0; display: flex; flex-direction: column; }
.shots .note { flex: 1; }
.shots .note { max-width: 440px; }
.shots figcaption { margin-top: 20px; font-size: 18px; line-height: 1.45; color: var(--ink2); max-width: 34ch; }
.sources { list-style: none; margin: 18px 0 0; padding: 0; }
.sources li { display: grid; gap: 2px; padding: 12px 0; border-top: 1px solid var(--hair); font-size: 16px; line-height: 1.4; }
.sources li:last-child { padding-bottom: 0; }
.sources .from { font-size: 13px; color: var(--ink3); }
.sources .play { color: var(--signal-ink); font-size: 0.8em; }
.todos-card h4 { margin: 18px 0 0; font-size: 15px; font-weight: 600; letter-spacing: -0.01em; }
.todos-card .note-meta + h4 { margin-top: 12px; }
.todos-card .note-todos { margin-top: 10px; gap: 10px; }
@media (min-width: 960px) {
  .shots-in { grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr); grid-template-rows: 1fr auto; column-gap: clamp(48px, 7vw, 112px); row-gap: 0; }
  /* The cards share a height, and the captions share a top line. */
  .shots figure { display: grid; grid-row: span 2; grid-template-rows: subgrid; }
}

/* An example: what you say, and the note Ravel writes. */
.vh { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.example { padding: var(--section) var(--gutter) 0; }
.example-in { max-width: var(--wrap); margin: 0 auto; display: grid; gap: 40px; }
.speech { font-size: clamp(20px, 2vw, 25px); line-height: 1.5; letter-spacing: -0.012em; color: var(--ink2); max-width: 34ch; text-indent: -0.42em; }
.speech .um { color: color-mix(in srgb, var(--ink3) 75%, var(--canvas)); }
.speech mark { background: none; color: var(--ink); text-decoration: underline; text-decoration-color: var(--signal); text-decoration-thickness: 2px; text-underline-offset: 0.2em; white-space: nowrap; }
/* Cards take the opposite theme to the page, as the hero phone does. */
.note { --ink: #EEE6DA; --ink2: #CFC5B7; --ink3: #A49A8C; --hair: rgb(238 230 218 / 0.14); --sheet: #26211C; --signal-ink: #F0874F;
  color: var(--ink); padding: 22px 24px 24px; border-radius: 26px; background: var(--sheet); box-shadow: 0 0 0 1px var(--hair), 0 1px 2px rgb(var(--shadow) / 0.05), 0 24px 48px -28px rgb(var(--shadow) / 0.3); max-width: 440px; }
@media (prefers-color-scheme: dark) {
  .note { --ink: #4A4037; --ink2: #5E544A; --ink3: #655A4E; --hair: rgb(74 64 55 / 0.12); --sheet: #FCF9F3; --signal-ink: #A9441A; }
}
.note-meta { display: flex; align-items: center; gap: 7px; font-size: 13px; color: var(--ink3); }
.note-meta .dot { width: 5px; height: 5px; border-radius: 50%; background: var(--signal); }
.note h3 { margin-top: 10px; font-size: 23px; line-height: 1.2; letter-spacing: -0.02em; }
.note-sum { margin-top: 8px; font-size: 16px; line-height: 1.5; color: var(--ink2); }
.note-todos { list-style: none; margin: 18px 0 0; padding: 0; display: grid; gap: 12px; }
.note-todos li { display: grid; grid-template-columns: 20px 1fr; gap: 12px; font-size: 16px; line-height: 1.35; }
/* Each to-do carries the number of the words it came from. */
.n { font-weight: 600; color: var(--signal-ink); margin-left: 0.15em; vertical-align: 0.55em; line-height: 0; font-variant-numeric: tabular-nums; }
.speech .n { font-size: 0.5em; }
.note .n { font-size: 11px; }
.speech mark .n { text-decoration: none; display: inline-block; }
.note-todos li::before { content: ""; width: 18px; height: 18px; margin-top: 0.5px; border-radius: 6px; box-shadow: inset 0 0 0 1.5px var(--ink3); }
@media (min-width: 960px) {
  .example-in { grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr); column-gap: clamp(48px, 7vw, 112px); align-items: center; }
}

/* Details, pricing and questions: one column on the shared left edge, each at its own pace. */
.block { padding: var(--section) var(--gutter) 0; }
.block-in { max-width: var(--wrap); margin: 0 auto; }
.block-in > * { max-width: 680px; }
.block h2 { font-size: 28px; line-height: 1.1; letter-spacing: -0.025em; margin-bottom: 28px; }
.block-in > .facts-list { max-width: 880px; }
.facts-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 18px; }
.facts-list li { display: grid; grid-template-columns: 20px 1fr; column-gap: 14px; align-items: start; }
.facts-list svg { display: block; width: 20px; height: 20px; margin-top: 2px; fill: none; stroke: var(--ink3); stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
.facts-list p { font-size: 17px; line-height: 1.45; color: var(--ink); max-width: 36ch; }
@media (min-width: 960px) { .facts-list { grid-template-columns: 1fr 1fr; gap: 24px 64px; } }

/* Pricing: the yearly price large, the others one line each. */
@media (min-width: 960px) {
  .pricing .block-in { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr); column-gap: clamp(48px, 7vw, 112px); align-items: start; }
  .pricing .block-in > * { max-width: none; }
  .pricing h2 { grid-column: 1 / -1; }
  .price-rest { padding-top: 6px; }
  .price-rest .price-alt { margin-top: 0; padding-top: 0; border-top: 0; }
}
.price-main { font-size: clamp(44px, 5vw, 56px); font-weight: 600; letter-spacing: -0.045em; line-height: 1; font-variant-numeric: tabular-nums; }
.price-main span { font-size: 0.4em; font-weight: 500; letter-spacing: -0.01em; color: var(--ink2); }
.price-terms { margin-top: 14px; font-size: 18px; color: var(--ink2); }
.price-alt { list-style: none; margin: 28px 0 0; padding: 20px 0 0; border-top: 1px solid var(--hair); display: grid; gap: 8px; font-size: 18px; color: var(--ink2); }
.price-alt strong { color: var(--ink); font-weight: 600; font-variant-numeric: tabular-nums; }
.every { margin-top: 24px; font-size: 17px; color: var(--ink); max-width: 44ch; }
.fine { margin-top: 14px; font-size: 14px; color: var(--ink3); max-width: 60ch; }


/* The end: the wordmark once more. */
.end { padding: 96px var(--gutter); text-align: center; }
.end-in { display: grid; justify-items: center; gap: 28px; }
.end-word { display: block; width: min(240px, 56vw); }

/* Footer. */
.foot { padding: 0 var(--gutter) calc(40px + env(safe-area-inset-bottom)); }
.foot-in { max-width: var(--wrap); margin: 0 auto; padding-top: 36px; border-top: 1px solid var(--hair); display: grid; gap: 16px; align-items: center; }
.foot nav { display: flex; flex-wrap: wrap; gap: 0 20px; }
.foot nav a { display: inline-flex; align-items: center; min-height: 44px; font-size: 15px; color: var(--ink2); text-decoration: none; }
.foot nav a:hover { color: var(--ink); }
.copy { font-size: 14px; color: var(--ink3); }
@media (min-width: 820px) { .foot-in { grid-template-columns: 1fr auto; gap: 32px; } }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition-duration: 0.01ms !important; animation-duration: 0.01ms !important; }
}
.no-anim *, .no-anim *::before, .no-anim *::after { transition: none !important; }

/* Plain pages: privacy and 404. */
.page { max-width: calc(var(--wrap) + 2 * var(--gutter)); margin: 0 auto; padding: calc(env(safe-area-inset-top) + 120px) var(--gutter) 96px; }
.page > * { max-width: 680px; }
.page h2 + p { margin-top: 10px; }
.page h1 { font-size: clamp(36px, 5vw, 56px); line-height: 1.02; letter-spacing: -0.035em; }
.page h2 { font-size: 21px; letter-spacing: -0.01em; margin-top: 44px; }
.page p, .page li { color: var(--ink2); font-size: 17px; }
.page p + p { margin-top: 14px; }
.page ul { padding-left: 1.1em; }
.page li { margin-top: 8px; }
.page li::marker { color: var(--signal); }
.page .updated { margin-top: 14px; color: var(--ink3); font-size: 15px; }
.draft { margin-top: 24px; font-size: 15px; color: var(--ink3); }
.page .home-link { display: inline-flex; align-items: center; min-height: 44px; margin-top: 20px; color: var(--ink); font-weight: 500; font-size: 17px; text-underline-offset: 4px; text-decoration-thickness: 1px; }
