/*
  Opie design language: tokens and components for tryopie.com.
  Source of truth: docs/design-language.md. SwiftUI mirror: DS.Opie in DesignSystem.swift.
  One stylesheet, no framework. Class names are BEM-ish: .block, .block__part, .block--variant.
*/

/* ---------- Font: Bricolage Grotesque (SIL OFL 1.1), variable opsz 12-96 + wght 200-800, latin subset ---------- */
@font-face {
  font-family: "Bricolage Grotesque";
  font-style: normal;
  font-weight: 200 800;
  font-display: swap;
  src: url("/assets/fonts/BricolageGrotesque-latin.var.woff2") format("woff2");
  /* Latin only. Persian, Arabic and other scripts fall through to the system fonts in --font-sans. */
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

/* ---------- Tokens ---------- */
:root {
  /* Colour: the pen, the island, the paper */
  --accent: #3B82F6;          /* Opie's pen. Marks, focus rings, fills, toggles. Not for small text. */
  --accent-ink: #2563EB;      /* Pen colour for text and links on paper/sheet (AA 4.7:1 on paper). */
  --accent-wash: #E4EDFD;     /* Selected rows, notices, accent pills. */
  --accent-ink-strong: #1D4ED8; /* Blue text on accent-wash: accent pills, links in notices (AA 5.7:1 on wash). */
  --island: #000000;          /* The notch. Pure black, never tinted. */
  --on-island: #FFFFFF;
  --on-island-muted: #A3ABBB;
  --on-island-line: rgba(255, 255, 255, 0.14);
  --island-hover: #262C38;    /* Primary button hover on paper. */
  --on-island-hover: #DCE6F7; /* Inverted primary button hover on black. */
  --ink: #141A26;             /* Body text and headings. */
  --muted: #5A6477;           /* Secondary text (AA 5.5:1 on paper). */
  --paper: #F2F5FA;           /* Page background: cool desk paper. */
  --sheet: #FFFFFF;           /* Raised surfaces: cards, fields. */
  --line: #DCE2EC;            /* Hairlines and borders. */
  --line-strong: #B9C2D2;     /* Stronger decorative outlines: quiet plan, language switch. */
  --control: #8A93A5;         /* Boundaries of controls: fields, code boxes, toggle off (3:1 on sheet). */
  --placeholder: #6B7385;     /* Placeholder text in fields (4.8:1 on sheet). */
  --success: #15803D;
  --warning: #B45309;
  --danger: #C81E1E;
  --success-wash: #EDF7F0;    /* Behind success text (AA 4.6:1). */
  --warning-wash: #FDF2E5;    /* Behind warning text (AA 4.6:1). */
  --danger-wash: #FCECEC;     /* Behind danger text (AA 5.0:1). */
  --success-on-island: #4ADE80;
  --danger-on-island: #F87171;
  --listening: #3FD3C9;       /* On the island only. */
  --thinking: #B07CFF;        /* On the island only. */
  --listening-ink: #C9F4F0;   /* Island text while listening. */
  --thinking-ink: #DCC8FF;    /* Island text while thinking. */

  /* Type */
  --font-sans: "Bricolage Grotesque", system-ui, -apple-system, "Segoe UI", "Noto Sans", "Noto Sans Arabic", Tahoma, sans-serif;
  --font-pen: ui-rounded, "SF Pro Rounded", system-ui, -apple-system, "Segoe UI", sans-serif;
  --text-12: 0.75rem;
  --text-14: 0.875rem;
  --text-16: 1rem;
  --text-18: 1.125rem;
  --text-22: 1.375rem;
  --text-28: 1.75rem;
  --text-40: 2.5rem;
  --text-56: 3.5rem;
  --text-72: 4.5rem;
  --leading-tight: 1.02;
  --leading-snug: 1.2;
  --leading-body: 1.55;
  --weight-body: 420;
  --weight-strong: 640;
  --weight-heading: 760;
  --tracking-display: -0.04em;
  --tracking-heading: -0.025em;

  /* Space: 4-point */
  --space-1: 4px;
  --space-2: 8px;
  --space-3: 12px;
  --space-4: 16px;
  --space-5: 20px;
  --space-6: 24px;
  --space-8: 32px;
  --space-10: 40px;
  --space-12: 48px;
  --space-16: 64px;
  --space-20: 80px;
  --space-24: 96px;
  --gutter: clamp(20px, 5vw, 48px);
  --page-max: 1160px;
  --measure: 66ch;

  /* Radii */
  --radius-pill: 999px;
  --radius-card: 18px;
  --radius-field: 12px;
  --radius-island: 22px;
  --radius-small: 8px;

  /* Shadows */
  --shadow-sheet: 0 1px 2px rgba(20, 26, 38, 0.05), 0 14px 32px -22px rgba(20, 26, 38, 0.32);
  --shadow-island: 0 22px 44px -22px rgba(0, 0, 0, 0.55);
  --shadow-pop: 0 18px 40px -16px rgba(0, 0, 0, 0.5);

  /* Motion */
  --ease-out: cubic-bezier(0.2, 0.9, 0.25, 1);
  --ease-spring: cubic-bezier(0.3, 1.3, 0.5, 1);
  --dur-fast: 150ms;
  --dur: 250ms;
  --dur-slow: 450ms;
  --dur-draw: 900ms;

  /* Access */
  --focus: 3px solid var(--accent);
  --focus-offset: 2px;
  --target: 44px;
}

/* ---------- Base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html {
  background: var(--paper);
  color: var(--ink);
  font-family: var(--font-sans);
  font-optical-sizing: auto;
  font-size: 100%;
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
  scroll-padding-top: 72px; /* anchors land below the sticky island */
}
body {
  margin: 0;
  font-size: var(--text-16);
  font-weight: var(--weight-body);
  line-height: var(--leading-body);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}
img, svg, video { max-width: 100%; }
img, video { display: block; height: auto; }
h1, h2, h3, h4, p, ul, ol, figure, blockquote { margin: 0; }
h1, h2, h3, h4 { font-weight: var(--weight-heading); letter-spacing: var(--tracking-heading); line-height: var(--leading-snug); text-wrap: balance; }
p { text-wrap: pretty; }
a { color: var(--accent-ink); text-decoration-thickness: 1.5px; text-underline-offset: 0.18em; }
a:hover { text-decoration-thickness: 2.5px; }
strong, b { font-weight: var(--weight-strong); }
button, input, select, textarea { font: inherit; color: inherit; }
:focus-visible { outline: var(--focus); outline-offset: var(--focus-offset); }
::selection { background: var(--accent-wash); color: var(--ink); }
[hidden] { display: none !important; }

.sr-only {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}
.skip-link {
  position: absolute; left: var(--space-4); top: var(--space-2); z-index: 100;
  padding: var(--space-2) var(--space-4); border-radius: var(--radius-pill);
  background: var(--sheet); color: var(--ink); font-weight: var(--weight-strong);
  transform: translateY(-200%);
}
.skip-link:focus { transform: none; }

/* ---------- Layout ---------- */
.wrap { width: 100%; max-width: calc(var(--page-max) + 2 * var(--gutter)); margin-inline: auto; padding-inline: var(--gutter); }
.section { padding-block: clamp(var(--space-12), 8vw, var(--space-24)); }
.stack > * + * { margin-top: var(--stack, var(--space-4)); }
.cluster { display: flex; flex-wrap: wrap; align-items: center; gap: var(--cluster, var(--space-3)); }
.grid { display: grid; gap: var(--grid-gap, var(--space-6)); grid-template-columns: repeat(auto-fit, minmax(min(100%, var(--grid-min, 260px)), 1fr)); }

/* ---------- Type ---------- */
.display { font-size: clamp(var(--text-40), 7.2vw, var(--text-72)); line-height: var(--leading-tight); letter-spacing: var(--tracking-display); font-weight: 780; }
.h1 { font-size: clamp(var(--text-40), 5.4vw, var(--text-56)); line-height: 1.04; letter-spacing: var(--tracking-display); }
/* Long Norwegian compounds ("Personvernerklæring") must fit a 360px phone: smaller there, and never overflow. */
@media (max-width: 400px) { .h1 { font-size: 2.125rem; } }
.h1, .display, .h2 { overflow-wrap: break-word; }
.h2 { font-size: clamp(var(--text-28), 3.6vw, var(--text-40)); line-height: 1.1; letter-spacing: -0.03em; }
.h3 { font-size: var(--text-22); line-height: var(--leading-snug); }
.h4 { font-size: var(--text-18); line-height: var(--leading-snug); letter-spacing: -0.01em; }
.lede { font-size: clamp(var(--text-18), 2vw, var(--text-22)); line-height: 1.45; color: var(--muted); max-width: 34em; }
.body-lg { font-size: var(--text-18); }
.small { font-size: var(--text-14); }
.tiny { font-size: var(--text-12); }
.muted { color: var(--muted); }
.kbd, kbd {
  display: inline-block; min-width: 1.8em; padding: 0.12em 0.5em 0.18em; border-radius: var(--radius-small);
  background: var(--sheet); box-shadow: inset 0 0 0 1px var(--line), 0 2px 0 var(--line);
  font: 640 0.86em/1.3 var(--font-pen); color: var(--ink); text-align: center; white-space: nowrap;
}

.prose { max-width: var(--measure); font-size: var(--text-18); }
.prose > * + * { margin-top: 1em; }
.prose h2 { font-size: var(--text-28); margin-top: 1.8em; letter-spacing: -0.025em; }
.prose h3 { font-size: var(--text-22); margin-top: 1.5em; }
.prose h2 + *, .prose h3 + * { margin-top: 0.5em; }
.prose ul, .prose ol { padding-left: 1.3em; }
.prose li + li { margin-top: 0.35em; }
.prose li::marker { color: var(--accent); }

/* ---------- Wordmark ---------- */
.wordmark {
  display: inline-flex; align-items: center; gap: 0.4em; min-height: var(--target);
  font-weight: 800; font-size: var(--text-22); letter-spacing: -0.035em; line-height: 1;
  color: inherit; text-decoration: none;
}
.wordmark svg { width: 1.05em; height: 1.05em; flex: none; }
.wordmark:hover { text-decoration: none; }

/* ---------- Island: the black notch ---------- */
.island { background: var(--island); color: var(--on-island); border-radius: 0 0 var(--radius-island) var(--radius-island); }
.island--status {
  display: inline-flex; align-items: center; gap: var(--space-3); height: 40px; padding: 0 var(--space-5) 0 var(--space-4);
  font-size: var(--text-14); font-weight: 520; white-space: nowrap; max-width: 100%;
}
.island--floating { border-radius: var(--radius-pill); }
.island__text { overflow: hidden; text-overflow: ellipsis; }
.island__signal { flex: none; display: inline-flex; align-items: center; justify-content: center; gap: 3px; width: 22px; height: 16px; }
.island__signal i { display: none; }
.island[data-state="idle"] .island__signal::after,
.island[data-state="speaking"] .island__signal::after {
  content: ""; width: 13px; height: 13px; background: var(--accent);
  clip-path: polygon(15% 0, 100% 55%, 50% 62%, 32% 100%);
}
.island[data-state="speaking"] .island__signal::after { filter: drop-shadow(0 0 5px var(--accent)); }
.island[data-state="listening"] .island__signal i { display: block; width: 3px; height: 6px; border-radius: 2px; background: var(--listening); animation: opie-level 0.8s ease-in-out infinite; }
.island[data-state="listening"] .island__signal i:nth-child(2) { animation-delay: -0.25s; }
.island[data-state="listening"] .island__signal i:nth-child(3) { animation-delay: -0.5s; }
.island[data-state="listening"] .island__text { color: var(--listening-ink); }
.island[data-state="thinking"] .island__signal i { display: block; width: 5px; height: 5px; border-radius: 50%; background: var(--thinking); animation: opie-blink 1s ease-in-out infinite; }
.island[data-state="thinking"] .island__signal i:nth-child(2) { animation-delay: 0.18s; }
.island[data-state="thinking"] .island__signal i:nth-child(3) { animation-delay: 0.36s; }
.island[data-state="thinking"] .island__text { color: var(--thinking-ink); }
.island[data-state="working"] .island__signal::after {
  content: ""; width: 13px; height: 13px; border-radius: 50%;
  border: 2px solid rgba(59, 130, 246, 0.3); border-top-color: var(--accent); animation: opie-turn 0.8s linear infinite;
}
@keyframes opie-level { 50% { height: 15px; } }
@keyframes opie-blink { 50% { opacity: 0.25; } }
@keyframes opie-turn { to { transform: rotate(360deg); } }

/* ---------- Nav: the site's notch island ---------- */
.nav { position: sticky; top: 0; z-index: 40; display: flex; justify-content: center; padding-inline: var(--space-3); pointer-events: none; }
.nav__island {
  pointer-events: auto; width: min(100%, 900px);
  display: grid; grid-template-columns: auto 1fr; align-items: center; column-gap: var(--space-4);
  padding: var(--space-1) var(--space-2) var(--space-1) var(--space-5);
  box-shadow: var(--shadow-island);
}
.nav__brand { color: var(--on-island); font-size: var(--text-22); }
.nav__toggle { display: none; }
.nav__menu { display: block; min-width: 0; }
.nav__menu-inner { display: flex; align-items: center; justify-content: space-between; gap: var(--space-4); }
.nav__links { display: flex; align-items: center; gap: var(--space-1); list-style: none; padding: 0; margin: 0 auto; }
.nav__link {
  position: relative; display: inline-flex; align-items: center; min-height: var(--target); padding: 0 var(--space-3);
  border-radius: var(--radius-pill); color: var(--on-island-muted); font-weight: 560; text-decoration: none; white-space: nowrap;
  transition: color var(--dur-fast), background-color var(--dur-fast);
}
.nav__link:hover { color: var(--on-island); background: rgba(255, 255, 255, 0.08); text-decoration: none; }
.nav__link[aria-current="page"] { color: var(--on-island); }
.nav__link[aria-current="page"]::after {
  content: ""; position: absolute; left: var(--space-3); right: var(--space-3); bottom: 7px; height: 6px;
  background: var(--accent); -webkit-mask: var(--opie-underline) center / 100% 100% no-repeat; mask: var(--opie-underline) center / 100% 100% no-repeat;
}
.nav__actions { display: flex; align-items: center; gap: var(--space-2); }

@media (max-width: 860px) {
  .nav__island { width: min(100%, 520px); grid-template-columns: 1fr auto; padding-left: var(--space-4); }
  .nav__toggle {
    display: inline-flex; align-items: center; justify-content: center; gap: var(--space-2);
    min-width: var(--target); min-height: var(--target); padding: 0 var(--space-3); border: 0; border-radius: var(--radius-pill);
    background: transparent; color: var(--on-island); font-weight: 560; cursor: pointer;
  }
  .nav__toggle:hover { background: rgba(255, 255, 255, 0.08); }
  .nav__toggle svg { width: 18px; height: 18px; }
  .nav__toggle .nav__toggle-close { display: none; }
  .nav__toggle[aria-expanded="true"] .nav__toggle-open { display: none; }
  .nav__toggle[aria-expanded="true"] .nav__toggle-close { display: block; }
  .nav__menu {
    grid-column: 1 / -1; display: grid; grid-template-rows: 0fr; visibility: hidden;
    transition: grid-template-rows var(--dur) var(--ease-out), visibility 0s linear var(--dur);
  }
  /* overflow clips the collapsed menu; the inline padding (cancelled by the margin) leaves room for focus rings. */
  .nav__menu-inner { overflow: hidden; min-height: 0; flex-direction: column; align-items: stretch; gap: 0; padding-inline: 6px; margin-inline: -6px; }
  .nav__island[data-open] .nav__menu { grid-template-rows: 1fr; visibility: visible; transition: grid-template-rows var(--dur) var(--ease-out); }
  .nav__links { flex-direction: column; align-items: stretch; margin: var(--space-2) 0 0; gap: 0; }
  .nav__link { width: 100%; font-size: var(--text-18); padding: 0 var(--space-2); border-radius: var(--radius-field); }
  .nav__link[aria-current="page"]::after { left: var(--space-2); right: auto; width: 4em; }
  .nav__actions { justify-content: space-between; padding: var(--space-3) 0 var(--space-3); margin-top: var(--space-2); border-top: 1px solid var(--on-island-line); }
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: var(--space-2);
  min-height: 48px; padding: 0 var(--space-6); border: 1.5px solid transparent; border-radius: var(--radius-pill);
  font-size: var(--text-16); font-weight: 680; line-height: 1.1; letter-spacing: -0.005em; text-align: center; text-decoration: none;
  cursor: pointer; user-select: none; -webkit-tap-highlight-color: transparent;
  transition: background-color var(--dur-fast), color var(--dur-fast), border-color var(--dur-fast), transform var(--dur-fast);
}
.btn:hover { text-decoration: none; }
.btn:active { transform: translateY(1px); }
.btn svg { width: 1.15em; height: 1.15em; flex: none; }
.btn--primary { background: var(--island); color: var(--on-island); }
.btn--primary:hover { background: var(--island-hover); }
.btn--secondary { background: var(--sheet); color: var(--ink); border-color: var(--ink); }
.btn--secondary:hover { background: var(--paper); }
.btn--quiet { background: transparent; color: var(--ink); padding-inline: var(--space-4); }
.btn--quiet:hover { background: rgba(20, 26, 38, 0.06); }
.btn--danger { background: var(--sheet); color: var(--danger); border-color: var(--danger); }
.btn--danger:hover { background: var(--danger-wash); }
.btn--sm { min-height: var(--target); padding-inline: var(--space-4); font-size: var(--text-14); }
.btn--lg { min-height: 56px; padding-inline: var(--space-8); font-size: var(--text-18); }
.btn--block { display: flex; width: 100%; }
.btn[disabled], .btn[aria-disabled="true"] { opacity: 0.45; cursor: not-allowed; pointer-events: none; }
.btn[aria-busy="true"] { cursor: progress; }
.btn[aria-busy="true"]::before {
  content: ""; width: 1em; height: 1em; border-radius: 50%; border: 2px solid currentColor; border-right-color: transparent;
  animation: opie-turn 0.8s linear infinite;
}
/* On black surfaces the primary inverts and the others follow. */
.island .btn--primary, .card--island .btn--primary, .plan--featured .btn--primary { background: var(--on-island); color: var(--island); }
.island .btn--primary:hover, .card--island .btn--primary:hover, .plan--featured .btn--primary:hover { background: var(--on-island-hover); }
.island .btn--secondary, .card--island .btn--secondary, .plan--featured .btn--secondary { background: transparent; color: var(--on-island); border-color: var(--on-island-muted); }
.island .btn--quiet, .card--island .btn--quiet, .plan--featured .btn--quiet { color: var(--on-island); }
.island .btn--quiet:hover, .card--island .btn--quiet:hover, .plan--featured .btn--quiet:hover { background: rgba(255, 255, 255, 0.1); }

/* ---------- Pills ---------- */
.pill {
  display: inline-flex; align-items: center; gap: 0.45em; min-height: 28px; padding: 0 0.8em;
  border-radius: var(--radius-pill); background: var(--sheet); box-shadow: inset 0 0 0 1px var(--line);
  font-size: var(--text-14); font-weight: 600; line-height: 1; color: var(--ink); white-space: nowrap;
}
.pill--accent { background: var(--accent-wash); box-shadow: none; color: var(--accent-ink-strong); }
.pill--island { background: var(--island); box-shadow: none; color: var(--on-island); }
.pill--success { background: var(--success-wash); box-shadow: none; color: var(--success); }
.pill--warning { background: var(--warning-wash); box-shadow: none; color: var(--warning); }
.pill--danger { background: var(--danger-wash); box-shadow: none; color: var(--danger); }
.pill__dot { width: 0.5em; height: 0.5em; border-radius: 50%; background: currentColor; flex: none; }
.card--island .pill, .plan--featured .pill { background: rgba(255, 255, 255, 0.12); box-shadow: none; color: var(--on-island); }
.card--island .pill--accent, .plan--featured .pill--accent { background: var(--accent-ink); color: var(--on-island); }

/* ---------- Cards and rows ---------- */
.card {
  position: relative; padding: clamp(var(--space-5), 3vw, var(--space-8)); border-radius: var(--radius-card);
  background: var(--sheet); box-shadow: inset 0 0 0 1px var(--line);
}
.card--raised { box-shadow: inset 0 0 0 1px var(--line), var(--shadow-sheet); }
.card--island { background: var(--island); color: var(--on-island); box-shadow: var(--shadow-island); }
.card--island .muted, .card--island .card__text { color: var(--on-island-muted); }
.card--island a:not(.btn) { color: var(--on-island); }
.card__title { font-size: var(--text-22); }
.card__text { color: var(--muted); }
.card > * + * { margin-top: var(--space-3); }
.card__actions { display: flex; flex-wrap: wrap; gap: var(--space-3); padding-top: var(--space-3); }

.rows { list-style: none; padding: 0; margin: 0; border-radius: var(--radius-card); background: var(--sheet); box-shadow: inset 0 0 0 1px var(--line); }
.row { display: flex; flex-wrap: wrap; align-items: center; gap: var(--space-3) var(--space-4); padding: var(--space-4) var(--space-5); min-height: 64px; }
.row + .row { border-top: 1px solid var(--line); }
.row__main { flex: 1 1 14em; min-width: 0; }
.row__title { font-weight: var(--weight-strong); }
.row__meta { font-size: var(--text-14); color: var(--muted); }

.notice {
  display: flex; gap: var(--space-3); align-items: flex-start; padding: var(--space-4) var(--space-5);
  border-radius: var(--radius-field); background: var(--accent-wash); color: var(--ink); font-size: var(--text-16);
}
.notice::before { content: ""; flex: none; width: 4px; align-self: stretch; border-radius: 2px; background: var(--accent); }
.notice a { color: var(--accent-ink-strong); }
.notice--warning { background: var(--warning-wash); }
.notice--warning::before { background: var(--warning); }
.notice--danger { background: var(--danger-wash); }
.notice--danger::before { background: var(--danger); }

.frame { padding: clamp(6px, 1vw, 10px); border-radius: var(--radius-island); background: var(--island); box-shadow: 0 40px 90px -40px rgba(20, 26, 38, 0.55); }
.frame > img, .frame > video, .frame > picture img { width: 100%; border-radius: calc(var(--radius-island) - 8px); background: var(--island); }

/* ---------- Plan cards ---------- */
/* Three plans side by side when the row is at least 840px wide, otherwise one per row (never 2 + 1). */
.plans {
  --plans-gap: var(--space-5);
  display: grid; gap: var(--plans-gap); align-items: stretch;
  grid-template-columns: repeat(auto-fit, minmax(max(calc((100% - 2 * var(--plans-gap)) / 3), min(100%, calc((840px - 100%) * 999))), 1fr));
}
.plan {
  display: flex; flex-direction: column; gap: var(--space-4); padding: var(--space-8) var(--space-6) var(--space-6);
  border-radius: var(--radius-card); background: var(--sheet); box-shadow: inset 0 0 0 1px var(--line);
}
.plan--quiet { background: transparent; box-shadow: inset 0 0 0 1.5px var(--line-strong); }
.plan--featured { background: var(--island); color: var(--on-island); box-shadow: var(--shadow-island); }
.plan__head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: var(--space-2); }
.plan__name { font-size: var(--text-28); letter-spacing: -0.03em; }
.plan__price { display: grid; gap: var(--space-2); padding-block: var(--space-2); justify-items: start; }
.plan__amount { font-size: var(--text-40); font-weight: 780; letter-spacing: -0.04em; line-height: 1; white-space: nowrap; }
.plan__period { font-size: var(--text-14); color: var(--muted); }
.plan--featured .plan__period, .plan--featured .plan__text { color: var(--on-island-muted); }
.plan__text { color: var(--muted); }
.plan__features { list-style: none; padding: 0; margin: 0 0 auto; display: grid; gap: var(--space-2); }
.plan__features li { position: relative; padding-left: 30px; }
.plan__features li::before {
  content: ""; position: absolute; left: 0; top: 0.2em; width: 20px; height: 17px; background: var(--accent);
  -webkit-mask: var(--opie-check) center / contain no-repeat; mask: var(--opie-check) center / contain no-repeat;
}
.plan__cta { margin-top: var(--space-4); }
.plan__fine { font-size: var(--text-12); color: var(--muted); text-align: center; }
.plan--featured .plan__fine { color: var(--on-island-muted); }

/* ---------- Usage bar ---------- */
.usage { display: grid; gap: var(--space-2); }
.usage__head { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: var(--space-1) var(--space-4); }
.usage__label { font-weight: var(--weight-strong); }
.usage__value { font-size: var(--text-14); color: var(--muted); font-variant-numeric: tabular-nums; }
.usage__track { position: relative; height: 10px; border-radius: var(--radius-pill); background: var(--line); overflow: hidden; }
.usage__fill {
  position: absolute; left: 0; top: 0; bottom: 0; width: clamp(0%, var(--value, 0%), 100%);
  border-radius: inherit; background: var(--accent); transition: width var(--dur-slow) var(--ease-out);
}
.usage__note { font-size: var(--text-14); color: var(--muted); }
.usage--high .usage__fill { background: var(--warning); }
.usage--high .usage__value { color: var(--warning); }
.usage--empty .usage__fill { background: var(--danger); }
.usage--empty .usage__value { color: var(--danger); }
.card--island .usage__track { background: rgba(255, 255, 255, 0.16); }
.card--island .usage__value, .card--island .usage__note { color: var(--on-island-muted); }

/* ---------- Tabs ---------- */
.tabs__list {
  display: flex; gap: var(--space-1); overflow-x: auto; scrollbar-width: none;
  box-shadow: inset 0 -1px 0 var(--line); margin-bottom: var(--space-6);
}
.tabs__list::-webkit-scrollbar { display: none; }
.tabs__tab {
  position: relative; flex: none; min-height: var(--target); padding: 0 var(--space-4) var(--space-1); border: 0; background: none;
  color: var(--muted); font-weight: 600; cursor: pointer; border-radius: var(--radius-small) var(--radius-small) 0 0;
}
.tabs__tab:hover { color: var(--ink); }
@media (max-width: 480px) { .tabs__tab { padding-inline: var(--space-3); } .tabs__tab[aria-selected="true"]::after { left: var(--space-2); right: var(--space-2); } }
.tabs__tab:focus-visible { outline-offset: -3px; }
.tabs__tab[aria-selected="true"] { color: var(--ink); }
.tabs__tab[aria-selected="true"]::after {
  content: ""; position: absolute; left: var(--space-3); right: var(--space-3); bottom: 0; height: 7px;
  background: var(--accent); -webkit-mask: var(--opie-underline) center / 100% 100% no-repeat; mask: var(--opie-underline) center / 100% 100% no-repeat;
}

/* ---------- Toggle ---------- */
.toggle { display: flex; align-items: center; justify-content: space-between; gap: var(--space-4); min-height: var(--target); cursor: pointer; }
.toggle__text { display: grid; gap: 2px; }
.toggle__label { font-weight: var(--weight-strong); }
.toggle__hint { font-size: var(--text-14); color: var(--muted); }
.toggle__input { position: absolute; opacity: 0; width: 1px; height: 1px; margin: 0; }
.toggle__track {
  position: relative; flex: none; width: 48px; height: 28px; border-radius: var(--radius-pill);
  background: var(--control); transition: background-color var(--dur-fast);
}
.toggle__track::after {
  content: ""; position: absolute; left: 3px; top: 3px; width: 22px; height: 22px; border-radius: 50%;
  background: var(--sheet); box-shadow: 0 1px 3px rgba(20, 26, 38, 0.3); transition: transform var(--dur) var(--ease-spring);
}
.toggle__input:checked + .toggle__track { background: var(--accent); }
.toggle__input:checked + .toggle__track::after { transform: translateX(20px); }
.toggle__input:focus-visible + .toggle__track { outline: var(--focus); outline-offset: var(--focus-offset); }
.toggle__input:disabled + .toggle__track { opacity: 0.45; }
.toggle:has(.toggle__input:disabled) { cursor: not-allowed; }

/* ---------- Fields ---------- */
.field { display: grid; gap: var(--space-2); }
.field__label { font-weight: var(--weight-strong); }
.field__hint { font-size: var(--text-14); color: var(--muted); }
.field__error { font-size: var(--text-14); color: var(--danger); font-weight: 560; }
.field__input {
  width: 100%; min-height: 48px; padding: var(--space-3) var(--space-4); border: 1.5px solid var(--control);
  border-radius: var(--radius-field); background: var(--sheet); color: var(--ink); font-size: var(--text-16);
  transition: border-color var(--dur-fast);
}
.field__input::placeholder { color: var(--placeholder); opacity: 1; }
.field__input:hover { border-color: var(--muted); }
.field__input:focus-visible { outline: var(--focus); outline-offset: 0; border-color: var(--accent); }
.field__input[aria-invalid="true"] { border-color: var(--danger); }
textarea.field__input { min-height: 120px; resize: vertical; line-height: var(--leading-body); }
select.field__input {
  appearance: none; padding-right: var(--space-10);
  background: var(--sheet) no-repeat right 14px center / 14px 14px
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 14 14'%3E%3Cpath d='M3 5l4 4 4-4' fill='none' stroke='%23141A26' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
}

/* ---------- Code input (6 boxes, built by opie.js from one input) ---------- */
.code { display: grid; grid-template-columns: repeat(6, minmax(0, 56px)); gap: var(--space-2); }
.code__box {
  width: 100%; height: 60px; padding: 0; border: 1.5px solid var(--control); border-radius: var(--radius-field);
  background: var(--sheet); color: var(--ink); text-align: center;
  font-size: var(--text-28); font-weight: 700; font-variant-numeric: tabular-nums; caret-color: var(--accent);
}
.code__box:focus-visible { outline: var(--focus); outline-offset: 0; border-color: var(--accent); }
.code__box:not(:placeholder-shown) { border-color: var(--ink); }
.code--done .code__box { border-color: var(--accent); }
.code__box[aria-invalid="true"], .code--done .code__box[aria-invalid="true"] { border-color: var(--danger); }
/* Narrow phones: tighter gaps and card padding keep each box at least 44px wide. */
@media (max-width: 400px) {
  .code { gap: var(--space-1); }
  .card { padding: var(--space-4); }
}

/* ---------- Language switch ---------- */
.lang { display: inline-flex; align-items: center; padding: 3px; border-radius: var(--radius-pill); box-shadow: inset 0 0 0 1px var(--line-strong); }
.lang__option {
  display: inline-flex; align-items: center; min-height: var(--target); padding: 0 var(--space-3); border-radius: var(--radius-pill);
  font-size: var(--text-14); font-weight: 600; color: var(--muted); text-decoration: none;
}
.lang__option:hover { color: var(--ink); text-decoration: none; }
.lang__option[aria-current="true"] { background: var(--ink); color: var(--paper); }
.island .lang { box-shadow: inset 0 0 0 1px var(--on-island-line); }
.island .lang__option { color: var(--on-island-muted); }
.island .lang__option:hover { color: var(--on-island); }
.island .lang__option[aria-current="true"] { background: rgba(255, 255, 255, 0.16); color: var(--on-island); }

/* ---------- Footer ---------- */
.footer { margin-top: var(--space-24); padding-block: var(--space-12) var(--space-10); border-top: 1px solid var(--line); color: var(--muted); font-size: var(--text-14); }
.footer__inner { display: grid; gap: var(--space-10); grid-template-columns: minmax(0, 1.1fr) minmax(0, 2fr); }
.footer__brand { display: grid; gap: var(--space-2); align-content: start; }
.footer__brand .wordmark { color: var(--ink); justify-self: start; }
.footer__nav { display: grid; gap: var(--space-6); grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); }
.footer__heading { font-size: var(--text-14); font-weight: 700; letter-spacing: 0; color: var(--ink); margin-bottom: var(--space-2); }
.footer__list { list-style: none; padding: 0; margin: 0; }
.footer__list a { display: inline-flex; align-items: center; min-height: var(--target); color: var(--muted); text-decoration: none; }
.footer__list a:hover { color: var(--ink); text-decoration: underline; }
.footer__base { grid-column: 1 / -1; display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: var(--space-4); padding-top: var(--space-6); border-top: 1px solid var(--line); }
@media (max-width: 720px) { .footer__inner { grid-template-columns: minmax(0, 1fr); } }

/* ---------- Toasts: the island speaks ---------- */
.toasts {
  position: fixed; left: 50%; top: 72px; z-index: 60; transform: translateX(-50%);
  display: grid; justify-items: center; gap: var(--space-2); width: max-content; max-width: calc(100vw - 2 * var(--space-4)); pointer-events: none;
}
.toast {
  display: inline-flex; align-items: center; gap: var(--space-3); max-width: 100%; min-height: 44px; padding: var(--space-2) var(--space-5) var(--space-2) var(--space-4);
  border-radius: var(--radius-pill); background: var(--island); color: var(--on-island); box-shadow: var(--shadow-pop);
  font-size: var(--text-14); font-weight: 560; pointer-events: auto;
  animation: opie-toast-in var(--dur) var(--ease-spring);
}
.toast__icon { flex: none; width: 16px; height: 16px; color: var(--accent); }
.toast--success .toast__icon { color: var(--success-on-island); }
.toast--error .toast__icon { color: var(--danger-on-island); }
.toast.is-leaving { opacity: 0; transform: translateY(-6px) scale(0.97); transition: opacity var(--dur-fast), transform var(--dur-fast); }
@keyframes opie-toast-in { from { opacity: 0; transform: translateY(-10px) scale(0.94); } }

/* ---------- Disclosure (FAQ) ---------- */
.disclosure { border-top: 1px solid var(--line); }
.disclosure:last-of-type { border-bottom: 1px solid var(--line); }
.disclosure__summary {
  display: flex; align-items: center; justify-content: space-between; gap: var(--space-4); min-height: 60px; padding: var(--space-3) 0;
  font-size: var(--text-18); font-weight: 640; cursor: pointer; list-style: none;
}
.disclosure__summary::-webkit-details-marker { display: none; }
.disclosure__summary::after {
  content: ""; flex: none; width: 14px; height: 14px; background: currentColor; transition: transform var(--dur) var(--ease-out);
  clip-path: polygon(42% 0, 58% 0, 58% 42%, 100% 42%, 100% 58%, 58% 58%, 58% 100%, 42% 100%, 42% 58%, 0 58%, 0 42%, 42% 42%);
}
.disclosure[open] > .disclosure__summary::after { transform: rotate(45deg); }
.disclosure__body { padding: 0 0 var(--space-5); max-width: var(--measure); color: var(--muted); }
.disclosure__body > * + * { margin-top: var(--space-3); }

/* ---------- Table ---------- */
.table-wrap { overflow-x: auto; border-radius: var(--radius-card); box-shadow: inset 0 0 0 1px var(--line); background: var(--sheet); }
.table { width: 100%; border-collapse: collapse; font-size: var(--text-14); }
.table th, .table td { padding: var(--space-3) var(--space-4); text-align: left; vertical-align: top; }
.table th { font-weight: 700; color: var(--ink); white-space: nowrap; }
.table tr + tr td, .table thead + tbody tr td { border-top: 1px solid var(--line); }

/* ---------- Steps (a real sequence only) ---------- */
.steps { list-style: none; padding: 0; margin: 0; display: grid; gap: var(--space-8); grid-template-columns: repeat(auto-fit, minmax(min(100%, 240px), 1fr)); counter-reset: opie-step; }
.steps__item { display: grid; gap: var(--space-2); align-content: start; }
.steps__num { position: relative; display: inline-flex; align-items: center; justify-content: center; width: 52px; height: 52px; font-size: var(--text-22); font-weight: 800; }
.steps__title { font-size: var(--text-22); margin-top: var(--space-2); }
.steps__text { color: var(--muted); }

/* ---------- Marks: what the pen draws ---------- */
.mark { position: relative; }
:where(span.mark--circle, span.mark--underline, strong.mark--circle, strong.mark--underline, em.mark--underline) { display: inline-block; }
.mark__ink { position: absolute; max-width: none; overflow: visible; pointer-events: none; fill: none; stroke: var(--accent); stroke-width: 3; stroke-linecap: round; stroke-linejoin: round; }
.mark__ink path { stroke-dasharray: 1; stroke-dashoffset: 0; vector-effect: non-scaling-stroke; }
.mark--circle .mark__ink { left: -0.55em; top: -0.32em; width: calc(100% + 1.15em); height: calc(100% + 0.62em); }
.steps__num.mark--circle .mark__ink { inset: -2px; width: calc(100% + 4px); height: calc(100% + 4px); }
.mark--underline .mark__ink { left: -0.08em; right: -0.08em; bottom: -0.32em; width: calc(100% + 0.16em); height: 0.42em; }
.mark--arrow .mark__ink { left: -0.7em; bottom: calc(100% - 0.12em); width: 2em; height: 1.35em; }
/* Entrance: each mark draws itself once when it first comes into view. */
.mark.is-pending .mark__ink path { stroke-dashoffset: 1; }
.mark.is-drawing .mark__ink path { transition: stroke-dashoffset var(--dur-draw) var(--ease-out); transition-delay: var(--mark-delay, 0ms); }
.mark.is-drawing .mark__ink path + path { transition-duration: 260ms; transition-delay: calc(var(--mark-delay, 0ms) + var(--dur-draw) - 200ms); }

/* Hand-drawn shapes reused as masks */
:root {
  --opie-underline: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 100 8' preserveAspectRatio='none'%3E%3Cpath d='M2 5.5C24 2.6 60 1.8 98 4' fill='none' stroke='%23000' stroke-width='3' stroke-linecap='round'/%3E%3C/svg%3E");
  --opie-check: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 22 18'%3E%3Cpath d='M2.5 9.5C4.6 11 6.4 13 7.8 15.4C10.6 9.6 14.6 5.4 19.6 2.6' fill='none' stroke='%23000' stroke-width='2.6' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
}

/* =====================================================================
   Site pages (tryopie.com): page layouts only. Components above stay the
   building blocks; nothing here restyles a component outside its page block.
   ===================================================================== */

/* ---------- Shared page scaffolding ---------- */
.page-head { display: grid; gap: var(--space-5); padding-block: clamp(var(--space-12), 8vw, var(--space-20)) clamp(var(--space-6), 4vw, var(--space-12)); }
.page-head .lede { max-width: 36em; }
.page-head--center { justify-items: center; text-align: center; }
.page-head--center .lede { margin-inline: auto; }
.section-head { display: grid; gap: var(--space-4); margin-bottom: clamp(var(--space-8), 5vw, var(--space-12)); max-width: 40em; }
.section-head .lede { font-size: var(--text-18); }
.narrow { max-width: 30rem; margin-inline: auto; }
.measure { max-width: var(--measure); }
.rule { border: 0; border-top: 1px solid var(--line); margin: 0; }
.link-row { display: flex; flex-wrap: wrap; gap: var(--space-2) var(--space-6); }
.check-list { list-style: none; padding: 0; margin: 0; display: grid; gap: var(--space-3); }
.check-list li { position: relative; padding-left: 32px; }
.check-list li::before {
  content: ""; position: absolute; left: 0; top: 0.2em; width: 20px; height: 17px; background: var(--accent);
  -webkit-mask: var(--opie-check) center / contain no-repeat; mask: var(--opie-check) center / contain no-repeat;
}
.legal-draft { margin-bottom: var(--space-8); }

.page-head--flush { padding-top: 0; }
.section-title { margin-bottom: var(--space-8); }
.split__card { align-self: start; }

/* ---------- Landing: hero, where the pen points at the page itself ---------- */
.hero { position: relative; padding-block: clamp(var(--space-12), 8vw, var(--space-20)) clamp(var(--space-10), 6vw, var(--space-16)); }
.hero__title { max-width: 12ch; }
@media (min-width: 720px) { .hero__title { max-width: none; } .hero__line { display: block; } }
/* The ring around the download button sits well clear of it, so it reads as the pen and not as a focus ring. */
.hero [data-hero-target].mark--circle .mark__ink { left: -22px; top: -16px; width: calc(100% + 44px); height: calc(100% + 32px); }
.hero__lede { margin-top: var(--space-6); max-width: 31em; }
.hero__actions { margin-top: var(--space-10); --cluster: var(--space-6) var(--space-10); }
.hero__fine { margin-top: var(--space-12); font-size: var(--text-14); color: var(--muted); }
.hero__pen, .hero__tag { position: absolute; left: 0; top: 0; pointer-events: none; opacity: 0; }
.hero__pen {
  width: 30px; height: 30px; z-index: 2;
  filter: drop-shadow(0 0 8px rgba(59, 130, 246, 0.6)) drop-shadow(0 2px 3px rgba(0, 0, 0, 0.2));
  transform: translate(var(--pen-x0, 0), var(--pen-y0, 0));
}
.hero__pen.is-moving { opacity: 1; transform: translate(var(--pen-x1, 0), var(--pen-y1, 0)); transition: transform 1100ms var(--ease-out), opacity var(--dur-fast); }
.hero__pen.is-there { opacity: 1; transform: translate(var(--pen-x1, 0), var(--pen-y1, 0)); }
.hero__tag {
  z-index: 2; padding: 6px 12px; border-radius: var(--radius-pill); background: var(--accent); color: var(--on-island);
  font: 700 var(--text-14)/1 var(--font-pen); box-shadow: 0 6px 18px -6px rgba(59, 130, 246, 0.7);
  transform: translate(calc(var(--pen-x1, 0) + 30px), calc(var(--pen-y1, 0) + 26px)) scale(0.6); transform-origin: 0 0;
}
.hero__tag.is-shown { opacity: 1; transform: translate(calc(var(--pen-x1, 0) + 30px), calc(var(--pen-y1, 0) + 26px)); transition: transform var(--dur) var(--ease-spring), opacity var(--dur-fast); }

/* ---------- Landing: demo video ---------- */
.demo { display: grid; gap: var(--space-4); }
.demo__stage { position: relative; }
.demo__toggle {
  position: absolute; right: clamp(14px, 2vw, 22px); bottom: clamp(14px, 2vw, 22px); z-index: 1;
  display: inline-flex; align-items: center; justify-content: center; width: var(--target); height: var(--target);
  border: 0; border-radius: var(--radius-pill); background: rgba(0, 0, 0, 0.72); color: var(--on-island); cursor: pointer;
}
.demo__toggle:hover { background: var(--island); }
.demo__toggle svg { width: 16px; height: 16px; }
.demo__toggle .demo__play { display: none; }
.demo__toggle[aria-pressed="true"] .demo__play { display: block; }
.demo__toggle[aria-pressed="true"] .demo__pause { display: none; }
.demo__caption { color: var(--muted); font-size: var(--text-14); max-width: 46em; }

/* ---------- Landing: what Opie does, one scene per row ---------- */
.features { display: grid; gap: clamp(var(--space-12), 8vw, var(--space-20)); }
.feature { display: grid; gap: var(--space-8); align-items: center; grid-template-columns: minmax(0, 1fr); }
.feature__text { display: grid; gap: var(--space-3); max-width: 30em; }
.feature__text p { color: var(--muted); font-size: var(--text-18); }
@media (min-width: 900px) {
  .feature { grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: var(--space-16); }
  .feature:nth-child(even) { grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); }
  .feature:nth-child(even) .feature__text { order: 2; }
}

/* A drawing of a screen with Opie at work. Sizes follow the drawing's own width. */
.mock {
  container-type: inline-size; position: relative; aspect-ratio: 16 / 10; overflow: hidden;
  border-radius: calc(var(--radius-island) - 8px); background: var(--line); color: var(--ink);
}
.mock__in { position: absolute; inset: 0; font-size: clamp(9px, calc(2.1cqi + 2px), 15px); line-height: 1.25; }
@media (max-width: 600px) { .mock { aspect-ratio: 4 / 3.3; } }
.mock .island--status { position: absolute; top: 0; left: 50%; transform: translateX(-50%); z-index: 2; height: 2.9em; padding: 0 1.3em 0 1em; gap: 0.7em; font-size: 1em; max-width: 84%; }
.mock .island__signal { width: 1.4em; height: 1em; }
.mock__win {
  position: absolute; left: 7%; right: 7%; top: 18%; bottom: 7%; display: flex; flex-direction: column;
  border-radius: 0.8em; background: var(--sheet); box-shadow: var(--shadow-sheet);
}
.mock__bar { display: flex; align-items: center; gap: 0.45em; padding: 0.7em 1em; border-bottom: 1px solid var(--line); font-weight: 680; }
.mock__bar i { width: 0.7em; height: 0.7em; border-radius: 50%; background: var(--line-strong); }
.mock__bar b { margin-left: 0.6em; font-weight: 680; }
.mock__body { position: relative; flex: 1; display: grid; align-content: start; gap: 0.9em; padding: 1.2em 1.4em; min-height: 0; }
.mock__row { display: flex; flex-wrap: wrap; align-items: center; gap: 0.6em; }
.mock__chip { position: relative; display: inline-flex; align-items: center; padding: 0.45em 0.85em; border-radius: 0.55em; background: var(--paper); font-weight: 620; white-space: nowrap; }
.mock__chip--solid { background: var(--ink); color: var(--sheet); }
.mock__line { height: 0.62em; border-radius: var(--radius-pill); background: var(--paper); }
.mock__title { font-size: 1.25em; font-weight: 720; letter-spacing: -0.01em; }
.mock__pen { position: absolute; width: 1.9em; height: 1.9em; z-index: 3; filter: drop-shadow(0 0 0.4em rgba(59, 130, 246, 0.65)) drop-shadow(0 1px 2px rgba(0, 0, 0, 0.25)); }
.mock__tag { position: absolute; z-index: 3; padding: 0.4em 0.75em; border-radius: var(--radius-pill); background: var(--accent); color: var(--on-island); font: 700 1em/1 var(--font-pen); white-space: nowrap; box-shadow: 0 0.4em 1.1em -0.4em rgba(59, 130, 246, 0.7); }
.mock .mark--circle .mark__ink { stroke-width: 2.5; left: -0.75em; top: -0.55em; width: calc(100% + 1.5em); height: calc(100% + 1.1em); }

/* Mail: where is Archive? */
.mock__mail { display: grid; grid-template-columns: 2fr 3fr; gap: 1.2em; min-height: 0; margin-top: 2.4em; }
.mock__list { display: grid; gap: 0.55em; align-content: start; }
.mock__item { display: grid; gap: 0.4em; padding: 0.6em 0.7em; border-radius: 0.5em; }
.mock__item--on { background: var(--accent-wash); }
.mock__read { display: grid; gap: 0.6em; align-content: start; }
/* Lesson: step by step */
.mock__drop { display: grid; place-items: center; height: 4.2em; border: 1.5px dashed var(--line-strong); border-radius: 0.6em; color: var(--muted); font-weight: 560; }
.mock__step { position: absolute; right: 1.4em; top: 1.1em; }
.mock__step .pill { min-height: 0; padding: 0.35em 0.7em; font-size: 0.9em; }
/* Explain: a note with a drawing */
.mock__note { position: absolute; left: 6%; top: 21%; width: 47%; display: grid; align-content: start; gap: 0.75em; padding: 1.2em 1.3em; border-radius: 0.8em; background: var(--sheet); box-shadow: var(--shadow-sheet); }
.mock__flow { list-style: none; margin: 0; padding: 0; display: grid; gap: 0.5em; counter-reset: flow; }
.mock__flow li { position: relative; display: flex; align-items: center; gap: 0.6em; padding: 0.45em 0.6em; border-radius: 0.5em; background: var(--paper); font-weight: 600; counter-increment: flow; }
.mock__flow li::before { content: counter(flow); display: inline-grid; place-items: center; flex: none; width: 1.5em; height: 1.5em; border-radius: 50%; background: var(--sheet); font-size: 0.85em; font-weight: 760; box-shadow: inset 0 0 0 1px var(--line-strong); }
.mock__flow li.is-on { background: var(--accent-wash); }
.mock__art { position: absolute; right: 4%; top: 22%; width: 42%; height: 66%; }
.mock__art svg { width: 100%; height: 100%; overflow: visible; }
/* Do it: reminders and a question before saving */
.mock__task { display: flex; align-items: center; gap: 0.7em; padding: 0.55em 0.2em; border-bottom: 1px solid var(--line); }
.mock__task i { width: 1em; height: 1em; flex: none; border-radius: 50%; box-shadow: inset 0 0 0 1.5px var(--line-strong); }
.mock__task small { margin-left: auto; color: var(--muted); font-size: 0.9em; }
.mock__task--new { background: var(--accent-wash); border-radius: 0.5em; padding-inline: 0.6em; border-bottom-color: transparent; }
.mock__ask {
  position: absolute; right: 5%; bottom: 9%; z-index: 2; display: grid; gap: 0.8em; width: min(60%, 21em); padding: 1em 1.1em;
  border-radius: 1em; background: var(--island); color: var(--on-island); box-shadow: var(--shadow-island); font-weight: 560;
}
.mock__ask .mock__chip { background: rgba(255, 255, 255, 0.14); color: var(--on-island); }
.mock__ask .mock__chip--solid { background: var(--on-island); color: var(--island); }

/* ---------- Landing: smaller sections ---------- */
.split { display: grid; gap: var(--space-10); grid-template-columns: minmax(0, 1fr); }
@media (min-width: 900px) { .split { grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: var(--space-16); } }
@media (min-width: 900px) { .split--text-first { grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); } }
.split__aside { display: grid; gap: var(--space-4); align-content: start; }
.split__aside .lede { font-size: var(--text-18); }
.points { list-style: none; padding: 0; margin: 0; }
.points > li { display: grid; gap: var(--space-2); padding-block: var(--space-6); border-top: 1px solid var(--line); }
.points > li:last-child { border-bottom: 1px solid var(--line); }
.points p { color: var(--muted); }

.privacy { display: grid; gap: var(--space-10); padding: clamp(var(--space-8), 6vw, var(--space-16)); }
@media (min-width: 900px) { .privacy { grid-template-columns: minmax(0, 6fr) minmax(0, 5fr); align-items: start; } }
.privacy__intro { display: grid; gap: var(--space-5); align-content: start; }
.privacy__intro p { color: var(--on-island-muted); font-size: var(--text-18); }
.privacy .check-list li { color: var(--on-island); }
.privacy .check-list li span { display: block; color: var(--on-island-muted); font-size: var(--text-14); margin-top: 2px; }

.ways { display: grid; gap: var(--space-5); grid-template-columns: repeat(auto-fit, minmax(min(100%, 320px), 1fr)); }
.ways .card { display: grid; gap: var(--space-3); align-content: start; }
.ways .card > * + * { margin-top: 0; }

.plans--teaser .plan { padding-top: var(--space-6); }
.plans--teaser .plan__amount { font-size: var(--text-40); }
.teaser-note { margin-top: var(--space-6); color: var(--muted); }

.get-started { display: grid; gap: var(--space-10); }
.get-started__actions { --cluster: var(--space-3); }

/* ---------- Pricing ---------- */
.table-wrap.allowance-table { margin-top: var(--space-12); }
.allowance-table th[scope="row"] { white-space: normal; min-width: 9em; }
.allowance-table td { font-variant-numeric: tabular-nums; }
.price-facts { display: grid; gap: var(--space-8); }
@media (min-width: 900px) { .price-facts { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: var(--space-12); } }
.price-facts > div { display: grid; gap: var(--space-3); align-content: start; }
.price-facts p { color: var(--muted); }

/* ---------- Download ---------- */
.downloads { display: grid; gap: var(--space-5); grid-template-columns: repeat(auto-fit, minmax(min(100%, 340px), 1fr)); align-items: stretch; }
.downloads .card { display: grid; gap: var(--space-4); align-content: start; }
.downloads .card > * + * { margin-top: 0; }
.downloads .card__head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: var(--space-3); }
.downloads .card__head h2 { font-size: var(--text-28); }
.downloads .btn { justify-self: start; margin-top: var(--space-2); }

/* ---------- Sign in, connect ---------- */
.auth { padding-block: clamp(var(--space-10), 7vw, var(--space-20)) 0; }
.auth__card { display: grid; gap: var(--space-5); }
.auth__card > * + * { margin-top: 0; }
.auth__card form { display: grid; gap: var(--space-4); }
.auth__or { display: flex; align-items: center; gap: var(--space-3); color: var(--muted); font-size: var(--text-14); }
.auth__or::before, .auth__or::after { content: ""; flex: 1; border-top: 1px solid var(--line); }
.auth__google svg { width: 18px; height: 18px; }
.auth__note { font-size: var(--text-14); color: var(--muted); }
.auth__after { margin-top: var(--space-6); }
.auth__mark { display: block; }
.auth__actions { display: flex; flex-wrap: wrap; gap: var(--space-2) var(--space-3); }

/* ---------- Account ---------- */
.account { padding-block: clamp(var(--space-10), 6vw, var(--space-16)) 0; }
.account__head { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: var(--space-4); margin-bottom: var(--space-8); }
.account__who { display: grid; gap: var(--space-2); min-width: 0; }
.account__email { color: var(--muted); overflow-wrap: anywhere; }
.account__panel { display: grid; gap: var(--space-6); max-width: 46rem; }
.account__panel .card { display: grid; gap: var(--space-5); }
.account__panel .card > * + * { margin-top: 0; }
.account__plan { display: flex; flex-wrap: wrap; align-items: center; gap: var(--space-3); }
.account__plan h2 { font-size: var(--text-28); letter-spacing: -0.03em; }
.account__invite { display: grid; gap: var(--space-3); grid-template-columns: minmax(0, 1fr); align-items: end; }
@media (min-width: 560px) {
  .account__invite { grid-template-columns: minmax(0, 1fr) auto; align-items: start; }
  /* Line up with the input, below its label, whether or not an error shows under it. */
  .account__invite > .btn { margin-top: calc(1lh + var(--space-2)); }
}
.account__copy { display: grid; gap: var(--space-3); grid-template-columns: minmax(0, 1fr); }
@media (min-width: 560px) { .account__copy { grid-template-columns: minmax(0, 1fr) auto; } }
.account__notice { margin-bottom: var(--space-6); }
.account__notice p { display: flex; flex-wrap: wrap; align-items: center; gap: var(--space-2) var(--space-3); }
.account__copy .btn { align-self: end; }
.account__danger { box-shadow: inset 0 0 0 1.5px var(--danger-wash), inset 0 0 0 1px var(--line); }
.account__loading { padding-block: var(--space-16); color: var(--muted); }
.consent { display: flex; gap: var(--space-3); align-items: flex-start; min-height: var(--target); cursor: pointer; }
.consent input { flex: none; width: 22px; height: 22px; margin: 1px 0 0; accent-color: var(--accent-ink); }

/* ---------- Help ---------- */
.faq { display: grid; gap: var(--space-12); max-width: 48rem; margin-top: var(--space-6); }
.faq h2 { margin-bottom: var(--space-3); }

/* ---------- 404 ---------- */
.lost { padding-block: clamp(var(--space-16), 12vw, var(--space-24)); display: grid; gap: var(--space-6); justify-items: start; }
.lost__en { padding-top: var(--space-6); border-top: 1px solid var(--line); display: grid; gap: var(--space-3); }

/* ---------- Reduced motion ---------- */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 0.01ms !important; animation-iteration-count: 1 !important; transition-duration: 0.01ms !important; transition-delay: 0ms !important; scroll-behavior: auto !important; }
  .mark.is-pending .mark__ink path { stroke-dashoffset: 0; }
  .hero__pen, .hero__tag { transition: none !important; }
}
