/* Sliders ------------------------------------------------------- */

/* Ambient hero crossfade ---------------------------------------- */

.hero-slider {
  position: absolute;
  inset: 0;
  z-index: 0;
  overflow: hidden;
  pointer-events: none;
}

.hero-slider__slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  transform: scale(1.04);
  transition: opacity 1.8s var(--ease), transform 18s linear;
  will-change: opacity, transform;
}

.hero-slider__slide.is-active {
  opacity: 1;
  transform: scale(1);
}

.hero-slider__slide img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 42%;
  opacity: 0.62;
  filter: saturate(0.55) contrast(1.06);
}

.hero-slider__veil {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(180deg, rgba(23, 25, 22, 0.94) 0%, rgba(23, 25, 22, 0.74) 42%, rgba(23, 25, 22, 0.94) 100%),
    linear-gradient(90deg, rgba(23, 25, 22, 0.88) 0%, rgba(23, 25, 22, 0.52) 58%, rgba(23, 25, 22, 0.78) 100%);
}

.hero-slider__progress {
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 2px;
  background: rgba(166, 165, 138, 0.18);
}

.hero-slider__progress span {
  display: block;
  width: 100%;
  height: 100%;
  background: var(--olive);
  transform: scaleX(0);
  transform-origin: left center;
  will-change: transform;
}

/* Visual notes gallery slider ----------------------------------- */

.gallery-slider {
  margin-top: clamp(50px, 6vw, 84px);
  padding-top: clamp(28px, 3.4vw, 44px);
  border-top: 1px solid var(--line);
}

.gallery-slider__head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 20px 32px;
  margin-bottom: 22px;
}

.gallery-slider__title {
  margin-top: 8px;
  font-family: var(--serif);
  font-size: clamp(1.5rem, 2.6vw, 2.3rem);
  font-weight: 400;
  line-height: 1.1;
  letter-spacing: -0.02em;
}

.gallery-slider__controls {
  display: inline-flex;
  align-items: center;
  gap: 10px;
}

.gallery-slider__count {
  margin-right: 8px;
  font-family: var(--mono);
  font-size: 9px;
  text-transform: uppercase;
  letter-spacing: 0.16em;
  color: var(--muted);
  font-variant-numeric: tabular-nums;
}

.gallery-slider__btn {
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  padding: 0;
  border: 1px solid var(--line-strong);
  border-radius: 50%;
  background: transparent;
  cursor: pointer;
  transition: background 0.35s ease, color 0.35s ease, border-color 0.35s ease, transform 0.35s var(--ease);
}

.gallery-slider__btn svg {
  width: 16px;
  height: 16px;
}

.gallery-slider__btn--prev svg {
  transform: rotate(180deg);
}

.gallery-slider__btn:hover {
  background: var(--olive);
  border-color: var(--olive);
  color: var(--ink);
  transform: translateY(-2px);
}

.gallery-slider__viewport {
  overflow: hidden;
  border: 1px solid var(--line-strong);
  background: var(--ink-3);
  touch-action: pan-y;
}

.gallery-slider__track {
  display: flex;
  will-change: transform;
  transition: transform 0.75s var(--ease);
}

.gallery-slider__slide {
  position: relative;
  flex: 0 0 100%;
  margin: 0;
}

.gallery-slider__slide img {
  display: block;
  width: 100%;
  aspect-ratio: 3 / 1.55;
  object-fit: cover;
  filter: saturate(0.72) contrast(1.04);
  -webkit-user-drag: none;
  user-select: none;
}

.gallery-slider__slide figcaption {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: clamp(14px, 2vw, 22px);
  background: linear-gradient(0deg, rgba(23, 25, 22, 0.92), rgba(23, 25, 22, 0));
  font-family: var(--serif);
  font-size: clamp(0.95rem, 1.5vw, 1.3rem);
  font-style: italic;
  line-height: 1.3;
  color: var(--ivory);
}

.gallery-slider__slide figcaption span {
  font-family: var(--mono);
  font-size: 9px;
  font-style: normal;
  letter-spacing: 0.16em;
  color: var(--olive);
}

.gallery-slider__dots {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin-top: 16px;
}

.gallery-slider__dots button {
  width: 28px;
  height: 3px;
  padding: 0;
  border: 0;
  background: rgba(233, 229, 216, 0.22);
  cursor: pointer;
  transition: background 0.35s ease, width 0.4s var(--ease);
}

.gallery-slider__dots button:hover {
  background: rgba(166, 165, 138, 0.6);
}

.gallery-slider__dots button.is-active {
  width: 46px;
  background: var(--olive);
}

@media (max-width: 680px) {
  .gallery-slider__head {
    align-items: flex-start;
  }

  .gallery-slider__controls {
    width: 100%;
    justify-content: space-between;
  }

  .gallery-slider__slide img {
    aspect-ratio: 4 / 3;
  }

  .hero-slider__progress {
    display: none;
  }
}
