:root {
  --ink: #0f172a;
  --ink-soft: #1e293b;
  --text: #0f172a;
  --muted: #475569;
  --line: #e2e8f0;
  --bg: #f8fafc;
  --white: #ffffff;
  --amber: #f59e0b;
  --amber-deep: #d97706;
  --amber-ink: #92400e;
  --on-dark: #fde68a;
  --ok: #047857;
  --danger: #991b1b;
  --shadow: 0 18px 40px rgba(15, 23, 42, 0.16);
  --radius: 18px;
  --max: 1120px;
  --font: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}

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

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--font);
  color: var(--text);
  background: var(--bg);
  line-height: 1.6;
  font-size: 1.02rem;
}

img, svg { max-width: 100%; }

[hidden] { display: none !important; }

h1, h2, h3, p { overflow-wrap: anywhere; }

h1, h2, h3 {
  line-height: 1.2;
  font-weight: 700;
  letter-spacing: -0.02em;
}

h1 { font-size: clamp(1.9rem, 4.4vw, 3.15rem); margin: 0 0 0.6rem; }
h2 { font-size: clamp(1.45rem, 2.4vw, 2rem); margin: 0 0 0.75rem; }
h3 { font-size: 1.12rem; margin: 0 0 0.45rem; }

p { margin: 0 0 0.8rem; }

a { color: var(--amber-ink); }

a:hover { color: #7c2d12; }

:focus-visible {
  outline: 3px solid #9a3412;
  outline-offset: 3px;
}

.skip {
  position: absolute;
  left: 12px;
  top: -40px;
  background: var(--amber);
  color: var(--ink);
  padding: 8px 12px;
  z-index: 20;
}

.skip:focus { top: 12px; }

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  border: 0;
}

.wrap {
  width: min(var(--max), calc(100% - 32px));
  margin-inline: auto;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 30;
  background: var(--ink);
  color: #e2e8f0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.header-bar {
  min-height: 72px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  position: relative;
}

.logo {
  display: flex;
  gap: 10px;
  align-items: center;
  color: white;
  text-decoration: none;
}

.logo-mark {
  width: 44px;
  height: 44px;
  object-fit: contain;
  border-radius: 10px;
  background: white;
  flex: none;
}

.logo strong { display: block; font-size: 1rem; letter-spacing: 0; }
.logo small { display: block; color: #cbd5e1; font-size: 0.75rem; }

.nav-toggle {
  display: inline-flex;
  background: transparent;
  color: white;
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 10px;
  min-width: 44px;
  min-height: 44px;
  align-items: center;
  justify-content: center;
}

.nav {
  display: none;
  position: absolute;
  top: calc(100% + 1px);
  left: 0;
  right: 0;
  background: var(--ink-soft);
  padding: 12px 16px 16px;
  flex-direction: column;
  gap: 4px;
}

.nav.is-open { display: flex; }

.nav a {
  color: #e2e8f0;
  text-decoration: none;
  padding: 10px 8px;
  border-radius: 8px;
}

.nav a[aria-current="page"] { color: var(--on-dark); }

.nav .btn { margin-top: 8px; text-align: center; }

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 48px;
  padding: 0 18px;
  border-radius: 999px;
  border: 1px solid transparent;
  font: inherit;
  font-weight: 700;
  text-decoration: none;
  cursor: pointer;
}

.btn-amber {
  background: var(--amber);
  color: var(--ink);
}

.btn-amber:hover { background: var(--amber-deep); color: var(--ink); }

.btn-ghost {
  background: transparent;
  color: var(--ink);
  border-color: var(--line);
}

.site-header .btn-ghost,
.hero .btn-ghost { color: white; border-color: rgba(255, 255, 255, 0.3); }

.btn-small { min-height: 42px; padding: 0 14px; font-size: 0.95rem; }

.btn[disabled] { opacity: 0.6; cursor: wait; }

.hero {
  background:
    radial-gradient(circle at 100% -10%, rgba(245, 158, 11, 0.18), transparent 42%),
    linear-gradient(180deg, #0f172a 0%, #1e293b 100%);
  color: #e2e8f0;
  padding: 20px 0 40px;
  position: relative;
  overflow: hidden;
}

.hero-photo {
  background: #0f172a;
  min-height: min(92vh, 820px);
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding-top: 28px;
}

.hero-media {
  position: absolute;
  inset: 0;
  z-index: 0;
}

.hero-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 35%;
}

/*
  Foto visible a la derecha; oscurece solo la franja del copy (sin caja/card).
  El formulario blanco ya aporta contraste propio.
*/
.hero-media::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(105deg,
      rgba(15, 23, 42, 0.9) 0%,
      rgba(15, 23, 42, 0.82) 28%,
      rgba(15, 23, 42, 0.45) 48%,
      rgba(15, 23, 42, 0.18) 68%,
      rgba(15, 23, 42, 0.12) 100%);
  pointer-events: none;
}

.hero-photo .hero-copy {
  max-width: 62ch;
  padding: 8px 12px 8px 0;
  text-shadow: 0 1px 18px rgba(15, 23, 42, 0.85), 0 1px 2px rgba(15, 23, 42, 0.9);
}

.hero-photo .hero-copy .lead,
.hero-photo .hero-copy .checks li {
  color: #e8eef7;
}

.hero-photo .eyebrow {
  color: #fbbf24;
}

.hero:not(.hero-photo)::before,
.hero:not(.hero-photo)::after {
  content: "";
  position: absolute;
  border: 1px solid rgba(245, 158, 11, 0.28);
  border-radius: 50%;
  pointer-events: none;
}

.hero:not(.hero-photo)::before { width: 340px; height: 340px; right: -120px; top: -140px; }
.hero:not(.hero-photo)::after { width: 180px; height: 180px; right: 40px; top: 80px; }

.hero-grid { position: relative; z-index: 1; display: grid; gap: 28px; }

.hero h1, .hero h2 { color: white; }

.eyebrow {
  margin: 0 0 8px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--amber-ink);
}

.hero .eyebrow, .site-footer .eyebrow { color: var(--on-dark); }

.lead, .section-lead { font-size: 1.05rem; }
.hero .lead { color: #e2e8f0; max-width: 62ch; }

.badges, .checks { list-style: none; padding: 0; margin: 0 0 16px; }

.badges { display: flex; flex-wrap: wrap; gap: 8px; }

.badges li {
  border: 1px solid rgba(253, 230, 138, 0.45);
  color: var(--on-dark);
  border-radius: 999px;
  padding: 6px 10px;
  font-size: 0.86rem;
  font-weight: 700;
}

.checks li { padding-left: 1.3rem; position: relative; margin: 0 0 6px; }
.checks li::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: var(--amber); position: absolute; left: 0; top: 0.55rem; }

.crumbs ol { display: flex; flex-wrap: wrap; gap: 8px; list-style: none; padding: 0; margin: 0 0 18px; font-size: 0.92rem; }
.crumbs a { color: white; }
.crumbs li:not(:last-child)::after { content: "/"; margin-left: 8px; color: #94a3b8; }
.crumbs [aria-current="page"] { color: var(--on-dark); }

.wizard {
  background:
    linear-gradient(180deg, #fffbeb 0%, #ffffff 72px),
    var(--white);
  color: var(--ink);
  border: 1px solid #f1e7d2;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 22px 18px 20px;
}

.wizard-head {
  padding-bottom: 14px;
  margin-bottom: 4px;
  border-bottom: 1px solid #f1e7d2;
}

.wizard h2 {
  color: var(--ink);
  font-size: 1.4rem;
  margin-bottom: 12px;
}

.wizard .eyebrow {
  color: var(--amber-ink);
  margin-bottom: 4px;
}

.wizard-status { color: var(--muted); font-size: 0.92rem; }

.dots { display: flex; gap: 6px; padding: 0; margin: 0 0 12px; list-style: none; }
.dots li { width: 28px; height: 4px; border-radius: 99px; background: #e2e8f0; }
.dots li.is-on { background: var(--amber-deep); }

.steps-bar {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
  padding: 0;
  margin: 0;
  list-style: none;
}

.steps-bar li {
  display: flex;
  align-items: center;
  gap: 8px;
  min-height: 46px;
  padding: 8px 10px;
  border-radius: 12px;
  border: 2px solid #cbd5e1;
  background: white;
  color: #334155;
  font-weight: 800;
  font-size: 0.9rem;
  transition: border-color 0.15s ease, background 0.15s ease, color 0.15s ease, box-shadow 0.15s ease;
}

.steps-num {
  display: grid;
  place-items: center;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  flex: none;
  background: #0f172a;
  color: #fde68a;
  font-size: 0.86rem;
  font-weight: 800;
}

.steps-label { line-height: 1.1; }

.steps-bar li.is-on {
  border-color: var(--amber-deep);
  background: #fffbeb;
  color: var(--amber-ink);
  box-shadow: 0 0 0 3px rgba(245, 158, 11, 0.22);
}

.steps-bar li.is-on .steps-num {
  background: var(--amber);
  color: var(--ink);
}

.steps-bar li.is-done {
  border-color: #f59e0b;
  background: #fff7ed;
  color: var(--amber-ink);
}

.steps-bar li.is-done .steps-num {
  background: var(--amber-deep);
  color: white;
}

.steps-bar li.is-done .steps-num::after {
  content: "";
}

.wizard fieldset:not([hidden]) {
  animation: wizard-step-in 150ms ease-out;
}

@keyframes wizard-step-in {
  from {
    opacity: 0;
    transform: translateY(6px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.wizard legend {
  font-size: 1.15rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  margin-bottom: 6px;
}

.wizard .micro {
  color: var(--muted);
  font-size: 0.92rem;
  line-height: 1.45;
  margin: 0 0 14px;
}

.wizard .field {
  font-weight: 600;
  margin-bottom: 14px;
}

.wizard .field-label {
  font-weight: 600;
  color: var(--ink-soft);
  margin: 16px 0 10px;
}

.wizard input:not([type="radio"]):not([type="checkbox"]),
.wizard select {
  min-height: 52px;
  background: #f8fafc;
  border: 1.5px solid #cbd5e1;
  border-radius: 14px;
  padding: 12px 14px;
  transition: border-color 0.15s ease, background 0.15s ease, box-shadow 0.15s ease;
}

.wizard input:not([type="radio"]):not([type="checkbox"]):focus,
.wizard select:focus {
  outline: none;
  background: white;
  border-color: var(--amber-deep);
  box-shadow: 0 0 0 3px rgba(245, 158, 11, 0.2);
}

.hero .h1-accent,
.h1-accent {
  color: #fbbf24;
  display: inline;
  font-weight: 800;
  letter-spacing: -0.01em;
  text-shadow: 0 0 32px rgba(245, 158, 11, 0.45);
}

.hero-photo .h1-accent {
  color: #fbbf24;
  box-decoration-break: clone;
  -webkit-box-decoration-break: clone;
  background: linear-gradient(180deg, transparent 58%, rgba(245, 158, 11, 0.42) 58%);
  padding: 0 0.08em;
}

fieldset { border: 0; margin: 0; padding: 0; min-inline-size: 0; }
legend { font-weight: 700; margin-bottom: 10px; }

.field, .filters label, .login-form .field { display: grid; gap: 6px; font-weight: 700; margin-bottom: 12px; }
.field-label { font-weight: 700; margin: 12px 0 8px; }
.optional { font-weight: 500; color: var(--muted); }

input, select, textarea {
  width: 100%;
  font: inherit;
  color: var(--ink);
  background: white;
  border: 1px solid #cbd5e1;
  border-radius: 12px;
  min-height: 48px;
  padding: 10px 12px;
}

textarea { min-height: 72px; resize: vertical; }
::placeholder { color: #64748b; opacity: 1; }

.choices { display: grid; gap: 10px; }

.choice {
  position: relative;
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 10px;
  align-items: center;
  min-height: 52px;
  border: 1.5px solid #dbe3ef;
  border-radius: 14px;
  padding: 12px 14px;
  background: white;
  cursor: pointer;
  transition: border-color 0.15s ease, background 0.15s ease, box-shadow 0.15s ease, transform 0.15s ease;
}

.choice:hover {
  border-color: #f59e0b;
  box-shadow: 0 6px 16px rgba(15, 23, 42, 0.06);
}

.choice:has(input:checked) {
  border-color: var(--amber-deep);
  border-width: 2px;
  background: #fffbeb;
  box-shadow: 0 0 0 3px rgba(245, 158, 11, 0.14);
  padding: 11.5px 13.5px;
}

.choice:has(input:checked)::after {
  content: "";
  width: 22px;
  height: 22px;
  border-radius: 50%;
  flex: none;
  background:
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='none'%3E%3Cpath d='M3.5 8.2l3 3 6-6' stroke='%230f172a' stroke-width='2.2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center / 12px no-repeat,
    var(--amber);
  box-shadow: inset 0 0 0 1px rgba(146, 64, 14, 0.15);
}

.choice input {
  position: absolute;
  opacity: 0;
  width: 1px;
  height: 1px;
  margin: 0;
  pointer-events: none;
}

.choice:has(input:focus-visible) {
  outline: 3px solid #9a3412;
  outline-offset: 2px;
}

.choice span { font-weight: 600; }

.wizard-actions {
  display: flex;
  gap: 10px;
  align-items: center;
  margin-top: 16px;
}

.wizard-actions [data-next],
.wizard-actions [data-send] {
  flex: 1;
  min-height: 52px;
  box-shadow: 0 10px 22px rgba(217, 119, 6, 0.28);
}

.wizard-actions [data-back] {
  flex: none;
  min-width: auto;
  min-height: 44px;
  padding: 0 12px;
  border: 0;
  background: transparent;
  color: var(--muted);
  box-shadow: none;
}

.wizard-actions [data-back]:hover {
  color: var(--ink);
  background: #f8fafc;
}

.fine { color: var(--muted); font-size: 0.88rem; margin: 10px 0 0; }

.wizard .fine {
  font-size: 0.86rem;
  margin: 12px 0 0;
  text-align: center;
}

.wizard .fine a {
  font-weight: 700;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
}

.wizard .fine a:hover { text-decoration: underline; }

.wizard .fine a[data-wa-direct]::before {
  content: "";
  width: 14px;
  height: 14px;
  flex: none;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='%2392400e'%3E%3Cpath d='M12 2a10 10 0 0 0-8.6 14.9L2 22l5.3-1.4A10 10 0 1 0 12 2zm0 18a8 8 0 0 1-4.1-1.1l-.3-.2-3.1.8.8-3-.2-.3A8 8 0 1 1 12 20zm4.4-5.9c-.2-.1-1.4-.7-1.6-.8s-.4-.1-.5.1-.6.8-.7.9-.3.2-.5.1a6.6 6.6 0 0 1-1.9-1.2 7.2 7.2 0 0 1-1.3-1.7c-.1-.3 0-.4.1-.5l.4-.4.2-.3a.4.4 0 0 0 0-.4c0-.1-.5-1.2-.7-1.6s-.4-.4-.5-.4h-.5a1 1 0 0 0-.7.3 2.9 2.9 0 0 0-.9 2.2 5 5 0 0 0 1.1 2.6 11.4 11.4 0 0 0 4.4 3.9 15 15 0 0 0 1.5.5 3.6 3.6 0 0 0 1.6.1 2.7 2.7 0 0 0 1.8-1.2 2.2 2.2 0 0 0 .2-1.2c-.1-.1-.2-.2-.4-.3z'/%3E%3C/svg%3E") center / contain no-repeat;
}

.form-error {
  background: #fef2f2;
  color: var(--danger);
  border: 1px solid #fecaca;
  border-radius: 12px;
  padding: 10px 12px;
  margin: 0 0 10px;
}

.success { display: grid; gap: 10px; }
.success-title { font-size: 1.3rem; font-weight: 700; margin: 0; }
.hp { position: absolute; left: -9999px; height: 0; overflow: hidden; }

.section { padding: 56px 0; }
.section-alt { background: white; }
.prose { max-width: 74ch; }

.grid-3, .grid-2, .grid-comunas, .stack, .steps { display: grid; gap: 16px; }
.grid-comunas { grid-template-columns: 1fr; }

.card {
  background: white;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 18px;
}

.section-alt .card { background: var(--bg); }

.card-icon {
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  border-radius: 12px;
  background: #fffbeb;
  color: var(--amber-ink);
  margin-bottom: 10px;
}

.card h3 svg { width: 18px; height: 18px; vertical-align: -3px; color: var(--amber-ink); }

.card-link a { font-weight: 700; }
.zone-region { color: var(--muted); font-size: 0.82rem; font-weight: 700; letter-spacing: 0.04em; text-transform: uppercase; margin-bottom: 4px; }

.ticks { margin: 0; padding-left: 1.1rem; }
.ticks li { margin: 0.25rem 0; }

.note {
  margin-top: 16px;
  padding: 12px 14px;
  border-left: 4px solid var(--amber-deep);
  background: white;
  border-radius: 0 12px 12px 0;
}

.steps { list-style: none; padding: 0; counter-reset: paso; }
.steps li {
  background: white;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 16px 16px 8px 64px;
  position: relative;
}
.section-alt .steps li { background: var(--bg); }
.steps li::before {
  counter-increment: paso;
  content: counter(paso);
  position: absolute;
  left: 16px;
  top: 16px;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: var(--ink);
  color: var(--on-dark);
  font-weight: 700;
}

.faq { border-bottom: 1px solid var(--line); }
.faq summary { cursor: pointer; list-style: none; display: flex; justify-content: space-between; gap: 16px; align-items: center; padding: 14px 0; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary h3 { margin: 0; font-size: 1.05rem; }
.faq summary::after { content: "+"; color: var(--amber-ink); font-weight: 700; font-size: 1.4rem; line-height: 1; }
.faq[open] summary::after { content: "–"; }
.faq p { color: var(--muted); max-width: 74ch; }
.faq p:first-of-type { color: var(--ink); }

.cierre-local { margin-top: 18px; }

.cta-band { background: var(--ink); color: white; padding: 48px 0; }
.cta-band h2, .cta-band p { color: white; }
.cta-band p { max-width: 60ch; }

.site-footer { background: #020617; color: #cbd5e1; padding: 36px 0 18px; }
.footer-grid { display: grid; gap: 22px; }
.footer-brand, .footer-title { color: white; font-weight: 700; margin-bottom: 8px; }
.site-footer a { color: var(--on-dark); }
.site-footer ul { margin: 0; padding: 0; list-style: none; }
.site-footer li { margin: 0 0 6px; }
.footer-email { margin: 12px 0 0; font-weight: 600; }
.footer-base { margin-top: 22px; border-top: 1px solid rgba(255, 255, 255, 0.08); padding-top: 12px; font-size: 0.9rem; }

.dock {
  display: flex;
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 25;
  padding: 10px 16px calc(10px + env(safe-area-inset-bottom));
  background: rgba(248, 250, 252, 0.96);
  border-top: 1px solid var(--line);
}

.dock .btn { width: 100%; }

body.has-dock { padding-bottom: 78px; }

.link-list { padding-left: 1.1rem; }
.link-list a { font-weight: 700; }

.panel h1 { font-size: clamp(1.6rem, 3vw, 2.2rem); }
.login-card { max-width: 460px; background: white; border: 1px solid var(--line); border-radius: var(--radius); padding: 22px; }
.panel-top { display: flex; justify-content: space-between; gap: 16px; align-items: flex-start; margin-bottom: 16px; }
.kpi-grid { display: grid; gap: 12px; margin-bottom: 16px; }
.kpi { background: white; border: 1px solid var(--line); border-radius: 16px; padding: 14px; }
.kpi p { margin: 0; color: var(--muted); font-size: 0.9rem; }
.kpi strong { display: block; font-size: 1.8rem; margin-top: 4px; }
.filters { display: grid; gap: 10px; margin: 16px 0; }
.filters label { font-size: 0.92rem; }
.flash { background: #ecfdf5; color: #065f46; border-radius: 12px; padding: 10px 12px; }
.table-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: 16px; background: white; }
.leads, .breakdown { width: 100%; border-collapse: collapse; min-width: 760px; }
.breakdown { min-width: 0; }
.leads th, .leads td, .breakdown th, .breakdown td { text-align: left; vertical-align: top; padding: 12px; border-bottom: 1px solid var(--line); font-size: 0.92rem; }
.leads th, .breakdown th { background: #f8fafc; font-size: 0.8rem; letter-spacing: 0.03em; text-transform: uppercase; color: var(--muted); }
.cell-url { color: var(--muted); word-break: break-all; }
.lead-form { display: grid; gap: 8px; min-width: 180px; }
.tag { display: inline-flex; border-radius: 999px; padding: 3px 8px; font-size: 0.78rem; font-weight: 700; }
.tag-alto { background: #fef3c7; color: #92400e; }
.tag-medio { background: #e0f2fe; color: #075985; }
.tag-bajo { background: #e2e8f0; color: #334155; }
.bar { display: inline-block; height: 8px; width: 0; max-width: 140px; background: var(--amber-deep); border-radius: 99px; margin-right: 8px; vertical-align: middle; }
.scroll-hint { color: var(--muted); font-size: 0.88rem; }
.save-state { color: var(--ok); font-size: 0.85rem; font-weight: 700; }

.calc-grid { display: grid; gap: 24px; }
.calc-card { background: white; border: 1px solid var(--line); border-radius: var(--radius); padding: 18px; box-shadow: var(--shadow); }
.calc-boleta-val { font-size: 1.4rem; font-weight: 700; margin: -4px 0 12px; color: var(--amber-ink); }
.calc-kpis { margin: 12px 0; }
.calc-actions { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 12px; }
.urgency-bar {
  background: #fffbeb;
  border: 1px solid #fcd34d;
  color: #92400e;
  border-radius: 12px;
  padding: 10px 14px;
  font-weight: 700;
  margin: 0 0 16px;
}
.grid-4 { display: grid; gap: 12px; }
.card.compact { padding: 14px; }
.subhead { margin: 28px 0 8px; font-size: 1.2rem; }
.result-line { color: var(--ok); font-weight: 700; }
.trust-split { margin-top: 16px; }
.svg-systems { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 20px; color: var(--ink); }
.svg-systems figcaption { font-size: 0.85rem; color: var(--muted); margin-top: 6px; }

.photo-systems {
  display: grid;
  gap: 12px;
  margin-top: 20px;
}

.photo-card {
  margin: 0;
  background: white;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
}

.photo-card img {
  display: block;
  width: 100%;
  height: 180px;
  object-fit: cover;
}

.photo-card figcaption {
  padding: 10px 12px;
  font-size: 0.9rem;
  font-weight: 700;
  color: var(--ink);
}

.card-media {
  overflow: hidden;
  padding-top: 0;
}

.card-media > img {
  display: block;
  width: calc(100% + 36px);
  max-width: none;
  height: 160px;
  object-fit: cover;
  margin: 0 -18px 14px;
}

.footer-brand img {
  display: block;
  width: min(220px, 100%);
  height: auto;
  border-radius: 10px;
  background: white;
  margin-bottom: 10px;
}
.comuna-chip-wrap { display: flex; align-items: center; gap: 10px; margin: 4px 0 14px; }
.comuna-chip {
  display: inline-flex;
  background: #fffbeb;
  color: var(--amber-ink);
  border: 1px solid #fcd34d;
  border-radius: 999px;
  padding: 6px 12px;
  font-weight: 700;
  font-size: 0.9rem;
}
.linkish { background: none; border: 0; color: var(--amber-ink); font: inherit; font-weight: 700; text-decoration: underline; cursor: pointer; padding: 0; }
.micro { color: var(--muted); font-size: 0.9rem; margin: 0 0 10px; }

.choices-cards {
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.choice-card {
  grid-template-columns: 1fr;
  justify-items: start;
  align-content: start;
  gap: 10px;
  min-height: 108px;
  padding: 14px;
}

.choice-card:has(input:checked) {
  padding: 13.5px;
}

.choice-icon {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: #fff7ed;
  color: var(--amber-ink);
  box-shadow: inset 0 0 0 1px #fde68a;
}

.choice-icon svg { width: 20px; height: 20px; }

.choice-card span:last-of-type {
  font-size: 0.95rem;
  line-height: 1.25;
  font-weight: 700;
}

.choice-card:has(input:checked)::after {
  position: absolute;
  top: 12px;
  right: 12px;
}

.choices-chips {
  grid-template-columns: 1fr 1fr;
}

.choices-chips .choice {
  min-height: 56px;
  text-align: left;
}

.field-hint { font-size: 0.82rem; font-weight: 600; color: var(--muted); }
.field-hint.ok { color: var(--ok); }
.email-optional {
  margin: 4px 0 12px;
  border: 1px dashed #cbd5e1;
  border-radius: 14px;
  padding: 10px 12px;
  background: #f8fafc;
}
.email-optional summary {
  cursor: pointer;
  font-weight: 700;
  color: var(--muted);
  list-style: none;
}
.email-optional summary::-webkit-details-marker { display: none; }
.email-optional[open] summary { margin-bottom: 10px; color: var(--amber-ink); }
.email-optional .field { margin-bottom: 0; }
.next-steps { margin: 14px 0 0; padding-left: 1.2rem; color: var(--muted); }
.success-estimate { background: #fffbeb; border-radius: 12px; padding: 10px 12px; font-weight: 700; }
.hero-links { margin-top: 12px; }
.quote footer { color: var(--muted); font-size: 0.9rem; }
.footer-grid-4 { gap: 22px; }

@media (min-width: 800px) {
  .grid-2 { grid-template-columns: 1fr 1fr; }
  .grid-3 { grid-template-columns: repeat(3, 1fr); }
  .grid-comunas { grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); }
  .card-row { display: grid; grid-template-columns: 1.5fr 1fr; align-items: start; }
  .stack { gap: 12px; }
  .footer-grid { grid-template-columns: 1.3fr 0.8fr 1fr; }
  .footer-grid-4 { grid-template-columns: 1.2fr 0.8fr 1fr 1fr; }
  .kpi-grid { grid-template-columns: repeat(4, 1fr); }
  .grid-4 { grid-template-columns: repeat(4, 1fr); }
  .calc-grid { grid-template-columns: 1fr 1.05fr; align-items: start; }
  .filters { grid-template-columns: 1.2fr 0.8fr 0.9fr 1.2fr auto auto; align-items: end; }
  .steps { grid-template-columns: 1fr 1fr; }
  .photo-systems { grid-template-columns: repeat(3, 1fr); }
  .photo-card img { height: 200px; }
  .wizard { padding: 24px 22px 22px; }
}

@media (min-width: 960px) {
  .nav-toggle { display: none; }
  .nav {
    display: flex;
    position: static;
    flex-direction: row;
    align-items: center;
    background: transparent;
    padding: 0;
    gap: 4px;
  }
  .nav a { padding: 8px 10px; }
  .nav .btn { margin-top: 0; }
  .hero-grid { grid-template-columns: 1.05fr 0.95fr; align-items: start; }
  .dock { display: none; }
  body.has-dock { padding-bottom: 0; }
}

@media (max-width: 959px) {
  .hero-grid { display: flex; flex-direction: column; }
  .wizard { order: -1; }
  .wizard-actions {
    position: sticky;
    bottom: 84px;
    background: linear-gradient(180deg, rgba(255, 255, 255, 0) 0%, #fff 28%);
    padding: 14px 0 12px;
    z-index: 26;
  }
}

@media (max-width: 360px) {
  .choices-cards,
  .choices-chips {
    grid-template-columns: 1fr;
  }

  .steps-label { display: none; }

  .steps-bar li {
    justify-content: center;
    padding: 8px;
  }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }

  .wizard fieldset:not([hidden]),
  .choice,
  .wizard input:not([type="radio"]):not([type="checkbox"]),
  .wizard select {
    animation: none;
    transition: none;
  }
}
