:root {
  --navy: #0E1E3A;
  --navy-2: #16294D;
  --blue: #1677E5;
  --sky: #5AB0FF;
  --ice: #EAF4FF;
  --green: #2FA84F;
  --sun: #FF8A3D;
  --red: #E5484D;
  --text: #0E1E3A;
  --muted: #55657E;
  --line: #DCE7F3;
  --bg: #F4F8FD;
  --card: #FFFFFF;
  --radius: 18px;
  --shadow: 0 1px 2px rgba(14, 30, 58, .06), 0 8px 24px rgba(14, 30, 58, .06);
  --font: 'Inter', system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
  --display: 'Bricolage Grotesque', 'Inter', system-ui, sans-serif;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: var(--font);
  color: var(--text);
  background: var(--bg);
  line-height: 1.45;
  padding-bottom: env(safe-area-inset-bottom);
}
h1, h2, h3 { font-family: var(--display); line-height: 1.15; margin: 0 0 .4rem; }
h2 { font-size: 1.25rem; }
h3 { font-size: 1.05rem; }
.hint { color: var(--muted); font-size: .9rem; margin: 0 0 1rem; }
[hidden] { display: none !important; }

/* Barra superior */
.top {
  position: sticky; top: 0; z-index: 20;
  background: var(--navy);
  color: #fff;
  padding-top: env(safe-area-inset-top);
  box-shadow: 0 4px 18px rgba(14, 30, 58, .25);
}
.top-in {
  max-width: 1100px; margin: 0 auto; padding: 10px 16px;
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
}
.brand { display: flex; align-items: center; gap: 10px; color: inherit; text-decoration: none; min-width: 0; }
.brand img { height: 44px; width: auto; display: block; background: #fff; border-radius: 10px; padding: 3px 8px; }
.brand-sub { font-size: .78rem; color: #A9C4E6; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
@media (max-width: 520px) { .brand-sub { display: none; } }
.mode { display: flex; background: var(--navy-2); border-radius: 999px; padding: 3px; flex-shrink: 0; }
.mode button {
  border: 0; background: transparent; color: #C9D8EE; font: 600 .82rem var(--font);
  padding: 7px 12px; border-radius: 999px; cursor: pointer;
}
.mode button.on { background: var(--blue); color: #fff; }
.steps {
  max-width: 1100px; margin: 0 auto; display: grid; grid-template-columns: repeat(3, 1fr);
  padding: 0 8px;
}
.steps button {
  border: 0; background: transparent; color: #A9C4E6; font: 600 .88rem var(--font);
  padding: 10px 4px 12px; cursor: pointer; border-bottom: 3px solid transparent;
}
.steps button b {
  display: inline-grid; place-items: center; width: 20px; height: 20px; border-radius: 50%;
  background: var(--navy-2); font-size: .72rem; margin-right: 4px;
}
.steps button.on { color: #fff; border-bottom-color: var(--sky); }
.steps button.on b { background: var(--blue); }

main { max-width: 1100px; margin: 0 auto; padding: 16px; }
.tab { display: none; }
.tab.on { display: block; animation: fade .25s ease; }
@keyframes fade { from { transform: translateY(6px); } }

.card {
  background: var(--card); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 18px; margin-bottom: 14px; box-shadow: var(--shadow);
}
.grid2, .grid3 { display: grid; gap: 12px; }
@media (min-width: 640px) {
  .grid2 { grid-template-columns: 1fr 1fr; }
  .grid3 { grid-template-columns: repeat(3, 1fr); }
}
label { display: block; font-size: .85rem; font-weight: 600; color: var(--muted); }
label > input, label > select, .field {
  display: block; width: 100%; margin-top: 5px; font: 500 1rem var(--font); color: var(--text);
  background: #fff; border: 1.5px solid var(--line); border-radius: 12px; padding: 10px 12px;
  min-height: 44px;
}
input:focus, select:focus { outline: none; border-color: var(--blue); box-shadow: 0 0 0 3px rgba(22, 119, 229, .15); }
.check { display: flex; align-items: center; gap: 8px; font-weight: 600; color: var(--text); min-height: 44px; }
.check input { width: 20px; height: 20px; accent-color: var(--blue); }
.sub { font-weight: 400; color: var(--muted); font-size: .8rem; display: block; margin-top: 4px; }

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  border: 0; border-radius: 12px; padding: 12px 18px; font: 700 .95rem var(--font);
  cursor: pointer; min-height: 44px; text-decoration: none;
}
.btn.primary { background: var(--blue); color: #fff; }
.btn.primary:hover { background: #0F66CC; }
.btn.green { background: var(--green); color: #fff; }
.btn.ghost { background: var(--ice); color: var(--blue); }
.btn.sm { padding: 8px 12px; min-height: 36px; font-size: .85rem; }
.btn.block { width: 100%; margin-top: 12px; }
.icon-btn { border: 0; background: var(--ice); color: var(--navy); width: 40px; height: 40px; border-radius: 10px; font-size: 1rem; cursor: pointer; }
.actions { display: flex; justify-content: space-between; gap: 10px; flex-wrap: wrap; margin: 6px 0 24px; }
.actions .btn.primary:only-child { margin-left: auto; }
.row-between { display: flex; justify-content: space-between; align-items: flex-start; gap: 10px; }

/* Clima */
.clima { display: grid; grid-template-columns: repeat(2, 1fr); gap: 8px; margin-top: 14px; }
@media (min-width: 640px) { .clima { grid-template-columns: repeat(4, 1fr); } }
.chip {
  background: var(--ice); border-radius: 12px; padding: 10px 12px;
}
.chip small { display: block; color: var(--muted); font-size: .74rem; font-weight: 600; }
.chip b { font-size: 1.05rem; }
.chip.hot { background: #FFF1E7; }
.chip.cold { background: #EAF4FF; }

/* Zonas */
.zone-list { display: grid; gap: 10px; }
.zone {
  display: grid; grid-template-columns: 1fr auto; gap: 8px; align-items: center;
  border: 1.5px solid var(--line); border-radius: 14px; padding: 12px 14px; background: #fff;
}
.zone h3 { margin: 0; font-size: 1rem; }
.zone .meta { color: var(--muted); font-size: .84rem; }
.zone .tr { font: 800 1.1rem var(--display); color: var(--blue); text-align: right; }
.zone .tr small { display: block; font: 500 .72rem var(--font); color: var(--muted); }
.zone .z-actions { grid-column: 1 / -1; display: flex; gap: 6px; flex-wrap: wrap; }
.empty { text-align: center; padding: 26px 10px; color: var(--muted); border: 2px dashed var(--line); border-radius: 14px; }

/* Editor (sheet) */
.sheet { position: fixed; inset: 0; z-index: 40; background: rgba(14, 30, 58, .45); display: flex; justify-content: center; align-items: flex-end; }
.sheet-panel {
  background: var(--bg); width: 100%; max-width: 760px; max-height: 94vh; display: flex; flex-direction: column;
  border-radius: 22px 22px 0 0; overflow: hidden; animation: up .25s ease;
}
@media (min-width: 760px) { .sheet { align-items: center; } .sheet-panel { border-radius: 22px; max-height: 90vh; } }
@keyframes up { from { transform: translateY(30px); } }
.sheet-head { display: flex; justify-content: space-between; align-items: center; padding: 14px 16px; background: #fff; border-bottom: 1px solid var(--line); }
.sheet-head h2 { margin: 0; }
.sheet-body { overflow-y: auto; padding: 14px 16px; flex: 1; }
.sheet-foot {
  display: flex; justify-content: space-between; align-items: center; gap: 10px; padding: 12px 16px calc(12px + env(safe-area-inset-bottom));
  background: #fff; border-top: 1px solid var(--line);
}
.live { font-weight: 700; color: var(--navy); font-size: .9rem; }
.live small { display: block; font-weight: 500; color: var(--muted); }
fieldset { border: 1px solid var(--line); border-radius: 14px; padding: 14px; margin: 0 0 12px; background: #fff; }
legend { font: 700 .95rem var(--display); padding: 0 6px; color: var(--navy); }
.q { margin-bottom: 12px; }
.q:last-child { margin-bottom: 0; }
.seg { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 6px; }
.seg button {
  border: 1.5px solid var(--line); background: #fff; color: var(--text); border-radius: 10px;
  padding: 8px 12px; font: 600 .86rem var(--font); cursor: pointer; min-height: 40px;
}
.seg button.on { border-color: var(--blue); background: var(--ice); color: var(--blue); }
.compass { display: grid; grid-template-columns: repeat(3, 56px); gap: 6px; margin-top: 6px; }
.compass button { min-height: 44px; border: 1.5px solid var(--line); background: #fff; border-radius: 10px; font: 700 .8rem var(--font); cursor: pointer; color: var(--text); }
.compass button.on { border-color: var(--sun); background: #FFF1E7; color: #B4510E; }
.compass .c { display: grid; place-items: center; font-size: 1.3rem; }
.list-row { display: grid; gap: 8px; grid-template-columns: 1fr 1fr; align-items: end; padding: 10px 0; border-bottom: 1px dashed var(--line); }
.list-row:last-of-type { border-bottom: 0; }
@media (min-width: 640px) { .list-row { grid-template-columns: 1.1fr .8fr 1.6fr 1.4fr auto; } .list-row.w4 { grid-template-columns: 1.1fr .8fr 2fr auto; } }
.list-row .icon-btn { width: 44px; height: 44px; background: #FDECEC; color: var(--red); }
.list-row label { font-size: .78rem; }

/* Resultados */
.hero {
  background: linear-gradient(135deg, var(--navy) 0%, #123A73 60%, var(--blue) 130%);
  color: #fff; border-radius: 22px; padding: 20px; margin-bottom: 14px; box-shadow: var(--shadow);
}
.hero small { color: #A9C4E6; font-weight: 600; font-size: .8rem; }
.hero .big { font: 800 2.6rem var(--display); line-height: 1; margin: 6px 0 4px; }
.hero .big span { font-size: 1.1rem; font-weight: 600; color: #A9C4E6; }
.hero-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; margin-top: 14px; }
@media (min-width: 640px) { .hero-grid { grid-template-columns: repeat(4, 1fr); } #results .hero-grid { grid-template-columns: repeat(3, 1fr); } }
.hero-grid div { background: rgba(255, 255, 255, .08); border-radius: 12px; padding: 10px 12px; }
.hero-grid b { display: block; font-size: 1.1rem; }
.sys { display: grid; gap: 10px; }
.sys-opt {
  border: 1.5px solid var(--line); border-radius: 14px; padding: 12px 14px; background: #fff; cursor: pointer;
  display: grid; grid-template-columns: 1fr auto; gap: 4px; text-align: left; font: inherit; color: inherit; width: 100%;
}
.sys-opt.on { border-color: var(--blue); background: var(--ice); }
.sys-opt b { font-size: 1rem; }
.sys-opt .cap { font: 800 1.1rem var(--display); color: var(--blue); text-align: right; }
.sys-opt p { grid-column: 1 / -1; margin: 0; color: var(--muted); font-size: .84rem; }
.tag { display: inline-block; background: var(--green); color: #fff; font-size: .7rem; font-weight: 700; padding: 2px 8px; border-radius: 99px; margin-left: 6px; vertical-align: middle; }
.table-wrap { overflow-x: auto; margin: 0 -4px; }
table { width: 100%; border-collapse: collapse; font-size: .88rem; }
th, td { padding: 9px 8px; text-align: right; border-bottom: 1px solid var(--line); white-space: nowrap; }
th:first-child, td:first-child { text-align: left; white-space: normal; }
th { color: var(--muted); font-size: .76rem; text-transform: uppercase; letter-spacing: .02em; }
tfoot td { font-weight: 800; border-bottom: 0; }
td select { font: 600 .82rem var(--font); border: 1.5px solid var(--line); border-radius: 8px; padding: 6px; max-width: 170px; background: #fff; color: var(--text); }
.bars { display: grid; gap: 8px; }
.bar { display: grid; grid-template-columns: 150px 1fr 70px; gap: 8px; align-items: center; font-size: .85rem; }
@media (max-width: 480px) { .bar { grid-template-columns: 110px 1fr 56px; font-size: .8rem; } }
.bar i { display: block; height: 12px; border-radius: 6px; background: var(--blue); }
.bar span:last-child { text-align: right; font-weight: 700; }
.notes { color: var(--muted); font-size: .84rem; padding-left: 18px; margin: 0; }
.notes li { margin-bottom: 4px; }
.warn { background: #FFF6E5; border: 1px solid #FFD89A; color: #7A4B00; border-radius: 12px; padding: 10px 12px; font-size: .86rem; margin-bottom: 14px; }

.only-det { display: none; }
body.det .only-det { display: block; }
body.det .only-rap { display: none; }

.toast {
  position: fixed; left: 50%; bottom: calc(20px + env(safe-area-inset-bottom)); transform: translateX(-50%); z-index: 60;
  background: var(--navy); color: #fff; padding: 10px 16px; border-radius: 12px; font-weight: 600; font-size: .9rem; box-shadow: var(--shadow);
}

/* ---------- Reporte para PDF ---------- */
.report { display: none; }
@media print {
  @page { size: letter; margin: 14mm 12mm; }
  body { background: #fff; padding: 0; }
  .top, main, .sheet, .toast { display: none !important; }
  .report { display: block; font-size: 10.5pt; color: #0E1E3A; }
  .report * { -webkit-print-color-adjust: exact; print-color-adjust: exact; }
}
.r-head { display: flex; justify-content: space-between; align-items: center; border-bottom: 3px solid var(--blue); padding-bottom: 8px; margin-bottom: 12px; }
.r-head img { height: 64px; }
.r-head .r-title { text-align: right; }
.r-head h1 { font-size: 16pt; margin: 0; }
.r-head small { color: var(--muted); }
.r-band { background: var(--navy); color: #fff; border-radius: 10px; padding: 10px 14px; display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; margin: 10px 0; }
.r-band small { color: #A9C4E6; display: block; font-size: 8pt; }
.r-band b { font-size: 13pt; }
.r-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.r-box { border: 1px solid var(--line); border-radius: 8px; padding: 8px 10px; margin-bottom: 10px; break-inside: avoid; }
.r-box h3 { font-size: 11pt; margin: 0 0 6px; color: var(--blue); }
.report table { font-size: 9pt; }
.report th, .report td { padding: 4px 6px; }
.report td:last-child, .report th:last-child { white-space: normal; text-align: left; min-width: 120px; }
.report td small { color: var(--muted); }
.r-kv { display: grid; grid-template-columns: 1fr auto; gap: 2px 10px; font-size: 9pt; }
.r-kv span:nth-child(even) { font-weight: 700; text-align: right; }
.r-foot { border-top: 1px solid var(--line); margin-top: 12px; padding-top: 8px; font-size: 8.5pt; color: var(--muted); display: grid; grid-template-columns: 1.3fr 1fr; gap: 10px; }
.r-foot b { color: var(--navy); }
.r-zone { break-inside: avoid; }

/* ---------- Modo Rápido: asistente paso a paso ---------- */
.legal { font-size: .8rem; color: #7A4B00; background: #FFF6E5; border: 1px solid #FFD89A; border-radius: 12px; padding: 9px 12px; margin: 12px 0; }
details.fold > summary { list-style: none; cursor: pointer; }
details.fold > summary::-webkit-details-marker { display: none; }
details.fold > summary h2 { display: flex; justify-content: space-between; align-items: center; margin: 0; }
details.fold > summary h2::after { content: '▾'; color: var(--blue); font-size: 1rem; transition: transform .2s; }
details.fold[open] > summary h2 { margin-bottom: 12px; }
details.fold[open] > summary h2::after { transform: rotate(180deg); }
details.fold small { font: 500 .8rem var(--font); color: var(--muted); }

.wiz-top {
  position: sticky; top: -14px; z-index: 2; margin: -14px -16px 12px; padding: 12px 16px;
  background: linear-gradient(135deg, var(--navy), #123A73); color: #fff;
  display: flex; justify-content: space-between; align-items: center; gap: 10px;
}
.dots { display: flex; gap: 6px; }
.dot { width: 26px; height: 8px; border-radius: 99px; border: 0; background: rgba(255,255,255,.22); cursor: pointer; padding: 0; transition: all .25s; }
.dot.done { background: var(--sky); }
.dot.on { background: #fff; width: 38px; }
.gauge { display: flex; align-items: baseline; gap: 4px; flex-wrap: wrap; justify-content: flex-end; }
.g-num { font: 800 2rem var(--display); line-height: 1; }
.g-unit { font-weight: 700; color: var(--sky); }
.g-btu { width: 100%; text-align: right; font-size: .75rem; color: #A9C4E6; }
.gauge.pulse .g-num { animation: pop .45s ease; }
@keyframes pop { 40% { transform: scale(1.12); color: var(--sky); } }
.wiz-title { font-size: 1.35rem; margin: 4px 0 14px; }
.wiz-body { animation: slidein .25s ease; }
@keyframes slidein { from { transform: translateX(14px); } }
.q-label { font-weight: 700; color: var(--navy); margin: 16px 0 8px; font-size: .95rem; }
.center { text-align: center; }

.tiles { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; }
@media (min-width: 560px) { .tiles { grid-template-columns: repeat(4, 1fr); } }
.tiles.row { grid-template-columns: repeat(auto-fit, minmax(96px, 1fr)); }
.tile {
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 6px; text-align: center;
  min-height: 92px; padding: 12px 8px; border: 2px solid var(--line); background: #fff; border-radius: 16px;
  font: 600 .86rem var(--font); color: var(--text); cursor: pointer; transition: transform .12s, border-color .15s, background .15s;
}
.tile:hover { border-color: var(--sky); }
.tile:active { transform: scale(.96); }
.tile.on { border-color: var(--blue); background: var(--ice); color: var(--blue); box-shadow: 0 0 0 3px rgba(22,119,229,.12); }
.t-emo { font-size: 1.7rem; line-height: 1; }
.tiles.row .tile { min-height: 78px; }
.tiles.row .t-emo { font-size: 1.35rem; }

.big-input { display: flex; align-items: baseline; justify-content: center; gap: 8px; margin: 6px 0 4px; }
.big-input input {
  width: 160px; text-align: center; font: 800 2.6rem var(--display); color: var(--navy);
  border: 0; border-bottom: 3px solid var(--blue); background: transparent; padding: 2px; border-radius: 0;
}
.big-input input:focus { outline: none; box-shadow: none; }
.big-input span { font: 700 1.3rem var(--display); color: var(--muted); }
.range { width: 100%; accent-color: var(--blue); height: 32px; margin: 4px 0 8px; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip-btn {
  border: 1.5px solid var(--line); background: #fff; border-radius: 99px; padding: 8px 14px; min-height: 40px;
  font: 600 .88rem var(--font); color: var(--text); cursor: pointer;
}
.chip-btn.on { border-color: var(--blue); background: var(--blue); color: #fff; }
details.mini { margin: 14px 0 0; background: #fff; border: 1px solid var(--line); border-radius: 12px; padding: 10px 12px; }
details.mini summary { cursor: pointer; font-weight: 600; color: var(--blue); font-size: .9rem; }
details.mini .grid2 { margin-top: 10px; grid-template-columns: 1fr 1fr; }

.stepper { display: flex; align-items: center; justify-content: center; gap: 22px; margin: 10px 0 12px; }
.stepper button {
  width: 64px; height: 64px; border-radius: 50%; border: 0; background: var(--blue); color: #fff;
  font: 700 2rem var(--font); cursor: pointer; box-shadow: var(--shadow);
}
.stepper button:active { transform: scale(.93); }
.stepper b { font: 800 3.2rem var(--display); min-width: 90px; text-align: center; color: var(--navy); }
.people { text-align: center; font-size: 1.3rem; letter-spacing: 2px; min-height: 2rem; margin-bottom: 12px; word-break: break-all; }

/* Tarjetas de equipo con foto */
.eq-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; }
@media (min-width: 560px) { .eq-grid { grid-template-columns: repeat(3, 1fr); } }
.eq-card {
  display: flex; flex-direction: column; gap: 4px; text-align: left; padding: 8px 8px 12px; border: 2px solid var(--line);
  background: #fff; border-radius: 16px; cursor: pointer; font: inherit; color: var(--text); transition: transform .12s, border-color .15s;
}
.eq-card:active { transform: scale(.97); }
.eq-card.on { border-color: var(--blue); background: var(--ice); box-shadow: 0 0 0 3px rgba(22,119,229,.12); }
.eq-card b { font-size: .88rem; line-height: 1.25; padding: 0 4px; }
.eq-card .tag { display: table; margin: 4px 0 0; }
.eq-cap { font: 800 .95rem var(--display); color: var(--blue); padding: 0 4px; }
.eq-img { display: grid; place-items: center; background: #fff; border-radius: 10px; height: 92px; overflow: hidden; }
.eq-img img { max-width: 100%; max-height: 88px; object-fit: contain; }

.sheet-panel.wiz .sheet-foot { gap: 8px; }
.sheet-panel.wiz .live { flex: 1; text-align: center; }

/* Zonas y resultados con foto */
.zone { grid-template-columns: 72px 1fr auto; }
.z-img { width: 72px; height: 54px; object-fit: contain; background: #fff; border-radius: 10px; border: 1px solid var(--line); grid-row: span 2; }
.z-eq { grid-column: 2 / -1; font-size: .8rem; color: var(--blue); font-weight: 600; }
.zone .z-actions { grid-column: 1 / -1; }
.sys-opt { grid-template-columns: 96px 1fr auto; align-items: center; }
.sys-opt .eq-img { height: 66px; grid-row: span 2; }
.sys-opt .eq-img img { max-height: 62px; }
.sys-opt p { grid-column: 2 / -1; }
@media (max-width: 480px) { .sys-opt { grid-template-columns: 72px 1fr; } .sys-opt .cap { grid-column: 2; text-align: left; } }
.t-img { width: 44px; height: 32px; object-fit: contain; float: left; margin: 2px 8px 0 0; background: #fff; border-radius: 6px; }
.r-sys { display: grid; grid-template-columns: 120px 1fr; gap: 12px; align-items: center; }
.r-sys img { width: 120px; max-height: 90px; object-fit: contain; }
.r-legal { border: 1px solid #FFD89A; background: #FFF6E5; color: #7A4B00; border-radius: 8px; padding: 6px 10px; font-size: 8.5pt; margin-bottom: 10px; }

/* ---------- Navegación entre módulos ---------- */
.mode button { text-decoration: none; }
@media (max-width: 420px) { .mode button { padding: 7px 9px; font-size: .78rem; } }
.pro-only { display: none; }
body.in-pro .pro-only { display: grid; }

/* ---------- Inicio ---------- */
.home-hero { text-align: center; padding: 18px 8px 8px; }
.home-hero h1 { font-size: clamp(1.6rem, 5vw, 2.3rem); color: var(--navy); }
.home-hero p { color: var(--muted); max-width: 560px; margin: 0 auto 18px; }
.home-grid { display: grid; gap: 14px; }
@media (min-width: 760px) { .home-grid { grid-template-columns: repeat(3, 1fr); } }
.home-card {
  display: flex; flex-direction: column; align-items: flex-start; gap: 8px; text-align: left; cursor: pointer;
  background: #fff; border: 2px solid var(--line); border-radius: 22px; padding: 20px; font: inherit; color: var(--text);
  box-shadow: var(--shadow); transition: transform .12s, border-color .15s;
}
.home-card:hover { border-color: var(--blue); transform: translateY(-2px); }
.home-card b { font: 800 1.35rem var(--display); color: var(--navy); }
.home-card span { color: var(--muted); font-size: .92rem; }
.home-card em { margin-top: auto; font-style: normal; font-weight: 700; font-size: .8rem; color: var(--blue); background: var(--ice); border-radius: 99px; padding: 4px 10px; }
.home-card .h-emo { font-size: 2.3rem; line-height: 1; color: inherit; }
.home-card img { height: 64px; width: auto; }
.home-card.pro { border-color: #C9DDF5; }
.home-card.tvr { background: linear-gradient(160deg, #fff 55%, var(--ice)); }

/* ---------- Modo Rápido ---------- */
.quick { max-width: 760px; margin: 0 auto; }
.quick-top {
  position: sticky; top: 112px; z-index: 5; margin-bottom: 12px; padding: 12px 16px; border-radius: 18px;
  background: linear-gradient(135deg, var(--navy), #123A73); color: #fff; box-shadow: var(--shadow);
  display: flex; justify-content: space-between; align-items: center; gap: 10px;
}
body:not(.in-pro) .quick-top { top: 76px; }
.tile small { font-weight: 500; font-size: .75rem; color: var(--muted); }
.center-chips { justify-content: center; }
.btn.wa { background: #25D366; color: #fff; }
.btn.wa:hover { background: #1EB857; }
a.btn.block { display: flex; }
.q-result { display: grid; grid-template-columns: 120px 1fr; gap: 14px; align-items: center; background: var(--ice); border-radius: 16px; padding: 14px; }
.q-result img { width: 120px; max-height: 100px; object-fit: contain; background: #fff; border-radius: 12px; padding: 4px; }
.q-result small { color: var(--muted); font-weight: 600; }
.q-result p { margin: 4px 0 0; color: var(--muted); font-size: .88rem; }
.q-big { font: 800 1.5rem var(--display); color: var(--blue); line-height: 1.15; margin-top: 4px; }
@media (max-width: 480px) { .q-result { grid-template-columns: 84px 1fr; } .q-result img { width: 84px; } .q-big { font-size: 1.2rem; } }
.eq-line { color: var(--muted); font-size: .76rem; padding: 0 4px; }

/* ---------- Módulo TVR ---------- */
.tvr-head { display: grid; grid-template-columns: 96px 1fr; gap: 14px; align-items: center; }
.tvr-head img, .tvr-cta img { width: 96px; height: auto; }
.tvr-head .hint { margin: 0; }
.tvr-cta { display: grid; grid-template-columns: 96px 1fr; gap: 14px; align-items: center; background: linear-gradient(160deg, #fff 55%, var(--ice)); }
.series-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; }
@media (min-width: 640px) { .series-grid { grid-template-columns: repeat(4, 1fr); } }
.series {
  display: flex; flex-direction: column; gap: 3px; text-align: left; padding: 8px 10px 12px; border: 2px solid var(--line);
  background: #fff; border-radius: 16px; cursor: pointer; font: inherit; color: var(--text);
}
.series.on { border-color: var(--blue); background: var(--ice); box-shadow: 0 0 0 3px rgba(22,119,229,.12); }
.series b { font-size: .92rem; }
.series small { color: var(--muted); font-size: .76rem; line-height: 1.3; }
.series .volt { color: var(--blue); font-weight: 700; }
.series .eq-img { height: 80px; }
.series .eq-img img { max-height: 76px; }
.tvr-src { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 12px; }
.btn:disabled { opacity: .45; cursor: not-allowed; }
.link { border: 0; background: none; color: var(--blue); font: 700 .86rem var(--font); cursor: pointer; padding: 0; text-decoration: underline; }
.tvr-zone { border-bottom: 1px dashed var(--line); padding-bottom: 8px; }
.tvr-zone .list-row { border-bottom: 0; }
.list-row.tvr-row { grid-template-columns: 1.4fr .8fr auto; }
.list-row.tvr-row > * { min-width: 0; }
.list-row.tvr-row label:nth-child(-n+2) { grid-column: 1 / -1; }
@media (min-width: 900px) { .list-row.tvr-row { grid-template-columns: 1.6fr 1.5fr 1.6fr .8fr auto; } .list-row.tvr-row label:nth-child(-n+2) { grid-column: auto; } }
.unit-in { display: flex; gap: 4px; margin-top: 5px; }
.unit-in input, .unit-in select { min-height: 44px; border: 1.5px solid var(--line); border-radius: 12px; padding: 8px 10px; font: 500 1rem var(--font); color: var(--text); background: #fff; }
.unit-in input { flex: 1; min-width: 0; }
.unit-in select { width: 82px; font-size: .85rem; }
.tvr-pick { display: flex; align-items: center; gap: 10px; font-size: .88rem; color: var(--navy); }
.tvr-pick img { width: 64px; height: 40px; object-fit: contain; background: #fff; border: 1px solid var(--line); border-radius: 8px; }
.tvr-pick b { color: var(--blue); display: block; }
.tvr-pick small { color: var(--muted); }
.tvr-sys-head { display: grid; grid-template-columns: 90px 1fr; gap: 14px; align-items: center; margin-bottom: 12px; }
.tvr-sys-head img { width: 90px; }
.tvr-sys-head small { color: var(--muted); font-weight: 700; text-transform: uppercase; font-size: .72rem; letter-spacing: .03em; }
.tvr-sys-head h2 { color: var(--navy); margin: 2px 0; }
.tvr-sys-head p { margin: 0; color: var(--muted); font-size: .88rem; }
.ratio { display: grid; grid-template-columns: 1fr auto; gap: 4px 10px; background: var(--ice); border-radius: 12px; padding: 10px 12px; margin-bottom: 12px; font-size: .88rem; }
.ratio b { font: 800 1.1rem var(--display); color: var(--blue); }
.ratio small { grid-column: 1 / -1; color: var(--muted); }
.ratio-bar { grid-column: 1 / -1; position: relative; height: 10px; background: #fff; border-radius: 6px; overflow: hidden; }
.ratio-bar i { position: absolute; inset: 0 auto 0 0; background: var(--green); border-radius: 6px; }
.ratio-bar em { position: absolute; top: 0; bottom: 0; width: 2px; background: var(--navy); }

/* TVR: habitación calculada por medidas */
.tvr-room { display: grid; gap: 8px; grid-template-columns: 1fr 1fr auto; align-items: end; padding: 10px 0; }
.tvr-room > * { min-width: 0; }
.tvr-room .full { grid-column: 1 / -1; }
.tvr-room .sun .seg { margin-top: 5px; }
.tvr-room .sun .seg button { flex: 1; }
.tvr-room .icon-btn { width: 44px; height: 44px; background: #FDECEC; color: var(--red); }
@media (min-width: 600px) {
  .tvr-room { grid-template-columns: 1.3fr 1.5fr .7fr .8fr; }
  .tvr-room .full { grid-column: auto; }
  .tvr-room .sun { grid-column: span 2; }
}
@media (min-width: 1000px) {
  .tvr-room { grid-template-columns: 1.2fr 1.5fr .6fr .7fr 1.9fr 1.3fr auto; }
  .tvr-room .sun { grid-column: auto; }
}
.t-load { display: block; color: var(--navy); font-size: .84rem; }
.t-load b { display: inline; color: var(--navy); }
.btn.armed { background: var(--red); color: #fff; }

/* ---------- TVR: capacidad real, diagrama y lista de materiales ---------- */
.chips-info { display: flex; flex-wrap: wrap; gap: 8px; }
.chips-info span { background: var(--ice); border-radius: 12px; padding: 8px 12px; font-size: .86rem; color: var(--navy); }
.chips-info b { margin-left: 4px; color: var(--blue); }
.chips-info .tot { background: var(--navy); color: #fff; }
.chips-info .tot b { color: var(--sky); }
.ratio.ok b { color: var(--green); }
.ratio.bad b { color: #B4510E; }
.sub-h { margin: 16px 0 8px; font-size: 1rem; color: var(--navy); }
.diagram { overflow-x: auto; border: 1px solid var(--line); border-radius: 12px; background: #fff; padding: 6px; -webkit-overflow-scrolling: touch; }
.diagram svg { display: block; }
.big-m { display: flex; align-items: baseline; gap: 8px; margin-bottom: 8px; }
.big-m input { width: 110px; font: 800 1.6rem var(--display); color: var(--navy); border: 0; border-bottom: 3px solid var(--blue); background: transparent; text-align: center; border-radius: 0; }
.big-m input:focus { outline: none; box-shadow: none; }
.big-m span { color: var(--muted); font-weight: 600; }
table.bom td:first-child { white-space: normal; }
table.bom .cat { color: var(--muted); font-size: .72rem; text-transform: uppercase; letter-spacing: .03em; font-weight: 700; }
.r-diagram svg { width: 100%; height: auto; max-height: 200px; }

/* Opciones del dividido (modo y voltaje) */
.div-opts { background: var(--ice); border-radius: 14px; padding: 4px 14px 14px; margin-top: 12px; }
.div-opts .chip-btn small { font-weight: 500; opacity: .75; margin-left: 4px; }
