/* The carousel (templates/_carousel.tsx): the working parts. Colours and sizes are the site's: override them in its CSS. */
.carousel { position: relative; --carousel-gap: 16px; --carousel-per-view: 1; }
.carousel-track { display: flex; gap: var(--carousel-gap); overflow-x: auto; scroll-snap-type: x mandatory; scroll-behavior: smooth; scrollbar-width: none; overscroll-behavior-x: contain; }
.carousel-track::-webkit-scrollbar { display: none; }
.carousel-track:focus-visible { outline: 2px solid currentColor; outline-offset: 4px; }
.carousel-slide { flex: 0 0 calc((100% - (var(--carousel-per-view) - 1) * var(--carousel-gap)) / var(--carousel-per-view)); scroll-snap-align: start; min-width: 0; }
.carousel-slide > * { margin: 0; }
.carousel-slide img { display: block; width: 100%; height: auto; }
.carousel-arrows { position: absolute; inset: 50% 8px auto; transform: translateY(-50%); display: flex; justify-content: space-between; pointer-events: none; }
.carousel-arrows[hidden] { display: none; }
.carousel-arrow { pointer-events: auto; width: 44px; height: 44px; display: grid; place-items: center; border: 0; border-radius: 50%; background: rgba(255, 255, 255, .92); color: #111; box-shadow: 0 2px 10px rgba(0, 0, 0, .18); cursor: pointer; }
.carousel-arrow svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 2.4; stroke-linecap: round; stroke-linejoin: round; }
.carousel-arrow:disabled { opacity: 0; pointer-events: none; }
.carousel-dots { display: flex; justify-content: center; gap: 10px; margin-top: 14px; }
.carousel-dots button { width: 10px; height: 10px; padding: 0; border-radius: 50%; border: 2px solid currentColor; background: transparent; opacity: .55; cursor: pointer; }
.carousel-dots button[aria-current] { background: currentColor; opacity: 1; }
@media (prefers-reduced-motion: reduce) { .carousel-track { scroll-behavior: auto; } }
