/*
 * The suite's interface: every app's frame, sign-in, settings, dialogs,
 * notices and controls, with the Cronum Studio brand. One look for every
 * app; each keeps its accent (the product's colour, from tokens.css by
 * <html data-app="…">, or --app set by the page) and greys with a touch of
 * that hue. Yolk marks "now" and nothing else.
 *
 * Logical properties throughout (margin-inline, inset-inline-start): the
 * suite's convention, and right-to-left for free. The theme hangs from
 * <html data-theme>, which theme.js resolves before the first paint.
 * Linked after tokens.css, which brings the brand's colours and fonts.
 */

:root {
  color-scheme: light;
  /* The drawer and what slides with it: quick to start, soft to land. */
  --kit-slide-time: .28s;
  --kit-slide: cubic-bezier(.32, .72, 0, 1);
  --kit-hue: var(--app, #7A7064);
  --kit-accent: var(--app-accent, var(--app, #16130E));
  --kit-on-accent: var(--app-on, #FFFFFF);
  --kit-accent-soft: color-mix(in oklab, var(--kit-accent) 12%, #FFFFFF);
  --kit-bg: color-mix(in oklab, var(--kit-hue) 4%, #FAF8F4);
  --kit-side: color-mix(in oklab, var(--kit-hue) 7%, #F4F1EA);
  --kit-panel: #FFFFFF;
  --kit-hover: color-mix(in oklab, var(--kit-hue) 9%, #F1EEE7);
  --kit-text: color-mix(in oklab, var(--kit-hue) 8%, #17150F);
  --kit-muted: color-mix(in oklab, var(--kit-hue) 14%, #6E675C);
  --kit-border: color-mix(in oklab, var(--kit-hue) 9%, #E6E0D4);
  --kit-now: var(--cr-yolk-600);
  /* A highlighter's yellow in every app: a highlight is not the app's colour. */
  --kit-md-mark: color-mix(in oklab, var(--cr-yolk-500) 42%, #FFFFFF);
  --kit-now-text: var(--cr-yolk-text);
  /* Read as text on the page, on a panel and on their soft tint, 4.5:1 (web-kit.test.js): a
     module's states as text (a task overdue or at risk, a branch stuck) take these. */
  --kit-ok: #167548;
  --kit-warn: #9A5A00;
  --kit-danger: #BA3429;
  --kit-warn-soft: #FFF1D6;
  --kit-danger-soft: #FCE7E4;
  --kit-toast: #1F1B15;
  --kit-toast-text: #FFF7E6;
  --kit-scrim: rgba(10, 8, 4, .45);
  --kit-shadow: 0 1px 2px rgba(40, 30, 10, .07), 0 8px 24px rgba(40, 30, 10, .07);
  --kit-shadow-high: 0 12px 40px rgba(20, 15, 5, .22);
  /* The kit's old names for three corners of the look's (--look-r-*, below), kept for the sheets
     that still say them: a module's sheet and the kit's own write --look-r-*. */
  --kit-radius: var(--look-r-md);
  --kit-radius-small: var(--look-r-sm);
  --kit-radius-large: var(--look-r-xl);
  /* The palette of a list, a notebook, a project (palette.js KIT_COLORS, by name): what a module
     that keeps the name paints with. One that keeps the hex paints the hex, these same values. */
  --kit-color-blue: #2564cf;
  --kit-color-cyan: #0a7ea6;
  --kit-color-teal: #0e7c86;
  --kit-color-green: #15803d;
  --kit-color-olive: #6e7a2a;
  --kit-color-brown: #8a6a45;
  --kit-color-pink: #c2407c;
  --kit-color-plum: #a03ea3;
  --kit-color-violet: #6e55c2;
  --kit-color-indigo: #4f5bd5;
  --kit-color-steel: #56708a;
  --kit-color-slate: #606776;
  --kit-sig-ring: var(--cr-yolk-600);
  --kit-sig-dot: var(--cr-ink);
  --kit-font: var(--cr-font-text);
  --kit-font-display: var(--cr-font-display);
  --kit-font-mono: var(--cr-font-mono);
  --kit-safe-top: env(safe-area-inset-top, 0px);
  --kit-safe-bottom: env(safe-area-inset-bottom, 0px);
  /*
   * The look's type, corners and room: one short scale, the same in every module, and every
   * sheet says the name, never a number beside it (`var(--look-body)`, not `var(--look-body,
   * 14px)`: web-kit-css.test.js fails on one). These are the Cronum look's; the Clean look has
   * its own, an iPhone's, below. A thing that must not go under a size in Cronum and takes the
   * look's in Clean says so with max() (`max(16px, var(--look-body))`, a field a phone would zoom
   * into); one whose Cronum size isn't on the scale at all writes it, and its Clean rule the
   * look's (kit.css's Clean block at the end, a module's own).
   */
  --look-base: 15px;
  --look-large-title: 21px;
  --look-title1: 24px;
  --look-title2: 22px;
  --look-title3: 19px;
  --look-headline: 15px;
  --look-body: 15px;
  --look-callout: 14px;
  --look-subhead: 14px;
  --look-footnote: 13px;
  --look-caption: 12px;
  --look-caption2: 11px;
  --look-r-xs: 4px;
  --look-r-sm: 8px;
  --look-r-md: 10px;
  --look-r-lg: 12px;
  --look-r-xl: 16px;
  /* What a view's content keeps from the edges of its pane, the title of its head included: one
     margin for every module. */
  --look-gutter: 16px;
  --look-row-y: 11px;
  --look-row-gap: 10px;
  --look-head-y: 10px;
  --look-item-y: 9px;
  --look-bar-y: 10px;
  --look-section: 20px;
  /* The small label in capitals over a group of things (a sidebar's section, Share's «People»,
     a step's «Why»): one measure in every module (.kit-eyebrow). Clean has its own spacing, below;
     its size follows Clean's footnote. */
  --kit-eyebrow-size: 11px;
  --kit-eyebrow-weight: 600;
  --kit-eyebrow-spacing: .1em;
}

/*
 * In the dark, a product's colour (graphite, say) would vanish on ink: the
 * accent is its light step from tokens.css, or the colour lightened with
 * cream, with ink on it.
 */
:root[data-theme="dark"] {
  color-scheme: dark;
  --kit-accent: var(--app-accent-dark, color-mix(in oklab, var(--app, #FFC21A) 55%, #FFF7E6));
  --kit-on-accent: var(--app-on-dark, #16130E);
  --kit-accent-soft: color-mix(in oklab, var(--kit-accent) 18%, #1C1914);
  --kit-bg: color-mix(in oklab, var(--kit-hue) 6%, #14120E);
  --kit-side: color-mix(in oklab, var(--kit-hue) 8%, #110F0B);
  --kit-panel: color-mix(in oklab, var(--kit-hue) 6%, #1C1914);
  --kit-hover: color-mix(in oklab, var(--kit-hue) 10%, #26221B);
  --kit-text: #F6F1E7;
  --kit-muted: color-mix(in oklab, var(--kit-hue) 12%, #ABA294);
  --kit-border: color-mix(in oklab, var(--kit-hue) 10%, #312C24);
  --kit-now: var(--cr-yolk-500);
  --kit-md-mark: color-mix(in oklab, var(--cr-yolk-500) 34%, #1C1914);
  --kit-now-text: var(--cr-yolk-500);
  --kit-ok: #4CC184;
  --kit-warn: #FFC94D;
  --kit-danger: #F07A6E;
  --kit-warn-soft: #3A2E12;
  --kit-danger-soft: #3D1D19;
  --kit-toast: #FFF7E6;
  --kit-toast-text: #16130E;
  --kit-scrim: rgba(0, 0, 0, .6);
  --kit-shadow: 0 1px 2px rgba(0, 0, 0, .4), 0 8px 24px rgba(0, 0, 0, .35);
  --kit-shadow-high: 0 12px 40px rgba(0, 0, 0, .55);
  --kit-sig-ring: var(--cr-yolk-500);
  --kit-sig-dot: var(--cr-cream);
  /* The palette's lighter steps (palette.js `dark`), read as text on the dark page. */
  --kit-color-blue: #6f9ff7;
  --kit-color-cyan: #5cc3e4;
  --kit-color-teal: #4fbcc4;
  --kit-color-green: #5cc98a;
  --kit-color-olive: #a8b55a;
  --kit-color-brown: #c49a6c;
  --kit-color-pink: #ec85b0;
  --kit-color-plum: #d08be6;
  --kit-color-violet: #a593ea;
  --kit-color-indigo: #949cf2;
  --kit-color-steel: #8fb0cf;
  --kit-color-slate: #a5abb6;
}

/*
 * Cronum Work's one-document shell: the page is Work's, and each module keeps its accent inside
 * its windows and the pieces it hangs on the page (`data-module`, `data-owner`): its --app…
 * from tokens.css there, and the kit's accent from them again, since what :root gave is already
 * worked out in Work's colour. The greys stay the page's.
 */
:root[data-app="work"] :is([data-module], [data-owner]) {
  --kit-hue: var(--app, #7A7064);
  --kit-accent: var(--app-accent, var(--app, #16130E));
  --kit-on-accent: var(--app-on, #FFFFFF);
  --kit-accent-soft: color-mix(in oklab, var(--kit-accent) 12%, #FFFFFF);
}
:root[data-app="work"][data-theme="dark"] :is([data-module], [data-owner]) {
  --kit-accent: var(--app-accent-dark, color-mix(in oklab, var(--app, #FFC21A) 55%, #FFF7E6));
  --kit-on-accent: var(--app-on-dark, #16130E);
  --kit-accent-soft: color-mix(in oklab, var(--kit-accent) 18%, #1C1914);
}
:root[data-app="work"][data-look="clean"]:not([data-theme="dark"]) :is([data-module], [data-owner]) {
  --kit-accent-soft: color-mix(in oklab, var(--kit-accent) 10%, #FFFFFF);
}
:root[data-app="work"][data-look="clean"][data-theme="dark"] :is([data-module], [data-owner]) {
  --kit-accent-soft: color-mix(in oklab, var(--kit-accent) 18%, #1C1C1E);
}

/*
 * The Clean look (<html data-look="clean">, a host's choice for each person:
 * theme.js and shell.js): white and greys with no hue in them, hairline
 * borders, soft shadows and Inter everywhere. The product's accent stays, as
 * the one colour; yolk still marks "now". Light and dark each have their own.
 */
:root[data-look="clean"] {
  --kit-font: var(--cr-font-clean);
  --kit-font-display: var(--cr-font-clean);
  /* Its type, corners and room, an iPhone's: the sizes are Apple's text styles. */
  --look-base: 17px;
  --look-large-title: 34px;
  --look-title1: 28px;
  --look-title2: 22px;
  --look-title3: 20px;
  --look-headline: 17px;
  --look-body: 17px;
  --look-callout: 16px;
  --look-subhead: 15px;
  --look-footnote: 13px;
  --look-caption: 12px;
  --look-caption2: 11px;
  --look-r-xs: 6px;
  --look-r-sm: 10px;
  --look-r-md: 12px;
  --look-r-lg: 14px;
  --look-r-xl: 18px;
  --look-gutter: 20px;
  --look-row-y: 12px;
  --look-row-gap: 14px;
  --look-head-y: 18px;
  --look-item-y: 10px;
  --look-bar-y: 10px;
  --look-section: 28px;
  --kit-eyebrow-size: var(--look-footnote);
  --kit-eyebrow-spacing: .02em;
}
:root[data-look="clean"]:not([data-theme="dark"]) {
  --kit-accent-soft: color-mix(in oklab, var(--kit-accent) 10%, #FFFFFF);
  --kit-bg: #FFFFFF;
  --kit-side: #F5F5F7;
  --kit-panel: #FFFFFF;
  --kit-hover: #F2F2F7;
  --kit-text: #1D1D1F;
  --kit-muted: #6E6E73;
  --kit-border: #E5E5EA;
  --kit-toast: #1D1D1F;
  --kit-toast-text: #FFFFFF;
  --kit-scrim: rgba(0, 0, 0, .32);
  --kit-shadow: 0 1px 2px rgba(0, 0, 0, .04), 0 4px 16px rgba(0, 0, 0, .05);
  --kit-shadow-high: 0 10px 36px rgba(0, 0, 0, .14);
}
:root[data-look="clean"][data-theme="dark"] {
  --kit-accent-soft: color-mix(in oklab, var(--kit-accent) 18%, #1C1C1E);
  --kit-bg: #000000;
  --kit-side: #0E0E10;
  --kit-panel: #1C1C1E;
  --kit-hover: #2C2C2E;
  --kit-text: #F5F5F7;
  --kit-muted: #98989D;
  --kit-border: #38383A;
  --kit-md-mark: color-mix(in oklab, var(--cr-yolk-500) 34%, #1C1C1E);
  --kit-toast: #F5F5F7;
  --kit-toast-text: #1D1D1F;
  --kit-shadow: 0 1px 2px rgba(0, 0, 0, .5);
  --kit-shadow-high: 0 12px 40px rgba(0, 0, 0, .6);
}

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

* { box-sizing: border-box; }
[hidden] { display: none !important; }
/* A module on its own page, its frame (.kit-app, fixed to the screen) on the page's body: the page
   itself stays put and only the frame's zones scroll, pulling past an edge drags nothing, and a
   tap answers at once, with no wait for a double tap's zoom. Every module's, said once (it was in
   Tasks', Projects' and Next's sheets); a page without the frame (a public page) scrolls as any
   page, and in Cronum Work the page is Work's. */
:where(:root:not([data-app="work"]):has(> body > .kit-app)),
:where(:root:not([data-app="work"]):has(> body > .kit-app)) > body {
  height: 100%; overflow: hidden; overscroll-behavior: none; touch-action: manipulation;
}

body {
  margin: 0;
  font: 400 var(--look-base)/1.5 var(--kit-font);
  color: var(--kit-text);
  background: var(--kit-bg);
  -webkit-font-smoothing: antialiased;
  -webkit-text-size-adjust: 100%;
  /* No blue flash when a row or a button is tapped on a phone: the kit's own states show it. */
  -webkit-tap-highlight-color: transparent;
}
/* The frame's controls aren't selected by a long press, in every module; what is typed in them
   and an item's own text are. */
:is(.kit-side, .kit-bar, .kit-head, .kit-nav__item, .kit-group-title, .kit-round-check, .kit-segmented) {
  user-select: none; -webkit-user-select: none;
}
:is(.kit-side, .kit-bar, .kit-head) :is(input, textarea, [contenteditable]) { user-select: text; -webkit-user-select: text; }
button, input, select, textarea { font: inherit; color: inherit; }
a { color: var(--kit-accent); }
h1, h2, h3, h4 { line-height: 1.2; text-wrap: balance; }
:focus-visible { outline: 2px solid var(--kit-accent); outline-offset: 2px; }
.kit-mono { font-family: var(--kit-font-mono); font-size: var(--look-footnote); word-break: break-all; }
.kit-now { color: var(--kit-now-text); }
.kit-visually-hidden { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* An icon from icons.js: stroked, round ends, the colour of its text. */
.kit-icon { width: 18px; height: 18px; flex: none; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
[dir="rtl"] .kit-icon[data-directional] { transform: scaleX(-1); }

@media (prefers-reduced-motion: reduce) {
  :root { --kit-slide-time: 0s; }
  *, *::before, *::after { transition-duration: 0s !important; animation-duration: 0s !important; }
}

/* ------------------------------ simple pages ------------------------------ */
/* A page without the app frame: the admin panel. */

.kit-header {
  display: flex; flex-wrap: wrap; align-items: center; gap: 8px 16px;
  padding: calc(14px + var(--kit-safe-top)) 16px 0;
  max-width: 1120px; margin: 0 auto;
}
.kit-header h1 { margin: 0; font: 700 var(--look-title2)/1.1 var(--kit-font-display); letter-spacing: -.02em; }
.kit-header__icon { width: 40px; height: 40px; border-radius: 10px; flex: none; }
.kit-header__app { color: var(--kit-muted); font-size: var(--look-subhead); }
.kit-header__spacer { flex: 1; }
.kit-header__user { color: var(--kit-muted); font-size: var(--look-subhead); }

.kit-tabs {
  display: flex; gap: 4px; overflow-x: auto; scrollbar-width: none;
  max-width: 1120px; margin: 12px auto 0; padding: 0 16px;
  border-bottom: 1px solid var(--kit-border);
}
.kit-tab {
  padding: 9px 14px; border-radius: var(--look-r-sm) var(--look-r-sm) 0 0; color: var(--kit-muted);
  text-decoration: none; white-space: nowrap; font-weight: 500;
}
.kit-tab:hover { background: var(--kit-hover); color: var(--kit-text); }
.kit-tab[aria-current="page"] { color: var(--kit-text); box-shadow: inset 0 -2px var(--kit-accent); }

.kit-main { max-width: 1120px; margin: 0 auto; padding: 18px var(--look-gutter) 48px; }
.kit-main > h2 { margin: 0 0 4px; font: 700 20px/1.2 var(--kit-font-display); letter-spacing: -.02em; }
:root[data-look="clean"] .kit-main > h2 { font-size: var(--look-title2); }
.kit-lead { margin: 0 0 16px; color: var(--kit-muted); }
.kit-toolbar { display: flex; flex-wrap: wrap; align-items: end; gap: 10px; margin: 0 0 14px; }
.kit-toolbar .kit-field { min-width: 180px; }

.kit-notice {
  background: var(--kit-panel); border: 1px solid var(--kit-border); border-radius: var(--look-r-md);
  padding: 18px; box-shadow: var(--kit-shadow); display: grid; gap: 12px; justify-items: start;
}
.kit-notice p { margin: 0; }
.kit-empty { color: var(--kit-muted); padding: 12px 2px; margin: 0; }

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

.kit-btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 7px;
  min-height: 38px; padding: 0 14px; border-radius: var(--look-r-md); border: 1px solid var(--kit-border);
  background: var(--kit-panel); color: var(--kit-text); font-weight: 500; font-size: var(--look-subhead);
  cursor: pointer; text-decoration: none; white-space: nowrap;
}
.kit-btn:hover { background: var(--kit-hover); }
.kit-btn--primary { background: var(--kit-accent); border-color: var(--kit-accent); color: var(--kit-on-accent); font-weight: 600; }
.kit-btn--primary:hover { background: var(--kit-accent); filter: brightness(1.07); }
.kit-btn--quiet { background: none; border-color: transparent; }
.kit-btn--quiet:hover { background: var(--kit-hover); }
.kit-btn--danger { background: var(--kit-danger); border-color: var(--kit-danger); color: #FFFFFF; font-weight: 600; }
.kit-btn--danger:hover { background: var(--kit-danger); filter: brightness(1.07); }
.kit-btn--danger-quiet { background: none; border-color: transparent; color: var(--kit-danger); }
.kit-btn--small { min-height: 31px; padding: 0 10px; font-size: var(--look-subhead); border-radius: var(--look-r-sm); }
.kit-btn--block { width: 100%; }
.kit-btn[disabled], .kit-btn[aria-busy="true"] { opacity: .55; cursor: default; filter: none; }
.kit-btn .kit-icon { width: 17px; height: 17px; }

.kit-link { background: none; border: 0; padding: 0; color: var(--kit-accent); cursor: pointer; font-size: var(--look-subhead); text-decoration: none; font-weight: 500; }
.kit-link:hover { text-decoration: underline; }
.kit-link--danger { color: var(--kit-danger); }

.kit-icon-btn {
  width: 40px; height: 40px; border-radius: var(--look-r-md); border: 0; background: none; cursor: pointer; flex: none;
  display: inline-grid; place-items: center; color: var(--kit-muted); font-size: var(--look-title2); line-height: 1; padding: 0;
}
.kit-icon-btn:hover { background: var(--kit-hover); color: var(--kit-text); }
.kit-icon-btn .kit-icon { width: 20px; height: 20px; }
/* A button that stays on while what it opens is open (a card's pencil, a note's pin): in every module. */
.kit-icon-btn[aria-pressed="true"] { background: var(--kit-accent-soft); color: var(--kit-accent); }

/* The small label in capitals over a group of things, the same in every module. */
.kit-eyebrow {
  font: var(--kit-eyebrow-weight) var(--kit-eyebrow-size)/1.2 var(--kit-font);
  letter-spacing: var(--kit-eyebrow-spacing); text-transform: uppercase; color: var(--kit-muted);
}

.kit-spinner {
  width: 15px; height: 15px; border-radius: 50%; border: 2px solid currentColor; border-inline-end-color: transparent;
  animation: kit-spin .8s linear infinite; flex: none;
}
@keyframes kit-spin { to { transform: rotate(360deg); } }

.kit-field { display: grid; gap: 5px; }
/* `.kit-label`: a field's label where there is no field() around it (a block of an item's detail,
   over several controls), with the same measure in every module. */
.kit-field > label, .kit-label { font-size: var(--look-footnote); font-weight: 500; color: var(--kit-text); }
.kit-label { display: block; margin: 0; line-height: 1.5; }
.kit-field input:not([type="checkbox"]):not([type="radio"]):not([type="file"]), .kit-field select, .kit-field textarea, .kit-input {
  width: 100%; min-height: 40px; padding: 8px 12px; border-radius: var(--look-r-md);
  border: 1px solid var(--kit-border); background: var(--kit-panel); color: var(--kit-text);
}
.kit-field textarea { min-height: 90px; resize: vertical; }
.kit-field input:focus-visible, .kit-field select:focus-visible, .kit-field textarea:focus-visible, .kit-input:focus-visible {
  outline: 2px solid var(--kit-accent); outline-offset: -1px; border-color: transparent;
}
/* On a touch screen a field's text is never under 16px: below that the iPhone zooms the page in
   when it takes the focus. In every module (it was Notes' alone). */
@media (pointer: coarse) {
  .kit-input, .kit-field input, .kit-field select, .kit-field textarea { font-size: max(16px, var(--look-body)); }
}
.kit-field--bad input, .kit-field--bad select, .kit-field--bad textarea { border-color: var(--kit-danger); }
/* A password with its eye inside, at the end (ui.js revealable): the text stops before the eye. */
.kit-password { position: relative; display: grid; }
/* As specific as the field's own input rule, or its padding would win. */
.kit-field .kit-password > input:not([type="checkbox"]):not([type="radio"]):not([type="file"]) { padding-inline-end: 44px; }
.kit-password__eye {
  position: absolute; inset-block: 0; inset-inline-end: 0; width: 40px; border: 0; background: none; padding: 0;
  display: grid; place-items: center; color: var(--kit-muted); cursor: pointer; border-radius: var(--look-r-md);
}
.kit-password__eye:hover { color: var(--kit-text); }
.kit-password__eye:focus-visible { outline: 2px solid var(--kit-accent); outline-offset: -4px; }
.kit-password__eye .kit-icon { width: 18px; height: 18px; }
.kit-hint { margin: 0; color: var(--kit-muted); font-size: var(--look-footnote); }
.kit-error { margin: 0; color: var(--kit-danger); font-size: var(--look-footnote); }
.kit-check { display: flex; align-items: center; gap: 9px; }
.kit-check input { width: 18px; height: 18px; accent-color: var(--kit-accent); margin: 0; flex: none; }
.kit-grid { display: grid; gap: 12px; grid-template-columns: repeat(auto-fit, minmax(min(200px, 100%), 1fr)); }
.kit-row { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; }
.kit-stack { display: grid; gap: 12px; }

/* A switch: a button with role="switch" and aria-checked. */
.kit-switch {
  width: 42px; height: 26px; border-radius: 999px; background: var(--kit-border); border: 0;
  position: relative; cursor: pointer; flex: none; padding: 0;
}
.kit-switch::after {
  content: ""; position: absolute; top: 3px; inset-inline-start: 3px; width: 20px; height: 20px; border-radius: 50%;
  background: #FFFFFF; box-shadow: 0 1px 2px rgba(0, 0, 0, .25); transition: inset-inline-start .15s;
}
.kit-switch[aria-checked="true"] { background: var(--kit-accent); }
.kit-switch[aria-checked="true"]::after { inset-inline-start: 19px; }
.kit-switch-row { display: flex; align-items: center; justify-content: space-between; gap: 14px; }
.kit-switch-row small { display: block; color: var(--kit-muted); font-size: var(--look-footnote); }
.kit-switch-row--swatch > span:first-child { display: flex; align-items: center; gap: 8px; min-width: 0; }
/* Settings › Modules: a row's name and its line under it, wrapping on a narrow phone; and the
   icon of a button on the rail (the calendar's, the daily summary's, a door's). */
.kit-switch-row__text { min-width: 0; }
.kit-switch-row__icon { display: inline-grid; place-items: center; width: 22px; flex: none; color: var(--kit-muted); }
.kit-switch-row__icon .kit-icon { width: 18px; height: 18px; }
/* Settings › Daily summary: each notice a block of its own (switch, time, modules, its page). */
.kit-day-list { display: grid; gap: 18px; }
.kit-day { display: grid; gap: 14px; min-width: 0; }
.kit-day + .kit-day { border-top: 1px solid var(--kit-border); padding-top: 18px; }
.kit-day__time { display: flex; align-items: center; justify-content: space-between; gap: 14px; color: var(--kit-text); }
/* Its hour and its minutes, two lists as wide as what they say (the kit's fields are as wide as
   their box), never over their neighbours. */
.kit-day__time .kit-day__clock { display: inline-flex; align-items: center; gap: 4px; flex: none; }
.kit-day__clock .kit-day__part { width: auto; min-width: 4.2em; padding-inline: 10px; text-align: center; font-variant-numeric: tabular-nums; }
.kit-day__colon { font-weight: 600; color: var(--kit-muted); }
.kit-day__modules { display: grid; gap: 10px; padding: 12px 14px; border-radius: var(--look-r-md); background: var(--kit-hover); }
.kit-day__label { font-size: var(--look-footnote); font-weight: 600; color: var(--kit-muted); }
.kit-day__icon { width: 20px; height: 20px; border-radius: var(--look-r-xs); flex: none; }
.kit-day__see { justify-self: start; display: inline-flex; align-items: center; gap: 6px; text-decoration: none; }
.kit-day__see svg { width: 16px; height: 16px; }
/* What picks a module up to put it in order (Settings › Modules): dragged, or pressed for its menu. */
.kit-module-grip {
  display: inline-grid; place-items: center; width: 28px; height: 32px; margin-inline-start: -6px; flex: none;
  border: 0; border-radius: var(--look-r-xs); background: none; color: var(--kit-muted); cursor: grab; touch-action: none;
}
.kit-module-grip:hover { color: var(--kit-text); }
.kit-module-grip:active { cursor: grabbing; }
.kit-module-grip .kit-icon { width: 18px; height: 18px; stroke-width: 3; }

/* One choice among a few, side by side (the theme). */
.kit-segmented { display: inline-flex; flex-wrap: wrap; padding: 3px; border-radius: var(--look-r-md); background: var(--kit-hover); gap: 2px; }
.kit-segmented button {
  border: 0; background: none; padding: 6px 12px; border-radius: var(--look-r-sm); color: var(--kit-muted); font-weight: 500;
  cursor: pointer; min-height: 32px;
}
.kit-segmented button[aria-pressed="true"] { background: var(--kit-panel); color: var(--kit-text); box-shadow: 0 1px 2px rgba(0, 0, 0, .12); }

/* ---------------------------------- data ---------------------------------- */

.kit-table-wrap {
  overflow-x: auto; background: var(--kit-panel); border: 1px solid var(--kit-border);
  border-radius: var(--look-r-md); box-shadow: var(--kit-shadow);
}
.kit-table { width: 100%; border-collapse: collapse; font-size: var(--look-subhead); }
.kit-table th {
  text-align: start; font-weight: 600; color: var(--kit-muted); font-size: var(--look-footnote);
  padding: 10px 12px; border-bottom: 1px solid var(--kit-border); white-space: nowrap;
}
.kit-table td { padding: 10px 12px; border-bottom: 1px solid var(--kit-border); vertical-align: top; }
.kit-table tr:last-child td { border-bottom: 0; }
.kit-table tbody tr[data-open] { cursor: pointer; }
.kit-table tbody tr[data-open]:hover { background: var(--kit-hover); }
.kit-table small { display: block; color: var(--kit-muted); font-size: var(--look-footnote); }
/* The admin's account dialog (admin.js): folds that say what they hold, closed. */
.kit-fold__now {
  flex: 0 1 auto; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
  color: var(--kit-muted); font-size: var(--look-footnote); font-weight: 400;
}
.kit-fold__now--warn { color: var(--kit-warn); font-weight: 600; }
.kit-grid--3 { grid-template-columns: repeat(auto-fit, minmax(min(160px, 100%), 1fr)); }
.kit-grid--4 { grid-template-columns: repeat(auto-fit, minmax(min(140px, 100%), 1fr)); }
.kit-row--end { align-items: end; }
.kit-row__last { margin-inline-start: auto; }
.kit-warning {
  margin: 0; padding: 10px 12px; border-radius: var(--look-r-md); font-size: var(--look-subhead); line-height: 1.4;
  background: var(--kit-warn-soft); color: var(--kit-warn);
}
.kit-subfold > summary { cursor: pointer; color: var(--kit-accent); font-size: var(--look-subhead); font-weight: 500; width: fit-content; }
.kit-subfold[open] > summary { margin-bottom: 10px; }
.kit-subfold > :not(summary) + :not(summary) { margin-top: 10px; }
.kit-contents { display: contents; }
.kit-dialog__end { display: grid; gap: 8px; padding-top: 12px; border-top: 1px solid var(--kit-border); }
/* What an account uses (admin.js, Usage): a line per count, a bar where there is a limit. */
.kit-usage { display: grid; gap: 16px; }
.kit-usage__group { display: grid; gap: 8px; }
.kit-usage__group + .kit-usage__group { padding-top: 14px; border-top: 1px solid var(--kit-border); }
.kit-usage__title { display: flex; align-items: center; gap: 8px; margin: 0; font-size: var(--look-subhead); font-weight: 600; }
.kit-usage__row { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: 4px 12px; }
.kit-usage__row > .kit-meter, .kit-usage__row > .kit-usage__note { grid-column: 1 / -1; }
.kit-usage__row > .kit-badge { grid-column: 1 / -1; justify-self: start; }
.kit-usage__value { color: var(--kit-muted); font-variant-numeric: tabular-nums; text-align: end; }
.kit-usage__note { color: var(--kit-muted); font-size: var(--look-footnote); }
.kit-meter { display: block; block-size: 6px; border-radius: 999px; background: var(--kit-border); overflow: hidden; }
.kit-meter > span { display: block; block-size: 100%; border-radius: inherit; background: var(--kit-accent); }
.kit-meter--near > span { background: var(--kit-warn); }
.kit-meter--reached > span { background: var(--kit-danger); }
.kit-usage-cell { min-inline-size: 96px; }
.kit-usage-cell .kit-meter { inline-size: 80px; margin-block: 4px 2px; }
/*
 * The calls of each day: thin bars on one baseline, a day without any a stub, a day before the
 * account or still to come nothing; in weeks, a gap before each Monday, and one week's seven wider. Each day is a column the chart's height; pointing at it (or tapping it) says
 * its day and calls above the chart, kept inside it at both ends.
 */
.kit-usage__days { display: flex; align-items: stretch; gap: 2px; block-size: 48px; border-block-end: 1px solid var(--kit-border); }
.kit-usage__day { flex: 1; min-inline-size: 0; display: flex; align-items: end; outline: none; cursor: default; }
.kit-usage__day > span { flex: 1; border-radius: 2px 2px 0 0; background: var(--kit-accent); }
.kit-usage__day--none > span { background: var(--kit-border); }
.kit-usage__day:not(.kit-usage__day--before):is(:hover, :focus) > span { filter: brightness(1.15); box-shadow: 0 0 0 1px var(--kit-text); }
.kit-usage__day[data-tip]:is(:hover, :focus)::after {
  content: attr(data-tip); position: absolute; inset-block-end: calc(100% + 4px); inset-inline-start: 50%; translate: -50% 0; z-index: 2;
  padding: 3px 8px; border-radius: 6px; background: var(--kit-text); color: var(--kit-bg);
  font-size: var(--look-footnote); white-space: nowrap; pointer-events: none;
}
.kit-usage__day[data-tip] { position: relative; }
.kit-usage__day:nth-child(-n+6)[data-tip]:is(:hover, :focus)::after { inset-inline-start: 0; translate: 0 0; }
.kit-usage__day:nth-last-child(-n+6)[data-tip]:is(:hover, :focus)::after { inset-inline-start: auto; inset-inline-end: 0; translate: 0 0; }
.kit-usage__days--weeks > .kit-usage__day--monday { margin-inline-start: 6px; }
.kit-usage__days--week { gap: 8px; }
.kit-usage__weekdays { display: flex; gap: 8px; margin-block-start: 4px; }
.kit-usage__weekdays > span { flex: 1; text-align: center; font-size: var(--look-caption); color: var(--kit-muted); }
.kit-usage__days--week > .kit-usage__day[data-tip]:is(:hover, :focus)::after { inset-inline-start: 50%; inset-inline-end: auto; translate: -50% 0; }
.kit-usage__days--week > .kit-usage__day:first-child[data-tip]:is(:hover, :focus)::after { inset-inline-start: 0; translate: 0 0; }
.kit-usage__days--week > .kit-usage__day:last-child[data-tip]:is(:hover, :focus)::after { inset-inline-start: auto; inset-inline-end: 0; translate: 0 0; }
/* Settings › Plan › Your usage: near a cap of one's own plan, said first, with what is at it. */
.kit-usage__alert--near { border-color: var(--kit-warn); }
.kit-usage__alert--reached { border-color: var(--kit-danger); }
.kit-usage__at { display: flex; flex-wrap: wrap; gap: 6px; }
.kit-usage__at > .kit-badge { font-size: var(--look-subhead); padding: 3px 10px; }
/*
 * The storage by module, as a phone shows its own: each module in its icon's hue, a step that
 * tells the four apart with any colour vision (light and dark each checked), the room left grey,
 * 2px of ground between parts. Another module, the muted ink.
 */
.kit-usage [data-part] { --kit-part: var(--kit-muted); }
.kit-usage [data-part="tasks"] { --kit-part: #EF4B2A; }
.kit-usage [data-part="projects"] { --kit-part: #A12A83; }
.kit-usage [data-part="next"] { --kit-part: #2BA8D2; }
.kit-usage [data-part="notes"] { --kit-part: #7C3AED; }
:root[data-theme="dark"] .kit-usage [data-part="tasks"] { --kit-part: #E8603F; }
:root[data-theme="dark"] .kit-usage [data-part="projects"] { --kit-part: #AD3D92; }
:root[data-theme="dark"] .kit-usage [data-part="next"] { --kit-part: #2A9FC6; }
:root[data-theme="dark"] .kit-usage [data-part="notes"] { --kit-part: #9C7CF0; }
.kit-storage { display: flex; gap: 2px; block-size: 12px; border-radius: 4px; background: var(--kit-border); overflow: hidden; }
.kit-storage__part { flex-grow: 0; flex-shrink: 0; min-inline-size: 3px; background: var(--kit-part); }
.kit-storage__legend { display: flex; flex-wrap: wrap; gap: 6px 16px; margin: 0; padding: 0; list-style: none; font-size: var(--look-footnote); }
.kit-storage__legend li { display: flex; align-items: center; gap: 6px; }
.kit-storage__size { color: var(--kit-muted); font-variant-numeric: tabular-nums; }
.kit-storage__dot { inline-size: 10px; block-size: 10px; border-radius: 3px; background: var(--kit-part); }
.kit-storage__dot[data-free] { background: var(--kit-border); }
/* A QR code (qr.js): black on white in any theme, with its quiet zone drawn in. */
.kit-qr { display: block; width: min(220px, 100%); height: auto; border-radius: var(--look-r-sm); }

.kit-badge {
  display: inline-flex; align-items: center; gap: 4px; padding: 2px 8px; border-radius: 999px;
  font-size: var(--look-caption); font-weight: 600; background: var(--kit-hover); color: var(--kit-muted); white-space: nowrap;
}
.kit-badge--accent { background: var(--kit-accent-soft); color: var(--kit-accent); }
.kit-badge--ok { color: var(--kit-ok); }
.kit-badge--on { background: color-mix(in srgb, var(--kit-ok) 14%, transparent); color: var(--kit-ok); }
.kit-badge--on svg { width: 14px; height: 14px; }
.kit-badge--warn { background: var(--kit-warn-soft); color: var(--kit-warn); }
.kit-badge--danger { background: var(--kit-danger-soft); color: var(--kit-danger); }
.kit-badge--now { background: color-mix(in srgb, var(--kit-now) 22%, transparent); color: var(--kit-now-text); }

.kit-copy {
  display: flex; gap: 8px; align-items: center; padding: 8px 10px; border-radius: var(--look-r-sm);
  background: var(--kit-bg); border: 1px dashed var(--kit-border); min-width: 0;
}
.kit-copy code { flex: 1; min-width: 0; font-family: var(--kit-font-mono); font-size: var(--look-footnote); word-break: break-all; }

/* A list of rows in a box: people, devices, tokens. */
.kit-list { border: 1px solid var(--kit-border); border-radius: var(--look-r-lg); background: var(--kit-panel); overflow: hidden; }
.kit-list__row { display: flex; align-items: center; gap: 12px; padding: var(--look-row-y) 14px; min-height: 52px; }
.kit-list__row + .kit-list__row { border-top: 1px solid var(--kit-border); }
.kit-list__text { flex: 1; min-width: 0; line-height: 1.35; }
.kit-list__text small { display: block; color: var(--kit-muted); font-size: var(--look-footnote); overflow-wrap: anywhere; }

.kit-blank {
  display: grid; justify-items: center; text-align: center; gap: 8px; padding: 28px 16px;
  color: var(--kit-muted);
}
.kit-blank__icon { width: 46px; height: 46px; border-radius: var(--look-r-lg); background: var(--kit-accent-soft); color: var(--kit-accent); display: grid; place-items: center; }
.kit-blank__icon .kit-icon { width: 22px; height: 22px; }
/* One size of title in every module, the line of a list's and the heading of a view's (blank({ page })). */
.kit-blank strong, .kit-blank h2 { margin: 0; color: var(--kit-text); font-size: var(--look-headline); font-weight: 600; }
.kit-blank p { margin: 0; max-width: 36ch; font-size: var(--look-subhead); }
/* The emoji a person chose (a Tasks list's) in the icon's box; the spinner while it loads. */
.kit-blank__glyph { font-size: 22px; line-height: 1; }
.kit-blank--loading .kit-blank__icon { background: none; }
.kit-blank__note { margin-top: 6px; font-size: var(--look-footnote); }
.kit-blank .kit-btn { margin-top: 6px; }

/*
 * The row whose item is open in the detail beside it (rule 17 of web-kit.md): a soft background
 * in the accent, the same in every module. A module whose row carries a surface of its own (what
 * a finger slides) paints that surface too.
 */
.kit-list-row[aria-current="true"] { background: var(--kit-accent-soft); }

/*
 * The bar that adds an item at the foot of a list (ui.js addBar, rule 16): a card with a +, the
 * field without a frame of its own and «Añadir». Where it sits (at the foot of a column, sticky
 * over a chart) is the module's.
 */
.kit-add-bar {
  display: flex; align-items: center; gap: var(--look-row-gap); flex: 0 0 auto;
  margin: 0 var(--look-gutter) max(16px, var(--kit-safe-bottom));
  padding: var(--look-bar-y) 14px;
  background: var(--kit-panel); border: 1px solid var(--kit-border); border-radius: var(--look-r-md);
  box-shadow: var(--kit-shadow);
}
.kit-add-bar:focus-within { border-color: color-mix(in oklab, var(--kit-accent) 45%, var(--kit-border)); }
.kit-add-bar__plus { display: inline-grid; place-items: center; color: var(--kit-accent); flex: none; }
.kit-add-bar__plus .kit-icon { width: 18px; height: 18px; }
.kit-add-bar__input {
  flex: 1; min-width: 0; border: none; background: transparent; outline: none; color: inherit; font: inherit;
  padding: 4px 10px;
}
.kit-add-bar__add { flex: none; }

.kit-avatar {
  width: 30px; height: 30px; border-radius: 50%; display: grid; place-items: center; flex: none;
  font: 600 var(--look-caption)/1 var(--kit-font); color: #FFFFFF; background: color-mix(in oklab, var(--kit-hue) 60%, #3D3A36);
}

/* --------------------------------- dialogs -------------------------------- */
/* On the browser's own <dialog>: it traps focus and closes with Escape. */

.kit-dialog {
  width: min(var(--kit-dialog-width, 560px), calc(100vw - 24px)); max-height: calc(100dvh - 40px);
  padding: 0; border: 0; border-radius: var(--look-r-xl); background: var(--kit-panel); color: var(--kit-text);
  box-shadow: var(--kit-shadow-high); display: flex; flex-direction: column;
}
.kit-dialog:not([open]) { display: none; }
.kit-dialog--wide { width: min(760px, calc(100vw - 24px)); }
.kit-dialog::backdrop { background: var(--kit-scrim); }
/* One look in every module (Martin, 14/11): no line under the title nor over the buttons, and the
   room below. A module never paints its own header, body or footer over these. */
.kit-dialog__header { display: flex; align-items: center; gap: 8px; padding: 14px 10px 8px 20px; }
.kit-dialog__header h2, .kit-dialog__titles h2 { margin: 0; font: 700 var(--look-title3)/1.2 var(--kit-font-display); letter-spacing: -.01em; }
.kit-dialog__header h2 { flex: 1; }
.kit-dialog__body { padding: 6px 20px 14px; overflow-y: auto; display: grid; gap: 14px; }
.kit-dialog__body > p { margin: 0; }
/* Settings → Your data: what goes for good, asked before (settings.js sure()). */
.kit-sure > p { margin: 0; }
.kit-dialog__footer { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 8px; padding: 12px 16px 16px; }
.kit-dialog__grab { display: none; }
/* A form dialog (ui.js formDialog): a title with its subtitle, tools before the ×, a bar that stays
   and a form whose body alone scrolls, with the error inside it. */
.kit-dialog__titles { flex: 1; min-width: 0; }
.kit-dialog__header > :first-child:not(h2, .kit-dialog__titles) { flex: 1; min-width: 0; }
.kit-dialog__subtitle { margin: 2px 0 0; font-size: var(--look-subhead); color: var(--kit-muted); overflow-wrap: anywhere; }
.kit-dialog__tools { display: flex; align-items: center; gap: 2px; flex: none; }
.kit-dialog__form { display: flex; flex-direction: column; flex: 1 1 auto; min-height: 0; margin: 0; }
.kit-dialog__form > .kit-dialog__body { flex: 1 1 auto; min-height: 0; }
.kit-dialog__error { margin: 0; color: var(--kit-danger); font-size: var(--look-subhead); }
.kit-dialog__error[hidden], .kit-dialog__footer[hidden] { display: none; }
.kit-dialog__extra { padding: 0 20px 10px; }

/* On a phone, a sheet that rises from the bottom, within reach of the thumb. */
@media (max-width: 640px) {
  .kit-dialog, .kit-dialog--wide {
    width: 100vw; max-width: 100vw; max-height: 92dvh; margin: auto 0 0;
    border-radius: 20px 20px 0 0; padding-bottom: var(--kit-safe-bottom);
    animation: kit-rise .22s ease-out;
  }
  :root[data-look="clean"] :is(.kit-dialog, .kit-dialog--wide) { border-radius: var(--look-r-xl) var(--look-r-xl) 0 0; }
  .kit-dialog__grab { display: block; width: 40px; height: 4px; border-radius: 2px; background: var(--kit-border); margin: 8px auto 0; }
  .kit-dialog__footer .kit-btn { flex: 1; }
}
@keyframes kit-rise { from { transform: translateY(40px); opacity: .4; } }

/* ---------------------------------- menus --------------------------------- */

.kit-menu {
  position: fixed; z-index: 900; min-width: 220px; max-width: calc(100vw - 16px);
  background: var(--kit-panel); border: 1px solid var(--kit-border); border-radius: var(--look-r-lg);
  box-shadow: var(--kit-shadow-high); padding: 6px; display: grid; margin: 0;
}
.kit-menu__who { padding: 8px 10px 10px; border-bottom: 1px solid var(--kit-border); margin-bottom: 4px; font-size: var(--look-footnote); color: var(--kit-muted); overflow-wrap: anywhere; }
.kit-menu__who strong { display: block; color: var(--kit-text); font-size: var(--look-subhead); }
.kit-menu__item {
  display: flex; align-items: center; gap: 10px; padding: var(--look-item-y) 10px; border-radius: var(--look-r-sm); border: 0; background: none;
  cursor: pointer; text-align: start; color: var(--kit-text); font-size: var(--look-body); text-decoration: none; min-height: 40px;
}
.kit-menu__item:hover, .kit-menu__item:focus-visible { background: var(--kit-hover); outline: none; }
.kit-menu__item .kit-icon { width: 17px; height: 17px; color: var(--kit-muted); }
.kit-menu__image { width: 20px; height: 20px; border-radius: 6px; flex: none; display: block; margin-inline: -1px; }
.kit-menu__glyph { width: 20px; flex: none; text-align: center; font-size: 16px; line-height: 1; }
.kit-menu__item--danger, .kit-menu__item--danger .kit-icon { color: var(--kit-danger); }
.kit-menu__item .kit-menu__end { margin-inline-start: auto; }
/* The one in use now: its tick in the accent. */
.kit-menu__item[aria-current="true"] { font-weight: 600; }
.kit-menu__item[aria-current="true"] .kit-menu__end .kit-icon { color: var(--kit-accent); }
.kit-menu__sep { height: 1px; background: var(--kit-border); margin: 4px 6px; }

/* --------------------------------- notices -------------------------------- */

.kit-toasts {
  /* Over an add bar in sight, when ui.js measured one under them (--kit-toast-floor): never on it. */
  position: fixed; inset-inline: 12px; bottom: max(calc(16px + var(--kit-safe-bottom)), var(--kit-toast-floor, 0px)); z-index: 1000;
  display: grid; justify-items: center; gap: 8px; pointer-events: none;
}
/* Over an open dialog (ui.js toast), without the browser's popover look: a box in the middle, framed. */
.kit-toasts[popover] {
  top: auto; width: auto; height: auto; margin: 0; padding: 0; border: 0; background: none; color: inherit; overflow: visible;
}
.kit-toast {
  pointer-events: auto; display: flex; align-items: center; gap: 12px; max-width: min(460px, 100%);
  padding: 10px 10px 10px 14px; border-radius: var(--look-r-lg); background: var(--kit-toast); color: var(--kit-toast-text);
  box-shadow: var(--kit-shadow-high); font-size: var(--look-subhead); animation: kit-rise .18s ease-out;
}
.kit-toast > span { flex: 1; min-width: 0; }
.kit-toast--error { background: var(--kit-danger); color: #FFFFFF; }
.kit-toast__action {
  border: 0; background: none; color: inherit; font-weight: 600; padding: 6px 8px; border-radius: var(--look-r-sm); cursor: pointer;
  text-decoration: underline; text-underline-offset: 3px; flex: none;
}

/* One row however narrow: the text wraps, its button and the × stay beside it. */
.kit-banner {
  display: flex; align-items: center; gap: 10px; padding: 8px 8px 8px 16px; font-size: var(--look-subhead); line-height: 1.35;
  border-bottom: 1px solid var(--kit-border); background: var(--kit-panel);
}
.kit-banner > span { flex: 1 1 auto; min-width: 0; }
.kit-banner > .kit-btn { flex: none; }
.kit-banner > .kit-icon { color: var(--kit-muted); }
.kit-banner--warn { background: var(--kit-warn-soft); }
.kit-banner--warn > .kit-icon { color: var(--kit-warn); }
.kit-banner--accent { background: var(--kit-accent-soft); }
.kit-banner--accent > .kit-icon { color: var(--kit-accent); }
.kit-banner--danger { background: var(--kit-danger-soft); }
.kit-banner--danger > .kit-icon { color: var(--kit-danger); }
.kit-banner .kit-icon-btn { width: 32px; height: 32px; }

/* The state of a save, next to what is being saved. */
.kit-saved { display: inline-flex; align-items: center; gap: 5px; font-size: var(--look-footnote); color: var(--kit-muted); white-space: nowrap; }
.kit-saved .kit-icon { width: 14px; height: 14px; color: var(--kit-ok); }
.kit-saved .kit-spinner { width: 12px; height: 12px; }
.kit-saved--offline { color: var(--kit-warn); }
.kit-saved--offline .kit-icon { color: var(--kit-warn); }
.kit-saved--error, .kit-saved--error .kit-icon { color: var(--kit-danger); }
/* Who made an item and who changed it (ui.js stamps()): a line each, under its detail. */
.kit-stamps { display: flex; flex-direction: column; gap: 2px; min-width: 0; color: var(--kit-muted); font-size: var(--look-footnote); line-height: 1.4; }
.kit-stamps > span { overflow: hidden; text-overflow: ellipsis; }

/* The live channel: green while it is open. */
.kit-live { width: 8px; height: 8px; border-radius: 50%; flex: none; background: var(--kit-muted); transition: background .3s, box-shadow .3s; }
.kit-live[data-state="open"] { background: var(--kit-ok); box-shadow: 0 0 0 3px color-mix(in srgb, var(--kit-ok) 22%, transparent); }

/* ------------------------------ drag and drop ----------------------------- */
/* drag.js: what is picked up stays faded in its place, a card with its name and
   what letting go would do follows the pointer, and the place under it lights up. */

/* A finger held on a row picks it up: the phone's own menu and selection must not. */
.kit-draggable { -webkit-touch-callout: none; }
:root[data-kit-dragging], :root[data-kit-dragging] * { cursor: grabbing !important; user-select: none; -webkit-user-select: none; }
.kit-drag-source { opacity: .4; }
/* Physical left and top on purpose: it follows the pointer, whose coordinates are physical. */
.kit-drag-ghost {
  position: fixed; top: 0; left: 0; z-index: 1100; pointer-events: none; display: grid; gap: 3px;
  /* One column no wider than the card: a long title is cut, not carried past its edge. */
  grid-template-columns: minmax(0, 1fr);
  max-width: min(300px, calc(100vw - 8px)); padding: 9px 13px; border-radius: var(--look-r-lg);
  background: var(--kit-panel); color: var(--kit-text); border: 1px solid var(--kit-border);
  box-shadow: var(--kit-shadow-high); font-size: var(--look-subhead); line-height: 1.3;
}
.kit-drag-ghost > strong { font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.kit-drag-ghost__where { display: flex; align-items: flex-start; gap: 5px; font-size: var(--look-footnote); font-weight: 500; color: var(--kit-accent); }
/* Where it falls goes down to a second line before it is cut: "After …" is the part that has to be read. */
.kit-drag-ghost__where > span { min-width: 0; overflow: hidden; overflow-wrap: anywhere; display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; }
.kit-drag-ghost__where .kit-icon { width: 14px; height: 14px; flex: none; margin-top: 1px; }
.kit-drag-ghost--no .kit-drag-ghost__where { color: var(--kit-danger); }
.kit-drag-ghost__detail { font-size: var(--look-caption); color: var(--kit-muted); overflow: hidden; overflow-wrap: anywhere; display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; }
[data-drop-state="ok"] { background: var(--kit-accent-soft) !important; box-shadow: inset 0 0 0 2px var(--kit-accent); }
[data-drop-state="no"] { box-shadow: inset 0 0 0 1.5px var(--kit-border); opacity: .7; }
/* Between two rows: where it would sit, as a dashed gap the size of the row, which the rest make room for. */
.kit-drop-gap {
  display: block; box-sizing: border-box; list-style: none; flex: none; margin: 0; padding: 0;
  border: 2px dashed var(--kit-accent); border-radius: var(--look-r-md); background: var(--kit-accent-soft);
}
/* Something held over a place that opens what is behind it (☰, a tab) says it is about to. */
[data-drag-spring][data-spring-armed] { filter: brightness(1.12); }
/* On a phone, while a task is carried that may also stay in the list: a tab at the start edge opens
   the drawer as soon as the finger reaches it, and one at the end edge, beside the open drawer, closes
   it (shell.js). Each takes more than its drawn pill, and slides in from its edge and out again. */
.kit-drag-tab {
  position: absolute; top: 50%; z-index: 40; width: 60px; height: 180px; margin-top: -90px;
  display: flex; align-items: center; visibility: hidden; pointer-events: none;
  transition: visibility 0s linear var(--kit-slide-time);
}
.kit-drag-tab--open { inset-inline-start: 0; justify-content: flex-start; }
.kit-drag-tab--back { inset-inline-end: 0; justify-content: flex-end; }
.kit-drag-tab__pill {
  display: flex; align-items: center; justify-content: center; width: 38px; height: 112px;
  background: var(--kit-accent); color: var(--kit-on-accent); box-shadow: var(--kit-shadow-high); opacity: 0;
  transition: transform var(--kit-slide-time) var(--kit-slide), opacity .18s ease, width .15s ease;
}
.kit-drag-tab__pill .kit-icon { width: 20px; height: 20px; }
.kit-drag-tab--open .kit-drag-tab__pill { border-start-end-radius: var(--look-r-xl); border-end-end-radius: var(--look-r-xl); transform: translateX(-110%); }
.kit-drag-tab--back .kit-drag-tab__pill { border-start-start-radius: var(--look-r-xl); border-end-start-radius: var(--look-r-xl); transform: translateX(110%); }
[dir="rtl"] .kit-drag-tab--open .kit-drag-tab__pill { transform: translateX(110%); }
[dir="rtl"] .kit-drag-tab--back .kit-drag-tab__pill { transform: translateX(-110%); }
.kit-app[data-drag-tabs]:not([data-drawer]) .kit-drag-tab--open,
.kit-app[data-drag-tabs][data-drawer] .kit-drag-tab--back { visibility: visible; pointer-events: auto; transition-delay: 0s; }
.kit-app[data-drag-tabs]:not([data-drawer]) .kit-drag-tab--open .kit-drag-tab__pill,
.kit-app[data-drag-tabs][data-drawer] .kit-drag-tab--back .kit-drag-tab__pill { transform: none; opacity: 1; }
.kit-drag-tab[data-spring-armed] .kit-drag-tab__pill { width: 48px; }
/* The gap grows where it is going and the one it leaves shrinks, at once: the rows between slide to
   their place instead of jumping (drag.js). One closing is no place to drop on. */
.kit-drop-gap { animation: kit-gap-open .2s var(--kit-slide); }
.kit-drop-gap--closing { animation: kit-gap-close .2s var(--kit-slide) forwards; pointer-events: none; overflow: hidden; }
/* A list with gaps between its rows (flex, grid) puts one more beside the gap at once: a negative margin of that size
   (--kit-gap-space, drag.js) takes it back while the gap is shut, or the rows would hop by it at the start and the end. */
@keyframes kit-gap-open { from { height: 0; opacity: 0; border-width: 0; margin-block-start: calc(-1 * var(--kit-gap-space, 0px)); } }
@keyframes kit-gap-close { to { height: 0; opacity: 0; border-width: 0; margin-block-start: calc(-1 * var(--kit-gap-space, 0px)); margin-block-end: 0; } }
/* Rows level with something beside them (a chart's bars) can't move: a dashed line, and nothing moves. */
.kit-drop-gap--thin { height: 0; border: 0; border-radius: 0; background: none; outline: 1px dashed var(--kit-accent); outline-offset: 0; }

/* ------------------------------- row swipes ------------------------------- */
/* swipe.js: a finger across a row slides it over what letting go would do, its
   icon and its words, faint and grey until reached, then in the action's colour.
   Sideways pans on the row are the swipe's; up and down is still the list's. The
   colours are the kit's variables, so the dark theme and the Clean look follow. */

.kit-swipe { position: relative; touch-action: pan-y; }
.kit-swipe__bg {
  position: absolute; inset: 0; z-index: 0; display: none; align-items: center; justify-content: flex-start;
  padding-inline: 18px; border-radius: inherit; overflow: hidden; pointer-events: none;
  background: var(--kit-hover); color: var(--kit-text); font-size: var(--look-body);
  user-select: none; -webkit-user-select: none; transition: background-color .18s, color .18s;
}
/* While swiped, and under what slides until it is back in place. */
.kit-swipe[data-swiping] > .kit-swipe__bg, .kit-swipe[data-swipe-settling] > .kit-swipe__bg { display: flex; }
/* What a swipe to the right does sits at the line's start, what one to the left does at its end. */
.kit-swipe__bg[data-side="left"] { justify-content: flex-end; }
/* What slides inside the row goes over the colour, which the row's edges cut (Tasks' rows). */
.kit-swipe__content { position: relative; z-index: 1; }
.kit-swipe[data-swipe="under"]:is([data-swiping], [data-swipe-settling]) { overflow: hidden; }
/* The row slides itself (Notes' button): the colour fills the room it leaves, beside it (its left and
   width are physical, set by swipe.js, as the finger's way is). */
.kit-swipe[data-swipe="beside"][data-swiping] { overflow: visible; }
.kit-swipe[data-swipe="beside"] > .kit-swipe__bg { inset: 0 auto; padding-inline: 14px; }
.kit-swipe__action { display: flex; align-items: center; gap: 8px; min-width: 0; opacity: .35; transition: opacity .15s, transform .15s; }
.kit-swipe__action[data-armed] { opacity: 1; transform: scale(1.06); }
.kit-swipe__icon { display: grid; place-items: center; flex: none; }
.kit-swipe__icon .kit-icon { width: 20px; height: 20px; }
.kit-swipe__label { font-size: var(--look-footnote); font-weight: 600; letter-spacing: .01em; white-space: nowrap; }
.kit-swipe__bg[data-tone="danger"] { background: var(--kit-danger); color: #FFFFFF; }
.kit-swipe__bg[data-tone="accent"] { background: var(--kit-accent); color: var(--kit-on-accent); }
/* Yolk marks "now": My Day. Ink on it, as on every yolk. */
.kit-swipe__bg[data-tone="sun"] { background: var(--kit-now); color: var(--cr-ink); }
.kit-swipe__bg[data-tone="done"] { background: var(--kit-ok); color: #FFFFFF; }
/* In the dark the red and the green are light: ink reads on them. */
:root[data-theme="dark"] .kit-swipe__bg:is([data-tone="danger"], [data-tone="done"]) { color: var(--cr-ink); }

/* ------------------------------- app frame -------------------------------- */
/*
 * shell.js: a sidebar and the app's views beside it. On a phone the sidebar is
 * a drawer and a list and its detail are two screens; on a tablet or a
 * computer it can be folded away (`data-folded`), and the bar with ☰ comes
 * back to unfold it. Container queries, so the frame answers to its own width.
 */

.kit-app {
  container: kit-app / inline-size; position: fixed; inset: 0; background: var(--kit-bg);
  /* The sidebar's width beside the views; an app laying out its own columns uses it too. */
  --kit-side-width: 260px;
}
.kit-shell {
  position: absolute; inset: 0; display: grid; overflow: hidden;
  grid-template-columns: minmax(0, 1fr);
  grid-template-rows: auto auto minmax(0, 1fr);
  grid-template-areas: "bar" "banners" "main";
}

.kit-bar {
  grid-area: bar; display: flex; align-items: center; gap: 2px; min-width: 0;
  min-height: calc(54px + var(--kit-safe-top)); padding: var(--kit-safe-top) 8px 0;
  background: var(--kit-bg); border-bottom: 1px solid var(--kit-border);
}
.kit-bar__title {
  flex: 1; min-width: 0; padding-inline: 6px; font-weight: 600; font-size: var(--look-headline);
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.kit-bar__actions { display: flex; align-items: center; gap: 2px; flex: none; }
.kit-app:not([data-screen="detail"]) .kit-bar__back,
.kit-app[data-screen="detail"] .kit-bar__menu { display: none; }

.kit-appicon { width: 30px; height: 30px; border-radius: 8px; flex: none; display: block; }
.kit-appname { font: 700 max(17px, var(--look-headline))/1 var(--kit-font-display); letter-spacing: -.02em; white-space: nowrap; }

.kit-banners { grid-area: banners; }
.kit-pane { grid-area: main; min-width: 0; min-height: 0; overflow-y: auto; overscroll-behavior: contain; background: var(--kit-bg); }
.kit-app[data-screen="detail"] .kit-pane--list,
.kit-app:not([data-screen="detail"]) .kit-pane--detail,
.kit-app[data-panes="single"] .kit-pane--detail { display: none; }
.kit-app[data-panes="single"] .kit-pane--list { display: block; }
/* Going back from a phone's detail with a finger (shell.js): the list beneath, the detail over it. */
.kit-app[data-back-swipe] .kit-pane--list { display: block; }
.kit-app[data-back-swipe] .kit-pane--detail { position: relative; z-index: 1; }

/* The sidebar, a drawer on a phone. */
.kit-side {
  position: absolute; inset-block: 0; inset-inline-start: 0; z-index: 30; width: min(290px, 86%);
  display: flex; flex-direction: column; min-height: 0; background: var(--kit-side);
  padding-top: var(--kit-safe-top); transform: translateX(-105%); visibility: hidden;
  /* Closing, it stays visible until it has slid out; opening, it is visible from the start. */
  transition: transform var(--kit-slide-time) var(--kit-slide), visibility 0s linear var(--kit-slide-time);
}
[dir="rtl"] .kit-side { transform: translateX(105%); }
.kit-app[data-drawer] .kit-side { transform: none; visibility: visible; box-shadow: var(--kit-shadow-high); transition-delay: 0s; }
.kit-scrim { position: absolute; inset: 0; z-index: 25; background: var(--kit-scrim); opacity: 0; pointer-events: none; transition: opacity var(--kit-slide-time) ease; }
.kit-app[data-drawer] .kit-scrim { opacity: 1; pointer-events: auto; }
/* A finger drags the drawer (shell.js): it is where the finger is, and slides only once it lets go. */
.kit-app[data-drawer-drag] .kit-side, .kit-app[data-drawer-drag] .kit-scrim { transition: none; }
.kit-side__head { display: flex; align-items: center; gap: 10px; padding: 14px 14px 10px; }
.kit-side__head .kit-appname { flex: 1; }
/* Folding is for where the sidebar sits beside the views; in the drawer it would mean nothing. */
.kit-side__fold { display: none; width: 32px; height: 32px; margin-inline-end: -6px; }
/* In Work's shell the head holds only that button: none in the drawer, at the end beside the views. */
.kit-app[data-embedded] .kit-side__head { display: none; justify-content: flex-end; padding: 8px 12px 4px; }
/* The module's search, the sidebar's first line: as far from its top as from its sides. */
.kit-side__search {
  display: flex; align-items: center; gap: 8px; margin: 12px 12px 6px; padding: 0 12px; min-height: 42px;
  border: 1px solid var(--kit-border); border-radius: var(--look-r-md); background: var(--kit-bg); color: var(--kit-muted);
}
/* Under the app's name (an app on its own, or beside the views in Work), the head gives the room above. */
.kit-app:not([data-embedded]) .kit-side__search { margin-top: 0; }
.kit-side__search:focus-within { border-color: var(--kit-accent); box-shadow: 0 0 0 3px var(--kit-accent-soft); }
.kit-side__search .kit-icon { width: 16px; height: 16px; flex: none; }
/* The box shows the focus (:focus-within): a module's own input:focus ring would draw a second inside it. */
.kit-side__search .kit-side__search-input:focus { box-shadow: none; outline: none; }
/* In Work's shell, with a search (shell.js), the button that folds shares its line: no line of its own. */
.kit-side__top { display: flex; align-items: center; gap: 4px; margin: 12px 12px 6px; }
.kit-side__top .kit-side__search { flex: 1; min-width: 0; margin: 0; }
.kit-side__top .kit-side__fold { margin-inline-end: -4px; }
.kit-side__search-input {
  flex: 1; min-width: 0; padding: 9px 0; border: 0; background: none; outline: none; color: var(--kit-text);
  /* 16px or more: below it an iPhone zooms the page in on tapping it. Its own line height, not the
     page's: Notes' 1.5 made its box a pixel taller than the other modules', its magnifier lower. */
  font: inherit; font-size: max(16px, var(--look-body)); line-height: 1.45;
}
/* The kit's word in it («Buscar») in the kit's faint colour, light or dark: not the browser's grey. */
.kit-side__search-input::placeholder { color: var(--kit-faint); opacity: 1; }
/* «/» goes to the search (shell.js): its key, beside the word and never in it (it wouldn't fit), only on a
   big screen with a mouse or a trackpad, the sidebar beside the views; gone while the field has the focus
   or something typed. */
/* A key, where Settings › About lists them. */
.kit-keys { display: inline-flex; gap: 4px; flex: none; }
.kit-key { min-width: 22px; padding: 0 6px; border: 1px solid var(--kit-border); border-radius: 5px; color: var(--kit-text); font: 500 12px/20px var(--kit-font-mono); text-align: center; }
.kit-side__search-key {
  display: none; flex: none; min-width: 20px; padding: 0 5px; border: 1px solid var(--kit-border); border-radius: 5px;
  color: var(--kit-faint); font: 500 12px/18px var(--kit-font-mono); text-align: center;
}
@media (hover: hover) and (pointer: fine) {
  @container kit-app (min-width: 640px) {
    .kit-app[data-layout="side"] .kit-side__search-key { display: block; }
  }
}
.kit-app .kit-side__search:focus-within .kit-side__search-key,
.kit-app .kit-side__search-input:not(:placeholder-shown) + .kit-side__search-key { display: none; }
.kit-side__nav { flex: 1; overflow-y: auto; padding: 0 8px calc(10px + var(--kit-safe-bottom)); display: grid; grid-template-columns: minmax(0, 1fr); align-content: start; gap: 1px; }
/*
 * The sidebar's foot (shell.js `foot`): the + that makes a collection at its start, the trash at
 * its end. It never scrolls away, in the drawer or beside the views: the nav scrolls above it, and
 * the room over the phone's bottom edge is the foot's, not left at the end of the nav.
 */
.kit-side__nav:has(+ .kit-side__foot) { padding-bottom: 10px; }
.kit-side__foot {
  flex: none; display: flex; align-items: center; gap: 4px; margin-inline: 8px;
  padding: 4px 0 calc(6px + var(--kit-safe-bottom)); border-top: 1px solid var(--kit-border);
}
.kit-side__trash { margin-inline-start: auto; }
.kit-side__foot .kit-icon-btn[aria-expanded="true"] { background: var(--kit-hover); color: var(--kit-text); }
/* Notes' trash is a view: open, it is marked as an entry of the sidebar is. */
.kit-side__trash[aria-current="page"] { background: var(--kit-accent-soft); color: var(--kit-accent); }

.kit-nav__section { font: var(--kit-eyebrow-weight) var(--kit-eyebrow-size)/1 var(--kit-font); letter-spacing: var(--kit-eyebrow-spacing); text-transform: uppercase; color: var(--kit-muted); padding: 16px 8px 6px; }
/* A heading that folds its group (shell.js navFold): the same words, a button with a chevron. */
.kit-nav__group, .kit-nav__fold-body { display: grid; grid-template-columns: minmax(0, 1fr); gap: 1px; }
.kit-nav__fold-body[hidden] { display: none; }
.kit-nav__fold {
  display: flex; align-items: center; gap: 6px; width: 100%; border: 0; background: none; text-align: start;
  cursor: pointer; border-radius: var(--look-r-sm);
}
.kit-nav__fold:hover { color: var(--kit-text); }
.kit-nav__fold:focus-visible { outline-offset: -2px; }
.kit-nav__fold-chevron { width: 12px; height: 12px; flex: none; transition: transform .3s ease; }
.kit-nav__fold[aria-expanded="true"] .kit-nav__fold-chevron { transform: rotate(90deg); }
@media (prefers-reduced-motion: reduce) { .kit-nav__fold-chevron { transition: none; } }
/* Its own line height, as the search's: the page's (1.5 in the kit, 1.45 in some modules) made an entry 36.5 px tall in one module and 36 in the others. */
.kit-nav__item {
  display: flex; align-items: center; gap: 10px; width: 100%; min-height: 36px; line-height: 1.45; padding: 7px 8px; border-radius: var(--look-r-sm);
  border: 0; background: none; color: var(--kit-text); text-decoration: none; text-align: start; cursor: pointer;
}
.kit-nav__item:hover { background: var(--kit-hover); }
/* The list scrolls and would cut a ring drawn outside the entry: it goes inside. The drawer itself
   takes the focus when a finger opens it, with nothing drawn. */
.kit-nav__item:focus-visible { outline-offset: -2px; }
.kit-side__nav:focus { outline: none; }
.kit-nav__item[aria-current="page"] { background: var(--kit-accent-soft); font-weight: 600; }
.kit-nav__item .kit-icon { color: var(--kit-muted); width: 17px; height: 17px; }
.kit-nav__item[aria-current="page"] .kit-icon { color: var(--kit-accent); }
.kit-nav__item--now, .kit-nav__item--now .kit-icon { color: var(--kit-now-text); }
.kit-nav__item--now .kit-icon { color: var(--kit-now); }
.kit-nav__label { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
/* The name with something under it (navItem `under`: a project's progress), in the name's column. */
.kit-nav__body { position: relative; flex: 1; min-width: 0; display: grid; }
.kit-nav__count { font: 400 var(--look-footnote) var(--kit-font-mono); color: var(--kit-muted); font-variant-numeric: tabular-nums; }
/* As wide as a view's icon with its margins (17): a colour's label starts in line with a view's. */
.kit-nav__swatch { width: 10px; height: 10px; border-radius: var(--look-r-xs); flex: none; margin-inline: 3.5px; }
/* A collection's own emoji, as wide as a view's icon: every label of the sidebar starts in line (navItem). */
.kit-nav__emoji { display: inline-grid; place-items: center; width: 17px; height: 17px; flex: none; font-size: max(16px, var(--look-callout)); line-height: 1; overflow: visible; }
/* Its icon with marks on its corners: a shared one's, a public page's (navItem `shared`, `marks`). */
.kit-nav__lead { position: relative; display: inline-grid; place-items: center; width: 17px; height: 17px; flex: none; }
.kit-nav__lead > .kit-nav__swatch { margin: 0; }
/* Shared: two people on the bottom corner, the same in every module (sharedMark). */
.kit-nav__shared {
  position: absolute; inset-inline-end: -6px; inset-block-end: -4px; width: 14px; height: 14px; border-radius: 50%;
  display: grid; place-items: center; background: var(--kit-side); box-shadow: 0 0 0 1px var(--kit-border-strong);
}
.kit-nav__item .kit-nav__shared .kit-icon, .kit-nav__shared .kit-icon { width: 9px; height: 9px; color: var(--kit-muted); stroke-width: 2.6; }
/* After a group's name, having no icon of its own to sit on (navGroup `extra`). */
.kit-nav-group__name > .kit-nav__shared { position: static; flex: none; }
/* An entry with a menu (menuOnPress): a long press is its menu, not the browser's nor a selection. */
[data-kit-menu] { -webkit-touch-callout: none; -webkit-user-select: none; user-select: none; }

/*
 * A group of collections (shell.js navGroup), the same in every module: its head in the group's
 * colour (a border at its start, a tint behind, its name between the colour and the text's), its
 * collections a step in under it. Mixed with the kit's own colours, so light and dark both follow.
 */
.kit-nav-group { display: grid; grid-template-columns: minmax(0, 1fr); margin-block: 6px 2px; }
.kit-nav-group__head {
  display: flex; align-items: center; gap: 2px; min-height: 36px; line-height: 1.45; padding-inline: 2px 4px; margin-block-end: 2px;
  border-radius: var(--look-r-sm); border-inline-start: 3px solid var(--group-color, var(--kit-muted));
  background: color-mix(in oklab, var(--group-color, var(--kit-muted)) 12%, transparent);
  color: color-mix(in oklab, var(--group-color, var(--kit-muted)) 50%, var(--kit-text));
}
:root[data-theme="dark"] .kit-nav-group__head { background: color-mix(in oklab, var(--group-color, var(--kit-muted)) 18%, transparent); }
.kit-nav-group__toggle, .kit-nav-group__name {
  display: inline-flex; align-items: center; min-height: 32px; border: 0; border-radius: var(--look-r-sm);
  background: none; color: inherit; font: inherit; cursor: pointer;
}
.kit-nav-group__toggle { justify-content: center; width: 28px; flex: none; padding: 0; }
.kit-nav-group__toggle .kit-icon { width: 14px; height: 14px; transition: transform .3s ease; }
.kit-nav-group__toggle[aria-expanded="true"] .kit-icon { transform: rotate(90deg); }
@media (prefers-reduced-motion: reduce) { .kit-nav-group__toggle .kit-icon { transition: none; } }
.kit-nav-group__name { flex: 1; min-width: 0; gap: 6px; padding-inline: 4px; font-weight: 650; font-size: var(--look-callout); text-align: start; }
.kit-nav-group__label { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.kit-nav-group__icon { display: inline-grid; place-items: center; width: 20px; flex: none; font-size: max(16px, var(--look-callout)); line-height: 1; }
.kit-nav-group__icon .kit-icon { width: 16px; height: 16px; }
.kit-nav-group__head :is(.kit-nav-group__toggle, .kit-nav-group__name):hover,
.kit-nav-group__name[aria-expanded="true"] { background: color-mix(in oklab, var(--group-color, var(--kit-muted)) 14%, transparent); }
.kit-nav-group__head :is(.kit-nav-group__toggle, .kit-nav-group__name):focus-visible { outline-offset: -2px; }
.kit-nav-group__head .kit-nav__count { padding-inline: 4px; }
.kit-nav-group__body { display: grid; grid-template-columns: minmax(0, 1fr); gap: 1px; padding-inline-start: 12px; }
.kit-nav-group__empty { padding: 4px 10px 6px; font-size: var(--look-footnote); color: var(--kit-muted); }

/*
 * What creates an item (shell.js `create`), at every width: at the bottom end corner of the pane
 * that holds the list, its grid area being its box. So it stays inside the module's frame (its
 * window in Cronum Work), over the list and never over a detail beside it. Not on a phone's
 * detail, which covers the list.
 */
.kit-fab {
  position: absolute; grid-area: main; inset-inline-end: 16px; bottom: calc(16px + var(--kit-safe-bottom)); z-index: 10;
  width: 56px; height: 56px; border-radius: var(--look-r-xl); border: 0; background: var(--kit-accent); color: var(--kit-on-accent);
  display: grid; place-items: center; box-shadow: var(--kit-shadow-high); cursor: pointer;
}
.kit-fab .kit-icon { width: 24px; height: 24px; }
.kit-app[data-screen="detail"] .kit-fab { display: none; }

/* A tablet: the sidebar stays; the list and its detail are still two screens. */
@container kit-app (min-width: 640px) {
  .kit-app[data-layout="side"] .kit-shell {
    grid-template-columns: var(--kit-side-width) minmax(0, 1fr);
    grid-template-rows: auto auto minmax(0, 1fr);
    grid-template-areas: "side bar" "side banners" "side main";
  }
  .kit-app[data-layout="side"] .kit-side {
    position: static; grid-area: side; width: auto; transform: none; visibility: visible; box-shadow: none;
    border-inline-end: 1px solid var(--kit-border);
  }
  .kit-app[data-layout="side"] .kit-scrim, .kit-app[data-layout="side"] .kit-bar__menu { display: none; }
  .kit-side__fold { display: inline-grid; }
  .kit-app[data-embedded][data-layout="side"] .kit-side__head { display: flex; }
  .kit-app[data-embedded][data-layout="side"] .kit-side__search { margin-top: 0; }
}

/* A computer: the list and its detail side by side. */
@container kit-app (min-width: 960px) {
  .kit-app[data-layout="side"][data-panes="split"] .kit-shell {
    grid-template-columns: var(--kit-side-width) minmax(260px, 340px) minmax(0, 1fr);
    grid-template-rows: auto minmax(0, 1fr);
    grid-template-areas: "side banners banners" "side list detail";
  }
  .kit-app[data-layout="side"] .kit-shell {
    grid-template-rows: auto minmax(0, 1fr);
    grid-template-areas: "side banners" "side main";
  }
  .kit-app[data-layout="side"] .kit-bar { display: none; }
  .kit-app[data-panes="split"] .kit-pane--list { grid-area: list; display: block; border-inline-end: 1px solid var(--kit-border); }
  .kit-app[data-panes="split"] .kit-pane--detail { grid-area: detail; display: block; }
  /* Beside its detail the list stays in sight, and so does what creates: over the list, never the detail. */
  .kit-app[data-panes="split"] .kit-fab { grid-area: list; display: grid; }
}

/*
 * Folded away (shell.js): the views take the whole width, under the bar whose
 * ☰ unfolds it. Something carried brings it over them as a drawer, as on a
 * phone, and it goes again when the drag ends. The detail as a column of its
 * own (createShell({ detail: 'column' }), below) has its folded version there.
 */
@container kit-app (min-width: 640px) {
  .kit-app[data-layout="side"][data-folded] .kit-shell {
    grid-template-columns: minmax(0, 1fr);
    grid-template-rows: auto auto minmax(0, 1fr);
    grid-template-areas: "bar" "banners" "main";
  }
  .kit-app[data-layout="side"][data-folded] .kit-bar { display: flex; }
  .kit-app[data-layout="side"][data-folded] .kit-bar__menu { display: inline-grid; }
  .kit-app[data-layout="side"][data-folded] .kit-side { display: none; }
  .kit-app[data-layout="side"][data-folded] .kit-scrim { display: block; }
  .kit-app[data-layout="side"][data-folded][data-drawer] .kit-side {
    display: flex; position: absolute; inset-block: 0; inset-inline-start: 0; width: var(--kit-side-width); box-shadow: var(--kit-shadow-high);
  }
  .kit-app[data-layout="side"][data-folded][data-drawer] .kit-side__fold { display: none; }
}
@container kit-app (min-width: 960px) {
  .kit-app[data-layout="side"][data-panes="split"][data-folded] .kit-shell {
    grid-template-columns: minmax(260px, 340px) minmax(0, 1fr);
    grid-template-rows: auto auto minmax(0, 1fr);
    grid-template-areas: "bar bar" "banners banners" "list detail";
  }
  /* The detail is beside the list here: nothing to go back from. */
  .kit-app[data-layout="side"][data-panes="split"][data-folded] .kit-bar__back { display: none; }
}

/*
 * The detail as a column of its own (createShell({ detail: 'column' }), Tasks and Projects): from
 * 960 px the list takes the whole width while nothing is open, and the item opens as a column on
 * its right (`shell.setDetailOpen()`, `data-detail-open`), the list being what is read and the
 * item what is touched now and then. Folded away, the same under the bar. Below, the kit's two
 * screens, as any split frame.
 */
@container kit-app (min-width: 960px) {
  .kit-app[data-detail="column"][data-layout="side"][data-panes="split"] .kit-shell {
    grid-template-columns: var(--kit-side-width, 260px) minmax(0, 1fr);
    grid-template-areas: "side banners" "side list";
  }
  .kit-app[data-detail="column"][data-layout="side"][data-panes="split"][data-detail-open] .kit-shell {
    grid-template-columns: var(--kit-side-width, 260px) minmax(0, 1fr) minmax(340px, 400px);
    grid-template-areas: "side banners banners" "side list detail";
  }
  .kit-app[data-detail="column"]:not([data-detail-open]) .kit-pane--detail { display: none; }
  .kit-app[data-detail="column"][data-folded][data-layout="side"][data-panes="split"] .kit-shell {
    grid-template-columns: minmax(0, 1fr);
    grid-template-rows: auto auto minmax(0, 1fr);
    grid-template-areas: "bar" "banners" "list";
  }
  .kit-app[data-detail="column"][data-folded][data-layout="side"][data-panes="split"][data-detail-open] .kit-shell {
    grid-template-columns: minmax(0, 1fr) minmax(340px, 400px);
    grid-template-areas: "bar bar" "banners banners" "list detail";
  }
}

/*
 * The modules of a host (shell.js, in Cronum Work). The app's icon and name at
 * the sidebar's head are a button whose menu has the other modules and
 * Settings: on a phone, that is how one changes module, and the drawer keeps
 * all its width. Where the sidebar stays, a rail at its start has each module
 * the person uses, the host's home above them and Settings at its foot. In an
 * app on its own the same button opens Settings, with their icon in place of
 * the arrow. The rail is ink in both themes, as the brand's frame around the
 * products' colours.
 */
.kit-side__app {
  display: flex; align-items: center; gap: 10px; flex: 1; min-width: 0; margin: -5px -6px; padding: 5px 6px;
  border: 0; border-radius: var(--look-r-md); background: none; color: var(--kit-text); cursor: pointer; text-align: start;
}
.kit-side__app:hover, .kit-side__app[aria-expanded="true"] { background: var(--kit-hover); }
.kit-side__app .kit-appname { flex: 0 1 auto; min-width: 0; overflow: hidden; text-overflow: ellipsis; }
.kit-side__app .kit-icon { width: 16px; height: 16px; flex: none; color: var(--kit-muted); }
.kit-side__app[aria-expanded="true"] .kit-icon { transform: rotate(180deg); }
.kit-side__app:focus-visible { outline: 2px solid var(--kit-accent); outline-offset: 1px; }
.kit-app[data-rail] { --kit-side-width: 326px; }
.kit-side__main { flex: 1; min-width: 0; min-height: 0; display: flex; flex-direction: column; }
.kit-side[data-rail] { flex-direction: row; padding-top: 0; }
.kit-side[data-rail] .kit-side__main { padding-top: var(--kit-safe-top); }
.kit-rail {
  flex: none; width: 66px; display: none; flex-direction: column; align-items: center; gap: 4px; overflow-y: auto;
  padding: calc(12px + var(--kit-safe-top)) 0 calc(12px + var(--kit-safe-bottom)); background: var(--cr-ink);
}
.kit-rail__home { display: grid; place-items: center; width: 44px; height: 44px; margin-bottom: 8px; border-radius: var(--look-r-lg); color: var(--cr-cream); }
.kit-rail__home img { width: 32px; height: 32px; border-radius: 9px; display: block; }
.kit-rail__module {
  position: relative; display: flex; flex-direction: column; align-items: center; gap: 3px; width: 58px; padding: 6px 2px;
  border-radius: var(--look-r-lg); color: var(--cr-stone-dark); text-decoration: none;
}
.kit-rail__module img { width: 28px; height: 28px; border-radius: 8px; display: block; }
.kit-rail__name { font: 500 var(--look-caption2)/1.2 var(--kit-font); max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.kit-rail__module:hover { background: rgba(255, 247, 230, .08); }
.kit-rail__module[aria-current="page"] { background: rgba(255, 247, 230, .12); color: var(--cr-cream); }
/* The module open now: its colour at the rail's edge. */
.kit-rail__module[aria-current="page"]::before {
  content: ''; position: absolute; inset-inline-start: -4px; inset-block: 10px; width: 4px; border-radius: 0 4px 4px 0;
  background: var(--module, var(--cr-cream));
}
.kit-rail__settings {
  display: grid; place-items: center; flex: none; width: 44px; height: 44px; margin-top: auto; border: 0; border-radius: var(--look-r-lg);
  background: none; color: var(--cr-stone-dark); cursor: pointer;
}
.kit-rail__settings .kit-icon { width: 20px; height: 20px; }
.kit-rail__settings:hover { background: rgba(255, 247, 230, .08); color: var(--cr-cream); }
/* The host's calendar, a link to its page: at the rail's foot too, over Settings. */
.kit-rail__calendar {
  display: grid; place-items: center; flex: none; width: 44px; height: 44px; margin-top: auto; border-radius: var(--look-r-lg);
  color: var(--cr-stone-dark); text-decoration: none;
}
.kit-rail__calendar .kit-icon { width: 20px; height: 20px; }
.kit-rail__calendar:hover { background: rgba(255, 247, 230, .08); color: var(--cr-cream); }
.kit-rail__calendar + .kit-rail__settings { margin-top: 0; }
.kit-rail a:focus-visible, .kit-rail button:focus-visible { outline: 2px solid var(--cr-cream); outline-offset: 1px; }
/* The Clean look, light: a white rail with a hairline, the modules' names in grey and the open one in ink. */
:root[data-look="clean"]:not([data-theme="dark"]) .kit-rail {
  background: var(--kit-panel); border-inline-end: 1px solid var(--kit-border);
}
:root[data-look="clean"]:not([data-theme="dark"]) :is(.kit-rail__module, .kit-rail__settings, .kit-rail__calendar) { color: var(--kit-muted); }
:root[data-look="clean"]:not([data-theme="dark"]) :is(.kit-rail__module, .kit-rail__settings, .kit-rail__calendar):hover {
  background: var(--kit-hover); color: var(--kit-text);
}
:root[data-look="clean"]:not([data-theme="dark"]) .kit-rail__module[aria-current="page"] { background: var(--kit-hover); color: var(--kit-text); }
:root[data-look="clean"]:not([data-theme="dark"]) .kit-rail__home { color: var(--kit-text); }
:root[data-look="clean"]:not([data-theme="dark"]) .kit-rail :is(a, button):focus-visible { outline-color: var(--kit-accent); }
@container kit-app (min-width: 640px) {
  .kit-rail { display: flex; }
}

/* From one module to another (a host's rail, its menu on a phone) is a page of the same site
   after another: one fades into the next instead of a cut, and the rail, the same in both,
   stays where it is. Browsers without view transitions go on with the cut; whoever asks for
   less motion gets the cut too. */
@view-transition { navigation: auto; }
.kit-rail { view-transition-name: kit-rail; }
::view-transition-old(root), ::view-transition-new(root) { animation-duration: 200ms; }
@media (prefers-reduced-motion: reduce) {
  @view-transition { navigation: none; }
}

/* ------------------------------- view heads ------------------------------- */
/*
 * shell.head(): a view's head, the same in every app. The title and the app's
 * «…»; ☰ (← over a phone's detail) follows the bar's own rules above, by its
 * class, and a detail beside its list ends with × instead of ←. A pane showing
 * a head takes the bar's place: the bar gives way, and the head keeps the
 * clock's gap it kept.
 */
.kit-head {
  container: kit-head / inline-size; position: sticky; inset-block-start: 0; z-index: 4;
  padding: calc(8px + var(--kit-safe-top)) var(--look-gutter) var(--look-head-y); background: var(--kit-bg); border-bottom: 1px solid var(--kit-border);
}
.kit-head__row { display: flex; align-items: center; gap: 8px; min-width: 0; min-height: 40px; }
/* ☰ and ← sit on the head's edge, their icon where the title's margin would be. */
.kit-head__row > .kit-bar__menu, .kit-head__row > .kit-bar__back { margin-inline-start: -8px; }
.kit-head__title {
  flex: 1; min-width: 0; margin: 0; font: 700 var(--look-large-title)/1.2 var(--kit-font-display); letter-spacing: -.02em;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
/* The collection open's own emoji, loose before the title (head({ icon })), the same in every module. */
.kit-head__icon { flex: none; font-size: var(--look-title1); line-height: 1; }
.kit-head__icon[hidden] { display: none; }
.kit-head__actions { display: flex; align-items: center; gap: 4px; flex: none; }
.kit-head__actions:empty { display: none; }
/* A detail's ×, last on its line: only where ← doesn't show, the list and its detail side by side (below). */
.kit-head__close { display: none; }

.kit-app:not([data-screen="detail"]):has(.kit-pane--list .kit-head) .kit-bar,
.kit-app[data-screen="detail"]:has(.kit-pane--detail .kit-head) .kit-bar { display: none; }
/*
 * With the bar gone, a banner is the first thing on the screen: it keeps the clock's gap, in its
 * own colour, and the head under it no longer needs it. Without this, in an iPhone's installed
 * app the banner went under the clock and the head kept an empty gap below it.
 */
.kit-app:not([data-screen="detail"]):has(.kit-pane--list .kit-head):has(.kit-banners > *) .kit-banners > :first-child,
.kit-app[data-screen="detail"]:has(.kit-pane--detail .kit-head):has(.kit-banners > *) .kit-banners > :first-child {
  padding-top: calc(8px + var(--kit-safe-top));
}
.kit-app:not([data-screen="detail"]):has(.kit-pane--list .kit-head):has(.kit-banners > *) .kit-head,
.kit-app[data-screen="detail"]:has(.kit-pane--detail .kit-head):has(.kit-banners > *) .kit-head { padding-top: 8px; }
@container kit-app (min-width: 960px) {
  /* The list and its detail side by side: the list's head has ☰, nothing goes back, and × closes the detail. */
  .kit-app[data-panes="split"]:has(.kit-pane--list .kit-head) .kit-bar { display: none; }
  .kit-app[data-panes="split"] .kit-head .kit-bar__back { display: none; }
  .kit-app[data-panes="split"] .kit-head .kit-head__close { display: inline-grid; }
}

/* --------------------------------- people ---------------------------------- */
/* The people one already shares with, as chips under a share dialog's email (people.js). */
.kit-people { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; min-width: 0; }
.kit-people[hidden] { display: none; }
.kit-people__label { flex-basis: 100%; font-size: var(--look-footnote); color: var(--kit-muted); }
.kit-people__chip {
  max-width: 100%; min-height: 32px; padding: 4px 12px; border: 1px solid var(--kit-border); border-radius: 999px;
  background: var(--kit-panel); color: var(--kit-text); font: 500 var(--look-subhead)/1.2 var(--kit-font); cursor: pointer;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.kit-people__chip:hover { background: var(--kit-hover); }
.kit-people__chip[aria-pressed="true"] { background: var(--kit-accent-soft); border-color: var(--kit-accent); color: var(--kit-accent); }
.kit-people__chip[aria-pressed="true"]::before { content: "✓ "; }

/* ---------------------------------- share ---------------------------------- */
/* Who has something, and inviting (share.js shareDialog): Notes' dialog, now every app's. */
.kit-share__invite { display: grid; gap: 10px; }
.kit-share__invite[hidden] { display: none; }
.kit-share__row { justify-content: space-between; }
.kit-share__heading { margin: 4px 0 0; font: var(--kit-eyebrow-weight) var(--kit-eyebrow-size)/1 var(--kit-font); letter-spacing: var(--kit-eyebrow-spacing); text-transform: uppercase; color: var(--kit-muted); }
/* On a phone, what someone may do and the button to take it back go under their name. */
.kit-share__people .kit-list__row { flex-wrap: wrap; gap: 8px 10px; }
.kit-share__people .kit-list__text { flex: 1 1 150px; }
/* A name never breaks mid-word ("Martíne / z" at 320 px, Tasks 1.x): one line, cut with "…", all of it in its title. */
.kit-share__name { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; overflow-wrap: normal; }
.kit-share__pending { color: var(--kit-warn) !important; }
.kit-share__permission { width: auto; margin-inline-start: auto; min-height: 34px; padding-block: 4px; font-size: var(--look-subhead); }
/* The invitation's choice as a list (an app with more than two roles): beside Invite, not pushed away. */
.kit-share__choice { margin-inline-start: 0; }
/* A row kept as it is: what they may do, where the others have their list. */
.kit-share__role { margin-inline-start: auto; color: var(--kit-muted); font-size: var(--look-subhead); white-space: nowrap; }
/* A touch screen's field text is never under 16px: below that the iPhone zooms the page in. */
@media (pointer: coarse) { .kit-share__permission { font-size: max(16px, var(--look-body)); } }
.kit-share__offline { margin: 0; }

/* An invitation waiting for an answer (invitation.js), first in the sidebar in every module:
   who offers what, what accepting it gives, and the two answers, as wide as each other. */
.kit-invites { display: grid; gap: 8px; margin-block: 4px 10px; }
.kit-invite {
  display: grid; gap: 6px; padding: 10px 12px; min-width: 0;
  border: 1px solid var(--kit-border); border-inline-start: 3px solid var(--invite-color, var(--kit-accent));
  border-radius: var(--look-r-md); background: var(--kit-panel);
}
.kit-invite__from { display: flex; align-items: center; gap: 6px; min-width: 0; font-size: var(--look-footnote); color: var(--kit-muted); }
.kit-invite__from > span:last-child { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.kit-invite__name { display: flex; align-items: center; gap: 8px; min-width: 0; font-size: var(--look-headline); }
.kit-invite__name > span:last-child { overflow-wrap: anywhere; }
.kit-invite__icon { flex: none; line-height: 1; }
.kit-invite__swatch { flex: none; width: 10px; height: 10px; border-radius: 3px; background: var(--invite-color, var(--kit-accent)); }
.kit-invite__about { font-size: var(--look-caption); color: var(--kit-muted); }
.kit-invite__actions { display: flex; gap: 6px; margin-block-start: 2px; }
.kit-invite__actions .kit-btn { flex: 1 1 0; }
/* ☰ while an invitation waits in the closed drawer (shell.js setMark): a dot at its corner. */
.kit-app[data-mark] .kit-bar__menu { position: relative; }
.kit-app[data-mark] .kit-bar__menu::after {
  content: ''; position: absolute; inset-block-start: 7px; inset-inline-end: 7px; width: 8px; height: 8px;
  border-radius: 50%; background: var(--kit-accent); box-shadow: 0 0 0 2px var(--kit-bg, var(--kit-panel));
}

/* ---------------------------------- links ---------------------------------- */
/* The "Linked" row of an item (links.js): one chip per link, a dot in the other module's colour. */
.kit-linked { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 8px; min-width: 0; }
.kit-linked[hidden] { display: none; }
.kit-linked__label { font-size: var(--look-footnote); font-weight: 500; color: var(--kit-muted); margin-inline-end: 2px; }
.kit-linked__chips { display: contents; }
.kit-linked__chip {
  display: inline-flex; align-items: center; max-width: 100%; min-width: 0; min-height: 32px;
  border: 1px solid var(--kit-border); border-radius: var(--look-r-sm); background: var(--kit-panel); font-size: var(--look-subhead);
}
.kit-linked__open {
  display: inline-flex; align-items: center; gap: 7px; min-width: 0; padding: 4px 6px 4px 10px;
  color: var(--kit-text); text-decoration: none; border-radius: var(--look-r-sm);
}
a.kit-linked__open:hover .kit-linked__title { text-decoration: underline; }
.kit-linked__dot { width: 8px; height: 8px; border-radius: 50%; background: var(--module, var(--kit-muted)); flex: none; }
.kit-linked__title { min-width: 0; max-width: 30ch; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.kit-linked__note { color: var(--kit-muted); font-size: var(--look-footnote); white-space: nowrap; }
.kit-linked__together { display: inline-grid; color: var(--kit-muted); }
.kit-linked__together .kit-icon { width: 14px; height: 14px; }
.kit-linked__more {
  width: 28px; height: 28px; margin-inline-end: 2px; border: 0; border-radius: var(--look-r-sm); background: none; color: var(--kit-muted);
  cursor: pointer; display: inline-grid; place-items: center; flex: none; padding: 0;
}
.kit-linked__more:hover { background: var(--kit-hover); color: var(--kit-text); }
.kit-linked__more .kit-icon { width: 16px; height: 16px; }
.kit-linked__chip[data-state="done"] .kit-linked__title,
.kit-linked__chip[data-state="cancelled"] .kit-linked__title { text-decoration: line-through; text-decoration-color: var(--kit-muted); }
.kit-linked__chip[data-state="gone"], .kit-linked__chip[data-state="hidden"] { border-style: dashed; background: none; }
.kit-linked__chip[data-state="gone"] .kit-linked__open,
.kit-linked__chip[data-state="hidden"] .kit-linked__open { color: var(--kit-muted); }
/* What "Link existing…" finds. */
.kit-linked__results { display: grid; gap: 2px; max-height: min(46vh, 340px); overflow-y: auto; }
.kit-linked__result {
  display: flex; align-items: center; gap: 9px; width: 100%; min-height: 44px; padding: 8px 10px; border: 0; border-radius: var(--look-r-sm);
  background: none; color: var(--kit-text); text-align: start; cursor: pointer; font: inherit;
}
.kit-linked__result:hover { background: var(--kit-hover); }
.kit-linked__result[disabled] { opacity: .55; cursor: default; background: none; }
.kit-linked__result .kit-linked__title { flex: 1; max-width: none; }
.kit-linked__result[data-state="done"] .kit-linked__title { text-decoration: line-through; text-decoration-color: var(--kit-muted); }
@media (max-width: 640px) {
  .kit-linked__title { max-width: 20ch; }
  .kit-linked__more { width: 36px; height: 36px; }
}

/* -------------------------------- sign-in --------------------------------- */
/* The product's colour large, the form beside it; stacked on a phone. */

.kit-signin { min-height: 100dvh; display: flex; flex-direction: column; background: var(--kit-bg); }
.kit-signin__hero {
  position: relative; overflow: hidden; display: grid; gap: 14px; align-content: end;
  min-height: 210px; padding: calc(28px + var(--kit-safe-top)) 24px 26px;
  background: var(--app, var(--cr-ink)); color: var(--cr-cream);
}
.kit-signin__hero::after {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background: linear-gradient(135deg, rgba(255, 255, 255, .2), rgba(255, 255, 255, 0) 60%);
}
.kit-signin__hero img { width: 56px; height: 56px; border-radius: 15px; box-shadow: 0 0 0 2px rgba(255, 247, 230, .35); }
.kit-signin__hero h1 { margin: 0; font: 700 36px/1 var(--kit-font-display); letter-spacing: -.04em; }
.kit-signin__hero p { margin: 0; max-width: 32ch; font-size: var(--look-body); opacity: .92; }
.kit-signin__side { flex: 1; display: flex; flex-direction: column; }
.kit-signin__body { flex: 1; padding: 26px 20px 8px; }
.kit-signin__card { display: grid; gap: 14px; width: 100%; max-width: 380px; margin: 0 auto; }
.kit-signin__card h2 { margin: 0; font: 700 var(--look-title2)/1.2 var(--kit-font-display); letter-spacing: -.02em; }
.kit-signin__card > p { margin: 0; color: var(--kit-muted); font-size: var(--look-subhead); }
.kit-signin__links { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 8px; }
.kit-signin__notice { margin: 0; padding: 10px 12px; border-radius: var(--look-r-md); background: var(--kit-accent-soft); font-size: var(--look-subhead); }
.kit-signin__notice p { margin: 4px 0 0; }
.kit-signin__sig { display: flex; justify-content: center; padding: 22px 16px calc(22px + var(--kit-safe-bottom)); }
/* The connect page (connect.js): the device's name is what the app sent, set apart from the page's words. */
.kit-connect__device { color: var(--kit-text); font-weight: 600; overflow-wrap: anywhere; }
@media (min-width: 760px) {
  .kit-signin { flex-direction: row; }
  .kit-signin__hero { flex: 0 0 44%; align-content: center; padding: 56px; }
  .kit-signin__hero img { width: 76px; height: 76px; border-radius: 20px; }
  .kit-signin__hero h1 { font-size: 52px; }
  .kit-signin__hero p { font-size: max(17px, var(--look-body)); }
  .kit-signin__body { display: grid; align-content: center; }
}

/* -------------------------------- settings -------------------------------- */
/* A list of sections; on a phone, each section is a screen of its own. */

.kit-settings-page {
  position: fixed; inset: 0; z-index: 500; background: var(--kit-bg);
  display: grid; grid-template-rows: auto minmax(0, 1fr);
}
.kit-settings-page__bar {
  display: flex; align-items: center; gap: 4px; min-height: calc(54px + var(--kit-safe-top));
  padding: var(--kit-safe-top) 8px 0; border-bottom: 1px solid var(--kit-border);
}
.kit-settings-page__title { margin: 0; font-size: var(--look-headline); font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.kit-settings-page__body { overflow-y: auto; overscroll-behavior: contain; padding-bottom: var(--kit-safe-bottom); }

.kit-settings { container: kit-settings / inline-size; position: relative; min-height: 100%; }
.kit-settings__grid { display: grid; grid-template-columns: minmax(0, 1fr); min-height: 100%; }
.kit-settings__list { padding: 10px 10px 24px; display: grid; grid-template-columns: minmax(0, 1fr); align-content: start; gap: 2px; }
/* A group's heading folds and unfolds it (one open at a time); a group of one section opens it. */
.kit-settings__group {
  display: flex; align-items: center; gap: 8px; width: 100%; min-height: 44px; padding: 8px 10px; margin-top: 2px;
  border: 0; border-radius: var(--look-r-md); background: none; cursor: pointer; text-align: start;
  font: var(--kit-eyebrow-weight) var(--kit-eyebrow-size)/1 var(--kit-font); letter-spacing: var(--kit-eyebrow-spacing); text-transform: uppercase; color: var(--kit-muted);
}
.kit-settings__group:hover { background: var(--kit-hover); color: var(--kit-text); }
.kit-settings__group[aria-expanded="true"], .kit-settings__group[aria-current="page"] { color: var(--kit-text); }
.kit-settings__group[aria-current="page"] { background: var(--kit-accent-soft); }
.kit-settings__group-name { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.kit-settings__fold { width: 16px; height: 16px; flex: none; transition: transform .3s ease; }
.kit-settings__group[aria-expanded="true"] .kit-settings__fold { transform: rotate(90deg); }
.kit-settings__folder { display: grid; grid-template-columns: minmax(0, 1fr); gap: 2px; padding-bottom: 6px; }
.kit-settings__folder[hidden] { display: none; }
@media (prefers-reduced-motion: reduce) { .kit-settings__fold { transition: none; } }
/* While a fold slides (ui.js move), the rows passing under a pointer that stays still don't light
   up one after another: it read as the list blinking. */
:root[data-kit-folding] :is(.kit-settings__group, .kit-settings__item, .kit-nav__item, .kit-nav-group__toggle, .kit-nav-group__name):not([aria-current]):hover { background: none; }
:root[data-kit-folding] :is(.kit-settings__group:not([aria-expanded="true"]):not([aria-current]), .kit-nav__fold):hover { color: var(--kit-muted); }
.kit-settings__item {
  display: flex; align-items: center; gap: 12px; width: 100%; min-height: 52px; padding: 9px 10px; border-radius: var(--look-r-md);
  border: 0; background: none; color: var(--kit-text); text-align: start; cursor: pointer; text-decoration: none;
}
.kit-settings__item:hover { background: var(--kit-hover); }
.kit-settings__item[aria-current="page"] { background: var(--kit-accent-soft); }
.kit-settings__item[aria-current="page"] .kit-settings__label { font-weight: 600; }
.kit-settings__icon {
  width: 34px; height: 34px; border-radius: 9px; display: grid; place-items: center; flex: none;
  background: var(--kit-panel); border: 1px solid var(--kit-border); color: var(--kit-muted);
}
.kit-settings__item[aria-current="page"] .kit-settings__icon { color: var(--kit-accent); }
.kit-settings__text { flex: 1; min-width: 0; line-height: 1.3; }
.kit-settings__text small { display: block; color: var(--kit-muted); font-size: var(--look-footnote); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.kit-settings__chevron { color: var(--kit-muted); }
.kit-settings__page { padding: 20px 18px 40px; display: none; }
/* It takes the focus when a section opens (settings.js), for the keyboard and a reader, not to draw a
   ring: around the whole page it showed as a black line under the section, and at its edge in a swipe. */
.kit-settings__page:focus { outline: none; }
.kit-settings[data-open] .kit-settings__list { display: none; }
.kit-settings[data-open] .kit-settings__page { display: block; }
/* A section going back with a finger (settings.js): the list beneath it, where the page had scrolled to. */
/* Clipped, or the section slid aside would scroll the page sideways. */
.kit-settings[data-swipe] { overflow: clip; }
.kit-settings[data-swipe] .kit-settings__list { display: grid; position: absolute; inset-inline: 0; z-index: 0; }
.kit-settings[data-swipe] .kit-settings__page { position: relative; z-index: 1; background: var(--kit-bg); }
/* On a phone the bar already names the open section. */
@container kit-settings (max-width: 719px) {
  .kit-settings__page h2:first-child { display: none; }
}
.kit-settings__page h2:first-child { margin: 0 0 18px; font: 700 var(--look-title1)/1.1 var(--kit-font-display); letter-spacing: -.02em; }
.kit-settings__block { display: grid; gap: 12px; padding-block: 18px; border-top: 1px solid var(--kit-border); max-width: 640px; }
.kit-settings__block:first-of-type { border-top: 0; padding-top: 0; }
.kit-settings__block h3 { margin: 0; font-size: var(--look-headline); font-weight: 600; }
.kit-settings__block > p { margin: 0; }
/* Without a signal (settings.js): a section only the server can draw says so in its place, and what
   needs it (the email, your data) is off, saying why, its links out of reach too. */
.kit-settings__offline { max-width: 640px; }
.kit-settings__online { border: 0; margin: 0; padding: 0; min-width: 0; }
.kit-settings__offline-hint { margin: 0 0 6px; color: var(--kit-text); font-weight: 600; }
.kit-settings__online:disabled a { pointer-events: none; opacity: 0.5; }
/*
 * Side by side, the list and the open section each scroll on their own: the
 * grid fills the page exactly (a container query can't reach the page's body,
 * which scrolls both together on a phone) and each column has its scroll.
 */
@container kit-settings (min-width: 720px) {
  .kit-settings__grid { position: absolute; inset: 0; grid-template-columns: 290px minmax(0, 1fr); grid-template-rows: minmax(0, 1fr); }
  .kit-settings__list { border-inline-end: 1px solid var(--kit-border); display: grid !important; overflow-y: auto; overscroll-behavior: contain; }
  .kit-settings__page { display: block; padding: 28px 34px 48px; overflow-y: auto; overscroll-behavior: contain; }
  .kit-settings__chevron { display: none; }
}

.kit-facts { display: grid; border: 1px solid var(--kit-border); border-radius: var(--look-r-lg); background: var(--kit-panel); }
.kit-fact { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 12px; padding: 12px 14px; }
.kit-fact + .kit-fact { border-top: 1px solid var(--kit-border); }
.kit-fact > span { color: var(--kit-muted); font-size: var(--look-footnote); flex: 1 1 150px; }
.kit-fact > strong { font-weight: 600; font-variant-numeric: tabular-nums; }
.kit-fact small { flex-basis: 100%; color: var(--kit-muted); font-size: var(--look-caption); font-family: var(--kit-font-mono); }
.kit-fact__value { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 10px; }
.kit-fact__value > strong { font-weight: 600; font-variant-numeric: tabular-nums; }
.kit-fact__value > .kit-hint { margin: 0; }
.kit-fact__ok { color: var(--kit-ok); }
/* An app's own `a { color: inherit }` (Next) mustn't turn the source link into plain text. */
.kit-fact a { color: var(--kit-accent); }
/* Settings › Sharing (shared.js): one card for each thing shared, a row for each person. On a
   narrow phone the choice of permission goes under the name, never off the screen. */
.kit-shared[aria-busy="true"]:empty { min-height: 120px; }
.kit-shared__list { display: grid; gap: 10px; }
.kit-shared__item { display: grid; gap: 10px; padding: 12px 14px; border: 1px solid var(--kit-border); border-radius: var(--look-r-lg); background: var(--kit-panel); min-width: 0; }
.kit-shared__head { display: flex; align-items: center; gap: 10px; min-width: 0; }
.kit-shared__icon, .kit-shared__emoji { display: grid; place-items: center; width: 30px; height: 30px; flex: none; }
.kit-shared__icon { color: var(--kit-muted); }
.kit-shared__emoji { font-size: var(--look-title3); }
.kit-shared__title { flex: 1; min-width: 0; display: grid; line-height: 1.3; }
.kit-shared__title small { color: var(--kit-muted); font-size: var(--look-footnote); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.kit-shared__name { font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; text-align: start; }
.kit-shared__name--link { background: none; border: 0; padding: 0; font: inherit; font-weight: 600; color: inherit; cursor: pointer; }
.kit-shared__name--link:hover { color: var(--kit-accent); text-decoration: underline; }
.kit-shared__people { display: grid; gap: 8px; }
.kit-shared__person { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 10px; padding-top: 8px; border-top: 1px solid var(--kit-border); }
.kit-shared__who { flex: 1 1 120px; min-width: 0; display: grid; line-height: 1.3; }
.kit-shared__who > * { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.kit-shared__who small { color: var(--kit-muted); font-size: var(--look-caption); }
.kit-shared__person .kit-icon-btn { width: 32px; height: 32px; flex: none; }
.kit-shared__about { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 10px; }
.kit-shared__actions { display: flex; flex-wrap: wrap; gap: 6px; margin-inline-start: auto; }
/* Without a signal (shared.js): what changes something is off, greyed as the kit's buttons are. */
.kit-shared > .kit-settings__offline-hint { margin-bottom: 10px; }
.kit-shared .kit-icon-btn[disabled], .kit-shared .kit-segmented button[disabled], .kit-shared select[disabled] { opacity: .55; cursor: default; pointer-events: none; }
/* What can be bought (plan.js): on a narrow phone the button goes under the name, not over it. */
.kit-plan__offer .kit-list__row { flex-wrap: wrap; row-gap: 8px; }
.kit-plan__offer .kit-list__text { flex: 1 1 150px; }
.kit-plan__offer .kit-btn { flex: none; }
.kit-plan__offer .kit-badge { margin-inline-start: 8px; vertical-align: 1px; }
/* Its price before the button: a founder's beside the regular one, struck through. */
.kit-plan__price { flex: none; display: inline-flex; align-items: baseline; gap: 6px; white-space: nowrap; }
.kit-plan__price strong { font-size: 17px; font-weight: 700; color: var(--kit-text); }
.kit-plan__price s { color: var(--kit-muted); font-size: 13.5px; }
.kit-plan__price small { color: var(--kit-muted); font-size: 12.5px; }
.kit-plan__offer .kit-list__text small.kit-plan__note { margin-top: 4px; color: var(--kit-accent); }
/* What can be done at the provider's page, in "Change or cancel plan". */
.kit-plan__can { margin: 0; padding-inline-start: 20px; display: grid; gap: 6px; }
/* Your AI's instructions: one fold per app, one open at a time (settings.js fold()). */
.kit-folds { display: grid; gap: 8px; }
.kit-fold { border: 1px solid var(--kit-border); border-radius: var(--look-r-lg); background: var(--kit-panel); }
.kit-fold > summary {
  display: flex; align-items: center; gap: 10px; min-height: 48px; padding: 8px 14px; cursor: pointer;
  list-style: none; font-weight: 600; border-radius: var(--look-r-lg);
}
.kit-fold > summary::-webkit-details-marker { display: none; }
.kit-fold > summary:hover { background: var(--kit-hover); }
.kit-fold > summary img { width: 22px; height: 22px; border-radius: 6px; flex: none; }
.kit-fold > summary span { flex: 1; min-width: 0; }
.kit-fold__chevron { color: var(--kit-muted); transition: transform .3s ease; }
.kit-fold[open]:not([data-closing]) .kit-fold__chevron { transform: rotate(180deg); }
.kit-fold__body { display: grid; gap: 10px; padding: 0 14px 14px; }
.kit-fold__body > .kit-hint { margin: 0; }
.kit-fold__list { display: grid; gap: 6px; margin: 0; padding-inline-start: 18px; }
.kit-fold__list strong { color: var(--kit-text); font-weight: 600; }
@media (prefers-reduced-motion: reduce) { .kit-fold__chevron { transition: none; } }

/* Administration › Notifications (admin.js renderNotices): a head with how things stand, then
   cards — where they go (a fold), one row per group (when, how it reads, its words), the summary. */
.kit-notices__head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px; }
.kit-notices__head h2 { margin: 0; }
/* minmax(0, …): the destination's one-line summary (nowrap) mustn't widen the page on a phone. */
.kit-notices { display: grid; grid-template-columns: minmax(0, 1fr); gap: 12px; margin-top: 14px; }
.kit-notices > .kit-fold > summary > .kit-icon,
.kit-notices__card-head > .kit-icon { width: 20px; height: 20px; color: var(--kit-muted); flex: none; }
/* The destination's title whole, and its summary after it, cut short when the line is short. */
.kit-notices > .kit-fold > summary > span { flex: none; }
.kit-notices > .kit-fold > summary > .kit-fold__now { flex: 1 1 auto; text-align: end; }
.kit-notices__card {
  display: grid; gap: 10px; padding: 12px 14px; border: 1px solid var(--kit-border);
  border-radius: var(--look-r-lg); background: var(--kit-panel);
}
.kit-notices__card-head { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; min-height: 32px; }
.kit-notices__card-head h3 { margin: 0; font-size: inherit; font-weight: 600; flex: 1 1 auto; }
.kit-notices__extras { display: flex; flex-wrap: wrap; gap: 16px; }
.kit-notices__via { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 22px; }
.kit-notices__via > .kit-row { gap: 14px; }
.kit-notices__rows { display: grid; }
.kit-notices__row {
  display: grid; grid-template-columns: minmax(0, 1fr) auto auto; align-items: center; gap: 6px 12px;
  grid-template-areas: "name mode edit" "preview preview preview" "editor editor editor";
  padding: 10px 0; border-top: 1px solid var(--kit-border);
}
.kit-notices__name { grid-area: name; font-weight: 500; }
.kit-notices__row > .kit-segmented { grid-area: mode; }
.kit-notices__row > .kit-icon-btn { grid-area: edit; }
.kit-notices__row > .kit-notices__preview { grid-area: preview; }
.kit-notices__row > .kit-notices__editor { grid-area: editor; }
.kit-notices__row .kit-segmented button { min-height: 30px; padding: 4px 11px; font-size: var(--look-footnote); }
.kit-notices__preview { margin: 0; color: var(--kit-muted); font-size: var(--look-footnote); overflow-wrap: anywhere; }
.kit-notices__row[data-mode="off"] .kit-notices__preview { text-decoration: line-through; opacity: .6; }
.kit-notices__editor { display: grid; gap: 8px; padding-top: 4px; }
.kit-notices__editor textarea { width: 100%; box-sizing: border-box; }
.kit-notices__vars { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; }
.kit-notices__vars > button:not(.kit-btn) {
  font-family: var(--kit-font-mono); font-size: 12px; padding: 3px 8px; border-radius: 6px; cursor: pointer;
  border: 1px solid var(--kit-border); background: var(--kit-hover); color: var(--kit-text);
}
.kit-notices__vars > button:not(.kit-btn):hover { border-color: var(--kit-muted); }
.kit-notices__vars > .kit-btn { margin-inline-start: auto; }
.kit-notices__rules { padding-top: 8px; border-top: 1px solid var(--kit-border); }
.kit-notices__hour { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.kit-notices__hour select { width: auto; }
.kit-notices__save { justify-content: flex-end; }
@media (max-width: 560px) {
  .kit-notices__row { grid-template-columns: minmax(0, 1fr) auto; grid-template-areas: "name edit" "mode mode" "preview preview" "editor editor"; }
  .kit-notices__row > .kit-segmented { display: flex; }
  .kit-notices__row > .kit-segmented button { flex: 1; }
}

/* The plan: its own card, then what it includes, a check for what is in, a dash for what isn't. */
.kit-plan-card {
  display: grid; gap: 6px; padding: 20px 22px; border: 1px solid var(--kit-border); border-radius: 14px;
  background: var(--kit-panel); max-width: 640px;
}
.kit-plan-card__label { font: 600 11px/1 var(--kit-font); letter-spacing: .1em; text-transform: uppercase; color: var(--kit-muted); }
.kit-plan-card__name { font: 700 28px/1.1 var(--kit-font-display); letter-spacing: -.02em; color: var(--kit-text); }
.kit-plan-card__until { margin: 0; color: var(--kit-muted); font-size: 13.5px; }
.kit-plan-card__status { display: grid; gap: 4px; }
.kit-plan-card__status:empty { display: none; }
.kit-plan-card__extras { display: grid; gap: 6px; margin-top: 8px; padding-top: 10px; border-top: 1px solid var(--kit-border); }
.kit-plan-card__extras ul { margin: 0; padding-inline-start: 18px; display: grid; gap: 4px; font-size: 13.5px; }
/* Over the block's own `h3 { margin: 0 }`. */
.kit-settings__block .kit-benefits__title { margin: 28px 0 14px; font-size: var(--look-headline); font-weight: 600; }
.kit-benefits { list-style: none; margin: 0 0 12px; padding: 0 2px; display: grid; gap: 10px; }
.kit-benefits li { display: flex; align-items: flex-start; gap: 10px; line-height: 1.35; }
.kit-benefits li svg { width: 18px; height: 18px; flex: none; color: var(--kit-ok); margin-top: 1px; }
.kit-benefits li.kit-benefits__no { color: var(--kit-muted); }
.kit-benefits li.kit-benefits__no svg { color: var(--kit-muted); }

/* The host's About: a card for each of its apps, with its version. */
.kit-about-cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 220px), 1fr)); gap: 10px; }
.kit-about-card { display: flex; align-items: flex-start; gap: 12px; padding: 14px; border: 1px solid var(--kit-border); border-radius: var(--look-r-lg); background: var(--kit-panel); min-width: 0; }
.kit-about-card img { width: 36px; height: 36px; border-radius: 10px; flex: none; }
.kit-about-card__text { display: grid; gap: 3px; min-width: 0; justify-items: start; }
.kit-about-card__text strong { font-weight: 600; }
.kit-about-card__text p { margin: 0; color: var(--kit-muted); font-size: var(--look-footnote); line-height: 1.35; }
.kit-about-card__text small { color: var(--kit-muted); font: var(--look-caption)/1.4 var(--kit-font-mono); font-variant-numeric: tabular-nums; }

.kit-about { display: flex; align-items: center; gap: 14px; }
.kit-about img { width: 54px; height: 54px; border-radius: 14px; }
.kit-about strong { display: block; font: 700 var(--look-title2)/1 var(--kit-font-display); letter-spacing: -.03em; }
.kit-about p { margin: 4px 0 0; color: var(--kit-muted); }
.kit-codes { display: grid; grid-template-columns: repeat(auto-fill, minmax(120px, 1fr)); gap: 6px; padding: 0; margin: 0; list-style: none; }
.kit-codes code { font-family: var(--kit-font-mono); }
.kit-instruction { white-space: pre-wrap; margin: 0; padding: 12px 14px; border-radius: var(--look-r-md); background: var(--kit-hover); font: var(--look-footnote)/1.5 var(--kit-font-mono); overflow-wrap: anywhere; }

/* The AI agents (agents.js): a chip for each with its mark, its steps, and the prompt for the modules ticked. */
.kit-agents { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 136px), 1fr)); gap: 8px; }
.kit-agent {
  display: flex; align-items: center; gap: 10px; min-width: 0; padding: 10px 12px; border: 1px solid var(--kit-border);
  border-radius: var(--look-r-md); background: var(--kit-panel); color: var(--kit-text); font: inherit; font-weight: 500; text-align: start; cursor: pointer;
}
.kit-agent:hover { background: var(--kit-hover); }
.kit-agent:focus-visible { outline: 2px solid var(--kit-accent); outline-offset: 2px; }
.kit-agent[aria-pressed="true"] { border-color: var(--kit-accent); box-shadow: inset 0 0 0 1px var(--kit-accent); }
.kit-agent span { min-width: 0; overflow-wrap: anywhere; }
.kit-agent-mark { width: 20px; height: 20px; flex: none; fill: currentColor; }
.kit-agent-steps { display: grid; gap: 10px; min-width: 0; }
.kit-steps { display: grid; gap: 16px; margin: 0; padding: 0; list-style: none; counter-reset: kit-step; }
.kit-steps li { position: relative; display: grid; gap: 8px; min-width: 0; padding-inline-start: 36px; counter-increment: kit-step; }
.kit-steps li::before {
  content: counter(kit-step); position: absolute; inset-inline-start: 0; top: -1px; width: 24px; height: 24px; border-radius: 50%;
  display: grid; place-items: center; background: var(--kit-hover); color: var(--kit-text); font: 600 13px/1 var(--kit-font);
}
.kit-steps p { margin: 0; }
.kit-steps a.kit-btn { justify-self: start; }
.kit-prompt { display: grid; gap: 10px; min-width: 0; }
/* The prompt is long: in its own scroll, so Copy stays near. */
.kit-prompt .kit-instruction { max-height: min(22em, 55vh); overflow-y: auto; overscroll-behavior: contain; }
.kit-prompt__modules { display: flex; flex-wrap: wrap; gap: 8px 18px; }
.kit-prompt__modules img { border-radius: 5px; flex: none; }

/* -------------------------- the phone's keyboard -------------------------- */
/*
 * keyboard.js, while the keyboard is up: what is fixed to the full screen takes
 * the part of it left in view (--kit-view-top, --kit-view-h), so its top doesn't
 * slide out of reach and its foot doesn't stay under the keyboard. The frame and
 * Settings fill it; a modal dialog (the kit's, or an app's own <dialog>) sits in
 * its middle, and on a phone, as a sheet, on the keyboard; the notices just above
 * it. The home indicator is under the keyboard: nothing keeps room for it. An
 * app's own layers that are not a <dialog> read the same attribute.
 */
:root[data-kit-keyboard] { --kit-safe-bottom: 0px; }
/* A field scrolled back into view is not left touching the keyboard's edge. */
:root[data-kit-keyboard] :is(input, textarea) { scroll-margin-block: 12px; }
:root[data-kit-keyboard] .kit-app,
:root[data-kit-keyboard] .kit-settings-page { top: var(--kit-view-top); bottom: auto; height: var(--kit-view-h); }
:root[data-kit-keyboard] dialog:modal {
  inset-block: auto; top: calc(var(--kit-view-top) + var(--kit-view-h) / 2); translate: 0 -50%;
  margin-block: 0; max-height: calc(var(--kit-view-h) - 24px);
}
:root[data-kit-keyboard] .kit-toasts { bottom: auto; top: calc(var(--kit-view-top) + var(--kit-view-h) - max(16px, var(--kit-toast-floor, 0px))); translate: 0 -100%; }
@media (max-width: 640px) {
  :root[data-kit-keyboard] dialog:modal { top: calc(var(--kit-view-top) + var(--kit-view-h)); translate: 0 -100%; max-height: calc(var(--kit-view-h) - 8px); }
}
/* A sheet going up or down with the keyboard in the suite's iPhone app (keyboard.js rideKeyboard):
   held where it slides to, out of the page's layout, which comes a moment later. */
.kit-dialog[data-riding] {
  box-sizing: border-box; inset-block: var(--ride-top) auto; margin: 0;
  height: var(--ride-height); max-height: none; padding-bottom: var(--ride-pad);
}

/* ------------------------------- signature -------------------------------- */

#admin:empty + .kit-signature { display: none; }
.kit-signature { display: flex; justify-content: center; padding: 8px 16px max(28px, var(--kit-safe-bottom)); }
.cronum-sig {
  display: inline-flex; align-items: center; gap: 6px; font-size: var(--look-footnote);
  color: var(--kit-muted); text-decoration: none;
}
.cronum-sig strong { font-weight: 600; color: var(--kit-text); }
.cronum-sig svg { width: 17px; height: 17px; flex: none; }
.cronum-sig path { fill: none; stroke: var(--kit-sig-ring); stroke-width: 20; stroke-linecap: round; }
.cronum-sig circle { fill: var(--kit-sig-dot); }

/* ------------------------------- markdown --------------------------------- */
/* What markdown.js draws: a note, read. */

.kit-md { font-size: var(--look-body); line-height: 1.65; overflow-wrap: anywhere; }
.kit-md > :first-child { margin-top: 0; }
.kit-md h1, .kit-md h2, .kit-md h3 { font-family: var(--kit-font-display); font-weight: 700; letter-spacing: -.02em; margin: 1.4em 0 .4em; }
.kit-md h1 { font-size: max(26px, var(--look-title1)); letter-spacing: -.03em; }
.kit-md h2 { font-size: 19px; }
.kit-md h3 { font-size: 16.5px; }
:root[data-look="clean"] .kit-md h2 { font-size: var(--look-title2); }
:root[data-look="clean"] .kit-md h3 { font-size: var(--look-title3); }
.kit-md h4, .kit-md h5, .kit-md h6 { font-size: var(--look-headline); margin: 1.2em 0 .3em; }
.kit-md p { margin: 0 0 .75em; }
.kit-md ul, .kit-md ol { margin: 0 0 .75em; padding-inline-start: 1.4em; }
.kit-md li { margin: .15em 0; }
.kit-md li > ul, .kit-md li > ol { margin: .15em 0; }
.kit-md .kit-md__task { list-style: none; margin-inline-start: -1.4em; display: flex; gap: 9px; align-items: flex-start; }
.kit-md .kit-md__task > input { width: 18px; height: 18px; margin: .2em 0 0; flex: none; accent-color: var(--kit-accent); }
.kit-md .kit-md__task--done > span { color: var(--kit-muted); text-decoration: line-through; }
.kit-md blockquote { margin: 0 0 .75em; padding: 2px 0 2px 14px; border-inline-start: 3px solid var(--kit-border); color: var(--kit-muted); }
.kit-md code { font: .88em var(--kit-font-mono); background: var(--kit-hover); padding: 1px 5px; border-radius: var(--look-r-xs); }
.kit-md pre { margin: 0 0 .75em; padding: 12px 14px; border-radius: var(--look-r-md); background: var(--kit-hover); overflow-x: auto; }
.kit-md pre code { background: none; padding: 0; font-size: var(--look-subhead); }
.kit-md hr { border: 0; border-top: 1px solid var(--kit-border); margin: 1.4em 0; }
.kit-md a { color: var(--kit-accent); }
.kit-md mark { background: var(--kit-md-mark); color: inherit; border-radius: var(--look-r-xs); padding: 0 2px; }
.kit-md u { text-decoration-thickness: 1px; text-underline-offset: .18em; }
.kit-md img { max-width: 100%; height: auto; border-radius: var(--look-r-sm); }
.kit-md table { border-collapse: collapse; margin: 0 0 .75em; display: block; overflow-x: auto; }
.kit-md th, .kit-md td { border: 1px solid var(--kit-border); padding: 6px 10px; text-align: start; }

@media (max-width: 640px) {
  .kit-hide-narrow { display: none; }
}

/* The Clean look's own touches, beyond its variables: an iPhone's large title, sidebar and section labels. */
:root[data-look="clean"] .kit-head { border-bottom-color: transparent; }
:root[data-look="clean"] .kit-head__title { letter-spacing: -.022em; }
:root[data-look="clean"] .kit-nav__item { min-height: 40px; padding-block: 8px; font-size: var(--look-callout); }
:root[data-look="clean"] .kit-nav__item[aria-current="page"] { font-weight: 500; }
:root[data-look="clean"] .kit-settings__item { padding-block: var(--look-row-y); }
/* The sidebar's groups as plain rows the size of their collections: the colour stays in the collections' own marks. */
:root[data-look="clean"] .kit-nav-group__head {
  min-height: 40px; padding-inline-start: 5px; border-inline-start: 0; background: transparent; color: var(--kit-text);
}
:root[data-look="clean"] .kit-nav-group__name { font-weight: 600; }
:root[data-look="clean"] :is(.kit-nav-group__toggle, .kit-nav-group__name):hover,
:root[data-look="clean"] .kit-nav-group__name[aria-expanded="true"] { background: var(--kit-hover); }
/* A list's narrow head, as on an iPhone: ☰, ← and the actions on the bar, the large title (with what
   leads it) on its own line under them. A detail's head keeps one line. */
@container kit-head (max-width: 639px) {
  :root[data-look="clean"] .kit-head[data-pane="list"] .kit-head__row { flex-wrap: wrap; row-gap: 2px; }
  :root[data-look="clean"] .kit-head[data-pane="list"] .kit-head__row::before { content: ""; order: 1; flex-basis: 100%; }
  :root[data-look="clean"] .kit-head[data-pane="list"] .kit-head__row > :not(.kit-bar__menu, .kit-bar__back, .kit-icon-btn, .kit-head__actions) { order: 2; }
  :root[data-look="clean"] .kit-head[data-pane="list"] .kit-head__actions { margin-inline-start: auto; }
  :root[data-look="clean"] .kit-head[data-pane="list"] .kit-head__title:empty { display: none; }
}


/* --------------------------- shared components ---------------------------- */
/*
 * What Tasks, Projects, Next and Notes each drew for themselves until 0.176.0, so a module looks
 * the same as the next one beside it in Cronum Work. Only --kit-* variables in here: an app's own
 * (a Tasks list's colour, a project's) reach these through the variables each one names.
 */

/* The names the apps had for these, as the kit's: one set of names in every module. */
:root {
  --kit-faint: color-mix(in oklab, var(--kit-muted) 78%, var(--kit-bg));
  --kit-border-strong: color-mix(in oklab, var(--kit-border) 82%, var(--kit-text));
}

/*
 * Selected text, in either theme and inside a field: the accent through, the text keeping its own
 * colour. The browser's blue could hardly be told from a dark ground; the iPhone ignores this in a
 * field and tints with the caret, hence the caret in the accent.
 */
::selection { background: color-mix(in srgb, var(--kit-accent) 30%, transparent); }
:root[data-theme="dark"] ::selection { background: color-mix(in srgb, var(--kit-accent) 48%, transparent); }
input, textarea { caret-color: var(--kit-accent); }

/* A field whose label names a group (a palette of colours): a span, as a <label> around several buttons would hand every click to the first. */
.kit-field > .kit-field__label { font-size: var(--look-footnote); font-weight: 500; color: var(--kit-text); }

/*
 * A chip: something said of an item (its date, who has it), small and quiet. `--tint` colours it
 * with --kit-chip (a state, a group); a button chip is one to press (a filter), `--large` beside
 * others in a row, the accent while aria-pressed.
 */
.kit-chip {
  display: inline-flex; align-items: center; gap: 5px; flex: none; max-width: 100%;
  padding: 2px 9px; border: 1px solid var(--kit-border); border-radius: 999px;
  background: var(--kit-panel); color: var(--kit-muted); font-size: var(--look-caption); white-space: nowrap;
}
.kit-chip--tint {
  border-color: transparent; font-weight: 600; color: var(--kit-chip, var(--kit-muted));
  background: color-mix(in srgb, var(--kit-chip, var(--kit-muted)) 16%, transparent);
}
.kit-chip--large { padding: 6px 13px; color: var(--kit-text); font-size: var(--look-subhead); }
button.kit-chip { cursor: pointer; }
button.kit-chip:hover { background: var(--kit-hover); }
/* With a finger, 23 px are below the 24 of WCAG 2.5.8: an invisible margin takes the taps above and below, as the round check's (ui-movil-12). */
@media (pointer: coarse) {
  button.kit-chip { position: relative; }
  button.kit-chip::before { content: ""; position: absolute; inset: -7px 0; }
}
.kit-chip[aria-pressed="true"], .kit-chip[aria-pressed="true"]:hover {
  background: var(--kit-accent); border-color: var(--kit-accent); color: var(--kit-on-accent); font-weight: 600;
}

/* An icon button in a row of items (a task's, a step's): smaller, so the row keeps its height. */
.kit-icon-btn--small { width: 34px; height: 34px; border-radius: var(--look-r-sm); font-size: max(16px, var(--look-callout)); }
.kit-icon-btn--small .kit-icon { width: 18px; height: 18px; }

/* A colour to choose: a circle of --kit-swatch (or its own background), ringed while chosen. */
.kit-swatches { display: flex; flex-wrap: wrap; gap: 8px; }
.kit-swatch {
  width: 28px; height: 28px; flex: none; padding: 0; border-radius: 50%; border: 2px solid transparent;
  background: var(--kit-swatch, var(--kit-muted)); cursor: pointer; transition: transform .12s;
}
.kit-swatch:hover { transform: scale(1.12); }
.kit-swatch:is([aria-pressed="true"], [aria-checked="true"], .kit-swatch--on) {
  border-color: var(--kit-text); box-shadow: inset 0 0 0 2px var(--kit-panel);
}
/* No colour (Next's «Automático», a group's «Sin color»): a pill with a dot of what it gives, after
   the swatches (pickers.js colorPicker `none`). */
.kit-swatch-none {
  display: inline-flex; align-items: center; gap: 6px; height: 32px; padding: 0 12px 0 5px;
  border: 2px solid var(--kit-border); border-radius: 999px; background: none; color: var(--kit-text);
  font: inherit; font-size: var(--look-subhead); cursor: pointer;
}
.kit-swatch-none__dot { flex: none; width: 18px; height: 18px; border-radius: 50%; background: var(--kit-swatch, var(--kit-muted)); }
.kit-swatch-none[aria-pressed="true"] { border-color: var(--kit-text); }

/* The icons to choose (pickers.js iconPicker): twenty in view, «Más…» for the rest, under a short
   field to type any other where the module takes one. */
.kit-icons { display: grid; gap: 8px; justify-items: start; min-width: 0; }
.kit-icons__grid { display: flex; flex-wrap: wrap; align-items: center; gap: 4px; }
.kit-icons__all { max-height: 216px; overflow-y: auto; overscroll-behavior: contain; padding-block: 2px; }
.kit-icon-pick {
  width: 36px; height: 36px; flex: none; display: grid; place-items: center; padding: 0;
  border: 1px solid transparent; border-radius: var(--look-r-sm); background: var(--kit-hover);
  font-size: var(--look-title3); line-height: 1; cursor: pointer;
}
.kit-icon-pick:hover { border-color: var(--kit-border); }
.kit-icon-pick[aria-pressed="true"] { border-color: var(--kit-accent); background: var(--kit-accent-soft); }
.kit-icons__more {
  height: 36px; padding: 0 12px; border: 1px solid var(--kit-border); border-radius: var(--look-r-sm);
  background: none; color: var(--kit-text); font: inherit; font-size: var(--look-subhead); cursor: pointer;
}
.kit-icons__more:hover { background: var(--kit-hover); }
/* As specific as the kit's rule for a field's input, which it narrows to one emoji. */
.kit-field input.kit-icons__typed:not([type="checkbox"]):not([type="radio"]):not([type="file"]), .kit-icons__typed.kit-input {
  width: 4.2em; padding: 6px; font-size: var(--look-title2); line-height: 1.2; text-align: center;
}

/*
 * The round check of a task: an empty circle, filled with the accent and ticked once done
 * (`--done`, or aria-pressed). The tick is an "L" turned 45°, whose box then hangs below its own
 * centre: lifted by --kit-tick-lift it sits in the middle. Physical left and border on purpose: a tick
 * is the same mark right to left. A finger misses a 21 px circle, and the row under it opens
 * instead: an invisible margin takes the taps around it.
 */
.kit-round-check {
  --kit-tick-lift: 2.1px;
  position: relative; flex: none; width: 21px; height: 21px; padding: 0; display: grid; place-items: center;
  border: 2px solid var(--kit-border-strong); border-radius: 50%; background: transparent; cursor: pointer;
  transition: border-color .15s, background .15s, transform .12s;
}
.kit-round-check:hover:not([disabled]) { border-color: var(--kit-accent); }
.kit-round-check::before { content: ""; position: absolute; inset: -10px; }
/* The tick, drawn as two borders turned: physical left and border-left on purpose, a drawing. */
.kit-round-check::after {
  content: ""; position: absolute; left: 50%; top: 50%; width: 10px; height: 6px;
  border-left: 2.2px solid var(--kit-on-accent); border-bottom: 2.2px solid var(--kit-on-accent);
  transform: translate(-50%, calc(-50% - var(--kit-tick-lift))) rotate(-45deg) scale(.2); opacity: 0;
  transition: transform .18s cubic-bezier(.2, .9, .3, 1.4), opacity .12s;
}
.kit-round-check:is(.kit-round-check--done, [aria-pressed="true"]) { background: var(--kit-accent); border-color: var(--kit-accent); }
.kit-round-check:is(.kit-round-check--done, [aria-pressed="true"])::after { opacity: 1; transform: translate(-50%, calc(-50% - var(--kit-tick-lift))) rotate(-45deg) scale(1); }
.kit-round-check[disabled] { opacity: .45; cursor: default; }
.kit-round-check[disabled]::before { content: none; }

/* The heading of a group of items in a list (Overdue, Completed, a section). */
.kit-group-title {
  display: flex; align-items: center; gap: 8px; margin: var(--look-section) 0 8px;
  font-size: var(--look-footnote); font-weight: 700; letter-spacing: .05em; text-transform: uppercase; color: var(--kit-muted);
}
:root[data-look="clean"] .kit-group-title { font-weight: 600; letter-spacing: .02em; }

/* An avatar's other sizes: a row's, a chip's, a header's. */
.kit-avatar--small { width: 26px; height: 26px; }
.kit-avatar--tiny { width: 20px; height: 20px; font-size: 9.5px; }
:root[data-look="clean"] .kit-avatar--tiny { font-size: var(--look-caption2); }
.kit-avatar--large { width: 34px; height: 34px; font-size: var(--look-caption); }

/* An empty view: the blank message alone in the middle of the page, with a heading of its own. */
.kit-blank--page { max-width: 460px; margin: 10vh auto 0; }

/* -------------------------------- a search -------------------------------- */

/* What a search found (ui.js searchResults): each kind under its heading, with how many. */
.kit-results__section:first-child .kit-results__title { margin-block-start: 4px; }
.kit-results__count { font-variant-numeric: tabular-nums; font-weight: 600; color: var(--kit-faint); }
.kit-results--none .kit-blank { max-width: 460px; margin: 10vh auto 0; }
/* The words found, in every module's rows (ui.js highlight). */
mark.kit-mark { background: var(--kit-accent-soft); color: var(--kit-text); border-radius: var(--look-r-xs); padding: 0 1px; }

/* ------------------------------ photos and files ----------------------------- */

/* An item's «Archivos» (files.js attachments): photos as squares that fill the row, as many as
   fit, and a PDF as a row of its own with its name and size. */
.kit-files { margin-block-start: 18px; }
.kit-files__title { display: flex; align-items: center; gap: 8px; margin: 0 0 8px; font-size: var(--look-footnote); font-weight: 500; color: var(--kit-muted); }
.kit-files__count { font-variant-numeric: tabular-nums; color: var(--kit-faint); }
.kit-files__grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(104px, 1fr)); gap: 8px; margin-block: 0 10px; }
.kit-files__none { margin: 0 0 10px; }
.kit-files__add .kit-icon { width: 16px; height: 16px; }
.kit-files__drop { margin: 6px 0 0; }
/* «or drop one here» only where a file can be dragged: a mouse. */
@media not ((hover: hover) and (pointer: fine)) { .kit-files__drop { display: none; } }
.kit-file { position: relative; min-width: 0; }
.kit-file__open { display: block; width: 100%; padding: 0; border: 0; background: none; cursor: zoom-in; border-radius: var(--look-r-md); }
.kit-file--photo img {
  display: block; width: 100%; aspect-ratio: 1; object-fit: cover;
  border-radius: var(--look-r-md); border: 1px solid var(--kit-border); background: var(--kit-hover);
}
.kit-file--doc { grid-column: 1 / -1; }
.kit-file__link {
  display: flex; align-items: center; gap: 8px; padding: 8px 10px; padding-inline-end: 36px;
  border: 1px solid var(--kit-border); border-radius: var(--look-r-md); background: var(--kit-hover);
  color: inherit; text-decoration: none;
}
.kit-file__link .kit-icon { width: 18px; height: 18px; flex: none; color: var(--kit-muted); }
.kit-file__name { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.kit-file__size { flex: none; font-size: var(--look-footnote); color: var(--kit-faint); font-variant-numeric: tabular-nums; }
.kit-files__remove {
  position: absolute; inset-block-start: 4px; inset-inline-end: 4px; width: 24px; height: 24px; display: grid; place-items: center;
  border: 0; border-radius: 50%; background: rgba(0, 0, 0, .55); color: #fff; cursor: pointer; padding: 0;
}
.kit-file--doc .kit-files__remove { inset-block-start: 50%; transform: translateY(-50%); }
.kit-files__remove .kit-icon { width: 14px; height: 14px; }
.kit-files__remove:hover { background: rgba(0, 0, 0, .78); }
/* With a mouse the × shows on the file it is over; a finger has no hover, so there it always shows. */
@media (hover: hover) and (pointer: fine) {
  .kit-files__remove { opacity: 0; transition: opacity .15s; }
  .kit-file:is(:hover, :focus-within) .kit-files__remove { opacity: 1; }
}
/* A detail with a file carried over it: where it will land. */
.kit-files-over { outline: 2px dashed var(--kit-accent); outline-offset: -6px; }

/* The photo viewer (files.js photoViewer): the photo rules, and never leaves the screen. */
.kit-viewer { display: flex; flex-direction: column; align-items: center; gap: 8px; }
/* The frame crops the enlarged photo; the gesture is the viewer's, not the page's scroll. */
.kit-viewer__frame {
  width: 100%; height: min(76dvh, 820px); display: flex; align-items: center; justify-content: center; overflow: hidden;
  border-radius: var(--look-r-sm); background: var(--kit-hover); touch-action: none; cursor: zoom-in;
}
.kit-viewer__frame--zoomed { cursor: grab; }
.kit-viewer__frame--zoomed:active { cursor: grabbing; }
.kit-viewer__photo {
  max-width: 100%; max-height: 100%; object-fit: contain; transform-origin: center center; will-change: transform;
  user-select: none; -webkit-user-drag: none;
}
/* As tall with a magnification or without: the photo doesn't jump while it is looked at. */
.kit-viewer__bar { display: flex; align-items: center; gap: 10px; min-height: 26px; }
.kit-viewer__counter { font-size: var(--look-footnote); color: var(--kit-muted); font-variant-numeric: tabular-nums; }
.kit-viewer__zoom { min-width: 34px; font-size: var(--look-caption); color: var(--kit-faint); font-variant-numeric: tabular-nums; }
.kit-viewer__help { color: var(--kit-faint); text-align: center; }
/* With a mouse there is no pinch: it says what does work (its words in data-wheel-hint, files.js). */
@media (hover: hover) and (pointer: fine) {
  .kit-viewer__help::after { content: ' ' attr(data-wheel-hint); }
}

/* ------------------------------- public page ------------------------------ */

/* A public page's dialog (public-page.js): what it shows, its link and the code to embed it. */
.kit-public .kit-hint { margin: 0; }
.kit-public__list { margin: 0; padding-inline-start: 18px; color: var(--kit-muted); display: grid; gap: 4px; }
.kit-public__row { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.kit-public__link { flex: 1 1 220px; min-width: 0; font-family: var(--kit-font-mono); font-size: 13px; }
/* The code to embed it in a website, folded under the link. */
.kit-public__embed { border-top: 1px solid var(--kit-border); padding-top: 10px; display: grid; gap: 10px; }
.kit-public__embed summary { display: inline-flex; align-items: center; gap: 8px; cursor: pointer; font-weight: 600; width: max-content; max-width: 100%; }
.kit-public__code { width: 100%; resize: vertical; font-family: var(--kit-font-mono); font-size: 12px; line-height: 1.45; word-break: break-all; }
