/* Hero carousel - fade between slides (partials/hero.php) */
.hero--slider .hero__slide-media {
  opacity: 0;
  transition: opacity 1.2s ease;
}
.hero--slider .hero__slide-media.is-active {
  opacity: 1;
}
.hero__slides {
  display: grid;
}
.hero__slide {
  grid-area: 1 / 1;
}
.hero--slider .hero__slide {
  opacity: 0;
  visibility: hidden;
  transform: translateY(16px);
  transition: opacity .6s ease, transform .6s ease, visibility 0s linear .6s;
}
.hero--slider .hero__slide.is-active {
  opacity: 1;
  visibility: visible;
  transform: none;
  transition: opacity .8s ease .4s, transform .8s ease .4s, visibility 0s;
}
.hero__dots {
  display: flex;
  gap: 8px;
  margin-top: 40px;
}
.hero__dot {
  width: 40px;
  height: 4px;
  padding: 0;
  border: 0;
  border-radius: 2px;
  background: rgba(243, 244, 246, .35);
  cursor: pointer;
  transition: background-color .3s ease;
}
.hero__dot:hover {
  background: rgba(243, 244, 246, .7);
}
.hero__dot.is-active {
  background: #ecf660;
}
.hero__dot:focus-visible {
  outline: 2px solid #ecf660;
  outline-offset: 4px;
}
@media (prefers-reduced-motion: reduce) {
  .hero--slider .hero__slide-media,
  .hero--slider .hero__slide,
  .hero--slider .hero__slide.is-active {
    transition: none;
    transform: none;
  }
}

/* Topbar shown as a floating bar at the bottom (components/topbar.php) */
body:has(.topbar) {
  --topbar-height: 0px;
}
.topbar {
  top: auto;
  bottom: 24px;
  left: 50%;
  right: auto;
  width: max-content;
  max-width: calc(100% - 32px);
  height: auto;
  border-radius: 999px;
  box-shadow: 0 16px 48px rgba(19, 21, 32, .28), 0 0 0 1px rgba(19, 21, 32, .08);
  transform: translateX(-50%);
  animation: topbar-in .6s cubic-bezier(.2, .8, .2, 1) 1.2s both;
  transition: opacity .3s ease, visibility .3s ease;
}
/* Hide it while the cookie banner is open so they do not overlap */
body:has(.cky-consent-container:not(.cky-hide)) .topbar {
  opacity: 0;
  visibility: hidden;
}
.topbar__inner {
  gap: 16px;
  padding: 8px 52px 8px 20px;
}
.topbar__text {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 1rem;
  font-weight: 700;
  overflow: visible;
}
.topbar__text::before {
  content: "";
  flex-shrink: 0;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: currentColor;
  animation: topbar-pulse 2s ease-out infinite;
}
.topbar__link {
  padding: 8px 18px;
  border-radius: 999px;
  background: var(--topbar-color, #131520);
  color: var(--topbar-bg, #ecf660);
  font-size: .875rem;
  text-decoration: none;
  transition: transform .2s ease, opacity .2s ease;
}
.topbar__link:hover {
  opacity: 1;
  transform: translateX(2px);
}
.topbar__link::after {
  content: " →";
}
.topbar__close {
  right: 8px;
}
@keyframes topbar-in {
  from {
    opacity: 0;
    transform: translate(-50%, calc(100% + 24px));
  }
  to {
    opacity: 1;
    transform: translate(-50%, 0);
  }
}
@keyframes topbar-pulse {
  0% {
    box-shadow: 0 0 0 0 currentColor;
  }
  70%,
  100% {
    box-shadow: 0 0 0 8px transparent;
  }
}
@media (max-width: 767px) {
  .topbar {
    bottom: 16px;
    width: calc(100% - 32px);
    border-radius: 20px;
  }
  .topbar__inner {
    justify-content: flex-start;
    gap: 12px;
    padding: 10px 44px 10px 16px;
  }
  .topbar__text {
    flex: 1;
    min-width: 0;
    font-size: .875rem;
    white-space: normal;
    line-height: 1.3;
  }
  .topbar__link {
    padding: 8px 14px;
    font-size: .8125rem;
  }
  .topbar__link::after {
    content: "";
  }
}
@media (prefers-reduced-motion: reduce) {
  .topbar,
  .topbar__text::before {
    animation: none;
  }
}
