/* PiCiviQ — Free Preparation Check (/preparation-check/): intro, onboarding, before you begin,
   results (main card, tabs or guest gate, next steps).
   The question card, confidence row and report blocks come from quiz.css + quiz-report.css. */
.dg-sec{padding-block:40px 72px}
.dg-wrap{max-width:820px}
.dg-stage[hidden],.dg-intro[hidden],.dg-resume[hidden]{display:none}
.dg-wrap .ic{display:inline-grid;place-items:center;flex:none}
.dg-wrap .ic svg{width:100%;height:100%}

/* ---------- intro ---------- */
.dg-intro{text-align:center;padding-top:8px}
.dg-intro h1{font-size:clamp(30px,4.8vw,48px);font-weight:800;letter-spacing:-.025em;line-height:1.15;margin-top:16px;text-wrap:balance}
.dg-lede{color:var(--muted);font-size:17px;line-height:1.6;max-width:52ch;margin:14px auto 0}
.pc-facts{list-style:none;padding:0;margin:30px auto 0;max-width:680px;display:grid;grid-template-columns:repeat(4,minmax(0,1fr));background:var(--surface);border:1px solid var(--border);border-radius:20px;box-shadow:var(--shadow)}
.pc-facts li{display:flex;flex-direction:column;align-items:center;gap:2px;padding:18px 8px}
.pc-facts li+li{border-left:1px solid var(--border)}
.pf-ic{width:36px;height:36px;border-radius:11px;display:grid;place-items:center;background:var(--grad-soft);color:var(--purple);margin-bottom:6px}
.pf-ic svg{width:19px;height:19px}
.pc-facts b{font-size:28px;font-weight:800;letter-spacing:-.02em;line-height:1.1;font-variant-numeric:tabular-nums}
.pc-facts span:last-child{font-size:12.5px;font-weight:700;color:var(--muted);text-transform:uppercase;letter-spacing:.05em}
.dg-cta{display:flex;flex-direction:column;align-items:center;gap:12px;margin-top:26px}
.dg-cta .btn{font-size:17px;padding:17px 30px}
.dg-cta .btn svg{width:18px;height:18px}
.dg-quick{display:inline-flex;align-items:center;gap:8px;font:inherit;font-size:14.5px;color:var(--text);background:var(--surface);border:1px dashed color-mix(in srgb,var(--purple) 45%,var(--border));border-radius:999px;padding:9px 16px;cursor:pointer}
.dg-quick:hover{border-style:solid;border-color:var(--purple)}
.dg-quick svg{width:17px;height:17px;color:var(--purple);flex:none}
.dg-quickres{display:flex;align-items:center;justify-content:space-between;gap:12px;flex-wrap:wrap;background:var(--grad-soft);border:1px solid color-mix(in srgb,var(--purple) 22%,var(--border));border-radius:16px;padding:14px 16px;font-size:14.5px;line-height:1.5}
.dg-quickres p{margin:0;flex:1 1 320px}
.dg-note{display:inline-flex;align-items:center;gap:6px;font-size:13px;color:var(--muted)}
.dg-note svg{width:14px;height:14px;flex:none}
.dg-empty{margin-top:28px;color:var(--muted);background:var(--surface);border:1px solid var(--border);border-radius:16px;padding:18px}
.dg-resume{margin:22px auto 0;max-width:520px;background:var(--grad-soft);border:1px solid var(--border);border-radius:16px;padding:16px 18px}
.dg-resume p{font-size:14.5px}
.dg-resume .dg-nav{justify-content:center;margin-top:12px}
.pc-gets-h{font-size:13px;font-weight:800;letter-spacing:.08em;text-transform:uppercase;color:var(--muted);margin-top:46px}
.pc-gets{list-style:none;padding:0;margin:14px 0 0;display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:14px;text-align:left}
.pc-gets li{background:var(--surface);border:1px solid var(--border);border-radius:18px;padding:20px;display:flex;flex-direction:column;gap:6px}
.pg-ic{width:44px;height:44px;border-radius:13px;display:grid;place-items:center;background:var(--grad);color:#fff;margin-bottom:6px;box-shadow:0 10px 22px -12px rgba(108,65,246,.7)}
.pg-ic svg{width:22px;height:22px}
.pc-gets b{font-size:16px;font-weight:800}
.pc-gets span:last-child{font-size:14px;color:var(--muted);line-height:1.5}

/* ---------- cards + onboarding ---------- */
.dg-card{background:var(--surface);border:1px solid var(--border);border-radius:22px;box-shadow:var(--shadow-lg);padding:32px 30px;animation:pq-rise .35s cubic-bezier(.2,.7,.2,1) both}
.dg-card h2{font-size:clamp(22px,2.8vw,27px);font-weight:800;letter-spacing:-.015em;line-height:1.3}
.dg-card h2:focus{outline:none}
.dg-steps{display:flex;gap:6px;margin-bottom:14px}
.dg-steps i{flex:1;height:5px;border-radius:99px;background:var(--surface-2)}
.dg-steps i.done{background:color-mix(in srgb,var(--purple) 45%,var(--surface-2))}
.dg-steps i.on{background:var(--grad)}
.dg-stepn{font-size:12.5px;font-weight:700;letter-spacing:.04em;text-transform:uppercase;color:var(--muted);margin-bottom:6px}
.dg-why{display:flex;align-items:flex-start;gap:8px;margin-top:10px;font-size:14px;line-height:1.5;color:var(--muted);background:var(--surface-2);border-radius:12px;padding:10px 12px}
.dg-why .ic{width:17px;height:17px;color:var(--purple);margin-top:1px}
.dg-why b{color:var(--text);font-weight:700}
.dg-hint{color:var(--muted);font-size:14px;line-height:1.55;margin-top:6px}
.dg-form{margin-top:18px}
.dg-choices{display:grid;grid-template-columns:1fr 1fr;gap:10px}
.dg-choice{position:relative;display:flex;cursor:pointer}
.dg-choice input{position:absolute;opacity:0;inset:0;margin:0;cursor:pointer}
/* The radio dot keeps one size when checked (border-box + inset ring), so nothing shifts. */
.dg-choice span{flex:1;display:flex;align-items:center;gap:12px;border:1.5px solid var(--border);background:var(--surface);border-radius:14px;padding:15px 16px;font-weight:700;font-size:15px;transition:border-color .15s,background-color .15s}
.dg-choice span::before{content:"";box-sizing:border-box;flex:none;width:20px;height:20px;border-radius:50%;border:2px solid var(--border-strong);background:var(--surface);transition:border-color .15s,box-shadow .15s}
.dg-choice:hover span{border-color:var(--border-strong)}
.dg-choice input:checked+span{border-color:var(--purple);background:color-mix(in srgb,var(--purple) 8%,var(--surface))}
.dg-choice input:checked+span::before{border-color:var(--purple);box-shadow:inset 0 0 0 4px var(--surface),inset 0 0 0 10px var(--purple)}
.dg-choice input:focus-visible+span{outline:3px solid var(--purple);outline-offset:2px}
.dg-fields{display:grid;gap:16px}
.dg-field span{display:block;font-size:14px;font-weight:700;margin-bottom:6px}
.dg-field small{font-weight:600;color:var(--muted)}
.dg-field input,.dg-field select{width:100%;font:inherit;font-size:15px;color:var(--text);background:var(--surface);border:1.5px solid var(--border);border-radius:12px;padding:12px 14px}
.dg-field select{appearance:none;-webkit-appearance:none;cursor:pointer;padding-right:40px;background:var(--surface) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%2359637F' stroke-width='2.4' stroke-linecap='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E") no-repeat right 14px center/15px}
.dg-field input:focus,.dg-field select:focus{border-color:var(--purple);outline:none;box-shadow:0 0 0 3px color-mix(in srgb,var(--purple) 20%,transparent)}
.dg-nav{display:flex;flex-wrap:wrap;align-items:center;gap:10px;margin-top:24px}
.dg-nav-r{margin-left:auto;display:flex;align-items:center;gap:6px}
.dg-nav .btn svg{width:16px;height:16px}
.dg-skip{background:none;border:0;font:inherit;font-size:15px;font-weight:700;color:var(--muted);cursor:pointer;padding:12px 14px;border-radius:12px}
.dg-skip:hover{color:var(--text);background:var(--surface-2)}

/* ---------- before you begin ---------- */
.ins-head{text-align:center}
.dg-prof{display:flex;flex-wrap:wrap;align-items:center;justify-content:center;gap:6px;margin-top:14px}
.dg-chip{font-size:12.5px;font-weight:700;background:var(--surface-2);color:var(--text);border-radius:999px;padding:5px 11px}
.dg-edit{display:inline-flex;align-items:center;gap:5px;background:none;border:0;font:inherit;font-size:13px;font-weight:700;color:var(--purple);cursor:pointer;padding:5px 6px}
.dg-edit .ic{width:14px;height:14px}
.ins-facts{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));margin-top:22px;background:var(--grad);border-radius:18px;color:#fff;box-shadow:0 16px 34px -18px rgba(108,65,246,.8)}
.ins-facts div{display:flex;flex-direction:column;align-items:center;padding:16px 6px}
.ins-facts div+div{border-left:1px solid rgba(255,255,255,.25)}
.ins-facts b{font-size:30px;font-weight:800;line-height:1.1;font-variant-numeric:tabular-nums}
.ins-facts span{font-size:12.5px;font-weight:700;text-transform:uppercase;letter-spacing:.05em;opacity:.9}
.ins-rules{list-style:none;margin:22px 0 0;padding:0;display:grid;grid-template-columns:1fr 1fr;gap:12px}
.ins-rules li{display:flex;gap:12px;align-items:flex-start;background:var(--surface-2);border-radius:14px;padding:14px}
.ins-rules .ic{width:36px;height:36px;border-radius:11px;background:var(--surface);color:var(--purple);padding:8px;box-shadow:var(--shadow)}
.ins-rules b{display:block;font-size:14.5px;font-weight:800}
.ins-rules li>span>span{display:block;font-size:13px;color:var(--muted);line-height:1.5;margin-top:2px}
.dg-langnote{display:flex;gap:8px;align-items:center;margin-top:14px;font-size:13.5px;background:var(--amber-bg);border-radius:12px;padding:10px 12px}
.dg-langnote .ic{width:16px;height:16px;color:#7A5300}
.dg-rec{margin-top:16px;border:1px solid var(--border);border-radius:14px;padding:4px 14px}
.dg-rec summary{display:flex;align-items:center;gap:8px;cursor:pointer;font-size:14px;font-weight:700;padding:10px 0;list-style:none}
.dg-rec summary::-webkit-details-marker{display:none}
.dg-rec summary::after{content:"+";margin-left:auto;font-size:18px;color:var(--muted)}
.dg-rec[open] summary::after{content:"−"}
.dg-rec summary .ic{width:16px;height:16px;color:var(--purple)}
.dg-rec p{font-size:13.5px;color:var(--muted);line-height:1.55;padding-bottom:12px}
.dg-rec a{color:var(--purple);font-weight:700}
.dg-limit{font-size:13px;color:var(--muted);margin-top:14px;text-align:center}

/* ---------- waiting ---------- */
.dg-wait{text-align:center;padding-block:48px}
.dg-spin{display:inline-block;width:34px;height:34px;border-radius:50%;border:3px solid var(--surface-2);border-top-color:var(--purple);animation:dg-spin .8s linear infinite;margin-bottom:14px}
@keyframes dg-spin{to{transform:rotate(360deg)}}

/* ---------- results ---------- */
.dg-res>*+*{margin-top:16px}
.dg-demo{background:var(--amber-bg);color:var(--text);border-radius:14px;padding:12px 16px;font-size:13.5px;line-height:1.5}
.dg-demo b{display:inline-block;background:#7A5300;color:#fff;border-radius:6px;padding:1px 7px;margin-right:6px;font-size:11.5px;letter-spacing:.06em}
.dg-prof-r{margin-top:0}
.dg-res .quiz-res .cm{text-align:left;margin-top:22px}

/* tabs (students) */
.res-tabs.quiz-card{padding:0;overflow:hidden;text-align:left}
.rt-list{display:flex;gap:4px;overflow-x:auto;padding:10px 10px 0;border-bottom:1px solid var(--border);background:var(--surface-2);scrollbar-width:none}
.rt-list::-webkit-scrollbar{display:none}
.rt{display:inline-flex;align-items:center;gap:8px;flex:none;font:inherit;font-size:14px;font-weight:700;color:var(--muted);background:none;border:1px solid transparent;border-bottom:0;border-radius:12px 12px 0 0;padding:12px 16px;cursor:pointer;white-space:nowrap}
.rt .ic{width:17px;height:17px}
.rt:hover{color:var(--text)}
.rt[aria-selected="true"]{background:var(--surface);color:var(--purple);border-color:var(--border);margin-bottom:-1px;padding-bottom:13px}
.rp{padding:24px}
.rp:focus-visible{outline:2px solid var(--purple);outline-offset:-4px}
.rp>.dg-hint:first-child{margin-top:0}
.rp .ans-rev{margin-top:0}
.rp .ans-rev h3{display:none}

/* guest gate */
.res-next h3{display:flex;align-items:center;gap:10px;font-size:19px;font-weight:800;margin-bottom:14px}
.res-next h3 .ic{width:20px;height:20px;color:var(--purple)}
.rn-more{font-size:13.5px;font-weight:700;color:var(--muted);margin-top:12px}
.rg-pv{padding:20px 24px 0}
.res-gate{position:relative;padding:0;overflow:hidden;height:440px}
.res-gate.quiz-card{padding:0}
.rg-blur{filter:blur(6px) saturate(.8);opacity:.6;pointer-events:none;user-select:none;padding-bottom:24px}
.rg-blur .rx-list,.rg-blur .cm{margin:20px 24px 0}
.rg-cta{position:absolute;inset:0;display:flex;flex-direction:column;align-items:center;justify-content:flex-start;gap:8px;padding:64px 24px 24px;text-align:center;background:linear-gradient(180deg,color-mix(in srgb,var(--surface) 35%,transparent),color-mix(in srgb,var(--surface) 88%,transparent) 45%)}
.rg-ic{width:54px;height:54px;border-radius:16px;background:var(--grad);color:#fff;display:grid;place-items:center;box-shadow:0 12px 26px -10px rgba(108,65,246,.8)}
.rg-ic .ic{width:24px;height:24px}
.rg-cta h3{font-size:22px;font-weight:800;margin-top:6px}
.rg-cta p{font-size:14.5px;color:var(--muted);max-width:460px;line-height:1.55;margin:0}
.rg-cta .rl-btns{margin-top:10px}
.rg-cta .rg-note{font-size:12.5px;margin-top:6px}

/* next steps */
.res-acts{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:12px}
.ra-card{display:flex;align-items:center;gap:12px;text-align:left;font:inherit;color:var(--text);background:var(--surface);border:1px solid var(--border);border-radius:18px;padding:16px;box-shadow:var(--shadow);cursor:pointer;transition:border-color .15s,box-shadow .2s}
.ra-card:hover{border-color:var(--purple);box-shadow:var(--shadow-lg)}
.ra-card>.ic{width:42px;height:42px;border-radius:12px;background:var(--grad-soft);color:var(--purple);padding:10px}
.ra-card>span{flex:1;min-width:0}
.ra-card b{display:block;font-size:15px;font-weight:800}
.ra-card>span>span{display:block;font-size:12.5px;color:var(--muted);line-height:1.4;margin-top:2px}
.ra-card>svg{flex:none;color:var(--muted)}
.ra-main{background:var(--grad);border-color:transparent;color:#fff}
.ra-main>.ic{background:rgba(255,255,255,.18);color:#fff}
.ra-main>span>span,.ra-main>svg{color:rgba(255,255,255,.85)}

/* prescription, traps, areas, speed (inside tabs) */
.rx-list{list-style:none;margin:0;padding:0;display:grid;gap:12px}
.rx{display:flex;gap:14px;background:var(--surface-2);border-radius:16px;padding:16px}
.rx-n{flex:none;width:30px;height:30px;border-radius:50%;background:var(--grad);color:#fff;display:grid;place-items:center;font-weight:800;font-size:14px}
.rx-b{min-width:0;flex:1}
.rx h4{font-size:16px;font-weight:800;line-height:1.35}
.rx-what{font-size:14.5px;margin-top:4px;line-height:1.55}
.rx-dl{margin:10px 0 0;display:grid;gap:6px}
.rx-dl div{display:grid;grid-template-columns:118px 1fr;gap:8px;font-size:13.5px;line-height:1.5}
.rx-dl dt{font-weight:700;color:var(--muted)}
.rx-dl dd{margin:0}
.rx-go{margin-top:12px}
.rx-go svg{width:15px;height:15px}
.rx-overconfidence{box-shadow:inset 3px 0 0 var(--amber)}
.rx-weak_area{box-shadow:inset 3px 0 0 var(--trap)}
.tr-list,.ar-list,.sp-list{list-style:none;margin:12px 0 0;padding:0;display:grid;gap:10px}
.tr,.ar{background:var(--surface-2);border-radius:14px;padding:12px 14px}
.tr-h,.ar-h{display:flex;justify-content:space-between;gap:10px;font-size:14.5px}
.tr-h span,.ar-h span{color:var(--muted);font-weight:700;font-size:13px;white-space:nowrap}
.ar-h a{color:var(--purple);font-weight:800}
.tr-bar,.ar-bar{display:flex;height:7px;border-radius:99px;background:var(--surface);overflow:hidden;margin-top:8px}
.tr-bar i{background:var(--trap);border-radius:99px}
.ar-bar i.ok{background:var(--good)}.ar-bar i.no{background:var(--trap)}.ar-bar i.sk{background:var(--border-strong)}
.tr-tip{font-size:13.5px;margin-top:8px;line-height:1.5}
.tr-qs,.ar-path,.ar-n{font-size:12.5px;color:var(--muted);margin-top:6px;line-height:1.5}
.sp{border-left:3px solid var(--border-strong);background:var(--surface-2);border-radius:0 12px 12px 0;padding:9px 12px;font-size:13.5px;line-height:1.5}
.sp b{display:block}
.sp span{color:var(--muted)}
.sp-slow_accurate{border-color:var(--sky)}.sp-hasty{border-color:var(--amber)}
.rp .rep-stats{margin-top:12px}
.rp .rep-stats:first-child{margin-top:0}

@media (max-width:760px){
  .pc-facts{grid-template-columns:repeat(2,minmax(0,1fr))}
  .pc-facts li:nth-child(3){border-left:0}
  .pc-facts li:nth-child(n+3){border-top:1px solid var(--border)}
  .pc-gets{grid-template-columns:1fr}
  .dg-card{padding:24px 18px}
  .dg-choices{grid-template-columns:1fr}
  .ins-rules{grid-template-columns:1fr}
  .res-acts{grid-template-columns:1fr}
  .rp{padding:18px 16px}
  .rx{padding:14px 12px;gap:10px}
  .rx-dl div{grid-template-columns:1fr;gap:0}
  .res-gate{height:450px}
  .rg-cta{padding-top:40px}
}
@media (max-width:420px){
  .ins-facts b{font-size:24px}
  .dg-nav .btn{padding-inline:16px}
}
@media (prefers-reduced-motion:reduce){
  .dg-card{animation:none}
  .dg-spin{animation-duration:2s}
}
