/* La pantalla de carga se pinta desde loader.css en la cabecera. */
.carousel-stage {
  overflow: hidden;
  isolation: isolate;
  position: relative;
  touch-action: pan-y pinch-zoom;
}
.hero .carousel-stage { position: absolute; inset: 0; }
.history-carousel .carousel-stage { aspect-ratio: 3 / 2; }
.history-carousel .carousel-stage > .slide { position: absolute; inset: 0; margin: 0; }
.hero .cover-rest .scene { object-position: 55% center; }
.hero:has(.cover-rest:not([hidden])) > .dots { color: var(--deep); }
.cover-rest .slide-text { width: 48%; }
.cover-rest .slide-text h2 { font-size: clamp(3.4rem, 6.4vw, 7rem); }
.quote p { font-size: clamp(2.4rem, 3.63vw, 4.2rem); }
.amazon-repeat { position: relative; }
.amazon-repeat::after {
  content: '✦';
  position: absolute;
  right: 0;
  top: 50%;
  transform: translate(50%, -50%);
  font-size: .8em;
}
.amazon-repeat img { width: 4.9rem; height: auto; margin-top: .25em; }
.shop-carousel button[data-shop] {
  width: clamp(38px, 3.35vw, 54px);
  height: clamp(38px, 3.35vw, 54px);
  padding: .62rem;
  border: 1px solid var(--border);
  border-radius: 50%;
  display: grid;
  place-items: center;
  flex: none;
  background: white;
  color: var(--ink);
}
.shop-carousel button[data-shop]:hover { background: var(--pale); border-color:var(--blue); }
.shop-carousel button[data-shop] svg { width: 100%; height: 100%; }
.shop-carousel button[data-shop="-1"] svg { transform: rotate(180deg); }

.zone-photo {
  position: relative;
  isolation: isolate;
  align-self: center;
  margin: 0;
  width: 100%;
  aspect-ratio: 616/455;
  overflow: hidden;
  background: var(--pale);
}
.zone-photo img { width: 100%; height: 100%; object-fit: cover; }
.zone-photo figcaption {
  position: absolute;
  inset: auto 0 0;
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: .7rem;
  padding: 2.1rem 1rem .75rem;
  color: white;
  font-size: .84rem;
  background: linear-gradient(transparent, #072e46ba);
}
.zone-photo figcaption a { text-decoration: underline; font-size: .75rem; }
.zone-list details { border-left: 3px solid transparent; }
.zone-list details summary { padding-inline: .75rem; }
.zone-list details p { padding-left: 3.6rem; }
.zone-list details[open] { background: var(--pale); border-left-color: var(--blue); }
.zone-list details[open] summary { font-weight: 600; }
.zone-list details[open] summary::after {
  content: '';
  width: .53rem;
  height: .53rem;
  margin-left: auto;
  margin-right: .4rem;
  border-radius: 50%;
  background: var(--blue);
}
.geo-map path[id] { transition: fill 320ms ease; }

@media (prefers-reduced-motion: no-preference) {
  .movimiento .scroll-piece {
    opacity: 0;
    translate: 0 38px;
  }
  .movimiento .reveal-media { translate: 0 52px; }
  .movimiento .scroll-piece.visible,
  .movimiento .scroll-piece:focus-within {
    opacity: 1;
    translate: 0 0;
    transition: translate 760ms cubic-bezier(.16, .72, .18, 1), opacity 620ms ease;
    transition-delay: var(--ritmo, 0ms);
  }
  .movimiento .country-info .eyebrow { --ritmo: 30ms; }
  .movimiento .country-info h3 { --ritmo: 95ms; }
  .movimiento .country-info label, .movimiento #country { --ritmo: 155ms; }
  .movimiento .country-result { --ritmo: 195ms; }
  .movimiento .country-info > .btn { --ritmo: 235ms; }
  .pagina-lista .hero .slide:first-child .slide-text,
  .pagina-lista .about-hero .photo-copy,
  .pagina-lista .cat-hero .photo-copy { animation: titular-entrada 820ms cubic-bezier(.16,.7,.2,1) both; }
  @keyframes titular-entrada {
    from { opacity: 0; translate: 0 25px; }
    to { opacity: 1; translate: 0 0; }
  }
  .why.story-running {
    padding: 0;
    position: relative;
    min-height: 195vh;
    min-height: 195svh;
  }
  .story-running .why-grid {
    position: sticky;
    top: 15vh;
    top: 15svh;
    padding-block: clamp(20px, 5vh, 64px);
  }
  .story-running ol { gap: clamp(22px, 6vh, 80px); }
  .story-running ol::before {
    transform: scaleY(var(--linea,0));
    transform-origin: center top;
  }
  .story-running li {
    opacity: 0;
    translate: 0 34px;
    transition: opacity 520ms ease, translate 660ms cubic-bezier(.17,.75,.16,1);
  }
  .story-running li.shown { opacity: 1; translate: 0 0; }
  @supports (animation-timeline: view()) {
    .habits, .philosophy { view-timeline-name: --escena; overflow: clip; }
    .habits .scene, .philosophy .scene {
      animation: acompanar-foto linear both;
      animation-timeline: --escena;
      animation-range: entry 0% exit 100%;
    }
    @keyframes acompanar-foto {
      from { transform: scale(1.055) translateY(-2%); }
      to { transform: scale(1.055) translateY(2%); }
    }
  }
}
@media (max-width:700px) {
  .cover-rest .slide-text { width: 89%; }
  .hero .cover-rest .scene { height: 64%; object-position: 65% center; }
  .hero .cover-rest .slide-text h2 { font-size: clamp(2.4rem, 10.6vw, 3.5rem); }
  .quote { padding-block: 2.9rem; }
  .quote p { font-size: clamp(1.72rem, 7vw, 2.35rem); }
  .amazon-repeat img { width: 3.55rem; }
  .zone-photo { aspect-ratio: 1.66; }
  .zone-list details p { padding-left: 2.45rem; }
  .shop-carousel button[data-shop] { padding: .55rem; }
}
@media (max-height:560px) and (prefers-reduced-motion:no-preference) {
  .story-running .why-grid { top: 3vh; padding-block: 1rem; gap: 1rem; }
  .story-running .why-grid ol { gap: 2.5vh; }
  .story-running .why-grid .icon { width: min(10vh, 4.5rem); }
  .story-running .why-grid ol::before { left: min(5vh, 2.25rem); }
}
@media (prefers-reduced-motion:reduce) {
  .page-loader, .preparando .page-loader { visibility: hidden; opacity: 0; }
}
@media print {
  .page-loader { display:none; }
  .scroll-piece,.story-running li { opacity:1!important; translate:none!important; }
  .why.story-running { min-height:0; }
  .story-running .why-grid { position:static; }
}

