/* Grupo MAS – control ambiental
   Paleta tomada del logo: azul #032751, verde #09602e */
:root {
  --navy: #032751;
  --navy-800: #06315f;
  --navy-900: #021a37;
  --navy-950: #011228;
  --blue-50: #eef3f8;
  --blue-100: #dbe5ef;
  --green: #09602e;
  --green-700: #0a5229;
  --green-500: #12803f;
  --green-light: #6ec486;
  --wa: #1fa855;
  --ink: #18222e;
  --text: #36414d;
  --muted: #5d6874;
  --line: #d9e0e7;
  --white: #fff;
  --radius: 5px;
  --header-h: 78px;
  --container: 1200px;
  --shadow: 0 1px 2px rgba(2, 26, 55, .06), 0 4px 14px rgba(2, 26, 55, .06);
  --font-title: "Montserrat", Arial, sans-serif;
  --font-body: "Open Sans", Arial, sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.65;
  color: var(--text);
  background: var(--white);
  overflow-x: hidden;
}
body.menu-open { overflow: hidden; }
img { max-width: 100%; height: auto; display: block; }
a { color: var(--navy); }
h1, h2, h3, h4 { font-family: var(--font-title); color: var(--ink); line-height: 1.2; margin: 0 0 .6em; }
h2 { font-size: clamp(1.6rem, 1.2rem + 1.5vw, 2.25rem); font-weight: 700; color: var(--navy); }
h3 { font-size: 1.2rem; font-weight: 700; }
p { margin: 0 0 1em; }
ul { margin: 0; }
.container { width: 100%; max-width: var(--container); margin: 0 auto; padding: 0 20px; }
.section { padding: 88px 0; scroll-margin-top: calc(var(--header-h) - 1px); }
.section--soft { background: var(--blue-50); }
.section-head { max-width: 720px; margin-bottom: 44px; }
.section-head p { font-size: 1.05rem; color: var(--muted); }
.kicker {
  display: block;
  font-family: var(--font-title);
  font-size: .8rem;
  font-weight: 700;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--green);
  margin-bottom: 10px;
}
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.icon { width: 18px; height: 18px; flex: none; fill: currentColor; }

/* Botones */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 9px;
  font-family: var(--font-title); font-weight: 700; font-size: .95rem;
  padding: 14px 24px; border-radius: var(--radius); border: 2px solid transparent;
  text-decoration: none; cursor: pointer; transition: background .2s, border-color .2s, color .2s;
  line-height: 1.2;
}
.btn .icon { width: 20px; height: 20px; }
.btn--wa { background: var(--wa); color: #fff; }
.btn--wa:hover { background: #18914a; }
.btn--primary { background: var(--navy); color: #fff; }
.btn--primary:hover { background: var(--navy-800); }
.btn--green { background: var(--green); color: #fff; }
.btn--green:hover { background: var(--green-700); }
.btn--ghost { border-color: rgba(255, 255, 255, .85); color: #fff; }
.btn--ghost:hover { background: #fff; color: var(--navy); }
.btn--outline { border-color: var(--navy); color: var(--navy); background: transparent; }
.btn--outline:hover { background: var(--navy); color: #fff; }

/* Topbar */
.topbar { background: var(--green-700); color: #e6f2ea; font-size: .85rem; }
.topbar .container { display: flex; align-items: center; justify-content: space-between; gap: 16px; min-height: 40px; }
.topbar__info, .topbar__social { display: flex; align-items: center; gap: 22px; }
.topbar a { color: inherit; text-decoration: none; display: inline-flex; align-items: center; gap: 7px; white-space: nowrap; }
.topbar a:hover { color: #fff; text-decoration: underline; }
.topbar .icon { width: 15px; height: 15px; }
.topbar__hours { display: inline-flex; align-items: center; gap: 7px; }
.topbar__social a .icon { width: 16px; height: 16px; }

/* Header */
.header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(255, 255, 255, .96);
  backdrop-filter: saturate(1.4) blur(8px);
  -webkit-backdrop-filter: saturate(1.4) blur(8px);
  border-bottom: 1px solid var(--line);
}
.header .container { display: flex; align-items: center; justify-content: space-between; gap: 24px; height: var(--header-h); }
.brand img { width: 168px; height: auto; }
.nav { display: flex; align-items: center; gap: 30px; }
.nav__list { display: flex; gap: 26px; list-style: none; padding: 0; }
.nav__list a {
  font-family: var(--font-title); font-weight: 600; font-size: .92rem; color: var(--ink);
  text-decoration: none; padding: 6px 0; border-bottom: 2px solid transparent;
}
.nav__list a:hover, .nav__list a.is-active { color: var(--navy); border-bottom-color: var(--green); }
.nav__cta { padding: 12px 20px; font-size: .9rem; }
.menu-toggle {
  display: none; width: 44px; height: 44px; border: 1px solid var(--line); border-radius: var(--radius);
  background: #fff; cursor: pointer; padding: 0; align-items: center; justify-content: center;
}
.menu-toggle span, .menu-toggle span::before, .menu-toggle span::after {
  display: block; width: 20px; height: 2px; background: var(--navy); position: relative; transition: transform .2s, background .2s;
}
.menu-toggle span::before, .menu-toggle span::after { content: ""; position: absolute; left: 0; }
.menu-toggle span::before { top: -6px; }
.menu-toggle span::after { top: 6px; }
.menu-toggle[aria-expanded="true"] span { background: transparent; }
.menu-toggle[aria-expanded="true"] span::before { transform: translateY(6px) rotate(45deg); }
.menu-toggle[aria-expanded="true"] span::after { transform: translateY(-6px) rotate(-45deg); }

/* Hero */
.hero { position: relative; min-height: calc(100vh - var(--header-h) - 40px); min-height: calc(100svh - var(--header-h) - 40px); display: flex; align-items: center; overflow: hidden; background: var(--navy-950); color: #fff; }
.hero__slides { position: absolute; inset: 0; }
.hero__slide { position: absolute; inset: 0; opacity: 0; transition: opacity 1.4s ease; }
.hero__slide img { width: 100%; height: 100%; object-fit: cover; transform: scale(1); }
.hero__slide.is-active { opacity: 1; }
.hero__slide.is-active img { animation: heroZoom 8s ease-out forwards; }
@keyframes heroZoom { from { transform: scale(1); } to { transform: scale(1.08); } }
.hero::after {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(90deg, rgba(1, 18, 40, .9) 0%, rgba(1, 18, 40, .78) 38%, rgba(1, 18, 40, .25) 75%, rgba(1, 18, 40, .1) 100%);
}
.hero__content { position: relative; z-index: 2; padding-top: 80px; padding-bottom: 110px; }
.hero__inner { max-width: 640px; }
.hero__place { font-family: var(--font-title); font-weight: 600; font-size: .9rem; color: var(--green-light); letter-spacing: .04em; margin-bottom: 18px; }
.hero h1 { color: #fff; font-size: clamp(2rem, 1.3rem + 2.6vw, 3.3rem); font-weight: 800; margin-bottom: 22px; }
.hero__lead { font-size: 1.15rem; color: #dce6f0; max-width: 560px; margin-bottom: 32px; }
.hero__actions { display: flex; flex-wrap: wrap; gap: 14px; }
.hero__dots { position: absolute; z-index: 3; left: 0; right: 0; bottom: 34px; }
.hero__dots .container { display: flex; gap: 10px; }
.hero__dot { width: 34px; height: 4px; border: 0; padding: 0; background: rgba(255, 255, 255, .4); cursor: pointer; border-radius: 2px; }
.hero__dot.is-active { background: #fff; }
.hero__dot:focus-visible { outline: 2px solid #fff; outline-offset: 4px; }

/* Franja de contacto */
.strip { background: var(--green); color: #fff; }
.strip .container { display: grid; grid-template-columns: 1.3fr repeat(3, 1fr); gap: 0; align-items: stretch; }
.strip__title { padding: 26px 24px 26px 0; display: flex; flex-direction: column; justify-content: center; }
.strip__title strong { font-family: var(--font-title); font-size: 1.25rem; line-height: 1.25; }
.strip__title span { color: #d5ecdd; font-size: .95rem; }
.strip__item { display: flex; align-items: center; gap: 14px; padding: 22px 22px; border-left: 1px solid rgba(255, 255, 255, .22); color: #fff; text-decoration: none; }
a.strip__item:hover { background: var(--green-700); }
.strip__item .icon { width: 26px; height: 26px; }
.strip__item small { display: block; font-size: .78rem; text-transform: uppercase; letter-spacing: .08em; color: #cfe8d7; font-family: var(--font-title); font-weight: 600; }
.strip__item b { font-family: var(--font-title); font-weight: 700; font-size: .98rem; }

/* Servicios */
.services { display: grid; grid-template-columns: repeat(3, 1fr); gap: 28px; }
.service { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; display: flex; flex-direction: column; }
.service img { width: 100%; aspect-ratio: 16 / 10; object-fit: cover; }
.service__body { padding: 24px 24px 22px; display: flex; flex-direction: column; flex: 1; }
.service h3 { color: var(--navy); font-size: 1.25rem; margin-bottom: 4px; }
.service__pests { font-size: .88rem; color: var(--green); font-weight: 600; margin-bottom: 12px; }
.service p { font-size: .95rem; }
.service ul { list-style: none; padding: 0; margin: 0 0 20px; border-top: 1px solid var(--line); padding-top: 14px; }
.service li { position: relative; padding-left: 20px; font-size: .92rem; margin-bottom: 6px; color: var(--ink); }
.service li::before { content: ""; position: absolute; left: 2px; top: .62em; width: 8px; height: 8px; background: var(--green); }
.service__link { margin-top: auto; font-family: var(--font-title); font-weight: 700; font-size: .92rem; color: var(--navy); text-decoration: none; display: inline-flex; align-items: center; gap: 6px; }
.service__link:hover { color: var(--green); }
.service__link .icon { width: 16px; height: 16px; }

.also { margin-top: 36px; border: 1px solid var(--line); border-left: 4px solid var(--green); background: #fff; border-radius: var(--radius); padding: 26px 28px; display: grid; grid-template-columns: 220px 1fr; gap: 24px; }
.also h3 { color: var(--navy); margin: 0; }
.also ul { list-style: none; padding: 0; display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px 28px; }
.also li strong { display: block; font-family: var(--font-title); color: var(--ink); font-size: .98rem; margin-bottom: 2px; }
.also li span { font-size: .9rem; color: var(--muted); }

/* MIP */
.split { display: grid; grid-template-columns: 1fr 1fr; gap: 64px; align-items: center; }
.split__media img { width: 100%; border-radius: var(--radius); aspect-ratio: 4 / 5; object-fit: cover; }
.split__text p { font-size: 1.02rem; }
.steps { list-style: none; padding: 0; margin: 30px 0 0; counter-reset: step; display: grid; grid-template-columns: 1fr 1fr; gap: 26px 32px; }
.steps li { counter-increment: step; border-top: 2px solid var(--navy); padding-top: 14px; }
.steps li::before { content: "0" counter(step); display: block; font-family: var(--font-title); font-weight: 800; font-size: 1.5rem; color: var(--green); margin-bottom: 4px; line-height: 1; }
.steps strong { display: block; font-family: var(--font-title); color: var(--navy); font-size: 1.05rem; margin-bottom: 4px; }
.steps p { font-size: .93rem; margin: 0; }

/* Nosotros */
.about .split { grid-template-columns: 1.05fr 1fr; }
.about .split__media img { aspect-ratio: 4 / 3; }
.checks { list-style: none; padding: 0; margin: 22px 0 0; }
.checks li { display: flex; gap: 12px; padding: 12px 0; border-bottom: 1px solid var(--line); color: var(--ink); }
.checks li:last-child { border-bottom: 0; }
.checks .icon { color: var(--green); width: 22px; height: 22px; margin-top: 2px; }

/* Sectores */
.sectors { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.sector { position: relative; border-radius: var(--radius); overflow: hidden; aspect-ratio: 4 / 3; background: var(--navy); }
.sector img { width: 100%; height: 100%; object-fit: cover; transition: transform .5s ease; }
.sector:hover img { transform: scale(1.04); }
.sector__text { position: absolute; inset: auto 0 0 0; padding: 60px 22px 20px; color: #fff; background: linear-gradient(0deg, rgba(1, 18, 40, .9) 0%, rgba(1, 18, 40, .55) 60%, rgba(1, 18, 40, 0) 100%); }
.sector h3 { color: #fff; margin: 0 0 4px; font-size: 1.15rem; }
.sector p { margin: 0; font-size: .9rem; color: #d6e1ec; }

/* Cobertura */
.zones { display: grid; grid-template-columns: repeat(4, 1fr); gap: 22px; }
.zone { background: #fff; border: 1px solid var(--line); border-top: 4px solid var(--navy); border-radius: var(--radius); padding: 24px; }
.zone h3 { color: var(--navy); font-size: 1.1rem; display: flex; align-items: center; gap: 8px; }
.zone h3 .icon { color: var(--green); width: 20px; height: 20px; }
.zone p { font-size: .94rem; margin: 0; }
.zones__note { margin-top: 26px; font-size: .98rem; }
.zones__note a { font-weight: 600; }

/* Banda CTA */
.cta-band { position: relative; color: #fff; padding: 100px 0; overflow: hidden; background: var(--navy-900); }
.cta-band__bg { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.cta-band::after { content: ""; position: absolute; inset: 0; background: rgba(2, 26, 55, .78); }
.cta-band .container { position: relative; z-index: 2; max-width: 820px; text-align: center; }
.cta-band h2 { color: #fff; }
.cta-band p { font-size: 1.12rem; color: #dce6f0; margin-bottom: 28px; }

/* FAQ */
.faq { max-width: 860px; }
.faq details { border-bottom: 1px solid var(--line); }
.faq details:first-of-type { border-top: 1px solid var(--line); }
.faq summary {
  list-style: none; cursor: pointer; padding: 20px 40px 20px 0; position: relative;
  font-family: var(--font-title); font-weight: 600; font-size: 1.05rem; color: var(--navy);
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: ""; position: absolute; right: 8px; top: 50%; width: 10px; height: 10px; border-right: 2px solid var(--green); border-bottom: 2px solid var(--green); transform: translateY(-70%) rotate(45deg); transition: transform .2s; }
.faq details[open] summary::after { transform: translateY(-30%) rotate(-135deg); }
.faq details p { padding: 0 40px 10px 0; margin-top: -4px; }

/* Contacto */
.contact { display: grid; grid-template-columns: 1fr 1.5fr; gap: 56px; align-items: start; }
.contact__info ul { list-style: none; padding: 0; margin: 24px 0 28px; }
.contact__info li { display: flex; gap: 14px; padding: 14px 0; border-bottom: 1px solid var(--line); }
.contact__info li .icon { color: var(--green); width: 22px; height: 22px; margin-top: 3px; }
.contact__info small { display: block; font-family: var(--font-title); font-weight: 600; font-size: .78rem; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
.contact__info a, .contact__info b { color: var(--ink); font-weight: 600; text-decoration: none; }
.contact__info a:hover { color: var(--navy); text-decoration: underline; }

.form { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 32px; box-shadow: var(--shadow); }
.form h3 { color: var(--navy); }
.form__grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px 18px; }
.field { display: flex; flex-direction: column; gap: 6px; }
.field--full { grid-column: 1 / -1; }
.field label { font-family: var(--font-title); font-weight: 600; font-size: .86rem; color: var(--ink); }
.field label .opt { font-weight: 400; color: var(--muted); }
.field input, .field select, .field textarea {
  font: inherit; font-size: 1rem; color: var(--ink); width: 100%;
  border: 1px solid #c4ced8; border-radius: 4px; padding: 11px 12px; background: #fff;
}
.field textarea { min-height: 110px; resize: vertical; }
.field input:focus, .field select:focus, .field textarea:focus { outline: 2px solid var(--navy); outline-offset: 0; border-color: var(--navy); }
.field.has-error input, .field.has-error select, .field.has-error textarea { border-color: #b3261e; }
.field__error { color: #b3261e; font-size: .82rem; min-height: 0; }
.form__actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 22px; }
.form__note { font-size: .85rem; color: var(--muted); margin: 14px 0 0; }
.form__status { margin-top: 12px; font-size: .92rem; font-weight: 600; color: var(--green); }
.form__status.is-error { color: #b3261e; }

/* Footer */
.footer { background: var(--navy-950); color: #b9c6d4; font-size: .93rem; padding-top: 64px; }
.footer__grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1.2fr; gap: 40px; padding-bottom: 48px; }
.footer__brand img { width: 220px; margin-bottom: 18px; }
.footer h4 { color: #fff; font-size: .95rem; margin-bottom: 16px; }
.footer ul { list-style: none; padding: 0; }
.footer li { margin-bottom: 8px; }
.footer a { color: #b9c6d4; text-decoration: none; }
.footer a:hover { color: #fff; text-decoration: underline; }
.footer__contact li { display: flex; gap: 10px; }
.footer__contact .icon { color: var(--green-light); margin-top: 4px; width: 16px; height: 16px; }
.footer__social { display: flex; gap: 16px; margin-top: 18px; }
.footer__social a { display: inline-flex; }
.footer__social .icon { width: 22px; height: 22px; }
.footer__bottom { border-top: 1px solid rgba(255, 255, 255, .1); padding: 20px 0; font-size: .84rem; }
.footer__bottom .container { display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap; }

/* Flotantes */
.float-wa {
  position: fixed; right: 20px; bottom: 20px; z-index: 60; width: 58px; height: 58px; border-radius: 50%;
  background: #25d366; color: #fff; display: flex; align-items: center; justify-content: center;
  box-shadow: 0 4px 14px rgba(0, 0, 0, .25); transition: transform .2s;
}
.float-wa:hover { transform: scale(1.06); }
.float-wa .icon { width: 32px; height: 32px; }
.to-top {
  position: fixed; right: 29px; bottom: 92px; z-index: 60; width: 40px; height: 40px; border-radius: var(--radius);
  border: 0; background: var(--navy); color: #fff; cursor: pointer; display: flex; align-items: center; justify-content: center;
  opacity: 0; visibility: hidden; transition: opacity .25s, visibility .25s;
}
.to-top.is-visible { opacity: 1; visibility: visible; }
.to-top .icon { width: 18px; height: 18px; }

:focus-visible { outline: 2px solid var(--green); outline-offset: 2px; }

/* Responsive */
@media (max-width: 1100px) {
  .nav__list { gap: 18px; }
  .strip .container { grid-template-columns: 1fr 1fr 1fr; }
  .strip__title { grid-column: 1 / -1; padding: 22px 0 6px; }
  .strip__item:first-of-type { border-left: 0; padding-left: 0; }
  .zones { grid-template-columns: repeat(2, 1fr); }
  .footer__grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 960px) {
  :root { --header-h: 68px; }
  .brand img { width: 140px; }
  .menu-toggle { display: inline-flex; }
  .nav {
    position: absolute; top: 100%; left: 0; right: 0;
    height: calc(100dvh - var(--header-h));
    background: #fff; flex-direction: column; align-items: stretch; gap: 0;
    padding: 12px 20px 32px; overflow-y: auto;
    opacity: 0; visibility: hidden; transition: opacity .2s, visibility .2s;
    border-top: 1px solid var(--line);
  }
  .nav.is-open { opacity: 1; visibility: visible; }
  .nav__list { flex-direction: column; gap: 0; }
  .nav__list a { display: block; padding: 16px 0; font-size: 1.1rem; border-bottom: 1px solid var(--line); }
  .nav__list a:hover, .nav__list a.is-active { border-bottom-color: var(--line); color: var(--green); }
  .nav__cta { margin-top: 24px; padding: 16px; font-size: 1rem; }
  .services { grid-template-columns: 1fr 1fr; }
  .also { grid-template-columns: 1fr; }
  .split, .about .split { grid-template-columns: 1fr; gap: 36px; }
  .split__media img { aspect-ratio: 16 / 10; }
  .sectors { grid-template-columns: 1fr 1fr; }
  .contact { grid-template-columns: 1fr; gap: 36px; }
}

@media (max-width: 720px) {
  .section { padding: 64px 0; }
  .topbar .topbar__hours, .topbar .topbar__mail, .topbar .topbar__social { display: none; }
  .topbar .container { justify-content: center; }
  .hero { min-height: calc(100svh - var(--header-h) - 40px); }
  .hero::after { background: linear-gradient(90deg, rgba(1, 18, 40, .88) 0%, rgba(1, 18, 40, .72) 100%); }
  .hero__content { padding-top: 56px; padding-bottom: 96px; }
  .hero__lead { font-size: 1.05rem; }
  .hero__actions .btn { flex: 1 1 100%; }
  .strip .container { grid-template-columns: 1fr; }
  .strip__item, .strip__item:first-of-type { border-left: 0; border-top: 1px solid rgba(255, 255, 255, .22); padding: 16px 0; }
  .services, .sectors, .zones { grid-template-columns: 1fr; }
  .also ul { grid-template-columns: 1fr; }
  .steps { grid-template-columns: 1fr; }
  .form { padding: 22px 18px; }
  .form__grid { grid-template-columns: 1fr; }
  .form__actions .btn { flex: 1 1 100%; }
  .footer__grid { grid-template-columns: 1fr; gap: 32px; }
  .cta-band { padding: 72px 0; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .hero__slide { transition: none; }
  .hero__slide.is-active img { animation: none; }
  .sector img { transition: none; }
}

/* que el botón flotante no tape el pie */
.footer__bottom { padding-bottom: 28px; }
.footer__bottom .container { padding-right: 96px; }
