:root {
  --red: #D71920;
  --red-dark: #A81319;
  --charcoal: #2E2E2E;
  --ink: #111111;
  --white: #FFFFFF;
  --gray-light: #F2F2F2;
  --gray-mid: #D8D8D8;
  --bg: var(--white);
  --bg-alt: var(--gray-light);
  --text: var(--charcoal);
  --text-soft: #5B5B5B;
  --card-bg: var(--white);
  --border: #E4E4E4;
  box-sizing: border-box;
  padding-top: env(safe-area-inset-top, 0px);
  padding-bottom: env(safe-area-inset-bottom, 0px);
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #1B1B1B;
    --bg-alt: #232323;
    --text: #F2F2F2;
    --text-soft: #B7B7B7;
    --card-bg: #262626;
    --border: #3A3A3A;
  }
}
:root[data-theme="dark"] {
  --bg: #1B1B1B;
  --bg-alt: #232323;
  --text: #F2F2F2;
  --text-soft: #B7B7B7;
  --card-bg: #262626;
  --border: #3A3A3A;
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: calc(var(--section-offset, 152px) + env(safe-area-inset-top, 0px)); }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: Montserrat, 'Segoe UI', Arial, sans-serif;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; display: block; }
h1, h2, h3 {
  font-family: 'Bebas Neue', Impact, 'Arial Narrow', sans-serif;
  letter-spacing: 0.02em;
  line-height: 1.05;
  margin: 0;
  color: var(--text);
}
a { color: inherit; }
.wrap { max-width: 1120px; margin: 0 auto; padding: 0 24px; }
.stripe {
  height: 6px;
  background: repeating-linear-gradient(135deg, var(--red) 0 22px, var(--white) 22px 44px);
}

/* ---- Header ---- */
header {
  position: sticky; top: 0; z-index: 40;
  background: var(--bg);
  border-bottom: 1px solid var(--border);
}
.nav {
  display: flex; align-items: center; justify-content: space-between;
  padding: 16px 24px;
  padding-top: calc(16px + env(safe-area-inset-top, 0px));
}
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; }
.brand img { height: 42px; width: auto; display: block; }
.brand-name { font-family: 'Bebas Neue', sans-serif; font-size: 22px; letter-spacing: 0.03em; }
.brand-name span { color: var(--red); }
.nav-cta {
  display: inline-flex; align-items: center; gap: 8px;
  background: #25D366; color: var(--white);
  padding: 10px 18px; border-radius: 4px;
  text-decoration: none; font-weight: 700; font-size: 14px;
  white-space: nowrap;
}
.nav-cta:hover { background: #1EBE5A; }

/* ---- Hero ---- */
.hero {
  position: relative;
  min-height: 78vh;
  display: flex; align-items: flex-end;
  background-image:
    linear-gradient(0deg, rgba(17,17,17,0.86) 0%, rgba(17,17,17,0.45) 55%, rgba(46,15,15,0.35) 100%),
    url('/img/hero.webp');
  background-size: cover;
  background-position: center;
}
.hero-inner { padding: 64px 24px 48px; width: 100%; color: var(--white); }
.eyebrow-bar {
  display: inline-flex; align-items: center; gap: 10px;
  color: var(--white); font-size: 13px; font-weight: 600;
  background: var(--red); padding: 6px 12px; margin-bottom: 18px;
}
.hero h1 {
  font-size: clamp(40px, 8vw, 76px);
  color: var(--white);
  max-width: 14ch;
}
.hero p {
  max-width: 46ch; margin-top: 16px; font-size: 17px; color: #EDEDED;
}
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 28px; }
.btn {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 14px 24px; border-radius: 4px;
  font-weight: 700; font-size: 15px; text-decoration: none;
  border: 2px solid transparent;
}
.btn-primary { background: #25D366; color: var(--white); }
.btn-primary:hover { background: #1EBE5A; }
.btn-outline { border-color: var(--white); color: var(--white); }
.btn-outline:hover { background: rgba(255,255,255,0.12); }

/* ---- Sections ---- */
section { padding: 72px 0; }
.section-alt { background: var(--bg-alt); }
.kicker {
  color: var(--red); font-weight: 700; font-size: 14px;
  margin-bottom: 8px; display: block;
}
.section-head { max-width: 640px; margin-bottom: 40px; }
.section-head h2 { font-size: clamp(30px, 5vw, 44px); }
.section-head p { color: var(--text-soft); margin-top: 12px; font-size: 16px; }

/* ---- Services ---- */
.services-grid {
  display: grid; gap: 20px;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
}
.service-card {
  background: var(--card-bg);
  border: 1px solid var(--border);
  border-top: 4px solid var(--red);
  padding: 28px 22px;
}
.service-card h3 { font-size: 24px; margin-bottom: 10px; }
.service-card p { color: var(--text-soft); font-size: 15px; margin: 0; }
.service-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 24px; }
.audience-title { font-size: 28px; margin: 48px 0 20px; }
.service-card .wa-link { margin-top: 14px; }
.wa-link {
  display: inline-block; margin-top: 10px; font-size: 14px; font-weight: 700;
  color: #128C4A; text-decoration: none;
}
.wa-link:hover { text-decoration: underline; }
.page-head { padding-top: 64px; }
.page-head h1 { font-size: clamp(32px, 6vw, 52px); max-width: 22ch; }
.page-head p { color: var(--text-soft); font-size: 17px; max-width: 60ch; margin-top: 14px; }
.steps { margin: 0; padding-left: 22px; max-width: 720px; }
.steps li { margin-bottom: 14px; color: var(--text-soft); font-size: 16px; }
.steps li strong { color: var(--text); }
.dept-title { font-size: 24px; color: var(--white); margin: 0; }
.services-note {
  margin-top: 28px; padding-top: 24px; border-top: 1px solid var(--border);
  color: var(--text-soft); font-size: 15px;
}

.depts { display: grid; gap: 24px; grid-template-columns: 1fr 1fr; }
.dept { background: var(--card-bg); border: 1px solid var(--border); }
.dept-head {
  background: var(--ink); color: var(--white);
  padding: 20px 24px;
  display: flex; align-items: baseline; justify-content: space-between; gap: 12px;
}
.dept-head h3 { font-size: 24px; color: var(--white); margin: 0; }
.dept-head span { font-size: 12px; color: #B7B7B7; font-weight: 600; }
.dept ul { list-style: none; margin: 0; padding: 22px 24px; }
.dept li {
  position: relative; padding-left: 22px; margin-bottom: 14px;
  font-size: 15px; color: var(--text-soft);
}
.dept li:last-child { margin-bottom: 0; }
.dept li::before {
  content: ""; position: absolute; left: 0; top: 8px;
  width: 9px; height: 9px; background: var(--red);
}
.dept li strong { color: var(--text); font-weight: 700; }
.dept-foot {
  padding: 14px 24px 20px; font-size: 12.5px; color: var(--text-soft);
  border-top: 1px solid var(--border);
}

.products-grid {
  display: grid; gap: 20px;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
}
.product-card {
  background: var(--card-bg); border: 1px solid var(--border);
  overflow: hidden;
}
.product-photo {
  aspect-ratio: 4/3; background: var(--bg-alt);
  display: flex; align-items: center; justify-content: center;
  overflow: hidden;
}
.product-photo img { width: 100%; height: 100%; object-fit: contain; }
.product-info { padding: 18px 20px; }
.product-info h3 { font-size: 20px; margin-bottom: 6px; }
.product-info p { color: var(--text-soft); font-size: 14px; margin: 0; }
.products-cta { text-align: center; margin-top: 32px; }
.review-cta {
  text-align: center; margin-top: 40px; padding-top: 36px;
  border-top: 1px solid var(--border);
}
.review-stars { font-size: 22px; letter-spacing: 4px; color: #F5A623; margin-bottom: 10px; }
.review-cta p { color: var(--text-soft); font-size: 15px; margin-bottom: 16px; }
.btn-review { background: #F5A623; color: var(--ink); }
.btn-review:hover { background: #DD9414; }
.products-note {
  display: inline-block; text-align: left; max-width: 560px;
  background: var(--card-bg); border-left: 4px solid var(--red);
  padding: 14px 18px; margin: 0 auto 20px; font-size: 15px;
  font-weight: 600; color: var(--text);
}

/* ---- Opiniones ---- */
.reviews-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 20px; }
.review-card {
  background: var(--card-bg); border: 1px solid var(--border); border-top: 4px solid var(--red);
  padding: 22px 22px 18px; display: flex; flex-direction: column; gap: 12px; margin: 0;
}
.review-card .stars { color: #F5A623; letter-spacing: 3px; font-size: 18px; line-height: 1; }
.review-card blockquote { margin: 0; font-size: 15px; color: var(--text); flex: 1; }
.review-card figcaption { font-size: 13px; font-weight: 700; color: var(--text-soft); display: flex; align-items: center; gap: 8px; }
.review-card figcaption .g { font-weight: 500; }
.reviews-cta { text-align: center; margin-top: 28px; }
.btn-ghost { border: 2px solid var(--text); color: var(--text); background: transparent; }
.btn-ghost:hover { background: var(--bg-alt); }

/* ---- About ---- */
.about { display: grid; grid-template-columns: 1.1fr 0.9fr; gap: 48px; align-items: center; }
.about-photo { overflow: hidden; }
.about-photo img { width: 100%; height: 100%; object-fit: cover; }
.about-copy p { margin: 0 0 16px; color: var(--text-soft); font-size: 16px; }
.about-copy p:last-child { margin-bottom: 0; }
.pillars { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; margin-top: 28px; max-width: 360px; }
.pillar { min-width: 0; }
.pillar .num { font-family: 'Bebas Neue', sans-serif; font-size: 34px; color: var(--red); display: block; }
.pillar .label { font-size: 13px; color: var(--text-soft); font-weight: 600; }

/* ---- Gallery ---- */
.gallery-grid {
  display: grid; gap: 4px;
  grid-template-columns: repeat(3, 1fr);
}
.gallery-item { position: relative; overflow: hidden; aspect-ratio: 1 / 1; background: var(--ink); }
.gallery-item img { width: 100%; height: 100%; object-fit: cover; transition: transform .35s ease; }
.gallery-item:hover img { transform: scale(1.06); }
.gallery-cap {
  position: absolute; left: 0; right: 0; bottom: 0;
  background: linear-gradient(0deg, rgba(17,17,17,0.82), rgba(17,17,17,0));
  color: var(--white); font-size: 13px; font-weight: 600;
  padding: 24px 12px 10px;
}

/* ---- Coverage / contact ---- */
.contact-grid {
  display: grid; grid-template-columns: 1fr 1fr; gap: 40px;
}
.contact-block h3 { font-size: 22px; margin-bottom: 14px; }
.contact-row {
  display: flex; gap: 14px; padding: 14px 0;
  border-bottom: 1px solid var(--border);
  font-size: 15px;
}
.contact-row:last-child { border-bottom: none; }
.contact-row .k { color: var(--text-soft); min-width: 110px; font-weight: 600; }
.contact-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 20px; align-items: center; }
.social-icon {
  display: inline-flex; align-items: center; justify-content: center;
  width: 48px; height: 48px; border-radius: 12px;
  color: var(--white); flex: none;
}
.social-icon.fb { background: #1877F2; border-radius: 50%; }
.social-icon.fb:hover { background: #145DBF; }
.social-icon.ig {
  background: radial-gradient(circle at 30% 107%, #fdf497 0%, #fdf497 5%, #fd5949 45%, #d6249f 60%, #285AEB 90%);
}
.social-icon.ig:hover { filter: brightness(1.08); }
.social-icon.maps { background: var(--red); border-radius: 50%; }
.social-icon.maps:hover { background: var(--red-dark); }
.social-icon svg { width: 24px; height: 24px; }
.btn-dark { background: var(--ink); color: var(--white); }
.btn-dark:hover { background: #000; }

.zone-card {
  background: var(--card-bg); border: 1px solid var(--border);
  padding: 28px; height: 100%;
}
.zone-tag {
  display: inline-block; background: var(--bg-alt); color: var(--text);
  padding: 5px 12px; font-size: 13px; font-weight: 600; margin: 4px 6px 0 0;
  border: 1px solid var(--border);
}

/* ---- Footer / privacy ---- */
footer { background: var(--ink); color: #D9D9D9; padding: 48px 0 32px; }
.footer-top {
  display: flex; justify-content: space-between; align-items: center;
  flex-wrap: wrap; gap: 16px; padding-bottom: 28px; border-bottom: 1px solid #3A3A3A;
}
.footer-top .brand-name { color: var(--white); }
.footer-links { display: flex; gap: 22px; flex-wrap: wrap; font-size: 14px; }
.footer-links a { text-decoration: none; color: #C9C9C9; }
.footer-links a:hover { color: var(--white); }
.footer-bottom {
  margin-top: 22px; font-size: 13px; color: #8C8C8C;
  display: flex; justify-content: space-between; flex-wrap: wrap; gap: 8px;
}

#privacidad { padding: 72px 0; background: var(--bg-alt); }
.policy { max-width: 760px; }
.policy h3 { font-size: 20px; margin: 28px 0 10px; }
.policy p, .policy li { color: var(--text-soft); font-size: 15px; }
.policy ul { padding-left: 20px; }

@media (max-width: 820px) {
  .depts { grid-template-columns: 1fr; }
  .about { grid-template-columns: 1fr; }
  .about-photo { order: -1; aspect-ratio: 16/9; }
  .contact-grid { grid-template-columns: 1fr; }
  .gallery-grid { grid-template-columns: repeat(2, 1fr); }
  .nav-cta span.long { display: none; }
}
@media (max-width: 480px) {
  section { padding: 52px 0; }
  .hero-inner { padding: 40px 18px 36px; }
  .nav { padding-left: 16px; padding-right: 16px; gap: 8px; }
  .brand { gap: 6px; min-width: 0; }
  .brand img { height: 30px; }
  .brand-name { font-size: 14px; letter-spacing: 0.01em; white-space: nowrap; }
  .nav-cta { padding: 8px 12px; font-size: 13px; }
  .contact-actions .btn { width: 100%; justify-content: center; }
}

/* Menú de secciones: enlaces nativos, sin scripts ni dependencias. */
.section-menu { padding-top: 8px; padding-bottom: 8px; }
.section-menu ul { list-style: none; margin: 0; padding: 0; }
.section-menu-desktop { display: flex; justify-content: center; flex-wrap: wrap; gap: 4px 12px; }
.section-menu a { display: block; padding: 12px 10px; text-decoration: none; font-size: 14px; font-weight: 700; border-radius: 4px; }
.section-menu a:hover { background: var(--bg-alt); color: var(--red); }
.section-menu a:focus-visible, .section-menu summary:focus-visible { outline: 3px solid var(--red); outline-offset: 2px; }
.section-menu-mobile { display: none; }
@media (max-width: 820px) {
  .section-menu-desktop { display: none; }
  .section-menu-mobile { display: block; }
  .section-menu summary { cursor: pointer; padding: 12px 0; font-weight: 700; font-size: 14px; }
  .section-menu-mobile ul { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 4px; padding-top: 8px; padding-bottom: 8px; }
}
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

/* El menú comparte la cabecera sticky. El espacio incluye el desplegable móvil. */
header .section-menu { border-top: 1px solid var(--border); }
@media (max-width: 820px) {
  html { --section-offset: 152px; }
  html:has(.section-menu-mobile[open]) { --section-offset: 364px; }
}
@media (max-width: 480px) {
  html { --section-offset: 136px; }
  html:has(.section-menu-mobile[open]) { --section-offset: 348px; }
}

/* Textos SEO local y preguntas frecuentes visibles. */
.hero h1 { max-width: 22ch; font-size: clamp(34px, 5.6vw, 64px); }
.hero .hero-tagline { font-weight: 700; font-size: clamp(18px, 2.4vw, 24px); max-width: 36ch; }
.faq-list { max-width: 800px; }
.faq-item { padding: 24px 0; border-bottom: 1px solid var(--border); }
.faq-item:first-child { padding-top: 0; }
.faq-item h3 { font-size: 26px; line-height: 1.2; }
.faq-item p { color: var(--text-soft); margin: 12px 0 0; }
.faq-item a { overflow-wrap: anywhere; }
/* Ocho accesos: desplegar en tablet para evitar una segunda fila fija. */
@media (max-width: 1020px) {
  .section-menu-desktop { display: none; }
  .section-menu-mobile { display: block; }
  .section-menu summary { cursor: pointer; padding: 12px 0; font-weight: 700; font-size: 14px; }
  .section-menu-mobile ul { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 4px; padding: 8px 0; }
  html { --section-offset: 152px; }
  html:has(.section-menu-mobile[open]) { --section-offset: 390px; }
}
@media (max-width: 480px) {
  html { --section-offset: 136px; }
  html:has(.section-menu-mobile[open]) { --section-offset: 374px; }
  .section-menu-mobile a { font-size: 13px; padding: 12px 4px; }
}
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .wa-link { color: #3DDC84; } }
:root[data-theme="dark"] .wa-link { color: #3DDC84; }


/* Tarjetas: acciones secundarias compactas, alineadas y sin bloques verdes repetidos. */
.audience-title + .services-grid .service-card { display: flex; flex-direction: column; }
.audience-title + .services-grid .service-card h3 { margin-bottom: 12px; }
.audience-title + .services-grid .service-card p { margin-bottom: 24px; }
.product-card { display: flex; flex-direction: column; }
.product-photo { flex-shrink: 0; }
.product-info { display: flex; flex-direction: column; flex: 1; align-items: flex-start; }
.product-info p { margin-bottom: 20px; }
.service-card .card-whatsapp, .product-info .card-whatsapp {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  align-self: flex-start; width: auto; max-width: 100%; min-height: 44px;
  margin-top: auto; padding: 9px 15px; border: 1px solid var(--gray-mid);
  border-radius: 24px; background: #111111; color: #FFFFFF; border-color: #111111;
  font-size: 13px; font-weight: 700; line-height: 1.35; text-decoration: none;
}
.card-whatsapp svg { width: 18px; height: 18px; flex: none; color: #3DDC84; }
.service-card .card-whatsapp:hover, .product-info .card-whatsapp:hover {
  border-color: #333333; background: #333333;
}
.card-whatsapp:focus-visible, .consorcios-link:focus-visible {
  outline: 3px solid var(--red); outline-offset: 3px;
}
.service-card .consorcios-link {
  display: inline-flex; align-items: center; justify-content: center;
  align-self: flex-start; max-width: 100%; min-height: 44px;
  margin-top: auto; margin-bottom: 12px; padding: 9px 12px;
  border: 1px solid var(--red); border-radius: 5px;
  background: var(--card-bg); color: var(--text);
  font-size: 13px; line-height: 1.35; text-align: left; white-space: normal;
}
.service-card .consorcios-link:hover { background: var(--red); color: var(--white); }
.service-card .consorcios-link + .card-whatsapp { margin-top: 0; }
.product-info .recambio-note {
  margin-top: 0; margin-bottom: 20px; padding: 0 0 0 10px;
  border-left: 2px solid var(--red); color: var(--text);
  font-size: 13px; line-height: 1.5; background: transparent;
}
/* Pedidos por servicio: opciones secundarias, el verde se reserva a las llamadas principales. */
#servicios .service-actions .btn {
  background: var(--card-bg); color: var(--text); border: 1px solid var(--border);
  padding: 10px 16px; font-size: 14px;
}
#servicios .service-actions .btn:hover { border-color: var(--red); background: var(--bg-alt); }
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .card-whatsapp svg { color: #3DDC84; }
}
:root[data-theme="dark"] .card-whatsapp svg { color: #3DDC84; }
