/**
 * Cinematic full-bleed hero carousel — hero section only.
 * Does not restyle the rest of the website.
 *
 * Layout: fixed header; hero starts immediately below it.
 * --parnadi-header-height is measured dynamically by header-offset.js
 */

:root {
  --parnadi-header-height: 75px;
}

/* Reserve exact header space so fixed nav never covers the hero */
body.index-page {
  padding-top: var(--parnadi-header-height) !important;
}

body.index-page .header,
body.index-page #header.header {
  position: fixed !important;
  top: 0 !important;
  left: 0 !important;
  right: 0 !important;
  z-index: 10010 !important;
  /* Solid bar — hero sits below (no image hidden under nav, no white gap) */
  background: #ffffff !important;
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
  border-bottom: 1px solid rgba(10, 37, 64, 0.08);
  box-shadow: 0 1px 0 rgba(10, 37, 64, 0.04);
}

body.index-page .header.scrolled,
body.index-page.scrolled .header {
  background: #ffffff !important;
  box-shadow: 0 4px 18px rgba(10, 37, 64, 0.08);
}

#hero.hero-cinematic,
#hero.hero.hero-cinematic {
  position: relative;
  /* Full width of main — do NOT use 100vw (scrollbar overflow shifts page left) */
  width: 100%;
  max-width: 100%;
  margin-left: 0;
  margin-right: 0;
  left: auto;
  right: auto;
  /*
   * Admin banners are 1600×666 (~2.4:1). Match that frame exactly so
   * object-fit:contain fills edge-to-edge with no navy side bars.
   */
  aspect-ratio: 1600 / 666;
  height: auto;
  min-height: 0;
  max-height: none;
  padding: 0 !important;
  margin-top: 0 !important;
  margin-bottom: 0 !important;
  overflow: hidden;
  background: #0a2540;
  isolation: isolate;
  display: block;
  scroll-margin-top: var(--parnadi-header-height);
}

#hero.hero-cinematic .hero-slider,
#hero.hero-cinematic #heroSlider {
  position: absolute !important;
  inset: 0 !important;
  width: 100% !important;
  height: 100% !important;
  min-height: 0 !important;
  max-height: none !important;
  margin: 0 !important;
  overflow: hidden !important;
  background: #06101c !important;
  z-index: 1;
}

#hero.hero-cinematic .slide {
  position: absolute !important;
  inset: 0 !important;
  width: 100% !important;
  height: 100% !important;
  opacity: 0;
  visibility: hidden;
  z-index: 1;
  transition: opacity 1.1s cubic-bezier(0.22, 1, 0.36, 1), visibility 1.1s;
  pointer-events: none;
  /* Admin banners are designed graphics — contain + brand letterbox */
  background-color: #0a2540 !important;
  background-size: contain !important;
  background-position: center center !important;
  background-repeat: no-repeat !important;
  transform: none !important;
}

#hero.hero-cinematic .slide.active {
  opacity: 1 !important;
  visibility: visible !important;
  z-index: 2;
  pointer-events: auto;
}

#hero.hero-cinematic .slide-media,
#hero.hero-cinematic .slide-img {
  position: absolute !important;
  inset: 0 !important;
  width: 100% !important;
  height: 100% !important;
  max-width: none !important;
  object-fit: contain !important;
  object-position: center center !important;
  display: block !important;
  opacity: 1 !important;
  visibility: visible !important;
  z-index: 1 !important;
  will-change: transform;
  transform: none;
  transition: opacity 0.8s ease;
  pointer-events: none;
  background: transparent;
}

#hero.hero-cinematic .slide.active .slide-img,
#hero.hero-cinematic .slide.active .slide-media {
  transform: none;
  opacity: 1 !important;
  visibility: visible !important;
}

/* Designed banners already include text — keep veil/overlay off so images stay visible */
#hero.hero-cinematic .slide-overlay,
#hero.hero-cinematic .hero-veil {
  position: absolute;
  inset: 0;
  z-index: 3;
  pointer-events: none;
  background: none !important;
  opacity: 0 !important;
}

/* HTML copy sits on top of designed banners and fights the artwork — hide it */
#hero.hero-cinematic .hero-content-layer {
  position: absolute;
  inset: 0;
  z-index: 5;
  display: none !important;
  align-items: center;
  pointer-events: none;
  padding: clamp(5.5rem, 12vh, 7.5rem) clamp(1.25rem, 6vw, 5.5rem) 5rem;
}

#hero.hero-cinematic .hero-copy {
  max-width: 650px;
  width: 100%;
  color: #fff;
  pointer-events: auto;
}

#hero.hero-cinematic .hero-eyebrow {
  margin: 0 0 0.65rem;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.78);
}

#hero.hero-cinematic .hero-tagline {
  margin: 0 0 0.85rem;
  font-size: clamp(0.85rem, 1.4vw, 1rem);
  font-weight: 500;
  letter-spacing: 0.04em;
  color: rgba(186, 230, 253, 0.95);
}

#hero.hero-cinematic .hero-headline {
  margin: 0 0 0.9rem;
  font-family: var(--font-primary, 'Sora', sans-serif);
  font-size: clamp(2rem, 4.6vw, 3.6rem);
  font-weight: 800;
  line-height: 1.08;
  letter-spacing: -0.02em;
  color: #fff;
  text-wrap: balance;
}

#hero.hero-cinematic .hero-desc {
  margin: 0 0 1.4rem;
  max-width: 34rem;
  font-size: clamp(0.92rem, 1.35vw, 1.08rem);
  line-height: 1.55;
  color: rgba(226, 232, 240, 0.9);
}

#hero.hero-cinematic .hero-cta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-bottom: 1.5rem;
}

#hero.hero-cinematic .hero-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  min-height: 48px;
  padding: 0.75rem 1.35rem;
  border-radius: 999px;
  font-size: 0.9rem;
  font-weight: 650;
  text-decoration: none;
  position: relative;
  overflow: hidden;
  transition: transform 0.3s ease, box-shadow 0.3s ease, background 0.3s ease, border-color 0.3s ease;
}

#hero.hero-cinematic .hero-btn-primary {
  color: #fff;
  border: 0;
  background: linear-gradient(135deg, #0056b3, #00b4d8);
  box-shadow: 0 14px 34px rgba(0, 86, 179, 0.35);
}

#hero.hero-cinematic .hero-btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 18px 40px rgba(0, 180, 216, 0.4);
  background: linear-gradient(135deg, #00b4d8, #0056b3);
  color: #fff;
}

#hero.hero-cinematic .hero-btn-secondary {
  color: #fff;
  border: 1px solid rgba(255, 255, 255, 0.35);
  background: rgba(255, 255, 255, 0.08);
  backdrop-filter: blur(10px);
}

#hero.hero-cinematic .hero-btn-secondary:hover {
  transform: translateY(-2px);
  border-color: rgba(255, 255, 255, 0.7);
  background: rgba(255, 255, 255, 0.16);
  color: #fff;
}

#hero.hero-cinematic .hero-btn .hero-ripple {
  position: absolute;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.45);
  transform: scale(0);
  animation: heroRipple 0.55s ease-out forwards;
  pointer-events: none;
}

@keyframes heroRipple {
  to { transform: scale(18); opacity: 0; }
}

#hero.hero-cinematic .hero-stats {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem 1.5rem;
}

#hero.hero-cinematic .hero-stat {
  min-width: 88px;
}

#hero.hero-cinematic .hero-stat strong {
  display: block;
  font-size: 1.15rem;
  font-weight: 750;
  color: #fff;
  letter-spacing: -0.01em;
}

#hero.hero-cinematic .hero-stat span {
  display: block;
  margin-top: 0.15rem;
  font-size: 0.72rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: rgba(226, 232, 240, 0.7);
}

#hero.hero-cinematic .hero-ui,
#hero.hero-cinematic .hero-ui.premium-controls,
#hero.hero-cinematic .premium-controls {
  position: absolute;
  inset: 0;
  z-index: 6;
  pointer-events: none;
  /* main.css .premium-controls uses solid #0a2540 — that covered every slide */
  background: transparent !important;
  background-color: transparent !important;
  padding: 0 !important;
}

#hero.hero-cinematic .hero-ui .navigation-arrows {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 clamp(0.75rem, 2vw, 1.5rem);
  margin: 0;
  transform: none;
  pointer-events: none;
}

#hero.hero-cinematic .hero-ui .arrow {
  pointer-events: auto;
  width: 48px;
  height: 48px;
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, 0.28);
  background: rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(12px);
  color: #fff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: transform 0.25s ease, background 0.25s ease, border-color 0.25s ease;
}

#hero.hero-cinematic .hero-ui .arrow:hover {
  transform: scale(1.06);
  background: rgba(255, 255, 255, 0.2);
  border-color: rgba(255, 255, 255, 0.55);
}

#hero.hero-cinematic .hero-ui .slide-indicators {
  position: absolute;
  left: 50%;
  bottom: 1.6rem;
  transform: translateX(-50%);
  display: flex;
  gap: 0.55rem;
  pointer-events: auto;
  margin: 0;
}

#hero.hero-cinematic .hero-ui .indicator {
  width: 10px;
  height: 10px;
  border-radius: 999px;
  border: 0;
  padding: 0;
  background: rgba(255, 255, 255, 0.35);
  transition: width 0.3s ease, background 0.3s ease;
}

#hero.hero-cinematic .hero-ui .indicator.active {
  width: 28px;
  background: #ff6b35;
}

#hero.hero-cinematic .slider-progress {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 3px;
  background: rgba(255, 255, 255, 0.12);
  overflow: hidden;
  pointer-events: none;
}

#hero.hero-cinematic .slider-progress .progress-bar {
  height: 100%;
  width: 0;
  background: linear-gradient(90deg, #0056b3, #00b4d8, #ff6b35);
  animation: heroProgress 6s linear infinite;
}

@keyframes heroProgress {
  from { width: 0; }
  to { width: 100%; }
}

#hero.hero-cinematic .scroll-indicator {
  position: absolute;
  left: 50%;
  bottom: 2.85rem;
  transform: translateX(-50%);
  display: flex !important;
  flex-direction: column;
  align-items: center;
  gap: 0.35rem;
  color: rgba(255, 255, 255, 0.75);
  pointer-events: auto;
  cursor: pointer;
  text-decoration: none;
  animation: heroScrollBounce 1.8s ease-in-out infinite;
}

#hero.hero-cinematic .scroll-indicator .mouse {
  width: 22px;
  height: 34px;
  border: 2px solid rgba(255, 255, 255, 0.55);
  border-radius: 14px;
  position: relative;
}

#hero.hero-cinematic .scroll-indicator .wheel {
  width: 3px;
  height: 7px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.85);
  position: absolute;
  top: 6px;
  left: 50%;
  transform: translateX(-50%);
  animation: heroWheel 1.4s ease-in-out infinite;
}

@keyframes heroWheel {
  0% { opacity: 1; transform: translateX(-50%) translateY(0); }
  100% { opacity: 0; transform: translateX(-50%) translateY(10px); }
}

@keyframes heroScrollBounce {
  0%, 100% { transform: translateX(-50%) translateY(0); }
  50% { transform: translateX(-50%) translateY(6px); }
}

@media (max-width: 991.98px) {
  #hero.hero-cinematic .hero-content-layer {
    justify-content: center;
    text-align: center;
    padding: 5.5rem 1.25rem 4.5rem;
  }

  #hero.hero-cinematic .hero-copy {
    margin: 0 auto;
  }

  #hero.hero-cinematic .hero-desc {
    margin-left: auto;
    margin-right: auto;
  }

  #hero.hero-cinematic .hero-cta,
  #hero.hero-cinematic .hero-stats {
    justify-content: center;
  }

  #hero.hero-cinematic .hero-ui .arrow {
    width: 40px;
    height: 40px;
  }
}

@media (max-width: 575.98px) {
  #hero.hero-cinematic .hero-stats {
    gap: 0.75rem 1rem;
  }

  #hero.hero-cinematic .scroll-indicator {
    bottom: 2.4rem;
  }

  #hero.hero-cinematic .hero-ui .slide-indicators {
    bottom: 1.15rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  #hero.hero-cinematic .slide,
  #hero.hero-cinematic .slide-img,
  #hero.hero-cinematic .scroll-indicator,
  #hero.hero-cinematic .scroll-indicator .wheel,
  #hero.hero-cinematic .slider-progress .progress-bar {
    animation: none !important;
    transition: none !important;
  }
}
