/* Theme values are Nowboard's own, from apple/Nowboard/Theme.swift.
   Card sizes come from CardView.swift (Metrics, Mac, roomy). */
:root,
[data-theme="casestudy"] {
  --bg: #F3F1EC; --surface: #FFFFFF; --well: #E6E3DC; --line: #D9D5CC;
  --ink: #151413; --muted: #55524C; --accent: #2352A3; --on-accent: #FFFFFF;
}
[data-theme="braun"] {
  --bg: #ECEAE4; --surface: #F8F7F4; --well: #E0DDD5; --line: #D5D2CA;
  --ink: #1B1B1A; --muted: #57554F; --accent: #E5541B; --on-accent: #FFFFFF;
}
[data-theme="graphite"] {
  --bg: #1D1D1C; --surface: #272725; --well: #2E2E2C; --line: #3B3A37;
  --ink: #EDEBE6; --muted: #A19F99; --accent: #F26B2F; --on-accent: #1D1D1C;
}
[data-theme="aluminium"] {
  --bg: #F5F5F7; --surface: #FFFFFF; --well: #E8E8ED; --line: rgba(0, 0, 0, .09);
  --ink: #1D1D1F; --muted: #5E5E63; --accent: #0071E3; --on-accent: #FFFFFF;
}
[data-theme="spacegrey"] {
  --bg: #161617; --surface: #2C2C2E; --well: #2C2C2E; --line: rgba(255, 255, 255, .1);
  --ink: #F5F5F7; --muted: #A1A1A6; --accent: #2997FF; --on-accent: #FFFFFF;
}
[data-theme="peach"] {
  --bg: #FBF1EA; --surface: #FFFAF6; --well: #F3E3D8; --line: #EEDDD1;
  --ink: #3B2A22; --muted: #5E4A3D; --accent: #EE8E62; --on-accent: #3B2A22;
}
[data-theme="lavender"] {
  --bg: #F1EEFA; --surface: #FBFAFF; --well: #E4DFF4; --line: #E2DCF3;
  --ink: #2B2640; --muted: #524C6B; --accent: #8B74E8; --on-accent: #FFFFFF;
}
[data-theme="plywood"] {
  --bg: #EFE6D6; --surface: #F8F2E7; --well: #E4D8C2; --line: #DCCDB4;
  --ink: #2A2119; --muted: #5C4F42; --accent: #C8431F; --on-accent: #FFFFFF;
}
[data-theme="walnut"] {
  --bg: #271F19; --surface: #33291F; --well: #3B3026; --line: #46392D;
  --ink: #F2E7D5; --muted: #C2B19A; --accent: #F07A43; --on-accent: #271F19;
}

/* Category colours, light and dark (Palette in Theme.swift). [data-theme]
   too, so a swatch inside a dark page still shows its own light colours. */
:root, [data-theme] {
  --violet: #7A55D6; --violet-tint: #E6DDFA;
  --amber: #C98512; --amber-tint: #FAEBCB;
  --teal: #138A7E; --teal-tint: #D3EFEA;
  --slate: #5D6470; --slate-tint: #E3E5E9;
  color-scheme: light;
}
[data-theme="graphite"], [data-theme="spacegrey"], [data-theme="walnut"] {
  --violet: #B9A2FF; --violet-tint: #30284A;
  --amber: #FFC266; --amber-tint: #45361C;
  --teal: #6FE0CF; --teal-tint: #17383A;
  --slate: #B4BAC6; --slate-tint: #2C3038;
  color-scheme: dark;
}
[data-cat="violet"] { --c: var(--violet); --c-tint: var(--violet-tint); }
[data-cat="amber"] { --c: var(--amber); --c-tint: var(--amber-tint); }
[data-cat="teal"] { --c: var(--teal); --c-tint: var(--teal-tint); }
[data-cat="slate"] { --c: var(--slate); --c-tint: var(--slate-tint); }

/* The four families: corner radii and the app's font. */
:root, [data-theme="plywood"], [data-theme="walnut"], [data-theme="casestudy"] {
  --r-s: 8px; --r-l: 16px; --r-c: 10px;
  --font-app: "Avenir Next", "Avenir", -apple-system, BlinkMacSystemFont, sans-serif;
}
[data-theme="braun"], [data-theme="graphite"] {
  --r-s: 4px; --r-l: 8px; --r-c: 4px;
  --font-app: "Helvetica Neue", Helvetica, Arial, sans-serif;
}
[data-theme="aluminium"], [data-theme="spacegrey"] {
  --r-s: 10px; --r-l: 20px; --r-c: 12px;
  --font-app: -apple-system, BlinkMacSystemFont, "SF Pro Display", sans-serif;
}
[data-theme="peach"], [data-theme="lavender"] {
  --r-s: 10px; --r-l: 18px; --r-c: 12px;
  --font-app: "Helvetica Neue", Helvetica, Arial, sans-serif;
}

/* ---------- Base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0; background: var(--bg); color: var(--ink);
  font: 400 18px/1.55 var(--font-app);
  -webkit-font-smoothing: antialiased; overflow-x: clip;
}
img, svg { display: block; max-width: 100%; }
a { color: inherit; }
p { margin: 0; }
h1, h2, h3 { margin: 0; font-weight: 600; letter-spacing: -0.02em; line-height: 1.05; }
h1 { font-size: clamp(44px, 7.4vw, 104px); letter-spacing: -0.035em; }
h2 { font-size: clamp(36px, 5.4vw, 76px); letter-spacing: -0.03em; }
kbd { font: 500 0.85em/1 ui-monospace, "SF Mono", Menlo, monospace; padding: 3px 7px; border: 1px solid var(--line); border-bottom-width: 2px; border-radius: var(--r-s); background: var(--surface); }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: absolute; left: 16px; top: -60px; z-index: 30; background: var(--ink); color: var(--bg); padding: 8px 14px; border-radius: var(--r-s); }
.skip:focus { top: 12px; }
.wrap { width: min(1180px, 100% - 48px); margin-inline: auto; }
.muted { color: var(--muted); }
.center { text-align: center; }
.sp { flex: 1; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }

/* Three category dots, the brand mark. */
.chipdots { display: inline-flex; gap: 4px; vertical-align: middle; }
.chipdots i { width: 8px; height: 8px; border-radius: 50%; background: var(--violet); }
.chipdots i:nth-child(2) { background: var(--amber); }
.chipdots i:nth-child(3) { background: var(--teal); }

/* ---------- Header ---------- */
.site-header { position: fixed; inset: 0 0 auto; z-index: 20; padding: 14px 0; transition: background .3s, box-shadow .3s; }
.site-header.scrolled { background: color-mix(in srgb, var(--page-bg, var(--bg)) 82%, transparent); backdrop-filter: blur(14px) saturate(1.4); -webkit-backdrop-filter: blur(14px) saturate(1.4); }
.site-header .wrap { display: flex; align-items: center; gap: 16px; }
.brand { display: flex; align-items: center; gap: 10px; font-weight: 600; font-size: 18px; text-decoration: none; letter-spacing: -0.01em; }
.brand img { border-radius: 7px; }
.header-actions { margin-left: auto; display: flex; align-items: center; gap: 10px; }
.theme-pick { display: flex; align-items: center; gap: 8px; padding: 0 4px 0 12px; height: 36px; border: 1px solid var(--line); border-radius: 999px; background: var(--surface); }
.theme-pick select { appearance: none; border: 0; background: transparent; color: var(--ink); font: inherit; font-size: 14px; padding: 0 22px 0 0; height: 100%; cursor: pointer;
  background-image: linear-gradient(45deg, transparent 50%, currentColor 50%), linear-gradient(135deg, currentColor 50%, transparent 50%);
  background-position: right 9px center, right 5px center; background-size: 4px 4px; background-repeat: no-repeat; }
.pill-btn { display: inline-flex; align-items: center; height: 36px; padding: 0 16px; border-radius: 999px; background: var(--ink); color: var(--bg); font-size: 14px; font-weight: 600; text-decoration: none; }
/* On a dark section the header flips too. */
.site-header.on-ink { color: var(--bg); }
.site-header.on-ink .pill-btn { background: var(--bg); color: var(--ink); }
.site-header.on-ink .theme-pick { background: transparent; border-color: color-mix(in srgb, var(--bg) 25%, transparent); }
.site-header.on-ink .theme-pick select { color: var(--bg); }

/* ---------- Sections: each one a full screen, with room around it ---------- */
main > section { min-height: 100vh; min-height: 100svh; display: flex; flex-direction: column; justify-content: center; padding: clamp(96px, 12vh, 160px) 0; position: relative; }
.on-ink { color: var(--bg); }
.on-ink .muted, .on-ink .marker { color: color-mix(in srgb, var(--bg) 62%, transparent); }
.marker { display: inline-flex; align-items: center; gap: 8px; font-size: 13px; font-weight: 600; letter-spacing: .14em; text-transform: uppercase; color: var(--muted); margin-bottom: 20px; }
.copy > p:not(.marker) { font-size: clamp(18px, 1.5vw, 21px); color: var(--muted); max-width: 34em; margin-top: 22px; }
.on-ink .copy > p:not(.marker) { color: color-mix(in srgb, var(--bg) 70%, transparent); }
.copy.center > p:not(.marker) { margin-inline: auto; }
.split { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 6fr); gap: clamp(40px, 6vw, 96px); align-items: center; }

/* ---------- Store buttons ---------- */
.store-btn { display: inline-flex; align-items: center; gap: 12px; height: 60px; padding: 0 24px 0 20px; border-radius: 14px; background: var(--ink); color: var(--bg); text-decoration: none; font-size: 22px; font-weight: 600; letter-spacing: -0.01em; line-height: 1.05; transition: transform .2s, opacity .2s; }
.store-btn small { display: block; font-size: 12px; font-weight: 500; letter-spacing: 0; opacity: .8; }
.store-btn:hover { transform: translateY(-2px); }
.store-btn.small { height: 52px; font-size: 19px; padding: 0 20px 0 16px; border-radius: 12px; }
.store-btn.ghost { background: transparent; color: var(--ink); box-shadow: inset 0 0 0 1.5px var(--ink); }
.on-ink .store-btn { background: var(--bg); color: var(--ink); }
.store-btn .apple, .store-btn .arrow { width: 26px; height: 26px; background: currentColor; flex: none; }
.store-btn .apple { -webkit-mask: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"><path d="M16.4 12.6c0-2.4 2-3.6 2.1-3.7-1.1-1.7-2.9-1.9-3.5-1.9-1.5-.2-2.9.9-3.7.9-.8 0-1.9-.9-3.2-.8-1.6 0-3.1 1-4 2.4-1.7 3-.4 7.3 1.2 9.7.8 1.2 1.8 2.5 3 2.4 1.2 0 1.7-.8 3.2-.8s1.9.8 3.2.8c1.3 0 2.2-1.2 3-2.4.9-1.4 1.3-2.7 1.3-2.8-.1 0-2.6-1-2.6-3.8zM14 5.4c.7-.8 1.1-1.9 1-3-1 0-2.1.7-2.8 1.5-.6.7-1.2 1.8-1 2.9 1 .1 2.1-.6 2.8-1.4z"/></svg>') center / contain no-repeat; mask: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"><path d="M16.4 12.6c0-2.4 2-3.6 2.1-3.7-1.1-1.7-2.9-1.9-3.5-1.9-1.5-.2-2.9.9-3.7.9-.8 0-1.9-.9-3.2-.8-1.6 0-3.1 1-4 2.4-1.7 3-.4 7.3 1.2 9.7.8 1.2 1.8 2.5 3 2.4 1.2 0 1.7-.8 3.2-.8s1.9.8 3.2.8c1.3 0 2.2-1.2 3-2.4.9-1.4 1.3-2.7 1.3-2.8-.1 0-2.6-1-2.6-3.8zM14 5.4c.7-.8 1.1-1.9 1-3-1 0-2.1.7-2.8 1.5-.6.7-1.2 1.8-1 2.9 1 .1 2.1-.6 2.8-1.4z"/></svg>') center / contain no-repeat; }
.store-btn .arrow { -webkit-mask: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="none" stroke="black" stroke-width="2.2" stroke-linecap="round" stroke-linejoin="round"><path d="M12 4v11m-4.5-4.5L12 15l4.5-4.5M5 19.5h14"/></svg>') center / contain no-repeat; mask: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="none" stroke="black" stroke-width="2.2" stroke-linecap="round" stroke-linejoin="round"><path d="M12 4v11m-4.5-4.5L12 15l4.5-4.5M5 19.5h14"/></svg>') center / contain no-repeat; }
.store-btn.soon { opacity: .55; cursor: default; }
.store-btn.soon:hover { transform: none; }

/* ======================================================================
   The board (board.js). Sizes from CardView.swift, Mac, roomy.
   ====================================================================== */
.nb { font-family: var(--font-app); color: var(--ink); text-align: left; letter-spacing: -0.01em; }
.nb-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 36px; }
.nb-date { display: flex; align-items: center; gap: 14px; font-size: 17px; line-height: 1.25; }
.nb-day { font-size: 92px; font-weight: 600; line-height: .8; letter-spacing: -0.04em; }
.nb-date b { font-weight: 600; }
.nb-dots { display: flex; align-items: center; gap: 20px; color: var(--muted); }
.nb-dots i { width: 14px; height: 14px; border-radius: 50%; background: var(--c); }
.nb-sep { width: 1px; height: 24px; background: var(--line); }
.nb-dots .ic { width: 22px; height: 22px; }
.nb-h { display: flex; align-items: baseline; gap: 12px; font-size: 28px; font-weight: 600; letter-spacing: -0.02em; padding-bottom: 14px; border-bottom: 2px solid var(--ink); margin: 0 0 16px; }
.nb-h .count { color: var(--muted); font-weight: 500; }
.nb-grid { display: grid; gap: 10px; margin-bottom: 56px; }
.nb-today { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.nb-backlog { grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 8px; }
.nb-done { display: flex; align-items: center; gap: 18px; border-top: 2px solid var(--ink); padding-top: 14px; font-size: 16px; line-height: 1.35; }
.nb-done-n { font-size: 64px; font-weight: 600; line-height: .9; letter-spacing: -0.04em; display: inline-block; overflow: hidden; height: 58px; }
.nb-done b { font-weight: 600; }
.nb-done .ic { width: 18px; height: 18px; color: var(--muted); }

.card { position: relative; display: flex; flex-direction: column; justify-content: space-between; min-height: 132px; padding: 16px 16px 8px; border-radius: var(--r-c); background: var(--c-tint); color: var(--ink); }
.card .title { display: flex; gap: 6px; align-items: flex-start; font-size: 17px; font-weight: 500; line-height: 1.3; letter-spacing: -0.01em; overflow-wrap: anywhere; }
.card .title .ic-lock { width: 12px; height: 12px; margin-top: 5px; color: var(--muted); flex: none; }
.card .steps { font: 13px/1 ui-monospace, "SF Mono", Menlo, monospace; opacity: .6; margin-top: 8px; letter-spacing: .08em; }
.card .foot { display: flex; align-items: center; gap: 8px; height: 40px; margin-left: -1px; min-width: 0; }
.card .dot, .dot { width: 12px; height: 12px; border-radius: 50%; background: var(--c); flex: none; display: inline-block; }
.card .age { font: 12px/1 ui-monospace, "SF Mono", Menlo, monospace; opacity: .62; letter-spacing: .04em; white-space: nowrap; overflow: hidden; min-width: 0; }
/* When the row is full the age gives way first, then the project shortens (DESIGN.md). */
.card .project + .age { flex-shrink: 4; }
.card .head { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.card .project { font-size: 11px; font-weight: 500; padding: 2px 7px; border-radius: 999px; background: color-mix(in srgb, currentColor 8%, transparent); opacity: .8; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; min-width: 0; }
/* Focus, Today ↑ and Pause: on the Mac they only show on hover (RevealButton). */
.card .reveal { display: inline-flex; align-items: center; gap: 5px; font: 500 11px/1 ui-monospace, "SF Mono", Menlo, monospace; opacity: 0; max-width: 0; overflow: hidden; white-space: nowrap; transition: opacity .15s, max-width .15s; }
.card .reveal .ic { width: 11px; height: 11px; }
.card:hover .reveal, .card.hover .reveal { opacity: .7; max-width: 90px; transition-delay: .12s; padding: 0 6px; }
.card .swap { display: inline-flex; align-items: center; }
.card:hover .swap .timer, .card.hover .swap .timer { display: none; }
.card .meta { font-size: 12px; line-height: 1.35; opacity: .6; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.card .meta b { font-weight: 600; }
.card .source { display: inline-flex; align-items: center; gap: 3px; font-size: 11.5px; opacity: .6; white-space: nowrap; }
.card .source .ext { width: 9px; height: 9px; }
.card .round.primary { color: var(--ink); }
.card .ic { width: 13px; height: 13px; }
.card .tick { width: 30px; height: 30px; border-radius: 50%; border: 1.5px solid currentColor; display: grid; place-items: center; color: transparent; margin-right: -2px; flex: none; transition: background .2s, border-color .2s, color .2s; }
.card .tick .ic { width: 14px; height: 14px; }
.card .tick.ticked { background: var(--accent); border-color: var(--accent); color: var(--on-accent); }
.card.today .tick { border-color: var(--ink); }

.card.now { grid-column: span 2; background: var(--ink); color: var(--bg); box-shadow: 0 14px 30px -12px rgba(0, 0, 0, .45); }
.card.now .title { font-size: 21px; font-weight: 600; }
.card.now .now-label { font-size: 11px; font-weight: 600; letter-spacing: .14em; }
.card.now .timer { font: 13px/1 ui-monospace, "SF Mono", Menlo, monospace; opacity: .7; letter-spacing: .02em; font-variant-numeric: tabular-nums; }
.card.now .tick { border-color: var(--bg); }

.card.backlog, .card.suggested { min-height: 96px; padding: 12px 12px 4px; border-radius: var(--r-s); background: var(--surface); box-shadow: inset 0 0 0 1px var(--line); }
.card.backlog .title, .card.suggested .title { font-size: 14.5px; }
.card.backlog .foot, .card.suggested .foot { height: 32px; gap: 8px; }
.card.backlog .dot, .card.suggested .dot { width: 10px; height: 10px; }
.card.suggested { background: transparent; box-shadow: none; outline: 1px dashed color-mix(in srgb, var(--muted) 60%, transparent); outline-offset: -1px; }
.card.suggested .title { color: var(--muted); }
.card.suggested .title .sparkle { width: 14px; height: 14px; margin-top: 2px; flex: none; opacity: .8; }
.card.suggested .dot { opacity: .75; }
.card .round { width: 26px; height: 26px; border-radius: 50%; box-shadow: inset 0 0 0 1px var(--line); display: grid; place-items: center; color: var(--muted); }
.card .round .ic { width: 11px; height: 11px; }

/* An empty place a flying card will land in. */
.card.slot { visibility: hidden; }
.slot-ghost { position: absolute; border-radius: var(--r-c); outline: 1.5px dashed var(--line); outline-offset: -1.5px; }

/* ======================================================================
   Devices
   ====================================================================== */
/* A Mac window drawn in HTML. The board inside is laid out at 1080px and
   zoomed to fit (main.js sets --z), so it matches the app's proportions. */
.mac-stage { --z: 1; position: relative; width: 1080px; zoom: var(--z); }
.mac { position: relative; border-radius: 14px; background: var(--bg); overflow: hidden; box-shadow: 0 0 0 1px var(--line), 0 40px 90px -30px rgba(0, 0, 0, .35), 0 12px 30px -16px rgba(0, 0, 0, .2); }
.mac-board { padding: 52px 52px 44px; }
.lights { position: absolute; top: 18px; left: 18px; display: flex; gap: 8px; }
.lights i { width: 12px; height: 12px; border-radius: 50%; background: #FF5F57; box-shadow: inset 0 0 0 .5px rgba(0, 0, 0, .15); }
.lights i:nth-child(2) { background: #FEBC2E; }
.lights i:nth-child(3) { background: #28C840; }

/* An iPhone: the screenshot already has the status bar and the Dynamic
   Island, so the frame is just a thin edge and the real corner radius. */
.phone { position: relative; width: 300px; aspect-ratio: 900 / 1955; border-radius: 15% / 7%; padding: 2.4%; background: #0E0E0F; box-shadow: inset 0 0 0 1.5px #3A3A3C, 0 40px 80px -30px rgba(0, 0, 0, .45); }
.phone > img, .phone > .lock { width: 100%; height: 100%; border-radius: 13% / 6%; object-fit: cover; }
.tablet { position: relative; aspect-ratio: 1400 / 1867; border-radius: 4.5% / 3.4%; padding: 2.6%; background: #0E0E0F; box-shadow: inset 0 0 0 1.5px #3A3A3C, 0 40px 80px -30px rgba(0, 0, 0, .4); }
.tablet img { width: 100%; height: 100%; border-radius: 3% / 2.2%; }

/* ======================================================================
   1. Hero
   ====================================================================== */
.hero { padding-top: 128px !important; justify-content: flex-start !important; overflow: clip; }
.hero-copy { text-align: center; position: relative; z-index: 2; }
.eyebrow { display: inline-flex; align-items: center; gap: 10px; font-size: 14px; font-weight: 600; letter-spacing: .14em; text-transform: uppercase; color: var(--muted); margin-bottom: 28px; }
.lede { font-size: clamp(19px, 1.8vw, 24px); color: var(--muted); margin: 26px auto 0; max-width: 28em; }
.get { display: flex; justify-content: center; flex-wrap: wrap; gap: 12px; margin-top: 36px; }
.hero-device { position: relative; margin-top: clamp(64px, 9vh, 110px); display: flex; justify-content: center; }
.hero .mac-stage { margin-inline: auto; }
.hero-phone { display: none; }
.floaters { position: absolute; inset: 0; z-index: 3; pointer-events: none; }
.floater { position: absolute; will-change: transform; }
.floater .card { box-shadow: 0 18px 40px -18px rgba(0, 0, 0, .35); }
.scroll-hint { position: absolute; left: 50%; bottom: 28px; transform: translateX(-50%); font-size: 13px; letter-spacing: .14em; text-transform: uppercase; color: var(--muted); z-index: 4; }
.scroll-hint span { display: inline-block; animation: nudge 1.6s ease-in-out infinite; }
@keyframes nudge { 50% { transform: translateY(4px); } }

/* ======================================================================
   2. Flow, 4. Categories, 9. Themes: small live boards
   ====================================================================== */
.demo .nb-h { font-size: 22px; padding-bottom: 10px; margin-bottom: 12px; }
.demo .nb-grid { margin-bottom: 36px; grid-template-columns: repeat(3, minmax(0, 1fr)); }
.demo .card.now { grid-column: span 2; }
.demo .nb-done-n { font-size: 52px; height: 48px; }
.beats { list-style: none; padding: 0; margin: 40px 0 0; display: grid; gap: 14px; }
.beats li { display: flex; align-items: center; gap: 14px; font-size: 18px; color: var(--muted); transition: color .3s; }
.beats li span { width: 30px; height: 30px; border-radius: 50%; display: grid; place-items: center; font-size: 13px; font-weight: 600; box-shadow: inset 0 0 0 1.5px var(--line); transition: background .3s, color .3s, box-shadow .3s; }
.beats li.on { color: var(--ink); }
.beats li.on span { background: var(--ink); color: var(--bg); box-shadow: none; }

.cats .copy { margin-bottom: 56px; }
.cat-pick { display: inline-flex; gap: 8px; margin-top: 32px; padding: 6px; border-radius: 999px; background: color-mix(in srgb, var(--surface) 70%, transparent); box-shadow: inset 0 0 0 1px var(--line); }
.cat-pick button { display: inline-flex; align-items: center; gap: 10px; height: 44px; padding: 0 20px 0 16px; border: 0; border-radius: 999px; background: transparent; color: var(--ink); font: inherit; font-size: 16px; font-weight: 500; cursor: pointer; transition: background .25s, color .25s; }
.cat-pick button i { width: 14px; height: 14px; border-radius: 50%; background: var(--c); }
.cat-pick button[aria-pressed="true"] { background: var(--c); color: var(--surface); }
.cat-pick button[aria-pressed="true"] i { background: var(--surface); }
.demo.wide { max-width: 980px; margin-inline: auto; }
.demo.wide .nb-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); margin-bottom: 0; }
.cats .card { transition: opacity .35s, filter .35s, box-shadow .35s; }
/* The page takes a soft version of the colour; the picked cards lift off it. */
.cats .card.picked { box-shadow: 0 0 0 1.5px color-mix(in srgb, var(--c) 55%, transparent), 0 16px 30px -16px rgba(0, 0, 0, .35); }
.cats .card.away { opacity: .22; filter: saturate(.3); }

/* ======================================================================
   3. Focus
   ====================================================================== */
.focus-stage { position: relative; display: flex; align-items: center; justify-content: center; gap: 48px; }
.focus-card { width: 380px; flex: none; }
.focus-card .card { min-height: 170px; }
.focus-card .card.now { box-shadow: 0 0 0 1px color-mix(in srgb, var(--bg) 18%, transparent), 0 30px 60px -20px rgba(0, 0, 0, .6); }
.focus .card.now { background: var(--ink); color: var(--bg); }
.lock-phone { width: 270px; flex: none; }
.lock { position: relative; display: flex; flex-direction: column; align-items: center; padding: 15% 6% 0; overflow: hidden; color: #fff; font-family: -apple-system, BlinkMacSystemFont, sans-serif;
  background: radial-gradient(120% 80% at 20% 10%, color-mix(in srgb, var(--violet) 70%, #000) 0%, transparent 60%), radial-gradient(100% 70% at 90% 90%, color-mix(in srgb, var(--teal) 60%, #000) 0%, transparent 60%), #1A1626; }
.lock-date { font-size: 14px; font-weight: 600; opacity: .85; margin-top: 10px; }
.lock-time { font-size: 76px; font-weight: 700; line-height: 1; letter-spacing: -0.03em; margin-top: 2px; }
.live { margin-top: auto; margin-bottom: 26%; width: 100%; padding: 14px 16px; border-radius: 22px; background: rgba(20, 20, 22, .72); backdrop-filter: blur(20px); -webkit-backdrop-filter: blur(20px); }
.live-top { display: flex; align-items: center; gap: 8px; font-size: 11px; letter-spacing: .14em; }
.live-top .dot, .island .dot { --c: var(--violet); width: 9px; height: 9px; }
.live .timer, .island .timer { font: 13px ui-monospace, "SF Mono", Menlo, monospace; font-variant-numeric: tabular-nums; opacity: .8; letter-spacing: 0; }
.live-title { font-size: 16px; font-weight: 600; margin-top: 8px; line-height: 1.25; }
.live-steps { font: 12px ui-monospace, "SF Mono", Menlo, monospace; opacity: .6; margin-top: 4px; }
.island { position: absolute; top: 3%; left: 50%; transform: translateX(-50%); height: 30px; width: 34%; border-radius: 999px; background: #000; display: flex; align-items: center; gap: 8px; padding: 0 12px; overflow: hidden; white-space: nowrap; font-size: 11px; font-weight: 600; letter-spacing: .1em; z-index: 2; }
.island > * { opacity: 0; }
.island .timer { margin-left: auto; }

/* ======================================================================
   5. Quick add
   ====================================================================== */
.quick-stage { position: relative; max-width: 760px; margin: 64px auto 0; }
.keys { display: flex; align-items: center; justify-content: center; gap: 10px; margin-bottom: 36px; }
.key { min-width: 52px; height: 52px; display: grid; place-items: center; font-size: 20px; border-bottom-width: 3px; border-radius: 10px; transition: background .15s, color .15s, transform .15s; }
.key.wide { min-width: 110px; font-size: 15px; }
.key.down { background: var(--ink); color: var(--bg); transform: translateY(2px); }
.then { font-size: 14px; color: var(--muted); }
.qa { position: relative; z-index: 2; background: var(--surface); border-radius: 22px; box-shadow: 0 0 0 1px var(--line), 0 30px 70px -24px rgba(0, 0, 0, .35); font-family: var(--font-app); text-align: left; }
.qa-title { display: flex; align-items: center; gap: 18px; padding: 30px 30px 0; font-size: 34px; font-weight: 500; letter-spacing: -0.02em; min-height: 84px; }
.qa-title .dot { width: 14px; height: 14px; transition: background .2s; }
.caret { width: 2.5px; height: 38px; background: var(--accent); margin-left: -16px; animation: blink 1s steps(1) infinite; }
@keyframes blink { 50% { opacity: 0; } }
.qa-row { display: flex; align-items: center; gap: 16px; padding: 18px 30px 22px; }
.qa-dots { display: flex; gap: 18px; align-items: center; }
.qa-dots i { width: 18px; height: 18px; border-radius: 50%; background: var(--c); transition: box-shadow .2s; }
.qa-dots i.on { box-shadow: 0 0 0 3px var(--surface), 0 0 0 5px var(--c); }
.qa-cat { color: var(--muted); font-size: 18px; margin-left: 6px; }
.seg { display: inline-flex; padding: 4px; border-radius: 999px; background: var(--well); font-size: 16px; }
.seg b, .seg span { padding: 8px 16px; border-radius: 999px; font-weight: 500; }
.seg b { background: var(--surface); box-shadow: 0 1px 3px rgba(0, 0, 0, .12); }
.seg span { color: var(--muted); }
.qa-foot { display: flex; justify-content: space-between; gap: 16px; padding: 14px 30px; border-top: 1px solid var(--line); font: 13px ui-monospace, "SF Mono", Menlo, monospace; color: var(--muted); }
.qa-target { margin-top: 48px; }
.qa-target .nb-grid { margin-bottom: 0; }
.qa-target .nb-h { border-bottom-color: color-mix(in srgb, var(--ink) 70%, transparent); }

/* ======================================================================
   6. Tiles
   ====================================================================== */
.tiles { list-style: none; padding: 0; margin: 72px 0 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 20px; }
.tile { padding: 22px 22px 28px; border-radius: var(--r-l); background: var(--surface); box-shadow: inset 0 0 0 1px var(--line); }
.tile h3 { font-size: 21px; margin-top: 22px; }
.tile > p { color: var(--muted); font-size: 16px; margin-top: 10px; line-height: 1.5; }
.tile-art { height: 168px; border-radius: var(--r-s); background: var(--c-tint, var(--bg)); display: grid; place-items: center; padding: 18px; overflow: hidden; position: relative; }
.tile-art .card { width: 100%; max-width: 240px; }
.bubble { padding: 14px 18px; border-radius: 20px 20px 20px 6px; background: var(--c); color: var(--surface); font-size: 17px; font-weight: 500; }
.toast { display: inline-flex; align-items: center; gap: 8px; padding: 10px 16px; border-radius: 999px; background: var(--ink); color: var(--bg); font-size: 14px; font-weight: 500; white-space: nowrap; box-shadow: 0 12px 30px -12px rgba(0, 0, 0, .4); }
.toast b { font-weight: 600; text-decoration: underline; text-underline-offset: 3px; }
.toast .ok { width: 18px; height: 18px; border-radius: 50%; background: var(--teal); -webkit-mask: radial-gradient(circle, #000 0 100%); }
.qa-toast { position: absolute; left: 50%; transform: translateX(-50%); margin-top: 14px; z-index: 3; opacity: 0; }
.tile-art .card.suggested, .tile-art .card.backlog { background: var(--surface); }
.calm-note { text-align: center; font-size: 26px; font-weight: 600; letter-spacing: -0.02em; }
.calm-note span { display: block; font-size: 15px; font-weight: 400; color: var(--muted); margin-top: 6px; letter-spacing: 0; }
.shield { width: 64px; height: 76px; background: var(--c); -webkit-mask: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 28"><path d="M12 1L2 5v8c0 6.5 4.3 11.6 10 14 5.7-2.4 10-7.5 10-14V5L12 1zm-1.6 17.6L6 14.2l1.8-1.8 2.6 2.6 5.8-5.8 1.8 1.8-7.6 7.6z"/></svg>') center / contain no-repeat; mask: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 28"><path d="M12 1L2 5v8c0 6.5 4.3 11.6 10 14 5.7-2.4 10-7.5 10-14V5L12 1zm-1.6 17.6L6 14.2l1.8-1.8 2.6 2.6 5.8-5.8 1.8 1.8-7.6 7.6z"/></svg>') center / contain no-repeat; }

/* ======================================================================
   7. Devices
   ====================================================================== */
.devices { position: relative; display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 2.3fr) minmax(0, .82fr); align-items: end; gap: 3%; margin-top: 96px; padding-top: 120px; }
.dev { min-width: 0; }
.dev-mac { overflow: visible; }
.dev-phone .phone { width: 100%; }
.arc { position: absolute; top: 0; left: 6%; width: 88%; height: 150px; overflow: visible; }
.arc path { fill: none; stroke: var(--line); stroke-width: 2; stroke-dasharray: 5 7; vector-effect: non-scaling-stroke; }
.cloud { position: absolute; top: -16px; left: 50%; transform: translateX(-50%); display: inline-flex; align-items: center; gap: 10px; padding: 10px 18px; border-radius: 999px; background: var(--surface); box-shadow: inset 0 0 0 1px var(--line); font-size: 15px; font-weight: 500; white-space: nowrap; z-index: 2; }
.cloud svg { width: 22px; height: 22px; fill: var(--accent); }
.sync-dot { position: absolute; top: 0; left: 0; width: 14px; height: 14px; border-radius: 50%; background: var(--c); z-index: 1; opacity: 0; }

/* ======================================================================
   8. Obsidian
   ====================================================================== */
.vault .marker img { width: 18px; height: 18px; }
.vault-stage { position: relative; display: grid; place-items: center; perspective: 1400px; min-height: 380px; }
.obsidian-logo { position: absolute; top: -30px; right: 8%; width: 88px; height: 88px; filter: drop-shadow(0 18px 30px rgba(80, 40, 160, .35)); }
.flipper { position: relative; width: min(420px, 100%); height: 300px; transform-style: preserve-3d; }
.face { position: absolute; inset: 0; backface-visibility: hidden; -webkit-backface-visibility: hidden; }
.face.front { display: flex; align-items: center; }
.face.front .card { width: 100%; min-height: 200px; }
.face.back { transform: rotateY(180deg); }
.file { margin: 0; border-radius: var(--r-l); background: var(--surface); box-shadow: 0 0 0 1px var(--line), 0 30px 60px -28px rgba(0, 0, 0, .35); overflow: hidden; }
.file header { display: flex; align-items: center; gap: 10px; padding: 14px 18px; border-bottom: 1px solid var(--line); font-size: 14px; font-weight: 600; }
.file-ic { width: 14px; height: 17px; border-radius: 2px 6px 2px 2px; box-shadow: inset 0 0 0 1.5px var(--muted); }
.file pre, .query pre { margin: 0; padding: 18px 20px; font: 15px/1.65 ui-monospace, "SF Mono", Menlo, monospace; white-space: pre-wrap; }
.file .fm { color: var(--muted); }
.file .k { color: #7A55D6; }
[data-theme="graphite"] .file .k, [data-theme="spacegrey"] .file .k, [data-theme="walnut"] .file .k { color: #B9A2FF; }
.query { margin-top: 32px; }
.query summary { cursor: pointer; font-size: 16px; font-weight: 500; color: var(--ink); }
.query figure { margin: 14px 0 0; border-radius: var(--r-s); background: var(--surface); box-shadow: inset 0 0 0 1px var(--line); overflow: hidden; }
.query header { display: flex; justify-content: space-between; align-items: center; padding: 10px 14px; border-bottom: 1px solid var(--line); font-size: 13px; color: var(--muted); }
.query pre { font-size: 12.5px; }
.copy-btn { border: 0; border-radius: var(--r-s); padding: 6px 12px; background: var(--ink); color: var(--bg); font: inherit; font-size: 13px; cursor: pointer; }

/* ======================================================================
   9. Themes
   ====================================================================== */
.families { border: 0; padding: 0; margin: 48px 0 0; display: flex; flex-wrap: wrap; justify-content: center; gap: 28px 40px; }
.family > span { display: block; font-size: 12px; font-weight: 600; letter-spacing: .14em; text-transform: uppercase; color: var(--muted); margin-bottom: 10px; text-align: center; }
.family > div { display: flex; gap: 8px; }
.swatch input { position: absolute; opacity: 0; pointer-events: none; }
.swatch label { display: inline-flex; align-items: center; gap: 10px; height: 44px; padding: 0 16px 0 12px; border-radius: 999px; cursor: pointer; font-size: 15px; background: var(--surface); box-shadow: inset 0 0 0 1px var(--line); transition: box-shadow .2s; }
.swatch label .chipdots { padding: 5px 7px; border-radius: 999px; background: var(--bg); box-shadow: inset 0 0 0 1px var(--line); }
.swatch input:checked + label { box-shadow: inset 0 0 0 2px var(--ink); font-weight: 600; }
.swatch input:focus-visible + label { outline: 2px solid var(--accent); outline-offset: 2px; }
.theme-board { max-width: 760px; margin: 56px auto 0; }
.theme-board .nb-grid { margin-bottom: 0; grid-template-columns: repeat(4, minmax(0, 1fr)); }

/* ======================================================================
   10. Download
   ====================================================================== */
.dl-icon { margin: 0 auto 36px; border-radius: 22%; box-shadow: 0 20px 50px -20px rgba(0, 0, 0, .6); }
.dl-options { display: flex; justify-content: center; flex-wrap: wrap; gap: 24px; margin-top: 56px; }
.dl { width: 320px; padding: 30px 28px 32px; border-radius: var(--r-l); background: color-mix(in srgb, var(--bg) 8%, transparent); box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--bg) 16%, transparent); }
.dl h3 { font-size: 22px; }
.dl p { margin: 8px 0 24px; color: color-mix(in srgb, var(--bg) 65%, transparent); font-size: 16px; }
.download .facts { margin-top: 48px; font-size: 15px; color: color-mix(in srgb, var(--bg) 60%, transparent); }

/* ---------- Footer ---------- */
footer { padding: 28px 0 40px; font-size: 14px; color: var(--muted); border-top: 1px solid var(--line); }
footer .wrap { display: flex; flex-wrap: wrap; gap: 8px 24px; justify-content: space-between; }
footer .tm { flex-basis: 100%; font-size: 12px; opacity: .8; }

/* ---------- Motion: hide what motion.js will bring in ---------- */
.motion .copy > *, .motion .hero-copy > *, .motion .tile, .motion .hero-device, .motion .dl-icon, .motion .download h2, .motion .dl { opacity: 0; }

/* ======================================================================
   Narrow screens
   ====================================================================== */
@media (max-width: 1100px) {
  .floaters { display: none; }
  .tiles { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 900px) {
  .split { grid-template-columns: 1fr; }
  .focus-stage { flex-direction: column; }
  .devices { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
  .dev-mac { display: none; }
  .demo .nb-grid, .demo.wide .nb-grid, .theme-board .nb-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 760px) {
  body { font-size: 17px; }
  .wrap { width: calc(100% - 32px); }
  .theme-pick { display: none; }
  .hero .mac-stage { display: none; }
  .hero-phone { display: block; width: min(300px, 76vw); }
  .scroll-hint { display: none; }
  .tiles { grid-template-columns: 1fr; }
  .qa-title { font-size: 24px; padding: 22px 20px 0; min-height: 64px; gap: 12px; }
  .caret { height: 28px; margin-left: -10px; }
  .qa-row { padding: 14px 20px 18px; gap: 10px; }
  .qa-dots { gap: 12px; }
  .qa-cat { display: none; }
  .qa-foot { display: none; }
  .keys { flex-wrap: wrap; }
  .card { min-height: 108px; padding: 12px 12px 4px; }
  .card .title { font-size: 15px; }
  .card.now .title { font-size: 17px; }
  .focus-card { width: 100%; }
  .devices { grid-template-columns: 1fr; padding-top: 90px; }
  .dev-ipad { display: none; }
  .dev-phone { width: min(300px, 76vw); margin-inline: auto; }
  .cat-pick button { padding: 0 14px 0 12px; font-size: 15px; }
}
@media (prefers-reduced-motion: reduce) {
  .scroll-hint span, .caret { animation: none; }
}
