/* Factibilidad Cisterna MASA (CINTER) — Hormitec. Estética migración Odoo 19 (Tesla-style) + tema claro/oscuro */
:root, [data-theme="dark"] {
  color-scheme: dark;
  --bg: #0a0a0a;
  --bg-elev: #111;
  --bg-card: #161616;
  --bg-card-alt: #1a1a1a;
  --text: #f5f5f5;
  --text-strong: #fff;
  --text-muted: rgba(245,245,245,.68);
  --text-soft: rgba(245,245,245,.86);
  --accent: #D2222A;
  --accent-soft: rgba(210,34,42,.14);
  --amber: #F5A524;
  --line: rgba(255,255,255,.12);
  --line-strong: rgba(255,255,255,.28);
  --nav-border: rgba(255,255,255,.35);
  --nav-solid: rgba(10,10,10,.94);
  --nav-grad: linear-gradient(to bottom, rgba(0,0,0,.55), transparent);
  --index-bg: rgba(10,10,10,.97);
  --hero-bg: radial-gradient(120% 80% at 50% 0%, #1c1c1c 0%, #0a0a0a 60%);
  --hero-veil: linear-gradient(to top, rgba(0,0,0,.6), transparent 55%);
  --fig-bg: radial-gradient(120% 120% at 50% 0%, #181818 0%, #0d0d0d 70%);
  --fig-bg-alt: radial-gradient(120% 120% at 50% 0%, #1b1b1b 0%, #101010 70%);
  --thead-bg: #1a1a1a;
  --td: rgba(245,245,245,.84);
  --row-hover: rgba(255,255,255,.025);
  --row-sub: rgba(255,255,255,.04);
  --win-bg: linear-gradient(180deg, rgba(210,34,42,.12), rgba(210,34,42,.02)), var(--bg-card);
  --logo-filter: none;
  --font: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, Helvetica, sans-serif;
  --nav-h: 56px;
  --measure: 1000px;
}
[data-theme="light"] {
  color-scheme: light;
  --bg: #F7F7F7;
  --bg-elev: #fff;
  --bg-card: #fff;
  --bg-card-alt: #f0f0f0;
  --text: #1a1a1a;
  --text-strong: #0a0a0a;
  --text-muted: rgba(26,26,26,.62);
  --text-soft: rgba(26,26,26,.88);
  --accent: #D2222A;
  --accent-soft: rgba(210,34,42,.10);
  --amber: #C47A00;
  --line: rgba(0,0,0,.10);
  --line-strong: rgba(0,0,0,.22);
  --nav-border: rgba(0,0,0,.22);
  --nav-solid: rgba(247,247,247,.94);
  --nav-grad: linear-gradient(to bottom, rgba(247,247,247,.85), transparent);
  --index-bg: rgba(255,255,255,.98);
  --hero-bg: radial-gradient(120% 80% at 50% 0%, #ffffff 0%, #F7F7F7 60%);
  --hero-veil: linear-gradient(to top, rgba(247,247,247,.85), transparent 55%);
  --fig-bg: radial-gradient(120% 120% at 50% 0%, #181818 0%, #0d0d0d 70%);
  --fig-bg-alt: radial-gradient(120% 120% at 50% 0%, #1b1b1b 0%, #101010 70%);
  --thead-bg: #efefef;
  --td: rgba(26,26,26,.84);
  --row-hover: rgba(0,0,0,.03);
  --row-sub: rgba(0,0,0,.04);
  --win-bg: linear-gradient(180deg, rgba(210,34,42,.08), rgba(210,34,42,.015)), var(--bg-card);
  --logo-filter: brightness(0);
}
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: calc(var(--nav-h) + env(safe-area-inset-top, 0px) + 1rem); -webkit-text-size-adjust: 100%; }
body {
  margin: 0; font-family: var(--font); font-weight: 400;
  color: var(--text); background: var(--bg);
  font-size: 17px; line-height: 1.7;
  -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility;
}
img { max-width: 100%; display: block; }
a { color: inherit; }
button { font: inherit; }
b, strong { color: var(--text-strong); font-weight: 600; }
.skip-link { position: absolute; left: -9999px; top: 0; background: #fff; color: #000; padding: .75rem 1rem; z-index: 1000; }
.skip-link:focus { left: 1rem; top: 1rem; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }

/* NAV */
.nav {
  position: fixed; inset: 0 0 auto 0;
  height: calc(var(--nav-h) + env(safe-area-inset-top, 0px));
  display: flex; align-items: center; justify-content: space-between;
  gap: .75rem;
  padding: env(safe-area-inset-top, 0px) 1rem 0;
  z-index: 50;
  background: var(--nav-grad);
  transition: background .25s ease, backdrop-filter .25s, border-color .25s;
  box-sizing: border-box;
}
.nav.is-solid, body.index-open .nav {
  background: var(--nav-solid); backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--line);
}
.nav-brand { display: flex; align-items: center; text-decoration: none; min-width: 0; flex: 1 1 auto; }
.nav-logo { height: 22px; width: auto; max-width: 100%; filter: var(--logo-filter); transition: filter .2s; }
.nav-actions { display: flex; gap: .4rem; align-items: center; flex: 0 0 auto; }
.nav-toggle, .theme-toggle {
  appearance: none; background: transparent; color: var(--text);
  border: 1px solid var(--nav-border); border-radius: 999px;
  padding: .4rem .9rem; font-size: .8125rem; font-weight: 500; letter-spacing: .02em; cursor: pointer;
  transition: border-color .2s, background .2s, color .2s;
  line-height: 1;
}
.theme-toggle {
  display: inline-flex; align-items: center; justify-content: center;
  gap: .35rem; padding: .4rem .85rem; flex-shrink: 0;
  background: var(--accent-soft); border-color: var(--accent); color: var(--text-strong);
  font-weight: 600;
}
.theme-toggle .theme-icons {
  position: relative; width: 1rem; height: 1rem; flex-shrink: 0;
}
.theme-toggle svg {
  position: absolute; inset: 0; width: 1rem; height: 1rem; display: block;
}
.theme-toggle .theme-label { line-height: 1; white-space: nowrap; }
.theme-toggle .icon-moon { opacity: 0; pointer-events: none; }
[data-theme="light"] .theme-toggle .icon-sun { opacity: 0; }
[data-theme="light"] .theme-toggle .icon-moon { opacity: 1; }
.nav-toggle:hover, .nav-toggle[aria-expanded="true"] {
  border-color: var(--accent); background: var(--accent); color: #fff;
}
.theme-toggle:hover { border-color: var(--accent); background: var(--accent); color: #fff; }
.theme-toggle:hover svg { stroke: #fff; }
@media (max-width: 520px) {
  .nav { padding-left: .75rem; padding-right: .75rem; }
  .nav-logo { height: 18px; }
  .theme-toggle { width: 2.4rem; height: 2.4rem; padding: 0; gap: 0; }
  .theme-toggle .theme-label { display: none; }
  .nav-toggle { padding: .4rem .8rem; font-size: .78rem; }
}
@media (min-width: 1100px) { .nav { padding-left: 2rem; padding-right: 2rem; } }

/* ÍNDICE (panel) */
.index { position: fixed; top: calc(var(--nav-h) + env(safe-area-inset-top, 0px)); right: 0; bottom: 0; left: 0; z-index: 49; background: var(--index-bg); overflow-y: auto; }
.index[hidden] { display: none; }
.index-inner { max-width: 680px; margin: 0 auto; padding: 2.5rem 1.5rem 4rem; }
body.index-open { overflow: hidden; }

/* LISTA DE SECCIONES */
.toc ol { list-style: none; margin: 0; padding: 0; }
.toc li { border-top: 1px solid var(--line); margin: 0; padding: 0; }
.toc li::before { display: none; }
.toc li:last-child { border-bottom: 1px solid var(--line); }
.toc a {
  display: flex; gap: 1.25rem; align-items: baseline; padding: 1rem 0;
  text-decoration: none; font-size: 1.05rem; font-weight: 500; line-height: 1.4;
  color: var(--text); opacity: .88; transition: opacity .2s, color .2s;
}
.toc a:hover { opacity: 1; color: var(--text-strong); }
.num { font-size: .8rem; font-weight: 500; letter-spacing: .12em; color: var(--accent); min-width: 2rem; font-variant-numeric: tabular-nums; }

/* HERO */
.hero {
  position: relative; min-height: 100vh; min-height: 100svh;
  display: flex; align-items: flex-end; justify-content: center;
  background: var(--hero-bg), var(--bg);
  overflow: hidden;
}
.hero-gradient { position: absolute; inset: 0; background: var(--hero-veil); }
.hero-content { position: relative; z-index: 2; text-align: center; padding: calc(var(--nav-h) + 3rem) 1.5rem 3rem; max-width: 56rem; }
.eyebrow { font-size: .75rem; font-weight: 500; letter-spacing: .18em; text-transform: uppercase; margin: 0 0 1rem; color: var(--text-muted); }
.hero h1 { font-size: clamp(2.3rem, 6.8vw, 4.5rem); font-weight: 600; letter-spacing: -.03em; line-height: 1.06; margin: 0; }
.hero-sub { font-size: clamp(1.05rem, 2.5vw, 1.3rem); font-weight: 300; margin: 1.25rem auto 0; max-width: 40rem; color: var(--text-muted); line-height: 1.5; }
.hero-sub .code { color: var(--text); }
.hero-tags { display: flex; flex-wrap: wrap; gap: .6rem; justify-content: center; margin: 1.75rem 0 0; }
.hero-tag { display: inline-block; margin: 0; font-size: .8125rem; padding: .4rem .95rem; border: 1px solid var(--nav-border); border-radius: 999px; letter-spacing: .04em; }
.hero-tag.acc { border-color: var(--accent); background: var(--accent-soft); }
.scroll-cue { display: flex; flex-direction: column; align-items: center; gap: .15rem; margin: 3.5rem auto 0; text-decoration: none; font-size: .75rem; letter-spacing: .12em; text-transform: uppercase; opacity: .75; }
.scroll-cue:hover { opacity: 1; }

/* PORTADA: CONTENIDO */
.toc-section { padding: 6rem 1.5rem; background: var(--bg-elev); }
.toc-inner { max-width: 680px; margin: 0 auto; }
.toc-section h2 { font-size: clamp(1.9rem, 5vw, 3rem); font-weight: 600; letter-spacing: -.025em; line-height: 1.12; margin: 0 0 2.5rem; }

/* CAPÍTULOS */
.chapter { padding: 0 1.5rem 6rem; background: var(--bg); }
.chapter.alt { background: var(--bg-elev); }
.chapter-head {
  min-height: 52vh; min-height: 52svh; max-width: 46rem; margin: 0 auto;
  display: flex; flex-direction: column; justify-content: center; text-align: center;
  padding: 6rem 0 3.5rem;
}
.chapter-head h2 { font-size: clamp(2.1rem, 6vw, 3.6rem); font-weight: 600; letter-spacing: -.03em; line-height: 1.08; margin: 0; }
.chapter-head .eyebrow { color: var(--accent); }
.lede { margin: 1.75rem auto 0; max-width: 38rem; font-size: clamp(1.05rem, 2.2vw, 1.25rem); font-weight: 300; line-height: 1.6; color: var(--text-muted); }

/* TEXTO */
.prose { max-width: var(--measure); margin: 0 auto; }
.prose > :first-child { margin-top: 0; }
.prose p { margin: 0 0 1.25rem; color: var(--text-soft); }
.prose h3 {
  font-size: clamp(1.35rem, 3.4vw, 1.75rem); font-weight: 600; letter-spacing: -.02em;
  line-height: 1.2; margin: 4rem 0 1.25rem; padding-top: 2.25rem; border-top: 1px solid var(--line);
}
.prose .two h3, .prose .verdict h3 { margin-top: 0; padding-top: 0; border-top: 0; font-size: 1.2rem; }
.prose h4 { font-size: 1.05rem; font-weight: 600; letter-spacing: -.01em; line-height: 1.35; margin: 0 0 .6rem; }
.prose ul { list-style: none; margin: 0 0 1.75rem; padding: 0; }
.prose ul li { position: relative; padding-left: 1.4rem; margin: 0 0 .9rem; color: var(--text-soft); }
.prose ul li::before { content: ""; position: absolute; left: 0; top: .72em; width: 6px; height: 6px; border-radius: 50%; background: var(--accent); }
.prose ol { list-style: none; margin: 0 0 1.75rem; padding: 0; counter-reset: o; }
.prose ol li { counter-increment: o; position: relative; padding-left: 2.1rem; margin: 0 0 .8rem; color: var(--text-soft); }
.prose ol li::before { content: counter(o, decimal-leading-zero); position: absolute; left: 0; top: .18em; font-size: .78rem; font-weight: 500; letter-spacing: .1em; color: var(--accent); font-variant-numeric: tabular-nums; }
.note { font-size: .9rem; color: var(--text-muted) !important; line-height: 1.6; }
.note b { color: var(--text); }
code, .code { font-family: inherit; font-weight: 600; color: var(--text-strong); white-space: nowrap; }
i { color: var(--text-muted); }

/* GRIDS */
.two { display: grid; grid-template-columns: 1fr 1fr; gap: 2.5rem; margin: 2rem 0; align-items: start; }
.verdict { display: grid; grid-template-columns: 1.25fr 1fr; gap: 2.5rem; align-items: start; }

/* BADGE / TAG */
.badge {
  display: inline-flex; align-items: center; gap: .55rem; padding: .4rem .95rem;
  border: 1px solid var(--amber); color: var(--amber); border-radius: 999px;
  font-size: .78rem; font-weight: 600; letter-spacing: .12em; text-transform: uppercase;
  background: rgba(245,165,36,.08);
}
.badge::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: var(--amber); box-shadow: 0 0 10px var(--amber); }
.tag {
  display: inline-block; vertical-align: middle; font-size: .68rem; font-weight: 600; padding: .12rem .6rem;
  border: 1px solid var(--line-strong); border-radius: 999px; text-transform: uppercase; letter-spacing: .1em;
  white-space: nowrap; color: var(--text-muted); margin-left: .35rem;
}
.tag.red { border-color: var(--accent); color: #fff; background: var(--accent); }

/* BOXES */
.box {
  background: var(--bg-card); border: 1px solid var(--line); border-left: 3px solid var(--accent);
  border-radius: 12px; padding: 1.25rem 1.4rem; color: var(--text-soft);
}
.chapter.alt .box { background: var(--bg-card-alt); }
.box > b:first-child { display: block; font-size: .72rem; font-weight: 600; letter-spacing: .14em; text-transform: uppercase; color: var(--accent); margin-bottom: .35rem; }
.box ol, .box ul { margin-bottom: 0 !important; }
.box ol li, .box ul li { font-size: .95rem; }
.box.plain { border-left: 1px solid var(--line); }

/* KPIs */
.kpis { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1px; margin: 3rem 0 1rem; background: var(--line); border: 1px solid var(--line); border-radius: 12px; overflow: hidden; }
.kpi { background: var(--bg); padding: 1.4rem 1.25rem 1.25rem; position: relative; }
.chapter.alt .kpi { background: var(--bg-elev); }
.kpi .v { font-size: clamp(1.4rem, 2.6vw, 1.95rem); font-weight: 600; letter-spacing: -.02em; line-height: 1.1; color: var(--text-strong); font-variant-numeric: tabular-nums; }
.kpi .v small { font-size: .85rem; font-weight: 400; color: var(--text-muted); letter-spacing: 0; }
.kpi .l { font-size: .7rem; font-weight: 500; color: var(--text-muted); text-transform: uppercase; letter-spacing: .12em; margin-top: .55rem; line-height: 1.4; }
.kpi.acc::before { content: ""; position: absolute; left: 0; right: 0; top: 0; height: 2px; background: var(--accent); }
.kpi.acc .v { color: var(--text-strong); }

/* OPCIONES (cards) */
.opt { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1rem; margin: 1.75rem 0 2rem; }
.opt .box { border-left: 1px solid var(--line); padding: 1.4rem; }
.opt .box.win { border-color: var(--accent); background: var(--win-bg); }
.opt h4 { margin: 0 0 .7rem; font-size: 1rem; color: var(--text-strong); }
.opt p { font-size: .92rem; margin: 0 !important; line-height: 1.6; color: var(--text-muted) !important; }
.opt .win p { color: var(--text-soft) !important; }

/* TABLAS */
.table-wrap {
  margin: 1.75rem 0 2rem; overflow: auto; -webkit-overflow-scrolling: touch; overscroll-behavior-x: contain;
  border: 1px solid var(--line); border-radius: 12px; max-height: min(80vh, 720px); max-height: min(80svh, 720px); position: relative;
  background: var(--bg-card);
}
.table-wrap table { border-collapse: separate; border-spacing: 0; width: 100%; min-width: 560px; font-size: .88rem; line-height: 1.5; font-variant-numeric: tabular-nums; }
.table-wrap.wide table { min-width: 860px; }
th, td { text-align: left; vertical-align: top; padding: .8rem 1rem; border-bottom: 1px solid var(--line); }
thead th {
  font-size: .7rem; font-weight: 600; letter-spacing: .1em; text-transform: uppercase; color: var(--text-muted);
  background: var(--thead-bg); white-space: nowrap; position: sticky; top: 0; z-index: 2; box-shadow: inset 0 -1px 0 var(--line); border-bottom: 0;
}
td { color: var(--td); }
td b { color: var(--text-strong); }
td.r, th.r { text-align: right; white-space: nowrap; }
tbody tr:hover td { background: var(--row-hover); }
tbody tr:last-child td { border-bottom: 0; }
tfoot td { font-weight: 600; color: var(--text-strong); background: var(--accent-soft); border-top: 1px solid var(--accent); border-bottom: 0; }
tr.sub td { background: var(--row-sub); border-top: 1px solid var(--line-strong); }
tr.total td { background: var(--accent-soft); border-top: 1px solid var(--accent); color: var(--text-strong); font-size: .95rem; }
tr.total td.r b { font-size: 1.05rem; }
.amount { font-size: clamp(2.2rem, 6vw, 3.4rem); font-weight: 600; letter-spacing: -.03em; color: var(--text-strong); line-height: 1; }

/* FIGURAS SVG — fondo oscuro en ambos temas (SVGs con fills claros) */
.fig {
  margin: 1.5rem 0 2.25rem; padding: 1.25rem; border: 1px solid var(--line); border-radius: 12px;
  background: var(--fig-bg);
}
.fig svg { width: 100%; height: auto; display: block; background: transparent; }
.chapter.alt .fig { background: var(--fig-bg-alt); }

/* GALERÍA */
.gallery { display: grid; grid-template-columns: minmax(0,.75fr) minmax(0,1.6fr); gap: 0 1.5rem; align-items: start; }
.gallery .tall { grid-row: span 2; }
.gallery .tall img { max-height: 900px; object-fit: contain; }
figure { margin: 0 0 1.75rem; }
figure a { display: block; border: 1px solid var(--line); border-radius: 12px; overflow: hidden; background: #fff; transition: border-color .2s, transform .2s; }
figure a:hover { border-color: var(--accent); }
figure img { width: 100%; height: auto; display: block; }
figcaption { font-size: .88rem; color: var(--text-muted); margin-top: .75rem; line-height: 1.55; }
figcaption b { color: var(--text-strong); }

/* REVEAL */
[data-reveal] { opacity: 0; transform: translateY(24px); transition: opacity .8s ease, transform .8s ease; }
[data-reveal].is-visible { opacity: 1; transform: none; }
.no-js [data-reveal] { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  [data-reveal] { opacity: 1; transform: none; transition: none; }
}

/* PIE */
.foot { padding: 4rem 1.5rem calc(4rem + env(safe-area-inset-bottom, 0)); text-align: center; border-top: 1px solid var(--line); color: var(--text-muted); font-size: .875rem; background: var(--bg); }
.foot img { margin: 0 auto 1.25rem; height: 17px; width: auto; opacity: .85; filter: var(--logo-filter); }
.foot p { margin: 0 0 1rem; }
.foot .conf { font-size: .72rem; letter-spacing: .14em; text-transform: uppercase; color: var(--accent); }
.foot a { color: var(--text); text-decoration: none; border-bottom: 1px solid var(--line); }

/* RESPONSIVE */
@media (max-width: 820px) {
  .verdict, .two, .opt { grid-template-columns: 1fr; gap: 1.5rem; }
  .kpis { grid-template-columns: repeat(2, 1fr); }
  .gallery { grid-template-columns: 1fr; }
  .gallery .tall { grid-row: auto; }
  .fig { padding: .75rem; }
}
@media (max-width: 480px) {
  body { font-size: 16px; }
  .chapter { padding: 0 1rem 4.5rem; }
  .kpi { padding: 1.1rem .9rem 1rem; }
  .kpi .v { font-size: 1.3rem; white-space: nowrap; }
  .chapter-head { min-height: 42svh; padding: 5rem 0 2.5rem; }
}

/* IMPRESIÓN (mantiene tema oscuro) */
@media print {
  @page { size: A4; margin: 10mm; }
  * { -webkit-print-color-adjust: exact; print-color-adjust: exact; }
  body { font-size: 11px; }
  .nav, .index, .scroll-cue, .toc-section, .skip-link { display: none !important; }
  .hero { min-height: auto; padding: 2rem 0; }
  .chapter-head { min-height: auto; padding: 2rem 0 1rem; }
  [data-reveal] { opacity: 1 !important; transform: none !important; }
  .table-wrap { max-height: none; overflow: visible; }
  thead th { position: static; }
  table, figure, .fig, .kpis, .opt { break-inside: avoid; }
}

/* ——— Modelo 3D interactivo ——— */
.modelo3d-wrap {
  position: relative;
  margin: 1.75rem 0 1.25rem;
  border: 1px solid var(--line);
  border-radius: 12px;
  overflow: hidden;
  background: #0e0e0e;
  height: min(70vh, 560px);
  height: min(70svh, 560px);
  min-height: 320px;
}
[data-theme="light"] .modelo3d-wrap { background: #f0eeea; }
.modelo3d-wrap canvas {
  display: block;
  width: 100% !important;
  height: 100% !important;
  touch-action: none;
  cursor: grab;
}
.modelo3d-wrap canvas:active { cursor: grabbing; }
.modelo3d-ui {
  position: absolute; top: .75rem; left: .75rem; right: .75rem;
  display: flex; flex-wrap: wrap; gap: .5rem; align-items: center;
  justify-content: space-between; pointer-events: none; z-index: 2;
}
.modelo3d-views {
  display: inline-flex; gap: 0; border-radius: 999px; overflow: hidden;
  border: 1px solid var(--line-strong); background: rgba(10,10,10,.72);
  backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px);
  pointer-events: auto;
}
[data-theme="light"] .modelo3d-views { background: rgba(255,255,255,.88); }
.modelo3d-views button {
  appearance: none; border: 0; background: transparent; color: var(--text);
  padding: .45rem .9rem; font-size: .78rem; font-weight: 600; letter-spacing: .04em;
  cursor: pointer; line-height: 1; transition: background .15s, color .15s;
}
.modelo3d-views button + button { border-left: 1px solid var(--line); }
.modelo3d-views button:hover { background: var(--accent-soft); }
.modelo3d-views button.is-active {
  background: var(--accent); color: #fff;
}
.modelo3d-check {
  pointer-events: auto;
  display: inline-flex; align-items: center; gap: .4rem;
  font-size: .78rem; font-weight: 500; letter-spacing: .02em;
  padding: .4rem .75rem; border-radius: 999px;
  border: 1px solid var(--line-strong);
  background: rgba(10,10,10,.72); color: var(--text);
  backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px);
  cursor: pointer; user-select: none;
}
[data-theme="light"] .modelo3d-check { background: rgba(255,255,255,.88); }
.modelo3d-check input { accent-color: var(--accent); margin: 0; }
.modelo3d-legend {
  position: absolute; bottom: .75rem; left: .75rem; right: .75rem;
  display: flex; flex-wrap: wrap; gap: .65rem 1.1rem;
  font-size: .72rem; font-weight: 500; letter-spacing: .04em;
  color: rgba(245,245,245,.88); pointer-events: none; z-index: 2;
}
[data-theme="light"] .modelo3d-legend { color: rgba(26,26,26,.78); }
.modelo3d-legend span { display: inline-flex; align-items: center; gap: .4rem; }
.modelo3d-legend i {
  display: inline-block; width: 12px; height: 12px; border-radius: 3px;
  border: 1px solid rgba(255,255,255,.25);
}
.modelo3d-legend .leg-panel i { background: #b7b3a8; }
.modelo3d-legend .leg-losa i { background: #8e8a82; }
.modelo3d-legend .leg-junta i { background: #1a1a18; border-color: #c4b8a0; box-shadow: inset 0 0 0 3px #c4b8a0; }
@media (max-width: 520px) {
  .modelo3d-wrap { height: min(60vh, 480px); height: min(60svh, 480px); }
  .modelo3d-views button { padding: .4rem .7rem; font-size: .72rem; }
  .modelo3d-legend { font-size: .65rem; gap: .45rem .75rem; }
}
@media print {
  .modelo3d-wrap { height: 360px; break-inside: avoid; }
  .modelo3d-ui { display: none; }
}
