/* Apex Electric — soluciones fotovoltaicas
   Paleta: modo oscuro premium — negro azulado + un único acento dorado, sin verde */

:root {
  --bg: 220 22% 5%;
  --bg-elevated: 220 20% 9%;
  --muted: 220 16% 12%;
  --border: 220 14% 20%;
  --fg: 40 15% 94%;
  --fg-muted: 220 8% 58%;
  --primary: 43 85% 56%;
  --primary-fg: 220 30% 8%;
  --secondary: 220 8% 58%;
  --accent: 38 75% 48%;
  --radius: 1rem;
  --radius-sm: 0.6rem;
  --shadow-color: 220 40% 2%;
  --container: 78rem;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
}

body {
  margin: 0;
  background: hsl(var(--bg));
  color: hsl(var(--fg));
  font-family: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
button { font: inherit; cursor: pointer; }
h1, h2, h3, h4 { margin: 0; line-height: 1.15; }
p { margin: 0; }
section { position: relative; }

/* Foco visible para navegación por teclado (no se muestra en clic de mouse) */
a:focus-visible, button:focus-visible, input:focus-visible, textarea:focus-visible,
select:focus-visible, [tabindex]:focus-visible {
  outline: 2px solid hsl(var(--primary));
  outline-offset: 2px;
  border-radius: 0.3rem;
}

.container {
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 1.5rem;
}

.brand-stripe {
  height: 4px;
  width: 100%;
  background: linear-gradient(90deg, hsl(var(--primary)), hsl(var(--accent)));
}

/* ---------- Header ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: hsl(var(--bg) / 0.88);
  backdrop-filter: blur(16px);
  border-bottom: 1px solid hsl(var(--border) / 0.6);
}
.site-header .inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
  padding: 0.75rem 1.5rem;
}
.logo img { height: 3.25rem; width: auto; }
.nav-links {
  display: none;
  gap: 1.75rem;
  font-size: 0.9rem;
  font-weight: 500;
  color: hsl(var(--fg-muted));
}
.nav-links a:hover { color: hsl(var(--primary)); }
@media (min-width: 900px) {
  .nav-links { display: flex; }
}
.header-cta { display: flex; align-items: center; gap: 0.75rem; }
.header-cta .btn-outline { display: none; }
@media (min-width: 900px) { .header-cta .btn-outline { display: inline-flex; } }
.social-icons { display: flex; gap: 0.45rem; }
.social-icons a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.1rem;
  height: 2.1rem;
  border: 1px solid hsl(var(--border));
  border-radius: 999px;
  font-size: 0.95rem;
  transition: border-color 0.15s ease;
}
.social-icons a:hover { border-color: hsl(var(--primary)); }
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.7rem 1.35rem;
  border-radius: 999px;
  font-weight: 600;
  font-size: 0.9rem;
  border: 1px solid transparent;
  transition: transform 0.15s ease, background-color 0.15s ease, border-color 0.15s ease;
  white-space: nowrap;
}
.btn:active { transform: scale(0.97); }
.btn-primary {
  background: hsl(var(--primary));
  color: hsl(var(--primary-fg));
}
.btn-primary:hover { background: hsl(45 93% 58%); }
.btn-outline {
  background: transparent;
  border-color: hsl(var(--border));
  color: hsl(var(--fg));
}
.btn-outline:hover { border-color: hsl(var(--primary)); color: hsl(var(--primary)); }
.btn-whatsapp {
  background: #25d366;
  color: #06210f;
}
.btn-whatsapp:hover { background: #2fe375; }
.btn-sm { padding: 0.5rem 1rem; font-size: 0.82rem; }
.menu-toggle {
  display: inline-flex;
  background: transparent;
  border: 1px solid hsl(var(--border));
  border-radius: var(--radius-sm);
  padding: 0.5rem 0.65rem;
  color: hsl(var(--fg));
}
@media (min-width: 900px) { .menu-toggle { display: none; } }
.mobile-nav {
  display: none;
  flex-direction: column;
  gap: 0.25rem;
  padding: 0.5rem 1.5rem 1.25rem;
  border-bottom: 1px solid hsl(var(--border) / 0.6);
}
.mobile-nav.open { display: flex; }
.mobile-nav a {
  padding: 0.65rem 0.25rem;
  color: hsl(var(--fg-muted));
  border-bottom: 1px solid hsl(var(--border) / 0.4);
}
@media (min-width: 900px) { .mobile-nav { display: none !important; } }

/* ---------- Hero ---------- */
.hero {
  padding: 4.5rem 0 3.5rem;
  background:
    radial-gradient(60rem 30rem at 85% -10%, hsl(var(--primary) / 0.14), transparent 60%),
    radial-gradient(50rem 30rem at -10% 20%, hsl(var(--accent) / 0.12), transparent 55%);
}
.hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 2.5rem;
  align-items: center;
}
@media (min-width: 960px) {
  .hero-grid { grid-template-columns: minmax(0, 1.05fr) minmax(0, 0.95fr); gap: 3rem; }
}
.hero-media { position: relative; order: -1; }
@media (min-width: 960px) { .hero-media { order: 0; } }
.carousel { position: relative; }
.carousel-viewport {
  width: 100%;
  aspect-ratio: 4 / 3;
  overflow: hidden;
  border-radius: 1.25rem;
  border: 1px solid hsl(var(--border) / 0.6);
  box-shadow: 0 1.5rem 3rem -1rem hsl(220 40% 8% / 0.35);
  touch-action: pan-y;
  cursor: grab;
}
.carousel-viewport:active { cursor: grabbing; }
.carousel-track {
  display: flex;
  height: 100%;
  transition: transform 0.55s cubic-bezier(0.65, 0, 0.35, 1);
  will-change: transform;
}
.carousel-slide {
  flex: 0 0 100%;
  height: 100%;
}
.carousel-slide img,
.carousel-slide video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  -webkit-user-drag: none;
  user-select: none;
  pointer-events: none;
}
.carousel-arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 2.25rem;
  height: 2.25rem;
  border-radius: 999px;
  background: hsl(220 30% 8% / 0.5);
  color: #fff;
  border: none;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.35rem;
  line-height: 1;
  cursor: pointer;
  backdrop-filter: blur(2px);
  transition: background 0.2s;
  z-index: 2;
}
.carousel-arrow:hover { background: hsl(var(--primary) / 0.9); }
.carousel-arrow.prev { left: 0.6rem; }
.carousel-arrow.next { right: 0.6rem; }
.carousel-dots {
  position: absolute;
  bottom: 0.7rem;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 0.4rem;
  z-index: 2;
}
.carousel-dot {
  width: 0.45rem;
  height: 0.45rem;
  border-radius: 999px;
  background: hsl(0 0% 100% / 0.5);
  border: none;
  padding: 0;
  cursor: pointer;
  transition: background 0.2s, width 0.2s;
}
.carousel-dot.active {
  background: #fff;
  width: 1.1rem;
}

.testimonial-carousel { max-width: 42rem; margin: 0 auto; }
.testimonial-carousel .carousel-viewport {
  aspect-ratio: unset;
  border: none;
  border-radius: 0;
  box-shadow: none;
  cursor: default;
}
.testimonial-carousel .carousel-slide { padding: 0 0.35rem; }
.testimonial-carousel .carousel-slide > .card { height: 100%; }
.testimonial-controls {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1.1rem;
  margin-top: 1.75rem;
}
.testimonial-controls .carousel-arrow {
  position: static;
  background: hsl(var(--bg-elevated));
  color: hsl(var(--fg));
  border: 1px solid hsl(var(--border));
}
.testimonial-controls .carousel-arrow:hover {
  background: hsl(var(--primary));
  color: hsl(var(--primary-fg));
  border-color: hsl(var(--primary));
}
.testimonial-controls .carousel-dots { position: static; transform: none; }
.testimonial-controls .carousel-dot { background: hsl(var(--border)); }
.testimonial-controls .carousel-dot.active { background: hsl(var(--primary)); }
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: hsl(var(--primary));
  background: hsl(var(--primary) / 0.1);
  border: 1px solid hsl(var(--primary) / 0.3);
  padding: 0.4rem 0.9rem;
  border-radius: 999px;
}
.hero h1 {
  font-size: clamp(2.3rem, 5vw, 3.75rem);
  font-weight: 800;
  margin-top: 1.1rem;
  max-width: 40rem;
}
.hero h1 span { color: hsl(var(--primary)); }
.hero .lead {
  margin-top: 1.25rem;
  max-width: 38rem;
  color: hsl(var(--fg-muted));
  font-size: 1.02rem;
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
}
.hero .lead strong { color: hsl(var(--fg)); }
.hero .lead .lead-tagline {
  color: hsl(var(--primary));
  font-weight: 700;
  font-size: 1rem;
}
.hero-actions {
  margin-top: 2rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.85rem;
}
.stats-row {
  margin-top: 3rem;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1.25rem;
  max-width: 34rem;
}
@media (min-width: 640px) { .stats-row { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
.stat-num {
  font-size: 1.75rem;
  font-weight: 800;
  color: hsl(var(--primary));
}
.stat-label {
  font-size: 0.72rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: hsl(var(--fg-muted));
  margin-top: 0.15rem;
}
.badge-strip {
  margin-top: 3rem;
  border-top: 1px solid hsl(var(--border) / 0.6);
  padding-top: 1.5rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
}
.badge-strip span {
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.03em;
  color: hsl(var(--fg-muted));
  border: 1px solid hsl(var(--border));
  border-radius: 999px;
  padding: 0.35rem 0.8rem;
}

/* ---------- Brands ---------- */
.brands-section { padding-top: 2rem; padding-bottom: 2rem; }
.brands-label {
  text-align: center;
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.03em;
  color: hsl(var(--fg-muted));
  margin-bottom: 1.75rem;
}
.brands-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 2.75rem;
}
.brands-row img {
  height: 2.1rem;
  width: auto;
  opacity: 0.75;
  filter: grayscale(1);
  transition: opacity 0.2s ease, filter 0.2s ease;
}
.brands-row img:hover { opacity: 1; filter: grayscale(0); }

/* ---------- Section headers ---------- */
.section { padding: 5rem 0; }
.section-alt { background: hsl(var(--bg-elevated) / 0.5); }
.section-tag {
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: hsl(var(--secondary));
}
.section-title {
  font-size: clamp(1.6rem, 3.4vw, 2.4rem);
  font-weight: 800;
  margin-top: 0.5rem;
  max-width: 34rem;
}
.section-head { margin-bottom: 2.75rem; }

/* ---------- Cards / grids ---------- */
.grid { display: grid; gap: 1.5rem; }
.grid-4 { grid-template-columns: minmax(0, 1fr); }
@media (min-width: 700px) { .grid-4 { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (min-width: 1100px) { .grid-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
.grid-2 { grid-template-columns: minmax(0, 1fr); }
@media (min-width: 640px) { .grid-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.feature-list { grid-template-columns: minmax(0, 1fr); }
@media (min-width: 640px) { .feature-list { grid-template-columns: repeat(2, minmax(0, 1fr)); } }

.card {
  background: hsl(var(--bg-elevated));
  border: 1px solid hsl(var(--border));
  border-radius: var(--radius);
  padding: 1.75rem;
  transition: border-color 0.2s ease, transform 0.2s ease;
}
.card:hover { border-color: hsl(var(--primary) / 0.5); }
.card .kicker {
  font-size: 0.72rem;
  font-weight: 700;
  color: hsl(var(--primary));
  letter-spacing: 0.03em;
}
.card h3 { margin-top: 0.6rem; font-size: 1.15rem; }
.card p { margin-top: 0.6rem; color: hsl(var(--fg-muted)); font-size: 0.92rem; }
.card .link {
  margin-top: 1rem;
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  font-size: 0.85rem;
  font-weight: 600;
  color: hsl(var(--accent));
}

.solution-card { overflow: hidden; padding: 0; }
.solution-card img { height: 11rem; width: 100%; object-fit: cover; }
.solution-card .body { padding: 1.5rem; }

/* Process steps */
.steps { counter-reset: step; }
.step {
  display: flex;
  gap: 1.25rem;
  padding: 1.5rem 0;
  border-bottom: 1px solid hsl(var(--border) / 0.6);
}
.step:last-child { border-bottom: none; }
.step-num {
  flex: none;
  width: 2.75rem;
  height: 2.75rem;
  border-radius: 999px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  color: hsl(var(--primary-fg));
  background: hsl(var(--primary));
}
.step h3 { font-size: 1.05rem; }
.step p { margin-top: 0.35rem; color: hsl(var(--fg-muted)); font-size: 0.92rem; }

/* Why us */
.feature-list .card { display: flex; flex-direction: column; gap: 0.5rem; }
.feature-icon {
  width: 2.75rem;
  height: 2.75rem;
  border-radius: var(--radius-sm);
  background: hsl(var(--accent) / 0.15);
  color: hsl(var(--accent));
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.25rem;
}

/* Generation banner */
.gen-banner {
  border-radius: var(--radius);
  padding: 2.5rem;
  background: linear-gradient(120deg, hsl(var(--primary) / 0.12), hsl(var(--accent) / 0.12));
  border: 1px solid hsl(var(--border));
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
}
.gen-banner .big { font-size: 2.5rem; font-weight: 800; color: hsl(var(--primary)); }

/* Testimonials */
.testimonial {
  padding: 2rem;
}
.testimonial p.quote { font-size: 1.05rem; color: hsl(var(--fg)); }
.testimonial .who {
  margin-top: 1.25rem;
  display: flex;
  align-items: center;
  gap: 0.75rem;
}
.testimonial .who img {
  width: 2.75rem;
  height: 2.75rem;
  border-radius: 999px;
  object-fit: cover;
}
.testimonial .who .name { font-weight: 700; font-size: 0.92rem; }
.testimonial .who .role { color: hsl(var(--fg-muted)); font-size: 0.8rem; }

/* Portfolio */
.portfolio-card { overflow: hidden; padding: 0; }
.portfolio-card img { height: 13rem; width: 100%; object-fit: cover; }
.portfolio-card .body { padding: 1.35rem; }
.portfolio-card .tag {
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  color: hsl(var(--secondary));
  text-transform: uppercase;
}

/* Forms (quote / booking / contact) */
.panel {
  background: hsl(var(--bg-elevated));
  border: 1px solid hsl(var(--border));
  border-radius: var(--radius);
  padding: 2rem;
}
.form-row { display: grid; grid-template-columns: minmax(0, 1fr); gap: 1rem; }
@media (min-width: 640px) { .form-row.two { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
label {
  display: block;
  font-size: 0.8rem;
  font-weight: 600;
  color: hsl(var(--fg-muted));
  margin-bottom: 0.4rem;
}
input, textarea, select {
  width: 100%;
  background: hsl(var(--bg));
  border: 1px solid hsl(var(--border));
  border-radius: var(--radius-sm);
  padding: 0.7rem 0.85rem;
  color: hsl(var(--fg));
  font: inherit;
  font-size: 0.9rem;
}
input:focus, textarea:focus, select:focus {
  outline: none;
  border-color: hsl(var(--primary));
}
textarea { resize: vertical; min-height: 6rem; }
.field { margin-bottom: 1rem; }
.form-note {
  font-size: 0.8rem;
  color: hsl(var(--fg-muted));
  margin-top: 0.9rem;
}
.form-status {
  margin-top: 1rem;
  padding: 0.85rem 1rem;
  border-radius: var(--radius-sm);
  font-size: 0.87rem;
  display: none;
}
.form-status.show { display: block; }
.form-status.ok { background: hsl(140 55% 45% / 0.15); border: 1px solid hsl(140 55% 45% / 0.4); color: hsl(140 60% 78%); }
.form-status.err { background: hsl(0 70% 45% / 0.15); border: 1px solid hsl(0 70% 45% / 0.4); color: hsl(0 80% 82%); }
.honeypot { position: absolute; left: -9999px; top: -9999px; opacity: 0; height: 0; }

.two-col { display: grid; grid-template-columns: minmax(0, 1fr); gap: 2.5rem; }
@media (min-width: 950px) { .two-col { grid-template-columns: minmax(0, 1.05fr) minmax(0, 0.95fr); align-items: start; } }

/* Mantención — video vertical + texto */
@media (min-width: 950px) {
  .mantencion-grid { grid-template-columns: minmax(240px, 320px) minmax(0, 1fr); align-items: center; }
}
.mantencion-video-wrap {
  position: relative;
  width: 100%;
  max-width: 320px;
  aspect-ratio: 9 / 16;
  margin: 0 auto;
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: 0 20px 50px hsl(215 60% 3% / 0.35);
  border: 1px solid hsl(var(--border));
  background: hsl(var(--bg-elevated));
}
.mantencion-video {
  position: absolute;
  inset: 0;
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.mantencion-video-caption {
  position: absolute;
  left: 0.75rem;
  right: 0.75rem;
  bottom: 0.75rem;
  padding: 0.5rem 0.75rem;
  border-radius: var(--radius-sm);
  background: hsl(215 45% 3% / 0.6);
  backdrop-filter: blur(4px);
  color: hsl(40 15% 96%);
  font-size: 0.78rem;
  font-weight: 600;
  line-height: 1.3;
  text-align: center;
}

/* Interactive availability calendar */
.cal-picker {
  border: 1px solid hsl(var(--border));
  border-radius: var(--radius-sm);
  padding: 1rem;
  background: hsl(var(--bg));
}
.cal-days {
  display: flex;
  gap: 0.5rem;
  overflow-x: auto;
  padding-bottom: 0.5rem;
  scrollbar-width: thin;
}
.cal-day-btn {
  flex: none;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.1rem;
  min-width: 2.75rem;
  padding: 0.4rem 0.3rem;
  border-radius: var(--radius-sm);
  border: 1px solid hsl(var(--border));
  background: hsl(var(--bg-elevated));
  color: hsl(var(--fg));
  font-size: 0.7rem;
  font-weight: 600;
}
.cal-day-btn .dow { font-size: 0.6rem; color: hsl(var(--fg-muted)); text-transform: uppercase; }
.cal-day-btn .num { font-size: 0.86rem; }
.cal-day-btn.selected {
  border-color: hsl(var(--primary));
  background: hsl(var(--primary) / 0.15);
  color: hsl(var(--primary));
}
.cal-day-btn:disabled {
  opacity: 0.35;
  cursor: not-allowed;
}
.cal-slots {
  margin-top: 0.9rem;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(4rem, 1fr));
  gap: 0.4rem;
}
.cal-slot-btn {
  padding: 0.4rem 0.3rem;
  border-radius: var(--radius-sm);
  border: 1px solid hsl(var(--border));
  background: hsl(var(--bg-elevated));
  color: hsl(var(--fg));
  font-size: 0.76rem;
  font-weight: 600;
  text-align: center;
}
.cal-slot-btn.selected {
  border-color: hsl(var(--primary));
  background: hsl(var(--primary));
  color: hsl(var(--primary-fg));
}
.cal-slot-btn:disabled {
  opacity: 0.3;
  text-decoration: line-through;
  cursor: not-allowed;
}
.cal-loading, .cal-empty {
  font-size: 0.85rem;
  color: hsl(var(--fg-muted));
  padding: 0.5rem 0;
}
.cal-note {
  margin-top: 0.6rem;
  font-size: 0.78rem;
  color: hsl(var(--fg-muted));
}

.cal-total {
  margin-top: 1rem;
  padding: 0.85rem 1rem;
  border-radius: var(--radius-sm);
  background: hsl(var(--primary) / 0.1);
  border: 1px solid hsl(var(--primary) / 0.35);
  font-weight: 700;
  font-size: 1rem;
  color: hsl(var(--fg));
}
.cal-total span { color: hsl(var(--primary)); }

/* Booking payment stub */
.payment-box {
  border: 1px dashed hsl(var(--primary) / 0.5);
  border-radius: var(--radius-sm);
  padding: 1.1rem 1.25rem;
  background: hsl(var(--primary) / 0.06);
  font-size: 0.85rem;
  color: hsl(var(--fg-muted));
  margin-top: 1.25rem;
}
.payment-box strong { color: hsl(var(--primary)); }

/* CTA final */
.cta-final {
  border-radius: var(--radius);
  padding: 3rem 2.5rem;
  text-align: center;
  background: linear-gradient(120deg, hsl(var(--bg-elevated)), hsl(var(--muted)));
  border: 1px solid hsl(var(--border));
}
.cta-final h2 { font-size: clamp(1.5rem, 3vw, 2rem); }
.cta-final p { margin-top: 0.75rem; color: hsl(var(--fg-muted)); max-width: 32rem; margin-inline: auto; }
.cta-final .actions { margin-top: 1.75rem; display: flex; flex-wrap: wrap; justify-content: center; gap: 0.85rem; }

/* Footer */
footer {
  border-top: 1px solid hsl(var(--border) / 0.6);
  padding: 3rem 0 2rem;
  color: hsl(var(--fg-muted));
  font-size: 0.85rem;
}
.footer-grid {
  display: grid;
  gap: 2rem;
  grid-template-columns: minmax(0, 1fr);
}
@media (min-width: 800px) { .footer-grid { grid-template-columns: minmax(0, 1.4fr) repeat(3, minmax(0, 1fr)); } }
.footer-grid h4 { color: hsl(var(--fg)); font-size: 0.85rem; margin-bottom: 0.9rem; }
.footer-grid a { display: block; padding: 0.3rem 0; }
.footer-grid a:hover { color: hsl(var(--primary)); }
.footer-bottom {
  margin-top: 2.5rem;
  padding-top: 1.5rem;
  border-top: 1px solid hsl(var(--border) / 0.5);
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 0.75rem;
}
.footer-legal-links a { color: inherit; }
.footer-legal-links a:hover { color: hsl(var(--primary)); }

/* FAQ */
.faq-list { display: flex; flex-direction: column; gap: 0.85rem; }
.faq-item {
  background: hsl(var(--bg-elevated));
  border: 1px solid hsl(var(--border));
  border-radius: var(--radius);
  padding: 0.3rem 1.5rem;
  transition: border-color 0.2s ease;
}
.faq-item[open] { border-color: hsl(var(--primary) / 0.4); }
.faq-item summary {
  list-style: none;
  cursor: pointer;
  padding: 1.1rem 1.75rem 1.1rem 0;
  position: relative;
  font-weight: 700;
  font-size: 0.98rem;
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::after {
  content: "+";
  position: absolute;
  right: 0;
  top: 50%;
  transform: translateY(-50%);
  font-size: 1.4rem;
  font-weight: 400;
  color: hsl(var(--primary));
  transition: transform 0.2s ease;
}
.faq-item[open] summary::after { transform: translateY(-50%) rotate(45deg); }
.faq-item p {
  color: hsl(var(--fg-muted));
  font-size: 0.9rem;
  line-height: 1.6;
  padding-bottom: 1.25rem;
}

/* Savings calculator */
.calc-compare {
  display: flex;
  align-items: flex-end;
  justify-content: center;
  gap: 3rem;
  padding: 1.5rem 1rem 0.5rem;
  margin-bottom: 1.5rem;
  border-bottom: 1px solid hsl(var(--border));
}
.calc-bar-col {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
  width: 6rem;
}
.calc-bar-value {
  font-size: 1.05rem;
  font-weight: 800;
  font-variant-numeric: tabular-nums;
}
.calc-bar-col:first-child .calc-bar-value { color: hsl(var(--fg-muted)); }
.calc-bar-col:last-child .calc-bar-value { color: hsl(var(--primary)); }
.calc-bar-track {
  width: 3.25rem;
  height: 9rem;
  display: flex;
  align-items: flex-end;
  background: hsl(var(--bg));
  border: 1px solid hsl(var(--border));
  border-radius: var(--radius-sm);
  overflow: hidden;
}
.calc-bar {
  width: 100%;
  height: 0%;
  border-radius: 0.2rem 0.2rem 0 0;
  transition: height 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}
.calc-bar-before { background: hsl(220 8% 40%); }
.calc-bar-after { background: hsl(var(--primary)); }
.calc-bar-label {
  font-size: 0.7rem;
  color: hsl(var(--fg-muted));
  text-align: center;
  line-height: 1.3;
}
.calc-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.85rem;
}
.calc-stat {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
  padding: 0.9rem;
  border-radius: var(--radius-sm);
  background: hsl(var(--bg));
  border: 1px solid hsl(var(--border));
}
.calc-label {
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  color: hsl(var(--fg-muted));
}
.calc-value {
  font-size: 1.15rem;
  font-weight: 800;
  color: hsl(var(--primary));
}

/* ---------- Reveal-on-scroll (gated, never on intrusive prefers-reduced-motion) ---------- */
.reveal { opacity: 1; transform: none; }
@media (prefers-reduced-motion: no-preference) {
  .reveal {
    opacity: 0;
    transform: translateY(16px);
    transition: opacity 0.6s ease, transform 0.6s ease;
  }
  .reveal.in-view { opacity: 1; transform: none; }
}

/* ---------- AI chat widget ---------- */
.chat-toggle {
  position: fixed;
  right: 1.25rem;
  bottom: 1.25rem;
  z-index: 60;
  width: 3.6rem;
  height: 3.6rem;
  border-radius: 999px;
  background: hsl(var(--primary));
  color: hsl(var(--primary-fg));
  display: flex;
  align-items: center;
  justify-content: center;
  border: none;
  box-shadow: 0 10px 30px hsl(var(--shadow-color) / 0.5);
  font-size: 1.5rem;
}
.chat-window {
  position: fixed;
  right: 1.25rem;
  bottom: 5.25rem;
  z-index: 60;
  width: min(23rem, calc(100vw - 2rem));
  height: min(32rem, calc(100vh - 8rem));
  background: hsl(var(--bg-elevated));
  border: 1px solid hsl(var(--border));
  border-radius: var(--radius);
  display: none;
  flex-direction: column;
  overflow: hidden;
  box-shadow: 0 20px 60px hsl(var(--shadow-color) / 0.6);
}
.chat-window.open { display: flex; }
.chat-head {
  padding: 1rem 1.15rem;
  border-bottom: 1px solid hsl(var(--border));
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.chat-head .title { font-weight: 700; font-size: 0.95rem; }
.chat-head .subtitle { font-size: 0.75rem; color: hsl(var(--fg-muted)); }
.chat-close { background: none; border: none; color: hsl(var(--fg-muted)); font-size: 1.1rem; }
.chat-body {
  flex: 1;
  overflow-y: auto;
  padding: 1rem 1.15rem;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}
.chat-msg {
  max-width: 85%;
  padding: 0.65rem 0.85rem;
  border-radius: 0.85rem;
  font-size: 0.87rem;
  line-height: 1.45;
}
.chat-msg.bot {
  background: hsl(var(--muted));
  align-self: flex-start;
  border-bottom-left-radius: 0.2rem;
}
.chat-msg.user {
  background: hsl(var(--primary));
  color: hsl(var(--primary-fg));
  align-self: flex-end;
  border-bottom-right-radius: 0.2rem;
}
.chat-msg .wa-link {
  display: inline-flex;
  margin-top: 0.55rem;
  align-items: center;
  gap: 0.4rem;
  background: #25d366;
  color: #06210f;
  font-weight: 700;
  font-size: 0.78rem;
  padding: 0.45rem 0.8rem;
  border-radius: 999px;
}
.chat-typing { font-size: 0.78rem; color: hsl(var(--fg-muted)); padding: 0 1.15rem 0.5rem; display: none; }
.chat-typing.show { display: block; }
.chat-input-row {
  display: flex;
  gap: 0.5rem;
  padding: 0.85rem;
  border-top: 1px solid hsl(var(--border));
}
.chat-input-row input {
  flex: 1;
}
.chat-input-row button {
  background: hsl(var(--primary));
  color: hsl(var(--primary-fg));
  border: none;
  border-radius: var(--radius-sm);
  padding: 0 1rem;
  font-weight: 700;
}

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