/* =========================================================
   VFCenter — hoja de estilos del sitio
   1. Tipografías
   2. Tokens
   3. Base y accesibilidad
   4. Cabecera y navegación
   5. Botones y enlaces
   6. Media (fotos, mapas, radios)
   7. Bloques de contenido
   8. Carrusel y galería
   9. Banner de cookies
  10. Preferencias de movimiento
   ========================================================= */

/* ---------- 1. Tipografías ---------- */

/* Montserrat autoalojada: antes venía de fonts.googleapis.com, que bloqueaba

   el renderizado y añadía un tercero a la política de cookies. El navegador

   solo descarga el subset que necesita gracias a unicode-range. */

@font-face {
  font-family: "Montserrat";
  src: url("../docs/font/montserrat/montserrat-400-latin.woff2") format("woff2");
  font-weight: 400;
  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;
}

@font-face {
  font-family: "Montserrat";
  src: url("../docs/font/montserrat/montserrat-400-latin-ext.woff2") format("woff2");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

@font-face {
  font-family: "Montserrat";
  src: url("../docs/font/montserrat/montserrat-500-latin.woff2") format("woff2");
  font-weight: 500;
  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;
}

@font-face {
  font-family: "Montserrat";
  src: url("../docs/font/montserrat/montserrat-500-latin-ext.woff2") format("woff2");
  font-weight: 500;
  font-style: normal;
  font-display: swap;
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

@font-face {
  font-family: "Montserrat";
  src: url("../docs/font/montserrat/montserrat-600-latin.woff2") format("woff2");
  font-weight: 600;
  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;
}

@font-face {
  font-family: "Montserrat";
  src: url("../docs/font/montserrat/montserrat-600-latin-ext.woff2") format("woff2");
  font-weight: 600;
  font-style: normal;
  font-display: swap;
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

@font-face {
  font-family: "Montserrat";
  src: url("../docs/font/montserrat/montserrat-700-latin.woff2") format("woff2");
  font-weight: 700;
  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;
}

@font-face {
  font-family: "Montserrat";
  src: url("../docs/font/montserrat/montserrat-700-latin-ext.woff2") format("woff2");
  font-weight: 700;
  font-style: normal;
  font-display: swap;
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

@font-face {
  font-family: "Montserrat";
  src: url("../docs/font/montserrat/montserrat-800-latin.woff2") format("woff2");
  font-weight: 800;
  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;
}

@font-face {
  font-family: "Montserrat";
  src: url("../docs/font/montserrat/montserrat-800-latin-ext.woff2") format("woff2");
  font-weight: 800;
  font-style: normal;
  font-display: swap;
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

@font-face {
  font-family: "Montserrat";
  src: url("../docs/font/montserrat/montserrat-900-latin.woff2") format("woff2");
  font-weight: 900;
  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;
}

@font-face {
  font-family: "Montserrat";
  src: url("../docs/font/montserrat/montserrat-900-latin-ext.woff2") format("woff2");
  font-weight: 900;
  font-style: normal;
  font-display: swap;
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

/* Vitesse en woff2 (un tercio del peso del .otf original) con el .otf
   como reserva para navegadores muy antiguos. */

@font-face {
  font-family: "Vitesse";
  src:
    url("../docs/font/Vitesse%20Font/Vitesse-Book.woff2") format("woff2"),
    url("../docs/font/Vitesse%20Font/Vitesse-Book.otf") format("opentype");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "Vitesse";
  src:
    url("../docs/font/Vitesse%20Font/Vitesse-Medium.woff2") format("woff2"),
    url("../docs/font/Vitesse%20Font/Vitesse-Medium.otf") format("opentype");
  font-weight: 500;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "Vitesse";
  src:
    url("../docs/font/Vitesse%20Font/Vitesse-Bold.woff2") format("woff2"),
    url("../docs/font/Vitesse%20Font/Vitesse-Bold.otf") format("opentype");
  font-weight: 700;
  font-style: normal;
  font-display: swap;
}

/* ---------- 2. Tokens ---------- */
:root {
  --navy: #084771;
  --cyan: #00aeef;
  /* Cian oscurecido para TEXTO: #00AEEF sobre blanco da 2,5:1 y no pasa AA.
     Este tono da 4,6:1 manteniendo la identidad. */
  --cyan-deep: #0e7fa8;
  /* Tinta profunda para texto sobre relleno cian (6:1). */
  --ink: #052f49;
  --white: #ffffff;
  --surface: #eef2f5;
  --surface-strong: #dfe7ec;
  --line: color-mix(in srgb, var(--navy) 16%, transparent);
  --line-strong: color-mix(in srgb, var(--navy) 26%, transparent);
  --muted: color-mix(in srgb, var(--navy) 75%, var(--white));
  --page-max: 72rem;
  --radius: 0.5rem; /* rounded-lg */
  --radius-sm: 0.375rem;
  --header-h: 68px;
  --shadow-soft: 0 1px 2px rgb(8 71 113 / 0.06), 0 8px 24px -12px rgb(8 71 113 / 0.18);
}

@media (min-width: 768px) {
  :root {
    --header-h: 76px;
  }
}

/* ---------- 3. Base y accesibilidad ---------- */
html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  background: var(--white);
  color: var(--navy);
  overflow-wrap: break-word;
}

::selection {
  background: var(--cyan);
  color: var(--ink);
}

/* Foco visible y consistente en todo el sitio, también sobre fondos oscuros. */
:focus-visible {
  outline: 3px solid var(--cyan);
  outline-offset: 3px;
  border-radius: var(--radius-sm);
}

.bg-navy :focus-visible,
.text-white :focus-visible {
  outline-color: var(--cyan);
}

/* Objetivo táctil mínimo de 44x44 px (WCAG 2.5.8). */
.tap-target {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
}

.sr-only-focusable:focus {
  position: fixed;
  z-index: 100;
}

.font-display {
  font-family: "Vitesse", Georgia, "Times New Roman", serif;
  font-weight: 700;
  letter-spacing: -0.02em;
}

/* Titulares: equilibrio de línea y sin viudas. */
h1,
h2,
h3 {
  text-wrap: balance;
}

p {
  text-wrap: pretty;
}

/* Cian legible: se sube la especificidad para ganar a la utilidad de Tailwind
   sin depender del orden de carga del CDN. */
body .text-cyan {
  color: var(--cyan-deep);
}

body .text-cyan-light {
  color: var(--cyan);
}

body .text-navy\/60,
body .text-navy\/65,
body .text-navy\/70 {
  color: var(--muted);
}

/* Sobre fondo marino el blanco al 65% es legible, pero se sube un punto. */
body .text-white\/60,
body .text-white\/65 {
  color: rgb(255 255 255 / 0.78);
}

/* ---------- 4. Cabecera y navegación ---------- */
header[data-header] {
  transition: box-shadow 0.2s ease, border-color 0.2s ease;
  border-bottom: 1px solid transparent;
}

/* Pantallas de 320-359 px: sin esto el «Reservar» empuja el botón de menú
   fuera de la cabecera y deja de poder pulsarse. */
@media (max-width: 359px) {
  header[data-header] .header-logo {
    height: 1.25rem;
  }

  header[data-header] .header-cta {
    padding-inline: 0.6rem;
    font-size: 0.8125rem;
  }

  /* «Windsurf» a 60 px es una palabra que no parte y sacaba la portada de la
     pantalla en los móviles de 320 px. */
  .sport-hero-grid h1 {
    font-size: 3rem;
  }
}

header[data-header][data-scrolled="true"] {
  border-bottom-color: var(--line);
  box-shadow: var(--shadow-soft);
  backdrop-filter: saturate(180%) blur(8px);
  background: rgb(255 255 255 / 0.92);
}

.nav-map {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.75rem;
  height: 2.75rem;
  border-radius: var(--radius);
  color: var(--navy);
}

.nav-map:hover,
.nav-map:focus-visible {
  background: var(--surface);
  color: var(--cyan-deep);
}

.nav-map svg {
  display: block;
}

.nav-link {
  position: relative;
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  color: var(--navy);
}

.nav-link::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0.6rem;
  height: 2px;
  background: var(--cyan);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.2s ease;
}

.nav-link:hover::after,
.nav-link:focus-visible::after,
.nav-link[aria-current="page"]::after,
.nav-link.is-active::after {
  transform: scaleX(1);
}

.menu-panel a {
  display: flex;
  align-items: center;
  min-height: 52px;
}

.menu-open {
  overflow: hidden;
}

/* El panel móvil arranca justo bajo la cabecera, sin número mágico. */
[data-menu-panel] {
  top: var(--header-h);
  overflow-y: auto;
  overscroll-behavior: contain;
}

/* ---------- 5. Botones y enlaces ---------- */
a {
  transition: color 0.15s ease, background-color 0.15s ease, border-color 0.15s ease;
}

/* Los enlaces dentro de párrafos van subrayados: el color por sí solo no
   basta para señalar un enlace (WCAG 1.4.1). */
main p a:not([class*="bg-"]):not(.btn-ghost):not(.btn-navy):not(.btn-cyan):not(.rate-btn),
main address a,
main li a:not([class*="bg-"]):not(.btn-ghost):not(.rate-btn),
footer li a:not(.rate-btn),
footer p a:not(.rate-btn) {
  text-decoration: underline;
  text-underline-offset: 0.22em;
  text-decoration-thickness: 1px;
  text-decoration-color: var(--line-strong);
}

main p a:not(.rate-btn):hover,
main address a:hover,
main li a:not(.rate-btn):hover,
footer li a:hover,
footer p a:hover {
  text-decoration-color: currentColor;
}

header nav a:hover,
footer a:hover,
main a:hover {
  color: var(--cyan-deep);
}

/* Enlaces de lista del pie y navegación secundaria: área pulsable cómoda. */
footer li a,
footer .legal a {
  display: inline-flex;
  align-items: center;
  min-height: 36px;
}

.btn,
a.bg-navy,
a.bg-cyan,
.btn-navy,
.btn-cyan,
.btn-ghost {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  min-height: 44px;
  border-radius: var(--radius);
  font-weight: 600;
  text-decoration: none;
  transition: background-color 0.15s ease, color 0.15s ease, border-color 0.15s ease;
}

main a.bg-navy,
header a.bg-navy,
footer a.bg-navy,
a.bg-navy,
.btn-navy {
  background: var(--navy);
  color: var(--white) !important;
}

main a.bg-navy:hover,
main a.bg-navy:focus-visible,
header a.bg-navy:hover,
header a.bg-navy:focus-visible,
footer a.bg-navy:hover,
a.bg-navy:hover,
a.bg-navy:focus-visible,
.btn-navy:hover,
.btn-navy:focus-visible {
  background: var(--cyan);
  color: var(--ink) !important;
}

main a.bg-cyan,
header a.bg-cyan,
a.bg-cyan,
.btn-cyan {
  background: var(--cyan);
  color: var(--ink) !important;
}

main a.bg-cyan:hover,
main a.bg-cyan:focus-visible,
header a.bg-cyan:hover,
a.bg-cyan:hover,
a.bg-cyan:focus-visible,
.btn-cyan:hover,
.btn-cyan:focus-visible {
  background: var(--navy);
  color: var(--white) !important;
}

/* Botón secundario gris: se lee como pulsable sin competir con la acción
   principal. Es el que sustituye a los antiguos enlaces de texto. */
.btn-ghost {
  padding: 0.7rem 1.15rem;
  background: var(--surface);
  color: var(--navy);
  border: 1px solid var(--line);
  font-size: 0.875rem;
}

.btn-ghost .btn-arrow {
  transition: transform 0.2s ease;
}

.btn-ghost:hover,
.btn-ghost:focus-visible {
  background: var(--surface-strong);
  border-color: var(--line-strong);
  color: var(--navy);
}

.btn-ghost:hover .btn-arrow,
.btn-ghost:focus-visible .btn-arrow {
  transform: translateX(3px);
}

.btn-ghost svg {
  flex: none;
}

/* Sobre fondo marino el gris se invierte. */
.bg-navy .btn-ghost {
  background: rgb(255 255 255 / 0.12);
  border-color: rgb(255 255 255 / 0.28);
  color: var(--white);
}

.bg-navy .btn-ghost:hover,
.bg-navy .btn-ghost:focus-visible {
  background: var(--white);
  color: var(--navy);
}

/* ---------- 6. Media ---------- */
img,
video {
  max-width: 100%;
  height: auto;
}

/* Radio suave en todas las fotos de contenido; se excluyen logos e iconos. */
main img:not(.no-round),
main iframe,
main video,
.photo-carousel-slide,
.photo-gallery figure,
.media-round {
  border-radius: var(--radius);
}

main img:not(.no-round) {
  background: var(--surface);
}

.footer-logo,
header img,
.no-round {
  border-radius: 0;
  background: none;
}

.footer-logo {
  display: block;
  height: 8rem;
  width: auto;
  max-width: 100%;
  object-fit: contain;
  object-position: left center;
}

.footer-main {
  display: grid;
  gap: 3rem;
}

.footer-link-columns {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 2rem;
}

.footer-intro-bottom {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.75rem;
}

.footer-badge-link {
  display: inline-flex;
  text-decoration: none;
}

.footer-badge-link:hover,
.footer-badge-link:focus-visible {
  color: inherit;
}

.footer-badge {
  width: 5rem;
  height: auto;
}

@media (min-width: 768px) {
  .footer-main {
    grid-template-columns: minmax(13rem, 1fr) minmax(0, 2.4fr);
    align-items: start;
  }
}

/* En una sola columna el pie ocupaba pantalla y media de listas cortas con
   mucho aire. «Deportes» y «Centro» caben en dos columnas; «Otras webs» son
   dos botones anchos y se queda con la fila entera debajo. */
@media (max-width: 639px) {
  .footer-link-columns {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 2rem 1.25rem;
  }

  .footer-link-columns > :last-child {
    grid-column: 1 / -1;
  }

  .footer-main {
    gap: 2.5rem;
    padding-block: 3rem;
  }

  .footer-logo {
    height: 5.5rem;
  }
}

iframe {
  border: 0;
  max-width: 100%;
}

.interactive-embed {
  position: relative;
  width: 100%;
  min-height: 450px;
  overflow: hidden;
}

.interactive-embed iframe {
  display: block;
  width: 100%;
  height: 450px;
  pointer-events: none;
}

.interactive-embed__gate {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 0;
  background: transparent;
  cursor: pointer;
}

.interactive-embed__gate span {
  padding: 0.7rem 1rem;
  border-radius: var(--radius);
  color: var(--white);
  background: rgb(8 71 113 / 0.92);
  box-shadow: var(--shadow-soft);
  font-size: 0.85rem;
  font-weight: 700;
}

.interactive-embed__gate:hover span,
.interactive-embed__gate:focus-visible span {
  background: var(--cyan-deep);
}

.interactive-embed.is-active iframe {
  pointer-events: auto;
}

.interactive-embed.is-active .interactive-embed__gate {
  display: none;
}

.llegar-media {
  display: grid;
  gap: 1.5rem;
}

.llegar-media img,
.llegar-media iframe {
  display: block;
  width: 100%;
  height: 100%;
}

.llegar-media img {
  object-fit: cover;
  min-height: 280px;
}

.llegar-media .llegar-map {
  min-height: 280px;
  overflow: hidden;
}

@media (min-width: 1024px) {
  .llegar-media {
    grid-template-columns: 1fr 1fr;
    align-items: stretch;
  }

  .llegar-media img,
  .llegar-media .llegar-map,
  .llegar-media iframe {
    min-height: 420px;
  }
}

/* ---------- 7. Bloques de contenido ---------- */
/* Banner de WhatsApp: la foto del club bajo un velo navy que mantiene el
   texto blanco por encima de 4,5:1. */
.wa-banner {
  border-radius: var(--radius);
  max-width: 680px;
  background:
    linear-gradient(
      90deg,
      color-mix(in srgb, var(--navy) 88%, transparent),
      color-mix(in srgb, var(--navy) 62%, transparent)
    ),
    url("../img/club-de-playa-almerimar-vista-dron-vfcenter.jpg") center 68% / cover no-repeat;
}

.llegar-block,
.bg-almerimar {
  background:
    linear-gradient(
      180deg,
      color-mix(in srgb, var(--white) 72%, transparent),
      color-mix(in srgb, var(--white) 58%, transparent)
    ),
    url("../img/almerimar-spain-llegar.webp") center / cover no-repeat;
}

/* Extra aire inferior: pb-48 no está en el CSS compilado de Tailwind. */
.formacion-block {
  padding-bottom: 12rem;
}

.llegar-panel {
  padding: 1.5rem;
  border-radius: var(--radius);
  background: color-mix(in srgb, var(--white) 88%, transparent);
}

@media (min-width: 1024px) {
  .llegar-panel {
    padding: 2rem;
  }
}

/* Ficha de oferta de la portada: qué se ofrece, sin precios. */
.sport-facts {
  display: grid;
  margin-top: 1.75rem;
}

.sport-facts > div {
  display: grid;
  grid-template-columns: 80px minmax(0, 1fr);
  gap: 1rem;
  padding: 0.8rem 0;
  border-top: 1px solid var(--line);
}

@media (max-width: 480px) {
  .sport-facts > div {
    grid-template-columns: 1fr;
    gap: 0.2rem;
  }
}

.sport-facts dt {
  font-size: 0.6875rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--cyan-deep);
  line-height: 1.5;
}

.sport-facts dd {
  margin: 0;
  font-size: 0.9375rem;
  line-height: 1.5;
  color: var(--navy);
}

.sport-figure img {
  border-radius: var(--radius);
}

.spot-intro {
  display: grid;
  gap: 2.5rem;
  align-items: center;
}

@media (min-width: 900px) {
  .spot-intro {
    grid-template-columns: minmax(0, 0.95fr) minmax(0, 1.05fr);
    gap: 4rem;
  }
}

.spot-intro__play {
  position: relative;
  display: block;
  padding: 0;
  border: 0;
  background: none;
  cursor: pointer;
  text-align: left;
  border-radius: var(--radius);
  overflow: hidden;
}

.spot-intro__play img {
  width: 100%;
  height: auto;
  display: block;
  box-shadow: 0 18px 40px -24px rgb(8 71 113 / 0.45);
}

.spot-intro__play-mark {
  position: absolute;
  right: 0.9rem;
  bottom: 0.9rem;
  z-index: 2;
  display: grid;
  place-items: center;
  width: 3.7rem;
  height: 2.55rem;
  border-radius: 0.55rem;
  background: #ff0000;
  box-shadow: 0 6px 16px rgb(0 0 0 / 0.4);
}

.spot-intro__play-mark::after {
  content: "";
  width: 0.78rem;
  height: 0.9rem;
  margin-left: 0.12rem;
  background: #fff;
  clip-path: polygon(0 0, 100% 50%, 0 100%);
}

.spot-intro__play:hover .spot-intro__play-mark,
.spot-intro__play:focus-visible .spot-intro__play-mark {
  background: #cc0000;
}

.video-lightbox {
  position: fixed;
  inset: 0;
  width: 100%;
  max-width: none;
  height: 100%;
  max-height: none;
  margin: 0;
  padding: 1.25rem;
  border: 0;
  background: rgb(5 31 49 / 0.78);
  overflow: hidden;
}

.video-lightbox[open] {
  display: grid;
  place-items: center;
}

.video-lightbox::backdrop {
  background: transparent;
}

.video-lightbox__panel {
  position: relative;
  width: min(64rem, 100%);
}

.video-lightbox__close {
  position: absolute;
  top: -2.75rem;
  right: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.5rem;
  height: 2.5rem;
  border: 0;
  border-radius: 999px;
  background: rgb(255 255 255 / 0.12);
  color: #fff;
  cursor: pointer;
}

.video-lightbox__close:hover,
.video-lightbox__close:focus-visible {
  background: #fff;
  color: var(--navy);
}

.video-lightbox__frame {
  position: relative;
  overflow: hidden;
  aspect-ratio: 16 / 9;
  background: #000;
  border-radius: var(--radius);
}

.video-lightbox__frame iframe {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

@media (max-width: 767px) {
  .video-lightbox {
    padding: 0;
  }

  .video-lightbox__panel {
    width: 100%;
    height: 100%;
  }

  .video-lightbox__close {
    top: 0.85rem;
    right: 0.85rem;
    z-index: 2;
  }

  .video-lightbox__frame {
    height: 100%;
    aspect-ratio: auto;
    border-radius: 0;
  }
}

.image-zoom {
  display: block;
  width: 100%;
  padding: 0;
  border: 0;
  background: none;
  cursor: zoom-in;
  text-align: left;
  border-radius: var(--radius);
}

.image-zoom img {
  display: block;
  width: 100%;
  height: auto;
}

.image-zoom:focus-visible {
  outline: 2px solid var(--cyan);
  outline-offset: 3px;
}

.image-lightbox {
  position: fixed;
  inset: 0;
  width: 100%;
  max-width: none;
  height: 100%;
  max-height: none;
  margin: 0;
  padding: 1.25rem;
  border: 0;
  background: rgb(5 31 49 / 0.78);
  overflow: hidden;
}

.image-lightbox[open] {
  display: grid;
  place-items: center;
}

.image-lightbox::backdrop {
  background: transparent;
}

.image-lightbox__panel {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  max-width: 100%;
}

.image-lightbox__close {
  position: static;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.5rem;
  height: 2.5rem;
  margin-bottom: 0.65rem;
  border: 0;
  border-radius: 999px;
  background: rgb(255 255 255 / 0.12);
  color: #fff;
  cursor: pointer;
  z-index: 2;
}

.image-lightbox__close:hover,
.image-lightbox__close:focus-visible {
  background: #fff;
  color: var(--navy);
}

.image-lightbox__frame {
  display: block;
  line-height: 0;
}

.image-lightbox__frame img {
  display: block;
  width: auto;
  height: auto;
  max-width: min(92rem, calc(100vw - 2.5rem));
  max-height: calc(100vh - 7rem);
  object-fit: contain;
  border-radius: var(--radius);
}

@media (max-width: 767px) {
  .image-lightbox {
    padding: 0;
  }

  .image-lightbox__panel {
    width: 100%;
    max-width: none;
    height: 100%;
    display: grid;
    place-items: center;
  }

  .image-lightbox__close {
    position: absolute;
    top: 0.85rem;
    right: 0.85rem;
    margin: 0;
  }

  .image-lightbox__frame {
    width: 100%;
    height: 100%;
    padding: 3.75rem 0.75rem 0.75rem;
  }

  .image-lightbox__frame img {
    max-width: 100%;
    max-height: 100%;
    border-radius: 0;
  }
}

/* ---------- 7.1 Tarifas: tarjetas de bono y matriz de alquiler ---------- */
.rates-head {
  max-width: 40rem;
}

.rates-eyebrow {
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--cyan-deep);
}

.rates-title {
  font-family: "Vitesse", Georgia, "Times New Roman", serif;
  font-weight: 700;
  font-size: clamp(1.7rem, 3.6vw, 2.25rem);
  line-height: 1.12;
  letter-spacing: -0.02em;
  margin-top: 0.5rem;
}

.rates-lead {
  margin-top: 0.75rem;
  font-size: 0.95rem;
  line-height: 1.6;
  color: var(--muted);
}

.rate-cards {
  display: grid;
  gap: 1rem;
  margin-top: 2rem;
}

@media (min-width: 900px) {
  .rate-cards {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  /* Dos bonos (wing foil): sin estirar las tarjetas a media pantalla. */
  .rate-cards--duo {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    max-width: 46rem;
  }
}

/* Las cinco filas se declaran en la rejilla para que precio, ahorro y botón
   caigan a la misma altura en todas las tarjetas. */
.rate-card {
  position: relative;
  display: grid;
  grid-template-rows: auto auto auto 1fr auto;
  min-width: 0;
  padding: 1.75rem 1.5rem 1.5rem;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: var(--white);
  box-shadow: var(--shadow-soft);
}

.rate-card__top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  min-height: 1.75rem;
}

.rate-card__name {
  font-size: 1rem;
  font-weight: 700;
  letter-spacing: 0.01em;
}

.rate-card__dur {
  padding: 0.3rem 0.6rem;
  border-radius: 999px;
  background: var(--surface);
  color: var(--navy);
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  white-space: nowrap;
}

.rate-card__price {
  display: flex;
  align-items: baseline;
  gap: 0.3rem;
  margin-top: 1.1rem;
}

.rate-card__price b {
  font-family: "Vitesse", Georgia, "Times New Roman", serif;
  font-weight: 700;
  font-size: 3rem;
  line-height: 0.95;
  letter-spacing: -0.01em;
  font-variant-numeric: tabular-nums;
}

.rate-card__price i {
  font-style: normal;
  font-size: 1.25rem;
  font-weight: 600;
  opacity: 0.65;
}

.rate-card__meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.5rem;
  margin-top: 0.8rem;
  min-height: 1.9rem;
}

.rate-card__unit {
  font-size: 0.84rem;
  font-weight: 600;
  color: var(--navy);
}

.rate-card__list {
  display: grid;
  gap: 0.6rem;
  align-content: start;
  margin-top: 1.25rem;
  padding-top: 1.25rem;
  border-top: 1px solid var(--line);
  font-size: 0.86rem;
  line-height: 1.45;
}

.rate-card__list li {
  display: grid;
  grid-template-columns: 15px 1fr;
  gap: 0.6rem;
  align-items: start;
}

.rate-card__list svg {
  margin-top: 0.28rem;
  color: var(--cyan-deep);
}

.rate-card__cta {
  margin-top: 1.5rem;
}

.rate-card__cta .rate-btn {
  width: 100%;
}

/* Banda del bono multideporte: es la oferta que se quiere vender, así que va
   ANTES de las tarjetas y es el único bloque en navy de toda la sección. */
.rate-hero {
  display: grid;
  gap: 1.5rem;
  margin-top: 2rem;
  padding: 1.75rem;
  border-radius: 16px;
  background: var(--navy);
  color: var(--white);
}

@media (min-width: 900px) {
  .rate-hero {
    grid-template-columns: 1.05fr 1fr auto;
    gap: 2.25rem;
    align-items: center;
    padding: 1.9rem 2rem;
  }
}

.rate-hero__eyebrow {
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--cyan);
}

.rate-hero__title {
  margin-top: 0.45rem;
  font-family: "Vitesse", Georgia, "Times New Roman", serif;
  font-weight: 700;
  font-size: 1.6rem;
  line-height: 1.1;
  letter-spacing: -0.02em;
}

.rate-hero__sub {
  margin-top: 0.5rem;
  font-size: 0.85rem;
  line-height: 1.5;
  color: color-mix(in srgb, var(--white) 82%, var(--navy));
}

.rate-hero__list {
  display: grid;
  gap: 0.5rem;
  font-size: 0.84rem;
  line-height: 1.4;
}

@media (min-width: 900px) {
  .rate-hero__list {
    padding-left: 2.25rem;
    border-left: 1px solid color-mix(in srgb, var(--white) 24%, transparent);
  }
}

.rate-hero__list li {
  display: grid;
  grid-template-columns: 15px 1fr;
  gap: 0.55rem;
  align-items: start;
}

.rate-hero__list svg {
  margin-top: 0.25rem;
  color: var(--cyan);
}

.rate-hero__buy {
  display: grid;
  gap: 0.55rem;
  justify-items: start;
}

@media (min-width: 900px) {
  .rate-hero__buy {
    min-width: 12rem;
    justify-items: end;
    text-align: right;
  }
}

.rate-hero__price {
  display: flex;
  align-items: baseline;
  gap: 0.3rem;
}

.rate-hero__price b {
  font-family: "Vitesse", Georgia, "Times New Roman", serif;
  font-weight: 700;
  font-size: 2.9rem;
  line-height: 0.95;
  font-variant-numeric: tabular-nums;
}

.rate-hero__price i {
  font-style: normal;
  font-size: 1.2rem;
  font-weight: 600;
  opacity: 0.7;
}

.rate-hero__unit {
  font-size: 0.8rem;
  color: color-mix(in srgb, var(--white) 82%, var(--navy));
}

.rate-hero .rate-btn {
  margin-top: 0.35rem;
}

/* Botón sobre fondo navy —banda del bono y banner de WhatsApp—: se invierte a
   blanco con texto navy y aclara al pasar, en vez de saltar a otro color. */
.rate-hero .rate-btn,
.wa-banner .rate-btn,
.bg-navy .rate-btn {
  background: var(--white);
  color: var(--navy) !important;
}

.rate-hero .rate-btn:hover,
.rate-hero .rate-btn:focus-visible,
.wa-banner .rate-btn:hover,
.wa-banner .rate-btn:focus-visible,
.bg-navy .rate-btn:hover,
.bg-navy .rate-btn:focus-visible {
  background: var(--surface-strong);
  color: var(--navy) !important;
}

.rate-hero a:focus-visible {
  outline: 2px solid var(--cyan);
  outline-offset: 3px;
}

/* Rótulo que separa la banda destacada de los bonos de un solo deporte. */
.rates-subhead {
  margin-top: 2.75rem;
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--cyan-deep);
}

.rates-subhead + .rate-cards {
  margin-top: 1rem;
}

.rate-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  /* Con width:100% dentro de la tarjeta, el padding debe entrar en la caja. */
  box-sizing: border-box;
  max-width: 100%;
  min-height: 46px;
  padding: 0 1.2rem;
  border-radius: var(--radius);
  background: var(--navy);
  color: var(--white) !important;
  font-size: 0.875rem;
  font-weight: 600;
  text-decoration: none;
  transition: background-color 0.15s ease, color 0.15s ease, border-color 0.15s ease;
}

/* El hover oscurece el propio navy; nada de saltar de un color de marca a otro. */
.rate-btn:hover,
.rate-btn:focus-visible {
  background: var(--ink);
  color: var(--white) !important;
}

.rate-btn--ghost {
  border: 1px solid var(--line-strong);
  background: transparent;
  color: var(--navy) !important;
}

.rate-btn--ghost:hover,
.rate-btn--ghost:focus-visible {
  border-color: var(--line-strong);
  background: var(--surface);
  color: var(--navy) !important;
}

.rate-btn svg {
  flex: none;
}

.rate-rent {
  margin-top: 2.75rem;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: var(--surface);
  overflow: hidden;
}

.rate-rent__head {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 1rem;
  padding: 1.5rem 1.5rem 1rem;
}

.rate-rent__head h3 {
  margin-top: 0.35rem;
  font-family: "Vitesse", Georgia, "Times New Roman", serif;
  font-weight: 700;
  font-size: 1.35rem;
  letter-spacing: -0.02em;
}

.rate-rent__head p {
  max-width: 32rem;
  margin-top: 0.35rem;
  font-size: 0.84rem;
  color: var(--muted);
}

.rate-scroll {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}

.rate-table {
  width: 100%;
  min-width: 30rem;
  border-collapse: collapse;
}

.rate-table th,
.rate-table td {
  padding: 0.85rem 1.5rem;
  text-align: right;
}

.rate-table thead th {
  border-bottom: 1px solid var(--line-strong);
  color: var(--cyan-deep);
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  white-space: nowrap;
}

/* La cabecera de la primera columna acompaña a sus filas, no a los precios. */
.rate-table thead th:first-child {
  text-align: left;
}

.rate-table th[scope="row"] {
  text-align: left;
  font-size: 0.9rem;
  font-weight: 600;
  white-space: nowrap;
}

.rate-table tbody tr + tr th,
.rate-table tbody tr + tr td {
  border-top: 1px solid var(--line);
}

.rate-table tbody tr:hover th,
.rate-table tbody tr:hover td {
  background: color-mix(in srgb, var(--white) 55%, transparent);
}

.rate-table td b {
  font-family: "Vitesse", Georgia, "Times New Roman", serif;
  font-weight: 700;
  font-size: 1.3rem;
  font-variant-numeric: tabular-nums;
}

.rate-extras {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  padding: 1.25rem 1.5rem;
  border-top: 1px solid var(--line);
  background: var(--white);
}

.rate-extra {
  display: inline-flex;
  align-items: baseline;
  gap: 0.45rem;
  padding: 0.45rem 0.85rem;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--white);
  font-size: 0.82rem;
}

.rate-extra b {
  font-family: "Vitesse", Georgia, "Times New Roman", serif;
  font-weight: 700;
  font-size: 1rem;
  font-variant-numeric: tabular-nums;
}

/* En el móvil la tabla cabe si se le quitan los 30rem de mínimo y se aprieta
   el acolchado: obligar a un scroll horizontal para leer tres cifras cortas
   escondía la última columna. El .rate-scroll sigue ahí por si algún día una
   tabla lleva más columnas de las que caben. */
@media (max-width: 640px) {
  .rate-rent__head {
    padding: 1.25rem 1rem 0.85rem;
  }

  .rate-table {
    min-width: 0;
  }

  .rate-table th,
  .rate-table td {
    padding: 0.8rem 0.7rem;
  }

  .rate-table thead th {
    font-size: 0.62rem;
    letter-spacing: 0.08em;
  }

  .rate-table td b {
    font-size: 1.15rem;
  }

  /* Los extras dejan de ser flex: en una línea estrecha cada trozo de texto
     era un ítem que rompía por su cuenta y el precio acababa suelto. */
  .rate-extras {
    flex-direction: column;
    align-items: stretch;
    padding: 1rem;
  }

  .rate-extra {
    display: block;
  }

  .rate-extra b {
    white-space: nowrap;
  }
}

.rate-foot {
  display: grid;
  gap: 1.25rem;
  margin-top: 2rem;
}

@media (min-width: 820px) {
  .rate-foot {
    grid-template-columns: 1fr auto;
    align-items: center;
  }
}

.rate-terms {
  display: grid;
  gap: 0.4rem;
  font-size: 0.8rem;
  line-height: 1.5;
  color: var(--muted);
}

.rate-terms li {
  display: grid;
  grid-template-columns: 14px 1fr;
  gap: 0.55rem;
  align-items: start;
}

.rate-terms svg {
  margin-top: 0.25rem;
  color: var(--cyan-deep);
}

.rate-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
}

.sport-hero-grid {
  display: grid;
  width: 100%;
  min-height: min(520px, calc(100svh - var(--header-h)));
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.hero-panel {
  container-type: inline-size;
}

.hero-title {
  font-family: "Montserrat", sans-serif;
  font-weight: 800;
  font-size: clamp(2.6rem, 10vw, 7rem);
  line-height: 0.95;
  letter-spacing: -0.02em;
}

.hero-title span {
  white-space: nowrap;
}

.hero-lede {
  max-width: 42rem;
  font-size: clamp(1.05rem, 2.5vw, 1.3rem);
  line-height: 1.65;
}

/* Iconos de redes: mismo tratamiento en el hero y en el pie. */
.hero-socials,
.footer-socials {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.hero-socials {
  gap: 0.75rem;
}

.hero-socials a,
.footer-socials a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.75rem;
  height: 2.75rem;
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--navy);
  text-decoration: none;
}

.hero-socials a {
  width: 3.75rem;
  height: 3.75rem;
  border-width: 1.5px;
}

.hero-socials a.hero-socials__instagram {
  width: auto;
  height: 3.75rem;
  padding: 0 1.35rem 0 1.05rem;
  gap: 0.65rem;
  overflow: visible;
  white-space: nowrap;
  font-size: 0.95rem;
  font-weight: 700;
}

.hero-socials a:hover,
.hero-socials a:focus-visible,
.footer-socials a:hover,
.footer-socials a:focus-visible {
  color: var(--white);
  background: var(--navy);
  border-color: var(--navy);
}

.hero-socials svg,
.footer-socials svg {
  width: 1.25rem;
  height: 1.25rem;
}

.hero-socials svg {
  width: 1.75rem;
  height: 1.75rem;
  flex: none;
}

@supports (font-size: 1cqi) {
  .hero-title {
    font-size: clamp(2.6rem, 12.4cqi, 7rem);
  }

  .hero-lede {
    font-size: clamp(1.05rem, 2.9cqi, 1.3rem);
  }
}

.sport-hero-image {
  width: 100%;
  height: 100%;
  min-height: 520px;
  object-fit: cover;
  border-radius: 0;
}

@media (min-width: 1024px) {
  .sport-hero-image {
    border-radius: var(--radius) 0 0 var(--radius);
  }
}

.chapter-list {
  counter-reset: chapter;
}

.chapter-item {
  counter-increment: chapter;
  display: grid;
  grid-template-columns: 2.5rem minmax(0, 1fr);
  gap: 1rem;
  padding: 1.25rem 0;
  border-top: 1px solid var(--line);
}

.bg-navy .chapter-item {
  border-top-color: rgb(255 255 255 / 0.22);
}

.chapter-item::before {
  content: counter(chapter, decimal-leading-zero);
  color: var(--cyan);
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  padding-top: 0.25rem;
}

@media (max-width: 420px) {
  .chapter-item {
    grid-template-columns: 2rem minmax(0, 1fr);
    gap: 0.75rem;
  }
}

.wind-placeholder {
  display: grid;
  min-height: 300px;
  place-items: center;
  border-radius: var(--radius);
  border: 1px solid var(--line-strong);
  background:
    linear-gradient(var(--white), var(--white)) padding-box,
    repeating-linear-gradient(
      -45deg,
      transparent,
      transparent 14px,
      color-mix(in srgb, var(--cyan) 10%, transparent) 14px,
      color-mix(in srgb, var(--cyan) 10%, transparent) 15px
    );
}

@media (max-width: 1023px) {
  .sport-hero-grid {
    grid-template-columns: 1fr;
  }

  .sport-hero-image {
    min-height: 300px;
    max-height: 58svh;
  }
}

/* Los widgets de terceros se desbordan en móvil: se aísla el scroll. */
.widget-scroll {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  overscroll-behavior-x: contain;
  border-radius: var(--radius);
}

.widget-scroll--windguru {
  width: 100%;
  overflow: hidden;
}

.widget-scroll--windguru #wg_target_div_48806 {
  transform-origin: top left;
}

/* ---------- 7.2 Víctor Fernández Center: tarjetas de curso y capítulos ---------- */
.course-cards {
  display: grid;
  gap: 1.25rem;
}

@media (min-width: 640px) {
  .course-cards {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (min-width: 1024px) {
  .course-cards {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

/* Cuatro filas fijas: título, duración, temario y llamada. Así las cuatro
   tarjetas miden lo mismo y sus botones caen a la misma altura. */
.course-card {
  display: grid;
  grid-template-rows: auto auto 1fr auto;
  min-width: 0;
  height: 100%;
}

.course-card h3 {
  margin-top: 0;
  font-family: "Vitesse", Georgia, "Times New Roman", serif;
  font-weight: 700;
  font-size: 1.5rem;
  letter-spacing: -0.02em;
}

.course-card__meta {
  margin-top: 0.6rem;
  font-size: 0.8rem;
  color: var(--muted);
}

.course-card__index {
  display: grid;
  gap: 0.45rem;
  margin: 1.1rem 0 0;
  padding: 1.1rem 0 0;
  border-top: 1px solid var(--line);
  font-size: 0.85rem;
  line-height: 1.4;
  list-style: none;
  align-content: start;
}

.course-card__index li {
  display: grid;
  grid-template-columns: 1.35rem 1fr;
  gap: 0.5rem;
}

.course-card__index span {
  font-variant-numeric: tabular-nums;
  color: var(--cyan-deep);
  font-weight: 700;
}

.course-card__cta {
  display: grid;
  gap: 0.6rem;
  margin-top: 1.4rem;
  justify-items: start;
}

.course-card__cta .rate-btn {
  width: 100%;
}

.course-card__cta a:last-child {
  width: 100%;
  text-align: center;
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--cyan-deep);
}

/* ---- Página de curso ---- */
.course-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: 1.5rem;
}

.course-meta span {
  padding: 0.4rem 0.85rem;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--surface);
  font-size: 0.8rem;
  font-weight: 500;
}

/* Columna lateral con el avance y el temario; el contenido va a la derecha. */
.course-layout {
  display: grid;
  gap: 2.5rem;
}

@media (min-width: 960px) {
  .course-layout {
    grid-template-columns: 17rem minmax(0, 1fr);
    gap: 3.5rem;
    align-items: start;
  }
}

.course-aside {
  display: grid;
  gap: 1.25rem;
  min-width: 0;
}

@media (min-width: 960px) {
  .course-aside {
    position: sticky;
    top: calc(var(--header-h) + 1.5rem);
  }
}

.course-progress {
  display: grid;
  gap: 0.7rem;
  padding: 1.1rem 1.25rem;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
}

.course-index {
  display: grid;
  gap: 0.1rem;
  margin: 0;
  padding: 0;
  list-style: none;
}

.course-index__title {
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--cyan-deep);
  margin-bottom: 0.5rem;
}

.course-index a {
  display: grid;
  grid-template-columns: 1.5rem minmax(0, 1fr);
  gap: 0.6rem;
  align-items: start;
  padding: 0.55rem 0.5rem;
  border-radius: var(--radius-sm);
  font-size: 0.85rem;
  line-height: 1.4;
  color: var(--navy);
  text-decoration: none;
}

.course-index a:hover,
.course-index a:focus-visible {
  background: var(--surface-strong);
  color: var(--navy);
}

.course-index__n {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 1.5rem;
  height: 1.5rem;
  border: 1px solid var(--line-strong);
  border-radius: 999px;
  font-size: 0.7rem;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  color: var(--muted);
}

.course-index li[data-done="true"] .course-index__n {
  border-color: var(--cyan);
  background: var(--cyan);
  color: var(--ink);
}

.course-index li[data-done="true"] a {
  color: var(--muted);
}

.course-progress__text {
  font-size: 0.85rem;
  font-weight: 600;
}

.course-progress__text b {
  font-variant-numeric: tabular-nums;
}

.course-progress__bar {
  grid-column: 1 / -1;
  height: 6px;
  border-radius: 999px;
  background: var(--surface-strong);
  overflow: hidden;
}

.course-progress__fill {
  display: block;
  height: 100%;
  width: 0;
  border-radius: 999px;
  background: var(--cyan);
  transition: width 0.25s ease;
}

.course-reset {
  justify-self: start;
  min-height: 36px;
  padding: 0 0.85rem;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--white);
  color: var(--navy);
  font: inherit;
  font-size: 0.78rem;
  font-weight: 600;
  cursor: pointer;
}

.course-reset:hover,
.course-reset:focus-visible {
  background: var(--surface-strong);
}

.lesson-list {
  display: grid;
  gap: 0.75rem;
  margin: 0;
  padding: 0;
  list-style: none;
}

.lesson {
  border: 1px solid var(--line);
  border-radius: 14px;
  background: var(--white);
  box-shadow: var(--shadow-soft);
  overflow: hidden;
  transition: border-color 0.15s ease;
}

.lesson[data-done="true"] {
  border-color: color-mix(in srgb, var(--cyan) 40%, transparent);
}

.lesson[open] {
  border-color: var(--line-strong);
}

/* Cabecera plegable: número, título, estado y flecha.
 *
 * Los cuatro van sueltos en la rejilla, sin un <span> que agrupe título y
 * subtítulo, porque el título es un <h2> de verdad y <summary> solo admite
 * texto y encabezados: un <span> no puede contener un <h2>. El encabezado
 * importa porque la teoría vive dentro de <details>, y con un <span> los
 * dieciséis capítulos de wing foil colgaban de un único <h1>: se indexaban,
 * pero ni Google ni los buscadores con IA podían citar un capítulo suelto.
 *
 * De ahí las dos filas: número y estado ocupan las dos, título y subtítulo
 * una cada uno. Y el hueco solo entre columnas, que la separación entre
 * título y subtítulo la pone el margen del propio subtítulo. */
.lesson__head {
  display: grid;
  grid-template-columns: 2.25rem minmax(0, 1fr) auto;
  grid-template-rows: auto auto;
  gap: 0 1rem;
  align-items: center;
  padding: 1.25rem 1.5rem;
  cursor: pointer;
  list-style: none;
}

.lesson__head > .lesson__n {
  grid-column: 1;
  grid-row: 1 / -1;
}

.lesson__head > .lesson__title {
  grid-column: 2;
  grid-row: 1;
}

.lesson__head > .lesson__sub {
  grid-column: 2;
  grid-row: 2;
}

.lesson__head > .lesson__state {
  grid-column: 3;
  grid-row: 1 / -1;
}

.lesson__head::-webkit-details-marker {
  display: none;
}

.lesson__head:hover {
  background: color-mix(in srgb, var(--surface) 55%, var(--white));
}

.lesson__n {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.25rem;
  height: 2.25rem;
  border: 1px solid var(--line-strong);
  border-radius: 999px;
  font-size: 0.8rem;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  color: var(--muted);
}

.lesson[data-done="true"] .lesson__n {
  border-color: var(--cyan);
  background: var(--cyan);
  color: var(--ink);
}

.lesson__n svg {
  display: none;
}

.lesson[data-done="true"] .lesson__n svg {
  display: block;
}

.lesson[data-done="true"] .lesson__n span {
  display: none;
}

.lesson__title {
  display: block;
  margin: 0;
  font-family: "Vitesse", Georgia, "Times New Roman", serif;
  font-weight: 700;
  font-size: 1.15rem;
  line-height: 1.25;
  letter-spacing: -0.02em;
}

.lesson__sub {
  display: block;
  margin-top: 0.3rem;
  font-size: 0.85rem;
  line-height: 1.5;
  color: var(--muted);
}

.lesson__state {
  display: inline-flex;
  align-items: center;
  gap: 0.75rem;
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--muted);
  white-space: nowrap;
}

.lesson[data-done="true"] .lesson__state {
  color: var(--cyan-deep);
}

@media (max-width: 560px) {
  .lesson__state [data-estado] {
    display: none;
  }
}

.lesson__chevron {
  flex: none;
  color: var(--cyan-deep);
  transition: transform 0.2s ease;
}

.lesson[open] .lesson__chevron {
  transform: rotate(180deg);
}

/* Cuerpo: se alinea con el título, no con el número, y respira. */
.lesson__body {
  display: grid;
  gap: 1.5rem;
  padding: 0.25rem 1.5rem 1.75rem;
}

@media (min-width: 640px) {
  .lesson__body {
    padding: 0.5rem 2rem 2rem 4.75rem;
  }
}

.lesson__body p {
  margin: 0;
  font-size: 0.95rem;
  line-height: 1.7;
  color: var(--navy);
  max-width: 42em;
}

.lesson__points {
  display: grid;
  gap: 0.7rem;
  margin: 0;
  padding: 1.25rem 1.35rem;
  border-radius: var(--radius);
  background: var(--surface);
  list-style: none;
  font-size: 0.9rem;
  line-height: 1.55;
}

.lesson__points li {
  display: grid;
  grid-template-columns: 15px 1fr;
  gap: 0.7rem;
  align-items: start;
}

.lesson__points svg {
  margin-top: 0.3rem;
  color: var(--cyan-deep);
}

/* El capítulo del diccionario de maniobras: subtítulos y listas de términos.
   Tailwind quita viñetas y tamaños de título en su reseteo, así que sin esto
   el bonus saldría como un bloque de texto plano. */
.lesson__h3 {
  margin: 0.5rem 0 -0.75rem;
  font-family: "Vitesse", Georgia, "Times New Roman", serif;
  font-weight: 700;
  font-size: 1.15rem;
  line-height: 1.3;
  color: var(--navy);
}

.lesson__list {
  display: grid;
  gap: 0.65rem;
  margin: 0;
  padding: 0 0 0 1.1rem;
  max-width: 42em;
  list-style: disc;
  font-size: 0.95rem;
  line-height: 1.6;
  color: var(--navy);
}

.lesson__list li::marker {
  color: var(--cyan-deep);
}

/* Una lista numerada del markdown («1. Entrada») sale con números; sin esto
   heredaría las viñetas de arriba y se perdería el orden de los pasos. */
ol.lesson__list {
  list-style: decimal;
}

.lesson__list b {
  font-weight: 600;
}

.lesson-table-wrap {
  max-width: 42em;
  overflow-x: auto;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
}

.lesson-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.82rem;
  line-height: 1.4;
  color: var(--navy);
}

.lesson-table th,
.lesson-table td {
  padding: 0.42rem 0.9rem;
  text-align: left;
  vertical-align: top;
}

.lesson-table thead th {
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--cyan-deep);
  border-bottom: 1px solid var(--line-strong);
  white-space: nowrap;
}

.lesson-table tbody th {
  font-weight: 600;
  white-space: nowrap;
}

.lesson-table tbody td:nth-child(2) {
  color: var(--muted);
  white-space: nowrap;
}

.lesson-table tbody tr + tr th,
.lesson-table tbody tr + tr td {
  border-top: 1px solid var(--line);
}

@media (max-width: 639px) {
  .lesson-table {
    min-width: 28rem;
  }
}

.lesson__actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.85rem;
  padding-top: 0.25rem;
}

.lesson__actions .rate-btn {
  min-width: 15rem;
}

.lesson[data-done="true"] .lesson__actions .rate-btn {
  background: var(--surface);
  border: 1px solid var(--line-strong);
  color: var(--navy) !important;
}

.lesson[data-done="true"] .lesson__actions .rate-btn:hover {
  background: var(--surface-strong);
}

/* Hueco para el vídeo o la infografía que se grabará más adelante. */
.media-slot {
  display: grid;
  place-items: center;
  aspect-ratio: 16 / 9;
  padding: 1.5rem;
  border: 1px dashed var(--line-strong);
  border-radius: var(--radius);
  background: var(--surface);
  text-align: center;
}

.media-slot p {
  margin: 0;
  font-size: 0.85rem;
  color: var(--muted);
}

.media-slot p:first-child {
  margin-bottom: 0.35rem;
  font-family: "Vitesse", Georgia, "Times New Roman", serif;
  font-weight: 700;
  font-size: 1.05rem;
  color: var(--navy);
}

/* Pestañas: el curso y las preguntas frecuentes son dos vistas del mismo
   contenido, no un anexo al final de la página. Pestañas tipo tarjeta
   apoyadas sobre un filete que cruza todo el ancho. */
.course-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 0.25rem;
  margin-bottom: 2rem;
  border-bottom: 1px solid var(--line);
}

.course-tabs button {
  appearance: none;
  min-height: 48px;
  margin-bottom: -1px;
  padding: 0 1.2rem;
  border: 1px solid transparent;
  border-bottom: 2px solid transparent;
  border-radius: 10px 10px 0 0;
  background: transparent;
  color: var(--muted);
  font: inherit;
  font-size: 0.9rem;
  font-weight: 600;
  cursor: pointer;
  transition: background-color 0.15s ease, color 0.15s ease, border-color 0.15s ease;
}

.course-tabs button:hover:not([aria-selected="true"]) {
  background: var(--surface);
  color: var(--navy);
}

.course-tabs button[aria-selected="true"] {
  border-color: var(--line);
  border-bottom-color: var(--cyan);
  background: var(--surface);
  color: var(--navy);
}

.course-panel[hidden] {
  display: none;
}

.course-faq h2 {
  margin-bottom: 1.5rem;
}

.faq-list {
  display: grid;
  gap: 1rem;
}

@media (min-width: 900px) {
  .faq-list {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

.faq-item {
  padding: 1.5rem;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: var(--white);
  box-shadow: var(--shadow-soft);
}

.faq-item h3 {
  font-family: "Vitesse", Georgia, "Times New Roman", serif;
  font-weight: 700;
  font-size: 1.1rem;
  line-height: 1.3;
  letter-spacing: -0.02em;
}

.faq-item p {
  margin: 0.6rem 0 0;
  font-size: 0.92rem;
  line-height: 1.65;
  color: var(--muted);
}

.course-next {
  margin-top: 4rem;
}

/* ---------- 8. Carrusel y galería ---------- */
.photo-carousel {
  --visible: 1;
  --gap: 0.75rem;
  width: 100%;
  box-sizing: border-box;
}

.photo-carousel-shell {
  position: relative;
  overflow: hidden;
}

.photo-carousel-track {
  display: flex;
  gap: var(--gap);
  transition: transform 0.55s cubic-bezier(0.22, 1, 0.36, 1);
  will-change: transform;
}

.photo-carousel-track.is-jumping {
  transition: none !important;
}

.photo-carousel-slide {
  flex: 0 0 calc((100% - (var(--visible) - 1) * var(--gap)) / var(--visible));
  aspect-ratio: 1 / 1;
  overflow: hidden;
  margin: 0;
}

.photo-carousel-slide img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 0;
}

.photo-carousel-nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  margin-top: 1.25rem;
  padding-inline: 1.25rem;
}

.photo-carousel-btn {
  display: inline-flex;
  height: 2.75rem;
  width: 2.75rem;
  flex-shrink: 0;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius);
  border: 1px solid var(--line-strong);
  background: var(--white);
  color: var(--navy);
  cursor: pointer;
}

.photo-carousel-btn:hover,
.photo-carousel-btn:focus-visible {
  border-color: var(--cyan);
  background: var(--cyan);
  color: var(--ink);
}

.photo-carousel-btn:disabled {
  cursor: default;
  opacity: 0.35;
}

.photo-carousel-btn svg {
  width: 1.1rem;
  height: 1.1rem;
}

.photo-carousel-dots {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.25rem;
  /* Sin esto la fila de puntos reclama su ancho de una sola línea y empuja la
     flecha siguiente fuera de la pantalla: en windsurf, con dieciséis fotos,
     ensanchaba la página entera. */
  flex: 1 1 auto;
  min-width: 0;
}

/* El punto visible es pequeño, pero el área pulsable llega a 44 px. */
.photo-carousel-dot {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: 2.75rem;
  width: 1.5rem;
  border: 0;
  background: none;
  cursor: pointer;
  padding: 0;
}

.photo-carousel-dot::before {
  content: "";
  display: block;
  height: 0.55rem;
  width: 0.55rem;
  border-radius: 999px;
  background: var(--line-strong);
  transition: width 0.2s ease, background-color 0.2s ease;
}

.photo-carousel-dot[aria-current="true"]::before {
  width: 1.35rem;
  background: var(--cyan-deep);
}

.photo-carousel-dot:hover::before,
.photo-carousel-dot:focus-visible::before {
  background: var(--navy);
}

.photo-gallery {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.75rem;
}

.photo-gallery figure {
  aspect-ratio: 1 / 1;
  overflow: hidden;
  margin: 0;
}

.photo-gallery img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 0;
  transition: transform 0.4s ease;
}

.photo-gallery figure:hover img {
  transform: scale(1.03);
}

@media (min-width: 768px) {
  .photo-gallery {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 1rem;
  }
}

@media (min-width: 1024px) {
  .photo-gallery {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }
}

/* Por debajo de 480 px los 9 puntos no caben junto a las dos flechas:
   se compacta el área pulsable sin bajar de los 44 px de alto. */
@media (max-width: 479px) {
  .photo-carousel-nav {
    gap: 0.5rem;
    padding-inline: 0.75rem;
  }

  .photo-carousel-dots {
    flex-wrap: nowrap;
    gap: 0;
  }

  .photo-carousel-dot {
    width: 1.15rem;
  }
}

@media (min-width: 640px) {
  .photo-carousel {
    --visible: 2;
  }

  .photo-carousel-nav {
    padding-inline: 1.5rem;
  }
}

@media (min-width: 1024px) {
  .photo-carousel {
    --visible: 3;
    --gap: 1rem;
  }

  .photo-carousel-nav {
    padding-inline: 2rem;
  }
}

@media (min-width: 1280px) {
  .photo-carousel {
    --visible: 4;
  }
}

/* ---------- 9. Banner de cookies ---------- */
.cookie-banner {
  position: fixed;
  z-index: 90;
  left: 0.75rem;
  right: auto;
  bottom: 0.75rem;
  max-width: min(20rem, calc(100vw - 1.5rem));
}

.cookie-banner[hidden] {
  display: none;
}

.cookie-card {
  display: grid;
  gap: 0.85rem;
  padding: 0.85rem 1rem;
  border-radius: var(--radius);
  border: 1px solid var(--line-strong);
  background: var(--white);
  box-shadow: 0 16px 36px -20px rgb(8 71 113 / 0.45);
}

.cookie-title {
  font-size: 0.85rem;
  font-weight: 700;
}

.cookie-text {
  margin-top: 0.35rem;
  font-size: 0.75rem;
  line-height: 1.45;
  color: var(--muted);
}

.cookie-text a {
  color: var(--navy);
  text-decoration: underline;
  text-underline-offset: 0.2em;
}

.cookie-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.cookie-actions .btn-ghost,
.cookie-actions .btn-navy {
  flex: 1 1 auto;
  justify-content: center;
  white-space: nowrap;
  min-height: 44px;
  padding-inline: 1rem;
  font-size: 0.78rem;
}

@media (min-width: 640px) {
  .cookie-actions {
    justify-content: flex-end;
  }

  .cookie-actions .btn-ghost,
  .cookie-actions .btn-navy {
    flex: 0 0 auto;
  }
}

/* Botón de icono para reabrir las preferencias desde el pie. */
.cookie-reopen {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2rem;
  height: 2rem;
  background: none;
  border: 0;
  padding: 0;
  font: inherit;
  color: inherit;
  cursor: pointer;
  border-radius: 999px;
}

.cookie-reopen:hover,
.cookie-reopen:focus-visible {
  color: var(--cyan-deep);
  background: var(--surface);
}

.cookie-reopen svg {
  display: block;
}

.help-tip {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 1.4rem;
  height: 1.4rem;
  border: 0;
  border-radius: 999px;
  background: color-mix(in srgb, var(--cyan) 18%, var(--white));
  color: var(--cyan-deep);
  cursor: pointer;
  text-transform: none;
  letter-spacing: 0;
  vertical-align: middle;
}

.help-tip svg {
  display: block;
  width: 0.92rem;
  height: 0.92rem;
}

.help-tip:hover,
.help-tip:focus-visible {
  background: var(--navy);
  color: var(--white);
}

.help-popover {
  width: min(22.5rem, calc(100vw - 2rem));
  padding: 1.15rem 1.2rem 1.2rem;
  border: 0;
  border-radius: 0.85rem;
  background:
    linear-gradient(var(--white), var(--white)) padding-box,
    linear-gradient(180deg, var(--cyan), var(--navy)) border-box;
  border: 1px solid transparent;
  color: var(--navy);
  box-shadow:
    0 18px 44px -20px rgb(8 71 113 / 0.5),
    0 0 0 1px rgb(8 71 113 / 0.06);
}

.help-popover::backdrop {
  background: rgb(5 31 49 / 0.22);
}

.help-popover__kicker {
  margin: 0;
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--cyan-deep);
}

.help-popover__title {
  margin: 0.35rem 0 0;
  font-family: "Vitesse", Georgia, "Times New Roman", serif;
  font-size: 1.2rem;
  font-weight: 700;
  letter-spacing: -0.02em;
}

.help-popover__lead {
  margin: 0.7rem 0 0;
  font-size: 0.9rem;
  line-height: 1.6;
  color: var(--muted);
  text-wrap: pretty;
}

.help-popover__terms {
  display: grid;
  gap: 0.55rem;
  margin: 1rem 0 0;
  padding: 0;
  list-style: none;
}

.help-popover__terms li {
  display: grid;
  gap: 0.15rem;
  padding: 0.7rem 0.8rem;
  border-radius: 0.55rem;
  background: color-mix(in srgb, var(--cyan) 9%, var(--white));
}

.help-popover__terms strong {
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--navy);
}

.help-popover__terms span {
  font-size: 0.84rem;
  line-height: 1.45;
  color: var(--muted);
}

@supports (anchor-name: --help-dir) {
  .help-tip {
    anchor-name: --help-dir;
  }

  .help-popover {
    margin: 0;
    position: absolute;
    position-anchor: --help-dir;
    top: calc(anchor(bottom) + 0.6rem);
    left: anchor(center);
    translate: -72% 0;
  }
}

/* ---------- 10. Preferencias de movimiento ---------- */
@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    animation-duration: 0.001ms !important;
    transition-duration: 0.001ms !important;
  }

  .photo-carousel-track {
    transition: none !important;
  }
}

/* Carrusel de reseñas de Google (js/resenas.js). Bloque deliberadamente
   ligero: sin cajas ni sombras, solo el texto y un filete de separación. */
.review-head {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 0.5rem 1rem;
  padding-top: 3.5rem;
  border-top: 1px solid var(--line);
}

.review-head__title {
  margin: 0;
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--cyan-deep);
}

.review-summary {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  margin: 0;
  font-size: 0.875rem;
  color: var(--muted);
}

.review-head__link {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  margin-left: auto;
  font-size: 0.85rem;
  font-weight: 600;
}

.review-stars {
  color: #f5a623;
  letter-spacing: 0.06em;
}

.review-carousel {
  --visible: 1;
  --gap: 2rem;
  margin-top: 1.25rem;
}

@media (min-width: 640px) {
  .review-carousel {
    --visible: 2;
  }
}

@media (min-width: 1024px) {
  .review-carousel {
    --visible: 3;
  }
}

.review-slide {
  flex: 0 0 calc((100% - (var(--visible) - 1) * var(--gap)) / var(--visible));
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

.review-slide__rating {
  margin: 0;
  font-size: 0.85rem;
  line-height: 1;
}

.review-slide__text {
  margin: 0;
  font-size: 0.875rem;
  line-height: 1.6;
  color: var(--muted);
}

.review-slide__meta {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 0.4rem;
  margin: 0;
  font-size: 0.8rem;
}

.review-slide__author {
  font-weight: 600;
  color: var(--navy);
}

.review-slide__date {
  color: var(--muted);
}

/* Webcams del spot: tarjetas de enlace saliente (las dos webcams envían
   X-Frame-Options: SAMEORIGIN, así que no se pueden incrustar). */
.webcam-grid {
  display: grid;
  gap: 1rem;
  grid-template-columns: 1fr;
}

@media (min-width: 640px) {
  .webcam-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

.webcam-card {
  display: grid;
  align-content: start;
  gap: 0.5rem;
  padding: 1.5rem;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: var(--white);
  box-shadow: var(--shadow-soft);
  color: inherit;
  text-decoration: none;
  transition: border-color 0.2s ease, box-shadow 0.2s ease, transform 0.2s ease;
}

.webcam-card:hover,
.webcam-card:focus-visible {
  border-color: var(--line-strong);
  box-shadow: 0 2px 4px rgb(8 71 113 / 0.08), 0 16px 32px -16px rgb(8 71 113 / 0.28);
  transform: translateY(-2px);
}

.webcam-card__tag {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--cyan-deep);
}

.webcam-card__name {
  font-family: Vitesse, Georgia, "Times New Roman", serif;
  font-size: 1.5rem;
  line-height: 1.15;
}

.webcam-card__desc {
  font-size: 0.9rem;
  line-height: 1.6;
  color: var(--muted);
}

.webcam-card__cta {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  margin-top: 0.5rem;
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--navy);
}

.webcam-card:hover .webcam-card__cta,
.webcam-card:focus-visible .webcam-card__cta {
  color: var(--cyan-deep);
}

@media (prefers-reduced-motion: reduce) {
  .webcam-card {
    transition: none;
  }

  .webcam-card:hover,
  .webcam-card:focus-visible {
    transform: none;
  }
}

/* Animaciones didácticas: vídeo en bucle con controles tipo GIF. */
.gif-player {
  position: relative;
  overflow: hidden;
  width: 100%;
  border-radius: var(--radius);
  background: #031724;
  line-height: 0;
}

.gif-player__video {
  display: block;
  width: 100%;
  height: auto;
  object-fit: contain;
}

.gif-player__controls {
  position: static;
  display: flex;
  align-items: center;
  gap: 0.35rem;
  min-height: 38px;
  padding: 0.15rem 0.3rem;
  border: 0;
  border-top: 1px solid rgb(255 255 255 / 14%);
  border-radius: 0;
  background: #031f31;
  box-shadow: none;
}

.gif-player__button {
  display: grid;
  flex: none;
  width: 32px;
  height: 32px;
  padding: 0;
  place-items: center;
  border: 0;
  border-radius: 50%;
  background: transparent;
  color: #fff;
  cursor: pointer;
  touch-action: manipulation;
}

.gif-player__button:hover {
  background: rgb(255 255 255 / 16%);
}

.gif-player__button:focus-visible,
.gif-player__progress:focus-visible {
  outline: 2px solid var(--cyan);
  outline-offset: 2px;
}

.gif-player__button svg {
  width: 18px;
  height: 18px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.gif-player__button .gif-player__play {
  display: none;
  fill: currentColor;
  stroke: none;
}

.gif-player.is-paused .gif-player__pause {
  display: none;
}

.gif-player.is-paused .gif-player__play {
  display: block;
}

.gif-player__progress {
  --progress: 0%;
  flex: 1;
  min-width: 3rem;
  height: 24px;
  margin: 0;
  padding: 0;
  appearance: none;
  -webkit-appearance: none;
  border: 0;
  background: transparent;
  cursor: pointer;
  touch-action: manipulation;
}

.gif-player__progress::-webkit-slider-runnable-track {
  height: 4px;
  border-radius: 999px;
  background: linear-gradient(
    to right,
    #fff 0 var(--progress),
    rgb(255 255 255 / 35%) var(--progress) 100%
  );
}

.gif-player__progress::-webkit-slider-thumb {
  width: 16px;
  height: 16px;
  margin-top: -6px;
  appearance: none;
  -webkit-appearance: none;
  border: 0;
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 1px 5px rgb(0 0 0 / 38%);
}

.gif-player__progress::-moz-range-track {
  height: 4px;
  border-radius: 999px;
  background: rgb(255 255 255 / 35%);
}

.gif-player__progress::-moz-range-progress {
  height: 4px;
  border-radius: 999px;
  background: #fff;
}

.gif-player__progress::-moz-range-thumb {
  width: 16px;
  height: 16px;
  border: 0;
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 1px 5px rgb(0 0 0 / 38%);
}

.gif-lightbox {
  position: fixed;
  inset: 0;
  width: 100%;
  max-width: none;
  height: 100%;
  max-height: none;
  margin: 0;
  padding: 1rem;
  border: 0;
  background: rgb(3 23 36 / 88%);
  overflow: hidden;
}

.gif-lightbox[open] {
  display: grid;
  place-items: center;
}

.gif-lightbox::backdrop {
  background: transparent;
}

.gif-lightbox__panel {
  display: flex;
  width: min(52rem, 100%);
  max-height: 100%;
  flex-direction: column;
  align-items: flex-end;
}

.gif-lightbox__close {
  display: grid;
  width: 42px;
  height: 42px;
  margin-bottom: 0.35rem;
  padding: 0;
  place-items: center;
  border: 1px solid rgb(255 255 255 / 35%);
  border-radius: 50%;
  background: rgb(3 23 36 / 70%);
  color: #fff;
  cursor: pointer;
}

.gif-lightbox__close:hover,
.gif-lightbox__close:focus-visible {
  background: #fff;
  color: var(--navy);
}

.gif-lightbox__frame {
  width: 100%;
  min-height: 0;
}

.gif-player--expanded {
  width: min(100%, calc(100vh - 6.5rem));
  margin-inline: auto;
}

.gif-player--expanded .gif-player__video {
  max-height: calc(100vh - 8.875rem);
}

.has-gif-lightbox {
  overflow: hidden;
}

@media (max-width: 480px) {
  .gif-player__controls {
    gap: 0.25rem;
    padding-inline: 0.2rem;
  }

  .gif-lightbox {
    padding: 0.75rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  .gif-player__button {
    transition: none;
  }
}

@media print {
  header,
  footer,
  .cookie-banner,
  .photo-carousel-nav,
  .video-lightbox,
  .image-lightbox,
  .gif-lightbox {
    display: none !important;
  }
}
