/*
 * doetoch.com. Tokens are the DoeToch design system's
 * (apps/web/src/styles/ds/tokens.css); only the ones the site uses are
 * copied, light first, dark from prefers-color-scheme. A few text colours are
 * darkened in light mode so small text stays at 4.5:1 (noted per token).
 */
:root {
  color-scheme: light dark;
  --bg-base: #ffffff;
  --bg-raised: #fff8f8;
  --bg-hover: #f4f4f4;
  --bg-control: #f4f4f4;
  --bg-control-active: #ededed;
  --text-control: #454545;
  --bg-selected: #fff0e3;
  --line: #ededed;
  --line-strong: #b8b8b8;
  --text-primary: #252525;
  --text-body: #454545;
  --text-secondary: #656565;
  --brand: #d23726;
  --brand-fill: #d23726; /* primary buttons: white text at >= 4.5:1 */
  --brand-fill-hover: #b92e1f;
  --on-brand: #ffffff;
  --brand-text: #d23726;
  --brand-text-hover: #a52500;
  --brand-text-bright: #d23726;
  --text-selected: #a52500;
  --date-today: #19822b;
  --date-this-week: #692fc2;
  --priority-1: #c0392f; /* ds #cf473d, darker for small text */
  --priority-1-fill: #fcebea;
  --priority-2: #a85d00; /* ds #eb8909 is 2.6:1 on white; this is 5:1 */
  --neutral-fill: #f4f4f4;
  --btn-dark: #252525;
  --btn-dark-hover: #3a3a3a;
  --on-btn-dark: #ffffff;
  --frame: #252525;
  --screen: #242424;
  --shadow-popover: 0 4px 16px rgba(0, 0, 0, 0.1);
  --topbar-bg: rgba(255, 255, 255, 0.9);

  --radius-sm: 5px;
  --radius-md: 8px;
  --radius-lg: 10px;
  --radius-xl: 12px;
  --radius-full: 9999px;
  --font-sans: -apple-system, BlinkMacSystemFont, "Segoe UI", "Noto Sans", Roboto, Helvetica, Arial, sans-serif;
  --wrap: 1248px;
  --gutter: 24px;
  --section-y: 96px;
  --header-h: 72px;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg-base: #242424;
    --bg-raised: #2b2b2b;
    --bg-hover: #363636;
    --bg-control: #414141;
    --bg-control-active: #484848;
    --text-control: #ffffff;
    --bg-selected: #482a2a;
    --line: #3f3f3f;
    --line-strong: #565656;
    --text-primary: #ffffff;
    --text-body: #cccccc;
    --text-secondary: #cccccc;
    --brand: #de4c4c;
    --brand-fill: #d0444a; /* brand-strong */
    --brand-fill-hover: #bd3a40;
    --brand-text: #e06a61;
    --brand-text-hover: #f77a70;
    --brand-text-bright: #f77a70;
    --text-selected: #f17d73;
    --date-today: #25b84c;
    --date-this-week: #a870fe;
    --priority-1: #fe7065;
    --priority-1-fill: #382c2a;
    --priority-2: #ff9719;
    --neutral-fill: #363636;
    --btn-dark: #f4f4f4;
    --btn-dark-hover: #ffffff;
    --on-btn-dark: #252525;
    --frame: #191919;
    --shadow-popover: 0 8px 24px rgba(0, 0, 0, 0.45);
    --topbar-bg: rgba(36, 36, 36, 0.9);
  }
}

@media (max-width: 860px) {
  :root {
    --gutter: 20px;
    --section-y: 48px;
    --header-h: 60px;
  }
}

/* ─── Base ──────────────────────────────────────────────────────────────── */

*,
*::before,
*::after {
  box-sizing: border-box;
}
html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-h) + 16px);
}
@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
}
body {
  margin: 0;
  background: var(--bg-base);
  color: var(--text-primary);
  font: 400 16px/1.6 var(--font-sans);
  -webkit-font-smoothing: antialiased;
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}
main {
  flex: 1;
}
main:focus {
  outline: none;
}
img {
  display: block;
  max-width: 100%;
  height: auto;
}
h1,
h2,
h3 {
  margin: 0;
  font-weight: 700;
  line-height: 1.15;
  letter-spacing: -0.02em;
}
h1 {
  font-size: clamp(36px, 5vw, 52px);
  line-height: 1.08;
  letter-spacing: -0.03em;
}
h2 {
  font-size: clamp(28px, 3.2vw, 40px);
  line-height: 1.12;
}
h3 {
  font-size: 17px;
  line-height: 1.35;
  letter-spacing: -0.01em;
}
p,
dl,
dd,
figure {
  margin: 0;
}
ul,
ol {
  margin: 0;
  padding: 0;
  list-style: none;
}
a {
  color: var(--brand-text);
  text-underline-offset: 3px;
}
a:hover {
  color: var(--brand-text-hover);
}
:focus-visible {
  outline: 2px solid var(--text-primary);
  outline-offset: 2px;
  border-radius: var(--radius-sm);
}
b {
  font-weight: 700;
  color: var(--text-primary);
}
.sr {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  clip-path: inset(50%);
  white-space: nowrap;
}
.wrap {
  width: 100%;
  max-width: var(--wrap);
  margin-inline: auto;
  padding-inline: max(var(--gutter), env(safe-area-inset-left)) max(var(--gutter), env(safe-area-inset-right));
}
.skip {
  position: absolute;
  left: 12px;
  top: -80px;
  z-index: 20;
  padding: 10px 14px;
  background: var(--bg-base);
  color: var(--text-primary);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-popover), 0 0 0 1px var(--line-strong);
  font-weight: 600;
}
.skip:focus {
  top: 12px;
}
.icon {
  width: 20px;
  height: 20px;
  flex: none;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.icon-sm {
  width: 16px;
  height: 16px;
}
.lead {
  font-size: clamp(17px, 1.6vw, 20px);
  line-height: 1.55;
  color: var(--text-body);
  max-width: 38em;
}
.hint {
  font-size: 15px;
  line-height: 1.6;
  color: var(--text-secondary);
}

/* ─── Brand ─────────────────────────────────────────────────────────────── */

.wordmark {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--text-primary);
  line-height: 1;
  font-size: 19px;
}
.toch {
  color: var(--brand-text-bright);
}
.mark {
  flex: none;
  display: block;
}
.mark-tile {
  fill: var(--brand);
}
.mark-stroke {
  fill: none;
  stroke: #ffffff;
}

/* ─── Buttons ───────────────────────────────────────────────────────────── */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 44px;
  padding: 10px 18px;
  border-radius: var(--radius-md);
  border: 1px solid transparent;
  font-weight: 600;
  font-size: 15px;
  line-height: 1.2;
  text-decoration: none;
  white-space: nowrap;
}
.btn-large {
  min-height: 50px;
  padding: 13px 22px;
  font-size: 16px;
}
.btn-small {
  padding-inline: 16px;
}
.btn-primary {
  background: var(--brand-fill);
  color: var(--on-brand);
}
.btn-primary:hover {
  background: var(--brand-fill-hover);
  color: var(--on-brand);
}
.btn-secondary {
  background: var(--bg-control);
  color: var(--text-control);
}
.btn-secondary:hover {
  background: var(--bg-control-active);
  color: var(--text-control);
}
.btn-dark {
  background: var(--btn-dark);
  color: var(--on-btn-dark);
}
.btn-dark:hover {
  background: var(--btn-dark-hover);
  color: var(--on-btn-dark);
}
.btn-outline {
  background: var(--bg-base);
  border-color: var(--line-strong);
  color: var(--text-control);
}
.btn-outline:hover {
  background: var(--bg-hover);
  color: var(--text-control);
}
.btn-soon {
  border: 1px dashed var(--line-strong);
  color: var(--text-secondary);
  cursor: default;
}
.icon-ext {
  width: 15px;
  height: 15px;
  opacity: 0.75;
}
.badge {
  font-size: 12px;
  font-weight: 600;
  line-height: 16px;
  padding: 2px 8px;
  border-radius: var(--radius-full);
  background: var(--bg-control);
  color: var(--text-secondary);
}
.badge-beta {
  background: var(--bg-selected);
  color: var(--text-selected);
}
.btn-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

/* ─── Header ────────────────────────────────────────────────────────────── */

.topbar {
  position: sticky;
  top: 0;
  z-index: 10;
  background: var(--topbar-bg);
  -webkit-backdrop-filter: saturate(1.4) blur(12px);
  backdrop-filter: saturate(1.4) blur(12px);
  border-bottom: 1px solid var(--line);
  padding-top: env(safe-area-inset-top);
}
.topbar-inner {
  display: flex;
  align-items: center;
  gap: 16px;
  height: var(--header-h);
}
.brand {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  text-decoration: none;
}
.menu {
  display: flex;
  align-items: center;
  gap: 16px;
  flex: 1;
}
.nav {
  display: flex;
  gap: 4px;
  flex: 1;
  margin-left: 24px;
}
.nav a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding: 0 12px;
  border-radius: var(--radius-md);
  color: var(--text-body);
  text-decoration: none;
  font-size: 15px;
}
.nav a:hover {
  background: var(--bg-hover);
  color: var(--text-primary);
}
.nav a[aria-current="page"] {
  color: var(--text-primary);
  font-weight: 600;
}
.lang {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  min-width: 44px;
  justify-content: center;
  text-decoration: none;
  color: var(--text-secondary);
  font-size: 14px;
}
.lang-short {
  padding: 5px 11px;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-full);
  line-height: 1.2;
}
.lang:hover {
  color: var(--text-primary);
}
.lang:hover .lang-short {
  background: var(--bg-hover);
}
.lang-long {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  clip-path: inset(50%);
  white-space: nowrap;
}
.open-short {
  display: none;
}
.menu-btn {
  display: none;
  width: 44px;
  height: 44px;
  margin-right: -10px;
  border: 0;
  border-radius: var(--radius-md);
  background: transparent;
  color: var(--text-body);
  align-items: center;
  justify-content: center;
  cursor: pointer;
}
.menu-btn .icon {
  width: 24px;
  height: 24px;
}
.menu-btn:hover {
  background: var(--bg-hover);
}
.icon-close {
  display: none;
}

@media (max-width: 860px) {
  .topbar-inner {
    gap: 8px;
  }
  .brand {
    flex: 1;
  }
  .brand .wordmark {
    font-size: 17px;
    gap: 8px;
  }
  .brand .mark {
    width: 24px;
    height: 24px;
  }
  .menu-btn {
    display: inline-flex;
  }
  .open-long {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip: rect(0 0 0 0);
    clip-path: inset(50%);
    white-space: nowrap;
  }
  .open-short {
    display: inline;
  }
  .open {
    padding-inline: 16px;
  }
  .menu {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    padding: 8px max(var(--gutter), env(safe-area-inset-left)) 16px;
    background: var(--bg-base);
    border-bottom: 1px solid var(--line);
    box-shadow: var(--shadow-popover);
    max-height: calc(100vh - var(--header-h));
    overflow-y: auto;
  }
  .topbar.is-open .menu {
    display: flex;
  }
  .topbar.is-open .icon-menu {
    display: none;
  }
  .topbar.is-open .icon-close {
    display: block;
  }
  .nav {
    flex-direction: column;
    margin: 0;
    gap: 0;
  }
  .nav a,
  .lang {
    min-height: 52px;
    padding: 0 4px;
    border-bottom: 1px solid var(--line);
    border-radius: 0;
    font-size: 17px;
    color: var(--text-primary);
    justify-content: flex-start;
  }
  .lang {
    border-bottom: 0;
    color: var(--brand-text);
    font-weight: 600;
  }
  .lang-short {
    display: none;
  }
  .lang-long {
    position: static;
    width: auto;
    height: auto;
    overflow: visible;
    clip: auto;
    clip-path: none;
  }
}

/* ─── Sections ──────────────────────────────────────────────────────────── */

.section {
  padding-block: var(--section-y);
}
.section + .section {
  border-top: 1px solid var(--line);
}
.band {
  background: var(--bg-raised);
}
.section + .band,
.band + .section {
  border-top: 1px solid var(--line);
}
.section .lead {
  margin-top: 16px;
}
.section-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  gap: 16px 40px;
  flex-wrap: wrap;
}
.section-head > div {
  max-width: 640px;
}
.more {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 44px;
  font-size: 15px;
  font-weight: 600;
  text-decoration: none;
}
.more:hover {
  text-decoration: underline;
}
.more-after {
  display: none;
}

/* ─── Home: hero ────────────────────────────────────────────────────────── */

.hero {
  background: var(--bg-raised);
  border-bottom: 1px solid var(--line);
  padding-block: 96px 88px;
}
.hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 5fr) minmax(0, 6fr);
  column-gap: clamp(32px, 7vw, 120px);
  align-items: center;
}
.hero-text {
  display: flex;
  flex-direction: column;
  gap: 24px;
}
.eyebrow {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 14px;
  font-weight: 700;
  color: var(--date-today);
}
.hero h1 {
  font-size: clamp(40px, 5.2vw, 64px);
  line-height: 1.04;
}
.hero .lead {
  max-width: 480px;
}
.actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  padding-top: 8px;
}
.note {
  font-size: 14px;
  color: var(--text-secondary);
}
.hero-visual {
  position: relative;
  aspect-ratio: 620 / 520;
}
.hero-visual .shot-tablet {
  position: absolute;
  top: 0;
  right: 0;
  width: 100%;
}
.shot-tablet img {
  border-radius: 18px;
  border: 1px solid var(--line);
  background: var(--bg-base);
}
.hero-visual .shot-phone {
  position: absolute;
  left: 0;
  bottom: 0;
  width: 34%;
}
.shot-phone img {
  width: 100%;
  border: 5px solid var(--frame);
  border-radius: clamp(20px, 2.2vw, 28px);
  background: var(--screen);
}
.hero-visual .shot-phone img {
  border-width: 6px;
  box-shadow: var(--shadow-popover);
}

@media (max-width: 860px) {
  .hero {
    padding-block: 40px 44px;
  }
  .hero-grid {
    grid-template-columns: minmax(0, 1fr);
    row-gap: 32px;
  }
  .hero-text {
    gap: 18px;
  }
  .eyebrow {
    font-size: 13px;
  }
  .eyebrow .icon {
    display: none;
  }
  .actions {
    flex-direction: column;
    padding-top: 4px;
  }
  .actions .btn {
    width: 100%;
  }
  .hero-visual {
    aspect-ratio: auto;
  }
  .hero-visual .shot-tablet {
    display: none;
  }
  .hero-visual .shot-phone {
    position: static;
    width: 250px;
    max-width: 70%;
    margin-inline: auto;
  }
  .hero-visual .shot-phone img {
    border-radius: 30px;
  }
}

/* ─── Home: quick add ───────────────────────────────────────────────────── */

.split {
  display: grid;
  grid-template-columns: minmax(0, 5fr) minmax(0, 6fr);
  column-gap: clamp(32px, 7vw, 120px);
  row-gap: 24px;
  align-items: start;
}
.split-text {
  display: flex;
  flex-direction: column;
  gap: 18px;
}
.split-text .lead {
  margin-top: 0;
}
.qa-demo {
  display: flex;
  flex-direction: column;
  gap: 16px;
}
.composer {
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-lg);
  padding: 16px 18px;
  display: flex;
  flex-direction: column;
  gap: 14px;
  background: var(--bg-base);
}
.composer-input {
  font-size: 18px;
  line-height: 1.5;
  overflow-wrap: anywhere;
}
.tok {
  border-radius: 4px;
  padding: 1px 4px;
}
.tok-date {
  background: var(--bg-selected);
  color: var(--text-selected);
}
.tok-priority {
  background: var(--priority-1-fill);
  color: var(--priority-1);
}
.tok-project {
  background: var(--neutral-fill);
  color: var(--text-body);
}
.chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 13px;
  line-height: 1.3;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  padding: 5px 9px;
  color: var(--text-secondary);
}
.chip .icon {
  width: 14px;
  height: 14px;
  stroke-width: 2;
}
.chip-date {
  color: var(--priority-2);
}
.chip-priority {
  color: var(--priority-1);
}
.chip-priority .icon {
  fill: currentColor;
}
.composer-actions {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
  border-top: 1px solid var(--line);
  padding-top: 12px;
}
.fake-btn {
  font-size: 14px;
  font-weight: 600;
  color: var(--text-control);
  background: var(--bg-control);
  padding: 8px 14px;
  border-radius: var(--radius-sm);
}
.fake-btn-primary {
  color: var(--on-brand);
  background: var(--brand-fill);
}
.qa-rows li {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 12px 4px;
  border-bottom: 1px solid var(--line);
}
.circle {
  width: 18px;
  height: 18px;
  flex: none;
  margin-top: 3px;
  border: 1.5px solid var(--line-strong);
  border-radius: var(--radius-full);
}
.qa-row-text {
  display: flex;
  flex-direction: column;
  gap: 2px;
  flex: 1;
  font-size: 15px;
  min-width: 0;
}
.qa-typed {
  font-size: 12px;
  color: var(--text-secondary);
}
.qa-when {
  font-size: 12px;
  line-height: 1.4;
  margin-top: 3px;
  text-align: right;
}
.qa-when-repeat {
  color: var(--date-this-week);
}
.qa-when-today {
  color: var(--date-today);
}

@media (max-width: 860px) {
  .split {
    grid-template-columns: minmax(0, 1fr);
  }
  .split-text {
    gap: 16px;
  }
  .composer {
    padding: 14px 16px;
    gap: 12px;
  }
  .composer-input {
    font-size: 16px;
  }
  .composer-actions,
  .qa-rows {
    display: none;
  }
}

/* ─── Home: features ────────────────────────────────────────────────────── */

.feature-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  column-gap: 48px;
  margin-top: 48px;
}
.feature-grid li {
  display: flex;
  gap: 16px;
  padding: 24px 0;
  border-top: 1px solid var(--line);
}
.tile {
  width: 36px;
  height: 36px;
  flex: none;
  border-radius: var(--radius-md);
  background: var(--bg-selected);
  color: var(--brand-text-bright);
  display: flex;
  align-items: center;
  justify-content: center;
}
.tile .icon {
  width: 19px;
  height: 19px;
  stroke-width: 2;
}
.tile-lg {
  width: 48px;
  height: 48px;
  border-radius: var(--radius-xl);
}
.tile-lg .icon {
  width: 24px;
  height: 24px;
}
.feature-grid h3 {
  margin-bottom: 6px;
}
.feature-grid p {
  font-size: 15px;
  line-height: 1.55;
  color: var(--text-secondary);
}
@media (max-width: 1000px) {
  .feature-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
@media (max-width: 640px) {
  .feature-grid {
    grid-template-columns: minmax(0, 1fr);
    margin-top: 20px;
  }
  .feature-grid li {
    border-top: 0;
    border-bottom: 1px solid var(--line);
    padding: 16px 0;
    gap: 14px;
  }
  .feature-grid h3 {
    font-size: 16px;
    margin-bottom: 4px;
  }
  .feature-grid p {
    font-size: 14px;
    line-height: 1.5;
  }
  .section-head .more {
    display: none;
  }
  .more-after {
    display: inline-flex;
    margin-top: 8px;
  }
}

/* ─── Home: gallery ─────────────────────────────────────────────────────── */

.gallery-wrap {
  margin-top: 40px;
}
.gallery-row {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 24px;
}
.gallery figure {
  display: flex;
  flex-direction: column;
  gap: 14px;
}
.gallery figcaption {
  font-size: 15px;
  font-weight: 600;
  text-align: center;
}
@media (max-width: 1000px) {
  .gallery-wrap {
    margin-top: 20px;
    padding-right: 0;
  }
  .gallery {
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    scroll-padding-inline-start: 0;
    padding-bottom: 12px;
    border-radius: var(--radius-md);
  }
  .gallery-row {
    display: flex;
    gap: 14px;
    width: max-content;
    padding-right: var(--gutter);
  }
  .gallery li {
    width: 200px;
    scroll-snap-align: start;
  }
  .gallery figure {
    gap: 10px;
  }
  .gallery figcaption {
    font-size: 14px;
  }
}

/* ─── Home: everywhere, privacy ─────────────────────────────────────────── */

.everywhere {
  display: grid;
  grid-template-columns: minmax(0, 7fr) minmax(0, 4fr);
  column-gap: clamp(32px, 7vw, 120px);
  row-gap: 32px;
  align-items: center;
}
.privacy-home {
  display: grid;
  grid-template-columns: minmax(0, 4fr) minmax(0, 7fr);
  column-gap: clamp(32px, 7vw, 120px);
  row-gap: 12px;
}
.text-links {
  display: flex;
  flex-wrap: wrap;
  gap: 0 20px;
  margin-top: 12px;
  font-size: 15px;
  font-weight: 600;
}
.text-links a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  text-decoration: none;
}
.text-links a:hover {
  text-decoration: underline;
}
.checks li {
  display: flex;
  gap: 16px;
  align-items: center;
  padding: 18px 0;
  border-bottom: 1px solid var(--line);
  font-size: 17px;
  line-height: 1.5;
}
.icon-check {
  color: var(--date-today);
  stroke-width: 2.2;
}
@media (max-width: 860px) {
  .everywhere,
  .privacy-home {
    grid-template-columns: minmax(0, 1fr);
  }
  .privacy-home .text-links {
    order: 2;
  }
  .checks li {
    align-items: flex-start;
    gap: 12px;
    padding: 14px 0;
    font-size: 15px;
  }
  .checks .icon {
    width: 18px;
    height: 18px;
    margin-top: 2px;
  }
}

/* ─── Home: AI assistants (FEATURES.mcp) ────────────────────────────────── */

code {
  font-family: ui-monospace, "SF Mono", SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 0.9em;
}
.checks-compact li {
  padding: 12px 0;
  font-size: 16px;
}
.checks-compact li:first-child {
  border-top: 1px solid var(--line);
}
.ai-demo {
  display: flex;
  flex-direction: column;
  gap: 16px;
}
.chat {
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-lg);
  padding: 18px;
  display: flex;
  flex-direction: column;
  gap: 14px;
  background: var(--bg-base);
}
.bubble {
  font-size: 16px;
  line-height: 1.55;
}
.bubble-you {
  align-self: flex-end;
  max-width: 85%;
  background: var(--bg-control);
  color: var(--text-primary);
  padding: 10px 14px;
  border-radius: 14px 14px 4px 14px;
}
.bubble-ai {
  display: flex;
  gap: 12px;
  color: var(--text-body);
}
.ai-mark {
  width: 28px;
  height: 28px;
  flex: none;
  border-radius: var(--radius-full);
  background: var(--bg-selected);
  color: var(--text-selected);
  display: flex;
  align-items: center;
  justify-content: center;
}
.bubble-ai-body {
  display: flex;
  flex-direction: column;
  gap: 10px;
  min-width: 0;
  padding-top: 2px;
}
.tool-calls {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}
.tool-call {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 13px;
  line-height: 1.3;
  color: var(--text-secondary);
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  padding: 4px 8px;
}
.tool-call .icon {
  width: 14px;
  height: 14px;
  color: var(--date-today);
  stroke-width: 2.2;
}
.tool-call code {
  color: var(--text-body);
}
.ai-activity {
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding: 0 4px;
}
.ai-activity-label {
  font-size: 13px;
  font-weight: 700;
  color: var(--text-secondary);
}
.ai-activity-row {
  display: flex;
  gap: 12px;
  align-items: center;
  padding: 10px 0;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}
.tile-sm {
  width: 32px;
  height: 32px;
  border-radius: var(--radius-md);
}
.ai-activity-text {
  display: flex;
  flex-direction: column;
  gap: 1px;
  font-size: 15px;
  min-width: 0;
}
.via {
  font-size: 13px;
  color: var(--text-secondary);
}
@media (max-width: 860px) {
  .chat {
    padding: 14px 16px;
  }
  .bubble {
    font-size: 15px;
  }
}

/* ─── Home: download ────────────────────────────────────────────────────── */

.platform-cols {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  margin-top: 40px;
  border-top: 1px solid var(--line);
}
.platform-col {
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: 28px 32px 8px;
}
.platform-col:first-child {
  padding-left: 0;
}
.platform-col:last-child {
  padding-right: 0;
}
.platform-col + .platform-col {
  border-left: 1px solid var(--line);
}
.platform-col h3 {
  font-size: 20px;
}
.platform-col p {
  font-size: 15px;
  line-height: 1.55;
  color: var(--text-secondary);
}
.platform-col .btn-row {
  margin-top: auto;
  padding-top: 4px;
}
@media (max-width: 860px) {
  .platform-cols {
    grid-template-columns: minmax(0, 1fr);
    margin-top: 24px;
  }
  .platform-col,
  .platform-col:first-child,
  .platform-col:last-child {
    padding: 20px 0;
  }
  .platform-col + .platform-col {
    border-left: 0;
    border-top: 1px solid var(--line);
  }
}
@media (max-width: 640px) {
  .btn-row {
    flex-direction: column;
  }
  .btn-row .btn {
    width: 100%;
    justify-content: space-between;
  }
  .btn-row .btn .icon-ext {
    margin-left: auto;
  }
}

/* ─── Footer ────────────────────────────────────────────────────────────── */

.footer {
  border-top: 1px solid var(--line);
  padding-block: 40px calc(48px + env(safe-area-inset-bottom));
  font-size: 14px;
  color: var(--text-secondary);
}
.footer-inner {
  display: flex;
  align-items: center;
  gap: 16px 32px;
  flex-wrap: wrap;
}
.footer-brand {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 44px;
  font-weight: 700;
  color: var(--text-primary);
  text-decoration: none;
}
.footer-nav {
  flex: 1;
}
.footer-nav ul {
  display: flex;
  flex-wrap: wrap;
  gap: 0 24px;
}
.footer a {
  color: var(--text-secondary);
  text-decoration: none;
}
.footer a:hover {
  color: var(--text-primary);
  text-decoration: underline;
}
.footer-nav a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
}
.footer-nav a[aria-current="page"] {
  color: var(--text-primary);
}
.footer-brand,
.footer-brand:hover {
  color: var(--text-primary);
  text-decoration: none;
}
.footer-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0 24px;
}
.footer-meta a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
}
@media (max-width: 860px) {
  .footer {
    padding-block: 32px calc(40px + env(safe-area-inset-bottom));
  }
  .footer-inner {
    flex-direction: column;
    align-items: stretch;
  }
  .footer-nav ul {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0 12px;
  }
  .footer-meta {
    flex-direction: column;
    align-items: flex-start;
  }
}

/* ─── Subpages ──────────────────────────────────────────────────────────── */

.page-head {
  padding-block: 80px 48px;
  display: flex;
  flex-direction: column;
  gap: 16px;
}
.page-head .lead {
  max-width: 760px;
}
@media (max-width: 860px) {
  .page-head {
    padding-block: 32px 28px;
  }
}

.with-toc {
  display: grid;
  grid-template-columns: minmax(0, 3fr) minmax(0, 8fr);
  column-gap: clamp(32px, 9vw, 132px);
  padding-bottom: 96px;
  align-items: start;
}
.toc {
  position: sticky;
  top: calc(var(--header-h) + 24px);
}
.toc a {
  display: flex;
  align-items: center;
  min-height: 44px;
  text-decoration: none;
}
.toc-box {
  background: var(--bg-raised);
  border-radius: var(--radius-lg);
  padding: 12px;
}
.toc-box a {
  padding: 0 12px;
  border-radius: var(--radius-sm);
  color: var(--text-primary);
  font-size: 15px;
}
.toc-box a:hover {
  background: var(--bg-hover);
}
.toc-plain {
  padding-top: 150px;
}
.toc-label {
  font-size: 13px;
  font-weight: 700;
  color: var(--text-secondary);
  padding-bottom: 6px;
}
.toc-plain a {
  font-size: 14px;
  color: var(--text-secondary);
}
.toc-plain a:hover {
  color: var(--text-primary);
}
@media (max-width: 860px) {
  .with-toc {
    grid-template-columns: minmax(0, 1fr);
    padding-bottom: 56px;
  }
  .toc {
    position: static;
    margin-bottom: 32px;
  }
  .toc-box ul {
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
  }
  .toc-box a {
    background: var(--bg-base);
    border: 1px solid var(--line);
  }
  .toc-plain {
    padding-top: 0;
    order: 2;
    margin: 40px 0 0;
    border-top: 1px solid var(--line);
    padding-top: 20px;
  }
}

/* Features page */
.groups {
  display: flex;
  flex-direction: column;
  gap: 64px;
}
.group-title {
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 0;
  color: var(--text-secondary);
  padding-bottom: 8px;
  border-bottom: 1px solid var(--line);
}
.def-rows > div {
  display: grid;
  grid-template-columns: minmax(0, 3fr) minmax(0, 5fr);
  column-gap: 24px;
  row-gap: 6px;
  padding: 20px 0;
  border-bottom: 1px solid var(--line);
}
.def-rows dt {
  font-size: 17px;
  font-weight: 700;
  line-height: 1.5;
}
.def-rows dd {
  color: var(--text-secondary);
  line-height: 1.6;
}
@media (max-width: 640px) {
  .groups {
    gap: 40px;
  }
  .def-rows > div {
    grid-template-columns: minmax(0, 1fr);
    padding: 16px 0;
  }
  .def-rows dd {
    font-size: 15px;
  }
}

/* Downloads page */
.platform-row {
  display: grid;
  grid-template-columns: 48px minmax(0, 6fr) minmax(0, 5fr);
  column-gap: 32px;
  row-gap: 16px;
  align-items: center;
  padding: 32px 0;
  border-top: 1px solid var(--line);
}
.platform-text {
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.platform-text h2 {
  font-size: 22px;
}
.platform-text p {
  color: var(--text-secondary);
  line-height: 1.55;
}
.platform-text .req {
  font-size: 13px;
}
.platform-row .btn-row {
  justify-content: flex-end;
}
.fineprint {
  border-top: 1px solid var(--line);
  padding-top: 16px;
  font-size: 14px;
  color: var(--text-secondary);
}
.callout {
  margin-block: 56px 96px;
  padding: 28px 32px;
  background: var(--bg-raised);
  border-radius: var(--radius-xl);
  display: flex;
  gap: 16px 24px;
  align-items: center;
}
.callout > div {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.callout h2 {
  font-size: 18px;
  letter-spacing: -0.01em;
}
.callout p {
  font-size: 15px;
  line-height: 1.55;
  color: var(--text-secondary);
}
@media (max-width: 860px) {
  .platform-row {
    grid-template-columns: 48px minmax(0, 1fr);
    align-items: start;
    padding: 24px 0;
  }
  .platform-row .btn-row {
    grid-column: 1 / -1;
    justify-content: flex-start;
  }
  .callout {
    flex-direction: column;
    align-items: stretch;
    padding: 24px 20px;
    margin-block: 40px 56px;
  }
}

/* Help page */
.topics {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  column-gap: 48px;
  row-gap: 8px;
}
.topic {
  padding: 24px 0;
  border-top: 1px solid var(--line);
}
.topic h2 {
  font-size: 18px;
  letter-spacing: -0.01em;
  margin-bottom: 6px;
}
.faq summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  min-height: 44px;
  padding: 6px 0;
  cursor: pointer;
  list-style: none;
  font-size: 15px;
  line-height: 1.5;
  color: var(--text-body);
}
.faq summary::-webkit-details-marker {
  display: none;
}
.faq summary::after {
  content: "";
  flex: none;
  width: 8px;
  height: 8px;
  margin-right: 4px;
  border-right: 1.8px solid var(--text-secondary);
  border-bottom: 1.8px solid var(--text-secondary);
  transform: rotate(45deg) translateY(-2px);
  transition: transform 0.15s;
}
.faq[open] summary::after {
  transform: rotate(-135deg) translateY(-2px);
}
.faq summary:hover {
  color: var(--text-primary);
}
.faq[open] summary {
  color: var(--text-primary);
  font-weight: 600;
}
.faq-body {
  padding: 2px 0 14px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  font-size: 15px;
  line-height: 1.6;
  color: var(--text-secondary);
}
@media (prefers-reduced-motion: reduce) {
  .faq summary::after {
    transition: none;
  }
}
@media (max-width: 1000px) {
  .topics {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
@media (max-width: 640px) {
  .topics {
    grid-template-columns: minmax(0, 1fr);
    row-gap: 0;
  }
  .topic {
    padding: 20px 0;
  }
}

/* About, delete account: one narrow column */
.narrow {
  max-width: calc(800px + 2 * var(--gutter));
}
.prose-page {
  padding-block: 80px 96px;
  display: flex;
  flex-direction: column;
  gap: 20px;
}
.prose-page h1 {
  margin-bottom: 8px;
}
.prose-page h2 {
  font-size: 22px;
  letter-spacing: -0.01em;
  margin-top: 24px;
}
.prose-page p {
  font-size: 18px;
  line-height: 1.7;
  color: var(--text-body);
}
.prose-page .intro {
  font-size: clamp(18px, 1.8vw, 21px);
  line-height: 1.6;
  color: var(--text-primary);
}
.facts {
  border-top: 1px solid var(--line);
}
.facts > div {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  padding: 14px 0;
  border-bottom: 1px solid var(--line);
}
.facts dt {
  color: var(--text-secondary);
}
.facts dd {
  text-align: right;
}
@media (max-width: 860px) {
  .prose-page {
    padding-block: 32px 56px;
    gap: 16px;
  }
  .prose-page p {
    font-size: 16px;
    line-height: 1.6;
  }
}
@media (max-width: 480px) {
  .facts > div {
    flex-direction: column;
    gap: 2px;
  }
  .facts dd {
    text-align: left;
  }
}

/* Privacy page */
.legal {
  padding-top: 80px;
}
.prose h1 {
  font-size: clamp(32px, 4vw, 44px);
  line-height: 1.1;
  margin-bottom: 8px;
}
.updated {
  font-size: 14px;
  color: var(--text-secondary);
  margin-bottom: 28px;
}
.prose-page .updated {
  font-size: 14px;
  margin: -12px 0 0;
  color: var(--text-secondary);
}
.prose .intro {
  font-size: 18px;
  line-height: 1.7;
}
.prose section {
  padding-top: 36px;
}
.prose h2 {
  font-size: 20px;
  letter-spacing: -0.01em;
  padding-bottom: 8px;
  margin-bottom: 12px;
  border-bottom: 1px solid var(--line);
}
.prose p,
.prose li {
  line-height: 1.7;
  color: var(--text-body);
}
.prose p + p {
  margin-top: 12px;
}
.prose ul,
.notes {
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding-left: 20px;
  list-style: disc;
}
.prose li::marker,
.notes li::marker {
  color: var(--text-secondary);
}
.contact {
  margin-top: 36px;
  font-weight: 600;
}
.contact a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
}
@media (max-width: 860px) {
  .legal {
    padding-top: 32px;
  }
  .prose .intro {
    font-size: 17px;
  }
}

/* Delete account page */
.ways {
  border-top: 1px solid var(--line);
}
.ways li {
  display: flex;
  gap: 14px;
  padding: 18px 0;
  border-bottom: 1px solid var(--line);
}
.num {
  width: 28px;
  height: 28px;
  flex: none;
  border-radius: var(--radius-full);
  background: var(--bg-selected);
  color: var(--text-selected);
  font-size: 14px;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
}
.ways h3 {
  margin-bottom: 4px;
}
.prose-page .ways p {
  font-size: 16px;
  line-height: 1.6;
  color: var(--text-secondary);
}
.cta-row {
  padding-top: 8px;
}
.timeline > div {
  display: flex;
  gap: 12px;
  padding: 12px 0;
  border-bottom: 1px solid var(--line);
}
.when {
  width: 88px;
  flex: none;
  font-size: 13px;
  font-weight: 700;
  padding-top: 3px;
}
.when-wait {
  color: var(--priority-2);
}
.when-final {
  color: var(--priority-1);
}
.timeline dd {
  font-size: 16px;
  line-height: 1.6;
}
.notes li {
  font-size: 15px;
  line-height: 1.6;
  color: var(--text-secondary);
}
.prose-page .small {
  font-size: 15px;
  color: var(--text-secondary);
}
.delete .contact {
  margin-top: 8px;
}
@media (max-width: 640px) {
  .cta-row .btn {
    width: 100%;
    white-space: normal;
    text-align: center;
  }
  .timeline dd {
    font-size: 15px;
  }
  .when {
    width: 64px;
  }
}

/* 404 */
.notfound {
  padding-block: 96px;
}
.notfound h1 {
  margin-top: 32px;
  font-size: 32px;
}
.notfound h2 {
  margin-top: 32px;
  font-size: 24px;
}
.notfound .lead {
  margin-top: 8px;
}

/* AI assistants guide (/hulp/mcp/) */
.crumb {
  font-size: 15px;
  font-weight: 600;
}
.crumb a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  margin-block: -12px -8px;
  text-decoration: none;
}
.crumb a:hover {
  text-decoration: underline;
}
.server {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px 12px;
  align-self: flex-start;
  max-width: 100%;
  padding: 10px 14px;
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  background: var(--bg-raised);
}
.server-label {
  font-size: 13px;
  font-weight: 700;
  color: var(--text-secondary);
}
.server-url {
  font-size: 15px;
  color: var(--text-primary);
  overflow-wrap: anywhere;
  user-select: all;
}
.beta-note {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  font-size: 15px;
  color: var(--text-secondary);
}
.guide {
  display: flex;
  flex-direction: column;
  gap: 56px;
  min-width: 0;
}
.guide-section {
  display: flex;
  flex-direction: column;
  gap: 14px;
}
.guide-section h2 {
  font-size: 24px;
  letter-spacing: -0.01em;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--line);
}
.guide-section > p,
.guide-section > ul li {
  line-height: 1.65;
  color: var(--text-body);
}
.guide-section > ul {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding-left: 20px;
  list-style: disc;
}
.guide-section > ul li::marker {
  color: var(--text-secondary);
}
.guide :not(pre) > code {
  background: var(--neutral-fill);
  color: var(--text-primary);
  padding: 1px 5px;
  border-radius: 4px;
  overflow-wrap: anywhere;
}
.steps li {
  align-items: flex-start;
  padding: 14px 0;
}
.steps p {
  line-height: 1.6;
  color: var(--text-body);
  padding-top: 2px;
  min-width: 0;
}
.code {
  margin: 0;
  padding: 14px 16px;
  background: var(--bg-raised);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  overflow-x: auto;
  font-size: 14px;
  line-height: 1.55;
  color: var(--text-primary);
}
.code code {
  font-size: inherit;
  white-space: pre;
}
.def-compact > div {
  padding: 12px 0;
}
.def-compact dt {
  font-size: 16px;
}
.def-compact:first-child > div:first-child,
.def-compact > div:first-child {
  border-top: 1px solid var(--line);
}
.tools-title {
  margin-top: 8px;
  font-size: 14px;
  font-weight: 700;
  color: var(--text-secondary);
}
.tools {
  border-top: 1px solid var(--line);
}
.tools > div {
  display: grid;
  grid-template-columns: minmax(0, 2fr) minmax(0, 5fr);
  column-gap: 20px;
  row-gap: 2px;
  padding: 10px 0;
  border-bottom: 1px solid var(--line);
}
.tools dt code {
  font-size: 14px;
  font-weight: 600;
  color: var(--text-primary);
}
.tools dd {
  font-size: 15px;
  line-height: 1.55;
  color: var(--text-secondary);
}
.guide .tools dd code {
  font-size: 13px;
}
.faqs {
  border-top: 1px solid var(--line);
}
.faqs .faq {
  border-bottom: 1px solid var(--line);
}
.faqs .faq summary {
  padding: 8px 0;
}
.topic .more,
.group .more {
  margin-top: 8px;
}
@media (max-width: 860px) {
  .guide {
    gap: 40px;
  }
  .guide-section h2 {
    font-size: 21px;
  }
}
@media (max-width: 640px) {
  .tools > div {
    grid-template-columns: minmax(0, 1fr);
  }
  .code {
    font-size: 13px;
  }
  .code code {
    white-space: pre-wrap;
    overflow-wrap: anywhere;
  }
}
