/* =========================================
   RSC Hero Slider — Frontend Styles
   Referência: RSC-Slider principal - Home.png
   ========================================= */

/* ── Escape de container Blocksy ── */

/* Garantir que os ancestors não cortam o slider */
.ct-container-full:has(.rsc-hero-slider),
.ct-container:has(.rsc-hero-slider),
.entry-content:has(.rsc-hero-slider) {
    overflow: visible !important;
}

.entry-content .rsc-hero-slider,
.ct-container .rsc-hero-slider,
.ct-container-full .rsc-hero-slider,
.is-layout-constrained > .rsc-hero-slider,
.is-layout-flow > .rsc-hero-slider {
    margin-left: calc(50% - 50vw) !important;
    margin-right: calc(50% - 50vw) !important;
    max-width: 100vw !important;
    width: 100vw !important;
    box-sizing: border-box;
}

.rsc-hero-slider {
    position: relative;
    width: 100%;
    height: 680px;
    overflow: hidden;
    display: flex;
    align-items: flex-end;
    justify-content: flex-start;
}

/* ── Slide stack ── */
.rsc-hero-slider__slides {
    position: absolute;
    inset: 0;
    z-index: 0;
}

.rsc-hero-slider__slide {
    position: absolute;
    inset: 0;
    background-size: cover;
    background-position: center top;
    opacity: 0;
    transition: opacity 1.4s cubic-bezier(0.4, 0, 0.2, 1);
    will-change: opacity;
}

.rsc-hero-slider__slide.is-active {
    opacity: 1;
}

/* ── Overlay — gradiente diagonal do canto inf-esq ── */
.rsc-hero-slider__overlay {
    position: absolute;
    inset: 0;
    z-index: 1;
    background:
        linear-gradient(
            to right,
            rgba(0, 0, 0, 0.72) 0%,
            rgba(0, 0, 0, 0.38) 55%,
            rgba(0, 0, 0, 0.05) 100%
        ),
        linear-gradient(
            to top,
            rgba(0, 0, 0, 0.65) 0%,
            rgba(0, 0, 0, 0.10) 50%,
            transparent 100%
        );
}

/* ── Content — container padrão header/footer: max-width 1440px + padding 0 32px ── */
.rsc-hero-slider__content {
    position: relative;
    z-index: 2;
    text-align: left;
    width: 100%;
    max-width: 1440px;
    margin: 0 auto;
    padding: 0 32px 72px;
}

.rsc-hero-slider__title {
    font-family: var(--font-family-highlight, 'Vollkorn', serif);
    font-size: clamp(2rem, 4vw, 3.5rem);
    font-weight: 700;
    color: #ffffff;
    margin: 0 0 16px;
    line-height: 1.15;
    text-shadow: 0 2px 16px rgba(0, 0, 0, 0.4);
}

.rsc-hero-slider__subtitle {
    font-family: var(--font-family-base, 'Titillium Web', sans-serif);
    font-size: clamp(0.95rem, 1.6vw, 1.2rem);
    font-weight: 400;
    color: rgba(255, 255, 255, 0.92);
    margin: 0 0 36px;
    line-height: 1.65;
    text-shadow: 0 1px 6px rgba(0, 0, 0, 0.3);
    max-width: 520px;
}

/* Botão CTA — estilo terracota RSC */
.rsc-hero-slider__cta {
    display: inline-block;
    padding: 14px 36px;
    background-color: var(--color-pure-terracota, #B84F26);
    color: #ffffff;
    font-family: var(--font-family-base, 'Titillium Web', sans-serif);
    font-size: 0.9rem;
    font-weight: 700;
    letter-spacing: 0.07em;
    text-transform: uppercase;
    text-decoration: none;
    border-radius: 4px;
    border: 2px solid transparent;
    transition:
        background-color 0.25s ease,
        border-color 0.25s ease,
        transform 0.18s ease,
        box-shadow 0.25s ease;
    box-shadow: 0 4px 18px rgba(184, 79, 38, 0.35);
}

.rsc-hero-slider__cta:hover,
.rsc-hero-slider__cta:focus-visible {
    background-color: var(--color-dark-marrom, #544017);
    border-color: transparent;
    color: #ffffff;
    transform: translateY(-2px);
    box-shadow: 0 8px 28px rgba(84, 64, 23, 0.45);
}

/* ── Dots — esquerda, acima do texto ── */
.rsc-hero-slider__dots {
    position: absolute;
    bottom: 32px;
    right: 48px;
    z-index: 3;
    display: flex;
    gap: 8px;
    align-items: center;
}

.rsc-hero-slider__dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.40);
    border: none;
    padding: 0;
    cursor: pointer;
    transition: background 0.3s ease, transform 0.3s ease;
    flex-shrink: 0;
}

.rsc-hero-slider__dot.is-active {
    background: var(--color-pure-terracota, #B84F26);
    transform: scale(1.4);
}

.rsc-hero-slider__dot:hover:not(.is-active) {
    background: rgba(255, 255, 255, 0.75);
    transform: scale(1.2);
}

/* ── Responsive ── */
@media (max-width: 768px) {
    .rsc-hero-slider {
        height: 520px;
    }

    .rsc-hero-slider__content {
        padding: 0 24px 56px;
    }

    .rsc-hero-slider__title {
        font-size: clamp(1.6rem, 7vw, 2.4rem);
    }

    .rsc-hero-slider__subtitle {
        font-size: 0.95rem;
    }

    .rsc-hero-slider__dots {
        right: 28px;
        bottom: 20px;
    }
}

@media (max-width: 480px) {
    .rsc-hero-slider {
        height: 420px;
    }

    .rsc-hero-slider__content {
        padding: 0 20px 44px;
    }
    .rsc-hero-slider__subtitle {
        max-width: 100%;
    }

    .rsc-hero-slider__cta {
        padding: 12px 28px;
        font-size: 0.85rem;
    }
}

/* ── Reduced motion ── */
@media (prefers-reduced-motion: reduce) {
    .rsc-hero-slider__slide {
        transition: none;
    }
    .rsc-hero-slider__cta {
        transition: none;
    }
    .rsc-hero-slider__dot {
        transition: none;
    }
}
