@font-face { font-family: Geist; src: url('/geist.woff2') format('woff2'); font-weight: 100 900; font-display: swap; }
@font-face { font-family: Fraunces; src: url('/fraunces.woff2') format('woff2'); font-weight: 900; font-display: swap; }

:root {
  --paper: #f7f8fa; --surface: #fff; --raised: #eff1f5; --over: #e7eaf0;
  --ink: #0f172a; --ink-2: #475569; --ink-3: #6b7890;
  --line: rgb(15 23 42 / 0.08); --line-2: rgb(15 23 42 / 0.14);
  --accent: #2563eb; --accent-soft: #edf3ff; --glow: rgb(37 99 235 / 0.14);
  --ok: #15803d; --ok-soft: #e6f5eb; --ok-line: #bfe5cb;
  --wait: #9a5b00; --wait-soft: #fdf4dc; --wait-line: #f2dfaa;
  --stop: #b91c1c; --stop-soft: #fde8e8;
  --main: #0f172a; --main-ink: #fff; --main-over: #1e293b;
  --go: #2563eb; --go-over: #1d4fd8;
  --press: #2563eb; --press-lit: #2f6df2; --press-deep: #1d4ed8; --press-deeper: #1a45c2;
  --amber: #c26a05; --amber-soft: #fef6e0;
  --blue: #2563eb; --blue-soft: #e8effe;
  --green: #15803d; --green-soft: #e3f6ea;
  --pink: #be185d; --pink-soft: #fde8f1;
  --violet: #6d28d9; --violet-soft: #f0eafe;
  --teal: #0f766e; --teal-soft: #dff4f1;
  --shadow: 0 1px 2px rgb(15 23 42 / 0.05);
  --lift: 0 8px 24px -12px rgb(15 23 42 / 0.18);
  --radius: 14px;
  /* Nothing is told apart by a line drawn round it. The page is one fill (--ground), the columns beside it another
     (--frame), a group of things a third (--group). A box to write in or a quiet button sits on --well, which is
     --well-out on the page and --well-in inside a group. --dent darkens whatever is behind it a little. */
  --ground: var(--surface); --frame: var(--paper); --group: #f4f5f8;
  --well-out: var(--raised); --well-in: var(--surface); --well: var(--well-out);
  --dent: rgb(15 23 42 / 0.055); --rule: rgb(15 23 42 / 0.07);
  --mono: ui-monospace, 'SF Mono', Menlo, monospace;
  color-scheme: light;
}
[data-theme='dark'] {
  --paper: #0b0f17; --surface: #121722; --raised: #1a2030; --over: #232b3d;
  --ink: #e6edf7; --ink-2: #a3afc4; --ink-3: #7f8ba3;
  --line: rgb(230 237 247 / 0.09); --line-2: rgb(230 237 247 / 0.16);
  --accent: #60a5fa; --accent-soft: rgb(96 165 250 / 0.14); --glow: rgb(96 165 250 / 0.2);
  --ok: #4ade80; --ok-soft: rgb(74 222 128 / 0.11); --ok-line: rgb(74 222 128 / 0.25);
  --wait: #fbbf24; --wait-soft: rgb(251 191 36 / 0.1); --wait-line: rgb(251 191 36 / 0.25);
  --stop: #f87171; --stop-soft: rgb(248 113 113 / 0.12);
  --main: #e6edf7; --main-ink: #0b0f17; --main-over: #fff;
  --go: #3b82f6; --go-over: #2563eb;
  --amber: #fbbf24; --amber-soft: rgb(251 191 36 / 0.1);
  --blue: #60a5fa; --blue-soft: rgb(96 165 250 / 0.12);
  --green: #4ade80; --green-soft: rgb(74 222 128 / 0.11);
  --pink: #f472b6; --pink-soft: rgb(244 114 182 / 0.12);
  --violet: #a78bfa; --violet-soft: rgb(167 139 250 / 0.13);
  --teal: #2dd4bf; --teal-soft: rgb(45 212 191 / 0.12);
  --shadow: 0 1px 2px rgb(0 0 0 / 0.4);
  --lift: 0 8px 24px -10px rgb(0 0 0 / 0.6);
  --group: #181e2b; --well-in: var(--over);
  --dent: rgb(230 237 247 / 0.07); --rule: rgb(230 237 247 / 0.08);
  color-scheme: dark;
}

* { box-sizing: border-box; scrollbar-width: thin; scrollbar-color: var(--line-2) transparent; }
html, body { height: 100%; }
body { margin: 0; background: var(--ground); color: var(--ink); font: 400 14.5px/1.5 Geist, ui-sans-serif, system-ui, sans-serif; -webkit-font-smoothing: antialiased; }
h1, h2, p, ul, ol, dl, dd, blockquote { margin: 0; padding: 0; }
ul, ol { list-style: none; }
h1 { font-size: 22px; line-height: 1.25; font-weight: 600; letter-spacing: -0.015em; }
h2 { font-size: 13.5px; font-weight: 600; }
b { font-weight: 600; }
small { font-size: 12.5px; color: var(--ink-3); }
a { color: inherit; text-decoration: none; }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; border: 0; background: none; text-align: left; }
button:disabled { cursor: default; opacity: 0.45; }
textarea { resize: vertical; }
img { display: block; }
[hidden] { display: none !important; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.page:focus { outline: none; }
.icon { flex: none; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
.logo { flex: none; object-fit: contain; }
[data-theme='dark'] .logo-github, [data-theme='dark'] .logo-x { filter: invert(1); }
.soft { color: var(--ink-3); font-size: 13.5px; }
.unseen { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); }
.stack { display: grid; gap: 12px; align-content: start; min-width: 0; }
.row { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.row > input { flex: 1 1 150px; min-width: 0; }
.row > select { width: auto; }
.wide { width: 100%; }
.stack > .main:not(.wide), .stack > .quiet:not(.wide) { justify-self: start; }

.main, .quiet { display: inline-flex; align-items: center; justify-content: center; gap: 7px; min-height: 36px; padding: 7px 14px; border-radius: 10px; font-size: 13.5px; font-weight: 500; white-space: nowrap; }
/* The main button: colour with small sunken dots and a light from above. Its blue is the same in both themes and deep
   enough for white words, 4.5 to 1 at its lightest; the dark theme's accent is too pale to carry them. */
.main { --top: var(--press-lit); --low: var(--press-deep); background: radial-gradient(rgb(0 0 0 / 0.2) 1px, transparent 1.5px) 0 0 / 6px 6px, linear-gradient(var(--top), var(--low)); color: #fff; box-shadow: inset 0 1px 0 rgb(255 255 255 / 0.32), 0 8px 16px -10px var(--press-deep); text-shadow: 0 1px 1px rgb(0 0 0 / 0.25); }
.main:hover:not(:disabled) { --top: var(--press); --low: var(--press-deeper); }
.quiet { background: var(--well); }
/* One rule for a quiet thing under the pointer, whatever fill it sits on. */
:is(.quiet, .try, .pill, .week-days button):hover:not(:disabled) { filter: brightness(0.96); }
[data-theme='dark'] :is(.quiet, .try, .pill, .week-days button):hover:not(:disabled) { filter: brightness(1.2); }
.plain, .linky { display: inline-flex; align-items: center; gap: 6px; padding: 5px 8px; border-radius: 8px; color: var(--ink-2); font-size: 13px; font-weight: 500; }
.plain:hover { background: var(--raised); color: var(--ink); }
.linky { padding: 2px 4px; color: var(--accent); }
.linky:hover { text-decoration: underline; text-underline-offset: 3px; }
.bare, .square { display: grid; place-items: center; width: 32px; height: 32px; border-radius: 9px; color: var(--ink-3); }
.bare:hover, .square:hover { background: var(--raised); color: var(--ink); }
.square { width: 36px; height: 36px; color: var(--ink-2); }

input:not([type='checkbox'], [type='radio']), select, textarea { width: 100%; min-height: 36px; padding: 7px 12px; border: 0; border-radius: 10px; background: var(--well); font-size: 14px; }
input:focus-visible, select:focus-visible, textarea:focus-visible { outline: 0; box-shadow: inset 0 0 0 1px var(--accent), 0 0 0 3px var(--glow); }
::placeholder { color: var(--ink-3); opacity: 0.85; }
.field { display: grid; gap: 6px; min-width: 0; }
.field > span { font-size: 13px; font-weight: 500; color: var(--ink-2); }
.check { display: flex; gap: 10px; align-items: center; cursor: pointer; }
.check input, .ticks input { accent-color: var(--accent); width: 16px; height: 16px; flex: none; }
.toggle { display: flex; justify-content: space-between; gap: 20px; align-items: center; cursor: pointer; }
.toggle > span { display: grid; gap: 2px; }
.toggle b { font-weight: 500; }
/* The switch says On or Off in its track, so its state does not rest on colour alone. On, it is the main button's
   blue, which carries the white word in both themes. */
.toggle input { appearance: none; flex: none; position: relative; width: 58px; height: 24px; margin: 0; border-radius: 99px; background: var(--over); transition: background 0.15s; cursor: pointer; }
.toggle input::after { content: ''; position: absolute; top: 3px; left: 3px; width: 18px; height: 18px; border-radius: 50%; background: #fff; box-shadow: 0 1px 2px rgb(15 23 42 / 0.3); transition: transform 0.15s; }
/* The second content, where it is understood, keeps the word from being read out: the switch already says its state. */
.toggle input::before { content: 'Off'; content: 'Off' / ''; position: absolute; top: 0; right: 9px; color: var(--ink-2); font-size: 11px; font-weight: 600; line-height: 24px; }
.toggle input:checked { background: var(--press); }
.toggle input:checked::before { content: 'On'; content: 'On' / ''; right: auto; left: 10px; color: #fff; }
.toggle input:checked::after { transform: translateX(34px); }

.chip { display: inline-flex; align-items: center; gap: 5px; flex: none; padding: 2px 9px; border-radius: 8px; background: var(--raised); font-size: 12.5px; font-weight: 500; line-height: 1.6; color: var(--ink-2); white-space: nowrap; }
.chip-green { background: var(--ok-soft); color: var(--ok); }
.chip-red { background: var(--stop-soft); color: var(--stop); white-space: normal; }
.chip-amber { background: var(--wait-soft); color: var(--wait); }
.chip-line { align-items: flex-start; padding: 5px 11px; white-space: normal; }
.chip-line .icon { margin-top: 3px; }
.seg { display: flex; flex: none; padding: 3px; border-radius: 11px; background: var(--dent); }
.seg button { display: inline-flex; gap: 6px; padding: 4px 11px; border-radius: 8px; font-size: 13px; color: var(--ink-2); white-space: nowrap; }
.seg [aria-pressed='true'] { background: var(--surface); color: var(--ink); font-weight: 600; box-shadow: 0 1px 2px rgb(15 23 42 / 0.14); }
[data-theme='dark'] .seg [aria-pressed='true'] { background: var(--over); box-shadow: none; }
.seg-count { color: var(--ink-3); font-weight: 400; }
.seg-effects [aria-pressed='true'] { color: var(--accent); }

.card { min-width: 0; padding: 18px; border-radius: var(--radius); background: var(--group); }
/* Inside a group the fields and quiet buttons take the fill that stands off the group's own. */
.card, .held, .person, .receipt-side, .how li { --well: var(--well-in); }
.fold > summary { display: flex; align-items: center; gap: 9px; cursor: pointer; list-style: none; }
.fold > summary::-webkit-details-marker { display: none; }
.fold > summary::after { content: ''; width: 7px; height: 7px; margin: -3px 3px 0 auto; border: solid var(--ink-3); border-width: 0 1.6px 1.6px 0; transform: rotate(45deg); }
.fold[open] > summary { margin-bottom: 14px; }
.fold[open] > summary::after { margin-top: 4px; transform: rotate(225deg); }
.list > li { display: flex; align-items: center; gap: 13px; padding: 11px 0; }
.list > li + li { border-top: 1px solid var(--rule); }
.list > li > div:not(.seg, .row-end) { flex: 1; min-width: 0; overflow-wrap: anywhere; }
.list > li small { display: block; }
.list .none { justify-content: center; padding: 26px; color: var(--ink-3); }
.sub { display: flex; align-items: center; gap: 8px; margin-bottom: 10px; color: var(--ink-2); }
/* An app is shown by its own logo and nothing round it. */
.app-face, .tile { display: grid; place-items: center; flex: none; width: 28px; height: 28px; color: var(--ink-3); }
.app-face > .logo { width: 22px; height: 22px; }
.app-face > .icon { width: 19px; height: 19px; }
.face { display: grid; place-items: center; flex: none; width: 34px; height: 34px; border-radius: 50%; background: linear-gradient(150deg, #cdf08f, #8ec5ff); color: #0f172a; font-weight: 600; }
.face-small { width: 30px; height: 30px; font-size: 13px; }
.recovery { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 8px; }
.recovery li { padding: 8px 0; border-radius: 9px; background: var(--raised); color: var(--ink); font: 600 14.5px/1.5 var(--mono); letter-spacing: 0.08em; text-align: center; }
.pair { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.key-done { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px; padding-top: 4px; }
.good { display: flex; align-items: center; gap: 9px; padding: 10px 14px; border-radius: 12px; background: var(--ok-soft); color: var(--ok); }
.bad { color: var(--stop); }
.status { display: flex; align-items: center; gap: 7px; color: var(--ink-3); font-size: 13px; }
.status-bad { color: var(--stop); }
code { font: 12.5px var(--mono); color: var(--ink-3); }
.row > code { padding: 5px 10px; border-radius: 8px; background: var(--raised); color: var(--ink); }
.blank { display: grid; justify-items: center; gap: 6px; padding: 54px 24px; text-align: center; color: var(--ink-3); }
.blank b { color: var(--ink); }
.blank .row { margin-top: 10px; }
.blank-mark { display: grid; place-items: center; width: 46px; height: 46px; margin-bottom: 6px; border-radius: 14px; background: var(--raised); color: var(--ink-2); }
/* What was just done (ui.js toast). The newest is the card in front; the ones still to come show as edges tucked
   behind it, one edge for one more and two for any more than that.
   max-content: a box set at the middle of the window would otherwise be held to half the window's width. */
.toast { position: fixed; left: 50%; bottom: 26px; translate: -50% 0; display: grid; width: max-content; max-width: min(460px, calc(100vw - 32px)); z-index: 9; }
.toast-two { padding-top: 6px; }
.toast-many { padding-top: 12px; }
.toast-two::after, .toast-many::before, .toast-many::after { content: ''; position: absolute; top: 0; left: 50%; height: 30px; border-radius: 14px; background: var(--surface); box-shadow: 0 2px 10px -2px rgb(15 23 42 / 0.28); translate: -50% 0; }
.toast-two::after { width: 92%; opacity: 0.8; }
.toast-many::before { width: 84%; opacity: 0.55; }
.toast-many::after { top: 6px; width: 92%; opacity: 0.8; }
.toast-card { position: relative; z-index: 1; display: flex; align-items: center; gap: 12px; min-width: 0; padding: 10px 10px 10px 12px; border-radius: 14px; background: var(--surface); color: var(--ink); font-size: 13.5px; line-height: 1.35; box-shadow: 0 2px 6px rgb(15 23 42 / 0.08), 0 16px 34px -14px rgb(15 23 42 / 0.5); animation: toast-in 0.22s ease-out; }
.toast-tile { display: grid; place-items: center; flex: none; width: 22px; height: 22px; border-radius: 50%; background: var(--ok); color: var(--surface); }
.toast-tile .icon { stroke-width: 2.4; }
.toast-bad .toast-tile { background: var(--stop); }
.toast-words { display: grid; flex: 1; min-width: 0; overflow-wrap: anywhere; }
.toast-words b { font-weight: 600; }
.toast-words small { color: var(--ink-3); font-size: 12.5px; }
.toast-more { flex: none; padding: 2px 8px; border-radius: 99px; background: var(--raised); color: var(--ink-2); font: 500 12px var(--mono); white-space: nowrap; }
.toast-close { display: grid; place-items: center; flex: none; width: 26px; height: 26px; border-radius: 8px; color: var(--ink-3); }
.toast-close:hover { background: var(--raised); color: var(--ink); }
[data-theme='dark'] .toast-card, [data-theme='dark'] .toast-two::after, [data-theme='dark'] .toast-many::before, [data-theme='dark'] .toast-many::after { background: var(--raised); box-shadow: 0 0 0 1px var(--line-2); }
[data-theme='dark'] .toast-card { box-shadow: 0 0 0 1px var(--line-2), 0 14px 30px -12px rgb(0 0 0 / 0.8); }
[data-theme='dark'] :is(.toast-more, .toast-close:hover) { background: var(--over); }
@keyframes toast-in { from { opacity: 0; translate: 0 8px; } }

/* Brand */
.brand { display: flex; align-items: center; gap: 9px; }
[data-theme='dark'] [src='/mark.svg'] { border-radius: 25%; box-shadow: 0 0 0 1px var(--line-2); }
.word { font: 900 18px/1 Fraunces, Georgia, serif; letter-spacing: -0.02em; }

/* Arriving: a single card to sign in; three steps, each in one window, to set up. */
/* Here the page is the grey one and what you fill in is a white sheet on it. */
.gate { min-height: 100vh; min-height: 100dvh; background: var(--paper); --group: var(--surface); --well-out: var(--raised); --well-in: var(--raised); }
.gate-top { display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 24px; padding: 18px 32px; }
.gate-steps { display: flex; gap: 10px; }
.gate-steps li { width: 136px; padding-top: 9px; border-top: 3px solid var(--over); color: var(--ink-3); font-size: 13px; font-weight: 500; text-align: center; }
.gate-steps .done { border-color: var(--blue-soft); color: var(--ink-2); }
.gate-steps [aria-current='step'] { border-color: var(--go); color: var(--ink); font-weight: 600; }
/* Steps sit a little above the middle of the window, so a short step does not leave the lower half bare. */
.gate-main { display: grid; gap: 22px; align-content: center; width: min(980px, 100%); min-height: calc(100dvh - 76px); margin: 0 auto; padding: 16px 32px 88px; }
.gate-main.gate-one { min-height: 100vh; min-height: 100dvh; align-content: center; justify-items: center; gap: 18px; padding-block: 32px; }
.gate-head { display: grid; gap: 6px; }
.gate-head h1 { font-size: 28px; letter-spacing: -0.025em; }
.gate-head .soft { color: var(--ink-2); font-size: 14.5px; }
.gate .card { padding: 24px; }
.gate .main, .gate .quiet { min-height: 44px; font-size: 14.5px; }
.gate input:not([type='checkbox']) { min-height: 44px; }
.gate-card { display: grid; gap: 22px; width: min(420px, 100%); border-radius: 16px; box-shadow: 0 12px 32px -16px rgb(15 23 42 / 0.16); }
.gate .gate-card { padding: 32px; }
.gate-card .gate-head h1 { font-size: 24px; }
.peek { display: flex; align-items: center; gap: 12px; padding: 12px 14px; border-radius: 12px; background: var(--well); }
.peek > div { display: grid; flex: 1; min-width: 0; }
.peek small { color: var(--ink-3); }
.gate-links { display: flex; gap: 24px; color: var(--ink-3); font-size: 13px; }
.gate-links a:hover { color: var(--ink); text-decoration: underline; text-underline-offset: 3px; }
/* The drawing is black line work, so its circle stays light in the dark theme too. */
.face-art { display: grid; flex: none; width: 44px; height: 44px; border-radius: 50%; background: #e2f3e5; overflow: hidden; }
.face-art img { width: 100%; height: 100%; }
.face-big { width: 112px; height: 112px; }
.gate-split { display: grid; grid-template-columns: minmax(0, 1fr) 280px; gap: 20px; align-items: start; }
.gate-aside { display: grid; gap: 14px; }
.gate-aside ul { display: grid; gap: 12px; }
.gate-aside li { display: flex; gap: 10px; color: var(--ink-2); font-size: 14px; }
.gate-aside .icon { margin-top: 3px; color: var(--go); }
.gate .gate-you { display: grid; grid-template-columns: auto minmax(0, 1fr); align-items: center; gap: 18px 26px; padding: 28px; }
.gate-you > .soft { grid-column: 1 / -1; }
.gate-key { gap: 16px; }
.gate-aside-end { gap: 14px; }
.gate-aside-end > .soft { text-align: center; }
.gate .ticks { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 9px 16px; }
.read-row { display: grid; gap: 10px; }
.gate .read-row { padding: 12px 14px; border-radius: 12px; background: var(--paper); }
.gate .read-row .found { padding: 2px 0 0; background: none; box-shadow: none; }
.gate form .main:not(.go) { background: var(--well); color: var(--ink); box-shadow: none; text-shadow: none; }
.gate form .main:not(.go):hover:not(:disabled) { background: var(--over); }
.gate .found .main:not(.go) { min-height: 36px; background: var(--blue-soft); color: var(--go); box-shadow: none; text-shadow: none; }

.field-row { display: grid; grid-template-columns: 168px 1fr; align-items: center; gap: 12px; }
.field-row > span { display: flex; align-items: center; gap: 10px; font-weight: 500; }
.side-cards .field-row { grid-template-columns: 1fr; gap: 6px; }
.found:empty { display: none; }
.found { display: grid; gap: 12px; padding: 13px 15px; border-radius: 12px; background: var(--well); }
.found > .chip, .found .row .chip { justify-self: start; }
.ticks { display: grid; gap: 9px; max-height: 270px; overflow-y: auto; font-size: 14px; }
.ticks .check { align-items: flex-start; }
.ticks input { margin: 3px 0 0; }
.working { display: flex; align-items: center; gap: 10px; color: var(--ink-2); font-size: 14px; font-variant-numeric: tabular-nums; }

/* The shell */
/* `position`: the side cards, when they come over a page, are placed in the shell and not in the window, so they
   start under its top bar also where a note sits above the shell (the demo). */
.app { position: relative; display: grid; grid-template-columns: 232px minmax(0, 1fr) 300px; height: 100vh; height: 100dvh; overflow: hidden; }
.demo { display: flex; flex-direction: column; overflow: hidden; }
.demo .app { flex: 1; height: auto; min-height: 0; }
.demo-note { flex: none; margin: 0; padding: 7px 16px; background: #d9f99d; color: #1a2e05; font-size: 13px; text-align: center; }
.demo-note .linky { color: inherit; text-decoration: underline; }
.app.no-rail { grid-template-columns: 232px minmax(0, 1fr); }
.app.no-rail .rail { display: none; }
.app.rail-open .rail { display: flex; }
.app.no-rail.rail-open .rail { position: absolute; top: 62px; right: 0; bottom: 0; width: 300px; box-shadow: var(--lift); z-index: 5; }
.nav-short, .only-small { display: none !important; }
.side { display: flex; flex-direction: column; gap: 14px; min-height: 0; padding: 18px 12px 12px; background: var(--frame); }
.side .brand { padding: 0 8px 4px; }
#nav { flex: 1; display: flex; flex-direction: column; gap: 2px; overflow-y: auto; margin: 0 -12px; padding: 0 12px; }
.nav-group { padding: 10px 10px 5px; color: var(--ink-3); font-size: 12.5px; font-weight: 500; }
.nav-item { position: relative; display: flex; align-items: center; gap: 12px; width: 100%; min-height: 36px; padding: 6px 10px; border-radius: 10px; color: var(--ink-2); font-size: 14px; }
.nav-item:hover { background: var(--raised); color: var(--ink); }
.nav-item[aria-current] { background: color-mix(in srgb, var(--tone) 13%, var(--surface)); color: var(--ink); font-weight: 600; }
/* Each page's mark is a tile in that page's own colour, the colour its header and cards take (see [data-page] below). */
.nav-mark { display: grid; place-items: center; flex: none; width: 24px; height: 24px; border-radius: 7px; background: linear-gradient(155deg, color-mix(in srgb, var(--tone) 72%, #fff), var(--tone)); color: #fff; box-shadow: inset 0 0 0 1px rgb(15 23 42 / 0.06), 0 1px 2px color-mix(in srgb, var(--tone) 35%, transparent); }
.nav-mark .icon { stroke-width: 2; }
[data-theme='dark'] .nav-mark { background: linear-gradient(155deg, var(--tone), color-mix(in srgb, var(--tone) 78%, #000)); color: #0b0f17; }
.count { min-width: 20px; margin-left: auto; padding: 0 6px; border-radius: 99px; background: var(--accent); color: #fff; font-size: 12px; line-height: 20px; text-align: center; }
[data-theme='dark'] .count { color: #0b0f17; }
.side-foot { display: flex; align-items: center; gap: 10px; padding: 12px 4px 2px 6px; }
.who { flex: 1; min-width: 0; display: grid; line-height: 1.35; }
.who small { display: flex; align-items: center; gap: 5px; color: var(--ok); }
.body { display: flex; flex-direction: column; min-width: 0; min-height: 0; }
.top { display: flex; align-items: center; gap: 12px; flex: none; min-height: 74px; padding: 16px 28px 10px; }
.top h1 { font-size: 17px; flex: none; }
.top p { flex: 1; min-width: 0; overflow: hidden; color: var(--ink-3); text-overflow: ellipsis; white-space: nowrap; }
.pulse { display: inline-flex; align-items: center; gap: 8px; flex: none; height: 36px; padding: 0 12px; border-radius: 10px; background: var(--well); color: var(--ink-2); font-size: 13px; font-weight: 500; }
.pulse:hover { background: var(--over); }
/* > i: the dot grid it shows at work is made of i as well, and those are not this dot. */
.pulse > i { width: 8px; height: 8px; border-radius: 50%; background: #d19a2a; }
.pulse-on > i { background: #22a55a; animation: pulse 2.4s ease-out infinite; }
/* While something is under way the pill says that step, with the grid in place of its dot (owner.js watchWork). */
.pulse-work { color: var(--ink); }
.pulse-work > span { max-width: 26ch; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
@keyframes pulse { 0% { box-shadow: 0 0 0 0 rgb(34 165 90 / 0.45); } 70%, 100% { box-shadow: 0 0 0 7px rgb(34 165 90 / 0); } }
.page { flex: 1; min-height: 0; overflow-y: auto; padding: 24px; background: var(--surface); }
.column { display: grid; gap: 24px; width: 100%; max-width: 860px; margin: 0 auto; }
.wide-column { display: grid; gap: 20px; width: 100%; max-width: 1180px; margin: 0 auto; }
.two { display: grid; grid-template-columns: minmax(0, 1fr) 330px; gap: 20px; align-items: start; width: 100%; max-width: 1180px; margin: 0 auto; }
.two-even { grid-template-columns: minmax(0, 1fr) minmax(0, 420px); }

/* Right of the page */
.rail { display: flex; flex-direction: column; gap: 22px; min-height: 0; overflow-y: auto; padding: 20px; background: var(--frame); }
.rail section { min-width: 0; flex: none; }
.rail-head { display: flex; justify-content: space-between; align-items: center; margin-bottom: 9px; }
.rail-head h2 { color: var(--ink-2); }
/* The lists beside the page are plain rows; the ones that open something lie 10px out, so their words line up with
   the heading while the fill under the pointer has room round them. */
.rail-list { display: grid; gap: 4px; }
.rail-list > .rail-receipt, .rail-ask { display: flex; justify-content: space-between; align-items: flex-start; gap: 10px; width: 100%; padding: 7px 0; font-size: 13.5px; line-height: 1.4; }
.rail-receipt b { font-weight: 500; overflow-wrap: anywhere; }
.rail-receipt small, .rail-ask small { display: block; margin-top: 2px; }
.rail-ask { position: relative; display: block; width: calc(100% + 20px); margin: 0 -10px; padding: 7px 10px 7px 28px; border-radius: 10px; }
/* What waits is marked by a dot, as unread things are. */
.rail-ask::before { content: ''; position: absolute; left: 11px; top: 14px; width: 7px; height: 7px; border-radius: 50%; background: var(--amber); }
.rail .note-card { padding: 0; background: none; }
.rail-receipt small::first-letter { text-transform: uppercase; }
.rail-ask:hover { background: var(--dent); }
.tiles { display: flex; flex-wrap: wrap; gap: 12px 16px; }
.tile > .logo { width: 24px; height: 24px; }
.tile-off .logo { filter: grayscale(1); opacity: 0.35; }
[data-theme='dark'] .tile-off .logo-github, [data-theme='dark'] .tile-off .logo-x { filter: invert(1) grayscale(1); }
.note-card { display: grid; gap: 8px; justify-items: start; padding: 14px 15px; border-radius: 13px; background: var(--raised); font-size: 13.5px; }
.note-card > b { display: flex; align-items: center; gap: 8px; font-size: 14px; }
.note-card p { color: var(--ink-2); }
.note-card .stack, .note-card details { width: 100%; }
.note-card summary { cursor: pointer; color: var(--ink-2); font-size: 13px; }
.note-card details form { margin-top: 8px; }
.note-green { background: var(--ok-soft); }
.note-green > b .icon { color: var(--ok); }
.note-blue { background: var(--accent-soft); }
.note-blue > b .icon { color: var(--accent); }
.note-amber { background: var(--wait-soft); }
.note-amber > b .icon { color: var(--wait); }

/* Today */
.page.page-today { display: flex; flex-direction: column; padding: 0; overflow: hidden; }
.talk { flex: 1; min-height: 0; overflow-y: auto; padding: 22px 28px 28px; }
/* What scrolls on goes under a fade, not a hard edge, so the talk reads as going on below and never as hidden by the box. */
.page-today .talk { mask-image: linear-gradient(to bottom, #000 calc(100% - 28px), transparent); }
.talk-in { display: grid; gap: 22px; width: 100%; max-width: 780px; margin: 0 auto; }
.turn { display: grid; grid-template-columns: 34px minmax(0, 1fr); gap: 13px; }
.turn-face { border-radius: 10px; }
.turn-body { display: grid; gap: 11px; justify-items: start; min-width: 0; }
.turn-body > .held, .turn-body > .card, .tries { width: 100%; }
.turn-who { margin-top: 5px; font-size: 13px; font-weight: 600; }
.said { white-space: pre-wrap; overflow-wrap: anywhere; }
.bubble { justify-self: end; max-width: 78%; padding: 10px 15px; border-radius: 15px 15px 4px 15px; background: var(--raised); white-space: pre-wrap; overflow-wrap: anywhere; }
/* At work: a small grid of dots (ui.js grid). Three a side, a lit dot runs round the rim, each dot a beat after the
   one before it; five a side, for a whole page that waits, light ripples out from the middle ring by ring. */
.grid { --dot: 3px; display: inline-grid; flex: none; grid-template-columns: repeat(3, var(--dot)); gap: calc(var(--dot) * 0.7); color: var(--accent); }
.grid i { width: var(--dot); height: var(--dot); border-radius: 50%; background: currentColor; opacity: 0.16; }
.grid-3 i { animation: grid-run 1.2s linear infinite; }
.grid-3 i:nth-child(1) { animation-delay: -1.2s; }
.grid-3 i:nth-child(2) { animation-delay: -1.05s; }
.grid-3 i:nth-child(3) { animation-delay: -0.9s; }
.grid-3 i:nth-child(6) { animation-delay: -0.75s; }
.grid-3 i:nth-child(9) { animation-delay: -0.6s; }
.grid-3 i:nth-child(8) { animation-delay: -0.45s; }
.grid-3 i:nth-child(7) { animation-delay: -0.3s; }
.grid-3 i:nth-child(4) { animation-delay: -0.15s; }
.grid-3 i:nth-child(5) { animation: grid-rest 1.2s ease-in-out infinite; }
.grid-5 { --dot: 5px; grid-template-columns: repeat(5, var(--dot)); }
.grid-5 i { animation: grid-ripple 1.5s ease-in-out infinite; }
.grid-5 .ring-1 { animation-delay: 0.12s; }
.grid-5 .ring-2 { animation-delay: 0.24s; }
.grid-5 .ring-3 { animation-delay: 0.36s; }
@keyframes grid-run { 0% { opacity: 1; scale: 1.2; } 45%, 100% { opacity: 0.16; scale: 1; } }
@keyframes grid-rest { 50% { opacity: 0.6; } }
@keyframes grid-ripple { 0%, 60%, 100% { opacity: 0.15; scale: 1; } 25% { opacity: 1; scale: 1.25; } }
/* Where an answer will be: the grid and a word for what is being done. */
.dots { display: flex; align-items: center; gap: 10px; padding: 6px 0; color: var(--ink-3); font-size: 14px; }
.dots .grid { --dot: 4px; }
/* A button whose work is running keeps its colour and shows the grid where its mark was (ui.js doing). */
button.busy:disabled { opacity: 1; cursor: progress; }
.busy > .icon { display: none; }
.busy > .grid { color: inherit; }
.blank-wait { gap: 16px; }
.tries { display: grid; grid-template-columns: 1fr 1fr; gap: 9px; }
.try { --tone: var(--blue); display: grid; grid-template-columns: 22px 1fr; column-gap: 12px; align-items: center; padding: 10px 14px; border-radius: 13px; background: var(--well); }
.try-mark { grid-row: span 2; display: grid; place-items: center; color: var(--tone); }
.try b { align-self: end; font-size: 14px; line-height: 1.3; }
.try small { align-self: start; color: var(--ink-2); }
.try-amber { --tone: var(--amber); }
.try-green { --tone: var(--green); }
.try-pink { --tone: var(--pink); }
.steps, .known { padding: 0; overflow: hidden; }
.steps header, .known header { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 14px 16px 12px; }
.steps header small { flex: none; }
/* How far a job has come: a tick for each thing in it (ui.js tally). The green is the one of the marks below it. */
.tally { display: grid; grid-auto-flow: column; grid-auto-columns: 1fr; gap: 3px; height: 14px; }
.tally i { border-radius: 2px; background: var(--line-2); }
.tally .tally-done { background: #22a55a; }
.steps .tally { margin: 0 16px 8px; }
.steps li { display: flex; align-items: center; gap: 12px; min-height: 54px; padding: 8px 16px; }
.steps li > div { flex: 1; min-width: 0; display: grid; line-height: 1.4; }
.steps li b { font-weight: 500; }
.step-mark { display: grid; place-items: center; flex: none; width: 22px; height: 22px; border-radius: 50%; box-shadow: inset 0 0 0 1.5px var(--line-2); }
.step-done .step-mark { background: #22a55a; box-shadow: none; color: #fff; }
.step-done b { color: var(--ink-3); }
.composer-box { flex: none; padding: 0 28px 22px; background: var(--surface); }
.composer { display: grid; gap: 4px; width: 100%; max-width: 780px; margin: 0 auto; padding: 8px; border-radius: 17px; background: var(--well); }
.composer:focus-within { box-shadow: 0 0 0 1.5px var(--accent), 0 0 0 4px var(--glow); }
.composer textarea { min-height: 40px; padding: 8px 10px; resize: none; box-shadow: none; background: none; font-size: 15px; }
.composer textarea:focus-visible { box-shadow: none; }
.composer-foot { display: flex; align-items: center; gap: 12px; }
.reach { display: inline-flex; align-items: center; gap: 6px; height: 34px; padding: 0 8px; border-radius: 10px; color: var(--ink-2); font-size: 13px; }
.reach:hover { background: var(--dent); }
.composer-note { flex: 1; font-size: 12.5px; }
.send { display: grid; place-items: center; width: 36px; height: 36px; border-radius: 11px; background: var(--main); color: var(--main-ink); }
.send:hover { background: var(--main-over); }

/* What it knows */
.map-box { overflow-x: auto; scrollbar-width: thin; }
.known .map-box { padding: 4px 8px 12px; }
/* Beside the talk the map is a window on its middle, as tall as the window leaves room for under the opening, so the card
   ends above the box you type in. 716px is everything else on the page at its usual size; the whole map is on Memory. */
.known .map-box { display: flex; flex-direction: column; justify-content: center; max-height: clamp(180px, calc(100dvh - 716px), 560px); overflow-y: hidden; mask-image: linear-gradient(to bottom, transparent, #000 28px, #000 calc(100% - 28px), transparent); }
.known .map { flex: none; }
.map { display: block; width: 100%; min-width: 760px; height: auto; font-family: Geist, sans-serif; }
.map-small { min-width: 600px; }
.map-line { fill: none; stroke: var(--tone); stroke-width: 1.4; opacity: 0.32; }
.map-stem { stroke-width: 2; opacity: 0.45; }
.map-same { fill: none; stroke: var(--ink-3); stroke-width: 1; stroke-dasharray: 3 4; opacity: 0.4; }
.map-pill rect { fill: var(--tone-soft); stroke: var(--tone); stroke-opacity: 0.35; }
.map-pill text { fill: var(--tone); font-size: 12.5px; font-weight: 600; }
.map-other rect { fill: var(--surface); stroke-opacity: 1; stroke-dasharray: 3 3; }
.map-leaf { cursor: pointer; }
.map-leaf circle { fill: var(--tone); }
.map-leaf text { fill: var(--ink); font-size: 12.5px; }
.map-leaf:hover text { text-decoration: underline; text-underline-offset: 3px; }
.map-more { cursor: default; }
.map-more text { fill: var(--ink-3); }
.map-you { fill: #b4ec5c; stroke: #0f172a; stroke-width: 2.5; }
[data-theme='dark'] .map-you { stroke: #e6edf7; }
.map-you-name { fill: #0f172a; font-size: 15px; font-weight: 600; }
.hue-0 { --tone: var(--blue); --tone-soft: var(--blue-soft); }
.hue-1 { --tone: var(--green); --tone-soft: var(--green-soft); }
.hue-2 { --tone: var(--amber); --tone-soft: var(--amber-soft); }
.hue-3 { --tone: var(--pink); --tone-soft: var(--pink-soft); }
.hue-4 { --tone: var(--violet); --tone-soft: var(--violet-soft); }
.hue-5 { --tone: var(--teal); --tone-soft: var(--teal-soft); }
.map-card { padding: 0; }
/* The map is its own ground of dots, so the card round it has no fill. */
.map-card, .known { background: none; }
.map-card header { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 10px 16px; padding: 0 0 12px; }
.map-card .map-box { padding: 8px; }
.map-card .map-box, .known .map-box { border-radius: var(--radius); }
/* The map sits on a faint dotted ground in the page's colour, like paper for drawing on. */
.map-card .map-box, .known .map-box { background: radial-gradient(color-mix(in srgb, var(--tone) 24%, transparent) 1px, transparent 1.3px) 0 0 / 20px 20px, color-mix(in srgb, var(--tone) 3%, var(--surface)); }
.sources { display: flex; flex-wrap: wrap; gap: 6px 8px; font-size: 13.5px; color: var(--ink-2); }
.sources li { display: flex; align-items: center; gap: 7px; padding: 3px 11px 3px 8px; border-radius: 99px; background: color-mix(in srgb, var(--from) 10%, var(--surface)); }
/* A fact's colour says how it was learned; the logo says from where. */
.from-profile { --from: var(--blue); }
.from-owner { --from: var(--violet); }
.from-approval { --from: var(--green); }
.from-decline { --from: var(--stop); }
.from-outsider { --from: var(--amber); }
.facts .app-face { width: 30px; height: 30px; border-radius: 9px; background: color-mix(in srgb, var(--from, var(--ink-3)) 11%, var(--surface)); color: var(--from, var(--ink-2)); }
.sources b { color: var(--ink); }
.facts { min-width: 0; }
.side-cards { position: sticky; top: 0; }
.tools { display: flex; flex-wrap: wrap; gap: 10px; margin-bottom: 12px; }
.search { position: relative; flex: 1 1 200px; min-width: 0; }
.search .icon { position: absolute; top: 11px; left: 12px; color: var(--ink-3); }
.search input { padding-left: 36px !important; }
.row-end { display: flex; align-items: center; gap: 4px; flex: none; }
.pill { display: inline-flex; align-items: center; gap: 6px; height: 28px; padding: 0 10px; border-radius: 8px; background: var(--dent); color: var(--ink-2); font-size: 12.5px; font-weight: 500; white-space: nowrap; }
.pill-open { background: var(--ok-soft); color: var(--ok); }
.triple { display: grid; gap: 8px; }

/* Needs you */
.how { display: grid; gap: 20px; padding: 0; background: none; }
.how ol { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; }
.how li { display: grid; gap: 3px; align-content: start; padding: 18px; border-radius: 13px; background: var(--group); }
.how li p { color: var(--ink-2); font-size: 13.5px; }
.how-mark { --mark: var(--amber); display: grid; place-items: center; width: 42px; height: 42px; margin-bottom: 8px; border-radius: 12px; background: color-mix(in srgb, var(--mark) 15%, var(--surface)); color: var(--mark); }
li:nth-child(2) > .how-mark { --mark: var(--blue); }
li:nth-child(3) > .how-mark { --mark: var(--green); }
.page.page-needs:has(.split), .page.page-receipts { padding: 0; overflow: hidden; }
.split { display: grid; grid-template-columns: 320px minmax(0, 1fr); height: 100%; }
.split-list { --under: var(--ground); display: flex; flex-direction: column; gap: 4px; overflow-y: auto; padding: 20px 14px; background: var(--under); }
.split-list .sub { padding: 0 8px; }
.split-main { display: grid; gap: 20px; align-content: start; overflow-y: auto; padding: 24px; }
.split-main > * { width: 100%; max-width: 880px; margin: 0 auto; }
.asks { display: grid; gap: 2px; }
.asks button { display: flex; align-items: center; gap: 12px; width: 100%; padding: 9px 10px; border-radius: 11px; }
.asks button > span:last-child { display: grid; min-width: 0; line-height: 1.4; }
.asks b { overflow: hidden; font-size: 14px; font-weight: 500; text-overflow: ellipsis; white-space: nowrap; }
.asks button:hover { background: var(--dent); }
.asks [aria-current='true'], .asks [aria-current='true']:hover { background: var(--well-out); }
/* A draft that waits. In the talk it is a group among the words; on its own page it is the page, with no fill. */
.held { display: grid; gap: 15px; padding: 20px; border-radius: var(--radius); background: var(--group); }
.split-main > .held { --well: var(--well-out); padding: 0; background: none; }
.held header { display: flex; align-items: center; gap: 12px; }
.held header > div { flex: 1; min-width: 0; display: grid; line-height: 1.4; }
/* What the other person wrote, set off the way a quote is: by a bar down its side. */
.held blockquote { padding: 1px 0 1px 14px; border-left: 2px solid var(--line-2); color: var(--ink-2); font-size: 14px; white-space: pre-wrap; overflow-wrap: anywhere; }
.held footer { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.held-why { display: flex; align-items: center; gap: 7px; color: var(--ink-3); font-size: 13px; }
/* A meeting two replicas agreed. Each owner's week is drawn as the times that were offered: lit where that owner is
   free, and the one both have marked in both rows. */
.meet { container-type: inline-size; }
.split-main { min-width: 0; }
.meet-week { display: grid; gap: 18px; padding-block: 4px; }
.meet-row { display: grid; grid-template-columns: minmax(130px, 200px) minmax(0, 1fr); align-items: center; gap: 16px; }
.meet-who { display: flex; align-items: center; gap: 11px; min-width: 0; }
.meet-who img { flex: none; border-radius: 50%; background: var(--raised); }
.meet-who > div { display: grid; min-width: 0; line-height: 1.35; }
.meet-who small { color: var(--ink-3); }
.meet-days { display: grid; grid-auto-flow: column; grid-auto-columns: minmax(0, 1fr); gap: 14px; }
.meet-day { display: grid; gap: 6px; min-width: 0; }
.meet-day small { overflow: hidden; color: var(--ink-3); font-size: 12px; white-space: nowrap; text-overflow: ellipsis; }
.meet-slots { display: flex; gap: 3px; }
.slot { flex: 1; height: 16px; border-radius: 4px; background: var(--dent); }
.slot-on { background: color-mix(in srgb, var(--accent) 34%, var(--surface)); }
/* The green of the marks for done (.tally-done): deep enough to stand out of a row of blue. */
.slot-both { background: #22a55a; }
.meet-when { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 18px; }
.meet-time { display: inline-flex; align-items: center; gap: 9px; padding: 7px 14px; border-radius: 10px; background: var(--ok-soft); font-weight: 600; font-variant-numeric: tabular-nums; }
.meet-time .icon, .meet-yes .icon { color: var(--ok); }
.meet-yes { display: inline-flex; align-items: center; gap: 7px; color: var(--ink-2); font-size: 14px; }
/* In a narrow card a week goes under its owner's name, so each day keeps room for its times. */
@container (max-width: 520px) {
  .meet-row { grid-template-columns: minmax(0, 1fr); gap: 12px; }
  .meet-days { gap: 8px; }
}
/* Under the list, how a draft gets there: three steps on one line that runs behind their marks. */
.how-steps { margin-top: auto; padding: 24px 8px 4px; }
.how-steps ol { display: grid; gap: 16px; }
.how-steps li { position: relative; display: grid; grid-template-columns: 34px minmax(0, 1fr); gap: 12px; }
.how-steps li:not(:last-child)::before { content: ''; position: absolute; left: 16px; top: 40px; bottom: -12px; width: 2px; border-radius: 2px; background: var(--line-2); }
.how-steps li > div { display: grid; gap: 1px; }
.how-steps b { font-size: 13.5px; }
.how-steps p { color: var(--ink-2); font-size: 13px; line-height: 1.45; }
.how-steps .how-mark { width: 34px; height: 34px; margin: 0; border-radius: 10px; }
.needs-more { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 18px; align-items: start; }
.needs-more .list > li { padding-block: 10px; }
.idea { display: flex; gap: 14px; padding: 18px; border-radius: var(--radius); background: var(--ok-soft); }
.idea > div { display: grid; gap: 6px; }
.idea .row { margin-top: 6px; }

/* A line that leads a page: what it is for, and the one choice that goes with it. */
.lead { display: flex; align-items: center; gap: 14px; }
.lead > div:not(.seg) { flex: 1; min-width: 0; }
.lead p { color: var(--ink-2); font-size: 14px; }
.lead-mark { display: grid; place-items: center; flex: none; width: 28px; height: 28px; color: var(--ink-3); }

/* Rules: a settings page of plain rows. The only colour is an app's own logo, the choice that is on, and the mark
   on what always asks. */
.rules-note { display: flex; align-items: center; gap: 12px 36px; }
.rules-say { flex: 1; display: flex; align-items: center; gap: 13px; min-width: 0; }
.rules-say p { color: var(--ink-2); font-size: 14px; line-height: 1.5; }
.rules-say b { color: var(--ink); font-weight: 600; }
.rules-count { display: grid; align-content: center; gap: 1px; flex: none; }
.rules-count small { color: var(--ink-3); font-size: 12.5px; }
.rules-count b { font-size: 20px; font-weight: 650; letter-spacing: -0.01em; line-height: 1.3; font-variant-numeric: tabular-nums; }
.rules > li { min-height: 58px; }
.a-day { display: flex; align-items: center; gap: 8px; flex: none; color: var(--ink-3); font-size: 13px; }
.limit { color: var(--ink); width: 78px !important; min-height: 32px !important; padding: 4px 10px !important; font-size: 13px !important; }
.new-rule { display: grid; grid-template-columns: 1.6fr 1.2fr 1fr 0.8fr auto; gap: 10px; align-items: end; margin-top: 12px; }
/* Every ability in two columns, so the page fits one window. */
.rules-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 22px; align-items: start; }
.rules-col { display: grid; gap: 20px; align-content: start; min-width: 0; }
.rules-col .sub { margin-bottom: 8px; color: var(--ink); font-size: 14px; font-weight: 600; }
.rules-col .sub .icon { color: var(--ink-3); }
.list.rules { overflow: hidden; }
.rules-grid .new-rule { grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr) minmax(0, 0.9fr) minmax(0, 0.8fr); margin-top: 10px; }
.rules-grid .new-rule > .main { grid-column: 1 / -1; justify-self: start; }

/* Public page */
.pre-side { position: sticky; top: 0; display: grid; gap: 12px; justify-items: center; }
.pre { width: 100%; overflow: hidden; border-radius: 16px; background: linear-gradient(160deg, #e9f7d0, #e6effe 60%, #f3f0fe); box-shadow: var(--lift); }
[data-theme='dark'] .pre { background: linear-gradient(160deg, #1c2a12, #10203a 60%, #1b1730); }
.pre-bar { display: flex; align-items: center; gap: 6px; padding: 10px 14px; background: var(--raised); }
.pre-bar i { width: 10px; height: 10px; border-radius: 50%; background: var(--over); }
.pre-bar span { flex: 1; overflow: hidden; margin-right: 48px; color: var(--ink-3); font-size: 12.5px; text-align: center; text-overflow: ellipsis; }
.pre-in { display: grid; gap: 13px; margin: 18px; padding: 18px; border-radius: 15px; background: var(--surface); }
.pre-in header { display: flex; align-items: center; gap: 12px; }
.pre-in header small { display: block; }
.pre-on { color: var(--ok) !important; }
.pre-about { padding: 10px 13px; border-radius: 11px; background: var(--ok-soft); font-size: 14px; white-space: pre-wrap; overflow-wrap: anywhere; }
.pre-answer { color: var(--ink-2); font-size: 14px; }
.pre-side > .card { justify-self: stretch; }
/* The switch leads the page, green while it takes messages and amber while it does not. */
.door-switch { --mark: var(--amber); display: flex; align-items: center; gap: 15px; }
.door-open { --mark: var(--green); }
.door-switch > .toggle { flex: 1; min-width: 0; }
.door-switch .toggle b { font-size: 15px; font-weight: 600; }
.door-mark { display: grid; place-items: center; flex: none; width: 46px; height: 46px; border-radius: 14px; background: color-mix(in srgb, var(--mark) 15%, var(--surface)); color: var(--mark); }
.open-facts header { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.open-facts ul { display: grid; gap: 7px; }
.open-facts li { display: flex; align-items: flex-start; gap: 10px; padding: 9px 12px; border-radius: 11px; background: var(--ok-soft); font-size: 14px; }
.open-facts li .icon { margin-top: 3px; color: var(--ok); }
.open-facts .open-more { padding: 0 12px; background: none; color: var(--ink-3); font-size: 13px; }
.open-facts .row .soft { font-size: 13px; }
.nobody { display: flex; align-items: center; gap: 12px; padding: 11px 13px; border-radius: 12px; background: var(--violet-soft); color: var(--ink-2); font-size: 13.5px; }
.nobody .app-face { color: var(--violet); }

/* Connections */
.app-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; align-items: start; }
.app-card { display: grid; gap: 15px; }
.app-card header { display: flex; align-items: center; gap: 13px; }
.app-card header > div { flex: 1; min-width: 0; display: grid; line-height: 1.4; }
.app-card > .plain, .app-card form > .quiet { justify-self: start; }
.app-card header .tile { width: 30px; height: 30px; }
.app-card header .logo { width: 26px; height: 26px; }
.app-card header small { color: var(--ink-2); }
.app-grid > .stack { gap: 16px; }
/* When the owner takes meetings: two times and the days of the week. */
.hours { display: grid; gap: 10px; }
.hours > b { font-weight: 500; }
.hours-row { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; color: var(--ink-2); font-size: 13.5px; }
.hours-row select { width: auto; min-height: 34px; padding: 4px 28px 4px 10px; font-size: 13.5px; }
.week-days { display: flex; flex-wrap: wrap; gap: 4px; }
.week-days button { width: 38px; height: 32px; border-radius: 9px; background: var(--well); color: var(--ink-3); font-size: 12.5px; font-weight: 500; }
.week-days [aria-pressed='true'] { background: var(--accent-soft); color: var(--accent); font-weight: 600; }
.ahead { display: grid; gap: 6px; }
.ahead li { display: flex; align-items: baseline; gap: 10px; font-size: 13.5px; }
.ahead b { font-weight: 500; font-variant-numeric: tabular-nums; }
.ahead span { color: var(--ink-2); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.parts { display: flex; flex-wrap: wrap; gap: 16px 34px; align-items: center; }
.parts > div { display: flex; align-items: center; gap: 12px; }
.parts > div > div { display: grid; line-height: 1.4; }
.parts .status { flex: 1 1 260px; justify-content: flex-end; }

/* Receipts */
.ledger { display: grid; grid-template: auto minmax(0, 1fr) / minmax(0, 1fr) 340px; height: 100%; }
.ledger-top { grid-column: 1 / -1; display: flex; flex-wrap: wrap; align-items: center; gap: 12px; padding: 13px 24px; }
.ledger-top .chip { padding: 5px 11px; }
.receipts { overflow-y: auto; padding: 4px 0 24px; }
.day { padding: 18px 24px 8px; color: var(--ink-2); }
.line { display: flex; align-items: center; gap: 14px; width: 100%; min-height: 48px; padding: 6px 24px; }
.line:hover { background: var(--paper); }
.line[aria-current='true'] { background: color-mix(in srgb, var(--tone) 12%, var(--surface)); }
.line:focus-visible { outline-offset: -2px; }
.line time { flex: none; color: var(--ink-3); font: 13px var(--mono); }
.line-text { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.receipt-side { overflow-y: auto; background: var(--group); }
.receipt { --mark: var(--tone); display: flex; flex-direction: column; gap: 16px; min-height: 100%; padding: 22px; }
.receipt-green { --mark: var(--green); }
.receipt-amber { --mark: var(--amber); }
.receipt-red { --mark: var(--stop); }
.receipt-head { display: grid; grid-template-columns: 44px minmax(0, 1fr); align-items: center; gap: 13px; }
.receipt-head > div { display: grid; gap: 1px; min-width: 0; }
.receipt-head small { color: var(--ink-2); }
.receipt-mark { display: grid; place-items: center; width: 44px; height: 44px; border-radius: 13px; background: color-mix(in srgb, var(--mark) 15%, var(--surface)); color: var(--mark); }
/* Where it sits in the chain: the one after it holds its fingerprint, and it holds the one before. */
.chain-box { display: grid; gap: 12px; }
.chain { display: grid; }
.chain-block { display: grid; grid-template-columns: 30px minmax(0, 1fr) auto; align-items: center; gap: 10px; padding: 9px 12px; border-radius: 12px; background: var(--well); font-size: 13px; }
.chain-n { display: grid; place-items: center; height: 24px; border-radius: 7px; background: var(--raised); color: var(--ink-2); font-size: 12px; font-weight: 600; font-variant-numeric: tabular-nums; }
.chain-text { overflow: hidden; color: var(--ink-2); text-overflow: ellipsis; white-space: nowrap; }
.chain-this { background: color-mix(in srgb, var(--tone) 16%, var(--surface)); }
.chain-this .chain-n { background: var(--tone); color: var(--surface); }
.chain-this .chain-text { color: var(--ink); font-weight: 500; }
.chain-link { display: flex; align-items: center; gap: 7px; height: 28px; margin-left: 26px; padding-left: 14px; border-left: 2px solid color-mix(in srgb, var(--tone) 40%, transparent); color: var(--ink-3); font: 12px var(--mono); }
.chain-link .icon { color: var(--tone); }
.receipt h2 { font-size: 17px; line-height: 1.35; overflow-wrap: anywhere; }
.receipt dl { display: grid; grid-template-columns: 92px 1fr; gap: 9px 12px; font-size: 14px; }
.receipt dt { color: var(--ink-3); }
.receipt dd { overflow-wrap: anywhere; }
.receipt-foot { margin-top: auto; color: var(--ink-3); font-size: 13px; }

/* The public page itself */
.door { display: grid; place-items: center; min-height: 100vh; padding: 24px; background: linear-gradient(160deg, #e9f7d0, #e6effe 58%, #f3f0fe); }
.door-card { display: flex; flex-direction: column; width: min(680px, 100%); height: min(820px, calc(100vh - 48px)); overflow: hidden; border-radius: 22px; background: var(--surface); box-shadow: 0 40px 80px -50px rgb(15 23 42 / 0.45); }
.door-head { display: flex; align-items: center; gap: 15px; padding: 22px 26px 6px; }
.door-head h1 { font-size: 20px; }
.door-state { display: flex; align-items: center; gap: 8px; color: var(--ink-3); font-size: 13.5px; }
.door-state::before { content: ''; width: 8px; height: 8px; border-radius: 50%; background: #cbd5e1; }
.door-state.on::before { background: #22a55a; }
.door-about { margin: 18px 26px 0; padding: 13px 16px; border-radius: 13px; background: var(--ok-soft); color: #14532d; white-space: pre-wrap; overflow-wrap: anywhere; }
.door .talk { display: flex; flex-direction: column; gap: 13px; padding: 20px 26px; }
.door .answer { align-self: flex-start; max-width: 84%; white-space: pre-wrap; overflow-wrap: anywhere; }
.door .bubble { align-self: flex-end; background: var(--main); color: #fff; }
.door .note { align-self: center; color: var(--ink-3); font-size: 13.5px; text-align: center; }
.door .ask { display: flex; align-items: flex-end; gap: 8px; margin: 0 20px; padding: 8px; border-radius: 16px; background: var(--well); }
.door .ask:focus-within { box-shadow: 0 0 0 1.5px var(--accent), 0 0 0 4px var(--glow); }
.door .ask textarea { resize: none; background: none; box-shadow: none; }
.door-foot { padding: 13px 26px 18px; color: var(--ink-3); font-size: 12.5px; text-align: center; }
.starters { display: grid; grid-template-columns: 1fr 1fr; gap: 9px; margin: auto 0 0; }
.starters .try { grid-template-columns: 1fr; }

/* Colour: each page has a tone, carried by its mark in the header and its place in the list. The page itself is
   white. */
/* Anything that names a page takes its tone: the app itself, and the tour that walks through it. */
.app, [data-page] { --tone: var(--blue); }
[data-page='today'], [data-page='receipts'] { --tone: var(--violet); }
[data-page='needs'], [data-page='saves'] { --tone: var(--amber); }
[data-page='memory'], [data-page='rules'] { --tone: var(--teal); }
[data-page='replicas'] { --tone: var(--pink); }
[data-page='machine'] { --tone: var(--green); }
.body { background: var(--ground); }
.page, .composer-box { background: transparent; }
.top-words { flex: 1; min-width: 0; display: grid; gap: 3px; }
.top .top-words h1 { font-size: 21px; font-weight: 700; letter-spacing: -0.02em; }
.top .top-words p { flex: none; font-size: 14px; color: var(--ink-2); }
/* The page's mark sits beside a two-line title, no taller than it, so it reads as a label and not a picture. */
.top-mark { display: grid; place-items: center; flex: none; width: 36px; height: 36px; border-radius: 10px; background: color-mix(in srgb, var(--tone) 12%, var(--surface)); color: var(--tone); }
.face-img { padding: 0; background: #d7f0c2; object-fit: cover; }
.who-state { width: fit-content; white-space: nowrap; padding: 0 8px; border-radius: 99px; background: var(--ok-soft); font-size: 12px; font-weight: 500; line-height: 20px; }
.who-rest { background: var(--wait-soft); color: var(--wait) !important; }

/* Numbers that open the page they count */
.stat-card { --mark: var(--blue); display: grid; grid-template-columns: 1fr auto; align-content: start; gap: 2px 10px; min-width: 0; padding: 10px 12px; border-radius: 14px; background: none; text-align: left; }
button.stat-card:hover { background: var(--well-out); }
.stat-card .stat-mark { grid-column: 1; grid-row: 1; color: var(--mark); }
.stat-card small { grid-column: 1 / -1; color: var(--ink-2); font-size: 13px; }
.stat-card > b { grid-column: 1 / -1; font-size: 26px; font-weight: 700; letter-spacing: -0.02em; line-height: 1.15; overflow-wrap: anywhere; }
.stat-amber { --mark: var(--amber); } .stat-violet { --mark: var(--violet); } .stat-green { --mark: var(--green); } .stat-pink { --mark: var(--pink); } .stat-red { --mark: var(--stop); }
/* Beside the talk the numbers sit in one slim row, so the opening, map and all, fits above the box you type in. */
.talk-in > .stats .stat-card { grid-template-columns: 34px minmax(0, 1fr); align-items: center; gap: 0 11px; padding: 10px 12px; }
.talk-in > .stats .stat-mark { grid-column: 1; grid-row: 1 / 3; }
.talk-in > .stats .stat-card small { grid-column: 2; grid-row: 1; align-self: end; font-size: 12.5px; line-height: 1.3; }
.talk-in > .stats .stat-card > b { grid-column: 2; grid-row: 2; align-self: start; font-size: 19px; line-height: 1.25; }
/* Each number keeps its label and its value on one line apiece, so the mark beside them sits at their middle. Four in a
   row in the talk (780 wide at most) leave a tile too narrow for that: "Waiting for your yes" broke in two and the
   mark floated between the lines. So beside the talk they sit two by two. */
.talk-in > .stats { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 6px 10px; }
.talk-in > .stats .stat-card small, .talk-in > .stats .stat-card > b { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; overflow-wrap: normal; }
.stats { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px; }

/* Its own computer */
.machine-hero { display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 16px 20px; padding: 20px 22px; }
.machine-name { display: grid; gap: 2px; min-width: 0; }
.machine-name .pills { margin-top: 10px; }
.machine-facts { list-style: none; margin: 0; padding: 0; display: grid; gap: 9px; color: var(--ink-2); font-size: 13.5px; }
.machine-facts li { display: flex; align-items: center; gap: 10px; }
.machine-facts svg { flex: none; color: var(--green); }
@media (max-width: 900px) {
  .machine-hero { grid-template-columns: auto 1fr; }
  .machine-facts { grid-column: 1 / -1; padding: 6px 0 0; }
}
.machine-hero b { font-size: 20px; font-weight: 700; }
.machine-hero a { color: var(--ink-2); font: 13px var(--mono); }
.machine-hero a:hover { color: var(--ink); text-decoration: underline; }
.machine-mark, .stat-mark { display: grid; place-items: center; flex: none; width: 52px; height: 52px; border-radius: 15px; background: var(--green-soft); color: var(--green); }
.stat-mark { width: 34px; height: 34px; border-radius: 10px; background: color-mix(in srgb, var(--mark, var(--tone)) 11%, var(--surface)); color: var(--mark, var(--tone)); }
.pills { display: flex; flex-wrap: wrap; gap: 8px; }
.chip-blue { background: var(--blue-soft); color: var(--blue); }
.chip-violet { background: var(--violet-soft); color: var(--violet); }
.chip .dot { width: 7px; height: 7px; border-radius: 50%; background: currentColor; }
.machine-grid { display: grid; grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr) minmax(0, 1fr); gap: 16px; }
.machine-grid-low { grid-template-columns: minmax(0, 1.6fr) minmax(0, 1fr) minmax(0, 1fr); }
.machine .card { display: grid; align-content: start; gap: 12px; }
.service-list { display: grid; gap: 10px; }
.service-list li { display: flex; align-items: center; gap: 12px; }
.service-list li > div { flex: 1; display: grid; }
.gauge { justify-items: center; text-align: center; }
.gauge h2 { justify-self: start; }
.gauge-ring { position: relative; display: grid; place-items: center; }
.gauge-ring svg { transform: rotate(-90deg); }
.gauge-ring b { position: absolute; font-size: 20px; font-weight: 700; }
.gauge-track { fill: none; stroke: var(--raised); stroke-width: 7; }
.gauge-fill { fill: none; stroke: var(--green); stroke-width: 7; stroke-linecap: round; }
.gauge-violet .gauge-fill { stroke: var(--violet); }
.diary header { display: grid; gap: 2px; }
.days { display: grid; gap: 7px; }
.day-bar { display: grid; grid-template-columns: 34px 1fr; align-items: center; gap: 10px; }
.bands { display: flex; height: 12px; overflow: hidden; border-radius: 99px; background: var(--raised); }
.band { display: block; height: 100%; }
.band-awake { background: #4cc46f; }
.band-asleep { background: color-mix(in srgb, var(--ink-3) 35%, var(--surface)); }
.band-unknown { background: repeating-linear-gradient(135deg, var(--raised) 0 4px, var(--surface) 4px 8px); }
.legend { display: flex; flex-wrap: wrap; gap: 6px 16px; color: var(--ink-2); font-size: 12.5px; }
.legend span { display: inline-flex; align-items: center; gap: 6px; }
.legend i { width: 11px; height: 11px; border-radius: 4px; }
.reach-list { display: grid; gap: 9px; }
.reach-list li { display: flex; align-items: center; gap: 10px; }
.machine-foot { text-align: center; }

/* Save points and the family dinner */
.saves-page { align-items: start; }
.saves > header, .dinner > header { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 4px; }
.dinner > header { justify-content: flex-start; }
.save-list { display: grid; margin: 8px 0 12px; }
.save { --dot: var(--amber); position: relative; display: grid; grid-template-columns: 22px minmax(0, 1fr) auto; align-items: start; gap: 4px 12px; padding: 14px 0; }
.save::before { content: ''; position: absolute; left: 6px; top: 0; bottom: 0; width: 2px; background: var(--line-2); }
.save:first-child::before { top: 22px; }
.save:last-child::before { bottom: calc(100% - 22px); }
/* The ring in the group's own fill breaks the line that runs behind the dots. */
.save-dot { position: relative; z-index: 1; width: 14px; height: 14px; margin-top: 3px; border-radius: 50%; background: var(--dot); box-shadow: 0 0 0 4px var(--group); }
.save > div:not(.save-warn) { display: grid; }
.save-when { color: var(--ink-2); }
.save-blue { --dot: var(--blue); } .save-green { --dot: var(--green); } .save-violet { --dot: var(--violet); } .save-pink { --dot: var(--pink); } .save-grey { --dot: var(--ink-3); }
.save-warn { grid-column: 2 / -1; display: grid; gap: 10px; padding: 12px 14px; border-radius: 12px; background: var(--wait-soft); color: var(--ink); }
.dinner { display: grid; gap: 12px; }
.dinner-ask input { flex: 1; min-width: 0; }
.dinner-q { justify-self: start; padding: 9px 14px; border-radius: 12px; background: var(--violet-soft); font-weight: 500; }
.seats { display: grid; gap: 10px; }
.seat { --seat: var(--violet); display: grid; grid-template-columns: 40px minmax(0, 1fr); gap: 12px; align-items: start; }
.seat img { border-radius: 50%; background: color-mix(in srgb, var(--seat) 22%, var(--surface)); }
.seat > div { padding: 10px 14px; border-radius: 4px 14px 14px 14px; background: var(--well); }
.seat b { font-size: 13px; }
.seat-1 { --seat: var(--green); } .seat-2 { --seat: var(--blue); } .seat-3 { --seat: var(--amber); }

/* Other replicas */
.people { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
.person { --band: var(--violet); display: grid; grid-template-columns: 64px minmax(0, 1fr); gap: 14px; padding: 16px; border-radius: var(--radius); background: var(--group); }
.person-face { border-radius: 50%; background: color-mix(in srgb, var(--band) 24%, var(--surface)); }
.person-words { display: grid; gap: 4px; align-content: start; min-width: 0; }
.person-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.person-head b { font-size: 15.5px; }
.person-words > p:first-of-type { color: var(--ink-2); }
.person-tags { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 4px; }
.tag { padding: 2px 10px; border-radius: 99px; background: color-mix(in srgb, var(--band) 14%, var(--surface)); color: color-mix(in srgb, var(--band) 80%, var(--ink)); font-size: 12.5px; font-weight: 500; }
.person-do { grid-column: 2; display: flex; flex-wrap: wrap; gap: 8px; }
.person-do a { display: inline-flex; align-items: center; gap: 6px; }
.person-green { --band: var(--green); } .person-blue { --band: var(--blue); } .person-amber { --band: var(--amber); } .person-pink { --band: var(--pink); } .person-teal { --band: var(--teal); }
.ask-box { display: grid; gap: 12px; }
.ask-row { display: grid; grid-template-columns: minmax(0, 180px) minmax(0, 1fr) auto; gap: 8px; }
.heard { display: grid; grid-template-columns: 40px minmax(0, 1fr); gap: 4px 12px; padding: 14px; border-radius: 14px; background: color-mix(in srgb, var(--pink) 7%, var(--surface)); }
.heard img { border-radius: 50%; background: var(--raised); }
.heard > div { display: grid; gap: 4px; }
.heard-note { grid-column: 2; }

@media (max-width: 1180px) {
  .app { grid-template-columns: 208px minmax(0, 1fr) 270px; }
  .app.no-rail { grid-template-columns: 208px minmax(0, 1fr); }
  .two, .two-even { grid-template-columns: 1fr; }
  .pre-side, .side-cards { position: static; }
  .new-rule { grid-template-columns: 1fr 1fr; }
  .rules-grid { grid-template-columns: 1fr; }
  .rules-note { flex-wrap: wrap; }
  .rules-say { flex: 1 1 100%; }
  .rules-count { flex: 1; min-width: 0; }
  .line code { display: none; }
  .ledger { grid-template-columns: minmax(0, 1fr) 290px; }
}
@media (max-width: 960px) {
  .app, .app.no-rail { display: flex; flex-direction: column; }
  .side { order: 2; flex: none; padding: 0; }
  .side .brand, .side-foot, .nav-group { display: none; }
  #nav { overflow-x: auto; scrollbar-width: none; flex-direction: row; gap: 0; margin: 0; padding: 4px 4px calc(4px + env(safe-area-inset-bottom)); }
  .nav-item { flex-direction: column; gap: 3px; flex: 1 0 62px; width: auto; min-width: 62px; min-height: 52px; padding: 6px 0; font-size: 11px; text-align: center; line-height: 1.2; justify-content: center; }
  .nav-item[aria-current] { background: none; box-shadow: none; color: var(--accent); }
  .count { position: absolute; top: 2px; right: 10px; min-width: 18px; line-height: 18px; }
  .body { flex: 1; }
  .rail { display: none; }
  .app.rail-open .rail, .app.no-rail.rail-open .rail { position: absolute; top: 56px; right: 0; bottom: 61px; width: min(340px, 100%); box-shadow: var(--lift); z-index: 5; }
  .nav-label { display: none; }
  .nav-short { display: inline !important; }
  .only-small { display: inline-flex !important; }
  .top { min-height: 64px; padding: 12px 16px; }
  .top-mark { width: 32px; height: 32px; border-radius: 9px; }
  .top .top-words h1 { font-size: 20px; }
  .stats, .machine-grid, .machine-grid-low, .people { grid-template-columns: 1fr 1fr; }
  .ask-row { grid-template-columns: 1fr; }
  .top p { display: block; }
  .page { padding: 16px; }
  .talk { padding: 20px 16px; }
  .composer-box { padding: 0 12px 12px; }
  .app-grid { grid-template-columns: 1fr; }
  .split { grid-template-columns: 1fr; height: auto; }
  .page.page-needs:has(.split), .page.page-receipts { overflow-y: auto; }
  /* On one column it would stand between the list and the draft. */
  .how-steps { display: none; }
  .split-main { padding: 16px; }
  .ledger { display: block; height: auto; }
  .receipt-side { display: none; }
  .ledger-top { padding: 12px 16px; }
  .day { padding: 16px 16px 6px; }
  .line { padding: 6px 16px; }
  .gate-top { grid-template-columns: 1fr; gap: 14px; padding: 16px 20px 0; }
  .gate-steps li { flex: 1; width: auto; }
  .gate-main { min-height: 0; align-content: start; padding: 20px 20px 36px; }
  .gate-split { grid-template-columns: 1fr; }
  .toast { bottom: 78px; }
}
@media (max-width: 620px) {
  /* No wider than the words it shows at rest, so the page's name keeps its room. */
  .pulse-work > span { max-width: 14ch; }
  .top p, .composer-note { display: none; }
  .top h1 { flex: 1; }
  .composer-foot { justify-content: space-between; }
  .tries, .starters, .how ol, .new-rule, .field-row, .machine-grid, .machine-grid-low, .people { grid-template-columns: 1fr; }
  .field-row { gap: 6px; }
  .turn { grid-template-columns: 1fr; gap: 6px; }
  .turn-face { display: none; }
  .bubble { max-width: 90%; }
  .list > li, .lead { flex-wrap: wrap; }
  .lead > div:not(.seg) { flex: 1 1 200px; }
  .rules-grid .new-rule { grid-template-columns: 1fr; }
  .list > li > .seg, .list > li > .row-end { margin-left: auto; }
  /* A rule with a daily limit has three parts; its name takes a line of its own so it is not squeezed to a few letters. */
  .rules > li:has(.a-day) > div:first-child { flex-basis: 100%; }
  .seg { max-width: 100%; overflow-x: auto; scrollbar-width: none; }
  .line { flex-wrap: wrap; gap: 4px 10px; padding-block: 10px; }
  .line-text { flex: 1 1 60%; white-space: normal; }
  .line .chip { margin-left: 53px; }
  .parts .status { justify-content: flex-start; }
  .door { padding: 0; }
  .gate .gate-card { padding: 24px 20px; }
  .gate .gate-you { grid-template-columns: 1fr; justify-items: center; text-align: center; }
  .gate-you > .stack { justify-self: stretch; text-align: left; }
  .gate-head h1 { font-size: 24px; }
  .gate .ticks { grid-template-columns: 1fr; }
  .peek { flex-wrap: wrap; }
  .peek .chip { margin-left: 56px; }
  .door-card { height: 100vh; height: 100dvh; border-radius: 0; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition: none !important; animation: none !important; }
  /* Standing still, the grid's dots would be too faint to read as a mark. */
  .grid i { opacity: 0.55; }
}

/* ---------- Your coding agents (Connections) ---------- */
.agents-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.agents-list li { display: flex; align-items: center; gap: 12px; }
.agents-list li > div { flex: 1; min-width: 0; display: grid; line-height: 1.4; }
.key-once { display: grid; gap: 10px; padding: 14px; border-radius: 12px; background: var(--well); }
.key-once p { margin: 0; }
.key-once pre { margin: 0; font-size: 12.5px; line-height: 1.5; white-space: pre-wrap; overflow-wrap: anywhere; }

.door-face { border-radius: 50%; background: var(--violet-soft); }
