:root {
  --forest: #245B56;
  --forest-dark: #1A433F;
  --muted: #5B6763;
  --muted-light: #8A9692;
  --pale: #EDF4F1;
  --pale-2: #F6FAF8;
  --ink: #161A19;
  --line: #CFD8D4;
  --line-soft: #E3EAE7;
  --rose: #A64452;
  --hl-yellow: #FBF3D5;
  --hl-yellow-border: #D4B24C;
  --hl-red: #FAEAEC;
  --hl-red-border: #C46875;
  --sans: "TeX Gyre Heros", "Helvetica Neue", Helvetica, Arial, "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
  --serif: "TeX Gyre Schola", "Times New Roman", Georgia, "Songti SC", "Source Han Serif SC", "STSong", serif;
  --mono: "SF Mono", "JetBrains Mono", ui-monospace, Menlo, Consolas, monospace;
}

*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html, body {
  height: 100%;
  background: #ffffff;
  color: var(--ink);
  font-family: var(--sans);
  font-size: 18px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow: hidden;
}

::selection {
  background: #d5e6e1;
}

/* Top Progress Bar & Floating Chrome */
#bar {
  position: fixed;
  top: 0;
  left: 0;
  height: 2.5px;
  width: 0;
  background: var(--forest);
  z-index: 90;
  transition: width 0.3s ease;
}

.chrome {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 80;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 12px 32px;
  pointer-events: none;
}

.chrome-left {
  font-family: var(--mono);
  font-size: 12px;
  letter-spacing: 0.06em;
  color: var(--muted);
}

.chrome-left b {
  color: var(--forest);
}

.rqnav {
  display: flex;
  gap: 6px;
  pointer-events: auto;
}

.rqnav button {
  appearance: none;
  font-family: var(--sans);
  font-size: 12.5px;
  font-weight: 600;
  color: var(--muted);
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.9);
  backdrop-filter: blur(8px);
  padding: 4px 12px;
  cursor: pointer;
}

.rqnav button:hover {
  color: var(--forest);
  border-color: var(--forest);
}

.rqnav button.on {
  color: #ffffff;
  background: var(--forest);
  border-color: var(--forest);
}

.chrome-right {
  pointer-events: auto;
  display: flex;
  gap: 8px;
}

.chrome-btn {
  appearance: none;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.9);
  color: var(--muted);
  font: 500 12px/1 var(--sans);
  padding: 5px 10px;
  cursor: pointer;
}

.chrome-btn:hover {
  color: var(--forest);
  border-color: var(--forest);
}
a.chrome-btn { display: inline-flex; align-items: center; text-decoration: none; white-space: nowrap; }
.deck-return { margin-top: 24px; font: 500 15px/1.5 var(--sans); color: var(--muted); }
.deck-return a { color: var(--forest); text-underline-offset: 4px; }
.chrome a:focus-visible, .deck-return a:focus-visible { outline: 2px solid var(--forest); outline-offset: 4px; }
@media (max-width: 1000px) {
  .chrome { flex-wrap: wrap; gap: 8px; padding: 10px 18px; background: rgba(255,255,255,.96); }
  .chrome-left { display: none; }
  .chrome-right { order: -1; flex-basis: 100%; justify-content: flex-end; }
  .rqnav { flex-wrap: wrap; }
  .rqnav button { padding-inline: 8px; }
  .deck .slide { padding-top: 128px; }
}

.cover-recording {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  margin-top: 24px;
  padding: 9px 18px;
  border: 1px solid var(--line);
  color: var(--forest);
  font: 500 15px/1.4 var(--sans);
  text-decoration: none;
}
.cover-recording:hover { background: var(--pale); border-color: var(--forest); }
.cover-recording:focus-visible { outline: 2px solid var(--forest); outline-offset: 4px; }

/* Full-bleed Scroll-Snap Deck */
.deck {
  height: 100vh;
  overflow-y: auto;
  scroll-snap-type: y mandatory;
  scroll-behavior: smooth;
  scrollbar-width: none;
}

.deck::-webkit-scrollbar {
  display: none;
}

.slide {
  min-height: 100vh;
  scroll-snap-align: start;
  scroll-snap-stop: always;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 62px 56px 66px;
  position: relative;
  background: #ffffff;
}

.in {
  max-width: 1180px;
  margin: 0 auto;
  width: 100%;
}

.speaker-note {
  display: none;
}

/* Right Dot Rail & Bottom Minimal HUD */
.rail {
  position: fixed;
  right: 16px;
  top: 50%;
  transform: translateY(-50%);
  z-index: 80;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.rail i {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--line);
  cursor: pointer;
  transition: 0.2s;
  display: block;
}

.rail i[data-d="1"] {
  border-radius: 0;
  border: 1px solid var(--muted);
  background: #ffffff;
}

.rail i.on {
  background: var(--forest);
  border-color: var(--forest);
  transform: scale(1.45);
}

.hud {
  position: fixed;
  bottom: 14px;
  right: 28px;
  z-index: 80;
  display: flex;
  align-items: center;
  gap: 8px;
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(8px);
  border: 1px solid var(--line);
  padding: 4px 10px;
}

.hud button {
  appearance: none;
  border: none;
  background: transparent;
  color: var(--muted);
  cursor: pointer;
  font-size: 14px;
  padding: 2px 6px;
}

.hud button:hover:not(:disabled) {
  color: var(--forest);
}

.hud button:disabled {
  opacity: 0.3;
  cursor: default;
}

.hud .ctr {
  font-family: var(--mono);
  font-size: 12px;
  color: var(--muted);
  min-width: 126px;
  text-align: center;
}

.hud .ctr b {
  color: var(--forest);
}

.hud .ctr .sec {
  display: block;
  font-family: var(--sans);
  font-size: 10.5px;
  color: var(--muted-light);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 146px;
}

/* Headings & Body Subheadings */
.s-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-bottom: 11px;
  border-bottom: 1.2px solid var(--forest);
  margin-bottom: 26px;
  gap: 16px;
}

.s-head h2 {
  font-family: var(--sans);
  font-size: clamp(26px, 2.35vw, 33px);
  font-weight: 700;
  color: var(--forest);
  letter-spacing: -0.01em;
}

.s-head .tag {
  font-family: var(--mono);
  font-size: 12.5px;
  color: var(--muted);
  white-space: nowrap;
}

.sub-banner {
  font-size: 24px;
  font-weight: 700;
  color: var(--ink);
  margin-bottom: 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.sub-banner em {
  font-style: normal;
  color: var(--forest);
}

/* =========================================================
   Interactive Segmented Sliders & Pill Tabs (Jetriever Style)
   ========================================================= */
.seg-switch {
  position: relative;
  display: inline-grid;
  grid-template-columns: 1fr 1fr;
  border: 1.4px solid var(--forest);
  background: var(--pale);
  padding: 2px;
  user-select: none;
  cursor: pointer;
}

.seg-switch .thumb {
  position: absolute;
  top: 2px;
  bottom: 2px;
  left: 2px;
  width: calc(50% - 2px);
  background: var(--forest);
  transition: transform 0.22s cubic-bezier(0.22, 1, 0.36, 1), background-color 0.22s ease;
  z-index: 0;
}

.seg-switch[data-mode="fail"] .thumb {
  background: var(--rose);
  transform: translateX(0%);
}

.seg-switch[data-mode="ok"] .thumb,
.seg-switch[data-state="1"] .thumb {
  background: var(--forest);
  transform: translateX(100%);
}

.seg-switch button {
  position: relative;
  z-index: 1;
  appearance: none;
  border: none;
  background: transparent;
  padding: 5px 14px;
  font: 600 12.5px/1.2 var(--sans);
  color: var(--muted);
  cursor: pointer;
  white-space: nowrap;
  transition: color 0.18s ease;
}

.seg-switch button.active {
  color: #ffffff;
}

.pill-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.pill-tab {
  appearance: none;
  border: 1px solid var(--line);
  background: #ffffff;
  color: var(--muted);
  font: 600 12.5px/1 var(--sans);
  padding: 7px 13px;
  cursor: pointer;
  transition: 0.15s;
}

.pill-tab:hover {
  border-color: var(--forest);
  color: var(--forest);
}

.pill-tab.active {
  background: var(--forest);
  border-color: var(--forest);
  color: #ffffff;
}

/* Cover & RQ Dividers */
.cover-center, .rq-center {
  text-align: center;
  padding: 40px 0;
}

.cover-en {
  font-family: var(--sans);
  font-size: clamp(54px, 5.6vw, 80px);
  font-weight: 700;
  color: var(--forest);
  letter-spacing: -0.025em;
  line-height: 1.08;
  margin-bottom: 16px;
}

.cover-zh {
  font-family: var(--sans);
  font-size: clamp(24px, 2.3vw, 33px);
  font-weight: 600;
  color: var(--ink);
}

.cover-rule {
  width: 120px;
  border: 0;
  border-top: 1.5px solid var(--forest);
  margin: 34px auto;
}

.cover-meta {
  font-family: var(--serif);
  font-size: 20px;
  line-height: 1.8;
  color: var(--muted);
}

.cover-meta b {
  color: var(--ink);
}

.rq-label {
  font-family: var(--mono);
  font-size: 15px;
  font-weight: 600;
  color: var(--muted);
  letter-spacing: 0.12em;
  margin-bottom: 14px;
}

.rq-title {
  font-family: var(--sans);
  font-size: clamp(42px, 4.2vw, 60px);
  font-weight: 700;
  color: var(--forest);
  line-height: 1.22;
}

/* =========================================================
   Refined Architectural Pipeline Component
   ========================================================= */
.pipe-wrap {
  width: 100%;
  padding: 8px 0;
}

.pipe-grid {
  display: grid;
  grid-template-columns: 1.08fr 0.78fr 1.08fr 1.02fr 1.08fr 0.72fr 1.02fr;
  align-items: center;
  gap: 8px;
}

.p-node {
  background: #ffffff;
  border: 1.5px solid #2b3330;
  padding: 15px 13px;
  min-height: 184px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  position: relative;
}

.p-node-head {
  font-family: var(--mono);
  font-size: 10.5px;
  font-weight: 600;
  letter-spacing: 0.06em;
  color: var(--muted);
  text-transform: uppercase;
  padding-bottom: 7px;
  border-bottom: 1px solid var(--line-soft);
  margin-bottom: 9px;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.p-node-foot {
  text-align: center;
  font-family: var(--serif);
  font-size: 20px;
  color: var(--ink);
  margin-top: 10px;
}

.mini-chat {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.mc-u {
  align-self: flex-end;
  background: var(--forest);
  color: #ffffff;
  font-size: 11.5px;
  padding: 4px 9px;
  border-radius: 8px 8px 2px 8px;
  max-width: 88%;
}

.mc-a {
  align-self: flex-start;
  background: var(--pale);
  color: var(--ink);
  font-size: 11.5px;
  padding: 4px 9px;
  border-radius: 8px 8px 8px 2px;
  max-width: 88%;
}

.mini-store {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.ms-row {
  border: 1px solid var(--line);
  background: var(--pale-2);
  padding: 5px 8px;
  font-size: 11.5px;
  color: var(--muted);
  display: flex;
  align-items: center;
  gap: 6px;
}

.ms-row.gold {
  border-color: var(--forest);
  background: var(--pale);
  color: var(--forest);
  font-weight: 600;
}

.ms-dot {
  width: 5px;
  height: 5px;
  background: currentColor;
  flex-shrink: 0;
}

.mini-ctx {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.mctx-card {
  border: 1px solid var(--line);
  border-left: 3px solid var(--forest);
  background: #ffffff;
  padding: 5.5px 8px;
  font-size: 11px;
  color: var(--muted);
  white-space: nowrap;
}

.mini-ans {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
  background: var(--pale);
  padding: 12px;
  border-left: 3px solid var(--forest);
}

.mini-ans b {
  font-size: 13px;
  color: var(--forest);
  margin-bottom: 4px;
}

.mini-ans span {
  font-size: 12px;
  color: var(--muted);
}

.p-stage {
  padding: 14px 8px;
  border-radius: 2px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: 184px;
  position: relative;
}

.p-stage.hl-yellow {
  background: var(--hl-yellow);
  outline: 1.5px dashed var(--hl-yellow-border);
}

.p-stage.hl-red {
  background: var(--hl-red);
  outline: 2px solid var(--hl-red-border);
}

.p-stage .st-badge {
  font-size: 11.5px;
  font-weight: 700;
  color: var(--forest);
  margin-bottom: 5px;
}

.p-stage .st-name {
  font-size: 17px;
  font-weight: 700;
  color: var(--ink);
  margin-bottom: 5px;
}

.p-stage.hl-red .st-name {
  color: var(--rose);
}

.p-stage .st-line {
  width: 100%;
  height: 2px;
  background: var(--ink);
  position: relative;
  margin: 6px 0;
}

.p-stage .st-line::after {
  content: "";
  position: absolute;
  right: -1px;
  top: -4px;
  border-left: 8px solid var(--ink);
  border-top: 5px solid transparent;
  border-bottom: 5px solid transparent;
}

.p-stage .st-sub {
  font-family: var(--mono);
  font-size: 11.5px;
  color: var(--muted);
  text-align: center;
  line-height: 1.45;
  margin-top: 4px;
}

.query-drop {
  display: grid;
  grid-template-columns: 1.08fr 0.78fr 1.08fr 1.02fr 1.08fr 0.72fr 1.02fr;
  gap: 8px;
  margin-bottom: 5px;
}

.query-drop-cell {
  grid-column: 4;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.q-chip {
  border: 1.5px solid var(--ink);
  background: #ffffff;
  padding: 5px 18px;
  font-family: var(--serif);
  font-size: 18px;
  font-weight: 600;
}

.q-down {
  width: 2px;
  height: 24px;
  background: var(--ink);
  position: relative;
}

.q-down::after {
  content: "";
  position: absolute;
  bottom: -2px;
  left: -4px;
  border-top: 8px solid var(--ink);
  border-left: 5px solid transparent;
  border-right: 5px solid transparent;
}

/* =========================================================
   Slide 3: Realistic Chat App UI + Answer Toggle
   ========================================================= */
.chat-windows {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 28px;
}

.chat-win {
  border: 1px solid var(--line);
  background: #fbfdfc;
  display: flex;
  flex-direction: column;
}

.chat-win-bar {
  padding: 9px 15px;
  background: var(--pale);
  border-bottom: 1px solid var(--line);
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 13px;
  font-weight: 700;
  color: var(--forest);
}

.chat-stream {
  padding: 14px 16px;
  display: flex;
  flex-direction: column;
  gap: 9px;
}

.time-sep {
  text-align: center;
  font-size: 11.5px;
  color: var(--muted-light);
  margin: 1px 0;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
}

.time-sep::before, .time-sep::after {
  content: "";
  width: 38px;
  height: 1px;
  background: var(--line-soft);
}

.msg-row {
  display: flex;
  align-items: flex-start;
  gap: 9px;
}

.msg-row.user {
  justify-content: flex-end;
}

.avatar {
  width: 25px;
  height: 25px;
  border-radius: 50%;
  background: var(--pale);
  border: 1px solid var(--forest);
  color: var(--forest);
  font: 700 10.5px/23px var(--mono);
  text-align: center;
  flex-shrink: 0;
  margin-top: 2px;
}

.bub {
  padding: 7.5px 12px;
  font-size: 14px;
  line-height: 1.45;
  max-width: 80%;
  transition: background-color 0.2s, border-color 0.2s;
}

.msg-row.user .bub {
  background: var(--forest);
  color: #ffffff;
  border-radius: 12px 12px 2px 12px;
}

.msg-row.bot .bub {
  background: #ffffff;
  color: var(--ink);
  border: 1px solid var(--line);
  border-radius: 12px 12px 12px 2px;
}

.msg-row.bot.fail .bub {
  border-color: var(--hl-red-border);
  background: #fff9fa;
}

.msg-row.bot.good .bub {
  border-color: var(--forest);
  background: var(--pale);
}

.verdict-pill {
  margin-left: auto;
  align-self: center;
  font-weight: 700;
  font-size: 18px;
  padding: 2px 5px;
}

.verdict-pill.ok { color: var(--forest); }
.verdict-pill.no { color: var(--rose); }

.rel-footer {
  margin-top: 20px;
  padding-top: 15px;
  border-top: 1px solid var(--line);
  display: flex;
  justify-content: center;
  gap: 64px;
  font-family: var(--serif);
  font-size: 21px;
}

.rel-item {
  display: flex;
  align-items: center;
  gap: 14px;
}

/* =========================================================
   Figures, Zoomable Frames & Stacked Paper Screenshots
   ========================================================= */
.zoomable {
  cursor: zoom-in;
}

.img-frame {
  border: 1px solid var(--line);
  background: #ffffff;
  padding: 10px;
}

.img-frame img {
  display: block;
  width: 100%;
  height: auto;
}

.paper-cascade {
  position: relative;
  width: 100%;
  height: 486px;
  margin-top: 8px;
}

.paper-shot {
  position: absolute;
  width: 452px;
  background: #ffffff;
  border: 1.5px solid #2b3330;
  padding: 6px;
  box-shadow: 0 10px 28px rgba(20, 28, 26, 0.11);
  transition: transform 0.24s cubic-bezier(0.22, 1, 0.36, 1), box-shadow 0.24s ease, border-color 0.2s, opacity 0.2s;
  cursor: zoom-in;
}

.paper-shot:hover, .paper-shot.is-focused {
  z-index: 30 !important;
  transform: translateY(-8px) scale(1.03);
  box-shadow: 0 20px 46px rgba(20, 28, 26, 0.22);
  border-color: var(--forest);
  border-width: 2px;
}

.paper-shot.is-dimmed {
  opacity: 0.72;
}

.paper-shot img {
  display: block;
  width: 100%;
  height: auto;
}

/* =========================================================
   Interactive Visual Bar Chart (P15 / P20)
   ========================================================= */
.hbar-list {
  display: flex;
  flex-direction: column;
  gap: 11px;
}

.hbar-row {
  display: grid;
  grid-template-columns: 165px 1fr 105px;
  align-items: center;
  gap: 14px;
  font-size: 14.5px;
}

.hbar-track {
  height: 20px;
  background: #eff3f1;
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.hbar-fill {
  height: 100%;
  background: var(--forest);
  transition: width 0.35s ease;
}

.hbar-fill.rose {
  background: var(--rose);
}

.hbar-fill.muted {
  background: #96a8a3;
}

.hbar-pair {
  display: flex;
  flex-direction: column;
  gap: 3px;
}

.hbar-pair i {
  display: block;
  height: 9px;
}

/* Paradigm Cards (P19) */
.paradigm-card {
  background: var(--pale);
  border: 1.5px solid transparent;
  padding: 11px 13px;
  cursor: pointer;
  transition: 0.16s;
  text-align: left;
}

.paradigm-card:hover, .paradigm-card.active {
  border-color: var(--forest);
  background: #ffffff;
}

/* =========================================================
   Booktabs Tables
   ========================================================= */
table.booktabs {
  width: 100%;
  border-collapse: collapse;
  font-family: var(--serif);
  font-variant-numeric: lining-nums tabular-nums;
  font-size: 17.5px;
  color: var(--ink);
}

.booktabs thead th {
  border-top: 2px solid var(--ink);
  border-bottom: 1.2px solid var(--ink);
  padding: 8.5px 14px;
  text-align: left;
  font-family: var(--sans);
  font-size: 14.5px;
  font-weight: 700;
}

.booktabs td {
  padding: 7.5px 14px;
}

.booktabs .num {
  text-align: right;
}

.booktabs tr.group td {
  font-style: italic;
  color: var(--muted);
  padding-top: 9px;
  padding-bottom: 3px;
  border-top: 0.8px solid var(--line);
}

.booktabs tr.group-first td {
  border-top: none;
}

.booktabs tr.pale td {
  background: var(--pale);
  font-weight: 700;
}

.booktabs tbody tr:last-child td {
  border-bottom: 2px solid var(--ink);
}

.fig-cap {
  margin-top: 12px;
  font-family: var(--sans);
  font-size: 14px;
  color: var(--muted);
  text-align: center;
}

.fig-cap b {
  color: var(--forest);
}

/* Brace Layouts */
.brace-row {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 28px;
}

.brace-items {
  display: flex;
  flex-direction: column;
  gap: 24px;
  font-size: 30px;
  font-weight: 600;
}

.brace-items small {
  font-size: 18px;
  font-weight: 400;
  color: var(--muted);
  margin-left: 14px;
}

/* QR Pair */
.qr-pair {
  display: flex;
  justify-content: center;
  gap: 96px;
  margin-top: 40px;
}

.qr-box {
  width: 236px;
  height: 236px;
  border: 1.8px solid var(--ink);
  background: #ffffff;
  padding: 6px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--muted);
  font-size: 15px;
}

.qr-box img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.qr-label {
  margin-top: 12px;
  text-align: center;
  font-size: 22px;
  font-weight: 700;
  color: var(--forest);
}

/* Lightbox */
.lb {
  position: fixed;
  inset: 0;
  z-index: 200;
  background: rgba(18, 24, 22, 0.92);
  display: none;
  align-items: center;
  justify-content: center;
  padding: 28px;
  cursor: zoom-out;
  backdrop-filter: blur(4px);
}

.lb.open {
  display: flex;
}

.lb img {
  max-width: 94vw;
  max-height: 92vh;
  background: #ffffff;
  padding: 8px;
}

/* Slide Sorter Grid (G) */
.sorter {
  position: fixed;
  inset: 0;
  z-index: 150;
  background: #f4f7f6;
  display: none;
  overflow-y: auto;
  padding: 36px 48px 64px;
}

.sorter.open {
  display: block;
}

.sorter-grid {
  max-width: 1320px;
  margin: 16px auto 0;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
}

.sorter-card {
  appearance: none;
  border: 1px solid var(--line);
  background: #ffffff;
  padding: 12px 14px;
  text-align: left;
  cursor: pointer;
}

.sorter-card:hover, .sorter-card.on {
  border-color: var(--forest);
  background: var(--pale);
}

.sorter-card b {
  font-family: var(--mono);
  font-size: 11.5px;
  color: var(--forest);
  display: block;
  margin-bottom: 3px;
}

.sorter-card span {
  font-size: 13.5px;
  font-weight: 600;
  color: var(--ink);
}

dialog#notes-modal {
  border: 1.5px solid var(--forest);
  padding: 24px 28px;
  max-width: 640px;
  width: 90vw;
  background: #ffffff;
  color: var(--ink);
  margin: auto;
}

/* =========================================================
   Laser Pointer Cursor (Active whenever mouse enters window)
   ========================================================= */
html.laser-mode,
html.laser-mode * {
  cursor: none !important;
}

#laser-dot {
  position: fixed;
  top: 0;
  left: 0;
  width: 12px;
  height: 12px;
  margin-left: -6px;
  margin-top: -6px;
  border-radius: 50%;
  pointer-events: none;
  z-index: 9999;
  opacity: 0;
  will-change: transform, opacity;
  background: radial-gradient(circle, #ffffff 0%, #ff5858 34%, #e01b24 70%, rgba(224, 27, 36, 0.88) 100%);
  box-shadow: 0 0 8px 2px rgba(230, 25, 35, 0.72), 0 0 20px 5px rgba(230, 25, 35, 0.28);
  transition: opacity 0.12s ease, box-shadow 0.12s ease;
}

html.laser-mode #laser-dot.visible {
  opacity: 1;
}

html.laser-down #laser-dot {
  box-shadow: 0 0 11px 4px rgba(230, 25, 35, 0.92), 0 0 28px 8px rgba(230, 25, 35, 0.44);
}

/* =========================================================
   P03: Per-Example Horizontal Swipe Answer Track (No Buttons)
   ========================================================= */
.swipe-hint {
  font-family: var(--mono);
  font-size: 11px;
  font-weight: 500;
  color: var(--muted);
}

.ans-slider {
  position: relative;
  width: 100%;
  user-select: none;
}

.ans-track {
  display: flex;
  overflow-x: auto;
  overflow-y: hidden;
  scroll-snap-type: x mandatory;
  scroll-behavior: smooth;
  scrollbar-width: none;
  -webkit-overflow-scrolling: touch;
  gap: 12px;
}

.ans-track::-webkit-scrollbar {
  display: none;
}

.ans-track.dragging {
  scroll-snap-type: none;
  scroll-behavior: auto;
}

.ans-pane {
  flex: 0 0 100%;
  width: 100%;
  scroll-snap-align: start;
  scroll-snap-stop: always;
}

.ans-dots {
  display: flex;
  justify-content: center;
  gap: 7px;
  margin-top: 7px;
}

.ans-dots i {
  width: 16px;
  height: 3px;
  background: var(--line);
  transition: background-color 0.2s, width 0.2s;
}

.ans-dots i.fail-dot.on {
  background: var(--rose);
  width: 24px;
}

.ans-dots i.ok-dot.on {
  background: var(--forest);
  width: 24px;
}

/* =========================================================
   P30: Booktabs Academic Summary Ledger
   ========================================================= */
.summary-ledger {
  border-top: 2px solid var(--ink);
  border-bottom: 2px solid var(--ink);
  margin-top: 6px;
}

.sum-row {
  display: grid;
  grid-template-columns: 168px 1fr;
  align-items: center;
  gap: 28px;
  padding: 23px 10px;
  border-bottom: 1px solid var(--line);
}

.sum-row:last-child {
  border-bottom: none;
}

.sum-rq {
  display: flex;
  flex-direction: column;
  gap: 3px;
}

.sum-rq b {
  font-family: var(--mono);
  font-size: 22px;
  color: var(--forest);
  letter-spacing: 0.02em;
}

.sum-rq span {
  font-size: 13.5px;
  font-weight: 600;
  color: var(--muted);
}

.sum-body {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px 12px;
  font-size: 18px;
  color: var(--ink);
}

.sum-tok {
  font-family: var(--mono);
  font-size: 15.5px;
  background: var(--pale-2);
  border: 1px solid var(--line);
  padding: 3px 10px;
  color: var(--ink);
}

.sum-sub {
  font-size: 16px;
  color: var(--muted);
}

.sum-arr {
  font-family: var(--mono);
  color: var(--forest);
  font-weight: 700;
  margin: 0 4px;
}

.sum-chip {
  font-family: var(--sans);
  font-size: 16px;
  font-weight: 600;
  padding: 6px 14px;
  border: 1px solid var(--line);
}

.sum-chip.ok {
  background: var(--pale);
  border-color: var(--forest);
  color: var(--forest);
}

.sum-chip.bad {
  background: var(--hl-red);
  border-color: var(--hl-red-border);
  color: var(--rose);
}

.sum-plans {
  flex-direction: column;
  align-items: flex-start;
  gap: 8px;
  font-size: 17.5px;
}

.sum-plans b {
  font-family: var(--mono);
  color: var(--forest);
}

/* =========================================================
   P31: Single Paper Screenshot Hero (Matches P05 Paper Shots)
   ========================================================= */
.paper-hero {
  max-width: 720px;
  margin: 4px auto 0;
  background: #ffffff;
  border: 1.5px solid #2b3330;
  padding: 8px;
  box-shadow: 0 12px 32px rgba(20, 28, 26, 0.11);
}

.paper-hero img {
  display: block;
  width: 100%;
  max-height: 505px;
  object-fit: contain;
}

@media print {
  html, body, .deck {
    height: auto;
    overflow: visible;
  }
  #bar, #laser-dot, .chrome, .rail, .hud, .lb, .sorter, dialog {
    display: none !important;
  }
  .slide {
    min-height: 0;
    padding: 40px 32px;
    page-break-after: always;
    break-after: page;
  }
}
