/* TokenHub admin console. Tokens from the design handoff; classes are prefixed `cp-`.
   The palette follows the Claude Design project's own tokens (`--om-*`), read from its computed styles so the two
   themes match the design rather than approximating it: light is `#faf9f5` on `#0f0c08`, dark is `#1c1b19` with
   `#2a2927` cards, and the accent is the design's clay `#d97757` / `#e08968`. */
:root {
  --ink: #0f0c08;
  --ink-hover: #2b2620;
  --paper: #faf9f5;
  --sidebar: #f8f7f3;
  --card: #ffffff;
  --table-head: #f8f7f3;
  --border: #0f0c081f;
  --border-2: #0f0c0814;
  --border-3: #0f0c080f;
  --border-btn: #0f0c0829;
  --border-dashed: #0f0c0829;
  --track: #f0eee6;
  --hover: #0f0c080a;
  --input-bg: #ffffff;
  --text-2: #0f0c08a3;
  --text-3: #0f0c0899;
  --text-4: #0f0c0899;
  --muted: #0f0c0880;
  --deep: #0f0c08;
  --deep-line: #2b2620;
  --on-deep: #faf9f5;
  --on-dark: #faf9f5a3;
  --on-dark-muted: #faf9f599;
  --on-dark-strong: #fff;
  --border-on-dark: #faf9f53d;
  --link: #b45a38;
  --link-hover: #94472c;
  --clay: #d97757;
  --clay-hover: #e08968;
  --clay-deep: #a34d2c;
  --clay-tint: #d977570a;
  --clay-tint-2: #d977571f;
  --clay-tint-3: #e8b39c;
  --clay-tint-4: #e0a88f;
  --clay-tint-hover: #d9775729;
  --on-clay: #0f0c08;
  --amber: #c9a82d;
  --ok: #558a42;
  --ok-deep: #3f6b31;
  --ok-tint: #558a421f;
  --danger: #a63244;
  --danger-tint: #a632441f;
  --danger-solid: #a63244;
  --danger-solid-hover: #8c2939;
  --on-danger: #faf9f5;
  --grey-tint: #f0eee6;
  --toast-ok: #558a42;
  --toast-warn: #d97757;
  --toast-err: #a63244;
  --knob: #fff;
  --knob-on: #fff;
  --shadow-sm: rgba(15, 12, 8, 0.08);
  --shadow-md: rgba(15, 12, 8, 0.12);
  --shadow-lg: rgba(15, 12, 8, 0.24);
  /* Each provider's own colour (#468), so a card's hover border and its logo tile say which provider it is before the
     name is read. The same three in both themes; they are brand colours, not surface colours. */
  --prov-anthropic: #d9774f;
  --prov-deepseek: #4d6bfe;
  --prov-river: #2fa7a0;
  --prov-antigravity: #4285f4;
  /* OpenAI's mark is a raster, a white glyph on an opaque black square. Inverted and multiplied it is a black glyph on
     the light card; left as it is and screened it is a white glyph on the dark one. Either way the square vanishes. */
  --mark-img-filter: invert(1);
  --mark-img-blend: multiply;
  --backdrop: rgba(15, 12, 8, 0.16);
  --overlay: rgba(15, 12, 8, 0.32);
  --chart-0: #d97757;
  --chart-1: #558a42;
  --chart-2: #2a78d6;
  --chart-3: #c9a82d;
  --chart-4: #8a6bb5;
  --chart-5: #3fa7a0;
  --chart-6: #b9b2a3;
  --sun-display: none;
  --moon-display: block;
  /* The top bar's theme button (#624) cross-fades its two glyphs: each is drawn, and the theme sets which one shows. */
  --tb-moon-o: 1;
  --tb-moon-t: none;
  --tb-sun-o: 0;
  --tb-sun-t: rotate(-90deg) scale(0.5);
  --sans: "Styrene B", "Anthropic Sans", "DM Sans", system-ui, sans-serif;
  --serif: "Tiempos Headline", "Copernicus", "Anthropic Serif", Newsreader, "Source Serif 4", Georgia, serif;
  --mono: "JetBrains Mono", ui-monospace, monospace;
  color-scheme: light;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --ink: #ece6dc;
    --ink-hover: #f5f0e8;
    --paper: #181512;
    --sidebar: #1d1915;
    --card: #201c18;
    --table-head: #262119;
    --border: #2f2923;
    --border-2: #2a251f;
    --border-3: #262119;
    --border-btn: #3a332b;
    --border-dashed: #3a332b;
    --track: #2a241e;
    --hover: #ffffff0f;
    --input-bg: #14110e;
    --text-2: #b8afa2;
    --text-3: #9a9185;
    --text-4: #7d7568;
    --muted: #9a9185;
    --deep: #201c18;
    --deep-line: #2f2923;
    --on-deep: #ece6dc;
    --on-dark: #ece6dc;
    --on-dark-muted: #9a9185;
    --on-dark-strong: #fff;
    --border-on-dark: #3a332b;
    --on-clay: #181512;
    --on-danger: #181512;
    --amber: #e8b04b;
    --link: #e8743b;
    --link-hover: #f39a6b;
    --clay: #e8743b;
    --clay-hover: #f39a6b;
    --clay-deep: #f39a6b;
    --clay-tint: #e8743b0f;
    --clay-tint-2: #e8743b29;
    --clay-tint-3: #6b4430;
    --clay-tint-4: #6b4430;
    --clay-tint-hover: #e8743b29;
    --ok: #7bc47f;
    --ok-deep: #7bc47f;
    --ok-tint: #7bc47f29;
    --danger: #ef7d5e;
    --danger-tint: #ef7d5e29;
    --danger-solid: #ef7d5e;
    --danger-solid-hover: #f39a6b;
    --grey-tint: #262119;
    --toast-ok: #7bc47f;
    --toast-warn: #e8b04b;
    --toast-err: #dc8290;
    --knob: #faf9f5;
    --knob-on: #1c1b19;
    --mark-img-filter: none;
    --mark-img-blend: screen;
    --shadow-sm: rgba(0, 0, 0, 0.4);
    --shadow-md: rgba(0, 0, 0, 0.45);
    --shadow-lg: rgba(0, 0, 0, 0.6);
    --backdrop: rgba(0, 0, 0, 0.5);
    --overlay: rgba(0, 0, 0, 0.62);
    --chart-0: #e08968;
    --chart-1: #6fa859;
    --chart-2: #4d90e0;
    --chart-3: #dabe4a;
    --chart-4: #a98fd0;
    --chart-5: #5cc0b9;
    --chart-6: #6b6457;
    --sun-display: block;
    --moon-display: none;
    --tb-moon-o: 0;
    --tb-moon-t: rotate(90deg) scale(0.5);
    --tb-sun-o: 1;
    --tb-sun-t: none;
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --ink: #ece6dc;
  --ink-hover: #f5f0e8;
  --paper: #181512;
  --sidebar: #1d1915;
  --card: #201c18;
  --table-head: #262119;
  --border: #2f2923;
  --border-2: #2a251f;
  --border-3: #262119;
  --border-btn: #3a332b;
  --border-dashed: #3a332b;
  --track: #2a241e;
  --hover: #ffffff0f;
  --input-bg: #14110e;
  --text-2: #b8afa2;
  --text-3: #9a9185;
  --text-4: #7d7568;
  --muted: #9a9185;
  --deep: #201c18;
  --deep-line: #2f2923;
  --on-deep: #ece6dc;
  --on-dark: #ece6dc;
  --on-dark-muted: #9a9185;
  --on-dark-strong: #fff;
  --border-on-dark: #3a332b;
  --on-clay: #181512;
  --on-danger: #181512;
  --amber: #e8b04b;
  --link: #e8743b;
  --link-hover: #f39a6b;
  --clay: #e8743b;
  --clay-hover: #f39a6b;
  --clay-deep: #f39a6b;
  --clay-tint: #e8743b0f;
  --clay-tint-2: #e8743b29;
  --clay-tint-3: #6b4430;
  --clay-tint-4: #6b4430;
  --clay-tint-hover: #e8743b29;
  --ok: #7bc47f;
  --ok-deep: #7bc47f;
  --ok-tint: #7bc47f29;
  --danger: #ef7d5e;
  --danger-tint: #ef7d5e29;
  --danger-solid: #ef7d5e;
  --danger-solid-hover: #f39a6b;
  --grey-tint: #262119;
  --toast-ok: #7bc47f;
  --toast-warn: #e8b04b;
  --toast-err: #ef7d5e;
  --knob: #ece6dc;
  --knob-on: #181512;
  --mark-img-filter: none;
  --mark-img-blend: screen;
  --shadow-sm: rgba(0, 0, 0, 0.4);
  --shadow-md: rgba(0, 0, 0, 0.45);
  --shadow-lg: rgba(0, 0, 0, 0.6);
  --backdrop: rgba(0, 0, 0, 0.5);
  --overlay: rgba(0, 0, 0, 0.62);
  --chart-0: #e8743b;
  --chart-1: #7bc47f;
  --chart-2: #4d90e0;
  --chart-3: #e8b04b;
  --chart-4: #a98fd0;
  --chart-5: #5cc0b9;
  --chart-6: #6b6457;
  --sun-display: block;
  --moon-display: none;
  --tb-moon-o: 0;
  --tb-moon-t: rotate(90deg) scale(0.5);
  --tb-sun-o: 1;
  --tb-sun-t: none;
  color-scheme: dark;
}

* { box-sizing: border-box; }
/* One scrollbar for the whole console (ADR-0046): thin, themed, and only as visible as it needs to be. The track stays
   transparent so a bar reads as part of the surface it scrolls rather than a foreign strip, and the thumb is the
   border colour at rest and the text colour under the pointer. Firefox uses the two standard properties; WebKit and
   Chromium use the pseudo-elements, and `scrollbar-width` there would override them, so it is scoped away. */
@supports not selector(::-webkit-scrollbar) {
  * { scrollbar-color: var(--border-btn) transparent; scrollbar-width: thin; }
}
::-webkit-scrollbar { width: 8px; height: 8px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: var(--border-btn); border-radius: 999px; border: 2px solid transparent; background-clip: padding-box; }
::-webkit-scrollbar-thumb:hover { background: var(--text-3); background-clip: padding-box; }
::-webkit-scrollbar-corner { background: transparent; }
body { margin: 0; background: var(--paper); color: var(--ink); font-family: var(--sans); -webkit-font-smoothing: antialiased; }
a { color: var(--link); }
a:hover { color: var(--link-hover); }
input::placeholder { color: var(--muted); }
[hidden] { display: none !important; }

@keyframes cpIn { from { opacity: 0; transform: translateY(-6px); } to { opacity: 1; transform: none; } }
@keyframes cpToast { from { opacity: 0; transform: translateY(14px) scale(0.97); } to { opacity: 1; transform: none; } }
@keyframes cpFade { from { opacity: 0; } to { opacity: 1; } }
@keyframes cpPulse { 0%, 100% { opacity: 1; } 50% { opacity: 0.35; } }
@keyframes cpSpin { to { transform: rotate(360deg); } }
@keyframes cpBar { from { transform: scaleX(1); } to { transform: scaleX(0); } }

/* Shell */
.cp-shell { min-height: 100vh; display: flex; flex-wrap: wrap; align-items: stretch; }
.cp-sidebar { flex: 0 0 236px; position: sticky; top: 0; align-self: flex-start; height: 100vh; overflow-y: auto; padding: 22px 16px; border-right: 1px solid var(--border); display: flex; flex-direction: column; gap: 28px; background: var(--sidebar); }
.cp-brand { display: flex; align-items: center; gap: 11px; padding: 0 6px; color: inherit; text-decoration: none; }
.cp-brand:hover { color: inherit; }
.cp-logo { width: 32px; height: 32px; object-fit: contain; flex-shrink: 0; }
.cp-brand-text { display: flex; flex-direction: column; gap: 1px; }
.cp-wordmark { font-weight: 700; font-size: 16px; letter-spacing: -0.01em; }
.cp-brand-sub { font-size: 12px; color: var(--text-4); }
.cp-nav { display: flex; flex-direction: column; gap: 18px; }
.cp-nav-group { display: flex; flex-direction: column; gap: 2px; }
.cp-nav-heading { padding: 0 12px 4px; font-size: 11px; font-weight: 600; letter-spacing: 0.06em; text-transform: uppercase; color: var(--text-4); }
.cp-nav-item { font-size: 14px; font-weight: 500; display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 10px 12px; border-radius: 10px; color: var(--text-2); text-decoration: none; }
.cp-nav-item:hover { background: var(--hover); color: var(--text-2); }
.cp-nav-item.is-active { background: var(--card); color: var(--ink); font-weight: 600; }
.cp-nav-count { font-size: 12px; font-weight: 600; color: var(--text-4); font-variant-numeric: tabular-nums; }
.cp-pulse { width: 7px; height: 7px; border-radius: 50%; background: var(--ok); animation: cpPulse 2.4s ease-in-out infinite; flex-shrink: 0; }
.cp-col { flex: 1 1 560px; min-width: 0; display: flex; flex-direction: column; }
.cp-main { flex: 1 1 auto; min-width: 0; padding: 34px 36px 70px; display: flex; flex-direction: column; gap: 26px; }
.cp-banner-slot { display: contents; }
.cp-page { display: flex; flex-direction: column; gap: 28px; }

.cp-nav-toggle, .cp-nav-backdrop, .cp-nav-close { display: none; }
/* Top bar (#562): sticky at every width. The brand and the menu button only show on narrow screens. */
.cp-topbar { position: sticky; top: 0; z-index: 31; height: 56px; flex: none; display: flex; align-items: center; gap: 12px; padding: 0 36px; background: var(--sidebar); border-bottom: 1px solid var(--border); }
.cp-topbar > .cp-brand, .cp-menu-btn { display: none; }
.cp-topbar-search { flex: 1 1 auto; min-width: 0; }
.cp-topbar-end { display: flex; align-items: center; gap: 12px; margin-left: auto; }
.cp-topbar-bell:empty { display: none; }
/* The command palette's field in the navigation drawer (#627): shown on a phone only, where the top bar has no room for it. */
.cp-drawer-search { display: none; }
/* Language menu and theme button (#624): they sit left of the bell and share its 38px hit area. */
.cp-lang { position: relative; }
.cp-lang > summary { list-style: none; }
.cp-lang > summary::-webkit-details-marker { display: none; }
.cp-lang-btn, .cp-theme-btn { display: flex; align-items: center; justify-content: center; gap: 6px; height: 38px; border-radius: 12px; cursor: pointer; color: var(--ink); }
.cp-lang-btn { padding: 0 9px; }
.cp-lang-btn:hover, .cp-lang[open] > .cp-lang-btn, .cp-theme-btn:hover { background: var(--hover); }
.cp-lang-btn:focus-visible, .cp-theme-btn:focus-visible, .cp-lang-item:focus-visible { outline: 2px solid var(--link); outline-offset: 2px; }
.cp-lang-code { font-size: 12px; font-weight: 600; letter-spacing: 0.02em; }
.cp-flag { width: 20px; height: 14px; flex: none; border-radius: 3px; box-shadow: 0 0 0 1px var(--border); }
.cp-lang-panel { position: absolute; right: 0; top: calc(100% + 8px); z-index: 40; width: 180px; margin: 0; padding: 6px; display: flex; flex-direction: column; gap: 2px; background: var(--card); border: 1px solid var(--border); border-radius: 14px; box-shadow: 0 12px 32px var(--shadow-md); animation: cpIn 0.15s ease-out; font-size: 13px; color: var(--ink); }
.cp-lang-item { display: flex; align-items: center; gap: 10px; width: 100%; padding: 8px; border: 0; border-radius: 8px; background: transparent; font: inherit; font-weight: 500; color: var(--ink); text-align: left; cursor: pointer; }
.cp-lang-item:hover { background: var(--hover); }
.cp-lang-item[aria-current="true"] { font-weight: 600; cursor: default; }
.cp-lang-item > span { flex: 1 1 auto; }
.cp-lang-item .cp-icon { width: 16px; height: 16px; color: var(--link); }
.cp-theme-btn { position: relative; width: 38px; padding: 0; border: 0; background: transparent; }
.cp-theme-btn .cp-icon { position: absolute; width: 20px; height: 20px; transition: opacity 0.22s ease, transform 0.22s ease; }
.cp-theme-btn .cp-icon-moon { opacity: var(--tb-moon-o); transform: var(--tb-moon-t); }
.cp-theme-btn .cp-icon-sun { opacity: var(--tb-sun-o); transform: var(--tb-sun-t); }
@media (prefers-reduced-motion: reduce) { .cp-lang-panel { animation: none; } .cp-theme-btn .cp-icon { transition: none; } }
/* Command palette (#563): the top bar's field, and the modal palette (palette.js) on the shared overlay. */
.cp-palette-trigger { font: inherit; font-size: 13px; display: flex; align-items: center; gap: 10px; width: 100%; max-width: 440px; height: 36px; padding: 0 8px 0 12px; border: 1px solid var(--border); border-radius: 10px; background: var(--input-bg); color: var(--muted); cursor: pointer; text-align: left; }
.cp-palette-trigger:hover { border-color: var(--border-btn); }
.cp-palette-trigger:focus-visible, .cp-palette-input:focus-visible { outline: 2px solid var(--link); outline-offset: 2px; }
.cp-palette-trigger-text { flex: 1 1 auto; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cp-palette-kbd { font: inherit; font-size: 11px; line-height: 1; padding: 3px 6px; border: 1px solid var(--border); border-radius: 6px; background: var(--paper); color: var(--text-3); white-space: nowrap; }
.cp-palette-icon { width: 16px; height: 16px; flex: none; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.cp-palette-overlay { place-items: start center; padding-top: 12vh; }
.cp-palette-overlay[hidden] { display: none; }
.cp-palette { width: 100%; max-width: 600px; max-height: 70vh; display: flex; flex-direction: column; background: var(--card); border: 1px solid var(--border); border-radius: 16px; box-shadow: 0 30px 80px var(--shadow-lg); overflow: hidden; animation: cpIn 0.2s ease-out; }
.cp-palette-head { display: flex; align-items: center; gap: 10px; padding: 0 14px; height: 52px; flex: none; border-bottom: 1px solid var(--border-2); color: var(--muted); }
.cp-palette-input { font: inherit; font-size: 15px; flex: 1 1 auto; min-width: 0; height: 100%; border: 0; background: transparent; color: var(--ink); outline: none; }
.cp-palette-input:focus-visible { outline: none; }
.cp-palette-list { overflow-y: auto; padding: 6px; flex: 1 1 auto; }
.cp-palette-heading { font-size: 11px; font-weight: 600; letter-spacing: 0.06em; text-transform: uppercase; color: var(--muted); padding: 10px 10px 4px; }
.cp-palette-item { display: flex; align-items: center; gap: 12px; padding: 8px 10px; border-radius: 10px; cursor: pointer; color: var(--ink); }
.cp-palette-item .cp-palette-icon { color: var(--text-3); }
.cp-palette-item[aria-selected="true"] { background: var(--clay-tint-2); }
.cp-palette-item[aria-selected="true"] .cp-palette-icon { color: var(--clay-deep); }
.cp-palette-item-text { display: flex; flex-direction: column; min-width: 0; }
.cp-palette-item-title { font-size: 14px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cp-palette-item-hint { font-size: 12px; color: var(--text-3); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cp-palette-empty { padding: 28px 16px; text-align: center; font-size: 14px; color: var(--text-3); }
.cp-palette-foot { display: flex; gap: 16px; padding: 8px 14px; flex: none; border-top: 1px solid var(--border-2); font-size: 12px; color: var(--text-3); }
.cp-palette-hint { display: inline-flex; align-items: center; gap: 6px; }
.cp-palette-sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
@media (max-width: 640px) { .cp-palette-overlay { padding: 12px; padding-top: 8vh; } .cp-palette-foot { display: none; } .cp-palette-kbd { display: none; } }
@media (prefers-reduced-motion: reduce) { .cp-palette { animation: none; } }
.cp-usermenu { position: relative; }
.cp-usermenu > summary { list-style: none; }
.cp-usermenu > summary::-webkit-details-marker { display: none; }
.cp-usermenu-btn { display: flex; align-items: center; gap: 10px; padding: 4px 8px 4px 4px; border-radius: 12px; cursor: pointer; color: var(--ink); }
.cp-usermenu-btn:hover, .cp-usermenu[open] > .cp-usermenu-btn { background: var(--hover); }
.cp-usermenu-btn:focus-visible { outline: 2px solid var(--link); outline-offset: 2px; }
.cp-avatar { width: 32px; height: 32px; flex: none; display: grid; place-items: center; border-radius: 50%; background: var(--clay-tint-2); color: var(--clay-deep); font-size: 12px; font-weight: 700; letter-spacing: 0.02em; }
.cp-avatar-lg { width: 40px; height: 40px; font-size: 14px; }
.cp-usermenu-who { display: flex; flex-direction: column; min-width: 0; line-height: 1.25; text-align: left; }
.cp-usermenu-name { font-size: 13px; font-weight: 600; max-width: 160px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cp-usermenu-role { font-size: 11px; color: var(--text-4); }
.cp-usermenu-caret { width: 14px; height: 14px; flex: none; fill: none; stroke: var(--text-4); stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; transition: transform 0.2s; }
.cp-usermenu[open] .cp-usermenu-caret { transform: rotate(180deg); }
.cp-usermenu-panel { position: absolute; right: 0; top: calc(100% + 8px); z-index: 40; width: 280px; padding: 8px; display: flex; flex-direction: column; gap: 4px; background: var(--card); border: 1px solid var(--border); border-radius: 14px; box-shadow: 0 12px 32px var(--shadow-md); animation: cpIn 0.15s ease-out; font-size: 13px; color: var(--ink); }
.cp-usermenu-head { display: flex; align-items: center; gap: 12px; padding: 8px 8px 12px; border-bottom: 1px solid var(--border-2); margin-bottom: 4px; }
.cp-usermenu-head .cp-usermenu-name { max-width: 190px; font-size: 14px; }
.cp-usermenu-badge { align-self: flex-start; margin-top: 3px; padding: 1px 8px; border-radius: 999px; background: var(--track); color: var(--text-2); font-size: 11px; font-weight: 600; }
.cp-usermenu-link { display: block; width: 100%; box-sizing: border-box; padding: 8px; border: 0; border-radius: 8px; background: transparent; font: inherit; font-weight: 500; color: var(--ink); text-align: left; text-decoration: none; cursor: pointer; }
.cp-usermenu-link:hover { background: var(--hover); color: var(--ink); }
.cp-usermenu-link:focus-visible { outline: 2px solid var(--link); outline-offset: -2px; }
.cp-usermenu-form { margin: 0; }
/* Alerts bell (#565): a top bar popover next to the user menu, same panel look */
.cp-bell { position: relative; }
.cp-bell > summary { list-style: none; }
.cp-bell > summary::-webkit-details-marker { display: none; }
.cp-bell-btn { position: relative; display: grid; place-items: center; width: 38px; height: 38px; border-radius: 12px; cursor: pointer; color: var(--ink); }
.cp-bell-btn:hover, .cp-bell[open] > .cp-bell-btn { background: var(--hover); }
.cp-bell-btn:focus-visible { outline: 2px solid var(--link); outline-offset: 2px; }
.cp-bell-icon { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.cp-bell-badge { position: absolute; top: 2px; right: 1px; min-width: 17px; height: 17px; padding: 0 4px; box-sizing: border-box; border-radius: 999px; background: var(--danger-solid); color: var(--on-danger); font-size: 10px; font-weight: 700; line-height: 17px; text-align: center; font-variant-numeric: tabular-nums; }
.cp-bell-badge[hidden] { display: none; }
.cp-bell-panel { position: absolute; right: 0; top: calc(100% + 8px); z-index: 40; width: 380px; max-width: calc(100vw - 24px); display: flex; flex-direction: column; background: var(--card); border: 1px solid var(--border); border-radius: 14px; box-shadow: 0 12px 32px var(--shadow-md); animation: cpIn 0.15s ease-out; font-size: 13px; color: var(--ink); overflow: hidden; }
.cp-bell-head { display: flex; align-items: center; gap: 8px; padding: 12px 14px; border-bottom: 1px solid var(--border-2); }
.cp-bell-title { font-size: 14px; font-weight: 600; }
.cp-bell-count { color: var(--text-2); font-size: 12px; }
.cp-bell-readall { margin-left: auto; padding: 4px 8px; border: 0; border-radius: 8px; background: transparent; font: inherit; font-size: 12px; font-weight: 600; color: var(--link); cursor: pointer; }
.cp-bell-readall:hover { background: var(--hover); color: var(--link-hover); }
.cp-bell-readall:focus-visible { outline: 2px solid var(--link); outline-offset: 1px; }
.cp-bell-readall[hidden], .cp-bell-list[hidden], .cp-bell-empty[hidden] { display: none; }
.cp-bell-list { list-style: none; margin: 0; padding: 4px; max-height: min(420px, 60vh); overflow-y: auto; }
.cp-bell-item > a { display: flex; align-items: flex-start; gap: 10px; padding: 10px; border-radius: 10px; color: inherit; text-decoration: none; }
.cp-bell-item > a:hover { background: var(--hover); }
.cp-bell-item > a:focus-visible { outline: 2px solid var(--link); outline-offset: -2px; }
.cp-bell-sev { display: grid; place-items: center; flex: none; width: 28px; height: 28px; border-radius: 8px; }
.cp-bell-sev svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.cp-bell-item[data-severity="error"] .cp-bell-sev { color: var(--danger); background: var(--danger-tint); }
.cp-bell-item[data-severity="warning"] .cp-bell-sev { color: var(--clay-deep); background: var(--clay-tint-2); }
.cp-bell-item[data-severity="info"] .cp-bell-sev { color: var(--chart-2); background: var(--grey-tint); }
.cp-bell-text { display: flex; flex-direction: column; gap: 2px; min-width: 0; flex: 1 1 auto; }
.cp-bell-item-title { font-weight: 500; overflow-wrap: anywhere; }
.cp-bell-item.is-unread .cp-bell-item-title { font-weight: 700; }
.cp-bell-body { color: var(--text-2); font-size: 12px; overflow-wrap: anywhere; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; white-space: pre-line; }
/* An alert's subjects (actor, account, member, amount, #700) stand out of the muted sentence in the bell, the log and the grid. */
.cp-bell-body strong, .al-event-hint strong, .cp-ra-alert .cp-req-secondary strong { font-weight: 600; color: var(--ink); }
.cp-bell-text time { color: var(--text-4); font-size: 11px; }
.cp-bell-dot { flex: none; align-self: center; width: 8px; height: 8px; border-radius: 50%; background: var(--clay); }
.cp-bell-empty { margin: 0; padding: 28px 14px; text-align: center; color: var(--text-2); }
.cp-bell-all { display: block; padding: 11px 14px; border-top: 1px solid var(--border-2); text-align: center; font-weight: 600; color: var(--link); text-decoration: none; }
.cp-bell-all:hover { background: var(--hover); color: var(--link-hover); }
.cp-bell-all:focus-visible { outline: 2px solid var(--link); outline-offset: -2px; }
/* Online admins (#827): a green dot and "N online" in the top bar, a popover of names, in the lang menu's panel surface */
.cp-online { position: relative; }
.cp-online > summary { list-style: none; }
.cp-online > summary::-webkit-details-marker { display: none; }
.cp-online-btn { display: flex; align-items: center; gap: 6px; height: 38px; padding: 0 10px; border-radius: 12px; cursor: pointer; color: var(--ink); font-size: 12px; font-weight: 600; white-space: nowrap; font-variant-numeric: tabular-nums; }
.cp-online-btn:hover, .cp-online[open] > .cp-online-btn { background: var(--hover); }
.cp-online-btn:focus-visible { outline: 2px solid var(--link); outline-offset: 2px; }
.cp-online-dot { flex: none; width: 8px; height: 8px; border-radius: 50%; background: var(--ok); box-shadow: 0 0 0 3px var(--ok-tint); }
.cp-online-word { font-weight: 500; color: var(--text-2); }
.cp-online-panel { position: absolute; right: 0; top: calc(100% + 8px); z-index: 40; width: 240px; max-width: calc(100vw - 24px); background: var(--card); border: 1px solid var(--border); border-radius: 14px; box-shadow: 0 12px 32px var(--shadow-md); animation: cpIn 0.15s ease-out; font-size: 13px; color: var(--ink); overflow: hidden; }
.cp-online-head { padding: 12px 14px; border-bottom: 1px solid var(--border-2); font-size: 14px; font-weight: 600; }
.cp-online-list { list-style: none; margin: 0; padding: 6px; max-height: min(320px, 60vh); overflow-y: auto; }
.cp-online-item { padding: 8px; border-radius: 8px; overflow-wrap: anywhere; }
.cp-online-item[data-you="true"] { font-weight: 600; }
.cp-online-you { color: var(--text-2); font-weight: 500; }
@media (prefers-reduced-motion: reduce) { .cp-online-panel { animation: none; } }

/* Narrow screens: a sticky top bar, and the sidebar becomes a drawer toggled by the #cp-nav-toggle checkbox */
@media (max-width: 1024px) {
  .cp-shell { display: block; }
  html:has(.cp-nav-toggle:checked) { overflow: hidden; }
  .cp-nav-toggle { display: block; position: fixed; top: 0; right: 0; width: 1px; height: 1px; margin: 0; opacity: 0; pointer-events: none; }
  .cp-topbar { padding: 0 12px 0 clamp(16px, 4vw, 48px); }
  .cp-topbar > .cp-brand { display: flex; padding: 0; gap: 9px; }
  .cp-topbar-end { gap: 6px; }
  .cp-usermenu-panel { width: min(280px, calc(100vw - 24px)); }
  .cp-topbar .cp-logo { width: 28px; height: 28px; border-radius: 8px; }
  .cp-menu-btn { width: 40px; height: 40px; border-radius: 10px; display: grid; place-items: center; cursor: pointer; flex-shrink: 0; }
  .cp-menu-btn:hover { background: var(--hover); }
  .cp-nav-toggle:focus-visible ~ .cp-col .cp-menu-btn { outline: 2px solid var(--link); outline-offset: 2px; }
  .cp-menu-icon, .cp-menu-icon::before, .cp-menu-icon::after { width: 18px; height: 2px; border-radius: 2px; background: var(--ink); transition: transform 0.2s, background 0.2s; }
  .cp-menu-icon { position: relative; }
  .cp-menu-icon::before, .cp-menu-icon::after { content: ""; position: absolute; left: 0; }
  .cp-menu-icon::before { top: -6px; }
  .cp-menu-icon::after { top: 6px; }
  .cp-nav-toggle:checked ~ .cp-col .cp-menu-icon { background: transparent; }
  .cp-nav-toggle:checked ~ .cp-col .cp-menu-icon::before { transform: translateY(6px) rotate(45deg); }
  .cp-nav-toggle:checked ~ .cp-col .cp-menu-icon::after { transform: translateY(-6px) rotate(-45deg); }
  .cp-sidebar { display: flex; position: fixed; top: 0; right: 0; bottom: 0; align-self: stretch; z-index: 32; width: min(86vw, 320px); height: auto; overflow-y: auto; gap: 18px; border-right: 0; border-left: 1px solid var(--border); box-shadow: -14px 0 40px var(--shadow-md); transform: translateX(100%); visibility: hidden; transition: transform 0.25s ease, visibility 0s linear 0.25s; }
  .cp-sidebar > .cp-brand { padding-right: 48px; }
  .cp-nav-close { position: absolute; top: 12px; right: 12px; width: 40px; height: 40px; border-radius: 10px; display: grid; place-items: center; cursor: pointer; }
  .cp-nav-close:hover { background: var(--hover); }
  .cp-nav-close .cp-menu-icon { background: transparent; }
  .cp-nav-close .cp-menu-icon::before { transform: translateY(6px) rotate(45deg); }
  .cp-nav-close .cp-menu-icon::after { transform: translateY(-6px) rotate(-45deg); }
  .cp-nav-toggle:checked ~ .cp-sidebar { transform: none; visibility: visible; transition: transform 0.25s ease; }
  .cp-nav-backdrop { display: block; position: fixed; inset: 0; z-index: 31; background: var(--backdrop); opacity: 0; visibility: hidden; transition: opacity 0.25s ease, visibility 0s linear 0.25s; }
  .cp-nav-toggle:checked ~ .cp-nav-backdrop { opacity: 1; visibility: visible; transition: opacity 0.25s ease; }
  .cp-main { padding-top: 28px; }
  .cp-overlay { place-items: start center; overflow-y: auto; }
  .cp-dialog { margin: auto 0; }
}

/* Phones: the user button is the avatar alone (the panel names the admin) */
@media (max-width: 640px) {
  .cp-usermenu-btn > .cp-usermenu-who, .cp-usermenu-caret { display: none; }
  .cp-usermenu-btn { padding: 4px; }
  .cp-bell, .cp-online { position: static; }
  .cp-online-btn { padding: 0 6px; }
  .cp-online-word { display: none; }
  .cp-online-panel { position: fixed; top: 60px; left: 12px; right: 12px; width: auto; max-width: none; }
  .cp-lang-btn { padding: 0 6px; }
  .cp-lang-code { display: none; }
  .cp-topbar-search { display: none; }
  .cp-drawer-search:not(:empty) { display: block; }
  .cp-drawer-search .cp-palette-trigger { max-width: none; height: 40px; }
  .cp-bell-panel { position: fixed; top: 60px; left: 12px; right: 12px; width: auto; max-width: none; }
}
/* Page header */
.cp-page-header { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 20px; }
.cp-page-heading { display: flex; flex-direction: column; gap: 8px; min-width: 0; }
.cp-h1 { margin: 0; font-family: var(--serif); font-weight: 400; font-size: 56px; line-height: 1; letter-spacing: -0.01em; }
.cp-subtitle { margin: 0; color: var(--text-3); font-size: 15px; text-wrap: pretty; }

/* Text helpers */
.cp-label { font-size: 12px; font-weight: 600; color: var(--text-4); text-transform: uppercase; letter-spacing: 0.06em; }
.cp-label-sm { font-size: 11px; font-weight: 600; color: var(--text-4); text-transform: uppercase; letter-spacing: 0.06em; }
.cp-hint { font-size: 12px; color: var(--text-4); }
.cp-strong { font-weight: 600; }
.cp-tabular, .cp-num { font-variant-numeric: tabular-nums; }
.cp-num { text-align: right; }
.cp-mono { font-family: var(--mono); }
.cp-text-12 { font-size: 12px; }
.cp-text-danger { color: var(--danger); }
.cp-muted-text { color: var(--text-4); }
.cp-empty { margin: 0; color: var(--text-4); font-size: 14px; }
.cp-row-8 { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.cp-gap-12 { gap: 12px !important; }
.cp-gap-16 { gap: 16px !important; }
.cp-end { align-self: flex-end; }
.cp-between { justify-content: space-between !important; align-items: center; }

/* Stats */
.cp-stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 10px; }
.cp-stat { padding: 14px 16px; background: var(--card); border: 1px solid var(--border); border-radius: 14px; display: flex; flex-direction: column; gap: 4px; min-width: 0; transition: transform 240ms cubic-bezier(.34,1.5,.5,1), border-color 200ms ease, box-shadow 240ms ease; }
/* A stat tile lifts a little on hover, the way the provider cards do: the page is a dashboard, and a tile that
   responds says "this is a thing you can look at" rather than "this is a number painted on the wall". */
.cp-stat:hover { transform: translateY(-2px); border-color: var(--border-2); box-shadow: 0 8px 20px var(--shadow-sm); }
.cp-stat-value { font-size: 26px; font-weight: 600; letter-spacing: -0.02em; font-variant-numeric: tabular-nums; }
/* The sparkline sits at the tile's foot, so every tile's bars line up along one baseline whatever its label wraps to. */
.cp-spark { display: flex; align-items: flex-end; gap: 3px; height: 26px; margin-top: 8px; }
.cp-spark i { flex: 1 1 0; min-width: 2px; border-radius: 2px; background: var(--track); }
.cp-spark .cp-spark-now { background: var(--clay); }
@media (prefers-reduced-motion: reduce) { .cp-stat { transition: none; } .cp-stat:hover { transform: none; } }

/* Cards and tables */
.cp-card { background: var(--card); border: 1px solid var(--border); border-radius: 16px; overflow: hidden; }
.cp-card-pad { padding: 18px 20px; }
.cp-table-scroll { overflow-x: auto; }
.cp-tr { display: grid; gap: 10px; align-items: center; padding: 12px 18px; font-size: 13px; font-variant-numeric: tabular-nums; border-top: 1px solid var(--border-3); }
.cp-th { padding: 11px 18px; font-size: 11px; font-weight: 600; color: var(--muted); text-transform: uppercase; letter-spacing: 0.06em; background: var(--table-head); border-top: 0; border-bottom: 1px solid var(--border-2); }
.cp-th + .cp-tr { border-top: 0; }
/* The account table's left edge (#468): a row grows an accent bar on hover, scaling up from its own middle so it
   reads as the row waking up rather than as a border appearing. It is drawn on the row's `::before`, which sits in
   the row's own box and takes no part in the grid, so the columns do not shift by a pixel. */
.cp-table-accounts .cp-tr[data-account-row] { position: relative; }
.cp-table-accounts .cp-tr[data-account-row]::before { content: ""; position: absolute; left: 0; top: 6px; bottom: 6px; width: 3px; border-radius: 0 3px 3px 0; background: var(--clay); transform: scaleY(0); transform-origin: center; transition: transform 220ms cubic-bezier(.34,1.5,.5,1); }
.cp-table-accounts .cp-tr[data-account-row]:hover::before { transform: scaleY(1); }
.cp-table-accounts .cp-tr[data-account-row]:hover { background: var(--hover); }
/* A disabled account is drawn at half strength: it is still listed and still reorderable, but it is not serving, and
   the row should not read as loudly as one that is. */
.cp-table-accounts .cp-tr[data-status="disabled"] { opacity: 0.5; }
.cp-table-accounts .cp-tr[data-status="disabled"]:hover { opacity: 0.75; }
@media (prefers-reduced-motion: reduce) { .cp-table-accounts .cp-tr[data-account-row]::before { transition: none; } }
/* The account column stays put when the table scrolls sideways (#468), so a row keeps its name while the numbers
   beside it slide. It needs an opaque background of its own — the row's is transparent, and a sticky cell without one
   lets the columns it passes over show through it. The header cell gets the same treatment so the two stay aligned. */
/* The first column stays put while the rest scrolls sideways (#468). It has to paint its own background or the cells
   sliding underneath would show through, so it also has to repaint on hover — otherwise the row highlights everywhere
   except its first cell, and the highlight reads as a block floating over the name rather than as the row waking up. */
.cp-table-accounts .cp-tr > :first-child { position: sticky; left: 0; z-index: 1; background: var(--card); }
/* `--hover` is a translucent wash, so it is layered over the card rather than replacing it: the same composite the
   browser does for the rest of the row, which keeps the first cell the same colour as its neighbours. */
.cp-table-accounts .cp-tr[data-account-row]:hover > :first-child { background-image: linear-gradient(var(--hover), var(--hover)); }

.cp-table-accounts .cp-th > :first-child { z-index: 2; background: var(--table-head); }
/* The row's own background is what a sticky cell would otherwise cover, so the hover tint moves onto the sticky cell
   and the rest of the row keeps a transparent background to let the bar's `::before` show. */

/* Pills, chips */
.cp-pill { display: inline-block; font-size: 12px; font-weight: 600; padding: 2px 8px; border-radius: 999px; white-space: nowrap; }
.cp-pill-ok { color: var(--ok-deep); background: var(--ok-tint); }
.cp-pill-warn { color: var(--clay-deep); background: var(--clay-tint); }
.cp-pill-danger { color: var(--danger); background: var(--danger-tint); }
.cp-pill-muted { color: var(--text-3); background: var(--grey-tint); }
.cp-pill-neutral { color: var(--text-2); background: var(--border-2); }
.cp-chip { font-size: 11px; font-weight: 600; color: var(--text-2); background: var(--border-2); padding: 1px 6px; border-radius: 5px; }

/* Buttons */
.cp-btn { font: inherit; font-size: 14px; font-weight: 600; padding: 11px 18px; border-radius: 10px; border: 0; cursor: pointer; text-decoration: none; display: inline-flex; align-items: center; justify-content: center; white-space: nowrap; }
.cp-btn:disabled { opacity: 0.6; cursor: progress; }
.cp-btn[aria-disabled="true"] { cursor: not-allowed; }
.cp-btn[aria-busy]::before { content: ""; width: 11px; height: 11px; margin-right: 7px; border-radius: 50%; border: 2px solid currentColor; border-right-color: transparent; animation: cpSpin 0.8s linear infinite; }
.cp-btn-primary { background: var(--ink); color: var(--paper); }
.cp-btn-primary:hover { background: var(--ink-hover); color: var(--paper); }
.cp-btn-primary-lg { background: var(--ink); color: var(--paper); padding: 12px 18px; }
.cp-btn-primary-lg:hover { background: var(--ink-hover); }
.cp-btn-outline { font-size: 13px; font-weight: 500; padding: 7px 12px; border-radius: 8px; border: 1px solid var(--border-btn); background: var(--card); color: var(--ink); }
.cp-btn-outline:hover { background: var(--border-3); }
.cp-btn-outline-lg { font-weight: 500; padding: 11px 16px; border: 1px solid var(--border-btn); background: var(--card); color: var(--ink); }
.cp-btn-outline-lg:hover { background: var(--border-3); }
.cp-btn-danger { font-size: 13px; font-weight: 500; padding: 7px 12px; border-radius: 8px; border: 1px solid transparent; background: transparent; color: var(--danger); }
.cp-btn-danger:hover { background: var(--danger-tint); }
.cp-btn-danger-solid { background: var(--danger-solid); color: var(--on-danger); }
.cp-btn-danger-solid:hover { background: var(--danger-solid-hover); }
.cp-btn-clay { background: var(--clay); color: var(--on-clay); }
.cp-btn-clay:hover { background: var(--clay-hover); color: var(--on-clay); }
.cp-btn-clay-outline { font-size: 13px; font-weight: 600; padding: 6px 11px; border-radius: 8px; border: 1px solid var(--clay); background: var(--clay-tint); color: var(--clay-deep); }
.cp-btn-clay-outline:hover { background: var(--clay-tint-hover); }
.cp-btn-ghost { font-size: 13px; font-weight: 500; padding: 8px 4px; background: transparent; color: var(--text-4); }
.cp-btn-dark-outline { font-weight: 500; padding: 11px 16px; border: 1px solid var(--border-on-dark); background: transparent; color: var(--on-dark); }
.cp-btn-dark-outline:hover { color: var(--on-dark-strong); }
.cp-btn-sm { font-size: 12px; padding: 5px 10px; border-radius: 7px; }
.cp-link-btn { font: inherit; font-size: 13px; padding: 8px 4px; border: 0; background: transparent; color: var(--text-4); cursor: pointer; }
.cp-link-btn:hover { color: var(--ink); }
.cp-inline-form { display: inline-flex; margin: 0; }

/* Theme toggle: the icon shows the mode it switches to, driven by --sun-display / --moon-display */
.theme-icon { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.theme-icon-sun { display: var(--sun-display); }
.theme-icon-moon { display: var(--moon-display); }
.cp-theme-toggle { width: 34px; height: 34px; flex-shrink: 0; display: grid; place-items: center; padding: 0; border: 1px solid var(--border-btn); border-radius: 9px; background: transparent; color: var(--text-2); cursor: pointer; }
.cp-theme-toggle:hover { background: var(--hover); color: var(--ink); }
.cp-lang-toggle { font: inherit; font-size: 12px; font-weight: 600; letter-spacing: 0.02em; }
.cp-theme-toggle:focus-visible { outline: 2px solid var(--link); outline-offset: 2px; }
.cp-actions { display: flex; gap: 6px; flex-wrap: wrap; }

/* Segmented control */
.cp-seg { display: flex; gap: 2px; padding: 3px; background: var(--track); border-radius: 10px; }
.cp-seg-btn { font: inherit; font-size: 13px; font-weight: 600; padding: 7px 14px; border: 0; border-radius: 8px; background: transparent; color: var(--text-3); cursor: pointer; text-decoration: none; }
.cp-seg-btn:hover { color: var(--ink); }
.cp-seg-btn[aria-current="true"], .cp-seg-btn[aria-pressed="true"] { background: var(--card); color: var(--ink); box-shadow: 0 1px 2px var(--shadow-sm); }

/* Meters */
.cp-meter { height: 8px; border-radius: 999px; background: var(--border-2); overflow: hidden; }
.cp-meter-fill { height: 100%; border-radius: 999px; }
.cp-fill-ok { background: var(--ok); }
.cp-fill-warn { background: var(--clay); }
.cp-fill-danger { background: var(--danger); }
.cp-fill-neutral, .cp-fill-muted { background: var(--ink); }

/* Forms */
.cp-input { font: inherit; font-size: 15px; padding: 12px 14px; border: 1px solid var(--border-btn); border-radius: 10px; background: var(--input-bg); color: var(--ink); outline: none; width: 100%; }
.cp-input.cp-mono { font-family: var(--mono); font-size: 13px; }
.cp-input:focus { border-color: var(--clay); }
.cp-input.is-invalid { border-color: var(--danger); }
.cp-field-error { font-size: 12px; color: var(--danger); min-height: 16px; }
.cp-add-form { display: flex; gap: 8px; padding: 6px; border: 1px dashed var(--border-dashed); border-radius: 14px; max-width: 560px; }
.cp-add-input { flex: 1; min-width: 0; font: inherit; font-size: 14px; padding: 10px 12px; border: 0; background: transparent; color: var(--ink); outline: none; }
.cp-add-form .cp-btn { padding: 9px 16px; border-radius: 9px; }

/* Alerts and the new key banner */
.cp-alert { padding: 14px 18px; border-radius: 14px; background: var(--danger-tint); color: var(--danger); font-size: 14px; font-weight: 500; animation: cpIn 0.35s ease-out; }
.cp-key-banner { animation: cpIn 0.35s ease-out; background: var(--deep); color: var(--on-deep); border-radius: 18px; padding: 20px 22px; display: flex; flex-wrap: wrap; align-items: center; gap: 18px; justify-content: space-between; }
.cp-key-banner-text { display: flex; flex-direction: column; gap: 10px; min-width: 0; flex: 1 1 380px; }
.cp-key-banner-note { display: flex; align-items: center; gap: 10px; font-size: 14px; color: var(--on-dark); }
.cp-key-banner-note strong { color: var(--on-dark-strong); }
.cp-dot-clay { width: 8px; height: 8px; border-radius: 50%; background: var(--clay); flex-shrink: 0; }
.cp-key-banner-key { font-family: var(--mono); font-size: clamp(13px, 1.5vw, 17px); color: var(--on-dark-strong); word-break: break-all; }
.cp-key-banner-actions { display: flex; gap: 8px; }

/* Accounts */
.cp-account-head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 14px; padding: 18px 20px; border-bottom: 1px solid var(--border-2); }
.cp-mini-stats { display: grid; grid-template-columns: 1fr 1fr; gap: 14px 12px; }
.cp-mini-stat { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.cp-mini-value { font-size: 20px; font-weight: 600; letter-spacing: -0.01em; font-variant-numeric: tabular-nums; }
.cp-icon { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
/* A vendor mark is filled artwork carrying its own colour (ADR-0046), so it is never stroked; a custom provider's is
   our own glyph, which is. */
.cp-mark { width: 14px; height: 14px; flex: none; vertical-align: -2px; fill: currentColor; stroke: none; }
.cp-mark-custom { fill: none; stroke: currentColor; stroke-width: 2.2; stroke-linecap: round; stroke-linejoin: round; color: var(--text-3); }
/* A custom account's mark names no vendor, so it takes the colour of the text beside it. */
.cp-mark-anthropic, .cp-mark-deepseek, .cp-mark-codex { color: inherit; }
/* The Codex mark is an image on an opaque black square; this takes the square out in either theme (#583). The topology
   island's node draws the same image as `img.cp-topo-mark`. */
img.cp-mark-codex, img.cp-topo-mark { filter: var(--mark-img-filter); mix-blend-mode: var(--mark-img-blend); }
.cp-btn-icon { width: 40px; height: 40px; padding: 0; border-radius: 10px; border: 1px solid var(--border-btn); background: var(--card); color: var(--ink); }
.cp-btn-icon:hover { background: var(--border-3); }
.cp-btn-icon.cp-btn-primary { border-color: var(--ink); background: var(--ink); color: var(--paper); }
.cp-btn-icon.cp-btn-primary:hover { background: var(--ink-hover); }
.cp-btn-icon[aria-busy]::before { content: none; }
.cp-btn-icon[aria-busy] .cp-icon-refresh { animation: cpSpin 0.8s linear infinite; }
.cp-btn-icon.cp-icon-danger { color: var(--danger); }
.cp-btn-icon.cp-icon-danger:hover { background: var(--danger-tint); border-color: transparent; }
.cp-warmup { display: flex; flex-direction: column; }
.cp-warmup-head { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 16px 20px; border-bottom: 1px solid var(--border-2); }
.cp-warmup-title { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.cp-warmup .cp-warmup-switch { width: auto; padding: 4px; }
.cp-warmup-body { display: flex; flex-direction: column; gap: 10px; padding: 16px 20px; }
.cp-warmup-times { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.cp-warmup-time { font: inherit; display: inline-flex; align-items: center; gap: 6px; font-family: var(--mono); font-size: 13px; font-weight: 600; padding: 6px 8px 6px 12px; border-radius: 999px; border: 1px solid var(--border-btn); background: var(--table-head); color: var(--ink); cursor: pointer; }
.cp-warmup-time > span { width: 18px; height: 18px; border-radius: 50%; display: grid; place-items: center; font-family: var(--sans); font-size: 14px; color: var(--text-4); }
.cp-warmup-time:hover > span { background: var(--danger-tint); color: var(--danger); }
.cp-warmup-add { display: inline-flex; align-items: center; gap: 6px; margin: 0; padding-left: 8px; border-left: 1px solid var(--border-2); }
.cp-warmup-input { font: inherit; font-family: var(--mono); font-size: 12px; padding: 5px 8px; border: 1px solid var(--border-btn); border-radius: 8px; background: var(--input-bg); color: var(--ink); outline: none; }
.cp-warmup-input:focus { border-color: var(--clay); }
/* Dropdown (admin.js): the trigger keeps the select's own class, so `cp-input`, `cp-add-input` and `cp-warmup-input`
   hold each context's size and only the layout and the menu itself are styled here. The menu is fixed and placed by
   the script, above the dialog it opens from (z-index 40) and below the toasts (60). */
.cp-sel-trigger { display: flex; align-items: center; gap: 8px; text-align: left; cursor: pointer; }
.cp-sel-label { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-weight: 400; }
.cp-sel-chevron { display: grid; place-items: center; flex-shrink: 0; color: var(--text-4); transition: transform 0.2s; }
.cp-sel-chevron svg { width: 16px; height: 16px; }
.cp-sel-trigger.cp-sel-open .cp-sel-chevron { transform: rotate(180deg); }
.cp-sel-menu { position: fixed; z-index: 50; display: flex; flex-direction: column; overflow-y: auto; padding: 5px; background: var(--card); border: 1px solid var(--border); border-radius: 12px; box-shadow: 0 12px 32px var(--shadow-md); animation: cpIn 0.15s ease-out; }
.cp-sel-group { padding: 8px 10px 4px; font-size: 11px; font-weight: 600; color: var(--muted); text-transform: uppercase; letter-spacing: 0.06em; }
.cp-sel-group:first-child { padding-top: 4px; }
.cp-sel-opt { font: inherit; font-size: 13px; display: flex; align-items: center; gap: 8px; width: 100%; padding: 8px 10px; border: 0; border-radius: 8px; background: transparent; color: var(--ink); text-align: left; cursor: pointer; }
.cp-sel-opt.cp-hi { background: var(--border-3); }
.cp-sel-opt[aria-selected="true"] { color: var(--clay); font-weight: 600; }
.cp-sel-text { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cp-sel-check { display: grid; place-items: center; flex-shrink: 0; width: 16px; color: var(--clay); }
.cp-sel-check svg { width: 16px; height: 16px; }
.cp-sel-multi { min-height: 44px; padding-top: 6px; padding-bottom: 6px; }
.cp-sel-chips { flex: 1; min-width: 0; display: flex; flex-wrap: wrap; gap: 4px; }
.cp-sel-chip { font-size: 12px; font-weight: 600; padding: 3px 9px; border-radius: 999px; background: var(--clay-tint-2); color: var(--clay-deep); }
.cp-sel-placeholder { font-size: 14px; color: var(--text-4); }
.cp-sel-box { display: grid; place-items: center; flex-shrink: 0; width: 16px; height: 16px; border: 1.5px solid var(--border-btn); border-radius: 4px; color: var(--clay); }
.cp-sel-opt[aria-selected="true"] .cp-sel-box { border-color: var(--clay); }
.cp-sel-box svg { width: 12px; height: 12px; }
/* Model combobox (#665, model-combo.js): a text field with a button that opens the dropdown's menu plus a search box. Only
   tokens are used, so both themes follow with no twin rules. The button shows once script runs (without it the field is plain). */
.cp-combo { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.cp-combo-box { position: relative; display: flex; min-width: 0; }
.cp-combo-in { width: 100%; min-width: 0; }
.js .cp-combo-in { padding-right: 38px; }
.cp-combo-btn { display: none; position: absolute; right: 5px; top: 50%; width: 28px; height: 28px; margin-top: -14px; place-items: center; padding: 0; border: 0; border-radius: 8px; background: transparent; color: var(--text-4); cursor: pointer; }
.js .cp-combo-btn { display: grid; }
.cp-combo-btn:hover { color: var(--ink); background: var(--border-3); }
.cp-combo-btn svg { width: 16px; height: 16px; transition: transform 0.2s; }
.cp-combo-open .cp-combo-btn svg { transform: rotate(180deg); }
.cp-combo-warn { margin: 0; font-size: 12.5px; line-height: 1.4; color: color-mix(in srgb, var(--amber) 65%, var(--ink)); }
.cp-combo-warn[hidden] { display: none; }
.cp-combo-menu { overflow: hidden; padding: 0; }
.cp-combo-search { font: inherit; font-size: 13px; width: 100%; padding: 10px 12px; border: 0; border-bottom: 1px solid var(--border-2); background: transparent; color: var(--ink); outline: 0; }
.cp-combo-search::placeholder { color: var(--text-4); }
.cp-combo-list { display: flex; flex-direction: column; min-height: 0; overflow-y: auto; padding: 5px; }
.cp-combo-opt { gap: 10px; }
.cp-combo-opt .cp-sel-text { flex: 0 1 auto; }
.cp-combo-id { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font: 12px ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; color: var(--text-4); text-align: right; }
.cp-combo-opt .cp-sel-check { margin-left: auto; }
.cp-combo-mark { display: inline-flex; flex: none; }
.cp-combo-mark .cp-pv { width: 22px; height: 22px; border-radius: 7px; }
.cp-combo-mark .cp-pv .cp-mark { width: 14px; height: 14px; }
.cp-combo-empty { padding: 10px; font-size: 13px; color: var(--text-4); }
.cp-warmup-foot { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 12px 20px; border-top: 1px solid var(--border-2); background: var(--table-head); }
.cp-stagger-close { display: grid; place-items: center; text-decoration: none; }
.cp-stagger-fields { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 150px), 1fr)); gap: 12px; }
.cp-stagger-field { display: flex; flex-direction: column; gap: 6px; margin: 0; font-size: 13px; font-weight: 600; }
.cp-stagger-field .cp-warmup-input { font-size: 14px; padding: 8px 10px; }
.cp-stagger-list { display: flex; flex-direction: column; border: 1px solid var(--border-2); border-radius: 12px; background: var(--table-head); }
.cp-stagger-list[aria-busy] { opacity: 0.6; }
.cp-stagger-row { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 6px 12px; padding: 10px 14px; border-top: 1px solid var(--border-2); }
.cp-stagger-row:first-child { border-top: 0; }
.cp-stagger-label { font-size: 14px; font-weight: 600; min-width: 0; overflow-wrap: anywhere; }
.cp-stagger-times { display: flex; flex-wrap: wrap; gap: 6px; }
.cp-stagger-time.is-next { border-color: var(--clay); color: var(--clay-deep, var(--clay)); }
.cp-stagger-time sup { margin-left: 2px; font-size: 9px; color: var(--text-4); }
.cp-stagger-time { font-family: var(--mono); font-size: 12px; font-weight: 600; padding: 3px 9px; border-radius: 999px; border: 1px solid var(--border-btn); background: var(--card); }
.cp-stagger-replace { font-size: 13px; color: var(--clay-deep); }
/* Switch (Members self-serve keys, Accounts auto warm-up) */
.mb-switch-row { font: inherit; display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 4px 0; border: 0; background: transparent; cursor: pointer; text-align: left; color: var(--ink); width: 100%; }
.mb-switch-text { display: flex; flex-direction: column; gap: 1px; }
.mb-switch { width: 36px; height: 20px; border-radius: 999px; background: var(--border-btn); position: relative; flex-shrink: 0; transition: background 0.2s; }
.mb-switch::after { content: ""; position: absolute; top: 2px; left: 2px; width: 16px; height: 16px; border-radius: 50%; background: var(--knob); box-shadow: 0 1px 2px var(--shadow-lg); transition: transform 0.2s; }
.mb-switch.is-on, .mb-switch-input:checked + .mb-switch { background: var(--ink); }
.mb-switch.is-on::after, .mb-switch-input:checked + .mb-switch::after { transform: translateX(16px); background: var(--knob-on); }
.mb-switch-input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.mb-switch-input:focus-visible + .mb-switch { outline: 2px solid var(--link); outline-offset: 2px; }
.mb-switch-title { font-size: 13px; font-weight: 600; }
.cp-login-panel { display: flex; flex-direction: column; gap: 12px; }
.cp-login-steps { margin: 0; padding-left: 20px; font-size: 14px; color: var(--text-2); display: flex; flex-direction: column; gap: 6px; }

/* Accounts table, toolbar, row menu and detail page */
.cp-table .cp-tr { align-items: start; }
.cp-table .cp-account-id { align-items: flex-start; }
.cp-table .cp-avatar-ink { width: 34px; height: 34px; border-radius: 10px; font-size: 14px; }
.cp-table .cp-window { gap: 5px; }
.cp-table .cp-meter { height: 6px; }
/* A key's row has no window to show (ADR-0020), so it carries one cell where a subscription account carries the
   two windows (ADR-0023): the wallet cell spreads over both tracks and the empty cell after it leaves the flow. */
.cp-table-accounts .cp-tr[data-kind="api_key"] > :nth-child(3) { grid-column: span 2; }
.cp-table-accounts .cp-tr[data-kind="api_key"] > :nth-child(4) { display: none; }
/* The Accounts page's provider sections (#461, #462, #468): one card holds every provider, and each is a collapsible
   band inside it — a summary with the mark, name, live dots and count, and the provider's own table underneath.

   The slide is `grid-template-rows: 0fr -> 1fr` (#468), which animates to the row's real height without JavaScript
   having to measure it: the body is a grid whose single row collapses to nothing, and the table inside it is clipped
   by `min-height: 0`. A <details> cannot animate its own height, and `::details-content` does not take the closed rule
   in Chrome, so the body carries the animation instead. Without JavaScript the band still opens and closes, as one
   always did — it just snaps. */
.cp-provider-card + .cp-provider-card { border-top: 1px solid var(--border-3); }
/* The chevron is the details marker, drawn here rather than as a glyph of its own. It turns with a spring, so the
   band reads as a lid opening rather than a list item changing state. */
.cp-provider-card:not([open]) .cp-provider-summary-end::after { transform: rotate(-90deg); }
.cp-provider-body { display: grid; grid-template-rows: 1fr; overflow: hidden; transition: grid-template-rows 300ms cubic-bezier(.2,.8,.2,1); }
.cp-provider-body > * { min-height: 0; }
/* A closed `<details>` hides its content through the UA's own rule, which `display` here overrides so the row can
   collapse on screen instead of vanishing. `visibility` then keeps the collapsed body out of the tab order and out
   of hit-testing once the slide is over — it is transitioned, not switched, so a closing body stays painted while it
   shrinks. Without this the body would keep painting under the summary and swallow clicks meant for the rows.

   `[data-closing]` is what collapses the row while the slide runs: `open` has to stay on until the transition ends,
   so the CSS cannot key off `:not([open])` for a section that is on its way out. */
.cp-provider-card[data-closing] > .cp-provider-body { grid-template-rows: 0fr; visibility: hidden; transition: grid-template-rows 300ms cubic-bezier(.2,.8,.2,1), visibility 0s linear 300ms; }
.cp-provider-card:not([open]) > .cp-provider-body { grid-template-rows: 0fr; visibility: hidden; }
.cp-provider-card[open] > .cp-provider-body { visibility: visible; transition: grid-template-rows 300ms cubic-bezier(.2,.8,.2,1), visibility 0s; }
@media (prefers-reduced-motion: reduce) { .cp-provider-body, .cp-provider-card[data-closing] > .cp-provider-body, .cp-provider-card[open] > .cp-provider-body { transition: none; } }
@media (prefers-reduced-motion: reduce) { .cp-provider-summary-end::after { transition: none; } }
/* The live dots (#468): one per account, filled when it is serving and hollow when it is not, so a band's health
   reads before the count does. Colour alone never carries it — the count and the ring say the same thing in words. */
/* A provider's block of rows (#451): a band with its mark, name, count and a link to its configuration. It spans the
   table's whole width and does not take part in the row grid, so the account columns stay aligned underneath. */
.cp-tr-group { display: flex; align-items: center; gap: 10px; margin-top: 6px; padding: 10px 14px 8px; border-top: 1px solid var(--border-subtle); background: var(--surface-2, transparent); }
.cp-tr-group:first-of-type { margin-top: 0; }
.cp-group-name .cp-mark { width: 18px; height: 18px; }
.cp-group-link { margin-left: auto; font-size: 12px; color: var(--clay-deep); text-decoration: none; }
.cp-group-link:hover { text-decoration: underline; }
/* A provider's health ring (#463): a donut whose sweep is the share of the provider's accounts that are live. Drawn
   with a conic gradient so it needs no SVG and no script; the hole is the card surface behind a centred number. */
.cp-ring-ok { --cp-ring-tone: var(--ok); }
.cp-ring-warn { --cp-ring-tone: var(--clay); }
.cp-ring-danger { --cp-ring-tone: var(--danger-solid); }
.cp-ring-empty { background: var(--track); }
/* The Providers list (#453, #463): one card per upstream — a large mark, its name, a health ring and the account
   count — and the whole card is the link to that provider's page. */
.cp-provider-tile-head .cp-mark { width: 22px; height: 22px; stroke-width: 1.9; }
.cp-provider-tile-share { font-size: 20px; font-weight: 600; font-variant-numeric: tabular-nums; color: var(--ink); line-height: 1.1; }
.cp-provider-tile-meta { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.cp-provider-empty { grid-column: 1 / -1; margin: 0; padding: 14px 16px; border: 1px dashed var(--border-3); border-radius: 14px; }
/* #468: the provider card as the handoff draws it — the name with a health chip, the ring, three figures, the model
   chips, and a footer that names the destination. The card lifts on hover and its border takes the provider's colour,
   so the grid reads as distinct providers rather than identical boxes. */
/* A soft bloom in the provider's own colour, bleeding off the card's top-right corner. It is what makes the three cards
   read as three sources rather than three copies of one box, and it costs no layout: it is a pseudo-element hanging
   outside the padding box, clipped by the card's own radius. */
/* The handoff leaves the card still in light mode: the lift is a dark-mode gesture, and the light card is already the
   brightest thing on the page. */
:root[data-theme="light"] .cp-provider-tile:hover { box-shadow: 0 12px 26px -10px rgba(31,29,26,.16); }
@media (prefers-color-scheme: light) { :root:not([data-theme="dark"]) .cp-provider-tile:hover { box-shadow: 0 12px 26px -10px rgba(31,29,26,.16); } }
/* The provider's mark, drawn as the handoff draws `.pv`: a 40px tile tinted with the provider's colour, an inset ring
   of the same colour at 28%, and the artwork at 22px inside it. */
.cp-pv { display: flex; align-items: center; justify-content: center; flex: none; width: 40px; height: 40px; border-radius: 11px; color: var(--prov, var(--clay)); background: color-mix(in srgb, var(--prov, var(--clay)) 15%, transparent); box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--prov, var(--clay)) 28%, transparent); }
.cp-pv .cp-mark { width: 22px; height: 22px; stroke-width: 1.9; }
.cp-provider-tile-stats { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; padding-top: 12px; border-top: 1px solid var(--border-3); }
.cp-provider-tile-stat { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.cp-provider-tile-stat-value { font-size: 16px; font-weight: 600; font-variant-numeric: tabular-nums; color: var(--ink); letter-spacing: -0.01em; }
/* The card's body is a ring beside a two-by-two list of figures, as the handoff draws it. The list is a real `dl`, so
   each label sits above its own number and a wide number never pushes the next label out of its column — the failure
   that made the old three-across strip wrap "0 / 4" and stack "USD EQUIV." on "RATE LIMITED". */
/* The dashed slot that ends the grid: adding a provider is not a provider, so it reads as an empty place to fill. */
@media (prefers-reduced-motion: reduce) { .cp-provider-tile, .cp-provider-add { transition: none; } .cp-provider-tile:hover { transform: none; } }
/* #480, #514: a provider's account list, drawn the way the handoff draws it. The row is a six-column grid — grip, the
   account, one column per quota window, the switch, the chevron — so the two bars line up down the whole list and a
   long email can only ever eat its own column. The position the account holds sits inside the grip as a small badge
   rather than in a column of its own, which is what makes the row narrow enough to hold two full bars. */
/* The accounts head is the card's own title bar, as the handoff draws `.tb`: padded away from the card's edges and
   ruled off from the rows beneath, so the title reads as a heading rather than as a row that lost its border. */
/* The row being dragged lifts off the list — a shadow, a rounded edge and the chip colour — so it reads as picked up
   rather than as another row, which is what the handoff draws as `.ar.drag`. */
/* A disabled account stays readable but recedes: it is still part of the provider, just not serving. */
/* The grip carries the position badge in its top-left corner, as the handoff draws it, so the order is legible without
   spending a column on a number. */
.cp-account-priority { position: absolute; left: -1px; top: -5px; min-width: 16px; padding: 1px 3px; font-size: 10px; font-weight: 700; font-variant-numeric: tabular-nums; text-align: center; color: var(--card); background: var(--ink); border-radius: 6px; }
/* The account cell is the dot beside the name and email, so the dot reads as part of the account rather than as a
   column of its own. */
/* One quota window: its label and its number on a line, its bar full-width beneath. The bar spans the column rather
   than sitting in a fixed 54px stub, so the two windows are comparable at a glance down the list. */
/* The bars grow into place rather than being there on arrival, as the handoff draws them. Only when a script is running,
   because the growth is the script's doing — without one the bar is simply drawn at its value. */
/* The chevron points the way out of the row, and slides toward it when the row is hovered, as the handoff draws `.chv`. */
/* Says how much of the list a filter is hiding, and stays empty when nothing is hidden (#522). */
/* Below 1100px the two quota columns fold away and the row keeps what identifies the account and what turns it on. */
/* Below 760px the row collapses to its name and its switch. */
@media (prefers-reduced-motion: reduce) { .cp-account-row, .cp-account-bar-fill, .cp-filter-chip { transition: none; } }
/* #478: a provider's own page opens on a hero — the mark on a tinted tile, the name, one line of facts, and the two
   actions that belong to the provider as a whole. */
/* The provider's own page opens on its name, not on a boxed summary (#512). The handoff draws the hero as an open
   block — a large mark, the name at display size, one line of facts, the two actions pushed right — so the page starts
   with the provider rather than with a card that repeats what the KPI strip below already says. */
.cp-provider-hero .cp-pv { width: 72px; height: 72px; border-radius: 20px; }
.cp-provider-hero .cp-pv .cp-mark { width: 38px; height: 38px; }
/* The test button swaps its label for the answer in place, so the hero does not reflow when the probe returns. */
.cp-provider-hero-actions [data-test-connection][aria-busy] .cp-test-label { opacity: 0.6; }
/* #484: the answer to a reachability probe is a chip, not bare coloured text — it is a result, and a result should
   look like one. A failure takes the danger tint so it reads at a glance, and the glyph carries the meaning for anyone
   who cannot see the colour. */
.cp-test-result { display: inline-flex; align-items: center; gap: 4px; padding: 2px 9px; font-size: 12px; font-weight: 600; font-variant-numeric: tabular-nums; border-radius: 999px; border: 1px solid transparent; }
.cp-test-result[data-state="ok"] { color: var(--ok-deep); background: var(--ok-tint); border-color: var(--ok-deep); }
.cp-test-result[data-state="err"] { color: var(--danger); background: var(--danger-tint); border-color: var(--danger); }
/* #484: an account whose OAuth token has expired. The name takes the accent and its bars go muted, because the numbers
   there describe a credential that can no longer be used. */
/* #484: a loading skeleton, for a page whose figures are still being read. It is a shape, not a spinner: the page keeps
   its layout so nothing jumps when the numbers arrive. */
.cp-skeleton { display: block; border-radius: 8px; background: linear-gradient(90deg, var(--border-3) 25%, var(--hover) 50%, var(--border-3) 75%); background-size: 200% 100%; animation: cpShimmer 1400ms ease-in-out infinite; }
.cp-skeleton-line { height: 11px; margin: 5px 0; }
.cp-skeleton-line.is-short { width: 42%; }
@keyframes cpShimmer { from { background-position: 200% 0; } to { background-position: -200% 0; } }
@media (prefers-reduced-motion: reduce) { .cp-skeleton { animation: none; } }
/* The KPI strip is one bordered block of four cells, as the handoff draws `.kp`: no gap, the outer border and radius on
   the block, and a single rule between cells. */
/* The routing tiles: a radio group of three cards, each drawing what its strategy does. */
/* The chosen tile is the one whose diagram is running, so it is marked the way the handoff marks it: the page's ink as
   a one-pixel ring, and a wash of the provider's colour rising from the top-left corner. */
/* The radio is the control the browser and a screen reader use; it is drawn away and the tile is its label. Its visible
   stand-in is the dot in the title, which fills in when the strategy is chosen. */
/* The flow diagram: one source, three lines, three targets. Each strategy animates the same drawing differently, so
   the tile says what it does without a paragraph. */
@keyframes cpFlowFade { 0%, 100% { border-top-color: var(--border-2); } 50% { border-top-color: var(--clay); } }
@keyframes cpFlowPulse { 0%, 100% { border-top-color: var(--border-2); } 50% { border-top-color: var(--clay); } }
/* Below 1100px the KPI strip folds to 2x2 and the routing tiles become rows rather than columns. */
/* Below 760px the hero stacks and the tiles become full-width rows. */
@media (max-width: 760px) {
  .cp-provider-hero-actions .cp-btn { flex: 1 1 auto; justify-content: center; }
}
/* A provider's own page (#453): a back link above the header. Everything below it is the console's own card, row and
   table classes, so the page reads like Settings and the Accounts page's pending-link list. */
/* Row drag (#463): the grip is quiet until the row is under the pointer, so a resting table reads as data rather
   than as a control panel. Dragging lifts the row onto a card carrying the clay ring the design uses for focus; the
   row it left behind stays in the flow as a dimmed placeholder, so the table already shows the result. */
.cp-tr:hover .cp-grip { opacity: 1; }
/* The row being dragged, still in place: a gap the pointer can drop back into. It is drawn faint rather than moved —
   it keeps its `transform` free, because the FLIP that slides the neighbours writes `translateY` onto these rows and
   a `scale` here would be overwritten by it. */
.cp-tr.sort-ghost { opacity: 0.3; transition: opacity 160ms ease; }
.cp-tr.sort-ghost .cp-grip { cursor: grabbing; }
/* The clone that follows the pointer. It is fixed to the viewport and moved with a transform, so it never reflows
   the table, and it ignores the pointer so `elementFromPoint` still reports the row underneath it. It keeps the
   table's column widths as `--cp-drag-cols` so its cells line up with the rows it came from, and it is drawn a touch
   larger with a deep shadow and the clay ring the design uses for focus, which is what makes it read as picked up. */
.cp-tr.sort-drag {
  position: fixed;
  z-index: 40;
  display: grid;
  grid-template-columns: var(--cp-drag-cols, 1fr);
  margin: 0;
  background: var(--card);
  border-radius: 12px;
  box-shadow: 0 18px 44px var(--shadow-lg), 0 0 0 1.5px var(--clay);
  opacity: 1 !important;
  cursor: grabbing;
  pointer-events: none;
  transform-origin: center;
  animation: cpDragLift 180ms cubic-bezier(.34,1.5,.5,1) both;
}
@keyframes cpDragLift { from { opacity: 0.6; } to { opacity: 1; } }
.cp-tr.sort-drag .cp-grip { opacity: 1; color: var(--clay); cursor: grabbing; }
/* While a drag runs, the rows it can reach glow faintly, so the block it may move within is visible before the
   pointer arrives; the placeholder it left behind stays transparent. */
.cp-table.cp-sorting .cp-tr[data-account-row] { background: var(--clay-tint); }
.cp-table.cp-sorting .cp-tr.sort-ghost { background: transparent; }
/* A drag must not select the text it sweeps over. */
@media (prefers-reduced-motion: reduce) {
  .cp-tr.sort-ghost { transition: none; }
  .cp-tr.sort-drag { animation: none; }
}
.cp-actions-end { justify-content: flex-end; flex-wrap: nowrap; align-items: center; }
.cp-menu { position: relative; }
.cp-menu-trigger { list-style: none; width: 32px; height: 32px; display: grid; place-items: center; border: 1px solid var(--border-btn); border-radius: 8px; background: var(--card); color: var(--ink); cursor: pointer; font-size: 16px; line-height: 1; }
.cp-menu-trigger::-webkit-details-marker { display: none; }
.cp-menu-trigger:hover, .cp-menu[open] > .cp-menu-trigger { background: var(--border-3); }
.cp-menu-list { position: fixed; z-index: 20; width: 180px; margin: 4px 0 0 -148px; padding: 4px; display: flex; flex-direction: column; background: var(--card); border: 1px solid var(--border); border-radius: 12px; box-shadow: 0 12px 32px var(--shadow-md); animation: cpIn 0.15s ease-out; }
.cp-menu-list .cp-inline-form { display: flex; }
/* A row-menu item that carries a dropdown stacks it under the item: side by side it would sit on top of it. */
.cp-btn-menu { width: 100%; justify-content: flex-start; font-size: 13px; font-weight: 500; padding: 8px 10px; border-radius: 8px; background: transparent; color: var(--ink); }
.cp-btn-menu:hover { background: var(--border-3); color: var(--ink); }
.cp-btn-menu:disabled { cursor: not-allowed; }
form[action$="/remove"] > .cp-btn-menu { color: var(--danger); }
.cp-detail-section { display: flex; flex-direction: column; gap: 10px; }
/* Members and requests are two views of one account, not two things to read in turn: a tab bar keeps the page one
   screen long, so the danger zone stays reachable without scrolling past a request log. */
@media (prefers-reduced-motion: reduce) { .cp-tab { transition: none; } }
.cp-detail-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.cp-detail-head .cp-btn-icon { width: 32px; height: 32px; border-radius: 8px; }
.cp-detail-head .cp-icon { width: 15px; height: 15px; }
[data-requests-panel] .cp-card { transition: opacity 0.15s; }
[data-requests-panel].is-loading .cp-card { opacity: 0.55; pointer-events: none; }
.cp-pager-nav { display: flex; align-items: center; flex-wrap: wrap; justify-content: flex-end; gap: 6px 18px; }
.cp-pager-sizes { display: flex; align-items: center; gap: 2px; }
.cp-pager-sizes .cp-hint { margin-right: 6px; }
.cp-pager-size { font-size: 12px; font-weight: 600; padding: 3px 8px; border-radius: 7px; color: var(--text-3); text-decoration: none; }
.cp-pager-size:hover { background: var(--border-3); color: var(--ink); }
.cp-pager-size[aria-current="true"] { background: var(--track); color: var(--ink); }
.cp-pager { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 10px 18px; border-top: 1px solid var(--border-3); }
.cp-pager-link { font-size: 13px; font-weight: 600; color: var(--text-2); text-decoration: none; }
a.cp-pager-link:hover { color: var(--ink); }
.cp-pager-link.is-disabled { color: var(--muted); opacity: 0.5; }
.cp-routecap { display: flex; flex-direction: column; gap: 8px; padding-top: 4px; border-top: 1px solid var(--border-2); }

/* A custom account's model aliases (ADR-0024): one chip per rewrite, then the form that adds one */
.cp-aliases { display: flex; flex-direction: column; gap: 12px; padding: 16px 18px; }
.cp-aliases-head { display: flex; flex-direction: column; gap: 3px; }
.cp-aliases-rows { display: flex; flex-wrap: wrap; gap: 8px; }
.cp-alias-row { display: flex; align-items: center; gap: 8px; padding: 4px 4px 4px 10px; border: 1px solid var(--border-3); border-radius: 8px; }
.cp-alias-remove { width: 22px; height: 22px; padding: 0; border: 0; border-radius: 6px; background: transparent; color: var(--text-3); font-size: 15px; line-height: 1; cursor: pointer; }
.cp-alias-remove:hover { background: var(--hover); color: var(--ink); }
/* Account owner card: one row per quota request, sent time on the left, the outcome after it. */
@media (max-width: 560px) { .cp-owner-history li { grid-template-columns: 1fr; gap: 2px; } }

/* Member shares of an account (Usage, account page, Members) */
.cp-quota-bar { display: flex; height: 14px; border-radius: 999px; overflow: hidden; background: var(--border-2); gap: 2px; }
.cp-quota-seg { min-width: 3px; }
.cp-dot { display: inline-block; width: 9px; height: 9px; border-radius: 50%; margin-right: 6px; flex-shrink: 0; }
.cp-quota-legend .cp-dot { margin-right: 0; }
/* Member colours: hues the status colours (green, amber, red) never use, mid-tone so they read on both themes. */
.cp-mc-0 { background: #4f7cc0; }
.cp-mc-1 { background: #8a63b8; }
.cp-mc-2 { background: #2a9db0; }
.cp-mc-3 { background: #c0568c; }
.cp-mc-4 { background: #7a8a99; }
.cp-mc-5 { background: #a8794a; }
.cp-mc-none { background: var(--muted); opacity: 0.55; }
.cp-shares-block { display: flex; flex-direction: column; gap: 10px; }
.cp-shares-title { display: flex; align-items: baseline; gap: 10px; flex-wrap: wrap; font-weight: 600; font-size: 15px; }

/* Overlays: confirm dialog and OAuth modal */
.cp-overlay { position: fixed; inset: 0; background: var(--overlay); backdrop-filter: blur(3px); -webkit-backdrop-filter: blur(3px); display: grid; place-items: center; padding: 20px; z-index: 40; animation: cpFade 0.2s ease-out; }
.cp-dialog { width: 100%; max-width: 540px; background: var(--card); border-radius: 20px; box-shadow: 0 30px 80px var(--shadow-lg); overflow: hidden; animation: cpIn 0.25s ease-out; }
.cp-dialog-sm { max-width: 420px; }
.cp-dialog-head { padding: 22px 24px 18px; display: flex; flex-direction: column; gap: 16px; border-bottom: 1px solid var(--border-2); }
.cp-dialog-titlebar { display: flex; justify-content: space-between; align-items: center; gap: 12px; }
.cp-dialog-title { font-family: var(--serif); font-size: 22px; letter-spacing: -0.01em; }
.cp-dialog-title-lg { font-size: 28px; }
.cp-dialog-close { font: inherit; font-size: 18px; width: 32px; height: 32px; border-radius: 8px; border: 0; background: transparent; color: var(--text-4); cursor: pointer; flex-shrink: 0; }
.cp-dialog-close:hover { background: var(--border-3); }
.cp-dialog-body { padding: 22px 24px 24px; display: flex; flex-direction: column; gap: 16px; }
.cp-dialog-text { margin: 0; font-size: 14px; color: var(--text-2); text-wrap: pretty; }
.cp-dialog-text strong { color: var(--ink); }
.cp-dialog-actions { display: flex; flex-wrap: wrap; gap: 8px; justify-content: flex-end; }
.cp-steps { display: flex; gap: 6px; }
.cp-step { flex: 1; display: flex; flex-direction: column; gap: 6px; }
.cp-step-bar { height: 4px; border-radius: 999px; background: var(--border-2); }
.cp-step-label { font-size: 12px; font-weight: 600; color: var(--muted); }
.cp-step.is-done .cp-step-bar { background: var(--ink); }
.cp-step.is-current .cp-step-bar { background: var(--clay); }
.cp-step.is-done .cp-step-label, .cp-step.is-current .cp-step-label { color: var(--ink); }
.cp-oauth-panel { display: flex; flex-direction: column; gap: 14px; }
.cp-oauth-mode { margin: 0; padding: 0; border: 0; display: flex; flex-direction: column; gap: 8px; min-width: 0; }
.cp-oauth-mode legend { padding: 0; margin-bottom: 2px; }
.cp-oauth-mode-opt { display: flex; gap: 10px; align-items: flex-start; padding: 10px 12px; border: 1px solid var(--border-btn); border-radius: 10px; cursor: pointer; font-size: 14px; }
.cp-oauth-mode-opt:has(input:checked) { border-color: var(--clay); }
.cp-oauth-mode-opt input { margin: 3px 0 0; accent-color: var(--ink); }
.cp-oauth-mode-opt > span { display: flex; flex-direction: column; gap: 2px; }
.cp-url-box { display: flex; flex-direction: column; gap: 6px; padding: 12px 14px; background: var(--paper); border-radius: 10px; }
.cp-url { font-family: var(--mono); font-size: 12px; color: var(--ink); word-break: break-all; line-height: 1.5; }
.cp-oauth-busy { align-items: center; padding: 22px 0; }
.cp-spinner { width: 34px; height: 34px; border-radius: 50%; border: 3px solid var(--border-2); border-top-color: var(--clay); animation: cpSpin 0.8s linear infinite; }
.cp-done-head { display: flex; align-items: center; gap: 12px; }
.cp-done-check { width: 40px; height: 40px; border-radius: 50%; background: var(--ok-tint); color: var(--ok-deep); display: grid; place-items: center; font-size: 20px; font-weight: 700; flex-shrink: 0; }
.cp-done-text { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.cp-done-title { font-weight: 600; font-size: 16px; overflow-wrap: anywhere; }
.cp-done-sub { font-size: 13px; color: var(--text-3); overflow-wrap: anywhere; }
.cp-done-grid { display: grid; grid-template-columns: auto 1fr; gap: 8px 16px; padding: 14px; background: var(--paper); border-radius: 10px; font-size: 13px; }

/* Toasts */
.cp-toasts { position: fixed; right: 20px; bottom: 20px; display: flex; flex-direction: column; gap: 10px; z-index: 60; width: min(360px, calc(100vw - 40px)); pointer-events: none; }
.cp-toast { pointer-events: auto; position: relative; overflow: hidden; display: flex; align-items: flex-start; gap: 12px; padding: 14px 14px 16px 16px; background: var(--deep); color: var(--on-deep); border-radius: 14px; box-shadow: 0 14px 40px var(--shadow-lg); animation: cpToast 0.32s cubic-bezier(0.2, 0.9, 0.3, 1.2); }
.cp-toast-icon { width: 22px; height: 22px; border-radius: 50%; color: var(--deep); display: grid; place-items: center; font-size: 12px; font-weight: 700; flex-shrink: 0; margin-top: 1px; }
.cp-toast-text { display: flex; flex-direction: column; gap: 2px; flex: 1; min-width: 0; }
.cp-toast-title { font-size: 14px; font-weight: 600; }
.cp-toast-body { font-size: 13px; color: var(--on-dark); text-wrap: pretty; overflow-wrap: anywhere; }
.cp-toast-close { font: inherit; font-size: 16px; line-height: 1; border: 0; background: transparent; color: var(--on-dark-muted); cursor: pointer; padding: 2px; }
.cp-toast-close:hover { color: var(--on-dark-strong); }
.cp-toast-bar { position: absolute; left: 0; bottom: 0; height: 3px; width: 100%; transform-origin: left; animation: cpBar 3.6s linear forwards; }
.cp-toast-ok .cp-toast-icon, .cp-toast-ok .cp-toast-bar { background: var(--toast-ok); }
.cp-toast-warn .cp-toast-icon, .cp-toast-warn .cp-toast-bar { background: var(--toast-warn); }
.cp-toast-info .cp-toast-icon, .cp-toast-info .cp-toast-bar { background: var(--on-dark); }
.cp-toast-err .cp-toast-icon, .cp-toast-err .cp-toast-bar { background: var(--toast-err); }

/* Pre-redesign content kept on stub pages until wave B restyles them */
.cp-legacy { font-size: 14px; line-height: 1.5; }
.cp-legacy h3 { margin: 0 0 8px; font-size: 16px; display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.cp-legacy p { margin: 0 0 8px; }
.cp-legacy form:not(.cp-inline-form) { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; margin: 0 0 12px; }
.cp-legacy input:not([type="hidden"]) { font: inherit; font-size: 13px; padding: 6px 8px; border: 1px solid var(--border-btn); border-radius: 8px; background: var(--input-bg); color: var(--ink); }
.cp-legacy table { border-collapse: collapse; width: 100%; margin: 8px 0 16px; font-size: 13px; }
.cp-legacy th { text-align: left; padding: 8px 10px; font-size: 11px; font-weight: 600; color: var(--muted); text-transform: uppercase; letter-spacing: 0.06em; background: var(--table-head); }
.cp-legacy td { text-align: left; padding: 8px 10px; border-top: 1px solid var(--border-3); }
.cp-legacy td.num, .cp-legacy th.num { text-align: right; font-variant-numeric: tabular-nums; }
.cp-legacy code { font-family: var(--mono); font-size: 12px; }

/* Settings: both cards' rows. One row per setting — its name with an info icon carrying the hint as a tooltip, the
   setting's own control in its own column, and a switch in the last column; a row with a textarea puts it on a line
   below. The switch column is always the third, so a row without a control (Compress tool output) lines its switch up
   with the rows that have one. */
.cp-card-head { display: flex; align-items: center; gap: 6px; margin-bottom: 4px; }
.cp-saver-list { display: flex; flex-direction: column; margin: 4px 0 0; }
.cp-saver-row { display: grid; grid-template-columns: minmax(0, 1fr) auto 44px; gap: 8px 16px; align-items: center; padding: 14px 0; border-top: 1px solid var(--border-3); }
.cp-saver-row:first-child { border-top: 0; }
.cp-saver-head { display: flex; align-items: center; gap: 6px; min-width: 0; }
.cp-saver-title { font-size: 14px; font-weight: 600; color: var(--ink); }
/* The switch keeps the last column whether or not its row has a control, and sits at the row's right edge. */
.cp-saver-switch { grid-column: 3; justify-self: end; display: inline-flex; align-items: center; cursor: pointer; }
.cp-saver-level { max-width: 200px; }
.cp-unit { display: inline-flex; align-items: center; gap: 8px; }
.cp-unit-text { font-size: 13px; color: var(--text-3); white-space: nowrap; }
.cp-num { width: 88px; }
.cp-saver-wide { grid-column: 1 / -1; display: flex; flex-direction: column; gap: 4px; max-width: 420px; margin-top: 4px; }
.cp-saver-wide textarea { resize: vertical; font-family: var(--mono); font-size: 12px; }
.cp-saver-note { margin: 0 0 6px; }
.cp-saver-note:last-child { margin-bottom: 0; }
/* A card that holds a tooltip cannot clip it: .cp-card is overflow: hidden, so a hint above a row was cut off. */
.cp-card-tip { overflow: visible; }
/* On a narrow screen the control drops under the title rather than squeezing it. */
@media (max-width: 640px) {
  .cp-saver-row { grid-template-columns: minmax(0, 1fr) auto; }
  .cp-saver-row > .cp-saver-level { grid-column: 1 / -1; max-width: none; }
  .cp-saver-switch { grid-column: 2; }
}

/* An info icon whose hint shows as a tooltip on hover or keyboard focus, so a row's copy does not crowd its control. */
.cp-info { position: relative; display: inline-flex; color: var(--text-4); cursor: help; border-radius: 50%; }
.cp-info:hover, .cp-info:focus-visible { color: var(--text-2); }
.cp-info:focus-visible { outline: 2px solid var(--link); outline-offset: 2px; }
.cp-info .cp-icon { width: 14px; height: 14px; }
.cp-tip { position: absolute; left: 50%; bottom: calc(100% + 8px); z-index: 20; display: flex; flex-direction: column; gap: 6px; width: max-content; max-width: 280px; padding: 8px 10px; border-radius: 8px; background: var(--deep); color: var(--on-deep); font-size: 12px; font-weight: 400; line-height: 1.45; text-align: left; white-space: normal; box-shadow: 0 8px 24px var(--shadow-lg); transform: translateX(-50%); opacity: 0; visibility: hidden; transition: opacity 0.15s, visibility 0.15s; pointer-events: none; }
.cp-info:hover .cp-tip, .cp-info:focus-visible .cp-tip { opacity: 1; visibility: visible; }
.cp-tip [data-routing-note][hidden] { display: none; }

/* ============================================================================
   Danger zone (#486) — shared by the account page and the provider page.

   The gesture is the same in both places, so the rules live here rather than in
   either page's own <style>. A page that renders the button without the rule is
   a button that does nothing, which is exactly what happened when these sat
   inside account-detail.ts and the provider page rendered .cp-hold bare.
   ============================================================================ */
/* The handoff lays the danger zone out in two bands: the heading and its sentence across the top, then one row of
   three columns — the accounts that are affected, the consequences, and the hold ring. Keeping the chips in their own
   column is what lets the consequences read as a list beside them rather than as a paragraph underneath. */
/* While the ring fills the card shakes and glows, so the gesture is felt as well as seen. */
.cp-danger-card:has(.cp-hold[data-holding]) { border-color: var(--danger); box-shadow: 0 0 0 3px var(--danger-tint), 0 14px 38px var(--shadow-md); animation: cpDangerShake 320ms ease-in-out infinite; }
/* Each consequence carries a disc that fills as the hold pays for it, so the cost is read while the gesture is made. */
/* What survives is never struck: it is the reassurance the card exists to give. */
/* The provider's accounts, fading out one by one as the hold rises. Each chip carries the account's initial in the
   provider's own colour, as the handoff draws it, so the column reads as named people rather than as a list of strings. */

/* The dissolve (#504): once the hold completes the card lifts and thins out while dust rises off it, so the removal
   reads as the thing coming apart rather than as a page that suddenly changed. The dust is drawn by the script; the
   card itself only has to fade, blur and drift. */
.cp-dust { position: fixed; z-index: 60; border-radius: 2px; pointer-events: none; }
@keyframes cpDangerDissolve {
  to { opacity: 0; filter: blur(6px); transform: translateY(-10px) scale(.985); }
}

/* The hold ring: a 96px circle whose stroke fills from the top, an icon in the middle that turns as it fills, and a
   hint underneath. The glow around it grows with --cp-hold, so the button reads as charging. */
.cp-hold-wrap { display: flex; flex-direction: column; align-items: center; gap: 12px; text-align: center; }
.cp-hold-wrap[data-gone] { opacity: 0; pointer-events: none; transform: scale(.9); transition: opacity 300ms ease, transform 300ms ease; }
.cp-hold-hint { font-size: 12px; line-height: 1.5; color: var(--text-3); max-width: 150px; }
.cp-hold { position: relative; width: 96px; height: 96px; padding: 0; border: 0; border-radius: 50%; background: color-mix(in srgb, var(--danger) 14%, var(--card)); color: var(--danger); cursor: pointer; touch-action: none; user-select: none; box-shadow: 0 0 0 1px color-mix(in srgb, var(--danger) 40%, transparent), 0 0 calc(var(--cp-hold, 0) * 38px) calc(var(--cp-hold, 0) * 5px) color-mix(in srgb, var(--danger) 45%, transparent); transition: transform 250ms cubic-bezier(.34,1.8,.5,1), background 200ms ease; }
.cp-hold:hover { transform: scale(1.05); }
.cp-hold:active, .cp-hold[data-holding] { transform: scale(.93); }
.cp-hold:focus-visible { outline: 2px solid var(--danger); outline-offset: 3px; }
.cp-hold-svg { position: absolute; inset: -4px; width: calc(100% + 8px); height: calc(100% + 8px); transform: rotate(-90deg); overflow: visible; }
.cp-hold-track, .cp-hold-fill { fill: none; stroke-width: 6; stroke-linecap: round; }
.cp-hold-track { stroke: var(--danger-tint); }
.cp-hold-fill { stroke: var(--danger); stroke-dasharray: 0 327; transition: stroke-dasharray 60ms linear; }
.cp-hold[data-rewinding] .cp-hold-fill { transition: stroke-dasharray 400ms ease-out; }
.cp-hold-icon { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; }
.cp-hold-icon svg { width: 30px; height: 30px; transform: rotate(calc(var(--cp-hold, 0) * 180deg)); }
.cp-hold[data-done] { background: var(--danger); color: var(--on-deep); }

/* The undo bar: 8 seconds to take the removal back, with a bar that empties as the time runs out. */
.cp-undo { position: relative; display: none; align-items: center; gap: 14px; flex-wrap: wrap; grid-column: 1 / -1; padding: 14px 16px; overflow: hidden; background: var(--card); border: 1px solid var(--border-2); border-radius: 14px; }
.cp-undo[data-on] { display: flex; animation: cpRise 400ms cubic-bezier(.2,.8,.2,1) both; }
.cp-undo-text { font-size: 14px; font-weight: 600; color: var(--ink); }
.cp-undo-bar { position: absolute; left: 0; right: 0; bottom: 0; height: 3px; background: var(--track); }
.cp-undo-bar i { display: block; height: 100%; background: var(--danger); }
.cp-undo-btn { padding: 7px 16px; font: inherit; font-size: 13px; font-weight: 600; color: var(--on-deep); background: var(--danger); border: 0; border-radius: 999px; cursor: pointer; }
.cp-undo-btn:hover { filter: brightness(1.08); }
.cp-undo-btn:focus-visible { outline: 2px solid var(--danger); outline-offset: 2px; }

@keyframes cpDangerShake {
  0%, 100% { transform: translateX(0); }
  25% { transform: translateX(-2px); }
  75% { transform: translateX(2px); }
}
@keyframes cpRise { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: translateY(0); } }

@media (prefers-reduced-motion: reduce) {
  .cp-danger-card:has(.cp-hold[data-holding]) { animation: none; }
  .cp-dust { display: none; }
  .cp-danger-list li, .cp-danger-list li::before, .cp-danger-chip, .cp-hold, .cp-hold-fill, .cp-undo { transition: none; animation: none; }
}
@media (max-width: 1100px) {
  .cp-hold-wrap { align-items: flex-start; text-align: left; }
  .cp-hold-hint { max-width: none; }
}

/* ============================================================================
   The strategy tag on an account row (#488), and the sentence that explains
   where a provider's requests go. Both come from the handoff's provider page.
   ============================================================================ */
/* The tag says what the chosen strategy is doing with this account right now: a share, Draining, or Primary. */

/* The plain-language line under the connection rows: the same facts, said the way a person would say them. */

/* The routing tile's flow diagram (#488): one source, three targets, and a dash that travels along each line at the
   weight the strategy gives it. Drawn as SVG paths rather than rules so the dash can move along a curve. The lines take
   the provider's own colour (#512) — the handoff paints them with `--c` — so the diagram belongs to Anthropic or River
   rather than to the console's generic accent. */
/* The handoff draws every line with one dash pattern and one animation (`dsh`, 3 7, 1.1s), and lets the *tile* decide
   whether it runs: a selected tile animates all of its lines, an unselected one pauses all of them at 45% opacity. The
   difference between the strategies is drawn in the weights, not in separate animations. */
/* Balanced: all three carry an equal share. */
/* Fill first: the first target takes everything and the rest are waiting. */
/* Failover: the first line is solid — it always carries — and the others are dotted standbys. */
/* The unselected tiles dim their lines and stop the dash, so the moving one is unmistakably the chosen strategy. */
@keyframes cpFlowTravel { to { stroke-dashoffset: -20; } }

/* The hero's actions are pushed to the right edge, as the handoff draws them, so the name has the width it needs. */

/* ===== Handoff (#524) =====================================================================================
   The Accounts, Account, Providers and Provider pages are drawn from the design handoff's reference prototypes
   (`designs/Upstream accounts interactive dialog/design_handoff_accounts_providers/reference`), with its values taken
   as they are. Its tokens live under `--hx-*` so these pages read the handoff's palette in both themes: dark is its
   default, light is its flat "Claude-style" variant. Classes are prefixed `hx-`. */
:root {
  --hx-bg: #f4f1ea;
  --hx-c1: #fffdf9;
  --hx-in: #fffdf9;
  --hx-ln: #e3ddd0;
  --hx-ln2: #e6e0d3;
  --hx-ib-ln: #ded8ca;
  --hx-tx: #1f1d1a;
  --hx-tx2: #5f5a52;
  --hx-mu: #6b665e;
  --hx-mu2: #8a8479;
  --hx-chip: #ebe6db;
  --hx-chip-tx: #4a453e;
  --hx-ok: #2f7a43;
  --hx-wn: #a8650f;
  --hx-ac: #c4572b;
  --hx-bad: #b43a1f;
  --hx-off: #b9b1a0;
  --hx-tok: #1f1d1a;
  --hx-hover: #f9f6ef;
  --hx-head: #f4f1ea;
  --hx-sticky: #fffdf9;
  --hx-sticky-head: #f4f1ea;
  --hx-sticky-hover: #f9f6ef;
  --hx-drag: #fffdf9;
  --hx-pri-bg: #1f1d1a;
  --hx-pri-tx: #fff;
  --hx-track: #ebe6db;
  --hx-ring-tr: #e6e0d3;
  --hx-dot-off: #d9d2c3;
  --hx-menu: #fffdf9;
  --hx-expired: #b85a2e;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --hx-bg: #181512;
    --hx-c1: #201c18;
    --hx-in: #14110e;
    --hx-ln: #2f2923;
    --hx-ln2: #2a2520;
    --hx-ib-ln: #3a332b;
    --hx-tx: #ece6dc;
    --hx-tx2: #cfc7ba;
    --hx-mu: #9a9185;
    --hx-mu2: #7a7167;
    --hx-chip: #2a241e;
    --hx-chip-tx: #cfc7ba;
    --hx-ok: #7bc47f;
    --hx-wn: #e8b04b;
    --hx-ac: #e8743b;
    --hx-bad: #ef7d5e;
    --hx-off: #8a8176;
    --hx-tok: #f1e9dc;
    --hx-hover: rgba(255, 255, 255, .035);
    --hx-head: rgba(0, 0, 0, .18);
    --hx-sticky: #1f1b17;
    --hx-sticky-head: #191612;
    --hx-sticky-hover: #25201b;
    --hx-drag: #2c251e;
    --hx-pri-bg: #f1e9dc;
    --hx-pri-tx: #181512;
    --hx-track: rgba(255, 255, 255, .08);
    --hx-ring-tr: rgba(255, 255, 255, .08);
    --hx-dot-off: #4a4238;
    --hx-menu: rgba(34, 29, 24, .96);
    --hx-expired: #e8946b;
  }
}
:root[data-theme="dark"] {
  --hx-bg: #181512;
  --hx-c1: #201c18;
  --hx-in: #14110e;
  --hx-ln: #2f2923;
  --hx-ln2: #2a2520;
  --hx-ib-ln: #3a332b;
  --hx-tx: #ece6dc;
  --hx-tx2: #cfc7ba;
  --hx-mu: #9a9185;
  --hx-mu2: #7a7167;
  --hx-chip: #2a241e;
  --hx-chip-tx: #cfc7ba;
  --hx-ok: #7bc47f;
  --hx-wn: #e8b04b;
  --hx-ac: #e8743b;
  --hx-bad: #ef7d5e;
  --hx-off: #8a8176;
  --hx-tok: #f1e9dc;
  --hx-hover: rgba(255, 255, 255, .035);
  --hx-head: rgba(0, 0, 0, .18);
  --hx-sticky: #1f1b17;
  --hx-sticky-head: #191612;
  --hx-sticky-hover: #25201b;
  --hx-drag: #2c251e;
  --hx-pri-bg: #f1e9dc;
  --hx-pri-tx: #181512;
  --hx-track: rgba(255, 255, 255, .08);
  --hx-ring-tr: rgba(255, 255, 255, .08);
  --hx-dot-off: #4a4238;
  --hx-menu: rgba(34, 29, 24, .96);
  --hx-expired: #e8946b;
}

/* The handoff's dark surfaces: its `.glass` card is top-lit and a dragged row lifts on a shadow. One rule set, used
   by both ways the console can be dark (the system, or the toggle). */
.hx-glass { background: var(--hx-c1); border: 1px solid var(--hx-ln); border-radius: 18px; }
:root[data-theme="light"] .hx-glass { box-shadow: inset 0 1px 0 rgba(255,255,255,.7), 0 6px 20px -8px rgba(31,29,26,.1); }
@media (prefers-color-scheme: light) { :root:not([data-theme="dark"]) .hx-glass { box-shadow: inset 0 1px 0 rgba(255,255,255,.7), 0 6px 20px -8px rgba(31,29,26,.1); } }
:root[data-theme="dark"] .hx-glass { background: linear-gradient(145deg, rgba(255,255,255,.06), rgba(255,255,255,.012)); border: 1px solid rgba(255,255,255,.08); border-top-color: rgba(255,255,255,.15); box-shadow: inset 0 1px 0 rgba(255,255,255,.06), 0 10px 30px rgba(0,0,0,.28); }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .hx-glass { background: linear-gradient(145deg, rgba(255,255,255,.06), rgba(255,255,255,.012)); border: 1px solid rgba(255,255,255,.08); border-top-color: rgba(255,255,255,.15); box-shadow: inset 0 1px 0 rgba(255,255,255,.06), 0 10px 30px rgba(0,0,0,.28); } }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .hx-glass { background: linear-gradient(145deg, rgba(255,255,255,.06), rgba(255,255,255,.012)); border: 1px solid rgba(255,255,255,.08); border-top-color: rgba(255,255,255,.15); box-shadow: inset 0 1px 0 rgba(255,255,255,.06), 0 10px 30px rgba(0,0,0,.28); } }

/* #670: every other admin page's `.cp-card` (above, "Cards and tables") shares this same surface — background,
   border, radius, the light inset highlight and the dark gradient/top-highlight — so the console reads as one card
   language instead of this one and a flatter older one. Values copied from `.hx-glass` above, not shared through it,
   because every other themed pair in this file is its own single-selector line (so the `admin.css theme rules` test
   above keeps pairing toggle and media rules by their exact text). Scoped to `body[data-shell="admin"]`
   (`src/admin/layout.ts`, and `src/admin/pages/terms.ts` for the tenant acceptance gate only): the member app and the
   platform console load this same stylesheet but never set that attribute, and the platform's own cards are
   `.pf-card`, not `.cp-card`, so neither is touched. `.cp-ra` (Requests'/Alerts' AG Grid wrapper, #351/#361) is left
   out: its loading skeleton and the grid's own theme already match the plain `--card`/`--border` tokens, and giving
   it a different background would show a seam at the grid's edge. A stat tile (`.cp-stat`) and a nested row or panel
   inside a card (e.g. `.cp-saver-list`, a key's slide-open limits panel) never carried `.cp-card` to begin with, so
   they are unaffected without needing their own exception here. */
body[data-shell="admin"] .cp-card:not(.cp-ra) { background: var(--hx-c1); border: 1px solid var(--hx-ln); border-radius: 18px; }
:root[data-theme="light"] body[data-shell="admin"] .cp-card:not(.cp-ra) { box-shadow: inset 0 1px 0 rgba(255,255,255,.7), 0 6px 20px -8px rgba(31,29,26,.1); }
@media (prefers-color-scheme: light) { :root:not([data-theme="dark"]) body[data-shell="admin"] .cp-card:not(.cp-ra) { box-shadow: inset 0 1px 0 rgba(255,255,255,.7), 0 6px 20px -8px rgba(31,29,26,.1); } }
:root[data-theme="dark"] body[data-shell="admin"] .cp-card:not(.cp-ra) { background: linear-gradient(145deg, rgba(255,255,255,.06), rgba(255,255,255,.012)); border: 1px solid rgba(255,255,255,.08); border-top-color: rgba(255,255,255,.15); box-shadow: inset 0 1px 0 rgba(255,255,255,.06), 0 10px 30px rgba(0,0,0,.28); }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) body[data-shell="admin"] .cp-card:not(.cp-ra) { background: linear-gradient(145deg, rgba(255,255,255,.06), rgba(255,255,255,.012)); border: 1px solid rgba(255,255,255,.08); border-top-color: rgba(255,255,255,.15); box-shadow: inset 0 1px 0 rgba(255,255,255,.06), 0 10px 30px rgba(0,0,0,.28); } }

/* Shared pieces of the handoff's ui-kit. */
.hx-lbl { font-size: 11px; letter-spacing: .09em; text-transform: uppercase; color: var(--hx-mu); font-weight: 600; }
.hx-mut { color: var(--hx-mu); }
.hx-mono { font-family: ui-monospace, Menlo, monospace; }
/* `backwards`, not `both`: a fill that outlives the animation leaves a transform on the element, and a transformed
   ancestor traps the `position: fixed` row menus inside a card's overflow (#526). */
[data-region="page"][data-swapped] .hx-rise { animation: none; }
.hx-rise { animation: hxRise .6s cubic-bezier(.2,.8,.2,1) backwards; animation-delay: calc(var(--i, 0) * 70ms); }
@keyframes hxRise { from { opacity: 0; transform: translateY(14px); } }
.hx-pill { display: inline-flex; align-items: center; gap: 6px; padding: 4px 11px; border-radius: 99px; font-size: 12px; font-weight: 600; white-space: nowrap; background: color-mix(in srgb, var(--c) 15%, transparent); color: var(--c); }
.hx-pill u { width: 6px; height: 6px; border-radius: 50%; background: var(--c); }
.hx-ib { width: 38px; height: 38px; border-radius: 10px; border: 1px solid var(--hx-ib-ln); background: var(--hx-c1); color: var(--hx-tx); display: flex; align-items: center; justify-content: center; cursor: pointer; padding: 0; flex: none; text-decoration: none; transition: transform .25s cubic-bezier(.34,1.6,.5,1), border-color .2s, background .2s; }
.hx-ib:hover { border-color: var(--hx-ac); transform: translateY(-2px); color: var(--hx-tx); }
.hx-ib svg { width: 17px; height: 17px; }
.hx-ib .cp-icon { fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.hx-ib-pri, .hx-ib-pri:hover { background: var(--hx-pri-bg); color: var(--hx-pri-tx); border-color: var(--hx-pri-bg); }
.hx-in { background: var(--hx-in); border: 1px solid var(--hx-ib-ln); border-radius: 10px; color: var(--hx-tx); padding: 10px 12px; font: inherit; font-size: 14px; outline: 0; transition: border-color .2s, box-shadow .2s; }
.hx-in:focus { border-color: var(--hx-ac); box-shadow: 0 0 0 3px color-mix(in srgb, var(--hx-ac) 18%, transparent); }
.hx-in::placeholder { color: var(--hx-mu); }
.hx-ring { flex: none; overflow: visible; transform: rotate(-90deg); }
.hx-ring circle { fill: none; stroke-linecap: round; }
.hx-ring-tr { stroke: var(--hx-ring-tr); }
.hx-ring-pr { animation: hxRing 1.1s cubic-bezier(.2,.8,.2,1) both; }
@keyframes hxRing { from { stroke-dasharray: 0 999; } }
.hx-bar { height: 6px; border-radius: 9px; background: var(--hx-track); overflow: hidden; }
.hx-bar i { display: block; height: 100%; border-radius: 9px; background: var(--c); animation: hxGrow 1s cubic-bezier(.2,.8,.2,1) both; }
@keyframes hxGrow { from { width: 0; } }
.hx-chip { display: inline-block; padding: 2px 8px; border-radius: 6px; background: var(--hx-chip); font-size: 11px; font-weight: 600; color: var(--hx-chip-tx); white-space: nowrap; }
@media (prefers-reduced-motion: reduce) { .hx-rise, .hx-ring-pr, .hx-bar i { animation: none; } }

/* Accounts list (`Accounts List.html`). */
.hx-stats { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 14px; margin: 26px 0 22px; }
.hx-stat { padding: 16px 18px; position: relative; overflow: hidden; transition: transform .3s cubic-bezier(.34,1.6,.5,1); }
.hx-stat:hover { transform: translateY(-4px); }
.hx-stat b { display: block; font-size: 28px; font-weight: 700; margin: 8px 0 4px; letter-spacing: -.01em; font-variant-numeric: tabular-nums; color: var(--hx-tx); }
.hx-stat small { display: block; color: var(--hx-mu); font-size: 12px; line-height: 1.5; }
.hx-sk { position: absolute; right: 14px; bottom: 14px; display: flex; align-items: flex-end; gap: 3px; height: 34px; opacity: .55; }
.hx-sk i { width: 4px; border-radius: 2px; background: var(--hx-ac); }
.hx-stat-rg { position: absolute; right: 14px; top: 14px; }
:root[data-theme="light"] .hx-stat:hover { box-shadow: 0 14px 30px -10px rgba(31,29,26,.16), 0 3px 8px rgba(31,29,26,.06); border-color: #d9d2c3; }
@media (prefers-color-scheme: light) { :root:not([data-theme="dark"]) .hx-stat:hover { box-shadow: 0 14px 30px -10px rgba(31,29,26,.16), 0 3px 8px rgba(31,29,26,.06); border-color: #d9d2c3; } }
@media (max-width: 1100px) { .hx-stats { grid-template-columns: repeat(2, 1fr); } }
.hx-tb { display: flex; justify-content: space-between; align-items: center; gap: 12px; margin-bottom: 16px; }
.hx-tb-r { display: flex; gap: 8px; }
.hx-tb-r .cp-inline-form { display: flex; }
/* The search field every console list shares (Requests, Alerts, Accounts): a magnifier inside the input's left padding. Moved here from grids.css (#607) so a page without the grid bundle can use it. */
.cp-ra-search { position: relative; flex: 1 1 260px; min-width: 0; display: flex; align-items: center; }
.cp-ra-search .cp-icon { position: absolute; left: 12px; color: var(--text-3); pointer-events: none; }
.cp-ra-search input { width: 100%; font: inherit; font-size: 14px; padding: 9px 14px 9px 36px; border: 1px solid var(--border-btn); border-radius: 10px; background: var(--input-bg); color: var(--ink); outline: none; }
.cp-ra-search input:focus { border-color: var(--clay); }
.hx-tb .cp-ra-search { flex: 0 1 280px; }
@media (max-width: 640px) { .hx-tb:has(> .cp-ra-search) { flex-wrap: wrap; } .hx-tb > .cp-ra-search { flex-basis: 100%; } .hx-tb:has(> .cp-ra-search) .hx-tb-r { margin-left: auto; } }
.hx-empty-card { padding: 26px; text-align: center; color: var(--hx-mu); margin: 0 0 14px; }
.hx-grp { margin-bottom: 14px; overflow: hidden; }
.hx-gh { display: flex; align-items: center; gap: 14px; padding: 14px 18px; cursor: pointer; user-select: none; list-style: none; }
.hx-gh::-webkit-details-marker { display: none; }
.hx-gh:hover { background: rgba(255,255,255,.025); }
:root[data-theme="light"] .hx-gh:hover { background: #f4f1ea; }
@media (prefers-color-scheme: light) { :root:not([data-theme="dark"]) .hx-gh:hover { background: #f4f1ea; } }
.hx-gh:focus-visible { outline: 2px solid var(--hx-ac); outline-offset: -2px; border-radius: 18px; }
/* The provider's mark is bare, about 20px, in its brand colour: no tile behind it (#591). A raster mark such as Codex's
   takes `--mark-img-filter` from the `img.cp-mark-codex` rule so it stays visible in light mode (#583). */
.hx-lg { width: 20px; height: 20px; display: flex; align-items: center; justify-content: center; color: var(--c); flex: none; }
.hx-lg .cp-pv { display: contents; }
.hx-lg .cp-mark { width: 20px; height: 20px; color: var(--c); background: none; border: 0; box-shadow: none; padding: 0; }
.hx-gh-name { display: flex; align-items: baseline; gap: 12px; color: var(--hx-tx); }
.hx-gh-name b { letter-spacing: .06em; font-size: 14px; text-transform: uppercase; }
/* The provider card's summary: three stats spread evenly, each behind a thin divider (#591). They wrap under the name on a phone. */
.hx-gsum { display: flex; flex: 1; min-width: 0; justify-content: flex-end; }
.hx-gsum-i { display: flex; flex-direction: column; gap: 2px; flex: 1 1 0; max-width: 170px; padding: 0 18px; border-left: 1px solid var(--hx-ln2); min-width: 0; }
.hx-gsum-i:first-child { border-left: 0; }
.hx-gsum-i small { font-size: 10.5px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--hx-mu); white-space: nowrap; }
.hx-gsum-i b { font-size: 15px; font-weight: 700; font-variant-numeric: tabular-nums; color: var(--hx-tx); white-space: nowrap; }
@media (max-width: 720px) {
  .hx-gh { flex-wrap: wrap; row-gap: 10px; }
  .hx-gsum { order: 5; flex-basis: 100%; justify-content: stretch; }
  .hx-gsum-i { max-width: none; padding: 0 12px; }
  .hx-gsum-i:first-child { padding-left: 0; }
}
.hx-cv { width: 18px; height: 18px; color: var(--hx-mu); display: flex; transition: transform .35s cubic-bezier(.34,1.6,.5,1); }
.hx-cv svg { width: 18px; height: 18px; }
.hx-grp[open]:not([data-closing]) .hx-cv { transform: rotate(90deg); }
.hx-gb { display: grid; grid-template-rows: 1fr; transition: grid-template-rows .45s cubic-bezier(.2,.8,.2,1); }
.hx-grp[data-closing] > .hx-gb, .hx-grp:not([open]) > .hx-gb { grid-template-rows: 0fr; }
/* `overflow-y` stays hidden: an `overflow-x: auto` alone computes `overflow-y: auto` too, so while the band grows
   from 0fr its content overflows vertically and a scrollbar flashes in (dark in light mode, #532). */
.hx-sc { overflow: hidden; overflow-x: auto; overflow-y: hidden; min-height: 0; }
.hx-th, .hx-tr { display: grid; grid-template-columns: minmax(240px,1.6fr) minmax(210px,1.2fr) minmax(130px,.8fr) minmax(110px,.6fr) 118px; align-items: center; gap: 14px; padding: 0 18px; min-width: 860px; width: 100%; }
.hx-th { height: 38px; border-top: 1px solid var(--hx-ln2); background: var(--hx-head); }
.hx-th .hx-r { text-align: right; }
.hx-tr { padding-top: 13px; padding-bottom: 13px; border-top: 1px solid var(--hx-ln2); position: relative; cursor: grab; touch-action: pan-y; transition: background .2s; color: var(--hx-tx); }
.hx-tr::before { content: ""; position: absolute; left: 0; top: 10px; bottom: 10px; width: 3px; border-radius: 0 3px 3px 0; background: var(--c); transform: scaleY(0); transition: transform .3s cubic-bezier(.34,1.6,.5,1); z-index: 3; }
:root[data-theme="light"] .hx-tr::before { background: #1f1d1a; }
@media (prefers-color-scheme: light) { :root:not([data-theme="dark"]) .hx-tr::before { background: #1f1d1a; } }
.hx-tr:hover { background: var(--hx-hover); }
.hx-tr:hover::before { transform: scaleY(1); }
.hx-tr.is-drag { z-index: 5; cursor: grabbing; background: var(--hx-drag); box-shadow: 0 18px 40px rgba(0,0,0,.55), 0 0 0 1px rgba(232,116,59,.5); border-radius: 12px; will-change: transform; }
:root[data-theme="light"] .hx-tr.is-drag { box-shadow: 0 8px 24px rgba(31,29,26,.14), 0 0 0 1px #1f1d1a; }
@media (prefers-color-scheme: light) { :root:not([data-theme="dark"]) .hx-tr.is-drag { box-shadow: 0 8px 24px rgba(31,29,26,.14), 0 0 0 1px #1f1d1a; } }
.hx-tr.is-settle { transition: transform .35s cubic-bezier(.34,1.5,.5,1), box-shadow .3s; }
.hx-tr.is-go { background: color-mix(in srgb, var(--hx-ac) 12%, transparent); }
body.hx-dnd, body.hx-dnd * { user-select: none; cursor: grabbing !important; }
.hx-th > :first-child, .hx-tr > :first-child { position: sticky; left: 0; z-index: 2; align-self: stretch; margin-left: -18px; padding-left: 18px; background: var(--hx-sticky); transition: background .2s; }
.hx-th > :first-child { display: flex; align-items: center; background: var(--hx-sticky-head); }
.hx-tr > :first-child { margin-top: -13px; margin-bottom: -13px; padding-top: 13px; padding-bottom: 13px; }
.hx-tr:hover > :first-child { background: var(--hx-sticky-hover); }
.hx-tr.is-drag > :first-child { background: var(--hx-drag); }
.hx-id { display: flex; gap: 12px; align-items: center; min-width: 0; }
/* The status dot before the account's name (#591): green active, amber cooling down or token expiring, red needs re-auth or suspended, grey disabled. */
.hx-asd { width: 10px; height: 10px; border-radius: 50%; background: var(--c); flex: none; box-shadow: 0 0 0 3px color-mix(in srgb, var(--c) 18%, transparent); }
.hx-apl { display: block; margin-top: 4px; }
.hx-nm { min-width: 0; }
.hx-nm a { display: block; font-size: 14px; font-weight: 700; color: var(--hx-tx); text-decoration: none; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.hx-nm a:hover { color: var(--hx-tx); }
.hx-nm small { display: block; color: var(--hx-mu); font-size: 13px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.hx-chips { display: flex; gap: 4px; flex-wrap: wrap; margin-top: 4px; }
/* Quota: two thin stacked bars, `5h` and `Week`, each with its percentage and time left (#591). */
.hx-aq { display: flex; flex-direction: column; gap: 6px; min-width: 0; padding-right: 18px; }
.hx-aqr { display: grid; grid-template-columns: 34px minmax(40px,1fr) 38px 44px; align-items: center; gap: 8px; font-size: 12px; }
.hx-aqr .hx-bar { height: 4px; }
.hx-aql { color: var(--hx-mu); font-weight: 600; }
.hx-aqr b { text-align: right; font-weight: 700; font-variant-numeric: tabular-nums; }
.hx-aqr small { color: var(--hx-mu); font-size: 11.5px; font-variant-numeric: tabular-nums; white-space: nowrap; text-align: right; }
/* An Antigravity account's quota buckets (#745): the same rows, with room for `Gemini Week` in the name column. */
.hx-aq-multi .hx-aqr { grid-template-columns: 84px minmax(36px,1fr) 34px 40px; gap: 6px; }
.hx-aq-multi .hx-aql { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.hx-aqbal { grid-template-columns: auto 1fr; }
.hx-aqbal b { text-align: left; font-size: 14px; }
.hx-aqbal .hx-low { color: var(--hx-bad); }
/* Today: spend as the figure, requests and tokens muted under it. */
.hx-atd b { display: block; font-size: 14px; font-weight: 700; font-variant-numeric: tabular-nums; }
.hx-atd small { display: block; color: var(--hx-mu); font-size: 11.5px; white-space: nowrap; }
/* Token: text only. */
.hx-atk { font-size: 12.5px; font-weight: 600; color: var(--hx-mu); white-space: nowrap; }
.hx-atk.is-soon { color: var(--hx-ac); }
.hx-atk.is-expired { color: var(--hx-expired); }
.hx-act { display: flex; justify-content: flex-end; align-items: center; gap: 8px; }
/* The row's enable switch (#567): a pill whose knob slides, green while the account is not disabled. */
.hx-sw { width: 34px; height: 20px; border-radius: 999px; border: 1px solid var(--hx-ib-ln); background: var(--hx-off); position: relative; cursor: pointer; padding: 0; flex: none; transition: background .2s; }
.hx-sw i { position: absolute; top: 2px; left: 2px; width: 14px; height: 14px; border-radius: 50%; background: #fff; transition: transform .2s cubic-bezier(.34,1.6,.5,1); }
.hx-sw[aria-checked="true"] { background: var(--hx-ok); }
.hx-sw[aria-checked="true"] i { transform: translateX(14px); }
.hx-sw:disabled { opacity: .6; cursor: progress; }
.hx-sw:focus-visible, .hx-ib:focus-visible { outline: 2px solid var(--hx-ac); outline-offset: 2px; }
/* The row's refresh button is the menu button's size; its icon spins while the request runs (also the Refresh all button). */
.hx-ib-sm { width: 32px; height: 32px; }
.hx-ib[aria-busy] svg { animation: hxSpin .8s linear infinite; }
@keyframes hxSpin { to { transform: rotate(360deg); } }
@media (prefers-reduced-motion: reduce) { .hx-ib[aria-busy] svg { animation-duration: 2.4s; } }
/* The row whose menu is open stays marked, so it is clear which account the menu acts on. */
.hx-tr:has(.cp-menu[open]) { background: var(--hx-hover); }
.hx-tr:has(.cp-menu[open])::before { transform: scaleY(1); }
.hx-tr:has(.cp-menu[open]) > :first-child { background: var(--hx-sticky-hover); }
/* The note above the list while `?account=<id>` narrows it. */
.hx-only { margin-bottom: 14px; }
.hx-kb { width: 32px; height: 32px; list-style: none; }
.hx-kb::-webkit-details-marker { display: none; }
.hx-act .cp-menu[open] > .hx-kb { border-color: var(--hx-ac); }
/* An icon-only menu trigger (#628, the member page's header): the same <details> menu as the Accounts row's, with its
   entrance and placement, but no border and only a hover tint. */
.cp-menu-trigger.cp-ib-bare { border-color: transparent; background: transparent; }
.cp-menu-trigger.cp-ib-bare:hover, .cp-menu[open] > .cp-menu-trigger.cp-ib-bare { background: var(--border-3); }
/* The row menu as the handoff's `#mn`: a blurred card whose items nudge right on hover. */
.hx-act .cp-menu-list { min-width: 210px; width: auto; padding: 6px; border-radius: 14px; background: var(--hx-menu); backdrop-filter: blur(14px); border: 1px solid var(--hx-ib-ln); box-shadow: 0 24px 60px rgba(0,0,0,.6); animation: none; transform-origin: top right; }
/* The entrance (#604): with scripts, the list rests faded and nudged toward its trigger and admin.js puts `is-in` on the
   menu once it is placed; `data-side="up"` is the flipped menu, which slides up instead of down. No transform or
   colour here depends on the theme, so there is no twin to keep. Without scripts it simply shows. */
html.js .hx-act .cp-menu-list { opacity: 0; transform: translateY(-6px) scale(.97); pointer-events: none; transition: opacity 150ms ease, transform 150ms cubic-bezier(.2,.8,.2,1); }
html.js .hx-act .cp-menu[data-side="up"] .cp-menu-list { transform: translateY(6px) scale(.97); transform-origin: bottom right; }
html.js .hx-act .cp-menu.is-in .cp-menu-list { opacity: 1; transform: none; pointer-events: auto; }
@media (prefers-reduced-motion: reduce) { html.js .hx-act .cp-menu-list { transition: none; } }
:root[data-theme="light"] .hx-act .cp-menu-list { border-color: #e3ddd0; box-shadow: 0 12px 32px rgba(31,29,26,.14); backdrop-filter: none; }
@media (prefers-color-scheme: light) { :root:not([data-theme="dark"]) .hx-act .cp-menu-list { border-color: #e3ddd0; box-shadow: 0 12px 32px rgba(31,29,26,.14); backdrop-filter: none; } }
.hx-act .cp-btn-menu { padding: 9px 12px; border-radius: 9px; font-size: 13.5px; font-weight: 500; color: var(--hx-tx); transition: background .15s, transform .2s; }
.hx-act .cp-btn-menu:hover:not(:disabled) { background: rgba(255,255,255,.07); transform: translateX(3px); }
:root[data-theme="light"] .hx-act .cp-btn-menu:hover:not(:disabled) { background: #f4f1ea; box-shadow: 0 4px 10px rgba(31,29,26,.08); }
@media (prefers-color-scheme: light) { :root:not([data-theme="dark"]) .hx-act .cp-btn-menu:hover:not(:disabled) { background: #f4f1ea; box-shadow: 0 4px 10px rgba(31,29,26,.08); } }
.hx-act form[action$="/remove"] > .cp-btn-menu { color: var(--hx-bad); }
/* The handoff spaces its sections with their own margins, so its pages drop the console's 28px column gap. */
.cp-page:has(> .hx-stats) { gap: 0; }
.cp-page:has(> .hx-stats) > [data-pending-links] { margin-top: 14px; }
/* A disabled account is drawn at half strength, its menu excepted, so it still reads as something that can be acted on. */
.hx-tr[data-status="disabled"] > :not(.hx-act):not(:first-child), .hx-tr[data-status="disabled"] > :first-child > * { opacity: .5; }
/* Move up / Move down (#627): only a phone shows them; a wide screen drags the row instead. */
.hx-mv { display: none; }
/* Accounts on a phone (#627). The same markup as the wide table, laid out as a card per account with no sideways scroll:
   line 1 the dot, the name and the actions; line 2 the email with the abnormal pill; line 3 the quota; line 4 today and the
   token, muted. A swipe is a scroll here, so the row is not a drag handle (admin.js leaves it unbound) and the arrows
   reorder instead, in a column at the card's right edge while the provider's routing uses order. */
@media (max-width: 640px) {
  .hx-stats { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; margin: 16px 0 18px; }
  .hx-gh-name { flex-wrap: wrap; gap: 2px 10px; min-width: 0; }
  .hx-gsum-i small { letter-spacing: .04em; }
  /* The stats as a compact 2 x 2 (#768): the figure over its label, no hint or decoration; Live already says x / y, so Total goes. */
  .hx-stat { padding: 12px 14px; display: flex; flex-direction: column; }
  .hx-stat b { order: -1; margin: 0 0 2px; font-size: 20px; }
  .hx-stat .hx-lbl { letter-spacing: .04em; text-transform: none; font-size: 12px; }
  .hx-stat small, .hx-stat .hx-sk, .hx-stat .hx-stat-rg { display: none; }
  .hx-stat:has(> [data-stat="total"]) { display: none; }
  .hx-sc[data-account-sort], .hx-grp[open]:not([data-closing]) > .hx-gb .hx-sc[data-account-sort] { overflow-x: hidden; }
  .hx-sc > .hx-th { display: none; }
  .hx-tr { grid-template-columns: minmax(0, 1fr) auto; align-items: start; gap: 10px 12px; min-width: 0; padding: 14px 14px; cursor: auto; touch-action: auto; }
  .hx-tr > .hx-id, .hx-tr:hover > .hx-id, .hx-tr:has(.cp-menu[open]) > .hx-id, .hx-tr.is-drag > .hx-id { position: static; margin: 0; padding: 0; background: transparent; }
  .hx-id { grid-column: 1; grid-row: 1; align-items: flex-start; }
  .hx-asd { margin-top: 5px; }
  .hx-nm { display: flex; flex-wrap: wrap; align-items: center; gap: 2px 8px; }
  .hx-nm a { flex: 0 0 100%; }
  .hx-nm small { flex: 0 1 auto; min-width: 0; max-width: 100%; }
  .hx-apl, .hx-chips { flex: none; margin-top: 0; }
  .hx-act { grid-column: 2; grid-row: 1; gap: 6px; }
  .hx-aq { grid-column: 1 / -1; grid-row: 2; padding-right: 0; }
  .hx-atd { grid-column: 1; grid-row: 3; display: flex; align-items: baseline; gap: 8px; min-width: 0; color: var(--hx-mu); }
  .hx-atd b, .hx-atd small { display: inline; font-size: 12.5px; font-weight: 600; color: var(--hx-mu); }
  .hx-atd b:not(:only-child)::after { content: "·"; margin-left: 8px; }
  .hx-atk { grid-column: 2; grid-row: 3; justify-self: end; }
  .hx-mv { grid-column: 3; grid-row: 2 / 4; display: flex; flex-direction: column; justify-content: center; align-self: stretch; gap: 6px; }
  .hx-tr:has(> .hx-mv) { grid-template-columns: minmax(0, 1fr) auto 34px; }
  .hx-tr:has(> .hx-mv) .hx-act { grid-column: 2 / 4; }
  .hx-tr:has(> .hx-mv) .hx-aq { grid-column: 1 / 3; }
  .hx-mv .hx-ib-sm { width: 34px; }
  .hx-mv .hx-ib:disabled { opacity: .35; cursor: default; }
  .hx-mv .hx-ib:hover:not(:disabled) { transform: none; }
}
/* Accounts on a phone with scripts (#768): the provider cards give way to a 2-column grid of provider tiles, and a tile
   opens its card as a bottom sheet (admin.js `data-sheet-open`, which adds `is-sheet`). The sheet's rows keep only the
   dot, name, email, switch and menu; today and the token are on the account page, and Move up / Move down move
   into the menu (`.hx-mv-menu`). Without scripts, and on a wide screen, none of this shows and the cards stay. The sheet
   enters with a fill-backwards animation, so it carries no transform at rest that would capture the menu's fixed list. */
.hx-tb-h, .hx-pt, .hx-sheet-x, .hx-sheet-ft, .hx-mv-menu, .hx-aqring, .hx-grip { display: none; }
@media (max-width: 640px) {
  html.js .hx-tb-h { display: block; margin: 0; font-size: 17px; font-weight: 700; color: var(--hx-tx); }
  html.js .hx-tb > .cp-ra-search { display: none; }
  html.js .hx-tb { flex-wrap: nowrap; margin-bottom: 12px; }
  html.js .hx-pt { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; margin-bottom: 14px; }
  .hx-pti { display: flex; flex-direction: column; gap: 6px; min-width: 0; min-height: 104px; padding: 12px 12px 12px 14px; font: inherit; text-align: left; color: var(--hx-tx); text-decoration: none; cursor: pointer; transition: transform .2s, border-color .2s; }
  .hx-pti:active { transform: scale(.98); }
  .hx-pti:focus-visible { outline: 2px solid var(--hx-ac); outline-offset: 2px; }
  .hx-pti-top { display: flex; align-items: center; justify-content: space-between; }
  .hx-pti .hx-lg, .hx-pti .hx-lg .cp-mark { width: 26px; height: 26px; }
  .hx-pti .hx-cv { width: 24px; height: 24px; align-items: center; justify-content: center; border: 1px solid var(--hx-ib-ln); border-radius: 50%; }
  .hx-pti .hx-cv svg { width: 14px; height: 14px; }
  .hx-pti b { font-size: 15px; font-weight: 700; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
  .hx-pti-foot { display: flex; flex-direction: column; align-items: flex-start; gap: 6px; margin-top: auto; }
  .hx-pti small { display: flex; align-items: center; gap: 5px; min-width: 0; font-size: 11.5px; color: var(--hx-mu); white-space: nowrap; }
  /* One dot per account in its status colour (#776): the accounts are peers, so no signal levels. */
  .hx-tdots { order: -1; display: flex; flex-wrap: wrap; align-items: center; gap: 4px; }
  .hx-tdots i { width: 7px; height: 7px; border-radius: 50%; background: var(--c); }
  .hx-tdots em { font-style: normal; font-size: 10.5px; color: var(--hx-mu); margin-left: 1px; }
  .hx-pti-add { align-items: center; justify-content: center; gap: 8px; border-style: dashed; color: var(--hx-mu); font-size: 13.5px; font-weight: 600; }
  .hx-pti-add .cp-icon { width: 20px; height: 20px; }
  html.js .hx-grp { display: none; }
  html.js .hx-grp.is-sheet { display: flex; flex-direction: column; position: fixed; left: 0; right: 0; bottom: 0; z-index: 41; max-height: 84vh; margin: 0; border-radius: 22px 22px 0 0; border-bottom: 0; background-color: var(--hx-sticky); animation: hxSheet .3s cubic-bezier(.2,.8,.2,1) backwards; }
  /* Chrome wraps a <details>' content in ::details-content, which would keep the body and footer out of the sheet's flex
     column: the body then never scrolls and a short screen cuts the footer off (#772). */
  html.js .hx-grp.is-sheet::details-content { display: contents; }
  html.js .hx-grp.is-sheet::before { content: ""; flex: none; width: 40px; height: 4px; margin: 8px auto 0; border-radius: 4px; background: var(--hx-off); opacity: .5; }
  .hx-grp.is-sheet > .hx-gh { flex: none; padding: 12px 58px 12px 18px; cursor: default; }
  .hx-grp.is-sheet > .hx-gh:hover { background: transparent; }
  .hx-grp.is-sheet > .hx-gh .hx-cv { display: none; }
  .hx-grp.is-sheet > .hx-gh .hx-lg, .hx-grp.is-sheet > .hx-gh .hx-lg .cp-mark { width: 28px; height: 28px; }
  .hx-grp.is-sheet > .hx-sheet-x { display: flex; align-items: center; justify-content: center; position: absolute; top: 20px; right: 14px; width: 34px; height: 34px; padding: 0; border: 0; border-radius: 50%; background: transparent; color: var(--hx-mu); font-size: 24px; line-height: 1; cursor: pointer; }
  .hx-grp.is-sheet > .hx-sheet-x:hover { background: var(--hx-hover); color: var(--hx-tx); }
  .hx-grp.is-sheet > .hx-gb { display: block; flex: 1 1 auto; min-height: 0; overflow-y: auto; overscroll-behavior: contain; padding: 10px 12px 4px; }
  .hx-grp.is-sheet .hx-tr, .hx-grp.is-sheet .hx-tr:has(> .hx-mv) { grid-template-columns: 18px minmax(0, 160px) max-content minmax(0, 1fr) auto; align-items: center; column-gap: 8px; margin-bottom: 8px; padding: 12px 12px 12px 6px; border: 1px solid var(--hx-ln2); border-radius: 14px; overflow: hidden; }
  .hx-grp.is-sheet .hx-tr > .hx-id { grid-column: 2; grid-row: 1; }
  .hx-grp.is-sheet .hx-tr .hx-act { grid-column: 5; grid-row: 1; }
  /* The drag handle (#776): only it starts a drag on a phone (admin.js), so a swipe elsewhere still scrolls the sheet. */
  .hx-grp.is-sheet .hx-grip { grid-column: 1; grid-row: 1 / 3; align-self: stretch; display: flex; align-items: center; justify-content: center; color: var(--hx-mu); cursor: grab; touch-action: none; opacity: .7; }
  .hx-grp.is-sheet .hx-grip svg { width: 16px; height: 16px; }
  .hx-grp.is-sheet .hx-tr.is-drag .hx-grip { cursor: grabbing; color: var(--hx-ac); opacity: 1; }
  .hx-grp.is-sheet .hx-id { align-items: center; }
  .hx-grp.is-sheet .hx-asd { margin-top: 0; }
  .hx-grp.is-sheet .hx-atd, .hx-grp.is-sheet .hx-atk, .hx-grp.is-sheet .hx-mv, .hx-grp.is-sheet .hx-chips, .hx-grp.is-sheet .hx-apl, .hx-grp.is-sheet .hx-act > .cp-inline-form:not([data-account-toggle]) { display: none; }
  /* The quota at a glance (#774): the windows under the name, each its name, a thin bar, the percentage and the time
     left; a key shows its wallet. The status is the dot alone, so the pill is dropped above. */
  /* The two windows as thin progress bars (#781), the window's name, the bar, the percentage and the time left to the
     reset side by side, under the name. The ring it replaces hid the time left, which a phone cannot read from a tooltip.
     An Antigravity account's several buckets and a key's wallet wrap the same way, a little narrower. */
  .hx-grp.is-sheet .hx-aq { grid-column: 3; grid-row: 1; display: flex; flex-direction: column; gap: 4px; padding: 0; }
  .hx-grp.is-sheet .hx-aq:has(> .hx-aqbal) { grid-column: 2 / -1; grid-row: 2; gap: 6px 10px; margin-top: 6px; padding-left: 22px; }
  .hx-grp.is-sheet .hx-aqr, .hx-grp.is-sheet .hx-aq-multi .hx-aqr { display: grid; grid-template-columns: 30px minmax(36px, 1fr) 34px 40px; gap: 6px; align-items: center; }
  .hx-grp.is-sheet .hx-aqr > .hx-bar { display: block; height: 4px; }
  .hx-grp.is-sheet .hx-aqr > b { font-size: 10.5px; }
  .hx-grp.is-sheet .hx-aqr > small { display: block; font-size: 10px; }
  .hx-grp.is-sheet .hx-aqr > .hx-aql { font-size: 10px; line-height: 1.1; text-align: left; }
  .hx-grp.is-sheet .hx-aqbal { display: flex; gap: 8px; align-items: baseline; }
  .hx-grp.is-sheet .hx-aqbal > b { font-size: 13px; letter-spacing: 0; }
  .hx-grp.is-sheet .hx-aqbal > .hx-aql { max-width: none; font-size: 12px; }
  .hx-grp.is-sheet .hx-mv-menu { display: contents; }
  .hx-grp.is-sheet > .hx-sheet-ft { display: flex; flex: none; gap: 10px; padding: 12px 16px calc(14px + env(safe-area-inset-bottom)); border-top: 1px solid var(--hx-ln2); }
  .hx-sheet-ft > .hx-bn { flex: 1; justify-content: center; padding: 11px 14px; }
  .hx-sheet-ft > .hx-ib, .hx-sheet-ft > .cp-inline-form > .hx-ib { width: 44px; height: 44px; }
  .hx-sheet-ft > .cp-inline-form { display: flex; }
  .hx-sheet-bd { position: fixed; inset: 0; z-index: 40; background: var(--overlay); backdrop-filter: blur(3px); -webkit-backdrop-filter: blur(3px); animation: cpFade .2s ease-out; }
  html.hx-sheet-lock, html.hx-sheet-lock body { overflow: hidden; }
}
/* A very narrow phone gives the name more room: narrower bars (#778), and the time left moves under its bar (#781). */
@media (max-width: 400px) { .hx-grp.is-sheet .hx-aq-multi { max-width: 86px; } }
@media (max-width: 360px) { .hx-grp.is-sheet .hx-aqr { grid-template-columns: 26px minmax(28px, 1fr) 30px; } .hx-grp.is-sheet .hx-aqr > small { grid-column: 2 / -1; justify-self: end; } }
@keyframes hxSheet { from { transform: translateY(100%); } }
/* A sheet put back after a region swap (#772) is already on screen, so it does not slide in again. */
html.js .hx-grp.is-sheet.is-instant { animation: none; }
@media (prefers-reduced-motion: reduce) { html.js .hx-grp.is-sheet { animation: none; } }
/* The sidebar's nav as the handoff draws it: a stroked icon before each label, the icon taking the accent on hover and
   on the current page, and the hover nudging the entry right. */
.cp-nav-item { justify-content: flex-start; gap: 11px; border-radius: 9px; color: var(--ink); transition: background .2s, padding .2s; }
.cp-nav-item:hover { color: var(--ink); padding-left: 16px; }
.cp-nav-item.is-active { background: var(--track); font-weight: 700; }
.cp-nav-label { flex: 1; }
.cp-nav-count { font-size: 11px; font-weight: 500; color: var(--hx-mu); margin-left: auto; }
.cp-nav-icon { width: 17px; height: 17px; flex: none; fill: none; stroke: currentColor; stroke-width: 1.9; stroke-linecap: round; stroke-linejoin: round; color: var(--hx-mu); transition: color .2s; }
.cp-nav-item:hover .cp-nav-icon, .cp-nav-item.is-active .cp-nav-icon { color: var(--hx-ac); }
:root[data-theme="light"] .cp-nav-item:hover { background: rgba(31,29,26,.05); }
@media (prefers-color-scheme: light) { :root:not([data-theme="dark"]) .cp-nav-item:hover { background: rgba(31,29,26,.05); } }
:root[data-theme="light"] .cp-nav-item.is-active { background: #fffdf9; box-shadow: 0 0 0 1px #e6e0d3; }
@media (prefers-color-scheme: light) { :root:not([data-theme="dark"]) .cp-nav-item.is-active { background: #fffdf9; box-shadow: 0 0 0 1px #e6e0d3; } }

/* Account detail (`Account Detail.html`). */
.cp-page:has(> .hx-top) { gap: 0; }
.hx-back { font-weight: 600; color: var(--hx-tx2); text-decoration: none; align-self: flex-start; }
.hx-back:hover { color: var(--hx-ac); }
.hx-top { display: flex; justify-content: space-between; align-items: flex-end; gap: 20px; margin: 18px 0 22px; flex-wrap: wrap; }
.hx-top-l { min-width: 0; }
.hx-nmw { position: relative; display: inline-flex; align-items: center; gap: 12px; cursor: text; max-width: 100%; }
.hx-ti { font: 400 56px/1.05 var(--serif); margin: 0; min-width: 120px; max-width: 100%; field-sizing: content; color: var(--hx-tx); background: transparent; border: 0; border-bottom: 2px dashed transparent; outline: 0; padding: 0 0 2px; letter-spacing: -.01em; transition: border-color .25s; }
.hx-nmw:hover .hx-ti { border-bottom-color: var(--hx-ib-ln); }
.hx-ti:focus { border-bottom-color: var(--hx-ac); }
.hx-nmw svg { width: 20px; height: 20px; color: var(--hx-mu2); opacity: 0; transition: opacity .25s; flex: none; }
.hx-nmw:hover svg, .hx-ti:focus + svg { opacity: 1; }
.hx-bd { display: flex; gap: 8px; align-items: center; margin-top: 12px; flex-wrap: wrap; }
.hx-sep { width: 1px; height: 20px; background: var(--hx-ib-ln); margin: 0 4px; }
.hx-ow { position: relative; display: inline-flex; align-items: center; gap: 9px; height: 36px; padding: 0 12px; border-radius: 10px; background: var(--hx-in); border: 1px solid var(--hx-ib-ln); color: var(--hx-mu); cursor: text; transition: border-color .2s, box-shadow .2s; }
.hx-ow:hover { border-color: #5a5046; }
.hx-ow:focus-within { border-color: var(--hx-tx2); box-shadow: 0 0 0 4px rgba(241,233,220,.07); color: var(--hx-tx); }
.hx-ow input { width: 220px; background: transparent; border: 0; outline: 0; color: var(--hx-tx); font: 500 13.5px var(--sans); padding: 0; }
.hx-ow input::placeholder { color: var(--hx-off); }
.hx-ow-mi { width: 15px; height: 15px; flex: none; }
.hx-ow-ck { width: 0; height: 14px; color: var(--hx-tx); opacity: 0; transition: all .25s; flex: none; }
.hx-ow:has(input:valid:not(:placeholder-shown)) .hx-ow-ck { width: 14px; opacity: 1; }
.hx-seg { position: relative; display: inline-flex; padding: 3px; border-radius: 99px; background: var(--hx-in); border: 1px solid var(--hx-ln); }
.hx-seg label { position: relative; z-index: 1; cursor: pointer; }
.hx-seg input { position: absolute; opacity: 0; pointer-events: none; }
.hx-seg b { display: block; padding: 3px 12px; font-size: 12px; color: var(--hx-mu); transition: color .25s; }
.hx-seg label:has(input:checked) b { color: var(--hx-pri-tx); }
.hx-seg label:has(input:focus-visible) b { outline: 2px solid var(--hx-ac); border-radius: 99px; }
.hx-seg i { position: absolute; top: 3px; bottom: 3px; left: 3px; width: calc(50% - 3px); border-radius: 99px; background: var(--hx-pri-bg); transition: transform .35s cubic-bezier(.34,1.6,.5,1); }
.hx-seg:has(label:nth-of-type(2) input:checked) i { transform: translateX(100%); }
.hx-acts { display: flex; gap: 8px; }
.hx-acts .cp-inline-form { display: flex; }
.hx-ib:disabled { opacity: .4; cursor: not-allowed; transform: none; }
.hx-ts { display: flex; gap: 28px; margin-bottom: 22px; flex-wrap: wrap; }
.hx-ts div { display: flex; flex-direction: column; gap: 2px; }
.hx-ts b { font: 400 30px var(--serif); font-variant-numeric: tabular-nums; color: var(--hx-tx); }
.hx-ts small { color: var(--hx-mu); font-size: 11px; letter-spacing: .08em; text-transform: uppercase; font-weight: 600; }
.hx-note { margin: -10px 0 22px; display: flex; flex-wrap: wrap; gap: 18px; color: var(--hx-bad); font-size: 13px; }
.hx-deck { display: grid; grid-template-columns: minmax(0,1.5fr) minmax(280px,1fr); gap: 16px; margin-bottom: 30px; }
.hx-deck-one { grid-template-columns: minmax(0,1fr); }
.hx-card { padding: 26px; }
.hx-card h2, .hx-qc h2, .hx-td h2 { font: 400 26px var(--serif); margin: 0; color: var(--hx-tx); }
.hx-ch2 { display: flex; justify-content: space-between; align-items: flex-start; gap: 14px; margin-bottom: 6px; }
.hx-sub { color: var(--hx-mu); margin: 4px 0 0; font-size: 13px; line-height: 1.45; }
.hx-gs { margin-top: 26px; }
.hx-gs-row { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; margin-bottom: 10px; }
.hx-gs-row b { font-size: 15px; color: var(--hx-tx); }
.hx-gs-row span { color: var(--hx-mu); font-size: 12.5px; text-align: right; }
.hx-bal-amount { display: block; font: 400 30px var(--serif); color: var(--hx-tx); margin-bottom: 4px; }
.hx-bal-amount.hx-low { color: var(--hx-bad); }
.hx-bal-block > .hx-mut, .hx-empty { font-size: 13px; }
.hx-trk { position: relative; height: 46px; border-radius: 14px; background: var(--hx-in); border: 1px solid var(--hx-ln); user-select: none; }
.hx-trk .hx-fl { position: absolute; left: 0; top: 0; bottom: 0; width: var(--used); border-radius: 13px 0 0 13px; background: linear-gradient(90deg, color-mix(in srgb, var(--c) 30%, transparent), color-mix(in srgb, var(--c) 70%, transparent)); border-right: 2px solid var(--c); animation: hxGrow 1s cubic-bezier(.2,.8,.2,1) both; }
.hx-trk .hx-zn { position: absolute; top: 0; bottom: 0; right: 0; width: calc(100% - var(--cap)); border-radius: 0 13px 13px 0; background: repeating-linear-gradient(135deg, rgba(255,255,255,.05) 0 6px, transparent 6px 12px); }
:root[data-theme="light"] .hx-trk .hx-zn { background: repeating-linear-gradient(135deg, rgba(31,29,26,.05) 0 6px, transparent 6px 12px); }
@media (prefers-color-scheme: light) { :root:not([data-theme="dark"]) .hx-trk .hx-zn { background: repeating-linear-gradient(135deg, rgba(31,29,26,.05) 0 6px, transparent 6px 12px); } }
.hx-trk .hx-ut { position: absolute; left: 14px; top: 50%; transform: translateY(-50%); font: 700 13px ui-monospace, Menlo, monospace; color: #fff; text-shadow: 0 1px 3px rgba(0,0,0,.6); pointer-events: none; }
:root[data-theme="light"] .hx-trk .hx-ut { color: #1f1d1a; text-shadow: none; }
@media (prefers-color-scheme: light) { :root:not([data-theme="dark"]) .hx-trk .hx-ut { color: #1f1d1a; text-shadow: none; } }
.hx-trk .hx-hd { position: absolute; top: -8px; bottom: -8px; left: var(--cap); width: 3px; margin-left: -1.5px; background: var(--hx-tok); border-radius: 3px; box-shadow: 0 0 14px rgba(241,233,220,.5); pointer-events: none; }
.hx-trk .hx-hd::before { content: attr(data-l); position: absolute; bottom: calc(100% + 6px); left: 50%; transform: translateX(-50%); white-space: nowrap; background: var(--hx-tok); color: var(--hx-pri-tx); font: 700 11px var(--sans); padding: 3px 8px; border-radius: 7px; }
.hx-trk .hx-hd::after { content: ""; position: absolute; top: 50%; left: 50%; width: 18px; height: 18px; margin: -9px; border-radius: 50%; background: var(--hx-tok); border: 3px solid var(--hx-bg); box-shadow: 0 2px 8px rgba(0,0,0,.6); transition: transform .25s cubic-bezier(.34,1.8,.5,1); }
.hx-trk:hover .hx-hd::after, .hx-trk:active .hx-hd::after { transform: scale(1.25); }
.hx-trk[data-cap-behind] .hx-hd, .hx-trk[data-cap-behind] .hx-hd::before, .hx-trk[data-cap-behind] .hx-hd::after { background: var(--hx-ac); }
.hx-trk[data-cap-behind] .hx-hd::before { color: #fff; }
.hx-trk:has(.hx-trk-in:focus-visible) { box-shadow: 0 0 0 3px color-mix(in srgb, var(--hx-ac) 30%, transparent); }
/* The range is the real control: laid over the whole track, invisible, so a press anywhere sets the cap there. */
.hx-trk-in { position: absolute; inset: 0; width: 100%; height: 100%; margin: 0; opacity: 0; cursor: ew-resize; touch-action: none; }
.hx-tgw { position: relative; display: inline-flex; flex: none; cursor: pointer; }
.hx-tgw input { position: absolute; opacity: 0; width: 100%; height: 100%; margin: 0; cursor: pointer; }
.hx-tg { width: 42px; height: 24px; border-radius: 99px; background: var(--hx-ib-ln); position: relative; transition: background .25s; }
.hx-tg::after { content: ""; position: absolute; left: 3px; top: 3px; width: 18px; height: 18px; border-radius: 50%; background: var(--hx-tx); transition: transform .3s cubic-bezier(.34,1.6,.5,1); }
.hx-tgw input:checked + .hx-tg { background: var(--hx-ac); }
.hx-tgw input:checked + .hx-tg::after { transform: translateX(18px); }
.hx-tgw input:focus-visible + .hx-tg { outline: 2px solid var(--hx-ac); outline-offset: 2px; }
:root[data-theme="light"] .hx-tg::after { background: #fff; }
@media (prefers-color-scheme: light) { :root:not([data-theme="dark"]) .hx-tg::after { background: #fff; } }
:root[data-theme="light"] .hx-tgw input:checked + .hx-tg { background: #1f1d1a; }
@media (prefers-color-scheme: light) { :root:not([data-theme="dark"]) .hx-tgw input:checked + .hx-tg { background: #1f1d1a; } }
.hx-dial { display: flex; flex-direction: column; align-items: center; gap: 14px; margin-top: 14px; }
.hx-dial svg { width: 100%; max-width: 250px; cursor: copy; overflow: visible; }
.hx-dial-tr { stroke: var(--hx-ln2); }
.hx-dial-h { fill: var(--hx-mu2); font: 10px var(--sans); }
.hx-dial-t { fill: #f1d6c6; font: 600 11px ui-monospace, monospace; }
:root[data-theme="light"] .hx-dial-t { fill: #7a3a1a; }
@media (prefers-color-scheme: light) { :root:not([data-theme="dark"]) .hx-dial-t { fill: #7a3a1a; } }
.hx-dial-n { fill: var(--hx-tx); font: 34px var(--serif); }
.hx-dial-of { fill: var(--hx-mu); font: 11px var(--sans); }
.hx-mk { fill: var(--hx-ac); stroke: var(--hx-bg); stroke-width: 3; cursor: pointer; transition: r .2s; }
.hx-mk:hover { r: 11px; fill: #f39a6b; }
:root[data-theme="light"] .hx-mk { fill: #1f1d1a; stroke: #fffdf9; }
@media (prefers-color-scheme: light) { :root:not([data-theme="dark"]) .hx-mk { fill: #1f1d1a; stroke: #fffdf9; } }
.hx-dc { text-align: center; color: var(--hx-mu); font-size: 12px; }
.hx-wu { position: relative; overflow: hidden; display: flex; align-items: center; gap: 10px; padding: 13px 26px 13px 16px; border: 0; border-radius: 99px; color: #fff; font: 700 14px var(--sans); cursor: pointer; background: linear-gradient(120deg, #f08a52, #d9552b 55%, #f08a52); background-size: 200% 100%; box-shadow: 0 0 0 1px rgba(255,255,255,.25) inset, 0 8px 24px -4px rgba(232,116,59,.6); transition: transform .35s cubic-bezier(.34,1.8,.5,1), box-shadow .3s, background-position .8s; }
.hx-wu:hover { transform: translateY(-3px) scale(1.04); background-position: 100% 0; box-shadow: 0 0 0 1px rgba(255,255,255,.35) inset, 0 14px 34px -4px rgba(240,138,82,.85); }
.hx-wu:active { transform: scale(.95); }
.hx-wu::before { content: ""; position: absolute; inset: 0; background: linear-gradient(105deg, transparent 35%, rgba(255,255,255,.45) 50%, transparent 65%); transform: translateX(-120%); animation: hxSweep 3.2s ease-in-out infinite; }
@keyframes hxSweep { 0%, 55% { transform: translateX(-120%); } 100% { transform: translateX(120%); } }
.hx-wi { width: 28px; height: 28px; border-radius: 50%; background: rgba(0,0,0,.22); display: flex; align-items: center; justify-content: center; animation: hxFlame 1.6s ease-in-out infinite; }
.hx-wi svg { width: 16px; height: 16px; }
@keyframes hxFlame { 0%, 100% { transform: scale(1) rotate(-4deg); } 50% { transform: scale(1.18) rotate(4deg); } }
:root[data-theme="light"] .hx-wu { box-shadow: 0 8px 20px -6px rgba(31,29,26,.3); background: #1f1d1a; }
@media (prefers-color-scheme: light) { :root:not([data-theme="dark"]) .hx-wu { box-shadow: 0 8px 20px -6px rgba(31,29,26,.3); background: #1f1d1a; } }
:root[data-theme="light"] .hx-wu::before { opacity: .25; }
@media (prefers-color-scheme: light) { :root:not([data-theme="dark"]) .hx-wu::before { opacity: .25; } }
.hx-wu-rows { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 16px; }
html.js .hx-wu-rows { display: none; }
.hx-wu-row { display: flex; align-items: center; gap: 8px; }
.hx-x { width: 26px; height: 26px; border-radius: 50%; border: 0; background: transparent; color: var(--hx-mu); cursor: pointer; font: inherit; }
.hx-x:hover { color: var(--hx-bad); background: color-mix(in srgb, var(--hx-bad) 12%, transparent); }
.hx-btn { background: var(--hx-in); border: 1px solid var(--hx-ib-ln); color: var(--hx-tx); border-radius: 10px; padding: 9px 14px; font: 600 13px var(--sans); cursor: pointer; transition: border-color .2s, transform .2s; }
.hx-btn:hover { border-color: var(--hx-ac); transform: translateY(-2px); }
.hx-btn:disabled { opacity: .4; pointer-events: none; }
.hx-btn-pri { background: var(--hx-pri-bg); color: var(--hx-pri-tx); border-color: var(--hx-pri-bg); }
.hx-btn-pri:hover { background: #fff; border-color: #fff; }
:root[data-theme="light"] .hx-btn-pri:hover { background: #35312b; border-color: #35312b; }
@media (prefers-color-scheme: light) { :root:not([data-theme="dark"]) .hx-btn-pri:hover { background: #35312b; border-color: #35312b; } }
.hx-qc { padding: 24px 26px; margin-bottom: 26px; }
.hx-qh2 { display: flex; justify-content: space-between; align-items: flex-start; gap: 16px; flex-wrap: wrap; }
.hx-qa { display: flex; gap: 8px; flex-wrap: wrap; }
.hx-stp { position: relative; display: grid; grid-template-columns: repeat(4, 1fr); margin-top: 26px; }
.hx-stp-ln { position: absolute; left: 12.5%; right: 12.5%; top: 13px; height: 2px; background: var(--hx-ln); border-radius: 2px; overflow: hidden; }
.hx-stp-ln i { display: block; height: 100%; width: var(--done); background: var(--hx-tx); animation: hxGrow 1s cubic-bezier(.2,.8,.2,1) both; }
.hx-sp { position: relative; display: flex; flex-direction: column; align-items: center; text-align: center; gap: 8px; }
.hx-sp-d { width: 28px; height: 28px; border-radius: 50%; background: var(--hx-bg); border: 2px solid var(--hx-ib-ln); display: flex; align-items: center; justify-content: center; color: var(--hx-bg); z-index: 1; }
.hx-sp-d svg { width: 14px; height: 14px; }
.hx-sp.is-done .hx-sp-d { background: var(--hx-tx); border-color: var(--hx-tx); }
.hx-sp.is-cur .hx-sp-d { border-color: var(--hx-wn); animation: hxPulse 1.8s infinite; }
.hx-sp.is-cur .hx-sp-d::after { content: ""; width: 8px; height: 8px; border-radius: 50%; background: var(--hx-wn); }
@keyframes hxPulse { 0% { box-shadow: 0 0 0 0 rgba(232,176,75,.55); } 70%, 100% { box-shadow: 0 0 0 9px transparent; } }
.hx-sp b { font-size: 13px; color: var(--hx-tx); }
.hx-sp small { font-size: 11.5px; color: var(--hx-mu); min-height: 15px; }
.hx-sp:not(.is-done):not(.is-cur) b { color: var(--hx-mu2); }
.hx-sp.is-cur small { color: var(--hx-wn); }
.hx-qhist { display: grid; grid-template-rows: 0fr; transition: grid-template-rows .45s cubic-bezier(.2,.8,.2,1); }
.hx-qhist.is-on, html:not(.js) .hx-qhist { grid-template-rows: 1fr; }
.hx-qhist > div { overflow: hidden; min-height: 0; }
.hx-ql { margin-top: 22px; padding-top: 18px; border-top: 1px solid var(--hx-ln2); }
.hx-ql:empty { display: none; }
.hx-hi { position: relative; display: grid; grid-template-columns: 18px 1fr auto; gap: 12px; padding-bottom: 16px; }
.hx-hi::before { content: ""; position: absolute; left: 4px; top: 14px; bottom: -2px; width: 1px; background: var(--hx-ib-ln); }
.hx-hi:last-child::before { display: none; }
.hx-hi > i { width: 9px; height: 9px; border-radius: 50%; margin-top: 5px; background: var(--c); }
.hx-hi b { font-size: 13px; display: block; color: var(--hx-tx); }
.hx-hi small { font-size: 12px; color: var(--hx-mu); }
.hx-hi em { font: 600 11px var(--sans); font-style: normal; color: var(--c); text-transform: uppercase; letter-spacing: .08em; margin-top: 3px; }
.hx-up { margin-bottom: 26px; }
.hx-up-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; margin: 20px 0 16px; }
.hx-fld { display: grid; gap: 7px; font-size: 12px; letter-spacing: .06em; text-transform: uppercase; color: var(--hx-mu); font-weight: 600; }
.hx-fld .hx-in, .hx-fld .hx-mut { text-transform: none; letter-spacing: 0; font-weight: 500; }
.hx-fld .hx-in { font-size: 14px; color: var(--hx-tx); width: 100%; }
.hx-tabs { display: flex; gap: 6px; border-bottom: 1px solid var(--hx-ln2); margin-bottom: 18px; }
.hx-tab { padding: 12px 18px; cursor: pointer; color: var(--hx-mu); font: 600 14px var(--sans); position: relative; background: none; border: 0; transition: color .2s; }
.hx-tab:hover, .hx-tab.is-on, .hx-tab[aria-selected="true"] { color: var(--hx-tx); }
.hx-tab.is-on::after, .hx-tab[aria-selected="true"]::after { content: ""; position: absolute; left: 12px; right: 12px; bottom: -1px; height: 2px; border-radius: 2px; background: var(--hx-ac); }
:root[data-theme="light"] .hx-tab.is-on::after { background: #1f1d1a; }
:root[data-theme="light"] .hx-tab[aria-selected="true"]::after { background: #1f1d1a; }
@media (prefers-color-scheme: light) { :root:not([data-theme="dark"]) .hx-tab.is-on::after { background: #1f1d1a; } }
@media (prefers-color-scheme: light) { :root:not([data-theme="dark"]) .hx-tab[aria-selected="true"]::after { background: #1f1d1a; } }
.hx-tab small { margin-left: 6px; color: var(--hx-mu2); font-weight: 500; }
.hx-pn:not([hidden]) { display: block; animation: hxRise .45s both; }
.hx-mems { overflow: hidden; }
.hx-mem { display: grid; grid-template-columns: minmax(150px,1fr) 2fr 2fr; gap: 24px; padding: 20px 24px; align-items: center; }
.hx-mem-one { grid-template-columns: 1fr; }
.hx-mem + .hx-mem { border-top: 1px solid var(--hx-ln2); }
.hx-mem b { color: var(--hx-tx); }
.hx-mem .hx-mut { margin-top: 3px; }
.hx-bar-10 { height: 10px; margin: 6px 0 4px; }
.hx-mem-note { margin: 14px 4px 0; }
.hx-empty { padding: 26px; text-align: center; color: var(--hx-mu); }
.hx-rq { overflow: hidden; }
.hx-rq .cp-table-scroll { overflow-x: auto; }
.hx-rq .cp-table { border: 0; }
.hx-rq .cp-th { background: rgba(0,0,0,.2); }
.hx-rq .cp-tr:not(.cp-th) { border-top: 1px solid var(--hx-ln2); }
.hx-rq .cp-tr:not(.cp-th):hover { background: var(--hx-hover); }
.hx-rq .cp-pager { padding: 14px 18px; border-top: 1px solid var(--hx-ln2); color: var(--hx-mu); }
.hx-rq .cp-pager-size[aria-current] { background: var(--hx-chip); font-weight: 700; }
.hx-td { margin-top: 48px; border: 1px solid rgba(239,125,94,.28); border-radius: 20px; padding: 26px; background: linear-gradient(180deg, rgba(239,125,94,.06), transparent 60%); }
:root[data-theme="light"] .hx-td { background: #fffdf9; border-color: #ecc9bd; }
@media (prefers-color-scheme: light) { :root:not([data-theme="dark"]) .hx-td { background: #fffdf9; border-color: #ecc9bd; } }
.hx-tdh .hx-lbl { color: var(--hx-bad); }
.hx-tdh h2 { margin-top: 6px; }
.hx-tdb { position: relative; display: grid; grid-template-columns: minmax(0,1fr) auto; gap: 32px; align-items: center; margin-top: 22px; }
.hx-tc { display: grid; grid-template-columns: minmax(220px,300px) minmax(0,1fr); gap: 28px; align-items: center; }
.hx-tcard { position: relative; display: flex; align-items: center; gap: 14px; padding: 16px; border-radius: 14px; border: 1px solid var(--hx-ib-ln); background: var(--hx-in); transition: opacity .5s, filter .5s, transform .05s; }
.hx-tcard { box-shadow: 0 0 calc(var(--cp-hold, 0) * 40px) calc(var(--cp-hold, 0) * 4px) rgba(239,125,94,.35); }
.hx-tcard[data-gone] { opacity: 0; filter: blur(8px); transform: scale(.92) !important; transition: opacity .7s .1s, filter .7s .1s, transform .7s; }
.hx-tl li[data-kept] > i { background: color-mix(in srgb, var(--hx-ok) 18%, transparent); }
.hx-tav { width: 42px; height: 42px; border-radius: 12px; background: var(--hx-tx); color: var(--hx-bg); font: 700 16px var(--sans); display: flex; align-items: center; justify-content: center; flex: none; }
.hx-tin { min-width: 0; }
.hx-tin b { display: block; font-size: 14.5px; color: var(--hx-tx); overflow: hidden; text-overflow: ellipsis; }
.hx-tin small { font-size: 12.5px; color: var(--hx-mu); }
.hx-tl { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.hx-tl li { display: flex; align-items: center; gap: 12px; font-size: 13.5px; color: var(--hx-tx); transition: color .3s; }
.hx-tl li > i { width: 20px; height: 20px; border-radius: 50%; border: 1.5px solid var(--hx-ib-ln); display: flex; align-items: center; justify-content: center; flex: none; color: transparent; transition: all .3s cubic-bezier(.34,1.8,.5,1); }
.hx-tl li > i svg { width: 11px; height: 11px; }
.hx-tl li[data-struck] { color: var(--hx-mu); }
.hx-tl li[data-struck] span { text-decoration: line-through; text-decoration-color: var(--hx-bad); }
.hx-tl li[data-struck] > i { background: var(--hx-bad); border-color: var(--hx-bad); color: var(--hx-bg); }
.hx-tl li.hx-keep > i { border-color: #4a6b4d; color: var(--hx-ok); }
:root[data-theme="light"] .hx-tl li.hx-keep > i { border-color: #9bc6a2; }
@media (prefers-color-scheme: light) { :root:not([data-theme="dark"]) .hx-tl li.hx-keep > i { border-color: #9bc6a2; } }
.hx-rm { box-shadow: 0 0 calc(var(--cp-hold, 0) * 38px) calc(var(--cp-hold, 0) * 3px) color-mix(in srgb, var(--hx-bad) 22%, transparent); }
.hx-td .cp-hold-wrap { display: flex; flex-direction: column; align-items: center; gap: 12px; text-align: center; }
.hx-td .cp-hold-hint { font-size: 12px; color: var(--hx-mu); line-height: 1.5; max-width: 190px; }
.hx-td .cp-undo { grid-column: 1 / -1; }
.hx-td:has(.cp-undo[data-on]) .cp-hold-wrap { display: none; }
.hx-td .cp-undo-btn { background: var(--hx-pri-bg); color: var(--hx-pri-tx); }
.hx-td .cp-undo-bar i { background: var(--hx-bad); }
.hx-noscript-save { margin-top: 18px; }
@media (max-width: 1100px) { .hx-deck { grid-template-columns: 1fr; } .hx-mem { grid-template-columns: 1fr; } }
@media (max-width: 1000px) { .hx-tdb, .hx-tc { grid-template-columns: 1fr; } .hx-up-grid { grid-template-columns: 1fr; } }
@media (max-width: 760px) { .hx-ti { font-size: 40px; } .hx-ow input { width: 180px; } .hx-stp { grid-template-columns: repeat(2, 1fr); row-gap: 18px; } .hx-stp-ln { display: none; } }
@media (prefers-reduced-motion: reduce) { .hx-wu::before, .hx-wi, .hx-sp.is-cur .hx-sp-d, .hx-td:has([data-holding]) .hx-tcard { animation: none; } }

/* Providers (`Providers.html`) and Provider detail (`Provider Detail.html`). */
.cp-page:has(> .hx-ph), .cp-page:has(> .hx-hero) { gap: 0; }
.hx-ph { display: flex; justify-content: space-between; align-items: flex-end; gap: 20px; flex-wrap: wrap; margin-bottom: 26px; }
.hx-ph h1, .hx-hero h1 { font: 400 56px/1 var(--serif); margin: 0; letter-spacing: -.01em; color: var(--hx-tx); }
.hx-ph p { margin: 8px 0 0; color: var(--hx-mu); font-size: 15px; max-width: 620px; }
.hx-g3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
@media (max-width: 1000px) { .hx-g3 { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 640px) { .hx-g3 { grid-template-columns: 1fr; } }
.hx-cd { background: var(--hx-c1); border: 1px solid var(--hx-ln); border-radius: 18px; padding: 22px; }
:root[data-theme="dark"] .hx-cd { background: linear-gradient(145deg, rgba(255,255,255,.05), rgba(255,255,255,.01)); }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .hx-cd { background: linear-gradient(145deg, rgba(255,255,255,.05), rgba(255,255,255,.01)); } }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .hx-cd { background: linear-gradient(145deg, rgba(255,255,255,.05), rgba(255,255,255,.01)); } }
.hx-cd h3 { margin: 0 0 4px; font: 400 22px var(--serif); color: var(--hx-tx); }
.hx-pv { width: 40px; height: 40px; border-radius: 11px; display: flex; align-items: center; justify-content: center; color: var(--c); background: color-mix(in srgb, var(--c) 15%, transparent); box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--c) 28%, transparent); flex: none; }
.hx-pv .cp-pv { display: contents; }
.hx-pv .cp-mark { width: 22px; height: 22px; color: var(--c); background: none; border: 0; box-shadow: none; padding: 0; }
.hx-pv-lg { width: 72px; height: 72px; border-radius: 20px; }
.hx-pv-lg .cp-mark { width: 38px; height: 38px; }
.hx-pc { position: relative; display: flex; flex-direction: column; gap: 18px; min-height: 300px; overflow: hidden; color: var(--hx-tx); text-decoration: none; cursor: pointer; transition: border-color .25s, transform .3s cubic-bezier(.34,1.5,.5,1); }
.hx-pc:hover { border-color: var(--c, var(--hx-tx)); transform: translateY(-3px); color: var(--hx-tx); }
:root[data-theme="light"] .hx-pc:hover { box-shadow: 0 14px 30px -10px rgba(31,29,26,.16), 0 3px 8px rgba(31,29,26,.06); }
@media (prefers-color-scheme: light) { :root:not([data-theme="dark"]) .hx-pc:hover { box-shadow: 0 14px 30px -10px rgba(31,29,26,.16), 0 3px 8px rgba(31,29,26,.06); } }
.hx-pc::after { content: ""; position: absolute; right: -40px; top: -40px; width: 150px; height: 150px; border-radius: 50%; background: var(--c, transparent); opacity: .08; filter: blur(30px); pointer-events: none; }
.hx-ph2 { display: flex; gap: 14px; align-items: center; }
.hx-ph2 > div { min-width: 0; }
.hx-ph2 b { display: block; font-size: 16px; letter-spacing: .05em; text-transform: uppercase; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.hx-ph2 small { color: var(--hx-mu); font-size: 12.5px; }
.hx-ph2 .hx-ch3 { margin-left: auto; flex: none; }
.hx-ch3 { display: inline-flex; align-items: center; gap: 6px; padding: 3px 10px; border-radius: 99px; background: var(--hx-chip); font-size: 12px; font-weight: 600; color: var(--hx-mu); white-space: nowrap; }
.hx-ch3.is-ok { color: var(--hx-ok); }
.hx-ch3.is-wn { color: var(--hx-wn); }
.hx-ch3.is-bad { color: var(--hx-bad); }
.hx-md .hx-ch3.hx-mono { font-size: 11px; }
.hx-pm { display: grid; grid-template-columns: auto 1fr; gap: 18px; align-items: center; }
.hx-pm dl { margin: 0; display: grid; grid-template-columns: 1fr 1fr; gap: 10px 16px; }
.hx-pm dt { font-size: 11px; letter-spacing: .08em; text-transform: uppercase; color: var(--hx-mu); font-weight: 600; }
.hx-pm dd { margin: 2px 0 0; font-size: 16px; font-weight: 600; font-variant-numeric: tabular-nums; }
.hx-pm .is-wn dd { color: var(--hx-wn); }
.hx-md { display: flex; gap: 6px; flex-wrap: wrap; }
.hx-pf { margin-top: auto; display: flex; justify-content: space-between; align-items: center; gap: 10px; padding-top: 16px; border-top: 1px solid var(--hx-ln); color: var(--hx-mu); font-size: 13px; }
.hx-pf u { text-decoration: none; color: var(--hx-ac); font-weight: 600; white-space: nowrap; }
.hx-add { border-style: dashed; align-items: center; justify-content: center; text-align: center; color: var(--hx-mu); }
.hx-add:hover { color: var(--hx-tx); border-color: var(--hx-tx); }
.hx-add svg { width: 28px; height: 28px; fill: none; stroke: currentColor; stroke-width: 2.2; stroke-linecap: round; }
.hx-add-t { margin-top: 10px; font-weight: 600; font-size: 14px; }
.hx-add small { font-size: 12px; }
/* Provider detail. */
.hx-hero { display: flex; gap: 20px; align-items: center; margin: 16px 0 26px; flex-wrap: wrap; }
.hx-hero h1 { font-size: 52px; }
.hx-hs { display: flex; gap: 10px; align-items: center; margin-top: 10px; flex-wrap: wrap; color: var(--hx-mu); font-size: 13px; }
.hx-hac { margin-left: auto; display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.hx-bn { display: inline-flex; align-items: center; gap: 8px; background: var(--hx-c1); border: 1px solid var(--hx-ln); color: var(--hx-tx); border-radius: 10px; padding: 9px 14px; font: 600 13px var(--sans); cursor: pointer; text-decoration: none; transition: border-color .2s, transform .2s, background .2s; }
.hx-bn:hover { border-color: var(--hx-tx); color: var(--hx-tx); }
.hx-bn svg { width: 15px; height: 15px; }
.hx-bn .cp-icon { fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.hx-bn-pr, .hx-bn-pr:hover { background: var(--hx-tx); color: var(--hx-c1); border-color: var(--hx-tx); }
.hx-bn-pr:hover { opacity: .88; }
.hx-hac .cp-test-chip { display: inline-flex; align-items: center; gap: 8px; font-size: 12.5px; font-weight: 600; padding: 6px 12px; border-radius: 99px; background: var(--hx-chip); color: var(--hx-mu); animation: hxRise .35s both; }
.hx-hac .cp-test-chip[hidden] { display: none; }
.hx-hac .cp-test-chip.is-ok { color: var(--hx-ok); }
.hx-hac .cp-test-chip.is-err { color: var(--hx-bad); }
.hx-hac .cp-test-chip.is-loading::before { content: ""; width: 12px; height: 12px; border-radius: 50%; border: 2px solid currentColor; border-right-color: transparent; animation: hxSpin .7s linear infinite; }
@keyframes hxSpin { to { transform: rotate(360deg); } }
.hx-kp { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); margin-bottom: 20px; border: 1px solid var(--hx-ln); border-radius: 18px; overflow: hidden; }
.hx-kp > div { padding: 18px 22px; border-left: 1px solid var(--hx-ln); }
.hx-kp > div:first-child { border-left: 0; }
.hx-kp small { display: block; font-size: 11px; letter-spacing: .09em; text-transform: uppercase; color: var(--hx-mu); font-weight: 600; }
.hx-kp b { display: block; font: 400 30px var(--serif); margin-top: 6px; font-variant-numeric: tabular-nums; color: var(--hx-tx); }
.hx-kp span { font-size: 12px; color: var(--hx-mu); }
.hx-rtc { padding: 20px; }
.hx-rth { display: flex; align-items: baseline; gap: 12px; flex-wrap: wrap; margin-bottom: 16px; }
.hx-rth h3 { margin: 0; }
.hx-rth span { color: var(--hx-mu); font-size: 13px; }
.hx-rt3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.hx-rtl { position: relative; border: 1px solid var(--hx-ln); border-radius: 16px; padding: 14px; cursor: pointer; color: var(--hx-tx); display: grid; gap: 10px; align-content: start; transition: border-color .25s, background .25s, transform .35s cubic-bezier(.34,1.6,.5,1); }
.hx-rtl:hover { transform: translateY(-2px); border-color: var(--hx-mu); }
.hx-rtl input { position: absolute; opacity: 0; pointer-events: none; }
.hx-rtl:has(input:checked) { border-color: var(--hx-tx); background: linear-gradient(160deg, color-mix(in srgb, var(--c) 14%, transparent), transparent 70%); box-shadow: 0 0 0 1px var(--hx-tx); }
.hx-rtl:has(input:focus-visible) { outline: 2px solid var(--hx-ac); outline-offset: 2px; }
.hx-rtl svg { width: 100%; height: 64px; overflow: visible; }
.hx-rtl .hx-ln { fill: none; stroke: var(--c); stroke-linecap: round; }
.hx-rtl .hx-fl { stroke-dasharray: 3 7; animation: hxDash 1.1s linear infinite; }
@keyframes hxDash { to { stroke-dashoffset: -20; } }
.hx-rtl .hx-nd { fill: var(--hx-c1); stroke: var(--c); stroke-width: 2; }
.hx-rtl .hx-src { fill: var(--c); }
.hx-rtl:not(:has(input:checked)) .hx-ln { opacity: .45; }
.hx-rtl:not(:has(input:checked)) .hx-fl { animation-play-state: paused; }
.hx-rtl b { font-size: 14.5px; display: flex; align-items: center; gap: 8px; }
.hx-rtl b i { width: 16px; height: 16px; border-radius: 50%; border: 1.5px solid var(--hx-ln); display: inline-flex; align-items: center; justify-content: center; transition: all .25s; }
.hx-rtl:has(input:checked) b i { background: var(--hx-tx); border-color: var(--hx-tx); }
/* The provider's default route cap (#610) under the strategy tiles, and the suffix-in-the-box field Settings uses for its
   rate: the unit sits inside the input so a value and its unit read as one thing. */
.hx-rcap { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-top: 16px; padding-top: 16px; border-top: 1px solid var(--hx-ln); }
.hx-rcap-t { display: inline-flex; align-items: center; gap: 6px; font-size: 14px; }
.hx-rcap-note { margin: 14px 0 0; font-size: 13px; }
.hx-sfx { position: relative; display: inline-flex; align-items: center; justify-self: start; }
.hx-sfx .hx-in { padding-right: 32px; text-align: right; font-variant-numeric: tabular-nums; }
.hx-sfx i { position: absolute; right: 12px; font-style: normal; font-size: 13px; color: var(--hx-mu); pointer-events: none; }
.hx-num { width: 96px; }
.hx-rtl b i::after { content: ""; width: 6px; height: 6px; border-radius: 50%; background: var(--hx-c1); transform: scale(0); transition: transform .3s cubic-bezier(.34,1.8,.5,1); }
.hx-rtl:has(input:checked) b i::after { transform: scale(1); }
.hx-rtl small { color: var(--hx-mu); font-size: 12.5px; line-height: 1.45; }
.hx-acc { padding: 0; overflow: hidden; }
.hx-atb { display: flex; gap: 10px; align-items: center; padding: 16px 20px; flex-wrap: wrap; border-bottom: 1px solid var(--hx-ln); }
.hx-atb h3 { margin: 0 8px 0 0; }
.hx-atb .hx-in { width: 190px; padding: 8px 12px; }
.hx-acn { margin-left: auto; color: var(--hx-mu); font-size: 12.5px; }
.hx-seg2 { display: inline-flex; padding: 3px; border-radius: 10px; background: var(--hx-chip); gap: 2px; flex: none; }
.hx-seg2 button { border: 0; background: transparent; color: var(--hx-mu); font: 600 12.5px var(--sans); padding: 6px 12px; border-radius: 8px; cursor: pointer; white-space: nowrap; transition: all .2s; }
.hx-seg2 button.is-on { background: var(--hx-c1); color: var(--hx-tx); box-shadow: 0 1px 2px rgba(0,0,0,.2); }
.hx-ls { display: flex; flex-direction: column; }
.hx-ar { position: relative; display: grid; grid-template-columns: minmax(150px,1.3fr) minmax(0,1fr) minmax(0,1fr) 44px 18px; align-items: center; gap: 18px; padding: 14px 20px; border-top: 1px solid var(--hx-ln); background: var(--hx-c1); cursor: pointer; color: var(--hx-tx); transition: background .2s; }
.hx-ar:first-child { border-top: 0; }
.hx-ar:hover { background: color-mix(in srgb, var(--hx-c1) 94%, #7f7f7f); }
.hx-ar[hidden] { display: none; }
.hx-an { display: flex; gap: 12px; align-items: center; min-width: 0; }
.hx-an > div { min-width: 0; }
.hx-an b { display: block; font-size: 14.5px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.hx-an b.is-expired { color: var(--hx-ac); }
.hx-an small { color: var(--hx-mu); font-size: 12px; }
.hx-dot { width: 9px; height: 9px; border-radius: 50%; background: var(--hx-ok); flex: none; box-shadow: 0 0 0 3px color-mix(in srgb, var(--hx-ok) 20%, transparent); }
.hx-ar.is-off .hx-dot { background: var(--hx-mu); box-shadow: none; }
.hx-ar.is-off .hx-qb, .hx-ar.is-off .hx-an > div { opacity: .5; }
.hx-tg2 { display: inline-block; font-weight: 600; font-size: 11px; padding: 1px 7px; border-radius: 99px; background: color-mix(in srgb, var(--c) 15%, transparent); color: var(--c); margin-left: 6px; vertical-align: 1px; }
.hx-tg2.is-mu { --c: var(--hx-mu) !important; }
.hx-qb small { display: flex; justify-content: space-between; font-size: 11.5px; color: var(--hx-mu); margin-bottom: 6px; }
.hx-qb small b { color: var(--hx-tx); font-weight: 600; font-variant-numeric: tabular-nums; }
.hx-mb { height: 6px; border-radius: 9px; background: var(--hx-chip); overflow: hidden; }
.hx-mb i { display: block; height: 100%; border-radius: 9px; background: var(--c, var(--hx-ac)); animation: hxGrow 1s cubic-bezier(.2,.8,.2,1) both; }
.hx-tgb { width: 42px; height: 24px; border-radius: 99px; background: var(--hx-ib-ln); position: relative; cursor: pointer; transition: background .25s; flex: none; border: 0; padding: 0; }
.hx-tgb::after { content: ""; position: absolute; left: 3px; top: 3px; width: 18px; height: 18px; border-radius: 50%; background: var(--hx-tx); transition: transform .3s cubic-bezier(.34,1.6,.5,1); }
.hx-tgb[aria-checked="true"] { background: var(--hx-ac); }
.hx-tgb[aria-checked="true"]::after { transform: translateX(18px); }
.hx-tgb:focus-visible { outline: 2px solid var(--hx-ac); outline-offset: 2px; }
:root[data-theme="light"] .hx-tgb::after { background: #fff; }
@media (prefers-color-scheme: light) { :root:not([data-theme="dark"]) .hx-tgb::after { background: #fff; } }
:root[data-theme="light"] .hx-tgb[aria-checked="true"] { background: #1f1d1a; }
@media (prefers-color-scheme: light) { :root:not([data-theme="dark"]) .hx-tgb[aria-checked="true"] { background: #1f1d1a; } }
.hx-chv { display: flex; width: 16px; height: 16px; color: var(--hx-mu); transition: transform .25s, color .2s; }
.hx-chv svg { width: 16px; height: 16px; }
.hx-ar:hover .hx-chv { transform: translateX(3px); color: var(--hx-tx); }
.hx-emp { padding: 40px; text-align: center; color: var(--hx-mu); display: flex; flex-direction: column; align-items: center; gap: 14px; margin: 0; }
.hx-sc2 { padding: 20px; display: grid; gap: 16px; }
.hx-sc2 h3 { margin: 0; }
.hx-sc2 .hx-fld .hx-in { width: 100%; }
.hx-in[readonly] { color: var(--hx-tx); cursor: default; }
.hx-in[readonly]:focus { border-color: var(--hx-ib-ln); box-shadow: none; }
.hx-rp { font-size: 12.5px; color: var(--hx-mu); line-height: 1.55; padding: 12px 14px; border-radius: 12px; background: var(--hx-chip); }
.hx-rp code { font: 600 12px ui-monospace, Menlo, monospace; color: var(--hx-tx); }
.hx-rp-src { display: block; margin-top: 6px; font-size: 11.5px; }
.hx-sc2-act { display: flex; justify-content: flex-end; gap: 8px; }
/* #664: a provider's page is a hero, the day's figures and four tabs. The tab bar scrolls sideways on a phone, a panel is
   as wide as the page, and nothing is side by side, so no width breaks a layout. */
.hx-ptabs { overflow-x: auto; overflow-y: hidden; margin-bottom: 16px; }
.hx-ptabs .hx-tab { flex: none; white-space: nowrap; text-decoration: none; }
.hx-tp { min-width: 0; }
.hx-tp:not([hidden]) { animation: hxRise .45s both; }
.hx-rtw { max-width: 780px; }
.hx-cnc { max-width: 640px; }
.hx-cch { display: flex; align-items: center; gap: 6px; }
.hx-nosave { display: flex; justify-content: flex-end; margin-top: 16px; }
p.hx-rp { margin: 0; }
.hx-alc { padding: 20px; display: grid; gap: 14px; }
.hx-alh { display: flex; align-items: center; gap: 6px; }
.hx-alh h3 { margin: 0; }
.hx-alcount { margin-left: auto; font-size: 12.5px; font-variant-numeric: tabular-nums; }
.hx-alscroll { max-height: min(60vh, 520px); overflow: auto; border: 1px solid var(--hx-ln); border-radius: 12px; }
.hx-alhead, .hx-alias-row { display: grid; grid-template-columns: minmax(0, 1fr) 20px minmax(0, 1fr) 32px; align-items: center; gap: 8px; }
.hx-alhead { position: sticky; top: 0; z-index: 1; padding: 10px 12px 8px; background: var(--hx-c1); border-bottom: 1px solid var(--hx-ln); font-size: 11.5px; letter-spacing: .08em; text-transform: uppercase; color: var(--hx-mu); font-weight: 600; }
.hx-alias-rows { display: grid; gap: 8px; padding: 12px; }
.hx-alias-rows:empty { display: none; }
.hx-alias-row .hx-in { width: 100%; min-width: 0; }
.hx-alias-row > .hx-mut { text-align: center; }
.hx-alias-row .hx-x { display: grid; place-items: center; width: 32px; height: 32px; padding: 0; }
.hx-alias-row .hx-x .cp-icon { width: 15px; height: 15px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.hx-alias-row .hx-in[aria-invalid="true"] { border-color: var(--hx-bad); }
.hx-aldup { grid-column: 1 / -1; color: var(--hx-bad); font-size: 12.5px; }
.hx-alempty { margin: 0; font-size: 13px; }
.hx-alact { display: flex; }
.hx-alact .hx-bn:disabled { opacity: .45; cursor: not-allowed; }
.hx-rm { margin-top: 28px; border: 1px solid color-mix(in srgb, var(--hx-bad) 28%, var(--hx-ln)); border-radius: 20px; padding: 26px; background: linear-gradient(180deg, color-mix(in srgb, var(--hx-bad) 6%, transparent), transparent 60%); }
.hx-rmh .hx-lbl { color: var(--hx-bad); }
.hx-rmh h2 { font: 400 26px var(--serif); margin: 6px 0 0; color: var(--hx-tx); }
.hx-rmh p { margin: 8px 0 0; color: var(--hx-mu); font-size: 14px; max-width: 560px; }
.hx-rmb { position: relative; display: grid; grid-template-columns: minmax(220px,300px) minmax(0,1fr) auto; gap: 32px; align-items: center; margin-top: 22px; }
.hx-rmc { display: flex; flex-wrap: wrap; gap: 8px; align-content: center; }
.hx-rmc i { font-style: normal; white-space: nowrap; max-width: 100%; overflow: hidden; text-overflow: ellipsis; display: inline-flex; align-items: center; gap: 8px; padding: 6px 11px 6px 7px; border-radius: 99px; background: var(--hx-chip); font-size: 12.5px; font-weight: 600; color: var(--hx-tx); transition: opacity .45s, transform .45s, filter .45s; }
.hx-rmc i em { width: 20px; height: 20px; border-radius: 50%; background: var(--c); color: #fff; font: 700 10px var(--sans); font-style: normal; display: flex; align-items: center; justify-content: center; }
.hx-rmc i[data-gone] { opacity: 0; transform: translateY(-14px) scale(.8); filter: blur(5px); }
.hx-rm .cp-hold-wrap { display: flex; flex-direction: column; align-items: center; gap: 12px; text-align: center; }
.hx-rm .cp-hold-hint { font-size: 12px; color: var(--hx-mu); line-height: 1.5; max-width: 150px; }
.hx-rm .cp-undo { grid-column: 1 / -1; }
.hx-rm:has(.cp-undo[data-on]) .cp-hold-wrap { display: none; }
.hx-rm .cp-undo-btn { background: var(--hx-pri-bg); color: var(--hx-pri-tx); }
.hx-rm .cp-undo-bar i { background: var(--hx-bad); }
@media (max-width: 1100px) {
  .hx-kp { grid-template-columns: repeat(2, 1fr); }
  .hx-kp > div:nth-child(3) { border-left: 0; }
  .hx-kp > div:nth-child(n+3) { border-top: 1px solid var(--hx-ln); }
  .hx-rmb { grid-template-columns: 1fr; }
  .hx-rt3 { grid-template-columns: 1fr; }
  .hx-rtl { grid-template-columns: 110px 1fr; align-items: center; }
  .hx-rtl svg { grid-row: span 2; }
}
@media (max-width: 760px) {
  .hx-ar { grid-template-columns: minmax(0,1fr) 44px; }
  .hx-ar .hx-qb, .hx-ar .hx-chv { display: none; }
  .hx-hero h1 { font-size: 40px; }
  .hx-hac { margin-left: 0; }
}
@media (prefers-reduced-motion: reduce) { .hx-rtl .hx-fl, .hx-mb i { animation: none; } }
.hx-nojs-form { display: flex; gap: 8px; margin-top: 14px; flex-wrap: wrap; }
.hx-pill .cp-pv { display: contents; }
.hx-pill .cp-mark { width: 13px; height: 13px; background: none; border: 0; box-shadow: none; padding: 0; }
.hx-rm[data-dissolving] .hx-tl { opacity: .4; filter: blur(2px); transition: opacity .7s, filter .7s; }

/* The unsaved-changes bar (#526): a dark floating card — a tile with the number of pending changes and a pulsing dot,
   what changed, Discard as a quiet text button, and Save with its keyboard shortcut. */
.hx-sv { position: fixed; left: 50%; bottom: 26px; transform: translateX(-50%); z-index: 70; display: flex; align-items: center; gap: 14px; max-width: calc(100vw - 32px); padding: 10px 10px 10px 12px; border-radius: 16px; background: #1f1b17; border: 1px solid #3a332b; color: #ece6dc; box-shadow: 0 18px 50px rgba(0,0,0,.55), inset 0 1px 0 rgba(255,255,255,.05); animation: hxSv .4s cubic-bezier(.34,1.5,.5,1); }
@keyframes hxSv { from { opacity: 0; transform: translate(-50%, 30px); } }
.hx-sv-n { position: relative; flex: none; width: 34px; height: 34px; border-radius: 9px; display: flex; align-items: center; justify-content: center; background: color-mix(in srgb, #e8743b 22%, transparent); box-shadow: inset 0 0 0 1px color-mix(in srgb, #e8743b 30%, transparent); }
.hx-sv-n b { font: 400 18px var(--serif); color: #e8743b; font-variant-numeric: tabular-nums; }
.hx-sv-n::before { content: ""; position: absolute; left: -3px; top: -3px; width: 9px; height: 9px; border-radius: 50%; background: #e8743b; box-shadow: 0 0 0 2px #1f1b17; animation: hxSvDot 1.8s ease-out infinite; }
@keyframes hxSvDot { 0% { box-shadow: 0 0 0 2px #1f1b17, 0 0 0 2px rgba(232,116,59,.55); } 70%, 100% { box-shadow: 0 0 0 2px #1f1b17, 0 0 0 9px rgba(232,116,59,0); } }
.hx-sv-t { display: flex; flex-direction: column; gap: 1px; min-width: 0; margin-right: 12px; }
.hx-sv-t b { font-size: 13.5px; font-weight: 700; white-space: nowrap; }
.hx-sv-t small { font-size: 12px; color: #9a9185; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 320px; }
.hx-sv-t small:empty { display: none; }
.hx-sv button { border: 0; border-radius: 10px; font: 700 13px var(--sans); cursor: pointer; white-space: nowrap; }
.hx-sv-d { background: transparent; color: #9a9185; padding: 9px 14px; transition: color .2s; }
.hx-sv-d:hover { color: #ece6dc; }
.hx-sv-s { display: inline-flex; align-items: center; gap: 8px; background: #ece6dc; color: #181512; padding: 9px 10px 9px 14px; transition: background .2s; }
.hx-sv-s:hover { background: #fff; }
.hx-sv-s:disabled { opacity: .6; cursor: progress; }
.hx-sv-s kbd { font: 600 11px var(--sans); padding: 2px 6px; border-radius: 5px; background: rgba(24,21,18,.08); box-shadow: inset 0 0 0 1px rgba(24,21,18,.14); color: #6b665e; }
:root[data-theme="light"] .hx-sv { background: #fffdf9; border-color: #e3ddd0; color: #1f1d1a; box-shadow: 0 14px 40px rgba(31,29,26,.16); }
@media (prefers-color-scheme: light) { :root:not([data-theme="dark"]) .hx-sv { background: #fffdf9; border-color: #e3ddd0; color: #1f1d1a; box-shadow: 0 14px 40px rgba(31,29,26,.16); } }
:root[data-theme="light"] .hx-sv-n::before { box-shadow: 0 0 0 2px #fffdf9; }
@media (prefers-color-scheme: light) { :root:not([data-theme="dark"]) .hx-sv-n::before { box-shadow: 0 0 0 2px #fffdf9; } }
:root[data-theme="light"] .hx-sv-d { color: #6b665e; }
@media (prefers-color-scheme: light) { :root:not([data-theme="dark"]) .hx-sv-d { color: #6b665e; } }
:root[data-theme="light"] .hx-sv-d:hover { color: #1f1d1a; }
@media (prefers-color-scheme: light) { :root:not([data-theme="dark"]) .hx-sv-d:hover { color: #1f1d1a; } }
:root[data-theme="light"] .hx-sv-s { background: #1f1d1a; color: #fff; }
@media (prefers-color-scheme: light) { :root:not([data-theme="dark"]) .hx-sv-s { background: #1f1d1a; color: #fff; } }
:root[data-theme="light"] .hx-sv-s:hover { background: #35312b; }
@media (prefers-color-scheme: light) { :root:not([data-theme="dark"]) .hx-sv-s:hover { background: #35312b; } }
:root[data-theme="light"] .hx-sv-s kbd { background: rgba(255,255,255,.12); box-shadow: inset 0 0 0 1px rgba(255,255,255,.2); color: #d9d2c3; }
@media (prefers-color-scheme: light) { :root:not([data-theme="dark"]) .hx-sv-s kbd { background: rgba(255,255,255,.12); box-shadow: inset 0 0 0 1px rgba(255,255,255,.2); color: #d9d2c3; } }
/* Centred over the main column, not the viewport: with the sidebar showing, the column's middle is half a sidebar to the
   right of the viewport's (#610). */
@media (min-width: 1025px) { .hx-sv { left: calc(50% + 118px); } }
@media (max-width: 640px) { .hx-sv { gap: 8px; } .hx-sv-t { flex: 1 1 0; margin-right: 0; } .hx-sv-t b { overflow: hidden; text-overflow: ellipsis; } .hx-sv-t small { display: none; } .hx-sv-s kbd { display: none; } .hx-sv-d { padding: 9px 8px; } }
@media (prefers-reduced-motion: reduce) { .hx-sv, .hx-sv-n::before { animation: none; } }
html:not(.js) .js-only { display: none !important; }
/* A provider's rows reorder the way the Accounts page's do (#530): the whole row is the handle while the routing uses
   order, lifting with a shadow and a ring as it is dragged and settling on the drop. */
[data-provider-accounts][data-ordered="1"] .hx-ar { cursor: grab; touch-action: pan-y; }
.hx-ar.is-drag { z-index: 5; cursor: grabbing; background: var(--hx-drag); box-shadow: 0 18px 40px rgba(0,0,0,.55), 0 0 0 1px rgba(232,116,59,.5); border-radius: 12px; will-change: transform; }
:root[data-theme="light"] .hx-ar.is-drag { box-shadow: 0 8px 24px rgba(31,29,26,.14), 0 0 0 1px #1f1d1a; }
@media (prefers-color-scheme: light) { :root:not([data-theme="dark"]) .hx-ar.is-drag { box-shadow: 0 8px 24px rgba(31,29,26,.14), 0 0 0 1px #1f1d1a; } }
.hx-ar.is-settle { transition: transform .35s cubic-bezier(.34,1.5,.5,1), box-shadow .3s; }
/* A band's body is painted with its card, never with the page behind it (#532): while the row grows from 0fr the sticky
   account column and the table's own background would otherwise show the page's backdrop for a frame, which reads as a
   dark flash in light mode. The horizontal scrollbar is only revealed once the band is fully open, so it never appears
   mid-slide. */
.hx-gb, .hx-sc { background: var(--hx-c1); }
.hx-grp[data-closing] > .hx-gb .hx-sc, .hx-grp:not([open]) > .hx-gb .hx-sc { overflow-x: hidden; }
.hx-grp[open]:not([data-closing]) > .hx-gb .hx-sc { overflow-x: auto; }

/* The connect-account dialog (#548), drawn as the prototype: a wide card with a serif title, three step tabs, the
   "what are you connecting" cards, a labelled name field and a segmented who-signs-in choice. */
.cp-dialog.hx-dialog { width: min(560px, calc(100vw - 32px)); max-width: min(560px, calc(100vw - 32px)); padding: 0; border-radius: 18px; overflow: hidden; background: var(--hx-c1); }
.hx-dialog-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; padding: 22px 24px 0; }
.hx-dialog-title { font: 400 26px/1.15 var(--serif); color: var(--hx-tx); }
.hx-dialog-x { width: 32px; height: 32px; border: 0; border-radius: 9px; background: transparent; color: var(--hx-mu); font-size: 22px; line-height: 1; cursor: pointer; flex: none; }
.hx-dialog-x:hover { background: var(--hx-chip); color: var(--hx-tx); }
/* The connect dialog's progress (#608): the bars the dialog had before #548 (`.cp-step*` above), set in the new head. */
.hx-dialog-steps { margin: 16px 24px 0; }
.hx-dialog-steps .cp-step-bar { transition: background 0.25s; }
.hx-dialog-steps .cp-step-label { transition: color 0.25s; }
@media (prefers-reduced-motion: reduce) { .hx-dialog-steps .cp-step-bar, .hx-dialog-steps .cp-step-label { transition: none; } }
/* The lifetime picker is the console's select (rule 31) in the dialog's field: it keeps `.cp-input`'s size and look
   (rule 32) and only drops the field label's caps and spacing, which the trigger would otherwise inherit. */
.hx-fld .cp-input { text-transform: none; letter-spacing: 0; font-weight: 400; }
.hx-dialog-body { padding: 20px 24px 22px; max-height: min(70vh, 640px); overflow: auto; }
.hx-dialog-body .cp-oauth-panel { gap: 18px; }
.hx-kinds { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.hx-kind { position: relative; display: grid; gap: 6px; padding: 12px; border: 1px solid var(--hx-ib-ln); border-radius: 14px; background: var(--hx-c1); cursor: pointer; transition: border-color .2s, background .2s, transform .25s cubic-bezier(.34,1.6,.5,1); }
.hx-kind:hover { transform: translateY(-2px); border-color: var(--hx-mu); }
.hx-kind input { position: absolute; opacity: 0; pointer-events: none; }
.hx-kind:has(input:checked) { border-color: var(--hx-ac); background: color-mix(in srgb, var(--hx-ac) 7%, var(--hx-c1)); box-shadow: 0 0 0 1px var(--hx-ac); }
.hx-kind:has(input:focus-visible) { outline: 2px solid var(--hx-ac); outline-offset: 2px; }
.hx-kind-mark { display: flex; }
.hx-kind-mark .cp-pv { width: 34px; height: 34px; border-radius: 10px; }
.hx-kind-mark .cp-mark { width: 20px; height: 20px; }
.hx-kind-dot { position: absolute; top: 12px; right: 12px; width: 16px; height: 16px; border-radius: 50%; border: 1.5px solid var(--hx-ib-ln); }
.hx-kind:has(input:checked) .hx-kind-dot { border-color: var(--hx-ac); background: radial-gradient(circle, var(--hx-ac) 0 4px, transparent 4px); }
.hx-kind b { font-size: 13.5px; color: var(--hx-tx); }
.hx-kind small { font-size: 11.5px; line-height: 1.35; color: var(--hx-mu); }
.hx-fld-row > span { display: flex; justify-content: space-between; gap: 12px; align-items: baseline; text-transform: none; letter-spacing: 0; }
.hx-fld-row > span > span { text-transform: none; letter-spacing: 0; font-weight: 500; font-size: 12px; }
.hx-seg3 { display: grid; grid-template-columns: 1fr 1fr; gap: 4px; padding: 4px; border-radius: 11px; background: var(--hx-chip); }
.hx-seg3 label { position: relative; cursor: pointer; }
.hx-seg3 input { position: absolute; opacity: 0; pointer-events: none; }
.hx-seg3 b { display: block; padding: 8px 10px; border-radius: 8px; text-align: center; font-size: 12.5px; font-weight: 600; color: var(--hx-mu); transition: background .2s, color .2s; }
.hx-seg3 label:has(input:checked) b { background: var(--hx-c1); color: var(--hx-tx); box-shadow: 0 1px 2px rgba(0,0,0,.18); }
.hx-seg3 label:has(input:focus-visible) b { outline: 2px solid var(--hx-ac); }
.hx-dialog-actions { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-top: 6px; padding-top: 18px; border-top: 1px solid var(--hx-ln); }
.hx-dialog-cancel { border: 0; background: transparent; color: var(--hx-mu); font: 600 13.5px var(--sans); padding: 10px 4px; cursor: pointer; }
.hx-dialog-cancel:hover { color: var(--hx-tx); }
.hx-dialog-go { border: 0; border-radius: 10px; padding: 11px 20px; background: var(--hx-pri-bg); color: var(--hx-pri-tx); font: 600 13.5px var(--sans); cursor: pointer; }
.hx-dialog-go:hover { opacity: .9; }
/* The Connect dialog on a phone (#770): a bottom sheet the width of the screen whose body scrolls between the fixed head
   and the screen's edge, and kind cards two to a row with the mark beside the name, so the label and the who-authorizes
   choice sit above the fold. */
@media (max-width: 560px) {
  .cp-overlay:has(> .hx-dialog) { display: flex; flex-direction: column; justify-content: flex-end; padding: 0; overflow: hidden; }
  .cp-dialog.hx-dialog { display: flex; flex-direction: column; margin: 0; width: 100%; max-width: 100%; max-height: 92dvh; border-radius: 22px 22px 0 0; border-bottom: 0; animation: hxSheet .3s cubic-bezier(.2,.8,.2,1) backwards; }
  .hx-dialog-head { flex: none; align-items: center; padding: 18px 16px 0 20px; }
  .hx-dialog-title { font-size: 22px; }
  .hx-dialog-steps { flex: none; margin: 12px 20px 0; }
  .hx-dialog-body { flex: 1 1 auto; min-height: 0; max-height: none; overscroll-behavior: contain; padding: 16px 20px calc(16px + env(safe-area-inset-bottom)); }
  .hx-dialog-body .cp-oauth-panel { gap: 14px; }
  .hx-kinds { gap: 8px; }
  .hx-kind { grid-template-columns: 30px minmax(0, 1fr); align-items: center; gap: 1px 10px; padding: 10px 26px 10px 10px; }
  .hx-kind:hover { transform: none; }
  .hx-kind-mark { grid-row: 1 / 3; }
  .hx-kind-mark .cp-pv { width: 30px; height: 30px; border-radius: 9px; }
  .hx-kind-mark .cp-mark { width: 18px; height: 18px; }
  .hx-kind-dot { top: 9px; right: 9px; width: 13px; height: 13px; }
  .hx-kind b { font-size: 13px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
  .hx-kind small { font-size: 11px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
  .hx-dialog-actions { padding-top: 14px; }
  .hx-dialog-go { flex: 1; }
  .hx-seg3 b { text-transform: none; letter-spacing: 0; }
}
@media (max-width: 560px) and (prefers-reduced-motion: reduce) { .cp-dialog.hx-dialog { animation: none; } }

/* Light and dark share every hover and motion effect; only the colours differ (#593). Reduced motion drops the lifts in both. */
:root[data-theme="light"] .hx-pc::after { filter: none; opacity: .05; }
@media (prefers-color-scheme: light) { :root:not([data-theme="dark"]) .hx-pc::after { filter: none; opacity: .05; } }
@media (prefers-reduced-motion: reduce) {
  .hx-stat, .hx-pc, .hx-ib, .hx-wu, .cp-nav-item, .hx-act .cp-btn-menu { transition: none; }
  .hx-stat:hover, .hx-pc:hover, .hx-ib:hover, .hx-wu:hover, .hx-act .cp-btn-menu:hover:not(:disabled) { transform: none; }
  .hx-tp:not([hidden]) { animation: none; }
}
