:root {
  color-scheme: light;
  --ink: #172026;
  --muted: #5d6b66;
  --soft: #f6faf8;
  --line: #dde6e3;
  --card: #ffffff;
  --green: #20b486;
  --green-soft: #e7f6f2;
  --blue: #4e7cff;
  --blue-soft: #eef2ff;
  --yellow: #f7c95f;
  --yellow-soft: #fff6d9;
  --coral: #f26d5b;
  --coral-soft: #fff0ed;
  --sidebar: #172026;
  --focus-ring: 0 0 0 3px rgba(32, 180, 134, 0.22);
  --hover-shadow: 0 10px 24px rgba(23, 32, 38, 0.1);
  font-family:
    Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI",
    "Noto Sans KR", "Microsoft YaHei", sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  overflow-x: hidden;
}

[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;
}

body {
  margin: 0;
  background: var(--soft);
  color: var(--ink);
  font-size: 16px;
  line-height: 1.65;
  overflow-x: hidden;
}

button {
  border: 0;
  cursor: pointer;
  font: inherit;
}

a,
button,
[role="button"],
[data-view],
[data-topic],
[data-topic-group],
[data-vocab-level],
[data-vocab-unit],
[data-vocab-answer],
.is-clickable {
  -webkit-tap-highlight-color: transparent;
}

img,
audio,
video,
canvas {
  max-width: 100%;
}

p,
h1,
h2,
h3,
h4,
strong,
span,
button {
  overflow-wrap: anywhere;
}

.app-shell {
  min-height: 100vh;
  display: grid;
  grid-template-columns: 260px 1fr;
}

.mobile-header,
.mobile-nav-backdrop {
  display: none;
}

.app-sidebar {
  position: fixed;
  inset: 0 auto 0 0;
  z-index: 40;
  width: 260px;
  height: 100dvh;
  padding: 32px 24px;
  background: var(--sidebar);
  color: #fff;
  display: flex;
  flex-direction: column;
  gap: 28px;
  overflow-y: auto;
}

.brand-block {
  display: flex;
  align-items: center;
  gap: 12px;
}

.brand-mark {
  width: 42px;
  height: 42px;
  border-radius: 8px;
  display: grid;
  place-items: center;
  background: var(--green);
  font-weight: 800;
}

.brand-block h1 {
  margin: 0;
  font-size: 24px;
}

.brand-block p,
.app-sidebar p {
  margin: 4px 0 0;
  color: #9db0aa;
  font-size: 13px;
}

.primary-nav {
  display: grid;
  gap: 8px;
}

.nav-item {
  width: 100%;
  padding: 12px 14px;
  border-radius: 8px;
  background: transparent;
  color: #b9c8c3;
  text-align: left;
  font-weight: 600;
}

.nav-item.is-active {
  background: #27413a;
  color: #fff;
}

.sidebar-footer {
  margin-top: auto;
  display: grid;
  gap: 10px;
}

.account-button {
  width: 100%;
  min-width: 0;
  padding: 10px;
  display: grid;
  grid-template-columns: 34px minmax(0, 1fr);
  align-items: center;
  gap: 10px;
  border: 1px solid #385048;
  border-radius: 8px;
  background: #21312d;
  color: #fff;
  text-align: left;
}

.account-button:hover,
.account-button:focus-visible {
  border-color: #69c39f;
  background: #29413a;
}

.account-avatar,
.account-profile-avatar {
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: var(--green);
  color: #10231c;
  font-weight: 900;
}

.account-avatar {
  width: 34px;
  height: 34px;
  font-size: 13px;
}

.account-avatar.is-icon {
  background: transparent;
  color: var(--green);
}

.account-avatar-icon {
  width: 34px;
  height: 34px;
  display: block;
}

.account-button-copy {
  min-width: 0;
}

.account-button-copy strong,
.account-button-copy small {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.account-button-copy strong {
  font-size: 13px;
}

.account-button-copy small {
  margin-top: 3px;
  color: #9db0aa;
  font-size: 11px;
}

.account-dialog-layer {
  position: fixed;
  inset: 0;
  z-index: 1200;
  display: grid;
  place-items: center;
  padding: 18px;
}

.account-dialog-backdrop {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
  border-radius: 0;
  background: rgba(12, 20, 18, 0.66);
}

.account-dialog {
  position: relative;
  width: min(100%, 420px);
  max-height: min(720px, calc(100dvh - 36px));
  overflow-y: auto;
  padding: 28px;
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 24px 70px rgba(8, 18, 15, 0.28);
}

.account-dialog h2 {
  margin: 0 42px 22px 0;
  font-size: 24px;
}

.account-dialog-close {
  position: absolute;
  top: 18px;
  right: 18px;
  width: 34px;
  height: 34px;
  padding: 0;
  border-radius: 50%;
  background: #eef3f1;
  color: var(--ink);
  font-size: 25px;
  line-height: 1;
}

.account-tabs {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 4px;
  margin-bottom: 20px;
  padding: 4px;
  border-radius: 8px;
  background: #eef3f1;
}

.account-tab {
  min-height: 40px;
  border-radius: 6px;
  background: transparent;
  color: var(--muted);
  font-weight: 800;
}

.account-tab.is-active {
  background: #fff;
  color: var(--ink);
  box-shadow: 0 1px 4px rgba(15, 32, 27, 0.12);
}

.account-form,
.account-field {
  display: grid;
}

.account-form {
  gap: 15px;
}

.account-field {
  gap: 7px;
  color: var(--ink);
  font-size: 13px;
  font-weight: 800;
}

.account-input {
  width: 100%;
  min-height: 46px;
  padding: 0 13px;
  border: 1px solid var(--line);
  border-radius: 7px;
  background: #fff;
  color: var(--ink);
  font: inherit;
}

.account-input:focus {
  border-color: var(--green);
  outline: 3px solid rgba(65, 183, 137, 0.16);
}

.account-form-message {
  min-height: 20px;
  margin: 0;
  color: var(--muted);
  font-size: 13px;
}

.account-form-message.is-error {
  color: #b42318;
}

.account-submit {
  min-height: 46px;
  border-radius: 7px;
  background: var(--green);
  color: #10231c;
  font-weight: 900;
}

.account-submit.is-secondary {
  width: 100%;
  background: #eef3f1;
  color: var(--ink);
}

.account-submit:disabled {
  cursor: wait;
  opacity: 0.65;
}

.account-profile {
  margin-bottom: 22px;
  display: grid;
  grid-template-columns: 52px minmax(0, 1fr);
  align-items: center;
  gap: 13px;
}

.account-profile-avatar {
  width: 52px;
  height: 52px;
  font-size: 20px;
}

.account-profile strong,
.account-profile span {
  display: block;
  overflow-wrap: anywhere;
}

.account-profile span {
  margin-top: 4px;
  color: var(--muted);
  font-size: 13px;
}

.question-count-badge {
  align-self: flex-start;
  padding: 8px 12px;
  border-radius: 8px;
  background: var(--yellow);
  color: var(--ink);
  font-size: 13px;
  font-weight: 800;
}

.app-main {
  grid-column: 2;
  padding: 32px 40px;
  max-width: 1280px;
  width: 100%;
  min-width: 0;
}

.view {
  display: none;
}

.view.is-visible {
  display: block;
}

.topbar {
  min-height: 72px;
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 18px;
  margin-bottom: 22px;
}

.topbar h2 {
  margin: 0;
  font-size: 31px;
  line-height: 1.2;
}

.topbar p {
  margin: 4px 0 0;
  color: var(--muted);
}

.eyebrow {
  margin: 0 0 4px;
  color: #136c65;
  font-size: 13px;
  font-weight: 800;
}

.mint {
  color: #8fe3c3;
}

.top-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
  justify-content: flex-end;
}

.primary-btn,
.secondary-btn,
.pill-btn,
.text-btn {
  min-height: 43px;
  border-radius: 8px;
  padding: 0 16px;
  font-weight: 800;
}

.primary-btn {
  background: var(--ink);
  color: #fff;
}

.primary-btn.is-loading,
.secondary-btn.is-loading {
  position: relative;
  color: transparent;
  pointer-events: none;
}

.primary-btn.is-loading::after,
.secondary-btn.is-loading::after {
  content: "";
  position: absolute;
  inset: 0;
  width: 18px;
  height: 18px;
  margin: auto;
  border: 2px solid currentColor;
  border-right-color: transparent;
  border-radius: 999px;
  color: #fff;
  animation: spin 760ms linear infinite;
}

.secondary-btn.is-loading::after {
  color: var(--ink);
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

.primary-btn,
.secondary-btn,
.pill-btn,
.text-btn,
.option,
.type-tab,
.nav-item,
.topic-card,
.topic-group-toggle,
.grammar-section-toggle,
.section-head,
.vocab-level-btn,
.vocab-unit-btn,
.vocab-audio-chip,
.vocab-sound-btn,
.vocab-quiz-option,
.timer-control,
.mobile-menu-toggle,
.breakdown-card.is-clickable,
.clear-mistakes-btn {
  transition:
    transform 160ms ease,
    box-shadow 160ms ease,
    background-color 160ms ease,
    border-color 160ms ease,
    color 160ms ease,
    opacity 160ms ease;
}

.primary-btn:not(:disabled):active,
.secondary-btn:not(:disabled):active,
.pill-btn:not(:disabled):active,
.text-btn:not(:disabled):active,
.option:not(:disabled):active,
.type-tab:not(:disabled):active,
.nav-item:not(:disabled):active,
.vocab-level-btn:not(:disabled):active,
.vocab-unit-btn:not(:disabled):active,
.vocab-quiz-option:not(:disabled):active,
.vocab-sound-btn:not(:disabled):active,
.timer-control:not(:disabled):active {
  transform: translateY(1px) scale(0.98);
}

.primary-btn:not(:disabled):hover,
.secondary-btn:not(:disabled):hover,
.pill-btn:not(:disabled):hover,
.option:not(:disabled):hover,
.type-tab:not(:disabled):hover,
.topic-card:hover,
.topic-group-toggle:not(:disabled):hover,
.vocab-level-btn:not(:disabled):hover,
.vocab-unit-btn:not(:disabled):hover,
.vocab-audio-chip:not(:disabled):hover,
.vocab-sound-btn:not(:disabled):hover,
.vocab-quiz-option:not(:disabled):hover,
.breakdown-card.is-clickable:not(:disabled):hover {
  transform: translateY(-2px);
  box-shadow: var(--hover-shadow);
}

.text-btn:not(:disabled):hover {
  color: #0d4f49;
  text-decoration: underline;
  text-underline-offset: 3px;
}

.nav-item:not(:disabled):hover {
  background: #223833;
  color: #fff;
  transform: translateX(3px);
}

.primary-btn:not(:disabled):hover {
  background: #0f171c;
}

.secondary-btn:not(:disabled):hover {
  border-color: #8bbcb3;
  background: #fbfefd;
}

.pill-btn:not(:disabled):hover,
.vocab-audio-chip:not(:disabled):hover,
.vocab-sound-btn:not(:disabled):hover {
  border-color: #8fd8c7;
  background: #dff5ef;
}

button:focus-visible,
a:focus-visible,
[tabindex]:focus-visible {
  outline: 0;
  box-shadow: var(--focus-ring);
}

.secondary-btn,
.pill-btn {
  background: #fff;
  color: var(--ink);
  border: 1px solid #c9d6d2;
}

.secondary-btn.is-active {
  background: var(--green-soft);
  color: #136c65;
  border-color: var(--green);
}

.pill-btn {
  background: var(--green-soft);
  border-color: transparent;
  color: #136c65;
}

.text-btn {
  min-height: 0;
  padding: 0;
  color: #136c65;
  background: transparent;
}

.hero-panel {
  min-height: 150px;
  padding: 24px;
  border-radius: 8px;
  background: var(--ink);
  color: #fff;
  display: grid;
  grid-template-columns: 1fr 220px;
  align-items: center;
  gap: 24px;
  margin-bottom: 22px;
}

.hero-panel h3 {
  margin: 0;
  font-size: 28px;
}

.hero-panel p {
  color: #b9c8c3;
  max-width: 720px;
}

.study-visual {
  height: 112px;
  border-radius: 8px;
  background: #fff;
  color: var(--ink);
  display: grid;
  place-content: center;
  gap: 4px;
  box-shadow: inset 0 0 0 1px #d9e7e2;
}

.study-visual span {
  color: #136c65;
  font-size: 12px;
  font-weight: 800;
}

.study-visual strong {
  font-size: 30px;
}

.study-visual small {
  color: var(--muted);
}

.metric-grid,
.topic-grid {
  display: grid;
  gap: 12px;
  margin-bottom: 22px;
}

.metric-grid {
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
}

.topic-grid {
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
}

.metric-card,
.topic-card,
.question-card,
.grammar-card,
.mistake-card {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.metric-card {
  padding: 16px;
}

.metric-card p,
.topic-card p,
.mistake-card p {
  color: var(--muted);
}

.metric-card strong {
  display: block;
  margin-top: 8px;
  font-size: 26px;
}

.study-report {
  margin: 22px 0;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.report-head {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  align-items: start;
  margin-bottom: 14px;
}

.report-head h3 {
  margin: 2px 0 0;
  font-size: 22px;
}

.report-head > span {
  padding: 6px 10px;
  border-radius: 999px;
  background: var(--green-soft);
  color: #136c65;
  font-size: 12px;
  font-weight: 900;
}

.report-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
}

.report-grid article,
.report-lists article {
  min-width: 0;
  padding: 12px;
  border: 1px solid #edf3f1;
  border-radius: 8px;
  background: #f9fcfb;
}

.report-grid span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
}

.report-grid strong {
  display: block;
  margin-top: 5px;
  color: var(--ink);
  font-size: 18px;
  overflow-wrap: anywhere;
}

.report-lists {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin-top: 12px;
}

.report-lists article {
  background: #fff;
}

.report-lists h4 {
  margin: 0 0 8px;
  color: var(--ink);
  font-size: 14px;
}

.report-lists p {
  margin: 7px 0 0;
  color: #34524b;
  line-height: 1.55;
}

.report-lists p span {
  color: #c65f52;
  font-weight: 900;
}

.muted-line {
  color: var(--muted) !important;
}

.topic-card {
  padding: 18px;
}

.topic-card:hover {
  border-color: #b8d8d1;
}

.topic-card h3 {
  margin: 12px 0 8px;
}

.topic-group-card {
  padding: 0;
  overflow: hidden;
}

.topic-group-card > p {
  margin: 0;
  padding: 0 18px 18px;
}

.topic-group-toggle {
  width: 100%;
  min-height: 82px;
  padding: 18px;
  border: 0;
  background: transparent;
  color: var(--ink);
  display: grid;
  grid-template-columns: 14px minmax(0, 1fr) 28px;
  gap: 12px;
  align-items: center;
  text-align: left;
}

.topic-group-toggle strong,
.topic-group-toggle small {
  display: block;
}

.topic-group-toggle strong {
  font-size: 24px;
}

.topic-group-toggle small {
  margin-top: 4px;
  color: var(--muted);
  font-size: 13px;
}

.topic-group-toggle .chevron {
  width: 28px;
  height: 28px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  background: #f4f7f6;
  color: var(--muted);
  font-size: 25px;
  line-height: 1;
  transition: transform 0.2s ease;
}

.topic-group-toggle[aria-expanded="true"] .chevron {
  transform: rotate(90deg);
}

.topic-group-body {
  display: grid;
  gap: 8px;
  padding: 0 14px 16px;
}

.topic-mini-card {
  min-height: 58px;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #f8fbfa;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
  align-items: center;
}

.topic-mini-card strong,
.topic-mini-card span {
  display: block;
}

.topic-mini-card strong {
  font-size: 15px;
}

.topic-mini-card span {
  margin-top: 2px;
  color: var(--muted);
  font-size: 12px;
}

.must-drill-grid {
  display: grid;
  gap: 14px;
}

.must-tabbar {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  padding: 12px 0 22px;
}

.must-tab {
  min-height: 44px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--card);
  color: var(--muted);
  font-weight: 800;
  padding: 0 18px;
  box-shadow: 0 6px 16px rgba(23, 32, 38, 0.04);
  transition: transform 180ms ease, border-color 180ms ease, background 180ms ease, color 180ms ease;
}

.must-tab:hover,
.must-tab.is-active {
  transform: translateY(-1px);
  border-color: rgba(18, 126, 111, 0.28);
  background: #078579;
  color: #fff;
}

.must-filterbar {
  display: grid;
  grid-template-columns: minmax(180px, 1fr) repeat(3, minmax(130px, 170px));
  gap: 10px;
  align-items: center;
}

.must-search-placeholder,
.must-filterbar select {
  width: 100%;
  min-height: 48px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--card);
}

.must-filterbar select {
  color: var(--ink);
  font: inherit;
  padding: 0 14px;
  transition: border-color 180ms ease, box-shadow 180ms ease;
}

.must-filterbar select:focus {
  outline: none;
  border-color: var(--green);
  box-shadow: var(--focus-ring);
}

.must-summary {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
  padding: 12px 14px;
  border-radius: 8px;
  background: var(--green-soft);
  color: #136c65;
}

.must-summary span {
  color: var(--muted);
  font-size: 14px;
}

.must-table-wrap {
  overflow-x: auto;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--card);
  box-shadow: var(--shadow);
}

.must-table {
  width: 100%;
  min-width: 720px;
  border-collapse: collapse;
}

.must-table th,
.must-table td {
  padding: 14px 16px;
  text-align: left;
  border-bottom: 1px solid var(--line);
}

.must-table th {
  background: #078579;
  color: #fff;
  font-size: 14px;
}

.must-table tbody tr {
  transition: background 180ms ease;
}

.must-table tbody tr:hover {
  background: var(--soft);
}

.must-table td strong,
.must-table td span {
  display: block;
}

.must-table td span {
  margin-top: 4px;
  color: var(--muted);
  font-size: 13px;
}

.compact-action {
  min-height: 38px;
  padding: 0 18px;
  white-space: nowrap;
}

.must-empty {
  color: var(--muted);
  text-align: center;
}

.type-tabs {
  display: grid;
  gap: 12px;
  padding: 0 0 12px;
  margin-bottom: 14px;
}

.type-group {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  overflow: hidden;
}

.type-group-toggle {
  width: 100%;
  padding: 14px 16px;
  border: 0;
  background: transparent;
  color: var(--ink);
  text-align: left;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 28px;
  gap: 10px;
  align-items: center;
}

.type-group-title strong,
.type-group-title small {
  display: block;
}

.type-group-title strong {
  font-size: 18px;
}

.type-group-title small {
  margin-top: 4px;
  color: var(--muted);
  font-size: 12px;
}

.type-group-toggle .chevron {
  width: 28px;
  height: 28px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  background: #f4f7f6;
  color: var(--muted);
  font-size: 25px;
  line-height: 1;
  transition: transform 0.2s ease;
}

.type-group.is-open .type-group-toggle .chevron {
  transform: rotate(90deg);
}

.type-group-body {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 10px;
  padding: 0 14px 14px;
}

.type-tab {
  min-width: 0;
  padding: 12px 14px;
  border-radius: 8px;
  background: #fff;
  border: 1px solid var(--line);
  color: var(--ink);
  text-align: left;
}

.type-tab span,
.type-tab small {
  display: block;
}

.type-tab span {
  font-weight: 800;
  white-space: nowrap;
}

.type-tab small {
  margin-top: 4px;
  color: var(--muted);
  font-size: 12px;
}

.type-tab.is-active {
  background: var(--ink);
  border-color: var(--ink);
  color: #fff;
}

.type-tab:not(.is-active):not(:disabled):hover {
  border-color: #b9dad3;
}

.type-tab.is-active small {
  color: #b9c8c3;
}

.prep-panel {
  margin-bottom: 20px;
  padding: 20px;
  border-radius: 8px;
  border: 1px solid var(--line);
  background: #fff;
}

.prep-panel h3 {
  margin: 0;
  font-size: 24px;
}

.prep-panel > div:first-child p {
  margin: 6px 0 0;
  color: var(--muted);
}

.prep-summary {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 14px;
}

.prep-summary span {
  padding: 7px 10px;
  border-radius: 8px;
  background: var(--green-soft);
  color: #136c65;
  font-size: 13px;
  font-weight: 800;
}

.grammar-toggle {
  margin-top: 14px;
}

.prep-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
  margin-top: 18px;
}

.prep-card {
  display: grid;
  grid-template-columns: 14px 1fr;
  gap: 10px;
  padding: 14px;
  border-radius: 8px;
  background: #f6faf8;
  border: 1px solid #e6eeee;
}

.prep-card h4 {
  margin: 0 0 4px;
  font-size: 16px;
}

.prep-card strong {
  display: block;
  color: #136c65;
  font-size: 14px;
  line-height: 1.5;
}

.prep-card p {
  margin: 6px 0 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.6;
}

.dot {
  display: inline-block;
  width: 10px;
  height: 10px;
  border-radius: 999px;
}

.green {
  background: var(--green);
}

.blue {
  background: var(--blue);
}

.yellow {
  background: var(--yellow);
}

.coral {
  background: var(--coral);
}

.grammar-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 18px;
}

.grammar-card {
  padding: 16px;
  min-height: 150px;
}

.grammar-card h3 {
  margin: 10px 0 8px;
}

.grammar-card strong {
  display: block;
  margin-bottom: 6px;
  font-size: 15px;
}

.grammar-card p {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.6;
}

.grammar-section,
.prep-category {
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.section-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 14px;
  margin-bottom: 14px;
}

.grammar-section-toggle {
  width: 100%;
  padding: 0;
  background: transparent;
  color: inherit;
  text-align: left;
}

.grammar-section-toggle:hover {
  background: transparent;
}

.grammar-section-toggle .chevron {
  font-size: 24px;
  line-height: 1;
  color: var(--muted);
}

.grammar-section:not(.is-open) .section-head {
  margin-bottom: 0;
}

.section-head h3,
.section-head h4 {
  margin: 0;
  font-size: 22px;
}

.section-head span {
  padding: 6px 10px;
  border-radius: 8px;
  background: var(--green-soft);
  color: #136c65;
  font-size: 12px;
  font-weight: 800;
  white-space: nowrap;
}

.detail-list {
  display: grid;
  gap: 12px;
}

.detail-card {
  padding: 14px;
  border: 1px solid #e6eeee;
  border-radius: 8px;
  background: #f9fcfb;
}

.detail-title {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
  margin-bottom: 12px;
}

.detail-title span {
  width: 28px;
  height: 28px;
  border-radius: 8px;
  display: grid;
  place-items: center;
  background: var(--ink);
  color: #fff;
  font-size: 12px;
  font-weight: 800;
}

.detail-title strong {
  font-size: 19px;
}

.mark-unknown-btn {
  margin-left: auto;
  min-height: 30px;
  padding: 0 10px;
  border: 1px solid #c9d6d2;
  border-radius: 8px;
  background: #fff;
  color: var(--ink);
  font-size: 12px;
  font-weight: 900;
  white-space: nowrap;
  transition:
    transform 160ms ease,
    border-color 160ms ease,
    background-color 160ms ease,
    color 160ms ease;
}

.mark-unknown-btn:hover {
  transform: translateY(-1px);
  border-color: var(--green);
}

.mark-unknown-btn.is-active,
#unknown-btn.is-active {
  border-color: #c65f52;
  background: var(--coral-soft);
  color: #9d3024;
}

.meaning-list {
  display: grid;
  gap: 10px;
}

.meaning-item {
  display: grid;
  grid-template-columns: 28px 1fr;
  gap: 10px;
  padding: 12px;
  border-radius: 8px;
  background: #fff;
  border: 1px solid #edf3f1;
}

.meaning-index {
  width: 24px;
  height: 24px;
  border-radius: 999px;
  display: grid;
  place-items: center;
  background: var(--green-soft);
  color: #136c65;
  font-size: 12px;
  font-weight: 800;
}

.meaning-text,
.example-ko,
.example-zh,
.note-text {
  margin: 0;
  line-height: 1.65;
}

.meaning-text {
  font-weight: 800;
}

.example-ko {
  margin-top: 8px;
  color: var(--ink);
  font-weight: 700;
}

.example-zh {
  margin-top: 4px;
  color: var(--muted);
}

.note-text {
  margin-top: 6px;
  color: #99513e;
  font-size: 13px;
}

.similar-list {
  display: grid;
  gap: 10px;
}

.similar-card {
  padding: 14px;
  border: 1px solid #e6eeee;
  border-radius: 8px;
  background: #f9fcfb;
}

.similar-card strong {
  display: block;
  margin-top: 6px;
  color: var(--ink);
  font-size: 18px;
  line-height: 1.55;
}

.form-chip-list {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 10px;
}

.form-chip-list span {
  padding: 7px 10px;
  border-radius: 8px;
  background: #fff;
  border: 1px solid var(--line);
  color: #136c65;
  font-size: 13px;
  font-weight: 800;
}

.breakdown-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 10px;
}

.breakdown-card,
.word-card {
  border: 1px solid #e6eeee;
  border-radius: 8px;
  background: #f9fcfb;
}

.breakdown-card {
  padding: 14px;
}

.breakdown-card.is-clickable {
  width: 100%;
  color: inherit;
  text-align: left;
  cursor: pointer;
}

.breakdown-card.is-clickable:hover,
.breakdown-card.is-clickable.is-active {
  border-color: #69c9bd;
  background: #f0fffb;
}

.breakdown-card.is-clickable.is-active {
  box-shadow: inset 0 0 0 1px #69c9bd;
}

.breakdown-card strong {
  display: block;
  color: #136c65;
  font-size: 15px;
}

.breakdown-card p {
  margin: 6px 0 0;
  color: var(--muted);
  line-height: 1.5;
}

.section-note {
  margin: -6px 0 14px;
  color: var(--muted);
}

.word-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 8px;
}

.word-card {
  padding: 10px 12px;
}

.word-card strong,
.word-card span {
  display: block;
}

.word-card strong {
  color: var(--ink);
  font-size: 15px;
}

.word-card span {
  margin-top: 3px;
  color: var(--muted);
  font-size: 13px;
}

.idiom-grid {
  display: grid;
  gap: 14px;
}

.idiom-section {
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #f8fbfa;
}

.idiom-section > strong {
  display: block;
  margin-bottom: 10px;
  color: #136c65;
}

.idiom-list {
  display: grid;
  gap: 8px;
}

.idiom-row {
  display: grid;
  grid-template-columns: 36px minmax(140px, 0.9fr) minmax(0, 1.1fr);
  gap: 10px;
  align-items: start;
  padding: 9px 10px;
  border-radius: 8px;
  background: #fff;
  border: 1px solid #e6eeee;
}

.idiom-row span {
  width: 26px;
  height: 26px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  background: var(--green-soft);
  color: #136c65;
  font-size: 12px;
  font-weight: 900;
}

.idiom-row b {
  font-size: 16px;
}

.idiom-row em {
  color: var(--muted);
  font-style: normal;
  line-height: 1.55;
}

.slide-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.slide-card {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  overflow: hidden;
}

.slide-card img {
  display: block;
  width: 100%;
  background: #f8fbfa;
}

.slide-card div {
  padding: 12px 14px;
}

.slide-card strong,
.slide-card p {
  display: block;
  margin: 0;
}

.slide-card strong {
  color: #136c65;
}

.slide-card p {
  margin-top: 4px;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.5;
}

.writing54-page-grid {
  display: grid;
  gap: 14px;
}

.writing54-page-card {
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fbfefd;
}

.writing54-page-card header {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
  margin-bottom: 12px;
}

.writing54-page-card header span {
  padding: 5px 9px;
  border-radius: 8px;
  background: var(--green-soft);
  color: #136c65;
  font-size: 12px;
  font-weight: 900;
}

.writing54-page-card header strong {
  color: var(--ink);
  font-size: 16px;
  line-height: 1.45;
}

.writing54-lines {
  display: grid;
  gap: 6px;
}

.writing54-line {
  margin: 0;
  color: var(--ink);
  font-size: 14px;
  line-height: 1.72;
  word-break: break-word;
}

.writing54-line.is-heading {
  margin-top: 8px;
  color: #136c65;
  font-size: 15px;
  font-weight: 900;
}

.writing54-line.is-numbered {
  color: #33524d;
  font-weight: 900;
}

.writing54-line.is-korean {
  color: #172724;
  font-weight: 750;
}

.writing54-line.is-chinese {
  color: var(--muted);
}

.practice-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 20px;
}

.question-card {
  padding: 24px;
}

.question-head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
  margin-bottom: 16px;
}

.pill {
  display: inline-flex;
  align-items: center;
  min-height: 32px;
  padding: 0 12px;
  border-radius: 8px;
  background: var(--green-soft);
  color: #136c65;
  font-size: 13px;
  font-weight: 800;
}

.pill.muted {
  background: #f4f7f6;
  color: var(--muted);
}

.timer-pill {
  background: #fff7e8;
  color: #8a5a16;
}

.timer-control {
  min-height: 32px;
  padding: 0 12px;
  border: 1px solid #e1c88f;
  border-radius: 8px;
  background: #fffaf0;
  color: #8a5a16;
  font-size: 13px;
  font-weight: 800;
  transition:
    transform 120ms ease,
    background-color 120ms ease,
    border-color 120ms ease;
}

.timer-control:not(:disabled):hover {
  background: #fff3d6;
  border-color: #d2a94c;
}

.timer-control:not(:disabled):active {
  transform: translateY(1px) scale(0.98);
}

.question-card h3 {
  margin: 0 0 18px;
  font-size: 25px;
  line-height: 1.45;
}

.question-media {
  margin: 0 0 18px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.question-media img {
  display: block;
  width: 100%;
  max-height: 560px;
  object-fit: contain;
}

.question-material-image {
  width: 100%;
  height: auto;
  display: block;
  object-fit: contain;
}

.question-group-instruction {
  margin: 0 0 10px;
  font-size: 17px;
  line-height: 1.6;
  font-weight: 700;
  color: var(--ink);
}

.question-number {
  margin: 0 0 12px;
  font-size: 18px;
  font-weight: 800;
  color: var(--ink);
}

.writing-prompt-image {
  width: 100%;
  height: auto;
  display: block;
  object-fit: contain;
}

.question-media img.writing-prompt-image {
  height: auto;
  max-height: none;
  object-fit: contain;
}

.question-audio {
  display: block;
  width: 100%;
  margin-bottom: 12px;
}

.question-passage {
  font-size: 17px;
  line-height: 1.85;
  color: var(--ink);
  white-space: pre-wrap;
}

.options {
  display: grid;
  gap: 10px;
}

.options:has(.image-option) {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.option {
  min-height: 52px;
  padding: 12px 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  color: var(--ink);
  display: flex;
  align-items: center;
  gap: 12px;
  text-align: left;
}

.option .letter {
  width: 30px;
  height: 26px;
  border-radius: 999px;
  display: grid;
  place-items: center;
  background: #f4f7f6;
  color: var(--muted);
  font-weight: 800;
}

.image-option {
  display: grid;
  grid-template-columns: 40px minmax(0, 1fr);
  align-items: start;
  padding: 10px;
}

.image-option img {
  display: block;
  width: 100%;
  max-height: 240px;
  object-fit: contain;
  border-radius: 6px;
  background: #f8fbfa;
}

.option.is-selected {
  border-color: var(--blue);
  background: var(--blue-soft);
}

.option:not(.is-selected):not(.is-correct):not(.is-wrong):not(:disabled):hover,
.vocab-quiz-option:not(.is-correct):not(.is-wrong):not(:disabled):hover {
  border-color: #9fc9ff;
  background: #f7faff;
}

.option.is-correct {
  border-color: var(--green);
  background: var(--green-soft);
}

.option.is-correct .letter {
  background: var(--green);
  color: #fff;
}

.option.is-wrong {
  border-color: var(--coral);
  background: var(--coral-soft);
}

.option.is-wrong .letter {
  background: var(--coral);
  color: #fff;
}

.fill-answer {
  min-height: 58px;
  padding: 12px 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  display: flex;
  align-items: center;
  gap: 12px;
}

.fill-answer.is-checked {
  background: #f8fbfa;
}

.fill-label {
  width: 34px;
  height: 30px;
  border-radius: 999px;
  display: grid;
  place-items: center;
  background: var(--green-soft);
  color: #136c65;
  font-weight: 900;
  flex: 0 0 auto;
}

.fill-answer input {
  width: 100%;
  min-width: 0;
  border: 0;
  outline: 0;
  color: var(--ink);
  font: inherit;
  background: transparent;
}

.fill-answer input::placeholder {
  color: var(--muted);
}

.essay-answer {
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  display: grid;
  gap: 10px;
}

.essay-answer span {
  font-weight: 900;
}

.essay-answer textarea {
  width: 100%;
  min-height: 190px;
  resize: vertical;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 12px;
  color: var(--ink);
  font: inherit;
  line-height: 1.7;
  outline: 0;
}

.essay-answer textarea:focus {
  border-color: var(--green);
  box-shadow: 0 0 0 3px var(--green-soft);
}

.essay-answer small {
  color: var(--muted);
}

.answer-panel {
  margin-top: 14px;
  padding: 16px 18px;
  border: 1px solid var(--green);
  border-radius: 8px;
  background: var(--green-soft);
  color: #34524b;
}

.answer-panel strong {
  color: #136c65;
}

.answer-panel .model-answer {
  color: var(--ink);
  line-height: 1.85;
  white-space: pre-wrap;
}

button:disabled {
  cursor: not-allowed;
  opacity: 0.45;
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 1ms !important;
    scroll-behavior: auto !important;
    transition-duration: 1ms !important;
  }
}

.practice-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 18px;
}

.action-feedback {
  min-height: 38px;
  margin-top: 12px;
  padding: 9px 12px;
  border: 1px solid #bfe9df;
  border-radius: 8px;
  background: #effbf7;
  color: #0d4f49;
  font-size: 14px;
  font-weight: 800;
  opacity: 0;
  transform: translateY(4px);
  transition:
    opacity 160ms ease,
    transform 160ms ease,
    background-color 160ms ease,
    border-color 160ms ease;
}

.action-feedback.is-visible {
  opacity: 1;
  transform: translateY(0);
}

.action-feedback.is-error {
  border-color: #f1b3aa;
  background: #fff4f2;
  color: #9d3024;
}

.selection-translator {
  position: fixed;
  z-index: 180;
  width: min(360px, calc(100vw - 24px));
  max-height: min(420px, calc(100dvh - 24px));
  overflow: auto;
  padding: 14px;
  border: 1px solid #b9dad3;
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 18px 46px rgba(23, 32, 38, 0.18);
}

.selection-translator h4 {
  margin: 0 0 4px;
  font-size: 16px;
}

.selection-translator .lookup-source {
  margin: 0 0 10px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.lookup-card {
  padding: 10px 0;
  border-top: 1px solid #edf3f1;
}

.lookup-card:first-of-type {
  border-top: 0;
  padding-top: 0;
}

.lookup-card-source-hanxiaoban {
  margin: 4px 0;
  padding: 10px;
  border: 1px solid #b9dad3;
  border-radius: 8px;
  background: #f3fbf8;
}

.lookup-card strong {
  display: block;
  color: #136c65;
}

.lookup-card p {
  margin: 5px 0 0;
  color: var(--ink);
  line-height: 1.55;
}

.lookup-card small {
  display: block;
  margin-top: 5px;
  color: var(--muted);
  line-height: 1.45;
}

.lookup-meta {
  display: block;
  margin-top: 10px;
  color: var(--muted);
  font-size: 11px;
  line-height: 1.4;
  word-break: break-all;
}

.lookup-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 10px;
}

.lookup-audio-btn,
.lookup-close-btn {
  min-height: 32px;
  padding: 0 10px;
  border: 1px solid #b9dad3;
  border-radius: 8px;
  background: var(--green-soft);
  color: #136c65;
  font-size: 12px;
  font-weight: 900;
}

.lookup-close-btn {
  margin-left: auto;
  background: #fff;
  color: var(--ink);
  border-color: var(--line);
}

.lookup-empty {
  margin: 0;
  color: var(--muted);
  line-height: 1.55;
}

.mistake-tools {
  margin: 0 0 14px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
}

.mistake-filter-btn {
  min-height: 36px;
  padding: 0 12px;
  border: 1px solid #c9d6d2;
  border-radius: 8px;
  background: #fff;
  color: var(--ink);
  font-weight: 850;
  transition:
    transform 160ms ease,
    box-shadow 160ms ease,
    border-color 160ms ease,
    background-color 160ms ease;
}

.mistake-filter-btn:hover {
  transform: translateY(-1px);
  box-shadow: var(--hover-shadow);
}

.mistake-filter-btn.is-active {
  border-color: var(--green);
  background: var(--green-soft);
  color: #136c65;
}

.mistake-card.is-important {
  border-color: #f1b3aa;
  background: #fff8f6;
}

.mistake-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 8px 0;
}

.mistake-meta span {
  padding: 5px 8px;
  border-radius: 999px;
  background: #eef7f4;
  color: #136c65;
  font-size: 12px;
  font-weight: 900;
}

.mistake-meta .is-important {
  background: var(--coral-soft);
  color: #9d3024;
}

.mock-shell {
  display: grid;
  grid-template-columns: 1fr;
  gap: 16px;
  align-items: start;
}

.mock-reading-shell {
  max-width: 1120px;
  margin: 0 auto;
}

.mock-exam-toolbar {
  position: sticky;
  top: 12px;
  z-index: 5;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 18px;
  align-items: center;
  padding: 16px 18px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.96);
  box-shadow: 0 10px 30px rgba(31, 45, 51, 0.08);
  backdrop-filter: blur(12px);
}

.mock-exam-options,
.mock-session-options {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 14px;
  margin-top: 18px;
}

.mock-exam-option {
  position: relative;
  min-height: 124px;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  color: var(--ink);
  font-weight: 900;
  text-align: left;
  cursor: pointer;
  box-shadow: 0 10px 22px rgba(31, 45, 51, 0.05);
  transition: border-color 0.18s ease, box-shadow 0.18s ease, transform 0.18s ease;
}

.mock-exam-option::before {
  content: "";
  position: absolute;
  top: 18px;
  right: 18px;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--mint-strong);
}

.mock-exam-option strong,
.mock-exam-option span {
  display: block;
}

.mock-exam-option strong {
  font-size: 28px;
  line-height: 1.15;
  letter-spacing: 0;
}

.mock-exam-option span {
  margin-top: 8px;
  color: var(--muted);
  font-size: 14px;
}

.mock-exam-option em {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin-top: 18px;
  padding: 9px 14px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: #f7fbf9;
  color: var(--ink);
  font-style: normal;
  font-size: 14px;
  text-align: center;
}

.mock-exam-option:hover {
  border-color: rgba(0, 116, 99, 0.28);
  transform: translateY(-1px);
  box-shadow: 0 16px 28px rgba(31, 45, 51, 0.09);
}

.mock-exam-option.is-active {
  border-color: rgba(0, 116, 99, 0.34);
  background: #f6fbf8;
}

.mock-panel,
.mock-answer-sheet,
.mock-paper {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.mock-panel,
.mock-answer-sheet {
  padding: 16px;
}

.mock-panel {
  position: static;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto auto;
  gap: 16px;
  align-items: center;
}

.mock-panel-head {
  margin-bottom: 12px;
}

.mock-panel-head strong {
  display: block;
  font-size: 18px;
}

.mock-section-tabs {
  display: grid;
  gap: 8px;
}

.mock-section-tab {
  width: 100%;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  color: var(--ink);
  text-align: left;
  transition:
    transform 160ms ease,
    border-color 160ms ease,
    background-color 160ms ease;
}

.mock-section-tab:hover {
  transform: translateY(-1px);
  border-color: var(--green);
}

.mock-section-tab.is-active {
  border-color: var(--green);
  background: var(--green-soft);
}

.mock-section-tab strong,
.mock-section-tab span {
  display: block;
}

.mock-section-tab span,
.mock-note {
  color: var(--muted);
  font-size: 13px;
}

.mock-timer-card {
  margin-top: 0;
  padding: 14px;
  border: 1px solid #d8e7e2;
  border-radius: 8px;
  background: #f8fbfa;
}

.mock-timer-card span,
.mock-timer-card strong {
  display: block;
}

.mock-timer-card strong {
  margin-top: 4px;
  font-size: 32px;
}

.mock-timer-actions,
.mock-page-nav {
  display: flex;
  gap: 8px;
  align-items: center;
  margin-top: 10px;
}

.mock-timer-actions button,
.mock-page-nav button {
  flex: 1;
}

.mock-audio {
  width: 100%;
  margin-top: 14px;
}

.mock-audio-panel {
  display: grid;
  gap: 8px;
  margin-top: 14px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fbfdfc;
}

.mock-audio-panel audio {
  width: 100%;
}

.mock-audio-panel a {
  color: #136c65;
  font-size: 13px;
  font-weight: 900;
}

.mock-page-nav span {
  min-width: 64px;
  text-align: center;
  color: var(--muted);
  font-weight: 900;
}

.mock-paper {
  padding: 22px;
}

.mock-scroll-summary {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  margin-bottom: 18px;
  color: var(--muted);
  font-weight: 900;
}

.mock-reading-list {
  display: grid;
  gap: 18px;
}

.mock-page-frame {
  margin: 0;
  display: grid;
  place-items: center;
}

.mock-page-frame img {
  width: 100%;
  border: 1px solid #edf3f1;
  border-radius: 8px;
  background: #fff;
}

.mock-answer-grid {
  display: grid;
  gap: 10px;
  max-height: calc(100dvh - 180px);
  overflow: auto;
  padding-right: 4px;
}

.mock-choice-row {
  margin: 0;
  padding: 8px;
  border: 1px solid #edf3f1;
  border-radius: 8px;
  display: grid;
  grid-template-columns: 34px repeat(4, minmax(0, 1fr));
  gap: 6px;
  align-items: center;
}

.mock-choice-row legend {
  padding: 0;
  color: var(--ink);
  font-weight: 900;
}

.mock-choice-row label {
  min-height: 30px;
  border-radius: 8px;
  display: grid;
  place-items: center;
  background: #f5f8f7;
  color: var(--muted);
  font-weight: 900;
}

.mock-choice-row input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.mock-choice-row label.is-selected {
  background: var(--green);
  color: #fff;
}

.mock-writing-answer {
  display: grid;
  gap: 6px;
  color: var(--ink);
  font-weight: 900;
}

.mock-writing-answer textarea {
  min-height: 110px;
  resize: vertical;
  padding: 10px;
  border: 1px solid #c9d6d2;
  border-radius: 8px;
  font: inherit;
  line-height: 1.6;
}

.mock-reading-card {
  display: grid;
  gap: 16px;
  scroll-margin-top: 120px;
  padding: 22px;
  border: 1px solid #dbe8e4;
  border-radius: 8px;
  background: #fff;
}

.mock-reading-list [data-mock-question-card] > .question-head,
.mock-reading-list [data-mock-question-card] > .pill,
.mock-reading-list [data-mock-question-card] .question-head .pill {
  display: none !important;
}

.mock-question-text {
  margin: 0;
  min-height: 0;
  padding: 22px;
  border: 1px solid #edf3f1;
  border-radius: 8px;
  background: #fbfdfc;
  color: var(--ink);
  font-family: "Noto Sans KR", "Microsoft YaHei", system-ui, sans-serif;
  font-size: 20px;
  line-height: 1.9;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}

.given-sentence-box,
.passage-box,
.mock-shared-passage-box {
  margin: 0;
  padding: 12px 16px;
  border: 1px solid #222;
  border-radius: 6px;
  background: #fff;
  color: var(--ink);
  font-family: "Noto Sans KR", "Microsoft YaHei", system-ui, sans-serif;
  font-size: 19px;
  line-height: 1.8;
  overflow-wrap: anywhere;
}

.passage-box,
.mock-shared-passage-box {
  white-space: pre-line;
}

.mock-unstructured-note {
  margin: -6px 0 0;
  padding: 10px 12px;
  border: 1px dashed #c9d6d2;
  border-radius: 8px;
  background: #fbfdfc;
  color: var(--muted);
  font-size: 14px;
  font-weight: 700;
}

.mock-writing-image-card .mock-unstructured-note {
  display: none;
}

.mock-reference-tools {
  display: flex;
  justify-content: flex-start;
}

.mock-reference-answer {
  display: grid;
  gap: 8px;
  padding: 14px 16px;
  border: 1px solid var(--green);
  border-radius: 8px;
  background: #f4fbf8;
}

.mock-reference-answer strong {
  color: #136c65;
}

.mock-reference-answer p {
  margin: 0;
  line-height: 1.85;
  white-space: pre-wrap;
}

.mock-submit-panel {
  display: grid;
  gap: 16px;
  padding: 22px;
  border: 1px solid #cfe1dc;
  border-radius: 8px;
  background: #ffffff;
}

.mock-submit-head {
  display: flex;
  gap: 16px;
  align-items: center;
  justify-content: space-between;
}

.mock-submit-head h3,
.mock-submit-head p {
  margin: 0;
}

.mock-submit-head p {
  margin-top: 6px;
  color: var(--muted);
  line-height: 1.6;
}

.mock-score-card {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 18px;
  align-items: center;
  padding: 14px 16px;
  border: 1px solid var(--green);
  border-radius: 8px;
  background: #f4fbf8;
  color: #136c65;
}

.mock-result-table {
  display: grid;
  overflow: hidden;
  border: 1px solid #dbe8e4;
  border-radius: 8px;
}

.mock-result-row {
  display: grid;
  grid-template-columns: 80px repeat(3, minmax(0, 1fr));
  gap: 10px;
  padding: 10px 12px;
  border-top: 1px solid #edf3f1;
  color: var(--ink);
}

.mock-result-row:first-child {
  border-top: 0;
}

.mock-result-row-head {
  background: #f6faf8;
  color: #51625e;
  font-weight: 900;
}

.mock-result-row.is-correct {
  background: #f2fbf6;
}

.mock-result-row.is-wrong {
  background: #fff5f2;
}

.mock-result-row.is-pending {
  color: #66736f;
}

.text-unit-inline {
  display: grid;
  gap: 10px;
  margin-top: 10px;
}

.transcript-unit-list {
  display: grid;
  gap: 12px;
}

.transcript-unit-line {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 10px;
  align-items: start;
}

.transcript-speaker {
  color: var(--ink);
  font-weight: 900;
  line-height: 32px;
  white-space: nowrap;
}

.transcript-plain {
  color: var(--ink);
  line-height: 1.7;
}

.text-unit-list {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.text-unit-chip {
  min-height: 32px;
  padding: 4px 10px;
  border: 1px solid #b9dad3;
  border-radius: 8px;
  background: #eef8f5;
  color: #136c65;
  font: inherit;
  font-weight: 900;
  transition:
    transform 160ms ease,
    background-color 160ms ease,
    border-color 160ms ease;
}

.text-unit-chip:hover {
  transform: translateY(-1px);
  border-color: var(--green);
  background: #def4ee;
}

.mock-question-media {
  display: grid;
  gap: 16px;
}

.mock-question-figure {
  margin: 0;
  padding: 14px;
  border: 1px solid #edf3f1;
  border-radius: 8px;
  background: #fff;
}

.mock-question-figure img {
  display: block;
  width: 100%;
  height: auto;
  border-radius: 6px;
}

.mock-reading-group-card {
  gap: 18px;
}

.mock-reading-group-items {
  display: grid;
  gap: 28px;
}

.mock-reading-group-item {
  display: grid;
  gap: 14px;
}

.mock-leading-group-instruction {
  padding-top: 18px;
  padding-bottom: 18px;
}

.mock-leading-group-instruction .question-group-instruction {
  margin-bottom: 0;
}

.mock-inline-options {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.mock-inline-option {
  min-height: 54px;
  display: grid;
  grid-template-columns: 34px minmax(0, 1fr);
  gap: 10px;
  align-items: center;
  text-align: left;
  padding: 12px 14px;
  border: 1px solid #c9d6d2;
  border-radius: 8px;
  background: #fff;
  color: var(--ink);
  font-size: 17px;
  font-weight: 800;
  line-height: 1.55;
  transition:
    transform 160ms ease,
    border-color 160ms ease,
    background-color 160ms ease,
    color 160ms ease;
}

.mock-option-index {
  width: 30px;
  height: 30px;
  display: grid;
  place-items: center;
  border-radius: 8px;
  background: #eef8f5;
  color: var(--green-dark);
}

.mock-inline-option:hover {
  transform: translateY(-1px);
  border-color: var(--green);
}

.mock-inline-option.is-selected {
  border-color: var(--green);
  background: var(--green);
  color: #fff;
}

.mock-inline-option.is-correct {
  border-color: #18a56f;
  background: #e9fbf3;
  color: #0c6b49;
}

.mock-inline-option.is-wrong {
  border-color: #ef7b73;
  background: #fff1ef;
  color: #9e2b24;
}

.mock-single-question {
  align-content: start;
}

.mock-question-section {
  display: grid;
  gap: 10px;
}

.mock-section-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.mock-question-section-label {
  margin: 0;
  color: var(--green-dark);
  font-size: 13px;
  font-weight: 900;
}

.mock-transcript-text {
  margin: 0;
  white-space: pre-wrap;
  color: var(--ink);
  line-height: 1.75;
}

.mock-question-prompt {
  margin: 0;
  color: var(--ink);
  font-size: 20px;
  line-height: 1.6;
}

.mock-question-audio-btn {
  width: fit-content;
}

.mock-letter-options {
  grid-template-columns: 1fr;
}

.mock-answer-feedback {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 16px;
  align-items: center;
  justify-content: space-between;
  padding: 12px 14px;
  border-radius: 8px;
  background: #f7fbfa;
  color: var(--muted);
  font-weight: 800;
}

.mock-answer-feedback.is-correct {
  background: #e9fbf3;
  color: #0c6b49;
}

.mock-answer-feedback.is-wrong {
  background: #fff5ef;
  color: #9b3b18;
}

.mock-group-answer-list {
  display: grid;
  gap: 10px;
}

.mock-group-answer-row {
  display: grid;
  grid-template-columns: 86px minmax(0, 1fr);
  gap: 12px;
  align-items: center;
  padding: 10px 12px;
  border: 1px solid #edf3f1;
  border-radius: 8px;
  background: #fbfdfc;
}

.compact-options {
  grid-template-columns: repeat(4, minmax(54px, 1fr));
}

.compact-options .mock-inline-option {
  min-height: 42px;
  grid-template-columns: 1fr;
  place-items: center;
  padding: 8px;
}

.mock-question-list-panel .mock-answer-grid {
  grid-template-columns: repeat(5, minmax(0, 1fr));
}

.mock-question-jump {
  min-height: 42px;
  border: 1px solid #d8e7e2;
  border-radius: 8px;
  background: #fff;
  color: var(--ink);
  font-weight: 900;
  display: grid;
  place-items: center;
  gap: 2px;
}

.mock-question-jump.is-current {
  border-color: var(--green);
  background: var(--green-soft);
  color: #136c65;
}

.mock-question-jump.is-done strong {
  color: var(--green);
  font-size: 11px;
}

.mock-explanation-modal {
  position: fixed;
  inset: 0;
  z-index: 130;
  display: grid;
  place-items: center;
  padding: 18px;
}

.mock-explanation-backdrop {
  position: absolute;
  inset: 0;
  border: 0;
  background: rgba(23, 32, 38, 0.46);
}

.mock-explanation-card {
  position: relative;
  width: min(560px, 100%);
  max-height: min(760px, calc(100vh - 36px));
  overflow: auto;
  padding: 20px;
  border: 1px solid #dbe8e4;
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 24px 70px rgba(23, 32, 38, 0.24);
}

.mock-explanation-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding-bottom: 12px;
  border-bottom: 1px solid #edf3f1;
}

.mock-explanation-head h3 {
  margin: 0;
  font-size: 18px;
}

.mock-explanation-body {
  display: grid;
  gap: 12px;
  padding-top: 14px;
}

.mock-explanation-block {
  display: grid;
  gap: 8px;
  padding: 12px;
  border-radius: 8px;
  background: #f7fbfa;
}

.mock-explanation-block h4,
.mock-explanation-block p {
  margin: 0;
}

.mock-explanation-block h4 {
  color: var(--green-dark);
  font-size: 14px;
}

.mock-explanation-block p {
  color: var(--ink);
  line-height: 1.75;
  white-space: pre-wrap;
}

.mock-transcript-block {
  padding: 0;
  background: transparent;
}

.mock-transcript-block h4 {
  color: var(--ink);
  font-size: 15px;
}

.mock-start-modal {
  position: fixed;
  inset: 0;
  z-index: 120;
  display: grid;
  place-items: center;
  padding: 24px;
}

.mock-start-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(23, 32, 38, 0.52);
}

.mock-start-card {
  position: relative;
  width: min(520px, 100%);
  padding: 70px 34px 28px;
  border-radius: 8px;
  background: linear-gradient(180deg, #d8ccff 0%, #fff 48%);
  box-shadow: 0 24px 70px rgba(23, 32, 38, 0.28);
  text-align: center;
}

.mock-mascot {
  position: absolute;
  top: -32px;
  left: 50%;
  transform: translateX(-50%);
  width: 112px;
  height: 76px;
  border-radius: 999px 999px 18px 18px;
  background: #fff;
  color: #8d73f6;
  display: grid;
  place-items: center;
  font-weight: 950;
  box-shadow: 0 12px 28px rgba(141, 115, 246, 0.24);
}

.mock-start-card h3 {
  margin: 0;
  font-size: 26px;
}

.mock-start-time {
  margin: 20px 0 8px;
  color: var(--ink);
  font-size: 18px;
  font-weight: 900;
}

.mock-start-note {
  margin: 0;
  color: var(--muted);
  line-height: 1.8;
}

.mock-start-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
  margin-top: 28px;
}

.mistake-list {
  display: grid;
  gap: 10px;
}

.mistake-card {
  padding: 12px 14px;
  border-radius: 8px;
  background: #f6faf8;
}

.mistake-card strong {
  display: block;
  margin-bottom: 4px;
  color: #136c65;
  font-size: 13px;
}

.mistake-card {
  background: #fff;
  padding: 18px;
}

.empty-state {
  min-height: 220px;
  border: 1px dashed #c9d6d2;
  border-radius: 8px;
  display: grid;
  place-content: center;
  color: var(--muted);
  text-align: center;
}

.empty-test {
  min-height: 220px;
  border: 1px dashed #c9d6d2;
  border-radius: 8px;
  background: #fff;
  display: grid;
  place-content: center;
  padding: 28px;
  text-align: center;
}

.empty-test h3 {
  margin: 0 0 8px;
  font-size: 24px;
}

.empty-test p {
  margin: 0;
  color: var(--muted);
  max-width: 520px;
}

.vocab-hero {
  margin-bottom: 18px;
  padding: 22px 24px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  display: flex;
  justify-content: space-between;
  gap: 20px;
  align-items: center;
}

.vocab-hero h3 {
  margin: 0;
  font-size: 28px;
}

.vocab-hero p {
  margin: 8px 0 0;
  color: var(--muted);
}

.vocab-meta {
  min-width: 180px;
  padding: 16px 18px;
  border-radius: 8px;
  background: var(--blue-soft);
  color: #2946a8;
  display: grid;
  gap: 4px;
}

.vocab-meta strong {
  font-size: 28px;
  line-height: 1.1;
}

.vocab-meta span {
  font-size: 13px;
  font-weight: 700;
}

.vocab-panel {
  margin-bottom: 18px;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.vocab-panel-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 16px;
  margin-bottom: 14px;
}

.vocab-panel-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 10px;
}

.vocab-panel-head h3 {
  margin: 0;
  font-size: 22px;
}

.vocab-panel-head p {
  margin: 6px 0 0;
  color: var(--muted);
}

.vocab-levels,
.vocab-units {
  display: grid;
  gap: 10px;
}

.vocab-levels {
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  margin-bottom: 12px;
}

.vocab-units {
  grid-template-columns: repeat(auto-fit, minmax(130px, 1fr));
}

.vocab-level-btn,
.vocab-unit-btn {
  width: 100%;
  min-width: 0;
  padding: 12px 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #f9fcfb;
  color: var(--ink);
  text-align: left;
}

.vocab-level-btn strong,
.vocab-level-btn span,
.vocab-unit-btn strong,
.vocab-unit-btn span {
  display: block;
}

.vocab-level-btn strong,
.vocab-unit-btn strong {
  font-size: 15px;
  font-weight: 900;
}

.vocab-level-btn span,
.vocab-unit-btn span {
  margin-top: 4px;
  color: var(--muted);
  font-size: 12px;
}

.vocab-level-btn.is-active {
  background: var(--ink);
  border-color: var(--ink);
  color: #fff;
}

.vocab-level-btn.is-active span {
  color: #b9c8c3;
}

.vocab-unit-btn {
  background: #fff;
}

.vocab-unit-btn.is-active {
  background: var(--green-soft);
  border-color: var(--green);
  box-shadow: inset 0 0 0 1px var(--green);
}

.vocab-layout {
  display: grid;
  gap: 14px;
}

.vocab-card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  gap: 14px;
}

.vocab-card {
  min-height: 168px;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  display: grid;
  gap: 10px;
}

.vocab-card.is-known {
  border-color: #bfe9df;
  background: #f3fff9;
}

.vocab-card-head strong,
.vocab-card-head span {
  display: block;
}

.vocab-card-head strong {
  font-size: 18px;
}

.vocab-card-head span {
  margin-top: 4px;
  color: #136c65;
  font-size: 13px;
  font-weight: 800;
}

.vocab-example-ko,
.vocab-example-zh {
  margin: 0;
  line-height: 1.7;
}

.vocab-example-zh {
  color: var(--muted);
  font-size: 13px;
}

.vocab-audio-player {
  width: 100%;
  margin: 0 0 10px;
}

.vocab-audio-status {
  margin: -2px 0 14px;
  color: var(--muted);
  font-size: 13px;
}

.vocab-audio-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: auto;
}

.vocab-audio-chip {
  min-height: 34px;
  padding: 0 10px;
  border: 1px solid #b9dad3;
  border-radius: 8px;
  background: var(--green-soft);
  color: #136c65;
  font-size: 13px;
  font-weight: 900;
}

.vocab-audio-chip:disabled {
  cursor: not-allowed;
  opacity: 0.45;
}

.vocab-study-panel {
  margin: 16px 0;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.vocab-study-top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
}

.vocab-study-top h3 {
  margin: 2px 0 6px;
  font-size: 22px;
}

.vocab-study-top p {
  margin: 0;
  color: var(--muted);
}

.vocab-progress {
  min-width: 76px;
  padding: 8px 12px;
  border: 1px solid #bfe9df;
  border-radius: 8px;
  background: var(--green-soft);
  color: #136c65;
  font-weight: 900;
  text-align: center;
}

.vocab-study-filters {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 16px 0;
}

.vocab-study-card {
  border: 1px solid #d7e4df;
  border-radius: 8px;
  background: #fbfefd;
}

.vocab-study-question {
  display: grid;
  gap: 14px;
  padding: 18px;
}

.vocab-study-word-row {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
}

.vocab-study-count {
  margin: 0 0 6px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
}

.vocab-study-word {
  margin: 0;
  font-size: 36px;
  line-height: 1.15;
}

.vocab-study-pron {
  margin: 6px 0 0;
  color: var(--muted);
  font-size: 14px;
}

.vocab-sound-btn {
  min-width: 74px;
  min-height: 42px;
  padding: 0 14px;
  border: 1px solid #b9dad3;
  border-radius: 8px;
  background: var(--green-soft);
  color: #136c65;
  font-weight: 900;
}

.vocab-sound-btn:disabled {
  cursor: not-allowed;
  opacity: 0.45;
}

.vocab-meaning-box {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  min-height: 54px;
  padding: 12px;
  border: 1px dashed #cbd8d4;
  border-radius: 8px;
  background: #fff;
  color: var(--muted);
}

.vocab-meaning-box.is-visible {
  border-style: solid;
  background: #f1fffb;
  color: #0d4f49;
  font-weight: 900;
}

.vocab-quiz-options {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.vocab-quiz-option {
  min-height: 48px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  color: var(--ink);
  font-weight: 800;
  text-align: left;
}

.vocab-quiz-option.is-correct {
  border-color: #1fa37a;
  background: #eafbf3;
  color: #075c44;
}

.vocab-quiz-option.is-wrong {
  border-color: #e47b7b;
  background: #fff0f0;
  color: #9d2424;
}

.vocab-feedback {
  margin: 0;
  padding: 10px 12px;
  border-radius: 8px;
  font-weight: 900;
}

.vocab-feedback.is-correct {
  background: #eafbf3;
  color: #075c44;
}

.vocab-feedback.is-wrong {
  background: #fff0f0;
  color: #9d2424;
}

.vocab-study-example,
.vocab-study-example-zh {
  margin: 0;
  line-height: 1.7;
}

.vocab-study-example {
  padding-top: 4px;
  border-top: 1px solid #e1ece8;
}

.vocab-study-example-zh {
  color: var(--muted);
  font-size: 13px;
}

.vocab-study-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.vocab-study-actions .secondary-btn.is-active {
  border-color: #1fa37a;
  background: #eafbf3;
  color: #075c44;
}

.vocab-study-mini-stats,
.vocab-study-stats {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.vocab-study-mini-stats span,
.vocab-study-stats span {
  padding: 6px 10px;
  border-radius: 999px;
  background: #eef7f4;
  color: #136c65;
  font-size: 12px;
  font-weight: 900;
}

.vocab-study-empty,
.vocab-study-finished {
  padding: 28px;
  color: var(--muted);
  text-align: center;
}

.vocab-study-finished h4 {
  margin: 0 0 12px;
  color: var(--ink);
  font-size: 22px;
}

.vocab-empty {
  min-height: 180px;
  padding: 24px;
  border: 1px dashed #cfdad6;
  border-radius: 8px;
  background: #fbfefd;
  color: var(--muted);
  display: grid;
  place-items: center;
  text-align: center;
}

.vocab-empty-mini {
  padding: 12px 14px;
  border: 1px dashed #d9e4e0;
  border-radius: 8px;
  background: #fbfefd;
  color: var(--muted);
}

@media (min-width: 861px) and (max-width: 1180px) {
  .app-shell {
    grid-template-columns: 220px 1fr;
  }

  .app-sidebar {
    width: 220px;
    padding: 24px 18px;
  }

  .app-main {
    padding: 28px 28px;
  }

  .brand-block h1 {
    font-size: 20px;
  }

  .topbar {
    flex-wrap: wrap;
  }

  .practice-layout {
    grid-template-columns: 1fr;
  }

  .mock-shell {
    grid-template-columns: 1fr;
  }

  .mock-panel {
    grid-template-columns: 1fr;
  }

  .mock-exam-toolbar {
    position: static;
    grid-template-columns: 1fr;
  }

  .mock-panel,
  .mock-answer-sheet {
    position: static;
  }

  .vocab-card-grid {
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  }
}

@media (max-width: 860px) {
  body.nav-open {
    overflow: hidden;
  }

  .app-shell {
    display: block;
    min-height: 100vh;
  }

  .mobile-header {
    position: sticky;
    top: 0;
    z-index: 50;
    min-height: 60px;
    padding: 10px 14px;
    border-bottom: 1px solid var(--line);
    background: rgba(246, 250, 248, 0.96);
    backdrop-filter: blur(14px);
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
  }

  .mobile-brand {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    min-width: 0;
    font-weight: 900;
  }

  .mobile-brand .brand-mark {
    width: 36px;
    height: 36px;
    flex: 0 0 auto;
  }

  .mobile-menu-toggle {
    width: 42px;
    height: 42px;
    padding: 0;
    border: 1px solid #c9d6d2;
    border-radius: 8px;
    background: #fff;
    display: inline-grid;
    place-content: center;
    gap: 5px;
  }

  .mobile-menu-toggle span {
    width: 18px;
    height: 2px;
    border-radius: 999px;
    background: var(--ink);
    display: block;
  }

  .mobile-nav-backdrop {
    position: fixed;
    inset: 0;
    z-index: 55;
    background: rgba(23, 32, 38, 0.42);
    display: block;
  }

  .app-sidebar {
    position: fixed;
    inset: 0 auto 0 0;
    z-index: 60;
    width: min(82vw, 320px);
    height: 100dvh;
    padding: 24px 20px;
    transform: translateX(-104%);
    transition: none;
    box-shadow: 18px 0 36px rgba(23, 32, 38, 0.22);
    display: flex;
    overflow-y: auto;
  }

  body.nav-open .app-sidebar {
    transform: translateX(0);
  }

  .app-main {
    grid-column: auto;
    width: 100%;
    padding: 20px 14px 84px;
  }

  .topbar {
    flex-direction: column;
    align-items: flex-start;
    gap: 14px;
  }

  .topbar h2 {
    font-size: 27px;
  }

  .topbar p {
    font-size: 13px;
  }

  .top-actions {
    width: 100%;
    flex-wrap: wrap;
    justify-content: stretch;
  }

  .top-actions button {
    flex: 1 1 140px;
  }

  .hero-panel {
    grid-template-columns: 1fr;
    min-height: 0;
    padding: 18px;
  }

  .study-visual {
    display: none;
  }

  .hero-panel h3 {
    font-size: 26px;
  }

  .metric-grid,
  .report-grid,
  .report-lists,
  .topic-grid,
  .vocab-card-grid,
  .grammar-grid,
  .prep-grid,
  .breakdown-list,
  .word-grid,
  .idiom-row,
  .slide-grid,
  .options:has(.image-option),
  .practice-layout {
    grid-template-columns: 1fr;
  }

  .type-tab {
    min-width: 136px;
  }

  .metric-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .type-tabs,
  .vocab-levels,
  .vocab-units {
    display: flex;
    overflow-x: auto;
    padding-bottom: 6px;
    scroll-snap-type: x proximity;
  }

  .type-tab,
  .vocab-level-btn,
  .vocab-unit-btn {
    flex: 0 0 76%;
    scroll-snap-align: start;
  }

  .vocab-level-btn {
    flex-basis: 44%;
  }

  .vocab-hero {
    flex-direction: column;
    align-items: flex-start;
    padding: 18px;
  }

  .vocab-meta {
    min-width: 0;
    width: 100%;
  }

  .vocab-panel-head {
    flex-direction: column;
  }

  .vocab-panel-actions {
    width: 100%;
    justify-content: stretch;
  }

  .vocab-panel-actions .secondary-btn {
    flex: 1 1 160px;
  }

  .vocab-study-top,
  .vocab-study-word-row,
  .vocab-meaning-box {
    align-items: stretch;
    flex-direction: column;
  }

  .vocab-progress,
  .vocab-sound-btn {
    width: 100%;
  }

  .vocab-study-word {
    font-size: 30px;
  }

  .vocab-quiz-options {
    grid-template-columns: 1fr;
  }

  .vocab-card-grid {
    grid-template-columns: 1fr;
  }

  .question-card {
    padding: 18px;
  }

  .question-head {
    gap: 8px;
  }

  .question-card h3 {
    font-size: 20px;
  }

  .options,
  .writing-fill-list {
    grid-template-columns: 1fr;
  }

  .question-media {
    overflow-x: auto;
  }

  .practice-actions {
    position: sticky;
    bottom: 12px;
    background: var(--soft);
    padding-top: 10px;
  }

  .practice-actions button,
  .top-actions button {
    flex: 1;
  }

  .mock-answer-grid {
    max-height: none;
  }

  .mock-choice-row {
    grid-template-columns: 32px repeat(4, minmax(38px, 1fr));
  }

  .mock-paper {
    padding: 12px;
  }

  .mock-question-text {
    padding: 18px;
    font-size: 18px;
    line-height: 1.9;
  }

  .mock-inline-options {
    grid-template-columns: 1fr;
    gap: 10px;
  }

  .mock-inline-option {
    min-height: 56px;
  }

  .mock-start-card {
    padding: 62px 20px 22px;
  }

  .mock-start-actions {
    gap: 12px;
  }
}

@media (max-width: 520px) {
  .app-main {
    padding-inline: 10px;
  }

  .topbar h2 {
    font-size: 24px;
  }

  .hero-panel,
  .vocab-hero,
  .vocab-panel,
  .vocab-study-panel,
  .prep-panel,
  .question-card,
  .metric-grid {
    grid-template-columns: 1fr;
  }

  .type-tab,
  .vocab-unit-btn {
    flex-basis: 88%;
  }

  .vocab-level-btn {
    flex-basis: 58%;
  }

  .practice-actions {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 760px) {
  .must-filterbar {
    grid-template-columns: 1fr;
  }

  .must-tabbar {
    gap: 8px;
  }

  .must-tab {
    min-height: 40px;
    padding: 0 13px;
    font-size: 14px;
  }

  .must-table {
    min-width: 640px;
  }
}
