/* =====================================================================
   GESTA Consultoría & Capacitación — estilos
   Colores tomados del logo: negro, teal y cian de las tres barras.
   ===================================================================== */

@font-face {
  font-family: "Archivo";
  src: url("../fonts/archivo-var.woff2") format("woff2-variations"),
       url("../fonts/archivo-var.woff2") format("woff2");
  font-weight: 100 900;
  font-stretch: 62% 125%;
  font-style: normal;
  font-display: swap;
}

:root {
  /* colores del logotipo de GESTA */
  --navy: #161D36;
  --azul: #3F6EBF;
  --azul-oscuro: #2F5596;
  --celeste: #8FB2EC;
  --bruma: #EEF2FA;
  --texto: #1B2338;
  --gris: #5A6480;
  --linea: #D7E0F0;

  --wrap: 1200px;
  --gutter: clamp(20px, 4vw, 40px);
  --r-s: 6px;
  --r-m: 12px;
  --header-h: 82px;
}

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

html {
  -webkit-text-size-adjust: 100%;
  scroll-padding-top: calc(var(--header-h) + 12px);
}
@media (prefers-reduced-motion: no-preference) {
  html { scroll-behavior: smooth; }
}

body {
  margin: 0;
  font-family: "Archivo", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  font-size: 1.0625rem;
  font-stretch: 100%;
  line-height: 1.6;
  color: var(--texto);
  background: #fff;
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; height: auto; display: block; }
a { color: var(--azul-oscuro); }
p { margin: 0 0 1em; }

h1, h2, h3 {
  margin: 0;
  color: var(--texto);
  font-weight: 800;
  font-stretch: 116%;
  line-height: 1.08;
  letter-spacing: -0.012em;
}
h2 { font-size: clamp(1.9rem, 1.2rem + 2.3vw, 2.85rem); }
h3 { font-size: 1.25rem; font-weight: 750; font-stretch: 108%; line-height: 1.2; }

:focus-visible {
  outline: 3px solid var(--celeste);
  outline-offset: 3px;
  border-radius: 4px;
}

.sr-only {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}

.skip {
  position: absolute; left: 12px; top: -80px; z-index: 100;
  background: var(--navy); color: #fff; padding: 10px 16px; border-radius: var(--r-s);
}
.skip:focus { top: 12px; }

.wrap {
  width: min(var(--wrap), 100% - 2 * var(--gutter));
  margin-inline: auto;
}

/* ---------- botones ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 50px;
  padding: 0.75em 1.4em;
  border: 2px solid transparent;
  border-radius: var(--r-s);
  font: inherit;
  font-size: 1rem;
  font-weight: 650;
  font-stretch: 106%;
  line-height: 1.2;
  text-decoration: none;
  cursor: pointer;
  transition: background-color .15s ease, color .15s ease, border-color .15s ease;
}
.btn--primary { background: var(--azul-oscuro); color: #fff; }
.btn--primary:hover { background: #25457A; }
.btn--ghost { background: transparent; color: var(--texto); border-color: var(--texto); }
.btn--ghost:hover { background: var(--texto); color: #fff; }
.btn--light { background: #fff; color: var(--navy); }
.btn--light:hover { background: var(--bruma); }
.btn--block { width: 100%; }

/* ---------- cabecera ---------- */
.header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(255, 255, 255, 0.95);
  -webkit-backdrop-filter: saturate(1.2) blur(10px);
  backdrop-filter: saturate(1.2) blur(10px);
  border-bottom: 1px solid transparent;
  transition: border-color .2s ease;
}
.header.is-scrolled { border-bottom-color: var(--linea); }

.header__bar {
  display: flex; align-items: center; justify-content: space-between;
  gap: 24px; height: var(--header-h);
}
.header__logo { flex: none; }
.header__logo img { height: 46px; width: auto; }

.nav { display: flex; align-items: center; gap: 16px; }
.nav__list { display: flex; gap: 8px; list-style: none; margin: 0; padding: 0; }
.nav__item { position: relative; display: flex; align-items: center; height: var(--header-h); }
.nav__item > a {
  display: inline-flex; align-items: center;
  color: var(--texto); text-decoration: none;
  white-space: nowrap;
  font-weight: 600; font-size: 0.9rem;
  padding: 0.5em 0.85em;
  background: var(--bruma);
  border: 1px solid var(--linea);
  border-radius: 999px;
  transition: background-color .15s ease, border-color .15s ease, color .15s ease;
}
.nav__item > a:hover,
.nav__item:hover > a,
.nav__item:focus-within > a {
  background: var(--azul);
  border-color: var(--azul);
  color: #fff;
}
.nav__item > a.is-current {
  background: var(--azul-oscuro);
  border-color: var(--azul-oscuro);
  color: #fff;
}
.has-sub > a::after {
  content: "";
  display: inline-block;
  width: 5px; height: 5px;
  margin-left: 7px;
  border-right: 2px solid currentColor;
  border-bottom: 2px solid currentColor;
  transform: translateY(-3px) rotate(45deg);
  transition: transform .2s ease;
}
.has-sub:hover > a::after,
.has-sub:focus-within > a::after { transform: translateY(0) rotate(225deg); }

/* menús desplegables al pasar el mouse (o al llegar con el teclado) */
.dropdown {
  position: absolute; top: 100%; left: -16px; z-index: 60;
  min-width: 250px;
  opacity: 0; visibility: hidden;
  transform: translateY(6px);
  transition: opacity .18s ease, transform .18s ease, visibility 0s linear .18s;
}
.nav__item--right .dropdown { left: auto; right: -16px; }
.has-sub:hover .dropdown,
.has-sub:focus-within .dropdown {
  opacity: 1; visibility: visible; transform: none;
  transition: opacity .18s ease, transform .18s ease, visibility 0s;
}
.has-sub.is-closing .dropdown { opacity: 0; visibility: hidden; }
.dropdown__panel {
  list-style: none; margin: 0; padding: 8px;
  background: #fff;
  border: 1px solid var(--linea);
  border-top: 3px solid var(--celeste);
  border-radius: 0 0 var(--r-m) var(--r-m);
  box-shadow: 0 16px 32px rgba(22, 29, 54, .12);
}
.dropdown__panel a {
  display: block;
  padding: 10px 14px;
  border-radius: var(--r-s);
  color: var(--texto); text-decoration: none;
  font-size: 0.95rem; line-height: 1.3; white-space: nowrap;
}
.dropdown__panel a:hover,
.dropdown__panel a:focus-visible { background: var(--bruma); color: var(--azul-oscuro); }
.nav__cta { min-height: 44px; padding-block: 0.6em; white-space: nowrap; }

.header__toggle {
  display: none;
  width: 48px; height: 48px;
  align-items: center; justify-content: center;
  background: transparent; border: 0; border-radius: 8px; cursor: pointer;
}
/* el ícono del menú repite las tres barras del logo */
.burger { display: grid; gap: 4px; width: 26px; }
.burger i {
  display: block; height: 4px;
  background: var(--navy);
  border-bottom-left-radius: 4px;
  transition: transform .2s ease, opacity .2s ease;
}
.burger i:nth-child(2) { background: var(--azul); }
.burger i:nth-child(3) { background: var(--celeste); }
.header.is-open .burger i:nth-child(1) { transform: translateY(8px) rotate(45deg); }
.header.is-open .burger i:nth-child(2) { opacity: 0; }
.header.is-open .burger i:nth-child(3) { transform: translateY(-8px) rotate(-45deg); }

/* ---------- portada ---------- */
.hero { padding: clamp(32px, 5vw, 64px) 0 clamp(44px, 5vw, 72px); }

.hero__top {
  display: grid;
  grid-template-columns: minmax(0, 1.6fr) minmax(0, 1fr);
  gap: clamp(28px, 4vw, 64px);
  align-items: end;
  margin-bottom: clamp(28px, 3.5vw, 44px);
}

.hero__title {
  font-size: clamp(2.3rem, 1rem + 3.7vw, 4rem);
  font-weight: 820;
  font-stretch: 112%;
  line-height: 1.02;
  letter-spacing: -0.022em;
  text-wrap: balance;
}

.nowrap { white-space: nowrap; }

/* el icono del logo, a la altura de las mayúsculas del titular */
.mark {
  display: inline-block;
  height: 0.92em;
  width: auto;
  margin-right: 0.22em;
  vertical-align: -0.06em;
}
@media (prefers-reduced-motion: no-preference) {
  .mark { animation: marca-in .6s cubic-bezier(.2, .75, .2, 1) both; }
}
@keyframes marca-in {
  from { opacity: 0; transform: translateY(8px); }
  to   { opacity: 1; transform: none; }
}

.hero__lead {
  font-size: clamp(1.08rem, 1rem + 0.35vw, 1.22rem);
  color: var(--gris);
  max-width: 42ch;
  margin-bottom: 26px;
}
.hero__actions { display: flex; flex-wrap: wrap; gap: 12px; }

.hero__photo { aspect-ratio: 3 / 1; }
.hero__photo img { object-position: 50% 22%; }

.hero__trust {
  display: flex; align-items: center; gap: 14px;
  margin-top: 20px;
  color: var(--gris); font-size: 0.98rem;
}
.hero__trust p { margin: 0; max-width: 60ch; }
.hero__trust strong { color: var(--texto); }

/* ---------- secciones ---------- */
.section { padding: clamp(52px, 6.5vw, 92px) 0; }
.section--tight { padding-bottom: clamp(40px, 5vw, 72px); }
.section--mist { background: var(--bruma); }
.section--dark { background: var(--navy); color: #C6D3EC; }
.section--dark h2, .section--dark h3 { color: #fff; }

.section__head { max-width: 660px; margin-bottom: clamp(26px, 3vw, 40px); }
.section__head p { margin: 14px 0 0; font-size: 1.125rem; color: var(--gris); }
.section--dark .section__head p { color: #AFC0E2; }

/* ---------- modalidades de los cursos ---------- */
.modos {
  list-style: none; margin: 0 0 34px; padding: 0;
  display: grid; grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px clamp(16px, 2vw, 28px);
}
.modos li {
  padding: 16px 20px;
  background: var(--bruma);
  border-radius: var(--r-m);
  border-left: 4px solid var(--azul);
}
.section--mist .modos li { background: #fff; }
.modos li:nth-child(2) { border-left-color: var(--navy); }
.modos li:nth-child(3) { border-left-color: var(--celeste); }
.modos h3 { font-size: 1.05rem; margin-bottom: 4px; }
.modos p { margin: 0; color: var(--gris); font-size: 0.94rem; }

/* ---------- cursos: cuadrícula compacta ---------- */
.courses {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  column-gap: clamp(24px, 3vw, 48px);
  border-top: 2px solid var(--texto);
}
.course {
  display: flex; flex-direction: column;
  padding: 24px 0 30px;
  border-bottom: 1px solid var(--linea);
}
.course__photo { aspect-ratio: 4 / 3; margin-bottom: 16px; }
.course__photo img { transition: transform .35s ease; }
.course:hover .course__photo img { transform: scale(1.04); }
.course h3 { font-size: 1.28rem; font-stretch: 112%; margin-bottom: 10px; max-width: 20ch; }
.course p { margin: 0 0 10px; }
.course .course__topics { font-size: 0.93rem; color: var(--gris); margin-bottom: 16px; }
.course__link {
  margin-top: auto; align-self: flex-start;
  font-weight: 650;
  color: var(--azul-oscuro);
  text-decoration: underline;
  text-decoration-thickness: 2px;
  text-underline-offset: 5px;
}
.course__link:hover { color: var(--texto); }
.course__more {
  margin-top: auto; align-self: flex-start;
  padding: 0.5em 1em;
  font: inherit; font-size: 0.95rem; font-weight: 650;
  color: var(--azul-oscuro); background: transparent;
  border: 2px solid var(--azul-oscuro); border-radius: var(--r-s);
  cursor: pointer;
  transition: background-color .15s ease, color .15s ease;
}
.course__more:hover { background: var(--azul-oscuro); color: #fff; }
.course__more + .course__link { margin-top: 14px; }

/* ---------- ventana de programas ---------- */
.modal {
  width: min(840px, 100% - 32px);
  max-height: min(88vh, 900px);
  padding: 0; border: 0;
  border-radius: var(--r-m);
  overflow: auto;
  color: var(--texto); background: #fff;
  box-shadow: 0 24px 60px rgba(22, 29, 54, .3);
}
.modal::backdrop { background: rgba(22, 29, 54, .6); }
body:has(dialog[open]) { overflow: hidden; }
.modal__head {
  position: sticky; top: 0; z-index: 1;
  display: flex; align-items: flex-start; justify-content: space-between; gap: 16px;
  padding: 22px 26px 16px;
  background: #fff;
  border-bottom: 1px solid var(--linea);
}
.modal__head h2 { font-size: clamp(1.35rem, 1rem + 1.2vw, 1.8rem); }
.modal__head p { margin: 6px 0 0; color: var(--gris); font-size: 0.97rem; }
.modal__close {
  flex: none; width: 44px; height: 44px;
  border: 0; border-radius: 50%;
  background: var(--bruma); color: var(--texto);
  font-size: 1.7rem; line-height: 1; cursor: pointer;
}
.modal__close:hover { background: #DDE6F6; }
.modal__body {
  display: grid; grid-template-columns: 1fr 1fr;
  gap: 0 34px; padding: 6px 26px 22px;
}
.program { display: flex; flex-direction: column; padding: 18px 0; border-bottom: 1px solid var(--linea); }
.program:nth-last-child(-n+2) { border-bottom: 0; }
.program h3 { font-size: 1.22rem; }
.program p { margin: 0 0 8px; }
.program .program__sub { margin: 4px 0 10px; font-weight: 620; color: var(--azul-oscuro); }
.program .program__for { font-size: 0.93rem; color: var(--gris); }
.program .program__topics { font-size: 0.97rem; margin-bottom: 14px; }


.course:target,
.consults li:target,
.mv:target { animation: resaltar 1.8s ease-out; }
@keyframes resaltar {
  from { background: rgba(143, 178, 236, .35); box-shadow: 0 0 0 12px rgba(143, 178, 236, .35); }
  to   { background: transparent; box-shadow: 0 0 0 12px transparent; }
}

/* ---------- consultorías ---------- */
.consults {
  list-style: none; margin: 0 0 24px; padding: 0;
  display: grid; grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 26px clamp(24px, 3vw, 48px);
}
.consults li {
  display: flex; flex-direction: column;
  border-top: 3px solid var(--azul);
  padding-top: 16px;
}
.consults__photo { aspect-ratio: 16 / 9; margin-bottom: 16px; }
.consults__photo img { transition: transform .35s ease; }
.consults li:hover .consults__photo img { transform: scale(1.04); }
.consults li:nth-child(2) { border-top-color: var(--navy); }
.consults li:nth-child(3) { border-top-color: var(--celeste); }
.consults h3 { font-size: 1.18rem; margin-bottom: 8px; }
.consults p { margin: 0 0 10px; font-size: 1rem; }
.consults .consults__temas { color: var(--gris); font-size: 0.93rem; margin-bottom: 16px; }
.consults .course__link { margin-top: auto; align-self: flex-start; }

.consults__extra {
  margin: 0 0 28px; padding: 16px 20px;
  background: #fff; border-left: 4px solid var(--celeste);
  border-radius: 0 var(--r-s) var(--r-s) 0;
}
.section:not(.section--mist) .consults__extra { background: var(--bruma); }
.consults__extra p { margin: 0; color: var(--gris); }
.consults__extra strong { color: var(--texto); }

/* ---------- evaluaciones online ---------- */
.eval__eyebrow {
  margin: 0 0 12px;
  color: var(--celeste);
  font-size: 0.8rem; font-weight: 650;
  letter-spacing: .16em; text-transform: uppercase;
}
.evals {
  display: grid; grid-template-columns: 1fr 1fr;
  gap: clamp(24px, 3vw, 48px);
  margin-bottom: 34px;
}
.eval {
  display: flex; flex-direction: column;
  padding: 26px clamp(20px, 2.4vw, 30px) 24px;
  background: rgba(255, 255, 255, .05);
  border-top: 3px solid var(--celeste);
  border-radius: 0 0 var(--r-m) var(--r-m);
}
.eval:first-child { border-top-color: var(--azul); }
.eval h3 { font-size: 1.3rem; margin-bottom: 8px; }
.eval .eval__claim { color: var(--celeste); font-weight: 620; margin-bottom: 12px; }
.eval p { margin: 0 0 12px; }
.eval__link {
  margin-top: auto; align-self: flex-start;
  color: #fff; font-weight: 650;
  text-decoration: underline; text-decoration-thickness: 2px; text-underline-offset: 5px;
}
.eval__link:hover { color: var(--celeste); }

.eval__cierre {
  display: grid; grid-template-columns: 1fr auto;
  gap: 16px clamp(24px, 4vw, 56px);
  align-items: center;
  padding-top: 28px;
  border-top: 1px solid rgba(255, 255, 255, .16);
}
.eval__cierre p { margin: 0; max-width: 62ch; }
.eval__lema {
  grid-column: 1 / -1;
  color: #fff; font-weight: 750; font-stretch: 108%;
  font-size: clamp(1.15rem, 1rem + .8vw, 1.5rem);
}

/* ---------- cómo trabajamos: escalera con las barras del logo ---------- */
.steps {
  --tope: 136px;               /* altura del escalón más alto */
  list-style: none; margin: 0; padding: 0;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 22px;
  align-items: start;
}
.step__bar {
  display: flex; align-items: flex-end;
  height: var(--h);
  margin-top: calc(var(--tope) - var(--h));
  margin-bottom: 18px;
  padding: 12px 18px;
  border-bottom-left-radius: 28px;
  color: #fff;
}
.step__num { font-size: 1.7rem; font-weight: 850; font-stretch: 120%; line-height: 1; }
.step:nth-child(1) .step__bar { --h: 64px;  background: var(--navy); }
.step:nth-child(2) .step__bar { --h: 88px;  background: var(--azul-oscuro); }
.step:nth-child(3) .step__bar { --h: 112px; background: var(--azul); }
.step:nth-child(4) .step__bar { --h: 136px; background: var(--celeste); color: var(--navy); }
.step h3 { margin-bottom: 8px; }
.step p { margin: 0; color: var(--gris); }

/* ---------- nosotros ---------- */
.about {
  display: grid;
  grid-template-columns: minmax(0, 5fr) minmax(0, 6fr);
  gap: clamp(32px, 5vw, 80px);
  align-items: center;
}
.about__photo { aspect-ratio: 4 / 5; max-width: 440px; }
.about__photo img { object-position: 50% 40%; }
.about__photo figcaption {
  position: absolute; left: 12px; right: 12px; bottom: 12px;
  padding: 8px 12px; border-radius: var(--r-s);
  background: rgba(255, 255, 255, .92); color: var(--texto); font-size: 0.88rem;
}
.about__photo figcaption {
  position: absolute; left: 12px; right: 12px; bottom: 12px;
  padding: 10px 14px;
  background: #fff; border-radius: var(--r-s);
  font-size: 0.9rem; line-height: 1.35; color: var(--gris);
}
.about__photo figcaption strong { display: block; color: var(--texto); font-stretch: 108%; }
.about__text h2 { margin-bottom: 20px; max-width: 18ch; }
.about__text p { max-width: 62ch; }
.about__text .btn { margin-top: 6px; }
.mv {
  display: grid; grid-template-columns: 1fr 1fr;
  gap: 20px 32px; margin: 26px 0 28px;
}
.mv > div { border-top: 3px solid var(--celeste); padding-top: 14px; }
.mv > div:first-child { border-top-color: var(--azul); }
.mv h3 { font-size: 1.1rem; margin-bottom: 6px; }
.mv p { margin: 0; font-size: 0.97rem; }

/* ---------- equipo ---------- */
.equipo {
  list-style: none; margin: 0; padding: 0;
  display: flex; flex-wrap: wrap; justify-content: center;
  gap: clamp(20px, 2.4vw, 28px);
}
.equipo__card {
  flex: 1 1 290px; max-width: 380px;
  display: flex; flex-direction: column;
  background: #fff;
  border: 1px solid var(--linea);
  border-radius: var(--r-m);
  overflow: hidden;
}
.equipo__foto { margin: 0; aspect-ratio: 3 / 4; }
.equipo__foto img { width: 100%; height: 100%; object-fit: cover; }
.equipo__texto { padding: 20px clamp(18px, 2vw, 24px) 24px; }
.equipo__texto h3 { margin: 0; font-size: 1.25rem; }
.equipo__rol {
  margin: 5px 0 12px;
  font-size: .9375rem; font-weight: 600; line-height: 1.35;
  color: var(--azul-oscuro);
}
.equipo__bio { margin: 0; font-size: .9375rem; color: var(--gris); }

/* ---------- clientes ---------- */
.marcas {
  list-style: none; margin: 0 0 30px; padding: 0;
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 14px;
}
.marca {
  display: flex; align-items: center; justify-content: center;
  aspect-ratio: 3 / 2;
  padding: 10px;
  background: #fff;
  border: 1px solid var(--linea);
  border-radius: var(--r-m);
  overflow: hidden;
}
.marca img {
  width: 100%; height: 100%;
  object-fit: contain;
  filter: saturate(.92);
  transition: transform .3s ease;
}
.marca:hover img { transform: scale(1.06); }
.marca.is-texto {
  padding: 12px; text-align: center;
  font-weight: 650; font-size: 0.92rem; color: var(--texto);
}
.clientes__sub { margin: 0 0 12px; color: var(--gris); font-size: 0.95rem; }

.clientes {
  list-style: none; margin: 0; padding: 0;
  display: flex; flex-wrap: wrap; gap: 10px;
}
.clientes li {
  padding: 0.6em 1.05em;
  background: #fff;
  border: 1px solid var(--linea);
  border-radius: 999px;
  font-weight: 600; font-size: 0.95rem;
  color: var(--texto);
  line-height: 1.2;
}


/* ---------- galería: carrusel que se desliza ---------- */
.gallery-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 20px; }
.g-nav { display: flex; gap: 10px; margin-bottom: clamp(26px, 3vw, 40px); }
.g-btn {
  width: 48px; height: 48px; border-radius: 50%;
  border: 2px solid var(--texto); background: #fff; color: var(--texto);
  font-size: 1.6rem; line-height: 1; cursor: pointer;
}
.g-btn:hover { background: var(--texto); color: #fff; }
.g-btn:disabled { opacity: .3; cursor: default; background: #fff; color: var(--texto); }
.gallery {
  display: grid; grid-auto-flow: column;
  grid-auto-columns: calc((100% - 3 * 14px) / 4);
  gap: 14px;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scroll-behavior: smooth;
  padding-bottom: 10px;
  scrollbar-width: thin;
}
.g-item { aspect-ratio: 4 / 3; scroll-snap-align: start; }
.g-open {
  position: absolute; inset: 0;
  padding: 0; border: 0; background: none;
  cursor: zoom-in; border-radius: inherit;
}
.g-open:focus-visible { outline: 3px solid var(--celeste); outline-offset: -3px; }
.g-item img { transition: transform .35s ease; }
.g-item:hover img { transform: scale(1.04); }
.gallery figcaption { pointer-events: none; }
.gallery figcaption {
  position: absolute; left: 0; right: 0; bottom: 0;
  padding: 36px 16px 14px;
  background: linear-gradient(to top, rgba(22, 29, 54, .82), rgba(22, 29, 54, 0));
  color: #fff; font-size: 0.92rem; line-height: 1.35;
}

/* ---------- imágenes y espacios para cargar luego ---------- */
.ph {
  position: relative;
  margin: 0;
  overflow: hidden;
  border-radius: var(--r-m);
  background: repeating-linear-gradient(135deg, #E3EAF7 0 14px, #EDF1FB 14px 28px);
}
.ph img {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  object-fit: cover;
}
.ph.is-empty {
  display: flex; flex-direction: column;
  align-items: center; justify-content: center;
  gap: 4px; padding: 12px; text-align: center;
}
.ph.is-empty::before {
  content: "Imagen para cargar luego";
  font-weight: 650; font-size: 0.95rem; line-height: 1.25;
  color: var(--azul-oscuro);
}
.ph.is-empty::after {
  content: attr(data-file);
  font-size: 0.8rem; color: var(--gris);
}
.ph.is-empty figcaption { display: none; }
.section--dark .ph.is-empty { background: repeating-linear-gradient(135deg, #222B4A 0 14px, #283258 14px 28px); }
.section--dark .ph.is-empty::before { color: var(--celeste); }
.section--dark .ph.is-empty::after { color: #AFC0E2; }

/* ---------- visor de fotos ---------- */
.lightbox {
  width: min(1100px, 100% - 24px); max-width: none;
  padding: 0; border: 0; background: transparent; overflow: visible;
}
.lightbox::backdrop { background: rgba(8, 20, 24, .9); }
.lightbox figure { margin: 0; text-align: center; }
.lightbox img {
  display: block; margin: 0 auto;
  max-width: 100%; max-height: 80vh;
  border-radius: 8px;
}
.lightbox figcaption { margin-top: 12px; color: #fff; font-size: 1rem; }
.lightbox__close { position: absolute; top: -8px; right: 0; z-index: 2; transform: translateY(-100%); }
.lightbox__nav {
  position: absolute; top: 45%; left: 8px; transform: translateY(-50%);
  width: 52px; height: 52px; border-radius: 50%; border: 0;
  background: rgba(255, 255, 255, .9); color: var(--texto);
  font-size: 1.9rem; line-height: 1; cursor: pointer;
}
.lightbox__nav--next { left: auto; right: 8px; }
.lightbox__nav:hover { background: #fff; }

/* ---------- contacto ---------- */
.contact {
  display: grid;
  grid-template-columns: minmax(0, 5fr) minmax(0, 6fr);
  gap: clamp(32px, 5vw, 88px);
  align-items: start;
}
.contact__info h2 { margin-bottom: 16px; max-width: 16ch; }
.contact__info > p { color: var(--gris); font-size: 1.125rem; max-width: 42ch; }

.channels { margin: 28px 0 0; }
.channels div {
  display: grid; grid-template-columns: 104px 1fr; gap: 12px;
  padding: 14px 0; border-top: 1px solid var(--linea);
}
.channels dt { color: var(--gris); font-size: 0.95rem; }
.channels dd { margin: 0; font-weight: 620; overflow-wrap: anywhere; }
.channels dd a { color: var(--texto); text-decoration: none; }
.channels dd a:hover { color: var(--azul-oscuro); text-decoration: underline; }

.mapa { margin: 22px 0 0; }
.mapa iframe {
  display: block; width: 100%; aspect-ratio: 16 / 10; min-height: 240px;
  border: 1px solid var(--linea); border-radius: var(--r-m);
  background: var(--bruma);
}
.mapa figcaption { margin-top: 10px; font-size: 0.95rem; }
.mapa figcaption a { color: var(--azul-oscuro); font-weight: 620; }
.mapa figcaption a:focus-visible { outline: 3px solid var(--azul); outline-offset: 2px; border-radius: 2px; }

.jobs-note { margin: 22px 0 0; font-size: 0.95rem; color: var(--gris); }
.form {
  background: var(--bruma);
  padding: clamp(22px, 3vw, 36px);
  border-radius: var(--r-m);
}
.field { margin-bottom: 16px; }
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.field label { display: block; font-weight: 620; font-size: 0.95rem; margin-bottom: 6px; }
.opt { font-weight: 400; color: var(--gris); }

.field input,
.field select,
.field textarea {
  width: 100%;
  font: inherit; font-size: 1rem;
  padding: 0.7em 0.85em;
  color: var(--texto);
  background: #fff;
  border: 1.5px solid #B9C6E4;
  border-radius: var(--r-s);
}
.field textarea { resize: vertical; min-height: 96px; }
.field input:focus,
.field select:focus,
.field textarea:focus {
  outline: none;
  border-color: var(--azul-oscuro);
  box-shadow: 0 0 0 3px rgba(63, 110, 191, .35);
}
.field__error { display: none; margin: 6px 0 0; font-size: 0.88rem; color: #B42318; }
.field.has-error input { border-color: #B42318; }
.field.has-error .field__error { display: block; }
.form__note { margin: 10px 0 0; text-align: center; font-size: 0.88rem; color: var(--gris); }

/* ---------- pie ---------- */
.footer { background: var(--navy); color: #AFC0E2; padding: 40px 0 24px; font-size: 0.95rem; }
.footer__row {
  display: flex; align-items: center; justify-content: space-between;
  flex-wrap: wrap; gap: 20px 40px;
}
.footer__logo { height: 54px; width: auto; }
.footer__links { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 10px 28px; }
.footer a { color: #DDE6F6; text-decoration: none; overflow-wrap: anywhere; }
.footer a:hover { color: #fff; text-decoration: underline; }
.footer__legal {
  display: flex; justify-content: space-between; flex-wrap: wrap; gap: 8px 24px;
  margin-top: 28px; padding-top: 18px;
  border-top: 1px solid rgba(255, 255, 255, .12);
  font-size: 0.86rem;
}
.footer__legal p { margin: 0; }

/* ---------- botón flotante de WhatsApp ---------- */
.wa-float {
  position: fixed; right: 18px; bottom: 18px; z-index: 60;
  display: grid; place-items: center;
  width: 58px; height: 58px; border-radius: 50%;
  background: #25D366; color: #fff;
  box-shadow: 0 6px 18px rgba(22, 29, 54, .28);
}
.wa-float:hover { background: #1EBE5B; }
.wa-float svg { width: 30px; height: 30px; }

/* =====================================================================
   Adaptación a tablets y celulares
   ===================================================================== */
/* en pantallas medianas se oculta el botón y se compacta el menú */
@media (max-width: 1320px) {
  .nav__cta { display: none; }
}
@media (max-width: 1240px) {
  .nav__list { gap: 6px; }
  .nav__item > a { padding: 0.5em 0.68em; font-size: 0.85rem; }
}

/* en celulares y tablets el menú va como una barra deslizable, siempre visible arriba */
@media (max-width: 1080px) {
  :root { --header-h: 66px; }
  .header__logo img { height: 38px; }
  .header__toggle { display: none; }

  /* El menu ocupa su propio renglon DENTRO de la cabecera. Antes iba flotando
     con position:absolute y no reservaba espacio, asi que tapaba el titulo de
     la portada al cargar la pagina. */
  .header__bar { height: auto; flex-wrap: wrap; gap: 0; }
  .header__logo { height: var(--header-h); display: flex; align-items: center; }
  .nav {
    position: relative;
    flex: 1 0 100%;
    gap: 0;
    background: #fff;
    border-bottom: 1px solid var(--linea);
    margin-inline: calc(-1 * var(--gutter));
  }
  .nav::after {
    content: "";
    position: absolute; top: 0; right: 0; bottom: 1px;
    width: 34px; pointer-events: none;
    background: linear-gradient(to right, rgba(255,255,255,0), #fff 75%);
  }
  .nav__list {
    gap: 8px;
    width: 100%;
    overflow-x: auto;
    scrollbar-width: none;
    padding: 9px var(--gutter);
    -webkit-overflow-scrolling: touch;
  }
  .nav__list::-webkit-scrollbar { display: none; }
  .nav__item { flex: none; }
  .nav__item > a { padding: 0.5em 0.9em; font-size: 0.9rem; }
  .has-sub > a::after { display: none; }
  .dropdown { display: none; }
  html { scroll-padding-top: calc(var(--header-h) + 86px + 12px); }
}

@media (max-width: 980px) {
  .hero__top { grid-template-columns: 1fr; align-items: start; }
  .courses { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .modos { grid-template-columns: 1fr; gap: 12px; }
  .consults { grid-template-columns: 1fr; gap: 22px; }
  .marcas { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; }
  .clientes { gap: 8px; }
  .clientes li { padding: 0.5em 0.85em; font-size: 0.88rem; }
  .evals { grid-template-columns: 1fr; }
  .eval__cierre { grid-template-columns: 1fr; }
  .consults li { display: grid; grid-template-columns: 96px 1fr; column-gap: 14px; align-items: start; }
  .consults__photo { grid-row: span 2; margin-bottom: 0; aspect-ratio: 1 / 1; }
  .consults h3, .consults li > p { grid-column: 2; }
  .consults .consults__temas { display: none; }
  .consults .course__link { grid-column: 1 / -1; margin-top: 4px; }
  .steps { grid-template-columns: repeat(2, minmax(0, 1fr)); row-gap: 32px; }
  .step:nth-child(-n+2) { --tope: 88px; }
  .about { grid-template-columns: minmax(0, 1fr) minmax(0, 1.6fr); }
  .gallery { grid-auto-columns: calc((100% - 14px) / 2.3); }
  .contact { grid-template-columns: 1fr; }
}

@media (max-width: 620px) {
  .hero__photo { aspect-ratio: 16 / 10; }
  .hero__photo img { object-position: 30% 40%; }
  .hero__actions .btn { flex: 1 1 auto; }

  .marcas { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .courses { grid-template-columns: 1fr; }
  .gallery { grid-auto-columns: 82%; }
  .g-nav { display: none; }
  .lightbox__close { transform: none; top: 8px; right: 8px; }

  .modal { width: calc(100% - 20px); max-height: 92vh; }
  .modal__head { padding: 18px 18px 14px; }
  .modal__body { grid-template-columns: 1fr; padding: 4px 18px 18px; }
  .program:nth-last-child(2) { border-bottom: 1px solid var(--linea); }
  .course {
    display: grid;
    grid-template-columns: 96px 1fr;
    column-gap: 14px;
    align-items: start;
    padding: 18px 0;
  }
  .course__photo { grid-row: span 2; margin-bottom: 0; aspect-ratio: 1 / 1; }
  .course .course__topics { display: none; }
  .course p { margin-bottom: 12px; }
  .course h3, .course > p { grid-column: 2; }
  .course__more, .course__link { grid-column: 1 / -1; margin-top: 4px; }
  .course__more + .course__link { margin-top: 12px; }

  .steps { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 22px 16px; }
  .step, .step:nth-child(-n+2) { --tope: 0px; }
  .step__bar {
    width: 52px; height: 52px;
    margin: 0 0 12px; padding: 0;
    align-items: center; justify-content: center;
    border-bottom-left-radius: 18px;
  }
  .step__num { font-size: 1.4rem; }
  .step h3 { font-size: 1.1rem; margin-bottom: 4px; }
  .step p { font-size: 0.95rem; }

  .about { grid-template-columns: 1fr; }
  .about__photo { aspect-ratio: 16 / 11; max-width: none; }
  .about__photo img { object-position: 50% 32%; }
  .mv { grid-template-columns: 1fr; }

  .footer__row { flex-direction: column; align-items: flex-start; }
  .footer__links { flex-direction: column; gap: 8px; }
  .footer__legal { flex-direction: column; }
}

/* titular: "Desarrollamos" es una palabra larga; en celulares chicos se estrecha un poco */
@media (max-width: 400px) { .hero__title { font-stretch: 102%; } }
@media (max-width: 340px) { .hero__title { font-size: 1.95rem; } }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
}
