/* M33Chem — estilos del sitio */

:root {
  --navy: #0B2C50;
  --navy-900: #071d36;
  --teal: #1A8288;
  --teal-600: #146a6f;
  --teal-light: #5CC3C8;
  --ink: #1c2b3a;
  --muted: #5a6b7b;
  --line: #dbe5ec;
  --tint: #f2f7f9;
  --white: #ffffff;

  --font-head: "Montserrat", system-ui, sans-serif;
  --font-body: "Open Sans", system-ui, sans-serif;

  --radius: 14px;
  --radius-sm: 8px;
  --shadow: 0 10px 30px rgba(11, 44, 80, 0.08);
  --header-h: 72px;
  --container: 1160px;
}

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

html { scroll-behavior: smooth; scroll-padding-top: calc(var(--header-h) + 12px); }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 1rem;
  line-height: 1.65;
  color: var(--ink);
  background: var(--white);
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; height: auto; display: block; }
a { color: var(--teal); }
a:hover { color: var(--teal-600); }
h1, h2, h3 { font-family: var(--font-head); color: var(--navy); line-height: 1.2; margin: 0 0 .5em; }
h1 { font-size: clamp(2rem, 4.6vw, 3.25rem); font-weight: 800; }
h2 { font-size: clamp(1.6rem, 3.2vw, 2.4rem); font-weight: 800; }
h3 { font-size: 1.125rem; font-weight: 700; }
p { margin: 0 0 1em; }
ul, ol { margin: 0; padding: 0; list-style: none; }
figure { margin: 0; }

:focus-visible { outline: 3px solid var(--teal-light); outline-offset: 2px; }

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

.skip-link {
  position: absolute; left: 16px; top: -48px; z-index: 100;
  background: var(--navy); color: var(--white); padding: 8px 14px; border-radius: var(--radius-sm);
}
.skip-link:focus { top: 12px; }

/* Botones */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .5em;
  font-family: var(--font-head); font-weight: 700; font-size: 1rem;
  padding: .85em 1.5em; border-radius: 999px; border: 2px solid transparent;
  text-decoration: none; cursor: pointer; transition: background .2s, color .2s, border-color .2s, transform .2s;
}
.btn:hover { transform: translateY(-1px); }
.btn-primary { background: var(--teal); color: var(--white); }
.btn-primary:hover { background: var(--teal-600); color: var(--white); }
.btn-ghost { border-color: rgba(255,255,255,.7); color: var(--white); }
.btn-ghost:hover { background: var(--white); color: var(--navy); }
.btn-sm { padding: .55em 1.1em; font-size: .9rem; }
.btn-block { width: 100%; }
.btn[disabled] { opacity: .6; cursor: progress; transform: none; }

.eyebrow {
  font-family: var(--font-head); font-weight: 700; font-size: .8rem;
  letter-spacing: .14em; text-transform: uppercase; color: var(--teal); margin-bottom: .75em;
}
.eyebrow-light { color: var(--teal-light); }

/* Encabezado */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(255,255,255,.96); backdrop-filter: saturate(1.4) blur(8px);
  border-bottom: 1px solid var(--line);
}
.header-inner { display: flex; align-items: center; justify-content: space-between; height: var(--header-h); }
.brand img { height: 40px; width: auto; }

.site-nav ul { display: flex; gap: 28px; }
.site-nav a:not(.btn) {
  font-family: var(--font-head); font-weight: 600; color: var(--navy); text-decoration: none; font-size: .98rem;
}
.site-nav a:not(.btn):hover { color: var(--teal); }

.nav-toggle {
  display: none; width: 44px; height: 44px; padding: 10px; border: 0; background: none; cursor: pointer;
}
.nav-toggle span { display: block; height: 2px; background: var(--navy); margin: 5px 0; transition: transform .2s, opacity .2s; }

@media (min-width: 861px) {
  .site-nav { display: flex; align-items: center; gap: 32px; }
}
@media (max-width: 860px) {
  .nav-toggle { display: block; }
  .site-nav {
    position: absolute; inset: var(--header-h) 0 auto 0;
    background: var(--white); border-bottom: 1px solid var(--line); box-shadow: var(--shadow);
    padding: 8px 16px 20px; display: none;
  }
  .site-nav.is-open { display: block; }
  .site-nav ul { flex-direction: column; gap: 0; margin-bottom: 12px; }
  .site-nav li a { display: block; padding: 12px 4px; border-bottom: 1px solid var(--line); }
  .site-nav .btn { width: 100%; }
  .nav-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
  .nav-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
  .nav-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }
}

/* Portada */
.hero { position: relative; color: var(--white); background: var(--navy); overflow: hidden; }
.hero-media { position: absolute; inset: 0; }
.hero-media img { width: 100%; height: 100%; object-fit: cover; object-position: 30% center; }
.hero-media::after {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(90deg, rgba(7,29,54,.92) 0%, rgba(7,29,54,.78) 45%, rgba(7,29,54,.35) 100%);
}
.hero-content { position: relative; padding: clamp(64px, 10vw, 128px) 0 48px; max-width: 760px; margin-left: max(16px, calc((100% - var(--container)) / 2)); }
.hero h1 { color: var(--white); }
.hero .eyebrow { color: var(--teal-light); }
.hero .lead { font-size: clamp(1.05rem, 1.6vw, 1.2rem); color: rgba(255,255,255,.88); max-width: 62ch; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 28px; }

.hero-stats {
  position: relative; display: grid; grid-template-columns: repeat(3, 1fr); gap: 1px;
  background: rgba(255,255,255,.18); border-radius: var(--radius); overflow: hidden;
  margin-bottom: 48px; backdrop-filter: blur(4px);
}
.hero-stats li { background: rgba(7,29,54,.7); padding: 20px 24px; }
.hero-stats strong { display: block; font-family: var(--font-head); font-size: 1.75rem; font-weight: 800; color: var(--teal-light); line-height: 1.1; }
.hero-stats span { font-size: .92rem; color: rgba(255,255,255,.85); }
@media (max-width: 700px) { .hero-stats { grid-template-columns: 1fr; } }

/* Secciones */
.section { padding: clamp(64px, 9vw, 112px) 0; }
.section-tint { background: var(--tint); }
.section-head { text-align: center; max-width: 720px; margin: 0 auto 48px; }
.section-head p:last-child { color: var(--muted); }
.section-head-left { text-align: left; margin: 0 0 28px; }

/* Nosotros */
.about-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 48px; align-items: center; }
.about-media img { width: 100%; border-radius: var(--radius); box-shadow: var(--shadow); aspect-ratio: 16 / 10; object-fit: cover; }
.feature-list { display: grid; gap: 28px; }
.feature { display: grid; grid-template-columns: 56px 1fr; gap: 18px; align-items: start; }
.feature p { color: var(--muted); margin: 0; }
.feature-icon {
  width: 56px; height: 56px; border-radius: 50%; background: var(--teal); color: var(--white);
  display: grid; place-items: center;
}
.feature-icon svg { width: 26px; height: 26px; }
@media (max-width: 860px) { .about-grid { grid-template-columns: 1fr; gap: 32px; } }

/* Sectores */
.sector-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 24px; }
.sector-card {
  background: var(--white); border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow);
  transition: transform .25s, box-shadow .25s;
}
.sector-card:hover { transform: translateY(-4px); box-shadow: 0 16px 36px rgba(11,44,80,.14); }
.sector-card img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; }
.sector-card h3 { padding: 18px 20px; margin: 0; }
@media (max-width: 960px) { .sector-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 520px) { .sector-grid { grid-template-columns: 1fr; } }

/* Productos */
.products-grid { display: grid; grid-template-columns: 1.15fr 1fr; gap: 56px; align-items: center; }
.chips { display: flex; flex-wrap: wrap; gap: 10px; }
.chips li {
  font-size: .93rem; font-weight: 600; color: var(--navy);
  background: var(--tint); border: 1px solid var(--line); border-radius: 999px; padding: 7px 14px;
}
.products-note { margin-top: 24px; color: var(--muted); }
.products-media img { border-radius: var(--radius); box-shadow: var(--shadow); width: 100%; aspect-ratio: 4 / 3.2; object-fit: cover; }
@media (max-width: 860px) { .products-grid { grid-template-columns: 1fr; gap: 36px; } }

/* Condiciones */
.steps { display: grid; grid-template-columns: repeat(4, 1fr); gap: 24px; counter-reset: none; }
.step { background: var(--white); border-radius: var(--radius); padding: 28px 24px; box-shadow: var(--shadow); }
.step p { color: var(--muted); margin: 0; }
.step-num {
  display: grid; place-items: center; width: 44px; height: 44px; border-radius: 50%;
  background: var(--navy); color: var(--white); font-family: var(--font-head); font-weight: 800; margin-bottom: 16px;
}
@media (max-width: 960px) { .steps { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 520px) { .steps { grid-template-columns: 1fr; } }

.logistics {
  display: grid; grid-template-columns: minmax(0, 474px) 1fr; gap: 40px; align-items: center;
  margin-top: 40px; background: var(--white); border-radius: var(--radius); box-shadow: var(--shadow); overflow: hidden;
}
.logistics img { width: 100%; height: 100%; min-height: 260px; object-fit: cover; }
.logistics > div { padding: 32px 40px 32px 0; }
.logistics h3 { font-size: 1.4rem; }
.logistics p { color: var(--muted); }
@media (max-width: 860px) {
  .logistics { grid-template-columns: 1fr; gap: 0; }
  .logistics img { min-height: 0; aspect-ratio: 16 / 9; }
  .logistics > div { padding: 24px; }
}

/* Contacto */
.section-dark { background: var(--navy); color: rgba(255,255,255,.88); }
.section-dark h2 { color: var(--white); }
.contact-grid { display: grid; grid-template-columns: 1fr 1.25fr; gap: 56px; align-items: start; }
.contact-list { display: grid; gap: 16px; margin-top: 28px; }
.contact-list li { display: flex; align-items: center; gap: 14px; }
.contact-list svg { width: 22px; height: 22px; color: var(--teal-light); flex: none; }
.contact-list a { color: var(--white); text-decoration: none; font-weight: 600; font-size: 1.05rem; }
.contact-list a:hover { color: var(--teal-light); }

.contact-form {
  background: var(--white); color: var(--ink); border-radius: var(--radius); padding: clamp(24px, 4vw, 40px);
  box-shadow: 0 20px 50px rgba(0,0,0,.25);
}
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 0 18px; }
.field { margin-bottom: 16px; }
.field label { display: block; font-size: .9rem; font-weight: 600; color: var(--navy); margin-bottom: 6px; }
.field input, .field select, .field textarea {
  width: 100%; font: inherit; font-size: 1rem; color: var(--ink);
  padding: 11px 14px; border: 1px solid #c8d5df; border-radius: var(--radius-sm); background: var(--white);
}
.field textarea { resize: vertical; min-height: 110px; }
.field input:focus, .field select:focus, .field textarea:focus { outline: none; border-color: var(--teal); box-shadow: 0 0 0 3px rgba(26,130,136,.2); }
.field [aria-invalid="true"] { border-color: #c0392b; }
.field-check { display: flex; gap: 10px; align-items: flex-start; }
.field-check input { width: 18px; height: 18px; margin-top: 3px; flex: none; accent-color: var(--teal); }
.field-check label { font-weight: 400; color: var(--ink); margin: 0; }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.form-status { margin: 14px 0 0; font-weight: 600; min-height: 1.5em; }
.form-status.is-error { color: #c0392b; }
.form-status.is-ok { color: var(--teal-600); }
@media (max-width: 860px) { .contact-grid { grid-template-columns: 1fr; gap: 36px; } }
@media (max-width: 520px) { .form-row { grid-template-columns: 1fr; } }

/* Pie */
.site-footer { background: var(--navy-900); color: rgba(255,255,255,.7); padding: 48px 0 32px; font-size: .93rem; }
.footer-inner { text-align: center; }
.footer-inner img { height: 36px; width: auto; margin: 0 auto 16px; }
.footer-links a { color: rgba(255,255,255,.85); text-decoration: none; }
.footer-links a:hover { color: var(--teal-light); }
.footer-links span { margin: 0 8px; }
.copyright { margin: 20px 0 0; font-size: .85rem; color: rgba(255,255,255,.5); }

/* WhatsApp flotante */
.whatsapp-float {
  position: fixed; right: 18px; bottom: 18px; z-index: 60;
  width: 56px; height: 56px; border-radius: 50%; background: #25D366; color: var(--white);
  display: grid; place-items: center; box-shadow: 0 8px 24px rgba(0,0,0,.25); transition: transform .2s;
}
.whatsapp-float:hover { transform: scale(1.07); color: var(--white); }
.whatsapp-float svg { width: 30px; height: 30px; }

/* Páginas legales */
.legal { padding: 56px 0 80px; }
.legal .container { max-width: 820px; }
.legal h1 { font-size: clamp(1.8rem, 3.5vw, 2.4rem); }
.legal h2 { font-size: 1.25rem; margin-top: 2em; }
.legal ul { list-style: disc; padding-left: 1.4em; margin-bottom: 1em; }
.legal .updated { color: var(--muted); }
