/* =========================================
   Home hero slideshow
   (the .hero__panel box, floats and fallback live in hero.css)
   ========================================= */

.hero__panel--slides {
    display: block;
    background: var(--color-primary-dark);
}

/* hide the decorative glow layers from hero.css over photos */
.hero__panel--slides::before,
.hero__panel--slides::after {
    display: none;
}

.hero-slide {
    position: absolute;
    inset: 0;
    margin: 0;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.9s ease, visibility 0s linear 0.9s;
}

.hero-slide.is-active {
    opacity: 1;
    visibility: visible;
    transition: opacity 0.9s ease, visibility 0s;
}

.hero-slide img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transform: scale(1.04);
    transition: transform 6s ease-out;
}

.hero-slide.is-active img {
    transform: scale(1);
}

/* soft shade at the bottom so the caption and dots stay readable */
.hero-slide::after {
    content: "";
    position: absolute;
    inset: 55% 0 0;
    background: linear-gradient(to top, rgba(6, 20, 46, 0.55), transparent);
    pointer-events: none;
}

.hero-slide figcaption {
    position: absolute;
    right: 18px;
    bottom: 18px;
    z-index: 2;
}

.hero-slide__caption {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 9px 14px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.94);
    color: var(--color-text);
    font-size: 0.9rem;
    font-weight: 700;
    box-shadow: var(--shadow-sm);
    backdrop-filter: blur(6px);
    transition: background 0.2s ease, color 0.2s ease;
}

a.hero-slide__caption:hover {
    background: var(--color-white);
    color: var(--color-primary);
}

.hero-slide__caption .icon {
    width: 15px;
    height: 15px;
}


/* Dots */

.hero-slides__dots {
    position: absolute;
    left: 22px;
    bottom: 32px;
    z-index: 3;
    display: flex;
    gap: 8px;
}

.hero-slides__dot {
    width: 9px;
    height: 9px;
    padding: 0;
    border: 0;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.55);
    cursor: pointer;
    transition: width 0.3s ease, background 0.3s ease;
}

.hero-slides__dot.is-active {
    width: 24px;
    background: var(--color-white);
}

.hero-slides__dot:focus-visible {
    outline-color: var(--color-white);
}


/* the checklist card covers the bottom-left and the badge the top-right,
   so on wide screens the dots move to the top-left corner */
@media (min-width: 961px) {
    .hero-slides__dots {
        left: 24px;
        bottom: auto;
        top: 24px;
    }
}

/* on phones the checklist card would cover the caption and dots, so hide it
   when photos are showing (it's decorative) */
@media (max-width: 600px) {
    .hero__visual--slides .hero__float--checklist {
        display: none;
    }

    .hero__visual--slides {
        padding-bottom: 0;
    }
}

@media (prefers-reduced-motion: reduce) {
    .hero-slide img {
        transform: none;
    }
}
