:root {
  color-scheme: light;
  --paper: #f5f3ec;
  --white: #fffdf8;
  --ink: #202920;
  --muted: #526053;
  --line: #d9ded3;
  --accent: #23553e;
  --pale: #e5eee6;
  font: 16px/1.5 system-ui, sans-serif;
  background: var(--paper);
  color: var(--ink);
}
* { box-sizing: border-box; }
[hidden] { display: none !important; }
.disconnected .view { display: none; }
body { margin: 0; min-width: 290px; }
.top { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 14px max(16px, calc((100% - 1112px) / 2)); border-bottom: 1px solid var(--line); background: var(--white); }
.identity { display: flex; align-items: center; gap: 11px; font-weight: 700; }
.identity img { border-radius: 11px; }
main { max-width: 1144px; margin: auto; padding: 18px 16px 54px; }
h1, h2 { font-family: Georgia, serif; font-weight: 500; line-height: 1.1; margin: 0 0 13px; }
h1 { font-size: clamp(2.15rem, 5vw, 3.65rem); letter-spacing: -.035em; }
h2 { font-size: 1.55rem; }
h3 { margin: 0 0 4px; font-size: 1rem; }
p { margin: 0 0 12px; color: var(--muted); }
button, input, select, textarea { font: inherit; }
button { cursor: pointer; background: var(--accent); border: 1px solid transparent; color: white; padding: 8px 14px; border-radius: 9px; min-height: 44px; }
button:disabled { opacity: .55; cursor: wait; }
button.quiet, nav button { color: var(--ink); background: var(--white); border-color: var(--line); }
button:hover:not(:disabled) { filter: brightness(.94); }
:focus-visible { outline: 3px solid #a35322; outline-offset: 3px; }
nav { display: flex; flex-wrap: wrap; gap: 7px; padding-bottom: 16px; border-bottom: 1px solid var(--line); margin-bottom: 26px; }
nav [aria-current] { background: var(--accent); color: white; border-color: var(--accent); }
.notice, .access, .panel, .metric, .result { border: 1px solid var(--line); background: var(--white); border-radius: 14px; padding: 17px; }
.notice { margin: 0 0 13px; background: var(--pale); color: var(--ink); overflow-wrap: anywhere; }
.notice.error { color: #742d12; background: #f8eae1; }
.access { max-width: 650px; margin: clamp(30px, 12vh, 120px) auto; padding: clamp(20px, 5vw, 45px); }
.access form { display: grid; gap: 14px; justify-items: start; }
.heading, .actions { display: flex; justify-content: space-between; align-items: start; gap: 9px; flex-wrap: wrap; }
.actions { justify-content: start; }
.columns, .metrics, .topics { display: grid; gap: 12px; margin: 0 0 19px; }
.columns { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.metrics { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.topics { grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); }
.topic { text-align: left; min-height: 58px; }
.topic small { display: block; color: var(--muted); }
.metric strong { display: block; font-family: Georgia, serif; font-size: 2rem; font-weight: 500; }
.metric span, small, .meta { color: var(--muted); }
.panel { margin-bottom: 13px; min-width: 0; }
.columns .panel { margin: 0; }
summary { cursor: pointer; font-weight: 650; }
details > div, details > form { margin-top: 14px; }
#reference, #reports { display: flex; flex-wrap: wrap; gap: 6px; }
#reference button, #reports button { overflow-wrap: anywhere; max-width: 100%; }
.form, .filters { display: grid; gap: 12px; }
.form > button { justify-self: start; }
.filters { grid-template-columns: 2fr 1.3fr 1fr auto; align-items: end; margin: 0 0 15px; }
label { display: grid; gap: 5px; font-weight: 600; }
input, select, textarea, fieldset { width: 100%; min-width: 0; border: 1px solid #b9c3b7; border-radius: 8px; padding: 8px; background: white; color: var(--ink); }
input, select { min-height: 44px; }
textarea { resize: vertical; }
.check { display: flex; align-items: center; gap: 8px; font-weight: 400; }
.check input { width: 20px; min-height: 30px; flex-shrink: 0; accent-color: var(--accent); }
.checks { display: grid; grid-template-columns: repeat(auto-fit, minmax(205px, 1fr)); }
.result { margin-bottom: 8px; overflow-wrap: anywhere; }
.item { padding: 10px 0; border-top: 1px solid var(--line); overflow-wrap: anywhere; }
.item:first-child { border-top: 0; }
blockquote { margin: 9px 0; padding: 5px 10px; border-left: 3px solid #91ac99; white-space: pre-wrap; overflow-wrap: anywhere; }
dialog { max-width: min(810px, calc(100vw - 24px)); max-height: 85dvh; width: 100%; padding: 20px; border: 1px solid var(--line); border-radius: 13px; background: var(--white); color: var(--ink); }
dialog::backdrop { background: #1b271fa0; }
dialog form { margin-bottom: 12px; }
pre { white-space: pre-wrap; overflow-wrap: anywhere; font-size: .9rem; }
.preview { max-width: 100%; max-height: 48vh; object-fit: contain; }
@media (max-width: 680px) {
  .columns { grid-template-columns: 1fr; }
  .metrics, .filters { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .filters label:first-child { grid-column: span 2; }
  .filters button { justify-self: start; }
}
