/* =========================================================
   Rapid Solutions — hoja de estilos principal
   ========================================================= */
:root {
  --red: #d9040a;
  --red-600: #b90308;
  --red-50: #fff1f1;
  --ink: #1b2230;          /* azul carbón del logo */
  --ink-2: #283346;
  --text: #2c3440;
  --muted: #626c7a;
  --line: #e3e7ed;
  --tint: #f4f6f9;
  --white: #fff;
  --wa: #1fa855;

  --radius: 14px;
  --radius-sm: 8px;
  --shadow: 0 1px 2px rgba(20, 28, 40, .06), 0 8px 24px rgba(20, 28, 40, .08);
  --shadow-lg: 0 18px 50px rgba(20, 28, 40, .16);

  --font: "Barlow", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --display: "Barlow Condensed", "Arial Narrow", var(--font);
  --container: 1200px;
  --gutter: clamp(16px, 4vw, 32px);
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0; font-family: var(--font); font-size: 17px; line-height: 1.65;
  color: var(--text); background: var(--white); -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--red); text-decoration-thickness: 1px; text-underline-offset: 3px; }
a:hover { color: var(--red-600); }
h1, h2, h3, h4 { color: var(--ink); line-height: 1.15; margin: 0 0 .5em; }
p { margin: 0 0 1em; }
:focus-visible { outline: 3px solid var(--red); outline-offset: 2px; border-radius: 4px; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip-link { position: absolute; left: 12px; top: -60px; z-index: 100; background: var(--ink); color: #fff; padding: 10px 16px; border-radius: 8px; }
.skip-link:focus { top: 12px; color: #fff; }

.container { width: 100%; max-width: var(--container); margin: 0 auto; padding: 0 var(--gutter); }
.container--narrow { max-width: 820px; }
.i { width: 1.15em; height: 1.15em; flex: none; vertical-align: -.2em; }
.i--sm { width: .8em; height: .8em; }

/* ---------- Botones ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .5em;
  padding: .72em 1.3em; border-radius: 999px; border: 2px solid transparent;
  font: 600 .95rem/1.2 var(--font); letter-spacing: .01em; text-decoration: none; cursor: pointer;
  transition: background .2s, color .2s, border-color .2s, transform .2s, box-shadow .2s;
}
.btn:hover { transform: translateY(-1px); }
.btn--lg { padding: .9em 1.6em; font-size: 1rem; }
.btn--sm { padding: .45em .95em; font-size: .85rem; }
.btn--block { width: 100%; }
.btn--primary { background: var(--red); color: #fff; box-shadow: 0 6px 18px rgba(217, 4, 10, .28); }
.btn--primary:hover { background: var(--red-600); color: #fff; }
.btn--dark { background: var(--ink); color: #fff; }
.btn--dark:hover { background: var(--ink-2); color: #fff; }
.btn--ghost { border-color: var(--line); color: var(--ink); background: #fff; }
.btn--ghost:hover { border-color: var(--red); color: var(--red); }
.btn--light { background: #fff; color: var(--red); }
.btn--light:hover { background: var(--red-50); color: var(--red-600); }
.btn--outline-light { border-color: rgba(255, 255, 255, .55); color: #fff; }
.btn--outline-light:hover { border-color: #fff; background: rgba(255, 255, 255, .1); color: #fff; }
.btn--whatsapp { background: var(--wa); color: #fff; margin-top: 8px; }
.btn--whatsapp:hover { background: #178d46; color: #fff; }

.link-arrow { display: inline-flex; align-items: center; gap: .4em; font-weight: 700; text-decoration: none; }
.link-arrow .i { transition: transform .2s; }
.link-arrow:hover .i { transform: translateX(3px); }

.eyebrow {
  display: inline-flex; align-items: center; gap: .6em; margin: 0 0 .6em;
  font: 700 .82rem/1.2 var(--font); letter-spacing: .14em; text-transform: uppercase; color: var(--red);
}
.eyebrow::before { content: ""; width: 26px; height: 3px; background: currentColor; transform: skewX(-25deg); }
.eyebrow--light { color: #ff6b6f; }

.section-title {
  font-family: var(--display); font-weight: 800; text-transform: uppercase; letter-spacing: .005em;
  font-size: clamp(1.9rem, 3.2vw, 2.7rem); line-height: 1.02;
}
.section-title a { color: inherit; text-decoration: none; }
.section-title a:hover { color: var(--red); }
.section-title--sm { font-size: clamp(1.5rem, 2.4vw, 1.9rem); margin-top: 2.2rem; }
.lead { font-size: 1.15rem; color: var(--ink-2); }

.section { padding: clamp(56px, 8vw, 96px) 0; }
.section--tint { background: var(--tint); }
.section--dark { background: var(--ink); color: #c9d0db; }
.section--dark .section-title, .section--dark h3 { color: #fff; }
.section-head { max-width: 680px; margin-bottom: clamp(28px, 4vw, 44px); }
.section-head__text { color: var(--muted); }
.section-head--row { max-width: none; display: flex; align-items: flex-end; justify-content: space-between; gap: 16px 32px; flex-wrap: wrap; }
.section-head--row .section-title { margin-bottom: 0; }

/* ---------- Topbar / Header ---------- */
.topbar { background: var(--ink); color: #aeb7c4; font-size: .85rem; }
.topbar__inner { display: flex; justify-content: space-between; align-items: center; gap: 16px; min-height: 40px; }
.topbar__tag { margin: 0; }
.topbar__info { display: flex; gap: 22px; list-style: none; margin: 0; padding: 0; }
.topbar__info li { display: inline-flex; align-items: center; gap: .45em; }
.topbar a { color: #fff; text-decoration: none; display: inline-flex; align-items: center; gap: .45em; }
.topbar a:hover { color: #ff9c9f; }

.site-header { position: sticky; top: 0; z-index: 50; background: rgba(255, 255, 255, .97); backdrop-filter: saturate(1.4) blur(8px); border-bottom: 1px solid transparent; transition: box-shadow .25s, border-color .25s; }
.site-header.is-scrolled { box-shadow: 0 6px 24px rgba(20, 28, 40, .08); border-color: var(--line); }
.site-header__inner { display: flex; align-items: center; justify-content: space-between; gap: 24px; min-height: 84px; }
.brand img { width: clamp(170px, 18vw, 220px); }

.nav { display: flex; align-items: center; gap: 28px; }
.nav__list { display: flex; align-items: center; gap: 4px; list-style: none; margin: 0; padding: 0; }
.nav__link {
  display: inline-flex; align-items: center; gap: .3em; padding: .55em .85em; border-radius: 8px;
  color: var(--ink); font-weight: 600; text-decoration: none; position: relative;
}
.nav__link::after { content: ""; position: absolute; left: .85em; right: .85em; bottom: .25em; height: 3px; background: var(--red); transform: scaleX(0); transform-origin: left; transition: transform .2s; }
.nav__link:hover { color: var(--red); }
.nav__link.is-active::after, .nav__link:hover::after { transform: scaleX(1); }
.nav__item--drop { position: relative; }
.nav__drop {
  position: absolute; top: calc(100% + 8px); left: -8px; min-width: 300px; list-style: none; margin: 0; padding: 8px;
  background: #fff; border: 1px solid var(--line); border-radius: 12px; box-shadow: var(--shadow-lg);
  opacity: 0; visibility: hidden; transform: translateY(6px); transition: opacity .2s, transform .2s, visibility .2s;
}
.nav__drop::before { content: ""; position: absolute; top: -12px; left: 0; right: 0; height: 12px; }
.nav__item--drop:hover .nav__drop, .nav__item--drop:focus-within .nav__drop { opacity: 1; visibility: visible; transform: none; }
.nav__drop a { display: flex; align-items: center; gap: 12px; padding: .6em .8em; border-radius: 8px; color: var(--text); text-decoration: none; font-size: .95rem; }
.nav__drop a strong { display: inline-grid; place-items: center; min-width: 46px; padding: .2em .4em; border-radius: 6px; background: var(--red-50); color: var(--red); font-family: var(--display); font-size: 1.05rem; }
.nav__drop a:hover { background: var(--tint); color: var(--ink); }

.nav-toggle { display: none; width: 46px; height: 46px; border: 1px solid var(--line); border-radius: 10px; background: #fff; cursor: pointer; padding: 12px 11px; flex-direction: column; justify-content: space-between; }
.nav-toggle > span:not(.sr-only) { display: block; height: 2px; background: var(--ink); border-radius: 2px; transition: transform .25s, opacity .25s; }
.nav-toggle[aria-expanded="true"] > span:nth-child(1) { transform: translateY(9px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] > span:nth-child(2) { opacity: 0; }
.nav-toggle[aria-expanded="true"] > span:nth-child(3) { transform: translateY(-9px) rotate(-45deg); }

/* ---------- Hero ---------- */
.hero { position: relative; overflow: hidden; background: radial-gradient(120% 90% at 85% 10%, #2c3950 0%, var(--ink) 55%, #121822 100%); color: #cfd6e0; }
.hero__lines { position: absolute; inset: auto 0 18% -10%; height: 60px; pointer-events: none;
  background: repeating-linear-gradient(180deg, rgba(255,255,255,.06) 0 3px, transparent 3px 12px); transform: skewY(-3deg); }
.hero__slide { display: none; }
.hero__slide.is-active { display: block; animation: heroIn .6s ease both; }
@keyframes heroIn { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }
.hero__grid { display: grid; grid-template-columns: 1.05fr .95fr; align-items: center; gap: 40px; padding-top: clamp(48px, 7vw, 88px); padding-bottom: clamp(64px, 8vw, 104px); }
.hero__title {
  font-family: var(--display); font-weight: 800; font-style: italic; text-transform: uppercase;
  font-size: clamp(2.6rem, 6vw, 4.6rem); line-height: .95; color: #fff; margin-bottom: .35em; letter-spacing: -.005em;
}
.hero__text { font-size: 1.15rem; max-width: 520px; }
.hero__actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 28px; }
.hero__visual { position: relative; }
.hero__visual::before { content: ""; position: absolute; inset: 8% -6% -6% 8%; border: 3px solid var(--red); border-radius: 22px; transform: skewX(-6deg); opacity: .8; }
.hero__visual img { position: relative; width: 100%; border-radius: 20px; box-shadow: 0 30px 70px rgba(0, 0, 0, .45); }
.hero__controls { position: absolute; left: 0; right: 0; bottom: 26px; display: flex; gap: 10px; }
.hero__dot { width: 34px; height: 5px; border: 0; border-radius: 3px; background: rgba(255, 255, 255, .28); cursor: pointer; padding: 0; transition: background .2s, width .2s; }
.hero__dot.is-active { background: var(--red); width: 54px; }

.stats-strip { background: var(--red); color: #fff; }
.stats-strip__grid { display: grid; grid-template-columns: repeat(4, 1fr); }
.stat { display: flex; align-items: center; gap: 14px; padding: 22px 18px; border-right: 1px solid rgba(255, 255, 255, .2); }
.stat:last-child { border-right: 0; }
.stat .i { width: 30px; height: 30px; opacity: .9; }
.stat strong { display: block; font-family: var(--display); font-size: 1.3rem; line-height: 1.1; text-transform: uppercase; }
.stat span { font-size: .88rem; opacity: .88; }

/* ---------- Split sections ---------- */
.split { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(32px, 6vw, 80px); align-items: center; }
.split--reverse .split__media { order: 2; }
.split__media--figure { display: flex; justify-content: center; position: relative; }
.split__media--figure::before { content: ""; position: absolute; width: 78%; aspect-ratio: 1; bottom: 0; border-radius: 50%; background: radial-gradient(circle, var(--red-50), #ffe0e1 70%); }
.split__media--figure img { position: relative; max-height: 560px; width: auto; }
.rounded { border-radius: var(--radius); }

.feature-list { list-style: none; margin: 28px 0 0; padding: 0; display: grid; gap: 22px; }
.feature-list li { display: flex; gap: 18px; align-items: flex-start; }
.feature-list h3 { font-size: 1.15rem; margin-bottom: .2em; }
.feature-list p { margin: 0; color: var(--muted); }
.feature-list__icon { display: grid; place-items: center; width: 52px; height: 52px; border-radius: 14px; background: var(--red-50); color: var(--red); flex: none; }
.feature-list__icon .i { width: 24px; height: 24px; }

/* ---------- Categorías (home) ---------- */
.cat-grid { display: grid; grid-template-columns: repeat(5, 1fr); gap: 18px; }
.cat-card {
  display: flex; flex-direction: column; background: #fff; border: 1px solid var(--line); border-radius: var(--radius);
  padding: 20px 18px; text-decoration: none; color: var(--text); position: relative; overflow: hidden;
  transition: transform .25s, box-shadow .25s, border-color .25s;
}
.cat-card::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 4px; background: var(--red); transform: scaleX(0); transform-origin: left; transition: transform .3s; }
.cat-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); border-color: transparent; color: var(--text); }
.cat-card:hover::after { transform: scaleX(1); }
.cat-card__height { display: flex; align-items: baseline; gap: 6px; }
.cat-card__num { font-family: var(--display); font-weight: 800; font-style: italic; font-size: 3.6rem; line-height: .9; color: var(--red); }
.cat-card__unit { font-family: var(--display); font-weight: 700; text-transform: uppercase; color: var(--ink); letter-spacing: .05em; }
.cat-card__img { margin: 14px 0; aspect-ratio: 16 / 10; object-fit: contain; width: 100%; }
.cat-card__label { font-weight: 700; color: var(--ink); line-height: 1.3; }
.cat-card__count { margin-top: auto; padding-top: 10px; display: inline-flex; align-items: center; gap: .35em; color: var(--red); font-weight: 600; font-size: .92rem; }

/* ---------- Tarjeta de equipo ---------- */
.eq-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; }
.eq-grid--2 { grid-template-columns: repeat(2, 1fr); }
.eq-card { display: flex; flex-direction: column; background: #fff; border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; transition: box-shadow .25s, transform .25s; }
.eq-card:hover { box-shadow: var(--shadow-lg); transform: translateY(-3px); }
.eq-card__media { position: relative; display: block; background: #fff; border-bottom: 1px solid var(--line); }
.eq-card__media img { width: 100%; aspect-ratio: 588 / 325; object-fit: contain; }
.eq-card__badge { position: absolute; top: 12px; left: 12px; background: var(--ink); color: #fff; font: 700 .8rem/1 var(--font); padding: .5em .75em; border-radius: 999px; letter-spacing: .03em; }
.eq-card__body { display: flex; flex-direction: column; flex: 1; padding: 20px 22px 22px; }
.eq-card__title { font-size: 1.2rem; }
.eq-card__title a { color: inherit; text-decoration: none; }
.eq-card__title a:hover { color: var(--red); }
.eq-card__text { color: var(--muted); font-size: .95rem; }
.eq-card__actions { margin-top: auto; display: flex; justify-content: space-between; align-items: center; gap: 12px; }

/* ---------- Page hero ---------- */
.page-hero {
  position: relative; color: #cfd6e0; padding: clamp(40px, 6vw, 72px) 0;
  background: linear-gradient(100deg, rgba(20, 26, 36, .96) 30%, rgba(20, 26, 36, .7)), url("../../uploads/2021/08/ban-elev.jpg") center / cover;
}
.page-hero::after { content: ""; position: absolute; left: 0; bottom: 0; width: min(38%, 420px); height: 5px; background: var(--red); }
.page-hero__title { font-family: var(--display); font-weight: 800; font-style: italic; text-transform: uppercase; color: #fff; font-size: clamp(2.2rem, 5vw, 3.6rem); line-height: 1; margin: 0; max-width: 900px; }
.page-hero__title--post { font-style: normal; font-size: clamp(2rem, 4.4vw, 3rem); }
.page-hero__sub { margin: .6em 0 0; font-size: 1.12rem; }
.page-hero__meta { margin: 1em 0 0; font-size: .95rem; color: #aeb7c4; }
.crumbs ol { list-style: none; margin: 0 0 14px; padding: 0; display: flex; flex-wrap: wrap; gap: 6px; font-size: .88rem; }
.crumbs li + li::before { content: "/"; margin-right: 6px; color: #6f7a8a; }
.crumbs a { color: #aeb7c4; text-decoration: none; }
.crumbs a:hover { color: #fff; }
.crumbs span { color: #fff; }

/* ---------- Layout con barra lateral ---------- */
.with-aside { display: grid; grid-template-columns: minmax(0, 1fr) 320px; gap: clamp(28px, 4vw, 56px); align-items: start; }
.aside { position: sticky; top: 108px; display: grid; gap: 20px; }
.aside-box { border: 1px solid var(--line); border-radius: var(--radius); padding: 22px; background: #fff; }
.aside-box__title { font-family: var(--display); text-transform: uppercase; font-size: 1.3rem; }
.aside-box--accent { background: var(--red); border-color: var(--red); color: #fff; display: grid; gap: 10px; }
.aside-box--accent .aside-box__title { color: #fff; margin-bottom: 0; }
.aside-box--accent p { margin: 0 0 6px; opacity: .92; }
.aside-heights { list-style: none; margin: 0; padding: 0; display: grid; gap: 4px; }
.aside-heights a { display: flex; align-items: center; gap: 12px; padding: 10px; border-radius: 10px; text-decoration: none; color: var(--text); font-weight: 500; }
.aside-heights a:hover, .aside-heights a.is-active { background: var(--tint); color: var(--ink); }
.aside-heights a.is-active { box-shadow: inset 3px 0 0 var(--red); }
.aside-heights__num { font-family: var(--display); font-weight: 800; font-size: 1.15rem; color: var(--red); min-width: 44px; white-space: nowrap; }

/* ---------- Detalle de equipo ---------- */
.product { display: grid; grid-template-columns: 1.1fr 1fr; gap: 32px; align-items: center; padding-bottom: 36px; margin-bottom: 36px; border-bottom: 1px solid var(--line); }
.product__media { margin: 0; border: 1px solid var(--line); border-radius: var(--radius); background: #fff; padding: 12px; }
.product__title { font-size: clamp(1.4rem, 2.4vw, 1.8rem); }
.product__specs { list-style: none; padding: 0; margin: 0 0 22px; display: grid; gap: 8px; color: var(--ink-2); }
.product__specs li { display: flex; gap: 10px; align-items: center; }
.product__specs .i { color: var(--red); }
.product__actions { display: flex; flex-wrap: wrap; gap: 10px; }

/* ---------- Contenido enriquecido ---------- */
.prose { color: var(--text); }
.prose > :first-child { margin-top: 0; }
.prose h2 { font-size: clamp(1.35rem, 2.3vw, 1.65rem); margin: 1.6em 0 .5em; }
.prose h3 { font-size: 1.2rem; margin: 1.4em 0 .4em; }
.prose ul, .prose ol { padding-left: 1.3em; margin: 0 0 1.2em; }
.prose li { margin-bottom: .45em; }
.prose li::marker { color: var(--red); font-weight: 700; }
.prose img { border-radius: 10px; margin: 1.5em auto; height: auto; }
.prose a { font-weight: 600; }
.prose strong { color: var(--ink); }
.prose--intro { font-size: 1.08rem; padding: 26px 28px; background: var(--tint); border-left: 4px solid var(--red); border-radius: 0 var(--radius) var(--radius) 0; }
.prose--intro p:last-child { margin-bottom: 0; }
.prose--post { font-size: 1.1rem; line-height: 1.75; }
.section--post { padding-top: 40px; }
.post-cover { margin: 0 0 36px; }
.post-cover img { width: 100%; border-radius: var(--radius); box-shadow: var(--shadow); }
.post-cta { margin-top: 48px; padding: 28px; border-radius: var(--radius); background: var(--ink); color: #c9d0db; display: flex; justify-content: space-between; align-items: center; gap: 20px; flex-wrap: wrap; }
.post-cta h2 { color: #fff; font-family: var(--display); text-transform: uppercase; font-size: 1.6rem; margin-bottom: .2em; }
.post-cta p { margin: 0; }
.post-cta__actions { display: flex; gap: 10px; flex-wrap: wrap; }

/* ---------- Blog ---------- */
.post-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 26px; }
.post-card { display: flex; flex-direction: column; background: #fff; border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; transition: box-shadow .25s, transform .25s; }
.post-card:hover { box-shadow: var(--shadow-lg); transform: translateY(-3px); }
.post-card__media img { width: 100%; aspect-ratio: 16 / 9; object-fit: cover; background: var(--tint); }
.post-card__body { padding: 20px 22px 24px; }
.post-card__meta { font-size: .82rem; color: var(--muted); text-transform: uppercase; letter-spacing: .06em; font-weight: 600; margin-bottom: .5em; }
.post-card__title { font-size: 1.15rem; line-height: 1.3; }
.post-card__title a { color: var(--ink); text-decoration: none; }
.post-card__title a:hover { color: var(--red); }
.post-card__excerpt { color: var(--muted); font-size: .95rem; margin: 0; }

.chips { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 32px; }
.chip { display: inline-flex; align-items: center; gap: .5em; padding: .45em 1em; border-radius: 999px; border: 1px solid var(--line); color: var(--ink); text-decoration: none; font-weight: 600; font-size: .9rem; background: #fff; }
.chip span { color: var(--muted); font-weight: 500; }
.chip:hover { border-color: var(--red); color: var(--red); }
.chip.is-active { background: var(--ink); border-color: var(--ink); color: #fff; }
.chip.is-active span { color: #aeb7c4; }

.pagination { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; margin-top: 48px; }
.pagination a, .pagination__gap { min-width: 44px; height: 44px; padding: 0 14px; display: inline-grid; place-items: center; border-radius: 10px; border: 1px solid var(--line); color: var(--ink); text-decoration: none; font-weight: 600; }
.pagination a:hover { border-color: var(--red); color: var(--red); }
.pagination a.is-active { background: var(--red); border-color: var(--red); color: #fff; }
.pagination__gap { border: 0; }

/* ---------- Equipos (listado) ---------- */
.height-nav { position: sticky; top: 84px; z-index: 20; background: #fff; border-bottom: 1px solid var(--line); }
.height-nav .container { display: flex; align-items: center; gap: 8px; overflow-x: auto; padding-top: 12px; padding-bottom: 12px; }
.height-nav__label { color: var(--muted); font-size: .9rem; margin-right: 4px; }
.height-nav a { padding: .35em .9em; border-radius: 999px; background: var(--tint); color: var(--ink); text-decoration: none; font-family: var(--display); font-weight: 700; font-size: 1.05rem; white-space: nowrap; }
.height-nav a:hover { background: var(--red); color: #fff; }
.cat-head { display: flex; align-items: center; gap: 18px; }
.cat-head__num { font-family: var(--display); font-weight: 800; font-style: italic; font-size: 4.2rem; line-height: .85; color: var(--red); }
.cat-head__num small { font-size: .45em; margin-left: 2px; color: var(--ink); font-style: normal; }
[id^="h-"] { scroll-margin-top: 150px; }

/* ---------- Nosotros ---------- */
.pillars { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; }
.pillar { padding: 30px 28px; border-radius: var(--radius); background: rgba(255, 255, 255, .04); border: 1px solid rgba(255, 255, 255, .1); }
.pillar h3 { font-family: var(--display); text-transform: uppercase; font-size: 1.6rem; margin: 18px 0 .3em; }
.pillar p { margin: 0; }
.pillar__icon { display: grid; place-items: center; width: 54px; height: 54px; border-radius: 14px; background: var(--red); color: #fff; }
.pillar__icon .i { width: 26px; height: 26px; }
.gallery { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 18px; }
.gallery--2 { grid-template-columns: 1fr 1fr; }
.gallery figure { margin: 0; border-radius: var(--radius); overflow: hidden; }
.gallery img { width: 100%; height: 100%; aspect-ratio: 4 / 3.3; object-fit: cover; transition: transform .5s; }
.gallery figure:hover img { transform: scale(1.04); }

/* ---------- Contacto ---------- */
.contact { display: grid; grid-template-columns: .9fr 1.1fr; gap: clamp(32px, 5vw, 72px); align-items: start; }
.contact-list { list-style: none; margin: 28px 0; padding: 0; display: grid; gap: 20px; }
.contact-list li { display: flex; gap: 16px; align-items: flex-start; }
.contact-list h3 { font-size: .8rem; text-transform: uppercase; letter-spacing: .1em; color: var(--muted); margin: 0 0 .2em; }
.contact-list a, .contact-list p { margin: 0; font-weight: 600; font-size: 1.1rem; color: var(--ink); text-decoration: none; }
.contact-list a:hover { color: var(--red); }
.contact-list__icon { display: grid; place-items: center; width: 48px; height: 48px; border-radius: 12px; background: var(--red-50); color: var(--red); flex: none; }
.contact__form { background: #fff; border: 1px solid var(--line); border-radius: 18px; padding: clamp(22px, 4vw, 40px); box-shadow: var(--shadow); scroll-margin-top: 110px; }
.form { display: grid; gap: 18px; }
.form__row { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.field label { display: block; font-weight: 600; font-size: .92rem; color: var(--ink); margin-bottom: 6px; }
.field input, .field select, .field textarea {
  width: 100%; font: inherit; font-size: 1rem; color: var(--text); background: var(--tint);
  border: 1.5px solid transparent; border-radius: 10px; padding: .75em .9em; transition: border-color .2s, background .2s, box-shadow .2s;
}
.field textarea { resize: vertical; min-height: 130px; }
.field input:focus, .field select:focus, .field textarea:focus { outline: none; background: #fff; border-color: var(--red); box-shadow: 0 0 0 4px rgba(217, 4, 10, .1); }
.field [aria-invalid="true"] { border-color: var(--red); background: var(--red-50); }
.field__error { margin: 6px 0 0; color: var(--red-600); font-size: .88rem; font-weight: 500; }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.alert { padding: 14px 18px; border-radius: 10px; margin-bottom: 20px; }
.alert strong { display: block; }
.alert--ok { background: #e9f8ef; color: #135c32; border: 1px solid #b8e6c9; }
.alert--error { background: var(--red-50); color: var(--red-600); border: 1px solid #ffc9cb; }
.map iframe { display: block; width: 100%; height: 420px; border: 0; filter: grayscale(.2); }

/* ---------- CTA + Footer ---------- */
.cta-band { background: linear-gradient(105deg, var(--red) 0%, #a80307 100%); color: #fff; position: relative; overflow: hidden; }
.cta-band::before { content: ""; position: absolute; right: -60px; top: 0; bottom: 0; width: 45%;
  background: repeating-linear-gradient(180deg, rgba(255,255,255,.08) 0 3px, transparent 3px 12px); transform: skewX(-20deg); }
.cta-band__inner { position: relative; display: flex; justify-content: space-between; align-items: center; gap: 24px 40px; flex-wrap: wrap; padding-top: 48px; padding-bottom: 48px; }
.cta-band__title { color: #fff; font-family: var(--display); font-weight: 800; font-style: italic; text-transform: uppercase; font-size: clamp(1.7rem, 3.2vw, 2.5rem); line-height: 1; margin: 0; max-width: 640px; }
.cta-band .eyebrow--light { color: #ffd0d1; }
.cta-band__actions { display: flex; flex-wrap: wrap; gap: 12px; }

.site-footer { background: #121822; color: #9aa4b2; font-size: .95rem; }
.site-footer__grid { display: grid; grid-template-columns: 1.4fr 1fr .8fr 1.2fr; gap: 40px; padding-top: 64px; padding-bottom: 48px; }
.site-footer__logo { width: 200px; background: #fff; padding: 10px 14px; border-radius: 10px; margin-bottom: 18px; }
.site-footer__title { color: #fff; font-family: var(--display); text-transform: uppercase; letter-spacing: .04em; font-size: 1.15rem; margin-bottom: 1em; }
.site-footer__links, .site-footer__contact { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.site-footer a { color: #cfd6e0; text-decoration: none; }
.site-footer a:hover { color: #fff; text-decoration: underline; }
.site-footer__contact li { display: flex; gap: 10px; align-items: flex-start; }
.site-footer__contact .i { color: var(--red); margin-top: .25em; }
.site-footer__bottom { border-top: 1px solid rgba(255, 255, 255, .08); padding: 20px 0; font-size: .85rem; }

.wa-float {
  position: fixed; right: 20px; bottom: 20px; z-index: 60; display: inline-flex; align-items: center; gap: 10px;
  background: var(--wa); color: #fff; text-decoration: none; font-weight: 700; padding: 12px 18px 12px 14px; border-radius: 999px;
  box-shadow: 0 10px 30px rgba(31, 168, 85, .45); transition: transform .2s, box-shadow .2s;
}
.wa-float svg { width: 30px; height: 30px; }
.wa-float:hover { color: #fff; transform: translateY(-2px) scale(1.02); box-shadow: 0 14px 34px rgba(31, 168, 85, .55); }

.error-page { text-align: center; }
.error-page__code { font-family: var(--display); font-weight: 800; font-style: italic; font-size: clamp(6rem, 18vw, 10rem); line-height: .9; color: var(--red); margin: 0; }
.error-page__actions { display: flex; justify-content: center; gap: 12px; flex-wrap: wrap; margin-top: 24px; }

/* ---------- Responsive ---------- */
@media (max-width: 1100px) {
  .cat-grid { grid-template-columns: repeat(3, 1fr); }
  .site-footer__grid { grid-template-columns: 1fr 1fr; }
  .with-aside { grid-template-columns: minmax(0, 1fr) 280px; }
}
@media (max-width: 960px) {
  .nav-toggle { display: flex; }
  .nav {
    position: fixed; inset: var(--nav-top, 124px) 0 0 0; background: #fff; flex-direction: column; align-items: stretch; gap: 20px;
    padding: 20px var(--gutter) 40px; overflow-y: auto; display: none;
  }
  .nav.is-open { display: flex; animation: navIn .25s ease both; }
  @keyframes navIn { from { opacity: 0; transform: translateY(-8px); } to { opacity: 1; transform: none; } }
  body.nav-open { overflow: hidden; }
  .nav__list { flex-direction: column; align-items: stretch; gap: 0; }
  .nav__link { padding: 14px 4px; border-bottom: 1px solid var(--line); border-radius: 0; font-size: 1.1rem; justify-content: space-between; }
  .nav__link::after { display: none; }
  .nav__drop { position: static; opacity: 1; visibility: visible; transform: none; box-shadow: none; border: 0; padding: 6px 0 10px; min-width: 0; }
  .nav__cta { justify-content: center; }
  .hero__grid, .split, .contact, .with-aside, .product { grid-template-columns: 1fr; }
  .hero__visual { max-width: 520px; }
  .hero__controls { position: static; padding-bottom: 28px; margin-top: -40px; }
  .split--reverse .split__media { order: 0; }
  .split__media--figure img { max-height: 420px; }
  .stats-strip__grid { grid-template-columns: 1fr 1fr; }
  .stat:nth-child(2) { border-right: 0; }
  .stat:nth-child(-n+2) { border-bottom: 1px solid rgba(255, 255, 255, .2); }
  .eq-grid, .post-grid { grid-template-columns: 1fr 1fr; }
  .aside { position: static; }
  .pillars { grid-template-columns: 1fr; }
  .height-nav { top: 84px; }
}
@media (max-width: 640px) {
  body { font-size: 16px; }
  .topbar__tag { display: none; }
  .topbar__inner { justify-content: center; }
  .topbar__info { gap: 14px; font-size: .78rem; flex-wrap: wrap; justify-content: center; }
  .site-header__inner { min-height: 72px; }
  .height-nav { top: 72px; }
  .cat-grid { grid-template-columns: 1fr 1fr; gap: 12px; }
  .cat-card { padding: 16px 14px; }
  .cat-card__num { font-size: 2.8rem; }
  .eq-grid, .eq-grid--2, .post-grid, .form__row, .site-footer__grid { grid-template-columns: 1fr; }
  .stats-strip__grid { grid-template-columns: 1fr; }
  .stat { border-right: 0; border-bottom: 1px solid rgba(255, 255, 255, .2); padding: 16px 4px; }
  .stat:last-child { border-bottom: 0; }
  .gallery { grid-template-columns: 1fr; }
  .cat-head__num { font-size: 3.2rem; }
  .wa-float span { display: none; }
  .wa-float { padding: 12px; }
  .map iframe { height: 320px; }
  .prose--intro { padding: 20px; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
}
