/* Signal Path: quiet surfaces, visible signals. No external font dependency. */
:root {
  --bg: #f5f5f7;
  --surface: #ffffff;
  --surface-2: #f5f5f7;
  --surface-3: #ebebed;
  --line: #e0e0e4;
  --line-strong: #c9c9ce;
  --text: #1d1d1f;
  --muted: #626267;
  --faint: #707076;
  --orange: #bf4800;
  --orange-ink: #a63e00;
  --orange-soft: #fff0e6;
  --btn-primary-bg: #bb4400;
  --btn-primary-ink: #fff;
  --font-display: -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --font-body: -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --font-mono: "SFMono-Regular", Consolas, "Liberation Mono", monospace;
  --radius: 22px;
  --radius-sm: 14px;
  --shadow: 0 4px 24px #00000004;
  --shadow-lift: 0 16px 42px #0000000c;
  --motion-fast: 180ms;
  --motion-normal: 360ms;
  --motion-slow: 800ms;
  --motion-ambient: 6s;
  --motion-ease: cubic-bezier(0.22, 1, 0.36, 1);
  --motion-distance: 24px;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #080809;
    --surface: #151517;
    --surface-2: #1b1b1e;
    --surface-3: #242427;
    --line: #303034;
    --line-strong: #48484e;
    --text: #f5f5f7;
    --muted: #aaaab0;
    --faint: #9b9ba3;
    --orange: #ff934f;
    --orange-ink: #ffab73;
    --orange-soft: #392116;
    --btn-primary-bg: #ff8a42;
    --btn-primary-ink: #221309;
  }
}
:root[data-theme="dark"] {
  --bg: #080809;
  --surface: #151517;
  --surface-2: #1b1b1e;
  --surface-3: #242427;
  --line: #303034;
  --line-strong: #48484e;
  --text: #f5f5f7;
  --muted: #aaaab0;
  --faint: #9b9ba3;
  --orange: #ff934f;
  --orange-ink: #ffab73;
  --orange-soft: #392116;
  --btn-primary-bg: #ff8a42;
  --btn-primary-ink: #221309;
}
html {
  scroll-padding-top: 84px;
}
body {
  letter-spacing: -0.012em;
}
h1,
h2,
h3 {
  letter-spacing: -0.045em;
  font-weight: 650;
}
h1 {
  line-height: 1.04;
}
h2 {
  line-height: 1.08;
}
.wrap {
  max-width: 1200px;
  padding-inline: 32px;
}
.topbar {
  background: color-mix(in srgb, var(--bg) 83%, transparent);
  backdrop-filter: blur(22px) saturate(160%);
  border-bottom: 1px solid color-mix(in srgb, var(--line) 65%, transparent);
}
.topbar-inner {
  max-width: 1280px;
  min-height: 64px;
  gap: 18px;
}
.brand {
  font-size: 18px;
  font-weight: 650;
  letter-spacing: -0.04em;
  gap: 9px;
}
.brand-logo {
  width: 29px;
  height: 32px;
  object-fit: contain;
}
.topnav {
  gap: 3px;
}
.topnav a {
  font-family: var(--font-body);
  font-size: 12px;
  padding: 8px 9px;
  font-weight: 500;
}
.nav-progress {
  display: none;
}
.theme-btn,
.motion-btn,
.nav-toggle {
  border-radius: 50%;
  min-width: 40px;
}
.motion-btn {
  display: inline-grid;
  place-items: center;
  flex: 0 0 40px;
  width: 40px;
  height: 40px;
  padding: 0;
  background: none;
  color: var(--muted);
  border: 1px solid var(--line);
  font-size: 19px;
  cursor: pointer;
}
.theme-btn {
  font-family: var(--font-body);
  font-size: 18px;
  padding: 0;
  width: 40px;
  height: 40px;
}
.motion-btn:hover {
  background: var(--surface-3);
  color: var(--text);
}
.btn {
  font-family: var(--font-body);
  border-radius: 999px;
  padding: 10px 20px;
  font-weight: 550;
  letter-spacing: -0.01em;
  min-height: 44px;
  box-shadow: none;
  transition:
    transform var(--motion-fast) var(--motion-ease),
    opacity var(--motion-fast);
}
.btn.primary {
  gap: 16px;
}
.btn:hover {
  transform: translateY(-1px);
}
.btn:active {
  transform: scale(0.98);
}
.text-link {
  text-decoration: none;
  font-weight: 500;
  display: inline-flex;
  gap: 10px;
  align-items: center;
}
.text-link:hover {
  text-decoration: underline;
}
.eyebrow {
  font-family: var(--font-body);
  font-weight: 600;
  letter-spacing: 0.055em;
  font-size: 12px;
}
.chip {
  font-family: var(--font-body);
  font-size: 12px;
  background: var(--surface-2);
  padding: 7px 12px;
}
.card {
  box-shadow: none;
}
.content section {
  margin-top: 48px;
}
.content h2 {
  font-size: clamp(27px, 4vw, 38px);
  margin-bottom: 20px;
}
.content h3 {
  letter-spacing: -0.025em;
}
.content {
  line-height: 1.75;
}
.content p,
.content ul,
.content ol {
  max-width: 72ch;
}
main.page:has(> .content:only-child) {
  max-width: 930px;
  padding-top: 64px;
  padding-bottom: 80px;
}
.mod-header {
  margin-bottom: 48px;
  align-items: start;
  gap: 22px;
}
.mod-header h1 {
  font-size: clamp(38px, 5vw, 62px);
  margin: 16px 0 22px;
}
.mod-index {
  background: var(--orange-soft);
  color: var(--orange);
  border-radius: 18px;
}
.mod-week {
  font-family: var(--font-body);
  letter-spacing: 0.03em;
}
.mod-titles {
  min-width: 0;
}
.mod-titles .lede {
  font-size: 21px;
  line-height: 1.45;
}
.mod-titles .chips {
  margin-top: 20px;
}
.content > nav.card {
  font-size: 14px;
  line-height: 2.2;
  background: transparent;
  border: 0;
  border-block: 1px solid var(--line);
  border-radius: 0;
  padding: 14px 0;
}
.content > nav a {
  white-space: nowrap;
}
.table-scroll {
  box-shadow: none;
  border-radius: 18px;
}
table caption {
  padding: 16px 18px;
  text-align: left;
  font-size: 14px;
  color: var(--text);
  font-weight: 600;
}
thead th {
  font-family: var(--font-body);
  font-size: 11px;
  letter-spacing: 0.055em;
}
tbody th {
  text-align: left;
  vertical-align: top;
  padding: 14px 16px;
  font-weight: 600;
  border-bottom: 1px solid var(--line);
  min-width: 140px;
}
tbody td {
  padding: 14px 16px;
}
tbody tr:last-child th {
  border-bottom: 0;
}
.source-note {
  border-top: 0;
  padding-top: 0;
  font-size: 12px;
}
.callout {
  box-shadow: none;
  border-radius: 18px;
}
pre {
  background: #17171b;
  color: #ececf1;
  border: 0;
  padding: 22px;
  border-radius: 16px;
}
pre code {
  color: inherit;
}
.q {
  border-radius: 20px;
  box-shadow: none;
}
.opt {
  border-radius: 12px;
  min-height: 46px;
}
.learning-page {
  padding-top: 72px;
}
.learning-page > h1 {
  font-size: clamp(38px, 5.5vw, 64px);
  max-width: 15ch;
  margin-bottom: 24px;
}
.route-grid .card {
  padding: 25px;
}
.site-footer {
  padding: 36px 0 48px;
  font-size: 12px;
  background: var(--surface-2);
}
.site-footer a {
  color: var(--muted);
}

/* Homepage */
.landing-hero {
  text-align: center;
  padding-top: 76px;
  padding-bottom: 46px;
}
.landing-hero .eyebrow {
  color: var(--orange-ink);
  margin-inline: auto;
  margin-bottom: 20px;
}
.landing-hero h1 {
  font-size: clamp(44px, 6.5vw, 86px);
  font-weight: 700;
  letter-spacing: -0.058em;
}
.hero-accent {
  color: var(--orange);
}
.hero-description {
  font-size: clamp(17px, 1.9vw, 22px);
  color: var(--muted);
  margin: 25px auto 0;
  line-height: 1.5;
  letter-spacing: -0.02em;
}
.hero-actions {
  display: flex;
  justify-content: center;
  align-items: center;
  flex-wrap: wrap;
  gap: 26px;
  margin-top: 28px;
}
.signal-stage {
  overflow: clip;
  position: relative;
  isolation: isolate;
  height: 400px;
  margin: 22px auto 0;
  max-width: 960px;
  display: grid;
  place-items: center;
}
.hero-device {
  position: relative;
  width: min(100%, 830px);
  z-index: 2;
  animation: device-float var(--motion-ambient) ease-in-out infinite;
  pointer-events: none;
}
.signal-orbit {
  position: absolute;
  width: 310px;
  height: 170px;
  border: 1px solid color-mix(in srgb, var(--orange) 18%, transparent);
  border-radius: 50%;
  transform: rotate(-10deg);
  animation: signal-radiate var(--motion-ambient) ease-out infinite;
  pointer-events: none;
}
.orbit-two {
  width: 470px;
  height: 260px;
  animation-delay: -2s;
}
.orbit-three {
  width: 640px;
  height: 350px;
  animation-delay: -4s;
}
.signal-readout {
  position: absolute;
  right: 0;
  top: 34px;
  text-align: left;
  z-index: 3;
  padding: 16px 22px;
  border-radius: 18px;
  background: color-mix(in srgb, var(--surface) 80%, transparent);
  border: 1px solid var(--line);
  backdrop-filter: blur(12px);
  box-shadow: 0 12px 40px #00000006;
}
.readout-label,
.readout-caption {
  display: block;
  font-size: 11px;
  color: var(--muted);
}
.signal-readout > div {
  color: var(--orange);
  font-family: var(--font-mono);
  font-size: 14px;
  margin: 5px 0;
}
.signal-readout b {
  font-size: 29px;
  font-weight: 500;
  color: inherit;
  letter-spacing: -0.04em;
}
.signal-tag {
  position: absolute;
  left: 12px;
  bottom: 38px;
  font-size: 12px;
  color: var(--muted);
  padding: 10px 15px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 999px;
  z-index: 3;
}
.status-dot {
  display: inline-block;
  width: 6px;
  height: 6px;
  background: #25865a;
  border-radius: 50%;
  margin-right: 6px;
}
.hero-board {
  position: absolute;
  width: 250px;
  left: -30px;
  top: -20px;
  z-index: 3;
  animation: device-float var(--motion-ambient) ease-in-out infinite reverse;
}
.hero-board[hidden] {
  display: none;
}
.signal-controls,
.firmware-controls {
  display: flex;
  justify-content: center;
  gap: 5px;
  padding: 5px;
  width: fit-content;
  max-width: 100%;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--surface-3);
  margin-inline: auto;
}
.signal-controls button,
.firmware-controls button {
  background: transparent;
  color: var(--muted);
  border: 0;
  border-radius: 999px;
  padding: 10px 20px;
  min-height: 42px;
  font: inherit;
  font-size: 13px;
  font-weight: 550;
  cursor: pointer;
  transition:
    color var(--motion-fast),
    background var(--motion-fast);
}
.signal-controls button[aria-pressed="true"],
.firmware-controls button[aria-pressed="true"] {
  background: var(--surface);
  color: var(--text);
  box-shadow: 0 1px 4px #00000012;
}
.visual-caption {
  color: var(--faint);
  font-size: 11px;
  margin: 14px auto 0;
}
.course-facts {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 20px;
  padding-block: 48px;
  border-block: 1px solid var(--line);
}
.course-facts div {
  text-align: center;
}
.course-facts strong {
  display: block;
  font-size: 34px;
  letter-spacing: -0.055em;
  font-weight: 600;
  line-height: 1.25;
}
.course-facts span {
  display: block;
  margin-top: 7px;
  font-size: 12px;
  color: var(--muted);
}
.story-section {
  padding-block: 100px;
}
.section-heading {
  margin-bottom: 38px;
}
.section-heading h2 {
  font-size: clamp(38px, 5vw, 60px);
}
.section-heading > p:last-child {
  margin: 18px 0 0;
  font-size: 19px;
  color: var(--muted);
  max-width: 49ch;
}
.experience-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 20px;
}
.experience-card {
  overflow: hidden;
  min-height: 390px;
  border-radius: 28px;
  padding: 32px;
  display: flex;
  flex-direction: column;
  text-decoration: none;
  color: var(--text);
  background: var(--surface);
  position: relative;
  transition:
    transform var(--motion-normal) var(--motion-ease),
    box-shadow var(--motion-normal);
}
.experience-card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-lift);
}
.section-number {
  display: block;
  font: 10px var(--font-mono);
  color: var(--faint);
  letter-spacing: 0.07em;
  margin-bottom: 25px;
}
.experience-card h3 {
  font-size: 32px;
  line-height: 1.1;
}
.experience-card p {
  margin: 15px 0 0;
  font-size: 15px;
  line-height: 1.5;
  color: var(--muted);
}
.card-link {
  display: flex;
  justify-content: space-between;
  gap: 15px;
  margin-top: auto;
  padding-top: 24px;
  font-size: 13px;
  font-weight: 550;
}
.experience-wave {
  color: #f5f5f7;
  background: #141416;
}
.experience-wave .section-number,
.experience-wave p {
  color: #aaaab0;
}
.wave-art {
  overflow: visible;
  width: calc(100% + 64px);
  max-width: none;
  margin: 35px -32px 10px;
}
.wave-base {
  stroke: #49423b;
  stroke-width: 1;
}
.wave-line {
  fill: none;
  stroke: #ff9754;
  stroke-width: 3;
  animation: wave-breathe var(--motion-ambient) ease-in-out infinite;
  transform-origin: center;
}
.evidence-art {
  padding: 24px 0 8px;
  display: grid;
  gap: 11px;
  font-size: 13px;
  color: var(--muted);
}
.evidence-art span {
  display: flex;
  gap: 10px;
  align-items: center;
}
.evidence-art i {
  width: 21px;
  height: 21px;
  border-radius: 50%;
  border: 1px solid var(--line-strong);
  position: relative;
}
.evidence-art i::after {
  content: "";
  position: absolute;
  left: 6px;
  top: 4px;
  width: 5px;
  height: 9px;
  border-right: 2px solid #2c8558;
  border-bottom: 2px solid #2c8558;
  transform: rotate(40deg);
}
.experience-build {
  background: var(--orange-soft);
}
.code-art {
  font: 14px/1.55 var(--font-mono);
  color: var(--muted);
  margin: 25px 0 0;
}
.code-art > span {
  color: var(--orange);
}
.wifi-feature-inner {
  display: grid;
  grid-template-columns: 1.1fr 1fr;
  align-items: center;
  border-radius: 32px;
  background: #141416;
  color: #f5f5f7;
  padding: 65px 56px;
  overflow: hidden;
}
.wifi-feature-copy {
  position: relative;
  z-index: 2;
}
.wifi-feature .eyebrow {
  color: #ffa467;
}
.wifi-feature h2 {
  font-size: clamp(38px, 5vw, 60px);
}
.wifi-feature p:not(.eyebrow) {
  color: #aaaab0;
  margin-top: 22px;
  max-width: 37ch;
  font-size: 17px;
}
.wifi-feature .btn {
  margin-top: 5px;
  background: #ff8a42;
  color: #221309;
  border: 0;
}
.wifi-feature .feature-footnote {
  font-size: 11px !important;
}
.board-scene {
  position: relative;
  display: grid;
  place-items: center;
  isolation: isolate;
  min-width: 0;
}
.board-scene img {
  position: relative;
  width: 115%;
  max-width: none;
  animation: device-float var(--motion-ambient) ease-in-out infinite;
}
.board-halo {
  position: absolute;
  width: 340px;
  height: 340px;
  border-radius: 50%;
  background: radial-gradient(circle, #f877262e, transparent 67%);
  z-index: -1;
}
.board-spec {
  font: 10px var(--font-mono);
  color: #aaaab0;
  letter-spacing: 0.14em;
}
.course-toolbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 18px;
  padding: 20px 0;
  border-block: 1px solid var(--line);
  margin-bottom: 25px;
  font-size: 13px;
}
.course-toolbar > span {
  color: var(--muted);
}
.mod-map {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
}
.mod-card {
  padding: 26px;
  border: 1px solid transparent;
  border-radius: 24px;
  box-shadow: none;
  gap: 16px;
  transition:
    transform var(--motion-normal) var(--motion-ease),
    border-color var(--motion-normal),
    box-shadow var(--motion-normal);
}
.mod-card:hover {
  transform: translateY(-4px);
}
.mod-card h3 {
  font-size: 22px;
  letter-spacing: -0.035em;
  line-height: 1.17;
}
.mod-card p {
  font-size: 14px;
  line-height: 1.6;
}
.mod-card .mc-idx {
  width: 30px;
  height: 30px;
  font-family: var(--font-mono);
  font-weight: 500;
  font-size: 12px;
  border-radius: 50%;
}
.mod-card .mc-week {
  font-family: var(--font-body);
  font-size: 10px;
  letter-spacing: 0.06em;
}
.mod-card .mc-foot {
  font-family: var(--font-body);
  font-size: 11px;
  border-top: 1px solid var(--line);
  padding-top: 15px;
}
.mod-card .mc-status {
  font-size: 10px;
}
.progress-details {
  border-block: 1px solid var(--line);
  padding: 22px 0;
}
.progress-details > summary {
  cursor: pointer;
  font-size: 15px;
  font-weight: 600;
}
.progress-details .progress-card {
  margin-top: 22px;
}
.progress-details p {
  margin-top: 15px;
  font-size: 12px;
  color: var(--muted);
}
.closing-section {
  padding-block: 25px 115px;
  text-align: center;
}
.closing-section > img {
  margin-bottom: 25px;
}
.closing-section h2 {
  font-size: clamp(38px, 6vw, 68px);
}
.closing-section p {
  margin: 18px auto;
  color: var(--muted);
  max-width: 40ch;
}

/* Interactive board diagram */
.firmware-explorer {
  border-radius: 28px;
  background: #141416;
  color: #f5f5f7;
  padding: 30px;
  margin: 36px 0 44px;
  overflow: hidden;
}
.firmware-explorer .eyebrow {
  color: #ffab73;
}
.firmware-explorer h2 {
  font-size: 31px;
  margin-bottom: 0;
}
.firmware-visual {
  position: relative;
  width: min(100%, 430px);
  margin: -5px auto 0;
}
.firmware-visual img {
  display: block;
  width: 100%;
  animation: device-float var(--motion-ambient) ease-in-out infinite;
}
.firmware-visual .signal-orbit {
  width: 230px;
  height: 220px;
  left: 25%;
  top: 15%;
  border-color: #ff964333;
}
.firmware-controls {
  background: #29292d;
  border-color: #3b3b40;
}
.firmware-controls button {
  color: #b8b8c0;
  font-size: 12px;
  padding-inline: 16px;
}
.firmware-controls button[aria-pressed="true"] {
  background: #efeff3;
  color: #1d1d1f;
}
.firmware-flow {
  display: grid;
  grid-template-columns: 1fr 25px 1fr 25px 1fr;
  align-items: center;
  gap: 8px;
  padding: 30px 0 18px;
  text-align: center;
}
.firmware-node {
  min-width: 0;
}
.firmware-node > span {
  display: block;
  color: #aaaab0;
  font-size: 10px;
  margin-bottom: 6px;
}
.firmware-node > b {
  display: block;
  color: #f5f5f7;
  font-size: 15px;
  font-weight: 550;
  line-height: 1.3;
}
.firmware-node > small {
  display: block;
  color: #ffab73;
  font: 10px/1.5 var(--font-mono);
  margin-top: 7px;
}
.flow-arrow {
  justify-self: center;
  width: 25px;
  height: 25px;
  pointer-events: none;
  color: #ffab73;
  font-size: 22px;
}
.firmware-explanation {
  font-size: 14px;
  color: #bdbdc5;
  line-height: 1.6;
  min-height: 4.8em;
  margin: 0 !important;
  padding-top: 18px;
  border-top: 1px solid #37373d;
}
.firmware-explorer .visual-caption {
  color: #aaaab0;
  text-align: center;
}
.reveal-pending {
  opacity: 0;
  transform: translateY(var(--motion-distance));
}
.reveal-visible {
  transition:
    opacity var(--motion-slow) var(--motion-ease),
    transform var(--motion-slow) var(--motion-ease);
  opacity: 1;
  transform: none;
}
@keyframes device-float {
  0%,
  100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(-9px);
  }
}
@keyframes signal-radiate {
  0% {
    transform: rotate(-10deg) scale(0.9);
    opacity: 0.1;
  }
  40% {
    opacity: 0.8;
  }
  100% {
    transform: rotate(-10deg) scale(1.15);
    opacity: 0.05;
  }
}
@keyframes wave-breathe {
  0%,
  100% {
    transform: scaleY(0.65);
    opacity: 0.7;
  }
  50% {
    transform: scaleY(1);
    opacity: 1;
  }
}
.motion-off *,
.motion-off *::before,
.motion-off *::after {
  animation: none !important;
  transition: none !important;
}
.motion-off .reveal-pending {
  opacity: 1;
  transform: none;
}
.motion-off .btn:hover,
.motion-off .btn:active,
.motion-off .mod-card:hover,
.motion-off .experience-card:hover {
  transform: none;
}
.motion-suspended *,
.is-offscreen * {
  animation-play-state: paused !important;
}
@media (max-width: 1100px) {
  .topbar-inner {
    gap: 10px;
  }
  .topnav a {
    padding-inline: 7px;
  }
}
@media (max-width: 980px) {
  .topnav {
    display: none;
    position: absolute;
    left: 0;
    right: 0;
    top: 100%;
    flex-direction: column;
    background: var(--surface);
    border-bottom: 1px solid var(--line);
    padding: 10px 18px 18px;
    box-shadow: var(--shadow-lift);
  }
  .topnav.open {
    display: flex;
  }
  .topnav a {
    padding: 10px;
    font-size: 15px;
  }
  .nav-toggle {
    display: inline-flex;
    margin-left: auto;
  }
  .topbar-inner {
    position: relative;
  }
  .experience-grid {
    gap: 14px;
  }
  .experience-card {
    padding: 25px;
  }
  .experience-card h3 {
    font-size: 28px;
  }
  .wifi-feature-inner {
    padding: 45px 36px;
  }
}
@media (max-width: 760px) {
  .wrap {
    padding-inline: 22px;
  }
  .landing-hero {
    padding-top: 54px;
  }
  .landing-hero h1 {
    font-size: clamp(39px, 7.3vw, 58px);
  }
  .hero-description br {
    display: none;
  }
  .hero-description {
    max-width: 34ch;
  }
  .signal-stage {
    height: 330px;
    margin-top: 25px;
  }
  .hero-device {
    width: 115%;
    max-width: none;
  }
  .signal-orbit {
    width: 190px;
    height: 130px;
  }
  .orbit-two {
    width: 290px;
    height: 200px;
  }
  .orbit-three {
    width: 390px;
    height: 270px;
  }
  .signal-readout {
    right: 0;
    top: 0;
    padding: 10px 14px;
  }
  .signal-readout b {
    font-size: 24px;
  }
  .readout-caption {
    display: none;
  }
  .signal-tag {
    left: 0;
    bottom: 18px;
    font-size: 10px;
  }
  .hero-board {
    width: 180px;
    top: 0;
    left: -20px;
  }
  .course-facts {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 28px 15px;
    padding-block: 35px;
  }
  .course-facts strong {
    font-size: 30px;
  }
  .story-section {
    padding-block: 68px;
  }
  .experience-grid {
    grid-template-columns: 1fr;
  }
  .experience-card {
    min-height: 330px;
    padding: 30px;
  }
  .experience-card h3 {
    font-size: 34px;
  }
  .wave-art {
    height: 120px;
    width: 100%;
    margin: 20px 0;
  }
  .wifi-feature-inner {
    grid-template-columns: 1fr;
    padding: 36px 28px;
    gap: 5px;
  }
  .board-scene img {
    width: min(100%, 390px);
  }
  .board-halo {
    width: 270px;
    height: 270px;
  }
  .mod-map {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .mod-card {
    padding: 22px;
  }
  .mod-card h3 {
    font-size: 20px;
  }
  .mod-card .mc-top {
    flex-wrap: wrap;
    gap: 7px;
  }
  .closing-section {
    padding-bottom: 75px;
  }
  .mod-header {
    gap: 14px;
  }
  .mod-header h1 {
    font-size: 41px;
  }
  .mod-titles .lede {
    font-size: 19px;
  }
  .firmware-explorer {
    padding: 24px;
  }
}
@media (max-width: 480px) {
  .wrap {
    padding-inline: 18px;
  }
  .topbar-inner {
    padding-inline: 14px;
    gap: 7px;
  }
  .brand {
    font-size: 17px;
  }
  .brand-logo {
    width: 26px;
    height: 29px;
  }
  .theme-btn,
  .motion-btn,
  .nav-toggle {
    width: 38px;
    min-width: 38px;
    height: 38px;
    min-height: 38px;
  }
  .motion-btn {
    flex-basis: 38px;
  }
  .hero-actions {
    gap: 20px;
  }
  .landing-hero h1 {
    font-size: clamp(37px, 9.4vw, 45px);
  }
  .landing-hero .eyebrow {
    font-size: 10px;
    letter-spacing: 0.025em;
  }
  .signal-stage {
    height: 285px;
    margin-top: 32px;
  }
  .hero-device {
    width: 121%;
  }
  .orbit-three {
    width: 280px;
    height: 225px;
  }
  .signal-readout {
    top: -3px;
  }
  .signal-readout b {
    font-size: 20px;
  }
  .readout-label {
    font-size: 9px;
  }
  .signal-readout > div {
    font-size: 11px;
  }
  .signal-tag {
    bottom: 10px;
  }
  .hero-board {
    width: 145px;
    top: -10px;
  }
  .signal-controls button {
    padding: 8px 14px;
    font-size: 11px;
  }
  .mod-map {
    grid-template-columns: 1fr;
  }
  .mod-card {
    padding: 25px;
  }
  .mod-card h3 {
    font-size: 23px;
  }
  .course-toolbar {
    align-items: start;
    flex-direction: column;
    gap: 8px;
  }
  .mod-header {
    display: block;
  }
  .mod-index {
    margin-bottom: 20px;
    width: 48px;
    height: 48px;
    font-size: 20px;
  }
  main.page:has(> .content:only-child) {
    padding-top: 38px;
  }
  .mod-header h1 {
    font-size: 39px;
  }
  .firmware-controls {
    border-radius: 18px;
    width: 100%;
  }
  .firmware-controls button {
    font-size: 11px;
    padding: 8px 10px;
    border-radius: 13px;
  }
  .firmware-flow {
    grid-template-columns: 1fr;
    gap: 12px;
  }
  .flow-arrow {
    transform: rotate(90deg);
    line-height: 1;
  }
  .firmware-explanation {
    min-height: 0;
  }
  .firmware-explorer h2 {
    font-size: 28px;
  }
}
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation: none !important;
    transition: none !important;
    scroll-behavior: auto !important;
  }
  .reveal-pending {
    opacity: 1;
    transform: none;
  }
  .btn:hover,
  .btn:active,
  .mod-card:hover,
  .experience-card:hover {
    transform: none;
  }
}
@media print {
  .reveal-pending {
    opacity: 1;
    transform: none;
  }
  .signal-orbit,
  .motion-btn,
  .signal-controls,
  .firmware-controls {
    display: none;
  }
  .firmware-explorer,
  .wifi-feature-inner {
    background: #fff;
    color: #000;
    border: 1px solid #aaa;
  }
  .firmware-explorer * {
    color: #000 !important;
  }
}

/* Keep long module names inside the quiz controls on narrow screens. */
[data-page="quiz"] .btn-row {
  display: grid;
  grid-template-columns: minmax(85px, 0.6fr) minmax(0, 2fr) auto;
  align-items: end;
}
[data-page="quiz"] .btn-row label {
  display: grid;
  gap: 6px;
  min-width: 0;
}
[data-page="quiz"] .btn-row select {
  min-width: 0;
  max-width: 100%;
  width: 100%;
  margin-left: 0 !important;
  min-height: 40px;
}
@media (max-width: 600px) {
  [data-page="quiz"] .btn-row {
    grid-template-columns: minmax(0, 1fr);
  }
}
