/* hundred — 04 Statement + photo band (prefix band-) */

/* ---- A) statement block ---- */

.band-statement {
  padding-block: var(--space-statement);
  background: var(--paper);
  text-align: center;
}

.band-statement__title {
  margin-top: 28px;
}

.band-statement__copy {
  max-width: 520px;
  margin-inline: auto;
  margin-top: 24px;
}

@media (max-width: 767px) {
  .band-statement {
    padding-block: 120px;
  }

  .band-statement__title {
    margin-top: 22px;
  }

  .band-statement__copy {
    margin-top: 18px;
  }
}

/* staggered scroll reveal (60ms steps) */
@media (prefers-reduced-motion: no-preference) {
  .band-statement__title.reveal {
    transition-delay: 60ms;
  }

  .band-statement__copy.reveal {
    transition-delay: 120ms;
  }
}

/* ---- B) full-bleed photo band ---- */

.band-photo {
  display: grid;
  place-items: center;
  /* 1:1 with getcasa.com's "Casa can you" band (measured 2026-08-23):
     646px desktop, 360px mobile — em-based fixed heights, not viewport */
  height: 646px;
  width: 100%;
}

.ph--band {
  background-image: url("../assets/band-hallway.jpg");
  background-size: cover;
  background-position: center;
  background-color: #ab8155; /* warm fallback while the photo loads */
}

/* the photo is bright (white walls, daylit glass), so the scrim carries a
   soft pool behind the centered line on top of a light overall wash */
.band-photo__scrim {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(68% 58% at 50% 50%, rgba(0, 0, 0, 0.45) 0%, rgba(0, 0, 0, 0) 74%),
    linear-gradient(
      180deg,
      rgba(0, 0, 0, 0.3) 0%,
      rgba(0, 0, 0, 0.24) 45%,
      rgba(0, 0, 0, 0.38) 100%
    );
  pointer-events: none;
}

/* ---- ticker line ---- */

.band-line {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: baseline;
  column-gap: 0.32em;
  padding-inline: var(--gutter);
  font-family: var(--font-display);
  font-weight: 400;
  font-size: 48px;
  line-height: 1.2;
  letter-spacing: -0.02em;
  color: var(--paper);
}

.band-ticker {
  --band-shift: 1.2em;
  position: relative;
  display: inline-block;
  white-space: nowrap;
}

/* invisible widest phrase reserves the box so the line never shifts */
.band-ticker__sizer {
  display: inline-block;
  visibility: hidden;
}

.band-ticker__item {
  position: absolute;
  top: 0;
  left: 0;
  white-space: nowrap;
  opacity: 0;
  transform: translate(var(--band-tx, 0), var(--band-ty, 0));
}

@media (prefers-reduced-motion: no-preference) {
  .band-ticker__item {
    transition: transform var(--dur-med) var(--ease-out),
      opacity var(--dur-med) var(--ease-out);
  }
}

/* no-JS fallback: show the first phrase only */
.band-ticker:not(.band-ticker--live) .band-ticker__item:first-child {
  opacity: 1;
}

/* JS-driven states: active centered, neighbors ghosted above/below */
.band-ticker__item--active {
  --band-ty: 0;
  opacity: 1;
}

.band-ticker__item--next {
  --band-ty: var(--band-shift);
  opacity: 0.25;
}

.band-ticker__item--prev {
  --band-ty: calc(var(--band-shift) * -1);
  opacity: 0.25;
}

/* the line sliding out above, fading as it goes */
.band-ticker__item--out {
  --band-ty: calc(var(--band-shift) * -2);
  opacity: 0;
}

/* parked below, repositioned without animation while invisible */
.band-ticker__item--parked {
  --band-ty: calc(var(--band-shift) * 2);
  opacity: 0;
  transition: none;
}

@media (max-width: 767px) {
  .band-photo {
    height: 360px;
  }

  .band-line {
    flex-direction: column;
    align-items: center;
    font-size: 30px;
    text-align: center;
  }

  .band-line__static {
    margin-bottom: 1.5em;
  }

  /* center each phrase within the reserved box */
  .band-ticker__item {
    left: 50%;
    --band-tx: -50%;
  }
}
