/* Portal layout of webmanagement (owner area and /verwaltung/), after the click dummy.
   One token-based stylesheet; light theme only in the first release (decided 2026-11-07),
   the tokens keep a dark theme possible later. Fonts are self-hosted IBM Plex (OFL). */

@font-face { font-family: "IBM Plex Sans"; font-weight: 400; font-style: normal; font-display: swap;
  src: url("fonts/IBMPlexSans-Regular-Latin1.678efa63c3fb.woff2") format("woff2"); }
@font-face { font-family: "IBM Plex Sans"; font-weight: 500; font-style: normal; font-display: swap;
  src: url("fonts/IBMPlexSans-Medium-Latin1.e0399fc4473d.woff2") format("woff2"); }
@font-face { font-family: "IBM Plex Sans"; font-weight: 600; font-style: normal; font-display: swap;
  src: url("fonts/IBMPlexSans-SemiBold-Latin1.106da8161b57.woff2") format("woff2"); }
@font-face { font-family: "IBM Plex Sans"; font-weight: 700; font-style: normal; font-display: swap;
  src: url("fonts/IBMPlexSans-Bold-Latin1.102e1e2880b8.woff2") format("woff2"); }
@font-face { font-family: "IBM Plex Mono"; font-weight: 400; font-style: normal; font-display: swap;
  src: url("fonts/IBMPlexMono-Regular-Latin1.71dd6bb610c9.woff2") format("woff2"); }
@font-face { font-family: "IBM Plex Mono"; font-weight: 500; font-style: normal; font-display: swap;
  src: url("fonts/IBMPlexMono-Medium-Latin1.46d493a70cd2.woff2") format("woff2"); }

:root {
  --bg: #f3f4f2; --panel: #ffffff; --ink: #15191d; --muted: #5b6670; --line: #dde1e0; --soft: #eceeec;
  --accent: #1f4fd1; --accent-ink: #ffffff; --accent-soft: #e6ecfb;
  --ok: #1d7a4a; --ok-soft: #e3f2ea; --warn: #8a5100; --warn-soft: #fbf0dc; --bad: #b3261e; --bad-soft: #fbe5e3;
  --code: #f6f7f6;
  --sans: "IBM Plex Sans", system-ui, -apple-system, "Segoe UI", sans-serif;
  --mono: "IBM Plex Mono", ui-monospace, "SF Mono", Menlo, monospace;
  color-scheme: light;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0; background: var(--bg); color: var(--ink); font: 400 15px/1.55 var(--sans);
  padding-left: max(16px, env(safe-area-inset-left, 0px));
  padding-right: max(16px, env(safe-area-inset-right, 0px));
  padding-bottom: 48px;
}
h1, h2, h3 { margin: 0; line-height: 1.2; text-wrap: balance; }
p { margin: 0; }
a { color: var(--accent); }
button { font: inherit; cursor: pointer; color: inherit; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
img { max-width: 100%; height: auto; }
.mono { font-family: var(--mono); font-size: .86em; }
.muted { color: var(--muted); }
.small { font-size: 13px; }
.num { font-variant-numeric: tabular-nums; }
.visually-hidden {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden;
  clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0;
}
.skip-link { position: absolute; left: 16px; top: -40px; background: var(--panel); padding: 8px 12px; z-index: 100; }
.skip-link:focus { top: 8px; }

/* Header */
.top {
  max-width: 1320px; margin: 0 auto; padding-block: 14px; display: flex; flex-wrap: wrap;
  gap: 12px 20px; align-items: center; justify-content: space-between;
}
.brand { display: flex; align-items: baseline; gap: 10px; text-decoration: none; color: var(--ink); flex-wrap: wrap; }
.brand b { font-weight: 700; font-size: 18px; letter-spacing: -.01em; }
.brand b i { font-style: normal; color: var(--accent); }
.brand span { font-family: var(--mono); font-size: 12px; color: var(--muted); }
.nav { display: flex; flex-wrap: wrap; gap: 2px; }
.nav a {
  border-radius: 6px; padding: 7px 11px; font-size: 14px; color: var(--muted); text-decoration: none;
  display: inline-flex; gap: 6px; align-items: center;
}
.nav a:hover { color: var(--ink); background: var(--soft); }
.nav a[aria-current="page"] { color: var(--ink); background: var(--panel); box-shadow: inset 0 0 0 1px var(--line); font-weight: 600; }
.badge {
  min-width: 18px; height: 18px; padding: 0 5px; border-radius: 9px; background: var(--accent);
  color: var(--accent-ink); font-size: 11px; font-weight: 700; display: inline-grid; place-items: center;
}
.badge:empty { display: none; }
.who { display: flex; align-items: center; gap: 10px; font-size: 13px; flex-wrap: wrap; }
.menu-wrap { position: relative; }
.menu-wrap > summary { list-style: none; }
.menu-wrap > summary::-webkit-details-marker { display: none; }
.avatar {
  width: 36px; height: 36px; border-radius: 50%; display: grid; place-items: center; font-weight: 600;
  font-size: 13px; background: var(--accent-soft); color: var(--accent); cursor: pointer;
}
.menu {
  position: absolute; right: 0; top: 44px; z-index: 20; min-width: 220px; background: var(--panel);
  border: 1px solid var(--line); border-radius: 9px; box-shadow: 0 8px 24px rgba(0, 0, 0, .12);
  padding: 6px; display: grid;
}
.menu .mh { padding: 8px 10px; font-size: 13px; border-bottom: 1px solid var(--line); margin-bottom: 4px; overflow-wrap: anywhere; }
.menu a, .menu button {
  background: none; border: 0; text-align: left; padding: 8px 10px; border-radius: 6px; font-size: 14px;
  color: var(--ink); text-decoration: none; display: block; width: 100%;
}
.menu a:hover, .menu button:hover { background: var(--soft); }
.menu form { margin: 0; }

/* Banner and messages */
.banner, .messages {
  max-width: 1320px; margin: 0 auto 12px; border-radius: 8px; padding: 10px 14px; font-size: 14px;
}
.banner { background: var(--warn-soft); border: 1px solid var(--warn); }
.messages { list-style: none; display: grid; gap: 6px; padding: 0; }
.messages li { background: var(--accent-soft); border-radius: 8px; padding: 10px 14px; }
.messages li.error { background: var(--bad-soft); }
.messages li.success { background: var(--ok-soft); }

/* Work area */
.grid { max-width: 1320px; margin: 0 auto; }
.panel { background: var(--panel); border: 1px solid var(--line); border-radius: 10px; }
.main { padding: 28px; min-width: 0; }
@media (max-width: 520px) { .main { padding: 20px 16px; } }
.admin-wrap { display: grid; grid-template-columns: 190px minmax(0, 1fr); gap: 24px; }
@media (max-width: 760px) { .admin-wrap { grid-template-columns: minmax(0, 1fr); } }
.admin-body { min-width: 0; }
.side-nav { display: grid; gap: 2px; align-content: start; position: relative; }
.side-nav .grp {
  font: 500 11px/1 var(--mono); text-transform: uppercase; letter-spacing: .08em; color: var(--muted);
  padding: 12px 10px 6px;
}
.side-nav a {
  text-decoration: none; padding: 8px 10px; border-radius: 6px; font-size: 14px; color: var(--muted);
  display: flex; justify-content: space-between; align-items: center; gap: 8px;
}
.side-nav a:hover { background: var(--soft); color: var(--ink); }
.side-nav a[aria-current="page"] { background: var(--accent-soft); color: var(--accent); font-weight: 600; }
@media (max-width: 760px) {
  .side-nav {
    grid-auto-flow: column; grid-auto-columns: max-content; overflow-x: auto; padding-bottom: 6px;
    border-bottom: 1px solid var(--line);
  }
  .side-nav .grp { display: none; }
}

.eyebrow { font: 500 12px/1.3 var(--mono); color: var(--muted); margin-bottom: 6px; }
.h1, .main h1 { font-size: 26px; font-weight: 600; letter-spacing: -.015em; overflow-wrap: anywhere; }
.lead { margin-top: 8px; color: var(--muted); max-width: 66ch; }
.head { display: flex; flex-wrap: wrap; gap: 12px 20px; align-items: flex-start; justify-content: space-between; }
.sec { margin-top: 24px; }
.sec > h2, .h2 { font-size: 15px; font-weight: 600; margin-bottom: 10px; }
.prose { max-width: 70ch; display: grid; gap: 12px; }
.prose h2 { font-size: 17px; font-weight: 600; margin-top: 12px; }
.prose ul { margin: 0; padding-left: 20px; display: grid; gap: 4px; }
.prose code { font-family: var(--mono); font-size: .9em; background: var(--code); padding: 1px 4px; border-radius: 4px; }

.btn {
  display: inline-flex; align-items: center; gap: 8px; border-radius: 7px; padding: 9px 15px; font-weight: 600;
  font-size: 14px; border: 1px solid transparent; min-height: 40px; text-decoration: none; cursor: pointer;
}
.btn-p { background: var(--accent); color: var(--accent-ink); }
.btn-p:hover { filter: brightness(1.07); }
.btn-s { background: var(--panel); border-color: var(--line); color: var(--ink); }
.btn-s:hover { border-color: var(--muted); }
.btn-ok { background: var(--ok); color: var(--panel); }
.btn-bad { background: var(--panel); border-color: var(--bad); color: var(--bad); }
.btn-sm { padding: 5px 10px; font-size: 13px; min-height: 32px; font-weight: 500; }
.btn[disabled] { opacity: .45; cursor: not-allowed; }
.link { background: none; border: 0; padding: 0; color: var(--accent); font-size: inherit; text-align: left; text-decoration: underline; }
.row { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; }
.between { justify-content: space-between; }
form.inline { display: inline; margin: 0; }

.pill {
  display: inline-flex; align-items: center; gap: 6px; font-size: 12px; font-weight: 500; padding: 3px 9px;
  border-radius: 999px; white-space: nowrap;
}
.pill::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: currentColor; }
.p-ok { background: var(--ok-soft); color: var(--ok); }
.p-warn { background: var(--warn-soft); color: var(--warn); }
.p-bad { background: var(--bad-soft); color: var(--bad); }
.p-acc { background: var(--accent-soft); color: var(--accent); }
.p-mute { background: var(--soft); color: var(--muted); }
.tag { display: inline-block; font: 500 11px/1.4 var(--mono); padding: 2px 6px; border-radius: 4px; background: var(--soft); color: var(--muted); }

/* Cards, lists, tables */
.todo {
  border: 1px solid var(--warn); background: var(--warn-soft); border-radius: 9px; padding: 14px 16px;
  display: flex; flex-wrap: wrap; gap: 10px 16px; align-items: center; justify-content: space-between;
}
.todo b { display: block; }
.empty { border: 1px dashed var(--line); border-radius: 9px; padding: 18px; color: var(--muted); }
.list { margin: 0; padding: 0; list-style: none; border: 1px solid var(--line); border-radius: 9px; }
.list li { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 2px 14px; padding: 12px 14px; align-items: center; }
.list li + li { border-top: 1px solid var(--line); }
.list li.unread .t::before {
  content: ""; display: inline-block; width: 8px; height: 8px; border-radius: 50%; background: var(--accent);
  margin-right: 8px; transform: translateY(-1px);
}
.list .t { font-weight: 500; overflow-wrap: anywhere; }
.list a.t { color: var(--ink); text-decoration: none; }
.list a.t:hover { text-decoration: underline; }
.list .d { grid-column: 1; font-size: 13px; color: var(--muted); }
.list .r { grid-row: 1 / 3; grid-column: 2; display: flex; gap: 8px; align-items: center; }
.tbl-box { overflow-x: auto; border: 1px solid var(--line); border-radius: 9px; position: relative; }
table { border-collapse: collapse; width: 100%; font-size: 14px; }
th { font-weight: 600; font-size: 12px; color: var(--muted); text-align: left; padding: 10px 12px; background: var(--soft); white-space: nowrap; }
td { padding: 10px 12px; border-top: 1px solid var(--line); vertical-align: middle; }
.matrix td, .matrix th { text-align: center; }
.matrix td:first-child, .matrix th:first-child { text-align: left; }
.yes { color: var(--ok); font-weight: 700; }
.no { color: var(--muted); }
.tiles { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; }
@media (max-width: 820px) { .tiles { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.tile { border: 1px solid var(--line); border-radius: 9px; padding: 14px; background: var(--panel); color: var(--ink); text-decoration: none; display: block; }
.tile b { display: block; font-size: 26px; font-weight: 600; font-variant-numeric: tabular-nums; margin-top: 2px; }
.tile span { font-size: 13px; color: var(--muted); }
.tile.warn { border-color: var(--warn); }
.cols { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; }
@media (max-width: 820px) { .cols { grid-template-columns: minmax(0, 1fr); } }
.kv { display: grid; grid-template-columns: minmax(120px, 200px) minmax(0, 1fr); gap: 8px 16px; font-size: 14px; margin: 0; }
@media (max-width: 520px) { .kv { grid-template-columns: minmax(0, 1fr); } }
.kv dt { color: var(--muted); }
.kv dd { margin: 0; min-width: 0; overflow-wrap: anywhere; }
.release { display: grid; gap: 16px; padding: 0; list-style: none; }
.release > li { border: 1px solid var(--line); border-radius: 9px; padding: 16px; }
.release h2 { margin: 0 0 4px; font-size: 1.05rem; }
.release .date { color: var(--muted); font-weight: 400; font-size: .9rem; }
.release ul { margin: 0; padding-left: 20px; }

/* Tabs */
.tabs { display: flex; gap: 2px; border-bottom: 1px solid var(--line); overflow-x: auto; margin-top: 22px; }
.tabs a {
  border-bottom: 2px solid transparent; padding: 9px 12px; font-size: 14px; color: var(--muted);
  white-space: nowrap; margin-bottom: -1px; text-decoration: none;
}
.tabs a[aria-current="page"] { color: var(--ink); border-bottom-color: var(--accent); font-weight: 600; }

/* Forms */
.form { display: grid; gap: 16px; max-width: 640px; }
.field { display: grid; gap: 6px; }
.field > label, .lbl { font-weight: 600; font-size: 14px; }
.hint, .helptext { font-size: 13px; color: var(--muted); }
.errorlist { margin: 0; padding: 0; list-style: none; color: var(--bad); font-size: 13px; }
textarea, input[type=text], input[type=email], input[type=password], input[type=date], input[type=time],
input[type=number], input[type=search], input[type=tel], select {
  width: 100%; font: inherit; color: var(--ink); background: var(--panel); border: 1px solid var(--line);
  border-radius: 7px; padding: 9px 12px; min-height: 40px;
}
textarea { min-height: 110px; resize: vertical; }
.check { display: flex; gap: 10px; align-items: flex-start; font-size: 14px; }
.check input { margin-top: 4px; width: 16px; height: 16px; flex: none; accent-color: var(--accent); }
.inline-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
@media (max-width: 620px) { .inline-grid { grid-template-columns: minmax(0, 1fr); } }
.note { border-radius: 8px; padding: 12px 14px; font-size: 14px; background: var(--soft); overflow-wrap: anywhere; }
.note.warn { background: var(--warn-soft); }
.note.warn b { color: var(--warn); }
.note.bad { background: var(--bad-soft); }
.note.bad b { color: var(--bad); }
.preview-box { border: 1px solid var(--line); border-radius: 9px; padding: 16px; overflow-wrap: anywhere; }

/* Sign-in pages (allauth) */
.auth { max-width: 440px; margin: 12px auto 0; display: grid; gap: 14px; }
.auth form { display: grid; gap: 12px; }
.auth form p { margin: 0; display: grid; gap: 6px; }
.auth label { font-weight: 600; font-size: 14px; }
.auth input[type=checkbox] { width: 16px; height: 16px; justify-self: start; }
.auth button[type=submit], .auth form button {
  display: inline-flex; justify-content: center; border-radius: 7px; padding: 9px 15px; font-weight: 600;
  font-size: 14px; border: 1px solid transparent; min-height: 40px; background: var(--accent); color: var(--accent-ink);
}
.auth form .btn-s, .auth .btn-s { background: var(--panel); color: var(--ink); border: 1px solid var(--line); }
.auth form .btn-bad { background: var(--panel); color: var(--bad); border: 1px solid var(--bad); }
.auth-wide { max-width: 600px; }
.auth .check { font-weight: 400; }

/* Account setup and security (#4) */
.steps-h { display: flex; flex-wrap: wrap; gap: 6px; margin: 4px 0 0; padding: 0; list-style: none; }
.steps-h li { font-size: 12px; padding: 4px 10px; border-radius: 999px; background: var(--soft); color: var(--muted); }
.steps-h li.done { background: var(--ok-soft); color: var(--ok); }
.steps-h li.now { background: var(--accent); color: var(--accent-ink); }
.qr-row { gap: 20px; align-items: flex-start; }
.qr-row .form { flex: 1; min-width: 200px; }
img.qr { width: 160px; height: 160px; background: #fff; border: 6px solid #fff; outline: 1px solid var(--line); border-radius: 4px; }
.codes {
  display: grid; grid-template-columns: repeat(2, max-content); gap: 6px 24px; font: 500 14px var(--mono);
  background: var(--code); border: 1px solid var(--line); border-radius: 8px; padding: 12px 16px;
}
.toggle { display: flex; justify-content: space-between; gap: 16px; align-items: center; padding: 12px 0; border-top: 1px solid var(--line); }
.toggle:first-of-type { border-top: 0; }
.toggle input { width: 20px; height: 20px; accent-color: var(--accent); flex: none; }
.mail-prefs { max-width: 640px; }

/* Footer */
.foot {
  max-width: 1320px; margin: 20px auto 0; display: flex; flex-wrap: wrap; gap: 6px 16px; font-size: 13px;
  color: var(--muted); align-items: center;
}
.foot a { color: var(--muted); }
.foot a:hover { color: var(--ink); }
.lang-switch { display: inline-flex; border: 1px solid var(--line); border-radius: 7px; overflow: hidden; margin: 0; }
.lang-switch button { background: var(--panel); border: 0; padding: 4px 10px; font-size: 13px; color: var(--muted); }
.lang-switch button + button { border-left: 1px solid var(--line); }
.lang-switch button[aria-pressed="true"] { background: var(--ink); color: var(--bg); }

/* Dialog (in-page confirmation, never a browser dialog) */
dialog.dlg {
  border: 1px solid var(--line); border-radius: 12px; max-width: 480px; width: calc(100% - 32px); padding: 22px;
  background: var(--panel); color: var(--ink);
}
dialog.dlg::backdrop { background: rgba(10, 12, 14, .45); }
dialog.dlg h2 { font-size: 18px; font-weight: 600; margin-bottom: 12px; }
dialog.dlg .row { margin-top: 16px; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
}

/* User administration (#5): stacked action buttons, centred count column, search row. */
.stack { display: grid; gap: 8px; justify-items: start; }
.stack form { margin: 0; }
td.c { text-align: center; }
fieldset.field { border: 0; margin: 0; padding: 0; min-width: 0; }

/* Website administration (#2): borderless fieldsets that disable a form for readers, fixed
   rows of the approval matrix, the job log, the danger zone. */
fieldset.plain { border: 0; margin: 0; padding: 0; min-width: 0; }
.lock { font-size: 12px; color: var(--muted); }
pre.log {
  font: 500 13px/1.5 var(--mono); background: var(--code); border: 1px solid var(--line); border-radius: 8px;
  padding: 12px 16px; white-space: pre-wrap; overflow-wrap: anywhere; margin: 0;
}
.danger-zone { max-width: 640px; justify-items: stretch; }
.toggle label { display: grid; gap: 2px; }

/* --- Change requests (#6): list filters, request form, order page --------------------------- */
.chips { display: flex; flex-wrap: wrap; gap: 6px; }
.chips a { background: var(--panel); border: 1px solid var(--line); border-radius: 999px; padding: 5px 12px;
  font-size: 13px; color: var(--muted); text-decoration: none; }
.chips a[aria-current="page"] { background: var(--ink); color: var(--bg); border-color: var(--ink); }
.search { max-width: 260px; }
.list li[hidden] { display: none; }
[data-show-when-empty][hidden] { display: none; }
.grow { flex: 1; min-width: 160px; }

.kinds { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; border: 0; padding: 0; margin: 0; }
@media (max-width: 620px) { .kinds { grid-template-columns: minmax(0, 1fr); } }
.kind { display: block; text-align: left; background: var(--panel); border: 1px solid var(--line);
  border-radius: 9px; padding: 12px 14px; cursor: pointer; }
.kind b { display: block; font-weight: 600; }
.kind span { display: block; font-size: 13px; color: var(--muted); margin-top: 2px; }
.kind:has(input:checked) { border-color: var(--accent); box-shadow: inset 0 0 0 1px var(--accent); background: var(--accent-soft); }
.kind:has(input:focus-visible) { outline: 2px solid var(--accent); outline-offset: 2px; }
/* What belongs to one kind only shows while that kind is chosen; the legal notice follows the page. */
.request [data-for] { display: none; }
.request:has(#kind-description:checked) [data-for~="description"],
.request:has(#kind-elements:checked) [data-for~="elements"],
.request:has(#kind-website_zip:checked) [data-for~="website_zip"] { display: revert; }
.request:has(#kind-description:checked) div[data-for~="description"],
.request:has(#kind-elements:checked) div[data-for~="elements"],
.request:has(#kind-website_zip:checked) div[data-for~="website_zip"] { display: block; }
.request .legal-note { display: none !important; }
.request:has(#kind-description:checked) .form:has(option[data-legal]:checked) .legal-note,
.request:has(#kind-elements:checked) .form:has(option[data-legal]:checked) .legal-note { display: block !important; }
.request .budget-stop .row { margin-top: 10px; }
.drop { border: 1.5px dashed var(--line); border-radius: 9px; padding: 14px; display: grid; gap: 10px; }
.file { display: flex; gap: 12px; align-items: center; min-width: 0; flex-wrap: wrap; }
.file .note-input { max-width: 240px; }
.ficon { width: 38px; height: 46px; border-radius: 4px; background: var(--soft); border: 1px solid var(--line);
  display: grid; place-items: center; font: 500 10px var(--mono); color: var(--muted); flex: none; }
input[type=file] { max-width: 100%; font: inherit; }

.track { margin: 0; padding: 0; list-style: none; }
.track li { display: grid; grid-template-columns: 28px minmax(0, 1fr); gap: 12px; padding-bottom: 16px; position: relative; }
.track li:not(:last-child)::after { content: ""; position: absolute; left: 13px; top: 28px; bottom: 2px; width: 2px; background: var(--line); }
.track li.done:not(:last-child)::after { background: var(--ok); }
.dot { width: 28px; height: 28px; border-radius: 50%; display: grid; place-items: center; border: 2px solid var(--line);
  background: var(--panel); font-size: 13px; font-weight: 700; color: var(--muted); }
li.done .dot { border-color: var(--ok); background: var(--ok); color: var(--panel); }
li.run .dot { border-color: var(--accent); }
li.run .dot::before { content: ""; width: 10px; height: 10px; border-radius: 50%; background: var(--accent); animation: puls 1s ease-in-out infinite; }
li.fail .dot { border-color: var(--bad); background: var(--bad); color: var(--panel); }
@keyframes puls { 50% { opacity: .25; } }
@media (prefers-reduced-motion: reduce) { li.run .dot::before { animation: none; } }
.track b { display: block; font-weight: 600; }
.track small { display: block; color: var(--muted); font-size: 13px; }
.track li.wait b { color: var(--muted); font-weight: 500; }

.compare { display: flex; gap: 6px; margin-bottom: 10px; flex-wrap: wrap; }
.compare a { background: var(--panel); border: 1px solid var(--line); border-radius: 6px; padding: 5px 11px;
  font-size: 13px; color: var(--muted); text-decoration: none; }
.compare a[aria-current="true"] { background: var(--ink); color: var(--bg); border-color: var(--ink); }
.browser { border: 1px solid var(--line); border-radius: 9px; overflow: hidden; margin-inline: auto; background: var(--panel); }
.browser.phone { max-width: 300px; }
.bbar { display: flex; align-items: center; gap: 8px; padding: 8px 12px; background: var(--soft);
  border-bottom: 1px solid var(--line); font: 400 12px var(--mono); color: var(--muted); min-width: 0; }
.bbar span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.bbar i { width: 9px; height: 9px; border-radius: 50%; background: var(--line); flex: none; }
.shot { display: block; width: 100%; height: auto; }
.changes { margin: 0; padding: 0; list-style: none; display: grid; gap: 8px; }
.changes li { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 10px; align-items: baseline; }
.changes li::before { content: ""; width: 8px; height: 8px; border-radius: 2px; background: var(--accent); }
.checks { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 6px 18px; margin: 0; padding: 0; list-style: none; font-size: 14px; }
@media (max-width: 620px) { .checks { grid-template-columns: minmax(0, 1fr); } }
.checks li { display: flex; gap: 8px; align-items: baseline; flex-wrap: wrap; }
.checks li::before { content: "✓"; color: var(--ok); font-weight: 700; }
.checks li.fixed::before { content: "↻"; color: var(--warn); }
.checks li.fail::before { content: "✕"; color: var(--bad); }
.msgs { display: grid; gap: 12px; }
.msg { border: 1px solid var(--line); border-radius: 9px; padding: 12px 14px; overflow-wrap: anywhere; }
.msg.me { background: var(--accent-soft); border-color: transparent; }
.msg.sys { background: var(--soft); border-color: transparent; font-size: 14px; }
.msg .mh { font-size: 12px; color: var(--muted); margin-bottom: 4px; display: flex; gap: 8px; flex-wrap: wrap; }
.request .form { grid-template-columns: minmax(0, 1fr); }
.request input[type=file] { min-width: 0; width: 100%; }
.kinds { min-width: 0; }

/* Approvals and release (#7): approval boxes, diff, tiles, budget bar, decision form. */
.tile.bad { border-color: var(--bad); }
.approvals { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
@media (max-width: 620px) { .approvals { grid-template-columns: minmax(0, 1fr); } }
.appr { border: 1px solid var(--line); border-radius: 9px; padding: 12px 14px; }
.appr b { display: block; font-size: 14px; }
.diff { background: var(--code); border: 1px solid var(--line); border-radius: 8px; padding: 12px 14px; font: 400 12.5px/1.6 var(--mono); overflow-x: auto; white-space: pre; margin: 0; }
.diff .a { color: var(--ok); }
.diff .r { color: var(--bad); }
.diff .h { color: var(--muted); }
progress.bar2 { display: block; width: 100%; height: 6px; margin-top: 8px; border: 0; border-radius: 3px; background: var(--line); overflow: hidden; appearance: none; }
progress.bar2::-webkit-progress-bar { background: var(--line); border-radius: 3px; }
progress.bar2::-webkit-progress-value { background: var(--accent); border-radius: 3px; }
progress.bar2::-moz-progress-bar { background: var(--accent); border-radius: 3px; }
progress.bar2.warn::-webkit-progress-value { background: var(--warn); }
progress.bar2.warn::-moz-progress-bar { background: var(--warn); }
.when { display: flex; flex-wrap: wrap; gap: 8px 16px; align-items: center; }
.when label { display: inline-flex; gap: 6px; align-items: center; font-weight: 400; }
input[type=datetime-local] { font: inherit; padding: 8px 10px; border: 1px solid var(--line); border-radius: 7px; background: var(--panel); color: var(--ink); max-width: 100%; }

/* Audit log dialog (#8): wider, the body scrolls so the footer stays reachable */
dialog.dlg.dlg-wide { max-width: 720px; }
dialog.dlg .dlg-body { max-height: 60vh; overflow: auto; }
dialog.dlg .dlg-body table { border-collapse: collapse; }
dialog.dlg .dlg-body th, dialog.dlg .dlg-body td { text-align: left; padding: 2px 8px 2px 0; vertical-align: top; }

/* Billing (#9): plan cards, consumption meter, table cells. */
.plans { display: grid; grid-template-columns: repeat(auto-fit, minmax(210px, 1fr)); gap: 12px; }
.plan { border: 1px solid var(--line); border-radius: 9px; padding: 14px; display: grid; gap: 8px; align-content: start; text-align: left; background: var(--panel); min-width: 0; }
.plan.cur { border-color: var(--accent); box-shadow: inset 0 0 0 1px var(--accent); }
.plan.muted { opacity: .7; }
.price { font-size: 24px; font-weight: 600; font-variant-numeric: tabular-nums; }
.price small { font-size: 13px; font-weight: 400; color: var(--muted); }
.meter-card { border: 1px solid var(--line); border-radius: 9px; padding: 16px; display: grid; gap: 8px; min-width: 0; }
form.inline { display: inline; }
td.r, th.r { text-align: right; }
