/* ========================================================
   MOON × LENSO — Manual de Configuración Rápida
   Built on the LENSO design system
   Responsive (mobile-friendly) + print-ready
   ======================================================== */

@import url("./assets/lenso.css");

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; overflow-x: hidden; }
body {
  background: var(--color-cream);
  color: var(--color-black);
  -webkit-font-smoothing: antialiased;
}

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

/* ---------- LAYOUT ---------- */
.shell {
  display: grid;
  grid-template-columns: 280px 1fr;
  min-height: 100vh;
  transition: grid-template-columns 280ms cubic-bezier(.4,0,.2,1);
}

/* ---------- MOBILE NAV TOGGLE ---------- */
.mobile-bar {
  display: none;
  position: sticky;
  top: 0;
  z-index: 50;
  background: var(--color-black);
  color: white;
  padding: 14px 20px;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  border-bottom: 1px solid rgba(255,255,255,0.1);
}
.mobile-bar__brand {
  display: flex; align-items: center; gap: 10px;
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 11px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}
.mobile-bar__brand img { height: 18px; width: auto; }
.mobile-bar__brand .x { opacity: 0.5; }
.mobile-bar__toggle {
  background: white;
  color: black;
  border: 0;
  padding: 8px 14px;
  border-radius: 6px;
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 11px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  cursor: pointer;
}

/* ---------- SIDEBAR ---------- */
.sidebar {
  position: sticky;
  top: 0;
  align-self: start;
  height: 100vh;
  background: var(--color-black);
  color: var(--color-white);
  padding: 32px 28px;
  display: flex;
  flex-direction: column;
  gap: 32px;
  overflow-y: auto;
  overflow-x: hidden;
  transition: transform 280ms cubic-bezier(.4,0,.2,1), opacity 200ms ease;
}

.sidebar__brandlock {
  display: flex;
  flex-direction: column;
  gap: 18px;
  padding-bottom: 24px;
  border-bottom: 1px solid rgba(255,255,255,0.18);
}

.brand-row { display: flex; align-items: center; gap: 12px; }
.brand-row img { height: 25px; width: auto; }
.brand-row .x {
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 14px;
  letter-spacing: 0.05em;
  opacity: 0.5;
}

.sidebar__meta {
  font-size: 11px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  opacity: 0.5;
  font-weight: 600;
}

.sidebar__title {
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 22px;
  line-height: 1.15;
  letter-spacing: 0.02em;
  text-transform: uppercase;
  margin-top: 4px;
}
.sidebar__sub {
  font-size: 13px;
  line-height: 1.5;
  opacity: 0.65;
  margin-top: 8px;
}

.nav { display: flex; flex-direction: column; gap: 2px; margin-top: 4px; }
.nav__group {
  font-size: 10px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  opacity: 0.4;
  font-weight: 700;
  margin: 18px 0 6px;
}
.nav a {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 10px;
  border: 0;
  border-radius: 6px;
  font-family: var(--font-body);
  font-size: 13px;
  font-weight: 500;
  color: rgba(255,255,255,0.78);
  cursor: pointer;
  text-decoration: none;
  transition: background 140ms, color 140ms;
}
.nav a .num {
  font-family: var(--font-heading);
  font-size: 10px;
  letter-spacing: 0.05em;
  opacity: 0.45;
  width: 18px;
  display: inline-block;
}
.nav a:hover { background: rgba(255,255,255,0.06); color: white; opacity: 1; }
.nav a.is-active { background: white; color: black; }
.nav a.is-active .num { opacity: 0.6; }

.sidebar__footer {
  margin-top: auto;
  font-size: 11px;
  letter-spacing: 0.04em;
  opacity: 0.45;
  line-height: 1.5;
}

/* ---------- SIDEBAR COLLAPSE (desktop only) ---------- */
.sidebar__collapse {
  position: absolute;
  top: 14px;
  right: 14px;
  width: 28px;
  height: 28px;
  border: 1px solid rgba(255,255,255,0.2);
  background: transparent;
  color: rgba(255,255,255,0.7);
  border-radius: 4px;
  font-family: var(--font-heading);
  font-size: 14px;
  line-height: 1;
  cursor: pointer;
  display: none;
  align-items: center;
  justify-content: center;
  transition: background 140ms, color 140ms;
}
.sidebar__collapse:hover { background: rgba(255,255,255,0.08); color: white; }

.sidebar__expand {
  position: fixed;
  top: 18px;
  left: 18px;
  z-index: 60;
  width: 40px;
  height: 40px;
  border-radius: 6px;
  border: 1px solid rgba(0,0,0,0.12);
  background: var(--color-black);
  color: white;
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 14px;
  cursor: pointer;
  display: none;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 16px rgba(0,0,0,0.18);
  transition: transform 140ms;
}
.sidebar__expand:hover { transform: scale(1.05); }

@media (min-width: 981px) {
  .sidebar__collapse { display: flex; }
  body.sidebar-collapsed .shell { grid-template-columns: 0 1fr; }
  body.sidebar-collapsed .sidebar { transform: translateX(-100%); opacity: 0; pointer-events: none; }
  body.sidebar-collapsed .sidebar__expand { display: flex; }
  .sidebar__expand { transition: opacity 220ms ease, transform 220ms ease; opacity: 1; }
}

/* ---------- WAREHOUSE-ONLY (section 13) ---------- */
.is-warehouse { display: none !important; }
body.warehouse-mode section.is-warehouse { display: block !important; }
body.warehouse-mode a.is-warehouse { display: flex !important; }

/* ---------- LANG TOGGLE ---------- */
.lang-toggle {
  display: flex;
  gap: 4px;
  margin-top: 14px;
}
.lang-toggle a {
  flex: 1;
  text-align: center;
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 10px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  padding: 8px 10px;
  border-radius: 4px;
  color: rgba(255,255,255,0.6);
  text-decoration: none;
  border: 1px solid rgba(255,255,255,0.2);
  transition: background 140ms, color 140ms;
}
.lang-toggle a:hover { color: white; background: rgba(255,255,255,0.06); }
.lang-toggle a.is-active { background: white; color: black; border-color: white; }

.sidebar__actions {
  display: flex; gap: 8px;
  padding-top: 16px;
  border-top: 1px solid rgba(255,255,255,0.18);
}
.sidebar__actions button {
  flex: 1;
  background: white;
  color: black;
  border: 0;
  padding: 10px 12px;
  border-radius: 6px;
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 10px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  cursor: pointer;
}
.sidebar__actions button.secondary {
  background: transparent;
  color: white;
  border: 1px solid rgba(255,255,255,0.3);
}

/* ---------- MAIN CONTENT ---------- */
.main { padding: 0; min-width: 0; }

section.band {
  padding: 96px 88px;
  border-top: 1px solid var(--color-lavender);
}
section.band:first-child { border-top: 0; }
section.band--cream { background: var(--color-cream); }
section.band--white { background: var(--color-white); }
section.band--black {
  background: var(--color-black);
  color: var(--color-white);
}
section.band--black h2,
section.band--black h3 { color: var(--color-white); }
section.band--black .lead { color: rgba(255,255,255,0.7); }
section.band--black .eyebrow { color: rgba(255,255,255,0.6); }

.eyebrow {
  font-size: 11px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  font-weight: 700;
  color: var(--color-espresso);
  margin-bottom: 18px;
  display: flex;
  align-items: center;
  gap: 14px;
}
.eyebrow::after {
  content: "";
  flex: 0 0 56px;
  height: 1px;
  background: currentColor;
  opacity: 0.4;
}

.section-h {
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: clamp(34px, 4.5vw, 56px);
  line-height: 1.05;
  letter-spacing: 0.01em;
  text-transform: uppercase;
  margin: 0 0 24px;
  max-width: 900px;
  text-wrap: balance;
}

.lead {
  font-size: clamp(15px, 1.5vw, 18px);
  line-height: 1.55;
  color: var(--color-ink-60);
  max-width: 720px;
  margin-bottom: 48px;
}

/* ---------- HERO ---------- */
.hero {
  background: var(--color-cream);
  padding: 88px 88px 96px;
  border-bottom: 1px solid var(--color-lavender);
}
.hero__top {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 40px;
  margin-bottom: 64px;
  flex-wrap: wrap;
}
.hero__crest {
  display: flex;
  align-items: center;
  gap: 18px;
  padding: 14px 22px;
  background: black;
  color: white;
  border-radius: 999px;
}
.hero__crest img { height: 17px; width: auto; }
.hero__crest .x {
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 11px;
  letter-spacing: 0.22em;
  opacity: 0.5;
}
.hero__crest .label {
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 11px;
  letter-spacing: 0.22em;
}

.hero__meta {
  text-align: right;
  font-size: 11px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  font-weight: 600;
  color: var(--color-ink-60);
  line-height: 1.8;
}
.hero__meta strong { color: black; font-weight: 700; }

.hero__title {
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: clamp(40px, 6.2vw, 96px);
  line-height: 0.92;
  letter-spacing: 0.005em;
  text-transform: uppercase;
  margin: 0;
  text-wrap: balance;
  word-break: break-word;
  hyphens: auto;
}
.hero__title .accent { color: var(--color-espresso); }

.hero__sub {
  font-size: clamp(15px, 1.5vw, 19px);
  line-height: 1.55;
  color: var(--color-ink-60);
  max-width: 640px;
  margin: 32px 0 0;
}

.hero__quote {
  margin-top: 48px;
  padding: 24px 32px;
  border-left: 2px solid black;
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 14px;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  line-height: 1.5;
  max-width: 720px;
}

/* ---------- DIAGRAM ---------- */
.diagram {
  background: var(--color-cream);
  border: 1px solid var(--color-lavender);
  border-radius: 10px;
  padding: 56px;
  position: relative;
}
.diagram svg { width: 100% !important; height: auto !important; max-width: 100%; display: block; }

/* Editable in-SVG labels (foreignObject) */
.svg-label {
  width: 100%;
  height: 100%;
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  font-family: var(--font-body);
  color: var(--color-ink);
  pointer-events: auto;
}
.svg-label--block h6 {
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 22px;
  letter-spacing: 0.02em;
  margin: 0 0 4px;
  line-height: 1.05;
  text-transform: none;
}
.svg-label--block p {
  font-size: 11px;
  color: var(--color-ink-60);
  margin: 0;
  line-height: 1.3;
}
.svg-label--inv h6 { color: #fff; }
.svg-label--inv p { color: rgba(255,255,255,0.6); }
.svg-label--inv span { color: #fff; }
.svg-label--mini {
  font-family: var(--font-body);
  font-size: 9px;
  letter-spacing: 0.04em;
  color: var(--color-ink-60);
  display: flex;
  align-items: center;
}
.svg-label--mini span { display: inline-block; }
.svg-label--group {
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 16px;
  letter-spacing: 0.06em;
  color: var(--color-ink);
}
.svg-label--motor {
  font-family: var(--font-body);
  font-size: 9px;
  letter-spacing: 0.08em;
  color: var(--color-ink);
  text-align: center;
  display: flex;
  align-items: flex-start;
  justify-content: center;
}

/* Pin badges */
.svg-pin {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 12px;
  color: #000;
  letter-spacing: 0;
}
.svg-pin--inv { color: #fff; }

.diagram__legend {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
  margin-top: 40px;
  padding-top: 32px;
  border-top: 1px solid var(--color-lavender);
}
.legend-item .pin {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 24px;
  height: 24px;
  padding: 0 8px;
  border: 1.5px solid black;
  border-radius: 999px;
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 11px;
  margin-bottom: 10px;
}
.legend-item h5 {
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 13px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  margin: 0 0 6px;
}
.legend-item p {
  font-size: 13px;
  line-height: 1.5;
  color: var(--color-ink-60);
  margin: 0;
}

/* ---------- STEP CARDS ---------- */
.steps {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0;
  border-top: 1px solid var(--color-lavender);
}
.step {
  display: grid;
  grid-template-columns: 90px 1fr 320px;
  gap: 48px;
  padding: 56px 0;
  border-bottom: 1px solid var(--color-lavender);
  align-items: start;
}
.step__num {
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 64px;
  line-height: 0.9;
  letter-spacing: -0.02em;
  color: var(--color-espresso);
}
.step__body h3 {
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: clamp(20px, 2vw, 24px);
  letter-spacing: 0.02em;
  text-transform: uppercase;
  margin: 4px 0 12px;
}
.step__body p {
  font-size: 15px;
  line-height: 1.6;
  color: var(--color-ink-60);
  margin: 0 0 12px;
  max-width: 560px;
}
.step__body ul {
  font-size: 14px;
  line-height: 1.7;
  color: var(--color-ink-60);
  margin: 12px 0 0;
  padding-left: 18px;
  max-width: 560px;
}
.step__body li::marker { color: var(--color-espresso); }
.step__body code {
  font-family: var(--font-mono);
  background: var(--color-cream);
  padding: 1px 6px;
  border-radius: 4px;
  font-size: 12.5px;
  color: black;
}

/* ---------- SCREENSHOT (illustrated UI) ---------- */
.screen {
  background: #fff;
  border: 1px solid var(--color-lavender);
  border-radius: 10px;
  overflow: hidden;
}
.screen__caption {
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 10px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--color-ink-60);
  padding: 12px 16px;
  border-top: 1px solid var(--color-lavender);
  background: var(--color-cream);
  display: flex;
  justify-content: space-between;
  gap: 12px;
}
.screen__caption .ruta { color: var(--color-espresso); }
.screen svg { width: 100%; display: block; background: #0E0E10; }
.screen img {
  width: 100%;
  display: block;
  background: #0E0E10;
  border-bottom: 1px solid var(--color-lavender);
}
.screen img:last-of-type { border-bottom: none; }
.screen img + img { border-top: 1px solid var(--color-lavender); }

/* ---------- SETTINGS GRID ---------- */
.grid-2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
}
.grid-3 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

.spec-card {
  background: var(--color-white);
  border: 1px solid var(--color-lavender);
  border-radius: 10px;
  padding: 28px;
}
section.band--black .spec-card {
  background: rgba(255,255,255,0.04);
  border-color: rgba(255,255,255,0.14);
}
.spec-card h4 {
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 14px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  margin: 0 0 6px;
}
.spec-card .key {
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 36px;
  letter-spacing: -0.01em;
  margin: 12px 0 6px;
  line-height: 1;
}
.spec-card .key small {
  font-size: 16px;
  font-weight: 700;
  margin-left: 4px;
  color: var(--color-ink-60);
}
section.band--black .spec-card .key small { color: rgba(255,255,255,0.6); }
.spec-card p {
  font-size: 13px;
  line-height: 1.55;
  color: var(--color-ink-60);
  margin: 0;
}
section.band--black .spec-card p { color: rgba(255,255,255,0.65); }
.spec-card .divider {
  height: 1px;
  background: var(--color-lavender);
  margin: 14px 0;
}
section.band--black .spec-card .divider { background: rgba(255,255,255,0.14); }

/* ---------- TROUBLESHOOT TABLE ---------- */
.tbl {
  width: 100%;
  border-collapse: collapse;
  font-size: 14px;
}
.tbl thead th {
  text-align: left;
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 11px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  padding: 14px 16px;
  border-bottom: 1px solid var(--color-lavender);
  color: var(--color-ink-60);
}
.tbl tbody td {
  padding: 18px 16px;
  border-bottom: 1px solid var(--color-lavender);
  vertical-align: top;
  line-height: 1.55;
}
.tbl tbody tr:hover td { background: var(--color-cream); }
.tbl .symptom {
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 13px;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  width: 28%;
}
.tbl .cause { color: var(--color-ink-60); width: 32%; }
.tbl .fix { color: var(--color-black); }
.tbl .fix code {
  font-family: var(--font-mono);
  background: var(--color-cream);
  padding: 1px 6px;
  border-radius: 4px;
  font-size: 12px;
}

/* ---------- MODE CARDS ---------- */
.mode-card {
  background: var(--color-white);
  border: 1px solid var(--color-lavender);
  border-radius: 10px;
  overflow: hidden;
}
.mode-card__top {
  background: var(--color-black);
  color: white;
  padding: 0;
  position: relative;
  aspect-ratio: 16/9;
  display: block;
  overflow: hidden;
}
.mode-card__top svg { position: absolute; inset: 0; width: 100%; height: 100%; }
.mode-card__top::after {
  content: "";
  position: absolute;
  left: 0; right: 0; bottom: 0;
  height: 60%;
  background: linear-gradient(180deg, rgba(0,0,0,0) 0%, rgba(0,0,0,0.85) 78%, rgba(0,0,0,0.95) 100%);
  pointer-events: none;
}
.mode-card__top h4 {
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 20px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  margin: 0;
  position: absolute;
  left: 24px;
  right: 24px;
  bottom: 24px;
  z-index: 1;
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 10px;
  line-height: 1.1;
}
.mode-card__top h4 .reco-tag {
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 9px;
  letter-spacing: 0.16em;
  padding: 4px 8px;
  border: 1px solid rgba(255,255,255,0.4);
  border-radius: 999px;
  background: rgba(255,255,255,0.08);
  margin-left: 0;
  opacity: 1;
  white-space: nowrap;
}
.mode-card__body { padding: 22px 24px 26px; }
.mode-card__body p {
  font-size: 14px;
  line-height: 1.55;
  color: var(--color-ink-60);
  margin: 0 0 14px;
}
.mode-card__body .tag {
  display: inline-block;
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 10px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  padding: 4px 8px;
  border: 1px solid var(--color-black);
  border-radius: 4px;
  color: var(--color-black);
}
.mode-card__body .tag--accent { background: var(--color-black); color: white; }

/* ---------- CHECKLIST ---------- */
.checklist {
  display: grid;
  gap: 0;
  border-top: 1px solid var(--color-lavender);
}
.checklist__row {
  display: grid;
  grid-template-columns: 32px 1fr 220px;
  gap: 24px;
  padding: 20px 0;
  border-bottom: 1px solid var(--color-lavender);
  align-items: start;
  cursor: pointer;
  user-select: none;
}
.checklist__box {
  width: 22px;
  height: 22px;
  border: 1.5px solid black;
  border-radius: 4px;
  margin-top: 2px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: white;
  transition: background 140ms;
}
.checklist__box svg {
  width: 14px;
  height: 14px;
  opacity: 0;
  transition: opacity 140ms;
  color: white;
}
.checklist__row.is-done .checklist__box { background: black; }
.checklist__row.is-done .checklist__box svg { opacity: 1; }
.checklist__row.is-done .checklist__txt { opacity: 0.4; text-decoration: line-through; }

.checklist__txt h5 {
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 14px;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  margin: 0 0 4px;
}
.checklist__txt p {
  font-size: 13px;
  line-height: 1.5;
  color: var(--color-ink-60);
  margin: 0;
}
.checklist__where {
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--color-ink-60);
  background: var(--color-cream);
  padding: 6px 10px;
  border-radius: 4px;
  text-align: center;
  margin-top: 2px;
}

/* ---------- CALLOUT ---------- */
.callout {
  display: flex;
  gap: 20px;
  padding: 22px 24px;
  background: var(--color-cream);
  border-left: 3px solid var(--color-black);
  border-radius: 4px;
  margin: 24px 0;
}
.callout--warn { border-left-color: var(--color-espresso); }
.callout__icon {
  flex: 0 0 28px;
  width: 28px;
  height: 28px;
  border-radius: 999px;
  background: var(--color-black);
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 14px;
}
.callout--warn .callout__icon { background: var(--color-espresso); }
.callout__body h5 {
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 12px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  margin: 4px 0 6px;
}
.callout__body p {
  font-size: 14px;
  line-height: 1.55;
  color: var(--color-ink-60);
  margin: 0;
}
section.band--black .callout {
  background: rgba(255,255,255,0.04);
  border-left-color: white;
}
section.band--black .callout__body p { color: rgba(255,255,255,0.7); }

/* ---------- KEY VALUE ---------- */
.kv {
  display: grid;
  grid-template-columns: 200px 1fr;
  gap: 16px 24px;
  padding: 16px 0;
  border-bottom: 1px solid var(--color-lavender);
}
.kv:last-child { border-bottom: 0; }
.kv dt {
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 12px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}
.kv dd {
  margin: 0;
  font-size: 14px;
  line-height: 1.55;
  color: var(--color-ink-60);
}
.kv dd code {
  font-family: var(--font-mono);
  background: var(--color-cream);
  padding: 1px 6px;
  border-radius: 4px;
  font-size: 12.5px;
  color: black;
}

/* ---------- FOOTER ---------- */
.colophon {
  background: var(--color-black);
  color: white;
  padding: 64px 88px;
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 48px;
}
.colophon h6 {
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 11px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  margin: 0 0 14px;
  opacity: 0.5;
}
.colophon p {
  font-size: 13px;
  line-height: 1.65;
  margin: 0;
  color: rgba(255,255,255,0.75);
}
.colophon img { height: 20px; opacity: 0.85; }

/* ============================================================
   RESPONSIVE — tablet
   ============================================================ */
@media (max-width: 980px) {
  .shell { grid-template-columns: 1fr; }
  .mobile-bar { display: flex; }
  .sidebar {
    position: fixed;
    inset: 60px 0 0 0;
    height: calc(100vh - 60px);
    width: 100%;
    z-index: 40;
    transform: translateX(-100%);
    transition: transform 240ms cubic-bezier(.4,0,.2,1);
  }
  .sidebar.is-open { transform: translateX(0); }
  section.band, .hero, .colophon { padding: 56px 32px; }
  .step {
    grid-template-columns: 60px 1fr;
    gap: 24px;
    padding: 40px 0;
  }
  .step__aside,
  .step .screen { grid-column: 1 / -1; max-width: 480px; }
  .grid-2, .grid-3 { grid-template-columns: 1fr 1fr; }
  .diagram { padding: 32px; }
  .diagram__legend { grid-template-columns: 1fr 1fr; }
  .colophon { grid-template-columns: 1fr; gap: 32px; }
}

/* ============================================================
   RESPONSIVE — phone
   ============================================================ */
@media (max-width: 640px) {
  .hero { padding: 40px 20px 56px; }
  .hero__title { font-size: clamp(36px, 11vw, 64px) !important; word-break: break-word; }
  section.band, .colophon { padding: 48px 20px; }
  .grid-2, .grid-3 { grid-template-columns: 1fr; }
  .step {
    grid-template-columns: 56px 1fr;
    gap: 20px;
    padding: 32px 0;
  }
  .step__num { font-size: 36px; }
  .step__body h3 { font-size: clamp(16px, 4.5vw, 22px); word-break: break-word; }
  .section-h { word-break: break-word; }
  .hero__top { flex-direction: column; align-items: flex-start; }
  .hero__meta { text-align: left; }
  .diagram { padding: 20px; }
  .diagram__legend { grid-template-columns: 1fr; gap: 20px; padding-top: 24px; }
  .checklist__row {
    grid-template-columns: 28px 1fr;
    gap: 14px;
  }
  .checklist__where { grid-column: 2; margin-top: 0; justify-self: start; }

  /* horizontal-scroll table */
  .tbl-wrap { overflow-x: auto; -webkit-overflow-scrolling: touch; }
  .tbl { min-width: 720px; }

  .kv { grid-template-columns: 1fr; gap: 4px; padding: 12px 0; }
  .colophon { padding: 40px 20px; }
}

/* ---------- LIGHTBOX ---------- */
.lightbox {
  position: fixed;
  inset: 0;
  background: rgba(8, 8, 10, 0.92);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 9000;
  padding: 5vh 5vw;
  cursor: zoom-out;
}
.lightbox.is-open { display: flex; }
.lightbox__img {
  max-width: 100%;
  max-height: 100%;
  width: auto;
  height: auto;
  object-fit: contain;
  background: #0E0E10;
  border: 1px solid rgba(255,255,255,0.1);
  cursor: zoom-out;
  box-shadow: 0 30px 80px rgba(0,0,0,0.6);
}
.lightbox__close {
  position: absolute;
  top: 24px;
  right: 28px;
  width: 44px;
  height: 44px;
  border-radius: 999px;
  border: 1px solid rgba(255,255,255,0.25);
  background: rgba(255,255,255,0.05);
  color: #fff;
  font-size: 24px;
  line-height: 1;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-heading);
}
.lightbox__close:hover { background: rgba(255,255,255,0.15); }
.lightbox__prev,
.lightbox__next {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 56px;
  height: 56px;
  border-radius: 999px;
  border: 1px solid rgba(255,255,255,0.25);
  background: rgba(255,255,255,0.05);
  color: #fff;
  font-size: 28px;
  line-height: 1;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-heading);
  z-index: 1;
}
.lightbox__prev { left: 24px; }
.lightbox__next { right: 24px; }
.lightbox__prev:hover,
.lightbox__next:hover { background: rgba(255,255,255,0.15); }
.lightbox__prev:disabled,
.lightbox__next:disabled { opacity: 0; pointer-events: none; }
@media (max-width: 640px) {
  .lightbox__prev, .lightbox__next { width: 44px; height: 44px; font-size: 22px; }
  .lightbox__prev { left: 8px; }
  .lightbox__next { right: 8px; }
}

/* ============================================================
   PRINT — exportable PDF manual
   ============================================================ */
@media print {
  @page {
    size: A4;
    margin: 14mm 14mm 16mm 14mm;
  }

  html, body {
    background: #fff !important;
    color: #000 !important;
    font-size: 10.5pt;
  }

  .mobile-bar, .sidebar, .sidebar__actions, .lang-toggle, .sidebar__expand, .sidebar__collapse, .lightbox, #tweaks-root { display: none !important; }
  .shell { display: block; }
  .main { padding: 0; }

  /* Restart sections — each band on its own page */
  section.band, .hero {
    padding: 0 !important;
    margin: 0 0 18mm 0 !important;
    border: 0 !important;
    background: #fff !important;
    color: #000 !important;
    page-break-inside: avoid;
    break-inside: avoid;
  }
  section.band--black {
    background: #fff !important;
    color: #000 !important;
  }
  section.band--black h2,
  section.band--black h3,
  section.band--black h4,
  section.band--black .lead,
  section.band--black .eyebrow,
  section.band--black .spec-card p,
  section.band--black .kv dd { color: #000 !important; }

  section.band, .hero { page-break-after: always; }

  .hero__title { font-size: 44pt !important; }
  .hero__quote { color: #000 !important; }
  .hero__crest { background: #000 !important; color: #fff !important; }

  .section-h { font-size: 22pt !important; }
  .lead { font-size: 11pt !important; }

  .step { page-break-inside: avoid; padding: 8mm 0 !important; gap: 8mm; grid-template-columns: 24mm 1fr; }
  .step__aside { grid-column: 1 / -1; margin-top: 4mm; }
  .step__num { font-size: 36pt; }

  /* Step screenshots: span full width, centered, sized to page */
  .step .screen {
    grid-column: 1 / -1;
    margin: 5mm auto 0 !important;
    max-width: 150mm;
    page-break-inside: avoid;
    break-inside: avoid;
  }
  .step .screen img,
  .step .screen svg { width: 100% !important; height: auto !important; display: block; }

  .grid-2, .grid-3 { gap: 6mm; }
  .spec-card { background: #fff !important; border: 1px solid #ccc !important; padding: 5mm !important; page-break-inside: avoid; break-inside: avoid; }
  section.band--black .spec-card { background: #fff !important; border-color: #ccc !important; }

  /* Cards & figures: never split across pages */
  .mode-card,
  figure,
  .kv { page-break-inside: avoid; break-inside: avoid; }
  figure img { width: 100% !important; height: auto !important; }

  .diagram { padding: 5mm !important; background: #fff !important; page-break-inside: avoid; break-inside: avoid; }
  .diagram svg { width: 100% !important; height: auto !important; max-width: 100% !important; }
  .diagram__legend { page-break-inside: avoid; break-inside: avoid; }

  /* Tables */
  .tbl-wrap { overflow: visible; }
  .tbl { font-size: 9.5pt; }
  .tbl tbody td, .tbl thead th { padding: 3mm 4mm; }
  .tbl thead { display: table-header-group; }
  .tbl tbody tr { page-break-inside: avoid; }

  .checklist__row { padding: 3mm 0; gap: 4mm; grid-template-columns: 8mm 1fr 40mm; }
  .checklist__where { background: #f4f4f4 !important; }

  .callout {
    background: #f4f3ee !important;
    border-left-color: #000 !important;
    page-break-inside: avoid;
    break-inside: avoid;
  }
  .callout__icon { background: #000 !important; color: #fff !important; }
  .callout__body h5,
  .callout__body p { color: #000 !important; }
  .callout__body p strong { color: #000 !important; }
  section.band--black .callout {
    background: #f4f3ee !important;
    border-left-color: #000 !important;
  }
  section.band--black .callout__body h5,
  section.band--black .callout__body p,
  section.band--black .callout__body p strong { color: #000 !important; }

  .colophon {
    background: #fff !important;
    color: #000 !important;
    border-top: 2px solid #000;
    padding-top: 8mm !important;
    grid-template-columns: 1fr 1fr 1fr;
  }
  .colophon h6 { color: #000 !important; opacity: 1; }
  .colophon p { color: #000 !important; }

  .screen svg,
  .screen img { background: #0E0E10 !important; -webkit-print-color-adjust: exact; print-color-adjust: exact; }
  .mode-card__top { -webkit-print-color-adjust: exact; print-color-adjust: exact; background: #000 !important; color: #fff !important; }
  .mode-card__top h4 { color: #fff !important; }

  a { color: #000; }

  /* color preserve */
  * {
    -webkit-print-color-adjust: exact !important;
    print-color-adjust: exact !important;
  }
}
