body:has(.alfa-archery-hero) { background: #060806; }
/* El contenedor se inyecta con JavaScript dentro del layout Gutenberg: hay que
   sacarlo explícitamente del ancho editorial para que el canvas nunca deje bandas. */
body:has(.alfa-archery-hero) .entry-content.is-layout-constrained > .forjando-archery-scroll-story {
  box-sizing: border-box;
  width: 100vw !important;
  min-width: 100vw;
  max-width: none !important;
  margin-inline: calc(50% - 50vw) !important;
}
.forjando-archery-scroll-story {
  position: relative;
  isolation: isolate;
  z-index: 1;
  background: #060806;
}
.forjando-archery-scroll-story__stage {
  position: sticky;
  z-index: 0;
  top: 0;
  height: 100svh;
  margin-bottom: -100svh;
  overflow: hidden;
  visibility: hidden;
  background: #060806;
}
.forjando-archery-scroll-story.is-ready .forjando-archery-scroll-story__stage { visibility: visible; }
.forjando-archery-scroll-story__canvas { display: block; width: 100%; height: 100%; }
.forjando-archery-scroll-story > .wp-block-cover,
.forjando-archery-scroll-story > .wp-block-group { position: relative; z-index: 1; }
.forjando-archery-scroll-story.is-ready > .alfa-archery-hero,
.forjando-archery-scroll-story.is-ready > .alfa-archery-start { background: transparent !important; }
.forjando-archery-scroll-story.is-ready > .alfa-archery-hero .wp-block-cover__background,
.forjando-archery-scroll-story.is-ready > .alfa-archery-start .wp-block-cover__background { opacity: 0 !important; }
.forjando-archery-scroll-story.is-ready > .alfa-archery-hero .wp-block-cover__image-background,
.forjando-archery-scroll-story.is-ready > .alfa-archery-start .wp-block-cover__image-background,
.forjando-archery-scroll-story.is-ready > .alfa-archery-start .wp-block-image { visibility: hidden; }
.forjando-archery-scroll-story.is-ready .alfa-archery-hero,
.forjando-archery-scroll-story.is-ready .alfa-archery-start { min-height: 100svh !important; }
.forjando-archery-scroll-story.is-ready .alfa-archery-hero h1,
.forjando-archery-scroll-story.is-ready .alfa-archery-start h2,
.forjando-archery-scroll-story.is-ready .alfa-archery-hero p,
.forjando-archery-scroll-story.is-ready .alfa-archery-start p { text-shadow: 0 2px 20px rgba(0, 0, 0, .72); }

/* Tras la secuencia, cada capítulo cubre el anterior y permanece anclado hasta
   que el siguiente toma el relevo. */
@media (min-width: 782px) {
  body:has(.alfa-archery-hero) .entry-content > :is(.alfa-archery-gallery, .alfa-archery-method, .alfa-archery-club, .alfa-archery-coach, .alfa-archery-practical, .alfa-archery-faq) {
    position: sticky;
    top: 0;
    box-sizing: border-box;
    min-height: 100svh !important;
    overflow: hidden;
  }
  body:has(.alfa-archery-hero) .entry-content > .alfa-archery-gallery { z-index: 2; }
  body:has(.alfa-archery-hero) .entry-content > .alfa-archery-method { z-index: 3; }
  body:has(.alfa-archery-hero) .entry-content > .alfa-archery-club { z-index: 4; }
  body:has(.alfa-archery-hero) .entry-content > .alfa-archery-coach { z-index: 5; }
  body:has(.alfa-archery-hero) .entry-content > .alfa-archery-practical { z-index: 6; }
  body:has(.alfa-archery-hero) .entry-content > .alfa-archery-faq { z-index: 7; }
}

/* Entradas de contenido: la escena llega limpia y su información gana presencia
   en una secuencia corta, sin afectar a los controles ni al scroll. */
.forjando-archery-scene .forjando-archery-reveal {
  opacity: 0;
  transform: translate3d(0, 28px, 0);
  transition: opacity .64s cubic-bezier(.2, .7, .2, 1), transform .64s cubic-bezier(.2, .7, .2, 1);
  transition-delay: calc(var(--forjando-archery-index, 0) * 80ms);
}
.forjando-archery-scene.is-visible .forjando-archery-reveal {
  opacity: 1;
  transform: translate3d(0, 0, 0);
}

/* Galería propia: una composición editorial que muestra las ocho imágenes
   elegidas sin competir con el texto de la escena. */
.alfa-archery-gallery {
  position: relative;
  isolation: isolate;
  background: #102738;
}
.alfa-archery-gallery__photos {
  display: flex !important;
  flex-wrap: nowrap !important;
  gap: clamp(7px, .75vw, 14px) !important;
  width: min(100%, 1280px) !important;
  height: clamp(280px, 43svh, 500px);
  margin: clamp(26px, 4vw, 52px) auto 0 !important;
  padding: 0 0 12px !important;
  overflow-x: auto;
  overflow-y: hidden;
  scroll-snap-type: x mandatory;
  scroll-behavior: smooth;
  scrollbar-color: #71f3c2 rgba(246, 245, 240, .14);
  scrollbar-width: thin;
  cursor: grab;
  touch-action: pan-x;
  overscroll-behavior-inline: contain;
}
.alfa-archery-gallery__photos.is-dragging { cursor: grabbing; scroll-snap-type: none; }
.alfa-archery-gallery__photos .wp-block-image {
  flex: 0 0 clamp(220px, 25vw, 360px) !important;
  min-width: 0;
  min-height: 100%;
  width: auto !important;
  margin: 0 !important;
  overflow: hidden;
  border-radius: 10px;
  background: #07161f;
  scroll-snap-align: start;
}
.alfa-archery-gallery__photos .wp-block-image:first-child {
  flex-basis: clamp(300px, 33vw, 500px) !important;
  border-radius: 16px;
}
.alfa-archery-gallery__photos img {
  display: block;
  width: 100%;
  height: 100%;
}
.alfa-archery-gallery__photos img {
  object-fit: cover;
}
.alfa-archery-gallery__controls {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 9px;
  width: min(100%, 1280px);
  margin: 0 auto 10px;
  color: rgba(246, 245, 240, .76);
}
.alfa-archery-gallery__count {
  margin-right: 5px;
  font-size: .7rem;
  font-weight: 800;
  letter-spacing: .11em;
  text-transform: uppercase;
}
.alfa-archery-gallery__arrow {
  display: grid;
  width: 2.8rem;
  height: 2.8rem;
  margin: 0;
  padding: 0;
  place-items: center;
  border: 1px solid rgba(113, 243, 194, .54);
  border-radius: 50%;
  background: rgba(7, 22, 31, .68);
  color: #f6f5f0;
  cursor: pointer;
  font-size: 1.25rem;
  line-height: 1;
  transition: background-color .2s ease, color .2s ease, transform .2s ease, opacity .2s ease;
}
.alfa-archery-gallery__arrow:hover,
.alfa-archery-gallery__arrow:focus-visible {
  background: #71f3c2;
  color: #07161f;
  outline: none;
  transform: translateY(-2px);
}
.alfa-archery-gallery__arrow:disabled {
  cursor: default;
  opacity: .32;
  transform: none;
}

/* Método: tres principios con una lectura editorial y una superficie más rica. */
.alfa-archery-method,
.alfa-archery-practical {
  position: relative;
  isolation: isolate;
  overflow: hidden;
}
.alfa-archery-method::before {
  position: absolute;
  z-index: -1;
  inset: 0;
  content: "";
  background:
    radial-gradient(circle at 82% 14%, rgba(99, 242, 191, .13), transparent 28%),
    linear-gradient(135deg, rgba(8, 23, 31, .98), rgba(5, 11, 13, .99));
}
.alfa-archery-method__grid {
  display: grid !important;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: clamp(12px, 1.5vw, 24px) !important;
  width: min(100%, 1120px);
  margin-inline: auto !important;
}
.alfa-archery-method__grid > .wp-block-column:first-child { display: none; }
.alfa-archery-method__grid > .wp-block-column {
  display: flex;
  min-width: 0;
  min-height: clamp(270px, 25vw, 340px);
  padding: clamp(28px, 3vw, 46px) !important;
  flex-direction: column;
  justify-content: flex-end;
  border: 1px solid rgba(232, 248, 242, .2);
  border-radius: 20px;
  background: linear-gradient(145deg, rgba(17, 38, 42, .82), rgba(6, 14, 16, .9));
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .06), 0 24px 55px rgba(0, 0, 0, .22);
}
.alfa-archery-method__grid > .wp-block-column > :first-child {
  margin-top: 0;
  color: #b7ff14 !important;
  font-size: clamp(2.8rem, 4.2vw, 4.8rem) !important;
  font-variant-numeric: tabular-nums;
  line-height: .9;
}
.alfa-archery-method__grid h3 {
  margin: auto 0 10px !important;
  color: #f8f7f2 !important;
  font-size: clamp(1.6rem, 2.1vw, 2.4rem) !important;
  line-height: .94;
}
.alfa-archery-method__grid p {
  max-width: 25ch;
  margin: 0 !important;
  color: rgba(248, 247, 242, .78) !important;
  font-size: clamp(.95rem, 1.1vw, 1.06rem);
  line-height: 1.55;
}

/* Entrena por ti: el fondo queda libre, pero el contenido se revela como una
   sola composición al ocupar la pantalla. */
.forjando-archery-scene.alfa-archery-club .forjando-archery-reveal {
  transform: translate3d(-36px, 0, 0);
}
.forjando-archery-scene.alfa-archery-club.is-visible .forjando-archery-reveal {
  transform: translate3d(0, 0, 0);
}
.alfa-archery-club .wp-block-cover__inner-container > * {
  position: relative;
  max-width: min(100%, 760px);
}
.alfa-archery-club .wp-block-cover__inner-container > *::before {
  position: absolute;
  z-index: -1;
  inset: -28px -36px;
  content: "";
  border: 1px solid rgba(245, 247, 241, .14);
  border-radius: 22px;
  background: rgba(3, 10, 12, .34);
  box-shadow: 0 28px 60px rgba(0, 0, 0, .28);
  backdrop-filter: blur(5px);
}

/* Referente: el retrato gana aire, volumen y una oscilación muy discreta. */
.alfa-archery-coach__row {
  align-items: center !important;
  gap: clamp(36px, 6vw, 88px) !important;
}
.alfa-archery-coach__image {
  width: min(100%, 27rem) !important;
  margin: 0 auto !important;
  overflow: hidden;
  border: 1px solid rgba(230, 246, 239, .25);
  border-radius: 26px;
  box-shadow: 0 28px 66px rgba(0, 0, 0, .34);
}
.alfa-archery-coach__image img {
  display: block;
  width: 100%;
  aspect-ratio: 4 / 5;
  object-fit: cover;
  object-position: center;
}
.forjando-archery-scene.alfa-archery-coach.is-visible .alfa-archery-coach__image {
  animation: forjando-archery-coach-float 7s ease-in-out .7s infinite;
}
.alfa-archery-coach__facts {
  display: inline-flex;
  width: fit-content;
  align-items: baseline;
  gap: 6px;
  margin-top: clamp(24px, 3vw, 38px) !important;
  padding: 9px 13px;
  border: 1px solid rgba(115, 242, 193, .25);
  border-radius: 999px;
  background: rgba(15, 43, 44, .36);
}
.alfa-archery-coach__facts strong { color: #b7ff14 !important; }

/* Horarios y precios: dos tarjetas claras, escaneables y preparadas para CTA. */
.alfa-archery-practical::before {
  position: absolute;
  z-index: -1;
  inset: 0;
  content: "";
  background:
    radial-gradient(circle at 13% 85%, rgba(255, 121, 27, .16), transparent 32%),
    linear-gradient(150deg, #081920 0%, #071012 100%);
}
.alfa-archery-practical__grid {
  display: grid !important;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: clamp(16px, 2vw, 28px) !important;
  width: min(100%, 1060px);
  margin-inline: auto !important;
}
.alfa-archery-practical__grid > .wp-block-column:first-child { display: none; }
.alfa-archery-practical__grid > .wp-block-column {
  min-width: 0;
  padding: clamp(28px, 3.2vw, 48px) !important;
  border: 1px solid rgba(239, 246, 239, .18);
  border-radius: 20px;
  background: linear-gradient(145deg, rgba(20, 42, 45, .88), rgba(6, 13, 15, .94));
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .05), 0 22px 52px rgba(0, 0, 0, .24);
}
.alfa-archery-practical__grid h3 {
  color: #f8f7f2 !important;
  font-size: clamp(1.65rem, 2.3vw, 2.5rem) !important;
  line-height: .95;
}
.alfa-archery-practical__grid p,
.alfa-archery-practical__grid li { color: rgba(248, 247, 242, .82) !important; }
.alfa-archery-practical__item:first-child {
  color: #71f3c2 !important;
  font-weight: 700;
  letter-spacing: .1em;
  text-transform: uppercase;
}
.alfa-archery-practical__grid ul { padding-left: 1.1em; }
.alfa-archery-practical__grid li::marker { color: #ff791b; }

@keyframes forjando-archery-coach-float {
  0%, 100% { transform: translate3d(0, 0, 0); }
  50% { transform: translate3d(0, -10px, 0); }
}

/* En escritorio el hero reserva una columna real para el texto. Sin esta
   restricción, el layout heredado podía colapsarla al cargar la secuencia. */
@media (min-width: 782px) {
  .forjando-archery-scroll-story > .alfa-archery-hero > .wp-block-cover__inner-container {
    display: flex;
    align-items: center;
  }
  .forjando-archery-scroll-story > .alfa-archery-hero .forjando-migrated-row {
    display: flex;
    width: min(100%, 1240px) !important;
    max-width: 1240px !important;
    margin-inline: auto !important;
    justify-content: flex-end;
  }
  .forjando-archery-scroll-story > .alfa-archery-hero .forjando-migrated-column {
    width: min(44rem, 52vw) !important;
    max-width: min(44rem, 52vw) !important;
    min-width: 0;
    flex: 0 1 min(44rem, 52vw) !important;
  }
  body.page .forjando-archery-scroll-story > .alfa-archery-hero h1 {
    width: 100% !important;
    max-width: 100% !important;
    font-size: clamp(2.8rem, 3.9vw, 4.6rem) !important;
    overflow-wrap: normal;
    word-break: normal;
    hyphens: none;
    text-wrap: balance;
  }
}
@media (max-width: 781px) {
  /* El lienzo sigue animado en móvil. Al acabar, los capítulos siguientes
     suben por encima de su contexto de apilado: así el último fotograma no
     puede quedarse superpuesto sobre galería, método o contenidos finales. */
  .forjando-archery-scroll-story { z-index: 0; }
  body:has(.alfa-archery-hero) .entry-content > :is(.alfa-archery-gallery, .alfa-archery-method, .alfa-archery-club, .alfa-archery-coach, .alfa-archery-practical, .alfa-archery-faq) {
    position: relative;
    z-index: 2;
    isolation: isolate;
  }
  .forjando-archery-scroll-story > .alfa-archery-hero .forjando-migrated-column {
    width: 100% !important;
    max-width: 100% !important;
  }
  .forjando-archery-scroll-story.is-ready .alfa-archery-start { min-height: 85svh !important; }
  body:has(.alfa-archery-hero) .entry-content > :is(.alfa-archery-gallery, .alfa-archery-method, .alfa-archery-club, .alfa-archery-coach, .alfa-archery-practical, .alfa-archery-faq) {
    min-height: 100svh !important;
  }
  .alfa-archery-method__grid,
  .alfa-archery-practical__grid { grid-template-columns: 1fr; }
  .alfa-archery-gallery__photos {
    height: 18rem;
  }
  .alfa-archery-gallery__photos .wp-block-image {
    flex-basis: 74vw !important;
    min-height: 100%;
  }
  .alfa-archery-gallery__photos .wp-block-image:first-child {
    flex-basis: 84vw !important;
    min-height: 100%;
  }
  .alfa-archery-gallery__controls {
    width: 100%;
    margin-bottom: 8px;
    padding-inline: 2px;
  }
  .alfa-archery-gallery__arrow {
    width: 2.55rem;
    height: 2.55rem;
  }
  .alfa-archery-method__grid > .wp-block-column { min-height: 250px; }
  .alfa-archery-club .wp-block-cover__inner-container > *::before { inset: -20px -16px; }
  .alfa-archery-coach__image { width: min(100%, 22rem) !important; }
}
@media (prefers-reduced-motion: reduce) {
  .forjando-archery-scene .forjando-archery-reveal {
    opacity: 1;
    transform: none;
    transition: none;
  }
  .forjando-archery-scene.alfa-archery-coach.is-visible .alfa-archery-coach__image { animation: none; }
}
