:root {
  color-scheme: light;
  --yellow: #ffce00;
  --yellow-dark: #ffbc0c;
  --orange-light: #ffad16;
  --orange: #ff9327;
  --light-grey: #e8e8e8;
  --grey: #a0a0a0;
  --light-black: #303030;
  --dark-grey: #545454;
  --white: #ffffff;
  --gradient: linear-gradient(135deg, var(--yellow) 0%, var(--orange) 100%);
  --line: rgba(160, 160, 160, 0.32);
  --soft-line: rgba(160, 160, 160, 0.18);
  --dark-line: rgba(232, 232, 232, 0.16);
  --dark-panel: rgba(48, 48, 48, 0.92);
  --dark-panel-soft: rgba(84, 84, 84, 0.74);
  --shadow: 0 18px 44px rgba(48, 48, 48, 0.12);
  --small-shadow: 0 10px 24px rgba(48, 48, 48, 0.09);
  --dark-shadow: 0 24px 60px rgba(48, 48, 48, 0.32);
  --radius: 8px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  min-height: 100vh;
  margin: 0;
  color: var(--light-black);
  font-family: "Segoe UI", Arial, sans-serif;
  background: linear-gradient(180deg, var(--white) 0%, var(--light-grey) 100%);
  transition: background 220ms ease, color 220ms ease;
}

body[data-page-theme="dashboard"],
body[data-page-theme="completion"] {
  color: var(--white);
  background:
    radial-gradient(circle at 16% 8%, rgba(255, 206, 0, 0.2), transparent 32%),
    radial-gradient(circle at 86% 4%, rgba(255, 147, 39, 0.22), transparent 34%),
    linear-gradient(135deg, var(--light-black) 0%, var(--dark-grey) 100%);
}

body[data-page-theme="lesson"],
body[data-page-theme="quiz"] {
  color: var(--light-black);
  background: linear-gradient(180deg, var(--white) 0%, var(--light-grey) 100%);
}

button,
input,
select {
  font: inherit;
}

button {
  border: 0;
}

img {
  display: block;
  max-width: 100%;
}

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

p,
li,
dd {
  color: var(--dark-grey);
  line-height: 1.58;
}

.retro-bg {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  overflow: hidden;
}

.retro-bg::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(232, 232, 232, 0.62) 1px, transparent 1px),
    linear-gradient(180deg, rgba(232, 232, 232, 0.56) 1px, transparent 1px);
  background-size: 44px 44px;
  opacity: 0.34;
}

body[data-page-theme="dashboard"] .retro-bg::before,
body[data-page-theme="completion"] .retro-bg::before {
  background:
    linear-gradient(90deg, rgba(232, 232, 232, 0.14) 1px, transparent 1px),
    linear-gradient(180deg, rgba(232, 232, 232, 0.12) 1px, transparent 1px);
  opacity: 0.24;
}

.energy-icon {
  position: absolute;
  width: 82px;
  height: 82px;
  fill: none;
  stroke: rgba(255, 147, 39, 0.26);
  stroke-width: 4;
  stroke-linecap: round;
  stroke-linejoin: round;
}

body[data-page-theme="dashboard"] .energy-icon,
body[data-page-theme="completion"] .energy-icon {
  stroke: rgba(255, 206, 0, 0.3);
}

.icon-pv {
  left: 7%;
  top: 18%;
}

.icon-genset {
  right: 9%;
  top: 14%;
}

.icon-grid {
  left: 12%;
  bottom: 12%;
}

.icon-bess {
  right: 15%;
  bottom: 14%;
}

.bg-line,
.bg-particle {
  display: none;
}

.app-shell {
  position: relative;
  z-index: 1;
  width: min(1280px, calc(100% - 32px));
  margin: 0 auto;
  padding: 24px 0 40px;
}

.brand-row,
.path-progress,
.dashboard-hero,
.metric,
.dashboard-panel,
.module-card,
.module-sidebar,
.lesson-stage,
.framework-card,
.learning-card,
.hardware-card,
.scenario-card,
.question-card,
.takeaway,
.concept-card,
.matrix-row,
.detail-copy,
.prime-copy,
.product-detail,
.module-summary,
details,
.completion-panel {
  border: 1px solid var(--soft-line);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.94);
  box-shadow: var(--small-shadow);
}

.brand-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 14px;
  padding: 14px 16px;
  background: var(--gradient);
}

.brand-lockup {
  display: flex;
  align-items: center;
  gap: 14px;
  min-width: 0;
  color: var(--light-black);
  text-align: left;
  cursor: pointer;
}

.reset-button {
  padding: 0;
  background: transparent;
}

.brand-logo {
  width: 90px;
  max-height: 46px;
  flex: 0 0 auto;
  object-fit: contain;
}

.brand-title {
  display: block;
  color: var(--light-black);
  font-size: clamp(1.45rem, 3vw, 2.35rem);
  font-weight: 800;
  line-height: 1;
  letter-spacing: 0;
}

.header-controls {
  display: flex;
  align-items: center;
  gap: 10px;
  flex: 0 0 auto;
}

.eyebrow {
  display: block;
  margin: 0 0 6px;
  color: var(--dark-grey);
  font-size: 0.75rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.path-progress {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 18px;
  margin-bottom: 18px;
  padding: 14px 16px;
}

.path-progress strong {
  display: block;
  color: var(--light-black);
  font-size: 2rem;
  line-height: 1;
}

.path-meta {
  color: var(--dark-grey);
  font-size: 0.9rem;
  font-weight: 700;
  text-align: right;
}

.progress-shell,
.mini-progress,
.lesson-progress {
  overflow: hidden;
  background: var(--light-grey);
  border-radius: 999px;
}

.progress-shell {
  height: 12px;
}

.progress-shell span,
.mini-progress span,
.lesson-progress span {
  display: block;
  height: 100%;
  background: var(--gradient);
  transition: width 240ms ease;
}

.mini-progress {
  width: 100%;
  height: 8px;
  margin: 14px 0 9px;
}

.view-shell {
  animation: riseIn 220ms ease both;
}

.dashboard {
  display: grid;
  gap: 18px;
}

.dashboard-hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(360px, 0.82fr);
  min-height: 410px;
  overflow: hidden;
  background: var(--gradient);
  box-shadow: var(--shadow);
}

.hero-copy {
  display: grid;
  align-content: center;
  padding: clamp(28px, 5vw, 56px);
}

.hero-copy h1,
.lesson-header h1 {
  margin-bottom: 16px;
  color: var(--light-black);
  font-size: clamp(2.3rem, 6vw, 4.9rem);
  line-height: 0.96;
  letter-spacing: 0;
}

.lesson-header h1 {
  font-size: clamp(2rem, 4vw, 3.5rem);
}

.hero-text {
  max-width: 660px;
  color: var(--light-black);
  font-size: 1.05rem;
}

.hero-actions,
.lesson-nav {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}

.hero-actions {
  margin-top: 16px;
}

.hero-media {
  position: relative;
  min-height: 360px;
  margin: 0;
  background: var(--white);
}

.hero-media img {
  width: 100%;
  height: 100%;
  min-height: 410px;
  object-fit: cover;
}

.hero-media::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(255, 206, 0, 0.26), transparent);
}

.media-stat {
  position: absolute;
  right: 18px;
  bottom: 18px;
  z-index: 1;
  min-width: 132px;
  padding: 16px;
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.94);
  box-shadow: var(--small-shadow);
}

.media-stat span,
.media-stat small,
.metric span,
.metric small,
.quiz-summary span,
.gauge span,
.matrix-row span,
.role-grid span,
.highlight-row span,
.achievement span,
.profile-list dt {
  display: block;
  color: var(--dark-grey);
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.media-stat strong {
  display: block;
  color: var(--orange);
  font-size: 3rem;
  line-height: 1;
}

.metric-grid,
.dashboard-panels,
.module-grid,
.lesson-framework,
.interactive-grid,
.concept-grid,
.hardware-grid,
.visual-strip,
.takeaway-grid,
.matrix,
.scenario-list,
.accordion-row {
  display: grid;
  gap: 14px;
}

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

.dashboard-panels {
  grid-template-columns: 0.95fr 1.1fr 1.1fr;
}

.metric,
.dashboard-panel,
.framework-card,
.learning-card,
.hardware-card,
.scenario-card,
.question-card,
.takeaway,
.matrix-row {
  padding: 16px;
}

.metric strong {
  display: block;
  margin: 9px 0 6px;
  color: var(--orange);
  font-size: clamp(1.55rem, 3vw, 2.35rem);
  line-height: 1;
}

.section-heading {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 16px;
  margin: 12px 0 14px;
}

.section-heading.compact {
  margin: 0 0 12px;
}

.section-heading h2 {
  margin-bottom: 0;
  color: var(--light-black);
  font-size: clamp(1.35rem, 2.4vw, 2rem);
}

.profile-list,
.detail-list {
  display: grid;
  gap: 10px;
  margin: 0;
}

.profile-list div,
.detail-list div,
.quiz-summary div,
.role-grid div,
.highlight-row div {
  padding: 14px;
  border: 1px solid var(--soft-line);
  border-radius: var(--radius);
  background: var(--white);
}

.profile-list dd,
.detail-list dd {
  margin: 6px 0 0;
}

.achievement-grid,
.tag-list {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.achievement {
  min-width: 144px;
  flex: 1 1 144px;
  padding: 12px;
  border: 1px solid var(--soft-line);
  border-radius: var(--radius);
  background: var(--white);
}

.achievement.active {
  border-color: rgba(255, 147, 39, 0.62);
  background: linear-gradient(180deg, rgba(255, 206, 0, 0.18), var(--white));
}

.achievement strong {
  display: block;
  margin-top: 6px;
  color: var(--light-black);
}

.tag-list span {
  display: inline-flex;
  align-items: center;
  min-height: 32px;
  padding: 6px 10px;
  border: 1px solid rgba(255, 147, 39, 0.34);
  border-radius: 999px;
  background: rgba(255, 206, 0, 0.18);
  color: var(--light-black);
  font-size: 0.84rem;
  font-weight: 700;
}

.compact-tags span {
  min-height: 28px;
  font-size: 0.8rem;
}

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

.module-card {
  min-height: 310px;
  display: grid;
  grid-template-rows: auto 1fr auto;
  gap: 14px;
  padding: 16px;
  border-top: 5px solid var(--orange);
}

.module-card.is-locked {
  opacity: 0.72;
  border-top-color: var(--grey);
}

.module-index {
  color: var(--orange);
  font-size: 2.4rem;
  font-weight: 800;
  line-height: 1;
}

.module-card h3 {
  margin: 0 0 9px;
  color: var(--light-black);
  font-size: 1.25rem;
}

.module-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-top: 12px;
  color: var(--dark-grey);
  font-size: 0.8rem;
  font-weight: 800;
  text-transform: uppercase;
}

.primary-button,
.secondary-button,
.answer-button,
.icon-button,
.back-button,
.timeline-step,
.resource-card,
.product-option,
.segmented button,
.breadcrumbs button,
.audio-placeholder button,
.audio-placeholder select {
  border: 1px solid transparent;
  border-radius: 6px;
  cursor: pointer;
  font-weight: 800;
  letter-spacing: 0;
  transition: transform 140ms ease, border-color 140ms ease, filter 140ms ease, box-shadow 140ms ease;
}

.primary-button,
.secondary-button {
  min-height: 44px;
  padding: 0 18px;
}

.primary-button {
  background: var(--orange);
  color: var(--white);
  box-shadow: 0 10px 24px rgba(255, 147, 39, 0.28);
}

.secondary-button {
  background: var(--yellow);
  color: var(--light-black);
}

.back-button {
  min-height: 42px;
  padding: 0 12px;
  background: var(--white);
  border-color: var(--soft-line);
  color: var(--light-black);
  text-align: left;
}

.icon-button {
  width: 42px;
  height: 42px;
  background: var(--white);
  border-color: rgba(255, 147, 39, 0.38);
  color: var(--light-black);
}

.primary-button:hover,
.secondary-button:hover,
.answer-button:hover,
.icon-button:hover,
.back-button:hover,
.timeline-step:hover,
.resource-card:hover,
.product-option:hover,
.segmented button:hover,
.breadcrumbs button:hover {
  transform: translateY(-1px);
  filter: brightness(1.03);
  border-color: var(--orange);
}

button:disabled,
select:disabled {
  cursor: not-allowed;
  opacity: 0.58;
}

button:disabled:hover {
  transform: none;
  border-color: transparent;
  filter: none;
}

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

.module-sidebar {
  position: sticky;
  top: 16px;
  display: grid;
  gap: 14px;
  padding: 16px;
}

.module-summary {
  padding: 14px;
  background: linear-gradient(180deg, rgba(255, 206, 0, 0.16), var(--white));
}

.module-summary h2 {
  margin-bottom: 8px;
  color: var(--light-black);
  font-size: 1.2rem;
}

.module-summary small {
  color: var(--dark-grey);
  font-weight: 700;
}

.lesson-timeline {
  display: grid;
  gap: 8px;
}

.timeline-step {
  display: grid;
  grid-template-columns: 42px 1fr;
  align-items: center;
  min-height: 48px;
  padding: 7px 10px;
  background: var(--white);
  border-color: var(--soft-line);
  color: var(--light-black);
  text-align: left;
}

.timeline-step span {
  color: var(--orange);
  font-weight: 800;
}

.timeline-step.active {
  border-color: var(--orange);
  background: rgba(255, 206, 0, 0.2);
}

.timeline-step.complete span::after {
  content: "";
  display: inline-block;
  width: 7px;
  height: 7px;
  margin-left: 6px;
  border-radius: 50%;
  background: var(--orange);
}

.lesson-stage {
  min-height: 720px;
  padding: clamp(18px, 3vw, 28px);
}

.breadcrumbs {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 14px;
  color: var(--dark-grey);
  font-size: 0.9rem;
}

.breadcrumbs button {
  padding: 0;
  background: transparent;
  color: var(--dark-grey);
}

.breadcrumbs strong {
  color: var(--light-black);
}

.lesson-progress {
  height: 10px;
  margin-bottom: 24px;
}

.lesson-header {
  max-width: 940px;
  margin-bottom: 22px;
}

.lesson-header p:last-child {
  font-size: 1.04rem;
}

.lesson-framework {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  margin-bottom: 18px;
}

.framework-card ul {
  margin: 0;
  padding-left: 19px;
}

.framework-card p:last-child {
  margin-bottom: 0;
}

.narration-panel {
  grid-column: 1 / -1;
  background: linear-gradient(180deg, rgba(255, 206, 0, 0.12), var(--white));
}

.voice-panel {
  grid-column: 1 / -1;
  display: grid;
  gap: 12px;
  padding: 16px;
  border: 1px solid rgba(255, 147, 39, 0.34);
  border-radius: var(--radius);
  background: linear-gradient(180deg, rgba(255, 206, 0, 0.18), var(--white));
  box-shadow: var(--small-shadow);
}

.voice-header,
.voice-controls {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}

.voice-header h2 {
  margin: 0;
  color: var(--light-black);
}

.speaker-placeholder {
  min-width: 150px;
  padding: 12px;
  border: 1px dashed rgba(255, 147, 39, 0.58);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.66);
  text-align: center;
}

.speaker-placeholder span,
.voice-status,
.feature-columns span {
  display: block;
  color: var(--dark-grey);
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.speaker-placeholder strong {
  display: block;
  margin-top: 5px;
  color: var(--light-black);
}

.compact-button {
  min-height: 36px;
  padding: 0 14px;
}

.voice-controls label {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--dark-grey);
  font-size: 0.82rem;
  font-weight: 800;
  text-transform: uppercase;
}

.voice-controls select {
  min-height: 36px;
  padding: 0 8px;
  border: 1px solid var(--soft-line);
  border-radius: 6px;
  background: var(--white);
  color: var(--light-black);
}

.voice-progress {
  overflow: hidden;
  height: 10px;
  border-radius: 999px;
  background: var(--light-grey);
}

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

.subtitle-line,
.sync-placeholder {
  margin: 0;
  padding: 12px 14px;
  border: 1px solid var(--soft-line);
  border-radius: var(--radius);
  background: var(--white);
}

.subtitle-line {
  color: var(--light-black);
  font-weight: 700;
}

details summary {
  cursor: pointer;
  padding: 13px 14px;
  color: var(--light-black);
  font-weight: 800;
}

details p,
details ul {
  margin: 0;
  padding: 0 14px 14px;
}

.audio-placeholder {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  padding: 0 14px 12px;
}

.audio-placeholder button,
.audio-placeholder select {
  min-height: 34px;
  padding: 0 10px;
  background: var(--white);
  border-color: var(--soft-line);
  color: var(--dark-grey);
}

.audio-placeholder span {
  color: var(--dark-grey);
  font-size: 0.86rem;
  font-weight: 700;
}

.intro-layout,
.lab-layout,
.mode-layout,
.portfolio-layout,
.prime-output,
.resource-detail {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(300px, 0.82fr);
  gap: 18px;
  align-items: stretch;
}

.intro-panel {
  display: grid;
  gap: 16px;
  align-content: start;
}

.highlight-row,
.quiz-summary,
.role-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.highlight-row strong,
.quiz-summary strong,
.role-grid strong {
  display: block;
  margin-top: 7px;
  color: var(--orange);
  font-size: 1.18rem;
  line-height: 1.15;
}

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

.objective {
  display: grid;
  grid-template-columns: 20px 1fr;
  gap: 10px;
  align-items: start;
}

.objective span {
  width: 12px;
  height: 12px;
  margin-top: 7px;
  border-radius: 50%;
  background: var(--orange);
}

.objective p {
  margin: 0;
}

.callout,
.feedback-panel,
.constraint-list p {
  margin: 18px 0 0;
  padding: 16px;
  color: var(--light-black);
  background: rgba(255, 206, 0, 0.18);
  border: 1px solid rgba(255, 147, 39, 0.36);
  border-left: 5px solid var(--orange);
  border-radius: var(--radius);
  line-height: 1.58;
}

.visual-frame {
  min-height: 190px;
  margin: 0;
  overflow: hidden;
  display: grid;
  place-items: center;
  border: 1px solid var(--soft-line);
  border-radius: var(--radius);
  background: var(--white);
}

.visual-frame img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.intro-layout .visual-frame {
  min-height: 430px;
}

.intro-layout .visual-frame img {
  object-fit: cover;
}

.visual-frame.compact {
  min-height: 230px;
}

.module-visual-placeholder {
  background:
    linear-gradient(135deg, rgba(255, 206, 0, 0.24), rgba(255, 147, 39, 0.14)),
    var(--white);
  text-align: center;
}

.module-visual-placeholder div {
  display: grid;
  gap: 8px;
  max-width: 360px;
  padding: 28px;
}

.module-visual-placeholder span {
  color: var(--orange);
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.module-visual-placeholder strong {
  color: var(--light-black);
  font-size: clamp(1.6rem, 4vw, 2.6rem);
  line-height: 1.02;
}

.resource-grid {
  grid-template-columns: repeat(4, minmax(0, 1fr));
  margin-bottom: 18px;
}

.learning-card-grid,
.process-flow,
.checklist-grid,
.comparison-grid {
  display: grid;
  gap: 14px;
}

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

.process-flow {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.process-step {
  position: relative;
  display: grid;
  gap: 10px;
  align-content: start;
  min-height: 220px;
  padding: 16px;
  border: 1px solid var(--soft-line);
  border-radius: var(--radius);
  background: var(--white);
  box-shadow: var(--small-shadow);
}

.process-step span {
  display: inline-grid;
  place-items: center;
  width: 42px;
  height: 42px;
  border-radius: 50%;
  background: var(--gradient);
  color: var(--light-black);
  font-weight: 900;
}

.process-step h2 {
  margin: 0;
  color: var(--light-black);
  font-size: 1.1rem;
}

.process-step p {
  margin-bottom: 0;
}

.process-step strong {
  display: block;
  margin-top: auto;
  padding-top: 10px;
  color: var(--orange);
}

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

.checklist-card {
  padding: 16px;
  border: 1px solid var(--soft-line);
  border-radius: var(--radius);
  background: var(--white);
  box-shadow: var(--small-shadow);
}

.checklist-card h2 {
  color: var(--light-black);
}

.check-items {
  display: grid;
  gap: 9px;
}

.check-items label {
  display: grid;
  grid-template-columns: 20px 1fr;
  gap: 10px;
  align-items: start;
  color: var(--dark-grey);
  line-height: 1.4;
}

.check-items input {
  width: 16px;
  height: 16px;
  margin-top: 3px;
  accent-color: var(--orange);
}

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

.mini-callout {
  margin: 12px 0 0;
  padding: 12px;
  border-left: 4px solid var(--orange);
  border-radius: var(--radius);
  background: rgba(255, 206, 0, 0.14);
  color: var(--light-black);
}

.resource-card,
.product-option {
  min-height: 150px;
  padding: 15px;
  background: var(--white);
  border-color: var(--soft-line);
  color: var(--light-black);
  text-align: left;
}

.resource-card.active,
.product-option.active,
.segmented button.active,
.answer-button.active {
  border-color: var(--orange);
  background: linear-gradient(180deg, rgba(255, 206, 0, 0.2), var(--white));
  box-shadow: 0 0 0 1px rgba(255, 147, 39, 0.12);
}

.resource-card span,
.product-option span {
  display: block;
  color: var(--orange);
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.resource-card strong,
.product-option strong {
  display: block;
  margin: 7px 0;
  color: var(--light-black);
  font-size: 1.08rem;
}

.resource-card p {
  margin: 0;
  font-weight: 500;
}

.detail-copy,
.prime-copy,
.product-detail {
  padding: 18px;
}

.detail-copy h2,
.prime-copy h2,
.product-detail h2,
.feedback-panel h2,
.learning-card h2,
.scenario-card h2,
.question-card h2 {
  margin-bottom: 12px;
  color: var(--light-black);
}

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

.feature-columns div {
  padding: 14px;
  border: 1px solid var(--soft-line);
  border-radius: var(--radius);
  background: rgba(232, 232, 232, 0.22);
}

.feature-columns ul {
  margin-bottom: 0;
  padding-left: 18px;
}

.visual-strip {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  margin-bottom: 16px;
}

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

.concept-card {
  min-height: 210px;
}

.concept-card summary {
  min-height: 176px;
}

.concept-card summary strong {
  display: block;
  margin: 6px 0 10px;
  color: var(--light-black);
  font-size: 1.45rem;
}

.concept-card summary span {
  color: var(--orange);
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.control-bank {
  display: grid;
  gap: 10px;
  align-content: start;
}

.stability-output {
  display: grid;
  gap: 14px;
}

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

.gauge {
  padding: 14px;
  border: 1px solid var(--soft-line);
  border-radius: var(--radius);
  background: var(--white);
}

.gauge-track {
  position: relative;
  height: 12px;
  margin: 13px 0;
  border-radius: 999px;
  background: linear-gradient(90deg, var(--orange), var(--yellow), var(--orange));
}

.gauge-track i {
  position: absolute;
  top: -7px;
  width: 4px;
  height: 24px;
  border-radius: 999px;
  background: var(--light-black);
  transform: translateX(-50%);
}

.gauge strong {
  color: var(--orange);
  font-size: 1.28rem;
}

.accordion-row {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  margin-top: 16px;
}

.mode-layout {
  grid-template-columns: minmax(300px, 0.9fr) minmax(0, 1fr);
}

.mode-pairs {
  display: grid;
  gap: 14px;
}

.portfolio-layout {
  grid-template-columns: minmax(230px, 0.42fr) minmax(0, 1fr);
  margin-bottom: 16px;
}

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

.product-option {
  min-height: 76px;
}

.detail-list dt {
  color: var(--dark-grey);
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

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

.hardware-card {
  display: grid;
  grid-template-columns: 160px 1fr;
  gap: 14px;
  align-items: center;
}

.segmented {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
  margin-bottom: 16px;
}

.segmented button {
  min-height: 48px;
  padding: 0 10px;
  background: var(--white);
  border-color: var(--soft-line);
  color: var(--light-black);
}

.prime-output {
  grid-template-columns: minmax(280px, 0.72fr) minmax(0, 1fr);
}

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

.constraint-list p {
  margin-top: 0;
}

.matrix {
  gap: 10px;
}

.matrix-row {
  display: grid;
  grid-template-columns: 150px 1fr 1fr;
  gap: 14px;
  align-items: start;
}

.matrix-row h3 {
  margin: 0;
  color: var(--orange);
}

.matrix-row p {
  margin-bottom: 0;
}

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

.scenario-card,
.question-card {
  display: grid;
  gap: 12px;
}

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

.answer-button {
  width: 100%;
  min-height: 54px;
  padding: 12px 14px;
  background: var(--white);
  border-color: var(--soft-line);
  color: var(--light-black);
  text-align: left;
  line-height: 1.35;
}

.answer-button:hover {
  background: rgba(255, 206, 0, 0.14);
}

.answer-button.correct {
  background: rgba(255, 206, 0, 0.24);
  border-color: var(--yellow-dark);
  box-shadow: 0 0 0 1px rgba(255, 188, 12, 0.22);
}

.answer-button.wrong {
  background: rgba(255, 147, 39, 0.16);
  border-color: var(--orange);
  box-shadow: 0 0 0 1px rgba(255, 147, 39, 0.16);
}

.feedback {
  min-height: 26px;
  margin-bottom: 0;
  color: var(--dark-grey);
  line-height: 1.45;
}

.quiz-shell {
  display: grid;
  gap: 14px;
}

.question-count {
  margin-bottom: 0;
  color: var(--orange);
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

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

.takeaway {
  display: grid;
  grid-template-columns: 58px 1fr;
  gap: 14px;
  align-items: start;
}

.takeaway span {
  color: var(--orange);
  font-size: 1.8rem;
  font-weight: 800;
}

.takeaway p {
  margin-bottom: 0;
}

.completion-panel {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  margin-top: 24px;
  padding: 14px 16px;
  background: linear-gradient(90deg, rgba(255, 206, 0, 0.18), var(--white));
}

.completion-panel strong {
  color: var(--light-black);
}

body[data-page-theme="dashboard"] .brand-row,
body[data-page-theme="completion"] .brand-row,
body[data-page-theme="dashboard"] .path-progress,
body[data-page-theme="completion"] .path-progress {
  background: var(--dark-panel);
  border-color: var(--dark-line);
  box-shadow: var(--dark-shadow);
}

body[data-page-theme="dashboard"] .brand-row,
body[data-page-theme="completion"] .brand-row {
  border-top: 4px solid var(--orange);
}

body[data-page-theme="lesson"] .brand-row,
body[data-page-theme="quiz"] .brand-row {
  background: rgba(255, 255, 255, 0.96);
  border-top: 4px solid var(--orange);
}

body[data-page-theme="lesson"] .brand-row .eyebrow,
body[data-page-theme="quiz"] .brand-row .eyebrow {
  color: var(--orange);
}

body[data-page-theme="dashboard"] .brand-lockup,
body[data-page-theme="completion"] .brand-lockup,
body[data-page-theme="dashboard"] .brand-title,
body[data-page-theme="completion"] .brand-title,
body[data-page-theme="dashboard"] .path-progress strong,
body[data-page-theme="completion"] .path-progress strong {
  color: var(--white);
}

body[data-page-theme="dashboard"] .brand-row .eyebrow,
body[data-page-theme="completion"] .brand-row .eyebrow,
body[data-page-theme="dashboard"] .path-progress .eyebrow,
body[data-page-theme="completion"] .path-progress .eyebrow {
  color: var(--yellow);
}

body[data-page-theme="dashboard"] .path-meta,
body[data-page-theme="completion"] .path-meta {
  color: var(--light-grey);
}

body[data-page-theme="dashboard"] .progress-shell,
body[data-page-theme="completion"] .progress-shell,
body[data-page-theme="dashboard"] .mini-progress,
body[data-page-theme="completion"] .mini-progress,
body[data-page-theme="completion"] .lesson-progress {
  background: rgba(232, 232, 232, 0.2);
}

body[data-page-theme="dashboard"] .icon-button,
body[data-page-theme="completion"] .icon-button {
  background: rgba(48, 48, 48, 0.68);
  border-color: rgba(255, 206, 0, 0.38);
  color: var(--yellow);
}

body[data-page-theme="dashboard"] .dashboard {
  color: var(--white);
}

body[data-page-theme="dashboard"] .dashboard-hero {
  position: relative;
  overflow: hidden;
  background:
    linear-gradient(135deg, rgba(48, 48, 48, 0.98), rgba(84, 84, 84, 0.9)),
    var(--gradient);
  border-color: var(--dark-line);
  border-top: 6px solid var(--orange);
  box-shadow: var(--dark-shadow);
}

body[data-page-theme="dashboard"] .dashboard-hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(135deg, rgba(255, 206, 0, 0.16), transparent 42%),
    linear-gradient(315deg, rgba(255, 147, 39, 0.18), transparent 46%);
  pointer-events: none;
}

body[data-page-theme="dashboard"] .hero-copy,
body[data-page-theme="dashboard"] .hero-media {
  position: relative;
  z-index: 1;
}

body[data-page-theme="dashboard"] .hero-copy h1,
body[data-page-theme="dashboard"] .section-heading h2,
body[data-page-theme="dashboard"] .dashboard-panel h2,
body[data-page-theme="dashboard"] .module-card h3 {
  color: var(--white);
}

body[data-page-theme="dashboard"] .dashboard .eyebrow {
  color: var(--yellow);
}

body[data-page-theme="dashboard"] .hero-text,
body[data-page-theme="dashboard"] .dashboard p,
body[data-page-theme="dashboard"] .module-card p,
body[data-page-theme="dashboard"] .module-meta,
body[data-page-theme="dashboard"] .profile-list dd,
body[data-page-theme="dashboard"] .metric small {
  color: var(--light-grey);
}

body[data-page-theme="dashboard"] .metric,
body[data-page-theme="dashboard"] .dashboard-panel,
body[data-page-theme="dashboard"] .module-card {
  background: linear-gradient(180deg, var(--dark-panel-soft), var(--dark-panel));
  border-color: var(--dark-line);
  box-shadow: var(--dark-shadow);
}

body[data-page-theme="dashboard"] .module-card {
  border-top-color: var(--orange);
}

body[data-page-theme="dashboard"] .metric span,
body[data-page-theme="dashboard"] .metric small,
body[data-page-theme="dashboard"] .achievement span,
body[data-page-theme="dashboard"] .profile-list dt {
  color: var(--light-grey);
}

body[data-page-theme="dashboard"] .metric strong,
body[data-page-theme="dashboard"] .module-index,
body[data-page-theme="dashboard"] .media-stat strong {
  color: var(--yellow);
}

body[data-page-theme="dashboard"] .profile-list div,
body[data-page-theme="dashboard"] .achievement {
  background: rgba(48, 48, 48, 0.66);
  border-color: var(--dark-line);
}

body[data-page-theme="dashboard"] .achievement.active {
  background: linear-gradient(180deg, rgba(255, 206, 0, 0.2), rgba(48, 48, 48, 0.72));
  border-color: rgba(255, 147, 39, 0.62);
}

body[data-page-theme="dashboard"] .achievement strong,
body[data-page-theme="dashboard"] .profile-list dd {
  color: var(--white);
}

body[data-page-theme="dashboard"] .tag-list span {
  background: rgba(255, 206, 0, 0.15);
  border-color: rgba(255, 206, 0, 0.34);
  color: var(--white);
}

body[data-page-theme="dashboard"] .hero-media {
  background: var(--light-black);
}

body[data-page-theme="dashboard"] .hero-media::after {
  background: linear-gradient(90deg, rgba(48, 48, 48, 0.72), rgba(255, 147, 39, 0.18));
}

body[data-page-theme="dashboard"] .media-stat {
  background: rgba(48, 48, 48, 0.9);
  border: 1px solid var(--dark-line);
}

body[data-page-theme="dashboard"] .media-stat span,
body[data-page-theme="dashboard"] .media-stat small {
  color: var(--light-grey);
}

body[data-page-theme="lesson"] .lesson-stage,
body[data-page-theme="quiz"] .lesson-stage {
  background: rgba(255, 255, 255, 0.96);
}

body[data-page-theme="lesson"] .module-sidebar,
body[data-page-theme="quiz"] .module-sidebar {
  background: rgba(255, 255, 255, 0.96);
}

.quiz-stage {
  background: linear-gradient(180deg, var(--white), rgba(255, 206, 0, 0.08));
  border-top: 5px solid var(--orange);
}

.quiz-stage .lesson-header {
  padding: 18px;
  border: 1px solid rgba(255, 147, 39, 0.28);
  border-left: 5px solid var(--orange);
  border-radius: var(--radius);
  background: linear-gradient(90deg, rgba(255, 206, 0, 0.14), var(--white));
}

.quiz-stage .quiz-summary div {
  background: rgba(255, 206, 0, 0.12);
  border-color: rgba(255, 147, 39, 0.28);
}

.quiz-stage .question-card {
  border-color: rgba(255, 147, 39, 0.28);
  transition: transform 160ms ease, box-shadow 160ms ease, border-color 160ms ease;
}

.quiz-stage .question-card:hover {
  transform: translateY(-2px);
  border-color: rgba(255, 147, 39, 0.5);
  box-shadow: var(--shadow);
}

body[data-page-theme="completion"] .module-sidebar {
  background: var(--dark-panel);
  border-color: var(--dark-line);
  box-shadow: var(--dark-shadow);
}

body[data-page-theme="completion"] .module-summary {
  background: linear-gradient(180deg, rgba(255, 206, 0, 0.16), rgba(48, 48, 48, 0.62));
  border-color: var(--dark-line);
}

body[data-page-theme="completion"] .module-summary h2,
body[data-page-theme="completion"] .module-summary p,
body[data-page-theme="completion"] .module-summary small,
body[data-page-theme="completion"] .timeline-step strong {
  color: var(--white);
}

body[data-page-theme="completion"] .back-button,
body[data-page-theme="completion"] .timeline-step {
  background: rgba(48, 48, 48, 0.7);
  border-color: var(--dark-line);
  color: var(--white);
}

body[data-page-theme="completion"] .timeline-step.active {
  background: rgba(255, 206, 0, 0.18);
  border-color: var(--orange);
}

.completion-stage {
  overflow: hidden;
  color: var(--white);
  background:
    radial-gradient(circle at 18% 10%, rgba(255, 206, 0, 0.2), transparent 34%),
    linear-gradient(135deg, rgba(48, 48, 48, 0.98), rgba(84, 84, 84, 0.92));
  border-color: var(--dark-line);
  box-shadow: var(--dark-shadow);
}

.completion-stage .breadcrumbs {
  color: var(--light-grey);
}

.completion-stage .breadcrumbs button {
  color: var(--yellow);
}

.completion-stage .breadcrumbs strong,
.completion-stage .lesson-header h1,
.completion-stage .lesson-header p,
.completion-stage .lesson-nav span,
body[data-page-theme="completion"] .completion-panel strong {
  color: var(--white);
}

.completion-stage .lesson-header .eyebrow,
body[data-page-theme="completion"] .completion-panel .eyebrow {
  color: var(--yellow);
}

.completion-hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(220px, 0.34fr);
  gap: 16px;
  align-items: stretch;
  margin-bottom: 14px;
  padding: clamp(20px, 4vw, 34px);
  border: 1px solid var(--dark-line);
  border-radius: var(--radius);
  background:
    linear-gradient(135deg, rgba(255, 206, 0, 0.16), transparent 42%),
    rgba(48, 48, 48, 0.78);
}

.completion-copy h2 {
  margin-bottom: 10px;
  color: var(--white);
  font-size: clamp(2rem, 5vw, 4rem);
  line-height: 1;
}

.completion-copy p {
  max-width: 720px;
  color: var(--light-grey);
}

.completion-actions {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 18px;
}

.completion-badge {
  display: grid;
  place-items: center;
  align-content: center;
  min-height: 220px;
  padding: 22px;
  border-radius: var(--radius);
  background: var(--gradient);
  color: var(--light-black);
  text-align: center;
  box-shadow: 0 18px 40px rgba(255, 147, 39, 0.22);
}

.completion-badge span,
.completion-badge small,
.completion-stats span {
  display: block;
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.completion-badge strong {
  margin: 8px 0;
  color: var(--light-black);
  font-size: 1.7rem;
  line-height: 1.05;
}

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

.completion-stats div {
  padding: 16px;
  border: 1px solid var(--dark-line);
  border-radius: var(--radius);
  background: rgba(48, 48, 48, 0.72);
}

.completion-stats span {
  color: var(--yellow);
}

.completion-stats strong {
  display: block;
  margin-top: 7px;
  color: var(--white);
  font-size: 1.55rem;
}

.completion-stage .takeaway {
  background: rgba(255, 255, 255, 0.08);
  border-color: var(--dark-line);
}

.completion-stage .takeaway span {
  color: var(--yellow);
}

.completion-stage .takeaway p {
  color: var(--light-grey);
}

.completion-stage .completion-callout {
  color: var(--white);
  background: rgba(255, 206, 0, 0.14);
  border-color: rgba(255, 147, 39, 0.42);
}

body[data-page-theme="completion"] .completion-panel {
  background: rgba(48, 48, 48, 0.78);
  border-color: var(--dark-line);
}

.completion-stage .lesson-nav {
  border-top-color: var(--dark-line);
}

.lesson-nav {
  justify-content: space-between;
  margin-top: 18px;
  padding-top: 18px;
  border-top: 1px solid var(--soft-line);
}

.lesson-nav span {
  color: var(--dark-grey);
  font-weight: 800;
}

@keyframes riseIn {
  from {
    opacity: 0;
    transform: translateY(8px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@media (max-width: 1080px) {
  .dashboard-hero,
  .completion-hero,
  .module-layout,
  .intro-layout,
  .lab-layout,
  .mode-layout,
  .portfolio-layout,
  .prime-output,
  .resource-detail {
    grid-template-columns: 1fr;
  }

  .module-sidebar {
    position: relative;
    top: auto;
  }

  .lesson-timeline {
    grid-template-columns: repeat(5, minmax(0, 1fr));
  }

  .timeline-step {
    grid-template-columns: 1fr;
  }

  .metric-grid,
  .module-grid,
  .resource-grid,
  .concept-grid,
  .learning-card-grid,
  .process-flow,
  .checklist-grid,
  .comparison-grid,
  .feature-columns,
  .lesson-framework,
  .dashboard-panels {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .narration-panel {
    grid-column: 1 / -1;
  }

  .matrix-row {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 760px) {
  .app-shell {
    width: min(100% - 18px, 620px);
    padding-top: 12px;
  }

  .brand-row {
    align-items: flex-start;
  }

  .brand-logo {
    width: 78px;
  }

  .brand-title {
    font-size: clamp(1.1rem, 7vw, 1.75rem);
  }

  .path-progress {
    grid-template-columns: 1fr;
    gap: 12px;
  }

  .path-meta {
    text-align: left;
  }

  .dashboard-hero {
    min-height: auto;
  }

  .hero-media {
    min-height: 250px;
  }

  .hero-media img {
    min-height: 250px;
  }

  .metric-grid,
  .module-grid,
  .resource-grid,
  .concept-grid,
  .learning-card-grid,
  .process-flow,
  .checklist-grid,
  .comparison-grid,
  .feature-columns,
  .visual-strip,
  .hardware-grid,
  .highlight-row,
  .quiz-summary,
  .role-grid,
  .gauge-grid,
  .accordion-row,
  .segmented,
  .constraint-list,
  .scenario-list,
  .takeaway-grid,
  .lesson-timeline,
  .lesson-framework,
  .dashboard-panels {
    grid-template-columns: 1fr;
  }

  .completion-hero,
  .completion-stats {
    grid-template-columns: 1fr;
  }

  .hardware-card,
  .takeaway {
    grid-template-columns: 1fr;
  }

  .lesson-stage {
    order: 1;
    min-height: 0;
    padding: 16px;
  }

  .module-sidebar {
    order: 2;
  }

  .hero-copy h1,
  .lesson-header h1 {
    font-size: clamp(1.75rem, 10vw, 2.65rem);
  }

  .lesson-nav,
  .completion-panel {
    display: grid;
    grid-template-columns: 1fr;
  }

  .lesson-nav span {
    text-align: center;
    order: -1;
  }
}
