:root {
  --bg: #faf7f2;
  --card: #ffffff;
  --ink: #2a2f2d;
  --muted: #5f6a66;
  --line: #e4ddd0;
  --accent: #2f6f6a;
  --accent-dark: #245a56;
  --green: #4a9b6a;
  --amber: #e0a43a;
  --red: #cf5c4c;
  --red-deep: #a2352a;
  --note-bg: #eef5f3;
  --warn-bg: #fdf3e3;
  --radius: 14px;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #1b1f1e; --card: #252a29; --ink: #ecefed; --muted: #a9b3af; --line: #38403e;
    --accent: #6fbdb5; --accent-dark: #8fd0c9; --note-bg: #22302e; --warn-bg: #33291a;
  }
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0; background: var(--bg); color: var(--ink);
  font: 17px/1.6 system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
}
.wrap { max-width: 680px; margin: 0 auto; padding: 16px; }
h1, h2, h3 { line-height: 1.25; margin: 0 0 .5em; }
h1 { font-size: 1.9rem; } h2 { font-size: 1.4rem; } h3 { font-size: 1.1rem; }
h1:focus, h2:focus { outline: none; }
p { margin: 0 0 1em; }
.lead { font-size: 1.2rem; }
.card {
  background: var(--card); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 22px; margin-bottom: 16px;
}
.disclaimer { font-size: .92rem; color: var(--muted); border-left: 3px solid var(--line); padding-left: 10px; }
.help { font-size: .92rem; color: var(--muted); margin-bottom: .6em; }
.indent { margin-left: 34px; }
.eyebrow { text-transform: uppercase; letter-spacing: .08em; font-size: .8rem; color: var(--accent); margin: 0 0 4px; font-weight: 600; }
.greeting { color: var(--muted); margin-bottom: 6px; }
.gentle, .notice { background: var(--note-bg); border-radius: 10px; padding: 12px 14px; }
.notice { max-width: 680px; margin: 0 auto 12px; }
.pending { color: var(--muted); font-style: italic; }

.actions { display: flex; gap: 12px; flex-wrap: wrap; margin-top: 20px; }
.btn {
  display: inline-block; font: inherit; font-weight: 600; text-decoration: none; text-align: center;
  background: var(--accent); color: #fff; border: 2px solid var(--accent); border-radius: 999px;
  padding: 12px 26px; cursor: pointer; min-height: 48px;
}
.btn:hover { background: var(--accent-dark); border-color: var(--accent-dark); }
.btn-quiet { background: transparent; color: var(--accent); }
.btn-quiet:hover { background: var(--note-bg); color: var(--accent-dark); }
.btn:focus-visible, .link-btn:focus-visible, input:focus-visible, select:focus-visible, textarea:focus-visible, a:focus-visible {
  outline: 3px solid var(--amber); outline-offset: 2px;
}
a { color: var(--accent); }

.field { margin-bottom: 18px; }
label { display: block; font-weight: 600; margin-bottom: 4px; }
input[type=text], input[type=email], select, textarea {
  width: 100%; font: inherit; color: var(--ink); background: var(--bg);
  border: 1px solid var(--line); border-radius: 10px; padding: 11px 12px;
}
.check { display: flex; gap: 12px; align-items: flex-start; margin-bottom: 8px; }
.check input { width: 22px; height: 22px; margin-top: 3px; flex: none; accent-color: var(--accent); }
.check label { font-weight: 400; margin: 0; }
.error { color: var(--red-deep); font-weight: 600; margin-top: 12px; }
@media (prefers-color-scheme: dark) { .error { color: #ff9c8f; } }

.progress-label { font-size: .9rem; color: var(--muted); margin-bottom: 6px; }
.progress { height: 10px; background: var(--line); border-radius: 999px; overflow: hidden; margin-bottom: 18px; }
.progress-fill { height: 100%; background: var(--accent); border-radius: 999px; transition: width .3s; }

fieldset.q { border: 0; border-top: 1px solid var(--line); margin: 0; padding: 16px 0 6px; }
fieldset.q legend { padding: 0; font-weight: 600; margin-bottom: 10px; float: left; width: 100%; }
fieldset.q .scale { clear: both; }
fieldset.q.missing { background: var(--warn-bg); border-radius: 10px; padding-left: 10px; padding-right: 10px; }
.scale { display: grid; grid-template-columns: repeat(5, 1fr); gap: 6px; }
.opt input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.opt label {
  display: flex; align-items: center; justify-content: center; text-align: center;
  font-weight: 500; font-size: .85rem; line-height: 1.2; min-height: 48px; padding: 6px 4px; margin: 0;
  border: 1.5px solid var(--line); border-radius: 10px; cursor: pointer; background: var(--bg);
}
.opt input:checked + label { background: var(--accent); border-color: var(--accent); color: #fff; }
.opt input:focus-visible + label { outline: 3px solid var(--amber); outline-offset: 2px; }
@media (max-width: 520px) {
  .scale { grid-template-columns: 1fr; }
  .opt label { justify-content: flex-start; padding: 10px 14px; font-size: 1rem; }
}

.bar-row { margin-bottom: 16px; }
.bar-head { display: flex; justify-content: space-between; gap: 12px; font-size: .95rem; margin-bottom: 4px; }
.bar-name { font-weight: 600; } .bar-val { color: var(--muted); white-space: nowrap; }
.bar { height: 14px; background: var(--line); border-radius: 999px; overflow: hidden; }
.bar-fill { height: 100%; border-radius: 999px; }
.band-low { background: var(--green); } .band-moderate { background: var(--amber); }
.band-high { background: var(--red); } .band-very-high { background: var(--red-deep); }

.signpost { background: var(--note-bg); border-left: 4px solid var(--accent); border-radius: 8px; padding: 10px 14px; margin-top: 10px; font-size: .95rem; }
.signpost p { margin: 0; }
.step { border-top: 1px solid var(--line); padding-top: 16px; margin-top: 16px; }
.step:first-of-type { border-top: 0; padding-top: 0; margin-top: 0; }
.step .after { margin-top: 18px; }
.safety { font-size: .92rem; color: var(--muted); }
.care { font-size: .95rem; font-weight: 600; }
.summary { border-top: 1px solid var(--line); margin-top: 18px; padding-top: 16px; }
.summary h2 { font-size: 1.15rem; }
.top-signpost { max-width: 680px; margin: 0 auto 12px; }
.adults { color: var(--muted); font-weight: 600; }

.site-footer { color: var(--muted); font-size: .88rem; padding-bottom: 40px; }
.link-btn { font: inherit; background: none; border: 0; color: var(--accent); text-decoration: underline; cursor: pointer; padding: 4px 0; }
[hidden] { display: none !important; }
