/* ==========================================================================
   LANDING · Diplomado en IA y Competencias Digitales Docentes
   --------------------------------------------------------------------------
   Índice
   1.  Variables (colores, tipografía, espaciados)
   2.  Reset y base
   3.  Utilidades (container, textos, animación reveal)
   4.  Botones
   5.  Cabecera y navegación
   6.  Secciones genéricas
   7.  Hero
   8.  Qué aprenderás (tarjetas)
   9.  Herramientas
   10. Modalidad
   11. Certificación
   12. Plan de estudio
   13. Formador
   14. Preguntas frecuentes
   15. Pie de página y botón flotante
   16. Responsive (tablet y móvil)
   ========================================================================== */


/* 1. VARIABLES
   ========================================================================== */
:root {
  /* Paleta tomada del diseño original en Canva */
  --blue-900: #1030a9;      /* azul principal */
  --sky-400: #5abcec;       /* celeste del degradado */
  --cyan-200: #96f6ff;      /* texto resaltado */
  --cyan-400: #35cfff;      /* acentos */
  --accent: #0ba9ff;        /* botones / insignias */
  --whatsapp: #25d366;
  --whatsapp-dark: #1da851;

  --white: #ffffff;
  --gray-50: #f5f8ff;
  --gray-600: #4a5578;
  --ink: #0d1b4c;           /* texto oscuro */

  --gradient: linear-gradient(90deg, var(--blue-900) 0%, var(--sky-400) 100%);

  /* Tipografía */
  --font-title: "Montserrat", system-ui, sans-serif;
  --font-body: "Open Sans", system-ui, sans-serif;

  /* Espaciados y formas */
  --container: 1200px;
  --gutter: 24px;
  --radius-sm: 10px;
  --radius: 18px;
  --radius-lg: 28px;
  --shadow: 0 12px 30px rgba(13, 27, 76, 0.18);
  --header-h: 82px;
}


/* 2. RESET Y BASE
   ========================================================================== */
*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: var(--header-h); /* evita que la cabecera tape los títulos */
}

body {
  font-family: var(--font-body);
  font-size: 1rem;
  line-height: 1.6;
  color: var(--white);
  background: var(--blue-900);
  -webkit-font-smoothing: antialiased;
}

img {
  display: block;
  max-width: 100%;
  height: auto;
}

a {
  color: inherit;
  text-decoration: none;
}

ul {
  list-style: none;
}

button {
  font: inherit;
  cursor: pointer;
  border: none;
  background: none;
  color: inherit;
}

:focus-visible {
  outline: 3px solid var(--cyan-200);
  outline-offset: 3px;
}


/* 3. UTILIDADES
   ========================================================================== */
.container {
  width: 100%;
  max-width: var(--container);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

.container--narrow {
  max-width: 860px;
}

.text-highlight {
  color: var(--cyan-200);
}

/* Texto pequeño en mayúsculas sobre los títulos */
.eyebrow {
  display: inline-block;
  font-family: var(--font-title);
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--cyan-200);
  margin-bottom: 12px;
}

.eyebrow--dark {
  color: var(--accent);
}

/* Animación de aparición al hacer scroll (la activa main.js) */
.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.reveal.is-visible {
  opacity: 1;
  transform: none;
}

/* Respeta a usuarios que prefieren menos movimiento */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .reveal { opacity: 1; transform: none; transition: none; }
}


/* 4. BOTONES
   ========================================================================== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 12px 22px;
  border-radius: 999px;
  font-family: var(--font-title);
  font-weight: 700;
  font-size: 0.95rem;
  text-align: center;
  transition: transform 0.2s ease, background-color 0.2s ease, box-shadow 0.2s ease;
}

.btn:hover {
  transform: translateY(-2px);
}

.btn--lg {
  padding: 16px 28px;
  font-size: 1.05rem;
}

.btn--sm {
  padding: 9px 18px;
  font-size: 0.9rem;
}

.btn--whatsapp {
  background: var(--whatsapp);
  color: var(--white);
  box-shadow: 0 8px 20px rgba(37, 211, 102, 0.35);
}

.btn--whatsapp:hover {
  background: var(--whatsapp-dark);
}

.btn--ghost {
  border: 2px solid rgba(255, 255, 255, 0.7);
  color: var(--white);
}

.btn--ghost:hover {
  background: rgba(255, 255, 255, 0.12);
}

.btn__icon {
  width: 22px;
  height: 22px;
  flex-shrink: 0;
}


/* 5. CABECERA Y NAVEGACIÓN
   ========================================================================== */
.header {
  position: fixed;
  inset: 0 0 auto 0;
  z-index: 100;
  height: var(--header-h);
  transition: background-color 0.3s ease, box-shadow 0.3s ease;
}

/* Clase añadida por main.js al hacer scroll */
.header.is-scrolled {
  background: rgba(16, 48, 169, 0.96);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
  backdrop-filter: blur(6px);
}

.header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 100%;
}

.header__logo {
  display: flex;
  align-items: center;
  gap: 20px;
}

.header__logo-img {
  height: 180px;
  width: auto;
}

/* El texto del logo solo se muestra si no existe img/logo.png */
.header__logo-text {
  display: none;
  font-family: var(--font-title);
  font-size: 1.2rem;
}

.header__logo.no-logo .header__logo-text {
  display: inline;
}

.nav {
  display: flex;
  align-items: center;
  gap: 28px;
}

.nav__list {
  display: flex;
  gap: 24px;
}

.nav__link {
  font-weight: 600;
  font-size: 0.95rem;
  opacity: 0.9;
  transition: opacity 0.2s ease, color 0.2s ease;
}

.nav__link:hover {
  opacity: 1;
  color: var(--cyan-200);
}

/* Botón hamburguesa (solo visible en móvil) */
.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  padding: 8px;
}

.nav-toggle span {
  display: block;
  width: 26px;
  height: 3px;
  border-radius: 3px;
  background: var(--white);
  transition: transform 0.3s ease, opacity 0.3s ease;
}


/* 6. SECCIONES GENÉRICAS
   ========================================================================== */
.section {
  padding-block: 96px;
}

.section--gradient {
  background: var(--gradient);
}

.section--light {
  background: var(--gray-50);
  color: var(--ink);
}

.section__header {
  max-width: 820px;
  margin: 0 auto 56px;
  text-align: center;
}

.section__header--left {
  margin-left: 0;
  text-align: left;
}

.section__title {
  font-family: var(--font-title);
  font-weight: 800;
  font-size: clamp(1.9rem, 4vw, 3rem);
  line-height: 1.1;
  letter-spacing: -0.02em;
}

.section__title--xl {
  font-size: clamp(2.3rem, 6vw, 4.5rem);
}

.section__title--dark {
  color: var(--blue-900);
}

.section__lead {
  margin-top: 18px;
  font-size: clamp(1rem, 1.6vw, 1.25rem);
  opacity: 0.95;
}


/* 7. HERO
   ========================================================================== */
.hero {
  position: relative;
  overflow: hidden;
  padding-top: calc(var(--header-h) + 48px);
  padding-bottom: 0;
}

.hero__grid {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  align-items: end;
  gap: 40px;
}

.hero__content {
  padding-bottom: 88px;
}

.hero__title {
  font-family: var(--font-title);
  font-weight: 800;
  font-size: clamp(2.1rem, 4.6vw, 3.6rem);
  line-height: 1.05;
  letter-spacing: -0.03em;
}

.hero__lead {
  margin-top: 24px;
  max-width: 600px;
  font-size: clamp(1.05rem, 1.6vw, 1.3rem);
}

/* Fecha de inicio en la portada */
.start-date {
  display: inline-flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px 14px;
  margin-top: 28px;
  padding: 12px 20px;
  border-radius: var(--radius);
  background: var(--white);
  color: var(--blue-900);
  box-shadow: var(--shadow);
}

.start-date__label {
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--accent);
}

.start-date__value {
  font-family: var(--font-title);
  font-size: clamp(1.05rem, 2vw, 1.3rem);
  font-weight: 800;
}

.start-date__countdown {
  padding: 4px 12px;
  border-radius: 999px;
  background: var(--whatsapp);
  color: var(--white);
  font-size: 0.85rem;
  font-weight: 700;
}

.badges {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 28px;
}

.badge {
  padding: 7px 16px;
  border-radius: 999px;
  background: var(--accent);
  font-size: 0.9rem;
  font-weight: 600;
}

.hero__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin-top: 36px;
}

.hero__media {
  position: relative;
  align-self: flex-start;
  min-height: 660px;
}

/* Forma blanca inclinada inspirada en el diseño original */
.hero__shape {
  position: absolute;
  inset: 8% 0 0 12%;
  border-radius: var(--radius-lg) var(--radius-lg) 0 0;
  background: linear-gradient(160deg, rgba(255, 255, 255, 0.3), rgba(255, 255, 255, 0.05));
  transform: skewX(-8deg);
}

.hero__img {
  position: absolute;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  max-height: 100%;
  width: auto;
}


/* 8. QUÉ APRENDERÁS
   ========================================================================== */
.cards-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

.learn-card {
  padding: 28px;
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.22);
  transition: background-color 0.25s ease, transform 0.25s ease;
}

.learn-card:hover {
  background: rgba(255, 255, 255, 0.18);
  transform: translateY(-4px);
}

.learn-card__num {
  display: inline-grid;
  place-items: center;
  width: 48px;
  height: 48px;
  margin-bottom: 18px;
  border-radius: 14px;
  background: var(--white);
  color: var(--blue-900);
  font-family: var(--font-title);
  font-weight: 800;
}

.learn-card__title {
  font-family: var(--font-title);
  font-size: 1.2rem;
  line-height: 1.3;
  margin-bottom: 8px;
}

.learn-card__text {
  opacity: 0.92;
}


/* 9. HERRAMIENTAS
   ========================================================================== */
.tools {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
}

.tool-group {
  padding: 24px;
  border-radius: var(--radius);
  background: var(--white);
  box-shadow: var(--shadow);
}

.tool-group__title {
  font-family: var(--font-title);
  font-size: 0.85rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 14px;
}

/* Lista vertical: cada herramienta es una fila con logo + nombre */
.tool-group__list {
  display: grid;
  gap: 10px;
}

.tool-item {
  display: flex;
  align-items: center;
  gap: 12px;
  min-height: 56px;
  padding: 10px 14px;
  border-radius: var(--radius-sm);
  background: var(--gray-50);
  border: 1px solid #dbe4ff;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.tool-item:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 14px rgba(13, 27, 76, 0.1);
}

/* Todos los íconos ocupan la misma caja para que se vean alineados */
.tool-item__logo {
  width: 36px;
  height: 36px;
  flex-shrink: 0;
  object-fit: contain;
}

.tool-item__name {
  color: var(--blue-900);
  font-weight: 700;
  font-size: 1rem;
}

/* Logos que ya incluyen el nombre (Gemini Notebook, Suno) */
.tool-item--logotipo .tool-item__logo {
  width: auto;
  max-width: 100%;
  height: 26px;
}


/* 10. MODALIDAD
   ========================================================================== */
.modalidad__grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  align-items: center;
  gap: 48px;
}

.schedule-card {
  padding: 28px;
  border-radius: var(--radius);
  background: var(--white);
  color: var(--ink);
  box-shadow: var(--shadow);
}

.schedule-card__title {
  font-family: var(--font-title);
  font-size: 1.4rem;
  font-weight: 700;
  color: var(--blue-900);
  line-height: 1.3;
}

.schedule-card__text {
  margin-top: 10px;
  color: var(--gray-600);
}

.schedule-card__turns {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 16px;
}

.schedule-card__turns li {
  padding: 8px 16px;
  border-radius: var(--radius-sm);
  background: var(--gradient);
  color: var(--white);
  font-weight: 700;
}

.pill-list {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 24px;
}

.pill {
  padding: 10px 20px;
  border-radius: 999px;
  background: var(--white);
  color: var(--blue-900);
  font-family: var(--font-title);
  font-weight: 700;
}


/* 11. CERTIFICACIÓN
   ========================================================================== */
.cert-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 340px));
  justify-content: center;
  gap: 28px;
}

.cert-card {
  padding: 36px 28px;
  border-radius: var(--radius-lg);
  background: var(--white);
  color: var(--ink);
  text-align: center;
  box-shadow: var(--shadow);
}

.cert-card__tag {
  display: inline-block;
  padding: 4px 12px;
  border-radius: 999px;
  background: var(--gradient);
  color: var(--white);
  font-size: 0.8rem;
  font-weight: 700;
}

.cert-card__title {
  margin-top: 16px;
  font-family: var(--font-title);
  font-size: 1.9rem;
  font-weight: 800;
  color: var(--blue-900);
}

.cert-card__subtitle {
  margin-top: 6px;
  font-weight: 600;
  color: var(--gray-600);
}

.valid-box {
  max-width: 820px;
  margin: 32px auto 0;
  padding: 28px;
  border-radius: var(--radius);
  background: var(--white);
  color: var(--ink);
  text-align: center;
  box-shadow: var(--shadow);
}

.valid-box__title {
  font-family: var(--font-title);
  font-size: 1.6rem;
  font-weight: 800;
  text-transform: uppercase;
}

.valid-box__list {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 12px 28px;
  margin-top: 16px;
}

/* Cada ítem lleva un check dibujado con CSS */
.valid-box__list li {
  position: relative;
  padding-left: 30px;
  font-weight: 600;
}

.valid-box__list li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 50%;
  width: 22px;
  height: 22px;
  transform: translateY(-50%);
  border-radius: 50%;
  background: var(--accent)
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='none' stroke='white' stroke-width='3' stroke-linecap='round' stroke-linejoin='round' d='M5 12.5l4.5 4.5L19 7.5'/%3E%3C/svg%3E")
    center / 14px no-repeat;
}

.valid-box__note {
  margin-top: 18px;
  font-size: 0.95rem;
  color: var(--gray-600);
}


/* 12. PLAN DE ESTUDIO
   ========================================================================== */
.modules-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 28px;
}

.module-card {
  display: flex;
  flex-direction: column;
  padding: 32px;
  border-radius: var(--radius-lg);
  background: var(--white);
  color: var(--ink);
  box-shadow: var(--shadow);
}

.module-card__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 12px 18px;
  border-radius: var(--radius-sm);
  background: var(--blue-900);
  color: var(--white);
  font-family: var(--font-title);
}

.module-card__label {
  font-size: 1.3rem;
  font-weight: 800;
}

.module-card__sessions {
  font-size: 0.8rem;
  font-weight: 700;
  padding: 4px 10px;
  border-radius: 999px;
  background: var(--accent);
}

.module-card__title {
  margin-top: 20px;
  font-family: var(--font-title);
  font-size: 1.35rem;
  line-height: 1.3;
  color: var(--blue-900);
}

.module-card__desc {
  margin-top: 8px;
  color: var(--gray-600);
}

.module-card__topics {
  display: grid;
  gap: 10px;
  margin-top: 20px;
  padding-top: 20px;
  border-top: 1px solid #e3e9fb;
}

.module-card__topics li {
  display: flex;
  align-items: flex-start;
  gap: 10px;
}

.module-card__topics svg {
  width: 20px;
  height: 20px;
  flex-shrink: 0;
  margin-top: 2px;
  color: var(--accent);
}

/* Banda de llamada a la acción bajo el plan de estudio */
.cta-band {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  margin-top: 40px;
  padding: 28px 32px;
  border-radius: var(--radius-lg);
  background: rgba(255, 255, 255, 0.14);
  border: 1px solid rgba(255, 255, 255, 0.3);
}

.cta-band__text {
  font-family: var(--font-title);
  font-size: 1.2rem;
  font-weight: 700;
  max-width: 620px;
}


/* 13. FORMADOR
   ========================================================================== */
.formador__grid {
  display: grid;
  grid-template-columns: 0.8fr 1.2fr;
  align-items: center;
  gap: 56px;
}

.formador__photo {
  position: relative;
  aspect-ratio: 4 / 5;
  border-radius: var(--radius-lg);
  background: var(--gradient);
  overflow: hidden;
  display: grid;
  place-items: end center;
}

.formador__photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: top;
}

/* Iniciales: solo se ven si falta img/formador.png */
.formador__initials {
  display: none;
  place-self: center;
  font-family: var(--font-title);
  font-size: 5rem;
  font-weight: 800;
  color: rgba(255, 255, 255, 0.85);
}

.formador__photo.no-photo .formador__initials {
  display: block;
}

.formador__name {
  font-family: var(--font-title);
  font-size: clamp(1.7rem, 3vw, 2.4rem);
  line-height: 1.15;
  color: var(--blue-900);
}

.formador__role {
  margin-top: 8px;
  font-weight: 700;
  color: var(--accent);
}

.check-list {
  display: grid;
  gap: 12px;
  margin: 24px 0 32px;
}

.check-list li {
  position: relative;
  padding-left: 32px;
  color: var(--gray-600);
}

.check-list li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 3px;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: var(--accent)
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='none' stroke='white' stroke-width='3' stroke-linecap='round' stroke-linejoin='round' d='M5 12.5l4.5 4.5L19 7.5'/%3E%3C/svg%3E")
    center / 12px no-repeat;
}


/* 14. PREGUNTAS FRECUENTES (acordeón)
   ========================================================================== */
.faq {
  display: grid;
  gap: 14px;
}

.faq-item {
  border-radius: var(--radius);
  background: var(--white);
  color: var(--ink);
  overflow: hidden;
  box-shadow: var(--shadow);
}

.faq-item__question {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  width: 100%;
  padding: 22px 24px;
  text-align: left;
  font-family: var(--font-title);
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--blue-900);
}

/* Icono + / − */
.faq-item__icon {
  position: relative;
  width: 28px;
  height: 28px;
  flex-shrink: 0;
  border-radius: 50%;
  background: var(--gray-50);
}

.faq-item__icon::before,
.faq-item__icon::after {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  width: 12px;
  height: 2px;
  background: var(--blue-900);
  transform: translate(-50%, -50%);
  transition: transform 0.3s ease;
}

.faq-item__icon::after {
  transform: translate(-50%, -50%) rotate(90deg);
}

.faq-item.is-open .faq-item__icon::after {
  transform: translate(-50%, -50%) rotate(0deg);
}

/* La altura se anima desde main.js */
.faq-item__answer {
  height: 0;
  overflow: hidden;
  transition: height 0.3s ease;
}

.faq-item__answer p {
  padding: 0 24px 22px;
  color: var(--gray-600);
}


/* 14b. CIERRE: FECHA DE INICIO
   ========================================================================== */
.final-cta__box {
  padding: 48px 32px;
  border-radius: var(--radius-lg);
  background: var(--white);
  text-align: center;
  box-shadow: var(--shadow);
  border-top: 6px solid var(--accent);
}

.final-cta__date {
  font-family: var(--font-title);
  font-size: clamp(1.8rem, 5vw, 3.2rem);
  font-weight: 800;
  line-height: 1.1;
  color: var(--blue-900);
}

.final-cta__countdown {
  display: inline-block;
  margin-top: 14px;
  padding: 6px 16px;
  border-radius: 999px;
  background: var(--whatsapp);
  color: var(--white);
  font-weight: 700;
}

.final-cta__text {
  max-width: 520px;
  margin: 18px auto 28px;
  color: var(--gray-600);
}


/* 15. PIE DE PÁGINA Y BOTÓN FLOTANTE
   ========================================================================== */
.footer {
  padding-block: 28px;
  background: #0b2176;
  font-size: 0.9rem;
}

.footer__inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.footer__top:hover {
  color: var(--cyan-200);
}

.whatsapp-float {
  position: fixed;
  right: 20px;
  bottom: 20px;
  z-index: 90;
  display: grid;
  place-items: center;
  width: 60px;
  height: 60px;
  border-radius: 50%;
  background: var(--whatsapp);
  color: var(--white);
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.25);
  transition: transform 0.2s ease;
}

.whatsapp-float:hover {
  transform: scale(1.08);
}

.whatsapp-float svg {
  width: 32px;
  height: 32px;
}


/* 16. RESPONSIVE
   ========================================================================== */

/* ---------- Tablet (≤ 1024px) ---------- */
@media (max-width: 1024px) {
  .cards-grid,
  .tools {
    grid-template-columns: repeat(2, 1fr);
  }

  .hero__grid,
  .modalidad__grid {
    grid-template-columns: 1fr;
  }

  .hero__content {
    padding-bottom: 0;
  }

  /* Sin foto en img/hero.png no tiene sentido mostrar el bloque vacío */
  .hero__media.no-image {
    display: none;
  }

  .hero {
    padding-bottom: 64px;
  }

  .hero:has(.hero__media:not(.no-image)) {
    padding-bottom: 0;
  }

  .hero__media {
    min-height: 380px;
    max-width: 520px;
    width: 100%;
    margin-inline: auto;
  }

  .modalidad__intro {
    text-align: center;
  }

  .formador__grid {
    grid-template-columns: 1fr;
    gap: 36px;
  }

  .formador__photo {
    max-width: 360px;
    width: 100%;
    margin-inline: auto;
  }
}

/* ---------- Menú móvil (≤ 900px) ---------- */
@media (max-width: 900px) {
  .nav-toggle {
    display: flex;
  }

  /* El menú se despliega bajo la cabecera */
  .nav {
    position: fixed;
    top: var(--header-h);
    left: 0;
    right: 0;
    flex-direction: column;
    align-items: stretch;
    gap: 16px;
    padding: 24px;
    background: var(--blue-900);
    box-shadow: 0 12px 20px rgba(0, 0, 0, 0.2);
    transform: translateY(-120%);
    visibility: hidden;
    transition: transform 0.3s ease, visibility 0.3s;
  }

  .nav.is-open {
    transform: none;
    visibility: visible;
  }

  .nav__list {
    flex-direction: column;
    gap: 4px;
  }

  .nav__link {
    display: block;
    padding: 10px 0;
    font-size: 1.05rem;
  }

  /* Cabecera siempre con fondo cuando el menú está abierto */
  .header.menu-open {
    background: var(--blue-900);
  }

  /* Hamburguesa → X */
  .nav-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(8px) rotate(45deg); }
  .nav-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
  .nav-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-8px) rotate(-45deg); }

  .modules-grid {
    grid-template-columns: 1fr;
  }

  .cta-band {
    flex-direction: column;
    text-align: center;
  }
}

/* ---------- Móvil (≤ 600px) ---------- */
@media (max-width: 600px) {
  :root {
    --gutter: 16px;
    --header-h: 84px;
  }

  .section {
    padding-block: 64px;
  }

  .section__header {
    margin-bottom: 36px;
  }

  .cards-grid,
  .tools,
  .cert-grid {
    grid-template-columns: 1fr;
  }

  .hero__actions .btn,
  .cta-band .btn,
  .final-cta .btn,
  .formador__content .btn {
    width: 100%;
  }

  .hero__media {
    min-height: 300px;
  }

  .start-date {
    width: 100%;
  }

  .final-cta__box {
    padding: 32px 20px;
  }

  .learn-card,
  .module-card,
  .schedule-card {
    padding: 22px;
  }

  .faq-item__question {
    padding: 18px;
    font-size: 1rem;
  }

  .faq-item__answer p {
    padding: 0 18px 18px;
  }

  .whatsapp-float {
    width: 54px;
    height: 54px;
    right: 14px;
    bottom: 14px;
  }
}
