/* =========================================================
   Calculadora Sanirey — Industrial Fieldbook
   Vanilla CSS. Sin frameworks, sin build step.
   ========================================================= */

:root {
  /* Concreto / grises cálidos */
  --paper:        #F5F3F0;
  --paper-2:      #EFEDE8;
  --concrete:     #E5E1DB;
  --concrete-2:   #D6D1C8;
  --stone:        #8A8479;
  --ink:          #1A1917;
  --ink-2:        #3D3A35;
  --ink-3:        #6B665D;

  /* Acentos */
  --blue:         #087553;
  --blue-dark:    #07583F;
  --blue-tint:    #E8F3ED;
  --amber:        #D98324;
  --amber-tint:   #FBF1E2;
  --amber-line:   #E8C79A;
  --green:        #2F6B4F;
  --green-tint:   #E8F0EB;
  --red:          #A32B1F;
  --red-tint:     #F7E9E7;

  /* Tipografía */
  --font: 'Satoshi', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
  --text-xs:   0.75rem;
  --text-sm:   0.8125rem;
  --text-base: 0.9375rem;
  --text-md:   1.0625rem;
  --text-lg:   1.25rem;
  --text-xl:   1.5rem;
  --text-2xl:  1.9375rem;
  --text-3xl:  2.5rem;

  /* Espacio */
  --sp-1: 4px;  --sp-2: 8px;  --sp-3: 12px; --sp-4: 16px;
  --sp-5: 24px; --sp-6: 32px; --sp-7: 48px; --sp-8: 64px; --sp-9: 88px;

  --radius: 3px;
  --line: 1px solid var(--concrete-2);
  --line-strong: 1px solid var(--stone);
  --wrap: 1140px;
}

*, *::before, *::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { animation-duration: 0.001ms !important; transition-duration: 0.001ms !important; }
}

body {
  margin: 0;
  font-family: var(--font);
  font-size: var(--text-base);
  line-height: 1.62;
  color: var(--ink);
  background: var(--paper);
  font-feature-settings: "ss01";
  -webkit-font-smoothing: antialiased;
}

/* Rejilla sutil de ficha técnica */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  background-image:
    linear-gradient(to right, rgba(138,132,121,.10) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(138,132,121,.10) 1px, transparent 1px);
  background-size: 64px 64px;
}
body > * { position: relative; z-index: 1; }

.wrap { width: 100%; max-width: var(--wrap); margin: 0 auto; padding: 0 var(--sp-5); }

h1, h2, h3, h4 { margin: 0 0 var(--sp-3); line-height: 1.18; letter-spacing: -0.015em; font-weight: 700; }
h1 { font-size: var(--text-3xl); font-weight: 900; letter-spacing: -0.028em; }
h2 { font-size: var(--text-2xl); }
h3 { font-size: var(--text-md); }
p { margin: 0 0 var(--sp-4); }
p:last-child { margin-bottom: 0; }

a { color: var(--blue-dark); text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 2px; }
a:hover { color: var(--ink); }

strong { font-weight: 700; }

:where(a, button, input, select, textarea, summary, [tabindex]):focus-visible {
  outline: 2px solid var(--blue);
  outline-offset: 2px;
  border-radius: 2px;
}

.visually-hidden {
  position: absolute !important; width: 1px; height: 1px;
  padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}

.skip-link {
  position: absolute; left: -9999px; top: 0;
  background: var(--ink); color: var(--paper); padding: var(--sp-3) var(--sp-4);
  z-index: 50; text-decoration: none; font-weight: 700;
}
.skip-link:focus { left: var(--sp-4); top: var(--sp-4); }

/* Números tabulares en todo dato numérico */
table, .figure-num, .equip-qty, .memoria-pasos, .hero-facts, input[type="number"], .stat {
  font-variant-numeric: tabular-nums;
  font-feature-settings: "tnum";
}

/* ============ HEADER ============ */
.site-header {
  background: #fff;
  color: var(--ink);
  border-bottom: 3px solid var(--blue);
}
.header-inner {
  display: flex; align-items: center; justify-content: space-between;
  gap: var(--sp-5); min-height: 76px; flex-wrap: wrap; padding-top: var(--sp-3); padding-bottom: var(--sp-3);
}
.brand { display: flex; align-items: center; gap: var(--sp-5); color: var(--ink); flex-wrap: wrap; }
.brand-logo { width: 218px; height: auto; display: block; }
.print-brand { display: none; }
.brand-text { display: flex; flex-direction: column; line-height: 1.25; }
.brand-text strong { font-size: var(--text-md); font-weight: 900; letter-spacing: 0.02em; }
.brand-text span { font-size: var(--text-xs); color: var(--ink-3); letter-spacing: 0.04em; text-transform: uppercase; }

.header-nav { display: flex; align-items: center; gap: var(--sp-5); flex-wrap: wrap; }
.header-nav a {
  color: var(--ink-2); font-size: var(--text-sm); text-decoration: none;
  letter-spacing: 0.01em; padding: var(--sp-1) 0; border-bottom: 1px solid transparent;
}
.header-nav a:hover { color: var(--blue-dark); border-bottom-color: var(--blue); }
.header-nav .header-cta {
  border: 1px solid var(--stone); padding: var(--sp-2) var(--sp-4); border-radius: var(--radius);
  color: var(--blue-dark);
}
.header-nav .header-cta:hover { background: var(--blue); border-color: var(--blue); color: #fff; }
.event-scope { margin-bottom: var(--sp-5); border-left: 3px solid var(--blue); padding-left: var(--sp-3); }
.hero-jump { display: inline-block; padding: var(--sp-2) 0; }
.figure-num.is-manual { font-size: var(--text-2xl); line-height: 1.25; }
.equip-qty { overflow-wrap: anywhere; }

/* ============ HERO ============ */
.hero { padding: var(--sp-6) 0 var(--sp-5); border-bottom: var(--line); }
.eyebrow {
  font-size: var(--text-xs); text-transform: uppercase; letter-spacing: 0.12em;
  color: var(--ink-3); font-weight: 700; margin-bottom: var(--sp-3);
}
.hero h1 { max-width: 28ch; font-size: var(--text-xl); margin-bottom: var(--sp-3); }
.lede { max-width: 68ch; font-size: var(--text-md); color: var(--ink-2); }

.hero-facts {
  list-style: none; margin: var(--sp-6) 0 0; padding: 0;
  display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 0;
  border: var(--line); background: #fff;
}
.hero-facts li {
  padding: var(--sp-4) var(--sp-4);
  border-right: var(--line);
  font-size: var(--text-sm); color: var(--ink-2);
}
.hero-facts li:last-child { border-right: 0; }
.hero-facts strong {
  display: block; font-size: var(--text-xs); text-transform: uppercase;
  letter-spacing: 0.1em; color: var(--blue-dark); margin-bottom: var(--sp-1);
}

/* ============ SECCIONES ============ */
.calc-section, .lead-section, .prose-section, .tables-section, .faq-section, .cred-section {
  padding: var(--sp-8) 0;
  border-bottom: var(--line);
}
.section-title {
  font-size: var(--text-xl);
  padding-bottom: var(--sp-3);
  margin-bottom: var(--sp-5);
  border-bottom: 2px solid var(--ink);
  display: inline-block;
}
.section-lede { max-width: 72ch; color: var(--ink-2); margin-bottom: var(--sp-6); }
.prose-section p, .prose-section li { max-width: 78ch; }

/* ============ PANELES ============ */
.panel { background: #fff; border: var(--line-strong); border-radius: var(--radius); }

.calc-shell {
  display: grid;
  grid-template-columns: minmax(0, 0.92fr) minmax(0, 1.08fr);
  gap: var(--sp-5);
  align-items: start;
}

/* ============ CONTROLES ============ */
.controls { padding: var(--sp-5); }

.field-group { border: 0; padding: 0; margin: 0 0 var(--sp-5); }
.field-group legend {
  padding: 0; font-size: var(--text-xs); font-weight: 700;
  text-transform: uppercase; letter-spacing: 0.1em; color: var(--ink-3);
  margin-bottom: var(--sp-2);
}

.segmented { display: grid; grid-template-columns: 1fr 1fr; border: 1px solid var(--ink); border-radius: var(--radius); overflow: hidden; }
.seg-option { position: relative; }
.seg-option input { position: absolute; opacity: 0; inset: 0; width: 100%; height: 100%; cursor: pointer; }
.seg-option span {
  display: block; text-align: center; padding: var(--sp-3) var(--sp-2);
  font-size: var(--text-sm); font-weight: 700; color: var(--ink-2);
  background: var(--paper-2); transition: background .15s ease, color .15s ease;
  cursor: pointer;
}
.seg-option + .seg-option span { border-left: 1px solid var(--ink); }
.seg-option input:checked + span { background: var(--ink); color: #fff; }
.seg-option input:focus-visible + span { outline: 2px solid var(--blue); outline-offset: -3px; }

.field { margin-bottom: var(--sp-5); }
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: var(--sp-4); }
.field label, .check span {
  display: block; font-size: var(--text-sm); font-weight: 700; color: var(--ink);
  margin-bottom: var(--sp-2);
}
.field label .opt { font-weight: 500; color: var(--ink-3); }

input[type="number"], input[type="text"], input[type="email"], input[type="tel"], select {
  width: 100%;
  font-family: var(--font);
  font-size: var(--text-base);
  color: var(--ink);
  background: var(--paper);
  border: 1px solid var(--concrete-2);
  border-radius: var(--radius);
  padding: 10px var(--sp-3);
  min-height: 44px;
  transition: border-color .15s ease, background .15s ease;
}
input::placeholder { color: var(--ink-3); opacity: 1; }
input:hover, select:hover { border-color: var(--stone); }
input:focus, select:focus { background: #fff; border-color: var(--blue); }
select {
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1.5 6 6.5l5-5' fill='none' stroke='%236B665D' stroke-width='1.6'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right var(--sp-3) center;
  padding-right: var(--sp-6);
}

.input-suffix { display: flex; align-items: stretch; }
.input-suffix input { border-radius: var(--radius) 0 0 var(--radius); }
.input-suffix span {
  display: flex; align-items: center; padding: 0 var(--sp-3);
  border: 1px solid var(--concrete-2); border-left: 0; border-radius: 0 var(--radius) var(--radius) 0;
  background: var(--concrete); font-size: var(--text-sm); color: var(--ink-3); white-space: nowrap;
}

.hint { font-size: var(--text-xs); color: var(--ink-3); margin: var(--sp-2) 0 0; line-height: 1.5; }
.error {
  font-size: var(--text-xs); font-weight: 700; color: var(--red);
  margin: var(--sp-2) 0 0; padding-left: var(--sp-3);
  border-left: 2px solid var(--red);
}
.field.has-error input, .field.has-error select { border-color: var(--red); background: var(--red-tint); }
.field.is-valid input { border-color: var(--green); }

.check { display: flex; align-items: flex-start; gap: var(--sp-3); margin-bottom: var(--sp-4); cursor: pointer; }
.check input[type="checkbox"] {
  flex: 0 0 18px; width: 18px; height: 18px; margin: 3px 0 0;
  accent-color: var(--blue); cursor: pointer;
}
.check span { margin: 0; font-weight: 500; font-size: var(--text-sm); color: var(--ink-2); }

.mode-fields[hidden] { display: none; }

.actions {
  display: flex; gap: var(--sp-3); flex-wrap: wrap;
  margin-top: var(--sp-5); padding-top: var(--sp-5); border-top: var(--line);
}

/* ============ BOTONES ============ */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  font-family: var(--font); font-size: var(--text-sm); font-weight: 700;
  letter-spacing: 0.01em; padding: 12px var(--sp-5); min-height: 46px;
  border-radius: var(--radius); border: 1px solid transparent;
  cursor: pointer; text-decoration: none; text-align: center;
  transition: background .15s ease, color .15s ease, border-color .15s ease;
}
.btn-primary { background: var(--blue); color: #fff; }
.btn-primary:hover { background: var(--blue-dark); color: #fff; }
.btn-ghost { background: transparent; color: var(--ink-2); border-color: var(--concrete-2); }
.btn-ghost:hover { background: var(--paper-2); color: var(--ink); border-color: var(--stone); }
.btn-accent { background: var(--ink); color: #fff; }
.btn-accent:hover { background: var(--ink-2); color: #fff; }

/* ============ RESULTADOS ============ */
.results { padding: var(--sp-5); }

.empty-state {
  text-align: left; color: var(--ink-2);
  border: 1px dashed var(--concrete-2); border-radius: var(--radius);
  padding: var(--sp-6) var(--sp-5); background: var(--paper);
}
.empty-mark { color: var(--stone); margin-bottom: var(--sp-4); display: block; }
.empty-state h3 { color: var(--ink); }
.empty-state p { max-width: 52ch; font-size: var(--text-sm); }
.empty-foot {
  margin-top: var(--sp-4); padding-top: var(--sp-3); border-top: var(--line);
  font-size: var(--text-xs); color: var(--ink-3);
}

.result-head { border-bottom: 2px solid var(--ink); padding-bottom: var(--sp-4); margin-bottom: var(--sp-5); }
.result-kicker {
  font-size: var(--text-xs); text-transform: uppercase; letter-spacing: 0.12em;
  color: var(--ink-3); font-weight: 700; margin-bottom: var(--sp-2);
}
.figure { display: flex; align-items: baseline; gap: var(--sp-3); flex-wrap: wrap; }
.figure-num {
  font-size: clamp(3rem, 8vw, 4.25rem); font-weight: 900; line-height: 0.95;
  letter-spacing: -0.04em; color: var(--ink);
}
.figure-unit { font-size: var(--text-sm); font-weight: 700; text-transform: uppercase; letter-spacing: 0.08em; color: var(--blue-dark); }
.result-sub { font-size: var(--text-sm); color: var(--ink-2); margin: var(--sp-3) 0 0; }

.result-block { padding-bottom: var(--sp-5); margin-bottom: var(--sp-5); border-bottom: var(--line); }
.result-block h3 {
  font-size: var(--text-xs); text-transform: uppercase; letter-spacing: 0.1em;
  color: var(--ink-3); margin-bottom: var(--sp-3);
}
.strong-line { font-weight: 700; font-size: var(--text-md); color: var(--ink); margin-bottom: var(--sp-3); }
.small { font-size: var(--text-xs); color: var(--ink-3); line-height: 1.6; }

.equip-list { list-style: none; margin: 0; padding: 0; }
.equip-list li {
  display: grid; grid-template-columns: 56px minmax(0, 1fr);
  gap: var(--sp-3); align-items: baseline;
  padding: var(--sp-3) 0; border-bottom: var(--line);
}
.equip-list li:last-child { border-bottom: 0; }
.equip-qty {
  font-size: var(--text-lg); font-weight: 900; color: var(--blue-dark);
  text-align: right; line-height: 1.2;
}
.equip-name { font-weight: 700; font-size: var(--text-base); overflow-wrap: anywhere; }
.equip-note { display: block; font-weight: 500; font-size: var(--text-xs); color: var(--ink-3); margin-top: 2px; }
.equip-list li.equip-pending { grid-template-columns: 1fr; gap: var(--sp-1); }
.equip-pending .equip-qty { text-align: left; font-size: var(--text-sm); }

.tick-list { margin: 0; padding: 0; list-style: none; }
.tick-list li {
  position: relative; padding-left: var(--sp-5); margin-bottom: var(--sp-2);
  font-size: var(--text-sm); color: var(--ink-2);
}
.tick-list li::before {
  content: ""; position: absolute; left: 0; top: 8px;
  width: 8px; height: 8px; border: 1px solid var(--blue); background: var(--blue-tint);
}

/* Memoria de cálculo */
.memoria {
  border: 1px solid var(--concrete-2); border-radius: var(--radius);
  background: var(--paper); margin-bottom: var(--sp-5);
}
.memoria > summary {
  cursor: pointer; padding: var(--sp-3) var(--sp-4);
  font-size: var(--text-sm); font-weight: 700; color: var(--ink);
  list-style: none; display: flex; align-items: center; gap: var(--sp-3);
}
.memoria > summary::-webkit-details-marker { display: none; }
.memoria > summary::before {
  content: "+"; flex: 0 0 20px; width: 20px; height: 20px;
  display: inline-flex; align-items: center; justify-content: center;
  border: 1px solid var(--stone); color: var(--ink-2); font-weight: 700; line-height: 1;
}
.memoria[open] > summary::before { content: "−"; }
.memoria[open] > summary { border-bottom: var(--line); }
.memoria-body { padding: var(--sp-4); }
.memoria-pasos { margin: 0 0 var(--sp-3); padding-left: var(--sp-5); }
.memoria-pasos li { font-size: var(--text-sm); color: var(--ink-2); margin-bottom: var(--sp-2); overflow-wrap: anywhere; }
.memoria-pasos code {
  font-family: var(--font); font-weight: 700; color: var(--ink);
  background: var(--concrete); padding: 1px 5px; border-radius: 2px;
  font-variant-numeric: tabular-nums;
}

/* Avisos */
.notice {
  border: 1px solid var(--concrete-2); border-left: 4px solid var(--stone);
  border-radius: var(--radius); padding: var(--sp-4); margin-bottom: var(--sp-4);
  font-size: var(--text-sm);
}
.notice h3 { font-size: var(--text-sm); text-transform: none; letter-spacing: 0; color: var(--ink); margin-bottom: var(--sp-2); }
.notice p { margin-bottom: var(--sp-3); }
.notice p:last-child { margin-bottom: 0; }
.notice-amber { background: var(--amber-tint); border-color: var(--amber-line); border-left-color: var(--amber); }
.notice-blue { background: var(--blue-tint); border-color: #C2D9E2; border-left-color: var(--blue); }
.notice-green { background: var(--green-tint); border-color: #C6DACE; border-left-color: var(--green); }
.notice-norma { margin-top: var(--sp-5); }

.result-actions { display: flex; gap: var(--sp-3); flex-wrap: wrap; margin: var(--sp-5) 0 var(--sp-3); }
.result-actions .btn { flex: 1 1 200px; }
.result-actions #btn-cotizar { flex-grow: 2; }
.result-actions #btn-imprimir { flex-basis: 130px; }
.review-note { padding: var(--sp-3) var(--sp-4); border-left: 3px solid var(--blue); background: var(--blue-tint); font-size: var(--text-sm); color: var(--ink-2); }
#memoria { margin-top: var(--sp-5); }
.expertise-section { padding: var(--sp-6) 0; background: #fff; border-top: var(--line); }
.expertise-inner { display: flex; align-items: center; gap: var(--sp-6); justify-content: space-between; }
.expertise-inner > div { max-width: 72ch; }
.expertise-inner h2 { font-size: var(--text-lg); margin-bottom: var(--sp-3); }
.expertise-inner p { font-size: var(--text-sm); color: var(--ink-2); margin: 0; }
.expertise-inner .btn { flex-shrink: 0; }

.js-warning { display: none; }
.no-js .js-warning { display: block; }
.no-js .calc-shell { display: none; }

/* ============ FORMULARIO DE LEAD ============ */
.lead-panel { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 0; }
.lead-copy { padding: var(--sp-6); background: var(--paper-2); border-right: var(--line); }
.lead-copy .section-title { margin-top: 0; }
.lead-form { padding: var(--sp-6); }
.demo-flag {
  display: inline-block; font-size: var(--text-xs); font-weight: 700;
  background: var(--amber-tint); border: 1px solid var(--amber-line);
  border-left: 3px solid var(--amber);
  padding: var(--sp-2) var(--sp-3); border-radius: var(--radius); color: var(--ink-2);
}
.lead-ok {
  margin-top: var(--sp-4); font-size: var(--text-sm);
  background: var(--green-tint); border: 1px solid #C6DACE; border-left: 3px solid var(--green);
  padding: var(--sp-3) var(--sp-4); border-radius: var(--radius); color: var(--ink-2);
}
.lead-form .btn { width: 100%; }

/* ============ METODOLOGÍA ============ */
.prose-section h3 { margin-top: var(--sp-6); font-size: var(--text-lg); }
.method-list { margin: 0 0 var(--sp-5); padding-left: 0; list-style: none; counter-reset: m; }
.method-list li {
  counter-increment: m; position: relative; padding-left: var(--sp-7);
  margin-bottom: var(--sp-4); color: var(--ink-2);
}
.method-list li::before {
  content: counter(m, decimal-leading-zero);
  position: absolute; left: 0; top: 0;
  font-size: var(--text-xs); font-weight: 900; color: var(--blue-dark);
  font-variant-numeric: tabular-nums;
  border: 1px solid var(--concrete-2); background: #fff;
  width: 30px; height: 24px; display: inline-flex; align-items: center; justify-content: center;
}
.disclaimer-line {
  border-top: var(--line); padding-top: var(--sp-4);
  font-size: var(--text-sm); color: var(--ink-3); max-width: 78ch;
}

.numerales { margin: 0 0 var(--sp-5); }
.numerales dt {
  font-weight: 900; font-size: var(--text-sm); text-transform: uppercase;
  letter-spacing: 0.06em; color: var(--blue-dark); margin-bottom: var(--sp-2);
}
.numerales dd {
  margin: 0 0 var(--sp-4); padding-left: var(--sp-4);
  border-left: 2px solid var(--concrete-2); color: var(--ink-2); max-width: 78ch;
}
.norma-section { background: var(--paper-2); }

/* ============ TABLAS ============ */
.tables-section h3 { font-size: var(--text-lg); margin-top: var(--sp-7); }
.tables-section h3:first-of-type { margin-top: 0; }
.table-note { font-size: var(--text-sm); color: var(--ink-3); margin-bottom: var(--sp-3); }
.table-scroll { overflow-x: auto; border: var(--line-strong); border-radius: var(--radius); background: #fff; }
.table-scroll:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }

/* Indicador de deslizamiento: solo en pantallas donde la tabla no cabe completa */
.scroll-hint { display: none; }
@media (max-width: 700px) {
  .scroll-hint {
    display: flex; align-items: center; gap: 0.4em;
    font-size: var(--text-xs); color: var(--ink-3);
    margin: 0 0 0.5rem;
  }
  .scroll-hint::after { content: "\2192"; font-size: 1.1em; }
}
.ref-table { width: 100%; border-collapse: collapse; font-size: var(--text-sm); min-width: 460px; }
.ref-table thead th {
  background: var(--ink); color: #fff; text-align: left;
  font-size: var(--text-xs); text-transform: uppercase; letter-spacing: 0.08em;
  padding: var(--sp-3) var(--sp-4); font-weight: 700; white-space: nowrap;
}
.ref-table tbody th, .ref-table tbody td {
  padding: var(--sp-3) var(--sp-4); border-bottom: var(--line); text-align: left;
}
.ref-table tbody th { font-weight: 700; background: var(--paper-2); white-space: nowrap; }
.ref-table tbody td { color: var(--ink-2); }
.ref-table tbody tr:last-child th, .ref-table tbody tr:last-child td { border-bottom: 0; }
.ref-table tbody tr:last-child { background: var(--blue-tint); }
.ref-table tbody tr:last-child th { background: var(--blue-tint); }
.table-source { font-size: var(--text-xs); color: var(--ink-3); margin-top: var(--sp-3); max-width: 84ch; line-height: 1.65; }

/* ============ FAQ ============ */
.faq-list { border-top: var(--line-strong); max-width: 900px; }
.faq-item { border-bottom: var(--line); background: transparent; }
.faq-item > summary {
  cursor: pointer; list-style: none; padding: var(--sp-4) var(--sp-6) var(--sp-4) 0;
  position: relative;
}
.faq-item > summary::-webkit-details-marker { display: none; }
.faq-item > summary h3 { margin: 0; font-size: var(--text-md); font-weight: 700; display: inline; }
.faq-item > summary::after {
  content: "+"; position: absolute; right: 0; top: var(--sp-4);
  font-size: var(--text-lg); font-weight: 700; color: var(--blue-dark); line-height: 1.2;
}
.faq-item[open] > summary::after { content: "−"; }
.faq-item[open] > summary h3 { color: var(--blue-dark); }
.faq-answer { padding: 0 var(--sp-6) var(--sp-5) 0; }
.faq-answer p { color: var(--ink-2); max-width: 78ch; margin: 0; }

/* ============ CREDIBILIDAD ============ */
.cred-grid { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr); gap: var(--sp-7); }
.cred-col p { color: var(--ink-2); max-width: 60ch; }
.cred-col h3 { font-size: var(--text-xs); text-transform: uppercase; letter-spacing: 0.1em; color: var(--ink-3); }
.catalog-list { list-style: none; margin: 0; padding: 0; border-top: var(--line); }
.catalog-list li { padding: var(--sp-3) 0; border-bottom: var(--line); font-size: var(--text-sm); color: var(--ink-3); }
.catalog-list li strong { color: var(--ink); }
.inline-cta { font-weight: 700; }

/* ============ FOOTER ============ */
.site-footer { background: var(--ink); color: var(--concrete); padding: var(--sp-7) 0 var(--sp-6); }
.site-footer a { color: #9FCBDA; }
.site-footer a:hover { color: #fff; }
.footer-disclaimer { font-size: var(--text-sm); max-width: 84ch; color: var(--concrete-2); }
.footer-disclaimer strong { color: #fff; }
.footer-meta {
  display: flex; justify-content: space-between; gap: var(--sp-4); flex-wrap: wrap;
  margin-top: var(--sp-5); padding-top: var(--sp-4); border-top: 1px solid #3D3A35;
  font-size: var(--text-xs); color: var(--concrete-2);
}
.footer-credit { letter-spacing: 0.04em; }

/* ============ RESPONSIVE ============ */
@media (max-width: 1000px) {
  .calc-shell { grid-template-columns: 1fr; }
  .lead-panel { grid-template-columns: 1fr; }
  .lead-copy { border-right: 0; border-bottom: var(--line); }
  .cred-grid { grid-template-columns: 1fr; gap: var(--sp-6); }
}

@media (max-width: 860px) {
  .header-nav { gap: var(--sp-4); }
  .header-nav a { font-size: var(--text-xs); }
  .hero-facts { grid-template-columns: 1fr; }
  .hero-facts li { border-right: 0; border-bottom: var(--line); }
  .hero-facts li:last-child { border-bottom: 0; }
}

@media (max-width: 640px) {
  .expertise-inner { flex-direction: column; align-items: stretch; }
  :root { --text-3xl: 1.9375rem; --text-2xl: 1.5rem; --text-xl: 1.25rem; }
  .wrap { padding: 0 var(--sp-4); }
  .header-inner { padding-top: var(--sp-4); padding-bottom: var(--sp-4); }
  .hero { padding: var(--sp-6) 0; }
  .hero h1 { max-width: none; }
  .calc-section, .lead-section, .prose-section, .tables-section, .faq-section, .cred-section { padding: var(--sp-6) 0; }
  .controls, .results { padding: var(--sp-4); }
  .lead-copy, .lead-form { padding: var(--sp-4); }
  .field-row { grid-template-columns: 1fr; gap: 0; }
  .figure-num { font-size: 3.25rem; }
  .equip-list li { grid-template-columns: 46px minmax(0, 1fr); }
  .result-actions .btn, .actions .btn { flex: 1 1 100%; width: 100%; }
  .method-list li { padding-left: var(--sp-6); }
  .footer-meta { flex-direction: column; gap: var(--sp-2); }
  .seg-option span { font-size: var(--text-xs); padding: var(--sp-3) var(--sp-1); }
  body::before { background-size: 40px 40px; }
}

/* =========================================================
   IMPRESIÓN — ficha de dimensionamiento en papel
   ========================================================= */
@media print {
  @page { size: letter portrait; margin: 14mm 14mm 16mm; }

  html, body { background: #fff !important; color: #000; font-size: 10.5pt; line-height: 1.45; }
  body::before { display: none !important; }

  /* Ocultar todo lo que no es la ficha */
  .site-header, .header-nav, .skip-link, .hero-facts,
  .lead-section, .prose-section, .tables-section, .faq-section, .cred-section,
  .actions, .result-actions, .print-hide, .js-warning, noscript,
  .empty-state, .controls .hint, .controls .error { display: none !important; }

  main > section { border: 0 !important; padding: 0 !important; }
  .wrap { max-width: none; padding: 0; }

  /* Encabezado impreso con logo */
  .hero { padding: 0 0 6mm !important; border-bottom: 1.5pt solid #000 !important; }
  .print-brand { display: block; width: 180px; height: auto; margin-bottom: 3mm; }
  .hero::after {
    content: "Sanirey · Renta de sanitarios portátiles · Monterrey, Nuevo León · sanirey.com.mx";
    display: block; font-size: 8pt; color: #444; margin-top: 2mm;
  }
  .eyebrow { font-size: 8pt; letter-spacing: 0.08em; margin-bottom: 2mm; }
  .hero h1 { font-size: 17pt; max-width: none; margin-bottom: 2mm; }
  .lede { font-size: 9pt; color: #333; max-width: none; }
  .lede a { color: #000; text-decoration: none; }

  /* La calculadora impresa = solo el panel de resultados */
  .calc-section .section-title { display: none !important; }
  .calc-shell { display: block !important; }
  .controls { display: none !important; }
  .panel.results { border: 0 !important; padding: 6mm 0 0 !important; background: #fff !important; }

  .result-head { border-bottom: 1pt solid #000 !important; padding-bottom: 3mm; margin-bottom: 4mm; }
  .result-kicker { font-size: 8pt; }
  .figure-num { font-size: 32pt !important; color: #000; }
  .figure-unit { font-size: 9pt; color: #000; }
  .result-sub { font-size: 9pt; color: #222; }

  .result-block { break-inside: avoid; page-break-inside: avoid; padding-bottom: 4mm; margin-bottom: 4mm; border-bottom: 0.5pt solid #bbb !important; }
  .result-block h3 { font-size: 8.5pt; color: #000; letter-spacing: 0.08em; }
  .equip-list li { border-bottom: 0.5pt dotted #bbb !important; padding: 1.5mm 0; grid-template-columns: 50px 1fr; }
  .equip-qty { font-size: 12pt; color: #000; }
  .equip-name { font-size: 10pt; }
  .tick-list li { font-size: 9pt; color: #222; }
  .tick-list li::before { border-color: #000; background: #fff; }
  .small { font-size: 8pt; color: #333; }
  .strong-line { font-size: 11pt; }

  /* Memoria de cálculo siempre expandida al imprimir */
  .memoria { border: 0.75pt solid #999 !important; background: #fff !important; break-inside: avoid; }
  .memoria > summary { padding: 2mm 3mm; font-size: 9pt; border-bottom: 0.5pt solid #ccc !important; }
  .memoria > summary::before { display: none !important; }
  .memoria .memoria-body { display: block !important; padding: 3mm; }
  .memoria-pasos li { font-size: 8.5pt; color: #222; }
  .memoria-pasos code { background: #eee; }

  .notice {
    border: 0.75pt solid #666 !important; border-left: 2pt solid #000 !important;
    background: #fff !important; padding: 3mm; font-size: 8.5pt; break-inside: avoid;
  }
  .notice h3 { font-size: 9pt; }
  .notice a { color: #000; }

  /* Pie impreso */
  .site-footer { background: #fff !important; color: #000 !important; padding: 4mm 0 0 !important; border-top: 1pt solid #000; break-inside: avoid; }
  .site-footer a { color: #000; text-decoration: none; }
  .footer-disclaimer { font-size: 8pt; color: #222; max-width: none; }
  .footer-disclaimer strong { color: #000; }
  .footer-meta { margin-top: 3mm; padding-top: 2mm; border-top: 0.5pt solid #999; font-size: 7.5pt; color: #444; }

  a[href^="http"]::after { content: ""; }
}
