:root {
  --drill-coral: #ff6b4a;
  --drill-teal: #168579;
  --drill-navy: #142238;
  --drill-cream: #fffdfa;
  --drill-line: rgba(20, 34, 56, 0.12);
  --drill-ok: #14735f;
  --drill-bad: #c24136;
  --drill-warn: #9a620d;
}

.number-practice-page .wrap {
  width: 100%;
  margin: 0;
  padding: 0 0 48px;
}

.number-practice-page .hero {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 18px 28px;
  overflow: hidden;
  margin: 0;
  padding: clamp(26px, 4vw, 46px);
  border: 1px solid var(--drill-line);
  border-radius: 26px;
  color: #fff;
  background:
    radial-gradient(circle at 88% 8%, rgba(22, 133, 121, 0.48), transparent 22rem),
    radial-gradient(circle at 64% 125%, rgba(255, 107, 74, 0.3), transparent 24rem),
    var(--drill-navy);
  box-shadow: 0 22px 48px rgba(20, 34, 56, 0.16);
}

.number-practice-page .hero::before {
  content: "01";
  position: absolute;
  right: 32px;
  top: -24px;
  color: rgba(255, 255, 255, 0.045);
  font: 900 clamp(120px, 18vw, 220px) / 1 Georgia, serif;
  pointer-events: none;
}

.hero-copy,
.toolbar,
.summary { position: relative; z-index: 1; }
.hero-copy { max-width: 760px; }
.hero-kicker {
  margin-bottom: 12px;
  color: #7fe0d3;
  font-size: 12px;
  font-weight: 900;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.number-practice-page .hero h2 {
  max-width: 720px;
  margin: 0 0 14px;
  font: 800 clamp(32px, 5vw, 58px) / 1.06 Georgia, "Noto Serif SC", "Songti SC", serif;
  letter-spacing: -0.045em;
}

.number-practice-page .sub {
  max-width: 670px;
  color: rgba(255, 255, 255, 0.72);
  font-size: 15px;
  line-height: 1.75;
}

.number-practice-page .toolbar {
  display: flex;
  align-items: flex-start;
  justify-content: flex-end;
  gap: 10px;
  flex-wrap: wrap;
}

.number-practice-page button {
  min-height: 44px;
  padding: 9px 15px;
  border: 1px solid transparent;
  border-radius: 11px;
  color: #fff;
  background: var(--drill-coral);
  font: 800 14px/1.2 "Noto Sans SC", "Microsoft YaHei", sans-serif;
  cursor: pointer;
  transition: transform .16s ease, background .16s ease, border-color .16s ease;
}

.number-practice-page button:hover { transform: translateY(-1px); }
.number-practice-page button:focus-visible,
.number-practice-page input:focus-visible {
  outline: 3px solid rgba(255, 107, 74, .3);
  outline-offset: 2px;
}
.number-practice-page button.secondary {
  color: #fff;
  border-color: rgba(255,255,255,.24);
  background: rgba(255,255,255,.09);
}
.number-practice-page button.ghost {
  color: #d9fff9;
  border-color: rgba(127,224,211,.28);
  background: rgba(22,133,121,.22);
}

.summary {
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: repeat(8, minmax(0, 1fr));
  gap: 8px;
  margin-top: 8px;
}
.summary-card {
  min-width: 0;
  padding: 12px;
  border: 1px solid rgba(255,255,255,.13);
  border-radius: 13px;
  background: rgba(255,255,255,.07);
}
.summary-card .muted { color: rgba(255,255,255,.58); }
.summary-card strong { display: block; margin-top: 5px; color: #fff; font-size: 18px; }
.summary-card .mini { color: #9de5dc; }

.tabs {
  display: grid;
  grid-template-columns: repeat(8, minmax(0, 1fr));
  gap: 8px;
  margin: 20px 0 12px;
  padding: 7px;
  border: 1px solid var(--drill-line);
  border-radius: 16px;
  background: rgba(255,253,250,.92);
  box-shadow: 0 10px 28px rgba(20,34,56,.05);
}
.number-practice-page .tab {
  min-width: 0;
  color: #66758a;
  border-color: transparent;
  background: transparent;
}
.number-practice-page .tab:hover { color: var(--drill-navy); background: #f0f3f2; }
.number-practice-page .tab.active {
  color: #fff;
  border-color: var(--drill-teal);
  background: var(--drill-teal);
  box-shadow: 0 8px 18px rgba(22,133,121,.2);
}

.panel {
  display: none;
  padding: clamp(18px, 3vw, 30px);
  border: 1px solid var(--drill-line);
  border-radius: 24px;
  background: rgba(255,253,250,.98);
  box-shadow: 0 16px 42px rgba(20,34,56,.07);
}
.panel.active { display: block; animation: panel-in .24s ease both; }
@keyframes panel-in { from { opacity: 0; transform: translateY(5px); } }
.panel-head {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  align-items: flex-start;
  margin-bottom: 20px;
}
.panel h2 { margin: 0 0 7px; color: var(--drill-navy); font-size: 26px; }
.mini { color: #66758a; font-size: 13px; line-height: 1.55; }
.audio-box {
  flex: 0 1 410px;
  min-width: 300px;
  padding: 14px 16px;
  border: 1px solid rgba(22,133,121,.18);
  border-radius: 15px;
  color: var(--drill-navy);
  background: #edf8f5;
}
.audio-box audio { display: block; width: 100%; margin-top: 8px; }
.table-scroll { overflow-x: auto; border: 1px solid var(--drill-line); border-radius: 15px; }
table { width: 100%; min-width: 670px; border-collapse: collapse; background: #fff; }
th, td { padding: 11px 13px; border-bottom: 1px solid var(--drill-line); vertical-align: middle; }
th { color: #5b6879; background: #f4f5f2; font-size: 13px; text-align: left; }
th + th, td + td { border-left: 1px solid var(--drill-line); }
tbody tr:last-child td { border-bottom: 0; }
td.no { width: 68px; color: var(--drill-teal); text-align: center; font-weight: 900; background: #fbfcfa; }
tbody tr.checked.is-correct { background: rgba(20,115,95,.035); }
tbody tr.checked.is-wrong { background: rgba(194,65,54,.035); }
input.answer {
  width: 100%;
  min-height: 43px;
  padding: 9px 11px;
  border: 1px solid #cbd3dc;
  border-radius: 9px;
  color: var(--drill-navy);
  background: #fff;
  font: 600 15px/1.3 "Noto Sans SC", "Microsoft YaHei", sans-serif;
}
input.answer:focus { border-color: var(--drill-teal); box-shadow: 0 0 0 3px rgba(22,133,121,.12); outline: none; }
.cell-status { min-height: 18px; margin-top: 5px; font-size: 12px; font-weight: 800; }
.correct-answer { display: none; margin-top: 5px; color: var(--drill-warn); font-size: 13px; font-weight: 800; }
.correct-answer.show { display: block; }
.ok { color: var(--drill-ok); }
.bad { color: var(--drill-bad); }
.muted { color: #66758a; }
.actions { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 18px; }
.actions button.secondary { color: var(--drill-teal); border-color: rgba(22,133,121,.25); background: #edf8f5; }
.actions button.ghost { color: #66758a; border-color: var(--drill-line); background: #fff; }
.result {
  margin-top: 14px;
  padding: 14px 16px;
  border: 1px solid var(--drill-line);
  border-radius: 13px;
  color: #4d5b6c;
  background: #f7f8f5;
}
.score { margin-bottom: 3px; color: var(--drill-navy); font-size: 20px; font-weight: 900; }
.footer-note { margin-top: 18px; padding: 0 6px; color: #66758a; font-size: 13px; line-height: 1.7; }

@media (max-width: 1180px) {
  .summary, .tabs { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}
@media (max-width: 760px) {
  .number-practice-page .hero { grid-template-columns: 1fr; padding: 24px 20px; }
  .number-practice-page .toolbar { justify-content: flex-start; }
  .summary { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .tabs { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .panel-head { flex-direction: column; }
  .audio-box { width: 100%; min-width: 0; flex-basis: auto; }
}
@media (max-width: 520px) {
  .number-practice-page .wrap { padding-bottom: 28px; }
  .number-practice-page .hero h2 { font-size: 34px; }
  .tabs { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .panel { padding: 14px; border-radius: 18px; }
  .actions button { flex: 1 1 100%; }
}

@media (prefers-reduced-motion: reduce) {
  .panel.active { animation: none; }
  .number-practice-page button { transition: none; }
}
