/* ==========================================================================
   Ethio IQ — Personality Discovery Assessment
   A deliberately separate design system from the main site.

   The site is dark and technology forward. This is not. An assessment a
   fifteen year old will read on a phone, and may show a parent, wants paper
   rather than console: warm white, real margins, one editorial serif, and
   restraint. Borders do the work that shadows usually do, corners are barely
   rounded, and the orange appears only where it means something.
   ========================================================================== */

/* ---------- 1. Tokens ---------- */
:root{
  /* Paper */
  --paper:      #FFFFFF;
  --sand:       #FBF8F4;
  --sand-2:     #F4EFE8;
  --sand-3:     #EBE3D9;

  /* Ink */
  --ink:        #17140F;
  --ink-2:      #4B443B;
  --ink-3:      #7C7167;
  --ink-4:      #A89D91;

  --line:       #E8E0D5;
  --line-2:     #D8CCBC;

  /* Brand, used sparingly */
  --brand:      #EE6E2F;
  --brand-deep: #C4551C;
  --brand-tint: #FDF0E7;
  --brand-line: #F6C9AB;

  /* One colour per dimension. Never the only signal for anything. */
  --energy:     #C2571F;
  --info:       #2E7D74;
  --decide:     #4A55A0;
  --approach:   #8A4A73;

  --ok:         #2F7D4F;
  --warn:       #9A6B1E;

  --font-display: "Fraunces", Georgia, "Times New Roman", serif;
  --font-body:    "Inter", system-ui, -apple-system, "Segoe UI", sans-serif;
  --font-eth:     "Noto Sans Ethiopic", "Inter", sans-serif;

  /* A slightly tighter scale than the marketing site. This is reading, not
     announcing. */
  --t-display: clamp(2.3rem, 1.4rem + 3.6vw, 4.1rem);
  --t-h1:      clamp(1.9rem, 1.3rem + 2.4vw, 3rem);
  --t-h2:      clamp(1.35rem, 1.1rem + 1.1vw, 1.85rem);
  --t-h3:      clamp(1.05rem, .98rem + .4vw, 1.25rem);
  --t-lead:    clamp(1.02rem, .97rem + .32vw, 1.18rem);
  --t-body:    clamp(.95rem, .93rem + .12vw, 1rem);
  --t-sm:      .875rem;
  --t-xs:      .78rem;

  --gutter:    clamp(1.15rem, .5rem + 2.6vw, 3.5rem);
  --measure:   66ch;

  --r-xs: 3px; --r: 6px; --r-lg: 10px; --r-pill: 999px;

  --sh-1: 0 1px 2px rgba(23,20,15,.05);
  --sh-2: 0 4px 16px rgba(23,20,15,.07);
  --sh-3: 0 18px 48px rgba(23,20,15,.11);

  --e-out:  cubic-bezier(.2,.7,.3,1);
  --e-soft: cubic-bezier(.4,0,.2,1);
  --e-back: cubic-bezier(.3,1.4,.5,1);
  --d-1: .16s; --d-2: .3s; --d-3: .55s;

  color-scheme: light;
}

/* ---------- 2. Reset ---------- */
*,*::before,*::after{ box-sizing:border-box; }
*{ margin:0; }
html{ -webkit-text-size-adjust:100%; scroll-behavior:smooth; }
body{
  font-family:var(--font-body);
  font-size:var(--t-body);
  line-height:1.62;
  color:var(--ink);
  background:var(--sand);
  -webkit-font-smoothing:antialiased;
  font-feature-settings:"kern","liga","calt";
}
img,svg,canvas{ display:block; max-width:100%; }
button,input,select,textarea{ font:inherit; color:inherit; }
button{ background:none; border:0; cursor:pointer; text-align:inherit; }
a{ color:inherit; }
ul,ol{ list-style:none; padding:0; }
h1,h2,h3{ font-family:var(--font-display); font-weight:600; line-height:1.14; letter-spacing:-.012em; }
h1{ font-variation-settings:"SOFT" 0,"WONK" 0; }
p{ text-wrap:pretty; }
:focus-visible{ outline:2px solid var(--brand); outline-offset:3px; border-radius:var(--r-xs); }
::selection{ background:var(--brand-tint); }
.am{ font-family:var(--font-eth); }

/* ---------- 3. Shell ---------- */
.wrap{ width:min(100% - var(--gutter)*2, 1080px); margin-inline:auto; }
.wrap-tight{ width:min(100% - var(--gutter)*2, 760px); margin-inline:auto; }
.stage{ display:none; }
.stage.on{ display:block; animation:stageIn .5s var(--e-out); }
@keyframes stageIn{ from{ opacity:0; transform:translateY(10px); } to{ opacity:1; transform:none; } }
.sr-only{
  position:absolute; width:1px; height:1px; padding:0; margin:-1px;
  overflow:hidden; clip:rect(0 0 0 0); white-space:nowrap; border:0;
}
.hide{ display:none !important; }

/* ---------- 4. Masthead ---------- */
.mast{
  display:flex; align-items:center; justify-content:space-between; gap:1rem;
  padding:1.15rem 0; border-bottom:1px solid var(--line);
}
.mast .brand{ display:flex; align-items:center; gap:.7rem; }
.mast .brand img{ height:26px; width:auto; }
.mast .brand span{
  font-size:var(--t-xs); letter-spacing:.14em; text-transform:uppercase;
  color:var(--ink-3); font-weight:600; padding-left:.7rem; border-left:1px solid var(--line-2);
  white-space:nowrap;
}
/* On a narrow phone the logo and four language buttons are all the room
   there is, so the product label steps aside rather than overlapping. */
@media (max-width:560px){
  .mast .brand span{ display:none; }
  .mast .brand img{ height:23px; }
  .mast .lang button{ padding:.34rem .55rem; }
}
.mast .lang{ display:flex; gap:.2rem; }
.mast .lang button{
  padding:.34rem .7rem; font-size:var(--t-xs); font-weight:600; color:var(--ink-3);
  border-radius:var(--r-xs); transition:color var(--d-1), background var(--d-1);
}
.mast .lang button:hover{ color:var(--ink); background:var(--sand-2); }
.mast .lang button[aria-pressed="true"]{ color:var(--brand-deep); background:var(--brand-tint); }

/* ---------- 5. Buttons ---------- */
.btn{
  display:inline-flex; align-items:center; justify-content:center; gap:.5rem;
  padding:.82rem 1.5rem; border-radius:var(--r); font-size:.94rem; font-weight:600;
  letter-spacing:-.005em; white-space:nowrap;
  transition:background var(--d-2) var(--e-out), color var(--d-2), border-color var(--d-2),
             transform var(--d-1) var(--e-out), box-shadow var(--d-2);
}
.btn:active{ transform:translateY(1px); }
.btn-primary{ background:var(--brand); color:#fff; box-shadow:var(--sh-1); }
.btn-primary:hover{ background:var(--brand-deep); box-shadow:var(--sh-2); }
.btn-quiet{ background:transparent; color:var(--ink-2); border:1px solid var(--line-2); }
.btn-quiet:hover{ background:var(--sand-2); border-color:var(--ink-4); color:var(--ink); }
.btn-text{ padding:.6rem .2rem; color:var(--ink-3); font-weight:500; }
.btn-text:hover{ color:var(--brand-deep); }
.btn-lg{ padding:1rem 1.9rem; font-size:1rem; }
.btn[disabled]{ opacity:.42; pointer-events:none; }
.btn-row{ display:flex; gap:.7rem; flex-wrap:wrap; }

/* ---------- 6. Landing ---------- */
.lede{ padding:clamp(2.6rem,1.6rem + 4vw,5.5rem) 0 clamp(2rem,1.4rem + 3vw,4rem); }
.lede-grid{ display:grid; grid-template-columns:1.08fr .92fr; gap:clamp(2rem,1rem + 4vw,4.5rem); align-items:center; }
@media (max-width:860px){ .lede-grid{ grid-template-columns:1fr; gap:2.4rem; } }
.kicker{
  font-size:var(--t-xs); letter-spacing:.16em; text-transform:uppercase;
  color:var(--brand-deep); font-weight:700; display:block; margin-bottom:1.1rem;
}
.lede h1{ font-size:var(--t-display); margin-bottom:1.3rem; }
.lede h1 em{ font-style:italic; color:var(--brand-deep); }
.lede p.lead{ font-size:var(--t-lead); color:var(--ink-2); max-width:52ch; }

.facts{ display:grid; grid-template-columns:repeat(3,auto); gap:0; margin:2.4rem 0; width:max-content; max-width:100%; }
@media (max-width:520px){ .facts{ grid-template-columns:1fr; } }
.facts div{ padding:0 1.6rem; border-left:1px solid var(--line); }
.facts div:first-child{ padding-left:0; border-left:0; }
@media (max-width:520px){
  .facts div{ padding:.7rem 0 .7rem 1rem; border-left:2px solid var(--line); }
  .facts div:first-child{ padding-left:1rem; border-left:2px solid var(--line); }
}
.facts .n{ font-family:var(--font-display); font-size:1.5rem; font-weight:600; display:block; }
.facts .l{ font-size:var(--t-xs); color:var(--ink-3); letter-spacing:.04em; }

.notice{
  display:flex; gap:.8rem; padding:1rem 1.15rem; border-radius:var(--r);
  background:var(--paper); border:1px solid var(--line); font-size:var(--t-sm); color:var(--ink-2);
  max-width:56ch;
}
.notice strong{ color:var(--ink); font-weight:600; }
.notice .mk{ width:3px; border-radius:2px; background:var(--brand); flex-shrink:0; }

/* ---------- 7. The compass, our one illustration ---------- */
.compass{ width:min(100%,380px); margin-inline:auto; aspect-ratio:1; position:relative; }
@media (max-width:860px){ .compass{ width:min(76%,300px); } }
@media (max-width:480px){ .compass{ width:min(84%,250px); } }
.compass svg{ width:100%; height:100%; overflow:visible; }
.compass .ring{ fill:none; stroke:var(--line-2); stroke-width:1.2; }
.compass .axis{ stroke:var(--line-2); stroke-width:1; stroke-dasharray:2 5; }
.compass .petal{
  fill:var(--c,var(--brand)); opacity:.18; stroke:var(--c,var(--brand)); stroke-width:1.4;
  /* transform-box is what makes transform-origin mean the centre of this
     shape rather than the centre of the whole drawing. Without it the petals
     scale from the corner of the viewport and fly off. */
  transform-box:fill-box; transform-origin:center; transform:scale(var(--s,.5));
  transition:transform 1.1s var(--e-back), opacity var(--d-3);
}
.compass .node{ fill:var(--c,var(--brand)); transition:r var(--d-3) var(--e-back); }
.compass .pole{
  font-family:var(--font-body); font-size:11px; font-weight:600;
  fill:var(--ink-3); letter-spacing:.08em; text-transform:uppercase;
}
.compass.live .petal{ animation:petalBreathe 7s var(--e-soft) infinite alternate; }
@keyframes petalBreathe{ from{ opacity:.14; } to{ opacity:.26; } }

/* ---------- 8. Form ---------- */
.panel{
  background:var(--paper); border:1px solid var(--line); border-radius:var(--r-lg);
  padding:clamp(1.4rem,1rem + 1.8vw,2.6rem);
}
.panel + .panel{ margin-top:1.2rem; }
.panel-title{ font-size:var(--t-h2); margin-bottom:.4rem; }
.panel-sub{ color:var(--ink-3); font-size:var(--t-sm); margin-bottom:1.8rem; }

.row{ display:grid; gap:1.1rem; }
@media (min-width:640px){ .row.two{ grid-template-columns:1fr 1fr; } .row.three{ grid-template-columns:repeat(3,1fr); } }
.fld{ display:grid; gap:.4rem; }
.fld label{ font-size:var(--t-sm); font-weight:600; color:var(--ink-2); }
.fld .req{ color:var(--brand-deep); }
.fld .hint{ font-size:var(--t-xs); color:var(--ink-4); }
.fld input,.fld select{
  width:100%; padding:.78rem .9rem; border-radius:var(--r);
  background:var(--paper); border:1px solid var(--line-2); color:var(--ink);
  font-size:.96rem; transition:border-color var(--d-2), box-shadow var(--d-2), background var(--d-2);
}
.fld input::placeholder{ color:var(--ink-4); }
.fld input:focus,.fld select:focus{
  outline:none; border-color:var(--brand); box-shadow:0 0 0 3px var(--brand-tint);
}
.fld select{
  appearance:none; cursor:pointer; padding-right:2.4rem;
  background-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' fill='none'%3E%3Cpath d='M1 1l5 5 5-5' stroke='%237C7167' stroke-width='1.6' stroke-linecap='round'/%3E%3C/svg%3E");
  background-repeat:no-repeat; background-position:right .95rem center;
}
.fld.bad input,.fld.bad select{ border-color:#B3472F; box-shadow:0 0 0 3px #FBEAE5; }
.fld .err{ font-size:var(--t-xs); color:#B3472F; display:none; }
.fld.bad .err{ display:block; }

/* ---------- 9. Assessment chrome ---------- */
.runner{ min-height:100svh; display:flex; flex-direction:column; background:var(--sand); }
.runbar{
  position:sticky; top:0; z-index:40; background:rgba(251,248,244,.94);
  backdrop-filter:blur(10px); border-bottom:1px solid var(--line);
}
.runbar .inner{ display:flex; align-items:center; gap:1.1rem; padding:.85rem 0; }
.runbar .count{ font-size:var(--t-xs); color:var(--ink-3); font-variant-numeric:tabular-nums; white-space:nowrap; }
.runbar .count b{ color:var(--ink); font-weight:600; }

/* The journey: five named stages rather than a bare bar. */
.journey{ flex:1; display:flex; align-items:center; gap:.4rem; min-width:0; }
.journey .leg{ flex:1; display:grid; gap:.42rem; min-width:0; }
.journey .leg .track{ display:block; height:3px; border-radius:2px; background:var(--sand-3); overflow:hidden; }
.journey .leg .track i{
  display:block; height:100%; width:0; border-radius:2px; background:var(--brand);
  transition:width .6s var(--e-out);
}
.journey .leg > span:last-child{
  display:block;
  font-size:.66rem; letter-spacing:.09em; text-transform:uppercase; color:var(--ink-4);
  font-weight:600; white-space:nowrap; overflow:hidden; text-overflow:ellipsis;
  transition:color var(--d-2);
}
.journey .leg.on span{ color:var(--brand-deep); }
.journey .leg.done span{ color:var(--ink-3); }
@media (max-width:720px){
  /* The leg names do not fit on a phone, so the bars carry the progress on
     their own and the question counter beside them carries the number. */
  .journey .leg > span:last-child{ display:none; }
  .journey .leg .track{ height:5px; }
}

.saved{ font-size:var(--t-xs); color:var(--ink-4); white-space:nowrap; }
.saved.on{ color:var(--ok); }
@media (max-width:560px){ .saved{ display:none; } }

/* ---------- 10. Question ---------- */
.qwrap{ flex:1; display:flex; align-items:flex-start; padding:clamp(1.8rem,1rem + 4vw,4.5rem) 0 2rem; }
.q{ width:100%; }
.q.leaving{ animation:qOut .22s var(--e-soft) forwards; }
.q.entering{ animation:qIn .38s var(--e-out); }
@keyframes qOut{ to{ opacity:0; transform:translateX(-14px); } }
@keyframes qIn{ from{ opacity:0; transform:translateX(16px); } to{ opacity:1; transform:none; } }

.q .tag{
  display:inline-flex; align-items:center; gap:.5rem; font-size:var(--t-xs);
  letter-spacing:.11em; text-transform:uppercase; font-weight:700; color:var(--ink-4);
  margin-bottom:1.1rem;
}
.q .tag i{ width:7px; height:7px; border-radius:50%; background:var(--dim,var(--brand)); }
.q h2{
  font-size:clamp(1.3rem,1.05rem + 1.5vw,2.05rem); line-height:1.26;
  max-width:28ch; margin-bottom:1.9rem;
}
.q .scenario{
  font-size:var(--t-body); color:var(--ink-2); max-width:54ch; margin:-1.1rem 0 1.9rem;
  padding-left:1rem; border-left:2px solid var(--line-2);
}

/* Likert: seven named steps, never bare numbers. */
.likert{ display:grid; gap:.45rem; max-width:620px; }
.lk{
  display:flex; align-items:center; gap:.9rem; width:100%;
  padding:.85rem 1.05rem; border-radius:var(--r);
  background:var(--paper); border:1px solid var(--line);
  font-size:.95rem; color:var(--ink-2);
  transition:border-color var(--d-1), background var(--d-1), transform var(--d-1) var(--e-out), color var(--d-1);
}
.lk:hover{ border-color:var(--line-2); background:var(--sand-2); transform:translateX(3px); }
.lk .dot{
  width:15px; height:15px; border-radius:50%; border:1.5px solid var(--line-2);
  flex-shrink:0; position:relative; transition:border-color var(--d-1);
}
.lk .dot::after{
  content:""; position:absolute; inset:2.5px; border-radius:50%;
  background:var(--brand); transform:scale(0); transition:transform var(--d-2) var(--e-back);
}
.lk[aria-pressed="true"]{ border-color:var(--brand); background:var(--brand-tint); color:var(--ink); font-weight:500; }
.lk[aria-pressed="true"] .dot{ border-color:var(--brand); }
.lk[aria-pressed="true"] .dot::after{ transform:scale(1); }
/* Weight shown as a quiet rule, so the scale reads as a scale. */
.lk .w{ margin-left:auto; height:2px; border-radius:1px; background:var(--sand-3); flex-shrink:0; }
.lk[aria-pressed="true"] .w{ background:var(--brand-line); }

/* Two scenarios, side by side. */
.pair{ display:grid; grid-template-columns:1fr 1fr; gap:.9rem; max-width:760px; }
@media (max-width:640px){ .pair{ grid-template-columns:1fr; } }
.pick{
  display:grid; gap:.65rem; align-content:start; padding:1.3rem 1.35rem;
  border-radius:var(--r-lg); background:var(--paper); border:1px solid var(--line);
  transition:border-color var(--d-2), box-shadow var(--d-2), transform var(--d-2) var(--e-out);
}
.pick:hover{ border-color:var(--line-2); box-shadow:var(--sh-2); transform:translateY(-3px); }
.pick .ltr{
  width:26px; height:26px; border-radius:var(--r-xs); display:grid; place-items:center;
  background:var(--sand-2); color:var(--ink-3); font-size:.74rem; font-weight:700;
  transition:background var(--d-2), color var(--d-2);
}
.pick p{ font-size:.97rem; color:var(--ink-2); line-height:1.55; }
.pick[aria-pressed="true"]{ border-color:var(--brand); box-shadow:0 0 0 1px var(--brand); }
.pick[aria-pressed="true"] .ltr{ background:var(--brand); color:#fff; }
.pick[aria-pressed="true"] p{ color:var(--ink); }

/* Slider between two named ends. */
.slide{ max-width:620px; }
.slide .ends{ display:flex; justify-content:space-between; gap:1rem; margin-bottom:.9rem; }
.slide .ends span{ font-size:var(--t-sm); color:var(--ink-3); max-width:20ch; }
.slide .ends span:last-child{ text-align:right; }
.slide input[type=range]{
  width:100%; appearance:none; height:30px; background:transparent; cursor:pointer;
}
.slide input[type=range]::-webkit-slider-runnable-track{
  height:4px; border-radius:2px;
  background:linear-gradient(90deg,var(--brand) var(--pct,50%), var(--sand-3) var(--pct,50%));
}
.slide input[type=range]::-moz-range-track{ height:4px; border-radius:2px; background:var(--sand-3); }
.slide input[type=range]::-moz-range-progress{ height:4px; border-radius:2px; background:var(--brand); }
.slide input[type=range]::-webkit-slider-thumb{
  appearance:none; width:26px; height:26px; margin-top:-11px; border-radius:50%;
  background:var(--paper); border:2px solid var(--brand); box-shadow:var(--sh-2);
  transition:transform var(--d-1) var(--e-back);
}
.slide input[type=range]:active::-webkit-slider-thumb{ transform:scale(1.14); }
.slide input[type=range]::-moz-range-thumb{
  width:22px; height:22px; border-radius:50%; background:var(--paper);
  border:2px solid var(--brand); box-shadow:var(--sh-2);
}
.slide .read{ margin-top:.9rem; font-size:var(--t-sm); color:var(--ink-3); min-height:1.5em; }
.slide .read b{ color:var(--ink); font-weight:600; }

.qnav{
  display:flex; align-items:center; justify-content:space-between; gap:1rem;
  margin-top:2.6rem; padding-top:1.4rem; border-top:1px solid var(--line); max-width:760px;
}

/* ---------- 11. Analysis ---------- */
.analysis{ min-height:100svh; display:grid; place-items:center; text-align:center; padding:2rem var(--gutter); }
.analysis .steps{ display:grid; gap:1rem; margin:2.6rem 0; justify-items:center; }
.analysis .st{
  display:flex; align-items:center; gap:.75rem; font-size:1.02rem; color:var(--ink-4);
  opacity:.35; transition:opacity var(--d-3), color var(--d-3);
}
.analysis .st.on{ opacity:1; color:var(--ink); }
.analysis .st.done{ opacity:1; color:var(--ink-3); }
.analysis .st .mk{
  width:16px; height:16px; border-radius:50%; border:1.5px solid var(--line-2);
  display:grid; place-items:center; flex-shrink:0;
}
.analysis .st.on .mk{ border-color:var(--brand); }
.analysis .st.on .mk::after{
  content:""; width:6px; height:6px; border-radius:50%; background:var(--brand);
  animation:pulseDot 1.1s var(--e-soft) infinite;
}
.analysis .st.done .mk{ border-color:var(--ok); background:var(--ok); }
.analysis .st.done .mk::after{
  content:""; width:5px; height:8px; border:solid #fff; border-width:0 1.6px 1.6px 0;
  transform:rotate(45deg) translate(-1px,-1px);
}
@keyframes pulseDot{ 0%,100%{ transform:scale(1); opacity:1; } 50%{ transform:scale(.55); opacity:.5; } }

/* ---------- 12. Result ---------- */
.result{ padding-bottom:5rem; }
.reveal{
  padding:clamp(2.6rem,1.6rem + 4vw,5rem) 0 clamp(2rem,1.4rem + 3vw,3.6rem);
  border-bottom:1px solid var(--line);
}
.reveal-grid{ display:grid; grid-template-columns:1fr auto; gap:clamp(1.6rem,1rem + 3vw,4rem); align-items:center; }
@media (max-width:760px){ .reveal-grid{ grid-template-columns:1fr; } }
.code{
  font-family:var(--font-display); font-weight:600;
  font-size:clamp(3.2rem,2rem + 7vw,6.4rem); line-height:.94; letter-spacing:-.03em;
  display:flex; gap:.04em;
}
.code span{
  display:inline-block; opacity:0; transform:translateY(26px);
  animation:letterUp .62s var(--e-out) forwards;
}
.code span:nth-child(1){ animation-delay:.05s; color:var(--energy); }
.code span:nth-child(2){ animation-delay:.16s; color:var(--info); }
.code span:nth-child(3){ animation-delay:.27s; color:var(--decide); }
.code span:nth-child(4){ animation-delay:.38s; color:var(--approach); }
@keyframes letterUp{ to{ opacity:1; transform:none; } }
.tname{ font-size:var(--t-h1); margin:.7rem 0 .9rem; }
.tline{ font-size:var(--t-lead); color:var(--ink-2); max-width:46ch; font-style:italic; font-family:var(--font-display); }

/* The glyph: a per type mark built from four quadrants, so each of the
   sixteen reads differently in shape as well as in colour. */
.glyph{ width:clamp(150px,30vw,210px); aspect-ratio:1; }
.glyph rect,.glyph circle,.glyph path{ transition:all var(--d-3) var(--e-out); }

.sect{ padding:clamp(2.2rem,1.4rem + 3vw,3.8rem) 0; border-bottom:1px solid var(--line); }
.sect:last-child{ border-bottom:0; }
.sect-head{ display:flex; align-items:baseline; gap:1rem; margin-bottom:1.8rem; flex-wrap:wrap; }
.sect-head h2{ font-size:var(--t-h2); }
.sect-head .num{
  font-family:var(--font-body); font-size:var(--t-xs); font-weight:700;
  color:var(--ink-4); letter-spacing:.12em;
}
.prose{ max-width:var(--measure); color:var(--ink-2); }
.prose p + p{ margin-top:1rem; }

/* Dimension bars */
.dims{ display:grid; gap:1.7rem; max-width:720px; }
.dim .top{ display:flex; justify-content:space-between; align-items:baseline; gap:1rem; margin-bottom:.6rem; }
.dim .top h3{ font-size:var(--t-h3); font-family:var(--font-body); font-weight:600; }
.dim .top .lean{ font-size:var(--t-sm); color:var(--ink-3); }
.dim .top .lean b{ color:var(--ink); font-weight:600; }
.dim .bar{
  height:34px; border-radius:var(--r); background:var(--sand-2); overflow:hidden;
  display:flex; border:1px solid var(--line); position:relative;
}
.dim .bar i{
  display:flex; align-items:center; padding:0 .8rem; width:0;
  font-size:var(--t-xs); font-weight:600; white-space:nowrap; color:#fff;
  transition:width 1.1s var(--e-out);
}
.dim .bar .a{ background:var(--c); justify-content:flex-start; }
.dim .bar .b{ background:transparent; color:var(--ink-3); justify-content:flex-end; margin-left:auto; }
.dim .foot{ display:flex; justify-content:space-between; font-size:var(--t-xs); color:var(--ink-4); margin-top:.4rem; }

/* Strengths, drawn as arcs rather than yet another bar */
.strengths{ display:grid; grid-template-columns:repeat(auto-fit,minmax(min(100%,164px),1fr)); gap:1.2rem; }
.str{ text-align:center; }
.str svg{ width:88px; height:88px; margin-inline:auto; }
.str .track{ fill:none; stroke:var(--sand-3); stroke-width:6; }
.str .fill{
  fill:none; stroke:var(--brand); stroke-width:6; stroke-linecap:round;
  transform:rotate(-90deg); transform-origin:center;
  stroke-dasharray:var(--circ); stroke-dashoffset:var(--circ);
  transition:stroke-dashoffset 1.3s var(--e-out);
}
.str .pc{ font-family:var(--font-display); font-size:15px; font-weight:600; fill:var(--ink); }
.str h4{ font-size:.92rem; font-weight:600; margin-top:.6rem; font-family:var(--font-body); }
.str p{ font-size:var(--t-xs); color:var(--ink-3); margin-top:.15rem; }

/* Plain lists that still feel designed */
.cards{ display:grid; grid-template-columns:repeat(auto-fit,minmax(min(100%,268px),1fr)); gap:1rem; }
.card{
  background:var(--paper); border:1px solid var(--line); border-radius:var(--r-lg);
  padding:1.3rem 1.4rem; transition:border-color var(--d-2), box-shadow var(--d-2), transform var(--d-2) var(--e-out);
}
.card:hover{ border-color:var(--line-2); box-shadow:var(--sh-2); transform:translateY(-2px); }
.card h4{ font-size:1rem; font-weight:600; margin-bottom:.45rem; font-family:var(--font-body); }
.card p{ font-size:.92rem; color:var(--ink-2); }
.card .ix{
  font-family:var(--font-display); font-size:1.15rem; color:var(--brand);
  display:block; margin-bottom:.6rem;
}

.steps-list{ display:grid; gap:0; max-width:var(--measure); counter-reset:s; }
.steps-list li{
  display:grid; grid-template-columns:auto 1fr; gap:1.1rem; align-items:start;
  padding:1.2rem 0; border-bottom:1px solid var(--line); counter-increment:s;
}
.steps-list li:last-child{ border-bottom:0; }
.steps-list li::before{
  content:counter(s,decimal-leading-zero);
  font-family:var(--font-display); font-size:.95rem; color:var(--brand); font-weight:600; padding-top:.1rem;
}
.steps-list b{ display:block; font-weight:600; margin-bottom:.2rem; }
.steps-list span{ color:var(--ink-2); font-size:.94rem; }

.chiprow{ display:flex; gap:.5rem; flex-wrap:wrap; }
.tag{
  padding:.4rem .85rem; border-radius:var(--r-pill); background:var(--sand-2);
  border:1px solid var(--line); font-size:var(--t-sm); color:var(--ink-2);
}

/* Sticky action bar on the result */
.actions{
  position:sticky; bottom:0; z-index:30; margin-top:2rem;
  background:rgba(251,248,244,.95); backdrop-filter:blur(10px);
  border-top:1px solid var(--line); padding:.9rem 0;
}
.actions .inner{ display:flex; gap:.7rem; align-items:center; flex-wrap:wrap; }
.actions .sp{ margin-left:auto; }
@media (max-width:620px){
  .actions .inner{ gap:.5rem; }
  .actions .btn{ flex:1; justify-content:center; padding:.8rem 1rem; font-size:.88rem; }
  .actions .sp{ margin-left:0; }
}

.disclaim{
  margin-top:2.4rem; padding:1.3rem 1.5rem; border-radius:var(--r-lg);
  background:var(--sand-2); border:1px solid var(--line);
  font-size:var(--t-sm); color:var(--ink-2); max-width:var(--measure);
}
.disclaim h4{ font-size:.9rem; font-weight:700; margin-bottom:.4rem; font-family:var(--font-body); }

/* ---------- 13. Toast ---------- */
.toast{
  position:fixed; left:50%; bottom:1.6rem; translate:-50% 0; z-index:200;
  padding:.85rem 1.3rem; border-radius:var(--r); background:var(--ink); color:var(--sand);
  font-size:.9rem; box-shadow:var(--sh-3); opacity:0; pointer-events:none;
  transform:translateY(10px); transition:opacity var(--d-2), transform var(--d-2) var(--e-out);
}
.toast.on{ opacity:1; transform:none; }

/* ---------- 14. Reduced motion ---------- */
@media (prefers-reduced-motion:reduce){
  *,*::before,*::after{
    animation-duration:.01ms !important; animation-iteration-count:1 !important;
    transition-duration:.01ms !important; scroll-behavior:auto !important;
  }
  .code span{ opacity:1; transform:none; }
  .compass.live .petal{ animation:none; }
}

/* ---------- 15. Print ---------- */
@media print{
  .runbar,.actions,.mast .lang,.btn{ display:none !important; }
  body{ background:#fff; }
  .sect{ break-inside:avoid; }
}

/* ==========================================================================
   Tabbed report
   The whole report still goes into the download. This is about how much a
   student is asked to read in one sitting.
   ========================================================================== */
.rtabs{ margin-top:2.2rem; }
.rtabs-strip{
  display:flex; gap:.4rem; overflow-x:auto; padding:.3rem .1rem 1.4rem;
  scrollbar-width:none; scroll-snap-type:x proximity;
}
.rtabs-strip::-webkit-scrollbar{ height:0; }
.rtab{
  flex:0 0 auto; scroll-snap-align:center; display:inline-flex; align-items:center; gap:.5rem;
  padding:.6rem 1.05rem; border-radius:999px; font-size:.92rem; font-weight:600;
  color:var(--ink-3); background:var(--paper); border:1px solid var(--line);
  cursor:pointer; white-space:nowrap;
  transition:color .24s, background .24s, border-color .24s, transform .24s cubic-bezier(.2,.7,.3,1);
}
.rtab:hover{ border-color:var(--line-2); transform:translateY(-1px); }
.rtab .n{
  font-family:var(--font-mono,monospace); font-size:.68rem; letter-spacing:.06em; opacity:.55;
}
.rtab.on{
  color:#fff; background:var(--ink); border-color:var(--ink);
  box-shadow:0 10px 22px -12px rgba(24,22,20,.5);
}
.rtab.on .n{ opacity:.7; }

.rpanel{ display:none; }
.rpanel.on{ display:block; animation:rpanelIn .42s cubic-bezier(.2,.7,.3,1) both; }
@keyframes rpanelIn{
  from{ opacity:0; transform:translateY(12px); }
  to{ opacity:1; transform:none; }
}
/* Children arrive just behind the panel, so a six card grid does not land
   as one slab. */
.rpanel.on > .cards > *,
.rpanel.on > .strengths > *,
.rpanel.on > .steps-list > *{ animation:rpanelIn .46s cubic-bezier(.2,.7,.3,1) both; }
.rpanel.on > * > *:nth-child(1){ animation-delay:.04s; }
.rpanel.on > * > *:nth-child(2){ animation-delay:.09s; }
.rpanel.on > * > *:nth-child(3){ animation-delay:.14s; }
.rpanel.on > * > *:nth-child(4){ animation-delay:.19s; }
.rpanel.on > * > *:nth-child(5){ animation-delay:.24s; }
.rpanel.on > * > *:nth-child(6){ animation-delay:.29s; }
.rpanel.on > * > *:nth-child(7){ animation-delay:.34s; }

@media (max-width:640px){
  .rtab{ padding:.52rem .85rem; font-size:.86rem; }
}
@media (prefers-reduced-motion:reduce){
  .rpanel.on,.rpanel.on > * > *{ animation:none; }
  .rtab:hover{ transform:none; }
}

/* Standing credit for the pages that carry no full footer. */
.eiq-credit{
  display:flex; justify-content:center; gap:1.4rem; flex-wrap:wrap;
  padding:2rem 1.2rem 2.6rem; font-size:.82rem; color:var(--ink-4,#9AA0A8);
  border-top:1px solid var(--line,#E5E4DE);
}
.eiq-credit a{ color:var(--ink-3,#6E757F); border-bottom:1px solid var(--line-2,#D3D1C9); }
.eiq-credit a:hover{ color:var(--brand-deep,#C4551C); }
