.anchor-marquee {
  --anchor-marquee-gap: 18px;
  position: relative;
  display: grid;
  align-items: center;
  gap: 12px;
  min-height: var(--anchor-marquee-height, 132px);
}

.anchor-marquee-viewport {
  overflow: hidden;
  min-height: inherit;
}

.anchor-marquee-track {
  display: flex;
  align-items: center;
  gap: var(--anchor-marquee-gap);
  min-height: inherit;
}

.anchor-marquee-mode-marquee .anchor-marquee-track {
  width: max-content;
}

.anchor-marquee-mode-slider .anchor-marquee-track {
  gap: 0;
  width: 100%;
}

.anchor-marquee-mode-slider .anchor-marquee-item {
  margin: 0;
  min-width: 0;
  max-width: none;
}

.anchor-marquee-mode-marquee.is-static-fit .anchor-marquee-track {
  width: 100%;
  justify-content: flex-start;
}

.anchor-marquee-mode-marquee.is-static-fit .anchor-marquee-item {
  flex: 0 1 calc((100% - (var(--anchor-marquee-gap) * (var(--anchor-marquee-items-effective, var(--anchor-marquee-items-visible, 4)) - 1))) / var(--anchor-marquee-items-effective, var(--anchor-marquee-items-visible, 4)));
  width: calc((100% - (var(--anchor-marquee-gap) * (var(--anchor-marquee-items-effective, var(--anchor-marquee-items-visible, 4)) - 1))) / var(--anchor-marquee-items-effective, var(--anchor-marquee-items-visible, 4)));
  max-width: calc((100% - (var(--anchor-marquee-gap) * (var(--anchor-marquee-items-effective, var(--anchor-marquee-items-visible, 4)) - 1))) / var(--anchor-marquee-items-effective, var(--anchor-marquee-items-visible, 4)));
  min-width: 0;
}

.anchor-marquee-item {
  flex: 0 0 auto;
  min-width: 120px;
  max-width: 280px;
  min-height: calc(var(--anchor-marquee-height, 132px) - 12px);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  padding: 14px 16px;
  border-radius: calc(var(--radius, 12px) + 2px);
  background: color-mix(in srgb, var(--surface, #fff) 88%, transparent);
  border: 1px solid color-mix(in srgb, var(--text, #1d2a36) 8%, transparent);
  text-align: center;
}

.anchor-marquee-card-style-none .anchor-marquee-item {
  background: transparent;
  border-color: transparent;
  box-shadow: none;
}

.anchor-marquee-item-text {
  min-width: 180px;
}

.anchor-marquee-image {
  max-width: min(180px, 100%);
  max-height: calc(var(--anchor-marquee-height, 132px) - 34px);
  width: auto;
  height: auto;
  object-fit: contain;
  display: block;
}

.anchor-marquee-icon {
  font-size: clamp(1.8rem, 3vw, 3rem);
  color: var(--accent-2, #1655a2);
}

.anchor-marquee-copy {
  display: grid;
  gap: 4px;
}

.anchor-marquee-copy strong {
  font-size: 1rem;
  line-height: 1.2;
}

.anchor-marquee-copy span {
  font-size: 0.92rem;
  line-height: 1.35;
  color: var(--muted, #5e6b76);
}

.anchor-marquee-note {
  font-size: 0.82rem;
  line-height: 1.3;
  opacity: 0.82;
}

.anchor-marquee-arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 40px;
  height: 40px;
  border: 1px solid color-mix(in srgb, var(--text, #1d2a36) 16%, transparent);
  border-radius: 999px;
  background: color-mix(in srgb, var(--surface, #fff) 90%, transparent);
  color: var(--text, #1d2a36);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  z-index: 2;
  cursor: pointer;
}

.anchor-marquee-prev {
  left: 8px;
}

.anchor-marquee-next {
  right: 8px;
}

.anchor-marquee-dots {
  display: flex;
  justify-content: center;
  gap: 8px;
}

.anchor-marquee-dot {
  width: 10px;
  height: 10px;
  border-radius: 999px;
  border: 0;
  background: color-mix(in srgb, var(--text, #1d2a36) 20%, transparent);
  padding: 0;
  cursor: pointer;
}

.anchor-marquee-dot.is-active {
  background: var(--accent-2, #1655a2);
}

@media (max-width: 760px) {
  .anchor-marquee-item {
    min-width: 150px;
    max-width: 220px;
    padding: 12px 14px;
  }
}
