/* ═══════════════════════════════════════════════
   RESET + TOKENS
═══════════════════════════════════════════════ */
*, *::before, *::after {
  box-sizing: border-box; margin: 0; padding: 0;
  -webkit-tap-highlight-color: transparent;
}

:root {
  --black:  #111111;
  --white:  #ffffff;
  --off:    #F4F3F1;
  --dust:   #E8E7E4;
  --border: #D4D2CE;
  --mid:    #888880;
  --body:   #444440;

  --font-display: 'Bebas Neue', 'Arial Black', 'Arial Narrow', Arial, sans-serif;
  --font-mono:    'DM Mono', 'SF Mono', 'Fira Code', 'Courier New', monospace;
  --font-body:    'DM Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Helvetica, Arial, sans-serif;

  --p: clamp(16px, 3vh, 44px);
  --px: clamp(18px, 3.5vw, 52px);
}

html, body {
  height: 100%;
  font-family: var(--font-body);
  background: var(--off);
  color: var(--black);
  -webkit-font-smoothing: antialiased;
  overflow: hidden;
  touch-action: none;
}

#app {
  height: 100dvh;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.topbar {
  flex-shrink: 0;
  height: 50px;
  background: var(--black);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 var(--px);
  border-bottom: 1px solid rgba(255,255,255,.08);
  z-index: 100;
}
.topbar-logo { text-decoration: none; display: block; }
.topbar-logo svg { height: 20px; width: auto; display: block; }
.topbar-logo svg path { fill: white; }
.topbar-meta {
  font-family: var(--font-mono);
  font-size: .6rem;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: rgba(255,255,255,.38);
}

.progress-track {
  flex-shrink: 0;
  height: 2px;
  background: var(--dust);
}
.progress-fill {
  height: 100%;
  background: var(--black);
  transition: width .4s ease;
  width: 0%;
}

.viewport {
  flex: 1;
  overflow: hidden;
  position: relative;
  cursor: grab;
  min-height: 0;
}
.viewport.is-dragging { cursor: grabbing; }

.slides-container {
  display: flex;
  height: 100%;
  will-change: transform;
}

.slide {
  flex-shrink: 0;
  width: 100%;
  height: 100%;
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

.slide-dark  { background: var(--black); color: var(--white); }
.slide-light { background: var(--off);   color: var(--black); }
.slide-white { background: var(--white); color: var(--black); }

.slide > .sl,
.slide > .sr {
  padding: var(--p) var(--px);
}

.slide > .sl {
  flex: 0 0 auto;
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  gap: clamp(4px, .8vh, 8px);
  padding: clamp(20px, 4vh, 36px) var(--px) clamp(12px, 2vh, 20px);
  overflow-y: auto;
  overflow-x: hidden;
  container-type: inline-size;
  scrollbar-width: thin;
  scrollbar-color: var(--black) transparent;
}
.slide > .sl::-webkit-scrollbar { width: 5px; }
.slide > .sl::-webkit-scrollbar-track { background: transparent; }
.slide > .sl::-webkit-scrollbar-thumb { background: var(--black); border-radius: 0; }
.slide-dark > .sl { scrollbar-color: var(--white) transparent; }
.slide-dark > .sl::-webkit-scrollbar-thumb { background: var(--white); }
.slide > .sr {
  flex: 1;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  min-height: 0;
  padding: clamp(8px, 1.5vh, 16px) var(--px) clamp(16px, 3vh, 28px);
}

.s-eyebrow {
  font-family: var(--font-mono);
  font-size: clamp(.48rem, 1.4vw, .6rem);
  letter-spacing: .16em;
  text-transform: uppercase;
  color: var(--mid);
  flex-shrink: 0;
  margin-bottom: clamp(12px, 2.5vh, 28px);
}
.slide-dark .s-eyebrow { color: rgba(255,255,255,.35); }

.s-display {
  font-family: var(--font-display);
  font-size: min(clamp(2.6rem, 13cqw, 6.5rem), 24cqw);
  line-height: .88;
  letter-spacing: .01em;
  flex-shrink: 0;
}

.s-body {
  font-size: clamp(.78rem, 1.8vw, .92rem);
  line-height: 1.55;
  color: var(--body);
  font-weight: 300;
  flex-shrink: 0;
  margin-top: clamp(14px, 2.5vh, 24px);
}
.slide-dark .s-body { color: rgba(255,255,255,.6); }
.s-body strong { color: var(--black); font-weight: 500; }
.slide-dark .s-body strong { color: rgba(255,255,255,.9); }

.s-rule {
  border: none;
  border-top: 1px solid var(--border);
  flex-shrink: 0;
}
.slide-dark .s-rule { border-color: rgba(255,255,255,.12); }

.s-footnote {
  font-family: var(--font-mono);
  font-size: clamp(.5rem, 1.4vw, .58rem);
  letter-spacing: .06em;
  color: var(--mid);
  line-height: 1.5;
  flex-shrink: 0;
}
.slide-dark .s-footnote { color: rgba(255,255,255,.25); }

/* ═══════════════════════════════════════════════
   BOTTOM NAV — defined here, outside any media query
═══════════════════════════════════════════════ */
.bottom-nav {
  flex-shrink: 0;
  min-height: clamp(64px, 10dvh, 80px);
  background: var(--white);
  border-top: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px var(--px);
  padding-bottom: max(12px, env(safe-area-inset-bottom));
  gap: 16px;
}
.nav-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  border: 1.5px solid var(--border);
  background: transparent;
  cursor: pointer;
  transition: background .15s, border-color .15s;
  flex-shrink: 0;
}
.nav-btn:hover { background: var(--off); border-color: var(--black); }
.nav-btn:disabled { opacity: .3; cursor: default; pointer-events: none; }
.nav-btn svg { display: block; }
.nav-btn.primary {
  width: auto;
  padding: 0 18px;
  border-radius: 24px;
  background: var(--black);
  border-color: var(--black);
  color: var(--white);
  font-family: var(--font-mono);
  font-size: .65rem;
  letter-spacing: .12em;
  text-transform: uppercase;
  white-space: nowrap;
  gap: 8px;
}
.nav-btn.primary:hover { background: #2c2c2c; }
.nav-dots {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  flex: 1;
}
.nav-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--dust);
  transition: background .2s, transform .2s;
  cursor: pointer;
  border: none;
  padding: 0;
  flex-shrink: 0;
}
.nav-dot.active { background: var(--black); transform: scale(1.3); }
.nav-dot.filled { background: var(--border); }
.nav-dot-build { transition: width .3s ease, border-radius .3s ease, background .2s, transform .2s; position: relative; overflow: hidden; }
.nav-dot-build.active { width: 24px; border-radius: 3px; transform: none; background: var(--dust); }
.nav-dot-build.active::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  height: 100%;
  width: var(--build-progress, 0%);
  background: var(--black);
  border-radius: 3px;
  transition: width .3s ease;
}
.nav-dot-build.filled { width: 24px; border-radius: 3px; transform: none; background: var(--black); }

/* ═══════════════════════════════════════════════
   DESKTOP LAYOUT (≥ 768px)
═══════════════════════════════════════════════ */
@media (orientation: landscape) {
  .topbar { height: 54px; }

  .slide {
    display: grid !important;
    grid-template-columns: 1fr 1fr;
    grid-template-rows: 1fr;
    overflow: hidden;
  }

  .slide > .sl,
  .slide > .sr {
    height: 100%;
    display: flex;
    flex-direction: column;
    padding: var(--p) var(--px);
    min-height: 0;
  }
  .slide > .sl {
    overflow-y: auto;
    overflow-x: hidden;
  }
  .slide > .sr {
    overflow: hidden;
  }

  .slide > .sl {
    border-right: 1px solid rgba(0,0,0,.07);
    justify-content: space-between;
  }
  .slide-dark > .sl { border-right-color: rgba(255,255,255,.07); }

  .slide > .sl > div:first-child {
    display: flex;
    flex-direction: column;
    gap: clamp(8px, 1.5vh, 16px);
  }

  .s-rule-mobile-only { display: none; }
  .matrix-mobile-rule { display: none; }
  .mobile-layer-summary { display: none; }

  .layer-summary {
    display: flex;
    flex-direction: column;
    gap: clamp(12px, 2vh, 22px);
    margin-top: 0;
  }
  .layer-summary-item {
    display: flex;
    flex-direction: column;
    gap: 3px;
  }
  .layer-summary-name {
    font-family: var(--font-mono);
    font-size: clamp(.55rem, 1vh, .7rem);
    letter-spacing: .14em;
    text-transform: uppercase;
    color: var(--black);
  }
  .layer-summary-els {
    font-size: clamp(.85rem, 1.6vh, 1.05rem);
    color: var(--mid);
    line-height: 1.4;
  }
  .layer-summary-desc {
    font-size: clamp(.78rem, 1.4vh, .92rem);
    color: var(--mid);
    font-style: italic;
    line-height: 1.4;
    opacity: .75;
  }

  .slide-matrix-fullbleed > .sr {
    padding: 0 !important;
  }
  .slide-matrix-fullbleed > .sr .matrix-fill {
    padding: 0;
  }
  .slide-matrix-fullbleed > .sr .matrix-wrap {
    border-radius: 0;
    border: none;
    border-top: 1px solid var(--border);
  }

  .slide-matrix-fullbleed > .sl .s-display {
    font-size: min(clamp(4rem, 14vh, 13rem), 24cqw) !important;
    line-height: .86 !important;
  }

  .s-display {
    font-size: min(clamp(4rem, 14vh, 13rem), 24cqw);
    margin-bottom: 0;
    line-height: .86;
  }

  .s-body {
    font-size: clamp(.95rem, 1.9vh, 1.25rem);
    line-height: 1.6;
  }

  .s-eyebrow {
    font-size: clamp(.55rem, 1vh, .68rem);
  }

  .s-footnote {
    font-size: clamp(.52rem, .9vh, .62rem);
  }
}

@media (min-width: 1200px) {
  .slide > .sl,
  .slide > .sr {
    padding: clamp(36px, 5vh, 60px) clamp(36px, 3.5vw, 60px);
  }
}

/* ═══════════════════════════════════════════════
   COVER SLIDE
═══════════════════════════════════════════════ */
@media (orientation: landscape) {
  .slide-cover {
    grid-template-columns: 1fr !important;
  }
  .slide-cover > .sl {
    grid-column: 1 / 3;
    border-right: none;
    justify-content: space-between;
    overflow: visible;
  }
  .slide-cover .s-display {
    font-size: min(clamp(6rem, 20vh, 16rem), 24cqw) !important;
    line-height: .82 !important;
  }
  .cover-bottom {
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    gap: 20px;
  }
}

@media (orientation: portrait) {
  .slide {
    overflow-y: auto;
    height: 100%;
  }
  .slide > .sr {
    flex: none;
    overflow: visible;
  }
  .cover-bottom {
    display: flex;
    flex-direction: column;
    gap: 4px;
  }
  .cover-bottom .s-footnote:last-child {
    display: none;
  }
  .slide-cover .s-display {
    font-size: min(clamp(3.4rem, 14dvh, 6.5rem), 24cqw) !important;
    line-height: .84 !important;
  }
}

.slide-cover .sl {
  align-items: flex-start;
  text-align: left;
}
.slide-cover .s-eyebrow {
  margin-bottom: clamp(12px, 2.5vh, 28px);
}

.cover-footer {
  width: 100%;
  margin-top: auto;
}
.cover-footer-rule {
  height: 1px;
  background: rgba(255,255,255,.2);
  width: 100%;
  margin-bottom: clamp(10px, 1.8vh, 18px);
}
.cover-subhead {
  font-family: var(--font-body);
  font-size: clamp(1.1rem, 2.4vw, 1.5rem);
  font-weight: 500;
  color: rgba(255,255,255,.8);
  margin-top: clamp(10px, 2vh, 20px);
  line-height: 1.4;
}
.cover-bottom {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  gap: 20px;
}
@media (orientation: portrait) {
  .cover-bottom {
    flex-direction: column;
    align-items: flex-start;
    gap: 4px;
  }
  .cover-bottom .s-footnote:last-child {
    display: none;
  }
  .cover-subhead {
    font-size: clamp(.95rem, 3.8vw, 1.15rem);
  }
}

/* Problem slide */
.problem-label {
  font-family: var(--font-body);
  font-size: clamp(.95rem, 2vh, 1.2rem);
  font-weight: 600;
  letter-spacing: 0;
  text-transform: none;
  color: var(--black);
  padding-bottom: clamp(8px, 1.5vh, 14px);
  border-bottom: 1px solid var(--border);
  flex-shrink: 0;
}

@media (orientation: portrait) {
  .slide-problem > .sl {
    flex: 0 0 auto;
    max-height: 42dvh;
    overflow: hidden;
  }
  .slide-problem > .sl .s-body:last-of-type {
    display: none;
  }
  .slide-problem > .sr {
    flex: 1;
    min-height: 0;
  }
}

/* ═══════════════════════════════════════════════
   RIGHT PANEL CONTENT
═══════════════════════════════════════════════ */
.sr-fill {
  flex: 1;
  display: flex;
  flex-direction: column;
  min-height: 0;
  overflow: hidden;
}

.sr-heading {
  font-family: var(--font-display);
  font-size: clamp(1.4rem, 3vh, 2.2rem);
  letter-spacing: .03em;
  color: var(--black);
  padding-bottom: clamp(10px, 1.8vh, 16px);
  border-bottom: 1px solid var(--border);
  flex-shrink: 0;
  line-height: 1;
}

.breakdown-list-v2 {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  min-height: 0;
}
.breakdown-item-v2 {
  flex: 1;
  display: flex;
  align-items: center;
  gap: clamp(12px, 2.5vw, 22px);
  border-bottom: 1px solid var(--border);
  padding: clamp(5px, .9vh, 9px) 0;
}
.breakdown-item-v2:last-child { border-bottom: none; }
.breakdown-icon {
  width: clamp(28px, 4vh, 40px);
  height: clamp(28px, 4vh, 40px);
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}
.breakdown-icon svg { width: 100%; height: 100%; display: block; }
.breakdown-content { flex: 1; }
.breakdown-heading-label {
  font-family: var(--font-mono);
  font-size: clamp(.52rem, 1vh, .62rem);
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--mid);
  margin-bottom: clamp(2px, .4vh, 4px);
  display: block;
}
.breakdown-heading {
  font-size: clamp(.9rem, 1.8vh, 1.15rem);
  font-weight: 500;
  color: var(--black);
  margin-bottom: clamp(1px, .3vh, 4px);
  line-height: 1.2;
}
.breakdown-sub {
  font-size: clamp(.75rem, 1.4vh, .9rem);
  color: var(--mid);
  line-height: 1.4;
}

/* ── MATRIX GRID ── */
.matrix-fill {
  flex: 1;
  display: flex;
  flex-direction: column;
  min-height: 0;
  padding: 0;
}
.matrix-fill .matrix-wrap {
  flex: 1;
  margin-top: 0;
  display: flex;
  flex-direction: column;
  min-height: 0;
  border-radius: 0;
  border: 1px solid var(--border);
  overflow: hidden;
  background: var(--border);
}
.matrix-fill .matrix-grid {
  flex: 1;
  display: grid;
  grid-template-columns: clamp(32px, 5vw, 52px) 1fr 1fr 1fr;
  grid-template-rows: 1fr 1fr 1fr;
  gap: 1px;
  min-height: 0;
  height: 100%;
}
.matrix-fill .m-rl {
  font-size: clamp(.48rem, 1.1vw, .62rem);
  font-weight: 600;
  letter-spacing: .1em;
  align-self: stretch;
}
.matrix-fill .m-cell { min-height: 0; height: auto; justify-content: flex-start; align-self: stretch; }
.matrix-fill .m-cell-lbl {
  font-size: clamp(.55rem, 1.1vw, .72rem);
  letter-spacing: .12em;
  padding: clamp(10px, 1.5vh, 18px) clamp(10px, 1.5vw, 18px) 0;
}
.matrix-fill .m-cell-val {
  font-size: clamp(.62rem, 1.2vh, .82rem);
  padding: clamp(6px, 1vh, 10px) clamp(10px, 1.5vw, 18px);
  line-height: 1.3;
}

.matrix-wrap {
  border: 1px solid var(--border);
  border-radius: 0;
  overflow: hidden;
  background: var(--border);
}
.matrix-grid {
  display: grid;
  grid-template-columns: 32px 1fr 1fr 1fr;
  align-items: stretch;
  gap: 1px;
}
.m-rl {
  display: flex;
  align-items: center;
  justify-content: center;
  writing-mode: vertical-rl;
  transform: rotate(180deg);
  font-family: var(--font-mono);
  font-size: clamp(.42rem, 1.2vw, .56rem);
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--mid);
  background: var(--dust);
  padding: 8px 4px;
}
.m-cell {
  min-height: clamp(48px, 9vw, 90px);
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  background: var(--dust);
}
.m-cell.core { background: var(--black); }
.m-cell-lbl {
  font-family: var(--font-mono);
  font-size: clamp(.4rem, 1vw, .56rem);
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--mid);
  padding: 10px 10px 0;
}
.m-cell.core .m-cell-lbl { color: rgba(255,255,255,.45); }
.m-cell-val {
  font-size: clamp(.65rem, 1.4vw, .8rem);
  color: var(--body);
  line-height: 1.3;
  padding: 8px 10px 6px;
  border-top: 1px solid var(--border);
}
.m-cell.core .m-cell-val {
  color: rgba(255,255,255,.85);
  border-top-color: rgba(255,255,255,.12);
}

/* ── LAYERS ── */
.layers-fill {
  flex: 1;
  display: flex;
  flex-direction: column;
  min-height: 0;
}
.layers-fill .layers-list {
  flex: 1;
  display: flex;
  flex-direction: column;
  margin-top: 0;
  border: 1px solid var(--border);
  border-radius: 4px;
  overflow: hidden;
}
.layers-fill .layer-block {
  flex: 1;
  display: flex;
  flex-direction: column;
  border-bottom: 1px solid var(--border);
}
.layers-fill .layer-block:last-child { border-bottom: none; }
.layers-fill .layer-elements {
  flex: 1;
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
}
.layers-fill .layer-el {
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
}

.layers-list {
  margin-top: clamp(12px, 2vh, 20px);
  display: flex;
  flex-direction: column;
  border: 1px solid var(--border);
  border-radius: 4px;
  overflow: hidden;
}
.layer-block { border-bottom: 1px solid var(--border); }
.layer-block:last-child { border-bottom: none; }
.layer-head {
  padding: clamp(8px, 1.5vh, 14px) clamp(10px, 1.5vw, 16px);
  background: var(--black);
  display: flex;
  align-items: baseline;
  gap: 12px;
  flex-shrink: 0;
}
.layer-head-name {
  font-family: var(--font-mono);
  font-size: clamp(.52rem, 1vh, .65rem);
  letter-spacing: .14em;
  text-transform: uppercase;
  color: rgba(255,255,255,.5);
  flex-shrink: 0;
  width: clamp(56px, 8vw, 80px);
}
.layer-head-desc {
  font-size: clamp(.72rem, 1.4vh, .88rem);
  color: rgba(255,255,255,.65);
  font-weight: 300;
}
.layer-elements {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
}
.layer-el {
  padding: clamp(8px, 1.5vh, 14px) clamp(10px, 1.5vw, 14px);
  border-right: 1px solid var(--border);
  background: var(--white);
}
.layer-el:last-child { border-right: none; }
.layer-el-core {
  background: var(--black) !important;
  border-right: 1px solid rgba(255,255,255,.1) !important;
}
.layer-el-name {
  font-family: var(--font-mono);
  font-size: clamp(.46rem, .9vh, .58rem);
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--mid);
  margin-bottom: clamp(3px, .5vh, 6px);
}
.layer-el-desc {
  font-size: clamp(.7rem, 1.4vh, .88rem);
  color: var(--body);
  line-height: 1.4;
}

/* ── DIAGONALS ── */
.diag-group {
  flex: 1;
  display: flex;
  flex-direction: column;
  min-height: 0;
  justify-content: space-between;
}
.diag-group-item {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  border-bottom: 1px solid var(--border);
  padding: clamp(12px, 2.2vh, 24px) 0;
  min-height: 0;
}
.diag-group-item:last-child { border-bottom: none; }
.diag-group-label {
  font-family: var(--font-mono);
  font-size: clamp(.5rem, .9vh, .62rem);
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--mid);
  margin-bottom: clamp(2px, .3vh, 4px);
  flex-shrink: 0;
}
.diag-group-title {
  font-family: var(--font-display);
  font-size: clamp(1.2rem, 3vh, 2rem);
  color: var(--black);
  line-height: 1;
  letter-spacing: .02em;
  margin-bottom: clamp(4px, .6vh, 8px);
  flex-shrink: 0;
}
.diag-group-q {
  font-size: clamp(.8rem, 1.5vh, .98rem);
  color: var(--mid);
  line-height: 1.5;
  flex: 1;
  padding-top: 0;
}

/* ── PRINCIPLES ── */
.principles-fill {
  flex: 1;
  display: flex;
  flex-direction: column;
  min-height: 0;
}
.principles-fill .principles-list {
  flex: 1;
  display: flex;
  flex-direction: column;
  margin-top: 0;
  overflow: hidden;
}
.principles-fill .principle-item {
  flex: none;
}

.principles-list {
  margin-top: clamp(12px, 2vh, 20px);
  display: flex;
  flex-direction: column;
  border: 1px solid var(--border);
  border-radius: 4px;
  overflow: hidden;
  background: var(--white);
}
.principle-item {
  display: flex;
  gap: clamp(12px, 2vw, 18px);
  align-items: flex-start;
  padding: clamp(10px, 2vh, 20px) clamp(12px, 2vw, 18px);
  border-bottom: 1px solid var(--border);
}
.principle-item:last-child { border-bottom: none; }
.principle-num {
  font-family: var(--font-display);
  font-size: clamp(1.6rem, 4vh, 3rem);
  line-height: 1;
  color: var(--dust);
  flex-shrink: 0;
  width: clamp(24px, 4vw, 36px);
  padding-top: clamp(1px, .2vh, 3px);
}
.principle-title {
  font-size: clamp(.88rem, 2.5vh, 1.5rem);
  font-weight: 600;
  margin-bottom: clamp(3px, .5vh, 6px);
  color: var(--black);
}
.principle-desc {
  font-size: clamp(.75rem, 2vh, 1.2rem);
  color: var(--body);
  line-height: 1.55;
}

@media (orientation: landscape) {
  .principle-title {
    font-size: clamp(1.1rem, 2.8vh, 1.8rem);
    margin-bottom: clamp(6px, 1.2vh, 12px);
  }
  .principle-desc {
    font-size: clamp(.8rem, 1.5vh, 1rem);
    line-height: 1.45;
  }
  .principle-num {
    font-size: clamp(2rem, 6vh, 5rem);
    width: clamp(28px, 5vw, 52px);
  }
  .principle-item {
    padding: clamp(14px, 3vh, 28px) clamp(16px, 2.5vw, 28px);
  }
}

/* Mobile keyboard toolbar */
.keyboard-toolbar {
  display: none;
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 999;
  background: var(--dust);
  border-top: 1px solid var(--border);
  padding: 8px 16px;
  justify-content: flex-end;
  align-items: center;
}
.keyboard-toolbar.visible { display: flex; }
.keyboard-done-btn {
  font-family: var(--font-mono);
  font-size: .75rem;
  font-weight: 500;
  letter-spacing: .08em;
  color: var(--black);
  background: none;
  border: none;
  cursor: pointer;
  padding: 6px 12px;
}
@media (orientation: landscape) {
  .keyboard-toolbar { display: none !important; }
}

/* ═══════════════════════════════════════════════
   GATE SLIDE
═══════════════════════════════════════════════ */
.slide-gate {
  display: flex !important;
  flex-direction: column;
}
.gate-inner {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: clamp(20px, 5vh, 60px) var(--px);
  gap: clamp(24px, 5vh, 48px);
}
.gate-top {
  display: flex;
  flex-direction: column;
  gap: clamp(10px, 2vh, 18px);
}
.gate-field {
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.gate-label {
  font-family: var(--font-mono);
  font-size: clamp(.55rem, 1vh, .65rem);
  letter-spacing: .16em;
  text-transform: uppercase;
  color: rgba(255,255,255,.4);
}
.gate-input {
  width: 100%;
  background: rgba(255,255,255,.07);
  border: 1px solid rgba(255,255,255,.15);
  border-radius: 4px;
  padding: clamp(14px, 2vh, 18px) clamp(14px, 2vw, 18px);
  font-family: var(--font-body);
  font-size: 16px;
  font-weight: 500;
  color: var(--white);
  outline: none;
  transition: border-color .2s, background .2s;
  -webkit-appearance: none;
}
.gate-input:focus {
  border-color: rgba(255,255,255,.4);
  background: rgba(255,255,255,.1);
}
.gate-input::placeholder { color: rgba(255,255,255,.25); }

@media (orientation: landscape) {
  .slide-gate {
    display: grid !important;
    grid-template-columns: 1fr 1fr;
  }
  .gate-inner {
    justify-content: space-between;
    padding: var(--p) var(--px);
    border-right: 1px solid rgba(255,255,255,.07);
  }
  .slide-gate > .sr { display: flex !important; }
}

.name-input-wrap { width: 100%; max-width: 420px; }
.name-label {
  font-family: var(--font-mono);
  font-size: clamp(.55rem, 1vh, .65rem);
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--mid);
  display: block;
  margin-bottom: clamp(6px, 1vh, 10px);
}
.name-input {
  width: 100%;
  background: transparent;
  border: none;
  border-bottom: 2px solid var(--border);
  padding: clamp(6px, 1vh, 10px) 0;
  font-family: var(--font-display);
  font-size: clamp(1.8rem, 5vh, 3.5rem);
  color: var(--black);
  outline: none;
  transition: border-color .2s;
  letter-spacing: .02em;
}
.name-input:focus { border-color: var(--black); }
.name-input::placeholder { color: var(--dust); }

.build-layer-badge {
  font-family: var(--font-mono);
  font-size: clamp(.52rem, 1vh, .62rem);
  letter-spacing: .16em;
  text-transform: uppercase;
  color: var(--mid);
  margin-bottom: clamp(2px, .4vh, 6px);
}
.build-element-name {
  font-family: var(--font-display);
  font-size: clamp(2.4rem, 7vh, 5rem);
  line-height: .88;
  letter-spacing: .01em;
  color: var(--black);
}
.build-guiding {
  background: var(--white);
  border: 1px solid var(--border);
  border-left: 3px solid var(--black);
  padding: clamp(10px, 1.5vh, 14px) clamp(12px, 1.5vw, 16px);
  border-radius: 0 3px 3px 0;
  font-size: clamp(.78rem, 1.4vh, .9rem);
  color: var(--body);
  line-height: 1.55;
  flex-shrink: 0;
}
.build-textarea {
  flex: 1;
  width: 100%;
  min-height: clamp(80px, 15vh, 140px);
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: 4px;
  padding: clamp(10px, 1.5vh, 16px) clamp(12px, 1.5vw, 16px);
  font-family: var(--font-body);
  font-size: 16px;
  color: var(--black);
  line-height: 1.6;
  resize: none;
  outline: none;
  transition: border-color .2s, box-shadow .2s;
  -webkit-appearance: none;
}
.build-textarea:focus {
  border-color: var(--black);
  box-shadow: 0 0 0 3px rgba(17,17,17,.06);
}
.build-textarea::placeholder { color: #BBBBBB; font-weight: 300; }
.char-hint {
  font-family: var(--font-mono);
  font-size: clamp(.48rem, .9vh, .6rem);
  letter-spacing: .08em;
  color: var(--mid);
  text-align: right;
  flex-shrink: 0;
}

/* ═══════════════════════════════════════════════
   MINI MATRIX
═══════════════════════════════════════════════ */
.mini-matrix {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 3px;
  width: clamp(44px, 7vw, 60px);
  flex-shrink: 0;
}
.mini-cell {
  aspect-ratio: 1;
  border-radius: 2px;
  background: var(--dust);
  transition: background .3s;
}
.mini-cell.filled { background: var(--black); }
.mini-cell.core   { background: var(--black); }
.mini-cell.core-empty { background: rgba(17,17,17,.2); }

/* ═══════════════════════════════════════════════
   REVIEW SCREEN
═══════════════════════════════════════════════ */
.review-matrix-grid {
  display: grid;
  grid-template-columns: clamp(28px, 5vw, 44px) 1fr 1fr 1fr;
  grid-template-rows: 1fr 1fr 1fr;
}
.rml {
  display: flex;
  align-items: center;
  justify-content: center;
  writing-mode: vertical-rl;
  transform: rotate(180deg);
  font-family: var(--font-mono);
  font-size: clamp(.38rem, 1vw, .5rem);
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--mid);
  border-right: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  background: var(--dust);
  padding: 6px 3px;
}
.rml.rml-last { border-bottom: none; }
.rmc {
  border-right: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  min-height: clamp(60px, 12vw, 100px);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: clamp(6px, 1vh, 10px) clamp(6px, 1.2vw, 10px);
  background: var(--dust);
}
.rmc.rmc-last { border-bottom: none; }
.rmc.rmc-core { background: var(--black); }
.rmc-lbl {
  font-family: var(--font-mono);
  font-size: clamp(.36rem, .9vw, .5rem);
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--mid);
  flex-shrink: 0;
}
.rmc.rmc-core .rmc-lbl { color: rgba(255,255,255,.4); }
.rmc-val {
  font-size: clamp(.62rem, 1.3vw, .78rem);
  color: var(--body);
  line-height: 1.3;
  margin-top: 4px;
}
.rmc.rmc-core .rmc-val { color: rgba(255,255,255,.85); }
.rmc-val:empty { display: none; }

.review-layout {
  width: 100%;
  height: 100%;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  display: flex;
  flex-direction: column;
}
.review-header {
  flex-shrink: 0;
  padding: clamp(14px, 2.5vh, 24px) var(--px) clamp(8px, 1.5vh, 14px);
}
@media (orientation: landscape) {
  .review-layout .review-header { display: none; }
}
.review-send-btn {
  flex-shrink: 0;
  margin: 0;
  border-radius: 0;
}
#gaps-section {
  flex-shrink: 0;
  padding: clamp(4px, .8vh, 8px) var(--px);
}
#review-matrix-grid {
  flex-shrink: 0;
  border-radius: 0;
  border-left: none;
  border-right: none;
}
#review-matrix-grid .matrix-grid {
  display: grid;
  grid-template-columns: clamp(28px, 5vw, 44px) 1fr 1fr 1fr;
}
#review-matrix-grid .m-cell {
  min-height: clamp(80px, 16vw, 130px);
  height: auto;
  justify-content: flex-start;
  padding: clamp(6px, 1vh, 10px) clamp(8px, 1.2vw, 12px);
}
#review-matrix-grid .m-rl {
  min-height: clamp(80px, 16vw, 130px);
}
#review-matrix-grid .m-cell-lbl {
  padding: 0 0 clamp(4px, .6vh, 8px) 0;
}
#review-matrix-grid .m-cell-val {
  font-size: clamp(.68rem, 1.3vw, .82rem);
  color: var(--body);
  line-height: 1.35;
  border-top: none;
  padding: 0;
}
#review-matrix-grid .m-cell.core .m-cell-val {
  color: rgba(255,255,255,.85);
  border-top: none;
}

.review-next {
  flex-shrink: 0;
  display: flex;
  flex-direction: column;
  gap: clamp(12px, 2vh, 18px);
  padding-top: clamp(4px, 1vh, 10px);
  border-top: 1px solid var(--border);
}
.review-diagonals {
  display: flex;
  flex-direction: column;
  gap: clamp(8px, 1.4vh, 14px);
}
.review-diagonal-item {
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.review-diagonal-name {
  font-family: var(--font-mono);
  font-size: clamp(.5rem, 1vw, .62rem);
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--black);
}
.review-diagonal-els {
  font-size: clamp(.78rem, 1.4vh, .9rem);
  color: var(--mid);
  line-height: 1.4;
}
.review-cta-link {
  font-family: var(--font-mono);
  font-size: clamp(.6rem, 1.1vh, .72rem);
  color: var(--black);
  text-decoration: none;
  border-bottom: 1px solid var(--border);
  padding-bottom: 2px;
  width: fit-content;
  letter-spacing: .04em;
}
.review-cta-link:hover { border-color: var(--black); }

.review-entries {
  display: flex;
  flex-direction: column;
  border: 1px solid var(--border);
  border-radius: 0;
  overflow: hidden;
  flex-shrink: 0;
}
.review-entry {
  padding: clamp(12px, 2vh, 18px) clamp(14px, 2vw, 20px);
  border-bottom: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.review-entry:last-child { border-bottom: none; }
.review-entry.is-core { background: var(--black); }
.review-entry.is-empty { opacity: .45; }
.review-entry-label {
  font-family: var(--font-mono);
  font-size: clamp(.48rem, 1vw, .58rem);
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--mid);
}
.review-entry.is-core .review-entry-label { color: rgba(255,255,255,.4); }
.review-entry-value {
  font-size: clamp(.88rem, 1.6vh, 1rem);
  color: var(--black);
  line-height: 1.4;
}
.review-entry.is-core .review-entry-value { color: var(--white); }
.review-entry-empty {
  font-size: clamp(.8rem, 1.4vh, .9rem);
  color: var(--mid);
  font-style: italic;
}

/* Desktop review — 50/50 split */
@media (orientation: landscape) {
  #slide-review {
    display: grid !important;
    grid-template-columns: 1fr 1fr;
    align-items: stretch;
  }
  #slide-review .review-layout {
    display: contents;
  }
  .review-left {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    padding: var(--p) var(--px);
    border-right: 1px solid var(--border);
    overflow: hidden;
  }
  .review-right {
    display: flex;
    flex-direction: column;
    overflow: hidden;
    min-height: 0;
  }
  #slide-review #review-matrix-grid {
    flex: 1;
    min-height: 0;
    display: flex;
    flex-direction: column;
    border-radius: 0;
    border-left: none;
    border-right: none;
    border-top: none;
  }
  #slide-review #review-matrix-grid .matrix-grid {
    flex: 1;
    grid-template-rows: 1fr 1fr 1fr;
  }
  #slide-review #review-matrix-grid .m-cell,
  #slide-review #review-matrix-grid .m-rl {
    min-height: 0;
  }
  #slide-review #gaps-section {
    padding: clamp(4px,.8vh,8px) var(--px);
    flex-shrink: 0;
  }
  #slide-review .review-send-btn {
    flex-shrink: 0;
    margin: 0;
    border-radius: 0;
  }
}

/* Mobile: hide review-left, show review-right as stacked */
@media (orientation: portrait) {
  .review-left { display: none; }
  .review-layout { display: flex; flex-direction: column; }
  .review-header { order: -1; }
  .review-right {
    display: flex;
    flex-direction: column;
    overflow-y: auto;
    min-height: 0;
  }
}

/* Send modal */
.send-modal {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 500;
  background: rgba(0,0,0,.5);
  align-items: flex-end;
  justify-content: center;
  padding: 0;
}
.send-modal.open { display: flex; }
.send-modal-inner {
  background: var(--white);
  width: 100%;
  max-width: 560px;
  border-radius: 12px 12px 0 0;
  padding: clamp(20px, 4vh, 32px) var(--px);
  padding-bottom: max(clamp(20px, 4vh, 32px), env(safe-area-inset-bottom));
  display: flex;
  flex-direction: column;
  gap: 12px;
  max-height: 80dvh;
  overflow-y: auto;
}
@media (min-width: 600px) {
  .send-modal { align-items: center; padding: 20px; }
  .send-modal-inner { border-radius: 8px; max-height: 90dvh; }
}
.send-modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.send-modal-title {
  font-family: var(--font-display);
  font-size: clamp(1.4rem, 3vh, 2rem);
  letter-spacing: .02em;
}
.send-modal-close {
  background: none;
  border: none;
  font-size: 1rem;
  color: var(--mid);
  cursor: pointer;
  padding: 4px 8px;
  line-height: 1;
}
.send-modal-desc {
  font-size: clamp(.8rem, 1.4vh, .9rem);
  color: var(--body);
  line-height: 1.55;
}

.review-title {
  font-family: var(--font-display);
  font-size: clamp(1.4rem, 4vh, 2.2rem);
  color: var(--black);
  letter-spacing: .02em;
  line-height: 1;
  margin-bottom: clamp(3px, .5vh, 6px);
}
.review-sub {
  font-family: var(--font-mono);
  font-size: clamp(.5rem, .9vh, .62rem);
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--mid);
  margin-bottom: clamp(10px, 2vh, 16px);
}

.send-section {
  border: 1px solid var(--border);
  border-radius: 4px;
  padding: clamp(12px, 2vh, 18px) clamp(14px, 2vw, 20px);
  background: var(--off);
}
.send-section-label {
  font-family: var(--font-mono);
  font-size: clamp(.55rem, 1vh, .65rem);
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--body);
  margin-bottom: clamp(4px, .8vh, 8px);
}
.send-section-desc {
  font-size: clamp(.75rem, 1.4vh, .88rem);
  color: var(--mid);
  line-height: 1.55;
  margin-bottom: clamp(10px, 1.8vh, 14px);
}
.email-input {
  width: 100%;
  padding: clamp(9px, 1.5vh, 13px) clamp(12px, 1.5vw, 14px);
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: 3px;
  font-family: var(--font-body);
  font-size: 16px;
  color: var(--black);
  outline: none;
  transition: border-color .2s;
  -webkit-appearance: none;
}
.email-input:focus { border-color: var(--black); }
.email-input::placeholder { color: #BBBBBB; }
.optin-row {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: clamp(9px, 1.5vh, 13px) clamp(12px, 1.5vw, 14px);
  background: var(--off);
  border: 1px solid var(--border);
  border-radius: 3px;
  cursor: pointer;
}
.optin-row input[type=checkbox] {
  width: 15px; height: 15px;
  flex-shrink: 0; margin-top: 2px;
  accent-color: var(--black);
}
.optin-text {
  font-size: clamp(.72rem, 1.3vh, .82rem);
  color: var(--body);
  line-height: 1.5;
}

.cta-block {
  border: 1px solid var(--border);
  border-radius: 4px;
  padding: clamp(14px, 2.5vh, 22px) clamp(14px, 2vw, 20px);
  background: var(--black);
  margin-top: auto;
}
.cta-head {
  font-family: var(--font-display);
  font-size: clamp(1.4rem, 3.5vh, 2.2rem);
  color: var(--white);
  letter-spacing: .02em;
  margin-bottom: clamp(6px, 1vh, 10px);
  line-height: 1;
}
.cta-body {
  font-size: clamp(.75rem, 1.4vh, .88rem);
  color: rgba(255,255,255,.55);
  line-height: 1.6;
  margin-bottom: clamp(12px, 2vh, 16px);
}
.cta-link {
  display: block;
  font-family: var(--font-mono);
  font-size: clamp(.68rem, 1.2vh, .8rem);
  font-weight: 500;
  color: var(--white);
  text-decoration: none;
  border-bottom: 1px solid rgba(255,255,255,.3);
  padding-bottom: 2px;
  margin-bottom: clamp(6px, 1vh, 10px);
  width: fit-content;
}
.cta-link:hover { border-bottom-color: var(--white); }
.cta-link-secondary {
  display: block;
  font-family: var(--font-mono);
  font-size: clamp(.6rem, 1vh, .7rem);
  color: rgba(255,255,255,.38);
  text-decoration: none;
  letter-spacing: .06em;
  width: fit-content;
}
.cta-link-secondary:hover { color: rgba(255,255,255,.75); }

.gaps-list {
  display: flex;
  flex-direction: column;
  gap: 4px;
  margin-bottom: clamp(8px, 1.5vh, 12px);
}
.gap-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: clamp(7px, 1.2vh, 10px) clamp(10px, 1.5vw, 14px);
  background: var(--off);
  border: 1px solid var(--border);
  border-radius: 3px;
  cursor: pointer;
  transition: border-color .15s;
}
.gap-item:hover { border-color: var(--black); }
.gap-dot { width: 5px; height: 5px; border-radius: 50%; background: var(--mid); flex-shrink: 0; }
.gap-name { font-family: var(--font-mono); font-size: clamp(.52rem, .9vh, .62rem); letter-spacing: .1em; text-transform: uppercase; color: var(--body); flex: 1; }
.gap-action { font-family: var(--font-mono); font-size: clamp(.5rem, .85vh, .6rem); letter-spacing: .08em; color: var(--mid); }

/* ═══════════════════════════════════════════════
   UTILITY
═══════════════════════════════════════════════ */
.btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: clamp(11px, 1.8vh, 15px) 20px;
  border-radius: 4px;
  border: none;
  cursor: pointer;
  font-family: var(--font-mono);
  font-size: clamp(.62rem, 1.2vh, .72rem);
  letter-spacing: .12em;
  text-transform: uppercase;
  transition: opacity .15s, transform .1s;
  -webkit-appearance: none;
  min-height: 44px;
}
.btn:active { transform: scale(.98); }
.btn-primary { background: var(--black); color: var(--white); }
.btn-primary:hover { background: #2c2c2c; }
.btn-outline { background: var(--white); color: var(--black); border: 1.5px solid var(--border); }
.btn-outline:hover { border-color: var(--black); }
.btn-full { width: 100%; }

.section-divider { display: flex; align-items: center; gap: 12px; }
.section-divider-line { flex: 1; height: 1px; background: var(--border); }
.slide-dark .section-divider-line { background: rgba(255,255,255,.12); }
.section-divider-label { font-family: var(--font-mono); font-size: .58rem; letter-spacing: .14em; text-transform: uppercase; color: var(--mid); white-space: nowrap; }

/* ── MATRIX HIGHLIGHT STATES ── */
.m-cell.active { background: var(--black) !important; }
.m-cell.active .m-cell-lbl { color: rgba(255,255,255,.45) !important; }
.m-cell.diag { background: #444 !important; }
.m-cell.diag .m-cell-lbl { color: rgba(255,255,255,.35) !important; }
.m-cell.dimmed { background: var(--off) !important; opacity: .3; }
.m-cell.dimmed .m-cell-lbl { color: var(--mid) !important; }
.m-rl.dimmed { opacity: .25; }

.context-matrix {
  flex-shrink: 0;
  width: 40px;
}
.context-matrix .matrix-wrap { margin-top: 0; border-radius: 0; }
.context-matrix .matrix-grid { grid-template-columns: 1fr 1fr 1fr; }
.context-matrix .m-cell { min-height: 12px; }
.context-matrix .m-cell-lbl { display: none; }
.context-matrix .m-rl { display: none; }

@media (orientation: landscape) {
  .context-matrix { width: 56px; }
  .context-matrix .m-cell { min-height: 16px; }
}

.diag-item-matrix {
  flex-shrink: 0;
  width: clamp(18px, 4vw, 24px);
  height: clamp(18px, 4vw, 24px);
  display: flex;
  align-items: flex-start;
  padding-top: 0;
}
.diag-item-matrix .matrix-wrap {
  flex: 1;
  margin: 0;
  background: transparent;
  border: 1px solid var(--border);
  border-radius: 0;
}
.diag-item-matrix .matrix-grid { grid-template-columns: 1fr 1fr 1fr; }
.diag-item-matrix .m-cell {
  min-height: 0;
  aspect-ratio: 1;
  background: transparent;
  border-color: var(--border);
}
.diag-item-matrix .m-cell.active { background: var(--black) !important; border-color: var(--border) !important; }
.diag-item-matrix .m-cell.dimmed { background: transparent !important; border-color: var(--border) !important; opacity: 1; }
.diag-item-matrix .m-cell-lbl { display: none; }
.diag-item-matrix .m-rl { display: none; }
@media (orientation: landscape) {
  .diag-item-matrix { width: clamp(24px, 3vw, 36px); height: clamp(24px, 3vw, 36px); padding-top: 0; }
}

/* ── MOBILE: cover + gate sl fills full height ── */
@media (orientation: portrait) {
  .slide-cover,
  .slide[data-section="gate"] {
    display: flex;
    flex-direction: column;
  }
  .slide-cover > .sl,
  .slide[data-section="gate"] > .sl {
    flex: 1;
    min-height: 0;
    justify-content: space-between;
    padding-bottom: clamp(12px, 2.5vh, 24px);
  }
  .slide-cover > .sr,
  .slide[data-section="gate"] > .sr {
    display: none;
  }

  /* Matrix slide — mobile layout */
  .slide-matrix-fullbleed {
    display: flex;
    flex-direction: column;
  }
  .slide-matrix-fullbleed > .sl {
    flex: 0 0 auto;
    padding: 0;
    overflow: visible;
  }
  .slide-matrix-fullbleed > .sl .s-eyebrow {
    padding: clamp(12px, 2.5vh, 28px) var(--px) 0;
  }
  .slide-matrix-fullbleed > .sl .s-display {
    font-size: min(clamp(2.4rem, 14.5cqw, 6.5rem), 24cqw) !important;
    line-height: .88 !important;
    padding: 0 var(--px);
    width: 100%;
    box-sizing: border-box;
  }
  .slide-matrix-fullbleed > .sl .s-body {
    padding: 0 var(--px);
  }
  .slide-matrix-fullbleed > .sl .s-rule {
    margin: 0 var(--px);
  }
  .slide-matrix-fullbleed > .sr {
    flex: 1;
    min-height: 0;
    padding-left: var(--px);
    padding-right: var(--px);
    overflow: hidden;
    display: flex;
    flex-direction: column;
    gap: clamp(10px, 1.5vh, 16px);
  }
  .slide-matrix-fullbleed > .sr .matrix-fill {
    flex: 0 0 auto;
    max-height: 42dvh;
  }
  .slide-matrix-fullbleed .mobile-layer-summary {
    display: flex;
    flex-direction: column;
    gap: clamp(6px, 1vh, 10px);
    flex-shrink: 0;
  }
  .slide-matrix-fullbleed .mobile-layer-summary-item {
    display: flex;
    flex-direction: column;
    gap: 1px;
  }
  .slide-matrix-fullbleed .mobile-layer-name {
    font-family: var(--font-mono);
    font-size: clamp(.5rem, 1.1vw, .62rem);
    letter-spacing: .14em;
    text-transform: uppercase;
    color: var(--black);
  }
  .slide-matrix-fullbleed .mobile-layer-desc {
    font-size: clamp(.75rem, 1.4vw, .88rem);
    color: var(--mid);
    line-height: 1.4;
  }
  .slide-matrix-fullbleed > .sr .matrix-wrap {
    border-radius: 0;
    border: none;
    border-top: 1px solid var(--border);
  }
  .slide-matrix-fullbleed > .sl .layer-summary { display: none; }
  .slide-matrix-fullbleed > .sl .s-footnote-desktop { display: none; }
  .slide-matrix-fullbleed > .sr .matrix-fill {
    flex: 1;
    display: flex;
    flex-direction: column;
  }
}

/* ═══════════════════════════════════════════════
   TOAST
═══════════════════════════════════════════════ */
.toast {
  position: fixed;
  bottom: 80px;
  left: 50%;
  transform: translateX(-50%) translateY(20px);
  background: var(--black);
  color: var(--white);
  padding: 10px 20px;
  border-radius: 24px;
  font-family: var(--font-mono);
  font-size: .68rem;
  letter-spacing: .08em;
  opacity: 0;
  transition: opacity .25s, transform .25s;
  pointer-events: none;
  white-space: nowrap;
  z-index: 999;
}
.toast.show { opacity: 1; transform: translateX(-50%) translateY(0); }
