/* ==========================================================================
   hero.css — Penumbra Rental
   Full-viewport hero section with ken-burns and parallax
   ========================================================================== */

/* --------------------------------------------------------------------------
   Hero base
   -------------------------------------------------------------------------- */
.hero {
  position: relative;
  height: 100vh;
  min-height: 640px;
  max-height: 1200px;
  display: flex;
  align-items: flex-end;
  padding-bottom: 6rem;
  overflow: hidden;
  background: var(--color-bg-deep);
  /* Cancel default section top padding/border */
  padding-top: 0;
  border-top: none;
}

/* --------------------------------------------------------------------------
   Background image wrapper
   -------------------------------------------------------------------------- */
.hero__bg {
  position: absolute;
  inset: 0;
  z-index: 0;
  overflow: hidden;
}

.hero__img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center center;
  animation: kenBurns 10s ease-in-out infinite alternate;
  will-change: transform;
}

/* --------------------------------------------------------------------------
   Overlay layers
   -------------------------------------------------------------------------- */
/* Dark bottom-to-top gradient for text readability */
.hero__overlay {
  position: absolute;
  inset: 0;
  z-index: 1;
  background: linear-gradient(
    to top,
    rgba(7, 9, 11, 0.95) 0%,
    rgba(7, 9, 11, 0.70) 30%,
    rgba(7, 9, 11, 0.35) 60%,
    rgba(7, 9, 11, 0.15) 100%
  );
}

/* Subtle horizontal vignette */
.hero__overlay-sides {
  position: absolute;
  inset: 0;
  z-index: 1;
  background: linear-gradient(
    to right,
    rgba(7, 9, 11, 0.4) 0%,
    transparent 30%,
    transparent 70%,
    rgba(7, 9, 11, 0.3) 100%
  );
}

/* --------------------------------------------------------------------------
   Content
   -------------------------------------------------------------------------- */
.hero__content {
  position: relative;
  z-index: 2;
  width: 100%;
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 var(--gutter);
}

.hero__eyebrow {
  display: block;
  font-family: var(--font-mono);
  font-size: 0.65rem;
  letter-spacing: 0.2em;
  color: var(--color-gold);
  text-transform: uppercase;
  margin-bottom: var(--space-5);
  opacity: 0;
  transform: translateY(10px);
  animation: heroFadeUp 0.8s 0.2s ease-out forwards;
}

.hero__title {
  font-family: var(--font-heading);
  font-weight: 400;
  font-size: var(--h1-size);
  line-height: 1.05;
  letter-spacing: -0.03em;
  color: var(--color-text);
  max-width: 820px;
  margin-bottom: var(--space-6);
  opacity: 0;
  transform: translateY(16px);
  animation: heroFadeUp 0.9s 0.4s ease-out forwards;
}

.hero__subtitle {
  font-family: var(--font-body);
  font-weight: 300;
  font-size: clamp(1rem, 1.5vw, 1.2rem);
  color: var(--color-text-muted);
  max-width: 600px;
  line-height: var(--lh-relaxed);
  margin-bottom: var(--space-10);
  opacity: 0;
  transform: translateY(16px);
  animation: heroFadeUp 0.9s 0.6s ease-out forwards;
}

/* --------------------------------------------------------------------------
   CTAs
   -------------------------------------------------------------------------- */
.hero__ctas {
  display: flex;
  align-items: center;
  gap: var(--space-4);
  flex-wrap: wrap;
  opacity: 0;
  transform: translateY(16px);
  animation: heroFadeUp 0.9s 0.8s ease-out forwards;
}

/* --------------------------------------------------------------------------
   Scroll indicator
   -------------------------------------------------------------------------- */
.hero__scroll {
  position: absolute;
  bottom: 2rem;
  right: var(--gutter);
  z-index: 2;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-3);
  opacity: 0;
  animation: heroFadeUp 0.8s 1.2s ease-out forwards;
}

.hero__scroll-text {
  font-family: var(--font-mono);
  font-size: 0.5625rem;
  letter-spacing: 0.2em;
  color: var(--color-steel);
  text-transform: uppercase;
  writing-mode: vertical-rl;
}

.hero__scroll-line {
  width: 1px;
  height: 40px;
  background: var(--color-border);
  position: relative;
  overflow: hidden;
}

.hero__scroll-line::after {
  content: '';
  position: absolute;
  top: -100%;
  left: 0;
  width: 100%;
  height: 100%;
  background: var(--color-gold);
  animation: scrollLine 1.8s 1.5s ease-in-out infinite;
}

/* --------------------------------------------------------------------------
   Page hero (sub-pages — shorter)
   -------------------------------------------------------------------------- */
.hero--page {
  height: 55vh;
  min-height: 380px;
  max-height: 600px;
  align-items: center;
  padding-top: 72px; /* nav offset */
  padding-bottom: 0;
}

.hero--page .hero__title {
  font-size: clamp(2rem, 4vw, 3.5rem);
}

/* --------------------------------------------------------------------------
   Responsive
   -------------------------------------------------------------------------- */
@media (max-width: 768px) {
  .hero {
    padding-bottom: 4rem;
    align-items: flex-end;
  }

  .hero__ctas {
    flex-direction: column;
    align-items: flex-start;
  }

  .hero__ctas .btn {
    width: 100%;
    max-width: 320px;
    justify-content: center;
  }

  .hero__scroll {
    display: none;
  }

  .hero--page {
    height: 48vh;
    min-height: 320px;
  }
}

@media (max-width: 576px) {
  .hero {
    min-height: 580px;
  }
}
