/* Forge Night — BMW hero background */
.page-home .home-hero {
  position: relative;
  overflow: hidden;
}

.page-home .hero-visual {
  position: relative;
  min-height: 100%;
}

.page-home .hero-visual .hero-bg {
  position: absolute;
  inset: 0;
  z-index: 0;
  overflow: hidden;
  background: #0a1218;
}

.page-home .hero-visual .hero-bmw-bg {
  position: absolute;
  inset: 0;
  pointer-events: none;
}

.hero-bmw-bg__colors {
  position: absolute;
  inset: -20%;
  background:
    radial-gradient(ellipse 55% 45% at 25% 35%, rgba(13, 148, 136, 0.35), transparent 55%),
    radial-gradient(ellipse 50% 40% at 75% 25%, rgba(28, 105, 212, 0.4), transparent 50%),
    radial-gradient(ellipse 45% 50% at 60% 80%, rgba(180, 120, 60, 0.12), transparent 55%),
    linear-gradient(135deg, #0a1218 0%, #0f1c28 45%, #0a141c 100%);
  animation: bmw-color-drift 20s ease-in-out infinite alternate;
}

.hero-bmw-bg__colors::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(
    105deg,
    transparent 0%,
    rgba(255, 255, 255, 0.03) 30%,
    transparent 55%,
    rgba(13, 148, 136, 0.06) 80%,
    transparent 100%
  );
  animation: bmw-light-sweep 10s ease-in-out infinite;
}

.hero-bmw-bg__slides {
  position: absolute;
  inset: 0;
}

.hero-bmw-bg__slide {
  position: absolute;
  inset: -5%;
  background-size: cover;
  background-position: center 40%;
  opacity: 0;
  transform: scale(1.05);
  animation: bmw-photo-kenburns 24s ease-in-out infinite;
  filter: saturate(0.9) contrast(1.05) brightness(0.75) sepia(0.08);
}

.hero-bmw-bg__slide:nth-child(1) { animation-delay: 0s; }
.hero-bmw-bg__slide:nth-child(2) { animation-delay: 6s; }
.hero-bmw-bg__slide:nth-child(3) { animation-delay: 12s; }
.hero-bmw-bg__slide:nth-child(4) { animation-delay: 18s; }

.hero-bmw-bg__stripes {
  position: absolute;
  right: -5%;
  top: 15%;
  width: 38%;
  height: 70%;
  opacity: 0.08;
  background: repeating-linear-gradient(
    -12deg,
    #5eead4 0px, #5eead4 3px, transparent 3px, transparent 18px,
    #1c69d4 18px, #1c69d4 21px, transparent 21px, transparent 36px,
    #c9a227 36px, #c9a227 39px, transparent 39px, transparent 54px
  );
  animation: bmw-stripe-shift 12s linear infinite;
  mask-image: linear-gradient(90deg, transparent, #000 30%, #000 70%, transparent);
}

.hero-bmw-bg__overlay {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(8, 12, 18, 0.75) 0%, rgba(10, 20, 28, 0.35) 45%, rgba(10, 18, 24, 0.15) 100%),
    linear-gradient(180deg, rgba(8, 12, 18, 0.5) 0%, transparent 35%, rgba(8, 12, 18, 0.55) 100%);
}

@keyframes bmw-color-drift {
  0% { transform: scale(1) translate(0, 0); }
  100% { transform: scale(1.05) translate(-1.5%, 0.5%); }
}

@keyframes bmw-light-sweep {
  0%, 100% { opacity: 0.35; transform: translateX(-8%); }
  50% { opacity: 0.8; transform: translateX(8%); }
}

@keyframes bmw-photo-kenburns {
  0%, 22% { opacity: 0; transform: scale(1.08); }
  28%, 47% { opacity: 0.7; transform: scale(1.0); }
  53%, 100% { opacity: 0; transform: scale(1.02); }
}

@keyframes bmw-stripe-shift {
  from { transform: translateY(0); }
  to { transform: translateY(-54px); }
}

@media (max-width: 1024px) {
  .page-home .hero-visual { min-height: 280px; }
  .page-home .hero-trustpilot--right {
    top: 16px;
    right: 16px;
    max-width: 10rem !important;
    padding: 0.65rem 0.85rem !important;
  }
  .hero-bmw-bg__stripes { display: none; }
}

@media (max-width: 768px) {
  .page-home .hero-trustpilot--right {
    position: relative;
    top: auto;
    right: auto;
    margin: 0 auto 1rem !important;
    display: inline-flex;
  }
}

@media (prefers-reduced-motion: reduce) {
  .hero-bmw-bg__colors,
  .hero-bmw-bg__colors::after,
  .hero-bmw-bg__slide,
  .hero-bmw-bg__stripes { animation: none !important; }
  .hero-bmw-bg__slide:first-child { opacity: 0.55; }
}
