/* owner: admin-v2 B1 · contract: server/ADMIN-V2.md sec. 4.5 (the class vocabulary), 4.6 (fonts), 6.3 to 6.5 (focus, motion,
   transparency)
   The base of v2, ported from the approved sketch (teal): reset, the self-hosted Rubik, the surface inks, glass, the orb, the
   band/page/wrap layout and every shared component class. Page files only compose these under their own root.

   Rubik: Copyright 2015 The Rubik Project Authors (https://github.com/googlefonts/rubik).
   This Font Software is licensed under the SIL Open Font License, Version 1.1. This license is available with a FAQ at:
   https://openfontlicense.org
   The files in ../fonts are the Hebrew and Latin subsets Google Fonts serves (Rubik v31), unmodified: one variable file per
   subset (weights 300 to 900); the admin uses 400 and 500. */

@font-face {
  font-family: 'Rubik';
  font-style: normal;
  font-weight: 300 900;
  font-display: swap;
  src: url('../fonts/rubik-hebrew.woff2') format('woff2');
  unicode-range: U+0307-0308, U+0590-05FF, U+200C-2010, U+20AA, U+25CC, U+FB1D-FB4F;
}
@font-face {
  font-family: 'Rubik';
  font-style: normal;
  font-weight: 300 900;
  font-display: swap;
  src: url('../fonts/rubik-latin.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F,
    U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

/* ---------- reset ---------- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
[hidden] { display: none !important; }
html { background-color: var(--ground); -webkit-text-size-adjust: 100%; }
body {
  min-height: 100dvh; background-color: var(--ground); color: var(--ink);
  font: 400 16px/1.5 var(--font); -webkit-font-smoothing: antialiased;
}
button, input, select, textarea { font: inherit; color: inherit; }
/* an empty dir="auto" field resolves to LTR, which left-aligns a Hebrew placeholder and clips its start (any input or textarea,
   classed or not, e.g. #maya-input); once there is text, dir="auto" picks the direction again */
[dir="auto"]:placeholder-shown { direction: rtl; }
button { border: 0; background-color: transparent; cursor: pointer; }
button:disabled { cursor: not-allowed; }
a { color: inherit; }
ul, ol { list-style: none; }
b, strong, h1, h2, h3, h4 { font-weight: 500; }
fieldset { min-width: 0; border: 0; }
summary { cursor: pointer; }
:focus-visible { outline: 2px solid var(--ring); outline-offset: 2px; }
[tabindex="-1"]:focus { outline: none; }

/* ---------- utilities ---------- */
.sr-only {
  position: absolute !important; width: 1px; height: 1px; margin: -1px; padding: 0; overflow: hidden;
  clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}
.muted { color: var(--fgMuted); }
.num { font-variant-numeric: tabular-nums; }
bdi.num, a.num { white-space: nowrap; }
.linkish {
  display: inline; padding: 0; border: 0; background-color: transparent; color: inherit;
  font-weight: 500; text-decoration: underline; text-underline-offset: 3px; cursor: pointer;
}
.fact-src {
  display: inline-flex; align-items: center; gap: 5px; max-width: 100%; margin-top: 6px;
  font-size: 13px; color: var(--fgMuted); text-decoration: none;
}
.fact-src span { overflow: hidden; white-space: nowrap; text-overflow: ellipsis; unicode-bidi: plaintext; }
a.fact-src:hover span { text-decoration: underline; }
.skip {
  position: fixed; z-index: var(--z-skip); top: 8px; inset-inline-start: 8px;
  padding: 10px 18px; border-radius: var(--r); background-color: var(--solid); color: var(--onSolid);
  font-weight: 500; text-decoration: none; transform: translateY(-200%); transition: transform .15s;
}
.skip:focus { transform: none; }
.boot { display: grid; place-items: center; min-height: 100dvh; }
.boot .orb { --o: 72px; }
.noscript { padding: 24px; }
.sprite { position: absolute; width: 0; height: 0; overflow: hidden; }

/* icons: the sprite in index.html through dom.js icon() */
.icon {
  display: inline-block; flex: none; width: 20px; height: 20px; vertical-align: middle;
  fill: none; stroke: currentColor; stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round;
}
.icon.sm { width: 16px; height: 16px; }
.icon.flip-rtl { transform: scaleX(-1); }
.icon.hang { transform: rotate(135deg); }

/* ---------- surface inks ----------
   Plain controls and secondary text read --fg and its friends; every surface sets them once. A light box inside a dark one
   (a white card on the band, a notice in a dark card) is covered by the first rule. */
:root, .card:not(.dark, .bandcard), .notice {
  --fg: var(--ink); --fgOn: var(--onSolid); --fgMuted: var(--muted); --fgLine: var(--ink);
  --fgSoft: rgba(0, 0, 0, .06); --fgFill: var(--stone); --ring: var(--ink);
}
.band, .card.dark, .card.bandcard, .stage, .mlive {
  --fg: #fff; --fgLine: rgba(255, 255, 255, .55); --fgSoft: rgba(255, 255, 255, .14); --fgFill: rgba(255, 255, 255, .13);
  --ring: #fff;
}
.band { --fgOn: var(--band); --fgMuted: var(--onBandMuted); }
.card.bandcard { --fgOn: var(--bandCard); --fgMuted: var(--onBandCard); }
.card.dark, .stage, .mlive { --fgOn: var(--deep); --fgMuted: var(--onDeep); }
.card.spark { --fg: var(--onSpark); --fgOn: var(--spark); --fgMuted: var(--onSpark); --fgLine: var(--onSpark); }

/* ---------- Liquid Glass: the functional layer only (nav, tab bar, Maya) ---------- */
.glass {
  isolation: isolate; background-color: var(--glass);
  -webkit-backdrop-filter: blur(20px) saturate(170%); backdrop-filter: blur(20px) saturate(170%);
  border: 1px solid rgba(255, 255, 255, .6);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .9), inset 0 -1px 0 rgba(255, 255, 255, .28), 0 18px 50px rgba(0, 0, 0, .14),
    0 2px 8px rgba(0, 0, 0, .06);
}
.glass::before {
  content: ""; position: absolute; inset: 0; z-index: -1; border-radius: inherit; pointer-events: none;
  background-image: linear-gradient(180deg, rgba(255, 255, 255, .55), rgba(255, 255, 255, 0) 16%, rgba(255, 255, 255, 0) 84%,
    rgba(255, 255, 255, .2));
}
@supports not ((backdrop-filter: blur(1px)) or (-webkit-backdrop-filter: blur(1px))) {
  .glass { background-color: var(--glassSolid); }
}
@media (prefers-reduced-transparency: reduce) {
  .glass { background-color: var(--glassSolid); -webkit-backdrop-filter: none; backdrop-filter: none; }
}

/* ---------- the orb: Maya's clear glass orb with a conic spark glow ---------- */
.orb {
  --o: 46px; position: relative; flex: none; width: var(--o); height: var(--o); overflow: hidden; isolation: isolate;
  border-radius: 50%;
  background-image: radial-gradient(circle at 50% 50%, rgba(255, 255, 255, .06) 52%, rgba(255, 255, 255, .5) 100%);
  -webkit-backdrop-filter: blur(3px) saturate(160%); backdrop-filter: blur(3px) saturate(160%);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .8), inset 0 -3px 8px rgba(255, 255, 255, .45), 0 4px 14px rgba(0, 0, 0, .1);
  animation: breathe 3.6s ease-in-out infinite;
}
.orb::before {
  content: ""; position: absolute; inset: -18%;
  background-image: conic-gradient(from 0deg, var(--spark), color-mix(in srgb, var(--band) 75%, #fff), transparent 42%,
    var(--spark) 66%, color-mix(in srgb, var(--band) 65%, #fff) 84%, var(--spark));
  -webkit-mask-image: radial-gradient(circle, #000 28%, transparent 68%); mask-image: radial-gradient(circle, #000 28%, transparent 68%);
  filter: blur(8px); opacity: .5; animation: spin 7s linear infinite;
}
.orb::after {
  content: ""; position: absolute; inset: 0; border-radius: 50%;
  background-image: radial-gradient(circle at 30% 24%, rgba(255, 255, 255, .95) 0 6%, rgba(255, 255, 255, 0) 26%),
    radial-gradient(circle at 70% 80%, rgba(255, 255, 255, .5) 0 4%, rgba(255, 255, 255, 0) 17%);
}
.orb.sm { --o: 40px; }
.orb.lg { --o: 132px; }
.orb[data-s="live"] {
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .8), inset 0 -3px 8px rgba(255, 255, 255, .45),
    0 4px 18px color-mix(in srgb, var(--spark) 40%, transparent);
}
.orb[data-s="live"]::before { opacity: .85; animation-duration: 2.6s; }
.orb[data-s="wait"] { animation: ripple 1.3s ease-out infinite; }
.orb[data-s="wait"]::before { opacity: .85; animation-duration: 4s; }
.orb[data-s="off"] { filter: grayscale(1); animation: none; }
.orb[data-s="off"]::before { opacity: .3; animation: none; }

/* ---------- layout: the band under the glass nav, then the page ---------- */
.band { padding-block: 44px 48px; padding-inline: var(--gs) 32px; background-color: var(--band); color: var(--onBand); }
.in, .wrap { max-width: 1200px; margin-inline: auto; }
.page { padding-inline: var(--gs) 32px; }
.wrap { padding-block: 56px 80px; }
.mhead { display: none; }
.date { margin-bottom: 12px; font-size: 15px; color: var(--fgMuted); }
.display { font-size: 64px; line-height: .92; letter-spacing: -.02em; font-weight: 500; text-wrap: balance; }
.row3 { display: grid; grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr) minmax(0, 1fr); gap: 20px; margin-top: 34px; }
.sechead { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 16px; margin-bottom: 20px; }
.h2 { font-size: 40px; line-height: 1; letter-spacing: -.02em; font-weight: 500; }
.grid2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; }
.span2 { grid-column: 1 / -1; }

/* ---------- cards: flat boxes told apart by value ---------- */
.card { min-width: 0; padding: 28px; border-radius: var(--r); background-color: var(--card); color: var(--ink); }
.card.parch { background-color: var(--parch); }
.card.dark { background-color: var(--deep); color: #fff; }
.card.bandcard { background-color: var(--bandCard); color: var(--onBand); }
.card.spark { background-color: var(--spark); color: var(--onSpark); }
.card > :first-child { margin-top: 0; }
.card p { color: var(--fgMuted); }
.card :is(.h3, .headline, .quote, .fact) { color: inherit; }
.chead { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px 12px; min-height: 22px; }
.kicker { display: block; font-size: 14px; line-height: 1.5; font-weight: 500; color: var(--fgMuted); }
.headline { margin: 14px 0 8px; font-size: 30px; line-height: 1.08; letter-spacing: -.015em; font-weight: 500; text-wrap: balance; }
.h3 { margin: 10px 0 4px; font-size: 22px; line-height: 1.2; letter-spacing: -.01em; font-weight: 500; text-wrap: balance; }
.big { margin: 16px 0 10px; font-size: 56px; line-height: .92; letter-spacing: -.02em; font-weight: 500; }
.big small { font-size: 22px; letter-spacing: 0; }
.fact { margin-top: 10px; font-size: 19px; line-height: 1.35; }
.quote { margin-top: 12px; font-size: 26px; line-height: 1.25; letter-spacing: -.01em; font-weight: 500; text-wrap: balance; }
.note { margin-top: 10px; font-size: 14px; color: var(--fgMuted); }
.stats { display: grid; gap: 6px; margin-top: 14px; color: var(--fgMuted); }
.stats b { margin-inline-end: 6px; color: var(--fg); }
.acts { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 22px; }

/* ---------- buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px; height: 48px; padding: 0 20px;
  border: 1px solid var(--fgLine); border-radius: var(--r); background-color: transparent; color: var(--fg);
  font-size: 15px; font-weight: 500; line-height: 1.2; white-space: nowrap; text-decoration: none; cursor: pointer;
  transition: background-color .15s, border-color .15s, color .15s;
}
.btn:hover { background-color: var(--fgSoft); }
.btn.fill { border-color: var(--solid); background-color: var(--solid); color: var(--onSolid); }
.btn.cta { border-color: var(--ctaLine); background-color: var(--cta); color: var(--onCta); }
.btn.inspark { border-color: var(--sparkBtn); background-color: var(--sparkBtn); color: var(--onSparkBtn); }
.btn.ghost-spark { border-color: var(--onSpark); color: var(--onSpark); }
.btn.ghost-spark:hover { background-color: rgba(255, 255, 255, .14); }
.btn.ghost-l { border-color: rgba(255, 255, 255, .55); color: #fff; }
.btn.ghost-l:hover { background-color: rgba(255, 255, 255, .1); }
.btn.danger { border-color: var(--bad); background-color: var(--bad); color: #fff; }
.btn.quiet { border-color: transparent; }
.btn.sm { height: 36px; padding: 0 14px; font-size: 13px; }
.btn.sm .icon { width: 18px; height: 18px; }
.btn[aria-pressed="true"]:not(.fill, .cta, .inspark, .danger) { border-color: var(--fg); background-color: var(--fg); color: var(--fgOn); }
.btn[data-confirm="true"] { border-color: var(--bad); background-color: var(--bad); color: #fff; box-shadow: 0 0 0 3px var(--badSoft); }
.btn:disabled:not([aria-busy="true"]) { opacity: .45; cursor: not-allowed; }
.btn[aria-busy="true"] { pointer-events: none; }
.btn[aria-busy="true"] .icon { display: none; }
.btn[aria-busy="true"]::before {
  content: ""; flex: none; width: 16px; height: 16px; border: 2px solid currentColor; border-top-color: transparent;
  border-radius: 50%; animation: spin .8s linear infinite;
}
.icb, .xb {
  display: inline-grid; place-items: center; flex: none; border-radius: 50%; color: var(--fg); text-decoration: none; cursor: pointer;
}
.icb { width: 48px; height: 48px; border: 1px solid var(--fgLine); background-color: var(--fgFill); }
.xb { width: 36px; height: 36px; margin-inline-start: auto; border: 0; background-color: var(--fgSoft); }
.icb:hover, .xb:hover { background-image: linear-gradient(var(--fgSoft), var(--fgSoft)); }
.icb[aria-pressed="true"], .xb[aria-pressed="true"] { border-color: var(--fg); background-color: var(--fg); color: var(--fgOn); }
.icb:disabled, .xb:disabled { opacity: .45; cursor: not-allowed; }

/* ---------- trays (tabs, section links), radio pills, radio cards, switches ---------- */
.tray {
  display: flex; gap: 2px; width: max-content; max-width: 100%; padding: 4px; overflow-x: auto; scrollbar-width: none;
  border-radius: var(--r); background-color: var(--fgFill);
}
.tray::-webkit-scrollbar { display: none; }
.tray > * {
  display: inline-flex; flex: none; align-items: center; gap: 6px; min-height: 44px; padding: 0 18px;
  border-radius: var(--r); color: var(--fg); font-size: 15px; font-weight: 500; white-space: nowrap; text-decoration: none; cursor: pointer;
}
.tray > :hover { background-color: var(--fgSoft); }
.tray > [aria-selected="true"], .tray > [aria-current="page"] { background-color: var(--fg); color: var(--fgOn); }
.tray > :focus-visible { outline-offset: -2px; }
.tray .count { font-size: 13px; font-variant-numeric: tabular-nums; opacity: .75; }
.tray .count:empty { display: none; }
.stray { margin-top: 32px; }

.seg {
  display: inline-flex; flex-wrap: wrap; gap: 2px; max-width: 100%; margin-top: 16px; padding: 4px;
  border-radius: var(--r); background-color: var(--fgFill);
}
.seg label { position: relative; display: flex; min-width: 0; }
.seg input { position: absolute; inset: 0; width: 100%; height: 100%; margin: 0; opacity: 0; cursor: pointer; }
.seg span {
  display: inline-flex; align-items: center; justify-content: center; min-height: 44px; padding: 0 16px;
  border-radius: var(--r); color: var(--fg); font-size: 15px; font-weight: 500; text-align: center;
}
.seg label:hover span { background-color: var(--fgSoft); }
.seg input:checked + span { background-color: var(--fg); color: var(--fgOn); }
.seg input:focus-visible + span { outline: 2px solid var(--ring); outline-offset: 2px; }
.seg input:disabled + span { opacity: .45; }

.choices { display: grid; grid-template-columns: minmax(0, 1fr); gap: 10px; margin-top: 16px; }
.choices.two { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.choice { position: relative; display: block; min-width: 0; }
.choice input { position: absolute; inset: 0; width: 100%; height: 100%; margin: 0; opacity: 0; cursor: pointer; }
.choice-body {
  display: grid; gap: 2px; min-height: 44px; padding: 14px 20px; border-radius: var(--r); color: var(--ink);
  background-color: var(--parch); box-shadow: inset 0 0 0 1px var(--line); transition: background-color .15s, box-shadow .15s;
}
.choice-body span { font-size: 14px; line-height: 1.45; color: var(--muted); }
.choice:hover .choice-body { box-shadow: inset 0 0 0 1px var(--muted); }
.choice input:checked + .choice-body { background-color: var(--ground); box-shadow: inset 0 0 0 2px var(--ink); }
.choice input:focus-visible + .choice-body { outline: 2px solid var(--ring); outline-offset: 2px; }
.choice input:disabled + .choice-body { opacity: .5; }

.toggle { display: flex; align-items: center; justify-content: space-between; gap: 16px; min-height: 44px; margin-top: 16px; cursor: pointer; }
.toggle-text { display: grid; gap: 2px; min-width: 0; }
.toggle-text span { font-size: 14px; line-height: 1.45; color: var(--fgMuted); }
.toggle input {
  position: relative; flex: none; width: 52px; height: 32px; margin: 0; border-radius: 16px;
  background-color: var(--fgFill); -webkit-appearance: none; appearance: none; cursor: pointer; transition: background-color .2s;
}
.toggle input::after {
  content: ""; position: absolute; top: 3px; inset-inline-start: 3px; width: 26px; height: 26px; border-radius: 50%;
  background-color: #fff; box-shadow: 0 1px 3px rgba(0, 0, 0, .25); transition: inset-inline-start .2s var(--spring);
}
.toggle input:checked { background-color: var(--fg); }
.toggle input:checked::after { inset-inline-start: 23px; background-color: var(--fgOn); }
.toggle input:disabled { opacity: .45; cursor: not-allowed; }

.check { display: flex; align-items: flex-start; gap: 10px; min-height: 44px; padding-block: 10px; cursor: pointer; }
.check input { flex: none; width: 20px; height: 20px; margin-top: 2px; accent-color: var(--solid); cursor: pointer; }

/* ---------- form fields: label above, help and error below ---------- */
.field { display: grid; gap: 6px; min-width: 0; margin-top: 16px; }
.flabel { font-size: 14px; font-weight: 500; color: var(--fg); }
.fhelp { font-size: 13px; line-height: 1.45; color: var(--fgMuted); }
.ferr { display: flex; align-items: flex-start; gap: 6px; font-size: 13px; font-weight: 500; color: var(--bad); }
.ferr .icon { margin-top: 1px; }
.fhelp:empty, .ferr:empty { display: none; }
.input, .select, .textarea {
  width: 100%; min-height: 48px; padding: 0 20px; border: 0; border-radius: var(--r);
  background-color: var(--parch); box-shadow: inset 0 0 0 1px var(--line); color: var(--ink); font-size: 16px;
  transition: box-shadow .15s;
}
.textarea { display: block; min-height: 96px; padding: 12px 18px; border-radius: 20px; line-height: 1.5; resize: vertical; }
.input::placeholder, .textarea::placeholder { color: var(--muted); opacity: 1; }
.input:hover, .select:hover, .textarea:hover { box-shadow: inset 0 0 0 1px var(--muted); }
.input[dir="ltr"] { text-align: end; }
.input[aria-invalid="true"], .select[aria-invalid="true"], .textarea[aria-invalid="true"] { box-shadow: inset 0 0 0 2px var(--bad); }
.input:disabled, .select:disabled, .textarea:disabled { opacity: .55; cursor: not-allowed; }
.select {
  padding-inline-end: 48px; -webkit-appearance: none; appearance: none; cursor: pointer;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%236d6d6d' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-size: 16px; background-position: left 18px center;
}

/* ---------- chips and status dots ---------- */
.chip {
  display: inline-flex; align-items: center; gap: 7px; min-height: 26px; max-width: 100%; padding: 3px 10px;
  border-radius: var(--chip); background-color: var(--ground); color: var(--ink); font-size: 13px; font-weight: 500; line-height: 1.25;
}
.chip.strong { background-color: var(--solid); color: var(--onSolid); }
.dot { display: inline-block; flex: none; width: 8px; height: 8px; border-radius: 50%; background-color: var(--muted); }
.dot.ok { background-color: var(--ok); }
.dot.bad, .dot.rec { background-color: var(--bad); }
.dot.wait { background-color: var(--wait); box-shadow: inset 0 0 0 1px rgba(0, 0, 0, .15); }
.dot.rec { animation: blink 1.2s ease-in-out infinite; }

/* ---------- list rows ---------- */
.row {
  position: relative; display: flex; align-items: center; gap: 14px; width: 100%; padding: 14px;
  border: 0; border-top: 1px solid var(--line); background-color: transparent; color: inherit;
  font: inherit; text-align: start; text-decoration: none; cursor: pointer;
}
.row:hover { background-color: var(--parch); }
.row[aria-current="true"] { background-color: var(--ground); }
.row[aria-current="true"]::before {
  content: ""; position: absolute; inset-block: 12px; inset-inline-start: 0; width: 3px; background-color: var(--solid);
}
.ic { display: grid; place-items: center; flex: none; width: 44px; height: 44px; border-radius: 50%; background-color: var(--ground); }
.row[aria-current="true"] :is(.ic, .chip) { background-color: #fff; }
.rmain { flex: 1; min-width: 0; }
.rmain b { display: block; overflow-wrap: anywhere; }
.sum { display: block; overflow: hidden; font-size: 14px; color: var(--fgMuted); white-space: nowrap; text-overflow: ellipsis; }
.meta {
  display: grid; justify-items: end; gap: 6px; flex: 0 1 auto; min-width: 0; max-width: 50%;
  font-size: 14px; color: var(--fgMuted);
}

/* ---------- definition lists, meters, notices, empty states, skeletons ---------- */
.kv { display: grid; grid-template-columns: minmax(0, max-content) minmax(0, 1fr); column-gap: 18px; margin-top: 14px; font-size: 15px; }
.kv dt, .kv dd { padding-block: 10px; border-bottom: 1px solid var(--line); }
.kv dt { color: var(--fgMuted); }
.kv dd { min-width: 0; overflow-wrap: anywhere; }
.kv > :nth-last-child(-n + 2) { border-bottom: 0; }

.meter { display: block; height: 10px; margin-top: 6px; overflow: hidden; border-radius: var(--r); background-color: var(--stone); }
.meter > span { display: block; width: var(--p, 0%); height: 100%; border-radius: inherit; background-color: var(--solid); }
.meter[data-level="warn"] > span { background-color: var(--wait); }
.meter[data-level="cap"] > span { background-color: var(--bad); }

.notice {
  display: flex; flex-wrap: wrap; align-items: flex-start; gap: 10px 12px; margin-top: 14px; padding: 14px 20px;
  border-radius: var(--r); background-color: var(--ground); color: var(--ink); font-size: 15px; line-height: 1.5;
}
.notice > .icon { margin-top: 2px; color: var(--muted); }
.notice > div { flex: 1 1 14em; min-width: 0; }
.notice p { color: inherit; }
.notice.ok { background-color: var(--okSoft); }
.notice.ok > .icon { color: var(--ok); }
.notice.warn { background-color: var(--waitSoft); }
.notice.warn > .icon { color: var(--ink); }
.notice.danger { background-color: var(--badSoft); }
.notice.danger > .icon { color: var(--bad); }

.empty { display: grid; justify-items: start; gap: 4px; padding: 20px 14px; color: var(--fgMuted); }
.empty strong { color: var(--fg); font-size: 17px; }
.empty .btn { margin-top: 10px; }

.skel {
  display: block; border-radius: var(--chip); background-color: var(--fgSoft);
  background-image: linear-gradient(90deg, transparent, rgba(255, 255, 255, .45), transparent);
  background-size: 200% 100%; background-repeat: no-repeat; animation: shimmer 1.4s linear infinite;
}
.skel-row { height: 52px; margin-block: 12px; }

/* ---------- bubbles (variants: .me in shell.css, .maya and .them in calls.css), save state ---------- */
.bub { max-width: 86%; padding: 12px 18px; border-radius: var(--r); font-size: 15px; line-height: 1.45; overflow-wrap: anywhere; }
.save-state { display: inline-flex; align-items: center; gap: 6px; min-height: 22px; font-size: 13px; font-weight: 500; color: var(--fgMuted); }
.save-state[data-state="saved"] .icon { color: var(--ok); }
.save-state[data-state="error"] { color: var(--bad); }

/* ---------- toasts and the confirm dialog ---------- */
.toasts {
  position: fixed; z-index: var(--z-toast); inset-inline: 16px; bottom: 28px;
  display: flex; flex-direction: column; align-items: center; gap: 8px; pointer-events: none;
}
.toast {
  display: flex; align-items: center; gap: 10px; max-width: min(520px, 100%); padding: 12px 18px; border-radius: var(--r);
  background-color: var(--solid); color: var(--onSolid); font-size: 14px; font-weight: 500;
  box-shadow: 0 12px 32px rgba(0, 0, 0, .18); pointer-events: auto; animation: rise .3s var(--spring);
}
.toast.danger { background-color: var(--bad); color: #fff; }
.toast .icon { width: 18px; height: 18px; }
.dialog {
  width: min(440px, calc(100vw - 32px)); margin: auto; padding: 28px; border: 0; border-radius: var(--r);
  background-color: var(--card); color: var(--ink); box-shadow: 0 24px 60px rgba(0, 0, 0, .25);
}
.dialog::backdrop { background-color: rgba(27, 27, 27, .45); }
.dialog h2 { font-size: 24px; line-height: 1.15; letter-spacing: -.01em; }
.dialog p { margin-top: 10px; color: var(--muted); }
.dialog-actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 24px; }
.dialog-body { display: grid; gap: 12px; margin-top: 16px; }
.dialog-body .textarea { min-height: 72px; }
.crm-acts { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 12px; }
.crm-history { margin-top: 8px; display: grid; gap: 4px; font-size: 13px; color: var(--muted); }

/* ---------- motion ---------- */
@keyframes breathe { 50% { transform: scale(1.045); } }
@keyframes spin { to { transform: rotate(1turn); } }
@keyframes ripple {
  0% { box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .8), 0 0 0 0 color-mix(in srgb, var(--spark) 70%, transparent); }
  100% { box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .8), 0 0 0 20px transparent; }
}
@keyframes blink { 50% { opacity: .3; } }
@keyframes shimmer { from { background-position: 150% 0; } to { background-position: -50% 0; } }
@keyframes rise { from { opacity: 0; transform: translateY(8px); } }
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
}

/* ---------- widths (sec. 2.1, 6.4): 1100 the band's cards become 2, 760 and down the phone ---------- */
@media (max-width: 1100px) {
  .row3 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .row3 > .spark { grid-column: 1 / -1; }
}
@media (max-width: 760px) {
  .band { padding: calc(14px + env(safe-area-inset-top)) 16px 28px; }
  .mhead { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 26px; }
  .mhead .logo { font-size: 26px; line-height: 1; letter-spacing: -.03em; font-weight: 500; }
  .display { font-size: 40px; }
  .row3 {
    grid-template-columns: none; grid-auto-flow: column; grid-auto-columns: 86%; gap: 12px; margin: 24px -16px 0; padding: 0 16px;
    overflow-x: auto; scroll-snap-type: x mandatory; scroll-padding-inline: 16px; scrollbar-width: none;
  }
  .row3::-webkit-scrollbar { display: none; }
  .row3 > * { scroll-snap-align: start; }
  .row3 > .spark { grid-column: auto; }
  .page { padding-inline: 16px; }
  .wrap { padding-block: 28px calc(130px + env(safe-area-inset-bottom)); }
  .grid2, .choices.two { grid-template-columns: minmax(0, 1fr); }
  .stray { width: auto; max-width: none; margin: 26px -16px 0; padding: 0 16px; gap: 6px; border-radius: 0; background-color: transparent; }
  .stray > * { background-color: var(--fgFill); }
  .card { padding: 22px; }
  .h2 { font-size: 30px; }
  .big { font-size: 44px; }
  .quote { font-size: 22px; }
  .toasts { bottom: calc(100px + env(safe-area-inset-bottom)); }
}
