:root{
  --green:#10b981; --green-deep:#0b8f6a; --blue:#2563eb;
  --ink:#0d2b3e; --ink2:#4a6b80; --ink3:#87a1b3; --line:#d9e7ee; --red:#e5484d;
}
*{ box-sizing:border-box; -webkit-tap-highlight-color:transparent; }
html,body{ margin:0; min-height:100%; }
body{
  font-family:-apple-system,BlinkMacSystemFont,"PingFang SC","Hiragino Sans GB",system-ui,sans-serif;
  color:var(--ink); -webkit-font-smoothing:antialiased;
  background:
    radial-gradient(900px 600px at 12% 0%, #d9f5e8 0%, transparent 60%),
    radial-gradient(800px 600px at 95% 8%, #dbe9ff 0%, transparent 62%),
    linear-gradient(180deg,#f6fbf9,#eef4fb);
}
.app{ min-height:100dvh; display:flex; align-items:center; justify-content:center;
      padding:max(24px,env(safe-area-inset-top)) 20px max(24px,env(safe-area-inset-bottom)); }
.screen{ display:none; width:100%; max-width:420px; flex-direction:column; gap:12px; }
.screen.on{ display:flex; }

.brand{ display:flex; align-items:center; gap:8px; justify-content:center; font-size:13px; color:var(--ink2); }
.brand .logo{ font-size:20px; }
h1{ margin:6px 0 0; font-size:26px; line-height:1.35; letter-spacing:-.5px; text-align:center; }
.lead{ margin:0 0 8px; text-align:center; color:var(--ink2); font-size:13.5px; line-height:1.7; }

.field{ display:flex; flex-direction:column; gap:6px; }
.field label{ font-size:12.5px; color:var(--ink2); font-weight:600; }
.field input{
  width:100%; padding:14px 15px; font-size:16px; color:var(--ink);
  background:#fff; border:1.5px solid var(--line); border-radius:13px; outline:none;
}
.field input:focus{ border-color:var(--green); box-shadow:0 0 0 4px rgba(16,185,129,.12); }
.field input::placeholder{ color:#a9bcc9; }
.field input.plain{ letter-spacing:2px; font-size:18px; }

.btn{
  border:0; cursor:pointer; width:100%; padding:15px 18px; margin-top:6px;
  font-size:16.5px; font-weight:700; color:#fff; border-radius:14px;
  background:linear-gradient(100deg,var(--green),#0ea5a3 55%,var(--blue));
  box-shadow:0 16px 30px -18px rgba(16,185,129,.7);
}
.btn:active{ transform:scale(.99); }
.btn:disabled{ opacity:.6; }
.btn.ghost{ background:#fff; color:var(--ink); border:1.5px solid var(--line); box-shadow:none; font-size:15px; }

.links{ display:flex; justify-content:space-between; margin-top:6px; }
.link{ border:0; background:none; color:var(--green-deep); font-size:13.5px; cursor:pointer; padding:6px 0; }
.link.center{ align-self:center; }
.err{ min-height:18px; margin:0; font-size:12.5px; color:var(--red); }
.hint{ margin:0; font-size:12px; color:var(--ink3); line-height:1.6; }
.hint.center{ text-align:center; }

.steps{ display:flex; gap:6px; justify-content:center; margin-bottom:4px; }
.steps i{ width:26px; height:4px; border-radius:2px; background:#dbe7ee; }
.steps i.on{ background:var(--green); }

.grade{ display:flex; gap:8px; }
.grade button{
  flex:1; padding:14px 0; font-size:15px; font-weight:600; color:var(--ink2);
  background:#fff; border:1.5px solid var(--line); border-radius:13px; cursor:pointer;
}
.grade button.on{ border-color:var(--green); color:var(--green-deep); background:#f0fbf6; }

.card{ background:#fff; border:1px solid var(--line); border-radius:18px; padding:18px;
       box-shadow:0 18px 40px -32px rgba(13,43,62,.5); display:flex; flex-direction:column; gap:10px; }
.row{ display:flex; justify-content:space-between; font-size:14px; color:var(--ink2); }
.row b{ color:var(--ink); }
.hello{ display:flex; justify-content:space-between; align-items:flex-start; }
.hello h1{ text-align:left; font-size:24px; }
.hello .sub{ margin:0; font-size:12.5px; color:var(--ink3); }

.hide{ display:none !important; }
.toast{ position:fixed; left:50%; bottom:32px; transform:translateX(-50%) translateY(12px);
  background:rgba(13,43,62,.92); color:#fff; font-size:13.5px; padding:10px 18px; border-radius:12px;
  opacity:0; pointer-events:none; transition:all .22s; max-width:86vw; text-align:center; }
.toast.show{ opacity:1; transform:translateX(-50%) translateY(0); }

/* ===== 答题 ===== */
.qtop{ display:flex; justify-content:space-between; align-items:center; font-size:13px; color:var(--ink3); }
.bar{ height:4px; background:#e4eef4; border-radius:2px; overflow:hidden; }
.bar i{ display:block; height:100%; width:0; background:var(--green); transition:width .2s; }
.qstem{ margin:18px 0 8px; font-size:22px; font-weight:700; line-height:1.5; text-align:center; }
.opts{ display:flex; flex-direction:column; gap:10px; margin-top:8px; }
.opt{ display:flex; align-items:center; gap:12px; width:100%; padding:15px 16px; text-align:left;
  background:#fff; border:1.5px solid var(--line); border-radius:14px; font-size:17px; color:var(--ink); cursor:pointer; }
.opt .k{ flex:0 0 26px; height:26px; border-radius:50%; background:#eef4f8; color:var(--ink2);
  font-size:13px; font-weight:700; display:flex; align-items:center; justify-content:center; }
.opt.on{ border-color:var(--green); background:#f2fbf7; }
.opt.on .k{ background:var(--green); color:#fff; }

/* ===== 结果 ===== */
.result-head{ text-align:center; margin:8px 0 4px; }
.score{ font-size:52px; font-weight:800; letter-spacing:-2px; }
.rlist{ display:flex; flex-direction:column; gap:8px; max-height:52vh; overflow:auto; padding-right:2px; }
.ritem{ background:#fff; border:1px solid var(--line); border-radius:12px; padding:12px 14px; font-size:14px; }
.ritem.ok{ border-color:#cfeee0; background:#f6fcf9; }
.ritem.bad{ border-color:#f6d6d6; background:#fffafa; }
.ritem .rs{ font-weight:600; margin-bottom:4px; }
.ritem .ra{ font-size:13px; color:var(--ink2); }
.ritem .re{ font-size:12.5px; color:var(--ink3); margin-top:4px; line-height:1.6; }
