/* ============================================================
   alumnAI — Components
   Mirrors the original prototype's visual language with the
   alumnAI brand palette (navy + bright blue) instead of purple.
   ============================================================ */

/* ---- Buttons ---- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-2);
  padding: 10px 18px;
  border-radius: var(--radius);
  font-size: var(--fs-base);
  font-weight: 500;
  cursor: pointer;
  transition: background var(--t-fast) var(--ease),
              border-color var(--t-fast) var(--ease),
              color var(--t-fast) var(--ease),
              transform var(--t-fast) var(--ease);
  border: 1px solid transparent;
  text-decoration: none;
  user-select: none;
  white-space: nowrap;
}
.btn:active { transform: translateY(1px); }
.btn:disabled { cursor: not-allowed; opacity: 0.55; transform: none; }

.btn-primary { background: var(--brand-blue); color: white; }
.btn-primary:hover:not(:disabled) { background: var(--brand-blue-dark); }

.btn-secondary {
  background: var(--surface);
  border-color: var(--border-strong);
  color: var(--text);
}
.btn-secondary:hover:not(:disabled) { background: var(--surface-2); }

.btn-ghost { background: transparent; color: var(--text-2); }
.btn-ghost:hover:not(:disabled) { background: var(--surface-2); color: var(--text); }

.btn-success { background: var(--success); color: white; }
.btn-success:hover:not(:disabled) { background: var(--success-dark); }

.btn-lg { padding: 14px 26px; font-size: var(--fs-md); }
.btn-sm { padding: 7px 12px; font-size: var(--fs-sm); }

/* ---- Pills / Tags ---- */
.pill {
  display: inline-block;
  background: var(--brand-blue-soft);
  color: var(--brand-navy);
  font-size: var(--fs-xs);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  padding: 4px 10px;
  border-radius: 100px;
  font-weight: 500;
}

/* ---- Progress bars ---- */
.progress {
  height: 8px;
  background: var(--surface-2);
  border-radius: 100px;
  overflow: hidden;
}
.progress-fill {
  height: 100%;
  background: var(--brand-blue);
  border-radius: 100px;
  transition: width 0.4s var(--ease);
}
.progress-sm { height: 6px; }

/* ---- Hero ---- */
.hero {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-xl);
  padding: 28px 32px;
  margin-bottom: var(--space-6);
  display: flex;
  justify-content: space-between;
  gap: var(--space-6);
  flex-wrap: wrap;
}
.hero-content { flex: 1; min-width: 250px; }
.hero h1 { font-size: var(--fs-2xl); font-weight: 600; margin-bottom: 6px; }
.hero p { color: var(--text-2); font-size: var(--fs-base); margin-bottom: var(--space-4); }
.hero-actions { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; }

.rank-card {
  background: var(--brand-blue-soft);
  border-radius: var(--radius-lg);
  padding: 16px 20px;
  min-width: 180px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  border: 1px solid rgba(27,45,82,0.10);
}
.rank-label {
  font-size: var(--fs-xs);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--brand-navy);
  font-weight: 500;
}
.rank-value { font-size: var(--fs-lg); font-weight: 600; color: var(--brand-navy); margin-top: 2px; }
.rank-next { font-size: var(--fs-sm); color: var(--brand-navy); opacity: 0.7; margin-top: 4px; }

/* ---- Stats grid ---- */
.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 12px;
  margin-bottom: 28px;
}
.stat-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 16px 18px;
}
.stat-card-label { font-size: var(--fs-sm); color: var(--text-3); margin-bottom: 4px; font-weight: 500; }
.stat-card-value { font-size: var(--fs-xl); font-weight: 600; }
.stat-card-meta { font-size: var(--fs-sm); color: var(--text-3); margin-top: 2px; }

/* ---- Section titles ---- */
.section-title { font-size: var(--fs-md); font-weight: 600; margin: 8px 0 14px; }

/* ---- Unit cards (list rows on Dashboard & Courses) ---- */
.units-list { display: flex; flex-direction: column; gap: 10px; margin-bottom: 32px; }
.unit-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 16px 20px;
  display: flex;
  align-items: center;
  gap: 18px;
  transition: border-color 0.15s, transform 0.1s;
  cursor: pointer;
  text-decoration: none;
  color: inherit;
}
.unit-card:hover { border-color: var(--border-strong); text-decoration: none; }
.unit-card.locked { opacity: 0.6; cursor: not-allowed; }
.unit-card.locked:hover { border-color: var(--border); }
.unit-card.completed { border-left: 4px solid var(--success); }
.unit-num {
  width: 36px; height: 36px;
  background: var(--surface-2);
  border-radius: 8px;
  display: flex; align-items: center; justify-content: center;
  font-weight: 600; font-size: var(--fs-base);
  flex-shrink: 0;
}
.unit-card.active-unit .unit-num { background: var(--brand-blue); color: white; }
.unit-card.completed .unit-num { background: var(--success); color: white; }
.unit-info { flex: 1; min-width: 0; }
.unit-title { font-weight: 500; font-size: var(--fs-md); margin-bottom: 2px; }
.unit-meta {
  font-size: var(--fs-sm); color: var(--text-3);
  display: flex; gap: 12px; flex-wrap: wrap;
}
.unit-progress {
  width: 100px;
  flex-shrink: 0;
}
.unit-status {
  font-size: var(--fs-sm);
  color: var(--text-3);
  min-width: 56px;
  text-align: right;
  flex-shrink: 0;
}
.lock-icon { width: 14px; height: 14px; color: var(--text-3); }

/* ---- Unit detail header ---- */
.unit-header {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-xl);
  padding: 28px 32px;
  margin-bottom: 20px;
}
.unit-tag {
  display: inline-block;
  background: var(--brand-blue-soft);
  color: var(--brand-navy);
  font-size: var(--fs-xs);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  padding: 4px 10px;
  border-radius: 100px;
  font-weight: 500;
  margin-bottom: 10px;
}
.unit-detail-title { font-size: var(--fs-3xl); font-weight: 600; margin-bottom: 8px; }
.unit-desc { color: var(--text-2); font-size: var(--fs-base); margin-bottom: 16px; max-width: 700px; }
.unit-detail-meta {
  display: flex; gap: 20px; flex-wrap: wrap;
  font-size: var(--fs-base); color: var(--text-2);
  padding-top: 14px; border-top: 1px solid var(--border);
}
.unit-detail-meta div { display: flex; align-items: center; gap: 6px; }

/* ---- Lesson cards ---- */
.lessons-list { display: flex; flex-direction: column; gap: 8px; margin-bottom: 32px; }
.lesson-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 14px 18px;
  display: flex;
  align-items: center;
  gap: 14px;
  cursor: pointer;
  transition: border-color 0.15s, background 0.12s;
  text-decoration: none;
  color: inherit;
}
.lesson-card:hover { border-color: var(--border-strong); text-decoration: none; }
.lesson-card.locked { opacity: 0.5; cursor: not-allowed; }
.lesson-num { font-size: var(--fs-sm); color: var(--text-3); font-weight: 500; min-width: 30px; }
.lesson-icon { width: 22px; height: 22px; flex-shrink: 0; color: var(--text-2); }
.lesson-info { flex: 1; min-width: 0; }
.lesson-title { font-weight: 500; font-size: var(--fs-base); }
.lesson-sub { font-size: var(--fs-sm); color: var(--text-3); margin-top: 2px; }
.lesson-status {
  font-size: var(--fs-sm);
  color: var(--text-3);
  display: flex; align-items: center; gap: 4px;
}
.lesson-status.done { color: var(--success); }
.check-circle {
  width: 18px; height: 18px;
  border-radius: 50%;
  border: 1.5px solid var(--text-3);
  flex-shrink: 0;
}
.check-circle.done {
  background: var(--success);
  border-color: var(--success);
  display: flex; align-items: center; justify-content: center;
}
.check-circle.done::after {
  content: ''; width: 4px; height: 8px;
  border-right: 2px solid white; border-bottom: 2px solid white;
  transform: rotate(45deg) translate(-1px, -1px);
}

/* ---- Lesson page ---- */
.lesson-page {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-xl);
  padding: 32px 40px;
  margin-bottom: 24px;
}
.lesson-page h1 { font-size: var(--fs-2xl); font-weight: 600; margin-bottom: 6px; }
.lesson-page-sub { font-size: var(--fs-sm); color: var(--text-3); margin-bottom: 24px; }
.lesson-nav {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: 28px;
  padding-top: 20px;
  border-top: 1px solid var(--border);
}

/* ---- Placeholder block (terse) ---- */
.placeholder-block {
  background: var(--surface-2);
  border-radius: var(--radius-lg);
  padding: 28px;
  margin: 20px 0;
  text-align: center;
  border: 1px dashed var(--border-strong);
}
.placeholder-block .pl-icon {
  width: 38px; height: 38px;
  margin: 0 auto 10px;
  color: var(--text-3);
}
.placeholder-block h3 { font-size: var(--fs-md); font-weight: 500; margin-bottom: 4px; }
.placeholder-block p { font-size: var(--fs-sm); color: var(--text-3); }

/* ---- Objectives box ---- */
.objectives {
  background: var(--info-soft);
  border-radius: var(--radius);
  padding: 14px 18px;
  margin-bottom: 20px;
}
.objectives-label {
  font-size: var(--fs-xs);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--info);
  font-weight: 500;
  margin-bottom: 8px;
}
.objectives ul { padding-left: 18px; font-size: var(--fs-base); color: var(--text); }
.objectives li { margin-bottom: 4px; }

/* ---- Badges grid ---- */
.badges-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
  gap: 14px;
}
.badge-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 20px 16px;
  text-align: center;
}
.badge-card.locked { opacity: 0.45; }
.badge-emoji { font-size: 38px; margin-bottom: 8px; }
.badge-name { font-weight: 500; font-size: var(--fs-base); margin-bottom: 4px; }
.badge-desc { font-size: var(--fs-sm); color: var(--text-3); }

/* ---- Sandbox grid ---- */
.sandbox-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 14px;
}
.sandbox-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 18px;
}
.sandbox-card.locked { opacity: 0.55; }
.sandbox-card h3 { font-size: var(--fs-md); font-weight: 500; margin-bottom: 4px; }
.sandbox-card p { font-size: var(--fs-sm); color: var(--text-2); margin-bottom: 12px; }

/* ---- Leaderboard ---- */
.lb-tabs { display: flex; gap: 6px; flex-wrap: wrap; margin-top: 8px; }
.lb-tab {
  padding: 8px 14px; background: var(--surface); border: 1px solid var(--border);
  border-radius: var(--radius-pill); font-size: var(--fs-sm); font-weight: 500;
  cursor: pointer; transition: all 0.12s var(--ease);
}
.lb-tab:hover { background: var(--surface-2); }
.lb-tab.active { background: var(--brand-blue-soft); border-color: var(--brand-blue); color: var(--brand-navy); }
.lb-summary {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(110px, 1fr));
  gap: 10px; margin: 16px 0;
}
.lb-stat { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-lg); padding: 12px 14px; }
.lb-stat-label { font-size: var(--fs-xs); color: var(--text-3); text-transform: uppercase; letter-spacing: 0.06em; font-weight: 600; }
.lb-stat-value { font-size: var(--fs-xl); font-weight: 700; margin-top: 4px; }
.lb-table { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-lg); overflow: hidden; }
.lb-row {
  display: flex; align-items: center; gap: 14px; padding: 12px 18px;
  border-bottom: 1px solid var(--border);
}
.lb-row:last-child { border-bottom: none; }
.lb-row.lb-me { background: var(--brand-blue-soft); }
.lb-pos { font-size: var(--fs-md); font-weight: 700; min-width: 36px; }
.lb-avatar {
  width: 36px; height: 36px; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-size: var(--fs-sm); font-weight: 600;
}
.lb-name { flex: 1; min-width: 0; }
.lb-tier { font-size: var(--fs-xs); color: var(--text-3); margin-top: 2px; }
.lb-xp { font-weight: 600; color: var(--brand-blue); }

/* ---- Prompt Playground ---- */
.pp-template {
  padding: 6px 12px; background: var(--surface-2); border: 1px solid var(--border);
  border-radius: var(--radius-pill); font-size: var(--fs-sm); font-weight: 500; cursor: pointer;
  transition: all 0.12s var(--ease);
}
.pp-template:hover { background: var(--brand-blue-soft); border-color: var(--brand-blue); color: var(--brand-navy); }

/* ---- Unit 7–11 components ---- */

/* Ethics line (7.3) */
.ethics-line { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
@media (max-width: 600px) { .ethics-line { grid-template-columns: 1fr; } }
.el-ok, .el-no { border-radius: var(--radius-lg); padding: 14px 18px; }
.el-ok { background: var(--success-soft); color: var(--success-dark); }
.el-no { background: var(--danger-soft); color: var(--danger); }
.el-ok ul, .el-no ul { padding-left: 18px; margin-top: 8px; font-size: var(--fs-sm); }

/* Debate (10.8) */
.debate { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
@media (max-width: 600px) { .debate { grid-template-columns: 1fr; } }
.debate-side { border-radius: var(--radius-lg); padding: 14px 18px; }
.debate-pro { background: var(--success-soft); color: var(--success-dark); }
.debate-con { background: var(--warning-soft); color: var(--warning); }
.debate-label { font-weight: 700; text-transform: uppercase; letter-spacing: 0.06em; font-size: var(--fs-xs); margin-bottom: 6px; }
.debate-side ul { padding-left: 18px; font-size: var(--fs-sm); }
.debate-side li { margin-bottom: 4px; }

/* Data table (11.6) */
.data-table {
  width: 100%; border-collapse: collapse; background: var(--surface);
  border: 1px solid var(--border); border-radius: var(--radius-lg);
  font-size: var(--fs-sm); overflow: hidden;
}
.data-table th, .data-table td {
  padding: 8px 12px; text-align: left; border-bottom: 1px solid var(--border);
}
.data-table th { background: var(--surface-2); font-weight: 600; font-size: var(--fs-xs); text-transform: uppercase; letter-spacing: 0.06em; color: var(--text-2); }
.data-table tbody tr:last-child td { border-bottom: none; }
.cell-bad { background: var(--danger-soft); color: var(--danger); font-style: italic; }

/* ---- Unit 6 components ---- */

/* RTCF cards */
.rtcf-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 10px; }
.rtcf-card {
  background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-lg);
  padding: 14px; position: relative;
}
.rtcf-letter {
  width: 32px; height: 32px; background: var(--brand-blue); color: white;
  border-radius: 50%; display: flex; align-items: center; justify-content: center;
  font-weight: 700; margin-bottom: 8px;
}
.rtcf-name { font-weight: 600; font-size: var(--fs-md); margin-bottom: 4px; }
.rtcf-ex { font-size: var(--fs-sm); color: var(--text-2); font-style: italic; }

/* Shot ladder */
.shot-ladder { display: flex; flex-direction: column; gap: 10px; }
.shot-card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-lg); padding: 14px 16px; }

/* Mistakes list */
.mistakes-list { display: flex; flex-direction: column; gap: 10px; }
.mistake-row { display: flex; gap: 12px; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-lg); padding: 12px 16px; font-size: var(--fs-base); }
.mistake-num {
  width: 28px; height: 28px; border-radius: 50%; background: var(--danger-soft); color: var(--danger);
  display: inline-flex; align-items: center; justify-content: center; font-weight: 700; flex-shrink: 0;
}

/* Prompt Battle */
.battle-strip {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 8px;
  margin: 16px 0;
}
@media (max-width: 640px) { .battle-strip { grid-template-columns: repeat(2, 1fr); } }
.battle-step {
  background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius);
  padding: 10px 8px; cursor: pointer; text-align: center;
  font-family: inherit;
  transition: border-color 0.12s var(--ease), background 0.12s var(--ease);
}
.battle-step:hover { border-color: var(--border-strong); }
.battle-step.active { background: var(--brand-blue-soft); border-color: var(--brand-blue); }
.battle-step.done { background: var(--success-soft); border-color: var(--success); }
.bs-num { font-size: var(--fs-sm); font-weight: 600; }
.bs-score { font-size: var(--fs-xs); color: var(--text-2); margin-top: 2px; }

/* ---- Unit 4 & 5 components ---- */

/* Modality / category cards (used in 4.1, 4.3, 5.3) */
.modality-grid {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); gap: 10px;
}
.modality-card {
  background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-lg);
  padding: 14px; text-align: center;
}
.modality-icon { font-size: 28px; margin-bottom: 6px; }
.modality-name { font-weight: 600; font-size: var(--fs-md); }
.modality-ex { font-size: var(--fs-sm); color: var(--text-2); margin-top: 4px; }

/* LLM comparison table */
.llm-compare { display: flex; flex-direction: column; gap: 0; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-lg); overflow: hidden; }
.llm-row { display: grid; grid-template-columns: 1fr 1fr 2fr; gap: 12px; padding: 12px 16px; border-bottom: 1px solid var(--border); font-size: var(--fs-base); }
.llm-row:last-child { border-bottom: none; }
.llm-head { background: var(--surface-2); font-weight: 600; font-size: var(--fs-xs); text-transform: uppercase; letter-spacing: 0.06em; color: var(--text-2); }

/* Vision examples */
.vision-examples { display: grid; grid-template-columns: repeat(auto-fit, minmax(120px, 1fr)); gap: 10px; }
.vision-card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-lg); padding: 14px; text-align: center; }
.vision-icon { font-size: 28px; margin-bottom: 4px; }
.vision-label { font-size: var(--fs-sm); color: var(--text); font-weight: 500; }

/* Speech flow */
.speech-flow { display: flex; flex-direction: column; gap: 8px; }
.sp-step { display: flex; gap: 12px; align-items: center; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-lg); padding: 12px 16px; }
.sp-num { width: 28px; height: 28px; border-radius: 50%; background: var(--brand-blue); color: white; display: flex; align-items: center; justify-content: center; font-weight: 700; }

/* Recommendation cycle */
.rec-cycle { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.rec-step { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 10px 14px; font-size: var(--fs-sm); flex: 1; min-width: 150px; text-align: center; }
.rec-arrow { font-size: var(--fs-lg); color: var(--brand-blue); }

/* Robot ladder */
.robot-ladder { display: flex; flex-direction: column; gap: 8px; }
.robot-step { padding: 12px 16px; border-radius: var(--radius); font-size: var(--fs-sm); }
.robot-step.working { background: var(--success-soft); color: var(--success-dark); }
.robot-step.partial { background: var(--warning-soft); color: var(--warning); }
.robot-step.hard    { background: var(--danger-soft);  color: var(--danger); }

/* Personal AI Map (4.7) */
.ai-cat-section { margin-bottom: 18px; }
.ai-cat-title { font-weight: 600; font-size: var(--fs-md); display: flex; justify-content: space-between; align-items: center; margin-bottom: 8px; }
.ai-cat-count { font-size: var(--fs-xs); background: var(--surface-2); padding: 2px 8px; border-radius: 999px; font-weight: 500; color: var(--text-2); }
.ai-tool-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(130px, 1fr)); gap: 8px; }
.ai-tool {
  background: var(--surface); border: 1.5px solid var(--border); border-radius: var(--radius-lg);
  padding: 12px 8px; text-align: center; cursor: pointer; position: relative;
  transition: all 0.12s var(--ease);
}
.ai-tool:hover { border-color: var(--brand-blue); }
.ai-tool.used { background: var(--brand-blue-soft); border-color: var(--brand-blue); }
.ai-tool-icon { font-size: 24px; margin-bottom: 4px; }
.ai-tool-name { font-size: var(--fs-sm); font-weight: 500; }
.ai-tool-check { position: absolute; top: 4px; right: 6px; color: var(--brand-blue); font-weight: 700; }

/* Unit 5 — Tool matcher table */
.tool-matcher { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-lg); overflow: hidden; }
.tool-row { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; padding: 10px 16px; border-bottom: 1px solid var(--border); font-size: var(--fs-base); }
.tool-row:last-child { border-bottom: none; }
.tool-head { background: var(--surface-2); font-weight: 600; font-size: var(--fs-xs); text-transform: uppercase; letter-spacing: 0.06em; color: var(--text-2); }

/* Hidden AI grid (5.5) */
.hidden-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 10px; }
.hidden-card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-lg); padding: 12px 14px; }

/* Tasks (5.7) */
.task-list { display: flex; flex-direction: column; gap: 10px; }
.task-card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-lg); padding: 14px 16px; }
.task-card.done { background: var(--success-soft); border-color: rgba(30,138,95,0.2); }
.task-row { display: flex; gap: 14px; align-items: flex-start; }
.task-icon { font-size: 28px; }
.task-title { font-weight: 600; font-size: var(--fs-base); }
.task-detail { color: var(--text-2); font-size: var(--fs-sm); margin: 4px 0 8px; }
.task-note {
  width: 100%; min-height: 50px; padding: 8px 10px;
  border: 1px solid var(--border); border-radius: var(--radius);
  font-size: var(--fs-sm); font-family: var(--font-sans);
  background: var(--surface-2);
}
.task-note:focus { outline: none; border-color: var(--brand-blue); background: var(--surface); }
.check-circle { background: transparent; padding: 0; cursor: pointer; }

/* ---- Unit 3 components ---- */
.confidence-demo { background: var(--surface-2); border-radius: var(--radius-lg); padding: 16px; margin-top: 16px; }
.conf-label { font-size: var(--fs-sm); font-weight: 600; color: var(--text-2); margin-bottom: 10px; text-transform: uppercase; letter-spacing: 0.06em; }
.conf-items { display: flex; flex-direction: column; gap: 8px; }
.conf-row { display: flex; align-items: center; gap: 10px; font-size: var(--fs-sm); }
.conf-row > span:first-child { min-width: 60px; }
.conf-row > .progress { flex: 1; }
.conf-row > span:last-child { min-width: 40px; text-align: right; color: var(--text-2); }

.train-vs-inf { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
@media (max-width: 600px) { .train-vs-inf { grid-template-columns: 1fr; } }
.ti-col { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-lg); padding: 16px 18px; }
.ti-title { font-weight: 600; margin-bottom: 8px; color: var(--brand-navy); }
.ti-col ul { padding-left: 18px; font-size: var(--fs-sm); color: var(--text-2); }
.ti-col li { margin-bottom: 4px; }

/* Train-a-classifier lab */
.lab { margin: 16px 0; }
.lab-section-title { font-size: var(--fs-sm); font-weight: 600; color: var(--text-2); margin-bottom: 8px; text-transform: uppercase; letter-spacing: 0.06em; }
.lab-bank { background: var(--surface-2); border-radius: var(--radius-lg); padding: 16px; margin-bottom: 14px; min-height: 80px; }
.lab-bins { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; margin-bottom: 14px; }
@media (max-width: 600px) { .lab-bins { grid-template-columns: 1fr; } }
.lab-bin {
  background: var(--surface);
  border: 2px dashed var(--border-strong);
  border-radius: var(--radius-lg);
  padding: 12px;
  min-height: 90px;
  transition: all 0.15s var(--ease);
}
.lab-bin.drag-over { border-color: var(--brand-blue); background: var(--brand-blue-soft); }
.lab-bin-title { font-weight: 600; font-size: var(--fs-sm); margin-bottom: 8px; display: flex; justify-content: space-between; }
.lab-bin-count {
  background: var(--surface-2); padding: 2px 8px; border-radius: 999px;
  font-size: var(--fs-xs); font-weight: 600; color: var(--text-2);
}
.shape-row { display: flex; flex-wrap: wrap; gap: 8px; min-height: 40px; }
.shape {
  width: 36px; height: 36px;
  cursor: grab;
  transition: transform 0.1s var(--ease);
  box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}
.shape:hover { transform: scale(1.1); }
.shape.dragging { opacity: 0.4; }
.shape-circle { border-radius: 50%; }
.shape-square { border-radius: 4px; }
.shape-triangle {
  width: 0; height: 0;
  background: transparent !important;
  border-left: 18px solid transparent;
  border-right: 18px solid transparent;
}
.shape-triangle { border-bottom-style: solid; border-bottom-width: 36px; }
/* Override: render triangle color via border */
.shape.shape-triangle[style*="background"] { background: transparent !important; }
.shape.shape-star, .shape.shape-pentagon { border-radius: 8px; transform: rotate(45deg); }

.lab-actions { display: flex; align-items: center; gap: 8px; margin: 16px 0; flex-wrap: wrap; }
.lab-test { background: var(--surface-2); border-radius: var(--radius-lg); padding: 16px; }
.test-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); gap: 10px; }
.test-item {
  background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius);
  padding: 12px; display: flex; flex-direction: column; align-items: center; gap: 8px;
}
.test-result {
  width: 100%; padding: 8px 10px; background: var(--surface-2);
  border-radius: var(--radius); font-size: var(--fs-sm); margin-top: 4px;
}

/* ---- Unit 2 components ---- */

/* Nesting dolls (AI ⊃ ML ⊃ DL) */
.nesting-dolls {
  margin: 20px 0;
  display: flex;
  justify-content: center;
}
.nest {
  border: 2px solid;
  border-radius: var(--radius-xl);
  padding: 20px 24px;
  text-align: center;
}
.nest-label { font-weight: 600; margin-bottom: 12px; }
.n-ai { border-color: var(--brand-navy); background: rgba(27,45,82,0.04); width: 100%; max-width: 480px; }
.n-ai > .nest-label { color: var(--brand-navy); }
.n-ml { border-color: var(--brand-blue); background: var(--brand-blue-soft); margin: 12px auto 0; max-width: 380px; }
.n-ml > .nest-label { color: var(--brand-blue-dark); }
.n-dl { border-color: var(--success); background: var(--success-soft); margin: 12px auto 0; max-width: 280px; padding: 14px; }
.n-dl > .nest-label { color: var(--success-dark); }

/* History timeline */
.history-timeline {
  display: flex; flex-direction: column;
  gap: 10px;
  margin: 16px 0;
  position: relative;
}
.history-item {
  display: flex;
  gap: 16px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 14px 18px;
}
.history-year {
  font-weight: 700; color: var(--brand-blue); font-size: var(--fs-md);
  min-width: 60px; padding-top: 2px;
}
.history-title { font-weight: 600; margin-bottom: 4px; }
.history-desc { font-size: var(--fs-sm); color: var(--text-2); }

/* AI tiers */
.ai-tiers {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 12px;
  margin: 20px 0;
}
.tier {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 18px 20px;
}
.tier-label { font-weight: 600; font-size: var(--fs-md); margin-bottom: 4px; }
.tier-state {
  display: inline-block;
  font-size: var(--fs-xs);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  font-weight: 600;
  padding: 3px 10px;
  border-radius: 100px;
  margin-bottom: 10px;
}
.tier-narrow .tier-state { background: var(--success-soft); color: var(--success-dark); }
.tier-general .tier-state { background: var(--warning-soft); color: var(--warning); }
.tier-super .tier-state { background: var(--danger-soft); color: var(--danger); }
.tier p { font-size: var(--fs-sm); color: var(--text-2); }

/* Scene grid (AI in Your Day) */
.scene-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 12px;
  margin: 16px 0;
}
.scene-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 16px 18px;
}
.scene-header { display: flex; align-items: center; gap: 10px; margin-bottom: 8px; }
.scene-icon { font-size: 28px; }
.scene-title { font-weight: 600; font-size: var(--fs-md); }
.scene-visible { color: var(--text-2); font-size: var(--fs-sm); margin-bottom: 12px; line-height: 1.5; }
.scene-hidden {
  background: var(--brand-blue-soft);
  border-radius: var(--radius);
  padding: 10px 14px;
  margin-top: 10px;
}
.scene-hidden-label {
  font-size: var(--fs-xs);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  font-weight: 600;
  color: var(--brand-navy);
  margin-bottom: 6px;
}
.scene-hidden ul { padding-left: 18px; font-size: var(--fs-sm); color: var(--brand-navy); }
.scene-hidden li { margin-bottom: 3px; }

/* Spot the AI */
.spot-list { display: flex; flex-direction: column; gap: 10px; margin: 16px 0; }
.spot-item {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 14px 18px;
}
.spot-question { font-weight: 500; margin-bottom: 10px; }
.spot-buttons { display: flex; gap: 8px; flex-wrap: wrap; }
.spot-correct { background: var(--success-soft) !important; border-color: var(--success) !important; color: var(--success-dark) !important; }
.spot-correct::before { content: '✓ '; }
.spot-incorrect { background: var(--danger-soft) !important; border-color: var(--danger) !important; color: var(--danger) !important; }
.spot-incorrect::before { content: '✗ '; }

/* ---- Video lesson (player + note-catcher) ---- */
.video-lesson {
  display: grid;
  grid-template-columns: 1.5fr 1fr;
  gap: 16px;
  margin: 16px 0;
}
@media (max-width: 920px) {
  .video-lesson { grid-template-columns: 1fr; }
}
.video-pane {
  background: #0E1116;
  border-radius: var(--radius-lg);
  overflow: hidden;
  aspect-ratio: 16 / 9;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
}
.video-placeholder {
  width: 100%;
  height: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, var(--brand-navy), var(--brand-navy-dark));
  color: #FFFFFF;
  text-align: center;
  padding: 24px;
}
.video-placeholder .play-icon {
  width: 56px; height: 56px;
  color: rgba(255,255,255,0.55);
  margin-bottom: 12px;
}
.video-ph-title { font-size: var(--fs-lg); font-weight: 600; margin-bottom: 6px; }
.video-ph-desc { font-size: var(--fs-sm); color: rgba(255,255,255,0.7); }
.video-player { width: 100%; height: 100%; border: 0; }

.notes-pane {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  max-height: 100%;
}
.notes-header {
  display: flex; justify-content: space-between; align-items: center;
  font-size: var(--fs-sm); color: var(--text-2); font-weight: 600;
}
.notes-saved {
  color: var(--success-dark); font-weight: 500; font-size: var(--fs-xs);
}
.notes-area {
  width: 100%; min-height: 120px;
  padding: 10px 12px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  font-size: var(--fs-base);
  font-family: var(--font-sans);
  resize: vertical;
  background: var(--surface-2);
  transition: border-color var(--t-fast) var(--ease);
}
.notes-area:focus { outline: none; border-color: var(--brand-blue); background: var(--surface); }

.notes-q-title {
  font-size: var(--fs-sm); font-weight: 600; color: var(--text);
  margin-top: 4px;
}
.notes-q-sub {
  font-size: var(--fs-xs); color: var(--text-3); margin-bottom: 4px;
}
.vq-block {
  background: var(--surface-2);
  border-radius: var(--radius);
  padding: 12px;
  margin-top: 6px;
}
.vq-question {
  font-size: var(--fs-sm);
  font-weight: 500;
  color: var(--text);
  margin-bottom: 8px;
  line-height: 1.4;
}
.vq-options { display: flex; flex-direction: column; gap: 6px; }
.vq-option {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 7px 10px;
  font-size: var(--fs-sm);
  text-align: left;
  cursor: pointer;
  transition: all 0.12s var(--ease);
}
.vq-option:hover { border-color: var(--brand-blue); background: var(--brand-blue-soft); }
.vq-option.selected {
  background: var(--brand-blue-soft);
  border-color: var(--brand-blue);
  color: var(--brand-navy);
  font-weight: 500;
}
.vq-text {
  width: 100%;
  min-height: 60px;
  padding: 8px 10px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  font-size: var(--fs-sm);
  font-family: var(--font-sans);
  background: var(--surface);
  resize: vertical;
}
.vq-text:focus { outline: none; border-color: var(--brand-blue); }

/* ---- Path options (Choose Your Path) ---- */
.path-options {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 12px;
  margin: 16px 0;
}
.path-option {
  background: var(--surface);
  border: 1.5px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 18px;
  cursor: pointer;
  transition: all 0.15s var(--ease);
  text-align: left;
}
.path-option:hover { border-color: var(--brand-blue); background: var(--brand-blue-soft); }
.path-option.selected { border-color: var(--brand-blue); background: var(--brand-blue-soft); }
.path-option-title { font-weight: 500; margin-bottom: 4px; font-size: var(--fs-base); color: var(--text); }
.path-option-desc { font-size: var(--fs-sm); color: var(--text-2); }

/* ---- Scavenger hunt ---- */
.scavenger-list {
  background: var(--surface-2);
  border-radius: var(--radius);
  padding: 16px 20px;
  margin: 16px 0;
}
.scavenger-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 0;
  font-size: var(--fs-base);
  color: var(--text-2);
}
.scavenger-item.done { color: var(--text); text-decoration: line-through; opacity: 0.7; }
.find-buttons {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin: 12px 0;
}
.find-btn {
  padding: 8px 14px;
  background: var(--surface);
  border: 1px solid var(--border-strong);
  border-radius: 100px;
  font-size: var(--fs-sm);
  font-weight: 500;
  transition: all 0.15s var(--ease);
  cursor: pointer;
}
.find-btn:hover { background: var(--brand-blue-soft); border-color: var(--brand-blue); color: var(--brand-navy); }
.find-btn.found { background: var(--success-soft); border-color: var(--success); color: var(--success-dark); }
.find-btn.found::before { content: '✓ '; }

/* ---- Roadmap ---- */
.roadmap { display: flex; flex-direction: column; gap: 8px; margin: 16px 0; }
.roadmap-phase { margin-bottom: 16px; }
.roadmap-phase-label {
  font-size: var(--fs-xs);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--text-3);
  font-weight: 600;
  margin-bottom: 8px;
  padding-left: 4px;
}
.roadmap-units { display: flex; gap: 8px; flex-wrap: wrap; }
.roadmap-unit {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 10px 14px;
  font-size: var(--fs-sm);
  flex: 1;
  min-width: 140px;
  cursor: default;
}
.roadmap-unit-num { font-size: var(--fs-xs); color: var(--text-3); font-weight: 500; }
.roadmap-unit-title { font-weight: 500; margin-top: 2px; }

/* ---- Quiz ---- */
.quiz-progress { display: flex; align-items: center; gap: 8px; margin-bottom: 18px; }
.quiz-q { margin-bottom: 24px; }
.quiz-option {
  background: var(--surface);
  border: 1.5px solid var(--border);
  border-radius: var(--radius);
  padding: 12px 16px;
  text-align: left;
  cursor: pointer;
  font-size: var(--fs-base);
  transition: all 0.15s var(--ease);
  width: 100%;
}
.quiz-option:hover { border-color: var(--border-strong); background: var(--surface-2); }
.quiz-option.selected { border-color: var(--brand-blue); background: var(--brand-blue-soft); }

/* ---- Forms ---- */
.field { display: flex; flex-direction: column; gap: 6px; margin-bottom: var(--space-4); }
.field label { font-size: var(--fs-sm); font-weight: 500; color: var(--text-2); }
.input, .textarea, .select {
  width: 100%;
  padding: 10px 14px;
  border: 1px solid var(--border-strong);
  border-radius: var(--radius);
  background: var(--surface);
  font-size: var(--fs-base);
  transition: border-color var(--t-fast) var(--ease);
}
.input:focus, .textarea:focus, .select:focus {
  outline: none;
  border-color: var(--brand-blue);
}
.textarea { min-height: 70px; resize: vertical; }

/* ---- Glossary ---- */
.glossary-search {
  width: 100%;
  padding: 12px 16px;
  border: 1px solid var(--border-strong);
  border-radius: var(--radius);
  font-size: var(--fs-base);
  margin-bottom: 16px;
  background: var(--surface);
}
.glossary-item {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 14px 18px;
  margin-bottom: 8px;
}
.glossary-term { font-weight: 500; font-size: var(--fs-base); }
.glossary-def { font-size: var(--fs-sm); color: var(--text-2); margin-top: 4px; }

/* ---- Modal ---- */
.modal-backdrop {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(15,25,50,0.5);
  z-index: 100;
  align-items: center;
  justify-content: center;
  padding: 20px;
}
.modal-backdrop.show { display: flex; }
.modal {
  background: var(--surface);
  border-radius: var(--radius-xl);
  padding: 32px;
  max-width: 460px;
  width: 100%;
  text-align: center;
  animation: pop 0.3s var(--ease-out);
}
@keyframes pop {
  from { transform: scale(0.94); opacity: 0; }
  to { transform: scale(1); opacity: 1; }
}

/* ---- Account dropdown (avatar menu) ---- */
.account-wrap { position: relative; }
.account-menu {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  min-width: 260px;
  background: #FFFFFF;
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  padding: 8px;
  z-index: 1000;
  animation: pop 0.18s var(--ease-out);
}
.account-header {
  padding: 10px 12px 12px;
  border-bottom: 1px solid var(--border);
  margin-bottom: 6px;
}
.account-name {
  font-weight: 600;
  font-size: var(--fs-base);
  color: var(--text);
}
.account-email {
  font-size: var(--fs-sm);
  color: var(--text-3);
  margin-top: 2px;
  overflow: hidden;
  text-overflow: ellipsis;
}
.account-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 9px 12px;
  font-size: var(--fs-base);
  color: var(--text);
  text-decoration: none;
  border-radius: var(--radius);
  width: 100%;
  text-align: left;
  cursor: pointer;
  background: transparent;
  border: none;
  font-weight: 500;
}
.account-item:hover { background: var(--surface-2); text-decoration: none; }
.account-item svg { color: var(--text-3); }
.account-item.account-cta { color: var(--brand-blue); }
.account-item.account-cta svg { color: var(--brand-blue); }
.account-item.account-signout { color: var(--danger); border-top: 1px solid var(--border); margin-top: 6px; padding-top: 12px; border-radius: 0 0 var(--radius) var(--radius); }
.account-item.account-signout svg { color: var(--danger); }
.account-item.account-signout:hover { background: var(--danger-soft); }

/* ---- Toast ---- */
.toast {
  position: fixed;
  bottom: 20px; right: 20px;
  background: var(--text);
  color: white;
  padding: 12px 20px;
  border-radius: var(--radius);
  font-size: var(--fs-base);
  z-index: 200;
  transform: translateY(100px);
  opacity: 0;
  transition: all 0.3s;
}
.toast.show { transform: translateY(0); opacity: 1; }
