/* =====================================================================
   effects.css — hero image carousel only (small screens, max-width 700px)
   Load AFTER style.css on index.html. Pairs with effects.js.
   ===================================================================== */

/* How dark the photos are. 0 = no dimming, 1 = black. Try 0.5 – 0.8. */
:root {
  --hc-dim: 0.62;
}

/* hidden on desktop, where the V and I shapes show instead */
.hero-carousel {
  display: none;
}

@media (max-width: 700px) {
  .hero {
    touch-action: pan-y; /* vertical scroll still works while swiping */
  }

  .hero-carousel {
    display: block;
    position: absolute;
    inset: 0;
    z-index: 0;
    overflow: hidden;
  }

  /* dimming layer over the photos */
  .hero-carousel::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(
      180deg,
      rgba(5, 34, 48, var(--hc-dim)) 0%,
      rgba(3, 12, 46, calc(var(--hc-dim) + 0.15)) 100%
    );
    pointer-events: none;
  }

  .hc-slide {
    position: absolute;
    inset: 0;
    opacity: 0;
    transition: opacity 1.1s ease;
  }
  .hc-slide.is-active {
    opacity: 1;
  }
  .hc-slide img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
  }

  /* dots */
  .hc-dots {
    position: absolute;
    left: 0;
    right: 0;
    bottom: 4.25rem;
    z-index: 2;
    display: flex;
    justify-content: center;
    gap: 0.6rem;
  }
  .hc-dots button {
    width: 0.55rem;
    height: 0.55rem;
    padding: 0;
    border: 0;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.4);
    cursor: pointer;
    transition:
      width 0.3s ease,
      background-color 0.3s ease;
  }
  .hc-dots button[aria-current="true"] {
    width: 1.6rem;
    background: var(--accent);
  }

  /* soft shadow keeps the headline crisp over busy photos */
  .hero h1 {
    text-shadow: 0 2px 18px rgba(0, 0, 0, 0.45);
  }

  /* let swipes and dot taps reach the carousel; keep the button clickable */
  .hero-copy {
    pointer-events: none;
  }
  .hero-copy .btn {
    pointer-events: auto;
  }
}

@media (prefers-reduced-motion: reduce) {
  .hc-slide,
  .hc-dots button {
    transition: none;
  }
}
