// Copyright (c) 2026 Alt. All rights reserved.
{}
/* The two lines above: the copyright line every source file starts with, and an
   empty block that ends the rule it opens (CSS has no line comment), so that the
   first real rule is read.
   ALT Licence portal pages. Colours are custom properties: light by default, dark from
   the system setting or the theme button (html[data-theme]). */

:root {
  color-scheme: light;
  --bg: #f4f5f2;
  --surface: #ffffff;
  --surface-2: #eef0ec;
  --surface-3: #e3e6e0;
  --text: #16191a;
  --text-2: #4b5255;
  --muted: #6c7376;
  --border: rgba(20, 24, 26, 0.13);
  --border-strong: rgba(20, 24, 26, 0.28);
  --accent: #1d6a83;
  --accent-hover: #175569;
  --accent-ink: #ffffff;
  --accent-soft: #e2eff3;
  --focus: #1d6a83;
  --shadow: 0 1px 2px rgba(20, 24, 26, 0.06), 0 2px 8px rgba(20, 24, 26, 0.05);

  /* Status: ink for words and icons, soft for backgrounds. */
  --good: #0b7a32;
  --good-soft: #e3f3e8;
  --info: #22609e;
  --info-soft: #e3edf8;
  --warning: #935400;
  --warning-soft: #fbf0dc;
  --critical: #b8322a;
  --critical-soft: #fbe6e3;
  --neutral: #5d6467;
  --neutral-soft: #eceeea;

  /* Chart. */
  --chart-surface: #fcfcfb;
  --grid: #e1e0d9;
  --axis: #c3c2b7;
  --band: #9a988f;
  --series-1: #2a78d6;
  --series-2: #eb6834;
  --series-3: #1baf7a;
  --series-4: #c98500;
  --series-5: #d55181;

  /* Calendar strip. */
  --day-a: #2a78d6;
  --day-b: #7fb0ea;
  --day-none: transparent;

  --radius: 10px;
  --radius-sm: 6px;
  --tap: 44px;
  --font: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --mono: ui-monospace, "Cascadia Mono", Consolas, "Liberation Mono", monospace;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    color-scheme: dark;
    --bg: #101211;
    --surface: #191b1a;
    --surface-2: #222524;
    --surface-3: #2c302e;
    --text: #f1f2ef;
    --text-2: #c4c7c2;
    --muted: #979b96;
    --border: rgba(255, 255, 255, 0.12);
    --border-strong: rgba(255, 255, 255, 0.26);
    --accent: #62b5d1;
    --accent-hover: #86c8de;
    --accent-ink: #0b1a1f;
    --accent-soft: #19323b;
    --focus: #86c8de;
    --shadow: 0 1px 2px rgba(0, 0, 0, 0.4);
    --good: #4cc574;
    --good-soft: #15301f;
    --info: #79b0ec;
    --info-soft: #172a40;
    --warning: #f0b445;
    --warning-soft: #3a2c10;
    --critical: #f27a6e;
    --critical-soft: #3d1b18;
    --neutral: #a6aaa5;
    --neutral-soft: #262928;
    --chart-surface: #1a1a19;
    --grid: #2c2c2a;
    --axis: #45453f;
    --band: #8a887f;
    --series-1: #3987e5;
    --series-2: #d95926;
    --series-3: #199e70;
    --series-4: #c98500;
    --series-5: #d55181;
    --day-a: #3987e5;
    --day-b: #1f4f8a;
  }
}

:root[data-theme="dark"] {
  color-scheme: dark;
  --bg: #101211;
  --surface: #191b1a;
  --surface-2: #222524;
  --surface-3: #2c302e;
  --text: #f1f2ef;
  --text-2: #c4c7c2;
  --muted: #979b96;
  --border: rgba(255, 255, 255, 0.12);
  --border-strong: rgba(255, 255, 255, 0.26);
  --accent: #62b5d1;
  --accent-hover: #86c8de;
  --accent-ink: #0b1a1f;
  --accent-soft: #19323b;
  --focus: #86c8de;
  --shadow: 0 1px 2px rgba(0, 0, 0, 0.4);
  --good: #4cc574;
  --good-soft: #15301f;
  --info: #79b0ec;
  --info-soft: #172a40;
  --warning: #f0b445;
  --warning-soft: #3a2c10;
  --critical: #f27a6e;
  --critical-soft: #3d1b18;
  --neutral: #a6aaa5;
  --neutral-soft: #262928;
  --chart-surface: #1a1a19;
  --grid: #2c2c2a;
  --axis: #45453f;
  --band: #8a887f;
  --series-1: #3987e5;
  --series-2: #d95926;
  --series-3: #199e70;
  --series-4: #c98500;
  --series-5: #d55181;
  --day-a: #3987e5;
  --day-b: #1f4f8a;
}

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

*, *::before, *::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }

body {
  margin: 0;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.5;
  overflow-wrap: break-word;
}

main { flex: 1; width: 100%; max-width: 1120px; margin: 0 auto; padding: 16px 16px 40px; outline: none; }

h1 { font-size: 1.5rem; line-height: 1.25; margin: 8px 0 4px; font-weight: 650; letter-spacing: -0.01em; }
h2 { font-size: 1.125rem; margin: 28px 0 10px; font-weight: 650; }
h3 { font-size: 1rem; margin: 0 0 6px; font-weight: 650; }
p { margin: 0 0 10px; }
a { color: var(--accent); text-underline-offset: 2px; }
a:hover { color: var(--accent-hover); }
code, .mono { font-family: var(--mono); font-size: 0.875em; }
small, .small { font-size: 0.875rem; }
.muted { color: var(--muted); }
.subtle { color: var(--text-2); }
.num { font-variant-numeric: tabular-nums; text-align: right; white-space: nowrap; }

:focus-visible { outline: 3px solid var(--focus); outline-offset: 2px; border-radius: 4px; }

.visually-hidden {
  position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}

.skip { position: absolute; left: 8px; top: -60px; background: var(--surface); padding: 8px 12px; border-radius: var(--radius-sm); z-index: 20; }
.skip:focus { top: 8px; }

[hidden] { display: none !important; }

/* ------------------------------------------------------------ header */

.top { background: var(--surface); border-bottom: 1px solid var(--border); position: sticky; top: 0; z-index: 10; }
.top-row { max-width: 1120px; margin: 0 auto; padding: 8px 16px; display: flex; align-items: center; gap: 12px; min-height: 56px; }
.brand { display: inline-flex; align-items: center; gap: 10px; color: var(--text); text-decoration: none; font-weight: 700; letter-spacing: -0.01em; min-height: var(--tap); }
.brand:hover { color: var(--text); }
.brand-mark { display: inline-flex; width: 28px; height: 28px; }
.brand-mark svg { width: 28px; height: 28px; }
.top-tools { margin-left: auto; display: flex; align-items: center; gap: 8px; min-width: 0; }
.site-select { max-width: 220px; }
.site-name { color: var(--text-2); font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 40vw; }

.nav { max-width: 1120px; margin: 0 auto; padding: 0 12px; display: flex; flex-wrap: wrap; gap: 2px; }
.nav a {
  display: inline-flex; align-items: center; gap: 6px; min-height: var(--tap); padding: 0 12px;
  color: var(--text-2); text-decoration: none; border-bottom: 3px solid transparent; font-weight: 550;
}
.nav a:hover { color: var(--text); background: var(--surface-2); }
.nav a[aria-current="page"] { color: var(--text); border-bottom-color: var(--accent); }
.nav .count { background: var(--accent); color: var(--accent-ink); border-radius: 999px; font-size: 0.75rem; padding: 0 7px; line-height: 1.5; font-weight: 700; }

.icon-button, .menu-button {
  min-height: var(--tap); min-width: var(--tap); padding: 0 12px; border-radius: var(--radius-sm);
  border: 1px solid var(--border-strong); background: var(--surface); color: var(--text); font: inherit; cursor: pointer;
}

@media (max-width: 599.98px) {
  .top-row { flex-wrap: wrap; }
  .menu-button:not([hidden]) { display: inline-flex; align-items: center; }
  .nav { flex-direction: column; padding: 0 0 8px; }
  .nav.closed { display: none; }
  .nav a { border-bottom: 0; border-left: 4px solid transparent; padding: 0 16px; }
  .nav a[aria-current="page"] { border-left-color: var(--accent); background: var(--surface-2); }
  .site-select { max-width: 46vw; }
}
@media (min-width: 600px) {
  .menu-button { display: none !important; }
}

/* ------------------------------------------------------------ footer, banners, toast */

.foot { border-top: 1px solid var(--border); background: var(--surface); color: var(--text-2); }
.foot-row { max-width: 1120px; margin: 0 auto; padding: 10px 16px 0; display: flex; flex-wrap: wrap; align-items: center; gap: 8px 20px; }
.foot-field { display: inline-flex; align-items: center; gap: 8px; }
.foot-field select { min-height: 40px; }
.foot-note { max-width: 1120px; margin: 0 auto; padding: 6px 16px 14px; font-size: 0.8125rem; color: var(--muted); }
.user-box { display: inline-flex; align-items: center; gap: 8px; }

.banner { background: var(--warning-soft); color: var(--text); border-bottom: 1px solid var(--border); }
.banner-inner { max-width: 1120px; margin: 0 auto; padding: 10px 16px; display: flex; flex-wrap: wrap; align-items: center; gap: 8px 14px; }

.toast {
  position: fixed; left: 50%; bottom: 20px; transform: translateX(-50%); z-index: 30;
  max-width: min(560px, calc(100vw - 32px)); background: var(--text); color: var(--bg);
  padding: 12px 16px; border-radius: var(--radius); box-shadow: var(--shadow);
}

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

button, .button {
  font: inherit; min-height: var(--tap); padding: 0 16px; border-radius: var(--radius-sm); cursor: pointer;
  border: 1px solid var(--border-strong); background: var(--surface); color: var(--text); font-weight: 600;
  display: inline-flex; align-items: center; justify-content: center; gap: 8px; text-decoration: none;
}
button:hover:not(:disabled), .button:hover { background: var(--surface-2); color: var(--text); }
button.primary, .button.primary { background: var(--accent); border-color: var(--accent); color: var(--accent-ink); }
button.primary:hover:not(:disabled) { background: var(--accent-hover); border-color: var(--accent-hover); color: var(--accent-ink); }
button.danger { color: var(--critical); border-color: var(--critical); }
button.danger:hover:not(:disabled) { background: var(--critical-soft); }
button:disabled { opacity: 0.55; cursor: not-allowed; }
.link-button { border: 0; background: none; padding: 0 4px; min-height: 40px; color: var(--accent); font-weight: 550; text-decoration: underline; text-underline-offset: 2px; }
.link-button:hover:not(:disabled) { background: none; color: var(--accent-hover); }

input, select, textarea {
  font: inherit; color: var(--text); background: var(--surface); border: 1px solid var(--border-strong);
  border-radius: var(--radius-sm); min-height: var(--tap); padding: 6px 10px; max-width: 100%;
}
textarea { min-height: 80px; width: 100%; resize: vertical; }
input[type="checkbox"] { min-height: 0; width: 20px; height: 20px; }

.field { display: flex; flex-direction: column; gap: 4px; margin: 0 0 14px; min-width: 0; }
.field > span:first-child, .field-label { font-weight: 600; font-size: 0.9375rem; }
.field .hint { font-size: 0.8125rem; color: var(--muted); }
.field input, .field select { width: 100%; }
.row { display: flex; flex-wrap: wrap; gap: 12px; align-items: flex-end; }
.row > .field { flex: 1 1 180px; }
.actions { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; margin-top: 6px; }

/* ------------------------------------------------------------ surfaces */

.card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 16px; box-shadow: var(--shadow); margin: 0 0 14px; min-width: 0; }
.card.narrow { max-width: 440px; margin: 32px auto; }
.page-head { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 4px 16px; margin-bottom: 12px; }
.page-head p { margin: 0; }
.notice { background: var(--surface-2); border-radius: var(--radius); padding: 12px 14px; color: var(--text-2); }
.error { background: var(--critical-soft); color: var(--text); border-left: 4px solid var(--critical); border-radius: var(--radius-sm); padding: 10px 12px; margin: 8px 0; }
.ok-box { background: var(--good-soft); border-left: 4px solid var(--good); border-radius: var(--radius-sm); padding: 10px 12px; margin: 8px 0; }
.loading { color: var(--muted); padding: 12px 0; }
.stack > * + * { margin-top: 10px; }

dl.facts { display: grid; grid-template-columns: max-content 1fr; gap: 4px 14px; margin: 8px 0 0; }
dl.facts dt { color: var(--muted); }
dl.facts dd { margin: 0; min-width: 0; }

/* ------------------------------------------------------------ status */

.status { display: inline-flex; align-items: center; gap: 6px; font-weight: 650; white-space: nowrap; }
.status svg { width: 18px; height: 18px; flex: none; }
.status.s-good { color: var(--good); }
.status.s-info { color: var(--info); }
.status.s-warning { color: var(--warning); }
.status.s-critical { color: var(--critical); }
.status.s-neutral { color: var(--neutral); }
.status.small { font-size: 0.8125rem; font-weight: 600; }
.status.small svg { width: 14px; height: 14px; }

.pill { display: inline-flex; align-items: center; gap: 5px; padding: 1px 9px; border-radius: 999px; font-size: 0.8125rem; font-weight: 600; white-space: nowrap; }
.pill svg { width: 14px; height: 14px; }
.pill.s-good { background: var(--good-soft); color: var(--good); }
.pill.s-info { background: var(--info-soft); color: var(--info); }
.pill.s-warning { background: var(--warning-soft); color: var(--warning); }
.pill.s-critical { background: var(--critical-soft); color: var(--critical); }
.pill.s-neutral { background: var(--neutral-soft); color: var(--neutral); }

/* ------------------------------------------------------------ Today */

.summary { display: flex; flex-wrap: wrap; gap: 8px 18px; margin: 4px 0 14px; }
.tiles { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 12px; }
.tile {
  display: flex; flex-direction: column; gap: 6px; padding: 14px 16px; min-height: 120px; text-decoration: none; color: var(--text);
  background: var(--surface); border: 1px solid var(--border); border-left: 6px solid var(--neutral); border-radius: var(--radius); box-shadow: var(--shadow);
}
.tile:hover { color: var(--text); border-color: var(--border-strong); }
.tile.s-good { border-left-color: var(--good); }
.tile.s-info { border-left-color: var(--info); }
.tile.s-warning { border-left-color: var(--warning); }
.tile.s-critical { border-left-color: var(--critical); }
.tile-name { font-weight: 700; font-size: 1.0625rem; line-height: 1.3; }
.tile-kind { color: var(--muted); font-size: 0.8125rem; }
.tile-detail { color: var(--text-2); font-size: 0.9375rem; }

.list { list-style: none; margin: 0; padding: 0; }
.list.card { padding: 4px 16px; }
.list > li { padding: 10px 0; border-top: 1px solid var(--border); display: flex; flex-wrap: wrap; gap: 4px 12px; align-items: baseline; }
.list > li:first-child { border-top: 0; }
.list .grow { flex: 1 1 220px; min-width: 0; }

/* ------------------------------------------------------------ tables (stacked on phones) */

.table-wrap { width: 100%; margin: 0 0 14px; }
table.rtable { width: 100%; border-collapse: collapse; background: var(--surface); }
.rtable th, .rtable td { text-align: left; padding: 8px 10px; border-bottom: 1px solid var(--border); vertical-align: top; }
.rtable th { font-size: 0.8125rem; color: var(--muted); font-weight: 650; text-transform: none; background: var(--surface-2); }
.rtable tr.total td { font-weight: 700; background: var(--surface-2); }
.rtable td.num, .rtable th.num { text-align: right; }

@media (max-width: 599.98px) {
  table.rtable, .rtable tbody, .rtable tr, .rtable td { display: block; width: 100%; }
  .rtable thead { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
  .rtable tr { border: 1px solid var(--border); border-radius: var(--radius-sm); margin: 0 0 10px; padding: 4px 0; background: var(--surface); }
  .rtable td { display: grid; grid-template-columns: minmax(96px, 40%) 1fr; gap: 10px; border-bottom: 0; padding: 4px 12px; text-align: left; }
  .rtable td.num { text-align: left; white-space: normal; }
  .rtable td::before { content: attr(data-label); color: var(--muted); font-size: 0.8125rem; font-weight: 600; }
  .rtable td[data-label=""]::before { content: none; }
  .rtable td[data-label=""] { grid-template-columns: 1fr; }
}

/* ------------------------------------------------------------ checks, versions */

.checks { list-style: none; padding: 0; margin: 6px 0 0; }
.checks li { display: flex; flex-wrap: wrap; gap: 4px 10px; align-items: baseline; padding: 6px 0; border-top: 1px dashed var(--border); }
.checks li:first-child { border-top: 0; }
.change { margin: 6px 0 0; }

.card h2 { margin-top: 0; }
.version-head h2 { margin: 0; }
.version-head { display: flex; flex-wrap: wrap; gap: 4px 12px; align-items: center; justify-content: space-between; }

/* ------------------------------------------------------------ upload */

.drop {
  display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; gap: 6px;
  border: 2px dashed var(--border-strong); border-radius: var(--radius); padding: 28px 16px; min-height: 150px;
  background: var(--surface-2); cursor: pointer; color: var(--text-2);
}
.drop:hover, .drop.over { border-color: var(--accent); background: var(--accent-soft); color: var(--text); }
.drop strong { color: var(--text); }
.drop input[type="file"] { position: absolute; width: 1px; height: 1px; opacity: 0; }
.progress { height: 10px; background: var(--surface-3); border-radius: 999px; overflow: hidden; margin: 10px 0 4px; }
.progress > div { height: 100%; width: 0; background: var(--accent); border-radius: 999px; transition: width 0.2s ease; }
.progress.indeterminate > div { width: 35%; animation: slide 1.2s ease-in-out infinite; }
@keyframes slide { from { transform: translateX(-100%); } to { transform: translateX(300%); } }
@media (prefers-reduced-motion: reduce) { .progress.indeterminate > div { animation: none; width: 100%; opacity: 0.5; } }

/* ------------------------------------------------------------ calendar strip */

.strip { display: grid; grid-template-columns: repeat(21, minmax(0, 1fr)); gap: 3px; margin: 8px 0; }
.strip .wd { font-size: 0.6875rem; color: var(--muted); text-align: center; }
.day {
  aspect-ratio: 1 / 1; min-height: 26px; border-radius: 4px; display: flex; align-items: center; justify-content: center;
  font-size: 0.75rem; font-variant-numeric: tabular-nums; border: 1px dashed var(--border-strong); color: var(--muted); background: var(--day-none);
}
.day.has { border: 1px solid transparent; color: #ffffff; font-weight: 600; }
.day.va { background: var(--day-a); }
.day.vb { background: var(--day-b); color: #0b1a2b; }
.day.today { outline: 2px solid var(--text); outline-offset: 1px; }
.day.future { opacity: 0.35; }
.legend-row { display: flex; flex-wrap: wrap; gap: 6px 16px; font-size: 0.8125rem; color: var(--text-2); }
.key { display: inline-block; width: 14px; height: 14px; border-radius: 3px; vertical-align: -2px; margin-right: 5px; }
.key.va { background: var(--day-a); }
.key.vb { background: var(--day-b); }
.key.none { border: 1px dashed var(--border-strong); }
@media (max-width: 599.98px) { .strip { grid-template-columns: repeat(7, minmax(0, 1fr)); } }

/* ------------------------------------------------------------ chart */

.chart-card { position: relative; }
.chart-controls { display: flex; flex-wrap: wrap; gap: 10px 14px; align-items: flex-end; margin: 0 0 12px; }
.chart-legend { display: flex; flex-wrap: wrap; gap: 6px 16px; margin: 0 0 8px; font-size: 0.875rem; color: var(--text-2); }
.chart-legend .item { display: inline-flex; align-items: center; gap: 6px; }
.chart-legend svg { width: 28px; height: 14px; }
.chart-box { position: relative; width: 100%; background: var(--chart-surface); border-radius: var(--radius-sm); }
.chart-box svg.chart { display: block; width: 100%; height: auto; touch-action: pan-y; }
.chart-box svg.chart:focus-visible { outline: 3px solid var(--focus); }
.chart-tip {
  position: absolute; pointer-events: none; background: var(--surface); color: var(--text); border: 1px solid var(--border-strong);
  border-radius: var(--radius-sm); box-shadow: var(--shadow); padding: 8px 10px; font-size: 0.8125rem; min-width: 150px; z-index: 5;
}
.chart-tip .tip-title { color: var(--muted); font-weight: 600; margin-bottom: 4px; }
.chart-tip .tip-row { display: flex; align-items: center; gap: 8px; }
.chart-tip .tip-row strong { font-variant-numeric: tabular-nums; min-width: 52px; }
.chart-tip svg { width: 18px; height: 10px; flex: none; }
.chart text { font-family: var(--font); }

details { margin: 10px 0 0; }
details > summary { cursor: pointer; min-height: var(--tap); display: flex; align-items: center; font-weight: 600; color: var(--accent); }

/* ------------------------------------------------------------ audit */

.event-details { font-family: var(--mono); font-size: 0.8125rem; color: var(--text-2); overflow-wrap: anywhere; }
.rtable td.nowrap { white-space: nowrap; }
.rtable td.wide { min-width: 220px; }
@media (max-width: 599.98px) { .rtable td.nowrap { white-space: normal; } .rtable td.wide { min-width: 0; } }
.segmented { display: inline-flex; border: 1px solid var(--border-strong); border-radius: var(--radius-sm); overflow: hidden; }
.segmented button { border: 0; border-radius: 0; min-width: 72px; }
.segmented button[aria-pressed="true"] { background: var(--accent); color: var(--accent-ink); }

@media (forced-colors: active) {
  .tile, .card { border: 1px solid CanvasText; }
  .day.has { border: 1px solid CanvasText; }
}

@media print {
  .top, .foot, .banner, .toast, button { display: none !important; }
  body { background: #ffffff; color: #000000; }
}
.narrow-row { max-width: 520px; }

/* ------------------------------------------------------------ sources and users (Admin) */

input[type="radio"] { min-height: 0; width: 20px; height: 20px; padding: 0; margin: 0; flex: none; accent-color: var(--accent); }
input[type="checkbox"] { flex: none; accent-color: var(--accent); }
fieldset.choices { border: 0; padding: 0; margin: 0 0 6px; min-width: 0; }
fieldset.choices > legend { padding: 0; margin: 0 0 6px; }
.choice { display: flex; align-items: center; gap: 10px; min-height: var(--tap); cursor: pointer; overflow-wrap: anywhere; }
.choice > span { min-width: 0; }
.range-row { border-top: 1px dashed var(--border); padding-top: 10px; }
.range-row > .field:last-child { flex: 0 0 auto; }
.issued { border-left: 4px solid var(--accent); }
.secret-row { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 14px; margin: 6px 0 10px; }
.secret {
  font-family: var(--mono); font-size: 1.25rem; letter-spacing: 0.06em; padding: 8px 12px; border-radius: var(--radius-sm);
  background: var(--surface-2); border: 1px solid var(--border-strong); user-select: all; overflow-wrap: anywhere; min-width: 0;
}
input[readonly] { background: var(--surface-2); color: var(--text-2); }

/* ------------------------------------------------------------ licence portal */

.support-bar { background: var(--warning-soft); color: var(--text); border-bottom: 2px solid var(--warning); }
.support-bar .banner-inner { font-weight: 600; }
.acting { display: inline-flex; align-items: center; gap: 8px; min-width: 0; }
.acting .who { color: var(--text-2); font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 38vw; }
.acting .role { color: var(--muted); font-size: 0.8125rem; }
.split { display: grid; grid-template-columns: minmax(0, 1fr) minmax(280px, 360px); gap: 14px; align-items: start; }
@media (max-width: 899.98px) { .split { grid-template-columns: minmax(0, 1fr); } }
.side { position: sticky; top: 72px; }
@media (max-width: 899.98px) { .side { position: static; } }
.alerts { list-style: none; margin: 0 0 14px; padding: 0; display: flex; flex-direction: column; gap: 8px; }
.alerts li svg { width: 20px; height: 20px; flex: none; }
.alerts li { display: flex; gap: 10px; align-items: center; padding: 10px 12px; border-radius: var(--radius-sm); background: var(--surface); border: 1px solid var(--border); border-left: 4px solid var(--neutral); }
.alerts li.s-warning { border-left-color: var(--warning); background: var(--warning-soft); }
.alerts li.s-critical { border-left-color: var(--critical); background: var(--critical-soft); }
.alerts li.s-good { border-left-color: var(--good); background: var(--good-soft); }
.tile-big { font-size: 1.75rem; font-weight: 700; font-variant-numeric: tabular-nums; line-height: 1.1; }
.meter { height: 8px; background: var(--surface-3); border-radius: 999px; overflow: hidden; margin-top: 4px; }
.meter > div { height: 100%; background: var(--series-1); border-radius: 999px; }
.meter.full > div { background: var(--critical); }
.kind-toggle { display: flex; gap: 8px; margin: 0 0 14px; }
.kind-toggle button { flex: 1 1 0; }
.kind-toggle button[aria-pressed="true"] { background: var(--accent); border-color: var(--accent); color: var(--accent-ink); }
.row-actions { display: flex; flex-wrap: wrap; gap: 6px; }
.row-actions button { min-height: 36px; padding: 0 10px; font-size: 0.875rem; font-weight: 550; }
.rtable tr.off td { color: var(--muted); }
.rtable tr.selected td { background: var(--accent-soft); }
.chart-bars rect { fill: var(--series-1); }
.chart-bars rect:hover { fill: var(--accent-hover); }
.chart text.lbl { font-size: 11px; fill: var(--muted); }
.chart line.grid { stroke: var(--grid); }
.chart line.axis { stroke: var(--axis); }
.otpauth { font-family: var(--mono); font-size: 0.8125rem; overflow-wrap: anywhere; background: var(--surface-2); padding: 8px 10px; border-radius: var(--radius-sm); }
.mods { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 2px 12px; }
.filters { display: flex; flex-wrap: wrap; gap: 10px 14px; align-items: flex-end; margin: 0 0 12px; }
.filters .field { margin: 0; flex: 0 1 220px; }
.count-note { color: var(--muted); font-size: 0.875rem; margin: 4px 0 10px; }
.wrap { overflow-wrap: anywhere; }
.login-card .brand-mark { margin: 0 auto 8px; display: flex; justify-content: center; }
.login-card h1 { text-align: center; margin-bottom: 14px; }
.password-row { display: flex; gap: 8px; align-items: flex-end; }
.password-row .field { flex: 1 1 auto; margin: 0; }
.acting .link-button { white-space: nowrap; }
@media (min-width: 600px) { .table-wrap { overflow-x: auto; } }
.rtable td.wrap, .rtable td.wide { overflow-wrap: anywhere; }
.row-actions button { white-space: nowrap; }
.rtable td.wide { width: 38%; min-width: 0; }
/* A wide table with a side panel: the panel goes below it on narrower screens. */
@media (max-width: 1319.98px) { .split.stack { grid-template-columns: minmax(0, 1fr); } .split.stack .side { position: static; } }

/* ------------------------------------------------------------ two-factor, alerts, privacy, invitations */

.totp-row { display: flex; flex-wrap: wrap; gap: 14px 20px; align-items: flex-start; }
.qr { flex: none; background: #ffffff; padding: 6px; border-radius: var(--radius-sm); border: 1px solid var(--border); line-height: 0; }
.qr svg { width: 196px; height: 196px; max-width: 100%; }
.totp-text { flex: 1 1 240px; min-width: 0; }
.alert-list li { align-items: flex-start; }
.alert-body { flex: 1 1 240px; min-width: 0; }
.alert-body p { margin: 2px 0 0; }
.alert-head { display: flex; flex-wrap: wrap; gap: 4px 10px; align-items: baseline; }
.alert-list li button { min-height: 36px; padding: 0 10px; font-size: 0.875rem; flex: none; }
.privacy { max-width: 760px; margin: 16px auto; }
.privacy h1 { margin-top: 0; }
.privacy ul { padding-left: 20px; margin: 0 0 8px; }
.privacy li { margin: 0 0 6px; }
.foot-link { margin-left: auto; }
.steps { padding-left: 20px; }
.steps li { margin: 0 0 6px; }
@media (max-width: 599.98px) { .qr svg { width: 160px; height: 160px; } }
.login-card dl.facts { margin: 4px 0 14px; }

/* The company's account on the login page: a quiet second way in. */
.sso-box { margin-top: 18px; padding-top: 14px; border-top: 1px solid var(--border); text-align: center; }
.sso-box p { margin: 0 0 10px; }

/* The server's plain pages of the single sign-on round trip (no script). */
main.sso-page { max-width: 560px; margin: 48px auto; padding: 0 16px; }
main.sso-page h1 { font-size: 1.4rem; margin-bottom: 12px; }
main.sso-page p { margin: 0 0 12px; line-height: 1.5; }
