/* JARVIS — quiet, warm, precise. Typography first, one accent, generous space, one focal element at a time.
   No external fonts or assets: the system font stack only. Light and dark follow the device unless chosen. */

/* ------------------------------------------------------------------------------------------ tokens */

:root {
  --bg: #f5f2ed;
  --bg-raise: #fbfaf7;
  --bg-sunk: #ece7df;
  --ink: #1b1916;
  --ink-2: #4a453e;
  --muted: #776f66;
  --faint: #a39b91;
  --line: rgba(27, 25, 22, 0.09);
  --line-strong: rgba(27, 25, 22, 0.17);
  --accent: #a9522a;
  --accent-ink: #ffffff;
  --accent-soft: rgba(169, 82, 42, 0.09);
  --scrim: rgba(24, 21, 18, 0.28);
  --shadow: 0 1px 1px rgba(27, 25, 22, 0.03), 0 10px 32px rgba(27, 25, 22, 0.07);
  --shadow-lift: 0 2px 4px rgba(27, 25, 22, 0.04), 0 24px 64px rgba(27, 25, 22, 0.14);

  --font: -apple-system, BlinkMacSystemFont, 'SF Pro Text', 'SF Pro Display', system-ui, 'Segoe UI', Roboto,
    'Helvetica Neue', Arial, sans-serif;
  --font-display: -apple-system, BlinkMacSystemFont, 'SF Pro Display', 'SF Pro Text', system-ui, 'Segoe UI', Roboto,
    'Helvetica Neue', Arial, sans-serif;
  --mono: ui-monospace, 'SF Mono', SFMono-Regular, Menlo, Consolas, monospace;

  --ease: cubic-bezier(0.2, 0.7, 0.2, 1);
  --rail: 84px;
  --col: 720px;
  --tabbar-h: 58px;
  --dock-gap: 20px;
  --radius: 16px;
  --radius-s: 11px;
  --safe-top: env(safe-area-inset-top, 0px);
  --safe-bottom: env(safe-area-inset-bottom, 0px);
  --safe-left: env(safe-area-inset-left, 0px);
  --safe-right: env(safe-area-inset-right, 0px);
  color-scheme: light;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #121110;
    --bg-raise: #1a1917;
    --bg-sunk: #0c0b0a;
    --ink: #eee9e2;
    --ink-2: #c8c1b7;
    --muted: #958e84;
    --faint: #6b655d;
    --line: rgba(238, 233, 226, 0.08);
    --line-strong: rgba(238, 233, 226, 0.16);
    --accent: #e0915f;
    --accent-ink: #1b1916;
    --accent-soft: rgba(224, 145, 95, 0.12);
    --scrim: rgba(0, 0, 0, 0.5);
    --shadow: 0 1px 1px rgba(0, 0, 0, 0.3), 0 10px 32px rgba(0, 0, 0, 0.35);
    --shadow-lift: 0 2px 4px rgba(0, 0, 0, 0.35), 0 24px 64px rgba(0, 0, 0, 0.55);
    color-scheme: dark;
  }
}

:root[data-theme="dark"] {
  --bg: #121110;
  --bg-raise: #1a1917;
  --bg-sunk: #0c0b0a;
  --ink: #eee9e2;
  --ink-2: #c8c1b7;
  --muted: #958e84;
  --faint: #6b655d;
  --line: rgba(238, 233, 226, 0.08);
  --line-strong: rgba(238, 233, 226, 0.16);
  --accent: #e0915f;
  --accent-ink: #1b1916;
  --accent-soft: rgba(224, 145, 95, 0.12);
  --scrim: rgba(0, 0, 0, 0.5);
  --shadow: 0 1px 1px rgba(0, 0, 0, 0.3), 0 10px 32px rgba(0, 0, 0, 0.35);
  --shadow-lift: 0 2px 4px rgba(0, 0, 0, 0.35), 0 24px 64px rgba(0, 0, 0, 0.55);
  color-scheme: dark;
}

/* ------------------------------------------------------------------------------------------ base */

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

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
  background: var(--bg);
}

html.is-locked { overflow: hidden; }

body {
  margin: 0;
  min-height: 100vh;
  min-height: 100dvh;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  font-feature-settings: "kern" 1;
}

h1, h2, h3, p, ul, ol, dl, dd, blockquote, figure { margin: 0; }
ul, ol { padding: 0; }
button, input, textarea, select { font: inherit; color: inherit; }
a { color: inherit; text-decoration-color: var(--line-strong); text-underline-offset: 3px; }
a:hover { text-decoration-color: currentColor; }
code, kbd { font-family: var(--mono); font-size: 0.9em; }
time, .tabular { font-variant-numeric: tabular-nums; }
[hidden] { display: none !important; }

::selection { background: var(--accent-soft); }

:focus { outline: none; }
:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

.visually-hidden {
  position: absolute !important;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

.skip {
  position: fixed;
  top: calc(8px + var(--safe-top));
  left: 8px;
  z-index: 100;
  padding: 10px 16px;
  border-radius: 999px;
  background: var(--ink);
  color: var(--bg);
  text-decoration: none;
  transform: translateY(-160%);
  transition: transform 0.15s var(--ease);
}
.skip:focus, .skip:focus-visible { transform: none; }

.noscript { padding: 48px 24px; max-width: 32em; margin: 0 auto; color: var(--ink-2); }

.muted { color: var(--muted); }
.t-label {
  font-size: 12px;
  line-height: 1.3;
  font-weight: 600;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  color: var(--muted);
}
.lede { font-size: 17px; line-height: 1.55; color: var(--ink-2); max-width: 38em; }
.footnote { font-size: 14px; color: var(--muted); margin-top: 24px; }
.link {
  background: none; border: 0; padding: 0; margin: 0;
  color: inherit; text-align: left; cursor: pointer;
  text-decoration: underline; text-decoration-color: var(--line-strong); text-underline-offset: 3px;
}
.link:hover { text-decoration-color: currentColor; }

.icon { flex: 0 0 auto; display: block; }
.mark { color: var(--ink); }
.mark__dot { fill: var(--accent); }

/* ------------------------------------------------------------------------------------------ frame */

.app { min-height: 100vh; min-height: 100dvh; }

.main {
  position: relative;
  min-height: 100vh;
  min-height: 100dvh;
  padding: calc(56px + var(--safe-top)) 40px calc(150px + var(--safe-bottom));
  margin-left: var(--rail);
}
.main:focus-visible { outline: none; }

.view {
  max-width: var(--col);
  margin: 0 auto;
  animation: rise 0.36s var(--ease) both;
}

@keyframes rise {
  from { opacity: 0; transform: translateY(6px); }
  to { opacity: 1; transform: none; }
}

.view__header { margin-bottom: 32px; }
.view__header--row { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; }
.view__title {
  font-family: var(--font-display);
  font-size: clamp(28px, 3.4vw, 36px);
  line-height: 1.12;
  font-weight: 650;
  letter-spacing: -0.022em;
}
.view__title:focus-visible { outline: none; }
.view__lede { margin-top: 8px; color: var(--muted); font-size: 16px; max-width: 36em; }

.boot {
  min-height: 100vh;
  min-height: 100dvh;
  display: grid;
  place-items: center;
}
.boot::after {
  content: "";
  width: 8px; height: 8px;
  border-radius: 50%;
  background: var(--accent);
  animation: breathe 1.6s ease-in-out infinite;
}

/* the rail (desktop) */
.rail {
  position: fixed;
  z-index: 20;
  top: 0; bottom: 0; left: 0;
  width: var(--rail);
  padding: calc(20px + var(--safe-top)) 0 calc(20px + var(--safe-bottom)) var(--safe-left);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 18px;
  border-right: 1px solid var(--line);
  background: var(--bg);
}
.rail__mark {
  display: grid; place-items: center;
  width: 48px; height: 48px;
  border-radius: 14px;
  margin-bottom: 10px;
}
.rail__list { list-style: none; display: flex; flex-direction: column; gap: 2px; }
.rail__link, .rail__tool {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 3px;
  width: 68px;
  min-height: 52px;
  padding: 6px 0;
  border-radius: 12px;
  border: 0;
  background: none;
  color: var(--muted);
  text-decoration: none;
  cursor: pointer;
  transition: color 0.15s, background-color 0.15s;
}
.rail__link__label { font-size: 10.5px; font-weight: 550; letter-spacing: 0.01em; }
.rail__link:hover, .rail__tool:hover { color: var(--ink); background: var(--bg-sunk); }
.rail__link.is-active { color: var(--ink); }
.rail__link.is-active .icon { color: var(--accent); }
.rail__tools { margin-top: auto; display: flex; flex-direction: column; gap: 2px; }
.rail__tool { min-height: 44px; width: 48px; }

/* the tab bar (phone) */
.tabbar {
  display: none;
  position: fixed;
  z-index: 20;
  left: 0; right: 0; bottom: 0;
  padding: 0 var(--safe-right) var(--safe-bottom) var(--safe-left);
  background: var(--bg);
  background: color-mix(in srgb, var(--bg) 88%, transparent);
  -webkit-backdrop-filter: saturate(1.4) blur(18px);
  backdrop-filter: saturate(1.4) blur(18px);
  border-top: 1px solid var(--line);
}
.tabbar__list { list-style: none; display: grid; grid-template-columns: repeat(4, 1fr); }
.tabbar__link {
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px;
  height: var(--tabbar-h);
  color: var(--muted);
  text-decoration: none;
  -webkit-tap-highlight-color: transparent;
}
.tabbar__link__label { font-size: 11px; font-weight: 550; }
.tabbar__link.is-active { color: var(--ink); }
.tabbar__link.is-active .icon { color: var(--accent); }

.offline-bar {
  position: fixed;
  z-index: 25;
  top: calc(12px + var(--safe-top));
  left: calc(var(--rail) + 50%);
  transform: translateX(calc(-50% - var(--rail) / 2));
  display: inline-flex; align-items: center; gap: 8px;
  padding: 6px 14px;
  border-radius: 999px;
  background: var(--bg-raise);
  border: 1px solid var(--line-strong);
  color: var(--ink-2);
  font-size: 13px;
  font-variant-numeric: tabular-nums;
  box-shadow: var(--shadow);
}
.is-now .offline-bar { display: none; }

/* ------------------------------------------------------------------------------------------ the dock (talk input) */

.dock {
  position: fixed;
  z-index: 30;
  left: var(--rail);
  right: 0;
  bottom: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  padding: 36px 40px calc(var(--dock-gap) + var(--safe-bottom));
  pointer-events: none;
  background: linear-gradient(to top, var(--bg) 0, var(--bg) 40%, transparent 100%);
}
.dock > * { pointer-events: auto; width: 100%; max-width: var(--col); }

.composer {
  position: relative;
  display: flex;
  align-items: flex-end;
  gap: 8px;
  padding: 8px 8px 8px 18px;
  border-radius: 22px;
  background: var(--bg-raise);
  border: 1px solid var(--line-strong);
  box-shadow: var(--shadow);
  transition: border-color 0.15s, box-shadow 0.2s;
}
.composer:focus-within { border-color: color-mix(in srgb, var(--accent) 45%, var(--line-strong)); box-shadow: var(--shadow-lift); }
.composer__input {
  flex: 1;
  min-height: 40px;
  max-height: 160px;
  padding: 8px 0;
  border: 0;
  background: transparent;
  resize: none;
  font-size: 16px;
  line-height: 1.5;
  color: var(--ink);
}
.composer__input::placeholder { color: var(--faint); }
.composer__input:focus-visible { outline: none; }
.composer__hint {
  align-self: center;
  padding: 3px 7px;
  border-radius: 6px;
  border: 1px solid var(--line);
  color: var(--faint);
  font-size: 11.5px;
  font-family: var(--font);
  white-space: nowrap;
}
.composer:focus-within .composer__hint { display: none; }
.composer__send {
  flex: 0 0 auto;
  display: grid; place-items: center;
  width: 40px; height: 40px;
  border-radius: 50%;
  border: 0;
  background: var(--ink);
  color: var(--bg);
  cursor: pointer;
  transition: opacity 0.15s, transform 0.15s var(--ease);
}
.composer__send:hover { transform: translateY(-1px); }
.composer__send:disabled { opacity: 0.35; cursor: default; transform: none; }

.dock-reply {
  max-height: min(52vh, 480px);
  overflow: auto;
  overscroll-behavior: contain;
  padding: 16px 20px 18px;
  border-radius: var(--radius);
  background: var(--bg-raise);
  border: 1px solid var(--line);
  box-shadow: var(--shadow-lift);
  animation: rise 0.28s var(--ease) both;
}
.dock-reply__top { display: flex; align-items: center; gap: 12px; margin-bottom: 8px; }
.dock-reply__said {
  flex: 1;
  min-width: 0;
  color: var(--muted);
  font-size: 14px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.dock-reply__link { font-size: 13.5px; color: var(--muted); }

/* ------------------------------------------------------------------------------------------ controls */

.btn {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 44px;
  padding: 0 20px;
  border-radius: 999px;
  border: 1px solid transparent;
  background: none;
  color: var(--ink);
  font-size: 15px;
  font-weight: 560;
  letter-spacing: -0.005em;
  line-height: 1.2;
  text-decoration: none;
  white-space: nowrap;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
  transition: background-color 0.15s, border-color 0.15s, color 0.15s, opacity 0.15s, transform 0.15s var(--ease);
}
.btn:active:not(:disabled) { transform: scale(0.985); }
.btn--primary { background: var(--ink); color: var(--bg); }
.btn--primary:hover:not(:disabled) { background: color-mix(in srgb, var(--ink) 88%, var(--bg)); }
.btn--quiet { border-color: var(--line-strong); }
.btn--quiet:hover:not(:disabled) { background: var(--bg-sunk); }
.btn--ghost { color: var(--muted); }
.btn--ghost:hover:not(:disabled) { color: var(--ink); background: var(--bg-sunk); }
.btn--danger { background: var(--accent); color: var(--accent-ink); }
.btn--small { min-height: 36px; padding: 0 14px; font-size: 14px; }
.btn--large { min-height: 52px; padding: 0 26px; font-size: 16px; width: 100%; }
.btn:disabled { opacity: 0.4; cursor: default; }
.btn.is-busy { opacity: 0.6; pointer-events: none; animation: breathe 1.2s ease-in-out infinite; }
.btn .icon { margin-left: -2px; }

.icon-btn {
  display: grid; place-items: center;
  width: 44px; height: 44px;
  flex: 0 0 auto;
  border-radius: 50%;
  border: 0;
  background: none;
  color: var(--muted);
  cursor: pointer;
}
.icon-btn:hover { color: var(--ink); background: var(--bg-sunk); }

.actions { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; margin-top: 20px; }
.actions--row { flex-wrap: nowrap; margin-top: 0; gap: 6px; flex: 0 0 auto; align-self: center; }
.actions--wrap { flex-wrap: wrap; margin-top: 12px; }
.actions--end { justify-content: flex-end; margin-top: 32px; }

.seg {
  display: inline-flex;
  padding: 3px;
  border-radius: 999px;
  background: var(--bg-sunk);
  gap: 2px;
}
.seg__opt {
  min-height: 32px;
  padding: 0 14px;
  border: 0;
  border-radius: 999px;
  background: none;
  color: var(--muted);
  font-size: 13.5px;
  font-weight: 560;
  cursor: pointer;
  transition: background-color 0.18s, color 0.18s, box-shadow 0.18s;
}
.seg__opt:hover { color: var(--ink); }
.seg__opt[aria-checked="true"] {
  background: var(--bg-raise);
  color: var(--ink);
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.06), 0 0 0 1px var(--line);
}

.input {
  display: block;
  width: 100%;
  min-height: 44px;
  padding: 10px 14px;
  border-radius: var(--radius-s);
  border: 1px solid var(--line-strong);
  background: var(--bg-raise);
  color: var(--ink);
  font-size: 16px;
  line-height: 1.4;
  transition: border-color 0.15s, box-shadow 0.15s;
  -webkit-appearance: none;
  appearance: none;
}
.input::placeholder { color: var(--faint); }
.input:focus { border-color: var(--accent); box-shadow: 0 0 0 4px var(--accent-soft); }
.input:focus-visible { outline: none; }
.input--area { min-height: 96px; resize: vertical; }
.input--select {
  padding-right: 36px;
  background-image: linear-gradient(45deg, transparent 50%, var(--muted) 50%), linear-gradient(135deg, var(--muted) 50%, transparent 50%);
  background-position: calc(100% - 19px) 50%, calc(100% - 14px) 50%;
  background-size: 5px 5px, 5px 5px;
  background-repeat: no-repeat;
}
.input--small { min-height: 40px; padding: 8px 12px; font-size: 15px; }
.input--large { min-height: 50px; font-size: 17px; padding: 12px 16px; }
.input--search { border-radius: 999px; padding-left: 18px; }

.field { display: grid; gap: 6px; margin: 0 0 16px; border: 0; padding: 0; min-width: 0; }
.field__label { font-size: 14px; font-weight: 560; color: var(--ink-2); padding: 0; }
.field__hint { font-size: 13px; color: var(--muted); }

.choices { display: grid; gap: 8px; }
.choice {
  display: flex; align-items: center; gap: 12px;
  min-height: 44px;
  padding: 10px 14px;
  border-radius: var(--radius-s);
  border: 1px solid var(--line-strong);
  cursor: pointer;
  transition: border-color 0.15s, background-color 0.15s;
}
.choice:hover { background: var(--bg-sunk); }
.choice:has(.choice__input:checked) { border-color: var(--accent); background: var(--accent-soft); }
.choice__input { accent-color: var(--accent); width: 18px; height: 18px; margin: 0; }
.choice__label { font-size: 15px; }

.toolbar { display: flex; gap: 10px; align-items: center; margin-bottom: 24px; flex-wrap: wrap; }
.toolbar .input--search { flex: 1 1 220px; }
.toolbar .input--select { flex: 0 1 200px; width: auto; }

.badge {
  display: inline-flex; align-items: center;
  margin-left: 8px;
  padding: 1px 8px;
  border-radius: 999px;
  background: var(--bg-sunk);
  color: var(--muted);
  font-size: 11.5px;
  font-weight: 560;
  letter-spacing: 0.01em;
  vertical-align: 1px;
  white-space: nowrap;
}
.badge--ok { color: var(--ink); background: var(--bg-sunk); }
.badge--warn { color: var(--accent); background: var(--accent-soft); }

.dot { display: inline-block; width: 8px; height: 8px; border-radius: 50%; flex: 0 0 auto; }
.dot--ok { background: var(--faint); }
.dot--bad { background: var(--accent); box-shadow: 0 0 0 4px var(--accent-soft); }

/* ------------------------------------------------------------------------------------------ states */

.empty { padding: 28px 0; }
.empty__title { font-size: 17px; font-weight: 560; color: var(--ink-2); }
.empty__text { margin-top: 4px; color: var(--muted); max-width: 32em; }

.loading { display: grid; gap: 10px; padding: 20px 0; }
.loading__line {
  display: block;
  height: 12px;
  border-radius: 6px;
  background: linear-gradient(90deg, var(--bg-sunk) 0%, color-mix(in srgb, var(--bg-sunk) 50%, var(--bg)) 50%, var(--bg-sunk) 100%);
  background-size: 200% 100%;
  animation: shimmer 1.4s linear infinite;
}
.loading__line--short { width: 40%; }
.loading__line--mid { width: 70%; }

@keyframes shimmer { from { background-position: 100% 0; } to { background-position: -100% 0; } }
@keyframes breathe { 0%, 100% { opacity: 1; } 50% { opacity: 0.45; } }

.notice {
  margin: 16px 0;
  padding: 14px 18px;
  border-radius: var(--radius-s);
  background: var(--accent-soft);
  border-left: 2px solid var(--accent);
}
.notice--compact { margin: 10px 0; padding: 10px 14px; }
.notice__title { font-weight: 560; }
.notice__text { margin-top: 2px; color: var(--ink-2); font-size: 15px; }
.notice__reasons { margin: 8px 0 0 18px; color: var(--ink-2); font-size: 15px; }
.notice__reasons li + li { margin-top: 2px; }
.notice__actions { margin-top: 10px; }

.stale {
  display: inline-flex; align-items: center; gap: 6px;
  margin-bottom: 16px;
  color: var(--muted);
  font-size: 13px;
  font-variant-numeric: tabular-nums;
}

/* ------------------------------------------------------------------------------------------ NOW */

.now__top { display: flex; align-items: center; justify-content: space-between; gap: 16px; flex-wrap: wrap; }
.now__when { display: grid; gap: 2px; }
.now__date { color: var(--muted); font-size: 14px; font-variant-numeric: tabular-nums; letter-spacing: 0.01em; }
.now__stale { display: inline-flex; align-items: center; gap: 6px; color: var(--accent); font-size: 13px; font-variant-numeric: tabular-nums; }

.now__headline {
  margin: 44px 0 36px;
  max-width: 19em;
  font-family: var(--font-display);
  font-size: clamp(30px, 4.4vw, 46px);
  line-height: 1.1;
  font-weight: 650;
  letter-spacing: -0.026em;
  text-wrap: balance;
}
.now__headline:focus-visible { outline: none; }
.now[data-state="clear"] .now__headline { margin-top: max(56px, 14vh); font-weight: 600; color: var(--ink-2); }
.now[data-state="clear"] .now__clear { margin-top: 4px; }
.now[data-state="clear"] .now__clear-mark { width: 56px; height: 56px; }
.now__note { margin: -20px 0 28px; color: var(--muted); font-size: 14.5px; }

.one {
  position: relative;
  padding: 30px 32px 28px;
  border-radius: 22px;
  background: var(--bg-raise);
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
  animation: rise 0.42s var(--ease) both;
}
.one::before {
  content: "";
  position: absolute;
  left: 32px; top: -1px;
  width: 28px; height: 2px;
  border-radius: 2px;
  background: var(--accent);
}
.one--quiet::before { background: var(--line-strong); }
.one__kicker {
  font-size: 12px;
  font-weight: 650;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
}
.one__kicker.is-loud, .one--loud .one__kicker { color: var(--accent); }
.one__title {
  margin-top: 10px;
  font-family: var(--font-display);
  font-size: clamp(22px, 2.6vw, 27px);
  line-height: 1.22;
  font-weight: 620;
  letter-spacing: -0.016em;
  text-wrap: pretty;
}
.one__title--small { font-size: 19px; line-height: 1.35; font-weight: 560; }
.one__detail { margin-top: 10px; color: var(--ink-2); font-size: 16px; max-width: 40em; }
.one__meta { margin-top: 10px; color: var(--muted); font-size: 14px; font-variant-numeric: tabular-nums; }
.one__questions { display: grid; gap: 16px; margin-top: 22px; }
.one__questions + .actions { margin-top: 16px; }

.question { display: grid; gap: 10px; }
.question__text { color: var(--ink-2); font-size: 15.5px; }
.question__options { display: flex; flex-wrap: wrap; gap: 8px; }
.question__form { display: flex; gap: 8px; }
.question__form .input { flex: 1; min-width: 0; }
/* a date question: the days offered first, any other day in words under them, 'No, leave it' set apart */
.question--days .question__days .btn { font-variant-numeric: tabular-nums; }
.question--days .question__other { max-width: 420px; }
.question--days .question__leave { padding-top: 2px; }

.now__sections { margin-top: 44px; border-bottom: 1px solid var(--line); }
.now__clear { display: flex; align-items: center; gap: 18px; margin-top: 8px; color: var(--muted); }
.now__clear-mark {
  position: relative;
  width: 44px; height: 44px;
  flex: 0 0 auto;
  border-radius: 50%;
  border: 1.5px solid var(--line-strong);
}
.now__clear-mark::after {
  content: "";
  position: absolute;
  left: 50%; top: 50%;
  width: 6px; height: 6px;
  margin: -3px 0 0 -3px;
  border-radius: 50%;
  background: var(--accent);
  animation: breathe 4s ease-in-out infinite;
}

.now-focus {
  padding: 28px 0 8px;
  border-top: 2px solid var(--accent);
  max-width: 34em;
}
.now-focus__label {
  margin-top: 10px;
  font-family: var(--font-display);
  font-size: clamp(24px, 3vw, 30px);
  line-height: 1.2;
  font-weight: 620;
  letter-spacing: -0.018em;
}
.now-focus__time { margin-top: 6px; color: var(--ink-2); font-variant-numeric: tabular-nums; }
.now-focus__held { margin-top: 14px; color: var(--muted); font-size: 14.5px; }
.now-focus + .one { margin-top: 28px; }

.now__away {
  display: flex; align-items: center; gap: 12px;
  width: 100%;
  margin-top: 28px;
  min-height: 52px;
  padding: 12px 16px;
  border-radius: var(--radius-s);
  border: 1px solid var(--line-strong);
  background: none;
  text-align: left;
  cursor: pointer;
}
.now__away::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: var(--accent); flex: 0 0 auto; }
.now__away:hover { background: var(--bg-sunk); }
.now__away-label { flex: 1; font-weight: 560; }
.now__away-meta { color: var(--muted); font-size: 14px; font-variant-numeric: tabular-nums; }

.now__footer { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 48px; }
.now__footer .btn { color: var(--muted); border-color: var(--line); }
.now__footer .btn:hover:not(:disabled) { color: var(--ink); }

/* ------------------------------------------------------------------------------------------ disclosures */

.disc { border-top: 1px solid var(--line); }
.disc__summary {
  display: flex;
  align-items: center;
  gap: 12px;
  min-height: 56px;
  padding: 8px 4px;
  list-style: none;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}
.disc__summary::-webkit-details-marker { display: none; }
.disc__label { flex: 1; font-size: 16px; font-weight: 560; color: var(--ink-2); }
.disc__count {
  min-width: 26px;
  padding: 1px 8px;
  border-radius: 999px;
  background: var(--bg-sunk);
  color: var(--ink-2);
  font-size: 13px;
  font-weight: 600;
  text-align: center;
  font-variant-numeric: tabular-nums;
}
.disc__chev { color: var(--faint); transition: transform 0.2s var(--ease); }
.disc[open] > .disc__summary .disc__chev { transform: rotate(180deg); }
.disc__summary:hover .disc__label { color: var(--ink); }
.disc__body { padding: 0 0 20px; animation: rise 0.24s var(--ease) both; }
.disc--empty .disc__summary { cursor: default; }
.disc--empty .disc__label { color: var(--faint); font-weight: 500; }
.disc--empty .disc__count { background: none; color: var(--faint); }
.disc--inline { border-top: 0; margin-top: 8px; }
.disc--inline > .disc__summary { min-height: 44px; padding: 0; }
.disc--inline .disc__label { font-size: 14.5px; color: var(--muted); flex: 0 1 auto; }
.disc--inline .disc__count { background: none; color: var(--faint); padding: 0; }

/* ------------------------------------------------------------------------------------------ rows */

.rows { list-style: none; }
.row {
  position: relative;
  display: flex;
  align-items: flex-start;
  gap: 14px;
  padding: 14px 0;
  border-top: 1px solid var(--line);
}
.rows > .row:first-child { border-top: 0; }
.disc__body > .rows > .row:first-child { border-top: 1px solid var(--line); }
.row__mark {
  position: absolute;
  left: -16px; top: 24px;
  width: 6px; height: 6px;
  border-radius: 50%;
  background: var(--accent);
}
.row__main {
  flex: 1;
  min-width: 0;
  display: grid;
  gap: 3px;
  align-content: start;
  text-align: left;
}
.row__main--link {
  position: relative;
  grid-template-columns: 1fr auto;
  column-gap: 12px;
  margin: -8px -10px;
  padding: 8px 10px;
  min-height: 44px;
  border: 0;
  border-radius: var(--radius-s);
  background: none;
  color: inherit;
  text-decoration: none;
  cursor: pointer;
  transition: background-color 0.15s;
}
.row__main--link > * { grid-column: 1; }
.row__main--link:hover { background: var(--bg-sunk); }
.row__chev { grid-column: 2 !important; grid-row: 1 / span 4; align-self: center; color: var(--faint); }
.row__kicker {
  font-size: 11.5px;
  font-weight: 650;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  color: var(--muted);
}
.row__kicker.is-loud { color: var(--accent); }
.row__title { font-size: 16px; font-weight: 560; line-height: 1.35; overflow-wrap: anywhere; }
.row__title--prose { font-weight: 450; }
.row__detail { font-size: 14.5px; color: var(--ink-2); line-height: 1.45; overflow-wrap: anywhere; }
.row__meta { font-size: 13px; color: var(--muted); font-variant-numeric: tabular-nums; }
.rows--tight .row { padding: 10px 0; }
.row.is-forgotten .row__title { color: var(--muted); text-decoration: line-through; text-decoration-color: var(--line-strong); }
.row.is-paused .row__title, .row.is-revoked .row__title { color: var(--muted); }

.group { margin-top: 32px; }
.group:first-child { margin-top: 0; }
.group__title {
  display: flex; align-items: baseline; gap: 10px;
  padding-bottom: 8px;
  font-size: 12px;
  font-weight: 650;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
  border-bottom: 1px solid var(--line);
}
.group__count { font-variant-numeric: tabular-nums; color: var(--faint); }
.group > .rows > .row:first-child { border-top: 0; }

.lines { list-style: none; display: grid; gap: 8px; padding: 12px 0 4px; }
.lines li { position: relative; padding-left: 16px; color: var(--ink-2); }
.lines li::before { content: ""; position: absolute; left: 2px; top: 0.72em; width: 4px; height: 4px; border-radius: 50%; background: var(--faint); }
.lines--memory li { color: var(--ink); }
.lines--mono li { font-family: var(--mono); font-size: 13px; }

/* ------------------------------------------------------------------------------------------ talk */

.talk { display: flex; flex-direction: column; min-height: calc(100vh - 250px); }
.thread { list-style: none; display: flex; flex-direction: column; gap: 22px; margin-top: 8px; }
.msg { display: flex; flex-direction: column; max-width: 100%; animation: rise 0.28s var(--ease) both; scroll-margin-bottom: 150px; }
.msg--user { align-items: flex-end; }
.msg__text {
  max-width: min(80%, 34em);
  padding: 10px 16px;
  border-radius: 20px 20px 6px 20px;
  background: var(--bg-sunk);
  color: var(--ink);
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}
.msg--jarvis { align-items: flex-start; }
.msg__body { max-width: 100%; width: 100%; }
.msg__time { margin-top: 4px; font-size: 12px; color: var(--faint); font-variant-numeric: tabular-nums; }

.prose p + p, .prose p + ul, .prose ul + p { margin-top: 8px; }
.prose { font-size: 16px; line-height: 1.55; overflow-wrap: anywhere; }
.prose ul { list-style: none; display: grid; gap: 4px; }
.prose li { position: relative; padding-left: 16px; }
.prose li::before { content: ""; position: absolute; left: 2px; top: 0.72em; width: 4px; height: 4px; border-radius: 50%; background: var(--faint); }

.reply { display: grid; gap: 12px; }
.reply__head { display: grid; gap: 12px; }
.reply .rows { margin-top: 2px; }
.reply__sources { font-size: 13px; color: var(--muted); }
.receipt { display: grid; gap: 10px; transition: opacity 0.2s; }
.receipt.is-busy { opacity: 0.55; pointer-events: none; }
.receipt__note { color: var(--ink-2); font-size: 15px; }
.receipt__warn { font-size: 14.5px; color: var(--ink-2); padding-left: 12px; border-left: 2px solid var(--accent); }
.receipt__undo { display: flex; flex-wrap: wrap; gap: 8px; }
.receipt .question { padding: 12px 14px; border-radius: var(--radius-s); background: var(--bg-sunk); }

.chips { list-style: none; display: flex; flex-wrap: wrap; gap: 6px; }
.chip__btn {
  display: inline-flex; align-items: baseline; gap: 7px;
  min-height: 36px;
  padding: 7px 13px;
  border-radius: 999px;
  border: 1px solid var(--line-strong);
  background: var(--bg-raise);
  color: var(--ink);
  font-size: 14px;
  line-height: 1.3;
  text-decoration: none;
  cursor: pointer;
}
button.chip__btn:hover, a.chip__btn:hover { background: var(--bg-sunk); }
span.chip__btn { cursor: default; }
.chip__type { font-size: 11px; font-weight: 650; letter-spacing: 0.06em; text-transform: uppercase; color: var(--muted); }
.chip__title { font-weight: 560; }
.chip__status { color: var(--muted); font-size: 13px; }
.chip__flag { color: var(--accent); font-size: 12px; font-weight: 600; }
.chip__btn--ref { align-items: center; gap: 4px; padding-right: 9px; }
.chip__btn--ref .chip__title { font-weight: 500; color: var(--ink-2); }
.chip__chev { color: var(--faint); }

.thinking { display: inline-flex; gap: 5px; padding: 10px 0; }
.thinking--inline { padding: 4px 0; }
.thinking__dot { width: 6px; height: 6px; border-radius: 50%; background: var(--faint); animation: breathe 1.2s ease-in-out infinite; }
.thinking__dot:nth-child(3) { animation-delay: 0.15s; }
.thinking__dot:nth-child(4) { animation-delay: 0.3s; }

/* ------------------------------------------------------------------------------------------ focus */

.is-focus-mode .rail, .is-focus-mode .tabbar { display: none; }
.is-focus-mode .main { margin-left: 0; }
.is-focus-mode .dock { left: 0; }
.is-focus-mode .dock > * { max-width: 560px; }

.view.focus {
  min-height: calc(100vh - 240px);
  display: flex;
  flex-direction: column;
  justify-content: center;
}
.focus__body { width: 100%; max-width: 620px; margin: 0 auto; }
.focus__label {
  margin-top: 14px;
  font-family: var(--font-display);
  font-size: clamp(36px, 6vw, 62px);
  line-height: 1.04;
  font-weight: 650;
  letter-spacing: -0.03em;
  text-wrap: balance;
}
.focus__label:focus-visible { outline: none; }
.focus__time { margin-top: 16px; font-size: 19px; color: var(--ink-2); font-variant-numeric: tabular-nums; letter-spacing: 0.005em; }
.is-time-up .focus__time { color: var(--accent); }
.focus__stats { margin-top: 4px; color: var(--muted); font-size: 14px; }
.focus__checkins { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 8px; margin-top: 36px; transition: opacity 0.2s; }
.focus__checkins.is-busy { opacity: 0.5; pointer-events: none; }
.focus__checkin { width: 100%; }
.focus__checkin:not(.btn--primary) { border-color: var(--line-strong); }
.focus__nudge { margin-top: 16px; min-height: 1.5em; color: var(--ink-2); max-width: 36em; }
.focus__foot { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 12px; }
.focus__foot .btn { color: var(--muted); }
.focus__related { margin-top: 48px; }
.focus__related .t-label { margin-bottom: 4px; }
.focus__hint { margin-top: 36px; color: var(--faint); font-size: 13.5px; }
.focus__leave { display: inline-block; margin-top: 6px; color: var(--muted); font-size: 13.5px; padding: 10px 0; }

/* ------------------------------------------------------------------------------------------ sheets and dialogs */

.sheet { position: fixed; inset: 0; z-index: 50; }
.sheet__scrim {
  position: absolute; inset: 0;
  background: var(--scrim);
  opacity: 0;
  transition: opacity 0.22s var(--ease);
}
.sheet__panel {
  position: absolute;
  top: 0; right: 0; bottom: 0;
  width: min(560px, 100%);
  display: flex;
  flex-direction: column;
  background: var(--bg);
  border-left: 1px solid var(--line);
  box-shadow: var(--shadow-lift);
  opacity: 0;
  transform: translateX(28px);
  transition: opacity 0.22s var(--ease), transform 0.28s var(--ease);
}
.sheet__panel--wide { width: min(640px, 100%); }
.sheet.is-open .sheet__scrim { opacity: 1; }
.sheet.is-open .sheet__panel { opacity: 1; transform: none; }
.sheet.is-leaving .sheet__scrim { opacity: 0; }
.sheet.is-leaving .sheet__panel { opacity: 0; transform: translateX(28px); }
.sheet__header {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: calc(20px + var(--safe-top)) 20px 16px 28px;
  border-bottom: 1px solid var(--line);
}
.sheet__heading { flex: 1; min-width: 0; padding-top: 6px; }
.sheet__kicker { margin-bottom: 4px; }
.sheet__title {
  font-family: var(--font-display);
  font-size: 23px;
  line-height: 1.22;
  font-weight: 640;
  letter-spacing: -0.016em;
  overflow-wrap: anywhere;
}
.sheet__title:focus-visible { outline: none; }
.sheet__body {
  flex: 1;
  overflow: auto;
  overscroll-behavior: contain;
  -webkit-overflow-scrolling: touch;
  padding: 24px 28px calc(40px + var(--safe-bottom));
}
.sheet__footer {
  display: flex; align-items: center; justify-content: flex-end; gap: 10px;
  margin-top: 32px;
  padding-top: 20px;
  border-top: 1px solid var(--line);
}
.sheet__footnote { flex: 1; color: var(--muted); font-size: 13.5px; }
.sheet .lede { margin-bottom: 28px; }
.eod__start { margin-bottom: 32px; }

.dialog-layer {
  position: fixed; inset: 0; z-index: 60;
  display: grid;
  place-items: center;
  padding: 16px;
}
.dialog-layer__scrim { position: absolute; inset: 0; background: var(--scrim); animation: fade 0.18s var(--ease) both; }
.dialog {
  position: relative;
  width: min(460px, 100%);
  max-height: calc(100vh - 32px);
  overflow: auto;
  padding: 26px 26px 22px;
  border-radius: 22px;
  background: var(--bg-raise);
  box-shadow: var(--shadow-lift);
  animation: pop 0.24s var(--ease) both;
}
.dialog__title { font-size: 20px; line-height: 1.25; font-weight: 640; letter-spacing: -0.012em; margin-bottom: 8px; }
.dialog__body { color: var(--ink-2); margin-bottom: 20px; }
.dialog__form .field:first-of-type { margin-top: 16px; }
.dialog__error { min-height: 1.4em; color: var(--accent); font-size: 14px; margin: 4px 0 8px; }
.dialog__actions { display: flex; justify-content: flex-end; gap: 10px; flex-wrap: wrap; }

@keyframes fade { from { opacity: 0; } to { opacity: 1; } }
@keyframes pop { from { opacity: 0; transform: translateY(8px) scale(0.985); } to { opacity: 1; transform: none; } }

.toasts {
  position: fixed;
  z-index: 70;
  left: var(--rail); right: 0;
  bottom: calc(var(--dock-gap) + 84px + var(--safe-bottom));
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  padding: 0 16px;
  pointer-events: none;
}
.toast {
  pointer-events: auto;
  display: flex; align-items: center; gap: 10px;
  max-width: min(520px, 100%);
  padding: 8px 6px 8px 18px;
  border-radius: 14px;
  background: var(--ink);
  color: var(--bg);
  box-shadow: var(--shadow-lift);
  animation: pop 0.22s var(--ease) both;
  transition: opacity 0.18s, transform 0.18s var(--ease);
}
.toast.is-leaving { opacity: 0; transform: translateY(6px); }
.toast--alert { box-shadow: inset 3px 0 0 var(--accent), var(--shadow-lift); }
.toast__text { flex: 1; font-size: 15px; line-height: 1.4; padding: 4px 0; }
.toast .btn { color: var(--bg); border-color: color-mix(in srgb, var(--bg) 30%, transparent); }
.toast .icon-btn { color: color-mix(in srgb, var(--bg) 70%, transparent); width: 40px; height: 40px; }
.toast .icon-btn:hover { color: var(--bg); background: color-mix(in srgb, var(--bg) 12%, transparent); }

/* ------------------------------------------------------------------------------------------ object detail */

.detail { display: grid; gap: 28px; }
.stateline-wrap { margin: -4px -28px 0; padding: 0 28px; overflow-x: auto; scrollbar-width: none; }
.stateline-wrap::-webkit-scrollbar { display: none; }
.stateline { list-style: none; display: flex; padding: 6px 0 2px; min-width: max-content; }
.stateline__step {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 8px;
  min-width: 84px;
  padding-right: 12px;
}
.stateline__step::before {
  content: "";
  position: absolute;
  left: 5px; right: 0; top: 5px;
  height: 1px;
  background: var(--line-strong);
}
.stateline__step:last-child::before { display: none; }
.stateline__step.is-past::before { background: var(--ink-2); }
.stateline__dot {
  position: relative;
  width: 11px; height: 11px;
  border-radius: 50%;
  background: var(--bg);
  border: 1.5px solid var(--line-strong);
}
.stateline__step.is-past .stateline__dot { background: var(--ink-2); border-color: var(--ink-2); }
.stateline__step.is-current .stateline__dot { background: var(--accent); border-color: var(--accent); box-shadow: 0 0 0 5px var(--accent-soft); }
.stateline__name { font-size: 12px; color: var(--faint); white-space: nowrap; }
.stateline__step.is-past .stateline__name { color: var(--muted); }
.stateline__step.is-current .stateline__name { color: var(--ink); font-weight: 650; }
.stateline__side { margin-top: 10px; font-size: 14px; color: var(--muted); }
.stateline__side strong { color: var(--accent); font-weight: 650; }

.detail__expect { display: grid; gap: 8px; }
.detail__next { font-size: 17px; }
.detail__next strong { font-weight: 640; }
.detail__action { color: var(--ink-2); }
.detail__moves .actions { margin-top: 0; }
.detail__error:empty { display: none; }
.detail__label { margin-bottom: 10px; }
.detail__section--loud .detail__label { color: var(--accent); }
.detail__body {
  margin-top: 12px;
  padding: 14px 16px;
  border-radius: var(--radius-s);
  background: var(--bg-sunk);
  white-space: pre-wrap;
  color: var(--ink-2);
}
.detail__foot { padding-top: 8px; border-top: 1px solid var(--line); }
.detail__rel { margin-top: -8px; }

.pairs { display: grid; gap: 0; }
.pairs__row {
  display: grid;
  grid-template-columns: 150px 1fr;
  gap: 16px;
  padding: 9px 0;
  border-top: 1px solid var(--line);
}
.pairs__row:first-child { border-top: 0; }
.pairs dt { color: var(--muted); font-size: 14px; }
.pairs dd { color: var(--ink); font-variant-numeric: tabular-nums; overflow-wrap: anywhere; }
.pairs--wide { margin-bottom: 20px; }
.pairs__row--accent dd { font-weight: 560; }
.pairs__row--accent dt { color: var(--accent); }

.evidence { list-style: none; display: grid; gap: 0; }
.evidence__item { padding: 12px 0; border-top: 1px solid var(--line); }
.evidence__item:first-child { border-top: 0; padding-top: 0; }
.evidence__kind { font-size: 13px; font-weight: 600; color: var(--muted); }
.evidence__summary { margin-top: 2px; }
.evidence__meta { margin-top: 2px; font-size: 13px; color: var(--muted); font-variant-numeric: tabular-nums; }

.timeline { list-style: none; position: relative; display: grid; gap: 14px; padding-left: 20px; }
.timeline::before { content: ""; position: absolute; left: 4px; top: 6px; bottom: 6px; width: 1px; background: var(--line-strong); }
.timeline__item { position: relative; }
.timeline__dot { position: absolute; left: -20px; top: 7px; width: 9px; height: 9px; border-radius: 50%; background: var(--bg); border: 1.5px solid var(--faint); }
.timeline__item:first-child .timeline__dot { border-color: var(--accent); background: var(--accent); }
.timeline__text { font-size: 15px; }
.timeline__meta { font-size: 13px; color: var(--muted); }

/* ------------------------------------------------------------------------------------------ people, memory, activity */

.back {
  display: inline-flex; align-items: center; gap: 6px;
  margin: -10px 0 18px -6px;
  padding: 10px 6px;
  color: var(--muted);
  font-size: 14.5px;
  text-decoration: none;
}
.back:hover { color: var(--ink); }
.person__header { display: grid; gap: 8px; margin-bottom: 28px; }
.person__header .chips { margin-top: 8px; }

.memory__row .row__title { font-size: 16px; }

.day + .day { margin-top: 32px; }
.day__label {
  padding-bottom: 8px;
  font-size: 12px;
  font-weight: 650;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
  border-bottom: 1px solid var(--line);
}
.events { list-style: none; }
.event { display: grid; grid-template-columns: 56px 1fr; gap: 12px; padding: 12px 0; border-top: 1px solid var(--line); }
.event:first-child { border-top: 0; }
.event__time { color: var(--muted); font-size: 14px; padding-top: 1px; }
.event__text { font-size: 15.5px; text-decoration: none; }
button.event__text:hover { text-decoration: underline; text-decoration-color: var(--line-strong); }
.event__actor { font-size: 13px; color: var(--faint); }
.activity__more { margin-top: 24px; }

.venture__asof { color: var(--muted); font-size: 14px; margin-bottom: 24px; font-variant-numeric: tabular-nums; }
.venture .one { margin-bottom: 36px; }

/* ------------------------------------------------------------------------------------------ system */

.sys { border-top: 1px solid var(--line); }
.system .sys:last-of-type { border-bottom: 1px solid var(--line); }
.sys > .disc__summary .disc__label { font-size: 17px; }
.sys__summary { display: flex; align-items: center; gap: 10px; font-weight: 560; margin-bottom: 12px; }
.sys__rows { list-style: none; }
.sys__row {
  display: grid;
  grid-template-columns: 8px 130px 1fr;
  align-items: center;
  gap: 12px;
  padding: 9px 0;
  border-top: 1px solid var(--line);
}
.sys__name { font-size: 14.5px; font-weight: 560; }
.sys__text { font-size: 14px; color: var(--ink-2); font-variant-numeric: tabular-nums; overflow-wrap: anywhere; }
.sys__note { font-size: 14px; color: var(--muted); margin: 8px 0 16px; max-width: 42em; }
.sys__account { margin-top: 40px; display: grid; gap: 4px; }
.sys__account .actions { margin-top: 12px; }

.integrations { list-style: none; display: grid; }
.integration { padding: 16px 0; border-top: 1px solid var(--line); }
.integration:first-child { border-top: 0; padding-top: 4px; }
.integration__head { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; }
.integration__name { font-weight: 600; font-size: 16px; }
.integration__status { font-size: 11.5px; font-weight: 700; letter-spacing: 0.1em; color: var(--accent); white-space: nowrap; }
.integration__status.is-ok { color: var(--muted); }
.integration__needs { margin-top: 6px; font-size: 14px; color: var(--ink-2); }
.integration__needs code { padding: 1px 6px; border-radius: 6px; background: var(--bg-sunk); font-size: 12.5px; }
.integration__error { margin-top: 6px; font-size: 14px; color: var(--accent); }
.integration__interim { margin-top: 12px; }
.integration__interim .lines { padding-top: 6px; }
.provider { margin-bottom: 16px; }

.caps { list-style: none; display: grid; }
.cap { padding: 12px 0; border-top: 1px solid var(--line); }
.cap:first-child { border-top: 0; }
.cap.is-unsupported .cap__name { color: var(--muted); }
.cap__name { font-weight: 560; font-size: 14.5px; }
.cap__how code { font-size: 12.5px; color: var(--ink-2); overflow-wrap: anywhere; }
.cap__notes { font-size: 13.5px; color: var(--ink-2); margin-top: 2px; }
.cap__doc { display: inline-flex; align-items: center; gap: 4px; margin-top: 4px; font-size: 13.5px; color: var(--muted); padding: 6px 0; }
.cap .muted { font-size: 13px; }

.prefs { list-style: none; }
.pref { display: flex; gap: 16px; align-items: center; padding: 12px 0; border-top: 1px solid var(--line); }
.pref:first-child { border-top: 0; }
.pref__main { flex: 1; min-width: 0; }
.pref__label { font-size: 15px; }
.pref__value { margin-top: 2px; }
.pref__v { font-family: var(--mono); font-size: 13.5px; color: var(--ink-2); }
.pref__key { font-family: var(--mono); font-size: 12px; margin-top: 2px; }

/* ------------------------------------------------------------------------------------------ more */

.more__list { list-style: none; border-top: 1px solid var(--line); }
.more__list + .more__list { margin-top: 28px; }
.more__link {
  display: flex; align-items: center; gap: 16px;
  width: 100%;
  min-height: 64px;
  padding: 10px 4px;
  border: 0;
  border-bottom: 1px solid var(--line);
  background: none;
  color: var(--ink);
  text-align: left;
  text-decoration: none;
  cursor: pointer;
}
.more__link > .icon:first-child { color: var(--muted); }
.more__text { flex: 1; display: grid; }
.more__label { font-weight: 560; }
.more__meta { font-size: 14px; color: var(--muted); }
.more__chev { color: var(--faint); }
.more__account { margin-top: 32px; display: grid; gap: 12px; justify-items: start; }

/* ------------------------------------------------------------------------------------------ sign in */

.auth {
  min-height: 100vh;
  min-height: 100dvh;
  display: grid;
  place-items: center;
  padding: calc(40px + var(--safe-top)) 24px calc(40px + var(--safe-bottom));
}
.auth__inner { width: min(400px, 100%); animation: rise 0.4s var(--ease) both; }
.auth__mark { margin-bottom: 28px; }
.auth__title {
  font-family: var(--font-display);
  font-size: 38px;
  line-height: 1.08;
  font-weight: 680;
  letter-spacing: -0.03em;
}
.auth__lede { margin-top: 10px; color: var(--muted); font-size: 16.5px; }
.auth__form { margin-top: 36px; }
.auth__error { min-height: 1.5em; margin: 4px 0 14px; color: var(--accent); font-size: 14.5px; }
.auth__form .btn + .btn { margin-top: 10px; }

/* ------------------------------------------------------------------------------------------ phone */

@media (max-width: 899px) {
  .rail { display: none; }
  .tabbar { display: block; }
  .main {
    margin-left: 0;
    padding: calc(24px + var(--safe-top)) calc(20px + var(--safe-right)) calc(var(--tabbar-h) + 104px + var(--safe-bottom)) calc(20px + var(--safe-left));
  }
  .dock {
    left: 0;
    bottom: calc(var(--tabbar-h) + var(--safe-bottom));
    padding: 8px calc(12px + var(--safe-right)) 10px calc(12px + var(--safe-left));
    background: var(--bg);
    background: linear-gradient(to top, var(--bg) 70%, color-mix(in srgb, var(--bg) 0%, transparent));
    pointer-events: auto;
  }
  .composer { border-radius: 24px; padding: 6px 6px 6px 16px; box-shadow: none; }
  .composer__hint { display: none; }
  .dock-reply { max-height: 46vh; }
  .offline-bar { left: 50%; transform: translateX(-50%); }
  .toasts { left: 0; bottom: calc(var(--tabbar-h) + 84px + var(--safe-bottom)); }

  .is-focus-mode .dock { bottom: var(--safe-bottom); }
  .is-focus-mode .main { padding-bottom: calc(110px + var(--safe-bottom)); }
  .is-focus-mode .toasts { bottom: calc(90px + var(--safe-bottom)); }

  .now__headline { margin: 32px 0 28px; }
  .one { padding: 24px 22px 22px; border-radius: 20px; }
  .one::before { left: 22px; }
  .row__mark { left: -12px; }

  .sheet__panel, .sheet__panel--wide {
    top: calc(28px + var(--safe-top));
    left: 0; right: 0;
    width: 100%;
    border-left: 0;
    border-radius: 22px 22px 0 0;
    transform: translateY(32px);
  }
  .sheet.is-leaving .sheet__panel { transform: translateY(32px); }
  .sheet__header { padding: 14px 12px 12px 22px; }
  .sheet__body { padding: 20px 22px calc(32px + var(--safe-bottom)); }
  .stateline-wrap { margin: -4px -22px 0; padding: 0 22px; }

  .dialog-layer { place-items: end center; padding: 12px 12px calc(12px + var(--safe-bottom)); }
  .dialog { border-radius: 22px; }

  .focus__checkins { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .pairs__row { grid-template-columns: 1fr; gap: 2px; }
  .sys__row { grid-template-columns: 8px 1fr; }
  .sys__text { grid-column: 2; }
  .view__header--row { flex-direction: column; }
  /* the text keeps a readable column: when a row's buttons do not fit beside it, they take a line of their own */
  .row { flex-wrap: wrap; }
  .row > .row__main { flex: 1 1 220px; }
  .row > .actions--row { margin-left: auto; flex-wrap: wrap; justify-content: flex-end; max-width: 100%; }
}

@media (max-width: 420px) {
  .now__top { gap: 12px; }
  .seg__opt { padding: 0 11px; }
  .actions .btn:not(.btn--small) { flex: 1 1 auto; }
}

/* touch: every target at least 44 px */
@media (pointer: coarse) {
  .btn--small { min-height: 44px; }
  .seg__opt { min-height: 40px; }
  .chip__btn { min-height: 44px; padding-top: 11px; padding-bottom: 11px; }
  .input--small { min-height: 44px; }
}

/* ------------------------------------------------------------------------------------------ motion */

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
    scroll-behavior: auto !important;
  }
}

@media print {
  .rail, .tabbar, .dock, .toasts, .offline-bar { display: none !important; }
  .main { margin: 0; padding: 0; }
}
