:root {
  --navy: #14254a;
  --navy-2: #1d3363;
  --red: #b3202a;
  --gold: #f2c400;
  --ink: #1b1f24;
  --muted: #555e6b;
  --line: #d9dde3;
  --bg: #f4f5f7;
  --panel: #ffffff;
  --link: #1a4f9c;
  --ok: #1d6b3a;
  --ok-bg: #e5f3ea;
  --warn: #7a4b00;
  --warn-bg: #fff3d6;
  --bad: #a1171f;
  --bad-bg: #fbe7e8;
  --info-bg: #e8eef8;
  --focus: #0b57d0;
}
* { box-sizing: border-box; }
html { font-size: 15px; }
body { margin: 0; font-family: "Segoe UI", "Segoe UI Web (West European)", -apple-system, BlinkMacSystemFont, Roboto, "Helvetica Neue", sans-serif; color: var(--ink); background: var(--bg); line-height: 1.45; }
a { color: var(--link); }
a:hover { text-decoration-thickness: 2px; }
:focus-visible { outline: 3px solid var(--focus); outline-offset: 2px; }
.skip { position: absolute; left: -999px; top: 0; background: #fff; padding: 8px 12px; z-index: 10; }
.skip:focus { left: 8px; }
.vh { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* Header */
.top { background: var(--navy); color: #fff; display: flex; align-items: center; gap: 16px; padding: 0 20px; height: 56px; border-bottom: 3px solid var(--red); }
.brand { display: flex; align-items: center; gap: 10px; color: #fff; text-decoration: none; font-weight: 600; font-size: 1.05rem; white-space: nowrap; }
.brand img { width: 30px; height: 34px; }
.brand small { display: block; font-weight: 400; font-size: .76rem; color: #c9d3e6; }
.top form.find { flex: 1; max-width: 560px; display: flex; }
.top form.find input { flex: 1; border: 1px solid #3d5287; background: #fff; border-radius: 3px 0 0 3px; padding: 7px 10px; font: inherit; min-height: 36px; }
.top form.find button { border: 0; background: var(--gold); color: var(--navy); font-weight: 600; padding: 0 14px; border-radius: 0 3px 3px 0; cursor: pointer; min-height: 36px; font: inherit; font-weight: 600; }
.who { margin-left: auto; display: flex; align-items: center; gap: 12px; font-size: .86rem; }
.who .role { color: #c9d3e6; }
.who button { background: transparent; color: #fff; border: 1px solid #5a6e9e; border-radius: 3px; padding: 5px 10px; cursor: pointer; font: inherit; min-height: 32px; }
.env { background: var(--gold); color: var(--navy); font-size: .72rem; font-weight: 700; padding: 2px 6px; border-radius: 2px; letter-spacing: .02em; }

/* Shell */
.shell { display: grid; grid-template-columns: 232px 1fr; min-height: calc(100vh - 56px); }
nav.side { background: #fff; border-right: 1px solid var(--line); padding: 14px 0 24px; }
nav.side h2 { font-size: .72rem; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); margin: 16px 18px 6px; font-weight: 600; }
nav.side a { display: flex; align-items: center; gap: 8px; padding: 8px 18px; color: var(--ink); text-decoration: none; font-size: .93rem; border-left: 3px solid transparent; min-height: 36px; }
nav.side a:hover { background: #f0f2f6; }
nav.side a[aria-current="page"] { border-left-color: var(--red); background: #eef1f7; font-weight: 600; }
nav.side .count { margin-left: auto; background: var(--red); color: #fff; font-size: .72rem; border-radius: 9px; padding: 0 7px; font-weight: 600; }
main { padding: 22px 28px 40px; min-width: 0; }
.crumbs { font-size: .84rem; color: var(--muted); margin-bottom: 6px; }
.crumbs a { color: var(--muted); }
h1 { font-size: 1.5rem; margin: 0 0 4px; font-weight: 600; }
h2 { font-size: 1.12rem; margin: 0 0 10px; font-weight: 600; }
h3 { font-size: .98rem; margin: 0 0 8px; font-weight: 600; }
.sub { color: var(--muted); margin: 0 0 18px; font-size: .92rem; }
.pagehead { display: flex; align-items: flex-end; gap: 16px; margin-bottom: 16px; flex-wrap: wrap; }
.pagehead .actions { margin-left: auto; display: flex; gap: 8px; flex-wrap: wrap; }

footer.site { border-top: 1px solid var(--line); margin-top: 32px; padding-top: 12px; color: var(--muted); font-size: .8rem; display: flex; gap: 18px; flex-wrap: wrap; }

/* Panels and grids */
.panel { background: var(--panel); border: 1px solid var(--line); border-radius: 4px; padding: 16px 18px; margin-bottom: 16px; }
.panel > h2 { display: flex; align-items: center; gap: 10px; }
.panel > h2 .more { margin-left: auto; font-size: .84rem; font-weight: 400; }
.grid { display: grid; gap: 16px; }
.g2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.g3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.g4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.split { display: grid; grid-template-columns: minmax(0, 2fr) minmax(0, 1fr); gap: 16px; }
.stats { display: flex; border: 1px solid var(--line); background: #fff; border-radius: 4px; margin-bottom: 16px; }
.stats > div { flex: 1; padding: 12px 16px; border-right: 1px solid var(--line); }
.stats > div:last-child { border-right: 0; }
.stats .n { font-size: 1.45rem; font-weight: 600; display: block; }
.stats .l { font-size: .8rem; color: var(--muted); }
.stats .n.bad { color: var(--bad); }
.panel .n { font-size: 1.45rem; font-weight: 600; }
.stats .n.ok { color: var(--ok); }

/* Tables */
table { border-collapse: collapse; width: 100%; font-size: .9rem; }
th, td { text-align: left; padding: 7px 10px; border-bottom: 1px solid var(--line); vertical-align: top; }
th { font-weight: 600; color: var(--muted); font-size: .8rem; background: #fafbfc; }
td.num, th.num { text-align: right; font-variant-numeric: tabular-nums; }
tr:hover td { background: #fafbfd; }
.tablewrap { overflow-x: auto; }
.mono { font-family: Consolas, "Cascadia Mono", monospace; font-size: .84rem; }
.muted { color: var(--muted); }
.small { font-size: .82rem; }
.nowrap { white-space: nowrap; }

/* Chips */
.chip { display: inline-block; font-size: .76rem; padding: 1px 7px; border-radius: 2px; border: 1px solid var(--line); background: #f3f4f6; white-space: nowrap; font-weight: 600; }
.chip.ok { background: var(--ok-bg); border-color: #b9dcc5; color: var(--ok); }
.chip.warn { background: var(--warn-bg); border-color: #edd38f; color: var(--warn); }
.chip.bad { background: var(--bad-bg); border-color: #efb9bc; color: var(--bad); }
.chip.info { background: var(--info-bg); border-color: #c4d2ea; color: #1a3d73; }
.chip.lock { background: #fff; border-color: var(--red); color: var(--red); }

/* Forms */
label { font-weight: 600; font-size: .88rem; display: block; margin-bottom: 4px; }
.field { margin-bottom: 14px; }
.field .help { font-size: .8rem; color: var(--muted); margin-top: 3px; }
.field .err { color: var(--bad); font-size: .82rem; margin-top: 3px; font-weight: 600; }
input[type=text], input[type=search], input[type=number], input[type=date], input[type=password], select, textarea {
  font: inherit; border: 1px solid #8a94a3; border-radius: 3px; padding: 6px 9px; width: 100%; max-width: 480px; background: #fff; min-height: 36px; }
textarea { min-height: 90px; max-width: 640px; }
input[aria-invalid=true], select[aria-invalid=true], textarea[aria-invalid=true] { border-color: var(--bad); border-width: 2px; }
.check { display: flex; gap: 8px; align-items: flex-start; font-weight: 400; }
.check input { width: 20px; height: 20px; margin-top: 2px; }
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 6px; font: inherit; font-weight: 600; border: 1px solid var(--navy); background: var(--navy); color: #fff; padding: 6px 14px; border-radius: 3px; cursor: pointer; text-decoration: none; min-height: 36px; font-size: .9rem; }
.btn:hover { background: var(--navy-2); }
.btn.secondary { background: #fff; color: var(--navy); }
.btn.secondary:hover { background: #eef1f7; }
.btn.danger { background: #fff; color: var(--bad); border-color: var(--bad); }
.filters { display: flex; flex-wrap: wrap; gap: 10px; align-items: flex-end; margin-bottom: 14px; }
.filters .field { margin: 0; }
.filters select, .filters input { min-width: 160px; width: auto; }

/* Notices */
.notice { border: 1px solid #c4d2ea; background: var(--info-bg); padding: 10px 14px; border-radius: 3px; margin-bottom: 14px; font-size: .9rem; }
.notice ul { margin: 6px 0 0; padding-left: 20px; }
.notice li { margin: 4px 0; }
.notice li a { display: inline-block; min-height: 24px; padding: 2px 0; }
main:focus { outline: none; }
.notice.ok { border-color: #b9dcc5; background: var(--ok-bg); }
.notice.warn { border-color: #edd38f; background: var(--warn-bg); }
.notice.bad { border-color: #efb9bc; background: var(--bad-bg); }
.empty { padding: 26px; text-align: center; color: var(--muted); border: 1px dashed var(--line); border-radius: 4px; background: #fff; }

/* Lists */
ul.plain { list-style: none; margin: 0; padding: 0; }
ul.plain li { padding: 9px 0; border-bottom: 1px solid var(--line); }
ul.plain li:last-child { border-bottom: 0; }
.meta { font-size: .8rem; color: var(--muted); }
.bulletin { border-left: 4px solid var(--navy); padding: 8px 12px; background: #fafbfd; margin-bottom: 10px; }
.bulletin.weather { border-left-color: var(--gold); }
.bulletin.action { border-left-color: var(--red); }

/* Search */
.result { padding: 12px 0; border-bottom: 1px solid var(--line); }
.result a.t { font-size: 1.02rem; font-weight: 600; }
.result p { margin: 4px 0; font-size: .9rem; }
mark { background: #ffe680; color: inherit; padding: 0 1px; }
.facets h3 { font-size: .8rem; text-transform: uppercase; letter-spacing: .05em; color: var(--muted); margin-top: 14px; }
.facets a { display: flex; justify-content: space-between; padding: 4px 0; font-size: .88rem; text-decoration: none; color: var(--ink); }
.facets a[aria-current=true] { font-weight: 700; color: var(--link); }
.facets a span { color: var(--muted); }
.pager { display: flex; gap: 8px; align-items: center; margin-top: 14px; font-size: .88rem; }

/* Doc */
dl.meta2 { display: grid; grid-template-columns: 160px 1fr; gap: 6px 12px; margin: 0; font-size: .9rem; }
dl.meta2 dt { color: var(--muted); }
dl.meta2 dd { margin: 0; }
.docbody { font-family: Georgia, "Times New Roman", serif; font-size: 1rem; line-height: 1.6; max-width: 760px; }
.bar { height: 8px; background: #e7e9ee; border-radius: 2px; overflow: hidden; min-width: 80px; }
.bar > span { display: block; height: 100%; background: var(--navy); }
.bar.ok > span { background: var(--ok); }
.bar.warn > span { background: #c98a00; }

/* Steps */
ol.steps { list-style: none; padding: 0; margin: 0; display: flex; gap: 0; flex-wrap: wrap; }
ol.steps li { flex: 1; min-width: 140px; padding: 8px 12px; border: 1px solid var(--line); background: #fff; font-size: .86rem; position: relative; }
ol.steps li + li { border-left: 0; }
ol.steps li.done { background: var(--ok-bg); }
ol.steps li.now { background: var(--warn-bg); font-weight: 600; }
.timeline { list-style: none; margin: 0; padding: 0 0 0 14px; border-left: 2px solid var(--line); }
.timeline li { position: relative; padding: 0 0 14px 12px; }
.timeline li::before { content: ""; position: absolute; left: -20px; top: 5px; width: 10px; height: 10px; border-radius: 50%; background: var(--navy); }

/* Charts */
.spark { display: flex; align-items: flex-end; gap: 2px; height: 90px; border-bottom: 1px solid var(--line); }
.spark span { flex: 1; background: var(--navy); min-width: 2px; }
.spark span.wk { background: #8d9cbc; }
.hbar { display: grid; grid-template-columns: 180px 1fr 60px; gap: 8px; align-items: center; font-size: .86rem; margin-bottom: 6px; }

/* Matrix */
.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: #9aa1ab; }

/* Utilities (no inline styles: the content security policy blocks them) */
.m0 { margin: 0; }
.mt18 { margin-top: 18px; }
.mt8 { margin-top: 8px; }
.w260 { max-width: 260px; }
.right { text-align: right; }
fieldset.bare { border: 0; padding: 0; margin: 0 0 12px; }
fieldset.bare legend { font-weight: 600; font-size: .88rem; padding: 0; margin-bottom: 4px; }
progress { width: 100%; min-width: 80px; height: 8px; appearance: none; -webkit-appearance: none; border: 0; background: #e7e9ee; border-radius: 2px; vertical-align: middle; }
progress::-webkit-progress-bar { background: #e7e9ee; border-radius: 2px; }
progress::-webkit-progress-value { background: var(--navy); border-radius: 2px; }
progress::-moz-progress-bar { background: var(--navy); }
progress.ok::-webkit-progress-value { background: var(--ok); }
progress.ok::-moz-progress-bar { background: var(--ok); }
progress.warn::-webkit-progress-value { background: #b47b00; }
progress.warn::-moz-progress-bar { background: #b47b00; }
svg.chart { width: 100%; height: auto; display: block; }
svg.chart .b { fill: #14254a; }
svg.chart .w { fill: #8d9cbc; }
svg.chart .d { fill: #a1171f; }
svg.chart text { font-size: 11px; fill: #555e6b; font-family: "Segoe UI", sans-serif; }
svg.chart line { stroke: #d9dde3; }
.legend { display: flex; gap: 14px; font-size: .8rem; color: var(--muted); margin-top: 6px; }
.sw { display: inline-block; width: 10px; height: 10px; margin-right: 4px; vertical-align: middle; }
.sw.b { background: #14254a; } .sw.w { background: #8d9cbc; } .sw.d { background: #a1171f; }

/* Sign-in */
.signin { max-width: 560px; margin: 48px auto; background: #fff; border: 1px solid var(--line); border-top: 4px solid var(--red); border-radius: 4px; padding: 28px 32px; }
.signin .head { display: flex; gap: 14px; align-items: center; margin-bottom: 18px; }
.signin .head img { width: 56px; height: 64px; }
.personas { display: grid; gap: 8px; margin: 8px 0 16px; }
.personas label { display: flex; gap: 10px; align-items: flex-start; border: 1px solid var(--line); border-radius: 3px; padding: 9px 12px; font-weight: 400; cursor: pointer; }
.personas label:has(input:checked) { border-color: var(--navy); background: #eef1f7; }
.personas input { margin-top: 3px; width: 18px; height: 18px; }
.personas b { display: block; }

@media (max-width: 1100px) {
  .g4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .g3 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .split { grid-template-columns: 1fr; }
}
@media (max-width: 860px) {
  .shell { grid-template-columns: 1fr; }
  nav.side { display: flex; flex-wrap: wrap; border-right: 0; border-bottom: 1px solid var(--line); padding: 6px; }
  nav.side h2 { display: none; }
  nav.side a { padding: 6px 10px; border-left: 0; }
  .g2, .g3, .g4 { grid-template-columns: 1fr; }
  .top { flex-wrap: wrap; height: auto; padding: 8px 12px; }
  .who .role { display: none; }
  .stats { flex-wrap: wrap; }
  main { padding: 16px; }
}
@media print {
  .top, nav.side, footer.site, .noprint { display: none; }
  .shell { display: block; }
}
