/* ============================================================
   The Queen — theme strip (infinite word marquee under the hero)
   Modeled in spirit on the horizontal word-slider beneath the hero
   at 5roles.com, re-set in this site's own museum/editorial system:
   Cormorant Garamond italic, ink-on-bg, hairline rules, one accent
   (--purple-ink) on the divider glyphs only. No new colors/fonts —
   every value below resolves to a token from css/tokens.css.

   Structure reuses the generic .marquee (mask) / .marquee__track
   (sliding row) primitives already defined in css/base.css and the
   [data-marquee] auto-init in js/main.js — this file only adds the
   word-strip-specific skin on top of those primitives.
   ============================================================ */

.word-strip {
  background: var(--bg);
  border-top: var(--line-thin);
  border-bottom: var(--line-thin);
  padding-block: var(--s-4);
}

/* .marquee (base.css) already gives this mask overflow:hidden +
   white-space:nowrap — this is the piece that guarantees the strip
   never pushes page width, even at 375px. */
.word-strip__mask {
  position: relative;
}

/* soft fade at each edge so the loop reads as continuous, not clipped */
.word-strip__edge {
  position: absolute;
  top: 0; bottom: 0;
  width: clamp(28px, 8vw, 120px);
  z-index: 2;
  pointer-events: none;
}
.word-strip__edge--l { left: 0; background: linear-gradient(90deg, var(--bg) 0%, rgba(250, 253, 251, 0) 100%); }
.word-strip__edge--r { right: 0; background: linear-gradient(270deg, var(--bg) 0%, rgba(250, 253, 251, 0) 100%); }

/* .marquee__track (base.css) already gives inline-flex + will-change:transform;
   the compound selector here overrides its default gap regardless of CSS
   load order, since two classes always out-specifies one. */
.word-strip__track.marquee__track {
  align-items: baseline;
  gap: 0 var(--s-3);
  padding-inline: var(--s-2);
}

.word-strip__item {
  font-family: var(--display);
  font-style: italic;
  font-weight: 500;
  font-size: clamp(var(--fs-3), 3vw, var(--fs-4));
  line-height: 1;
  color: var(--ink);
  letter-spacing: .01em;
  white-space: nowrap;
}

.word-strip__dot {
  font-family: var(--body);
  font-style: normal;
  font-size: var(--fs-2);
  line-height: 1;
  color: var(--purple-ink);
  opacity: .55;
}

@media (max-width: 640px) {
  .word-strip { padding-block: var(--s-3); }
  .word-strip__item { font-size: var(--fs-3); }
}

/* Reduced motion: main.js returns before initializing [data-marquee] when
   prefers-reduced-motion is set (or GSAP is absent), so the track never
   receives its x-tween and would otherwise sit static at x:0 — showing the
   duplicated word list twice in a row with no way to reach the second copy.
   Let a reduced-motion user pan it manually instead of leaving dead content
   or unreachable duplicate text. */
@media (prefers-reduced-motion: reduce) {
  .word-strip__mask {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: thin;
  }
  .word-strip__edge { display: none; }
}
