:root{
  --brand: #0b5ed7;
  --ink: #111;
  --muted: #5b6675;
  --panel: #0b1220;

  /* consistent score colours (web + pdf match these) */
  --score-bad: #dc3545;
  --score-okay: #f59e0b;
  --score-good: #198754;

  --score-track: rgba(17,17,17,.12);
}

body{
  color: var(--ink);
}

a:hover,
a:active,
.active {
  text-decoration: underline;
}

.skip-link{
  position: absolute;
  left: -999px;
  top: 0;
  background: #fff;
  padding: .5rem .75rem;
  border: 2px solid #000;
  z-index: 10000;
}
.skip-link:focus{
  left: .75rem;
  top: .75rem;
}

/* header (if you’ve made it sticky already) */
.site-header{
  z-index: 1030;
  box-shadow: 0 6px 20px rgba(0,0,0,.06);
}

.brand-mark{
  display:inline-block;
  transform: translateY(-1px);
  margin-right:.35rem;
}

.hero{
  background:
    radial-gradient(1000px 500px at 10% 10%, rgba(11,94,215,0.20), transparent 60%),
    radial-gradient(900px 500px at 90% 30%, rgba(20,184,166,0.14), transparent 60%),
    linear-gradient(180deg, #ffffff, #f7f9fc);
  border-bottom: 1px solid rgba(0,0,0,.08);
}

.hero-card{
  border: 1px solid rgba(0,0,0,.08);
  border-radius: 1rem;
  box-shadow: 0 10px 30px rgba(0,0,0,.06);
}

.kbd-hint{
  color: var(--muted);
}

/* ===== Results scoreboard ===== */

.scoreboard{
  display: grid;
  grid-template-columns: 148px 1fr;
  gap: 1.25rem;
  align-items: center;
}

@media (max-width: 575.98px){
  .scoreboard{
    grid-template-columns: 1fr;
    justify-items: start;
  }
}

/* Donut component */
.score-donut{
  --value: 0%;
  --ring: var(--brand);
  --track: var(--score-track);
  --cutout: var(--bs-body-bg, #fff);

  position: relative;
  display: grid;
  place-items: center;
  border-radius: 999px;

  /* pop + depth */
  box-shadow:
    0 14px 28px rgba(0,0,0,.10),
    0 2px 6px rgba(0,0,0,.06);

  border: 1px solid rgba(0,0,0,.10);

  /* IMPORTANT: var(--value) includes % now */
  background:
    conic-gradient(from -90deg,
      var(--ring) 0 var(--value),
      var(--track) 0 100%
    );
}

.score-donut::before{
  content: "";
  position: absolute;
  border-radius: 999px;
  background: var(--cutout);

  /* thicker ring looks more premium */
  inset: 12px;

  box-shadow:
    inset 0 0 0 1px rgba(0,0,0,.06),
    inset 0 10px 18px rgba(0,0,0,.03);
}

.score-donut__center{
  position: relative;
  text-align: center;
  line-height: 1.1;
}

.score-donut__value{
  font-weight: 900;
  font-size: 1.7rem;
  letter-spacing: -0.02em;
}

.score-donut__caption{
  font-size: .85rem;
  color: var(--muted);
  margin-top: .15rem;
}

.score-donut--xl{
  width: 124px;
  height: 124px;
}

.score-donut--xl::before{
  inset: 14px;
}

.score-donut--lg{
  width: 124px;
  height: 124px;
}

.score-donut--lg::before{
  inset: 14px;
}

.score-donut--sm{
  width: 88px;
  height: 88px;
}

.score-donut--sm::before{
  inset: 11px;
}

.score-donut--bad{ --ring: var(--score-bad); }
.score-donut--okay{ --ring: var(--score-okay); }
.score-donut--good{ --ring: var(--score-good); }

.score-mini{
  display: grid;
  justify-items: center;
  gap: .35rem;
}

.score-mini--muted{
  align-content: center;
}

.score-mini__placeholder{
  display: grid;
  place-items: center;
  min-height: 88px;
  padding: .55rem .75rem;
  border: 1px dashed rgba(0,0,0,.18);
  border-radius: .85rem;
  background: rgba(0,0,0,.02);
}

/* Progress bar width set by JS */
.progress-bar{
  width: 0;
  transition: width 220ms ease;
}

@media (prefers-reduced-motion: reduce){
  .progress-bar{ transition: none; }
}

/* ===== Existing components ===== */

.badge-term{
  display:inline-flex;
  align-items:center;
  gap:.25rem;
  border: 1px solid rgba(0,0,0,.12);
  border-radius: 999px;
  padding: .25rem .6rem;
  margin: .15rem .15rem 0 0;
  background: #fff;
}

.footer{
  background: #fff;
}

.cookie-banner{
  position: sticky;
  bottom: 0;
  background: #fff;
  border-top: 1px solid rgba(0,0,0,.12);
}

.form-textarea{
  min-height: 180px;
}

.focus-outline:focus{
  outline: 3px solid rgba(11,94,215,.35);
  outline-offset: 2px;
}
