/* =========================================================
   青云模考 · 离线全真模拟
   Design tokens
   ========================================================= */
:root {
  --paper: #f4f1e8;
  --paper-deep: #ebe5d7;
  --card: #fffdf8;
  --card-soft: #faf7ef;
  --ink: #17231f;
  --ink-soft: #33443d;
  --muted: #6d7a73;
  --muted-2: #99a39d;
  --line: #ded9cb;
  --line-strong: #cbc4b2;
  --green: #0f5c4d;
  --green-2: #1a7562;
  --green-3: #2e8f78;
  --mint: #e3efe9;
  --mint-2: #d3e6dd;
  --clay: #bf6242;
  --clay-soft: #f5e5dd;
  --gold: #ad874b;
  --gold-soft: #f2e9d6;
  --red: #a83b32;
  --red-soft: #f6e2df;
  --blue: #315f7d;
  --shadow-sm: 0 1px 2px rgba(23, 35, 31, .05), 0 4px 14px rgba(23, 35, 31, .04);
  --shadow-md: 0 2px 6px rgba(23, 35, 31, .05), 0 16px 40px rgba(23, 35, 31, .08);
  --shadow-lg: 0 30px 80px rgba(23, 35, 31, .15);
  --radius-sm: 9px;
  --radius: 16px;
  --radius-lg: 24px;
  --sans: "Noto Sans SC", "Source Han Sans SC", "PingFang SC", "Microsoft YaHei", "Segoe UI", sans-serif;
  --serif: "Noto Serif SC", "Source Han Serif SC", "Songti SC", "SimSun", Georgia, serif;
  --mono: "JetBrains Mono", "Cascadia Code", Consolas, monospace;
  --header-h: 74px;
  --ease: cubic-bezier(.22, .8, .32, 1);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  min-height: 100vh;
  color: var(--ink);
  font-family: var(--sans);
  font-size: 15px;
  line-height: 1.65;
  background:
    radial-gradient(circle at 8% -5%, rgba(15, 92, 77, .09), transparent 32rem),
    radial-gradient(circle at 92% 4%, rgba(191, 98, 66, .07), transparent 28rem),
    linear-gradient(180deg, #f7f4ec 0%, var(--paper) 45%, #f1ede2 100%);
  background-attachment: fixed;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  opacity: .5;
  background-image:
    linear-gradient(rgba(23, 35, 31, .025) 1px, transparent 1px),
    linear-gradient(90deg, rgba(23, 35, 31, .025) 1px, transparent 1px);
  background-size: 28px 28px;
  mask-image: linear-gradient(to bottom, black, transparent 85%);
}
::selection { background: var(--mint-2); color: var(--green); }
a { color: inherit; text-decoration: none; }
button, input, textarea, select { font: inherit; color: inherit; }
button { cursor: pointer; }
img { max-width: 100%; display: block; }
h1, h2, h3, h4, p { margin: 0; }
ul, ol { margin: 0; padding: 0; }

.serif { font-family: var(--serif); }
.mono { font-family: var(--mono); }
.muted { color: var(--muted); }
.faint { color: var(--muted-2); }
.nowrap { white-space: nowrap; }
.hidden { display: none !important; }
.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;
}

/* =========================================================
   Shell / header
   ========================================================= */
.site-header {
  position: sticky;
  top: 0;
  z-index: 40;
  height: var(--header-h);
  border-bottom: 1px solid rgba(222, 217, 203, .8);
  background: rgba(247, 244, 236, .86);
  backdrop-filter: blur(14px) saturate(120%);
}
.site-header__inner {
  max-width: 1180px;
  height: 100%;
  margin: 0 auto;
  padding: 0 28px;
  display: flex;
  align-items: center;
  gap: 34px;
}
.brand { display: flex; align-items: center; gap: 12px; flex: none; }
.brand__mark {
  width: 38px; height: 38px;
  display: grid; place-items: center;
  border-radius: 10px;
  background: var(--green);
  color: #f8f2e2;
  font-family: var(--serif);
  font-size: 21px;
  font-weight: 700;
  box-shadow: inset 0 0 0 1px rgba(255,255,255,.16), 0 6px 16px rgba(15,92,77,.2);
  position: relative;
  overflow: hidden;
}
.brand__mark::after {
  content: "";
  position: absolute; inset: 4px;
  border: 1px solid rgba(248, 242, 226, .38);
  border-radius: 6px;
}
.brand__text { line-height: 1.15; }
.brand__name {
  font-family: var(--serif);
  font-size: 20px;
  font-weight: 700;
  letter-spacing: .08em;
}
.brand__sub {
  font-size: 10px;
  letter-spacing: .18em;
  color: var(--muted);
  text-transform: uppercase;
  margin-top: 3px;
}
.nav { display: flex; align-items: center; gap: 4px; margin-left: 6px; }
.nav a {
  position: relative;
  padding: 9px 13px;
  border-radius: 8px;
  color: var(--muted);
  font-size: 14px;
  transition: color .2s, background .2s;
}
.nav a:hover { color: var(--ink); background: rgba(255,255,255,.55); }
.nav a.is-active { color: var(--green); font-weight: 600; }
.nav a.is-active::after {
  content: "";
  position: absolute;
  left: 13px; right: 13px; bottom: 2px;
  height: 2px;
  background: var(--green);
  border-radius: 2px;
}
.header-actions { margin-left: auto; display: flex; align-items: center; gap: 10px; }
.header-date {
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: .06em;
  color: var(--muted);
  padding-right: 8px;
}
.icon-btn {
  width: 36px; height: 36px;
  display: inline-grid; place-items: center;
  border: 1px solid var(--line);
  border-radius: 9px;
  background: rgba(255,255,255,.55);
  color: var(--ink-soft);
  transition: .2s var(--ease);
}
.icon-btn:hover { background: var(--card); border-color: var(--line-strong); transform: translateY(-1px); }

.page {
  max-width: 1180px;
  margin: 0 auto;
  padding: 38px 28px 80px;
  animation: pageIn .45s var(--ease) both;
}
@keyframes pageIn {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: none; }
}

.site-footer {
  max-width: 1180px;
  margin: 0 auto;
  padding: 26px 28px 38px;
  border-top: 1px solid var(--line);
  display: flex;
  align-items: center;
  gap: 16px;
  color: var(--muted);
  font-size: 12px;
}
.site-footer .sep { width: 1px; height: 12px; background: var(--line-strong); }
.site-footer .foot-mark { margin-left: auto; font-family: var(--serif); letter-spacing: .12em; color: var(--gold); }

/* =========================================================
   Buttons / chips / tags
   ========================================================= */
.btn {
  --btn-bg: transparent;
  --btn-fg: var(--ink);
  --btn-bd: var(--line-strong);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 42px;
  padding: 0 18px;
  border: 1px solid var(--btn-bd);
  border-radius: 10px;
  background: var(--btn-bg);
  color: var(--btn-fg);
  font-size: 14px;
  font-weight: 600;
  letter-spacing: .01em;
  transition: transform .2s var(--ease), box-shadow .2s var(--ease), background .2s, border-color .2s;
  white-space: nowrap;
}
.btn:hover { transform: translateY(-1px); box-shadow: var(--shadow-sm); }
.btn:active { transform: translateY(0); }
.btn:disabled { opacity: .45; pointer-events: none; }
.btn svg { flex: none; }
.btn--primary {
  --btn-bg: var(--green);
  --btn-fg: #fbf7ec;
  --btn-bd: var(--green);
  box-shadow: 0 6px 18px rgba(15, 92, 77, .2);
}
.btn--primary:hover { --btn-bg: #0c4f42; box-shadow: 0 10px 24px rgba(15, 92, 77, .25); }
.btn--clay { --btn-bg: var(--clay); --btn-fg: #fff9f0; --btn-bd: var(--clay); }
.btn--soft { --btn-bg: rgba(255,255,255,.55); --btn-fg: var(--ink-soft); --btn-bd: var(--line); }
.btn--ghost { --btn-bd: transparent; --btn-fg: var(--muted); }
.btn--ghost:hover { --btn-bg: rgba(255,255,255,.5); --btn-fg: var(--ink); box-shadow: none; }
.btn--danger { --btn-bg: #fff; --btn-fg: var(--red); --btn-bd: #e7c7c3; }
.btn--sm { min-height: 34px; padding: 0 12px; font-size: 12.5px; border-radius: 8px; }
.btn--lg { min-height: 52px; padding: 0 26px; font-size: 15px; border-radius: 12px; }
.btn--block { width: 100%; }
.btn--icon { min-width: 42px; padding: 0 12px; }

.chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 9px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(255,255,255,.55);
  color: var(--muted);
  font-size: 11.5px;
  font-weight: 600;
  letter-spacing: .03em;
}
.chip--green { color: var(--green); border-color: var(--mint-2); background: var(--mint); }
.chip--clay { color: var(--clay); border-color: #ecd2c6; background: var(--clay-soft); }
.chip--gold { color: #87652f; border-color: #e7d8b8; background: var(--gold-soft); }
.chip--red { color: var(--red); border-color: #ecd0cc; background: var(--red-soft); }
.dot { width: 6px; height: 6px; border-radius: 50%; background: currentColor; flex: none; }
.tag {
  display: inline-flex;
  align-items: center;
  height: 24px;
  padding: 0 8px;
  border-radius: 5px;
  background: var(--paper-deep);
  color: var(--ink-soft);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: .03em;
}
.tag--green { background: var(--mint); color: var(--green); }
.tag--clay { background: var(--clay-soft); color: var(--clay); }
.tag--gold { background: var(--gold-soft); color: #86652f; }
.tag--red { background: var(--red-soft); color: var(--red); }

/* =========================================================
   Cards / section headings
   ========================================================= */
.card {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
}
.card--pad { padding: 24px; }
.section-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 20px;
  margin: 0 0 18px;
}
.section-head h2 {
  font-family: var(--serif);
  font-size: 24px;
  font-weight: 700;
  letter-spacing: .02em;
  line-height: 1.3;
}
.section-head h2 .num {
  font-family: var(--mono);
  font-size: 11px;
  color: var(--gold);
  letter-spacing: .14em;
  display: block;
  margin-bottom: 7px;
  font-weight: 500;
}
.section-head p { color: var(--muted); font-size: 13px; }
.section-head .head-side { display: flex; align-items: center; gap: 10px; flex: none; }

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  color: var(--green);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .18em;
  text-transform: uppercase;
}
.eyebrow::before { content: ""; width: 22px; height: 1px; background: var(--green); }
.rule { height: 1px; background: var(--line); border: 0; margin: 0; }

/* =========================================================
   Home hero
   ========================================================= */
.hero {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(340px, .85fr);
  gap: 46px;
  align-items: center;
  padding: 30px 0 46px;
}
.hero__copy { position: relative; z-index: 1; }
.hero__title {
  font-family: var(--serif);
  font-size: clamp(40px, 5.4vw, 66px);
  line-height: 1.1;
  font-weight: 700;
  letter-spacing: .01em;
  margin: 20px 0 20px;
}
.hero__title em { font-style: normal; color: var(--green); position: relative; }
.hero__title em::after {
  content: "";
  position: absolute;
  left: 2%; right: 2%; bottom: 6px;
  height: 9px;
  background: var(--gold-soft);
  z-index: -1;
  transform: skewX(-8deg);
}
.hero__lead {
  max-width: 530px;
  color: var(--muted);
  font-size: 15.5px;
  line-height: 1.9;
}
.hero__actions { display: flex; align-items: center; flex-wrap: wrap; gap: 12px; margin-top: 30px; }
.hero__meta {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 18px;
  margin-top: 28px;
  color: var(--muted);
  font-size: 12px;
}
.hero__meta span { display: inline-flex; align-items: center; gap: 6px; }
.hero__meta b { color: var(--ink); font-family: var(--mono); font-weight: 600; }

.hero__visual { position: relative; min-height: 390px; display: grid; place-items: center; }
.hero__visual::before {
  content: "";
  position: absolute; inset: 8% 2%;
  border: 1px solid rgba(15, 92, 77, .14);
  border-radius: 50%;
  transform: rotate(-12deg);
}
.hero__visual::after {
  content: "";
  position: absolute; inset: 16% 8%;
  border: 1px dashed rgba(191, 98, 66, .18);
  border-radius: 50%;
  transform: rotate(18deg);
}
.exam-sheet {
  position: relative;
  width: min(340px, 92%);
  min-height: 360px;
  padding: 28px 26px 30px;
  background: var(--card);
  border: 1px solid var(--line-strong);
  border-radius: 4px 14px 14px 4px;
  box-shadow: var(--shadow-lg);
  transform: rotate(2.6deg);
  z-index: 1;
}
.exam-sheet::before {
  content: "";
  position: absolute; top: 0; bottom: 0; left: 22px;
  width: 1px;
  background: rgba(191, 98, 66, .22);
}
.exam-sheet::after {
  content: "";
  position: absolute; inset: 0;
  border-radius: inherit;
  box-shadow: inset 0 0 0 7px rgba(255,255,255,.7);
  pointer-events: none;
}
.exam-sheet__top { display: flex; align-items: center; justify-content: space-between; padding-left: 10px; }
.exam-sheet__top .code { font-family: var(--mono); font-size: 10px; color: var(--muted-2); letter-spacing: .12em; }
.exam-sheet__title {
  font-family: var(--serif);
  font-size: 25px;
  font-weight: 700;
  letter-spacing: .08em;
  margin: 30px 0 5px 10px;
}
.exam-sheet__sub { font-size: 11px; letter-spacing: .1em; color: var(--muted); margin-left: 10px; }
.exam-sheet__lines { margin: 30px 0 0 10px; display: grid; gap: 12px; }
.exam-sheet__line { height: 7px; background: var(--paper-deep); border-radius: 2px; }
.exam-sheet__line:nth-child(2) { width: 88%; }
.exam-sheet__line:nth-child(3) { width: 72%; }
.exam-sheet__line:nth-child(4) { width: 94%; }
.exam-sheet__line:nth-child(5) { width: 61%; }
.exam-sheet__foot {
  margin: 34px 0 0 10px;
  display: flex; align-items: center; justify-content: space-between;
}
.exam-sheet__foot .tiny { font-family: var(--mono); font-size: 9px; color: var(--muted-2); letter-spacing: .1em; }
.seal {
  width: 64px; height: 64px;
  display: grid; place-items: center;
  border: 2px solid rgba(168, 59, 50, .72);
  border-radius: 50%;
  color: rgba(168, 59, 50, .82);
  font-family: var(--serif);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: .16em;
  text-align: center;
  line-height: 1.35;
  transform: rotate(-9deg);
  opacity: .86;
}
.floating-note {
  position: absolute;
  z-index: 2;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 10px;
  box-shadow: var(--shadow-md);
  padding: 11px 13px;
  display: flex;
  align-items: center;
  gap: 9px;
  font-size: 11.5px;
  color: var(--ink-soft);
  animation: floaty 6s ease-in-out infinite;
}
.floating-note b { color: var(--green); font-family: var(--mono); font-size: 12px; }
.floating-note--a { top: 9%; left: 0; transform: rotate(-3deg); }
.floating-note--b { bottom: 12%; right: 0; animation-delay: -3s; transform: rotate(2deg); }
.floating-note .ic {
  width: 27px; height: 27px; border-radius: 7px;
  display: grid; place-items: center;
  background: var(--mint); color: var(--green);
}
@keyframes floaty {
  0%, 100% { translate: 0 0; }
  50% { translate: 0 -7px; }
}

/* =========================================================
   Stats strip
   ========================================================= */
.stats-strip {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  background: rgba(255, 253, 248, .68);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  margin-bottom: 50px;
}
.stat-cell { padding: 20px 24px; position: relative; }
.stat-cell + .stat-cell { border-left: 1px solid var(--line); }
.stat-cell .k { font-size: 11px; letter-spacing: .12em; color: var(--muted); font-weight: 600; }
.stat-cell .v {
  font-family: var(--serif);
  font-size: 31px;
  line-height: 1.2;
  margin-top: 5px;
  font-weight: 700;
  display: flex; align-items: baseline; gap: 5px;
}
.stat-cell .v small { font-family: var(--sans); font-size: 11px; color: var(--muted); font-weight: 400; }
.stat-cell .v .accent { color: var(--green); }

/* =========================================================
   Paper cards
   ========================================================= */
.paper-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; }
.paper-card {
  position: relative;
  padding: 26px 26px 22px;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
  overflow: hidden;
  transition: transform .28s var(--ease), box-shadow .28s var(--ease), border-color .2s;
  display: flex;
  flex-direction: column;
  min-height: 260px;
}
.paper-card:hover { transform: translateY(-3px); box-shadow: var(--shadow-md); border-color: var(--line-strong); }
.paper-card::before {
  content: "";
  position: absolute; top: 0; left: 0; right: 0; height: 3px;
  background: linear-gradient(90deg, var(--green), var(--green-3) 55%, var(--gold));
  opacity: .85;
}
.paper-card__top { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; }
.paper-card__index {
  font-family: var(--serif);
  font-size: 44px;
  line-height: .9;
  color: var(--paper-deep);
  font-weight: 700;
  letter-spacing: -.04em;
  -webkit-text-stroke: 1px var(--line-strong);
}
.paper-card__badges { display: flex; gap: 6px; flex-wrap: wrap; justify-content: flex-end; }
.paper-card h3 {
  font-family: var(--serif);
  font-size: 22px;
  line-height: 1.35;
  margin-top: 15px;
  letter-spacing: .01em;
}
.paper-card__desc { color: var(--muted); font-size: 12.5px; margin-top: 7px; }
.paper-card__meta {
  display: flex; flex-wrap: wrap; gap: 8px 16px;
  margin-top: 18px; padding-top: 16px;
  border-top: 1px dashed var(--line);
  color: var(--muted); font-size: 11.5px;
}
.paper-card__meta span { display: inline-flex; align-items: center; gap: 5px; }
.paper-card__foot { margin-top: auto; padding-top: 18px; display: flex; align-items: center; gap: 10px; }
.paper-card__foot .spacer { flex: 1; }
.paper-progress { display: flex; align-items: center; gap: 9px; color: var(--muted); font-size: 11px; }
.paper-progress .bar { width: 74px; height: 4px; background: var(--paper-deep); border-radius: 2px; overflow: hidden; }
.paper-progress .bar i { display: block; height: 100%; background: var(--green-3); border-radius: inherit; }

.paper-card--draft { border-style: dashed; background: linear-gradient(180deg, #fffdf8, #faf7ee); }
.paper-card--draft::before { background: var(--line-strong); }
.paper-card--draft .paper-card__index { -webkit-text-stroke-color: #d6cfbd; }
.draft-veil {
  position: absolute; inset: 0;
  display: grid; place-items: center;
  background: rgba(250, 247, 239, .55);
  backdrop-filter: blur(1.5px);
}
.draft-veil .stamp {
  transform: rotate(-7deg);
  border: 2px solid rgba(191, 98, 66, .55);
  color: rgba(191, 98, 66, .8);
  border-radius: 7px;
  padding: 7px 14px;
  font-family: var(--serif);
  font-weight: 700;
  letter-spacing: .18em;
  background: rgba(255, 253, 248, .8);
}

/* =========================================================
   Recent / list rows
   ========================================================= */
.home-columns { display: grid; grid-template-columns: minmax(0, 1.55fr) minmax(280px, .75fr); gap: 22px; margin-top: 44px; }
.list-card { padding: 8px 0; }
.list-row {
  display: flex; align-items: center; gap: 14px;
  padding: 15px 22px;
  border-bottom: 1px solid var(--line);
}
.list-row:last-child { border-bottom: 0; }
.list-row__icon {
  width: 38px; height: 38px; flex: none;
  border-radius: 10px;
  display: grid; place-items: center;
  background: var(--mint); color: var(--green);
}
.list-row__main { min-width: 0; flex: 1; }
.list-row__main b { display: block; font-size: 13.5px; font-weight: 600; }
.list-row__main span { display: block; color: var(--muted); font-size: 11.5px; margin-top: 2px; }
.list-row__side { flex: none; text-align: right; }
.list-row__side .score { font-family: var(--serif); font-weight: 700; font-size: 20px; color: var(--green); }
.list-row__side .score small { font-family: var(--sans); font-size: 10px; color: var(--muted); font-weight: 400; }
.attempt-actions { display: flex; align-items: center; justify-content: flex-end; gap: 6px; margin-top: 7px; }
.attempt-actions a, .attempt-actions button {
  border: 1px solid var(--line); background: var(--card);
  padding: 3px 8px; border-radius: 5px;
  color: var(--muted); font-size: 10.5px;
  cursor: pointer;
  transition: .15s;
}
.attempt-actions a:hover, .attempt-actions button:hover { color: var(--green); border-color: var(--mint-2); background: var(--mint); }
.attempt-actions .danger { color: var(--red); }
.attempt-actions .danger:hover { color: #8d2b24; border-color: #e7c7c3; background: var(--red-soft); }

.wrong-group { margin-bottom: 26px; }
.wrong-group__head {
  display: flex; align-items: center; justify-content: space-between;
  gap: 14px; padding: 0 2px 11px;
}
.wrong-group__head > div { display: flex; align-items: baseline; gap: 10px; flex-wrap: wrap; }
.wrong-group__title { font-family: var(--serif); font-size: 19px; font-weight: 700; }
.wrong-group__title:hover { color: var(--green); }
.wrong-group__head .muted { font-size: 11px; }

.verify-cta {
  background: linear-gradient(150deg, #143f36, #0f5c4d 58%, #1d6c59);
  color: #f7f2e5;
  border: 1px solid #0c4b3f;
  border-radius: var(--radius);
  padding: 26px;
  position: relative;
  overflow: hidden;
  box-shadow: 0 18px 40px rgba(15, 92, 77, .18);
}
.verify-cta::before {
  content: "核";
  position: absolute;
  right: -12px; bottom: -38px;
  font-family: var(--serif);
  font-size: 160px;
  color: rgba(247, 242, 229, .05);
  line-height: 1;
}
.verify-cta h3 { font-family: var(--serif); font-size: 21px; letter-spacing: .06em; }
.verify-cta p { color: rgba(247, 242, 229, .72); font-size: 12.5px; margin-top: 8px; line-height: 1.8; }
.verify-cta .steps { display: grid; gap: 9px; margin: 18px 0 20px; }
.verify-cta .step { display: flex; align-items: center; gap: 9px; font-size: 12px; color: rgba(247, 242, 229, .85); }
.verify-cta .step i {
  width: 19px; height: 19px; flex: none;
  border: 1px solid rgba(247, 242, 229, .28);
  border-radius: 50%;
  display: grid; place-items: center;
  font-family: var(--mono);
  font-size: 9.5px;
  font-style: normal;
}
.verify-cta .btn { --btn-bg: #f7f2e5; --btn-fg: #0f4a3e; --btn-bd: #f7f2e5; }
.verify-cta .link-light { color: rgba(247, 242, 229, .7); font-size: 11.5px; text-decoration: underline; text-underline-offset: 3px; }

/* =========================================================
   Paper detail
   ========================================================= */
.breadcrumb { display: flex; align-items: center; gap: 8px; color: var(--muted); font-size: 12px; margin-bottom: 22px; }
.breadcrumb a:hover { color: var(--green); }
.breadcrumb .sep { color: var(--muted-2); }

.paper-hero {
  display: grid;
  grid-template-columns: minmax(0, 1.35fr) minmax(300px, .65fr);
  gap: 28px;
  align-items: stretch;
}
.paper-hero__main {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: 36px 38px;
  position: relative;
  overflow: hidden;
  box-shadow: var(--shadow-sm);
}
.paper-hero__main::after {
  content: "";
  position: absolute; right: -80px; top: -90px;
  width: 260px; height: 260px;
  border: 1px solid var(--mint-2);
  border-radius: 50%;
}
.paper-hero__main::before {
  content: "";
  position: absolute; right: -30px; top: -40px;
  width: 160px; height: 160px;
  border: 1px dashed var(--gold-soft);
  border-radius: 50%;
}
.paper-hero h1 {
  font-family: var(--serif);
  font-size: clamp(30px, 3.4vw, 42px);
  line-height: 1.25;
  margin: 14px 0 10px;
  letter-spacing: .01em;
}
.paper-hero__sub { color: var(--muted); font-size: 14px; max-width: 620px; }
.paper-hero__tags { display: flex; flex-wrap: wrap; gap: 7px; margin-top: 20px; }
.paper-hero__stats {
  display: grid; grid-template-columns: repeat(3, 1fr);
  gap: 0; margin-top: 28px; padding-top: 22px;
  border-top: 1px solid var(--line);
}
.paper-hero__stats div { padding-right: 18px; }
.paper-hero__stats div + div { padding-left: 20px; border-left: 1px solid var(--line); }
.paper-hero__stats .k { font-size: 10.5px; letter-spacing: .12em; color: var(--muted); }
.paper-hero__stats .v { font-family: var(--serif); font-size: 26px; font-weight: 700; margin-top: 2px; }
.paper-hero__stats .v small { font-family: var(--sans); font-size: 10px; color: var(--muted); font-weight: 400; }

.start-panel {
  background: linear-gradient(160deg, #123e35, #0f5c4d 65%, #176b59);
  color: #f8f3e7;
  border-radius: var(--radius-lg);
  padding: 30px;
  display: flex;
  flex-direction: column;
  position: relative;
  overflow: hidden;
  box-shadow: 0 22px 50px rgba(15, 92, 77, .2);
}
.start-panel::after {
  content: "";
  position: absolute; width: 190px; height: 190px;
  border: 1px solid rgba(248, 243, 231, .12);
  border-radius: 50%;
  right: -60px; top: -80px;
}
.start-panel::before {
  content: "";
  position: absolute; width: 130px; height: 130px;
  border: 1px dashed rgba(248, 243, 231, .12);
  border-radius: 50%;
  right: 6px; top: -20px;
}
.start-panel .overline { font-size: 10px; letter-spacing: .2em; color: rgba(248, 243, 231, .55); font-weight: 700; }
.start-panel h2 { font-family: var(--serif); font-size: 26px; margin-top: 9px; letter-spacing: .04em; }
.start-panel p { color: rgba(248, 243, 231, .7); font-size: 12.5px; margin-top: 7px; line-height: 1.8; }
.start-panel .info-list { display: grid; gap: 10px; margin: 24px 0; }
.start-panel .info-list div { display: flex; align-items: center; justify-content: space-between; padding-bottom: 9px; border-bottom: 1px solid rgba(248, 243, 231, .13); font-size: 12.5px; }
.start-panel .info-list span { color: rgba(248, 243, 231, .6); }
.start-panel .info-list b { font-weight: 600; }
.start-panel .btn { margin-top: auto; --btn-bg: #f8f3e7; --btn-fg: #0d4b3f; --btn-bd: #f8f3e7; min-height: 50px; }
.start-panel .btn-stack { margin-top: auto; display: grid; gap: 9px; }
.start-panel .btn-stack .btn { margin-top: 0; width: 100%; }
.start-panel .btn--restart {
  --btn-bg: transparent;
  --btn-fg: #f8f3e7;
  --btn-bd: rgba(248, 243, 231, .32);
  box-shadow: none;
}
.start-panel .btn--restart:hover { --btn-bg: rgba(248, 243, 231, .08); --btn-bd: rgba(248, 243, 231, .5); }
.start-panel .fineprint { text-align: center; font-size: 10.5px; color: rgba(248,243,231,.5); margin-top: 12px; }

.detail-grid { display: grid; grid-template-columns: minmax(0, 1.35fr) minmax(300px, .65fr); gap: 28px; margin-top: 28px; }
.info-card { padding: 26px 28px; }
.info-card h3 { font-family: var(--serif); font-size: 19px; margin-bottom: 16px; }
.section-table { width: 100%; border-collapse: collapse; }
.section-table th {
  text-align: left; font-size: 10.5px; letter-spacing: .1em; color: var(--muted);
  font-weight: 600; padding: 0 0 10px; border-bottom: 1px solid var(--line);
}
.section-table td { padding: 12px 0; border-bottom: 1px dashed var(--line); font-size: 13px; }
.section-table tr:last-child td { border-bottom: 0; }
.section-table td:last-child, .section-table th:last-child { text-align: right; }
.section-table .qcount { font-family: var(--mono); font-size: 12px; color: var(--muted); }
.instruction-list { display: grid; gap: 11px; }
.instruction-list li {
  list-style: none; display: flex; gap: 10px; color: var(--muted); font-size: 12.5px; line-height: 1.75;
}
.instruction-list li i {
  width: 18px; height: 18px; flex: none; margin-top: 2px;
  display: grid; place-items: center;
  background: var(--mint); color: var(--green);
  border-radius: 50%; font-family: var(--mono); font-size: 9px; font-style: normal; font-weight: 700;
}

/* =========================================================
   Exam interface
   ========================================================= */
.exam-shell { min-height: 100vh; background: var(--paper); display: flex; flex-direction: column; }
.exam-header {
  height: 64px; flex: none;
  display: flex; align-items: center; gap: 18px;
  padding: 0 22px;
  background: rgba(255, 253, 248, .92);
  border-bottom: 1px solid var(--line);
  position: sticky; top: 0; z-index: 30;
  backdrop-filter: blur(12px);
}
.exam-header__title { min-width: 0; }
.exam-header__title b { display: block; font-size: 13.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 40vw; }
.exam-header__title span { display: block; color: var(--muted); font-size: 10.5px; letter-spacing: .04em; margin-top: 1px; }
.exam-header .spacer { flex: 1; }
.exam-timer {
  display: flex; align-items: center; gap: 8px;
  padding: 7px 13px;
  border: 1px solid var(--line);
  border-radius: 9px;
  background: var(--card-soft);
  font-family: var(--mono);
  font-size: 14px;
  font-weight: 600;
  letter-spacing: .05em;
  color: var(--ink);
  transition: .2s;
}
.exam-timer.is-warning { color: var(--clay); border-color: #e8cdc2; background: var(--clay-soft); }
.exam-timer.is-danger { color: var(--red); border-color: #e5c6c1; background: var(--red-soft); animation: pulse 1.4s infinite; }
@keyframes pulse { 50% { opacity: .65; } }
.exam-card-btn { display: none; }
.exam-progress-mini { display: flex; align-items: center; gap: 8px; color: var(--muted); font-size: 11px; min-width: 130px; }
.exam-progress-mini .bar { width: 80px; height: 4px; border-radius: 2px; background: var(--paper-deep); overflow: hidden; }
.exam-progress-mini .bar i { display: block; height: 100%; background: var(--green-3); transition: width .3s; }

.exam-body {
  flex: 1;
  width: 100%;
  max-width: 1320px;
  margin: 0 auto;
  padding: 22px 22px 46px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 310px;
  gap: 22px;
  align-items: start;
}
.question-panel {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  min-height: 600px;
  display: flex;
  flex-direction: column;
  box-shadow: var(--shadow-sm);
}
.question-panel__top {
  display: flex; align-items: center; gap: 10px;
  padding: 16px 26px;
  border-bottom: 1px solid var(--line);
}
.question-panel__top .qno { font-family: var(--mono); font-size: 11px; color: var(--muted); letter-spacing: .08em; }
.question-panel__top .spacer { flex: 1; }
.question-content { padding: 30px 34px 26px; flex: 1; display: flex; flex-direction: column; animation: qIn .28s var(--ease); }
.question-tip {
  margin-top: auto;
  padding-top: 26px;
  border-top: 1px dashed var(--line);
  color: var(--muted-2);
  font-size: 10.5px;
  display: flex;
  align-items: center;
  gap: 6px;
  letter-spacing: .02em;
}
@keyframes qIn { from { opacity: 0; transform: translateY(4px); } to { opacity: 1; transform: none; } }
.question-stem {
  font-size: 16.5px;
  line-height: 1.95;
  color: var(--ink);
  font-weight: 500;
  letter-spacing: .01em;
}
.question-stem p + p { margin-top: 10px; }
.question-stem .blank { color: var(--green); font-weight: 700; }
.question-material {
  margin: 0 0 22px;
  padding: 18px 20px;
  background: var(--card-soft);
  border: 1px solid var(--line);
  border-left: 3px solid var(--gold);
  border-radius: 0 8px 8px 0;
}
.question-material__head {
  display: flex; align-items: center; gap: 8px;
  font-family: var(--serif); font-weight: 700; font-size: 14px; color: var(--ink-soft);
  margin-bottom: 8px;
}
.question-material__body { color: var(--ink-soft); font-size: 13px; line-height: 1.9; white-space: pre-line; }
.question-material--collapsed .question-material__body { display: -webkit-box; -webkit-line-clamp: 4; -webkit-box-orient: vertical; overflow: hidden; }
.question-material--collapsed .question-figure { display: none; }
.material-toggle { margin-top: 8px; color: var(--green); font-size: 11.5px; font-weight: 600; background: none; border: 0; padding: 0; }
.material-toggle:hover { text-decoration: underline; text-underline-offset: 3px; }
.question-figure { margin: 18px 0 4px; }
.question-figure a { display: block; width: fit-content; margin: 0 auto; cursor: zoom-in; }
.question-figure img { border: 1px solid var(--line); border-radius: 8px; max-height: 470px; margin: 0 auto; background: #fff; }
@media (max-width: 860px) { .question-figure img { max-height: 340px; } }
.question-figure figcaption { text-align: center; color: var(--muted-2); font-size: 10.5px; margin-top: 6px; }

.options { display: grid; gap: 10px; margin-top: 26px; }
.option {
  display: flex; align-items: flex-start; gap: 13px;
  width: 100%;
  padding: 14px 16px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: rgba(255,255,255,.45);
  text-align: left;
  transition: border-color .18s, background .18s, transform .18s;
  position: relative;
}
.option:hover { border-color: var(--line-strong); background: #fff; transform: translateX(2px); }
.option__key {
  width: 27px; height: 27px; flex: none;
  display: grid; place-items: center;
  border: 1px solid var(--line-strong);
  border-radius: 50%;
  font-family: var(--mono);
  font-size: 11.5px;
  font-weight: 600;
  color: var(--muted);
  transition: .18s;
}
.option__text { font-size: 14px; line-height: 1.75; padding-top: 1px; }
.option--image { align-items: center; padding: 8px 14px; }
.option--image .option__text { display: flex; align-items: center; padding: 0; width: 100%; }
.option-image { max-height: 66px; max-width: 100%; width: auto; object-fit: contain; background: #fff; border-radius: 3px; }
.option-edit-img { width: 74px; max-height: 46px; object-fit: contain; background: #fff; border: 1px solid var(--line); border-radius: 4px; flex: none; }
.option.is-selected { border-color: var(--green); background: var(--mint); box-shadow: inset 0 0 0 1px var(--green); }
.option.is-selected .option__key { background: var(--green); border-color: var(--green); color: #fff; }
.option.is-selected .option__text { color: #0c463b; font-weight: 500; }
.option.is-correct { border-color: var(--green-3); background: #eef7f2; }
.option.is-correct .option__key { background: var(--green-3); border-color: var(--green-3); color: #fff; }
.option.is-wrong { border-color: #d99b93; background: var(--red-soft); }
.option.is-wrong .option__key { background: var(--red); border-color: var(--red); color: #fff; }
.option.is-dimmed { opacity: .55; }
.option:disabled { cursor: default; }
.option:disabled:hover { transform: none; }

.question-actions {
  display: flex; align-items: center; gap: 10px;
  padding: 16px 26px;
  border-top: 1px solid var(--line);
  background: var(--card-soft);
  border-radius: 0 0 var(--radius) var(--radius);
}
.question-actions .spacer { flex: 1; }
.flag-btn { color: var(--muted); }
.flag-btn.is-flagged { color: var(--clay); border-color: #e5c9bd; background: var(--clay-soft); }

/* answer card */
.answer-card {
  position: sticky; top: 86px;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
  overflow: hidden;
}
.answer-card__head { padding: 17px 18px 13px; border-bottom: 1px solid var(--line); }
.answer-card__head .row { display: flex; align-items: center; justify-content: space-between; }
.answer-card__head h3 { font-family: var(--serif); font-size: 16px; letter-spacing: .04em; }
.answer-card__head .count { font-family: var(--mono); font-size: 10.5px; color: var(--muted); }
.answer-card__legend { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 11px; color: var(--muted); font-size: 9.5px; }
.answer-card__legend span { display: inline-flex; align-items: center; gap: 4px; }
.answer-card__legend i { width: 7px; height: 7px; border-radius: 2px; background: var(--line); }
.answer-card__legend i.green { background: var(--green); }
.answer-card__legend i.clay { background: var(--clay); }
.answer-card__grid {
  display: grid; grid-template-columns: repeat(5, 1fr); gap: 7px;
  padding: 15px 16px 13px;
  max-height: calc(100vh - 280px);
  overflow: auto;
}
.answer-card__grid::-webkit-scrollbar { width: 5px; }
.answer-card__grid::-webkit-scrollbar-thumb { background: var(--line-strong); border-radius: 3px; }
.aq {
  aspect-ratio: 1.25; min-height: 32px;
  display: grid; place-items: center;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: rgba(255,255,255,.4);
  color: var(--muted);
  font-family: var(--mono);
  font-size: 10.5px;
  transition: .15s;
  position: relative;
}
.aq:hover { border-color: var(--green-3); color: var(--green); }
.aq.is-answered { background: var(--green); border-color: var(--green); color: #fff; }
.aq.is-flagged::after {
  content: ""; position: absolute; top: 3px; right: 3px;
  width: 5px; height: 5px; border-radius: 50%; background: var(--clay);
}
.aq.is-current { box-shadow: 0 0 0 2px var(--card), 0 0 0 3.5px var(--gold); }
.aq.is-correct { background: var(--green-3); border-color: var(--green-3); color: #fff; }
.aq.is-wrong { background: var(--red); border-color: var(--red); color: #fff; }
.answer-card__foot { padding: 12px 16px 16px; border-top: 1px solid var(--line); display: grid; gap: 8px; }
.answer-card__foot .hint { color: var(--muted-2); font-size: 10px; text-align: center; line-height: 1.5; }
.exam-setting-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 9px 0; }
.exam-setting-copy b { display: block; font-size: 11.5px; font-weight: 600; color: var(--ink-soft); }
.exam-setting-copy span { display: block; color: var(--muted); font-size: 10px; line-height: 1.55; margin-top: 2px; }
.answer-card__foot .exam-setting-copy span { display: none; }
.answer-card__foot .exam-setting-copy b { font-size: 10.5px; }
.switch {
  width: 38px; height: 21px; flex: none;
  position: relative; border: 0; border-radius: 20px;
  background: var(--line-strong);
  transition: background .18s;
  padding: 0;
}
.switch span {
  position: absolute; left: 2px; top: 2px;
  width: 17px; height: 17px; border-radius: 50%;
  background: #fff; box-shadow: 0 1px 3px rgba(0,0,0,.16);
  transition: transform .18s var(--ease);
}
.switch.is-on { background: var(--green); }
.switch.is-on span { transform: translateX(17px); }
.settings-box { margin-top: 16px; padding: 8px 14px; border: 1px solid var(--line); border-radius: 10px; background: var(--card-soft); }

.exam-mobile-bar { display: none; }

/* calculator */
.calc-fab {
  display: none;
  position: fixed; right: 18px; bottom: 78px; z-index: 55;
  width: 46px; height: 46px; border: 0; border-radius: 50%;
  place-items: center;
  background: var(--green); color: #fbf7ec;
  box-shadow: 0 8px 22px rgba(15, 92, 77, .28);
}
.calculator {
  display: none;
  position: fixed; right: 24px; bottom: 24px; z-index: 65;
  width: 300px;
  background: var(--card);
  border: 1px solid var(--line-strong);
  border-radius: 14px;
  box-shadow: var(--shadow-lg);
  overflow: hidden;
}
.calculator.is-open { display: block; animation: modalIn .22s var(--ease); }
.calc-head {
  display: flex; align-items: center; justify-content: space-between;
  padding: 10px 13px;
  background: var(--green); color: #f8f3e7;
  cursor: grab;
  user-select: none;
  touch-action: none;
}
.calculator.is-dragging .calc-head { cursor: grabbing; }
.calc-head > div { display: flex; align-items: center; gap: 6px; font-size: 12px; letter-spacing: .06em; }
.calc-close {
  width: 26px; height: 26px; display: grid; place-items: center;
  border: 1px solid rgba(248,243,231,.3); border-radius: 6px;
  background: transparent; color: #f8f3e7;
}
.calc-display {
  padding: 12px 15px 13px;
  text-align: right;
  background: var(--card-soft);
  border-bottom: 1px solid var(--line);
}
.calc-expr {
  min-height: 18px;
  color: var(--muted);
  font-family: var(--mono);
  font-size: 11.5px;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.calc-result {
  margin-top: 2px;
  font-family: var(--serif);
  font-size: 31px;
  font-weight: 700;
  line-height: 1.25;
  color: var(--ink);
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.calc-keys {
  display: grid; grid-template-columns: repeat(4, 1fr);
  gap: 6px; padding: 10px;
}
.calc-key {
  min-height: 40px;
  border: 1px solid var(--line);
  border-radius: 7px;
  background: var(--card);
  color: var(--ink-soft);
  font-family: var(--mono);
  font-size: 16px;
  transition: .14s;
}
.calc-key:hover { background: var(--mint); border-color: var(--mint-2); }
.calc-key:active { transform: scale(.97); }
.calc-key--op { background: var(--mint); color: var(--green); border-color: var(--mint-2); font-weight: 700; }
.calc-key--equals { background: var(--green); border-color: var(--green); color: #fff; font-weight: 700; }
.calc-key--equals:hover { background: #0c4f42; }
.calc-key--util { background: var(--paper-deep); color: var(--ink-soft); font-size: 13px; }
.calc-foot { text-align: center; color: var(--muted-2); font-size: 9.5px; padding: 0 0 9px; letter-spacing: .04em; }

/* =========================================================
   Result
   ========================================================= */
.result-hero {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: 34px 36px;
  display: grid;
  grid-template-columns: 210px minmax(0, 1fr);
  gap: 36px;
  align-items: center;
  position: relative;
  overflow: hidden;
  box-shadow: var(--shadow-sm);
}
.result-hero::after {
  content: "";
  position: absolute; right: -70px; bottom: -110px; width: 260px; height: 260px;
  border: 1px solid var(--mint-2); border-radius: 50%;
}
.score-ring {
  width: 188px; height: 188px;
  border-radius: 50%;
  display: grid; place-items: center;
  position: relative;
  background: conic-gradient(var(--green) calc(var(--pct) * 1%), var(--paper-deep) 0);
}
.score-ring::before {
  content: ""; position: absolute; inset: 9px;
  border-radius: 50%; background: var(--card);
  box-shadow: inset 0 0 0 1px var(--line);
}
.score-ring__inner { position: relative; text-align: center; }
.score-ring__inner .num { font-family: var(--serif); font-size: 52px; line-height: 1; font-weight: 700; color: var(--green); }
.score-ring__inner .num small { font-family: var(--sans); font-size: 12px; color: var(--muted); font-weight: 400; }
.score-ring__inner .label { font-size: 10px; letter-spacing: .18em; color: var(--muted); margin-top: 7px; }
.result-hero__main h1 { font-family: var(--serif); font-size: 34px; margin: 8px 0 6px; }
.result-hero__main .lead { color: var(--muted); font-size: 13.5px; }
.result-kpis { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 20px; }
.kpi {
  min-width: 96px;
  padding: 10px 14px;
  border: 1px solid var(--line);
  border-radius: 9px;
  background: var(--card-soft);
}
.kpi .k { font-size: 9.5px; color: var(--muted); letter-spacing: .08em; }
.kpi .v { font-family: var(--serif); font-size: 22px; font-weight: 700; line-height: 1.3; }
.kpi .v small { font-family: var(--sans); font-size: 10px; color: var(--muted); font-weight: 400; }
.result-actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 24px; }

.section-bars { display: grid; gap: 16px; }
.section-bar__top { display: flex; align-items: baseline; justify-content: space-between; font-size: 12.5px; margin-bottom: 6px; }
.section-bar__top b { font-weight: 600; }
.section-bar__top span { color: var(--muted); font-family: var(--mono); font-size: 10.5px; }
.section-bar__track { height: 7px; background: var(--paper-deep); border-radius: 4px; overflow: hidden; }
.section-bar__track i { display: block; height: 100%; border-radius: inherit; background: linear-gradient(90deg, var(--green), var(--green-3)); transition: width .8s var(--ease); }
.section-bar.is-low .section-bar__track i { background: linear-gradient(90deg, #b8863e, var(--clay)); }

.review-toolbar {
  display: flex; align-items: center; flex-wrap: wrap; gap: 8px;
  margin: 30px 0 16px;
}
.filter-btn {
  height: 32px; padding: 0 12px;
  border: 1px solid var(--line);
  border-radius: 7px;
  background: rgba(255,255,255,.5);
  color: var(--muted);
  font-size: 12px;
  transition: .18s;
}
.filter-btn:hover { border-color: var(--line-strong); color: var(--ink); }
.filter-btn.is-active { background: var(--green); border-color: var(--green); color: #fff; }
.review-list { display: grid; gap: 12px; }
.review-item {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 12px;
  overflow: hidden;
}
.review-item.is-open { border-color: var(--line-strong); box-shadow: var(--shadow-sm); }
.review-item__head {
  display: flex; align-items: center; gap: 12px;
  padding: 14px 18px;
  cursor: pointer;
  user-select: none;
}
.review-item__no {
  font-family: var(--mono); font-size: 11px; color: var(--muted);
  width: 36px; flex: none;
}
.review-item__stem {
  flex: 1; min-width: 0;
  font-size: 13px;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.review-item__mark { flex: none; }
.review-item__body { display: none; padding: 0 18px 18px; border-top: 1px dashed var(--line); }
.review-item.is-open .review-item__body { display: block; }
.review-item__full-stem { font-size: 14px; line-height: 1.85; margin: 14px 0 12px; }
.review-answer-row { display: flex; flex-wrap: wrap; gap: 8px; margin: 12px 0; }
.answer-pill {
  display: inline-flex; align-items: center; gap: 7px;
  padding: 6px 11px; border-radius: 7px;
  border: 1px solid var(--line);
  background: var(--card-soft);
  font-size: 11.5px;
}
.answer-pill b { font-family: var(--mono); }
.answer-pill--right { border-color: #bfdccd; background: #eef7f2; color: #135f4d; }
.answer-pill--wrong { border-color: #e7c3bd; background: var(--red-soft); color: var(--red); }
.explanation {
  margin-top: 12px;
  padding: 14px 16px;
  background: var(--card-soft);
  border-left: 3px solid var(--gold);
  border-radius: 0 7px 7px 0;
  color: var(--ink-soft);
  font-size: 12.5px;
  line-height: 1.9;
  white-space: pre-line;
}
.explanation b { color: var(--green); }
.source-link { display: inline-flex; align-items: center; gap: 5px; color: var(--muted); font-size: 10.5px; margin-top: 10px; }
.source-link:hover { color: var(--green); }

/* =========================================================
   Verification
   ========================================================= */
.verify-hero {
  display: grid; grid-template-columns: minmax(0, 1fr) auto;
  gap: 22px; align-items: end; margin-bottom: 26px;
}
.verify-hero h1 { font-family: var(--serif); font-size: 36px; line-height: 1.25; margin: 10px 0 7px; }
.verify-hero p { color: var(--muted); font-size: 13.5px; max-width: 640px; }
.verify-steps { display: flex; align-items: center; gap: 0; margin: 26px 0 30px; }
.vstep { display: flex; align-items: center; gap: 10px; flex: 1; min-width: 0; }
.vstep__num {
  width: 29px; height: 29px; flex: none;
  border-radius: 50%;
  display: grid; place-items: center;
  border: 1px solid var(--line-strong);
  background: var(--card);
  font-family: var(--mono); font-size: 10px; color: var(--muted);
}
.vstep.is-done .vstep__num { background: var(--green); border-color: var(--green); color: #fff; }
.vstep.is-active .vstep__num { border-color: var(--gold); color: var(--gold); box-shadow: 0 0 0 4px var(--gold-soft); }
.vstep__text b { display: block; font-size: 12.5px; font-weight: 600; }
.vstep__text span { display: block; color: var(--muted-2); font-size: 10px; margin-top: 1px; }
.vstep__line { flex: 1; height: 1px; background: var(--line); margin: 0 14px; min-width: 20px; }

.verify-list { display: grid; gap: 14px; }
.verify-paper-card {
  display: grid;
  grid-template-columns: 54px minmax(0, 1fr) auto;
  gap: 20px;
  align-items: center;
  padding: 22px 24px;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  transition: .2s;
}
.verify-paper-card:hover { border-color: var(--line-strong); box-shadow: var(--shadow-sm); }
.verify-paper-card__num {
  width: 50px; height: 58px;
  display: grid; place-items: center;
  background: var(--card-soft);
  border: 1px solid var(--line);
  border-radius: 3px 8px 8px 3px;
  font-family: var(--serif); font-size: 21px; font-weight: 700; color: var(--gold);
  position: relative;
}
.verify-paper-card__num::before {
  content: ""; position: absolute; left: 7px; top: 0; bottom: 0; width: 1px; background: rgba(191,98,66,.2);
}
.verify-paper-card h3 { font-family: var(--serif); font-size: 20px; }
.verify-paper-card .meta { display: flex; flex-wrap: wrap; gap: 8px 16px; margin-top: 6px; color: var(--muted); font-size: 11.5px; }
.verify-paper-card .meta span { display: inline-flex; align-items: center; gap: 5px; }
.verify-paper-card__right { display: flex; flex-direction: column; align-items: flex-end; gap: 8px; }

.check-list { display: grid; gap: 10px; }
.check-item { display: flex; align-items: center; gap: 10px; padding: 11px 13px; border: 1px solid var(--line); border-radius: 8px; background: var(--card-soft); font-size: 12px; }
.check-item .ic { width: 22px; height: 22px; flex: none; border-radius: 50%; display: grid; place-items: center; background: var(--mint); color: var(--green); }
.check-item .ic.warn { background: var(--gold-soft); color: var(--gold); }
.check-item .ic.bad { background: var(--red-soft); color: var(--red); }
.check-item b { margin-left: auto; font-family: var(--mono); font-size: 11px; color: var(--muted); }

/* verification workspace */
.vwork {
  display: grid;
  grid-template-columns: 225px minmax(0, 1fr) 330px;
  gap: 18px;
  align-items: start;
}
.vwork__side, .vwork__source {
  position: sticky; top: 92px;
  max-height: calc(100vh - 118px);
  overflow: auto;
}
.vwork__side { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); }
.vside-head { padding: 15px 16px 12px; border-bottom: 1px solid var(--line); }
.vside-head .row { display: flex; align-items: center; justify-content: space-between; }
.vside-head h3 { font-family: var(--serif); font-size: 15px; }
.vside-head .pct { font-family: var(--mono); font-size: 10px; color: var(--muted); }
.vside-progress { height: 4px; background: var(--paper-deep); border-radius: 2px; margin-top: 10px; overflow: hidden; }
.vside-progress i { display: block; height: 100%; background: var(--green-3); }
.vq-list { padding: 8px; display: grid; gap: 3px; }
.vq {
  display: flex; align-items: center; gap: 8px;
  padding: 8px 9px;
  border-radius: 6px;
  border: 1px solid transparent;
  background: none;
  text-align: left;
  color: var(--ink-soft);
  font-size: 11.5px;
  width: 100%;
  overflow: hidden;
}
.vq:hover { background: var(--card-soft); }
.vq.is-active { background: var(--mint); border-color: var(--mint-2); color: var(--green); font-weight: 600; }
.vq .n { font-family: var(--mono); font-size: 10px; width: 25px; flex: none; color: var(--muted); }
.vq .t { flex: 1; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.vq .s { width: 7px; height: 7px; border-radius: 50%; background: var(--line-strong); flex: none; }
.vq .s.ok { background: var(--green-3); }
.vq .s.issue { background: var(--clay); }

.vwork__main { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
.vmain-head { padding: 18px 24px; border-bottom: 1px solid var(--line); display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.vmain-head .spacer { flex: 1; }
.vmain-body { padding: 22px 24px; }
.field { margin-bottom: 16px; }
.field label { display: flex; align-items: center; justify-content: space-between; font-size: 10.5px; letter-spacing: .1em; color: var(--muted); font-weight: 600; margin-bottom: 6px; }
.field label .mini { font-family: var(--mono); font-size: 9px; letter-spacing: 0; color: var(--muted-2); }
.field textarea, .field input[type="text"], .field select {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--card-soft);
  padding: 10px 12px;
  font-size: 13px;
  line-height: 1.75;
  outline: none;
  transition: border-color .18s, box-shadow .18s, background .18s;
}
.field textarea { resize: vertical; min-height: 80px; }
.field textarea:focus, .field input[type="text"]:focus, .field select:focus {
  border-color: var(--green-3);
  background: #fff;
  box-shadow: 0 0 0 3px rgba(46, 143, 120, .1);
}
.field textarea.stem-input { min-height: 108px; font-size: 14px; }
.options-edit { display: grid; gap: 8px; }
.option-edit { display: flex; align-items: center; gap: 8px; }
.option-edit .key {
  width: 30px; height: 32px; flex: none;
  display: grid; place-items: center;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: var(--paper-deep);
  font-family: var(--mono); font-size: 10px; font-weight: 600; color: var(--muted);
}
.option-edit input { flex: 1; }
.option-edit .correct-mark {
  width: 30px; height: 32px; flex: none;
  display: grid; place-items: center;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #fff;
  color: var(--muted-2);
}
.option-edit .correct-mark.is-on { background: var(--green); border-color: var(--green); color: #fff; }
.vmain-foot { padding: 14px 24px; border-top: 1px solid var(--line); background: var(--card-soft); display: flex; align-items: center; gap: 9px; }
.vmain-foot .spacer { flex: 1; }
.issue-box { border: 1px solid #ecd2c6; background: var(--clay-soft); border-radius: 8px; padding: 11px 13px; color: #8a4b33; font-size: 11.5px; line-height: 1.7; margin-bottom: 15px; }
.issue-box b { color: var(--clay); }

.vwork__source { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
.vsource-head { padding: 13px 15px; border-bottom: 1px solid var(--line); display: flex; align-items: center; justify-content: space-between; }
.vsource-head b { font-family: var(--serif); font-size: 13px; }
.vsource-head span { font-family: var(--mono); font-size: 9.5px; color: var(--muted); }
.vsource-img { padding: 10px; background: #e9e5da; }
.vsource-img a { display: block; }
.vsource-img img { width: 100%; border: 1px solid var(--line-strong); background: #fff; box-shadow: 0 4px 14px rgba(0,0,0,.08); }
.vsource-foot { padding: 10px 14px; font-size: 10px; color: var(--muted); line-height: 1.6; border-top: 1px solid var(--line); }

/* =========================================================
   Bank
   ========================================================= */
.bank-stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; margin-bottom: 24px; }
.bank-stat { background: var(--card); border: 1px solid var(--line); border-radius: 12px; padding: 18px 20px; }
.bank-stat .k { font-size: 10px; letter-spacing: .1em; color: var(--muted); }
.bank-stat .v { font-family: var(--serif); font-size: 28px; font-weight: 700; margin-top: 2px; }
.bank-stat .v small { font-family: var(--sans); font-size: 10px; color: var(--muted); font-weight: 400; }
.bank-toolbar { display: flex; align-items: center; flex-wrap: wrap; gap: 10px; margin-bottom: 14px; }
.search-box { display: flex; align-items: center; gap: 8px; height: 38px; padding: 0 12px; border: 1px solid var(--line); border-radius: 8px; background: var(--card); min-width: 240px; }
.search-box input { border: 0; background: none; outline: none; width: 100%; font-size: 12.5px; }
.search-box svg { color: var(--muted-2); flex: none; }
.bank-toolbar .spacer { flex: 1; }
.bank-table { width: 100%; border-collapse: collapse; background: var(--card); border: 1px solid var(--line); border-radius: 12px; overflow: hidden; }
.bank-table th { text-align: left; padding: 11px 16px; background: var(--card-soft); border-bottom: 1px solid var(--line); font-size: 10px; letter-spacing: .1em; color: var(--muted); font-weight: 600; }
.bank-table td { padding: 12px 16px; border-bottom: 1px solid var(--line); font-size: 12.5px; vertical-align: top; }
.bank-table tr:last-child td { border-bottom: 0; }
.bank-table tr:hover td { background: #fffdf8; }
.bank-table .stem-cell { max-width: 580px; line-height: 1.6; }
.bank-table .stem-cell .qid { font-family: var(--mono); font-size: 9.5px; color: var(--muted-2); display: block; margin-bottom: 2px; }
.answer-badge { display: inline-flex; align-items: center; justify-content: center; min-width: 26px; height: 22px; padding: 0 6px; border-radius: 5px; background: var(--mint); color: var(--green); font-family: var(--mono); font-size: 10px; font-weight: 700; }

.empty-state { text-align: center; padding: 70px 24px; }
.empty-state .ic { width: 62px; height: 62px; margin: 0 auto 16px; border-radius: 50%; display: grid; place-items: center; background: var(--mint); color: var(--green); }
.empty-state h3 { font-family: var(--serif); font-size: 22px; }
.empty-state p { color: var(--muted); font-size: 13px; margin: 8px auto 20px; max-width: 430px; line-height: 1.8; }

/* =========================================================
   Modal / toast
   ========================================================= */
.modal-backdrop {
  position: fixed; inset: 0; z-index: 100;
  display: grid; place-items: center;
  padding: 20px;
  background: rgba(18, 31, 27, .48);
  backdrop-filter: blur(4px);
  animation: fadeIn .18s;
}
@keyframes fadeIn { from { opacity: 0; } }
.modal {
  width: min(480px, 100%);
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow-lg);
  padding: 28px;
  animation: modalIn .25s var(--ease);
}
@keyframes modalIn { from { opacity: 0; transform: translateY(10px) scale(.98); } }
.modal h3 { font-family: var(--serif); font-size: 23px; margin-bottom: 8px; }
.modal p { color: var(--muted); font-size: 13px; line-height: 1.8; }
.modal .modal-actions { display: flex; justify-content: flex-end; gap: 10px; margin-top: 24px; }
.modal .modal-stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin-top: 18px; }
.modal .modal-stats div { padding: 10px 12px; background: var(--card-soft); border: 1px solid var(--line); border-radius: 8px; }
.modal .modal-stats .k { font-size: 9.5px; color: var(--muted); }
.modal .modal-stats .v { font-family: var(--serif); font-size: 20px; font-weight: 700; margin-top: 1px; }

.modal-answer-grid { max-height: 56vh; overflow: auto; margin: 0 -6px; padding: 0 6px; }
.modal-answer-grid .answer-card__grid { max-height: none; padding: 0; }
.modal-answer-grid .aq { min-height: 38px; font-size: 12px; }
.toast-root { position: fixed; z-index: 200; left: 50%; bottom: 28px; transform: translateX(-50%); display: grid; gap: 8px; pointer-events: none; }
.toast {
  display: flex; align-items: center; gap: 8px;
  padding: 10px 16px;
  border-radius: 9px;
  background: #163d33;
  color: #f8f3e7;
  box-shadow: var(--shadow-md);
  font-size: 12.5px;
  animation: toastIn .28s var(--ease);
}
.toast .ic { color: #8fd3b9; display: grid; place-items: center; }
.toast--warn { background: #6b4329; }
@keyframes toastIn { from { opacity: 0; transform: translateY(8px); } }

/* =========================================================
   Utility / responsive
   ========================================================= */
.grid-2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: 18px; }
.stack { display: grid; gap: 14px; }
.mt-8 { margin-top: 8px; } .mt-12 { margin-top: 12px; } .mt-16 { margin-top: 16px; }
.mt-22 { margin-top: 22px; } .mt-30 { margin-top: 30px; } .mt-40 { margin-top: 40px; }
.mb-8 { margin-bottom: 8px; } .mb-16 { margin-bottom: 16px; } .mb-24 { margin-bottom: 24px; }
.flex { display: flex; align-items: center; gap: 10px; }
.flex-between { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.wrap { flex-wrap: wrap; }

@media (max-width: 1080px) {
  .hero { grid-template-columns: 1fr; gap: 26px; padding-top: 14px; }
  .hero__visual { min-height: 330px; order: -1; }
  .hero__title { font-size: clamp(38px, 8vw, 56px); }
  .exam-body { grid-template-columns: minmax(0, 1fr) 280px; }
  .vwork { grid-template-columns: 200px minmax(0, 1fr); }
  .vwork__source { display: none; }
}
@media (max-width: 860px) {
  :root { --header-h: 66px; }
  .site-header__inner { padding: 0 18px; gap: 12px; }
  .nav { margin-left: auto; gap: 0; }
  .nav a { padding: 8px 9px; font-size: 12.5px; }
  .header-date { display: none; }
  .page { padding: 26px 18px 60px; }
  .hero { padding: 10px 0 30px; }
  .hero__visual { min-height: 300px; }
  .exam-sheet { min-height: 310px; width: 300px; padding: 24px 20px; }
  .exam-sheet__title { font-size: 22px; margin-top: 22px; }
  .floating-note { display: none; }
  .stats-strip { grid-template-columns: repeat(2, 1fr); }
  .stat-cell:nth-child(3) { border-left: 0; border-top: 1px solid var(--line); }
  .stat-cell:nth-child(4) { border-top: 1px solid var(--line); }
  .paper-grid { grid-template-columns: 1fr; }
  .home-columns { grid-template-columns: 1fr; }
  .paper-hero { grid-template-columns: 1fr; }
  .paper-hero__main { padding: 28px 24px; }
  .paper-hero__stats { grid-template-columns: repeat(3, 1fr); }
  .detail-grid { grid-template-columns: 1fr; }
  .exam-body { grid-template-columns: 1fr; padding: 14px 14px 90px; }
  .answer-card { display: none; }
  .exam-header { padding: 0 14px; gap: 10px; }
  .exam-header__title span { display: none; }
  .exam-header .btn--submit { display: none; }
  .exam-card-btn { display: inline-grid; }
  .exam-calc-btn, .exam-settings-btn { display: none; }
  .calc-fab { display: grid; }
  .calculator { left: 10px; right: 10px; width: calc(100% - 20px); max-width: 380px; max-height: calc(100vh - 100px); overflow: auto; margin: 0 auto; bottom: 76px; }
  .exam-progress-mini { min-width: auto; }
  .exam-progress-mini .bar { width: 54px; }
  .question-content { padding: 22px 18px; }
  .question-panel__top { padding: 13px 18px; }
  .question-actions { padding: 12px 14px; }
  .question-stem { font-size: 15.5px; line-height: 1.9; }
  .exam-mobile-bar {
    display: grid; grid-template-columns: 1fr auto 1fr; align-items: center;
    position: fixed; left: 0; right: 0; bottom: 0; z-index: 40;
    padding: 9px 12px calc(9px + env(safe-area-inset-bottom));
    background: rgba(255,253,248,.96);
    border-top: 1px solid var(--line);
    backdrop-filter: blur(12px);
  }
  .exam-mobile-bar .btn { width: 100%; }
  .exam-mobile-bar .center { font-family: var(--mono); font-size: 11px; color: var(--muted); padding: 0 12px; }
  .result-hero { grid-template-columns: 1fr; gap: 24px; padding: 28px 22px; justify-items: center; text-align: center; }
  .result-hero__main h1 { font-size: 28px; }
  .result-kpis { justify-content: center; }
  .result-actions { justify-content: center; }
  .vwork { grid-template-columns: 1fr; }
  .vwork__side { position: static; max-height: 210px; }
  .vq-list { grid-template-columns: repeat(2, 1fr); display: grid; }
  .verify-hero { grid-template-columns: 1fr; }
  .verify-paper-card { grid-template-columns: 44px minmax(0, 1fr); }
  .verify-paper-card__right { grid-column: 1 / -1; flex-direction: row; align-items: center; justify-content: flex-end; }
  .bank-stats { grid-template-columns: repeat(2, 1fr); }
  .bank-table .hide-sm { display: none; }
  .site-footer { flex-wrap: wrap; }
  .site-footer .foot-mark { margin-left: 0; }
  .verify-steps { overflow-x: auto; padding-bottom: 4px; }
  .vstep__text span { display: none; }
}
@media (max-width: 560px) {
  .brand__sub { display: none; }
  .brand__name { font-size: 18px; }
  .nav a { padding: 7px 7px; font-size: 11.5px; }
  .nav a:nth-child(5) { display: none; }
  .header-actions .icon-btn { display: none; }
  .exam-progress-mini { display: none; }
  .exam-header { gap: 8px; }
  .exam-header__title b { max-width: 26vw; }
  .exam-timer { padding: 6px 9px; font-size: 12.5px; }
  .hero__title { font-size: 38px; }
  .hero__lead { font-size: 14px; }
  .paper-hero__stats .v { font-size: 22px; }
  .paper-hero__stats div { padding-right: 10px; }
  .paper-hero__stats div + div { padding-left: 12px; }
  .stats-strip { margin-bottom: 32px; }
  .stat-cell { padding: 15px 16px; }
  .stat-cell .v { font-size: 26px; }
  .exam-header__title b { max-width: 30vw; }
  .exam-progress-mini span { display: none; }
  .question-panel { min-height: auto; }
  .option { padding: 12px 13px; gap: 10px; }
  .option__text { font-size: 13.5px; }
  .question-actions .btn span { display: none; }
  .modal { padding: 22px; }
  .bank-table td, .bank-table th { padding: 10px 10px; }
  .bank-table .type-cell { display: none; }
  .attempt-row { flex-wrap: wrap; }
  .attempt-row .list-row__side { width: 100%; display: flex; align-items: center; justify-content: space-between; text-align: left; padding-left: 50px; }
  .attempt-row .attempt-actions { margin-top: 0; }
}
