@property --shine-angle {
  syntax: '<angle>';
  initial-value: 0deg;
  inherits: false;
}

.shimmer-quote {
  position: relative;
  isolation: isolate;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 18px;
  width: min(82%, 560px);
  margin-inline: auto;
  min-height: 64px;
  padding: 17px 54px;
  border: 1px solid #ffffff42;
  border-radius: 999px;
  color: #fff;
  background:
    linear-gradient(180deg, #ffffff24, transparent 52%),
    linear-gradient(115deg, #9b43c2, #8c36b5 48%, #7926a3);
  box-shadow:
    inset 0 1px 0 #ffffff40,
    inset 0 -2px 4px #5f14732b,
    0 8px 22px #8c36b52b,
    0 2px 5px #69218421;
  font-size: 20px;
  font-weight: 700;
  line-height: 1.4;
  text-align: center;
  transition: transform .25s ease, box-shadow .25s ease;
  -webkit-tap-highlight-color: transparent;
  -webkit-touch-callout: none;
  -webkit-user-select: none;
  user-select: none;
}

/* Keep a long press on the pill itself, rather than its text or icon. */
.shimmer-quote > * { pointer-events: none; }

/* A single crisp highlight stays on the edge; the outer shadow is static. */
.shimmer-quote::after {
  content: '';
  position: absolute;
  inset: -1px;
  padding: 1.5px;
  border-radius: inherit;
  background: conic-gradient(from var(--shine-angle),
    #f9e4ff00 0deg 255deg,
    #efbcff55 285deg,
    #f9e4ffcc 310deg,
    #fff 325deg,
    #f9e4ff99 335deg,
    #f9e4ff00 350deg 360deg);
  -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
  mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
  -webkit-mask-composite: xor;
  mask-composite: exclude;
  pointer-events: none;
  animation: quote-orbit 4.5s linear infinite;
}

.shimmer-quote svg {
  position: absolute;
  right: 23px;
  width: 23px;
  height: 23px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
  transition: transform .25s ease;
}

@media (hover: hover) {
  .shimmer-quote:hover {
    transform: translateY(-2px);
    box-shadow: inset 0 1px 0 #ffffff50, 0 12px 30px #8c36b53b, 0 3px 8px #69218421;
  }
  .shimmer-quote:hover svg { transform: translateX(3px); }
}

.shimmer-quote:active { transform: translateY(1px); }
.shimmer-quote:focus-visible { outline: 3px solid #8c36b5; outline-offset: 8px; }

@keyframes quote-orbit { to { --shine-angle: 360deg; } }

@media (max-width: 600px) {
  .shimmer-quote { width: 90%; font-size: 18px; }
}

@media (prefers-reduced-motion: reduce) {
  .shimmer-quote::after { --shine-angle: 45deg; animation: none; }
  .shimmer-quote,
  .shimmer-quote svg { transition: none; }
}

/* A soft reflection crosses the surface, with a pause between passes. */
.sweep-quote::after { content: none; }
.sweep-quote::before {
  content: '';
  position: absolute;
  z-index: -1;
  inset: 1px;
  border-radius: inherit;
  pointer-events: none;
  background: linear-gradient(110deg,
    #fff0 40%, #fff1 45%, #fff5 49%, #fff2 52%, #fff0 58%);
  background-size: 300% 100%;
  background-repeat: no-repeat;
  background-position: 150% 0;
  animation: quote-sweep 5s ease-in-out infinite;
}

@keyframes quote-sweep {
  0%, 18% { background-position: 150% 0; }
  62%, 100% { background-position: -50% 0; }
}

@media (prefers-reduced-motion: reduce) {
  .sweep-quote::before { animation: none; background-position: 65% 0; }
}
