/* Client spotlight (blocks/spotlight.html, js/spotlight.js). Loaded only on pages that have the block.
   The night panel of the closing CTA, compact: title + client logos on the left, one client at a time on
   the right. Without the script (.is-armed missing) every quote is shown, one under the other. */
@layer components {
  .rs-spot { --promise: var(--lilac-400); --spot-dur: 8s; position: relative; isolation: isolate; overflow: hidden; display: grid; gap: clamp(1.5rem, 1rem + 2vw, 2.25rem);
    border-radius: 36px; color: #fff; padding: clamp(2rem, 1.25rem + 3vw, 3.5rem) var(--rs-band-pad);
    background: linear-gradient(180deg, #0A0726 0%, #1A1058 52%, #3A1C9E 100%); }
  .rs-spot__glow { position: absolute; z-index: -1; left: 50%; bottom: 0; width: 130%; aspect-ratio: 3; translate: -50% 66%; pointer-events: none;
    background: radial-gradient(ellipse at 50% 50%, rgb(159 212 255 / .5), rgb(138 60 254 / .4) 30%, rgb(58 28 158 / .14) 52%, transparent 68%); }

  /* left: the title and the logos */
  .rs-spot__eyebrow { margin: 0 0 .7rem; font-size: .75rem; font-weight: 600; letter-spacing: .14em; text-transform: uppercase; color: rgb(255 255 255 / .6); }
  .rs-spot__title { margin: 0; max-width: 16ch; font-size: var(--fs-h2); line-height: 1.06; letter-spacing: var(--ls-display); text-wrap: balance; }
  .rs-spot__title .rs-promise { display: block; margin-top: .06em; font-weight: 330; }
  .rs-spot__tabs { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .5rem; margin-top: clamp(1.25rem, .9rem + 1.4vw, 2rem); max-width: 26rem; }
  .rs-spot__tabs:has(> :nth-child(5)) { grid-template-columns: repeat(3, minmax(0, 1fr)); max-width: 30rem; }  /* five or six clients: three across, no lone logo */
  .rs-spot__tab { position: relative; display: flex; align-items: center; height: 3.5rem; padding: 0 1rem; border: 1px solid rgb(255 255 255 / .08); border-radius: 14px;
    background: rgb(255 255 255 / .03); color: #fff; font: inherit; cursor: pointer; -webkit-tap-highlight-color: transparent;
    transition: background-color var(--dur-base) var(--ease-out), border-color var(--dur-base) var(--ease-out); }
  .rs-spot__tab:hover { background: rgb(255 255 255 / .06); }
  .rs-spot__tab[aria-selected="true"] { background: rgb(255 255 255 / .11); border-color: rgb(255 255 255 / .26); }
  .rs-spot__tab:focus-visible { outline: 2px solid #9FD4FF; outline-offset: 2px; }
  .rs-spot__logo { display: block; width: auto; height: auto; max-width: 100%; max-height: 1.45rem; filter: brightness(0) invert(1); opacity: .45; transition: opacity var(--dur-base) var(--ease-out); }
  .rs-spot__word { font-weight: 650; font-size: 1rem; letter-spacing: -.01em; opacity: .45; }
  .rs-spot__tab:hover :is(.rs-spot__logo, .rs-spot__word) { opacity: .75; }
  .rs-spot__tab[aria-selected="true"] :is(.rs-spot__logo, .rs-spot__word) { opacity: 1; }

  /* right: one client at a time */
  .rs-spot__stage { display: grid; gap: 1rem; min-width: 0; }
  .rs-spot__pane { display: flex; flex-direction: column; justify-content: center; align-items: flex-start; margin: 0; padding: clamp(1.4rem, 1rem + 1.5vw, 2.1rem);
    border-radius: 24px; border: 1px solid rgb(255 255 255 / .12);
    background: linear-gradient(180deg, rgb(255 255 255 / .09), rgb(255 255 255 / .04)); -webkit-backdrop-filter: blur(14px); backdrop-filter: blur(14px);
    box-shadow: inset 0 1px 0 rgb(255 255 255 / .1), 0 40px 70px -40px rgb(4 2 24 / .7); }
  .rs-spot.is-armed .rs-spot__stage { gap: 0; }
  .rs-spot.is-armed .rs-spot__pane { grid-area: 1 / 1; opacity: 0; visibility: hidden; translate: 0 10px;
    transition: opacity .45s var(--ease-out), translate .6s var(--ease-out), visibility 0s linear .45s; }
  .rs-spot.is-armed .rs-spot__pane.is-on { opacity: 1; visibility: visible; translate: 0 0; transition-delay: .08s, .08s, 0s; }

  .rs-spot__who { display: flex; align-items: center; gap: 1rem; margin-bottom: clamp(.9rem, .7rem + .8vw, 1.25rem); }
  .rs-spot__face { flex: none; display: grid; place-items: center; width: 5.5rem; height: 5.5rem; padding: 3px; border-radius: 50%;
    background: conic-gradient(from 200deg, #9FD4FF, #8A3CFE, #F3E3FF, #9FD4FF); box-shadow: 0 14px 30px -14px rgb(4 2 24 / .8); }
  .rs-spot__face img, .rs-spot__face > span { display: grid; place-items: center; width: 100%; height: 100%; border-radius: 50%; object-fit: cover; border: 3px solid #1A1058; background: #2A1A78; font-size: 1.25rem; font-weight: 700; }
  .rs-spot__id { display: grid; gap: .15rem; min-width: 0; line-height: 1.25; }
  .rs-spot__id b { font-weight: 650; font-size: 1.125rem; }
  .rs-spot__id span { font-size: .9rem; color: rgb(255 255 255 / .66); }
  .rs-spot__quote { margin: 0; }
  .rs-spot__quote p { margin: 0; font-size: clamp(1.0625rem, .95rem + .45vw, 1.3rem); line-height: 1.5; font-weight: 400; letter-spacing: -.005em; color: rgb(255 255 255 / .92); text-wrap: pretty; }
  .rs-spot__quote p::before { content: "\201C"; } .rs-spot__quote p::after { content: "\201D"; }
  .rs-spot__mark { color: #fff; background: rgb(168 120 255 / .32); border-radius: .3em; padding: .02em .18em; -webkit-box-decoration-break: clone; box-decoration-break: clone; }
  .rs-spot__more { margin-top: clamp(1rem, .8rem + .8vw, 1.4rem); display: inline-flex; align-items: center; gap: .45rem; padding: .62rem .95rem .62rem 1.15rem; border-radius: 99px;
    background: #fff; color: #1A1058; font-size: .875rem; font-weight: 600; text-decoration: none; white-space: nowrap;
    box-shadow: 0 8px 22px -10px rgb(4 2 24 / .6); transition: translate var(--dur-base) var(--ease-out), box-shadow var(--dur-base) var(--ease-out); }
  .rs-spot__more .rs-i { width: .9rem; height: .9rem; transition: translate var(--dur-base) var(--ease-out); }
  .rs-spot__more:hover { translate: 0 -1px; box-shadow: 0 12px 26px -10px rgb(4 2 24 / .7); }
  .rs-spot__more:hover .rs-i { translate: 2px 0; }
  .rs-spot__more:focus-visible { outline: 2px solid #9FD4FF; outline-offset: 3px; }

  /* each client comes in: the face first, then the words, then the link; the line counts down to the next */
  .rs-spot__time { position: relative; display: none; height: 2px; width: 8rem; margin: .9rem 0 0 .25rem; border-radius: 2px; overflow: hidden; background: rgb(255 255 255 / .16); }
  .rs-spot__time i { display: block; height: 100%; background: linear-gradient(90deg, #9FD4FF, #fff); transform-origin: left center; transform: scaleX(0); }
  .rs-spot.is-armed.is-playing .rs-spot__time { display: block; grid-area: 2 / 1; }
  .rs-spot.is-playing .rs-spot__time i { animation: rs-spot-fill var(--spot-dur) linear forwards; }
  .rs-spot.is-playing:is(.is-paused, .is-off) .rs-spot__time i { animation-play-state: paused; }
  @keyframes rs-spot-fill { to { transform: scaleX(1); } }
  @media (prefers-reduced-motion: no-preference) {
    .rs-spot.is-armed .rs-spot__face { scale: .6; opacity: 0; transition: scale .6s var(--ease-out), opacity .4s var(--ease-out); }
    .rs-spot.is-armed .rs-spot__id { opacity: 0; translate: -8px 0; transition: opacity .5s var(--ease-out), translate .6s var(--ease-out); }
    .rs-spot.is-armed .rs-spot__quote { opacity: 0; translate: 0 12px; filter: blur(4px); transition: opacity .6s var(--ease-out), translate .7s var(--ease-out), filter .6s var(--ease-out); }
    .rs-spot.is-armed .rs-spot__more { opacity: 0; translate: 0 6px; transition: opacity .5s var(--ease-out), translate .6s var(--ease-out); }
    .rs-spot.is-armed .rs-spot__pane.is-on .rs-spot__face { scale: 1; opacity: 1; transition-delay: .1s; }
    .rs-spot.is-armed .rs-spot__pane.is-on .rs-spot__id { opacity: 1; translate: 0 0; transition-delay: .25s; }
    .rs-spot.is-armed .rs-spot__pane.is-on .rs-spot__quote { opacity: 1; translate: 0 0; filter: none; transition-delay: .4s; }
    .rs-spot.is-armed .rs-spot__pane.is-on .rs-spot__more { opacity: 1; translate: 0 0; transition-delay: .62s; }
    .rs-spot__glow { animation: rs-breathe 8s ease-in-out infinite alternate; }
  }
  @media (prefers-reduced-motion: reduce) {
    .rs-spot.is-armed .rs-spot__pane { transition: none; }
  }

  /* wide screens: title + logos left, the client right */
  @media (min-width: 960px) {
    .rs-spot { grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); align-items: center; column-gap: clamp(2.5rem, 1rem + 4vw, 5rem); }
  }

  /* the verified-reviews widget right under the panel (its stylesheet link sits in between): closer to it */
  :is(.rs-spot-wrap + .rs-bchk, .rs-spot-wrap + link + .rs-bchk) { padding-top: 0; margin-top: calc(-1 * clamp(.5rem, 2vw, 1.5rem)); }
  :is(.rs-spot-wrap + .rs-bchk--slider, .rs-spot-wrap + link + .rs-bchk--slider) .rs-bchk__mount { display: grid; justify-items: center; }

  @media (max-width: 639.98px) {
    .rs-spot { border-radius: 28px; padding-inline: 1rem; }
    .rs-spot__tabs { max-width: none; gap: .4rem; }
    .rs-spot__tab { height: 3rem; padding: 0 .75rem; justify-content: center; }
    .rs-spot__logo { max-height: 1.15rem; }
    .rs-spot__pane { padding: 1.25rem 1.15rem 1.2rem; border-radius: 20px; }
    .rs-spot__face { width: 4.25rem; height: 4.25rem; }
    .rs-spot__more { width: 100%; justify-content: center; padding-block: .75rem; }
  }
}
