@font-face {
  font-family: 'Heebo';
  src: url('assets/Heebo-VF.ttf') format('truetype');
  font-weight: 100 900;
  font-display: swap;
}
:root {
  --navy: #0B2743;
  --navy-2: #14385e;
  --orange: #F58220;
  --orange-dark: #B35400; /* text-safe orange on light bg (AA) */
  --bg: #F6F6F4;
  --card: #FFFFFF;
  --line: #DCDFE4;
  --muted: #4A5868;
  --ok: #1E6B45;
  --err: #A4161A;
  --radius: 14px;
  --focus: 0 0 0 3px #fff, 0 0 0 6px var(--orange);
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: 'Heebo', 'Segoe UI', Arial, sans-serif;
  background: var(--bg);
  color: var(--navy);
  font-size: 17px;
  line-height: 1.6;
}
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: absolute; inset-inline-start: 8px; top: -60px; background: var(--navy); color: #fff; padding: 10px 14px; border-radius: 8px; z-index: 10; }
.skip:focus { top: 8px; }
:focus-visible { outline: none; box-shadow: var(--focus); border-radius: 8px; }

[hidden] { display: none !important; }
.test-banner { background: #FFF3E6; color: #7A3A00; text-align: center; font-size: 14px; padding: 6px 12px; border-bottom: 1px solid #F3C99B; }

.top { max-width: 760px; margin: 0 auto; padding: 14px 18px; display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.logo { height: 48px; width: auto; }
.lang-btn {
  font: inherit; font-weight: 600; font-size: 15px;
  background: transparent; color: var(--navy); border: 2px solid var(--navy); border-radius: 999px;
  padding: 6px 16px; min-height: 44px; cursor: pointer;
}
.lang-btn:hover { background: var(--navy); color: #fff; }

main { max-width: 760px; margin: 0 auto; padding: 8px 18px 40px; outline: none; }
.foot { text-align: center; color: var(--muted); font-size: 14px; padding: 24px 18px 36px; }

h1, h2, h3 { line-height: 1.25; margin: 0 0 10px; }
h1 { font-size: clamp(26px, 6vw, 38px); font-weight: 900; }
h2 { font-size: 22px; font-weight: 800; }
h3 { font-size: 18px; font-weight: 700; }
h1:focus, h2:focus { outline: none; }
p { margin: 0 0 12px; }

/* ---- buttons */
.btn {
  font: inherit; font-weight: 700; font-size: 18px;
  border: 0; border-radius: 999px; padding: 14px 28px; min-height: 52px;
  cursor: pointer; display: inline-flex; align-items: center; justify-content: center; gap: 8px; text-decoration: none;
}
.btn-primary { background: var(--orange); color: var(--navy); }
.btn-primary:hover { background: #ff9640; }
.btn-secondary { background: transparent; color: var(--navy); border: 2px solid var(--line); }
.btn-secondary:hover { border-color: var(--navy); }
.btn-navy { background: var(--navy); color: #fff; }
.btn-navy:hover { background: var(--navy-2); }
.btn[disabled] { opacity: .6; cursor: progress; }

/* ---- intro */
.intro { background: var(--card); border-radius: 22px; padding: 30px 26px; box-shadow: 0 2px 0 var(--line); border-top: 6px solid var(--orange); }
.intro .lead { font-size: 19px; color: var(--navy-2); font-weight: 500; }
.intro .body { color: var(--muted); }
.intro .privacy { font-size: 14px; color: var(--muted); margin-top: 14px; }

/* ---- question */
.progress-row { display: flex; justify-content: space-between; align-items: center; font-size: 15px; color: var(--muted); margin-bottom: 6px; }
.bar { height: 8px; border-radius: 99px; background: #E4E6EA; overflow: hidden; margin-bottom: 22px; }
.bar > span { display: block; height: 100%; background: var(--orange); border-radius: 99px; transition: width .25s; }
fieldset { border: 0; margin: 0; padding: 0; min-width: 0; }
legend { padding: 0; width: 100%; }
.hint { color: var(--muted); margin: 0 0 4px; }
.pick-info { display: inline-block; font-size: 14px; font-weight: 700; background: #E8EDF3; color: var(--navy); padding: 3px 12px; border-radius: 99px; margin: 4px 0 16px; }
.options { display: grid; gap: 10px; }
.opt {
  position: relative; display: flex; align-items: center; gap: 14px;
  background: var(--card); border: 2px solid var(--line); border-radius: var(--radius);
  padding: 14px 16px; min-height: 58px; cursor: pointer; font-size: 17px; font-weight: 500;
  transition: border-color .15s, background .15s;
}
.opt:hover { border-color: #9AA7B6; }
.opt input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.opt .mark {
  flex: 0 0 auto; width: 24px; height: 24px; border: 2px solid #8796A8; background: #fff;
  display: inline-flex; align-items: center; justify-content: center;
}
.opt.radio .mark { border-radius: 50%; }
.opt.check .mark { border-radius: 6px; }
.opt input:checked ~ .mark { border-color: var(--orange); background: var(--orange); }
.opt.radio input:checked ~ .mark::after { content: ''; width: 9px; height: 9px; border-radius: 50%; background: #fff; }
.opt.check input:checked ~ .mark::after { content: ''; width: 6px; height: 11px; border: solid #fff; border-width: 0 3px 3px 0; transform: rotate(45deg) translate(-1px, -1px); }
.opt:has(input:checked) { border-color: var(--orange); background: #FFF8F1; }
.opt:has(input:focus-visible) { box-shadow: var(--focus); }
.opt .excl { display: block; font-size: 13px; color: var(--muted); font-weight: 400; }

.insight { margin-top: 16px; background: #EEF3F8; border-inline-start: 5px solid var(--navy); border-radius: 10px; padding: 12px 16px; font-size: 16px; }
.insight strong { display: block; font-size: 13px; text-transform: none; color: var(--muted); margin-bottom: 2px; }
.error { color: var(--err); font-weight: 600; margin-top: 12px; min-height: 1px; }
.error:empty { display: none; }

.nav { display: flex; gap: 12px; margin-top: 24px; justify-content: space-between; flex-wrap: wrap; }
.nav .btn-primary { flex: 1 1 auto; max-width: 320px; margin-inline-start: auto; }

.consent { margin-top: 18px; background: var(--card); border: 2px dashed #B9C3CF; border-radius: var(--radius); padding: 14px 16px; font-size: 15px; }
.consent label { display: flex; gap: 10px; align-items: flex-start; font-weight: 600; margin-top: 8px; cursor: pointer; }
.consent input { width: 22px; height: 22px; margin: 2px 0 0; accent-color: var(--orange); flex: 0 0 auto; }

/* ---- loading / error */
.state { text-align: center; padding: 50px 10px; }
.spinner { width: 44px; height: 44px; border-radius: 50%; border: 5px solid #E4E6EA; border-top-color: var(--orange); margin: 0 auto 16px; animation: spin 0.9s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
@media (prefers-reduced-motion: reduce) { .spinner { animation-duration: 3s; } .bar > span { transition: none; } }
.state .btns { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; margin-top: 16px; }

/* ---- report */
.report-head { background: var(--navy); color: #fff; border-radius: 22px 22px 0 0; padding: 26px 24px 22px; }
.report-head h1 { color: #fff; }
.badge { display: inline-block; background: var(--orange); color: var(--navy); font-weight: 800; font-size: 14px; border-radius: 99px; padding: 3px 12px; margin-bottom: 10px; }
.badge-note { font-size: 14px; color: #C9D6E4; margin: 6px 0 0; }
.report-body { background: var(--card); border-radius: 0 0 22px 22px; padding: 8px 24px 26px; }
.sec { padding: 22px 0; border-bottom: 1px solid var(--line); }
.sec:last-child { border-bottom: 0; }
.sec h2 { display: flex; align-items: center; gap: 10px; }
.sec h2 .num { flex: 0 0 auto; width: 32px; height: 32px; border-radius: 50%; background: var(--orange); color: var(--navy); display: inline-flex; align-items: center; justify-content: center; font-size: 16px; font-weight: 900; }
.idea { border: 1px solid var(--line); border-radius: var(--radius); padding: 16px; margin-top: 14px; }
.idea h3 { color: var(--navy); }
dl.kv { margin: 0; display: grid; gap: 6px; }
dl.kv dt { font-weight: 700; font-size: 14px; color: var(--orange-dark); margin-top: 6px; }
dl.kv dd { margin: 0; }
.muted { color: var(--muted); }
ul.clean { margin: 4px 0 0; padding-inline-start: 22px; }
ul.clean li { margin-bottom: 4px; }
.month { display: grid; gap: 10px; margin-top: 12px; }
.month .wk { border-inline-start: 4px solid var(--orange); background: #FAFAF8; border-radius: 10px; padding: 12px 14px; }
.month .wk h3 { margin-bottom: 4px; }
.first-box { background: #FFF8F1; border: 2px solid #F8C69A; border-radius: var(--radius); padding: 18px; margin-top: 10px; }
.structure { list-style: none; padding: 0; margin: 6px 0 0; display: grid; gap: 6px; }
.structure li { display: flex; gap: 10px; }
.structure .t { flex: 0 0 auto; min-width: 82px; font-weight: 700; color: var(--navy-2); }
.caption { background: #EEF3F8; border-radius: 10px; padding: 12px 14px; font-weight: 500; margin-top: 6px; }
.note { font-size: 14px; color: var(--muted); margin-top: 10px; }
.today { font-size: 19px; font-weight: 600; background: #EEF3F8; border-radius: 12px; padding: 14px 16px; }
.actions { display: flex; gap: 10px; flex-wrap: wrap; margin: 18px 0 0; }
.status { min-height: 24px; margin-top: 8px; font-weight: 600; color: var(--ok); }
.cta { margin-top: 22px; background: var(--navy); color: #fff; border-radius: 22px; padding: 26px 24px; text-align: center; }
.cta h2 { color: #fff; font-size: 26px; }
.cta p { color: #DCE6F1; }
.cta .wa-note { font-size: 13px; color: #AFC2D6; margin-top: 12px; }
.cta .dev-note { font-size: 13px; color: #FFD3AA; margin-top: 6px; }

@media (max-width: 520px) {
  body { font-size: 16px; }
  .top { padding: 10px 14px; }
  .logo { height: 40px; }
  main { padding: 4px 12px 30px; }
  .intro { padding: 24px 18px; }
  .report-head, .report-body, .cta { padding-inline: 16px; }
  .nav .btn { flex: 1 1 100%; max-width: none; }
  .nav .btn-secondary { order: 2; }
  .structure li { flex-direction: column; gap: 0; }
  .actions .btn, .state .btns .btn { flex: 1 1 100%; }
}
@media print {
  .test-banner, .top, .actions, .cta .btn, .foot { display: none; }
  body { background: #fff; }
}
