:root {
  color-scheme: light;
  --ink: #1a2c2b;
  --muted: #5f6d6a;
  --line: #d6dfda;
  --paper: #f3f5ef;
  --white: #fdfefb;
  --teal: #11736d;
  --amber: #cc8926;
  --coral: #d46655;
  --charcoal: #203532;
  --shadow: 0 14px 40px rgba(32, 53, 50, 0.08);
}

* {
  box-sizing: border-box;
}

[hidden] {
  display: none !important;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: -apple-system, BlinkMacSystemFont, "SF Pro Text", "PingFang SC",
    "Microsoft YaHei", "Segoe UI", sans-serif;
  background: var(--paper);
  color: var(--ink);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

.language-switcher {
  position: fixed;
  top: 18px;
  right: 22px;
  z-index: 1000;
  display: inline-grid;
  grid-template-columns: 1fr 1fr;
  padding: 3px;
  border: 1px solid rgba(255, 255, 255, 0.55);
  border-radius: 6px;
  background: rgba(19, 33, 32, 0.76);
  box-shadow: 0 8px 22px rgba(19, 33, 32, 0.15);
  backdrop-filter: blur(10px);
}

.language-switcher button {
  min-width: 78px;
  min-height: 36px;
  border: 0;
  border-radius: 4px;
  background: transparent;
  color: rgba(255, 255, 255, 0.78);
  font: inherit;
  font-size: 13px;
  font-weight: 800;
  cursor: pointer;
}

.language-switcher button.active {
  background: #ffffff;
  color: #127f79;
}

@media (max-width: 720px) {
  .language-switcher {
    top: 10px;
    right: 10px;
  }

  .language-switcher button {
    min-width: 66px;
    min-height: 32px;
    font-size: 12px;
  }
}

button,
input {
  font: inherit;
}

button {
  cursor: pointer;
}

button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible {
  outline: 3px solid rgba(17, 115, 109, 0.2);
  outline-offset: 2px;
}

::selection {
  background: rgba(204, 137, 38, 0.24);
}

.app-shell {
  min-height: 100vh;
  padding-bottom: 36px;
}

.site-footer {
  border-top: 1px solid var(--line);
  background: var(--paper);
  color: var(--muted);
  font-size: 14px;
  line-height: 1.5;
  padding: 24px 16px 30px;
  text-align: center;
}

.hero {
  position: relative;
  min-height: clamp(720px, 78vh, 900px);
  overflow: hidden;
  color: var(--white);
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  padding: 22px clamp(18px, 4vw, 56px) 54px;
}

.hero-media,
.hero-overlay {
  position: absolute;
  inset: 0;
}

.hero-media {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
}

.hero-overlay {
  background:
    linear-gradient(90deg, rgba(10, 17, 17, 0.78) 0%, rgba(10, 17, 17, 0.34) 36%, rgba(10, 17, 17, 0.12) 64%, rgba(10, 17, 17, 0.5) 100%),
    linear-gradient(0deg, rgba(10, 17, 17, 0.74) 0%, rgba(10, 17, 17, 0) 38%);
}

.topbar,
.hero-main {
  position: relative;
  z-index: 1;
}

.topbar {
  display: flex;
  min-height: 61px;
  align-items: center;
  justify-content: flex-end;
  gap: 16px;
  padding-bottom: 18px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.22);
}

.nav-actions,
.hero-actions,
.panel-heading,
.coach-input,
.metric-strip,
.upload-grid {
  display: flex;
  align-items: center;
}

.nav-actions,
.hero-actions {
  gap: 10px;
}

.hero-main {
  width: 100%;
  flex: 1;
  display: grid;
  grid-template-columns: 1fr;
  align-items: start;
  padding-top: clamp(16px, 2vh, 24px);
}

.hero-content {
  width: min(940px, 100%);
  max-width: none;
  margin: 0 auto;
  text-align: center;
  transform: translateY(-1cm);
}

.hero-radar {
  position: absolute;
  right: -0.8cm;
  bottom: -0.8cm;
  width: 100%;
  max-width: 250px;
}

.hero-calling {
  margin: 0 0 -10px;
  color: #ffbe5c;
  font-size: clamp(34px, 3vw, 42px);
  line-height: 1;
  font-weight: 900;
  letter-spacing: 0;
  text-transform: uppercase;
  transform: translateY(-0.6cm) scale(2);
  transform-origin: center bottom;
}

.hero-content .intro {
  margin-right: auto;
  margin-left: auto;
}

.hero-content .hero-actions {
  justify-content: center;
}

.kicker {
  margin: 0 0 10px;
  color: var(--teal);
  font-size: 13px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0;
}

h1,
h2,
h3,
p {
  margin-top: 0;
}

h1 {
  margin: 0 auto 12px;
  font-size: clamp(48px, 6vw, 76px);
  line-height: 1.08;
  letter-spacing: 0;
  font-weight: 780;
  max-width: 820px;
}

h2 {
  margin-bottom: 0;
  font-size: 24px;
  line-height: 1.28;
  letter-spacing: 0;
  font-weight: 760;
}

h3 {
  margin-bottom: 8px;
  font-size: 17px;
  line-height: 1.42;
  font-weight: 730;
}

.intro {
  max-width: 660px;
  color: rgba(255, 255, 255, 0.86);
  font-size: clamp(22px, 2vw, 28px);
  line-height: 1.55;
  font-weight: 650;
}

.primary-action,
.secondary-action,
.icon-button {
  min-height: 42px;
  border: 0;
  border-radius: 8px;
  transition: transform 160ms ease, background 160ms ease, border-color 160ms ease;
}

.primary-action {
  padding: 0 18px;
  background: var(--teal);
  color: var(--white);
  font-weight: 800;
}

.secondary-action {
  padding: 0 16px;
  border: 1px solid rgba(255, 255, 255, 0.38);
  background: rgba(255, 255, 255, 0.1);
  color: inherit;
  font-weight: 800;
}

.icon-button {
  width: 42px;
  display: inline-grid;
  place-items: center;
  border: 1px solid rgba(255, 255, 255, 0.38);
  background: rgba(255, 255, 255, 0.12);
  color: inherit;
  font-size: 24px;
}

button:hover {
  transform: translateY(-1px);
}

.dashboard,
.workspace-grid,
.content-studio,
.assessment-lab,
.diagnostic-test {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
}

.dashboard {
  margin-top: 18px;
  position: relative;
  z-index: 2;
}

.account-panel {
  display: grid;
  grid-template-columns: minmax(240px, 1fr) minmax(280px, 1fr);
  gap: 14px;
  align-items: start;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--white);
  padding: 20px;
  margin-bottom: 18px;
  box-shadow: var(--shadow);
}

.account-panel p {
  color: var(--muted);
  line-height: 1.55;
  margin-bottom: 0;
}

.account-panel > div:first-child {
  grid-column: 1;
  grid-row: 1;
}

.account-form,
.account-actions {
  display: flex;
  gap: 8px;
}

.account-form {
  grid-column: 2;
  grid-row: 1;
}

.account-actions {
  grid-column: 1;
  grid-row: 2;
}

.account-form input,
.account-actions select {
  min-width: 0;
  width: 100%;
  min-height: 42px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fbfcf8;
  padding: 0 12px;
  color: var(--ink);
}

.account-actions .secondary-action {
  color: var(--ink);
  border-color: var(--line);
  background: #f3f6f2;
  white-space: nowrap;
}

.member-lock {
  grid-column: 2;
  grid-row: 1;
  align-self: start;
  min-height: 42px;
  border: 1px solid rgba(25, 135, 125, 0.32);
  border-radius: 8px;
  background: #eef8f5;
  color: var(--ink);
  padding: 10px 12px;
}

.member-lock strong,
.member-lock span {
  display: block;
}

.member-lock strong {
  font-size: 0.96rem;
}

.member-lock span {
  margin-top: 2px;
  color: var(--muted);
  font-size: 0.82rem;
}

.account-history {
  display: grid;
  gap: 8px;
  grid-column: 2;
  grid-row: 2;
}

.account-history article,
.account-history > span {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fbfcf8;
  padding: 10px 12px;
}

.account-history strong,
.account-history span {
  display: block;
}

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

.account-history span {
  color: var(--muted);
  font-size: 13px;
  line-height: 1.45;
}

.metric-strip {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1px;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--line);
  box-shadow: var(--shadow);
}

.metric-strip article {
  background: var(--white);
  padding: 20px 22px;
}

.metric-strip span,
.module-card p,
.studio-copy p,
.upload-tile small {
  color: var(--muted);
}

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

.result-panel > .metric-strip {
  margin-top: 18px;
  box-shadow: none;
}

.workspace-menu {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
  margin-top: 18px;
  border-bottom: 1px solid var(--line);
  padding-bottom: 10px;
}

.workspace-menu button {
  display: grid;
  grid-template-columns: 34px minmax(0, 1fr);
  grid-template-rows: auto auto;
  gap: 2px 10px;
  min-height: 84px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: var(--white);
  color: var(--ink);
  padding: 12px;
  text-align: left;
}

.workspace-menu button > span {
  grid-row: 1 / 3;
  align-self: center;
  color: var(--teal);
  font-size: 12px;
  font-weight: 800;
}

.workspace-menu button strong {
  align-self: end;
  font-size: 14px;
}

.workspace-menu button small {
  align-self: start;
  color: var(--muted);
  font-size: 11px;
  line-height: 1.35;
  white-space: normal;
}

.workspace-menu button:hover {
  border-color: #9bb8b0;
  background: #f7f9f4;
  transform: none;
}

.workspace-menu button.active {
  border-color: var(--charcoal);
  background: var(--charcoal);
  color: var(--white);
}

.workspace-menu button.active > span {
  color: var(--amber);
}

.workspace-menu button.active small {
  color: #c9d2d0;
}

.workspace-stage,
.workspace-view {
  display: grid;
  gap: 18px;
}

.workspace-stage {
  margin-top: 14px;
}

.diagnosis-actions {
  justify-content: center;
  min-height: 112px;
  border-radius: 6px;
  background: var(--charcoal);
  padding: 20px;
  color: var(--white);
}

.diagnosis-actions .primary-action,
.diagnosis-actions .secondary-action {
  min-width: 180px;
}

.workspace-view > .diagnostic-test {
  width: 100%;
  margin-top: 0;
}

.main-grid,
.workspace-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 18px;
}

.main-grid {
  margin-top: 18px;
}

.dashboard > .diagnosis-panel {
  margin-top: 18px;
}

.dashboard > .diagnostic-test {
  width: 100%;
}

.section-slogan {
  margin: 6px 0 0;
  color: var(--teal);
  font-size: 15px;
  font-weight: 800;
}

.caselab-shell {
  display: grid;
  grid-template-columns: 270px minmax(0, 1fr);
  min-height: 650px;
  margin-top: 8px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #f7f9f8;
  overflow: hidden;
}

.workspace-view,
.practice-panel,
.caselab-workspace {
  min-width: 0;
  max-width: 100%;
}

.practice-panel {
  width: 100%;
}

.caselab-library {
  border-right: 1px solid var(--line);
  background: #f1f5f3;
  padding: 18px 14px;
}

.caselab-library-head,
.caselab-source-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.caselab-library-head h3 {
  margin: 3px 0 0;
  font-size: 21px;
}

.caselab-library-head > span {
  border-radius: 999px;
  background: #dfece8;
  color: var(--teal);
  padding: 5px 9px;
  font-size: 12px;
  font-weight: 800;
}

.caselab-case-list {
  display: grid;
  gap: 10px;
  margin-top: 17px;
}

.caselab-case {
  position: relative;
  display: grid;
  gap: 6px;
  width: 100%;
  border: 1px solid transparent;
  border-radius: 7px;
  background: transparent;
  color: var(--ink);
  padding: 13px 12px 34px;
  text-align: left;
}

.caselab-case:hover {
  background: rgba(255, 255, 255, 0.72);
}

.caselab-case.active {
  border-color: #4d9188;
  background: var(--white);
  box-shadow: 0 8px 22px rgba(30, 66, 59, 0.08);
}

.caselab-case strong {
  font-size: 14px;
  line-height: 1.45;
}

.caselab-case span,
.caselab-case small {
  color: var(--muted);
  font-size: 11px;
  line-height: 1.45;
}

.caselab-case em {
  position: absolute;
  right: 11px;
  bottom: 10px;
  border-radius: 999px;
  background: #edf1ef;
  color: var(--muted);
  padding: 3px 7px;
  font-size: 10px;
  font-style: normal;
  font-weight: 800;
}

.caselab-case em.complete {
  background: #e3f2ed;
  color: var(--teal);
}

.caselab-workspace {
  display: grid;
  grid-template-rows: auto auto auto minmax(0, 1fr) auto;
  min-width: 0;
  background: var(--white);
}

.caselab-toolbar {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  border-bottom: 1px solid var(--line);
  background: #fbfcfb;
  padding: 11px 12px;
  scrollbar-width: thin;
}

.caselab-toolbar button {
  flex: 0 0 auto;
  min-height: 36px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: var(--white);
  color: #4d5b57;
  padding: 0 11px;
  font-size: 12px;
  font-weight: 800;
}

.caselab-toolbar button.active {
  border-color: #7fb2aa;
  background: #e6f2ef;
  color: var(--teal);
}

.caselab-toolbar .caselab-reset {
  margin-left: auto;
  border-color: #d79b45;
  background: #fff4df;
  color: #8b5c13;
}

.caselab-status {
  border-bottom: 1px solid var(--line);
  color: var(--muted);
  padding: 9px 16px;
  font-size: 12px;
  font-weight: 700;
}

.caselab-document {
  border-bottom: 1px solid var(--line);
  background: #f8faf9;
}

.caselab-document > summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  min-height: 46px;
  cursor: pointer;
  padding: 0 16px;
  list-style: none;
}

.caselab-document > summary::-webkit-details-marker {
  display: none;
}

.caselab-document > summary::after {
  content: "+";
  display: grid;
  flex: 0 0 auto;
  width: 26px;
  height: 26px;
  place-items: center;
  border: 1px solid var(--line);
  border-radius: 50%;
  background: var(--white);
  color: var(--teal);
  font-size: 18px;
  font-weight: 700;
}

.caselab-document[open] > summary::after {
  content: "−";
}

.caselab-document > summary span {
  color: var(--ink);
  font-weight: 800;
}

.caselab-document > summary small {
  min-width: 0;
  margin-left: auto;
  overflow: hidden;
  color: var(--muted);
  text-overflow: ellipsis;
  white-space: nowrap;
}

.caselab-document-body {
  max-height: 410px;
  overflow-y: auto;
  border-top: 1px solid var(--line);
  background: var(--white);
  padding: 18px 20px 22px;
}

.caselab-document-body > section {
  border-top: 1px solid var(--line);
  padding-top: 13px;
}

.caselab-document-body > section h4 {
  margin: 0 0 6px;
}

.caselab-document-body > section p,
.caselab-source-summary {
  color: var(--muted);
  line-height: 1.75;
}

.caselab-document-question {
  margin-top: 16px;
  border: 1px solid #e6bf7b !important;
  border-left: 4px solid var(--amber) !important;
  border-radius: 6px;
  background: #fff8e9;
  padding: 14px 16px !important;
}

.caselab-document-question span {
  display: block;
  margin-bottom: 6px;
  color: #8b5c13;
  font-size: 11px;
  font-weight: 800;
}

.caselab-document-question h4 {
  margin: 0 !important;
  line-height: 1.6;
}

.caselab-stage {
  position: relative;
  min-height: 500px;
  overflow: hidden;
  background:
    linear-gradient(rgba(16, 123, 117, 0.025) 1px, transparent 1px),
    linear-gradient(90deg, rgba(16, 123, 117, 0.025) 1px, transparent 1px),
    #fbfcfb;
  background-size: 32px 32px;
}

.caselab-dialogue {
  height: 100%;
  max-height: 555px;
  overflow-y: auto;
  padding: 24px;
}

.caselab-empty {
  display: grid;
  place-items: center;
  align-content: center;
  min-height: 450px;
  color: var(--muted);
  text-align: center;
}

.caselab-empty > span {
  display: grid;
  width: 48px;
  height: 48px;
  place-items: center;
  margin-bottom: 14px;
  border: 1px solid #95bdb6;
  border-radius: 50%;
  background: #e7f2ef;
  color: var(--teal);
  font-size: 25px;
}

.caselab-empty strong {
  color: var(--ink);
  font-size: 18px;
}

.caselab-empty p {
  max-width: 620px;
  margin: 8px 0 5px;
  line-height: 1.65;
}

.caselab-empty small {
  color: #8b5c13;
}

.caselab-empty .caselab-competency {
  margin-top: 14px;
  border-radius: 4px;
  background: #e7f2ef;
  color: var(--teal);
  padding: 6px 9px;
  font-weight: 800;
}

.caselab-empty .caselab-source-hint {
  margin-top: 4px;
  color: #8b5c13;
}

.caselab-message {
  width: min(76%, 720px);
  margin-bottom: 16px;
}

.caselab-message > span {
  display: block;
  margin-bottom: 5px;
  color: var(--muted);
  font-size: 11px;
  font-weight: 800;
}

.caselab-message p {
  margin: 0;
  border: 1px solid var(--line);
  border-radius: 7px;
  background: var(--white);
  padding: 13px 15px;
  line-height: 1.7;
}

.caselab-message.user {
  margin-left: auto;
}

.caselab-message.user > span {
  text-align: right;
}

.caselab-message.user p {
  border-color: #99c4bd;
  background: #eaf4f1;
}

.caselab-message.coach p {
  border-left: 3px solid var(--amber);
}

.caselab-source {
  position: absolute;
  inset: 0 0 0 auto;
  z-index: 6;
  width: min(440px, 62%);
  overflow-y: auto;
  border-left: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.98);
  padding: 20px;
  box-shadow: -18px 0 36px rgba(26, 43, 39, 0.1);
  backdrop-filter: blur(12px);
}

.caselab-source-head {
  position: sticky;
  top: 0;
  z-index: 2;
  margin: -20px -20px 14px;
  border-bottom: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.96);
  padding: 15px 20px;
}

.caselab-source-facts {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.caselab-source-facts span {
  border-radius: 4px;
  background: #edf2f0;
  color: var(--muted);
  padding: 4px 7px;
  font-size: 11px;
  font-weight: 800;
}

.caselab-source-summary,
.caselab-source section p {
  color: var(--muted);
  line-height: 1.7;
}

.caselab-source section {
  border-top: 1px solid var(--line);
  padding-top: 13px;
}

.caselab-source section h4 {
  margin: 0 0 6px;
}

.caselab-composer {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
  border-top: 1px solid var(--line);
  background: var(--white);
  padding: 12px;
}

.caselab-input-wrap {
  min-width: 0;
}

.caselab-composer textarea {
  width: 100%;
  min-height: 52px;
  max-height: 150px;
  resize: vertical;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #fbfcfb;
  color: var(--ink);
  padding: 12px 13px;
  font: inherit;
  line-height: 1.5;
}

.caselab-voice-actions {
  display: flex;
  gap: 7px;
  margin-top: 7px;
}

.caselab-voice-actions button {
  min-height: 32px;
  border: 1px solid var(--line);
  border-radius: 5px;
  background: #f7f9f8;
  color: var(--muted);
  padding: 0 10px;
  font-size: 11px;
  font-weight: 800;
}

.caselab-voice-actions button:hover,
.caselab-voice-actions button.active {
  border-color: #7fb2aa;
  background: #e7f2ef;
  color: var(--teal);
}

.caselab-composer :disabled {
  cursor: wait;
  opacity: 0.58;
}

.caselab-thinking {
  color: var(--muted);
  font-style: italic;
}

.caselab-thinking-dots::after {
  content: "";
  animation: caselab-thinking 1.2s steps(4, end) infinite;
}

@keyframes caselab-thinking {
  0% { content: ""; }
  25% { content: "."; }
  50% { content: ".."; }
  75%, 100% { content: "..."; }
}

.caselab-composer .primary-action {
  align-self: stretch;
  min-width: 82px;
}

.case-learning {
  margin-bottom: 22px;
  border: 1px solid var(--line);
  border-left: 4px solid var(--amber);
  border-radius: 8px;
  background: #fbfcf8;
  padding: 18px;
}

.case-learning-intro,
.case-player-head,
.case-player-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
}

.case-learning-intro h3,
.case-player-head h3 {
  margin: 2px 0 4px;
}

.case-learning-intro p:not(.kicker),
.case-learning-preview p,
.case-context-card p,
.case-expert-card p {
  color: var(--muted);
  line-height: 1.65;
}

.case-learning-progress {
  flex: 0 0 auto;
  border-radius: 6px;
  background: #e7f2ef;
  color: var(--teal);
  padding: 8px 10px;
  font-size: 12px;
  font-weight: 800;
}

.case-learning-controls {
  display: grid;
  grid-template-columns: minmax(240px, 1fr) auto;
  align-items: end;
  gap: 12px;
  margin-top: 16px;
}

.case-learning-controls label > span,
.case-reflection-label > span {
  display: block;
  margin-bottom: 6px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.case-learning-controls select {
  width: 100%;
  min-height: 44px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: var(--white);
  color: var(--ink);
  padding: 0 34px 0 11px;
  font: inherit;
  font-weight: 700;
}

.case-learning-preview {
  display: grid;
  grid-template-columns: minmax(0, 1fr) repeat(3, auto);
  align-items: center;
  gap: 12px;
  margin-top: 14px;
  border-top: 1px solid var(--line);
  padding-top: 14px;
}

.case-learning-preview p {
  margin: 0;
}

.case-learning-preview span,
.case-competencies span {
  border-radius: 4px;
  background: #edf0ee;
  padding: 4px 7px;
  color: var(--muted);
  font-size: 11px;
  font-weight: 800;
}

.case-learning-preview span.complete {
  background: #e7f2ef;
  color: var(--teal);
}

.case-player-head {
  position: sticky;
  top: 0;
  z-index: 8;
  margin: -8px -2px 0;
  border-bottom: 1px solid rgba(216, 224, 221, 0.9);
  background: rgba(251, 252, 248, 0.96);
  padding: 8px 2px 12px;
  backdrop-filter: blur(10px);
}

.case-stepper {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  margin: 14px 0 18px;
  border: 1px solid var(--line);
  border-radius: 6px;
  overflow: hidden;
}

.case-stepper button {
  min-height: 40px;
  border: 0;
  border-right: 1px solid var(--line);
  background: var(--white);
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.case-stepper button:last-child {
  border-right: 0;
}

.case-stepper button.active {
  background: var(--charcoal);
  color: var(--white);
}

.case-stepper button.complete:not(.active) {
  background: #e7f2ef;
  color: var(--teal);
}

.case-player-body {
  min-height: 330px;
  scroll-margin-top: 104px;
  outline: none;
}

.case-facts,
.case-context-grid,
.case-expert-grid {
  display: grid;
  gap: 10px;
}

.case-facts {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  margin-bottom: 14px;
}

.case-facts article,
.case-context-card,
.case-expert-card {
  border: 1px solid var(--line);
  border-radius: 6px;
  background: var(--white);
  padding: 13px;
}

.case-facts span,
.case-facts strong {
  display: block;
}

.case-facts span {
  margin-bottom: 4px;
  color: var(--muted);
  font-size: 11px;
  font-weight: 800;
}

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

.case-context-card h4,
.case-expert-card h4 {
  margin: 0 0 6px;
}

.case-context-card p,
.case-expert-card p {
  margin: 0;
}

.case-own-reflection {
  margin-bottom: 14px;
  border-left: 3px solid var(--amber);
  background: #fff8e9;
  padding: 12px 14px;
}

.case-own-reflection strong {
  display: block;
  margin-bottom: 5px;
  color: #8b5c13;
}

.case-own-reflection p {
  margin: 0;
  color: var(--ink);
  line-height: 1.65;
  white-space: pre-wrap;
}

.case-question {
  margin: 0 0 16px;
  font-size: 19px;
  line-height: 1.55;
}

.case-reflection-label textarea {
  width: 100%;
  min-height: 180px;
  resize: vertical;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: var(--white);
  color: var(--ink);
  padding: 13px;
  font: inherit;
  line-height: 1.65;
}

.case-reflection-meta {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  margin-top: 7px;
  color: var(--muted);
  font-size: 11px;
}

.case-action-list {
  display: grid;
  gap: 9px;
}

.case-action-list label {
  display: grid;
  grid-template-columns: 22px minmax(0, 1fr);
  align-items: start;
  gap: 10px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: var(--white);
  padding: 12px;
  line-height: 1.55;
}

.case-action-list input {
  width: 18px;
  height: 18px;
  accent-color: var(--teal);
}

.case-gate-note {
  margin: 12px 0 0;
  color: #8b5c13;
  font-size: 12px;
  font-weight: 800;
}

.case-competencies {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  margin: 14px 0;
}

.case-self-rating {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin-top: 16px;
  border-top: 1px solid var(--line);
  padding-top: 14px;
}

.case-self-rating strong {
  margin-right: 4px;
}

.case-self-rating button {
  width: 38px;
  height: 38px;
  border: 1px solid var(--line);
  border-radius: 50%;
  background: var(--white);
  color: var(--ink);
  font-weight: 800;
}

.case-self-rating button.active {
  border-color: var(--teal);
  background: var(--teal);
  color: var(--white);
}

.case-complete-note {
  margin-top: 14px;
  border-left: 3px solid var(--teal);
  background: #e7f2ef;
  padding: 11px 13px;
  color: var(--teal);
  font-weight: 800;
}

.case-player-actions {
  margin-top: 18px;
  border-top: 1px solid var(--line);
  padding-top: 14px;
}

.workspace-grid,
.assessment-lab,
.diagnostic-test,
.content-studio {
  margin-top: 18px;
}

.panel {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 22px;
  box-shadow: 0 8px 28px rgba(32, 53, 50, 0.05);
}

.panel-heading {
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 18px;
}

.panel-heading.compact {
  align-items: flex-start;
}

.segmented {
  display: inline-grid;
  grid-template-columns: repeat(3, 1fr);
  border: 1px solid var(--line);
  border-radius: 8px;
  overflow: hidden;
}

.segmented button {
  border: 0;
  background: #f3f6f2;
  padding: 10px 13px;
  color: var(--muted);
}

.segmented button.active {
  background: var(--charcoal);
  color: var(--white);
}

.module-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(360px, 1fr));
  gap: 12px;
}

.learning-filters {
  display: grid;
  grid-template-columns: minmax(240px, 420px);
  gap: 12px;
  margin-bottom: 14px;
}

.learning-selection-prompt {
  margin: 14px 0;
  border-left: 3px solid var(--teal);
  background: #f3f6f2;
  padding: 11px 13px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 700;
}

.learning-filters label > span {
  display: block;
  margin-bottom: 6px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.learning-filters select {
  width: 100%;
  min-height: 42px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: var(--white);
  color: var(--ink);
  padding: 0 34px 0 11px;
  font: inherit;
  font-weight: 700;
}

.dimension-overview {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  margin-bottom: 14px;
}

.dimension-tile {
  --dimension-accent: #247f72;
  --dimension-surface: #eef7f2;
  display: grid;
  align-content: start;
  gap: 8px;
  min-width: 0;
  min-height: 142px;
  border: 1px solid var(--line);
  border-top: 4px solid var(--dimension-accent);
  border-radius: 6px;
  background: var(--dimension-surface);
  color: var(--ink);
  padding: 14px;
  text-align: left;
  box-shadow: 0 5px 14px rgba(24, 52, 48, 0.08);
  transition: transform 160ms ease, box-shadow 160ms ease, border-color 160ms ease;
}

.dimension-tile[data-dimension="People"] {
  --dimension-accent: #4f9a73;
  --dimension-surface: #edf7f0;
}

.dimension-tile[data-dimension="Organization"] {
  --dimension-accent: #37896f;
  --dimension-surface: #e9f4ef;
}

.dimension-tile[data-dimension="Workplace"] {
  --dimension-accent: #6cab7f;
  --dimension-surface: #f0f7ec;
}

.dimension-tile[data-dimension="Interpersonal"] {
  --dimension-accent: #6856a0;
  --dimension-surface: #f1eff8;
}

.dimension-tile[data-dimension="Business"] {
  --dimension-accent: #555759;
  --dimension-surface: #f0f1ef;
}

.dimension-tile[data-dimension="Leadership"] {
  --dimension-accent: #29466f;
  --dimension-surface: #edf2f7;
}

.dimension-tile:hover {
  border-color: var(--dimension-accent);
  transform: translateY(-3px);
  box-shadow: 0 11px 22px rgba(24, 52, 48, 0.15);
}

.dimension-tile.active {
  border-color: var(--dimension-accent);
  box-shadow: inset 0 0 0 1px var(--dimension-accent), 0 12px 24px rgba(24, 52, 48, 0.16);
  background: color-mix(in srgb, var(--dimension-accent) 14%, white);
  transform: translateY(-2px);
}

.dimension-tile:focus-visible {
  outline: 3px solid color-mix(in srgb, var(--dimension-accent) 38%, white);
  outline-offset: 3px;
}

.dimension-tile-track {
  color: var(--dimension-accent);
  font-size: 10px;
  font-weight: 800;
}

.dimension-tile-head,
.dimension-tile-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.dimension-tile-head strong {
  font-size: 19px;
}

.dimension-tile-head b {
  font-size: 18px;
}

.dimension-tile-scope,
.dimension-tile-foot small {
  color: var(--muted);
  font-size: 11px;
}

.dimension-tile .dimension-meter i {
  background: var(--dimension-accent);
}

.dimension-tile-foot em {
  font-style: normal;
}

.module-chooser {
  margin: 4px 0 14px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #f7f9f6;
  padding: 14px;
}

.module-chooser-head {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 11px;
}

.module-chooser-head span,
.module-chooser-head strong {
  display: block;
}

.module-chooser-head span,
.module-chooser-head small {
  color: var(--muted);
  font-size: 11px;
}

.module-chooser-head strong {
  margin-top: 2px;
  font-size: 15px;
}

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

.module-choice {
  display: grid;
  gap: 5px;
  min-width: 0;
  min-height: 82px;
  border: 1px solid var(--line);
  border-radius: 5px;
  background: var(--white);
  color: var(--ink);
  padding: 11px 12px;
  text-align: left;
}

.module-choice:hover,
.module-choice.active {
  border-color: var(--teal);
}

.module-choice.active {
  box-shadow: inset 3px 0 0 var(--teal);
  background: #eef6f2;
}

.module-choice strong {
  overflow-wrap: anywhere;
  font-size: 13px;
}

.module-choice span,
.module-choice em {
  color: var(--muted);
  font-size: 10px;
  font-style: normal;
}

.dimension-row {
  display: grid;
  grid-template-columns: minmax(118px, 0.8fr) minmax(100px, 0.7fr) minmax(100px, 1fr) 52px 62px;
  align-items: center;
  gap: 12px;
  width: 100%;
  min-height: 50px;
  border: 0;
  border-bottom: 1px solid var(--line);
  background: transparent;
  color: var(--ink);
  padding: 7px 4px;
  text-align: left;
}

@media (max-width: 820px) {
  .dimension-overview {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 520px) {
  .dimension-overview,
  .module-choice-grid {
    grid-template-columns: 1fr;
  }

  .dimension-tile {
    min-height: 126px;
  }

  .module-chooser-head {
    align-items: start;
    flex-direction: column;
    gap: 4px;
  }
}

.dimension-row:hover,
.dimension-row.active {
  background: #f3f6f2;
}

.dimension-row.active {
  box-shadow: inset 3px 0 0 var(--teal);
}

.dimension-name strong,
.dimension-name small {
  display: block;
}

.dimension-name small,
.dimension-scope {
  color: var(--muted);
  font-size: 11px;
}

.dimension-meter {
  height: 6px;
  overflow: hidden;
  border-radius: 999px;
  background: #e2e8e5;
}

.dimension-meter i {
  display: block;
  height: 100%;
  background: var(--teal);
}

.dimension-score {
  text-align: right;
  font-weight: 800;
}

.dimension-status {
  border-radius: 4px;
  background: #edf0ee;
  padding: 4px 6px;
  color: var(--muted);
  text-align: center;
  font-size: 11px;
  font-weight: 800;
}

.dimension-status.strength {
  background: #e7f2ef;
  color: var(--teal);
}

.dimension-status.weakness {
  background: #fff0ed;
  color: #a44034;
}

.dimension-group {
  grid-column: 1 / -1;
  border-bottom: 1px solid var(--line);
  padding-bottom: 14px;
}

.dimension-group > summary {
  display: grid;
  grid-template-columns: minmax(180px, 1fr) auto auto auto;
  align-items: center;
  gap: 16px;
  min-height: 58px;
  cursor: pointer;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
  list-style-position: inside;
}

.dimension-group > summary > span:first-child {
  color: var(--ink);
  font-size: 15px;
}

.dimension-group > summary small {
  display: block;
  margin-top: 2px;
  color: var(--muted);
  font-size: 10px;
}

.dimension-group > .module-list {
  padding: 2px 0 4px;
}

.library-summary {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 12px;
}

.library-summary span {
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 5px 9px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.module-card {
  min-height: 112px;
  display: grid;
  grid-template-columns: 52px minmax(0, 1fr) 42px;
  align-items: center;
  gap: 16px;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fbfcf8;
}

.module-card-title,
.module-progress-meta {
  display: flex;
  align-items: center;
}

.module-card-title {
  justify-content: space-between;
  gap: 10px;
}

.module-card-title h3 {
  margin-bottom: 0;
}

.module-card-title > span {
  flex: 0 0 auto;
  color: var(--teal);
  font-size: 12px;
  font-weight: 800;
}

.module-icon {
  width: 52px;
  aspect-ratio: 1;
  display: grid;
  place-items: center;
  border-radius: 8px;
  background: #e7f2ef;
  color: var(--teal);
  font-size: 22px;
}

.module-card p {
  margin-top: 6px;
  margin-bottom: 12px;
  line-height: 1.55;
}

.module-progress-meta {
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 7px;
  color: var(--muted);
  font-size: 11px;
}

.module-progress-meta strong {
  margin-left: auto;
  color: var(--ink);
}

.module-result {
  border-radius: 4px;
  background: #edf0ee;
  padding: 2px 5px;
  font-weight: 800;
}

.module-result.strength {
  background: #e7f2ef;
  color: var(--teal);
}

.module-result.weakness {
  background: #fff0ed;
  color: #a44034;
}

.ai-review-count {
  border-radius: 4px;
  background: #fff4df;
  padding: 2px 5px;
  color: #8b5c13;
  font-weight: 800;
}

.expert-request-count {
  border-radius: 4px;
  background: #e9eef5;
  padding: 2px 5px;
  color: #385675;
  font-weight: 800;
}

.module-action {
  color: var(--ink);
  border-color: var(--line);
  background: var(--white);
}

.progress {
  height: 8px;
  background: #e7ece9;
  border-radius: 999px;
  overflow: hidden;
}

.progress span {
  display: block;
  height: 100%;
  background: linear-gradient(90deg, var(--teal), var(--amber));
}

.chapter-practice {
  position: relative;
  margin-top: 24px;
  border-top: 1px solid var(--line);
  padding-top: 22px;
}

.chapter-practice-head {
  position: sticky;
  top: 0;
  z-index: 8;
  display: flex;
  align-items: start;
  justify-content: space-between;
  gap: 16px;
  margin: -10px -2px 0;
  border-bottom: 1px solid rgba(216, 224, 221, 0.9);
  background: rgba(255, 255, 255, 0.96);
  padding: 10px 2px 12px;
  backdrop-filter: blur(10px);
}

.chapter-practice-head h3 {
  margin-bottom: 0;
}

.chapter-progress {
  height: 8px;
  margin: 0 0 18px;
  overflow: hidden;
  background: #e2e8e5;
}

.chapter-progress span {
  display: block;
  height: 100%;
  background: var(--teal);
  transition: width 180ms ease;
}

.chapter-complete {
  padding: 34px 18px 12px;
  text-align: center;
}

.chapter-question-body {
  scroll-margin-top: 104px;
  outline: none;
}

.complete-mark {
  display: grid;
  place-items: center;
  width: 56px;
  height: 56px;
  margin: 0 auto 16px;
  border-radius: 50%;
  background: var(--teal);
  color: var(--white);
  font-size: 28px;
  font-weight: 800;
}

.chapter-complete h3 {
  margin: 4px 0 10px;
  font-size: 24px;
}

.chapter-complete > p:not(.kicker) {
  color: var(--muted);
  line-height: 1.65;
}

.chapter-complete > p strong {
  color: var(--teal);
  font-size: 22px;
}

.chapter-attempt-history {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 18px;
}

.chapter-attempt-history span {
  border: 1px solid var(--line);
  border-radius: 6px;
  background: var(--white);
  padding: 7px 10px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.chapter-attempt-history span.active {
  border-color: #91cbb5;
  background: #e7f2ef;
  color: var(--teal);
}

.chapter-complete .review-actions {
  justify-content: center;
  margin-top: 24px;
}

.chapter-review-submit {
  margin-top: 24px;
  border-top: 1px solid var(--line);
  padding-top: 18px;
  text-align: left;
}

.chapter-review-submit-head,
.chapter-review-submit-actions,
.chapter-status-legend {
  display: flex;
  align-items: center;
  gap: 12px;
}

.chapter-review-submit-head,
.chapter-review-submit-actions {
  justify-content: space-between;
}

.chapter-status-legend {
  flex-wrap: wrap;
  color: var(--muted);
  font-size: 11px;
  font-weight: 800;
}

.chapter-status-legend span {
  display: inline-flex;
  align-items: center;
  gap: 5px;
}

.chapter-status-legend span::before {
  content: "";
  width: 10px;
  height: 10px;
  border: 1px solid transparent;
  border-radius: 3px;
}

.chapter-status-legend .mastered::before {
  border-color: #79bba4;
  background: #dceee8;
}

.chapter-status-legend .unmastered::before {
  border-color: #deb76c;
  background: #fff0c9;
}

.chapter-status-legend .review::before {
  border-color: #b97869;
  background: #ead8d2;
}

.chapter-review-map {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(38px, 1fr));
  gap: 8px;
  margin: 14px 0;
}

.chapter-review-map button {
  aspect-ratio: 1;
  min-width: 0;
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 0;
  font: inherit;
  font-size: 12px;
  font-weight: 800;
}

.chapter-review-map button.mastered {
  border-color: #79bba4;
  background: #dceee8;
  color: #096a58;
}

.chapter-review-map button.unmastered {
  border-color: #deb76c;
  background: #fff0c9;
  color: #805713;
}

.chapter-review-map button.review {
  border-color: #b97869;
  background: #ead8d2;
  color: #743b32;
  box-shadow: inset 0 0 0 1px rgba(116, 59, 50, 0.12);
}

.chapter-review-map button:hover {
  filter: brightness(0.97);
}

.chapter-review-map button:focus-visible {
  outline: 2px solid var(--charcoal);
  outline-offset: 2px;
}

.chapter-review-submit-actions > span {
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
}

.chapter-question-meta {
  min-height: 24px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
}

.chapter-question-title {
  margin: 16px 0;
  min-height: 62px;
  font-size: 19px;
  line-height: 1.6;
}

#chapterCaseText {
  max-height: 220px;
}

.chapter-answer-list {
  display: grid;
  gap: 9px;
  min-height: 243px;
}

.chapter-answer-option {
  display: grid;
  grid-template-columns: 22px 24px minmax(0, 1fr);
  gap: 9px;
  align-items: center;
  width: 100%;
  min-height: 54px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--white);
  color: var(--ink);
  padding: 11px 13px;
  text-align: left;
}

.chapter-answer-option:hover:not(:disabled) {
  border-color: var(--teal);
  background: #f3f6f2;
}

.chapter-answer-option.selected-wrong {
  border-color: #e6b6ad;
  background: #fff0ed;
  color: #8d352a;
}

.chapter-answer-option.correct {
  border-color: #91cbb5;
  background: #e7f2ef;
  color: #096a58;
}

.chapter-answer-option.selected-wrong .choice-control {
  border-color: var(--coral);
  background: var(--coral);
}

.chapter-answer-option.selected-wrong .choice-control::after {
  content: "×";
  position: absolute;
  inset: -4px 0 0;
  color: var(--white);
  text-align: center;
  font-size: 16px;
  font-weight: 800;
}

.chapter-answer-option.correct .choice-control {
  border-color: var(--teal);
  background: var(--teal);
}

.chapter-answer-option.correct .choice-control::after {
  content: "✓";
  position: absolute;
  inset: -3px 0 0;
  color: var(--white);
  text-align: center;
  font-size: 13px;
  font-weight: 800;
}

.chapter-answer-option:disabled {
  cursor: default;
}

.chapter-analysis-entry {
  margin-top: 12px;
}

.chapter-navigation {
  position: sticky;
  bottom: 12px;
  z-index: 7;
  margin: 16px -10px 0;
  border: 1px solid rgba(216, 224, 221, 0.96);
  background: rgba(255, 255, 255, 0.94);
  padding: 10px;
  box-shadow: 0 8px 24px rgba(23, 32, 34, 0.1);
  backdrop-filter: blur(10px);
}

.chapter-navigation .secondary-action,
.chapter-navigation .primary-action {
  min-width: 118px;
}

.danger-action {
  margin-right: auto;
  border-color: #e6b6ad;
  color: #a44034;
}

.analysis-review-action {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  margin-top: 14px;
  border: 1px solid #e4cf9b;
  border-radius: 6px;
  background: #fff8e8;
  padding: 11px 12px;
  color: #74541a;
  font-size: 13px;
  font-weight: 700;
}

.analysis-review-action .secondary-action.active {
  border-color: #b77b1f;
  background: #fff0c9;
  color: #74541a;
}

.option-reasons article.correct-reason {
  border-color: #91cbb5;
  background: #e7f2ef;
}

.option-reasons article.correct-reason .reason-flaw {
  background: var(--teal);
  color: var(--white);
}

.coach-feed {
  min-height: 190px;
  padding: 16px;
  background: #f3f6f2;
  border-radius: 8px;
  line-height: 1.65;
}

.huawei-case-lab {
  width: 100%;
  padding: 0;
  overflow: hidden;
}

.huawei-lab-heading {
  margin: 0;
  border-bottom: 1px solid var(--line);
  padding: 20px 22px 17px;
}

.huawei-lab-heading h2 {
  margin-bottom: 4px;
}

.huawei-lab-heading p:not(.kicker) {
  margin: 0;
  color: var(--muted);
}

.huawei-series-tabs {
  display: flex;
  gap: 0;
  border-bottom: 1px solid var(--line);
  background: #f7f9f8;
  padding: 0 22px;
}

.huawei-series-tabs button {
  min-height: 46px;
  border: 0;
  border-bottom: 3px solid transparent;
  background: transparent;
  color: var(--muted);
  padding: 0 20px;
  font-weight: 800;
}

.huawei-series-tabs button.active {
  border-bottom-color: var(--teal);
  color: var(--ink);
}

.huawei-lab-layout {
  display: grid;
  grid-template-columns: 270px minmax(0, 1fr);
  min-height: 650px;
}

.huawei-case-library {
  border-right: 1px solid var(--line);
  background: #f1f5f3;
  padding: 18px 14px;
}

.huawei-library-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 14px;
}

.huawei-library-title strong {
  font-size: 14px;
}

.huawei-library-title span {
  color: var(--muted);
  font-size: 11px;
}

.huawei-case-item {
  display: grid;
  gap: 6px;
  width: 100%;
  border: 1px solid transparent;
  border-radius: 7px;
  background: transparent;
  color: var(--ink);
  padding: 13px 12px;
  text-align: left;
}

.huawei-case-item.active {
  border-color: #72a9a0;
  background: var(--white);
  box-shadow: 0 8px 22px rgba(30, 66, 59, 0.08);
}

.huawei-case-item.material-required {
  border-color: #d8d3c8;
  background: rgba(255, 255, 255, 0.5);
}

.huawei-case-item.material-required > span {
  color: #9a6b24;
}

.huawei-case-item > span {
  color: var(--teal);
  font-size: 10px;
  font-weight: 800;
}

.huawei-case-item strong {
  font-size: 15px;
}

.huawei-case-item small,
.huawei-case-item em {
  color: var(--muted);
  font-size: 11px;
  font-style: normal;
  line-height: 1.45;
}

.huawei-series-empty,
.huawei-empty-workspace {
  color: var(--muted);
  padding: 28px 12px;
  text-align: center;
}

.huawei-case-workspace {
  display: grid;
  grid-template-rows: auto auto auto minmax(280px, 1fr) auto;
  min-width: 0;
}

.huawei-mode-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  border-bottom: 1px solid var(--line);
  padding: 11px 12px;
}

.huawei-mode-bar button {
  min-height: 36px;
  border: 1px solid var(--line);
  border-radius: 5px;
  background: var(--white);
  color: var(--muted);
  padding: 0 11px;
  font-size: 12px;
  font-weight: 800;
}

.huawei-mode-bar button.active {
  border-color: #7fb2aa;
  background: #e6f2ef;
  color: var(--teal);
}

.huawei-case-status {
  border-bottom: 1px solid var(--line);
  color: var(--muted);
  padding: 9px 16px;
  font-size: 12px;
  font-weight: 700;
}

.huawei-case-source {
  border-bottom: 1px solid var(--line);
  background: #f8faf9;
}

.huawei-case-source summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  min-height: 46px;
  cursor: pointer;
  padding: 0 16px;
}

.huawei-case-source summary span {
  color: var(--muted);
  font-size: 12px;
}

.huawei-case-source-body {
  max-height: 390px;
  overflow-y: auto;
  border-top: 1px solid var(--line);
  background: var(--white);
  padding: 18px 20px;
}

.huawei-case-source-body p {
  color: var(--muted);
  line-height: 1.75;
}

.huawei-case-source-body section {
  border-top: 1px solid var(--line);
  padding-top: 12px;
}

.huawei-case-source-body section h4 {
  margin: 0 0 5px;
}

.huawei-case-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.huawei-case-meta span {
  border-radius: 4px;
  background: #e7f2ef;
  color: var(--teal);
  padding: 4px 7px;
  font-size: 11px;
  font-weight: 800;
}

.huawei-case-question {
  margin: 14px 0;
  border-left: 4px solid var(--amber);
  background: #fff8e9;
  padding: 12px 14px;
}

.huawei-case-question p {
  margin-bottom: 0;
  color: var(--ink);
}

.huawei-material-required {
  border-left: 4px solid var(--amber);
  background: #fff8e9;
  padding: 15px 16px;
}

.huawei-material-required p {
  margin: 6px 0 0;
}

.huawei-coach-feed {
  min-height: 330px;
  max-height: 520px;
  overflow-y: auto;
  border-radius: 0;
  background: #fbfcfb;
  padding: 22px;
}

.huawei-coach-welcome {
  display: grid;
  place-items: center;
  align-content: center;
  min-height: 285px;
  text-align: center;
}

.huawei-coach-welcome span {
  border-radius: 4px;
  background: #e7f2ef;
  color: var(--teal);
  padding: 5px 8px;
  font-size: 11px;
  font-weight: 800;
}

.huawei-coach-welcome strong {
  margin-top: 10px;
}

.huawei-coach-welcome p {
  max-width: 650px;
  color: var(--muted);
}

.huawei-message {
  width: min(78%, 720px);
  margin-bottom: 15px;
}

.huawei-message > span {
  display: block;
  margin-bottom: 5px;
  color: var(--muted);
  font-size: 11px;
  font-weight: 800;
}

.huawei-message p {
  margin: 0;
  border: 1px solid var(--line);
  border-left: 3px solid var(--amber);
  border-radius: 7px;
  background: var(--white);
  padding: 13px 15px;
}

.huawei-message.user {
  margin-left: auto;
}

.huawei-message.user > span {
  text-align: right;
}

.huawei-message.user p {
  border-color: #99c4bd;
  border-left-width: 1px;
  background: #eaf4f1;
}

.huawei-message.thinking p {
  color: var(--muted);
  font-style: italic;
}

.huawei-coach-input {
  margin: 0;
  border-top: 1px solid var(--line);
  padding: 12px;
}

.huawei-runtime-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  border-top: 1px solid var(--line);
  background: #f7f9f8;
  padding: 9px 12px;
}

.huawei-runtime-actions span {
  margin-right: auto;
  color: var(--muted);
  font-size: 11px;
  font-weight: 800;
}

.huawei-runtime-actions button {
  min-height: 34px;
  border: 1px solid var(--line);
  border-radius: 5px;
  background: var(--white);
  color: var(--ink);
  padding: 0 10px;
  font-size: 11px;
  font-weight: 800;
}

.huawei-runtime-actions button:hover:not(:disabled) {
  border-color: #7fb2aa;
  color: var(--teal);
}

.huawei-runtime-actions button:disabled {
  cursor: not-allowed;
  opacity: 0.45;
}

.huawei-feedback {
  display: grid;
  gap: 12px;
  border-top: 1px solid var(--line);
  background: #f8faf9;
  padding: 16px;
}

.huawei-feedback[hidden] {
  display: none;
}

.huawei-feedback label {
  display: grid;
  gap: 6px;
  color: var(--ink);
  font-size: 12px;
  font-weight: 800;
}

.huawei-feedback textarea {
  width: 100%;
  min-height: 72px;
  resize: vertical;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: var(--white);
  padding: 9px 10px;
  color: var(--ink);
  font: inherit;
  font-weight: 400;
}

.huawei-feedback > div {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 12px;
}

.huawei-feedback > div span {
  color: var(--teal);
  font-size: 12px;
  font-weight: 800;
}

.huawei-outcome {
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  background: var(--white);
  padding: 18px 20px 20px;
}

.huawei-outcome[hidden] {
  display: none;
}

.huawei-outcome > header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
}

.huawei-outcome > header span {
  color: var(--teal);
  font-size: 10px;
  font-weight: 900;
}

.huawei-outcome > header h3 {
  margin: 3px 0 0;
  font-size: 20px;
}

.huawei-outcome > header small {
  color: var(--muted);
}

.huawei-outcome-tabs {
  display: flex;
  gap: 0;
  margin-top: 16px;
  border-bottom: 1px solid var(--line);
}

.huawei-outcome-tabs button {
  min-height: 38px;
  border: 0;
  border-bottom: 3px solid transparent;
  background: transparent;
  color: var(--muted);
  padding: 0 14px;
  font-size: 12px;
  font-weight: 800;
}

.huawei-outcome-tabs button.active {
  border-bottom-color: var(--teal);
  color: var(--ink);
}

.huawei-outcome-body {
  padding: 14px 0 4px;
}

.huawei-outcome-intro {
  margin: 0 0 12px;
  color: var(--muted);
  font-size: 12px;
}

.huawei-outcome-list {
  border-top: 1px solid var(--line);
}

.huawei-outcome-list article {
  display: grid;
  grid-template-columns: minmax(130px, 180px) minmax(0, 1fr);
  gap: 18px;
  border-bottom: 1px solid var(--line);
  padding: 13px 0;
}

.huawei-outcome-list article strong {
  font-size: 13px;
}

.huawei-outcome-list article p {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.65;
}

.huawei-next-practice {
  margin-top: 14px;
  border-left: 4px solid var(--amber);
  background: #fff8e9;
  padding: 11px 13px;
}

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

.huawei-evidence-group {
  border-top: 1px solid var(--line);
  padding: 13px 0;
}

.huawei-evidence-group h4 {
  margin: 0 0 9px;
  font-size: 13px;
}

.huawei-evidence-group > div {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 7px 18px;
}

.huawei-evidence-group span {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 10px;
  border-bottom: 1px solid #edf0ee;
  padding: 7px 0;
}

.huawei-evidence-group b {
  font-size: 12px;
}

.huawei-evidence-group small {
  color: var(--teal);
  text-align: right;
}

.huawei-outcome > footer {
  display: flex;
  justify-content: flex-end;
  margin-top: 14px;
}

.huawei-input-wrap {
  min-width: 0;
  flex: 1;
}

.huawei-coach-input textarea {
  width: 100%;
  min-width: 0;
  flex: 1;
  min-height: 58px;
  resize: vertical;
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 10px 12px;
  font: inherit;
}

.huawei-input-tools {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-top: 7px;
}

.huawei-input-tools button {
  min-height: 32px;
  border: 1px solid var(--line);
  border-radius: 5px;
  background: #f7f9f8;
  color: var(--muted);
  padding: 0 10px;
  font-size: 11px;
  font-weight: 800;
}

.huawei-input-tools button:hover,
.huawei-input-tools button.active {
  border-color: #7fb2aa;
  background: #e7f2ef;
  color: var(--teal);
}

.huawei-input-tools small {
  color: var(--muted);
  font-size: 10px;
}

#huaweiVoiceStatus {
  color: var(--muted);
  font-size: 0.78rem;
  line-height: 1.35;
}

#huaweiVoiceStatus[data-state="error"] {
  color: #a95b35;
}

#huaweiVoiceStatus[data-state="success"] {
  color: #107b75;
}

.coach-input {
  margin-top: 12px;
  gap: 8px;
}

.coach-input input,
.coach-input textarea {
  min-width: 0;
  flex: 1;
  min-height: 42px;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 0 12px;
}

@media (max-width: 900px) {
  .huawei-lab-layout {
    grid-template-columns: 1fr;
  }

  .huawei-case-library {
    border-right: 0;
    border-bottom: 1px solid var(--line);
  }

  #huaweiCaseList {
    display: grid;
    grid-template-columns: repeat(3, minmax(220px, 1fr));
    overflow-x: auto;
  }
}

@media (max-width: 560px) {
  .huawei-runtime-actions {
    align-items: stretch;
    flex-wrap: wrap;
  }

  .huawei-runtime-actions span {
    width: 100%;
  }

  .huawei-message {
    width: 94%;
  }

  .huawei-outcome {
    padding-right: 14px;
    padding-left: 14px;
  }

  .huawei-outcome-tabs {
    overflow-x: auto;
  }

  .huawei-outcome-tabs button {
    flex: 0 0 auto;
  }

  .huawei-outcome-list article,
  .huawei-evidence-group > div {
    grid-template-columns: 1fr;
  }
}

.live-dot,
.pill {
  display: inline-flex;
  align-items: center;
  min-height: 30px;
  padding: 0 10px;
  border-radius: 999px;
  background: #e7f2ef;
  color: var(--teal);
  font-weight: 800;
  font-size: 13px;
}

.diagnosis-panel .secondary-action {
  color: var(--ink);
  border-color: var(--line);
  background: #f3f6f2;
}

.full-action {
  width: 100%;
  margin-top: 18px;
}

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

.dimension-card {
  min-height: 250px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fbfcf8;
  padding: 18px;
}

.dimension-label {
  width: max-content;
  min-height: 28px;
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  background: #e7f2ef;
  color: var(--teal);
  padding: 0 10px;
  font-size: 12px;
  font-weight: 800;
  text-transform: uppercase;
}

.dimension-card p {
  color: var(--muted);
  line-height: 1.6;
}

.dimension-scoreline {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 12px;
  color: var(--muted);
}

.dimension-scoreline strong {
  color: var(--ink);
  font-size: 28px;
}

.dimension-outcome {
  color: var(--muted);
  font-size: 13px;
  font-weight: 700;
}

.score-meter {
  height: 12px;
  background: #e7ece9;
  border-radius: 999px;
  overflow: hidden;
}

.score-meter span {
  display: block;
  width: 0;
  height: 100%;
  background: linear-gradient(90deg, var(--teal), var(--amber));
  transition: width 180ms ease;
}

.capability-progress-head {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 18px;
  margin-top: 26px;
  padding-top: 22px;
  border-top: 1px solid var(--line);
}

.capability-progress-head h3,
.capability-progress-head p {
  margin-bottom: 0;
}

.capability-progress-head p {
  margin-top: 6px;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.5;
}

.capability-legend {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 6px;
}

.capability-legend span {
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 4px 8px;
  color: var(--muted);
  font-size: 11px;
  font-weight: 800;
}

.capability-progress {
  margin-top: 12px;
  border-bottom: 1px solid var(--line);
}

.capability-progress-row {
  display: grid;
  grid-template-columns: minmax(130px, 1.35fr) repeat(4, minmax(82px, 1fr)) 104px;
  gap: 12px;
  align-items: center;
  min-height: 94px;
  border-top: 1px solid var(--line);
  padding: 13px 0;
}

.capability-name {
  min-width: 0;
}

.capability-name span,
.capability-name strong,
.capability-name em {
  display: block;
}

.capability-name span {
  color: var(--teal);
  font-size: 11px;
  font-weight: 800;
}

.capability-name strong {
  margin-top: 4px;
  overflow-wrap: anywhere;
  font-size: 15px;
}

.capability-name em {
  width: max-content;
  margin-top: 5px;
  color: var(--muted);
  font-size: 11px;
  font-style: normal;
}

.capability-metric {
  min-width: 0;
}

.capability-metric > span,
.capability-metric > strong,
.capability-metric > small {
  display: block;
}

.capability-metric > span,
.capability-metric > small {
  color: var(--muted);
  font-size: 11px;
}

.capability-metric > strong {
  margin: 5px 0 3px;
  font-size: 18px;
}

.capability-metric > div {
  height: 5px;
  overflow: hidden;
  border-radius: 999px;
  background: #e2e8e5;
}

.capability-metric > div i {
  display: block;
  height: 100%;
  background: var(--teal);
}

.capability-recommend {
  text-align: right;
}

.capability-recommend button,
.recommend-learning {
  min-height: 34px;
  border: 1px solid #d4a851;
  border-radius: 6px;
  background: #fff4df;
  color: #805713;
  padding: 0 10px;
  font-size: 12px;
  font-weight: 800;
  white-space: nowrap;
}

.capability-recommend > span,
.recommendation-clear {
  color: var(--teal);
  font-size: 12px;
  font-weight: 800;
  white-space: nowrap;
}

.question-tabs {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1px;
  margin-bottom: 16px;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--line);
}

.question-tabs button {
  min-height: 42px;
  border: 0;
  background: #f3f6f2;
  color: var(--muted);
  font-weight: 800;
}

.question-tabs button.active {
  background: var(--charcoal);
  color: var(--white);
}

.scenario {
  margin-bottom: 16px;
  color: var(--ink);
  line-height: 1.65;
  font-weight: 700;
}

.choice-group {
  display: grid;
  gap: 10px;
}

.choice-group button {
  min-height: 48px;
  text-align: left;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fbfcf8;
  padding: 12px 14px;
}

.choice-group button.correct {
  border-color: var(--teal);
  background: #e7f2ef;
}

.choice-group button.wrong {
  border-color: var(--coral);
  background: #fff0ed;
}

.feedback {
  min-height: 62px;
  margin-top: 14px;
  padding: 12px 14px;
  border-radius: 8px;
  background: #f3f6f2;
  color: var(--muted);
  line-height: 1.55;
}

.test-shell,
.result-panel {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--white);
  padding: 22px;
  box-shadow: 0 8px 28px rgba(32, 53, 50, 0.05);
}

.test-topline,
.question-meta,
.test-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
}

.test-progress {
  height: 10px;
  border-radius: 999px;
  overflow: hidden;
  background: #e7ece9;
  margin: 14px 0 18px;
}

.test-progress span {
  display: block;
  width: 0;
  height: 100%;
  background: linear-gradient(90deg, var(--teal), var(--amber));
  transition: width 180ms ease;
}

.test-body {
  display: grid;
  grid-template-columns: 190px minmax(0, 1fr);
  gap: 18px;
}

.question-map {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 8px;
  align-content: start;
}

.question-map button {
  aspect-ratio: 1;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #f3f6f2;
  color: var(--muted);
  font-weight: 800;
}

.question-map button.answered {
  background: #e7f2ef;
  color: var(--teal);
}

.question-map button.active {
  background: var(--charcoal);
  color: var(--white);
}

.question-card {
  min-height: 430px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fbfcf8;
  padding: 20px;
}

.question-meta {
  color: var(--muted);
  font-weight: 800;
  margin-bottom: 14px;
}

.case-details {
  margin-top: 16px;
  overflow: hidden;
  border: 1px solid #b9d4cc;
  border-left: 4px solid var(--teal);
  border-radius: 0 8px 8px 0;
  background: #eef6f3;
}

.case-details summary {
  min-height: 48px;
  display: list-item;
  padding: 10px 14px;
  color: var(--teal);
  font-weight: 800;
  line-height: 28px;
  cursor: pointer;
}

.case-details[open] summary {
  border-bottom: 1px solid #cde0da;
}

.case-text {
  max-height: 320px;
  overflow-y: auto;
  scrollbar-gutter: stable;
  padding: 16px 18px 18px;
  color: var(--muted);
  line-height: 1.75;
  white-space: pre-line;
}

.answer-list {
  display: grid;
  gap: 10px;
  margin-top: 16px;
}

.answer-option {
  display: grid;
  grid-template-columns: 20px minmax(0, 1fr);
  gap: 10px;
  align-items: start;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--white);
  padding: 13px;
  line-height: 1.55;
}

.answer-option.checked {
  border-color: var(--teal);
  background: #e7f2ef;
}

.question-note {
  min-height: 42px;
  margin-top: 14px;
  color: var(--muted);
  font-weight: 800;
}

.test-actions {
  justify-content: flex-end;
  margin-top: 16px;
}

.test-actions .secondary-action {
  color: var(--ink);
  border-color: var(--line);
  background: #f3f6f2;
}

.result-panel {
  margin-top: 14px;
}

.result-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
  margin: 16px 0;
}

.result-grid article {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fbfcf8;
  padding: 16px;
}

.result-grid span {
  color: var(--muted);
}

.result-grid strong {
  display: block;
  margin-top: 8px;
  font-size: 28px;
}

.result-section-title {
  margin: 22px 0 8px;
}

.review-entry {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  margin-top: 16px;
  border-top: 1px solid var(--line);
  padding-top: 18px;
}

.review-entry h3,
.review-entry p {
  margin-bottom: 0;
}

.review-entry p {
  margin-top: 6px;
  color: var(--muted);
}

.review-entry-actions {
  display: flex;
  flex: 0 0 auto;
  align-items: center;
  gap: 10px;
}

.review-entry-actions button {
  white-space: nowrap;
}

.review-entry-actions .challenge-action {
  border: 1px solid #a86813;
  background: var(--amber);
  color: var(--charcoal);
  box-shadow: 0 8px 20px rgba(200, 132, 29, 0.2);
}

.review-entry-actions .challenge-action:hover {
  border-color: #91590e;
  background: #d9962f;
}

.answer-review {
  margin-top: 24px;
  border-top: 1px solid var(--line);
  padding-top: 24px;
}

.review-heading {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 16px;
}

.review-layout {
  display: grid;
  grid-template-columns: 170px minmax(0, 1fr);
  gap: 18px;
  align-items: start;
}

.review-question-map {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 8px;
}

.review-question-map button {
  aspect-ratio: 1;
  min-width: 0;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #f3f6f2;
  color: var(--muted);
  font-weight: 800;
}

.review-question-map button.correct {
  border-color: #91cbb5;
  background: #e7f2ef;
  color: var(--teal);
}

.review-question-map button.mastered {
  border-color: #4ea984;
  background: #d9eee6;
  color: #096a58;
}

.review-question-map button.missed {
  border-color: #e6b6ad;
  background: #fff0ed;
  color: #a94638;
}

.review-question-map button.active {
  border-color: var(--charcoal);
  background: var(--charcoal);
  color: var(--white);
}

.review-card {
  min-width: 0;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fbfcf8;
  padding: 20px;
}

.review-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 16px;
  margin-bottom: 14px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
}

.review-card > h3 {
  font-size: 20px;
  line-height: 1.55;
}

.learning-answer-head {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 16px;
  margin-top: 22px;
}

.learning-answer-head strong,
.learning-answer-head span {
  display: block;
}

.learning-answer-head strong {
  font-size: 16px;
}

.learning-answer-head div > span,
.analysis-entry > span {
  margin-top: 4px;
  color: var(--muted);
  font-size: 13px;
}

.learning-action-label {
  color: var(--teal);
  font-size: 13px;
  font-weight: 800;
}

.distribution-list {
  display: grid;
  margin-top: 10px;
  border-top: 1px solid var(--line);
}

.distribution-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(150px, 250px) 70px;
  gap: 14px;
  align-items: center;
  min-height: 70px;
  border-bottom: 1px solid var(--line);
  padding: 12px 0;
  width: 100%;
  border-top: 0;
  border-right: 0;
  border-left: 0;
  background: transparent;
  color: inherit;
  font: inherit;
  text-align: left;
}

.distribution-row.learning-choice {
  cursor: pointer;
}

.distribution-row.learning-choice:hover:not(:disabled) {
  background: #f3f6f2;
}

.distribution-row.learning-choice:focus-visible {
  outline: 2px solid var(--teal);
  outline-offset: 2px;
}

.distribution-row.learning-choice:disabled {
  cursor: default;
  opacity: 1;
}

.distribution-row.correct {
  color: var(--teal);
}

.distribution-row.selected-wrong {
  color: #a94638;
}

.distribution-option {
  display: grid;
  grid-template-columns: 22px 24px minmax(0, 1fr) auto;
  gap: 8px;
  align-items: center;
  line-height: 1.5;
}

.choice-control {
  position: relative;
  width: 18px;
  height: 18px;
  border: 2px solid #9aaba7;
  border-radius: 50%;
  background: var(--white);
}

.distribution-row.learning-choice:hover:not(:disabled) .choice-control {
  border-color: var(--teal);
}

.distribution-row.selected-wrong .choice-control {
  border-color: var(--coral);
  background: var(--coral);
}

.distribution-row.selected-wrong .choice-control::after {
  content: "×";
  position: absolute;
  inset: -4px 0 0;
  color: var(--white);
  text-align: center;
  font-size: 16px;
  font-weight: 800;
}

.distribution-row.correct .choice-control {
  border-color: var(--teal);
  background: var(--teal);
}

.distribution-row.correct .choice-control::after {
  content: "✓";
  position: absolute;
  inset: -3px 0 0;
  color: var(--white);
  text-align: center;
  font-size: 13px;
  font-weight: 800;
}

.answer-badge,
.choice-badge {
  min-height: 24px;
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  padding: 0 8px;
  font-size: 12px;
  font-style: normal;
  font-weight: 800;
  white-space: nowrap;
}

.answer-badge {
  background: #e7f2ef;
  color: var(--teal);
}

.choice-badge {
  background: #edf0f0;
  color: var(--ink);
}

.distribution-row.selected-wrong .choice-badge {
  background: #fff0ed;
  color: #a94638;
}

.distribution-bar {
  height: 10px;
  overflow: hidden;
  border-radius: 999px;
  background: #e1e7e4;
}

.distribution-bar span {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: #7d9995;
}

.distribution-row.correct .distribution-bar span {
  background: var(--teal);
}

.distribution-row.selected-wrong .distribution-bar span {
  background: var(--coral);
}

.distribution-rate {
  text-align: right;
  font-size: 14px;
}

.learning-feedback {
  margin-top: 16px;
  border-left: 4px solid #7d9995;
  background: #f3f6f2;
  padding: 13px 14px;
  color: var(--ink);
  line-height: 1.55;
}

.learning-feedback.wrong {
  border-left-color: var(--coral);
  background: #fff0ed;
  color: #8d352a;
}

.learning-feedback.correct {
  border-left-color: var(--teal);
  background: #e7f2ef;
  color: #096a58;
}

.analysis-entry {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-top: 14px;
}

.analysis-entry > span {
  margin-top: 0;
}

.analysis-toggle {
  border-color: var(--line);
  background: var(--white);
  color: var(--ink);
  flex: 0 0 auto;
}

.analysis-toggle:disabled {
  border-color: #d5ddda;
  background: #edf0ee;
  color: #899491;
  cursor: not-allowed;
}

.review-insight {
  display: grid;
  grid-template-columns: minmax(180px, 0.55fr) minmax(0, 1.45fr);
  gap: 18px;
  margin-top: 20px;
  background: #f3f6f2;
  padding: 16px;
}

.review-insight h4,
.option-reasons h4 {
  margin: 0 0 8px;
}

.review-insight p,
.option-reasons p {
  margin-bottom: 0;
  color: var(--muted);
  line-height: 1.6;
}

.review-verdict {
  border-left: 4px solid var(--teal);
  padding-left: 12px;
}

.review-verdict.missed {
  border-left-color: var(--coral);
}

.review-verdict strong,
.review-verdict span {
  display: block;
}

.review-verdict span {
  margin-top: 6px;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.45;
}

.chapter-competencies {
  grid-column: 1 / -1;
  border-top: 1px solid var(--line);
  padding-top: 13px;
}

.chapter-competencies strong,
.chapter-competencies span {
  display: block;
}

.chapter-competencies strong {
  margin-bottom: 6px;
  color: var(--teal);
  font-size: 13px;
}

.chapter-competencies span {
  color: var(--muted);
  line-height: 1.65;
}

.application-transfer {
  margin-top: 24px;
  border-top: 1px solid #b9d8d0;
  border-bottom: 1px solid #b9d8d0;
  background: #edf6f2;
  padding: 18px;
}

.application-transfer-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}

.application-transfer-head span,
.application-message span {
  display: block;
  color: var(--teal);
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0;
  text-transform: uppercase;
}

.application-transfer-head h4 {
  margin: 4px 0 3px;
  font-size: 20px;
}

.application-transfer-head p {
  margin: 0;
  color: var(--muted);
  line-height: 1.5;
}

.application-start {
  flex: 0 0 auto;
  border: 1px solid #c98419;
  border-radius: 5px;
  background: #d68d20;
  padding: 11px 16px;
  color: #172927;
  font: inherit;
  font-weight: 800;
  cursor: pointer;
  box-shadow: 0 5px 12px rgba(144, 91, 12, 0.17);
  transition: transform 160ms ease, box-shadow 160ms ease, background 160ms ease;
}

.application-start:hover {
  background: #e19a2f;
  transform: translateY(-2px);
  box-shadow: 0 8px 16px rgba(144, 91, 12, 0.22);
}

.application-start:focus-visible {
  outline: 3px solid rgba(20, 128, 116, 0.24);
  outline-offset: 3px;
}

.application-dialogue {
  display: grid;
  gap: 12px;
  margin-top: 18px;
}

.application-turn {
  display: grid;
  gap: 8px;
}

.application-message {
  max-width: 88%;
  border-left: 3px solid var(--teal);
  background: rgba(255, 255, 255, 0.78);
  padding: 11px 13px;
}

.application-message p {
  margin: 4px 0 0;
  color: var(--ink);
  line-height: 1.65;
  white-space: pre-wrap;
}

.application-message.learner-message {
  justify-self: end;
  border-left: 0;
  border-right: 3px solid #d18a22;
  background: #fff8e9;
}

.application-message.learner-message span {
  color: #926014;
  text-align: right;
}

.application-message.response-message {
  background: transparent;
  padding-top: 4px;
  padding-bottom: 4px;
}

.application-message.current-question {
  box-shadow: 0 7px 18px rgba(25, 70, 62, 0.1);
}

.application-form {
  margin-top: 14px;
}

.application-form label {
  display: block;
  margin-bottom: 7px;
  font-size: 13px;
  font-weight: 800;
}

.application-form textarea {
  box-sizing: border-box;
  width: 100%;
  resize: vertical;
  border: 1px solid #aac8c1;
  border-radius: 5px;
  background: rgba(255, 255, 255, 0.94);
  padding: 12px 13px;
  color: var(--ink);
  font: inherit;
  line-height: 1.55;
}

.application-form textarea:focus {
  border-color: var(--teal);
  outline: 3px solid rgba(20, 128, 116, 0.14);
}

.application-form > div {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  margin-top: 9px;
}

.application-form > div > span {
  color: var(--muted);
  font-size: 13px;
}

.application-competency-feedback {
  border-left: 4px solid #6856a0;
  background: #f4f1f8;
  padding: 15px 16px;
}

.application-competency-feedback > strong {
  display: block;
  margin-bottom: 8px;
  color: #51417f;
  font-size: 15px;
}

.application-competency-feedback p {
  margin: 7px 0 0;
  color: var(--ink);
  line-height: 1.7;
}

.application-competency-feedback b {
  color: #51417f;
}

.application-competency-feedback .application-next-step {
  margin-top: 11px;
  border-top: 1px solid #d9d1e7;
  padding-top: 10px;
  color: #51417f;
  font-weight: 750;
}

.application-evidence {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  border-left: 4px solid var(--teal);
  background: rgba(255, 255, 255, 0.82);
  padding: 13px 14px;
}

.application-evidence strong {
  width: 100%;
}

.application-evidence span {
  border: 1px solid #bfd8d2;
  border-radius: 999px;
  background: #f7fbf9;
  padding: 5px 9px;
  color: #27675d;
  font-size: 12px;
  font-weight: 800;
}

.option-reasons {
  margin-top: 22px;
}

.option-reasons article {
  border-top: 1px solid var(--line);
  padding: 14px 0;
}

.option-reasons article.your-mistake {
  border-left: 4px solid var(--coral);
  padding-left: 12px;
}

.option-reasons article > strong {
  display: flex;
  align-items: start;
  justify-content: space-between;
  gap: 12px;
  line-height: 1.5;
}

.option-reasons article > p {
  display: grid;
  grid-template-columns: max-content minmax(0, 1fr);
  gap: 8px;
  align-items: start;
}

.reason-flaw {
  border-left: 3px solid var(--coral);
  padding-left: 7px;
  color: #a94638;
  font-size: 12px;
  font-style: normal;
  font-weight: 800;
  line-height: 1.6;
  white-space: nowrap;
}

.common-choice-badge {
  flex: 0 0 auto;
  border-radius: 999px;
  background: #fff0ed;
  color: #a94638;
  padding: 3px 8px;
  font-size: 12px;
  font-style: normal;
  white-space: nowrap;
}

.review-actions {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  margin-top: 18px;
}

.review-actions .secondary-action {
  border-color: var(--line);
  background: var(--white);
  color: var(--ink);
}

.radar-result {
  margin: 16px 0;
}

.radar-card {
  display: grid;
  grid-template-columns: minmax(220px, 0.8fr) minmax(260px, 1fr);
  gap: 16px;
  align-items: center;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fbfcf8;
  padding: 16px;
}

.hero-radar .radar-card {
  min-height: 0;
  display: flex;
  flex-direction: column;
  gap: 6px;
  border-color: rgba(255, 255, 255, 0.26);
  background: rgba(11, 24, 25, 0.72);
  color: var(--white);
  padding: 14px 16px 12px;
  backdrop-filter: blur(12px);
}

.hero-radar .radar-card > div {
  display: contents;
}

.hero-radar .radar-card strong {
  order: 1;
  display: block;
  max-width: none;
  font-size: 16px;
  line-height: 1.4;
  text-align: center;
}

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

.radar-card span {
  margin-top: 6px;
  color: var(--muted);
  line-height: 1.45;
  font-size: 13px;
}

.radar-card svg {
  width: 100%;
  max-width: 360px;
  margin: 0 auto;
}

.radar-legend {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 14px;
  margin-top: 14px;
}

.radar-legend span {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-top: 0;
  font-size: 12px;
  font-weight: 800;
}

.radar-legend i {
  width: 18px;
  height: 4px;
  display: inline-block;
  border-radius: 999px;
}

.radar-legend i.personal {
  background: var(--teal);
}

.radar-legend i.norm {
  border-top: 2px dashed var(--amber);
}

.hero-radar .radar-card span {
  order: 3;
  margin-top: 0;
  color: rgba(255, 255, 255, 0.72);
  text-align: center;
}

.hero-radar .radar-card strong::before {
  display: none;
}

.hero-radar .radar-legend {
  display: none;
}

.hero-radar .radar-card svg {
  order: 2;
  max-width: 190px;
}

.hero-radar .radar-ring,
.hero-radar .radar-axis {
  stroke: rgba(255, 255, 255, 0.24);
}

.hero-radar .radar-label {
  fill: var(--white);
}

.radar-ring {
  fill: none;
  stroke: rgba(23, 32, 34, 0.12);
  stroke-width: 1;
}

.radar-axis {
  stroke: rgba(23, 32, 34, 0.12);
  stroke-width: 1;
}

.radar-area {
  fill: rgba(16, 123, 117, 0.32);
  stroke: var(--teal);
  stroke-width: 2;
}

.radar-norm-area {
  fill: rgba(200, 132, 29, 0.08);
  stroke: var(--amber);
  stroke-width: 2;
  stroke-dasharray: 6 4;
}

.hero-radar .radar-norm-area {
  fill: rgba(255, 190, 92, 0.08);
  stroke: #ffbe5c;
}

.radar-dot {
  fill: var(--teal);
  stroke: var(--white);
  stroke-width: 2;
}

.radar-label {
  fill: var(--ink);
  font-size: 10px;
  font-weight: 800;
  dominant-baseline: middle;
}

html[lang="en"] .radar-label {
  font-size: 8px;
}

html[lang="en"] .radar-card svg {
  overflow: visible;
}

.category-scoreboard {
  display: grid;
  gap: 10px;
  margin: 16px 0;
}

.category-row {
  display: grid;
  grid-template-columns: 170px minmax(140px, 1fr) 210px 76px 104px;
  gap: 14px;
  align-items: center;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fbfcf8;
  padding: 14px;
}

html[lang="en"] .category-row {
  grid-template-columns: 150px minmax(260px, 1fr) 210px;
  grid-template-areas:
    "identity meter status"
    "identity numbers action";
  column-gap: 18px;
  row-gap: 10px;
}

html[lang="en"] .category-row > div:first-child {
  grid-area: identity;
}

html[lang="en"] .category-row .category-meter {
  grid-area: meter;
}

html[lang="en"] .category-row .category-numbers {
  grid-area: numbers;
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

html[lang="en"] .category-row > em {
  grid-area: status;
}

html[lang="en"] .category-row > .recommend-learning,
html[lang="en"] .category-row > .recommendation-clear {
  grid-area: action;
}

html[lang="en"] .category-row > em,
html[lang="en"] .category-row > .recommend-learning,
html[lang="en"] .category-row > .recommendation-clear {
  width: 100%;
  min-width: 0;
  white-space: normal;
  text-align: center;
}

html[lang="en"] .category-row > .recommendation-clear {
  min-height: 34px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.category-row strong,
.category-row span {
  display: block;
}

.category-row div > span {
  margin-top: 4px;
  color: var(--muted);
  font-size: 13px;
}

.category-meter {
  height: 12px;
  border-radius: 999px;
  overflow: hidden;
  background: #e7ece9;
}

.category-meter span {
  display: block;
  height: 100%;
  background: linear-gradient(90deg, var(--amber), var(--teal));
}

.category-numbers {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 8px;
}

.category-numbers span {
  min-height: 30px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  background: #f3f6f2;
  color: var(--ink);
  font-size: 12px;
  font-weight: 800;
  text-align: center;
}

.category-row em {
  width: max-content;
  min-height: 30px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  background: #eef6f3;
  color: var(--teal);
  padding: 0 10px;
  font-style: normal;
  font-weight: 800;
  font-size: 13px;
}

.category-row.improve em {
  background: #fff4df;
  color: #8b5c13;
}

.category-row.strong em {
  background: #e7f2ef;
  color: var(--teal);
}

.assessment-lab {
  padding: 28px 0 12px;
}

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

.assessment-head .secondary-action {
  color: var(--ink);
  border-color: var(--line);
  background: var(--white);
}

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

.calibration-card {
  min-height: 230px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--white);
  padding: 18px;
  box-shadow: 0 10px 34px rgba(23, 32, 34, 0.05);
}

.calibration-card p {
  color: var(--muted);
  line-height: 1.6;
}

.stat-row {
  display: grid;
  grid-template-columns: auto 1fr auto 1fr;
  gap: 8px;
  align-items: baseline;
  margin-top: auto;
}

.stat-row strong {
  font-size: 30px;
  color: var(--teal);
}

.stat-row span {
  color: var(--muted);
  font-size: 13px;
}

.metric-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: auto;
}

.metric-tags span {
  min-height: 30px;
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  background: #f3f6f2;
  color: var(--ink);
  padding: 0 10px;
  font-weight: 800;
  font-size: 13px;
}

.blueprint-bars {
  display: grid;
  gap: 12px;
  margin-top: auto;
}

.blueprint-bars label {
  display: grid;
  gap: 8px;
  color: var(--muted);
  font-weight: 800;
}

.blueprint-bars label::after {
  content: "";
  height: 10px;
  border-radius: 999px;
  background: #e7ece9;
  grid-row: 2;
  grid-column: 1;
}

.blueprint-bars span {
  height: 10px;
  border-radius: 999px;
  background: linear-gradient(90deg, var(--teal), var(--coral));
  grid-row: 2;
  grid-column: 1;
  z-index: 1;
}

.item-table {
  margin-top: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  overflow: hidden;
  background: var(--white);
}

.item-table > div {
  display: grid;
  grid-template-columns: 1.1fr 1.1fr 0.8fr 0.7fr;
  gap: 12px;
  align-items: center;
  min-height: 50px;
  padding: 12px 16px;
  border-top: 1px solid var(--line);
}

.item-table > div:first-child {
  border-top: 0;
}

.item-table-head {
  background: #f3f6f2;
  color: var(--muted);
  font-weight: 800;
}

.item-table strong {
  width: max-content;
  min-height: 28px;
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  background: #fff4df;
  color: #8b5c13;
  padding: 0 10px;
  font-size: 13px;
}

.content-studio {
  display: grid;
  grid-template-columns: 0.8fr 1.2fr;
  gap: 28px;
  align-items: center;
  padding: 34px 0 54px;
}

.studio-copy p {
  line-height: 1.7;
}

.upload-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
}

.upload-tile {
  min-height: 150px;
  display: grid;
  align-content: center;
  gap: 10px;
  border: 1px dashed #9fb4ad;
  border-radius: 8px;
  background: var(--white);
  color: var(--ink);
  padding: 18px;
  text-align: left;
}

.upload-tile span {
  color: var(--teal);
  font-size: 28px;
}

.upload-tile strong {
  font-size: 18px;
}

.studio-manager,
.studio-library {
  grid-column: 1 / -1;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--white);
}

.studio-manager {
  padding: 24px;
}

.studio-manager-head,
.studio-library-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
}

.studio-manager-head h3,
.studio-library-head h3 {
  margin: 4px 0 0;
  font-size: 22px;
}

.studio-form {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
  margin-top: 22px;
}

.studio-form label {
  display: grid;
  gap: 8px;
  color: var(--muted);
  font-size: 14px;
  font-weight: 700;
}

.studio-form input,
.studio-form select,
.studio-form textarea {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #fbfcfb;
  color: var(--ink);
  font: inherit;
  padding: 12px 13px;
}

.studio-form textarea {
  resize: vertical;
}

.studio-file-field,
.studio-notes-field,
.studio-form-actions {
  grid-column: 1 / -1;
}

.studio-file-field {
  border: 1px dashed #91aaa3;
  border-radius: 7px;
  background: #f6faf8;
  padding: 16px;
}

.studio-file-field input {
  border: 0;
  background: transparent;
  padding: 0;
}

.studio-file-field small {
  color: var(--muted);
  font-weight: 500;
}

.studio-form-actions {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
}

.studio-library {
  padding: 22px 24px;
}

.studio-library-head > span {
  color: var(--muted);
  font-weight: 700;
}

.studio-empty {
  margin-top: 18px;
  border-top: 1px solid var(--line);
  color: var(--muted);
  padding: 24px 0 4px;
  text-align: center;
}

.studio-items {
  display: grid;
  gap: 0;
  margin-top: 16px;
}

.studio-item {
  display: grid;
  grid-template-columns: minmax(0, 1.5fr) minmax(150px, 0.8fr) auto;
  gap: 18px;
  align-items: center;
  border-top: 1px solid var(--line);
  padding: 16px 0;
}

.studio-item-copy {
  min-width: 0;
}

.studio-item-copy strong,
.studio-item-copy small {
  display: block;
}

.studio-item-copy strong {
  overflow-wrap: anywhere;
}

.studio-item-copy small,
.studio-item-meta {
  color: var(--muted);
  margin-top: 5px;
}

.studio-item-meta {
  display: grid;
  gap: 4px;
  font-size: 13px;
}

.studio-item-actions {
  display: flex;
  gap: 8px;
}

.studio-item-actions button {
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #f7f9f8;
  color: var(--ink);
  min-height: 36px;
  padding: 0 12px;
}

.studio-item-actions .delete {
  color: #a9483d;
}

.studio-status {
  display: inline-flex;
  width: fit-content;
  margin-bottom: 6px;
  border-radius: 999px;
  background: #eef3f1;
  color: #52645f;
  padding: 4px 9px;
  font-size: 12px;
  font-weight: 800;
}

.studio-status.published {
  background: #e4f3ef;
  color: #107b75;
}

@media (max-width: 880px) {
  .metric-strip,
  .account-panel,
  .main-grid,
  .workspace-grid,
  .content-studio,
  .assessment-grid,
  .test-body,
  .result-grid,
  .category-row,
  .radar-card,
  .review-layout,
  .review-insight,
  .upload-grid,
  .dual-diagnosis {
    grid-template-columns: 1fr;
  }

  .case-learning-preview,
  .case-facts,
  .case-context-grid,
  .case-expert-grid {
    grid-template-columns: 1fr;
  }

  .category-numbers {
    grid-template-columns: 1fr;
  }

  html[lang="en"] .category-row {
    grid-template-columns: 1fr;
    grid-template-areas:
      "identity"
      "meter"
      "numbers"
      "status"
      "action";
  }

  html[lang="en"] .category-row .category-numbers {
    grid-template-columns: 1fr;
  }

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

  .question-map {
    grid-template-columns: repeat(10, 1fr);
  }

  .item-table > div {
    grid-template-columns: 1fr;
  }

  .assessment-head {
    align-items: flex-start;
    flex-direction: column;
  }

  .review-entry,
  .review-heading,
  .analysis-entry {
    align-items: stretch;
    flex-direction: column;
  }

  .application-transfer-head,
  .application-form > div {
    align-items: stretch;
    flex-direction: column;
  }

  .application-start,
  .application-form .primary-action {
    width: 100%;
  }

  .application-message {
    max-width: 100%;
  }

  .review-entry-actions {
    align-items: stretch;
    flex-direction: column;
  }

  .review-question-map {
    grid-template-columns: repeat(10, 1fr);
  }

  .capability-progress-head {
    align-items: flex-start;
    flex-direction: column;
  }

  .capability-legend {
    justify-content: flex-start;
  }

  .capability-progress-row {
    grid-template-columns: minmax(140px, 1.2fr) repeat(2, minmax(90px, 1fr));
  }

  .capability-name {
    grid-row: span 2;
  }

  .account-form,
  .account-actions {
    flex-direction: column;
  }

  .account-panel > div:first-child,
  .account-form,
  .account-actions,
  .account-history {
    grid-column: 1;
    grid-row: auto;
  }

  .hero {
    min-height: 0;
    padding-bottom: 44px;
  }

  .hero-content {
    padding-top: 0;
    transform: none;
  }

  .hero-calling {
    transform: none;
  }

  .hero-main {
    grid-template-columns: 1fr;
    padding-top: 24px;
  }

  .hero-radar {
    position: static;
    max-width: 280px;
    justify-self: start;
  }

  .hero-radar .radar-card {
    min-height: 0;
  }

  .panel-heading {
    align-items: flex-start;
    flex-direction: column;
  }

  .segmented {
    width: 100%;
  }
}

@media (max-width: 560px) {
  .topbar,
  .hero-actions,
  .coach-input,
  .case-learning-intro,
  .case-learning-controls,
  .case-player-actions,
  .chapter-review-submit-head,
  .chapter-review-submit-actions {
    align-items: stretch;
    flex-direction: column;
  }

  .topbar {
    gap: 14px;
  }

  .nav-actions {
    width: 100%;
  }

  .nav-actions {
    justify-content: flex-start;
  }

  .hero {
    min-height: auto;
  }

  .hero-media {
    object-position: 48% center;
  }

  .hero-overlay {
    background: rgba(10, 17, 17, 0.72);
  }

  h1 {
    font-size: 44px;
  }

  .case-learning-controls {
    display: flex;
  }

  .case-learning-controls .primary-action {
    width: 100%;
  }

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

  .case-stepper button:nth-child(2) {
    border-right: 0;
  }

  .case-stepper button:nth-child(-n + 2) {
    border-bottom: 1px solid var(--line);
  }

  .case-player-head {
    position: static;
    margin-top: 0;
    backdrop-filter: none;
  }

  .chapter-review-map {
    grid-template-columns: repeat(6, minmax(0, 1fr));
  }

  .workspace-menu {
    gap: 6px;
  }

  .workspace-menu button {
    min-height: 62px;
    grid-template-columns: 26px minmax(0, 1fr);
    padding: 9px;
  }

  .workspace-menu button small {
    display: none;
  }

  .workspace-menu button strong {
    align-self: center;
    line-height: 1.35;
  }

  .chapter-practice-head {
    position: static;
    margin-top: 0;
    padding-top: 0;
    backdrop-filter: none;
  }

  .chapter-question-body {
    scroll-margin-top: 12px;
  }

  .chapter-question-title,
  .chapter-answer-list {
    min-height: 0;
  }

  .chapter-navigation {
    bottom: 8px;
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    margin-right: -4px;
    margin-left: -4px;
  }

  .chapter-navigation .primary-action,
  .chapter-navigation .secondary-action {
    min-width: 0;
  }

  .nav-actions {
    align-self: flex-end;
  }

  .primary-action,
  .secondary-action {
    width: 100%;
  }

  .learning-filters {
    grid-template-columns: 1fr;
  }

  .dimension-row {
    grid-template-columns: minmax(0, 1fr) auto auto;
    gap: 7px 10px;
    padding: 10px 4px;
  }

  .dimension-name {
    grid-column: 1;
    grid-row: 1;
  }

  .dimension-scope {
    grid-column: 2;
    grid-row: 1;
  }

  .dimension-score {
    grid-column: 3;
    grid-row: 1;
  }

  .dimension-meter {
    grid-column: 1 / 3;
    grid-row: 2;
  }

  .dimension-status {
    grid-column: 3;
    grid-row: 2;
  }

  .dimension-group > summary {
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 8px 12px;
    padding: 8px 0;
  }

  .module-card {
    grid-template-columns: 44px minmax(0, 1fr);
  }

  .module-list {
    grid-template-columns: 1fr;
  }

  .module-card .module-action {
    grid-column: 1 / -1;
    width: 100%;
  }

  .test-topline,
  .test-actions,
  .review-actions {
    align-items: stretch;
    flex-direction: column;
  }

  .review-question-map {
    grid-template-columns: repeat(6, 1fr);
  }

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

  .capability-name {
    grid-column: 1 / -1;
    grid-row: auto;
  }

  .capability-recommend {
    grid-column: 1 / -1;
    text-align: left;
  }

  .distribution-row {
    grid-template-columns: 1fr 58px;
  }

  .distribution-bar {
    grid-column: 1 / -1;
    grid-row: 2;
  }

  .distribution-rate {
    grid-column: 2;
    grid-row: 1;
  }

  .case-text {
    max-height: 260px;
    padding: 14px;
  }

  .question-map {
    grid-template-columns: repeat(6, 1fr);
  }

  .studio-form,
  .studio-item {
    grid-template-columns: 1fr;
  }

  .studio-item-actions {
    justify-content: flex-start;
  }
}

@media (max-width: 900px) {
  .caselab-shell {
    grid-template-columns: 1fr;
  }

  .caselab-library {
    border-right: 0;
    border-bottom: 1px solid var(--line);
  }

  .caselab-case-list {
    grid-template-columns: repeat(3, minmax(220px, 1fr));
    overflow-x: auto;
    padding-bottom: 5px;
  }

  .caselab-toolbar .caselab-reset {
    margin-left: 0;
  }
}

@media (max-width: 560px) {
  .caselab-shell {
    margin-right: -8px;
    margin-left: -8px;
    border-radius: 6px;
  }

  .caselab-dialogue {
    padding: 16px 12px;
  }

  .caselab-toolbar {
    flex-wrap: nowrap;
    overflow-x: auto;
  }

  .caselab-message {
    width: 92%;
  }

  .caselab-source {
    width: 100%;
  }

  .caselab-composer {
    grid-template-columns: 1fr;
  }

  .caselab-composer .primary-action {
    min-height: 44px;
  }
}
