/* Homepage hero: autoplaying photo slideshow with two stacked promo tiles. */
.hero {
  display: grid; grid-template-columns: 2fr 1fr; gap: 16px;
  margin-top: 24px; min-height: 580px;
}

/* ---- slideshow ---- */
.slideshow {
  --slide-ms: 7s;
  position: relative; overflow: hidden; isolation: isolate;
  border-radius: var(--radius-lg); background: var(--color-navy); min-height: 580px;
}
.slide { position: absolute; inset: 0; opacity: 0; transition: opacity .9s var(--ease); }
.slide.is-active { opacity: 1; z-index: 1; }
.slide > img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transform: scale(1.08); }
.slide.is-active > img { animation: ken-burns calc(var(--slide-ms) + 1.5s) ease-out forwards; }
@keyframes ken-burns { from { transform: scale(1.1); } to { transform: scale(1); } }
.slide::after {
  content: ''; position: absolute; inset: 0; pointer-events: none;
  background: linear-gradient(90deg, rgba(10, 14, 22, .74) 0%, rgba(10, 14, 22, .36) 46%, rgba(10, 14, 22, 0) 76%);
}

.hero__content {
  position: absolute; z-index: 1; left: 0; bottom: 92px;
  max-width: 580px; padding: 0 56px;
  color: #fff;
}
.slide .hero__content > * { opacity: 0; transform: translateY(16px); transition: opacity .6s var(--ease), transform .6s var(--ease); }
.slide.is-active .hero__content > * { opacity: 1; transform: none; }
.slide.is-active .hero__content > :nth-child(2) { transition-delay: .08s; }
.slide.is-active .hero__content > :nth-child(3) { transition-delay: .16s; }
.slide.is-active .hero__content > :nth-child(4) { transition-delay: .24s; }

.hero__title { color: #fff; font-size: clamp(34px, 4.4vw, 60px); font-weight: 800; line-height: 1.04; letter-spacing: -.035em; }
.hero__text { margin-top: 16px; max-width: 44ch; font-size: 18px; color: rgba(255, 255, 255, .88); }
.hero__ctas { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 28px; }

/* progress navigation */
.slideshow__nav {
  position: absolute; z-index: 2; left: 56px; right: 56px; bottom: 24px;
  display: grid; grid-auto-flow: column; grid-auto-columns: 1fr; gap: 12px;
}
.slideshow__dot { display: grid; gap: 8px; padding: 6px 0; text-align: left; color: rgba(255, 255, 255, .7); }
.slideshow__dot:hover, .slideshow__dot[aria-current] { color: #fff; }
.slideshow__label { font-size: 12px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.slideshow__track { height: 3px; border-radius: 3px; background: rgba(255, 255, 255, .3); overflow: hidden; }
.slideshow__bar { display: block; height: 100%; width: 0; background: #fff; }
.slideshow__dot[aria-current] .slideshow__bar { animation: slide-progress var(--slide-ms) linear forwards; }
.slideshow:hover .slideshow__bar,
.slideshow:focus-within .slideshow__bar,
.slideshow.is-paused .slideshow__bar { animation-play-state: paused; }
@keyframes slide-progress { from { width: 0; } to { width: 100%; } }

/* ---- promo tiles ---- */
.hero__side { display: grid; grid-template-rows: 1fr 1fr; gap: 16px; }
.promo { display: block; width: 100%; border-radius: var(--radius-lg); text-align: left; color: #fff; }
.promo::after {
  content: ''; position: absolute; inset: 0; pointer-events: none;
  background: linear-gradient(0deg, rgba(10, 14, 22, .75) 0%, rgba(10, 14, 22, .15) 60%, rgba(10, 14, 22, 0) 100%);
}
.promo > img { transition: transform .7s var(--ease); }
.promo:hover > img { transform: scale(1.04); }
.promo__content { position: absolute; z-index: 1; left: 0; right: 0; bottom: 0; display: grid; gap: 4px; padding: 24px 26px; }
.promo .eyebrow { margin-bottom: 2px; }
.promo__title { font-size: 22px; font-weight: 800; letter-spacing: -.02em; line-height: 1.2; }
.promo__text { font-size: 14px; color: rgba(255, 255, 255, .85); }
.promo__link { margin-top: 8px; font-size: 14px; font-weight: 700; }
.promo:hover .promo__link { text-decoration: underline; text-underline-offset: 3px; }

@media (prefers-reduced-motion: reduce) {
  .slideshow__dot[aria-current] .slideshow__bar { width: 100%; animation: none; }
}
/* Laptops: the slideshow is two-thirds wide, so tighten the progress labels to fit */
@media (max-width: 1366px) and (min-width: 1181px) {
  .slideshow__nav { left: 40px; right: 40px; }
  .slideshow__label { font-size: 11px; letter-spacing: .05em; }
}
/* Small laptops and tablets in landscape: a side column would squeeze the slide,
   so the slideshow takes the full width and the two promo tiles sit side by side below. */
@media (max-width: 1180px) {
  .hero { grid-template-columns: 1fr; min-height: 0; }
  .slideshow { min-height: 540px; }
  .hero__side { grid-template-rows: none; grid-template-columns: 1fr 1fr; }
  .promo { min-height: 260px; }
}
@media (max-width: 900px) {
  /* bars only on tablets and phones: a taller invisible hit area so each dot is easy to tap */
  .slideshow__label { display: none; }
  .slideshow__dot { padding: 17px 0; }
  .slideshow__nav { bottom: 4px; }
  .slideshow { min-height: 500px; }
  .slide::after { background: linear-gradient(0deg, rgba(10, 14, 22, .82) 0%, rgba(10, 14, 22, .35) 55%, rgba(10, 14, 22, 0) 100%); }
  .promo { min-height: 240px; }
}
@media (max-width: 600px) {
  .hero { margin-top: 12px; }
  .slideshow { min-height: 520px; }
  .hero__content { bottom: 64px; padding: 0 22px; }
  .hero__text { font-size: 16px; }
  .slideshow__nav { left: 22px; right: 22px; bottom: 2px; gap: 8px; }
  /* two equal buttons side by side; they stack full-width if they don't fit */
  .hero__ctas { gap: 10px; }
  .hero__ctas .btn { flex: 1 1 140px; padding: 0 16px; }
  .hero__side { grid-template-columns: 1fr; }
  .promo { min-height: 190px; }
}
