/* ==========================================================================
   Section: marquee  →  assets/section-marquee.css
   Figma 1363-2619: 64px below the Countdown Banner, a 102px #080808 band with a 1px #e2e2e2
   line top and bottom. The row starts 32px in and is centred on the band: each message is a 32px
   sparkle (#bfbfbf) and Heading/H3 text, 24px apart, and the messages are 24px apart too.
   The track holds the group of messages several times over and slides left by one group per loop
   (assets/js/components/marquee-strip.js sets the copies and the duration), so the seam never
   shows. Hovering the band pauses it.
   ========================================================================== */
.marquee__strip {
  display: flex;
  align-items: center;
  height: 102px;
  padding-left: 32px;
  overflow: hidden;
  border-top: 1px solid var(--color-border-tertiary);
  border-bottom: 1px solid var(--color-border-tertiary);
  background: var(--color-surface-primary);
  color: var(--color-text-inverse);
}

.marquee__track {
  display: flex;
  flex: none;
  will-change: transform;
}

/* the trailing padding is the gap to the next copy, so one group is exactly one loop
   (two classes: the reset's ul[role="list"] { padding: 0 } would otherwise win) */
.marquee__track>.marquee__group {
  display: flex;
  flex: none;
  align-items: center;
  gap: 24px;
  padding-right: 24px;
}

.marquee__item {
  display: flex;
  flex: none;
  align-items: center;
  gap: 24px;
}

.marquee__item .icon-sparkle {
  color: var(--color-icon-tertiary);
}

/* Heading/H3: EB Garamond 500 32px / 1.2, whole-pixel boxes as Figma lays them out */
.marquee__text {
  width: var(--width-whole-px);
  font-family: var(--font-display);
  font-size: var(--text-display-s-size);
  font-weight: 500;
  line-height: 1.2;
  white-space: nowrap;
}

.marquee__strip.is-running .marquee__track {
  animation: marquee-slide var(--marquee-duration, 30s) linear infinite;
}

.marquee__strip[data-direction='right'].is-running .marquee__track {
  animation-direction: reverse;
}

.marquee__strip:hover .marquee__track {
  animation-play-state: paused;
}

@keyframes marquee-slide {
  from {
    transform: translate3d(0, 0, 0);
  }

  to {
    transform: translate3d(calc(-100% / var(--marquee-copies, 2)), 0, 0);
  }
}

@media (max-width: 749px) {
  .marquee {
    margin-top: 40px;
  }

  .marquee__strip {
    height: 72px;
    padding-left: 20px;
  }

  .marquee__track>.marquee__group,
  .marquee__item {
    gap: 16px;
  }

  .marquee__track>.marquee__group {
    padding-right: 16px;
  }

  .marquee__item .icon-sparkle {
    width: 24px;
    height: 24px;
  }

  .marquee__text {
    font-size: 24px;
  }
}