/* [project]/src/app/globals.css [app-client] (css) */
:root {
  --bg: #f4f8f0;
  --surface: #fff;
  --surface-soft: #f7fee7;
  --surface-blue: #eff6ff;
  --surface-amber: #fff7ed;
  --text: #102014;
  --text-strong: #08111f;
  --muted: #53675c;
  --line: #dcead4;
  --line-strong: #bde8a8;
  --green: #42d900;
  --green-dark: #228600;
  --blue: #2563eb;
  --sky: #37bdf8;
  --violet: #7c3aed;
  --amber: #f59e0b;
  --red: #ff5138;
  --shadow-soft: 0 16px 38px #1850251a;
  --shadow-button: 0 6px 0 #0e3f1429;
  --radius-panel: 18px;
  --radius-card: 8px;
  --radius-pill: 999px;
  --child-green: #58cc02;
  --child-green-dark: #46a302;
  --child-blue: #1cb0f6;
  --child-sky: #eaf8ff;
  --child-yellow: #ffc800;
  --child-orange: #ff9600;
  --child-red: #ff4b4b;
  --child-purple: #8b5cf6;
  --child-ink: #13241b;
  --child-muted: #5d7067;
  --child-line: #d9edcf;
  --child-soft: #f4ffef;
  --child-bg-gradient: linear-gradient(180deg, #ffffffb3, #fff0 34%),
    linear-gradient(135deg, #fbfff7 0%, #effbe8 52%, #eafbff 100%);
  --child-font-body: "Nunito", "Inter", "PingFang SC", "Noto Sans SC", "Microsoft YaHei", Arial, sans-serif;
  --child-shadow-button: 0 7px 0 var(--child-green-dark);
  --child-shadow-button-pressed: 0 3px 0 var(--child-green-dark);
  --child-shadow-card: 0 14px 34px #20703424;
  --child-shadow-card-soft: 0 12px 28px #2070341c;
  --child-border-tint: #58cc0238;
  --child-border-tint-strong: #58cc023d;
  --child-radius-card: 22px;
  --child-radius-card-lg: 26px;
  --child-radius-button: 16px;
  --child-progress-track: #dce9d7;
  --child-progress-gradient: linear-gradient(90deg, var(--child-green), var(--child-blue));
  --child-surface-correct: #f2ffec;
  --child-surface-wrong: #fff4f4;
}

* {
  box-sizing: border-box;
}

html, body {
  min-height: 100%;
}

body {
  color: var(--text);
  background: linear-gradient(#fbfff6 0%, #eef7ff 58%, #fff7ed 100%);
  margin: 0;
  font-family: Arial, Helvetica, sans-serif;
}

a {
  color: inherit;
}

button, a {
  -webkit-tap-highlight-color: transparent;
}

button {
  font-family: inherit;
}

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

h1, h2, h3, strong {
  color: var(--text-strong);
}

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

.page-shell, .placement-shell {
  width: min(1720px, 100% - 56px);
  margin: 0 auto;
  padding: 26px 0 46px;
}

.eyebrow {
  color: var(--green-dark);
  letter-spacing: 0;
  text-transform: uppercase;
  margin: 0 0 6px;
  font-size: .8rem;
  font-weight: 900;
}

.app-header {
  border: 1px solid var(--line);
  border-radius: var(--radius-panel);
  min-height: 86px;
  box-shadow: var(--shadow-soft);
  background: #fffffff0;
  grid-template-columns: auto minmax(260px, 1fr) auto;
  align-items: center;
  gap: 18px;
  padding: 14px 18px;
  display: grid;
}

.brand-block {
  align-items: center;
  gap: 12px;
  min-width: 230px;
  text-decoration: none;
  display: inline-flex;
}

.brand-mark {
  color: #fff;
  background: linear-gradient(#62ff12, #2dbc00);
  border-radius: 16px;
  place-items: center;
  width: 58px;
  height: 58px;
  font-size: 2rem;
  font-weight: 900;
  display: grid;
  box-shadow: inset 0 -7px #00000024, 0 9px 16px #31bc0033;
}

.brand-block strong, .brand-block small {
  display: block;
}

.brand-block strong {
  font-size: 1.55rem;
  line-height: 1;
}

.brand-block small {
  color: var(--green-dark);
  margin-top: 6px;
  font-size: .9rem;
  font-weight: 900;
}

.nav-strip, .metric-strip {
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
  display: flex;
}

.nav-strip {
  justify-content: center;
}

.metric-strip {
  justify-content: flex-end;
}

.nav-pill-link, .primary-action {
  border-radius: var(--radius-pill);
  cursor: pointer;
  justify-content: center;
  align-items: center;
  gap: 8px;
  min-height: 44px;
  font-weight: 900;
  text-decoration: none;
  transition: transform .15s, box-shadow .15s, border-color .15s, background-color .15s;
  display: inline-flex;
}

.nav-pill-link {
  border: 1px solid var(--line);
  min-width: 124px;
  color: var(--text-strong);
  background: #fff;
  padding: 0 18px;
  box-shadow: 0 4px #0f172a1a;
}

.nav-pill-link.active, .primary-action {
  color: #fff;
  box-shadow: inset 0 -6px 0 #00000029, var(--shadow-button);
  background: linear-gradient(#62ff12, #31c400);
  border: 0;
}

.nav-pill-link:hover, .primary-action:hover, .route-node:hover, .task-row:hover, .option-button:hover {
  transform: translateY(-2px);
}

.nav-pill-link:active, .primary-action:active, .option-button:active {
  box-shadow: none;
  transform: translateY(2px);
}

.primary-action {
  min-width: 144px;
  padding: 0 20px;
  font-size: 1rem;
}

.primary-action.secondary {
  color: var(--blue);
  background: #fff;
  border: 1px solid #bfdbfe;
  box-shadow: 0 4px #2563eb1f;
}

.metric-pill {
  border: 1px solid var(--line);
  border-radius: var(--radius-card);
  background: #fff;
  min-width: 104px;
  padding: 11px 14px;
  box-shadow: 0 4px #0f172a14;
}

.metric-pill span {
  color: var(--muted);
  font-size: .76rem;
  font-weight: 900;
  display: block;
}

.metric-pill strong {
  margin-top: 3px;
  font-size: 1.22rem;
  line-height: 1;
  display: block;
}

.today-layout {
  grid-template-columns: minmax(0, 1fr) 420px;
  align-items: stretch;
  gap: 22px;
  margin-top: 22px;
  display: grid;
}

.route-board {
  border: 1px solid var(--line);
  border-radius: var(--radius-panel);
  min-height: 540px;
  box-shadow: var(--shadow-soft);
  background: linear-gradient(#fffffff0, #f8fdf2f5);
  padding: 26px;
}

.route-board-head {
  border-bottom: 1px solid var(--line);
  justify-content: space-between;
  align-items: flex-start;
  gap: 24px;
  padding-bottom: 22px;
  display: flex;
}

.route-board-head h1, .assessment-board h1 {
  margin-bottom: 10px;
  font-size: 3rem;
  line-height: 1.02;
}

.route-lede, .assessment-board p {
  max-width: 820px;
  color: var(--muted);
  margin-bottom: 0;
  font-size: 1.08rem;
  font-weight: 850;
  line-height: 1.48;
}

.route-track {
  grid-template-columns: repeat(4, minmax(130px, 1fr));
  gap: 14px;
  margin-top: 34px;
  display: grid;
  position: relative;
}

.route-track:before {
  content: "";
  border-radius: var(--radius-pill);
  background: #dce8d6;
  height: 8px;
  position: absolute;
  top: 42px;
  left: 8%;
  right: 8%;
}

.route-node {
  border: 1px solid var(--line);
  border-radius: var(--radius-card);
  background: #fff;
  min-height: 174px;
  padding: 16px;
  transition: transform .15s, box-shadow .15s, border-color .15s;
  position: relative;
  box-shadow: 0 5px #0f172a14;
}

.route-node.active {
  background: #f7fee7;
  border-color: #8eea65;
  box-shadow: 0 7px #31bc001f, 0 18px 26px #31bc001f;
}

.route-node.boss {
  background: #fff7ed;
  border-color: #ffd1c8;
}

.route-node-icon, .panel-icon, .task-index {
  color: #fff;
  place-items: center;
  display: grid;
  box-shadow: inset 0 -6px #00000024;
}

.route-node-icon {
  border-radius: 18px;
  width: 62px;
  height: 62px;
  margin-bottom: 12px;
}

.route-node span, .route-node small {
  color: var(--muted);
  font-weight: 900;
  display: block;
}

.route-node span {
  font-size: .88rem;
}

.route-node strong {
  margin: 5px 0 8px;
  font-size: 1.35rem;
  line-height: 1.1;
  display: block;
}

.route-node small {
  font-size: .82rem;
}

.tone-green {
  background: linear-gradient(#68ff16, #2ebd00);
}

.tone-blue {
  background: linear-gradient(#67d8ff, #2563eb);
}

.tone-violet {
  background: linear-gradient(#a78bfa, #7c3aed);
}

.tone-amber {
  background: linear-gradient(#fbbf24, #f97316);
}

.tone-red {
  background: linear-gradient(#ff8a73, #ff5138);
}

.route-progress-row {
  border: 1px solid var(--line);
  border-radius: var(--radius-card);
  background: #fff;
  grid-template-columns: auto minmax(180px, 1fr) auto;
  align-items: center;
  gap: 16px;
  margin-top: 28px;
  padding: 16px;
  display: grid;
}

.route-progress-row div:first-child span, .route-progress-row p {
  color: var(--muted);
  font-weight: 900;
}

.route-progress-row div:first-child strong {
  margin-top: 2px;
  font-size: 1.5rem;
  line-height: 1;
  display: block;
}

.route-progress-row p {
  margin-bottom: 0;
}

.progress-track, .gate-meter {
  border-radius: var(--radius-pill);
  background: #dfeadc;
  overflow: hidden;
}

.progress-track {
  height: 12px;
}

.progress-track span, .gate-meter span {
  border-radius: inherit;
  background: linear-gradient(90deg, var(--green), var(--sky));
  height: 100%;
  display: block;
}

.today-task-panel {
  border: 1px solid var(--line);
  border-radius: var(--radius-panel);
  min-height: 540px;
  box-shadow: var(--shadow-soft);
  background: #fffffff5;
  padding: 18px;
}

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

.task-panel-head h2 {
  margin-bottom: 0;
  font-size: 2rem;
  line-height: 1.05;
}

.task-panel-head > span {
  width: 48px;
  height: 48px;
  color: var(--green-dark);
  background: #ecfdf5;
  border-radius: 16px;
  place-items: center;
  font-size: 1.25rem;
  font-weight: 900;
  display: grid;
}

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

.task-row {
  border: 1px solid var(--line);
  border-radius: var(--radius-card);
  background: #fff;
  grid-template-columns: 48px minmax(0, 1fr) auto;
  align-items: center;
  gap: 12px;
  min-height: 108px;
  padding: 13px;
  transition: transform .15s, border-color .15s, box-shadow .15s;
  display: grid;
  box-shadow: 0 4px #0f172a0f;
}

.task-row.current {
  background: #f7fee7;
  border-color: #8eea65;
}

.task-index {
  border-radius: 15px;
  width: 48px;
  height: 48px;
}

.task-row span {
  color: var(--green-dark);
  margin-bottom: 3px;
  font-size: .78rem;
  font-weight: 900;
  display: inline-flex;
}

.task-row h3 {
  margin-bottom: 4px;
  font-size: 1.18rem;
}

.task-row p {
  color: var(--muted);
  margin-bottom: 0;
  font-size: .9rem;
  font-weight: 800;
  line-height: 1.35;
}

.task-row > strong {
  border-radius: var(--radius-pill);
  background: var(--surface-blue);
  min-width: 34px;
  height: 34px;
  color: var(--blue);
  place-items: center;
  font-size: .95rem;
  display: grid;
}

.boss-strip {
  border-radius: var(--radius-card);
  background: var(--surface-amber);
  color: #c2410c;
  border: 1px solid #ffd1c8;
  align-items: center;
  gap: 12px;
  margin-top: 14px;
  padding: 14px;
  display: flex;
}

.boss-strip strong, .boss-strip span {
  display: block;
}

.boss-strip strong {
  color: #9a3412;
}

.boss-strip span {
  margin-top: 2px;
  font-size: .9rem;
  font-weight: 850;
}

.stats-band {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
  margin-top: 18px;
  display: grid;
}

.route-stat-card {
  border: 1px solid var(--line);
  border-radius: var(--radius-card);
  background: #fff;
  grid-template-columns: 46px minmax(0, 1fr);
  align-items: center;
  gap: 8px 14px;
  min-height: 98px;
  padding: 16px;
  display: grid;
  box-shadow: 0 4px #0f172a0f;
}

.route-stat-card svg {
  background: var(--surface-blue);
  width: 46px;
  height: 46px;
  color: var(--blue);
  border-radius: 14px;
  grid-row: span 2;
  padding: 10px;
}

.route-stat-card span {
  font-size: 2rem;
  font-weight: 900;
  line-height: 1;
  display: block;
}

.route-stat-card p {
  color: var(--muted);
  margin-bottom: 0;
  font-weight: 900;
}

.assessment-layout {
  grid-template-columns: minmax(0, 1fr) 430px;
  align-items: stretch;
  gap: 22px;
  display: grid;
}

.assessment-layout.testing {
  grid-template-columns: minmax(0, 1fr) 380px;
}

.assessment-board, .question-panel, .assessment-side, .score-grid {
  border: 1px solid var(--line);
  border-radius: var(--radius-panel);
  box-shadow: var(--shadow-soft);
  background: #fffffff5;
}

.assessment-board {
  min-height: 420px;
  padding: 30px;
}

.assessment-board.result {
  min-height: 360px;
}

.assessment-kicker {
  color: var(--blue);
  letter-spacing: 0;
  text-transform: uppercase;
  align-items: center;
  gap: 8px;
  margin-bottom: 12px;
  font-size: .86rem;
  font-weight: 900;
  display: inline-flex;
}

.assessment-actions {
  flex-wrap: wrap;
  align-items: center;
  gap: 14px;
  margin-top: 28px;
  display: flex;
}

.assessment-actions > span {
  color: var(--muted);
  font-weight: 900;
}

.assessment-side {
  padding: 18px;
}

.question-panel {
  min-height: 640px;
  padding: 22px;
}

.question-meta {
  color: var(--muted);
  justify-content: space-between;
  gap: 14px;
  margin-bottom: 14px;
  font-weight: 900;
  display: flex;
}

.question-meta strong {
  color: var(--blue);
}

.question-card {
  border-radius: var(--radius-card);
  background: #fffdf7;
  border: 1px solid #f3cf80;
  min-height: 540px;
  padding: 24px;
  box-shadow: 0 4px #f59e0b1f;
}

.question-type {
  flex-wrap: wrap;
  gap: 9px;
  margin-bottom: 20px;
  display: flex;
}

.question-type span {
  border-radius: var(--radius-pill);
  min-height: 32px;
  color: var(--blue);
  background: #eef2ff;
  align-items: center;
  gap: 6px;
  padding: 0 11px;
  font-size: .84rem;
  font-weight: 900;
  display: inline-flex;
}

.question-type span.tone-green, .question-type span.tone-blue, .question-type span.tone-violet, .question-type span.tone-amber {
  color: #fff;
}

.listening-notice {
  border-radius: var(--radius-card);
  background: var(--surface-blue);
  color: #075985;
  border: 1px solid #bae6fd;
  align-items: center;
  gap: 9px;
  margin-bottom: 16px;
  padding: 12px;
  font-weight: 900;
  display: flex;
}

.listening-notice span {
  color: #38677d;
  font-size: .92rem;
}

.question-passage {
  border-radius: var(--radius-card);
  color: var(--muted);
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  margin-bottom: 18px;
  padding: 15px;
  font-weight: 800;
  line-height: 1.52;
}

.question-card h1 {
  margin-bottom: 24px;
  font-size: 2.35rem;
  line-height: 1.12;
}

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

.option-button {
  border-radius: var(--radius-card);
  cursor: pointer;
  text-align: left;
  background: #fff;
  border: 2px solid #dce9d6;
  grid-template-columns: 48px minmax(0, 1fr);
  align-items: center;
  gap: 13px;
  min-height: 82px;
  padding: 13px;
  transition: transform .15s, box-shadow .15s, border-color .15s;
  display: grid;
  box-shadow: 0 4px #0f172a14;
}

.option-button:hover {
  border-color: var(--sky);
  box-shadow: 0 6px #2563eb1a;
}

.option-button span {
  color: #fff;
  background: linear-gradient(#67d8ff, #2563eb);
  border-radius: 15px;
  place-items: center;
  width: 48px;
  height: 48px;
  font-size: 1.15rem;
  font-weight: 900;
  display: grid;
  box-shadow: inset 0 -5px #00000024;
}

.option-button strong {
  min-width: 0;
  font-size: 1.06rem;
  line-height: 1.24;
}

.panel-icon {
  border-radius: 16px;
  width: 50px;
  height: 50px;
  margin-bottom: 14px;
}

.gate-status {
  border: 1px solid var(--line);
  border-radius: var(--radius-card);
  background: #fff;
  padding: 16px;
}

.gate-status h2 {
  margin-bottom: 12px;
  font-size: 1.35rem;
}

.gate-status p {
  color: var(--muted);
  font-weight: 850;
  line-height: 1.45;
}

.gate-status strong {
  color: var(--green-dark);
  margin-top: 12px;
  font-size: 1.05rem;
  display: block;
}

.gate-meter {
  height: 11px;
  margin-bottom: 12px;
}

.gate-overview {
  gap: 11px;
  display: grid;
}

.gate-status + .gate-overview {
  margin-top: 16px;
}

.gate-card {
  border: 1px solid var(--line);
  border-radius: var(--radius-card);
  background: #fff;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  min-height: 82px;
  padding: 12px;
  display: flex;
  box-shadow: 0 3px #0f172a0f;
}

.gate-card.active {
  background: var(--surface-soft);
  border-color: #8eea65;
}

.gate-card-main {
  grid-template-columns: 42px minmax(0, 1fr);
  align-items: center;
  gap: 4px 10px;
  min-width: 0;
  display: grid;
}

.gate-card-main span {
  color: #fff;
  background: linear-gradient(#62ff12, #31c400);
  border-radius: 14px;
  grid-row: span 2;
  place-items: center;
  width: 42px;
  height: 42px;
  font-weight: 900;
  display: grid;
  box-shadow: inset 0 -5px #00000024;
}

.gate-card h3 {
  margin-bottom: 0;
  font-size: .98rem;
  line-height: 1.15;
}

.gate-card p {
  color: var(--muted);
  grid-column: 2;
  margin-bottom: 0;
  font-size: .84rem;
  font-weight: 850;
}

.gate-card strong {
  color: var(--green-dark);
  flex: none;
  align-items: center;
  gap: 5px;
  font-size: .9rem;
  display: inline-flex;
}

.score-grid {
  gap: 12px;
  padding: 18px;
  display: grid;
}

.score-card {
  border: 1px solid var(--line);
  border-radius: var(--radius-card);
  background: #fff;
  min-height: 124px;
  padding: 14px;
}

.score-card.passed {
  background: #f0fdf4;
  border-color: #a7f3d0;
}

.score-card span, .score-card em {
  color: var(--muted);
  font-size: .86rem;
  font-style: normal;
  font-weight: 900;
}

.score-card strong {
  margin: 10px 0 5px;
  font-size: 1.85rem;
  line-height: 1;
  display: block;
}

.score-card p {
  color: var(--muted);
  margin-bottom: 8px;
  font-weight: 850;
}

:focus-visible {
  outline-offset: 3px;
  outline: 3px solid #2563eb73;
}

@media (max-width: 1180px) {
  .app-header, .today-layout, .assessment-layout, .assessment-layout.testing {
    grid-template-columns: 1fr;
  }

  .nav-strip, .metric-strip {
    justify-content: flex-start;
  }

  .today-task-panel, .route-board {
    min-height: 0;
  }

  .assessment-side {
    order: -1;
  }
}

@media (max-width: 820px) {
  .page-shell, .placement-shell {
    width: min(100% - 24px, 1720px);
    padding-top: 12px;
  }

  .route-board-head, .assessment-actions {
    flex-direction: column;
    align-items: stretch;
  }

  .route-board-head h1, .assessment-board h1 {
    font-size: 2.25rem;
  }

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

  .route-track:before {
    display: none;
  }

  .route-progress-row, .stats-band, .option-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 560px) {
  .page-shell, .placement-shell {
    width: min(100% - 20px, 1720px);
  }

  .app-header, .route-board, .today-task-panel, .assessment-board, .question-panel, .assessment-side {
    border-radius: 16px;
    padding: 14px;
  }

  .brand-block {
    min-width: 0;
  }

  .brand-mark {
    width: 50px;
    height: 50px;
    font-size: 1.72rem;
  }

  .brand-block strong {
    font-size: 1.35rem;
  }

  .nav-strip, .metric-strip {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    width: 100%;
    display: grid;
  }

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

  .nav-pill-link, .metric-pill, .primary-action {
    width: 100%;
    min-width: 0;
  }

  .route-track {
    grid-template-columns: 1fr;
    margin-top: 18px;
  }

  .route-node {
    min-height: 122px;
  }

  .task-row {
    grid-template-columns: 44px minmax(0, 1fr) auto;
  }

  .task-index, .route-stat-card svg {
    width: 44px;
    height: 44px;
  }

  .route-board-head h1, .assessment-board h1, .question-card h1 {
    font-size: 1.9rem;
  }

  .route-lede, .assessment-board p {
    font-size: .98rem;
  }

  .question-card {
    min-height: 0;
    padding: 16px;
  }
}

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

