/* ==========================================================================
   IntegradosCR — estilos del sitio
   ========================================================================== */

/* Base */
:root { color-scheme: light; padding-block: env(safe-area-inset-top, 0px) env(safe-area-inset-bottom, 0px); }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; }
img { max-width: 100%; height: auto; }
[hidden] { display: none !important; }

/* Layout: plano técnico. Titular a la izquierda, diagrama unifilar vivo a la derecha;
   debajo, listas abiertas separadas por reglas (sin tarjetas) y una banda oscura de equipos. */
:root {
  --bg: #F1F5F6;
  --surface: #FFFFFF;
  --ink: #0B2530;
  --muted: #4A636E;
  --line: #C7D4D9;
  --grid: rgba(11, 37, 48, 0.055);
  --energy: #F0A202;
  --energy-ink: #8A5600;
  --on-energy: #1B1300;
  --tech: #087E8B;
  --alert: #C2412D;
  --band-bg: #0B2530;
  --band-fg: #EAF2F4;
  --band-muted: #A3BAC2;
  --band-line: #25495A;
  --wire-white: #F6F6F0;
  --wire-orange: #E8731A;
  --wire-green: #2E9B4E;
  --wire-blue: #2567C9;
  --wire-brown: #B0733F;
  --shadow: rgba(11, 37, 48, 0.32);
  --vis-bg: #0B2530;
  --vis-fg: #EAF2F4;
  --vis-line: #3F6676;
  --vis-grid: rgba(234, 242, 244, 0.07);
  --vis-chip: rgba(6, 22, 29, 0.6);
  --vis-energy: #FFB52E;
  --vis-tech: #45CFC6;
  --glow-energy: rgba(255, 181, 46, 0.30);
  --glow-tech: rgba(69, 207, 198, 0.28);
  --wa: #0F8A4F;
  --on-wa: #FFFFFF;
  --display: "Archivo", "Arial Narrow", "Helvetica Neue", Arial, sans-serif;
  --body: "IBM Plex Sans", "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  --mono: "IBM Plex Mono", ui-monospace, "SF Mono", Menlo, Consolas, monospace;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #06161D; --surface: #0C232D; --ink: #E7F0F2; --muted: #9CB3BB; --line: #234250;
    --grid: rgba(231, 240, 242, 0.05);
    --energy: #FFB52E; --energy-ink: #FFC65C; --on-energy: #1B1300;
    --tech: #45CFC6; --alert: #FF7D69;
    --band-bg: #0C232D; --band-fg: #E7F0F2; --band-muted: #9CB3BB; --band-line: #2A4C5B;
    --shadow: rgba(0, 0, 0, 0.6); --vis-bg: #071A22; --vis-line: #33586A; --wa: #25D366; --on-wa: #04210F;
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --bg: #06161D; --surface: #0C232D; --ink: #E7F0F2; --muted: #9CB3BB; --line: #234250;
  --grid: rgba(231, 240, 242, 0.05);
  --energy: #FFB52E; --energy-ink: #FFC65C; --on-energy: #1B1300;
  --tech: #45CFC6; --alert: #FF7D69;
  --band-bg: #0C232D; --band-fg: #E7F0F2; --band-muted: #9CB3BB; --band-line: #2A4C5B;
  --shadow: rgba(0, 0, 0, 0.6); --vis-bg: #071A22; --vis-line: #33586A; --wa: #25D366; --on-wa: #04210F;
  color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  background: var(--bg);
  color: var(--ink);
  font: 400 1rem/1.6 var(--body);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
h1, h2, h3, p, dl, dd, ul, figure { margin: 0; padding: 0; }
ul { list-style: none; }
a { color: inherit; }
:focus-visible { outline: 3px solid var(--tech); outline-offset: 3px; border-radius: 2px; }

.wrap { max-width: 1240px; margin-inline: auto; padding-inline: clamp(16px, 4vw, 40px); }
.label {
  font: 500 0.75rem/1.3 var(--mono);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--muted);
}
.h2 {
  font-family: var(--display);
  font-stretch: 118%;
  font-weight: 800;
  font-size: clamp(1.7rem, 4.6vw, 2.75rem);
  line-height: 1.08;
  letter-spacing: -0.015em;
  text-wrap: balance;
}
.lede { color: var(--muted); max-width: 60ch; font-size: 1.0625rem; }

/* Botones */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  min-height: 48px; padding: 0 22px;
  font: 600 1rem/1 var(--body);
  text-decoration: none; cursor: pointer;
  border: 2px solid var(--ink); border-radius: 4px;
  background: transparent; color: var(--ink);
  transition: transform 0.15s ease, background-color 0.15s ease;
}
.btn:hover { transform: translateY(-1px); }
.btn-primary { background: var(--energy); border-color: var(--energy); color: var(--on-energy); }
.btn-small { min-height: 40px; padding: 0 16px; font-size: 0.9375rem; }

/* Encabezado */
.site-header {
  position: sticky; top: env(safe-area-inset-top, 0px); z-index: 20;
  background: var(--bg);
  border-bottom: 1px solid var(--line);
}
.nav { display: flex; align-items: center; justify-content: space-between; gap: 16px; min-height: 64px; flex-wrap: wrap; }
.brand {
  display: inline-flex; align-items: center; gap: 6px;
  font-family: var(--display); font-stretch: 112%; font-weight: 800; font-size: 1.25rem;
  letter-spacing: -0.01em; text-decoration: none;
}
.brand b { background: var(--energy); color: var(--on-energy); padding: 1px 6px 2px; border-radius: 3px; font-weight: 800; }
.nav-links { display: flex; align-items: center; gap: 28px; }
.nav-links a { text-decoration: none; font-weight: 500; }
.nav-links a:not(.btn):hover { text-decoration: underline; text-decoration-color: var(--energy); text-decoration-thickness: 3px; text-underline-offset: 6px; }
.menu-btn {
  display: none; align-items: center; gap: 10px;
  min-height: 44px; padding: 0 14px;
  font: 600 0.9375rem/1 var(--body); color: var(--ink);
  background: transparent; border: 2px solid var(--ink); border-radius: 4px; cursor: pointer;
}
.menu-btn i { display: block; width: 16px; height: 2px; background: var(--ink); box-shadow: 0 5px 0 var(--ink), 0 -5px 0 var(--ink); }
@media (max-width: 720px) {
  .menu-btn { display: inline-flex; }
  .nav-links { display: none; flex-basis: 100%; flex-direction: column; align-items: stretch; gap: 0; padding-bottom: 16px; }
  .nav[data-open="true"] .nav-links { display: flex; }
  .nav-links a:not(.btn) { padding: 14px 0; border-top: 1px solid var(--line); font-size: 1.0625rem; }
  .nav-links .btn { margin-top: 12px; }
}

.nav-dd { position: relative; }
.nav-dd-btn { display: inline-flex; align-items: center; gap: 8px; min-height: 44px; padding: 0; border: 0; background: transparent; color: var(--ink); font: 500 1rem/1 var(--body); cursor: pointer; }
.nav-dd-btn::after { content: ""; width: 7px; height: 7px; margin-top: -4px; border-right: 2px solid currentColor; border-bottom: 2px solid currentColor; transform: rotate(45deg); }
.nav-dd-menu { display: none; flex-direction: column; position: absolute; top: calc(100% + 6px); left: -14px; min-width: 190px; padding: 6px; background: var(--surface); border: 1px solid var(--line); border-radius: 14px; box-shadow: 0 20px 40px -22px var(--shadow); }
.nav-dd[data-open="true"] .nav-dd-menu { display: flex; }
.nav-dd-menu a { padding: 11px 12px; border-radius: 10px; }
.nav-dd-menu a:hover { background: var(--bg); }
@media (max-width: 720px) {
  .nav-dd-btn { width: 100%; min-height: 0; padding: 16px 0 2px; border-top: 1px solid var(--line); pointer-events: none; font: 500 0.75rem/1.3 var(--mono); letter-spacing: 0.1em; text-transform: uppercase; color: var(--muted); }
  .nav-dd-btn::after { display: none; }
  .nav-dd-menu { display: flex; position: static; min-width: 0; padding: 0; border: 0; border-radius: 0; box-shadow: none; background: transparent; }
  .nav-links .nav-dd-menu a { padding: 11px 0; border-top: 0; border-radius: 0; }
}
.back { align-self: flex-start; font: 500 0.8125rem/1 var(--mono); letter-spacing: 0.06em; text-decoration: none; color: var(--muted); padding-block: 8px; }
.back:hover { color: var(--ink); }

/* Hero */
.hero { padding-block: clamp(32px, 6vw, 72px) clamp(40px, 7vw, 88px); }
.hero-grid { display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, 0.95fr); gap: clamp(28px, 5vw, 64px); align-items: center; }
.hero-copy { display: flex; flex-direction: column; gap: 22px; min-width: 0; }
.hero-title {
  font-family: var(--display);
  font-stretch: 122%;
  font-weight: 800;
  font-size: clamp(2.05rem, 6.2vw, 4.1rem);
  line-height: 1.04;
  letter-spacing: -0.02em;
  text-wrap: balance;
}
.hero-title span { display: block; }
.hero-title u { text-decoration-line: underline; text-decoration-thickness: 0.13em; text-underline-offset: 0.11em; text-decoration-skip-ink: none; }
.hero-title .u-energy { text-decoration-color: var(--energy); }
.hero-title .u-tech { text-decoration-color: var(--tech); }
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; }
@media (min-width: 1100px) { .hero-grid { grid-template-columns: minmax(0, 1.2fr) minmax(0, 0.8fr); } }
@media (max-width: 900px) { .hero-grid { grid-template-columns: minmax(0, 1fr); } .sim { width: 100%; max-width: 600px; } }
@media (max-width: 480px) { .hero-title { font-stretch: 108%; } .hero-actions .btn { flex: 1 1 100%; } }

.hero-benefit { font-family: var(--display); font-stretch: 112%; font-weight: 700; font-size: clamp(1.2rem, 2.6vw, 1.6rem); line-height: 1.2; text-wrap: balance; }

/* Para quién */
.section.para { padding-top: 0; }
.para-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: clamp(14px, 2vw, 24px); }
.para-card {
  --glow: var(--glow-energy); --mark: var(--vis-energy);
  display: flex; flex-direction: column; gap: 16px; min-width: 0;
  color: var(--vis-fg); border-radius: 20px; padding: clamp(22px, 3vw, 34px);
  background:
    radial-gradient(85% 70% at 100% 0%, var(--glow), transparent 64%),
    linear-gradient(var(--vis-grid) 1px, transparent 1px) 0 0 / 22px 22px,
    linear-gradient(90deg, var(--vis-grid) 1px, transparent 1px) 0 0 / 22px 22px,
    var(--vis-bg);
}
.para-card.acc-tech { --glow: var(--glow-tech); --mark: var(--vis-tech); }
.para-card .label { color: var(--vis-fg); opacity: 0.75; }
.para-card h2 { font-family: var(--display); font-stretch: 116%; font-weight: 800; font-size: clamp(1.5rem, 3.2vw, 2.1rem); line-height: 1.1; letter-spacing: -0.015em; text-wrap: balance; }
.para-card ul { border-bottom: 1px solid var(--vis-line); }
.para-card li { position: relative; padding: 11px 0 11px 22px; border-top: 1px solid var(--vis-line); line-height: 1.45; }
.para-card li::before { content: ""; position: absolute; left: 2px; top: 1.1em; width: 8px; height: 8px; border-radius: 2px; background: var(--mark); }
.para-card .btn { align-self: flex-start; margin-top: auto; }
.para-card :focus-visible { outline-color: var(--vis-tech); }
.calc-cta { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 16px 24px; margin-top: clamp(14px, 2vw, 24px); padding: clamp(18px, 2.4vw, 26px); background: var(--surface); border: 1px solid var(--line); border-radius: 20px; }
.calc-cta > div { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.calc-cta-t { font-family: var(--display); font-stretch: 112%; font-weight: 800; font-size: clamp(1.15rem, 2.4vw, 1.5rem); line-height: 1.2; text-wrap: balance; }
@media (max-width: 760px) { .para-grid { grid-template-columns: minmax(0, 1fr); } .para-card .btn, .calc-cta .btn { align-self: stretch; width: 100%; } }

/* WhatsApp flotante */
.wa-float {
  position: fixed; right: 16px; bottom: calc(16px + env(safe-area-inset-bottom, 0px)); z-index: 30;
  display: inline-flex; align-items: center; gap: 8px; min-height: 52px; padding: 0 20px 0 16px;
  background: var(--wa); color: var(--on-wa); border-radius: 999px;
  font: 600 1rem/1 var(--body); text-decoration: none;
  box-shadow: 0 14px 30px -12px var(--shadow);
}
.wa-float svg { width: 24px; height: 24px; flex: none; }
@media (max-width: 860px) { .page-calc .wa-float { display: none; } }

/* Simulación */
.sim {
  min-width: 0;
  background-color: var(--surface);
  background-image: linear-gradient(var(--grid) 1px, transparent 1px), linear-gradient(90deg, var(--grid) 1px, transparent 1px);
  background-size: 20px 20px;
  border: 1px solid var(--line); border-radius: 6px;
  padding: clamp(14px, 3vw, 22px);
  display: flex; flex-direction: column; gap: 14px;
}
.sim-head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px; }
.sim svg { display: block; width: 100%; height: auto; }
.sim-note { font-size: 0.9375rem; color: var(--ink); min-height: 3em; }
.node { fill: var(--surface); stroke: var(--ink); stroke-width: 1.5; }
.n-t { font: 500 9.5px var(--mono); letter-spacing: 0.05em; fill: var(--muted); }
.n-s { font: 600 11.5px var(--body); fill: var(--ink); }
.dot { fill: var(--tech); }
.pic { fill: none; stroke: var(--ink); stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
.pic-thin { stroke-width: 1.2; }
.pic-body { fill: var(--bg); }
.pic-panel { fill: var(--tech); fill-opacity: 0.2; }
.pic-sun { stroke: var(--energy); }
.bar { fill: var(--tech); }
.lever-off { display: none; stroke: var(--energy); }
.sim[data-grid="off"] .lever-on { display: none; }
.sim[data-grid="off"] .lever-off { display: inline; }
.sim[data-grid="off"] .bar { fill: var(--energy); }
.sim[data-grid="off"] #b3 { fill-opacity: 0.2; }
.link { fill: none; stroke: var(--line); stroke-width: 3; stroke-dasharray: 5 7; stroke-linecap: round; }
.cut line { stroke: var(--alert); stroke-width: 3; stroke-linecap: round; }
@keyframes flow { to { stroke-dashoffset: -12; } }
@keyframes flow-back { to { stroke-dashoffset: 12; } }
.sim[data-grid="on"] #l-pv, .sim[data-grid="on"] #l-bat,
.sim[data-grid="off"] #l-pv, .sim[data-grid="off"] #l-inv, .sim[data-grid="off"] #l-load { stroke: var(--energy); animation: flow 0.9s linear infinite; }
.sim[data-grid="off"] #l-bat { stroke: var(--energy); animation: flow-back 0.9s linear infinite; }
.sim[data-grid="on"] #l-grid, .sim[data-grid="on"] #l-load { stroke: var(--ink); animation: flow 0.9s linear infinite; }
.sim[data-grid="on"] .cut { display: none; }
.sim[data-grid="off"] #d-red { fill: var(--alert); }
.sim[data-grid="off"] #d-inv, .sim[data-grid="off"] #d-ats, .sim[data-grid="off"] #d-bat { fill: var(--energy); }
#d-pv { fill: var(--energy); }
@media (max-width: 480px) { .n-t { font-size: 11px; letter-spacing: 0.02em; } .n-s { font-size: 12.5px; } }
.legend { display: flex; flex-wrap: wrap; gap: 6px 18px; font: 400 0.75rem/1.4 var(--mono); color: var(--muted); }
.legend span { display: inline-flex; align-items: center; gap: 7px; }
.legend i { width: 18px; height: 3px; border-radius: 2px; background: var(--ink); }
.legend .k-sol { background: var(--energy); }

/* Secciones */
.section { padding-block: clamp(48px, 8vw, 96px); scroll-margin-top: 72px; }
.section-head { display: flex; flex-direction: column; gap: 14px; margin-bottom: clamp(28px, 5vw, 48px); }

/* Servicios */
.svc-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: clamp(14px, 2vw, 24px); }
.svc-grid:has(.svc[data-open="true"]) { align-items: start; }
.svc {
  --glow: var(--glow-tech);
  display: flex; flex-direction: column; min-width: 0;
  background: var(--surface);
  border: 1px solid var(--line); border-radius: 20px; overflow: hidden;
  transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
}
.svc:hover, .svc[data-open="true"] { border-color: var(--ink); box-shadow: 0 24px 48px -28px var(--shadow); }
.svc:hover { transform: translateY(-3px); }
.svc.acc-energy { --glow: var(--glow-energy); }
.svc-vis {
  position: relative; height: 176px; flex: none; color: var(--vis-fg);
  background:
    radial-gradient(85% 120% at 100% 0%, var(--glow), transparent 64%),
    linear-gradient(var(--vis-grid) 1px, transparent 1px) 0 0 / 22px 22px,
    linear-gradient(90deg, var(--vis-grid) 1px, transparent 1px) 0 0 / 22px 22px,
    var(--vis-bg);
}
.svc-vis svg { position: absolute; inset: 0; width: 100%; height: 100%; display: block; }
.vis-tag {
  position: absolute; left: 14px; bottom: 12px;
  font: 500 0.6875rem/1 var(--mono); letter-spacing: 0.06em; color: var(--vis-fg);
  background: var(--vis-chip); border: 1px solid var(--vis-line); border-radius: 999px; padding: 6px 10px;
}
.vis-tag.top { bottom: auto; top: 12px; }
.svc-body { display: flex; flex-direction: column; gap: 12px; padding: 22px clamp(18px, 2.4vw, 26px) 24px; min-width: 0; }
.svc h3 { font-family: var(--display); font-stretch: 114%; font-weight: 800; font-size: clamp(1.35rem, 2.6vw, 1.65rem); line-height: 1.12; letter-spacing: -0.01em; }
.svc-kicker { font: 500 0.75rem/1.3 var(--mono); letter-spacing: 0.1em; text-transform: uppercase; color: var(--energy-ink); }
.svc-body > p { color: var(--muted); }
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chips li { font: 500 0.75rem/1 var(--mono); padding: 7px 10px; border: 1px solid var(--line); border-radius: 999px; background: var(--bg); }
.more {
  align-self: flex-start; display: inline-flex; align-items: center; gap: 10px;
  min-height: 44px; padding: 0 20px 0 16px; margin-top: 4px;
  font: 600 0.8125rem/1 var(--mono); letter-spacing: 0.12em; text-transform: uppercase;
  color: var(--ink); background: transparent; border: 2px solid var(--ink); border-radius: 999px; cursor: pointer;
  transition: background-color 0.2s ease, color 0.2s ease;
}
.more:hover { background: var(--energy); border-color: var(--energy); color: var(--on-energy); }
.more-ico { position: relative; width: 12px; height: 12px; flex: none; }
.more-ico::before, .more-ico::after { content: ""; position: absolute; left: 0; top: 5px; width: 12px; height: 2px; background: currentColor; transition: transform 0.25s ease; }
.more-ico::after { transform: rotate(90deg); }
.svc[data-open="true"] .more { background: var(--ink); border-color: var(--ink); color: var(--bg); }
.svc[data-open="true"] .more-ico::after { transform: rotate(0deg); }
.svc-more { display: grid; grid-template-rows: 0fr; transition: grid-template-rows 0.35s ease; }
.svc[data-open="true"] .svc-more { grid-template-rows: 1fr; }
.svc-more-in { overflow: hidden; min-height: 0; visibility: hidden; transition: visibility 0s 0.35s; }
.svc[data-open="true"] .svc-more-in { visibility: visible; transition-delay: 0s; }
.svc-more h4 { margin: 10px 0 0; font: 500 0.75rem/1.3 var(--mono); letter-spacing: 0.1em; text-transform: uppercase; color: var(--muted); }
.svc-more ul { margin-top: 10px; border-bottom: 1px solid var(--line); }
.svc-more li { position: relative; padding: 11px 0 11px 22px; border-top: 1px solid var(--line); font-size: 0.9688rem; line-height: 1.5; }
.svc-more li::before { content: ""; position: absolute; left: 2px; top: 1.15em; width: 8px; height: 8px; border-radius: 2px; background: var(--energy); }
.svc.feature { grid-column: 1 / -1; flex-direction: row; }
.svc.feature .svc-vis { flex: 0 0 42%; height: auto; min-height: 250px; }
.svc.feature .svc-body { flex: 1 1 0; justify-content: center; padding-block: 28px; }
.v-fg { fill: none; stroke: var(--vis-fg); stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.v-dim { fill: none; stroke: var(--vis-line); stroke-width: 1.5; }
.v-wire { fill: none; stroke-width: 4.5; stroke-linecap: butt; }
.v-stripe { fill: none; stroke-width: 4.5; stroke-dasharray: 5 7; }
.v-flow { fill: none; stroke: var(--vis-tech); stroke-width: 2.5; stroke-dasharray: 4 7; stroke-linecap: round; animation: flow-net 1.1s linear infinite; }
@keyframes flow-net { to { stroke-dashoffset: -11; } }
.v-wave { fill: none; stroke: var(--vis-energy); stroke-width: 3.5; stroke-linecap: round; filter: drop-shadow(0 0 6px var(--vis-energy)); }
.v-wave2 { fill: none; stroke: var(--vis-fg); stroke-width: 2; stroke-opacity: 0.35; stroke-linecap: round; }
.v-num { font-family: var(--display); font-stretch: 118%; font-weight: 800; fill: var(--vis-fg); }
.v-cap { font: 500 8.5px var(--mono); letter-spacing: 0.1em; fill: var(--vis-fg); fill-opacity: 0.7; }
@media (max-width: 760px) {
  .svc-grid { grid-template-columns: minmax(0, 1fr); }
  .svc.feature { flex-direction: column; }
  .svc.feature .svc-vis { flex: none; height: 176px; min-height: 0; }
  .svc.feature .svc-body { flex: none; padding-block: 22px 24px; }
}

/* Inteligencia artificial */
.section.ai { padding-top: 0; }
.ai-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: clamp(28px, 5vw, 64px); align-items: start; }
.ai-copy { display: flex; flex-direction: column; gap: 16px; min-width: 0; }
.ai-list { border-bottom: 2px solid var(--tech); min-width: 0; }
.ai-list li { display: grid; grid-template-columns: 210px minmax(0, 1fr); gap: 4px 16px; padding-block: 18px; border-top: 2px solid var(--tech); align-items: baseline; }
.ai-list h3 { font-family: var(--display); font-stretch: 112%; font-weight: 700; font-size: 1.15rem; line-height: 1.2; }
.ai-list p { color: var(--muted); }
@media (max-width: 1100px) { .ai-list li { grid-template-columns: minmax(0, 1fr); } }
@media (max-width: 760px) { .ai-grid { grid-template-columns: minmax(0, 1fr); } }

/* Calculadora */
.calc { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, 0.85fr); gap: clamp(14px, 2vw, 24px); align-items: start; }
.calc-in { display: flex; flex-direction: column; gap: 22px; min-width: 0; background: var(--surface); border: 1px solid var(--line); border-radius: 20px; padding: clamp(18px, 2.4vw, 26px); }
.calc-in fieldset { border: 0; padding: 0; margin: 0; min-width: 0; }
.calc-in legend { padding: 0; margin-bottom: 10px; }
.calc-list { border-bottom: 1px solid var(--line); }
.calc-list li { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 12px; align-items: center; padding-block: 9px; border-top: 1px solid var(--line); }
.calc-name { display: block; font-weight: 600; line-height: 1.3; }
.calc-w { display: block; font: 400 0.75rem/1.4 var(--mono); color: var(--muted); }
.calc-list li[data-on="false"] .calc-name { font-weight: 500; color: var(--muted); }
.stepper { display: inline-flex; align-items: center; border: 1.5px solid var(--ink); border-radius: 999px; }
.stepper button { width: 42px; height: 42px; padding: 0; border: 0; border-radius: 999px; background: transparent; color: var(--ink); font: 600 1.25rem/1 var(--body); cursor: pointer; }
.stepper button:hover { background: var(--energy); color: var(--on-energy); }
.stepper output { min-width: 30px; text-align: center; font: 600 1rem/1 var(--mono); font-variant-numeric: tabular-nums; }
.calc-hours { display: flex; flex-direction: column; gap: 8px; }
.calc-hours-head { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; }
.calc-hours-head output { font-family: var(--display); font-stretch: 112%; font-weight: 800; font-size: 1.25rem; }
.calc-hours input { width: 100%; height: 32px; margin: 0; accent-color: var(--energy); }
.calc-reset { align-self: flex-start; }
.calc-out {
  position: sticky; top: calc(env(safe-area-inset-top, 0px) + 84px);
  display: flex; flex-direction: column; gap: 18px; min-width: 0;
  color: var(--vis-fg); border-radius: 20px; padding: clamp(20px, 2.6vw, 28px);
  background:
    radial-gradient(85% 70% at 100% 0%, var(--glow-energy), transparent 64%),
    linear-gradient(var(--vis-grid) 1px, transparent 1px) 0 0 / 22px 22px,
    linear-gradient(90deg, var(--vis-grid) 1px, transparent 1px) 0 0 / 22px 22px,
    var(--vis-bg);
}
.calc-out .label { color: var(--vis-fg); opacity: 0.75; }
.calc-big { font-family: var(--display); font-stretch: 118%; font-weight: 800; font-size: clamp(2.6rem, 6vw, 3.6rem); line-height: 1; letter-spacing: -0.02em; font-variant-numeric: tabular-nums; }
.calc-big small, .calc-rows dd small { font-size: 0.45em; color: var(--vis-energy); margin-left: 0.25em; letter-spacing: 0; }
.calc-rows { border-bottom: 1px solid var(--vis-line); }
.calc-rows div { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 2px 14px; align-items: baseline; padding-block: 13px; border-top: 1px solid var(--vis-line); }
.calc-rows dt { font: 500 0.75rem/1.3 var(--mono); letter-spacing: 0.1em; text-transform: uppercase; opacity: 0.8; }
.calc-rows dd { font-family: var(--display); font-stretch: 112%; font-weight: 800; font-size: 1.5rem; line-height: 1.1; text-align: right; font-variant-numeric: tabular-nums; }
.calc-rows dd small { font-size: 0.6em; }
.calc-rows .calc-sub { grid-column: 1 / -1; font: 400 0.8125rem/1.45 var(--body); opacity: 0.75; text-align: left; }
.calc-note { font-size: 0.8125rem; line-height: 1.5; opacity: 0.8; }
.calc-out .btn { width: 100%; }
.calc-out :focus-visible { outline-color: var(--vis-tech); }
@media (max-width: 860px) { .calc { grid-template-columns: minmax(0, 1fr); } .calc-out { position: static; } }

/* Productos */
.band { background: var(--band-bg); color: var(--band-fg); }
.band .label, .band .lede { color: var(--band-muted); }
.prod { border-bottom: 1px solid var(--band-line); }
.prod li {
  display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr) minmax(0, 2fr);
  gap: 8px clamp(16px, 3vw, 40px); align-items: baseline;
  padding-block: 26px; border-top: 1px solid var(--band-line);
}
.prod h3 { font-family: var(--display); font-stretch: 125%; font-weight: 800; font-size: clamp(1.9rem, 4.4vw, 3rem); line-height: 1; letter-spacing: -0.02em; }
.prod .kind { font: 500 0.8125rem/1.4 var(--mono); letter-spacing: 0.06em; text-transform: uppercase; color: var(--energy); }
.prod p { color: var(--band-muted); max-width: 52ch; }
@media (max-width: 760px) { .prod li { grid-template-columns: minmax(0, 1fr); padding-block: 22px; } }

/* Contacto */
.contact-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: clamp(28px, 5vw, 64px); align-items: start; }
.contact-copy { display: flex; flex-direction: column; gap: 16px; min-width: 0; }
.contact-list { border-bottom: 2px solid var(--ink); min-width: 0; }
.contact-list div { display: grid; grid-template-columns: 120px minmax(0, 1fr); gap: 12px; padding-block: 18px; border-top: 2px solid var(--ink); align-items: baseline; }
.contact-list dt { font: 500 0.75rem/1.3 var(--mono); letter-spacing: 0.1em; text-transform: uppercase; color: var(--muted); }
.contact-list dd { font-size: 1.125rem; font-weight: 600; overflow-wrap: anywhere; display: flex; flex-wrap: wrap; align-items: center; gap: 8px 14px; }
.contact-list .sel { user-select: all; }
.contact-list a.sel { display: inline-flex; align-items: center; min-height: 44px; }
.copy { min-height: 36px; padding: 0 14px; font: 600 0.75rem/1 var(--mono); letter-spacing: 0.1em; text-transform: uppercase; color: var(--ink); background: transparent; border: 1.5px solid var(--ink); border-radius: 999px; cursor: pointer; }
.copy:hover { background: var(--ink); color: var(--bg); }
.contact-list .pending { font-weight: 500; color: var(--energy-ink); border: 1px dashed var(--energy-ink); border-radius: 3px; padding: 2px 8px; display: inline-block; }
@media (max-width: 760px) { .contact-grid { grid-template-columns: minmax(0, 1fr); } .contact-list div { grid-template-columns: minmax(0, 1fr); gap: 4px; } .copy { min-height: 44px; } }

.social { display: inline-flex; gap: 10px; }
.social a { display: inline-flex; align-items: center; justify-content: center; width: 44px; height: 44px; color: var(--ink); border: 1.5px solid var(--ink); border-radius: 999px; transition: background-color 0.2s ease, color 0.2s ease; }
.social a:hover { background: var(--ink); color: var(--bg); }
.social svg { width: 22px; height: 22px; }

/* Tarjetas de servicio: enlace a la página del servicio */
.svc-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 20px; margin-top: 4px; }
.svc-actions .more { margin-top: 0; }
.svc-link { display: inline-flex; align-items: center; gap: 6px; min-height: 44px; font-weight: 600; text-decoration: underline; text-decoration-color: var(--energy); text-decoration-thickness: 2px; text-underline-offset: 5px; }
.svc-link:hover { text-decoration-thickness: 4px; }

/* Producto con "+ MÁS": fotos y ficha técnica */
.prod-desc { display: flex; flex-direction: column; align-items: flex-start; gap: 14px; min-width: 0; }
.band .more { color: var(--band-fg); border-color: var(--band-fg); }
.band .more:hover { color: var(--on-energy); border-color: var(--energy); }
.band [data-open="true"] .more { background: var(--band-fg); border-color: var(--band-fg); color: var(--band-bg); }
.band [data-open="true"] .more-ico::after { transform: rotate(0deg); }
.prod-more { grid-column: 1 / -1; display: grid; grid-template-rows: 0fr; transition: grid-template-rows 0.35s ease; }
.prod-x[data-open="true"] .prod-more { grid-template-rows: 1fr; }
.prod-more-in { display: grid; grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.2fr); gap: clamp(20px, 4vw, 48px); align-items: start; overflow: hidden; min-height: 0; visibility: hidden; transition: visibility 0s 0.35s; }
.prod-x[data-open="true"] .prod-more-in { visibility: visible; transition-delay: 0s; padding-top: 18px; }
.prod-gallery { display: flex; gap: 12px; overflow-x: auto; scroll-snap-type: x mandatory; }
.prod-gallery a { flex: 0 0 100%; scroll-snap-align: start; border-radius: 14px; overflow: hidden; background: #fff; }
.prod-gallery img { display: block; width: 100%; height: auto; aspect-ratio: 1; object-fit: contain; }
.prod-info { display: flex; flex-direction: column; align-items: flex-start; gap: 16px; min-width: 0; }
.prod-info p { max-width: 60ch; }
.prod-specs { width: 100%; border-bottom: 1px solid var(--band-line); }
.prod-specs div { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 12px; padding-block: 10px; border-top: 1px solid var(--band-line); align-items: baseline; }
.prod-specs dt { font: 500 0.75rem/1.3 var(--mono); letter-spacing: 0.08em; text-transform: uppercase; color: var(--band-muted); }
.prod-specs dd { font-weight: 600; text-align: right; }
@media (max-width: 760px) { .prod-more-in { grid-template-columns: minmax(0, 1fr); } .prod-gallery a { max-width: 360px; } }
@media (prefers-reduced-motion: reduce) { .prod-more { transition: none; } }

/* Preguntas frecuentes */
.faq { max-width: 880px; border-bottom: 2px solid var(--ink); }
.faq details { border-top: 2px solid var(--ink); }
.faq summary { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding-block: 18px; cursor: pointer; list-style: none; font-family: var(--display); font-stretch: 112%; font-weight: 700; font-size: 1.15rem; line-height: 1.25; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; flex: none; font: 500 1.5rem/1 var(--mono); color: var(--energy-ink); }
.faq details[open] summary::after { content: "−"; }
.faq details p { max-width: 68ch; padding-bottom: 20px; color: var(--muted); }
.faq a, .prose a { text-decoration-color: var(--energy); text-decoration-thickness: 2px; text-underline-offset: 4px; }

/* Páginas de servicio y calculadora */
.page-hero { padding-block: clamp(28px, 5vw, 56px) clamp(32px, 5vw, 64px); }
.page-hero-grid { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr); gap: clamp(24px, 4vw, 56px); align-items: center; }
.page-hero-copy { display: flex; flex-direction: column; gap: 18px; min-width: 0; }
.crumbs { display: flex; flex-wrap: wrap; gap: 8px; font: 500 0.75rem/1.4 var(--mono); letter-spacing: 0.06em; text-transform: uppercase; color: var(--muted); }
.crumbs a { color: inherit; text-decoration: none; }
.crumbs a:hover { color: var(--ink); text-decoration: underline; }
.page-h1 { font-family: var(--display); font-stretch: 118%; font-weight: 800; font-size: clamp(1.9rem, 5vw, 3.2rem); line-height: 1.06; letter-spacing: -0.02em; text-wrap: balance; }
.svc-vis.page-vis { --glow: var(--glow-energy); height: clamp(200px, 30vw, 320px); border-radius: 20px; overflow: hidden; }
.svc-vis.page-vis.acc-tech { --glow: var(--glow-tech); }
.section.page-body { padding-top: 0; }
.page-cols { display: grid; grid-template-columns: minmax(0, 1.5fr) minmax(0, 0.9fr); gap: clamp(24px, 4vw, 64px); align-items: start; }
.prose { display: flex; flex-direction: column; gap: 16px; min-width: 0; }
.prose h2 { margin-top: 14px; font-family: var(--display); font-stretch: 116%; font-weight: 800; font-size: clamp(1.4rem, 3vw, 1.9rem); line-height: 1.12; letter-spacing: -0.01em; text-wrap: balance; }
.prose h2:first-child { margin-top: 0; }
.prose p { max-width: 66ch; color: var(--muted); }
.check { border-bottom: 1px solid var(--line); }
.check li { position: relative; padding: 12px 0 12px 24px; border-top: 1px solid var(--line); line-height: 1.5; }
.check li::before { content: ""; position: absolute; left: 2px; top: 1.2em; width: 8px; height: 8px; border-radius: 2px; background: var(--energy); }
.page-aside { position: sticky; top: calc(env(safe-area-inset-top, 0px) + 84px); }
.page-aside .aside-tel { font-size: 0.9375rem; opacity: 0.85; }
.section.faq-sec { padding-top: 0; }
.related-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; }
.related-grid a { display: flex; flex-direction: column; gap: 6px; min-width: 0; padding: 18px; background: var(--surface); border: 1px solid var(--line); border-radius: 16px; text-decoration: none; transition: border-color 0.2s ease, transform 0.2s ease; }
.related-grid a:hover { border-color: var(--ink); transform: translateY(-2px); }
.related-grid strong { font-family: var(--display); font-stretch: 112%; font-weight: 800; font-size: 1.1rem; line-height: 1.2; }
.related-grid span { color: var(--muted); font-size: 0.9375rem; line-height: 1.4; }
@media (max-width: 900px) {
  .page-hero-grid, .page-cols { grid-template-columns: minmax(0, 1fr); }
  .page-aside { position: static; }
  .related-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 480px) { .related-grid { grid-template-columns: minmax(0, 1fr); } }

/* Pie */
.foot-links { display: flex; flex-wrap: wrap; gap: 8px 22px; padding-bottom: 20px; margin-bottom: 20px; border-bottom: 1px solid var(--line); }
.foot-links a { color: var(--ink); font-weight: 500; text-decoration: none; }
.foot-links a:hover { text-decoration: underline; text-decoration-color: var(--energy); text-decoration-thickness: 2px; text-underline-offset: 5px; }

.site-footer { border-top: 1px solid var(--line); padding-block: 28px 96px; color: var(--muted); font-size: 0.9375rem; }
.foot { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px 24px; }
.foot .brand { color: var(--ink); font-size: 1.0625rem; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .link, .v-flow { animation: none !important; }
  .svc, .svc-more, .more-ico::before, .more-ico::after { transition: none; }
  .svc:hover { transform: none; }
  .btn, .related-grid a { transition: none; }
  .related-grid a:hover { transform: none; }
}
