/* Bowtie Risk Platform - shared stylesheet.
   Deliberately light-only: no dark-mode variants, self-contained
   (no external font/CDN dependency) so it is safe to deploy behind
   locked-down government or corporate networks. */

:root {
  --bg: #FFFFFF;
  --bg-alt: #F7F6F2;
  --ink: #22252B;
  --ink-muted: #5B6270;
  --border: #E2E0D8;

  --primary: #0F6E63;
  --primary-dark: #0B5147;
  --primary-soft: #DCEEEB;

  --danger: #B5531C;
  --danger-soft: #F3E4D8;

  --sev-low: #3F8F5F;
  --sev-medium: #C68A2E;
  --sev-high: #C2571B;
  --sev-severe: #B5531C;

  /* Soft/ink pairs of the same four severity steps - used by the Raporty
     "pill" and node-flow components (report cards, area map, radar),
     which need a light tinted background + readable dark text instead of
     the solid badge fill used elsewhere in the app. */
  --sev-low-soft: #E5F2EA;    --sev-low-ink: #2E6B45;
  --sev-medium-soft: #FBF1DE; --sev-medium-ink: #8A6100;
  --sev-high-soft: #FDECE4;   --sev-high-ink: #B8481F;
  --sev-severe-soft: #FBE7E7; --sev-severe-ink: #A11F1F;

  --mitigative: #4E5F78;
  --detect: #7D5BA6;
  --detect-soft: #EFE7F5;

  /* Extra accent palette for the Raporty "Warstwa" bands (area map, radar,
     matrix, heatmap, roadmap) - cycled per band/area so each layer of the
     report reads as visually distinct. --primary doubles as the teal slot. */
  --accent-navy: #1D3A5C;   --accent-navy-soft: #E6EDF5;
  --accent-maroon: #8A2A20; --accent-maroon-soft: #F5E6E3;
  --accent-plum: #5B4B77;   --accent-plum-soft: #EFE9F5;
  --accent-gold: #B8943A;   --accent-gold-soft: #F9F3E6;
  --accent-green: #1A5C2A;  --accent-green-soft: #EAF5EC;
  --accent-brown: #8A5A28;  --accent-brown-soft: #F5ECE0;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: -apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  line-height: 1.5;
  font-size: 15px;
}

a { color: var(--primary); text-decoration: none; }
a:hover { text-decoration: underline; }

.topbar {
  background: var(--bg);
  border-bottom: 1px solid var(--border);
  padding: 0 24px;
  display: flex;
  align-items: center;
  gap: 24px;
  flex-wrap: wrap;
}

.topbar .brand {
  font-weight: 700;
  padding: 14px 0;
  color: var(--primary-dark);
  white-space: nowrap;
}

.topbar nav {
  display: flex;
  gap: 4px;
  flex-wrap: wrap;
}

.topbar nav a {
  color: var(--ink-muted);
  padding: 8px 10px;
  border-radius: 6px;
  font-size: 13.5px;
}

.topbar nav a:hover { background: var(--bg-alt); text-decoration: none; color: var(--ink); }

.topbar .spacer { flex: 1; }

.client-switcher, .user-box {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  color: var(--ink-muted);
}

.client-switcher select {
  font-size: 13px;
  padding: 4px 6px;
}

.container {
  max-width: 1100px;
  margin: 0 auto;
  padding: 32px 24px 64px;
}

.container.wide { max-width: 1400px; }

h1 { font-size: 1.6rem; margin: 0 0 6px; }
h2 { font-size: 1.15rem; margin: 32px 0 12px; }
h3 { font-size: 1rem; margin: 20px 0 8px; }

.page-header {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 24px;
  flex-wrap: wrap;
}

.subtitle { color: var(--ink-muted); margin: 0; font-size: 0.95rem; }

.card {
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 20px 24px;
  margin-bottom: 20px;
}

.card.tight { padding: 14px 18px; }

table {
  width: 100%;
  border-collapse: collapse;
  font-size: 14px;
}

th, td {
  text-align: left;
  padding: 9px 10px;
  border-bottom: 1px solid var(--border);
  vertical-align: top;
}

th {
  color: var(--ink-muted);
  font-weight: 600;
  font-size: 12.5px;
  text-transform: uppercase;
  letter-spacing: 0.03em;
}

tr:last-child td { border-bottom: none; }

.empty-row td { color: var(--ink-muted); font-style: italic; }

form.inline { display: inline; }

.form-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 14px 20px;
}

label {
  display: block;
  font-size: 13px;
  font-weight: 600;
  margin-bottom: 4px;
  color: var(--ink);
}

label .hint { font-weight: 400; color: var(--ink-muted); }

input[type=text], input[type=email], input[type=password], input[type=number],
input[type=date], select, textarea {
  width: 100%;
  padding: 8px 10px;
  border: 1px solid var(--border);
  border-radius: 6px;
  font-size: 14px;
  font-family: inherit;
  background: var(--bg);
  color: var(--ink);
}

textarea { resize: vertical; min-height: 70px; }

.field { margin-bottom: 14px; }

.actions { margin-top: 18px; display: flex; gap: 10px; }

.btn {
  display: inline-block;
  padding: 8px 16px;
  border-radius: 6px;
  border: 1px solid var(--primary);
  background: var(--primary);
  color: #fff;
  font-size: 13.5px;
  font-weight: 600;
  cursor: pointer;
}
.btn:hover { background: var(--primary-dark); border-color: var(--primary-dark); text-decoration: none; }

.btn.secondary { background: var(--bg); color: var(--primary); }
.btn.secondary:hover { background: var(--primary-soft); }

.btn.danger { background: var(--danger); border-color: var(--danger); }
.btn.danger:hover { background: #93400f; border-color: #93400f; }

.btn.small { padding: 4px 10px; font-size: 12.5px; }

.badge {
  display: inline-block;
  padding: 2px 9px;
  border-radius: 999px;
  font-size: 11.5px;
  font-weight: 600;
  color: #fff;
  background: var(--ink-muted);
}

.badge-low { background: var(--sev-low); }
.badge-medium { background: var(--sev-medium); }
.badge-high { background: var(--sev-high); }
.badge-severe { background: var(--sev-severe); }

.badge-preventive { background: var(--primary); }
.badge-mitigative { background: var(--mitigative); }

.pill {
  display: inline-block;
  padding: 1px 8px;
  border-radius: 999px;
  font-size: 11.5px;
  border: 1px solid var(--border);
  color: var(--ink-muted);
  background: var(--bg-alt);
}

.flash {
  padding: 10px 14px;
  border-radius: 8px;
  margin-bottom: 18px;
  font-size: 14px;
}
.flash.success { background: var(--primary-soft); color: var(--primary-dark); }
.flash.error   { background: var(--danger-soft); color: var(--danger); }

.help-text { color: var(--ink-muted); font-size: 13px; margin-top: 4px; }

.stat-row { display: flex; gap: 16px; flex-wrap: wrap; margin-bottom: 24px; }
.stat-tile {
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 14px 18px;
  min-width: 150px;
}
.stat-tile .value { font-size: 1.6rem; font-weight: 700; color: var(--primary-dark); }
.stat-tile .label { font-size: 12.5px; color: var(--ink-muted); text-transform: uppercase; letter-spacing: 0.03em; }

.tree ul { list-style: none; margin: 0; padding-left: 22px; }
.tree > ul { padding-left: 0; }
.tree li { margin: 4px 0; }
.tree .node {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 3px 8px;
  border-radius: 6px;
}
.tree .node:hover { background: var(--bg-alt); }

.bowtie-columns {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 28px;
  align-items: start;
}

.lane-title {
  font-size: 12.5px;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--ink-muted);
  margin-bottom: 10px;
}

.top-event-box {
  background: var(--danger-soft);
  border: 1px solid var(--danger);
  border-radius: 10px;
  padding: 16px 20px;
  margin: 20px 0;
}
.top-event-box h3 { margin: 0 0 6px; color: var(--danger); }

.chain-item {
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 12px 14px;
  margin-bottom: 10px;
  background: var(--bg);
}
.chain-item.threat, .chain-item.consequence { background: var(--bg-alt); }
.chain-item.barrier { border-color: var(--primary); background: var(--primary-soft); }

.attr-list { margin: 8px 0 0; padding: 0; list-style: none; font-size: 13px; color: var(--ink-muted); }
.attr-list li { padding: 2px 0; }

/* Zwijalne sekcje formularzy - drugorzędne dane, niepotrzebne do każdego
   zadania (patrz raport UX wrz. 2026, postulaty 1 i 3): warstwa ilościowa,
   czynniki eskalujące, historia ocen, pełna lista dostępów. */
details.disclosure {
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 0 18px;
  margin: 20px 0;
  background: var(--bg-alt);
}
details.disclosure > summary {
  cursor: pointer;
  padding: 14px 0;
  font-size: 1rem;
  font-weight: 700;
  color: var(--ink);
  list-style: none;
}
details.disclosure > summary::-webkit-details-marker { display: none; }
details.disclosure > summary::before { content: "▸ "; color: var(--ink-muted); }
details.disclosure[open] > summary::before { content: "▾ "; }
details.disclosure[open] > summary { padding-bottom: 6px; }
details.disclosure > *:not(summary) { margin-top: 0; }
details.disclosure > :last-child { padding-bottom: 16px; }

/* Zwarta lista struktury procesu + panel boczny (processes/steps.php) -
   przebudowa wg raportu UX wrz. 2026, postulat 1 i 3: lista pokazuje tylko
   to, co potrzebne do orientacji; formularz otwiera się obok, nie pod spodem. */
.steps-layout { display: grid; grid-template-columns: 1fr 380px; gap: 18px; align-items: start; margin-bottom: 22px; }
@media (max-width: 900px) { .steps-layout { grid-template-columns: 1fr; } }

.step-row-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 9px 10px;
  border: 1px solid var(--border);
  border-radius: 8px;
  margin-bottom: 6px;
  background: var(--bg);
}
.step-row-item.checkpoint { border-color: #D9CBEA; background: #FCFAFE; }
.step-row-item.active { border-color: var(--primary); background: var(--primary-soft); }
.step-row-item .grip { color: var(--ink-muted); font-size: 15px; flex-shrink: 0; line-height: 1; }
.step-row-item .row-link { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 1px; color: inherit; }
.step-row-item .row-link:hover .row-name { color: var(--primary-dark); text-decoration: underline; }
.step-row-item .row-name { font-weight: 700; font-size: 13.5px; color: var(--ink); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.step-row-item .row-meta { font-size: 11.5px; color: var(--ink-muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.step-row-item .type-pill { flex-shrink: 0; }
.step-row-item .row-actions { display: flex; gap: 4px; flex-shrink: 0; }
.step-row-item .row-actions .btn.small { padding: 3px 8px; font-size: 12px; }

.type-pill {
  display: inline-block;
  font-size: 11px;
  font-weight: 700;
  padding: 2px 9px;
  border-radius: 20px;
  white-space: nowrap;
}
.type-pill.zadanie { background: var(--primary-soft); color: var(--primary-dark); }
.type-pill.bramka { background: #FCEFD9; color: var(--sev-medium); }

.drawer-panel {
  border: 1px solid var(--border);
  border-radius: 10px;
  background: var(--bg);
  padding: 16px;
  position: sticky;
  top: 16px;
}
.drawer-panel h3 { margin: 0 0 14px; font-size: 15px; }
.drawer-panel .drawer-empty { color: var(--ink-muted); font-size: 13.5px; text-align: center; padding: 34px 10px; }

footer.app-footer {
  text-align: center;
  color: var(--ink-muted);
  font-size: 12.5px;
  padding: 24px;
}

/* --- Bowtie diagram (SVG foreignObject cards) ---------------------------- */

.dcard {
  box-sizing: border-box;
  width: 100%;
  height: 100%;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 10px 12px;
  font-family: -apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

.dcard-threat, .dcard-consequence { background: var(--bg-alt); }

.dcard-knot {
  background: var(--danger-soft);
  border-color: var(--danger);
  justify-content: center;
  align-items: center;
  text-align: center;
}
.dcard-knot .dcard-label { color: var(--danger); }
.dcard-knot .dcard-desc { -webkit-line-clamp: 5; font-size: 14px; }

.dcard-label {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  color: var(--ink-muted);
  margin-bottom: 4px;
}

.dcard-desc {
  font-weight: 600;
  font-size: 13px;
  color: var(--ink);
  display: -webkit-box;
  -webkit-line-clamp: 4;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.dcard-meta {
  font-size: 11.5px;
  color: var(--ink-muted);
  margin-top: auto;
  padding-top: 6px;
}

.dcard-link {
  font-size: 12px;
  margin-top: 4px;
  color: var(--primary);
  text-decoration: none;
  cursor: pointer;
}
.dcard-link:hover { text-decoration: underline; }

.dcard-actions {
  display: flex;
  gap: 10px;
  margin-top: auto;
  padding-top: 6px;
  font-size: 12px;
}

.dcard-empty {
  align-items: center;
  justify-content: center;
  text-align: center;
  color: var(--ink-muted);
  font-size: 13px;
}

.dcard-add {
  cursor: pointer;
  border-style: dashed;
  color: var(--ink-muted);
  transition: background 0.12s ease, border-color 0.12s ease;
}
.dcard-add:hover {
  background: var(--primary-soft);
  border-color: var(--primary);
  color: var(--primary-dark);
}
.dcard-knot.dcard-add {
  border-style: solid;
}
.dcard-knot.dcard-add:hover {
  background: var(--danger-soft);
  border-color: var(--danger);
  color: var(--danger);
}

/* --- Bowtie modal (popup forms opened from the interactive diagram) ------ */

dialog.bowtie-modal {
  border: none;
  border-radius: 10px;
  width: min(720px, 92vw);
  max-height: 88vh;
  padding: 0;
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.18);
  background: var(--bg);
  color: var(--ink);
}
dialog.bowtie-modal::backdrop {
  background: rgba(34, 37, 43, 0.45);
}
dialog.bowtie-modal .modal-header {
  display: flex;
  justify-content: flex-end;
  padding: 8px 8px 0;
}
dialog.bowtie-modal .modal-close {
  background: none;
  border: none;
  font-size: 22px;
  line-height: 1;
  color: var(--ink-muted);
  cursor: pointer;
  padding: 4px 8px;
}
dialog.bowtie-modal .modal-close:hover { color: var(--ink); }
dialog.bowtie-modal .modal-body {
  padding: 4px 24px 24px;
  overflow-y: auto;
  max-height: calc(88vh - 40px);
}
dialog.bowtie-modal .modal-body .card {
  border: none;
  padding: 0;
  box-shadow: none;
}

/* =====================================================================
   Sidebar navigation shell (replaces the old .topbar layout) and the
   screens introduced alongside it: Obszary odpowiedzialności, Procesy,
   Alerty, and the visual pieces the new Atrybuty grouping reuses.
   The .topbar rules above are now unused dead weight kept only in case
   a page still references them; every page goes through layout_top.php.
   ===================================================================== */

.shell { display: flex; min-height: 100vh; }

.sidebar { width: 246px; flex-shrink: 0; background: var(--bg); border-right: 1px solid var(--border); display: flex; flex-direction: column; }
.sidebar-brand { display: flex; align-items: center; gap: 9px; padding: 18px 20px; border-bottom: 1px solid var(--border); }
.sidebar-brand .name { font-weight: 700; color: var(--primary-dark); font-size: 15.5px; }
.sidebar-client { margin: 14px 20px 6px; padding: 7px 11px; background: var(--bg-alt); border: 1px solid var(--border); border-radius: 7px; font-size: 12.5px; color: var(--ink-muted); }
.sidebar-client strong { color: var(--ink); font-weight: 600; }
.nav-groups { flex: 1; padding: 6px 12px; overflow-y: auto; }
.nav-group { display: block; }
.nav-label-toggle { display: flex; align-items: center; justify-content: space-between; gap: 6px; width: 100%; background: none; border: none; margin: 0; padding: 16px 10px 6px; font: inherit; font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.05em; color: var(--ink-muted); cursor: pointer; text-align: left; }
.nav-label-toggle:hover { color: var(--ink); }
.nav-chevron { flex-shrink: 0; font-size: 9px; line-height: 1; color: var(--ink-muted); transform: rotate(-90deg); transition: transform .15s ease; }
.nav-group.open .nav-chevron { transform: rotate(0deg); }
.nav-item { display: flex; align-items: center; gap: 10px; padding: 8px 10px; border-radius: 7px; font-size: 13.8px; color: var(--ink-muted); font-weight: 500; cursor: pointer; }
.nav-item:hover { background: var(--bg-alt); color: var(--ink); text-decoration: none; }
.nav-item.active { background: var(--primary-soft); color: var(--primary-dark); font-weight: 700; }
.nav-item .ic { flex-shrink: 0; display: flex; }
.nav-item .nav-badge { margin-left: auto; background: var(--danger); color: #fff; font-size: 10.5px; font-weight: 700; padding: 1px 6px; border-radius: 999px; }
.sidebar-foot { border-top: 1px solid var(--border); padding: 12px 20px; font-size: 12.5px; color: var(--ink-muted); }

.main { flex: 1; min-width: 0; }

/* ---- Obszary odpowiedzialności ---- */
.areas-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
@media (max-width: 900px) { .areas-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 620px) { .areas-grid { grid-template-columns: 1fr; } .sidebar { width: 210px; } }
.icon-tile { width: 40px; height: 40px; border-radius: 10px; background: var(--primary-soft); display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
/* .area-card jest teraz zwykłym <div>, nie <a> (patrz areas/index.php,
   2026-09-04) - trzy statystyki mają własne, osobne odnośniki, więc cały
   kafelek nie może być jednym wspólnym linkiem. Hover pozostaje na całym
   kafelku, żeby wyglądał tak samo jak wcześniej. */
.card.area-card { transition: box-shadow .12s ease, border-color .12s ease; }
.card.area-card:hover { border-color: var(--primary); box-shadow: 0 4px 14px rgba(15,110,99,0.08); }
.card.area-card .pill:hover { border-color: var(--primary); color: var(--primary-dark); }

/* ---- Alerty ---- */
.alert-card { display: flex; gap: 14px; padding: 16px 18px; border: 1px solid var(--border); border-radius: 10px; background: var(--bg); margin-bottom: 10px; border-left-width: 4px; }
.alert-card .ic { flex-shrink: 0; margin-top: 1px; }
.alert-title { font-weight: 700; font-size: 14.5px; margin-bottom: 3px; }
.alert-desc { font-size: 13.5px; color: var(--ink-muted); margin-bottom: 8px; }

/* ---- Procesy ---- */
.badge-signal { background: var(--detect); }

/* ---- Projektowanie procesów: kroki, RACI, narzędzia ---- */
.flow-strip { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; margin-bottom: 22px; }
@media (max-width: 700px) { .flow-strip { grid-template-columns: 1fr; } }
.flow-box { border: 1px solid var(--border); border-radius: 8px; padding: 12px 16px; background: var(--bg-alt); }
.flow-box .label { font-size: 11px; text-transform: uppercase; letter-spacing: 0.04em; font-weight: 700; color: var(--primary-dark); margin-bottom: 4px; }
.flow-box p { margin: 0; font-size: 13.5px; }

.summary-bar { display: flex; gap: 22px; flex-wrap: wrap; border-top: 1px solid var(--border); border-bottom: 1px solid var(--border); padding: 10px 2px; margin-bottom: 22px; font-size: 13px; color: var(--ink-muted); }
.summary-bar b { color: var(--ink); font-size: 14px; }

.steps { position: relative; }
.step { display: flex; gap: 16px; }
.step .rail { display: flex; flex-direction: column; align-items: center; width: 30px; flex-shrink: 0; }
.step .num { width: 26px; height: 26px; border-radius: 50%; background: var(--primary-soft); color: var(--primary-dark); display: flex; align-items: center; justify-content: center; font-weight: 700; font-size: 12px; }
.step.checkpoint .num { background: var(--detect-soft); color: var(--detect); }
.step .line { flex: 1; width: 2px; background: var(--border); margin-top: 4px; min-height: 10px; }

.step .card { flex: 1; }
.step.checkpoint .card { border-color: #D9CBEA; background: #FCFAFE; }
.step .card-top { display: flex; justify-content: space-between; align-items: flex-start; gap: 10px; margin-bottom: 4px; }
.step .card-top .name { font-weight: 700; font-size: 14.5px; }
.step .desc { margin: 2px 0 8px; font-size: 13.5px; }

.badge-checkpoint { background: var(--detect); }

.criteria { font-size: 12.5px; color: var(--detect); background: var(--detect-soft); border-radius: 6px; padding: 7px 10px; margin: 0 0 10px; }

.chips-row { display: flex; flex-wrap: wrap; gap: 14px; align-items: center; margin-bottom: 8px; }
.chip-group { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.chip-group .gl { font-size: 11.5px; color: var(--ink-muted); margin-right: 2px; }
.chip { display: inline-flex; align-items: center; gap: 5px; font-size: 12.5px; padding: 3px 6px 3px 8px; border-radius: 12px; border: 1px solid var(--border); background: var(--bg-alt); color: var(--ink); }
.chip .raci { font-size: 9.5px; font-weight: 800; background: var(--primary); color: #fff; width: 15px; height: 15px; border-radius: 50%; display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.chip.tool { background: var(--mitig-soft, #E7EAF0); border-color: #D7DCE6; }
.chip.tool .dot { width: 6px; height: 6px; border-radius: 50%; background: var(--mitigative); flex-shrink: 0; }
.chip-remove { border: none; background: none; color: var(--ink-muted); font-size: 13px; line-height: 1; cursor: pointer; padding: 0 0 0 2px; }
.chip-remove:hover { color: var(--danger); }

.mini-form { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; margin-bottom: 4px; }
.mini-form select { width: auto; }

/* ---- Wyszukiwalny wielokrotny wybór (search-select) - assets/search-select.js
   zamienia ukryty <select multiple> w środku na chipy + pole wyszukiwania +
   rozwijaną listę filtrowanych opcji. Używane m.in. w formularzu kroku
   procesu (osoba odpowiedzialna, narzędzia). */
.search-select { position: relative; border: 1px solid var(--border); border-radius: 8px; background: var(--bg); padding: 6px 8px; }
.search-select.focused { border-color: var(--primary); box-shadow: 0 0 0 2px var(--primary-soft); }
.ss-chips { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 4px; }
.ss-chips:empty { display: none; margin: 0; }
.ss-chip { display: inline-flex; align-items: center; gap: 5px; font-size: 12.5px; padding: 3px 6px 3px 8px; border-radius: 12px; border: 1px solid var(--border); background: var(--bg-alt); color: var(--ink); }
.ss-chip button { border: none; background: none; color: var(--ink-muted); font-size: 13px; line-height: 1; cursor: pointer; padding: 0 0 0 2px; }
.ss-chip button:hover { color: var(--danger); }
.ss-input-row { position: relative; }
.ss-input { width: 100%; border: none; padding: 4px 2px; font-size: 13.5px; outline: none; background: transparent; }
.ss-dropdown { position: absolute; z-index: 30; left: 0; right: 0; top: calc(100% + 4px); background: var(--bg); border: 1px solid var(--border); border-radius: 8px; box-shadow: 0 6px 20px rgba(0,0,0,.1); max-height: 220px; overflow-y: auto; padding: 4px; }
.ss-option { padding: 7px 9px; border-radius: 6px; font-size: 13.5px; cursor: pointer; color: var(--ink); }
.ss-option:hover, .ss-option.active { background: var(--primary-soft); color: var(--primary-dark); }
.ss-empty { padding: 7px 9px; font-size: 12.5px; color: var(--ink-muted); font-style: italic; }


/* ---- Atrybuty (proposed-but-unconfirmed marker, kept for future use) ---- */
.pill-proposed { display: inline-block; margin-left: 8px; padding: 1px 8px; border-radius: 999px; font-size: 10.5px; font-weight: 600; color: var(--primary-dark); background: var(--primary-soft); border: 1px solid var(--primary); vertical-align: middle; }
.attr-empty { color: var(--ink-muted); font-size: 13.5px; padding: 4px 2px 2px; }

/* ---- Zgłoszenia i opinie użytkowników (feedback) ---- */
.feedback-fab { position:fixed; right:24px; bottom:24px; z-index:40; background:var(--primary); color:#fff; border:none; border-radius:999px; padding:11px 18px 11px 14px; font-size:13px; font-weight:700; display:flex; align-items:center; gap:7px; cursor:pointer; box-shadow:0 6px 18px rgba(15,110,99,0.28); }
.feedback-fab:hover { background:var(--primary-dark); }

.feedback-overlay { display:none; position:fixed; inset:0; z-index:50; background:rgba(34,37,43,0.32); align-items:center; justify-content:center; }
.feedback-overlay.open { display:flex; }
.feedback-modal { background:var(--bg); border-radius:12px; width:420px; max-width:92vw; max-height:88vh; overflow-y:auto; padding:24px; box-shadow:0 20px 50px rgba(0,0,0,0.18); }
.feedback-modal h2 { margin:0 0 2px; font-size:17px; }
.feedback-modal-sub { color:var(--ink-muted); font-size:12.5px; margin:0 0 18px; }

.feedback-segmented { display:flex; border:1px solid var(--border); border-radius:8px; overflow:hidden; }
.feedback-segmented input[type=radio] { position:absolute; opacity:0; width:0; height:0; }
.feedback-segmented label { flex:1; text-align:center; padding:8px 0; font-size:12.5px; color:var(--ink-muted); cursor:pointer; border-right:1px solid var(--border); margin:0; }
.feedback-segmented label:last-child { border-right:none; }
.feedback-segmented input:checked + label { background:var(--primary-soft); color:var(--primary-dark); font-weight:700; }

.feedback-urgency { display:flex; gap:6px; }
.feedback-urgency input[type=radio] { position:absolute; opacity:0; width:0; height:0; }
.feedback-urgency label { flex:1; text-align:center; border:1px solid var(--border); background:var(--bg); border-radius:8px; padding:8px 0; font-size:13px; color:var(--ink-muted); cursor:pointer; margin:0; }
.feedback-urgency input:checked + label { background:var(--primary); border-color:var(--primary); color:#fff; font-weight:700; }
.feedback-urgency-labels { display:flex; justify-content:space-between; font-size:10.5px; color:var(--ink-muted); margin-top:4px; }

.feedback-note { display:block; background:var(--bg-alt); border:1px solid var(--border); border-radius:8px; padding:10px 12px; font-size:12px; color:var(--ink-muted); margin:14px 0 0; }
.feedback-modal-actions { display:flex; justify-content:flex-end; gap:8px; margin-top:20px; }

.feedback-stats { display:grid; grid-template-columns:repeat(5,1fr); gap:12px; margin-bottom:20px; }
.feedback-stat { background:var(--bg); border:1px solid var(--border); border-radius:10px; padding:14px 16px; }
.feedback-stat .n { font-size:22px; font-weight:800; }
.feedback-stat .l { font-size:11px; color:var(--ink-muted); text-transform:uppercase; letter-spacing:.03em; margin-top:2px; }
.feedback-stat.new .n { color:var(--primary-dark); }
.feedback-stat.review .n { color:var(--sev-medium); }
.feedback-stat.planned .n { color:var(--detect); }
.feedback-stat.rejected .n { color:var(--ink-muted); }
.feedback-stat.done .n { color:var(--sev-low); }

.feedback-filters { display:flex; gap:10px; margin-bottom:16px; flex-wrap:wrap; }
.feedback-filters select { width:auto; border:1px solid var(--border); border-radius:8px; padding:7px 10px; font-size:12.5px; }

.feedback-table { width:100%; border-collapse:collapse; }
.feedback-table th, .feedback-table td { text-align:left; padding:10px 12px; font-size:13px; border-bottom:1px solid var(--border); vertical-align:top; }
.feedback-table th { color:var(--ink-muted); font-weight:600; font-size:11px; text-transform:uppercase; letter-spacing:.03em; background:var(--bg-alt); }
.feedback-table tr:last-child td { border-bottom:none; }

.pill.fb-type-sugestia { background:var(--primary-soft); color:var(--primary-dark); }
.pill.fb-type-blad { background:var(--danger-soft); color:var(--danger); }
.pill.fb-type-pytanie { background:var(--detect-soft); color:var(--detect); }

.fb-dots { display:flex; gap:2px; }
.fb-dot { width:7px; height:7px; border-radius:50%; background:var(--border); }
.fb-dot.on { background:var(--sev-high); }

.fb-msg { max-width:280px; }
.fb-msg .fb-excerpt { color:var(--ink); }
.fb-msg .fb-meta { color:var(--ink-muted); font-size:11.5px; margin-top:3px; word-break:break-all; }

.feedback-row-form { display:flex; flex-direction:column; gap:6px; min-width:190px; }
.fb-status-select { width:auto; font-size:12px; padding:5px 8px; }
.fb-note-input { width:auto; font-size:12px; padding:5px 8px; }

/* =====================================================================
   Raporty — panel operacyjny (reports/index.php)
   Łączy dwie makiety: konsolę "aktywnego sygnału" (panel kontekstu +
   rozwijane karty zagrożeń + rekomendowane działania) i mapę obszarów
   (pasek indeksu, kolorowe warstwy "Warstwa N", node-flow, radar,
   macierz, heatmapa, roadmapa). Kolory: reużywa --sev-*/--accent-* z
   :root zamiast osobnej palety makiety, żeby ekran pozostał spójny z
   resztą już wdrożonej aplikacji.
   ===================================================================== */

/* ---- Panel kontekstu (dawny "sygnał") ---- */
.context-panel {
  background: var(--bg-alt); border: 1px solid var(--border); border-radius: 10px;
  padding: 16px 20px; margin-bottom: 20px;
}
.context-panel-label { font-size: 11.5px; text-transform: uppercase; letter-spacing: .04em; color: var(--ink-muted); font-weight: 700; margin-bottom: 8px; }

/* ---- Rozwijane karty zagrożeń (node-flow chain wewnątrz karty) ---- */
.hazard-card { background: var(--bg); border: 1px solid var(--border); border-radius: 10px; margin-bottom: 10px; overflow: hidden; }
.hazard-card summary { list-style: none; cursor: pointer; padding: 13px 16px; display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.hazard-card summary::-webkit-details-marker { display: none; }
.hazard-card summary::before { content: "›"; display: inline-block; color: var(--ink-muted); font-size: 17px; width: 12px; flex: none; transition: transform .12s; }
.hazard-card[open] summary::before { transform: rotate(90deg); }
.hazard-area-tag { font-size: 11px; color: var(--ink-muted); background: var(--bg-alt); border: 1px solid var(--border); border-radius: 5px; padding: 2px 7px; flex: none; white-space: nowrap; }
.hazard-summary-main { flex: 1; min-width: 0; }
.hazard-name { font-weight: 700; font-size: 14px; color: var(--ink); }
.hazard-cause-line { color: var(--ink-muted); font-size: 12.5px; margin-top: 1px; }
.hazard-flags { display: flex; gap: 6px; flex: none; }

.pill-status { display: inline-flex; align-items: center; gap: 5px; font-size: 11.5px; font-weight: 600; padding: 3px 9px; border-radius: 20px; white-space: nowrap; background: #fff; border: 1px solid var(--border); }
.pill-status .pd { width: 6px; height: 6px; border-radius: 50%; flex: none; }
.pill-status.sev-low { background: var(--sev-low-soft); color: var(--sev-low-ink); } .pill-status.sev-low .pd { background: var(--sev-low); }
.pill-status.sev-medium { background: var(--sev-medium-soft); color: var(--sev-medium-ink); } .pill-status.sev-medium .pd { background: var(--sev-medium); }
.pill-status.sev-high { background: var(--sev-high-soft); color: var(--sev-high-ink); } .pill-status.sev-high .pd { background: var(--sev-high); }
.pill-status.sev-severe { background: var(--sev-severe-soft); color: var(--sev-severe-ink); } .pill-status.sev-severe .pd { background: var(--sev-severe); }
.pill-status.sev-none { color: var(--ink-muted); } .pill-status.sev-none .pd { background: var(--border); }

.hazard-body { padding: 0 16px 16px 42px; border-top: 1px solid var(--border); }
.hazard-body-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; padding-top: 14px; }
.flow-col-label { font-size: 11px; text-transform: uppercase; letter-spacing: .03em; color: var(--ink-muted); font-weight: 700; margin-bottom: 7px; }
.flow-item { background: var(--bg-alt); border: 1px solid var(--border); border-radius: 7px; padding: 8px 10px; font-size: 12.5px; margin-bottom: 6px; }
.flow-item.matched { border-color: var(--primary); background: var(--primary-soft); }
.flow-item-tag { font-size: 10.5px; color: var(--ink-muted); display: block; margin-bottom: 1px; }
.top-event-strip { grid-column: 1 / -1; background: var(--primary-soft); border: 1px solid var(--primary); border-radius: 7px; padding: 9px 12px; font-size: 12.5px; margin-bottom: 2px; }
.top-event-strip .flow-item-tag { color: var(--primary-dark); }

.barrier-table-wrap { overflow-x: auto; }
.barrier-table { width: 100%; border-collapse: collapse; margin-top: 12px; font-size: 12.5px; }
.barrier-table th { text-align: left; font-size: 10.5px; text-transform: uppercase; letter-spacing: .03em; color: var(--ink-muted); font-weight: 700; padding: 0 10px 6px; border-bottom: 1px solid var(--border); }
.barrier-table td { padding: 8px 10px; border-bottom: 1px solid var(--border); vertical-align: top; }
.barrier-table tr:last-child td { border-bottom: none; }
.barrier-role-note { color: var(--ink-muted); font-size: 11px; }

/* ---- Rekomendowane działania ---- */
.action-row { display: flex; gap: 12px; align-items: flex-start; background: var(--bg); border: 1px solid var(--border); border-radius: 10px; padding: 12px 15px; margin-bottom: 8px; }
.action-priority { flex: none; width: 78px; text-align: center; font-size: 10.5px; font-weight: 700; text-transform: uppercase; letter-spacing: .02em; padding: 4px 0; border-radius: 6px; margin-top: 1px; }
.action-priority.sev-severe { background: var(--sev-severe-soft); color: var(--sev-severe-ink); }
.action-priority.sev-high { background: var(--sev-high-soft); color: var(--sev-high-ink); }
.action-priority.sev-medium { background: var(--sev-medium-soft); color: var(--sev-medium-ink); }
.action-main { flex: 1; min-width: 0; overflow-wrap: anywhere; }
.action-title { font-weight: 700; font-size: 13.5px; }
.action-meta { color: var(--ink-muted); font-size: 12px; margin-top: 2px; }

/* ---- Pasek indeksu warstw ---- */
.index-strip { background: var(--bg); border: 1px solid var(--border); border-radius: 12px; padding: 14px 20px; display: flex; flex-wrap: wrap; align-items: center; gap: 8px 26px; margin-bottom: 26px; }
.index-strip-title { width: 100%; font-size: 10.5px; letter-spacing: .08em; text-transform: uppercase; color: var(--ink-muted); font-weight: 700; margin-bottom: 2px; }
.index-item { display: flex; align-items: center; gap: 8px; text-decoration: none; color: inherit; padding: 3px 0; }
.index-item:hover .index-name { text-decoration: underline; }
.index-badge { width: 26px; height: 26px; border-radius: 50%; display: flex; align-items: center; justify-content: center; color: #fff; font-size: 10px; font-weight: 700; flex: none; }
.index-name { font-size: 12.5px; font-weight: 600; color: var(--ink); }
.index-arrow { color: var(--ink-muted); font-size: 13px; margin-left: 1px; }

/* ---- Warstwa: pigułka nagłówka + kontener w tle akcentu ---- */
.level-band { margin-bottom: 28px; scroll-margin-top: 20px; }
.level-header { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; margin-bottom: 14px; }
.level-pill { display: inline-flex; align-items: center; padding: 7px 16px; border-radius: 8px; color: #fff; font-weight: 700; font-size: 11.5px; letter-spacing: .04em; text-transform: uppercase; white-space: nowrap; }
.level-meta { font-size: 11.5px; color: var(--ink-muted); }
.level-container { border-radius: 14px; padding: 22px; border: 1px solid var(--border); }
.inner-card { background: var(--bg); border: 1px solid var(--border); border-radius: 10px; padding: 18px 20px; }
.inner-card + .inner-card { margin-top: 14px; }
.inner-card-label { font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: .04em; color: var(--ink-muted); margin-bottom: 12px; }

.legend-row { display: flex; flex-wrap: wrap; gap: 14px; margin-bottom: 2px; }
.legend-item { display: flex; align-items: center; gap: 6px; font-size: 11.5px; color: var(--ink-muted); }
.legend-dot { width: 9px; height: 9px; border-radius: 50%; flex: none; }
.legend-dot.sev-low { background: var(--sev-low); } .legend-dot.sev-medium { background: var(--sev-medium); }
.legend-dot.sev-high { background: var(--sev-high); } .legend-dot.sev-severe { background: var(--sev-severe); }
.legend-dot.sev-none { background: var(--border); }

/* ---- Node-flow: mapa obszarów i inne poziome przepływy ---- */
.node-flow { display: flex; align-items: flex-start; gap: 0; overflow-x: auto; padding: 2px 2px 8px; }
.flow-node { display: flex; flex-direction: column; align-items: center; text-align: center; width: 156px; flex: none; padding: 0 7px; }
.flow-node.is-current .node-circle { box-shadow: 0 0 0 3px var(--bg), 0 0 0 5px var(--primary); }
.node-circle { width: 46px; height: 46px; border-radius: 50%; display: flex; align-items: center; justify-content: center; box-shadow: 0 2px 5px rgba(20,15,5,.16); margin-bottom: 10px; flex: none; }
.node-circle svg { width: 20px; height: 20px; }
.node-label { font-weight: 700; font-size: 12.5px; color: var(--ink); line-height: 1.28; margin-bottom: 4px; min-height: 32px; }
.node-desc { font-size: 10.5px; font-style: italic; color: var(--ink-muted); line-height: 1.35; margin-bottom: 10px; min-height: 14px; }
.node-detail { background: var(--bg); border: 1px solid var(--border); border-radius: 8px; padding: 9px 10px; width: 100%; display: flex; flex-direction: column; gap: 5px; align-items: center; }
.nd-stat { font-size: 10px; color: var(--ink-muted); font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; }
.nd-overdue { font-size: 10px; color: var(--sev-severe-ink); font-weight: 700; }
.flow-arrow { flex: none; color: var(--border); font-size: 17px; padding-top: 16px; width: 24px; text-align: center; }
.scroll-hint { font-size: 10.5px; color: var(--ink-muted); font-style: italic; margin-top: 8px; display: none; }

/* ---- Radar ---- */
.radar-row { display: flex; gap: 24px; align-items: center; flex-wrap: wrap; }
.radar-svg-box { flex: none; margin: 0 auto; }
.radar-legend-list { flex: 1; min-width: 220px; display: flex; flex-direction: column; gap: 7px; }
.radar-legend-row { display: flex; align-items: center; justify-content: space-between; gap: 10px; font-size: 12px; padding: 7px 10px; border-radius: 7px; background: var(--bg-alt); border: 1px solid var(--border); }
.radar-legend-name { font-weight: 600; color: var(--ink); }

/* ---- Macierz częstotliwość x dotkliwość / heatmapa obszar x źródło ---- */
.matrix-wrap, .xtab-wrap { overflow-x: auto; }
.risk-matrix, .xtab { border-collapse: separate; border-spacing: 5px; width: 100%; }
.risk-matrix td, .xtab td { text-align: center; vertical-align: middle; }
.rm-corner, .xtab-corner { width: 130px; }
.rm-col-head, .xtab-col-head { font-size: 10.5px; color: var(--ink-muted); font-weight: 600; padding-bottom: 4px; width: 78px; }
.rm-row-head { font-size: 10.5px; color: var(--ink-muted); font-weight: 600; text-align: right !important; padding-right: 8px; white-space: nowrap; }
.xtab-row-head { text-align: left !important; font-size: 12px; color: var(--ink); font-weight: 600; padding-right: 10px; min-width: 185px; }
.rm-cell, .xtab-cell { width: 78px; height: 40px; border-radius: 7px; font-size: 13px; font-weight: 700; }
.rm-cell.rm-zero { opacity: .45; font-weight: 600; }
.rm-cell.sev-low, .xtab-cell.xt-1 { background: var(--sev-low-soft); color: var(--sev-low-ink); }
.rm-cell.sev-medium, .xtab-cell.xt-2 { background: var(--sev-medium-soft); color: var(--sev-medium-ink); }
.rm-cell.sev-high, .xtab-cell.xt-3 { background: var(--sev-high-soft); color: var(--sev-high-ink); }
.rm-cell.sev-severe, .xtab-cell.xt-4 { background: var(--sev-severe-soft); color: var(--sev-severe-ink); }
.xtab-cell.xt-0 { background: var(--bg-alt); color: var(--ink-muted); font-weight: 600; }
.matrix-caption { font-size: 11.5px; color: var(--ink-muted); margin-top: 12px; }

/* ---- Roadmapa (node-flow variant z pionowym stosem kart) ---- */
.roadmap-flow { display: flex; align-items: flex-start; gap: 0; overflow-x: auto; padding: 2px 2px 8px; }
.roadmap-phase { display: flex; flex-direction: column; align-items: center; width: 250px; flex: none; padding: 0 10px; }
.roadmap-phase .node-circle { margin-bottom: 8px; color: #fff; font-weight: 700; font-size: 13px; }
.roadmap-phase-label { font-weight: 700; font-size: 13px; color: var(--ink); margin-bottom: 2px; }
.roadmap-phase-sub { font-size: 10.5px; color: var(--ink-muted); font-style: italic; margin-bottom: 13px; }
.roadmap-cards { display: flex; flex-direction: column; gap: 8px; width: 100%; }
.roadmap-card { background: var(--bg); border: 1px solid var(--border); border-left: 3px solid var(--ink-muted); border-radius: 8px; padding: 10px 11px; text-align: left; }
.roadmap-card.sev-severe { border-left-color: var(--sev-severe); }
.roadmap-card.sev-high { border-left-color: var(--sev-high); }
.roadmap-card.sev-medium { border-left-color: var(--sev-medium); }
.roadmap-card-title { font-weight: 600; font-size: 12px; line-height: 1.35; margin-bottom: 6px; }
.roadmap-card-meta { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.roadmap-area-tag { font-size: 10px; color: var(--ink-muted); background: var(--bg-alt); border: 1px solid var(--border); border-radius: 5px; padding: 1px 6px; }
.roadmap-flow-arrow { flex: none; color: var(--border); font-size: 17px; padding-top: 35px; width: 22px; text-align: center; }
.roadmap-empty { color: var(--ink-muted); font-size: 12.5px; font-style: italic; padding: 8px 2px; }

/* ---- Łącznik przejścia między warstwami ---- */
.band-transition { display: flex; flex-direction: column; align-items: center; gap: 4px; margin: -14px 0 24px; color: var(--ink-muted); font-size: 11.5px; font-style: italic; text-align: center; max-width: 560px; margin-left: auto; margin-right: auto; }
.band-transition .dots { border-left: 2px dotted var(--border); height: 22px; }
.band-transition .arrow-down { font-size: 13px; color: var(--ink-muted); line-height: 1; }

@media (max-width: 900px) {
  .hazard-body-grid { grid-template-columns: 1fr; }
  .radar-row { flex-direction: column; align-items: stretch; }
  .radar-svg-box { width: 100%; max-width: 280px; margin: 0 auto; }
  .radar-svg-box svg { width: 100%; height: auto; display: block; }
  .radar-legend-list { min-width: 0; width: 100%; }
  .scroll-hint { display: block; }
}
@media (max-width: 620px) {
  .context-panel { padding: 14px 16px; }
  .context-panel form { width: 100%; }
  .context-panel form .field { flex: 1 1 100%; }
  .hazard-card summary { flex-direction: column; align-items: stretch; row-gap: 6px; }
  .hazard-area-tag { order: 1; white-space: normal; max-width: 100%; align-self: flex-start; }
  .hazard-flags { order: 2; margin-left: 0; flex-wrap: wrap; }
  .hazard-summary-main { order: 3; }
  .pill-status { white-space: normal; text-align: center; }
  .hazard-body { padding-left: 16px; padding-right: 16px; }
  .barrier-table { min-width: 480px; }
  .level-container { padding: 16px 14px; }
  .inner-card { padding: 14px 16px; }
  .level-pill { white-space: normal; text-align: center; max-width: 100%; }
  .action-row { flex-wrap: wrap; }
  .action-priority { width: auto; padding: 3px 10px; }
  .index-strip { padding: 14px 16px; gap: 8px 16px; }
  .radar-legend-row { flex-wrap: wrap; }
  .radar-legend-name { min-width: 0; overflow-wrap: anywhere; flex: 1 1 auto; }
}

/* --- Słowniki, siły i środki, terytorium (migracje 016–019) --------------- */
.rdy { display: inline-block; padding: 2px 9px; border-radius: 999px; font-size: 12px; font-weight: 600; white-space: nowrap; }
.rdy-ok   { background: var(--sev-low-soft); color: var(--sev-low-ink); }
.rdy-lim  { background: var(--sev-medium-soft); color: var(--sev-medium-ink); }
.rdy-low  { background: var(--sev-severe-soft); color: var(--sev-severe-ink); }
.rdy-none { background: var(--bg-alt); color: var(--ink-muted); }
.pill.off-dict { background: var(--sev-medium-soft); color: var(--sev-medium-ink); border-color: transparent; }
.pill.retired  { background: var(--bg-alt); color: var(--ink-muted); text-decoration: line-through; }
.code-tag { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: 12px; color: var(--ink-muted); }
.meter { height: 8px; border-radius: 999px; background: var(--bg-alt); overflow: hidden; min-width: 90px; }
.meter > span { display: block; height: 100%; border-radius: 999px; background: var(--primary); }
.meter.lim > span { background: var(--sev-medium); }
.meter.low > span { background: var(--sev-severe); }
.filter-bar { display: flex; gap: 12px; flex-wrap: wrap; align-items: flex-end; margin-bottom: 16px; }
.filter-bar .field { margin-bottom: 0; min-width: 180px; }
.row-sub td { padding-left: 34px; }
.cat-row td { background: var(--bg-alt); font-weight: 600; }
.terr-tree ul { list-style: none; margin: 0; padding-left: 24px; border-left: 1px dashed var(--border); }
.terr-tree > ul { padding-left: 0; border-left: none; }
.terr-tree li { margin: 6px 0; }
.terr-node { display: flex; align-items: center; gap: 10px; padding: 8px 12px; border: 1px solid var(--border); border-radius: 8px; background: var(--bg); }
.terr-node .grow { flex: 1; min-width: 0; }
.terr-node .muted, .muted { color: var(--ink-muted); font-size: 12.5px; }
.exposure-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 12px; }
.inline-rows .row { display: grid; gap: 8px; align-items: end; margin-bottom: 8px; }
.inline-rows .row .field { margin-bottom: 0; }
