:root{
  --blue:#244f9e;
  --blue-dark:#173b80;
  --cyan:#27b9d8;
  --soft:#eef6ff;
  --ink:#14213d;
  --muted:#6b7280;
  --card:#ffffff;
  --line:#dbe7f7;
  --shadow:0 20px 45px rgba(25, 65, 130, .16);
}
*{box-sizing:border-box}
body{
  margin:0;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color:var(--ink);
  background:
    radial-gradient(circle at top right, rgba(39,185,216,.18), transparent 32%),
    radial-gradient(circle at bottom left, rgba(36,79,158,.16), transparent 32%),
    linear-gradient(180deg,#f8fbff 0%, #eef6ff 100%);
  min-height:100vh;
}
.app-shell{
  width:min(100%, 560px);
  margin:0 auto;
  padding:18px 16px 34px;
}
.topbar{
  display:flex;
  align-items:center;
  gap:12px;
  padding:10px 4px 18px;
}
.brand-mark{
  width:44px;
  height:44px;
  object-fit:contain;
}
.eyebrow{
  margin:0;
  font-size:12px;
  letter-spacing:.12em;
  font-weight:800;
  text-transform:uppercase;
  color:var(--cyan);
}
h1{font-size:22px;margin:2px 0 0;color:var(--blue)}
h2{font-size:26px;line-height:1.15;margin:0 0 12px}
h3{font-size:19px;margin:0 0 8px}
p{line-height:1.55}
.screen{display:none}
.screen.active{display:block;animation:fadeIn .25s ease}
@keyframes fadeIn{from{opacity:0;transform:translateY(8px)}to{opacity:1;transform:translateY(0)}}
.hero-card{
  color:white;
  background:linear-gradient(135deg,var(--blue) 0%, var(--blue-dark) 65%, #0c2d68 100%);
  border-radius:32px;
  padding:28px 22px 20px;
  box-shadow:var(--shadow);
  overflow:hidden;
  position:relative;
}
.hero-card:before{
  content:"";
  position:absolute;
  width:240px;height:240px;
  border-radius:50%;
  background:rgba(39,185,216,.18);
  right:-95px;top:-80px;
}
.hero-logo{
  max-width:210px;
  width:55%;
  min-height:42px;
  object-fit:contain;
  margin-bottom:18px;
  position:relative;
  z-index:1;
}
.pill{
  display:inline-flex;
  width:max-content;
  max-width:100%;
  padding:8px 12px;
  border-radius:999px;
  background:rgba(255,255,255,.13);
  border:1px solid rgba(255,255,255,.2);
  font-size:12px;
  font-weight:700;
}
.hero-copy{color:rgba(255,255,255,.88);font-size:15px}
.info-grid{
  display:grid;
  grid-template-columns:repeat(3,1fr);
  gap:10px;
  margin:20px 0;
}
.info-grid div{
  background:rgba(255,255,255,.12);
  border:1px solid rgba(255,255,255,.16);
  border-radius:18px;
  padding:12px 8px;
}
.info-grid b{display:block;font-size:17px}
.info-grid span{display:block;font-size:11px;color:rgba(255,255,255,.74)}
.card,.result-card{
  background:rgba(255,255,255,.88);
  backdrop-filter:blur(10px);
  border:1px solid rgba(255,255,255,.8);
  border-radius:28px;
  padding:22px;
  box-shadow:var(--shadow);
}
.muted{color:var(--muted)}
.disclaimer{font-size:12px;color:rgba(255,255,255,.72);margin-bottom:0}
label{display:block;font-weight:800;margin:16px 0 6px}
input{
  width:100%;
  min-height:54px;
  border:1.5px solid var(--line);
  border-radius:18px;
  padding:0 15px;
  font:inherit;
  outline:none;
  background:white;
}
input:focus{border-color:var(--cyan);box-shadow:0 0 0 4px rgba(39,185,216,.13)}
button,.wa-btn{
  border:none;
  border-radius:18px;
  min-height:54px;
  padding:0 18px;
  font-weight:900;
  font-size:15px;
  cursor:pointer;
  text-decoration:none;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  width:100%;
}
.primary-btn{
  color:white;
  background:linear-gradient(135deg,var(--cyan),#008bd2 45%,var(--blue));
  box-shadow:0 12px 24px rgba(36,79,158,.22);
}
.primary-btn:disabled{opacity:.45;cursor:not-allowed;box-shadow:none}
.ghost-btn{
  color:var(--blue);
  background:white;
  border:1.5px solid var(--line);
}
.wa-btn{
  margin-top:10px;
  color:white;
  background:#10b981;
}
.quiz-header{margin-bottom:14px}
.progress{
  height:10px;
  background:#d8e8fa;
  border-radius:99px;
  overflow:hidden;
  margin-top:8px;
}
.progress span{
  display:block;
  height:100%;
  width:0%;
  background:linear-gradient(90deg,var(--cyan),var(--blue));
  border-radius:99px;
  transition:.25s ease;
}
.quiz-card h2{font-size:23px}
.options{display:grid;gap:12px;margin-top:18px}
.option-btn{
  width:100%;
  text-align:left;
  border:1.5px solid var(--line);
  border-radius:20px;
  background:white;
  padding:16px;
  font-weight:700;
  line-height:1.4;
  color:var(--ink);
  display:block;
  min-height:auto;
}
.option-btn.selected{
  border-color:var(--cyan);
  background:#e9faff;
  box-shadow:0 0 0 4px rgba(39,185,216,.12);
}
.nav-row{
  display:grid;
  grid-template-columns:1fr 1.3fr;
  gap:12px;
  margin-top:16px;
}
.center{text-align:center;padding:42px 24px}
.loader{
  width:72px;height:72px;border-radius:50%;
  border:7px solid #d8e8fa;
  border-top-color:var(--cyan);
  margin:0 auto 20px;
  animation:spin 1s linear infinite;
}
@keyframes spin{to{transform:rotate(360deg)}}
.result-card{padding:18px}
.result-top{display:flex;gap:12px;align-items:center;margin-bottom:14px}
.result-summary{font-weight:650;color:#334155}
.top-results{display:grid;gap:12px;margin:18px 0}
.rank-card{
  background:white;
  border:1.5px solid var(--line);
  border-radius:22px;
  padding:16px;
  display:grid;
  gap:8px;
}
.rank-head{display:flex;justify-content:space-between;gap:12px;align-items:center}
.rank-title{font-weight:950;font-size:18px}
.percent{
  color:white;
  background:var(--blue);
  border-radius:999px;
  padding:6px 10px;
  font-weight:950;
  font-size:13px;
}
.meter{height:10px;background:#e8eff8;border-radius:999px;overflow:hidden}
.meter span{height:100%;display:block;background:linear-gradient(90deg,var(--cyan),var(--blue))}
.result-desc{margin:0;color:var(--muted);font-size:14px}
.promo-box{
  background:linear-gradient(180deg,#f3faff,#ffffff);
  border:1.5px solid var(--line);
  border-radius:24px;
  padding:16px;
  margin-top:16px;
}
.promo-box p{font-size:14px;color:#475569;margin:8px 0}
.share-actions{display:grid;gap:10px;margin-top:14px}
#story-canvas{display:none}
@media (max-width:380px){
  .app-shell{padding:12px 12px 28px}
  h2{font-size:23px}
  .info-grid{grid-template-columns:1fr}
}
