/* 问答页：起始页（四张题型卡片）、答题页、成绩页。内容区收窄居中，像图鉴里夹的一页小考卷。 */
.qz-inner { max-width: 760px; }
.qz-inner .page-head p, .qz-type small { text-wrap: balance; }
.qz-swap { transition: opacity .14s ease, transform .14s ease; }
.qz-swap.out { opacity: 0; transform: translateY(-6px); }
.qz-swap.in { animation: fade .34s var(--ease-out) backwards; }

/* ------------------------------------------------------------ 起始页 */
.qz-types { display: grid; gap: 12px; }
.qz-type { position: relative; display: grid; grid-template-columns: minmax(0, 1fr) 118px; align-items: center; width: 100%; min-height: 104px; padding: 12px 4px 12px 16px; text-align: left; cursor: pointer;
  box-shadow: 0 3px 0 var(--edge); transition: transform .15s, box-shadow .15s; }
@media (hover: hover) { .qz-type:hover { transform: translateY(-2px); box-shadow: 0 5px 0 var(--edge), 0 12px 24px rgba(80, 55, 30, .13); } }
.qz-type:active { transform: translateY(2px); box-shadow: 0 1px 0 var(--edge); }
.qz-type-text { display: grid; gap: 2px; min-width: 0; }
.qz-type-name { display: flex; align-items: center; gap: 7px; }
.qz-type-name .ico { color: var(--seal); }
.qz-type-name strong { font-size: 18px; font-weight: 600; letter-spacing: .14em; line-height: 1.5; }
.qz-type small { font-size: 13px; line-height: 1.55; color: var(--sub); }
.qz-best { display: flex; align-items: center; gap: 7px; margin-top: 5px; font-style: normal; font-size: 12.5px; letter-spacing: .08em; line-height: 1.5; color: var(--jade-deep); }
.qz-best i { width: 7px; height: 7px; background: var(--jade); transform: rotate(45deg); border-radius: 1px; }
.qz-best b { margin: 0 1px; font: 600 15px/1 var(--latin); }
.qz-best.none { color: var(--faint); }
/* 卡片右边叠两座模型：后面一座小一些，探出卡片上沿 */
.qz-type-deco { position: relative; align-self: stretch; pointer-events: none; }
.qz-type-deco img { position: absolute; right: 2px; bottom: -6px; width: 104px; filter: drop-shadow(0 5px 5px rgba(80, 55, 30, .18)); }
.qz-type-deco img:first-child { right: 44px; bottom: 30px; width: 74px; opacity: .92; }
.qz-stats { display: grid; grid-template-columns: repeat(3, 1fr); margin: 0; padding: 4px 0; }
.qz-stats div { display: grid; justify-items: center; padding: 2px 4px; }
.qz-stats div + div { border-left: 1px dashed var(--line-strong); }
.qz-stats dt { order: 2; font-size: 12.5px; letter-spacing: .2em; text-indent: .2em; color: var(--sub); }
.qz-stats dd { margin: 0; line-height: 1.3; }
.qz-stats dd b { font: 600 27px/1.2 var(--latin); }
.qz-stats dd small { margin-left: 3px; font-size: 12px; color: var(--sub); }

/* ------------------------------------------------------------ 答题页：顶栏 */
.qz-bar { display: flex; align-items: center; gap: 10px; min-height: 40px; margin-bottom: 10px; }
.qz-bar-type { display: inline-flex; align-items: center; gap: 6px; font-size: 14.5px; font-weight: 600; letter-spacing: .14em; white-space: nowrap; }
.qz-bar-type .ico { color: var(--seal); }
.qz-dots { flex: 1; display: flex; align-items: center; justify-content: center; gap: 7px; min-width: 0; height: 18px; margin: 0; padding: 0; list-style: none; }
.qz-dots li { flex: none; width: 8px; height: 8px; background: var(--card); border: 1.5px solid var(--line-strong); border-radius: 1.5px; transform: rotate(45deg); transition: background .25s, border-color .25s, box-shadow .25s; }
.qz-dots li.ok { background: var(--jade); border-color: var(--jade-deep); }
.qz-dots li.no { background: var(--seal); border-color: var(--seal-deep); }
.qz-dots li.now { border-color: var(--gold-deep); box-shadow: 0 0 0 2px var(--gold); }
.qz-count { display: none; font-size: 13px; letter-spacing: .06em; color: var(--sub); white-space: nowrap; }
.qz-count b { font: 600 15px var(--latin); color: var(--ink); }
.qz-quit { margin-right: -8px; color: var(--sub); }
.qz-confirm { display: flex; align-items: center; flex-wrap: wrap; gap: 8px; margin: -2px 0 10px; padding: 8px 10px 9px 14px; background: var(--card-hi); border: 1.5px dashed var(--line-strong); border-radius: var(--wob-b);
  font-size: 13.5px; color: var(--ink-soft); animation: fade .25s both; }
.qz-confirm span { flex: 1 1 170px; }

/* 题面：模型图放在纸面卡片上 */
.qz-stage { overflow: hidden; }
.qz-figure { display: grid; place-items: center; height: clamp(150px, 28vh, 240px); background: radial-gradient(ellipse at 50% 64%, #fffaf0 0%, var(--paper-deep) 80%); }
.qz-figure img { display: block; max-width: 100%; height: 100%; min-height: 0; object-fit: contain; padding: 4px 10px 6px; filter: drop-shadow(0 8px 7px rgba(80, 55, 30, .16)); user-select: none; -webkit-user-select: none; }
.qz-q { display: grid; gap: 0; padding: 8px 14px 10px; border-top: 1px dashed var(--line-strong); text-align: center; font-size: 16px; letter-spacing: .12em; line-height: 1.6; }
.qz-q strong { font-size: 19px; font-weight: 600; letter-spacing: .14em; }
.qz-q strong + span { font-size: 13.5px; color: var(--sub); }
.qz-q.solo { display: block; padding: 4px 4px 2px; border: 0; font-size: 17px; }
.qz-q.solo strong { margin: 0 .22em; color: var(--seal); }
.qz-q.solo strong + span { font-size: inherit; color: inherit; }

/* 选项 */
/* 文字选项：窄屏一列，够宽（平板、桌面）自动排成两列 */
.qz-opts { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 260px), 1fr)); gap: 9px; margin-top: 12px; }
.qz-opts.two, .qz-opts.pair, .qz-opts.quad { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.qz-opts.pair, .qz-opts.quad { gap: 10px; }
.qz-opts.two .qz-opt { gap: 7px; padding: 6px 8px; font-size: 15px; letter-spacing: .05em; }
.qz-opts.two .qz-num { width: 21px; height: 21px; font-size: 11.5px; }
.qz-opts.two .qz-mark { right: 7px; }
.qz-opt, .qz-pick { position: relative; cursor: pointer; border: 1.5px solid var(--ink-line); box-shadow: 0 3px 0 var(--edge);
  transition: transform .12s, box-shadow .12s, background .2s, border-color .2s, opacity .3s; user-select: none; -webkit-user-select: none; }
.qz-opt { display: flex; align-items: center; gap: 10px; width: 100%; min-height: 46px; padding: 6px 12px 6px 10px; text-align: left; background: var(--card-hi); border-radius: var(--wob-b); font-size: 15.5px; letter-spacing: .08em; line-height: 1.4; }
@media (hover: hover) { .qz-opt:hover, .qz-pick:hover { background: #fff; } }
.qz-opt:active, .qz-pick:active { transform: translateY(2px); box-shadow: 0 1px 0 var(--edge); }
.qz-num { flex: none; display: grid; place-items: center; width: 23px; height: 23px; background: var(--card); border: 1.5px solid var(--line-strong); border-radius: 50%; font: 600 12px/1 var(--latin); color: var(--sub); }
.qz-pick { display: flex; flex-direction: column; padding: 0; overflow: hidden; text-align: center; background: var(--card); border-radius: var(--wob-a); }
.qz-pick-fig { position: relative; display: block; flex: none; aspect-ratio: 42 / 29; background: radial-gradient(ellipse at 50% 64%, #fffaf0 0%, var(--paper-deep) 80%); }
.qz-quad .qz-pick-fig { aspect-ratio: 42 / 26; }
.qz-pick-fig img { position: absolute; inset: 0; display: block; width: 100%; height: 100%; object-fit: contain; padding: 6px 6px 3px; }
.qz-pick-text { flex: 1; display: grid; align-content: start; gap: 2px; padding: 6px 8px 9px; border-top: 1px dashed var(--line-strong); }
.qz-pick-text strong { font-size: 15.5px; font-weight: 600; letter-spacing: .1em; line-height: 1.45; text-wrap: balance; }
.qz-pick-text small { font-size: 12px; line-height: 1.5; color: var(--ink-soft); animation: fade .3s both; }
.qz-pick .qz-num { position: absolute; z-index: 1; left: 8px; top: 8px; }
.qz-keys { display: none; }

/* 作答之后：对的青绿、错的朱红，其余变淡 */
.answered .qz-opt, .answered .qz-pick { cursor: default; pointer-events: none; }
.qz-opt.is-right, .qz-pick.is-right { background: #e9eee3; border-color: var(--jade-deep); box-shadow: 0 3px 0 var(--jade-deep); }
.qz-opt.is-wrong, .qz-pick.is-wrong { background: #f7e4d9; border-color: var(--seal-deep); box-shadow: 0 3px 0 var(--seal-deep); color: var(--seal-deep); }
.qz-opt.is-dim, .qz-pick.is-dim { opacity: .46; box-shadow: 0 2px 0 var(--edge); }
.qz-pick.is-dim { opacity: .6; }
.qz-pair .qz-pick.is-dim { opacity: .84; }
.is-right .qz-num { border-color: var(--jade-deep); color: var(--jade-deep); }
.is-wrong .qz-num { border-color: var(--seal-deep); color: var(--seal-deep); }
.is-right .qz-pick-fig, .is-wrong .qz-pick-fig { background: none; }
.qz-mark { position: absolute; right: 9px; top: 50%; margin-top: -12px; padding: 1px 6px; font-size: 13px; letter-spacing: 0; transform: rotate(-8deg); }
.qz-pick .qz-mark { z-index: 1; top: 8px; right: 8px; margin: 0; }
.qz-mark.fresh { animation: qz-mark .45s var(--ease-back) both; }
@keyframes qz-mark { 0% { opacity: 0; transform: scale(2.2) rotate(-24deg); } 60% { opacity: 1; transform: scale(.9) rotate(-5deg); } 100% { opacity: 1; transform: scale(1) rotate(-8deg); } }

/* 知识点卡片 */
.qz-fact { margin-top: 13px; padding: 12px 15px 14px; scroll-margin: 14px; }
.qz-fact.fresh { animation: rise .42s var(--ease-out) .12s both; }
.qz-fact-head { display: flex; align-items: center; gap: 10px; }
.qz-fact-head .seal { flex: none; }
.qz-fact-head strong { flex: 1; min-width: 0; font-size: 18px; font-weight: 600; letter-spacing: .12em; line-height: 1.45; }
.qz-streak { flex: none; font-size: 12.5px; letter-spacing: .1em; color: var(--gold-deep); white-space: nowrap; }
.qz-streak b { font: 600 16px var(--latin); }
.qz-fact-meta { display: flex; flex-wrap: wrap; gap: 1px 16px; margin-top: 5px; font-size: 13px; line-height: 1.65; color: var(--ink-soft); }
.qz-fact-meta span { display: inline-flex; align-items: baseline; gap: 5px; }
.qz-fact-meta .ico { align-self: center; color: var(--sub); }
.qz-fact-intro { margin-top: 7px; padding-top: 8px; border-top: 1px dashed var(--line-strong); font-size: 14.5px; line-height: 1.8; text-align: justify; }
.qz-fact-acts { display: flex; gap: 10px; margin-top: 12px; }
.qz-fact-acts .btn { flex: 1; min-height: 42px; }
.qz-fact-acts .btn.primary { flex: 1.4; }

/* ------------------------------------------------------------ 成绩页 */
.qz-result .qz-count { display: inline; }
.qz-score { display: flex; align-items: center; gap: 18px; padding: 20px 16px 20px 20px; }
.qz-bigseal { flex: none; display: grid; grid-template: 1fr 1fr / 1fr 1fr; grid-auto-flow: column; direction: rtl; place-items: center; width: 98px; height: 98px; padding: 11px 10px 12px;
  background: var(--seal); color: #fff3e2; font-size: 30px; font-weight: 700; line-height: 1; transform: rotate(-5deg);
  border-radius: 12px 15px 12px 16px / 15px 12px 16px 12px; box-shadow: inset 0 0 0 2.5px rgba(255, 236, 214, .62), 0 4px 0 var(--seal-deep); }
.qz-bigseal.fresh { animation: qz-stamp .62s var(--ease-back) .2s both; }
@keyframes qz-stamp { 0% { opacity: 0; transform: scale(2.1) rotate(-22deg); } 60% { opacity: 1; transform: scale(.94) rotate(-3deg); } 100% { opacity: 1; transform: scale(1) rotate(-5deg); } }
.qz-score-text { display: grid; gap: 3px; min-width: 0; }
.qz-score-num { line-height: 1.05; }
.qz-score-num b { font: 600 46px/1 var(--latin); }
.qz-score-num span { margin-left: 8px; font: 20px var(--latin); color: var(--sub); }
.qz-score-title { display: flex; align-items: baseline; flex-wrap: wrap; gap: 0 10px; }
.qz-score-title strong { font-size: 17px; font-weight: 600; letter-spacing: .2em; }
.qz-score-title small { font-size: 12.5px; color: var(--sub); }
.qz-score-note { font-size: 14px; line-height: 1.65; color: var(--ink-soft); }
.qz-record { display: flex; align-items: center; gap: 8px; margin-top: 4px; font-size: 13px; line-height: 1.5; color: var(--ink-soft); white-space: nowrap; }
.qz-record .seal { flex: none; }
.qz-wrong { display: grid; gap: 2px; margin: 0 -4px; }
.qz-wrong .wc-text small { white-space: normal; line-height: 1.5; }
.qz-result-acts { display: flex; gap: 10px; margin-top: 24px; }
.qz-result-acts .btn { flex: 1; min-height: 44px; }

/* ------------------------------------------------------------ 桌面 */
@media (min-width: 900px) {
  /* 桌面上题型卡片改成上图下文，模型放大一些 */
  .qz-types { grid-template-columns: 1fr 1fr; gap: 18px; }
  .qz-type { grid-template-columns: minmax(0, 1fr); align-items: stretch; min-height: 0; padding: 0; overflow: hidden; }
  .qz-type-deco { order: -1; height: 156px; background: radial-gradient(ellipse at 50% 66%, #fffaf0 0%, var(--paper-deep) 82%); border-bottom: 1px dashed var(--line-strong); }
  .qz-type-deco img { right: 9%; bottom: 2px; width: 190px; }
  .qz-type-deco img:first-child { right: auto; left: 8%; bottom: 30px; width: 132px; }
  .qz-type-text { padding: 11px 18px 14px; }
  .qz-type-name strong { font-size: 19px; }
  .qz-type small { font-size: 13.5px; }
  .qz-stats dd b { font-size: 31px; }
  .qz-bar { margin-bottom: 14px; }
  .qz-bar-type { font-size: 15.5px; }
  .qz-dots { gap: 9px; }
  .qz-dots li { width: 9px; height: 9px; }
  .qz-count { display: inline; }
  .qz-figure { height: clamp(220px, 34vh, 310px); }
  .qz-q { padding: 10px 16px 12px; font-size: 17px; }
  .qz-q strong { font-size: 21px; }
  .qz-q.solo { padding: 2px 4px 4px; font-size: 18.5px; }
  .qz-opts { gap: 12px; margin-top: 14px; }
  .qz-opts.pair { gap: 16px; }
  .qz-opts.quad { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; }
  .qz-opt, .qz-opts.two .qz-opt { gap: 10px; min-height: 50px; padding: 7px 14px 7px 12px; font-size: 16px; letter-spacing: .08em; }
  .qz-opts.two .qz-num { width: 23px; height: 23px; font-size: 12px; }
  .qz-opts.two .qz-mark { right: 10px; }
  .qz-pick-text strong { font-size: 16px; }
  .qz-pair .qz-pick-text strong { font-size: 17.5px; }
  .qz-pick-text small { font-size: 12.5px; }
  .qz-keys { display: block; margin-top: 10px; text-align: center; font-size: 12px; letter-spacing: .08em; color: var(--sub); opacity: .8; }
  .answered .qz-keys { display: none; }
  .qz-fact { margin-top: 16px; padding: 14px 20px 16px; }
  .qz-fact-head strong { font-size: 19px; }
  .qz-fact-meta { font-size: 13.5px; }
  .qz-fact-intro { font-size: 15px; }
  .qz-fact-acts { justify-content: flex-end; }
  .qz-fact-acts .btn, .qz-fact-acts .btn.primary { flex: none; min-width: 132px; }
  .qz-score { gap: 26px; padding: 26px 28px 26px 34px; }
  .qz-bigseal { width: 118px; height: 118px; padding: 13px 12px 14px; font-size: 37px; }
  .qz-score-num b { font-size: 54px; }
  .qz-wrong { grid-template-columns: 1fr 1fr; gap: 4px 18px; }
  .qz-result-acts { justify-content: center; }
  .qz-result-acts .btn { flex: none; min-width: 150px; }
}
/* 手机横屏：题面在左，选项在右 */
@media (max-width: 899px) and (orientation: landscape) and (max-height: 520px) {
  .qz-play .qz-swap { display: grid; grid-template-columns: 1fr 1fr; gap: 0 14px; align-items: start; }
  .qz-play .qz-swap > :not(.qz-stage, .qz-opts) { grid-column: 1 / -1; }
  .qz-play .qz-opts { grid-template-columns: 1fr; margin-top: 0; }
  .qz-play .qz-opts.two { grid-template-columns: 1fr 1fr; }
  .qz-play .qz-opts.pair { grid-column: 1 / -1; grid-template-columns: 1fr 1fr; margin-top: 10px; }
  .qz-play .qz-opts.quad { grid-column: 1 / -1; grid-template-columns: repeat(4, minmax(0, 1fr)); margin-top: 10px; }
  .qz-figure { height: clamp(120px, 46vh, 210px); }
  .qz-types { grid-template-columns: 1fr 1fr; }
}
:lang(en) .qz-bigseal { direction: ltr; grid-auto-flow: row; letter-spacing: 0; }
:lang(en) :is(.qz-bar-type, .qz-result-acts, .qz-record) { white-space: normal; letter-spacing: normal; }
:lang(en) .qz-type-name strong { letter-spacing: .015em; }
:lang(en) .qz-fact-intro { text-align: left; }
