/* =====================================================================
   Talqava, fifth pass: the slim rail.
   Loaded last. The menu becomes a narrow rail of icons with the account
   at its foot, the dark look is the standard one, and it is calmer: no
   glow behind buttons and fields.

   The three "interaction layer" tokens below (a hover, a selected and a
   selected-hover surface mixed from the theme's own ink, so they sit
   right on any surface in either theme) are adapted from OpenClaw's
   ui/src/styles/base.css. Copyright (c) 2026 OpenClaw Foundation, MIT
   licence; see THIRD_PARTY_NOTICES.md.

   The greys and the reds are steps of the "sage" and "red" scales of
   Radix Colors (radix-ui.com/colors), where each step has one job: a
   surface, a border, quiet text, text. Copyright (c) 2021-2022 Modulz,
   (c) 2022-Present WorkOS, MIT licence; see THIRD_PARTY_NOTICES.md.
   The black ground and the green stay Talqava's own brand colours.
   Everything else here is Talqava's.
   ===================================================================== */
:root {
  --surface-hover: color-mix(in srgb, var(--text) 6%, transparent);
  --surface-selected: color-mix(in srgb, var(--text) 9%, transparent);
  --surface-selected-hover: color-mix(in srgb, var(--text) 12%, transparent);
  --rail-width: 56px;
}
/* Calm: the dark look keeps its green, without the glow around it. */
:root:not([data-theme="light"]) { --accent-glow: transparent; }

/* ---------- the rail ---------- */
#app { grid-template-columns: var(--rail-width) minmax(0, 1fr); }
.rail { padding: 10px 0 12px; align-items: center; gap: 4px; overflow: visible; z-index: 40; }
.rail .brand { align-self: center; padding: 4px 0 10px; }
.rail .railgroup { align-items: center; gap: 4px; width: 100%; }
.rail .railend { margin-top: auto; padding-top: 8px; }
.rail .railitem { width: 38px; min-height: 38px; height: 38px; padding: 0; justify-content: center; border-radius: 10px; color: var(--muted); }
.rail .railitem .ico { color: inherit; }
.rail .railitem:hover { background: var(--surface-hover); color: var(--text); }
.rail .railitem.on { background: var(--surface-selected); color: var(--text); }
.rail .railitem.on:hover { background: var(--surface-selected-hover); }
.rail .railitem.on::before { display: none; }
.rail .railitem.on .ico { color: var(--text); }
.rail .railitem:active { transform: scale(0.96); }
/* What needs you, as a number on the Inbox icon. */
.rail .railitem .count { position: absolute; top: -3px; right: -4px; min-width: 16px; height: 16px; padding: 0 4px; border-radius: 8px; font: 600 10px/16px var(--sans); text-align: center; background: var(--warn, #ffb020); color: #0a0a0a; box-shadow: none; }
/* Each icon says what it is when pointed at or reached with the keyboard. */
.rail .railitem[data-tip]::after {
  content: attr(data-tip); position: absolute; left: calc(100% + 10px); top: 50%; transform: translateY(-50%);
  padding: 5px 9px; border-radius: 7px; background: var(--raised); border: 1px solid var(--line2); color: var(--text);
  font: 500 12px/1.2 var(--sans); white-space: nowrap; pointer-events: none; opacity: 0; transition: opacity 0.12s ease 0.25s; z-index: 80;
}
.rail .railitem[data-tip]:hover::after, .rail .railitem[data-tip]:focus-visible::after { opacity: 1; }
.rail .acctbutton { width: 32px; height: 32px; min-height: 32px; padding: 0; border-radius: 50%; border: 1px solid var(--line2); background: var(--raised); color: var(--soft); font: 600 11px/1 var(--sans); display: grid; place-items: center; margin-top: 6px; }
.rail .acctbutton:hover, .rail .acctbutton[aria-expanded="true"] { border-color: var(--accent); color: var(--text); }

/* ---------- the account menu ---------- */
.acctmenu {
  position: fixed; left: calc(var(--rail-width) + 8px); bottom: 12px; width: min(300px, calc(100vw - var(--rail-width) - 24px)); z-index: 90;
  background: var(--panel); border: 1px solid var(--line2); border-radius: 14px; padding: 8px; display: flex; flex-direction: column; gap: 2px;
  box-shadow: 0 18px 50px rgba(0, 0, 0, 0.35);
}
:root:not([data-theme="light"]) .acctmenu { background: #151615; }
.accthead { display: flex; align-items: center; gap: 10px; padding: 8px 8px 10px; min-width: 0; }
.accthead .who { min-width: 0; }
.accthead .who b { display: block; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.accthead .who span { display: block; font-size: 13px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.acctavatar { width: 30px; height: 30px; border-radius: 50%; background: var(--raised); border: 1px solid var(--line2); display: grid; place-items: center; font: 600 11px/1 var(--sans); color: var(--soft); flex: none; }
.acctlabel { font: 600 10.5px/1 var(--sans); letter-spacing: 0.08em; text-transform: uppercase; color: var(--muted); padding: 8px 8px 4px; }
.acctsep { height: 1px; background: var(--line); margin: 6px 4px; }
.acctrow { display: flex; align-items: center; gap: 10px; width: 100%; min-height: 34px; padding: 0 8px; border: 0; border-radius: 8px; background: none; color: var(--text); text-align: left; font-size: 13.5px; }
.acctrow:hover { background: var(--surface-hover); border: 0; }
.acctrow .ico { display: inline-flex; color: var(--muted); flex: none; }
.acctlook { display: flex; gap: 4px; padding: 2px 4px 4px; }
.acctlook button { flex: 1; min-height: 30px; padding: 0 6px; font-size: 13px; border-radius: 8px; border: 1px solid var(--line); background: none; color: var(--soft); }
.acctlook button.on { background: var(--surface-selected); border-color: var(--line2); color: var(--text); font-weight: 600; }

/* ---------- small windows: the rail stays; there is no slide-out menu ---------- */
.menubtn { display: none !important; }
@media (max-width: 900px) {
  #app { grid-template-columns: var(--rail-width) minmax(0, 1fr); }
  .rail { position: static; inset: auto; width: auto; transform: none; box-shadow: none; }
  body.menuopen .rail { box-shadow: none; }
}
@media (prefers-reduced-motion: reduce) { .rail .railitem[data-tip]::after { transition: none; } }

/* A step not yet done shows its number in the page's own ink (it was drawn for a filled circle). */
.istepmark { color: var(--soft); }

/* ---------- Automations: one table for routines and briefings ---------- */
.autobar { display: flex; align-items: flex-end; gap: 12px; flex-wrap: wrap; border-bottom: 1px solid var(--line); }
.autotabs { display: flex; gap: 4px; flex-wrap: wrap; flex: 1; min-width: 0; }
.autotab { border: 0; border-radius: 0; background: none; color: var(--muted); padding: 8px 10px; min-height: 36px; font-size: 13.5px; box-shadow: none; }
.autotab:hover { color: var(--text); border: 0; }
.autotab.on { color: var(--text); font-weight: 600; box-shadow: inset 0 -2px 0 var(--accent); }
.autocount { margin-left: 6px; font: 500 11px var(--mono); color: var(--muted); }
.autobar > .primary { margin-bottom: 6px; }
.autobody { margin-top: 14px; display: grid; gap: 12px; }
.tablewrap { border: 1px solid var(--line); border-radius: 12px; background: var(--panel); }
/* A narrow window scrolls the table sideways; a wide one lets a row's menu hang below the table. */
@media (max-width: 820px) { .tablewrap { overflow-x: auto; } }
.autotable { width: 100%; min-width: 640px; border-collapse: collapse; font-size: 13.5px; }
.autotable th { text-align: left; font: 600 10.5px var(--sans); letter-spacing: 0.08em; text-transform: uppercase; color: var(--muted); padding: 10px 14px; border-bottom: 1px solid var(--line); }
.autotable td { padding: 11px 14px; border-bottom: 1px solid var(--line); vertical-align: middle; color: var(--soft); }
.autotable tbody tr:last-child td { border-bottom: 0; }
.autotable tr.paused td { color: var(--muted); }
.autotable td b { color: var(--text); font-weight: 600; }
.autoby { display: block; font-size: 13px; color: var(--muted); }
.autodot { width: 7px; height: 7px; border-radius: 50%; background: var(--line2); flex: none; margin-top: 7px; }
.autodot.on { background: var(--accent); }
.autonum { font-variant-numeric: tabular-nums; white-space: nowrap; font-size: 13px; }
.autoend { text-align: right; white-space: nowrap; width: 1%; }
.autobad { color: var(--bad, #ff6b6b); }
.autotoggle { width: 34px; min-width: 34px; height: 20px; min-height: 20px; padding: 0; border-radius: 10px; border: 0; background: var(--line2); position: relative; vertical-align: middle; }
.autotoggle::after { content: ""; position: absolute; top: 3px; left: 3px; width: 14px; height: 14px; border-radius: 50%; background: var(--muted); transition: transform 0.14s ease; }
.autotoggle.on { background: var(--accent); }
.autotoggle.on::after { transform: translateX(14px); background: var(--on-accent); }
.autotoggle:hover { border: 0; filter: brightness(1.1); }
.automenu { position: relative; display: inline-block; }
.automenu > summary { list-style: none; cursor: pointer; width: 30px; height: 30px; border-radius: 8px; display: grid; place-items: center; color: var(--muted); font-size: 18px; line-height: 1; }
.automenu > summary::-webkit-details-marker { display: none; }
.automenu > summary:hover, .automenu[open] > summary { background: var(--surface-hover); color: var(--text); }
.automenulist { position: absolute; right: 0; top: calc(100% + 4px); z-index: 30; min-width: 190px; background: var(--raised); border: 1px solid var(--line2); border-radius: 10px; padding: 6px; display: grid; gap: 2px; box-shadow: 0 14px 40px rgba(0, 0, 0, 0.3); }
:root:not([data-theme="light"]) .automenulist { background: #1a1b1a; }
.automenulist button { text-align: left; padding: 7px 10px; border-radius: 7px; color: var(--text); font-size: 13.5px; }
.automenulist button:hover { background: var(--surface-hover); }
.automenulist button.danger { color: var(--bad, #ff6b6b); border: 0; }
.autoedit > div { padding: 0 14px 14px; }
.autoempty { display: grid; gap: 8px; justify-items: start; }
@media (prefers-reduced-motion: reduce) { .autotoggle::after { transition: none; } }

/* Settings > Labs: the set-aside parts, each with a line saying what it is. */
.labslist { display: grid; gap: 8px; margin: 6px 0 14px; }
.labslist .lab { align-items: flex-start; }
.labslist .lab span { display: grid; gap: 1px; }

/* Connections > Telegram: the pairing code, large enough to read across a desk. */
.tgcode { font: 600 30px/1 var(--mono); letter-spacing: 0.28em; padding: 14px 18px; border: 1px dashed var(--line2); border-radius: 12px; justify-self: start; user-select: all; }

/* ---------- Sessions: chats and tasks in one list ---------- */
.sessrow { position: relative; }
.sessrow .navlink { padding-right: 30px; }
.sesskind { width: 18px; height: 18px; flex: none; display: grid; place-items: center; color: var(--muted); }
.sesskind svg { width: 15px; height: 15px; }
.sessmenu { position: absolute; right: 4px; top: 50%; transform: translateY(-50%); }
.sessmenu > summary { list-style: none; cursor: pointer; width: 24px; height: 24px; border-radius: 6px; display: grid; place-items: center; color: var(--muted); font-size: 16px; line-height: 1; opacity: 0; }
.sessmenu > summary::-webkit-details-marker { display: none; }
.sessrow:hover .sessmenu > summary, .sessmenu[open] > summary, .sessmenu > summary:focus-visible { opacity: 1; }
.sessmenu > summary:hover, .sessmenu[open] > summary { background: var(--surface-hover); color: var(--text); }
.sessmenu .automenulist { z-index: 50; min-width: 170px; }
.sessarch { margin: 10px 8px 4px; }
.dot.bad { background: var(--bad, #ff6b6b); }
/* The box you type in, with its choices underneath. */
.compose .composebox { flex-direction: column; align-items: stretch; gap: 8px; border: 1px solid var(--line2); border-radius: 14px; background: var(--field, var(--panel)); padding: 10px 12px; }
.compose .composebox textarea { border: 0; background: none; padding: 2px 0; box-shadow: none; resize: none; }
.compose .composebox textarea:focus { box-shadow: none; border: 0; }
.compose .composebox:focus-within { border-color: var(--accent); }
.composetools { display: flex; align-items: center; gap: 8px; flex-wrap: nowrap; min-width: 0; }
.composetools .askchip { min-width: 0; flex-shrink: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.composetools .modelpick { max-width: 190px; }
.composetools > button, .composetools > select { flex: none; }
.composetools select { width: auto; max-width: 220px; border: 0; background: none; color: var(--soft); padding: 4px 6px; font-size: 13px; }
.composetools select:hover { color: var(--text); }
.composetools .askchip { font-size: 13px; }

/* ---------- Files: one list, filtered by kind ---------- */
.fileskinds { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 10px; }
.fileskinds .mpill .autocount { margin-left: 6px; }

/* The set-up steps on a new session sit in the middle column, left-aligned. */
.empty.hero .askset { text-align: left; width: min(560px, 100%); margin: 6px auto; }

/* A session page with nothing to list is one column; the overview column appears only when it has something in it. */
.body.two.noside { grid-template-columns: minmax(0, 1fr); }
.body.two.over.noside { grid-template-columns: minmax(0, 1fr) 280px; }
@media (max-width: 1180px) { .body.two.over.noside { grid-template-columns: minmax(0, 1fr); } }

/* ---------- one scale of greys, each step with one job ---------- */
:root {
  --field: #101211;   /* sage 1: wells you type in */
  --side: #0d0e0d;
  --panel: #171918;   /* sage 2: cards and panels */
  --raised: #202221;  /* sage 3: what sits on a panel, and hover */
  --line: #272a29;    /* sage 4: quiet dividers */
  --line2: #373b39;   /* sage 6: borders of things you can press */
  --muted: #8a9490;   /* between sage 10 and 11, so small print stays readable on a panel */
  --soft: #adb5b2;    /* sage 11: quiet text */
  --text: #eceeed;    /* sage 12: text */
  --bad: #e5484d;     /* red 9 */
  --bad-ink: #ff9592; /* red 11 */
  --glass-line: #272a29;
}
:root[data-theme="light"] {
  --bg: #f7f9f8;      /* sage 2 */
  --field: #ffffff;
  --panel: #ffffff;
  --raised: #eef1f0;  /* sage 3 */
  --line: #dfe2e0;    /* sage 5 */
  --line2: #cbcfcd;   /* sage 7 */
  --muted: #5d6562;   /* 6:1 on white, 5.5:1 on the page ground */
  --soft: #535957;    /* sage 11, a step darker for small print */
  --text: #1a211e;    /* sage 12 */
  --bad: #dc3e42;     /* red 10 */
  --bad-ink: #ce2c31; /* red 11 */
  --glass-line: #dfe2e0;
}

/* Tables and the cost chart: the row under the pointer is marked, figures line up, and the chart has faint lines to read heights against. */
.autotable td { font-variant-numeric: tabular-nums; }
.autotable tbody tr:hover td { background: var(--surface-hover); }
/* The ways to start a file: three plain cards in a row, each clearly something to press. */
.mgrid.wide:has(> .officestart) { grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); }
button.card.officestart { border: 1px solid var(--line2); background: var(--panel); padding: 12px 14px; border-radius: 12px; text-align: left; }
button.card.officestart:hover { background: var(--raised); border-color: var(--accent); }

/* A file is the writing; its settings open beside it from Details. */
.wspage.nodetails { grid-template-columns: minmax(0, 1fr); max-width: 860px; }
/* The two parts of Knowledge. */
.knowparts { align-self: flex-start; }

/* ---------- the steps of a piece of work, under one line ---------- */
.worklog { border: 1px solid var(--line); border-radius: 12px; background: var(--panel); margin: 8px 0; }
.worklog > summary { display: flex; align-items: center; gap: 10px; padding: 9px 14px; cursor: pointer; list-style: none; color: var(--soft); font-size: 13.5px; }
.worklog > summary::-webkit-details-marker { display: none; }
.worklog > summary:hover { color: var(--text); }
.worklog .worksum { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.worklog .workshow::after { content: "Show the steps"; color: var(--accent-ink, var(--accent)); font-size: 13px; white-space: nowrap; }
.worklog[open] .workshow::after { content: "Hide"; }
.worklog[open] > summary { border-bottom: 1px solid var(--line); }
.worklog > details { margin: 6px 10px; }
.worklog > details:last-child { margin-bottom: 10px; }
.worklog details.tool > summary .what.plain { font-family: var(--sans); color: var(--text); font-size: 13.5px; }
/* The first task: one plain card, where there would be empty columns. */
.firsttask { max-width: 640px; display: grid; gap: 8px; padding: 18px 20px; }
.firsttask .note { margin: 0; }
/* The team page without the finished-work column, until something has finished. */
@media (min-width: 861px) { .body.three.nolog { grid-template-columns: 272px minmax(0, 1fr); } }

/* Settings: an explanation folded under its setting. */
details.why { margin: -2px 0 4px; }
details.why > summary { cursor: pointer; font-size: 13px; color: var(--muted); list-style: none; width: fit-content; }
details.why > summary::-webkit-details-marker { display: none; }
details.why > summary::after { content: " ›"; }
details.why[open] > summary::after { content: " ⌄"; }
details.why > summary:hover { color: var(--text); }
details.why > p.note { margin: 6px 0 0; }
/* A failed answer, with its Try again button. */
.failbanner { display: flex; gap: 12px; align-items: center; }
.failbanner::before { align-self: flex-start; }

/* How a run turned out: a small word in its colour, before what happened. */
.autoout { display: inline-block; font-size: 13px; font-weight: 600; padding: 1px 8px; border-radius: 999px; border: 1px solid var(--line2); margin-right: 8px; color: var(--soft); white-space: nowrap; }
.autoout.ok { color: var(--accent-ink, var(--accent)); border-color: color-mix(in srgb, var(--accent) 40%, var(--line2)); }
.autoout.wait { color: var(--warn); border-color: color-mix(in srgb, var(--warn) 40%, var(--line2)); }
.autoout.bad { color: var(--bad-ink); border-color: color-mix(in srgb, var(--bad) 45%, var(--line2)); }
td.autonum .autoout { margin: 0 0 0 8px; }

/* Security: what holds whatever an agent is told. */
.guaranteelist { margin: 8px 0 0; padding: 0; list-style: none; display: grid; gap: 8px; }
.guaranteelist li { padding: 10px 14px; border: 1px solid var(--line); border-radius: 10px; background: var(--panel); color: var(--soft); font-size: 13.5px; }
.guaranteelist li b { color: var(--text); }
td.autonum .autoby { display: block; }

/* Backups: each one with its Restore button, and the line that says what is waiting. */
.backuplist { display: grid; gap: 6px; margin-top: 6px; }
.backuprow { padding: 8px 12px; border: 1px solid var(--line); border-radius: 10px; align-items: center; gap: 10px; }
.restorewait { display: flex; gap: 12px; align-items: center; }

/* ---------- choosing the AI model in the message box: a short list, the rest by typing ---------- */
.modelbtn { display: inline-flex; align-items: center; gap: 6px; max-width: 320px; padding: 5px 10px; border: 1px solid var(--line2); border-radius: 999px; background: transparent; color: var(--soft); font-size: 13px; min-height: 0; }
.modelbtn:hover { color: var(--text); border-color: var(--accent); }
.modelbtnname { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.modelmenu { position: fixed; z-index: 60; width: 360px; max-width: calc(100vw - 24px); max-height: min(520px, calc(100vh - 120px)); display: flex; flex-direction: column; gap: 8px; padding: 10px; border: 1px solid var(--line2); border-radius: 14px; background: var(--panel); box-shadow: var(--shadow-l); }
:root:not([data-theme="light"]) .modelmenu { background: #171918; }
.modelfind { width: 100%; }
.modellist { overflow-y: auto; min-height: 0; display: grid; gap: 2px; }
.modelgroup { font: 600 10.5px var(--sans); letter-spacing: 0.08em; text-transform: uppercase; color: var(--muted); padding: 8px 8px 2px; }
.modelrow { display: flex; align-items: center; border-radius: 8px; }
.modelrow:hover, .modelservice:hover { background: var(--surface-hover); }
.modelrow.on { background: var(--surface-selected); }
.modelrowmain { flex: 1; min-width: 0; display: flex; align-items: baseline; gap: 8px; padding: 7px 8px; border: 0; background: none; text-align: left; color: var(--text); font-size: 13.5px; min-height: 0; }
.modelrowname { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.modelrowby { color: var(--muted); font-size: 13px; white-space: nowrap; }
.modelrowon { margin-left: auto; color: var(--accent-ink, var(--accent)); font-size: 13px; font-weight: 600; white-space: nowrap; }
.modelstar { border: 0; background: none; color: var(--muted); padding: 4px 8px; min-height: 0; font-size: 14px; }
.modelstar.on, .modelstar:hover { color: var(--warn); }
.modelservice { display: flex; align-items: center; gap: 8px; width: 100%; padding: 7px 8px; border: 0; border-radius: 8px; background: none; color: var(--soft); font-size: 13.5px; text-align: left; min-height: 0; }
.modelnote { padding: 4px 8px; margin: 0; }
.modeladd { align-self: flex-start; padding: 2px 8px; }

/* =====================================================================
   Simpler screens: a rail with words, and pages that are one list.
   What needs the owner is first and in amber; one green button a page.
   ===================================================================== */
:root { --rail-width: 84px; }
.rail .railitem { width: 72px; height: auto; min-height: 0; padding: 8px 0 6px; flex-direction: column; gap: 4px; color: var(--soft); }
.rail .railitem .raillabel { font: 500 13px/18px var(--sans); white-space: nowrap; }
.rail .railitem.on { color: var(--text); }
/* New is a plain button here: the green is kept for the one thing to do on the page. */
.rail .railitem .count { top: 2px; right: 14px; }

.simplepage { max-width: 860px; margin: 0 auto; gap: 24px; padding-bottom: 48px; }
.simplepage.wide { max-width: 1000px; }
.simplehead { align-items: flex-start; gap: 16px; }
.simplehead h1 { margin: 0 0 4px; }
.simplehead .lead { margin: 0; }
.simplelabel { margin: 0; font: 600 13px/18px var(--mono); letter-spacing: 0.12em; text-transform: uppercase; color: var(--muted); }
.simplelabel.needs { color: var(--warn); }
.simpleask { display: flex; flex-direction: column; gap: 12px; padding: 16px; }
.simpleask input[type="text"] { height: 48px; font-size: 15px; }
.simpleasktools { align-items: center; gap: 12px; }
.simplechips { gap: 8px; }
.simplechip { height: 40px; padding: 0 16px; border: 1px solid var(--line); border-radius: 999px; background: transparent; color: var(--soft); font: 500 13px/20px var(--sans); }
.simplechip:hover { color: var(--text); }
.simplechip.on { background: var(--raised); color: var(--text); }
.simplelist { display: flex; flex-direction: column; gap: 20px; }
.simplegroup { display: flex; flex-direction: column; gap: 8px; }
.simplecard { border: 1px solid var(--line); border-radius: 12px; background: var(--panel); }
.simplerow { display: flex; align-items: center; gap: 10px; padding: 0 12px 0 0; border-bottom: 1px solid var(--line); }
.simplerow:last-child { border-bottom: 0; }
.simplerowmain { flex: 1; min-width: 0; display: flex; align-items: center; gap: 14px; padding: 14px 4px 14px 16px; text-align: left; color: var(--text); border-radius: 12px; min-height: 0; }
.simplerowmain:hover b { text-decoration: underline; text-underline-offset: 3px; }
.simplewords { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.simplewords b { font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.simplewords .note { margin: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.simplestate { font-size: 13px; line-height: 20px; color: var(--muted); white-space: nowrap; font-family: var(--mono); }
.simplestate.wait { color: var(--warn); font-weight: 600; font-family: var(--sans); }
.simplestate.ok { color: var(--accent-ink, var(--accent)); font-weight: 600; font-family: var(--sans); }
.simplestate.bad { color: var(--bad-ink); font-weight: 600; font-family: var(--sans); }
.simpletile { flex: 0 0 36px; height: 36px; border-radius: 9px; border: 1px solid var(--line2); background: var(--bg); display: grid; place-items: center; color: var(--soft); }
.simplespace { width: auto; max-width: 220px; }
.simplerow .sessmenu { position: relative; }
.simplerow .sessmenu { position: relative; right: auto; top: auto; transform: none; }
.simplerow .sessmenu > summary { opacity: 1; width: 32px; height: 32px; }
.rail .railitem .raillabel { text-transform: none; letter-spacing: 0; }
.rail .railitem { text-transform: none; letter-spacing: 0; }
.simplepage h2.simplelabel, .simplepage .simplelabel { font: 600 13px/18px var(--mono); letter-spacing: 0.12em; text-transform: uppercase; margin: 0; }
.simplewords b { color: var(--text); }

/* Tasks as a list. */
.simpletasks { max-width: 860px; }
.tasks:has(.simpletasks) { max-width: 860px; margin: 0 auto; }
.simplerow.on { background: var(--surface-selected); }
.simpletick { flex: 0 0 36px; text-align: center; color: var(--accent-ink, var(--accent)); font-weight: 700; }
.simplerowmain.done .simplewords span { color: var(--soft); }
.simpleempty { padding: 12px 16px; margin: 0; }
.simplemore { display: block; padding: 12px 16px; }
.simplecalm { margin: 0; }

/* Projects as cards. */
.projgrid { display: grid; grid-template-columns: repeat(auto-fill, minmax(340px, 1fr)); gap: 16px; }
.projcard { display: flex; flex-direction: column; gap: 14px; padding: 20px; margin: 0; }
.projcardhead h2 { margin: 0 0 4px; font-size: 20px; line-height: 28px; font-weight: 600; }
.projcardhead .note { margin: 0; }
.projprogress { display: grid; gap: 6px; }
.projbar { display: block; height: 6px; border-radius: 3px; background: var(--line); overflow: hidden; }
.projbar i { display: block; height: 6px; background: var(--text); }
.projfigures { font: 500 13px/20px var(--mono); color: var(--muted); }
.projstands { margin: 0; }
.projstands b { color: var(--text); }
.projstands .simplestate { font-family: var(--sans); }
.projcardend { align-items: center; gap: 12px; margin-top: auto; }
.projstart { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 8px; min-height: 200px; padding: 20px; border: 1px dashed var(--line2); border-radius: 12px; color: var(--soft); text-align: center; }
.projstart b { color: var(--text); }
.projstart .note { max-width: 260px; margin: 0; }
.projstart:hover { border-color: var(--accent); }

/* Team as cards. */
.persongrid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 16px; }
.personcard { display: flex; flex-direction: column; gap: 12px; padding: 16px; margin: 0; }
.personhead { display: flex; align-items: center; gap: 12px; text-align: left; padding: 0; min-height: 0; color: var(--text); }
.personname { display: flex; flex-direction: column; min-width: 0; }
.personname b { font-size: 16px; line-height: 24px; font-weight: 600; }
.personhead:hover .personname b { text-decoration: underline; text-underline-offset: 3px; }
.persondept { font: 600 13px/18px var(--mono); letter-spacing: 0.12em; text-transform: uppercase; }
.personnow { margin: 0; }
.personnow b { color: var(--text); }
.personnow .simplestate { font-family: var(--sans); }
.personend { align-items: center; gap: 12px; margin-top: auto; }
.personname b, .simplerowmain b { color: var(--text); }

/* Home: what is missing to get going. */
.simplesetslot:empty { display: none; }
/* Settings: what the owner uses. */
.usescard { display: grid; gap: 10px; }
.useslist { display: grid; gap: 4px; }
.usesrow { display: grid; grid-template-columns: 180px 1fr 40px; align-items: center; gap: 10px; font-size: 13px; }
.usesbar { height: 6px; border-radius: 3px; background: var(--line); overflow: hidden; }
.usesbar i { display: block; height: 6px; background: var(--soft); }
.usescount { text-align: right; font-family: var(--mono); color: var(--muted); }

/* Ready-made automations: the short shelf, then all of them. */
.briefshelf { margin-bottom: 8px; }
details.briefall { margin-top: 8px; }
details.briefall > summary { cursor: pointer; padding: 10px 0; list-style: none; color: var(--soft); }
details.briefall > summary::-webkit-details-marker { display: none; }
details.briefall > summary::after { content: " ›"; }
details.briefall[open] > summary::after { content: " ⌄"; }

/* Files: the pages for one kind, folded at the foot. */
details.filesfold > summary { cursor: pointer; color: var(--soft); list-style: none; font-size: 13.5px; }
details.filesfold > summary::-webkit-details-marker { display: none; }
details.filesfold > summary::after { content: " ›"; }
details.filesfold[open] > summary::after { content: " ⌄"; }
details.filesfold[open] > summary { margin-bottom: 8px; }

/* An open session: the way back to Home at its head. */
.backhome { color: var(--soft); font-size: 13px; padding: 4px 8px; border-radius: 8px; min-height: 0; white-space: nowrap; }
.backhome:hover { color: var(--text); background: var(--surface-hover); }
/* An agent's page: the look and the advanced settings fold away. */
details.lookfold { margin-top: 16px; width: 100%; }
details.lookfold > summary, details.agentmore > summary { cursor: pointer; list-style: none; color: var(--soft); font-size: 13.5px; }
details.lookfold > summary::-webkit-details-marker, details.agentmore > summary::-webkit-details-marker { display: none; }
details.lookfold > summary::after, details.agentmore > summary::after { content: " ›"; }
details.lookfold[open] > summary::after, details.agentmore[open] > summary::after { content: " ⌄"; }
details.agentmore { display: block; }
details.agentmore[open] > summary { margin-bottom: 12px; }
details.agentmore > * + * { margin-top: 10px; }

/* Add someone: the short list of jobs. */
.addmore { display: flex; align-items: center; gap: 4px; flex-wrap: wrap; }
.simplepage > input[type="search"] { height: 44px; }

/* =====================================================================
   A plain-words pass. Section labels are ordinary words in the reading
   face, not capitals in the code face; figures in a sentence are set in
   the reading face too. The code face is kept for figures that line up
   in a column (tables, receipts).
   ===================================================================== */
.simplepage h2.simplelabel, .simplepage .simplelabel { font: 600 13.5px/20px var(--sans); letter-spacing: 0; text-transform: none; color: var(--soft); }
.simplepage h2.simplelabel.needs, .simplepage .simplelabel.needs { color: var(--warn); }
.persondept { font: 500 13px/18px var(--sans); letter-spacing: 0; text-transform: none; }
.simplestate, .projfigures { font-family: var(--sans); font-variant-numeric: tabular-nums; }

/* =====================================================================
   The rest of the app follows the brand guide's type rules: a label is
   ordinary words in the reading face, never capitals or letter-spacing;
   the code face is for code, and for figures that line up in a column.
   ===================================================================== */
.label, .acctlabel, .modelgroup, .sidelabel, .memnote .mlabel, .listlabel, .grouplabel, .dhead, .repoline, .receipt h3, .rtotals span, .rmark,
.frow.fheadrow, .posrow.head, .whychain .whykind, .taskpri, .briefmark, .inboxkind, .autotable th, .briefstate {
  text-transform: none; letter-spacing: 0; font-family: var(--sans);
}
.label, .acctlabel, .modelgroup, .sidelabel, .listlabel, .grouplabel { font-size: 13px; font-weight: 600; }
.autotable th, .dhead, .frow.fheadrow, .posrow.head, .receipt h3 { font-size: 13px; font-weight: 600; }
/* Words that were set in the code face only for the look of it. */
.chip, .pill, .tabs button, .member .type, .member .status, .qcard .now, .qcard .foot, .logitem .meta, .portrait .type, .approval strong,
.mfoot .mono, .mcard .mono, .core-card .mono, summary .what { font-family: var(--sans); }
/* A department's name is quiet text in both looks; its colour is on the agent's tile. */
.persondept { color: var(--muted); }

/* A link in the account menu (Follow us on X) looks like the rows around it. */
a.acctrow { text-decoration: none; box-sizing: border-box; }
a.acctrow:hover { text-decoration: none; }

/* A task's panel: one line of who and when, one button, and the rest folded under Details. */
.taskline { margin: -4px 0 2px; font-size: 13.5px; }
.taskpanelhead .tasknum { color: var(--muted); font-size: 13px; }
.taskmenu .automenulist { z-index: 50; }
.taskmore { margin-top: 8px; border-top: 1px solid var(--line); padding-top: 8px; }
.taskmore > summary { cursor: pointer; color: var(--muted); font-size: 13.5px; font-weight: 600; }
.taskmore > summary:hover { color: var(--text); }
.taskmore[open] > summary { margin-bottom: 8px; }
.composeform .taskmore { display: grid; gap: 10px; }
/* Group headings are ordinary words everywhere, the Tasks list included. */
h2.simplelabel, .simplelabel { font: 600 13.5px/20px var(--sans); letter-spacing: 0; text-transform: none; color: var(--soft); }
h2.simplelabel.needs, .simplelabel.needs { color: var(--warn); }

/* A project's page is one column: what it covers, what needs you, then its tasks, files and sessions. */
.projectspage > h2.simplelabel { margin: 18px 0 6px; }
.projectspage .label.needs { color: var(--warn); }
.projectend { margin-top: 22px; padding-top: 12px; border-top: 1px solid var(--line); }

/* Labs: where a set-aside part will live. */
.labhome { display: block; font-style: normal; }

/* Apps: a tile for each app, and the bar that says which app you are in. */
.appgrid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 12px; margin: 8px 0 14px; }
.appicon { flex: none; width: 44px; height: 44px; border-radius: 11px; background: #0a0a0a; border: 1px solid #2a2a2a; color: #f2f2f2; display: grid; place-items: center; }
.appicon .ico { display: inline-flex; color: inherit; }
.appnext { margin-top: 4px; }
.appback { color: var(--muted); font-size: 13.5px; padding: 0 4px; min-height: 0; }
.appback:hover { color: var(--text); }
.appsep { color: var(--muted); padding: 0 2px; }
.appspage h2.simplelabel { margin-top: 6px; }

/* Contacts, and an app waiting to be added. */
.simpletile.initials { font-size: 13px; font-weight: 600; color: var(--soft); }
.simplewhen { flex: none; padding-right: 4px; }
.addapp .taskfacts { grid-template-columns: 120px minmax(0, 1fr); align-items: start; }

/* The two bars at the top are the same on every page: the search bar, then (where a place has parts) one row of tabs.
   Neither may be squeezed by the page under it, which is what clipped the selected tab. */
.main > .top, .main > .areatabs { flex: none; }
.areatabs { min-height: 48px; padding: 0 20px; gap: 6px; background: var(--bg); border-bottom: 1px solid var(--line); }
.areatab, .appback { font-size: 13.5px; line-height: 20px; padding: 5px 12px; min-height: 32px; border-radius: 999px; }
.areatab { color: var(--soft); border: 1px solid transparent; }
.areatab:hover, .appback:hover { background: var(--surface-hover); color: var(--text); }
.areatab.on { background: var(--raised); border-color: var(--line); color: var(--text); font-weight: 600; }
.appback { color: var(--muted); }
.appsep { color: var(--muted); padding: 0; }
@media (max-width: 720px) { .areatabs { padding: 0 10px; } }

/* Connections: a status page. A row for what is connected, tiles for what to add. */
.connrow { display: flex; align-items: center; gap: 12px; padding: 0 14px 0 0; border-bottom: 1px solid var(--line); }
.connrow:last-child { border-bottom: 0; }
.connrow.quiet { border: 1px dashed var(--line2); border-radius: 12px; margin-top: 8px; }
.connmain { flex: 1; min-width: 0; display: flex; align-items: center; gap: 14px; padding: 12px 4px 12px 14px; text-align: left; color: var(--text); min-height: 0; border-radius: 12px; }
button.connmain:hover b { text-decoration: underline; text-underline-offset: 3px; }
.connwords { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.connwords b { font-weight: 600; }
.connwords .note { margin: 0; }
.connrow.bad .connwords .note { color: var(--bad, #b42318); }
.connlinks { margin: 2px 0 0; }
.connall { display: grid; gap: 14px; }
.integrations > .simplelabel { margin: 14px 0 -4px; }
.integrations .isearch { width: 100%; }
/* A problem that needs the owner: a dot on the account button. */
.acctbutton.alert { position: relative; }
.acctbutton.alert::after { content: ""; position: absolute; top: -1px; right: -1px; width: 10px; height: 10px; border-radius: 50%; background: var(--bad, #b42318); border: 2px solid var(--bg); }

/* One connection: a question in three sentences, who uses it, and the rest folded. */
.conntwo { display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr); gap: 16px; }
@media (max-width: 760px) { .conntwo { grid-template-columns: 1fr; } }
.connside { display: flex; flex-direction: column; gap: 8px; min-width: 0; }
.rulechoice { display: flex; gap: 10px; align-items: flex-start; padding: 10px 12px; border: 1px solid var(--line); border-radius: 10px; cursor: pointer; }
.rulechoice.on { border-color: var(--accent-text, #007a3d); background: var(--surface-hover); }
.rulechoice input { margin-top: 4px; flex: none; }
.rulechoice span { display: flex; flex-direction: column; }
.rulechoice b { font-weight: 600; }
.connmini { display: grid; gap: 6px; font-size: 13.5px; }
.connmini div { display: flex; justify-content: space-between; gap: 10px; }
.connmini em { font-style: normal; color: var(--muted); white-space: nowrap; }
.connmore > summary { cursor: pointer; color: var(--muted); font-size: 13.5px; font-weight: 600; padding: 4px 0; }
.connmore[open] > summary { margin-bottom: 8px; }
.connpromise p { margin: 0; }
/* Marks on the Connections page are tiles, like the agents'. */
.connrow .packicon.conn { flex: none; width: 34px; height: 34px; border-radius: 9px; background: #0a0a0a; color: #f2f2f2; display: grid; place-items: center; font: 600 13px/1 var(--sans); border: 1px solid #2a2a2a; }
.integrations input.isearch { width: 100%; max-width: none; box-sizing: border-box; }
.conncard label.rulechoice { flex-direction: row; align-items: flex-start; gap: 10px; font-weight: 400; }
.conncard label.rulechoice input { width: auto; min-height: 0; margin: 4px 0 0; }
.connrow .chip.bad { color: var(--bad, #b42318); border-color: currentColor; }

/* The Activity log: a diary. A line per thing, under the day it happened. */
.activityhead { align-items: flex-start; gap: 10px; }
.activityhead h1 { margin: 0 0 4px; }
.activityfind { width: 100%; max-width: none; box-sizing: border-box; }
.activitychips { align-items: center; margin: 0; }
.activitychips .chip.bad { color: var(--bad, #b42318); border-color: currentColor; }
.activitysince { width: auto; }
.activityrow { border-bottom: 1px solid var(--line); }
.activityrow:last-child { border-bottom: 0; }
.activityrow > summary { list-style: none; cursor: pointer; display: flex; align-items: center; gap: 12px; padding: 11px 14px; }
.activityrow > summary::-webkit-details-marker, .activityone > summary::-webkit-details-marker { display: none; }
.activityrow > summary:hover { background: var(--surface-hover); }
.activityrow.bad .activitywords b { color: var(--bad, #b42318); }
.activitytime { flex: none; width: 66px; color: var(--muted); font-size: 13px; font-variant-numeric: tabular-nums; }
.activityface { flex: none; display: inline-flex; }
.activityface.you { width: 28px; height: 28px; border-radius: 8px; border: 1px solid var(--line2); background: var(--bg); color: var(--soft); align-items: center; justify-content: center; font-size: 10px; font-weight: 600; }
.activitywords { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.activitywords b { font-weight: 600; overflow-wrap: anywhere; }
.activitywords .note { margin: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.activitycost { flex: none; color: var(--muted); font-size: 13px; font-variant-numeric: tabular-nums; }
.activityfull { padding: 4px 14px 14px 92px; display: flex; flex-direction: column; gap: 10px; }
.activitymany { padding: 0 14px 12px 92px; display: grid; gap: 2px; }
.activityone > summary { list-style: none; cursor: pointer; display: flex; gap: 12px; padding: 5px 0; font-size: 13.5px; }
.activityone .activityfull { padding: 4px 0 10px 78px; }
.activityraw { margin: 0; padding: 10px 12px; border-radius: 8px; background: var(--bg); border: 1px solid var(--line); font: 13px/18px var(--mono); white-space: pre-wrap; overflow-wrap: anywhere; }
.activityseal { margin-top: 4px; }
@media (max-width: 720px) { .activityfull, .activitymany { padding-left: 14px; } }

/* Security for one owner: a sentence, then protections with their control on the same line. */
.sechead { align-items: center; }
.sechead h1 { margin: 0; }
.secstop { color: var(--bad, #b42318); border-color: currentColor; background: none; }
.secline { display: flex; align-items: center; gap: 14px; padding: 12px 16px; border-bottom: 1px solid var(--line); }
.secline:last-child { border-bottom: 0; }
.seclinewords { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.seclinewords b { font-weight: 600; }
.seclinewords .note { margin: 0; }
.seclimitrow { align-items: center; gap: 6px; flex: none; }
input.seclimit { width: 74px; }
.secbody { display: flex; flex-direction: column; gap: 14px; }
.secbody > .simplelabel { margin: 4px 0 -6px; }
.security.integrations > .simplechips { margin: 0; }
.activityface.you { flex: 0 0 28px; padding: 0; }
.activitypage > .simplelabel { margin: 10px 0 -14px; }

/* Usage: the amount and how it stands first, then where it went. */
.usagehead { align-items: center; gap: 10px; }
.usagehead h1 { margin: 0; }
.usagehead .simplechips { margin: 0; }
.usagetop { padding: 16px 18px; display: flex; flex-direction: column; gap: 10px; }
.usagebig { display: flex; align-items: baseline; gap: 12px; flex-wrap: wrap; }
.usagebig b { font: 600 34px/38px var(--display, var(--sans)); letter-spacing: -0.02em; font-variant-numeric: tabular-nums; }
.usagebig span { color: var(--soft); }
.usagemeter { height: 10px; border-radius: 999px; background: var(--raised); overflow: hidden; }
.usagemeter i { display: block; height: 100%; border-radius: 999px; background: var(--accent, #00d26a); }
.usagemeter.warn i { background: var(--warn, #9a6200); }
.usagemeter.bad i { background: var(--bad, #b42318); }
.usagefoot { align-items: center; gap: 10px; }
.usagefoot .note { margin: 0; }
.usagepeak { text-align: center; }
.usagetwo { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 14px; }
.usagebox { padding: 14px 16px; display: flex; flex-direction: column; gap: 10px; }
.usagebars { display: grid; gap: 8px; font-size: 13.5px; }
.usagebars div { display: grid; grid-template-columns: minmax(0, 170px) minmax(0, 1fr) 62px; align-items: center; gap: 10px; }
.usagebars span { color: var(--soft); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.usagebars i { height: 8px; border-radius: 999px; background: var(--text); opacity: 0.8; }
.usagebars em { font-style: normal; text-align: right; font-variant-numeric: tabular-nums; }
.usagedays { display: flex; align-items: flex-end; gap: 3px; height: 76px; border-bottom: 1px solid var(--line); }
.usagedays i { flex: 1; background: var(--accent-text, #007a3d); border-radius: 3px 3px 0 0; opacity: 0.85; min-width: 2px; }
.usagepage > .simplelabel { margin: 4px 0 -12px; }

/* Settings: one line per setting, and questions answered by picking a sentence. */
.pickgrid { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 14px; }
.pickcard { padding: 14px 16px; display: flex; flex-direction: column; gap: 8px; }
.pickone { display: flex; gap: 10px; align-items: flex-start; padding: 10px 12px; border: 1px solid var(--line); border-radius: 10px; cursor: pointer; font-weight: 400; }
.pickone.on { border-color: var(--accent-text, #007a3d); background: var(--surface-hover); }
.pickone input { width: auto; min-height: 0; margin: 4px 0 0; flex: none; }
.pickone > span { display: flex; flex-direction: column; }
.pickone b { font-weight: 600; }
input.setname { width: 180px; }
.setaccent { flex: none; }
.setcheck { margin: -8px 0 0; }
.settings > .simplelabel, .page > .simplelabel { margin: 10px 0 -6px; }

/* Tasks: the list is a reading column, the same width as the Team page. */
.tasks.narrow { max-width: 1000px; width: 100%; }
.tasks-head .lead b { color: var(--text); font-weight: 600; }
.simplecount { color: var(--muted); font-weight: 500; }
/* The box where work is asked for. */
.askwrap { display: flex; flex-direction: column; gap: 10px; }
.askbox { display: flex; flex-direction: column; gap: 8px; padding: 12px 14px; border: 1.5px solid var(--text); border-radius: 12px; background: var(--panel); }
.askbox:focus-within { border-color: var(--accent-ink, var(--accent)); }
.asktext { border: 0; background: none; padding: 2px 0; font: inherit; font-size: 15px; line-height: 24px; resize: none; min-height: 48px; color: var(--text); outline: none; box-shadow: none; }
.asktext:focus { outline: none; box-shadow: none; }
.askfoot { align-items: center; gap: 8px; }
.askwho, .askdue, .askmodel { height: 32px; font-size: 13px; padding: 0 10px; border-radius: 999px; width: auto; max-width: 220px; }
.askfacts .secline .keychar { flex: none; }
/* How far a task has got. */
.taskbar { flex: none; width: 88px; height: 6px; border-radius: 3px; background: var(--line); overflow: hidden; }
.taskbar i { display: block; height: 100%; border-radius: 3px; background: var(--accent); }
.taskbar.unknown i { background: repeating-linear-gradient(90deg, var(--accent) 0 8px, transparent 8px 14px); opacity: 0.7; }
.taskbar[aria-hidden] { visibility: hidden; }
.taskstate { min-width: 62px; text-align: right; }
.duelate { color: var(--bad-ink); font-weight: 600; }
.tasktrack { display: grid; grid-auto-flow: column; grid-auto-columns: 1fr; gap: 6px; }
.tasktrack div { border-top: 3px solid var(--line); padding-top: 6px; font: 500 13px/18px var(--sans); color: var(--muted); }
.tasktrack .was { border-color: var(--accent); color: var(--soft); }
.tasktrack .now { border-color: var(--text); color: var(--text); font-weight: 600; }
.taskcost { font-variant-numeric: tabular-nums; }
@media (max-width: 720px) { .taskbar { display: none; } }

/* Team: cards grouped by who leads whom; a card waiting for the owner has an amber edge. */
.personcard.needs { border-color: var(--warn); }
.persongroup { margin: 6px 0 -12px; }
button.personadd { display: flex; flex-direction: column; align-items: flex-start; justify-content: center; gap: 4px; padding: 16px; border: 1px dashed var(--line); border-radius: 12px; text-align: left; color: var(--text); min-height: 120px; }
button.personadd:hover { border-color: var(--text); }
/* One person: their work on the left, what is set once on the right. */
.personcrumb { margin: 0 0 -10px; }
.personhero { align-items: center; gap: 14px; }
.personheroname { display: flex; flex-direction: column; min-width: 0; }
.personheroname h1 { margin: 0; }
.persontwo { display: grid; grid-template-columns: minmax(0, 1.5fr) minmax(0, 1fr); gap: 20px; align-items: start; }
.personcol { display: flex; flex-direction: column; gap: 12px; min-width: 0; }
.personcol > .simplelabel { margin: 6px 0 -4px; }
.personcol .simplerowmain { padding-left: 16px; }
.personbox { display: flex; flex-direction: column; gap: 8px; padding: 14px 16px; margin: 0; }
.personfacts { display: grid; gap: 6px; font-size: 13.5px; line-height: 20px; color: var(--soft); }
.personfacts > div { display: flex; justify-content: space-between; gap: 12px; }
.personfacts em { font-style: normal; color: var(--muted); text-align: right; font-variant-numeric: tabular-nums; }
.personjob { margin: 0; }
@media (max-width: 860px) { .persontwo { grid-template-columns: minmax(0, 1fr); } }

.tasks.narrow .simplelist { max-width: none; }

/* ===== One page frame =====
   Every page has the same width, the same heading and the same tabs, so nothing jumps when moving between pages.
   The task board and the organization chart are the two exceptions: they use the whole window. */
.center > .col.page, .center > .simplepage, .center > .simplepage.wide, .center > .integrations, .center > .inbox2, .center > .tasks.narrow { max-width: 960px; width: 100%; margin-left: auto; margin-right: auto; }
.center > .inbox2, .center > .simplepage.appspage { padding-top: 0; }
main.center h1:not(.md h1, .ProseMirror h1, .chathead h1, .subhead h1) { font: 600 24px/30px var(--display, var(--sans)); letter-spacing: -0.02em; margin: 0 0 4px; }
main.center p.lead { font-size: 14.5px; line-height: 22px; color: var(--soft); max-width: 72ch; margin: 0; }
main.center p.lead b { color: var(--text); font-weight: 600; }

/* One kind of tab inside a page: a pill. The one that is on is filled, like the tabs at the top of the window. */
.simplechips > .chip, .simplechip, .autotab, .inboxtab, .fileskinds .mpill, .spacetabs button[role="tab"], .segmented button {
  height: 34px; min-height: 34px; padding: 0 14px; border: 1px solid var(--line); border-radius: 999px; background: none; color: var(--soft);
  font: 500 13px/20px var(--sans); box-shadow: none; display: inline-flex; align-items: center; gap: 6px; white-space: nowrap;
}
.simplechips > .chip:hover, .simplechip:hover, .autotab:hover, .inboxtab:hover, .fileskinds .mpill:hover, .spacetabs button[role="tab"]:hover, .segmented button:hover { color: var(--text); border: 1px solid var(--line2); background: none; }
.simplechips > .chip.on, .simplechip.on, .autotab.on, .inboxtab.on, .fileskinds .mpill.on, .spacetabs button.on, .segmented button.on, .segmented button.on:last-child {
  background: var(--raised); border-color: var(--line2); color: var(--text); font-weight: 600; box-shadow: none;
}
.segmented { border: 0; border-radius: 0; overflow: visible; gap: 6px; margin-top: 0; }
.segmented button + button { border-left: 1px solid var(--line); }
.segmented button.on + button, .segmented button + button.on { border-left-color: var(--line2); }
.autotabs, .inboxtabs, .spacetabs { gap: 6px; }
.simplechips > .chip.bad { border-style: dashed; color: var(--bad-ink); }
.simplechips > .chip.warn { color: var(--warn); }

/* Things to press are at least 32px tall. */
button.small, .center select, .center input[type="number"], .center input[type="date"] { min-height: 32px; }
.swatch { width: 30px; height: 30px; }

/* The logo's black tile needs an edge on a black window. */
:root:not([data-theme="light"]) .logo-mark { border-radius: 25%; box-shadow: 0 0 0 1px var(--line2); }

.askduelabel { display: inline-flex; align-items: center; gap: 8px; white-space: nowrap; font-size: 13px; color: var(--soft); }
.center > .inbox2 { padding: 0 0 60px; }
.packicon.conn { font-size: 13px; letter-spacing: -0.02em; }
.autocount { font-size: 13px; }

.orghead .personcrumb { margin: 0 0 4px; }

/* An opened task sits beside the list, not over it, when the window is wide enough for both. */
@media (min-width: 1100px) { .body:has(> .taskpanel:not([hidden])) > main.center { padding-right: 496px; } }

/* Repeating work: rows like Tasks, each with its switch and its menu. */
.autorow { padding-right: 12px; gap: 12px; }
.autorow.paused .simplewords b { color: var(--muted); }
.autorowmain { cursor: default; align-items: flex-start; }
.autorowmain .simplewords .note { white-space: normal; }
.autocost { display: flex; flex-direction: column; align-items: flex-end; text-align: right; }
.autolist .autoedit { border-bottom: 1px solid var(--line); }
/* The chart's buttons, now that its counts are said in the opening sentence. */
.orgstrip { justify-content: flex-end; }
.simplelabel .labellink { margin-left: 10px; font-weight: 500; }

.officeask { display: flex; flex-direction: column; gap: 8px; margin-top: 12px; }
.orgstrip { border: 0; background: none; padding: 0; box-shadow: none; }

/* Home: what needs you, the first-day steps, and things to try. */
.homeneeds { border-color: var(--warn); }
.homeneedslot:empty, .simplesetslot:empty { display: none; }
.homestepmark { flex: none; width: 26px; height: 26px; border-radius: 50%; border: 1.5px solid var(--line2); display: grid; place-items: center; font: 600 12.5px/1 var(--sans); color: var(--muted); }
.homestep.done .homestepmark { background: var(--accent); border-color: var(--accent); color: var(--on-accent); }
.homestep.now .homestepmark { border-color: var(--text); color: var(--text); }
.homestep.done .seclinewords b { color: var(--soft); font-weight: 500; }
.hometries { gap: 6px; margin-top: -8px; }
.chip.hometry { height: 32px; padding: 0 12px; border: 1px solid var(--line); border-radius: 999px; background: var(--panel); color: var(--soft); font: 500 13px/20px var(--sans); cursor: pointer; }
.chip.hometry:hover { color: var(--text); border-color: var(--line2); }
/* Inbox: what kind of thing a row is, said in plain words; updates under their day. */
.inboxkind { display: inline-block; font: 600 12.5px/18px var(--sans); letter-spacing: 0; text-transform: none; padding: 2px 8px; border-radius: 6px; margin-right: 8px; background: color-mix(in srgb, var(--warn) 14%, transparent); color: var(--warn); }
:root[data-theme="light"] .inboxkind { color: var(--warn); }
.inboxkind.fix { background: color-mix(in srgb, var(--bad) 12%, transparent); color: var(--bad-ink); }
:root[data-theme="light"] .inboxkind.fix { color: var(--bad-ink); }
.inboxnews { flex: none; font: 500 12.5px/18px var(--sans); padding: 2px 8px; border-radius: 6px; background: var(--raised); color: var(--soft); white-space: nowrap; }
.inboxday { margin: 12px 0 6px; }
.inboxday:first-child { margin-top: 0; }
.inboxtools { margin-left: auto; }
.inboxhead .lead:empty { display: none; }
.inboxkind { justify-self: start; width: fit-content; }
.inbox2.deciding .inboxlist { max-width: none; }

/* Apps: a card for each app, with what happened in it lately. */
.appcard { display: flex; flex-direction: column; gap: 10px; padding: 16px; margin: 0; }
.appcardtop { align-items: center; gap: 12px; }
.appcardtop b { font: 600 17px/24px var(--display, var(--sans)); letter-spacing: -0.01em; }
.appcard .note { margin: 0; }
.appnews { display: grid; gap: 3px; padding-top: 10px; border-top: 1px solid var(--line); font-size: 13px; line-height: 19px; color: var(--muted); }
.appnews .first { color: var(--soft); font-weight: 600; }
.appcard.soon { border-style: dashed; background: none; }
.appcard.soon b { color: var(--soft); }
.appicon.dim { background: var(--raised); border-color: var(--line); color: var(--muted); }
.appgrid { grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); }
.appmay { margin: 0; padding-left: 18px; }
.appmay li { margin: 2px 0; }
/* An app's own screens: a sealed frame that fills the page. */
.body.appframebody { grid-template-columns: minmax(0, 1fr); }
.body.appframebody > .appframe { width: 100%; height: 100%; border: 0; display: block; background: transparent; color-scheme: normal; }
/* Files: one button to add, rows with a picture for each sort of file. */
.fileshead { align-items: flex-start; gap: 16px; }
.fileshead .lead { margin: 0; }
.newmenu { position: relative; }
.newmenu > summary { list-style: none; cursor: pointer; display: inline-flex; align-items: center; height: 36px; width: auto; padding: 0 18px; border-radius: 10px; background: var(--grad-accent, var(--accent)); color: var(--on-accent); font: 600 13.5px/20px var(--sans); opacity: 1; }
.newmenu > summary::-webkit-details-marker { display: none; }
.newmenulist { right: 0; left: auto; width: 300px; padding: 6px; }
.newway { display: flex; flex-direction: column; align-items: flex-start; gap: 1px; width: 100%; text-align: left; padding: 8px 10px; border-radius: 8px; min-height: 0; }
.newway:hover { background: var(--raised); }
.newway b { font-weight: 600; color: var(--text); }
.fileicon { flex: none; width: 28px; height: 34px; border-radius: 5px; border: 1.5px solid var(--muted); background: var(--panel); position: relative; }
.fileicon::after { content: ""; position: absolute; left: 5px; right: 5px; top: 9px; height: 1.5px; background: var(--muted); box-shadow: 0 6px 0 var(--muted), 0 12px 0 var(--muted); opacity: 0.55; }
.fileicon.pdf { border-color: var(--bad); }
.fileicon.numbers { border-color: var(--accent-ink, var(--accent)); }
.fileicon.picture::after { top: 16px; box-shadow: none; height: 8px; border-radius: 2px; }
.fileslist > input[type="search"] { margin-bottom: 10px; width: 100%; height: 40px; }
.officehomepage.dropping { outline: 2px dashed var(--accent); outline-offset: 8px; border-radius: 12px; }
.appspage .lead { margin-bottom: 12px; }

/* An open file: the page is the writing. The list of other files is closed to begin with. */
.body.wsbody.noside { grid-template-columns: minmax(0, 1fr); }
.body.wsbody.noside > .wsside { display: none; }
.filebar { align-items: center; gap: 8px; max-width: 1180px; margin: 0 auto 14px; }
.filebar button.on { background: var(--raised); border-color: var(--line2); color: var(--text); }
.wspage { grid-template-columns: minmax(0, 1fr) 340px; }
.wspage.nodetails { max-width: 820px; }
.fileside { gap: 16px; padding: 0; border: 0; background: none; box-shadow: none; }
.filebox { display: flex; flex-direction: column; gap: 10px; }
.card.filebox { padding: 14px; margin: 0; }
.filefold { display: flex; flex-direction: column; gap: 8px; padding-top: 8px; }
.pickone.off { opacity: 0.55; }
.wswhy { margin: 0; color: var(--soft); }
.fileside .wssuggestion { margin: 0; }
/* The toolbar, in words. */
.wstool.wsword, .wsmoretools > summary.wsword { min-width: 0; width: auto; height: 30px; padding: 0 9px; font: 500 13px/20px var(--sans); color: var(--soft); border-radius: 8px; opacity: 1; display: inline-flex; align-items: center; }
.wstool.wsword:hover, .wsmoretools > summary.wsword:hover { background: var(--raised); color: var(--text); }
.wstoolsep { width: 1px; height: 18px; margin: 0 6px; background: var(--line); }
.wswords { flex-wrap: wrap; row-gap: 4px; }
.wsmoretools { position: relative; }
.wsmoretools > summary { list-style: none; cursor: pointer; }
.wsmoretools > summary::-webkit-details-marker { display: none; }

/* Connections: how things stand, what stopped, and adding by what you want done. */
.connhead { align-items: flex-start; gap: 16px; }
.connhead .lead { margin: 0; }
.connstopped { display: flex; align-items: center; gap: 12px; padding: 12px 14px; border: 1px solid var(--bad); border-radius: 12px; background: color-mix(in srgb, var(--bad) 8%, var(--panel)); }
.connstopped .connwords { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.connask { margin: 0 0 8px; }
.connwants { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 12px; }
.connwant { display: flex; flex-direction: column; gap: 6px; padding: 14px; border: 1px solid var(--line); border-radius: 12px; background: var(--panel); }
.connwith { gap: 6px; margin-top: 6px; }
.connpick { display: inline-flex; align-items: center; gap: 8px; padding: 0 10px 0 4px; }
.connpick .packicon { width: 24px; height: 24px; border-radius: 7px; font-size: 10.5px; }
.connpick > :first-child { flex: none; width: 24px; height: 24px; display: inline-grid; place-items: center; line-height: 1; margin: 0; }
.connpick { height: 34px; }

/* Activity log: a piece of work is one entry; what did not work says what happened and what to do. */
.activitybad { color: var(--bad-ink); font-weight: 600; }
.activityshow { flex: none; white-space: nowrap; }
.activityone.bad > summary { color: var(--bad-ink); }
.activitytrouble { display: flex; flex-direction: column; gap: 10px; padding: 14px; border: 1px solid var(--bad); border-radius: 12px; background: color-mix(in srgb, var(--bad) 7%, var(--panel)); }
.activitytrouble p { margin: 0; font-size: 14px; line-height: 22px; color: var(--soft); }
.activitytrouble p b { color: var(--text); }
.activityproof { display: flex; flex-direction: column; gap: 12px; }
.activityintact { border: 1px solid var(--accent); border-radius: 12px; background: color-mix(in srgb, var(--accent) 8%, var(--panel)); }
.activityintact.bad { border-color: var(--bad); background: color-mix(in srgb, var(--bad) 7%, var(--panel)); }

/* Security: how protected the owner is, rules as questions, and when the last backup was. */
.secmeter { height: 8px; border-radius: 4px; background: var(--line); overflow: hidden; }
.secmeter i { display: block; height: 100%; border-radius: 4px; background: var(--accent); }
.secabove { margin: 0; }
.secbackup { border: 1px solid var(--warn); border-radius: 12px; background: color-mix(in srgb, var(--warn) 8%, var(--panel)); }
.secbackup.ok { border-color: var(--accent); background: color-mix(in srgb, var(--accent) 8%, var(--panel)); }
.secbackuptop:empty { display: none; }
.secbody .pickgrid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
@media (max-width: 760px) { .secbody .pickgrid { grid-template-columns: minmax(0, 1fr); } }

/* Add someone: the public catalogue, under the short list */
.cataloguebox { margin-top: 32px; padding-top: 24px; border-top: 1px solid var(--line); display: flex; flex-direction: column; gap: 12px; }
.cataloguebox h2 { margin: 0; font-size: 18px; }
.cataloguebox .card p { margin: 0 0 12px; }

/* ---------- Help: the user guide as a page of its own ----------
   Guides on the left, one guide in the middle at a width that reads well (about 70 characters a line), its headings
   on the right. Every colour is a token, so each palette, light and dark, carries over. */
.body.helpbody { grid-template-columns: minmax(0, 1fr); }
.helppage { display: flex; flex-direction: column; min-height: 0; }
.helphead { position: sticky; top: 0; z-index: 5; display: flex; flex-wrap: wrap; align-items: center; gap: 12px 24px; padding: 14px 32px; background: var(--bg); border-bottom: 1px solid var(--line); }
.helphead .helptitle { display: flex; align-items: baseline; gap: 10px; padding: 0; min-height: 44px; }
.helphead .helptitle:hover { background: none; }
.helpname { font: 700 22px/28px var(--round); letter-spacing: -0.01em; color: var(--text); }
.helpsub { font-size: 14px; color: var(--muted); }
.helpfind { flex: 1 1 320px; max-width: 560px; margin-left: auto; display: flex; align-items: center; gap: 10px; height: 46px; padding: 0 12px 0 14px; border: 1px solid var(--line2); border-radius: 12px; background: var(--field); color: var(--muted); }
.helpfind:focus-within { border-color: var(--accent-ink, var(--accent)); }
.helpfind input { flex: 1; min-width: 0; height: 100%; padding: 0; border: 0; background: none; box-shadow: none; font: 400 16px/1 var(--round); color: var(--text); }
.helpfind input:focus { border: 0; box-shadow: none; }
.helpfind input::placeholder { color: var(--muted); }
.helpfind kbd { font: 500 12px/1 var(--mono); padding: 3px 7px; border: 1px solid var(--line2); border-bottom-width: 2px; border-radius: 5px; background: var(--raised); color: var(--muted); }
.helpcols { display: flex; flex-wrap: wrap; align-items: flex-start; flex: 1; }
.helpnav { position: sticky; top: 75px; max-height: calc(100vh - 150px); overflow-y: auto; flex: 1 1 220px; max-width: 270px; display: flex; flex-direction: column; gap: 18px; padding: 24px 14px 48px 24px; }
.helpgroup { display: flex; flex-direction: column; gap: 1px; }
.helpgrouplabel { font: 600 11.5px/16px var(--round); letter-spacing: 0.08em; text-transform: uppercase; color: var(--muted); padding: 0 12px 6px; }
.helpnav .helpnavitem { display: block; width: 100%; min-height: 36px; padding: 8px 12px; border: 0; border-radius: 8px; background: none; text-align: left; font: 400 15px/20px var(--round); color: var(--soft); }
.helpnav .helpnavitem:hover { background: var(--surface-hover); color: var(--text); }
.helpnav .helpnavitem.on { background: var(--surface-selected); color: var(--text); font-weight: 600; }
.helpmain { flex: 999 1 520px; min-width: 0; padding: 32px 40px 96px; border-left: 1px solid var(--line); font-family: var(--round); }
.helpmain h1 { margin: 0 0 10px; font: 700 34px/42px var(--round); letter-spacing: -0.02em; color: var(--text); }
.helpmain section h2 { margin: 0 0 14px; font: 600 18px/24px var(--round); }
.helplead { margin: 0 0 28px; font-size: 19px; line-height: 30px; color: var(--soft); max-width: 62ch; }
.helphome { max-width: 960px; display: flex; flex-direction: column; gap: 36px; }
.helphome .helplead { margin: 0; }
.helphome h1 { margin-bottom: 8px; }
.helpcards { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 12px; }
.helpmain .helpcard { display: flex; flex-direction: column; align-items: flex-start; gap: 6px; height: auto; padding: 18px 20px; border: 1px solid var(--line); border-radius: 12px; background: var(--panel); text-align: left; font-family: var(--round); }
.helpmain .helpcard:hover { border-color: var(--line2); background: var(--raised); }
.helpcard b { font-size: 16px; line-height: 22px; color: var(--text); }
.helpcard > span:last-child { font-size: 14px; line-height: 21px; color: var(--soft); }
.helpnew { font-size: 11.5px; font-weight: 600; letter-spacing: 0.06em; text-transform: uppercase; color: var(--accent-ink, var(--accent)); }
.helpasked { display: flex; flex-direction: column; border-top: 1px solid var(--line); }
.helpmain .helprow { display: flex; align-items: center; justify-content: space-between; gap: 16px; width: 100%; min-height: 52px; padding: 12px 6px; border: 0; border-bottom: 1px solid var(--line); border-radius: 0; background: none; text-align: left; font: 400 16px/24px var(--round); color: var(--text); }
.helpmain .helprow:hover { background: var(--surface-hover); }
.helpwhere { font-size: 13px; line-height: 18px; color: var(--muted); white-space: nowrap; }
.helpresults { max-width: 760px; display: flex; flex-direction: column; }
.helpresults h1 { font-size: 22px; line-height: 30px; margin-bottom: 8px; }
.helpmain .helpresult { display: flex; flex-direction: column; align-items: flex-start; gap: 4px; width: 100%; height: auto; padding: 16px 6px; border: 0; border-bottom: 1px solid var(--line); border-radius: 0; background: none; text-align: left; font-family: var(--round); }
.helpmain .helpresult:hover { background: var(--surface-hover); }
.helpresult b { font-size: 17px; line-height: 24px; color: var(--text); }
.helpsnip { font-size: 15px; line-height: 23px; color: var(--soft); }
.helpmain mark { background: color-mix(in srgb, var(--accent) 26%, transparent); color: var(--text); border-radius: 2px; padding: 0; }
.helparticle { display: flex; flex-wrap: wrap; align-items: flex-start; gap: 48px; }
.helptext { flex: 999 1 460px; min-width: 0; max-width: 70ch; }
.helpcrumb { font-size: 13.5px; color: var(--muted); margin-bottom: 10px; }
.helpcrumb .plain.link { font-size: 13.5px; text-decoration: none; }
.helpdoc { font-size: 16.5px; line-height: 1.7; color: var(--text); }
.helpdoc p { margin: 0 0 14px; }
.helpdoc h2 { margin: 40px 0 12px; font: 600 22px/30px var(--round); letter-spacing: -0.01em; scroll-margin-top: 96px; }
.helpdoc h3 { margin: 28px 0 8px; font: 600 17.5px/26px var(--round); scroll-margin-top: 96px; }
.helpdoc ul, .helpdoc ol { margin: 0 0 16px; padding-left: 22px; }
.helpdoc li { margin: 6px 0; }
.helpdoc li::marker { color: var(--muted); }
/* Numbered steps: each number in a small round badge. */
.helpdoc ol { list-style: none; padding-left: 0; counter-reset: step; }
.helpdoc ol > li { counter-increment: step; position: relative; padding-left: 42px; min-height: 28px; margin: 12px 0; }
.helpdoc ol > li::before { content: counter(step); position: absolute; left: 0; top: 0; width: 28px; height: 28px; border-radius: 50%; border: 1px solid var(--line2); background: var(--raised); display: grid; place-items: center; font: 600 13px/1 var(--round); color: var(--text); }
.helpdoc code { font-size: 14px; }
.helpdoc table { margin: 0 0 16px; font-size: 15px; line-height: 1.5; }
.helpdoc th, .helpdoc td { padding: 8px 12px; vertical-align: top; }
.helpdoc th { background: var(--raised); }
.helpshort { margin: 0 0 32px; padding: 18px 22px; border: 1px solid var(--line); border-radius: 12px; background: var(--panel); }
.helpshort h2 { margin: 0 0 8px; font: 600 12px/16px var(--round); letter-spacing: 0.08em; text-transform: uppercase; color: var(--muted); }
.helpshort ul { margin: 0; }
.helpshort li { margin: 4px 0; }
.helprelated { margin-top: 40px; padding-top: 20px; border-top: 1px solid var(--line); display: flex; flex-wrap: wrap; align-items: center; gap: 8px 12px; }
.helprelated h2 { margin: 0; font: 500 14px/20px var(--round); color: var(--muted); }
.helprelated ul { display: contents; list-style: none; }
.helprelated li { margin: 0; padding: 0; }
.helprelated a { display: inline-flex; align-items: center; min-height: 34px; padding: 6px 14px; border: 1px solid var(--line2); border-radius: 999px; font-size: 14px; color: var(--text); text-decoration: none; }
.helprelated a:hover { background: var(--surface-hover); }
.helptoc { position: sticky; top: 100px; flex: 1 1 180px; max-width: 230px; padding-top: 6px; }
.helptoc .helpgrouplabel { padding: 0 0 10px; }
.helptoc .helptocitem { display: block; width: 100%; height: auto; min-height: 0; padding: 5px 0 5px 12px; border: 0; border-left: 2px solid var(--line); border-radius: 0; background: none; text-align: left; font: 400 13.5px/18px var(--round); color: var(--muted); }
.helptoc .helptocitem:hover { color: var(--text); background: none; }
.helptoc .helptocitem.on { border-left-color: var(--accent); color: var(--text); font-weight: 600; }
@media (max-width: 1100px) { .helptoc { display: none; } }
@media (max-width: 760px) {
  .helphead { padding: 10px 16px; }
  .helpfind { flex-basis: 100%; max-width: none; margin-left: 0; }
  .helpfind kbd { display: none; }
  .helpnav { position: static; max-height: none; flex: 1 1 100%; max-width: none; flex-direction: row; gap: 4px; overflow-x: auto; padding: 10px 16px; border-bottom: 1px solid var(--line); }
  .helpgroup { flex-direction: row; gap: 4px; }
  .helpgroup .helpgrouplabel { display: none; }
  .helpnav .helpnavitem { white-space: nowrap; width: auto; }
  .helpmain { padding: 24px 16px 64px; border-left: 0; }
  .helpmain h1 { font-size: 28px; line-height: 36px; }
  .helplead { font-size: 17px; line-height: 27px; }
}

/* Usage: where the month is heading, last month behind the days, receipts beside the cost, limits and savings. */
.usagemeter { position: relative; }
.usagemeter u { position: absolute; top: -4px; bottom: -4px; width: 2px; margin-left: -1px; background: var(--text); border-radius: 1px; text-decoration: none; }
.usageday { position: relative; flex: 1; height: 100%; display: flex; align-items: flex-end; min-width: 0; }
.usageday i { position: relative; width: 100%; border-radius: 2px 2px 0 0; background: var(--accent); opacity: 0.9; }
.usageday u { position: absolute; left: 0; right: 0; bottom: 0; border-radius: 2px 2px 0 0; background: var(--muted); opacity: 0.22; text-decoration: none; }
.usagelinks { margin: 0; }
.usagecost > summary { padding: 11px 14px; }
.usagereceipt { padding: 0 14px 14px; display: flex; flex-direction: column; gap: 8px; }
.usagepart { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 2px 12px; align-items: baseline; padding-top: 8px; border-top: 1px solid var(--line); }
.usagepart .note { grid-column: 1; margin: 0; }
.usagepart em { grid-column: 2; grid-row: 1; font-style: normal; font-variant-numeric: tabular-nums; font-weight: 600; }
.usagecalls { display: grid; gap: 3px; font-size: 13px; color: var(--soft); }
.usagecalls > div { display: grid; grid-template-columns: 70px minmax(0, 1fr) 70px; gap: 10px; }
.usagecalls em { font-style: normal; text-align: right; font-variant-numeric: tabular-nums; color: var(--muted); }
.usagenear { display: flex; align-items: center; gap: 12px; padding: 12px 14px; border: 1px solid var(--warn); border-radius: 12px; background: color-mix(in srgb, var(--warn) 8%, var(--panel)); }
.usagenear.bad { border-color: var(--bad); background: color-mix(in srgb, var(--bad) 7%, var(--panel)); }
.usagetone { color: var(--warn); }
.usagelimitbar.warn i { background: var(--warn); }
.usagelimitbar.bad i { background: var(--bad); }
.usagesaved { flex: none; min-width: 96px; font: 600 15px/22px var(--display, var(--sans)); color: var(--accent-ink, var(--accent)); font-variant-numeric: tabular-nums; }
.usagepage .personcrumb { margin: 0; }
.askmodel { max-width: 300px; }
@media (max-width: 720px), (pointer: coarse) { .palette .keys { display: none; } }

/* ---------- phones: the rail becomes a bar along the bottom, within reach of a thumb ---------- */
@media (max-width: 600px) {
  :root { --rail-width: 0px; --phonebar: calc(60px + env(safe-area-inset-bottom, 0px)); }
  #app { grid-template-columns: minmax(0, 1fr); min-width: 0; padding-bottom: var(--phonebar); }
  #app > .rail {
    position: fixed; inset: auto 0 0 0; z-index: 60; height: var(--phonebar); width: auto;
    flex-direction: row; align-items: stretch; justify-content: space-around; gap: 0; overflow: visible;
    padding: 0 4px env(safe-area-inset-bottom, 0px); border-right: 0; border-top: 1px solid var(--line);
    background: var(--raised); backdrop-filter: none; box-shadow: 0 -1px 12px rgba(0, 0, 0, 0.06);
  }
  .rail .brand { display: none; }
  .rail .railgroup, .rail .railgroup.railend { display: contents; }
  .rail .railitem { width: auto; height: 60px; flex: 1 1 0; min-width: 0; padding: 0; gap: 2px; justify-content: center; border-radius: 0; background: none; }
  .rail .railitem:hover, .rail .railitem.on, .rail .railitem.on:hover { background: none; }
  .rail .railitem.on, .rail .railitem.on .ico { color: var(--accent-ink); }
  .rail .railitem .raillabel { font-size: 11px; line-height: 14px; padding: 0; overflow: hidden; text-overflow: ellipsis; max-width: 100%; }
  .rail .railitem[data-tip]::after { display: none; }
  .rail .railitem.on .raillabel { color: inherit; }
  .rail .acctbutton { align-self: center; margin: 0 6px; flex: none; }
  .acctmenu { left: auto; right: 8px; bottom: calc(var(--phonebar) + 8px); width: min(300px, calc(100vw - 16px)); }
  .rail .recentitem, .rail .raillabel:not(.railitem .raillabel) { display: none; }
}
