/* ==========================================================================
   INICIO (index) - Cine House Costa Rica
   Lo compartido (reveal, hero, botones, tarjetas, cifras, teaser de locations,
   marquee) vive en site.css.
   ========================================================================== */

/* ---------- Hero slider ---------- */
.hm-hero { position: relative; overflow: hidden; background: #09090b; height: calc(100vh - 8rem); height: calc(100svh - 8rem); min-height: 34rem; }
.hm-slide { position: absolute; inset: 0; }
.hm-slide__img { position: absolute; inset: 0; background-size: cover; background-position: center; animation: ab-kenburns 10s ease-out both; }
.hm-slide__shade {
  position: absolute; inset: 0;
  background: linear-gradient(90deg, rgba(0,0,0,.85), rgba(0,0,0,.4) 55%, rgba(0,0,0,.1)), linear-gradient(to top, #09090b, transparent 38%);
}
.hm-slide__text { position: absolute; left: 0; right: 0; top: 0; bottom: 0; max-width: 80rem; margin: 0 auto; padding: 0 48px; display: flex; flex-direction: column; justify-content: center; }
.hm-slide__text > * { animation: ab-rise .9s cubic-bezier(.2, .7, .2, 1) both; animation-delay: calc(var(--k, 0) * 140ms + 150ms); }
.hm-title { margin: 1.1rem 0 0; max-width: 13ch; font-size: clamp(2.6rem, 7.5vw, 6.4rem); font-weight: 900; line-height: .96; letter-spacing: .03em; text-transform: uppercase; color: #fff; text-shadow: 0 6px 30px rgba(0,0,0,.5); }
.hm-text { margin: 1.4rem 0 0; max-width: 30rem; font-size: 15px; font-weight: 300; line-height: 1.7; color: #d4d4d8; }

.hm-arrow { position: absolute; top: 50%; z-index: 6; width: 46px; height: 46px; margin-top: -23px; display: flex; align-items: center; justify-content: center; border: 1px solid rgba(255,255,255,.25); border-radius: 50%; background: rgba(9,9,11,.55); color: #fff; cursor: pointer; transition: background-color .2s ease, color .2s ease, border-color .2s ease; }
.hm-arrow:hover { background: var(--ab-gold); color: #18181b; border-color: var(--ab-gold); }
.hm-arrow svg { width: 18px; height: 18px; }
.hm-arrow--prev { left: 18px; }
.hm-arrow--next { right: 18px; }

/* Indicadores del slider: centrados; la barra activa se llena en dorado durante los 6 s de la slide */
.hm-dots { position: absolute; left: 50%; bottom: 34px; z-index: 6; display: flex; align-items: center; gap: 12px; transform: translateX(-50%); }
.hm-dot {
  position: relative; width: 38px; height: 4px; padding: 0; border: 0; border-radius: 999px; overflow: hidden; cursor: pointer;
  background: rgba(255, 255, 255, .22);
  transition: width .5s cubic-bezier(.2, .7, .2, 1), background-color .3s ease, box-shadow .4s ease;
}
.hm-dot:hover { background: rgba(255, 255, 255, .45); }
.hm-dot span { position: absolute; inset: 0; border-radius: inherit; background: linear-gradient(90deg, #f59e0b, var(--ab-gold), #fde68a); transform: scaleX(0); transform-origin: left; }
.hm-dot.is-on { width: 78px; background: rgba(251, 191, 36, .28); box-shadow: 0 0 14px rgba(251, 191, 36, .45); }
.hm-dot.is-on span { animation: ab-fill 6s linear forwards; }

/* ---------- Proyectos destacados (marquee de pósters) ---------- */
.hm-marquee { position: relative; overflow: hidden; padding: 6px 0; }
.hm-marquee::before, .hm-marquee::after { content: ""; position: absolute; top: 0; bottom: 0; width: 90px; z-index: 2; pointer-events: none; }
.hm-marquee::before { left: 0; background: linear-gradient(90deg, #09090b, transparent); }
.hm-marquee::after { right: 0; background: linear-gradient(270deg, #09090b, transparent); }
.hm-marquee__track { display: flex; gap: 18px; width: max-content; animation: ab-marquee 70s linear infinite; }
.hm-marquee:hover .hm-marquee__track { animation-play-state: paused; }
.hm-poster { position: relative; flex: none; width: clamp(170px, 18vw, 250px); aspect-ratio: 2 / 3; overflow: hidden; border: 1px solid var(--ab-line); background: #111; }
.hm-poster img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform .8s cubic-bezier(.2, .7, .2, 1); }
.hm-poster:hover img { transform: scale(1.07); }
.hm-poster__title { position: absolute; left: 0; right: 0; bottom: 0; padding: 40px 14px 14px; background: linear-gradient(to top, rgba(0,0,0,.9), transparent); font-size: 11px; font-weight: 800; letter-spacing: .16em; text-transform: uppercase; color: #fff; opacity: 0; transition: opacity .3s ease; }
.hm-poster:hover .hm-poster__title { opacity: 1; }
.hm-poster--text { display: flex; align-items: center; justify-content: center; padding: 16px; text-align: center; font-size: 12px; font-weight: 800; letter-spacing: .18em; text-transform: uppercase; color: #52525b; }

/* ---------- Contacto ---------- */
.hm-contact { position: relative; background-size: cover; background-position: center; }
.hm-contact__card { background: rgba(9, 9, 11, .94); border: 1px solid var(--ab-line); padding: 2.5rem; box-shadow: 0 30px 80px rgba(0,0,0,.55); }

/* ---------- Responsive ---------- */
@media (max-width: 640px) {
  .hm-slide__text { padding: 0 24px; }
  .hm-dots { bottom: 24px; gap: 9px; }
  .hm-dot { width: 26px; }
  .hm-dot.is-on { width: 54px; }
  .hm-arrow { display: none; }
  .hm-contact__card { padding: 1.6rem; }
}

@media (prefers-reduced-motion: reduce) {
  .hm-slide__img, .hm-slide__text > *, .hm-marquee__track, .hm-dot.is-on span { animation: none !important; }
  .hm-dot.is-on span { transform: scaleX(1); }
}
