/* ==========================================================================
   Instituto Be Pro — estilos del sitio público
   Una sola familia tipográfica; solo cambian peso, tamaño y tracking.
   ========================================================================== */

/*
 * TIPOGRAFÍA
 * Provisional: Nunito Sans (licencia libre OFL, alojada en el propio servidor).
 * Es variable: un solo archivo de 31 KB cubre todos los pesos (200–1000).
 * Todos los visitantes ven la misma fuente, en cualquier equipo.
 */
@font-face {
  font-family: "Nunito Sans BePro";
  src: url("../fonts/nunito-sans-latin-wght.woff2") format("woff2");
  font-weight: 200 1000;
  font-style: normal;
  font-display: swap;
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

/*
 * Respaldo con las medidas de Nunito Sans: mientras la fuente termina de
 * descargarse, el texto ocupa el mismo espacio y no "brinca" al cambiar (CLS).
 */
@font-face {
  font-family: "Nunito Sans Respaldo";
  src: local("Arial"), local("Liberation Sans"), local("Helvetica");
  size-adjust: 99.48%;
  ascent-override: 101.63%;
  descent-override: 35.49%;
  line-gap-override: 0%;
}

/*
 * DEFINITIVA: Avenir (comercial). Cuando el cliente entregue los .woff2 con
 * licencia web, colócalos en /assets/fonts/ y descomenta este bloque; como
 * "Avenir BePro" va primero en --bp-font, reemplaza a Nunito Sans sin tocar
 * nada más (actualizar también el <link rel="preload"> en head.php).
 *
@font-face { font-family: "Avenir BePro"; src: url("../fonts/avenir-roman.woff2") format("woff2");  font-weight: 400; font-style: normal; font-display: swap; }
@font-face { font-family: "Avenir BePro"; src: url("../fonts/avenir-medium.woff2") format("woff2"); font-weight: 500; font-style: normal; font-display: swap; }
@font-face { font-family: "Avenir BePro"; src: url("../fonts/avenir-heavy.woff2") format("woff2");  font-weight: 800; font-style: normal; font-display: swap; }
@font-face { font-family: "Avenir BePro"; src: url("../fonts/avenir-black.woff2") format("woff2");  font-weight: 900; font-style: normal; font-display: swap; }
 */

:root {
  --bp-font: "Avenir BePro", "Nunito Sans BePro", "Nunito Sans Respaldo", Arial, sans-serif;

  --bp-black: #090609;
  --bp-ink: #1d1b1f;
  --bp-night: #28252c;
  --bp-graphite: #5e6069;
  --bp-steel: #8a898f;
  --bp-gold: #a48622;
  --bp-white: #fff;

  --bp-container: 1108px;
  --bp-header-pad: 55px;

  --bs-body-font-family: var(--bp-font);
  --bs-body-color: var(--bp-ink);
  --bs-link-color-rgb: 29, 27, 31;
  --bs-link-hover-color-rgb: 94, 96, 105;
}

body {
  font-family: var(--bp-font);
  font-weight: 400;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

.bp-container {
  width: 100%;
  max-width: var(--bp-container);
  margin-inline: auto;
}

/* en pantallas medianas el contenedor deja un margen a los lados (no pega con la orilla) */
@media (min-width: 768px) and (max-width: 1155.98px) {
  .bp-container { width: calc(100% - 3rem); }
}

.skip-link {
  position: absolute;
  z-index: 1050;
  top: .5rem;
  left: .5rem;
  padding: .5rem 1rem;
  background: var(--bp-black);
  color: var(--bp-white);
  border-radius: .375rem;
}

/* --------------------------------------------------------------------------
   Encabezado
   -------------------------------------------------------------------------- */
.site-header {
  background: var(--bp-white);
}

.site-header .navbar {
  min-height: 122px;
  padding: 26px var(--bp-header-pad) 0;
}

.site-logo {
  padding: 0;
  margin: 0;
}

.site-logo img {
  display: block;
  width: 190px;
  height: auto;
}

.site-nav {
  gap: clamp(.75rem, 3vw, 2.4rem);
  align-items: center;
}

.site-nav .nav-link {
  padding: .2rem .7rem;
  border-radius: .45rem;
  color: var(--bp-ink);
  font-size: .75rem;
  font-weight: 400;
  letter-spacing: .13em;
  text-transform: uppercase;
  line-height: 1.4;
  transition: background-color .2s ease, color .2s ease;
}

.site-nav .nav-link:hover,
.site-nav .nav-link:focus-visible,
.site-nav .nav-link.active {
  background: var(--bp-graphite);
  color: var(--bp-white);
}

.navbar-toggler {
  border: 0;
  padding: .5rem;
}

.navbar-toggler:focus {
  box-shadow: 0 0 0 .2rem rgba(94, 96, 105, .35);
}

/* --------------------------------------------------------------------------
   Hero / portada
   -------------------------------------------------------------------------- */
.hero {
  position: relative;
  padding-bottom: clamp(2.5rem, 7vw, 91px);
  background:
    /* destello metálico a la derecha */
    radial-gradient(22% 6% at 100% 27%, rgba(255, 255, 255, .95) 0%, rgba(255, 255, 255, .35) 45%, rgba(255, 255, 255, 0) 100%),
    /* reflejo suave a la izquierda */
    radial-gradient(10% 7% at 0% 32%, rgba(190, 186, 192, .35) 0%, rgba(190, 186, 192, 0) 100%),
    /* barrido oscuro */
    radial-gradient(55% 45% at 0% 55%, rgba(3, 2, 2, .95) 0%, rgba(3, 2, 2, 0) 100%),
    radial-gradient(45% 55% at 60% 100%, rgba(10, 8, 9, .75) 0%, rgba(10, 8, 9, 0) 100%),
    var(--bp-night);
  color: var(--bp-white);
}

/* Video de fondo (solo escritorio; lo activa assets/js/hero-video.js).
   Mientras no carga, se ve el degradado de .hero como respaldo. */
.hero__video {
  position: absolute;
  inset: 0;
  z-index: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0;
  pointer-events: none;
  transition: opacity 1.2s ease;
}

.hero__video.is-playing { opacity: 1; }

.hero__inner {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: 298fr 810fr;
}

.hero__panel {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: 82px 1.5rem 1.75rem;
  /* semitransparente: conserva el gris del diseño y deja ver la animación de fondo */
  background:
    linear-gradient(168deg, rgba(255, 255, 255, 0) 30%, rgba(255, 255, 255, .06) 38%, rgba(255, 255, 255, 0) 47%),
    linear-gradient(180deg, rgba(78, 76, 82, .6) 0%, rgba(71, 69, 74, .55) 32%, rgba(53, 51, 50, .5) 50%, rgba(52, 50, 50, .5) 70%, rgba(63, 61, 63, .55) 100%);
}

.hero__escudo {
  width: 150px;
  height: auto;
  margin-bottom: 38px;
}

.hero__title {
  margin: 0;
  font-size: 1.72rem;
  font-weight: 700; /* Avenir Heavy */
  line-height: 1;
  letter-spacing: .01em;
  text-transform: uppercase;
}

.hero__subtitle {
  display: block;
  margin-top: 1.55rem;
  font-size: .88rem;
  font-weight: 500;
  letter-spacing: .2em;
  line-height: 1.4;
}

.hero__social {
  display: flex;
  gap: 1rem;
  margin: auto 0 0;
  padding: 2rem 0 0;
  list-style: none;
}

.hero__social a,
.hero__social span {
  display: inline-flex;
  color: var(--bp-steel);
  transition: color .2s ease;
}

.hero__social-item--whatsapp a,
.hero__social-item--whatsapp span,
.hero__social a:hover,
.hero__social a:focus-visible {
  color: var(--bp-white);
}

.hero__social .bi {
  width: 22px;
  height: 22px;
}

.hero__media {
  position: relative;
  aspect-ratio: 810 / 506;
  overflow: hidden;
  background: #3a3739;
}

.hero__carousel,
.hero__slides,
.hero__slide,
.hero__slide picture {
  height: 100%;
}

.hero__slide picture { display: block; }

.hero__slide img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.hero__dots {
  margin-bottom: 1rem;
  gap: .6rem;
}

.hero__dots [data-bs-target] {
  width: 9px;
  height: 9px;
  margin: 0;
  border: 0;
  border-radius: 50%;
  background-color: #b9b9bd;
  opacity: 1;
}

.hero__dots .active {
  background-color: var(--bp-white);
  box-shadow: 0 0 0 1px rgba(0, 0, 0, .25);
}

/* --------------------------------------------------------------------------
   Pie de página
   -------------------------------------------------------------------------- */
.site-footer {
  padding: 2.6rem 1rem;
  background: var(--bp-white);
  text-align: center;
}

.tagline {
  margin: 0;
  /* el tracking se reduce en pantallas pequeñas para que la frase quepa */
  padding-left: clamp(.35em, 2.4vw, 1.55em);
  color: #4a4a4f;
  font-size: .88rem;
  font-weight: 400;
  letter-spacing: clamp(.35em, 2.4vw, 1.55em);
  text-transform: uppercase;
  white-space: nowrap;
}

/* --------------------------------------------------------------------------
   Responsive
   -------------------------------------------------------------------------- */
@media (max-width: 1199.98px) {
  :root { --bp-header-pad: 2rem; }
}

@media (max-width: 991.98px) {
  .site-header .navbar {
    min-height: 88px;
    padding: .75rem 1.25rem;
  }

  .site-logo img { width: 150px; }

  /* Menú lateral (offcanvas) */
  .site-offcanvas {
    --bs-offcanvas-width: min(320px, 85vw);
    --bs-offcanvas-bg: var(--bp-night);
    --bs-offcanvas-color: var(--bp-white);
    --bs-offcanvas-padding-x: 1.75rem;
    --bs-offcanvas-padding-y: 1.5rem;
    background:
      radial-gradient(60% 18% at 100% 30%, rgba(255, 255, 255, .12) 0%, rgba(255, 255, 255, 0) 100%),
      var(--bp-night);
  }

  .site-offcanvas .offcanvas-header {
    border-bottom: 1px solid rgba(255, 255, 255, .12);
  }

  .site-offcanvas__logo {
    width: 150px;
    height: auto;
    filter: invert(1);
  }

  .site-offcanvas .offcanvas-body {
    display: flex;
    flex-direction: column;
  }

  .site-nav {
    gap: .35rem;
    align-items: stretch;
    padding-top: 1rem;
  }

  .site-nav .nav-link {
    padding: .85rem 1rem;
    color: var(--bp-white);
    font-size: .85rem;
    font-weight: 500;
    letter-spacing: .16em;
  }

  .site-nav .nav-link:hover,
  .site-nav .nav-link:focus-visible,
  .site-nav .nav-link.active {
    background: var(--bp-graphite);
  }

  .site-offcanvas__tagline {
    margin: auto 0 0;
    padding-top: 2rem;
    color: var(--bp-steel);
    font-size: .7rem;
    letter-spacing: .45em;
    text-align: center;
    text-transform: uppercase;
  }

  .hero__inner { grid-template-columns: minmax(240px, 298fr) 810fr; }

  .hero__panel { padding: 2.5rem 1.25rem 1.5rem; }

  .hero__escudo {
    width: 120px;
    margin-bottom: 1.75rem;
  }

  .hero__title { font-size: 1.45rem; }

  .hero__subtitle { font-size: .8rem; letter-spacing: .12em; }

  /* en tableta la foto se estira a la altura del panel */
  .hero__media { aspect-ratio: auto; min-height: 100%; }
}

@media (max-width: 767.98px) {
  .hero__inner { grid-template-columns: 1fr; }

  .hero__panel { padding: 2.25rem 1.5rem 1.75rem; }

  .hero__title { font-size: 1.72rem; }

  .hero__subtitle { font-size: .88rem; letter-spacing: .2em; }

  /* en celular la foto va primero y el texto debajo */
  .hero__media { aspect-ratio: 810 / 506; order: -1; }
}

@media (max-width: 575.98px) {
  .hero__title { font-size: 1.55rem; }
  .hero__subtitle { font-size: .8rem; letter-spacing: .16em; }
  .tagline { font-size: .78rem; }
}

@media (prefers-reduced-motion: reduce) {
  .site-nav .nav-link,
  .hero__social a { transition: none; }

  .hero__video { display: none; }
}

/* ==========================================================================
   Página: Identidad
   ========================================================================== */
:root {
  --bp-gray-100: #dcdbdb;
  --bp-gray-300: #bfbebe;
  --bp-gray-400: #c8c8cc;
  --bp-gold-bg: #a58325;
  --bp-cream: #eed79f;
  --bp-bronze: #a77433;
  --bp-yellow: #dba414;
  --bp-text: #231f20;
}

.identidad section[id] { scroll-margin-top: 1rem; }

/* ---- Hero ---- */
.hero--identidad { padding-bottom: 0; }

/* el fondo oscuro se desvanece a blanco en la parte baja, como en el diseño */
.hero--identidad::after {
  content: "";
  position: absolute;
  inset: auto 0 0;
  height: 30%;
  background: linear-gradient(rgba(255, 255, 255, 0), #fff);
  pointer-events: none;
}

.hero-id,
.id-subnav {
  position: relative;
  z-index: 1;
}

.hero-id__media {
  position: relative;
  aspect-ratio: 1108 / 597;
  overflow: hidden;
  background: #3a3739;
}

/* velo dorado de izquierda a derecha */
.hero-id__media::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg,
    rgba(165, 131, 37, .93) 0%,
    rgba(165, 131, 37, .82) 28%,
    rgba(165, 131, 37, .45) 52%,
    rgba(165, 131, 37, 0) 78%);
  pointer-events: none;
}

.hero-id__text {
  position: absolute;
  top: 21%;
  left: 7.5%;
  z-index: 2;
  max-width: 30rem;
  color: var(--bp-white);
}

.hero-id__title {
  margin: 0;
  font-size: clamp(2rem, 3.6vw, 2.9rem);
  font-weight: 900;
  line-height: .95;
  text-transform: uppercase;
  max-width: 9.5em;
}

.hero-id__lead {
  margin: .9rem 0 0 .2rem;
  max-width: 17em;
  font-size: clamp(1rem, 1.5vw, 1.15rem);
  font-weight: 500;
  line-height: 1.3;
}

.id-subnav {
  background: #0a0807;
}

.id-subnav ul {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: .25rem clamp(1rem, 6vw, 4.5rem);
  margin: 0;
  padding: .85rem 1rem;
  list-style: none;
}

.id-subnav a {
  color: var(--bp-white);
  font-size: .75rem;
  letter-spacing: .1em;
  text-decoration: none;
  text-transform: uppercase;
}

.id-subnav a:hover,
.id-subnav a:focus-visible { color: var(--bp-cream); }

/* ---- Encabezados de sección ---- */
.id-head {
  max-width: 840px;
  margin: 0 auto;
  text-align: center;
}

.id-head__title {
  margin: 0;
  color: var(--bp-text);
  font-size: 1.4rem;
  font-weight: 900;
  line-height: 1.05;
  text-transform: uppercase;
}

.id-head__sub {
  margin: 1rem 0 0;
  font-size: 1rem;
  font-weight: 800;
}

.id-head__intro {
  margin: 1.1rem 0 0;
  font-size: .9rem;
  line-height: 1.55;
}

/* ---- Formación ---- */
.id-formacion {
  display: grid;
  grid-template-columns: 282px 1fr;
  align-items: start;
  padding: 45px 72px 50px 0;
  background: var(--bp-gray-100);
  color: var(--bp-text);
}

.id-formacion__escudo {
  display: flex;
  justify-content: center;
  padding-top: 15px;
}

.id-formacion__escudo img {
  width: 137px;
  height: auto;
}

.id-formacion__text p {
  margin: 0 0 1.15rem;
  font-size: .9rem;
  line-height: 1.55;
}

.id-formacion__text p:last-child { margin-bottom: 0; }

/* ---- Compromiso ---- */
.id-compromiso {
  padding: 40px 1.5rem 50px;
  background: var(--bp-gold-bg);
}

.id-compromiso .id-head__sub { color: #f5e4b3; }
.id-compromiso .id-head__intro { color: #f1e2b8; }

.id-cards {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  max-width: 954px;
  margin: 2rem auto 0;
}

.id-card {
  overflow: hidden;
  border-radius: 26px;
  background: var(--bp-cream);
  color: var(--bp-text);
  text-align: center;
}

.id-card__media {
  position: relative;
  aspect-ratio: 304 / 317;
}

.id-card__media img,
.id-equipo__media img,
.id-galeria__item img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.id-card__media picture { display: block; height: 100%; }

.id-card__badge {
  position: absolute;
  bottom: 0;
  left: 50%;
  z-index: 1;
  padding: .45rem 1.3rem;
  border-radius: 2rem;
  background: var(--bp-text);
  color: var(--bp-white);
  font-size: .72rem;
  letter-spacing: .1em;
  text-decoration: none;
  text-transform: uppercase;
  white-space: nowrap;
  transform: translate(-50%, 35%);
  transition: background-color .2s ease;
}

.id-card__badge:hover,
.id-card__badge:focus-visible { background: var(--bp-graphite); color: var(--bp-white); }

.id-card__body { padding: 1.4rem 1.75rem 2.5rem; }

/* íconos extraídos del diseño (vector): misma altura, ancho proporcional */
.id-card__icon { display: inline-flex; color: var(--bp-text); }

.id-card__icon .bi {
  width: auto;
  height: 42px;
}

.id-card__title {
  margin: .8rem 0 1rem;
  font-size: .95rem;
  font-weight: 900;
  line-height: 1.2;
  text-transform: uppercase;
}

.id-card__body p {
  margin: 0;
  font-size: .85rem;
  line-height: 1.5;
}

/* ---- Equipo ---- */
.id-equipo {
  padding: 35px 0 0;
  background: var(--bp-gray-100);
  color: var(--bp-text);
}

.id-equipo__card {
  display: grid;
  grid-template-columns: 332px 1fr;
  max-width: 966px;
  margin: 0 auto;
  overflow: hidden;
  border-radius: 26px;
}

.id-equipo__media picture { display: block; height: 100%; }

.id-equipo__text {
  padding: 38px 36px;
  background: var(--bp-gray-300);
}

.id-equipo__text .id-head__title { font-size: 1.3rem; }

.id-equipo__sub {
  margin: .9rem 0 1.2rem;
  font-size: .95rem;
  font-weight: 800;
}

.id-equipo__text p:not(.id-equipo__sub) {
  margin: 0 0 1.1rem;
  font-size: .85rem;
  line-height: 1.55;
}

.id-equipo__text p:last-child { margin-bottom: 0; }

.id-galeria {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 14px;
  padding: 48px 2px 0;
}

.id-galeria__item {
  margin: 0;
  aspect-ratio: 357 / 247;
  overflow: hidden;
}

.id-galeria__item picture { display: block; height: 100%; }

/* ---- Ubicación ---- */
.id-ubicacion {
  padding: 50px 78px 50px;
  background: var(--bp-gray-100);
  color: var(--bp-text);
}

.id-ruta-title {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin: 2rem 0 1.75rem;
  font-size: 1.2rem;
  font-weight: 400;
}

.id-ruta-title::before,
.id-ruta-title::after {
  content: "";
  flex: 1;
  height: 2px;
  background: var(--bp-white);
}

.id-ruta-title .bi {
  width: 1.9rem;
  height: 1.9rem;
  margin-right: -.25rem;
}

.id-rutas {
  max-width: 980px;
  margin-inline: auto;
}

/* las pestañas se reparten el ancho del panel y terminan antes de su esquina redondeada */
.id-rutas__tabs {
  display: flex;
  align-items: flex-end;
  gap: .75rem;
  padding-right: 26px;
}

.id-rutas__de {
  padding: 0 .5rem .45rem 1rem;
  font-size: 1rem;
  font-weight: 800;
}

.id-rutas__tabs .nav {
  flex: 1;
  flex-wrap: nowrap;
  gap: clamp(6px, 1vw, 12px);
}

.id-rutas__tabs .nav-item {
  flex: 1 1 0;
  min-width: 0;
}

.id-rutas__tabs .nav-link {
  width: 100%;
  min-width: 0;
  padding: .45rem .4rem;
  border: 2px solid var(--bp-white);
  border-bottom: 0;
  border-radius: 18px 18px 0 0;
  background: transparent;
  color: var(--bp-text);
  font-size: clamp(.78rem, 1.05vw, .95rem);
  font-weight: 800;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.id-rutas__tabs .nav-link:hover { background: rgba(255, 255, 255, .5); }

.id-rutas__tabs .nav-link.active { background: var(--bp-white); }

.id-rutas__panel {
  display: grid;
  grid-template-columns: 1fr 306px;
  /* misma distancia del mapa al borde del panel: arriba (bajo la franja blanca), derecha y abajo */
  --panel-gap: 16px;
  gap: 2rem;
  padding: 0 var(--panel-gap) var(--panel-gap);
  border: 2px solid var(--bp-white);
  border-radius: 24px;
  background: linear-gradient(var(--bp-white) 0 42px, transparent 42px);
}

.id-rutas__label {
  margin: 0;
  padding: .7rem 0 0 76px;
  height: 42px;
  color: #a07a36;
  font-size: .95rem;
  font-weight: 800;
}

.id-rutas__col--mapa .id-rutas__label {
  padding-left: 0;
  text-align: center;
}

.id-rutas__col--mapa picture { display: block; }

.id-rutas__mapa {
  display: block;
  width: 100%;
  height: auto;
  margin-top: var(--panel-gap);
  /* radio interior = radio del panel (24px) menos la separación */
  border-radius: 12px;
}

.id-rutas__list {
  display: grid;
  gap: 2.6rem;
  margin: 2.6rem 0 1.5rem;
  padding: 0;
  list-style: none;
}

.ruta {
  position: relative;
  display: grid;
  grid-template-columns: 120px 1fr;
  align-items: center;
  column-gap: 20px;
  --ruta-color: var(--bp-bronze);
}

.ruta--destacada { --ruta-color: var(--bp-yellow); }

.ruta__nombre {
  padding: .35rem .5rem;
  border-radius: 2rem;
  background: var(--bp-gray-400);
  font-size: .72rem;
  font-weight: 800;
  text-align: center;
  text-transform: uppercase;
}

.ruta__linea {
  position: relative;
  height: 2px;
  margin-right: 8px;
  background: var(--ruta-color);
}

.ruta__linea::before {
  content: "";
  position: absolute;
  top: 50%;
  left: 0;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: var(--ruta-color);
  transform: translate(-50%, -50%);
}

.ruta__linea::after {
  content: "";
  position: absolute;
  top: 50%;
  right: -8px;
  border-top: 8px solid transparent;
  border-bottom: 8px solid transparent;
  border-left: 12px solid var(--ruta-color);
  transform: translateY(-50%);
}

.ruta__destino {
  position: absolute;
  right: 0;
  bottom: calc(50% + 10px);
  font-size: .72rem;
  font-weight: 800;
  text-transform: uppercase;
}

.id-rutas__vacio {
  margin: 2.6rem 1rem 1.5rem;
  font-size: .9rem;
}

/* ---- Identidad: responsive ---- */
@media (max-width: 991.98px) {
  .id-formacion { grid-template-columns: 200px 1fr; padding-right: 2rem; }

  .id-card__body { padding: 1.2rem 1.1rem 2rem; }

  .id-equipo { padding-inline: 1.25rem; }
  .id-equipo__card { grid-template-columns: 38% 1fr; }

  .id-ubicacion { padding-inline: 1.5rem; }
  .id-rutas__panel { grid-template-columns: 1fr 290px; gap: 1.25rem; }
  .id-rutas__label { padding-left: 1rem; }
}

@media (max-width: 767.98px) {
  /* en celular el texto del hero va debajo de la foto, sobre dorado */
  .hero-id__media::after { background: linear-gradient(0deg, rgba(165, 131, 37, .45), rgba(165, 131, 37, 0) 60%); }

  .hero-id__text {
    position: static;
    max-width: none;
    padding: 1.5rem 1.25rem 1.6rem;
    background: var(--bp-gold-bg);
  }

  .hero-id__title { max-width: none; }

  .id-subnav ul { gap: .25rem 1.4rem; }
  .id-subnav a { font-size: .7rem; }

  .id-formacion {
    grid-template-columns: 1fr;
    gap: 1.5rem;
    padding: 2rem 1.25rem;
  }

  .id-formacion__escudo { padding-top: 0; }
  .id-formacion__escudo img { width: 110px; }

  .id-compromiso { padding: 2rem 1.25rem 2.5rem; }

  .id-cards {
    grid-template-columns: 1fr;
    max-width: 420px;
  }

  .id-equipo__card { grid-template-columns: 1fr; }
  .id-equipo__media { aspect-ratio: 4 / 3; }
  .id-equipo__text { padding: 1.75rem 1.4rem; }

  .id-galeria { grid-template-columns: 1fr; gap: 10px; padding: 1.5rem 0 0; }

  .id-ubicacion { padding: 2rem 1rem 2.5rem; }

  .id-ruta-title { font-size: 1.05rem; gap: .6rem; }

  .id-rutas__tabs { flex-direction: column; align-items: stretch; gap: .5rem; }
  .id-rutas__de { padding: 0 0 0 .25rem; }
  .id-rutas__tabs .nav { gap: 8px; }
  .id-rutas__tabs .nav-link { min-width: 0; font-size: .85rem; }

  .id-rutas__panel {
    grid-template-columns: 1fr;
    --panel-gap: 12px;
    gap: 0;
    padding: 0 var(--panel-gap) var(--panel-gap);
  }

  .id-rutas__label { padding-left: .25rem; }

  .ruta { grid-template-columns: 104px 1fr; column-gap: 14px; }

  .id-rutas__col--mapa .id-rutas__label {
    height: auto;
    padding: 0 0 .5rem;
  }

  .id-rutas__mapa { max-width: 360px; margin: 0 auto; }
  .id-rutas__col--mapa .id-rutas__label { padding-top: .25rem; }
}

@media (max-width: 767.98px) {
  /* subnav en una sola línea */
  .id-subnav ul { flex-wrap: nowrap; gap: 1rem; padding-inline: .5rem; }
  .id-subnav a { font-size: .66rem; letter-spacing: .06em; }

  /* pestañas de zonas en cuadrícula (se ven todas sin desplazar) */
  .id-rutas__tabs .nav {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 6px;
    overflow: visible;
  }

  .id-rutas__tabs .nav-link {
    width: 100%;
    padding: .45rem .25rem;
    border-bottom: 2px solid var(--bp-white);
    border-radius: 12px;
    font-size: .78rem;
    white-space: normal;
    line-height: 1.15;
  }

  .id-rutas__tabs { margin-bottom: .75rem; padding-right: 0; }
}

/* Página 404 */
.pagina-404 { padding: 5rem 1.25rem; text-align: center; }
.pagina-404 h1 { font-size: 1.6rem; font-weight: 900; text-transform: uppercase; }
.pagina-404 p { margin: 1rem 0 2rem; }

@media (min-width: 768px) and (max-width: 999.98px) {
  /* tableta: el texto largo de una pestaña pasa a dos líneas en lugar de cortarse */
  .id-rutas__tabs .nav-link {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 100%;
    white-space: normal;
    line-height: 1.1;
  }
}

/* ---- Mapa: miniatura que se amplía en un modal ---- */
.id-rutas__zoom {
  position: relative;
  display: block;
  width: 100%;
  padding: 0;
  border: 0;
  background: none;
  cursor: zoom-in;
}

.id-rutas__zoom:focus-visible {
  outline: 3px solid var(--bp-bronze);
  outline-offset: 3px;
  border-radius: 12px;
}

.id-rutas__zoom .id-rutas__mapa { transition: filter .2s ease; }
.id-rutas__zoom:hover .id-rutas__mapa { filter: brightness(.94); }

.id-rutas__zoom-icon {
  position: absolute;
  right: 10px;
  bottom: 10px;
  display: inline-flex;
  padding: 8px;
  border-radius: 50%;
  background: rgba(35, 31, 32, .75);
  color: var(--bp-white);
  transition: transform .2s ease, background-color .2s ease;
}

.id-rutas__zoom:hover .id-rutas__zoom-icon {
  background: var(--bp-text);
  transform: scale(1.1);
}

.id-rutas__zoom-icon .bi { width: 14px; height: 14px; }

.modal-mapa { --bs-modal-margin: 1rem; }

/* fondo más oscuro detrás del mapa ampliado */
body:has(.modal-mapa.show) .modal-backdrop { --bs-backdrop-opacity: .85; }

.modal-mapa .modal-dialog {
  max-width: min(92vw, calc(100vh - 7rem), 1000px);
}

.modal-mapa .modal-content {
  border: 0;
  background: transparent;
}

.modal-mapa .modal-header {
  padding: 0 0 .75rem;
  border: 0;
}

.modal-mapa .modal-title {
  color: var(--bp-white);
  font-size: .85rem;
  font-weight: 500;
  letter-spacing: .16em;
  text-transform: uppercase;
}

.modal-mapa .btn-close { opacity: .85; }

.modal-mapa__img {
  display: block;
  width: 100%;
  height: auto;
  border-radius: 18px;
  background: #bfbebe;
}

@media (prefers-reduced-motion: reduce) {
  .id-rutas__zoom .id-rutas__mapa,
  .id-rutas__zoom-icon { transition: none; }
}

/* ---- Identidad: entrada del texto del hero, renglón por renglón ----
   Cada renglón sube desde abajo de su propia "máscara": arranca rápido y
   frena lento hasta quedar fijo (curva ease-out exponencial). Ocurre una vez. */
@keyframes bp-renglon {
  from { opacity: 0; transform: translateY(110%); }
  to   { opacity: 1; transform: none; }
}

@keyframes bp-entrada-linea {
  from { transform: scaleX(0); }
  to   { transform: scaleX(1); }
}

.hero-id .renglon {
  display: block;
  overflow: hidden;
  /* margen extra para no recortar acentos (Ó) ni letras con trazo abajo */
  padding-block: .12em;
  margin-block: -.12em;
}

.hero-id .renglon > span {
  display: block;
  animation: bp-renglon 1.1s cubic-bezier(.16, 1, .3, 1) both;
}

.hero-id__title .renglon:nth-child(1) > span { animation-delay: .10s; }
.hero-id__title .renglon:nth-child(2) > span { animation-delay: .22s; }
.hero-id__title .renglon:nth-child(3) > span { animation-delay: .34s; }
.hero-id__lead  .renglon:nth-child(1) > span { animation-delay: .55s; }
.hero-id__lead  .renglon:nth-child(2) > span { animation-delay: .67s; }

/* línea fina que se dibuja entre el título y el texto */
.hero-id__lead::before {
  content: "";
  display: block;
  width: 56px;
  height: 2px;
  margin-bottom: .8rem;
  background: currentColor;
  opacity: .85;
  transform-origin: left center;
  animation: bp-entrada-linea .9s cubic-bezier(.16, 1, .3, 1) .5s both;
}

@media (prefers-reduced-motion: reduce) {
  .hero-id .renglon > span,
  .hero-id__lead::before { animation: none; }
}

/* ==========================================================================
   Página: Acreditación profesional
   ========================================================================== */

/* ---- Consulta (PDF pág. 2) ---- */
.hero--acreditacion .acr-barra,
.hero--acreditacion .acr-consulta { position: relative; z-index: 1; }

.acr-barra {
  background: var(--bp-gold-bg);
  text-align: center;
}

.acr-barra__titulo {
  margin: 0;
  padding: 1.55rem 1rem 1.5rem;
  padding-left: calc(1rem + .55em); /* compensa el tracking del último carácter */
  color: var(--bp-ink);
  font-size: 1.2rem;
  font-weight: 900;
  letter-spacing: .55em;
  line-height: 1.2;
  text-transform: uppercase;
}

.acr-form.hero__panel { padding: 24px 1.75rem 1.75rem; }

.acr-form__escudo {
  width: 100px;
  height: auto;
  margin-bottom: 1.1rem;
}

.acr-form__titulo {
  margin: 0;
  font-size: 1rem;
  font-weight: 900;
  line-height: 1.15;
  text-transform: uppercase;
}

.acr-form__intro {
  margin: .9rem 0 1.25rem;
  font-size: .85rem;
  line-height: 1.35;
}

.acr-form__form {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  width: 100%;
}

.acr-form__form label {
  margin-bottom: .45rem;
  font-size: .8rem;
}

.acr-form__form label strong { font-weight: 900; text-transform: uppercase; }

.acr-form__form input {
  height: 40px;
  padding: 0 1.1rem;
  border: 2px solid transparent;
  border-radius: 2rem;
  background: var(--bp-white);
  color: var(--bp-text);
  font: inherit;
  font-size: .95rem;
  text-align: center;
}

.acr-form__form input:focus {
  outline: none;
  border-color: var(--bp-gold-bg);
  box-shadow: 0 0 0 3px rgba(165, 131, 37, .35);
}

#acr-codigo { text-transform: uppercase; letter-spacing: .06em; }

.acr-form__o {
  margin: .8rem 0 .6rem;
  font-size: .78rem;
  text-transform: uppercase;
}

.acr-form__btn {
  align-self: center;
  margin-top: 1.1rem;
  padding: .5rem 1.8rem;
  border: 0;
  border-radius: 2rem;
  background: var(--bp-gold-bg);
  color: var(--bp-white);
  font-size: .78rem;
  font-weight: 800;
  letter-spacing: .14em;
  text-transform: uppercase;
  transition: background-color .2s ease;
}

.acr-form__btn:hover,
.acr-form__btn:focus-visible { background: #8c6f1e; }

.acr-form__error {
  padding: .45rem .7rem;
  border-radius: .6rem;
  background: rgba(255, 255, 255, .92);
  color: #8a1c1c;
  font-size: .8rem;
  line-height: 1.35;
}

/*
 * La foto conserva su proporción completa (se ven todas las personas) y el panel
 * del formulario se compacta para no ser más alto que ella.
 */
.acr-consulta { align-items: stretch; }
.acr-consulta__media { aspect-ratio: 1400 / 753; }
.acr-consulta__media img { object-position: center 30%; }

@media (min-width: 768px) {
  .acr-form.hero__panel { padding: 18px 1.5rem 1.1rem; }
  .acr-form__escudo { width: 78px; margin-bottom: .7rem; }
  .acr-form__titulo { font-size: .95rem; }
  .acr-form__intro { margin: .55rem 0 .8rem; font-size: .8rem; }
  .acr-form__form label { margin-bottom: .3rem; font-size: .76rem; }
  .acr-form__form input { height: 36px; }
  .acr-form__o { margin: .45rem 0 .35rem; font-size: .72rem; }
  .acr-form__btn { margin-top: .75rem; padding: .42rem 1.6rem; }
  .acr-form__error { padding: .3rem .6rem; font-size: .74rem; }
}

/* pantallas medianas: la foto es más baja, el panel se compacta un poco más */
@media (min-width: 768px) and (max-width: 1199.98px) {
  .acr-form__escudo { width: 60px; margin-bottom: .45rem; }
  .acr-form__intro { margin: .4rem 0 .55rem; }
  .acr-form__btn { margin-top: .55rem; }
}

/* ---- Perfil académico (PDF pág. 3) ---- */
.perfil { grid-template-columns: 298fr 810fr; }

.perfil__foto {
  overflow: hidden;
  background: #eef0ee;
}

.perfil__foto picture { display: block; height: 100%; }

.perfil__foto img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center top;
}

.perfil__panel {
  display: grid;
  grid-template-columns: 136px 1fr;
  padding: 30px 36px 2rem 0;
  background:
    linear-gradient(168deg, rgba(255, 255, 255, 0) 40%, rgba(255, 255, 255, .07) 52%, rgba(255, 255, 255, 0) 64%),
    linear-gradient(180deg, rgba(78, 76, 82, .6) 0%, rgba(58, 56, 58, .55) 50%, rgba(63, 61, 63, .6) 100%);
  color: var(--bp-white);
}

.perfil__escudo {
  justify-self: center;
  width: 90px;
  height: auto;
  margin-top: 18px;
}

.perfil__etiqueta {
  margin: 0;
  padding: 0 0 .9rem 4px;
  border-bottom: 1px solid rgba(255, 255, 255, .85);
  font-size: .85rem;
  letter-spacing: .5em;
  text-transform: uppercase;
}

.perfil__nombre {
  margin: 0;
  padding: .7rem 0 .8rem;
  border-bottom: 1px solid rgba(255, 255, 255, .85);
  font-size: 1.45rem;
  font-weight: 900;
  line-height: 1.05;
}

.perfil__tabla {
  width: 100%;
  border-collapse: collapse;
  font-size: .78rem;
}

.perfil__tabla thead th {
  padding: .55rem .25rem;
  border-bottom: 1px solid rgba(255, 255, 255, .85);
  font-size: .68rem;
  font-weight: 900;
  text-align: left;
  text-transform: uppercase;
}

.perfil__tabla th[scope="row"],
.perfil__tabla td {
  padding: .42rem .25rem;
  font-weight: 400;
  text-align: left;
  vertical-align: middle;
}

.perfil__tabla thead th:nth-child(1) { width: 36%; }
.perfil__tabla thead th:nth-child(2) { width: 28%; }
.perfil__tabla thead th:nth-child(3) { width: 26%; }

.perfil__tabla .perfil__col-constancia { text-align: center; }

.perfil__tabla tr.es-acreditado th,
.perfil__tabla tr.es-pendiente th {
  color: #c39b3f;
  font-weight: 900;
}

.perfil__tabla tr.es-acreditado td[data-label="Fecha"] { text-transform: uppercase; }

.perfil__pill {
  display: inline-block;
  padding: .2rem .8rem;
  border-radius: 2rem;
  background: var(--bp-gold-bg);
  color: #f6ecd0;
  font-size: .68rem;
  font-weight: 900;
  text-transform: uppercase;
  white-space: nowrap;
}

.perfil__pendiente {
  color: #b9b8bc;
  font-size: .72rem;
  text-transform: uppercase;
}

.perfil__guion { color: #9e9da2; }

.perfil__descarga {
  display: inline-flex;
  color: var(--bp-white);
  transition: color .2s ease, transform .2s ease;
}

.perfil__descarga:hover,
.perfil__descarga:focus-visible { color: #e7c873; transform: translateY(1px); }

.perfil__descarga .bi { width: 20px; height: 20px; }

.perfil__nueva {
  margin: 1.2rem 0 0;
  font-size: .8rem;
}

.perfil__nueva a { color: #e7d6a6; text-decoration: none; }
.perfil__nueva a:hover { text-decoration: underline; }

/* ---- Acreditación: responsive ---- */
@media (max-width: 991.98px) {
  .acr-barra__titulo { font-size: 1rem; letter-spacing: .35em; padding-left: calc(1rem + .35em); }

  .perfil { grid-template-columns: minmax(220px, 298fr) 810fr; }
  .perfil__panel { grid-template-columns: 1fr; padding: 1.5rem; }
  .perfil__escudo { display: none; }
}

@media (max-width: 767.98px) {
  .acr-barra__titulo { font-size: .85rem; letter-spacing: .25em; padding: 1.1rem .5rem; }

  /* en celular el formulario va primero: es la acción principal de la página */
  .acr-consulta .acr-form { order: -1; }
  .acr-consulta__media { aspect-ratio: 810 / 432; }

  .acr-form__form { max-width: 340px; margin-inline: auto; }

  .perfil { grid-template-columns: 1fr; }
  .perfil__foto { aspect-ratio: 4 / 4.2; }
  .perfil__panel { padding: 1.5rem 1.25rem 1.75rem; }
  .perfil__nombre { font-size: 1.35rem; }

  /* la tabla se convierte en una lista de tarjetas */
  .perfil__tabla thead { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }

  .perfil__tabla tbody tr {
    display: grid;
    grid-template-columns: 1fr auto;
    column-gap: .75rem;
    padding: .7rem 0;
    border-bottom: 1px solid rgba(255, 255, 255, .15);
  }

  .perfil__tabla th[scope="row"] { grid-column: 1; padding: 0 0 .3rem; font-size: .85rem; }

  .perfil__tabla td { padding: 0; }
  .perfil__tabla td[data-label="Estatus"] { grid-column: 1; }
  .perfil__tabla td[data-label="Fecha"] { grid-column: 1; padding-top: .3rem; font-size: .72rem; }

  .perfil__tabla td.perfil__col-constancia {
    grid-column: 2;
    grid-row: 1 / span 3;
    align-self: center;
  }

  /* los cursos sin registro se muestran compactos: solo nombre */
  .perfil__tabla tr.es-ninguno td[data-label="Estatus"],
  .perfil__tabla tr.es-ninguno td[data-label="Fecha"] { display: none; }
  .perfil__tabla tr.es-ninguno th { padding: 0; color: #cfcfd3; }

  .perfil__tabla tr.es-pendiente td[data-label="Fecha"] { display: none; }

  .perfil__descarga .bi { width: 26px; height: 26px; }
}
