/* =============================================================
   KIMU SMART — Domótica a medida · Puerto Montt
   Tema claro, limpio y tecnológico
   1. Tokens
   ============================================================= */
:root {
  --bg:         #f7f9fd;
  --bg-2:       #eef3fa;
  --panel:      #ffffff;
  --ink:        #10182b;
  --mute:       #5a6a85;
  --accent:     #1e88e5;
  --accent-ink: #1565c0;
  --line:       rgba(16, 24, 43, 0.09);
  --glow:       rgba(30, 136, 229, 0.28);

  --dark-bg:    #0b1120;
  --dark-bg-2:  #131d33;
  --dark-ink:   #e8eef9;
  --dark-mute:  #93a1bd;
  --dark-line:  rgba(147, 161, 189, 0.16);

  --sans:    "Inter", system-ui, -apple-system, sans-serif;
  --display: "Space Grotesk", "Inter", system-ui, sans-serif;
  --mono:    "JetBrains Mono", ui-monospace, monospace;

  --ease-out:  cubic-bezier(0.16, 1, 0.3, 1);
  --ease-soft: cubic-bezier(0.25, 0.46, 0.45, 0.94);

  --shadow-card: 0 1px 2px rgba(16, 24, 43, 0.04), 0 8px 24px -12px rgba(16, 24, 43, 0.1);
  --shadow-card-hover: 0 2px 4px rgba(16, 24, 43, 0.05), 0 18px 44px -14px rgba(30, 136, 229, 0.25);

  --nav-h: 76px;
  --radius: 18px;
  --gutter: clamp(1.25rem, 4vw, 3rem);
}

/* =============================================================
   2. Reset & base
   ============================================================= */
*, *::before, *::after { box-sizing: border-box; margin: 0; }

html {
  -webkit-text-size-adjust: 100%;
  overflow-x: clip;
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--nav-h) + 12px);
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
}

body {
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.65;
  color: var(--ink);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: clip;
  overscroll-behavior-y: none;
}

img, svg, video { display: block; max-width: 100%; }
img { height: auto; }
button { font: inherit; color: inherit; cursor: pointer; border: 0; background: none; }
a { color: inherit; text-decoration: none; }
p { text-wrap: pretty; }
h1, h2, h3, h4 {
  font-family: var(--display);
  text-wrap: balance;
  line-height: 1.05;
  letter-spacing: -0.02em;
  font-weight: 600;
}
::selection { background: var(--accent); color: #fff; }

:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
  border-radius: 4px;
}

.skip-link {
  position: fixed; top: -100px; left: 1rem;
  padding: 0.6rem 1rem;
  background: var(--ink); color: #fff;
  z-index: 9999; border-radius: 8px; font-weight: 500;
}
.skip-link:focus { top: 1rem; }

/* =============================================================
   3. Utilities
   ============================================================= */
.kicker {
  font-family: var(--mono);
  font-size: 0.78rem;
  font-weight: 500;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--accent-ink);
  margin-bottom: 1.1rem;
}

em {
  font-style: normal;
  color: var(--accent-ink);
}

.section {
  padding: clamp(4rem, 8vw, 7rem) var(--gutter);
  max-width: 1240px;
  margin-inline: auto;
}

.section-head {
  margin-bottom: clamp(2.2rem, 4.5vw, 3.5rem);
}
.section-head h2 {
  font-size: clamp(1.9rem, 4.6vw, 3.1rem);
}

/* Reveal on scroll */
.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.9s var(--ease-out), transform 0.9s var(--ease-out);
}
.reveal.is-visible {
  opacity: 1;
  transform: none;
}
.reveal[data-split] { opacity: 1; transform: none; }
html.no-js .reveal { opacity: 1; transform: none; }

/* =============================================================
   4. Buttons
   ============================================================= */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.55rem;
  padding: 0.85rem 1.6rem;
  border-radius: 999px;
  font-family: var(--display);
  font-weight: 600;
  font-size: 0.98rem;
  letter-spacing: 0.01em;
  transition: transform 0.35s var(--ease-out), box-shadow 0.35s var(--ease-out),
              background 0.35s var(--ease-out), border-color 0.35s var(--ease-out);
  will-change: transform;
}
.btn:hover { transform: translateY(-2px); }
.btn:active { transform: translateY(0); }

.btn-whatsapp {
  background: linear-gradient(135deg, var(--accent) 0%, var(--accent-ink) 100%);
  color: #fff;
  box-shadow: 0 8px 24px -8px var(--glow);
}
.btn-whatsapp:hover {
  box-shadow: 0 14px 34px -8px rgba(30, 136, 229, 0.45);
}

.btn-ghost {
  border: 1px solid rgba(16, 24, 43, 0.18);
  color: var(--ink);
  background: var(--panel);
}
.btn-ghost:hover {
  border-color: rgba(30, 136, 229, 0.5);
  background: rgba(30, 136, 229, 0.06);
}

.btn-block { width: 100%; }

/* Botón ghost sobre fondo oscuro (banner videovigilancia) */
.on-dark .btn-ghost {
  border-color: rgba(232, 238, 249, 0.3);
  color: var(--dark-ink);
  background: transparent;
}
.on-dark .btn-ghost:hover {
  border-color: rgba(63, 169, 255, 0.6);
  background: rgba(30, 136, 229, 0.15);
}

/* =============================================================
   5. Nav
   ============================================================= */
.nav {
  position: fixed;
  inset: 0 0 auto 0;
  z-index: 100;
  transition: background 0.4s var(--ease-soft), border-color 0.4s var(--ease-soft),
              box-shadow 0.4s var(--ease-soft);
  border-bottom: 1px solid transparent;
}
.nav.is-solid {
  background: rgba(247, 249, 253, 0.92);
  border-bottom-color: var(--line);
  box-shadow: 0 2px 16px -8px rgba(16, 24, 43, 0.08);
}
@supports (backdrop-filter: blur(14px)) {
  .nav.is-solid {
    background: rgba(247, 249, 253, 0.75);
    backdrop-filter: blur(14px) saturate(150%);
    -webkit-backdrop-filter: blur(14px) saturate(150%);
  }
}

.nav-inner {
  max-width: 1240px;
  margin-inline: auto;
  height: var(--nav-h);
  padding-inline: var(--gutter);
  display: flex;
  align-items: center;
  gap: 2rem;
}

.nav-logo { position: relative; display: inline-flex; align-items: center; width: 156px; height: 53px; }
.nav-logo img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: contain;
  object-position: left center;
  transition: opacity 0.3s var(--ease-out);
}
.nav-logo .logo-light { opacity: 1; }
.nav-logo .logo-dark { opacity: 0; }
.nav.is-solid .nav-logo .logo-light { opacity: 0; }
.nav.is-solid .nav-logo .logo-dark { opacity: 1; }

.nav-links {
  display: none;
  gap: 1.8rem;
  margin-left: auto;
}
.nav-links a {
  position: relative;
  font-size: 0.92rem;
  font-weight: 500;
  color: var(--mute);
  padding-block: 0.3rem;
  transition: color 0.3s var(--ease-out);
}
.nav-links a::after {
  content: "";
  position: absolute;
  left: 0; bottom: 0;
  width: 100%; height: 1.5px;
  background: var(--accent);
  transform: scaleX(0);
  transform-origin: right;
  transition: transform 0.4s var(--ease-out);
}
.nav-links a:hover { color: var(--ink); }
.nav-links a:hover::after {
  transform: scaleX(1);
  transform-origin: left;
}
.nav:not(.is-solid):not(.is-open) .nav-links a { color: rgba(255, 255, 255, 0.88); }
.nav:not(.is-solid):not(.is-open) .nav-links a:hover { color: #fff; }

.nav-cta { display: none; }

.nav-burger {
  margin-left: auto;
  width: 44px; height: 44px;
  display: grid;
  place-content: center;
  gap: 7px;
}
.nav-burger span {
  display: block;
  width: 24px; height: 2px;
  background: var(--ink);
  transition: transform 0.35s var(--ease-out), opacity 0.35s, background 0.3s var(--ease-out);
}
.nav-burger[aria-expanded="true"] span:first-child { transform: translateY(4.5px) rotate(45deg); }
.nav-burger[aria-expanded="true"] span:last-child { transform: translateY(-4.5px) rotate(-45deg); }
.nav:not(.is-solid):not(.is-open) .nav-burger span { background: #fff; }

/* Mobile menu panel */
.nav.is-open { background: var(--bg); }
.nav.is-open .nav-links {
  display: flex;
  position: absolute;
  top: var(--nav-h);
  left: 0; right: 0;
  flex-direction: column;
  gap: 0;
  background: var(--bg);
  border-bottom: 1px solid var(--line);
  padding: 0.5rem var(--gutter) 1.25rem;
  box-shadow: 0 24px 40px -20px rgba(16, 24, 43, 0.15);
}
.nav.is-open .nav-links a {
  padding: 0.85rem 0;
  font-size: 1.05rem;
  border-bottom: 1px solid var(--line);
}

@media (min-width: 960px) {
  .nav-links { display: flex; }
  .nav-cta { display: inline-flex; }
  .nav-burger { display: none; }
}

/* =============================================================
   6. Hero
   ============================================================= */
.hero {
  position: relative;
  min-height: 100vh;
  min-height: 100svh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: calc(var(--nav-h) + 3rem) var(--gutter) 3rem;
  overflow: clip;
}

.hero-media {
  position: absolute;
  inset: 0;
  z-index: -2;
  overflow: hidden;
  background: var(--dark-bg);
}
.hero-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 78% center;
}
.hero-media::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(105deg, rgba(6, 10, 20, 0.95) 0%, rgba(6, 10, 20, 0.88) 28%, rgba(6, 10, 20, 0.5) 58%, rgba(6, 10, 20, 0.14) 100%),
    linear-gradient(0deg, rgba(6, 10, 20, 0.6) 0%, rgba(6, 10, 20, 0) 32%);
}

.hero-inner {
  position: relative;
  z-index: 1;
  max-width: 1240px;
  width: 100%;
  margin-inline: auto;
}

.hero-copy { max-width: 640px; }

.hero .kicker { color: #bcdcff; }

.hero-title {
  font-size: clamp(2.9rem, 9vw, 5.4rem);
  font-weight: 700;
  line-height: 0.98;
  letter-spacing: -0.03em;
  margin-bottom: 1.4rem;
  color: #fff;
}
.hero em { color: #7ec2ff; }

.hero-sub {
  font-size: clamp(1.02rem, 1.6vw, 1.16rem);
  font-weight: 400;
  color: rgba(232, 238, 249, 0.86);
  max-width: 46ch;
  margin-bottom: 2rem;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.9rem;
  margin-bottom: 1rem;
}

.hero-note {
  font-family: var(--mono);
  font-size: 0.76rem;
  letter-spacing: 0.06em;
  color: rgba(232, 238, 249, 0.7);
}

.hero-chips {
  position: relative;
  z-index: 1;
  max-width: 1240px;
  margin: 3rem auto 0;
  width: 100%;
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
}
.hero-chips span {
  font-family: var(--mono);
  font-size: 0.74rem;
  letter-spacing: 0.08em;
  color: var(--mute);
  padding: 0.5rem 0.95rem;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--panel);
}

/* plano "a medida" */
.blueprint { width: 100%; display: block; }
.bp-pulse {
  transform-box: fill-box;
  transform-origin: center;
  animation: shPulse 2.8s var(--ease-soft) infinite;
}
.bp-pulse-2 { animation-delay: 0.8s; }
.bp-pulse-3 { animation-delay: 1.5s; }
.bp-pulse-4 { animation-delay: 2.1s; }
.bp-wires path {
  stroke-dashoffset: 0;
  animation: bpWire 1.6s linear infinite;
}
@keyframes bpWire { to { stroke-dashoffset: -24; } }

.ph-detect { animation: detectPulse 3s ease-in-out infinite; }
@keyframes detectPulse {
  0%, 100% { opacity: 1; }
  50%      { opacity: 0.55; }
}

/* teléfono con app de cámaras */
.phone-mock {
  width: min(62%, 250px);
  animation: phoneFloat 6s ease-in-out infinite;
  filter: drop-shadow(0 24px 40px rgba(0, 0, 0, 0.45));
}
@keyframes phoneFloat {
  0%, 100% { transform: translateY(0); }
  50%      { transform: translateY(-10px); }
}

@media (prefers-reduced-motion: reduce) {
  .phone-mock { animation: none; }
}

/* =============================================================
   7. Services
   ============================================================= */
.services-grid {
  display: grid;
  gap: 1.1rem;
  grid-template-columns: 1fr;
}
@media (min-width: 720px)  { .services-grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1280px) { .services-grid { grid-template-columns: repeat(4, 1fr); } }

.svc-card {
  position: relative;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1.8rem 1.6rem 1.6rem;
  overflow: clip;
  box-shadow: var(--shadow-card);
  transition: transform 0.45s var(--ease-out), border-color 0.45s var(--ease-out),
              box-shadow 0.45s var(--ease-out);
}
.svc-card::before {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(circle 220px at var(--gx, 50%) var(--gy, 0%), rgba(30, 136, 229, 0.07), transparent 70%);
  opacity: 0;
  transition: opacity 0.45s var(--ease-out);
  pointer-events: none;
}
.svc-card:hover {
  transform: translateY(-5px);
  border-color: rgba(30, 136, 229, 0.35);
  box-shadow: var(--shadow-card-hover);
}
.svc-card:hover::before { opacity: 1; }

.svc-icon {
  color: var(--accent-ink);
  margin-bottom: 1.3rem;
  width: 60px; height: 60px;
  display: grid;
  place-items: center;
  border-radius: 14px;
  background: rgba(30, 136, 229, 0.08);
  border: 1px solid rgba(30, 136, 229, 0.18);
}

.svc-card h3 {
  font-size: 1.18rem;
  margin-bottom: 0.7rem;
}
.svc-card p {
  font-size: 0.93rem;
  color: var(--mute);
  margin-bottom: 1.3rem;
}

.svc-link {
  font-family: var(--display);
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--accent-ink);
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
}
.svc-link span { transition: transform 0.3s var(--ease-out); }
.svc-link:hover span { transform: translateX(4px); }

/* =============================================================
   8. Tailored ("A medida")
   ============================================================= */
.tailored { position: relative; }
.tailored-inner {
  display: grid;
  gap: 2.5rem;
  align-items: center;
}
@media (min-width: 960px) {
  .tailored-inner { grid-template-columns: 0.9fr 1.1fr; gap: 4rem; }
}

.tailored-figure {
  position: relative;
  border-radius: var(--radius);
  overflow: clip;
  border: 1px solid var(--line);
  box-shadow: var(--shadow-card);
  background: #fbfcfe;
}

.tailored-tag {
  position: absolute;
  left: 1rem; bottom: 1rem;
  z-index: 1;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-family: var(--mono);
  font-size: 0.74rem;
  letter-spacing: 0.06em;
  color: #fff;
  background: rgba(16, 24, 43, 0.72);
  padding: 0.45rem 0.85rem;
  border-radius: 999px;
}
.tailored-tag .dot {
  width: 7px; height: 7px;
  border-radius: 50%;
  background: #3fa9ff;
  box-shadow: 0 0 8px #3fa9ff;
}

.tailored-copy h2 { font-size: clamp(1.9rem, 4.2vw, 2.9rem); margin-bottom: 1.2rem; }
.tailored-copy > p.reveal { color: var(--mute); max-width: 56ch; margin-bottom: 1.6rem; }

.tailored-list {
  list-style: none;
  padding: 0;
  display: grid;
  gap: 0.9rem;
}
.tailored-list li {
  padding: 1rem 1.2rem;
  border: 1px solid var(--line);
  border-left: 3px solid var(--accent);
  border-radius: 10px;
  background: var(--panel);
  box-shadow: var(--shadow-card);
  font-size: 0.95rem;
  color: var(--mute);
}
.tailored-list strong { color: var(--ink); font-weight: 600; }

/* =============================================================
   9. Process
   ============================================================= */
.process { background: var(--bg-2); max-width: none; }
.process > * { max-width: 1240px; margin-inline: auto; }

.process-steps {
  list-style: none;
  padding: 0;
  display: grid;
  gap: 1.1rem;
  counter-reset: step;
}
@media (min-width: 720px)  { .process-steps { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1280px) { .process-steps { grid-template-columns: repeat(4, 1fr); } }

.step {
  position: relative;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1.7rem 1.5rem;
  box-shadow: var(--shadow-card);
  transition: transform 0.45s var(--ease-out), border-color 0.45s var(--ease-out),
              box-shadow 0.45s var(--ease-out);
}
.step:hover {
  transform: translateY(-5px);
  border-color: rgba(30, 136, 229, 0.35);
  box-shadow: var(--shadow-card-hover);
}

.step-num {
  font-family: var(--mono);
  font-size: 0.8rem;
  font-weight: 500;
  letter-spacing: 0.12em;
  color: var(--accent-ink);
  display: inline-block;
  margin-bottom: 1rem;
  padding: 0.3rem 0.7rem;
  border: 1px solid rgba(30, 136, 229, 0.25);
  border-radius: 999px;
  background: rgba(30, 136, 229, 0.07);
}

.step h3 { font-size: 1.1rem; margin-bottom: 0.6rem; }
.step p { font-size: 0.92rem; color: var(--mute); }

.process-cta {
  margin-top: 2.6rem;
  text-align: center;
}

/* =============================================================
   10. Watch (videovigilancia — banda oscura de contraste)
   ============================================================= */
.watch { padding-block: 0; }
.watch-inner {
  display: grid;
  gap: 0;
  border-radius: calc(var(--radius) + 6px);
  overflow: clip;
  background: linear-gradient(135deg, var(--dark-bg-2) 0%, var(--dark-bg) 100%);
  box-shadow: 0 24px 60px -24px rgba(16, 24, 43, 0.35);
}
@media (min-width: 960px) {
  .watch-inner { grid-template-columns: 0.85fr 1.15fr; }
}

.watch-figure {
  position: relative;
  display: grid;
  place-items: center;
  padding: clamp(2rem, 4vw, 3rem) 1.5rem;
  background:
    radial-gradient(circle 300px at 50% 45%, rgba(30, 136, 229, 0.18), transparent 70%),
    linear-gradient(160deg, #101a30 0%, var(--dark-bg) 100%);
}

.watch-copy { padding: clamp(2rem, 5vw, 3.5rem); color: var(--dark-ink); }
.watch-copy .kicker { color: #3fa9ff; }
.watch-copy h2 { font-size: clamp(1.7rem, 3.6vw, 2.5rem); margin-bottom: 1rem; }
.watch-copy h2 em { color: #3fa9ff; }
.watch-copy p { color: var(--dark-mute); max-width: 52ch; margin-bottom: 1.6rem; }

/* =============================================================
   11. FAQ
   ============================================================= */
.faq-list {
  display: grid;
  gap: 0.8rem;
  max-width: 820px;
}

.faq-item {
  border: 1px solid var(--line);
  border-radius: 14px;
  background: var(--panel);
  box-shadow: var(--shadow-card);
  overflow: clip;
  transition: border-color 0.3s var(--ease-out);
}
.faq-item[open] { border-color: rgba(30, 136, 229, 0.35); }

.faq-item summary {
  cursor: pointer;
  list-style: none;
  padding: 1.1rem 1.3rem;
  font-family: var(--display);
  font-weight: 600;
  font-size: 1rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  transition: color 0.3s;
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::after {
  content: "+";
  font-family: var(--mono);
  font-size: 1.2rem;
  color: var(--accent-ink);
  transition: transform 0.35s var(--ease-out);
  flex-shrink: 0;
}
.faq-item[open] summary::after { transform: rotate(45deg); }
.faq-item summary:hover { color: var(--accent-ink); }

.faq-item p {
  padding: 0 1.3rem 1.2rem;
  color: var(--mute);
  font-size: 0.94rem;
}

/* =============================================================
   12. Contact
   ============================================================= */
.contact { position: relative; }
.contact-glow {
  position: absolute;
  inset: -10% -10% auto;
  height: 70%;
  background: radial-gradient(45% 50% at 50% 50%, rgba(30, 136, 229, 0.08), transparent 75%);
  filter: blur(70px);
  pointer-events: none;
}

.contact-inner {
  position: relative;
  display: grid;
  gap: 3rem;
}
@media (min-width: 960px) {
  .contact-inner { grid-template-columns: 1fr 1fr; gap: 4.5rem; }
}

.contact-copy h2 { font-size: clamp(2rem, 4.6vw, 3.1rem); margin-bottom: 1.1rem; }
.contact-copy > p.reveal { color: var(--mute); max-width: 44ch; margin-bottom: 2rem; }

.contact-data {
  list-style: none;
  padding: 0;
  display: grid;
  gap: 1.2rem;
}
.contact-label {
  display: block;
  font-family: var(--mono);
  font-size: 0.72rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--mute);
  margin-bottom: 0.2rem;
}
.contact-value {
  font-family: var(--display);
  font-size: 1.25rem;
  font-weight: 600;
}
a.contact-value {
  position: relative;
  display: inline-block;
}
a.contact-value::after {
  content: "";
  position: absolute;
  left: 0; bottom: -2px;
  width: 100%; height: 2px;
  background: var(--accent);
  transform: scaleX(0);
  transform-origin: right;
  transition: transform 0.4s var(--ease-out);
}
a.contact-value:hover::after {
  transform: scaleX(1);
  transform-origin: left;
}

.contact-form {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: calc(var(--radius) + 4px);
  padding: clamp(1.5rem, 3.5vw, 2.3rem);
  box-shadow: var(--shadow-card);
  display: grid;
  gap: 1.15rem;
}

.contact-form label span {
  display: block;
  font-size: 0.86rem;
  font-weight: 500;
  margin-bottom: 0.4rem;
  color: var(--ink);
}

.contact-form input,
.contact-form select,
.contact-form textarea {
  width: 100%;
  font: inherit;
  font-size: 0.95rem;
  color: var(--ink);
  background: var(--bg);
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 0.75rem 0.95rem;
  transition: border-color 0.3s var(--ease-out), box-shadow 0.3s var(--ease-out);
}
.contact-form textarea { resize: vertical; min-height: 96px; }
.contact-form input::placeholder,
.contact-form textarea::placeholder { color: rgba(90, 106, 133, 0.55); }
.contact-form input:focus,
.contact-form select:focus,
.contact-form textarea:focus {
  outline: none;
  border-color: rgba(30, 136, 229, 0.55);
  box-shadow: 0 0 0 3px rgba(30, 136, 229, 0.12);
}

.form-note {
  font-size: 0.78rem;
  color: var(--mute);
  text-align: center;
}

/* =============================================================
   13. Footer
   ============================================================= */
.footer {
  position: relative;
  overflow: clip;
  background: var(--dark-bg);
  color: var(--dark-ink);
  padding: clamp(3.5rem, 7vw, 5.5rem) var(--gutter) 1.8rem;
}

/* línea de acento superior */
.footer::before {
  content: "";
  position: absolute;
  inset: 0 0 auto 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(63, 169, 255, 0.6), transparent);
}

/* resplandor azul sutil */
.footer-glow {
  position: absolute;
  left: 50%; top: -60%;
  width: min(920px, 115%);
  aspect-ratio: 2 / 1;
  transform: translateX(-50%);
  background: radial-gradient(50% 50% at 50% 50%, rgba(30, 136, 229, 0.32), transparent 70%);
  filter: blur(70px);
  pointer-events: none;
}

.footer-inner {
  position: relative;
  max-width: 1240px;
  margin-inline: auto;
  display: grid;
  gap: 2.75rem;
  padding-bottom: 3rem;
}
@media (min-width: 720px) {
  .footer-inner { grid-template-columns: repeat(2, 1fr); }
}
@media (min-width: 1024px) {
  .footer-inner {
    grid-template-columns: 1.5fr 1fr 1fr 1.15fr;
    gap: 3rem 2.5rem;
  }
}

.footer-brand img {
  width: 200px;
  height: auto;
  border-radius: 12px;
  margin-bottom: 1rem;
}
.footer-tagline {
  font-family: var(--mono);
  font-size: 0.7rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: #3fa9ff;
  margin-bottom: 0.85rem;
}
.footer-desc {
  font-size: 0.9rem;
  color: var(--dark-mute);
  max-width: 38ch;
}

.footer-head {
  font-family: var(--mono);
  font-size: 0.68rem;
  font-weight: 500;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: #6d7d99;
  margin-bottom: 1.1rem;
}

.footer-col {
  display: grid;
  gap: 0.7rem;
  align-content: start;
}
.footer-col a {
  font-size: 0.92rem;
  color: var(--dark-mute);
  width: fit-content;
  transition: color 0.3s var(--ease-out), transform 0.3s var(--ease-out);
}
.footer-col a:hover {
  color: #fff;
  transform: translateX(3px);
}

.footer-cta-col { gap: 0.95rem; }
.footer-btn {
  width: fit-content;
  padding: 0.7rem 1.3rem;
  font-size: 0.92rem;
}
.footer-btn:hover { transform: translateY(-2px); }
.footer-phone {
  font-family: var(--display);
  font-size: 1.15rem !important;
  font-weight: 600;
  color: #fff !important;
  letter-spacing: -0.01em;
}
.footer-phone:hover { color: #3fa9ff !important; transform: none !important; }
.footer-place {
  display: flex;
  align-items: center;
  gap: 0.45rem;
  font-size: 0.85rem;
  color: var(--dark-mute);
}
.footer-place svg { color: #3fa9ff; flex-shrink: 0; }

.footer-base {
  position: relative;
  max-width: 1240px;
  margin-inline: auto;
  border-top: 1px solid rgba(147, 161, 189, 0.14);
  padding-top: 1.5rem;
  /* espacio para que el botón flotante de WhatsApp no tape el texto */
  padding-bottom: 3.5rem;
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 0.8rem;
  font-size: 0.8rem;
  color: #6d7d99;
}
@media (min-width: 720px) {
  .footer-base { padding-right: 5rem; padding-bottom: 0.5rem; }
}
.footer-note {
  font-family: var(--mono);
  font-size: 0.72rem;
  letter-spacing: 0.08em;
  color: #6d7d99;
}

/* =============================================================
   14. WhatsApp float
   ============================================================= */
.wa-float {
  position: fixed;
  right: 1.2rem;
  bottom: 1.2rem;
  z-index: 90;
  width: 56px; height: 56px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  color: #fff;
  background: linear-gradient(135deg, #25d366 0%, #128c7e 100%);
  box-shadow: 0 10px 30px -8px rgba(37, 211, 102, 0.5);
  transition: transform 0.35s var(--ease-out), box-shadow 0.35s var(--ease-out);
}
.wa-float:hover {
  transform: translateY(-3px) scale(1.05);
  box-shadow: 0 16px 38px -8px rgba(37, 211, 102, 0.65);
}

/* =============================================================
   15. Reduced motion (solo efectos intrusivos)
   ============================================================= */
@media (prefers-reduced-motion: reduce) {
  .sh-wire { animation: none; }
  .sh-core-pulse { animation: none; opacity: 0; }
}

/* =============================================================
   17. Movimiento (2026-09-09)
   ============================================================= */

/* ---- Barra de progreso de lectura ---- */
.progreso {
  position: fixed;
  inset: 0 0 auto 0;
  height: 2px;
  z-index: 120;
  background: transparent;
  pointer-events: none;
}
.progreso span {
  display: block;
  height: 100%;
  width: 0;
  background: linear-gradient(90deg, var(--accent), var(--accent-2, #3fa9ff));
  box-shadow: 0 0 10px rgba(30, 136, 229, 0.7);
  transform-origin: left;
  transition: width 0.12s linear;
}

/* ---- Hero: la foto respira y se desplaza más lento que el scroll ---- */
.hero-media img {
  will-change: transform;
  animation: respirar 26s ease-in-out infinite alternate;
}
@keyframes respirar {
  from { transform: scale(1); }
  to   { transform: scale(1.08); }
}
/* El desplazamiento lo aplica el JS sobre el contenedor, no sobre la imagen,
   para no pelear con la animación de escala */
.hero-media { will-change: transform; }

/* ---- Entrada escalonada de rejillas ---- */
.services-grid > .reveal:nth-child(1),
.process-steps > .reveal:nth-child(1),
.faq-list > .reveal:nth-child(1) { transition-delay: 0s; }
.services-grid > .reveal:nth-child(2),
.process-steps > .reveal:nth-child(2),
.faq-list > .reveal:nth-child(2) { transition-delay: 0.09s; }
.services-grid > .reveal:nth-child(3),
.process-steps > .reveal:nth-child(3),
.faq-list > .reveal:nth-child(3) { transition-delay: 0.18s; }
.services-grid > .reveal:nth-child(4),
.process-steps > .reveal:nth-child(4),
.faq-list > .reveal:nth-child(4) { transition-delay: 0.27s; }
.faq-list > .reveal:nth-child(5) { transition-delay: 0.36s; }

/* Las tarjetas entran con un leve giro, no solo subiendo */
.svc-card.reveal, .step.reveal {
  transform: translateY(30px) scale(0.985);
}
.svc-card.reveal.is-visible, .step.reveal.is-visible {
  transform: none;
}

/* ---- Inclinación 3D suave al pasar el cursor ---- */
@media (hover: hover) and (pointer: fine) {
  .svc-card, .step {
    transform-style: preserve-3d;
    transition: transform 0.5s var(--ease-out), border-color 0.45s var(--ease-out),
                box-shadow 0.45s var(--ease-out);
  }
  /* Debe superar a .svc-card.reveal.is-visible, que fija transform:none */
  .svc-card.reveal.is-visible.inclina, .step.reveal.is-visible.inclina {
    transform: perspective(900px)
               rotateX(var(--ry, 0deg))
               rotateY(var(--rx, 0deg))
               translateY(-5px);
  }
  .svc-icon { transition: transform 0.5s var(--ease-out); }
  .svc-card:hover .svc-icon { transform: translateY(-3px) scale(1.06); }
}

/* ---- Destello que barre los botones principales ---- */
.btn-whatsapp {
  position: relative;
  overflow: hidden;
  isolation: isolate;
}
.btn-whatsapp::after {
  content: "";
  position: absolute;
  top: 0; bottom: 0;
  left: -60%;
  width: 45%;
  z-index: -1;
  background: linear-gradient(100deg, transparent, rgba(255, 255, 255, 0.35), transparent);
  transform: skewX(-18deg);
  transition: left 0.75s var(--ease-out);
}
.btn-whatsapp:hover::after { left: 125%; }

/* ---- Línea de acento que se dibuja bajo los títulos de sección ---- */
.section-head .kicker { position: relative; display: inline-block; }
.section-head .kicker::after {
  content: "";
  position: absolute;
  left: 0; bottom: -6px;
  height: 2px; width: 100%;
  background: var(--accent);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.9s var(--ease-out) 0.2s;
}
.section-head .kicker.is-visible::after { transform: scaleX(1); }

/* ---- Los chips del hero flotan apenas, en secuencia ---- */
.hero-chips span {
  animation: flotarChip 7s ease-in-out infinite;
}
.hero-chips span:nth-child(2) { animation-delay: 0.9s; }
.hero-chips span:nth-child(3) { animation-delay: 1.8s; }
.hero-chips span:nth-child(4) { animation-delay: 2.7s; }
@keyframes flotarChip {
  0%, 100% { transform: translateY(0); }
  50%      { transform: translateY(-5px); }
}

/* ---- El número del paso late al entrar en pantalla ---- */
.step.is-visible .step-num {
  animation: latidoNum 1.6s var(--ease-out) 0.3s;
}
@keyframes latidoNum {
  0%   { box-shadow: 0 0 0 0 rgba(30, 136, 229, 0.45); }
  60%  { box-shadow: 0 0 0 12px rgba(30, 136, 229, 0); }
  100% { box-shadow: 0 0 0 0 rgba(30, 136, 229, 0); }
}

/* ---- Solo se apaga lo intrusivo: el zoom continuo de la foto ---- */
@media (prefers-reduced-motion: reduce) {
  .hero-media img { animation: none; }
  .hero-chips span { animation: none; }
}

/* =============================================================
   18. Movimiento del hero (2026-09-09)
   ============================================================= */

/* ---- La foto ya no solo acerca: también se desplaza ---- */
@keyframes respirar {
  from { transform: scale(1) translate3d(0, 0, 0); }
  to   { transform: scale(1.11) translate3d(-1.8%, 0, 0); }
}

/* ---- Luz cálida que late, como ventanas encendidas ---- */
.hero-luz {
  position: absolute;
  left: 64%; top: 44%;
  width: 34vmax; height: 34vmax;
  transform: translate(-50%, -50%);
  border-radius: 50%;
  background: radial-gradient(circle, rgba(255, 197, 112, 0.2) 0%, rgba(255, 197, 112, 0.07) 38%, transparent 66%);
  pointer-events: none;
  animation: latirLuz 8s ease-in-out infinite;
}
@keyframes latirLuz {
  0%, 100% { opacity: 0.55; transform: translate(-50%, -50%) scale(1); }
  50%      { opacity: 1;    transform: translate(-50%, -50%) scale(1.09); }
}

/* ---- Destello frío que barre la fachada cada tanto ---- */
.hero-destello {
  position: absolute;
  inset: -10% -30%;
  pointer-events: none;
  background: linear-gradient(100deg,
    transparent 40%,
    rgba(140, 200, 255, 0.085) 50%,
    transparent 60%);
  animation: barrer 14s ease-in-out infinite;
}
@keyframes barrer {
  0%, 8%   { transform: translateX(-38%); opacity: 0; }
  22%      { opacity: 1; }
  46%      { transform: translateX(38%); opacity: 0; }
  100%     { transform: translateX(38%); opacity: 0; }
}

/* ---- El titular sube por líneas, tras una máscara ---- */
.hero-title .linea {
  display: block;
  overflow: hidden;
  /* margen para que no se corten acentos ni la coma */
  padding-bottom: 0.09em;
  margin-bottom: -0.09em;
}
.hero-title .linea > span { display: block; }
/* El estado por defecto es VISIBLE. Solo se esconde para animarlo cuando
   sabemos que el navegador quiere animaciones; asi el titular nunca
   desaparece si la animacion no llega a correr. */
@media (prefers-reduced-motion: no-preference) {
  .hero-title .linea > span {
    transform: translateY(108%);
    animation: subirLinea 1.15s var(--ease-out) 0.15s forwards;
  }
  .hero-title .linea:nth-child(2) > span { animation-delay: 0.29s; }
  /* Red de seguridad del JS: si a los 2,5s no termino, se fuerza */
  html.titular-ok .hero-title .linea > span { transform: none; animation: none; }
}
@keyframes subirLinea {
  to { transform: translateY(0); }
}

/* ---- Indicador de bajar, con un punto que recorre la línea ---- */
.hero-cue {
  position: absolute;
  left: 50%;
  bottom: 1.6rem;
  z-index: 6;
  transform: translateX(-50%);
  width: 22px; height: 46px;
  display: grid;
  place-items: start center;
}
.hero-cue::before {
  content: "";
  position: absolute;
  top: 0; bottom: 0; left: 50%;
  width: 1px;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.55), transparent);
}
.hero-cue span {
  width: 5px; height: 5px;
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 0 8px rgba(255, 255, 255, 0.9);
  animation: bajarPunto 2.4s var(--ease-soft) infinite;
}
@keyframes bajarPunto {
  0%       { transform: translateY(0); opacity: 0; }
  20%      { opacity: 1; }
  80%      { opacity: 1; }
  100%     { transform: translateY(38px); opacity: 0; }
}
.hero-cue:hover span { background: #3fa9ff; box-shadow: 0 0 10px #3fa9ff; }
/* En pantallas bajas estorba: los chips ya ocupan ese borde */
@media (max-height: 700px), (max-width: 720px) {
  .hero-cue { display: none; }
}

/* ---- Solo se apaga lo continuo e intrusivo ---- */
@media (prefers-reduced-motion: reduce) {
  .hero-luz, .hero-destello { animation: none; }
  .hero-cue span { animation: none; opacity: 1; }
}

/* ---- Recorte del hero en pantallas angostas ----
   El degradado inferior más denso mejora la legibilidad del texto sobre la
   foto en vertical. (Los letreros ajenos que antes obligaban a desplazar el
   encuadre ya no existen: la imagen se recortó a 1800x2180 el 2026-09-09.) */
@media (max-width: 899px) {
  .hero-media::after {
    background:
      linear-gradient(105deg, rgba(6, 10, 20, 0.95) 0%, rgba(6, 10, 20, 0.9) 34%, rgba(6, 10, 20, 0.62) 66%, rgba(6, 10, 20, 0.3) 100%),
      linear-gradient(0deg, rgba(6, 10, 20, 0.82) 0%, rgba(6, 10, 20, 0) 40%);
  }
}

/* ---- Correo de contacto ----
   La dirección es larga, así que baja de tamaño y puede partirse
   sin desbordar la columna en pantallas angostas. */
.contact-correo {
  font-size: 1.02rem;
  line-height: 1.35;
  overflow-wrap: anywhere;
}
.footer-correo {
  font-size: 0.88rem;
  color: var(--dark-mute);
  overflow-wrap: anywhere;
  transition: color 0.3s var(--ease-out);
}
.footer-correo:hover { color: #3fa9ff; }
