/* Hallmark · genre: modern-minimal (editorial product sheet) · macrostructure: Tour + Ledger (centred hero, chaptered product tour, sticky-index feature ledger) · theme: custom (vibe: "after-dark studio, icon blue→cyan, premium" · paper oklch(11% 0.01 262) · accent oklch(80% 0.13 215) · Instrument Sans + JetBrains Mono · axes: dark / grotesk-sans / cool) · enrichment: real product screenshots + product video chapters (no chrome) · nav: N1 top bar · footer: Ft3 columns on a lowered band
 * tone: precise, assured · audience: iPhone users who need to blur a face, a plate or a background before posting · use: App Store download
 * pre-emit critique: P4 H5 E4 S4 R5 V5
 */
@import url("tokens.css");

*,
*::before,
*::after { box-sizing: border-box; }

html { overflow-x: clip; scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  overflow-x: clip;
  background: var(--color-paper);
  color: var(--color-ink);
  font-family: var(--font-body);
  font-size: var(--text-md);
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
}
/* two fixed glows in the icon's colours, behind everything: the room the page sits in */
body::before,
body::after {
  content: "";
  position: fixed; z-index: -1; pointer-events: none;
  border-radius: 50%; filter: blur(90px);
}
body::before { width: 52vw; height: 52vw; left: -14vw; top: -22vw; background: var(--glow-blue); }
body::after { width: 40vw; height: 40vw; right: -12vw; top: 30vh; background: var(--glow-cyan); }

img, video { display: block; max-width: 100%; height: auto; }
a { color: inherit; text-decoration-thickness: 1px; text-underline-offset: 0.16em; }
p { margin: 0; }
h1, h2, h3 {
  margin: 0;
  font-family: var(--font-display);
  font-style: normal;
  font-weight: 600;
  letter-spacing: -0.028em;
  line-height: 1.04;
  overflow-wrap: anywhere;
  min-width: 0;
  text-wrap: balance;
}
h1 { font-size: var(--text-display); letter-spacing: -0.035em; }
h2 { font-size: var(--text-3xl); }
h3 { font-size: var(--text-xl); letter-spacing: -0.02em; line-height: 1.2; }
.lede { font-size: var(--text-lg); color: var(--color-ink-2); max-width: 52ch; text-wrap: pretty; line-height: 1.45; }
.muted { color: var(--color-ink-3); }
.mono { font-family: var(--font-mono); font-size: var(--text-xs); letter-spacing: 0.02em; }
.eyebrow { font-family: var(--font-mono); font-size: var(--text-xs); letter-spacing: 0.06em; text-transform: uppercase; color: var(--color-accent); }

.wrap { width: min(100% - 2 * var(--page-gutter), 76rem); margin-inline: auto; }
section { padding-block: var(--space-3xl); }
.section-head { display: grid; gap: var(--space-sm); max-width: 44rem; margin-block-end: var(--space-xl); }

:focus-visible { outline: 2px solid var(--color-focus); outline-offset: 3px; border-radius: var(--radius-sm); }
.skip {
  position: absolute; left: var(--space-md); top: -3rem;
  padding: var(--space-xs) var(--space-md);
  background: var(--color-accent); color: var(--color-accent-ink);
  border-radius: var(--radius-pill); z-index: 30;
}
.skip:focus { top: var(--space-md); }

/* ---------- buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: var(--space-xs);
  padding: 0.8rem 1.25rem;
  border-radius: var(--radius-sm);
  border: var(--rule-hair) solid transparent;
  font: 600 var(--text-sm) / 1 var(--font-body);
  letter-spacing: -0.01em;
  text-decoration: none;
  white-space: nowrap;
  cursor: pointer;
  transition: transform var(--dur-fast) var(--ease-out), background-color var(--dur-fast) var(--ease-out), border-color var(--dur-fast) var(--ease-out);
}
.btn:active { transform: translateY(1px); }
.btn-fill { background: var(--color-ink); color: var(--color-paper); }
.btn-fill:hover { background: var(--color-accent-3); color: var(--color-accent-ink); }
.btn-ghost { border-color: var(--color-rule-2); color: var(--color-ink); background: var(--glass); box-shadow: var(--glass-edge); }
.btn-ghost:hover { border-color: var(--color-ink-3); background: oklch(100% 0 0 / 0.06); }
.link { display: inline-flex; align-items: center; gap: 0.35em; color: var(--color-accent); font-weight: 600; font-size: var(--text-sm); text-decoration: none; }
.link::after { content: "→"; transition: transform var(--dur-fast) var(--ease-out); }
.link:hover::after { transform: translateX(3px); }

/* Apple's own App Store badge (unmodified SVG from the marketing toolbox).
   Apple asks for clear space of 1/4 the badge height around it; the gap gives that. */
.badge { display: inline-block; line-height: 0; border-radius: 0.5rem; }
.badge img { height: 3.375rem; width: auto; }
.badge:hover img { opacity: 0.9; }
.hero-actions { display: flex; flex-wrap: wrap; justify-content: center; align-items: center; gap: var(--space-sm); }
/* the secondary button takes the badge's shape: same height, same corner radius */
.hero-actions .btn-ghost { min-height: 3.375rem; padding-inline: 1.5rem; border-radius: 0.5rem; }

/* ---------- nav · N1 top bar ---------- */
.topbar {
  position: fixed; inset: 0 0 auto 0; z-index: 20;
  background: color-mix(in oklch, var(--color-paper) 70%, transparent);
  -webkit-backdrop-filter: blur(16px) saturate(140%);
  backdrop-filter: blur(16px) saturate(140%);
  border-bottom: var(--rule-hair) solid var(--color-rule);
}
.topbar .wrap { display: flex; align-items: center; gap: var(--space-lg); min-height: 3.75rem; }
.wordmark { display: inline-flex; align-items: center; gap: var(--space-xs); font-weight: 600; letter-spacing: -0.02em; text-decoration: none; white-space: nowrap; }
.wordmark img { width: 1.6rem; height: 1.6rem; border-radius: 0.45rem; }
.wordmark small { font-weight: 400; color: var(--color-ink-3); margin-inline-start: 0.2rem; }
.topbar ul { display: flex; gap: var(--space-lg); margin: 0 auto; padding: 0; list-style: none; }
.topbar ul a { font-size: var(--text-sm); color: var(--color-ink-2); text-decoration: none; white-space: nowrap; }
.topbar ul a:hover { color: var(--color-ink); }
.topbar .btn { padding-block: 0.6rem; margin-inline-start: auto; }
@media (max-width: 860px) { .topbar ul { display: none; } }
@media (max-width: 420px) { .wordmark small { display: none; } }

/* ---------- hero: centred statement ---------- */
.hero { padding-block: calc(var(--space-3xl) + 3rem) var(--space-xl); }
.hero .wrap { display: grid; justify-items: center; text-align: center; gap: var(--space-lg); max-width: 56rem; }
.hero h1 { max-width: 16ch; }
.hero h1 em { font-style: normal; color: var(--color-accent); background: var(--grad-accent); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; }
.hero .lede { max-width: 58ch; }
.proof { display: flex; flex-wrap: wrap; justify-content: center; gap: var(--space-xs) var(--space-md); align-items: center; color: var(--color-ink-3); font-size: var(--text-sm); }
.proof strong { color: var(--color-ink); font-weight: 600; }
.stars { color: var(--color-accent); letter-spacing: 0.05em; }

/* ---------- product tour: chapters of the app's own preview video ---------- */
.tour { padding-block: var(--space-md) var(--space-3xl); }
.tour-panel {
  display: grid; gap: var(--space-lg);
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  grid-template-areas: "tabs tabs" "stage copy";
  align-items: center;
  padding: var(--space-lg);
  background: linear-gradient(180deg, oklch(100% 0 0 / 0.05), oklch(100% 0 0 / 0.02)), var(--color-paper-2);
  border: var(--rule-hair) solid var(--color-rule);
  border-radius: var(--radius-lg);
  box-shadow: var(--glass-edge), 0 40px 90px -50px oklch(0% 0 0 / 0.9);
}
.tour-tabs { grid-area: tabs; display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: var(--space-xs); }
.tour-tab {
  position: relative; display: grid; gap: 0.2rem; justify-items: start;
  padding: var(--space-sm) var(--space-md) calc(var(--space-sm) + 3px);
  background: transparent; border: 0; border-radius: var(--radius-sm);
  color: var(--color-ink-2); text-align: left; cursor: pointer;
  font: 600 var(--text-sm) / 1.15 var(--font-body); letter-spacing: -0.01em;
  transition: background-color var(--dur-fast) var(--ease-out), color var(--dur-fast) var(--ease-out);
}
.tour-tab .mono { color: var(--color-ink-3); font-weight: 400; }
.tour-tab:hover { background: var(--color-paper-3); color: var(--color-ink); }
.tour-tab.is-on { color: var(--color-ink); background: var(--color-paper-3); box-shadow: var(--glass-edge); }
.tour-tab.is-on .mono { color: var(--color-accent); }
/* the rule at the foot of the active tab fills as its clip plays */
.tour-tab::after { content: ""; position: absolute; left: var(--space-md); right: var(--space-md); bottom: 0.45rem; height: 2px; background: var(--color-rule); border-radius: 1px; }
.tour-tab .bar { position: absolute; left: var(--space-md); bottom: 0.45rem; height: 2px; width: 0; max-width: calc(100% - 2 * var(--space-md)); background: var(--grad-accent); border-radius: 1px; z-index: 1; }
.tour-stage {
  grid-area: stage; position: relative; aspect-ratio: 3 / 4; width: 100%; max-width: 26rem; justify-self: center;
  border-radius: var(--radius-md); overflow: hidden; background: var(--color-band);
  border: var(--rule-hair) solid var(--color-rule);
  box-shadow: 0 30px 60px -30px oklch(0% 0 0 / 0.9);
}
.tour-clip { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; opacity: 0; transition: opacity var(--dur-base) var(--ease-out); }
.tour-clip.is-on { opacity: 1; }
.tour-copy { grid-area: copy; position: relative; min-height: 12rem; }
.tour-text { display: none; gap: var(--space-sm); max-width: 30rem; }
.tour-text.is-on { display: grid; }
.tour-text h2 { font-size: var(--text-2xl); }
.tour-text p { color: var(--color-ink-2); text-wrap: pretty; }
.tour-text ul { margin: 0; padding: 0; list-style: none; display: flex; flex-wrap: wrap; gap: var(--space-2xs); }
.tour-text li { padding: 0.25rem 0.6rem; border-radius: var(--radius-pill); border: var(--rule-hair) solid var(--color-rule-2); font-size: var(--text-xs); color: var(--color-ink-2); }
.tour-note { color: var(--color-ink-3); margin-block-start: var(--space-md); text-align: center; }

/* ---------- facts ledger ---------- */
.facts { padding-block: 0; }
.facts .wrap { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); border-block: var(--rule-hair) solid var(--color-rule); }
.facts div { padding: var(--space-lg) var(--space-md); display: grid; gap: var(--space-2xs); }
.facts div + div { border-inline-start: var(--rule-hair) solid var(--color-rule); }
.facts strong { font-family: var(--font-display); font-size: var(--text-2xl); font-weight: 600; letter-spacing: -0.03em; line-height: 1; color: var(--color-ink); }
.facts span { font-size: var(--text-sm); color: var(--color-ink-2); }

/* ---------- gallery: the App Store screens ---------- */
.gallery .wrap { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: var(--space-md); }
.gallery .section-head { grid-column: 1 / -1; }
.gallery figure { margin: 0; display: grid; gap: var(--space-xs); }
.gallery img { border-radius: var(--radius-md); border: var(--rule-hair) solid var(--color-rule); box-shadow: 0 24px 48px -32px oklch(0% 0 0 / 0.9); }
.gallery figcaption { font-size: var(--text-sm); color: var(--color-ink-2); }

/* ---------- how it works: four columns ---------- */
.how { background: linear-gradient(180deg, oklch(100% 0 0 / 0.03), transparent); border-block: var(--rule-hair) solid var(--color-rule); }
.steps { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: var(--space-lg); margin: 0; padding: 0; list-style: none; counter-reset: step; }
.steps li { display: grid; gap: var(--space-sm); align-content: start; padding-block-start: var(--space-md); border-top: var(--rule-hair) solid var(--color-rule-2); counter-increment: step; }
.steps li::before { content: counter(step, decimal-leading-zero); font-family: var(--font-mono); font-size: var(--text-xs); color: var(--color-accent); }
.steps p { color: var(--color-ink-2); font-size: var(--text-sm); text-wrap: pretty; }

/* ---------- feature ledger: sticky index + entries ---------- */
.ledger .wrap { display: grid; grid-template-columns: 12rem minmax(0, 1fr); gap: var(--space-2xl); align-items: start; }
.ledger-index { position: sticky; top: 5rem; display: grid; gap: var(--space-2xs); margin: 0; padding: 0; list-style: none; }
.ledger-index a { display: flex; gap: var(--space-sm); padding: 0.35rem 0; font-size: var(--text-sm); color: var(--color-ink-3); text-decoration: none; border-left: 2px solid transparent; padding-inline-start: var(--space-sm); margin-inline-start: -2px; transition: color var(--dur-fast) var(--ease-out), border-color var(--dur-fast) var(--ease-out); }
.ledger-index a .mono { color: inherit; }
.ledger-index a:hover { color: var(--color-ink); }
.ledger-index a.is-on { color: var(--color-ink); border-color: var(--color-accent); }
.ledger-index { border-left: var(--rule-hair) solid var(--color-rule); }
.entries { display: grid; }
.entry {
  display: grid; gap: var(--space-xl);
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  align-items: center;
  padding-block: var(--space-2xl);
  border-top: var(--rule-hair) solid var(--color-rule);
  scroll-margin-top: 5rem;
}
.entry:first-child { border-top: 0; padding-block-start: 0; }
.entry-text { display: grid; gap: var(--space-md); max-width: 34rem; }
.entry-text h2 { font-size: var(--text-2xl); }
.entry-text .mono { color: var(--color-accent); }
.entry-text p { color: var(--color-ink-2); text-wrap: pretty; }
.entry-text .link { justify-self: start; margin-block-start: var(--space-2xs); }
.entry-art { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--space-md); align-items: start; }
.entry-art figure { margin: 0; border-radius: var(--radius-md); overflow: hidden; border: var(--rule-hair) solid var(--color-rule); background: var(--color-paper-2); box-shadow: 0 30px 60px -36px oklch(0% 0 0 / 0.9); }
.entry-art figure:nth-child(2) { margin-block-start: var(--space-xl); }
.entry-art.one { grid-template-columns: minmax(0, 1fr); max-width: 17rem; justify-self: center; }
.entry-art.one figure:nth-child(2) { margin: 0; }

/* ---------- use cases: two-column list with rules ---------- */
.uses { background: linear-gradient(180deg, oklch(100% 0 0 / 0.03), transparent); border-block: var(--rule-hair) solid var(--color-rule); }
.uses .wrap { display: grid; gap: var(--space-xl); grid-template-columns: minmax(0, 1fr) minmax(0, 1.5fr); align-items: start; }
.uses ul { margin: 0; padding: 0; list-style: none; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 var(--space-xl); }
.uses li { display: grid; gap: var(--space-2xs); padding-block: var(--space-md); border-top: var(--rule-hair) solid var(--color-rule-2); }
.uses li strong { font-weight: 600; letter-spacing: -0.01em; }
.uses li span { color: var(--color-ink-2); font-size: var(--text-sm); }

/* ---------- FAQ: two columns ---------- */
.faq .wrap { display: grid; gap: var(--space-xl); grid-template-columns: minmax(0, 1fr) minmax(0, 2fr); align-items: start; }
.faq .section-head { margin: 0; }
.faq details { border-top: var(--rule-hair) solid var(--color-rule-2); }
.faq details:last-child { border-bottom: var(--rule-hair) solid var(--color-rule-2); }
.faq summary { cursor: pointer; padding-block: var(--space-md); font-weight: 600; letter-spacing: -0.01em; list-style: none; display: flex; justify-content: space-between; gap: var(--space-md); }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; color: var(--color-ink-3); font-weight: 400; flex: none; }
.faq details[open] summary::after { content: "–"; }
.faq details p { color: var(--color-ink-2); padding-block-end: var(--space-md); max-width: 60ch; text-wrap: pretty; }

/* ---------- closing band + footer: the app's dark chrome ---------- */
.close { position: relative; background: var(--color-band); color: var(--color-band-ink); padding-block: var(--space-3xl) var(--space-2xl); border-top: var(--rule-hair) solid var(--color-rule); overflow: hidden; }
.close::before { content: ""; position: absolute; left: 50%; top: -30%; width: 44rem; height: 30rem; transform: translateX(-50%); border-radius: 50%; background: radial-gradient(closest-side, var(--glow-blue), transparent); filter: blur(40px); pointer-events: none; }
.close .wrap { position: relative; }
.close .wrap { display: grid; justify-items: center; text-align: center; gap: var(--space-lg); }
.close .icon { width: 4rem; height: 4rem; border-radius: 0.9rem; box-shadow: 0 20px 40px -16px var(--glow-blue); }
.close h2 { max-width: 18ch; }
.close .muted { color: var(--color-band-ink-2); }

.foot { background: var(--color-band); color: var(--color-band-ink-2); padding-block: var(--space-xl) var(--space-lg); border-top: var(--rule-hair) solid var(--color-band-rule); }
.foot .wrap { display: grid; grid-template-columns: minmax(0, 1.6fr) repeat(3, minmax(0, 1fr)); gap: var(--space-xl); }
.foot h3 { font-size: var(--text-xs); font-family: var(--font-mono); font-weight: 400; letter-spacing: 0.06em; text-transform: uppercase; color: var(--color-band-ink-2); margin-block-end: var(--space-sm); }
.foot ul { margin: 0; padding: 0; list-style: none; display: grid; gap: var(--space-xs); }
.foot a { color: var(--color-band-ink); text-decoration: none; font-size: var(--text-sm); }
.foot a:hover { text-decoration: underline; }
.foot-brand { display: grid; gap: var(--space-sm); align-content: start; }
.foot-brand .wordmark { color: var(--color-band-ink); }
.foot-brand p { font-size: var(--text-sm); max-width: 32ch; }
.foot-copy { grid-column: 1 / -1; padding-block-start: var(--space-md); border-top: var(--rule-hair) solid var(--color-band-rule); font-size: var(--text-xs); }

/* ---------- reveal ---------- */
.reveal { opacity: 0; transform: translateY(10px); transition: opacity var(--dur-slow) var(--ease-out), transform var(--dur-slow) var(--ease-out); }
.reveal.in { opacity: 1; transform: none; }
.no-js .reveal { opacity: 1; transform: none; }

/* ---------- responsive ---------- */
@media (max-width: 1000px) {
  .ledger .wrap { grid-template-columns: minmax(0, 1fr); }
  .ledger-index { display: none; }
}
@media (max-width: 900px) {
  .entry, .uses .wrap, .faq .wrap { grid-template-columns: minmax(0, 1fr); }
  .entry-art { max-width: 28rem; }
  .steps { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .gallery .wrap { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .facts .wrap { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .facts div:nth-child(3) { border-inline-start: 0; }
  .facts div:nth-child(n + 3) { border-top: var(--rule-hair) solid var(--color-rule); }
  .foot .wrap { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .foot-brand { grid-column: 1 / -1; }
  section { padding-block: var(--space-2xl); }
  .tour-panel { grid-template-columns: minmax(0, 1fr); grid-template-areas: "tabs" "stage" "copy"; padding: var(--space-md); }
  .tour-tabs { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .tour-copy { min-height: 0; }
  .tour-text { max-width: none; }
}
@media (max-width: 560px) {
  .hero { padding-block-start: calc(var(--space-2xl) + 3.5rem); }
  .uses ul { grid-template-columns: minmax(0, 1fr); }
  .steps { grid-template-columns: minmax(0, 1fr); }
  .gallery .wrap { grid-template-columns: minmax(0, 1fr); }
  .gallery figure { grid-template-columns: 7rem minmax(0, 1fr); align-items: center; gap: var(--space-md); }
  .entry-art figure:nth-child(2) { margin-block-start: var(--space-lg); }
  .tour-tabs { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .tour-tab .mono { display: none; }
  .facts strong { font-size: var(--text-xl); }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .reveal { transition: opacity 150ms linear; transform: none; }
  .btn, .link::after { transition: none; }
  .btn:active { transform: none; }
}
