/* ============================================================
   CARROSSEL — carrossel.css
   Salve em: /wp-content/themes/SEU-TEMA/assets/css/carrossel.css
   ============================================================ */

.meu-carrossel-wrapper {
    position: relative;
    width: 100%;
    overflow: hidden;
    padding-bottom: 32px;
}

/* ── variáveis ── */
.meu-carrossel-wrapper {
    --yellow: #FFD700;
    --yellow-dk: #F0C000;
    --black: #111111;
    --white: #ffffff;
    --radius: 20px;
    --card-h: 440px;
    --ease: cubic-bezier(0.77, 0, 0.175, 1);
    --dur: 0.55s;
}

/* ── wrap + stage ── */
.meu-carrossel-wrapper .carousel-wrap {
    position: relative;
    width: 100%;
}

.meu-carrossel-wrapper .carousel-stage {
    position: relative;
    width: 100%;
    height: var(--card-h);
    overflow: visible;
}

/* ── CARD ── */
.meu-carrossel-wrapper .card {
    position: absolute;
    top: 0;
    height: var(--card-h);
    border-radius: var(--radius);
    overflow: hidden;
    cursor: pointer;
    user-select: none;
    will-change: left, width, opacity, filter;
    transition:
        left var(--dur) var(--ease),
        width var(--dur) var(--ease),
        opacity var(--dur) var(--ease),
        filter var(--dur) var(--ease),
        box-shadow var(--dur) var(--ease);
}

.meu-carrossel-wrapper .card img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

/* ── overlay gradiente ── */
.meu-carrossel-wrapper .card-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(to top,
            rgba(0, 0, 0, 0.92) 0%,
            rgba(0, 0, 0, 0.22) 52%,
            transparent 74%);
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    padding: 20px 18px 20px;
}

/* ── TÍTULO — todos os cards ── */
.meu-carrossel-wrapper .card-overlay h2 {
    font-family: 'Exo 2', sans-serif;
    font-weight: 800;
    font-size: 1rem;
    color: var(--white);
    line-height: 1.2;
    margin: 0 0 6px;
    opacity: 1;
    transform: none;
    transition: font-size var(--dur) var(--ease);
}

/* ── DESCRIÇÃO — só no card ativo ── */
.meu-carrossel-wrapper .card-overlay p {
    font-family: 'Exo 2', sans-serif;
    font-size: 0.83rem;
    font-weight: 400;
    color: rgba(255, 255, 255, 0.82);
    line-height: 1.55;
    margin: 0 0 16px;
    opacity: 0;
    max-height: 0;
    overflow: hidden;
    transform: translateY(8px);
    transition:
        opacity 0.38s ease 0.07s,
        transform 0.38s ease 0.07s,
        max-height 0.38s ease 0.07s;
}

/* ── CTA — todos os cards ── */
.meu-carrossel-wrapper .btn-saiba {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: var(--yellow);
    color: var(--black);
    border: none;
    border-radius: 50px;
    padding: 7px 14px;
    font-family: 'Exo 2', sans-serif;
    font-weight: 700;
    font-size: 0.72rem;
    cursor: pointer;
    width: fit-content;
    white-space: nowrap;
    text-decoration: none;
    opacity: 1;
    transition:
        padding var(--dur) var(--ease),
        font-size var(--dur) var(--ease),
        background 0.2s;
}

.meu-carrossel-wrapper .btn-saiba:hover {
    background: var(--yellow-dk);
}

.meu-carrossel-wrapper .btn-saiba .icon {
    width: 18px;
    height: 18px;
    background: var(--black);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    transition: width var(--dur) var(--ease), height var(--dur) var(--ease);
}

.meu-carrossel-wrapper .btn-saiba .icon svg {
    width: 9px;
}

/* ── CARD ATIVO ── */
.meu-carrossel-wrapper .card{
    background: #FFD700;
}

.meu-carrossel-wrapper .card.active {
    z-index: 10;
}

.meu-carrossel-wrapper .card.active .card-overlay h2 {
    font-size: 1.55rem;
}

.meu-carrossel-wrapper .card.active .card-overlay p {
    opacity: 1;
    max-height: 120px;
    transform: translateY(0);
}

.meu-carrossel-wrapper .card.active .btn-saiba {
    padding: 10px 20px;
    font-size: 0.82rem;
}

.meu-carrossel-wrapper .card.active .btn-saiba .icon {
    width: 22px;
    height: 22px;
}

/* delays de entrada */
.meu-carrossel-wrapper .card.active.anim-in .card-overlay h2 {
    transition-delay: 0.28s;
}

.meu-carrossel-wrapper .card.active.anim-in .card-overlay p {
    transition-delay: 0.35s;
}

.meu-carrossel-wrapper .card.active.anim-in .btn-saiba {
    transition-delay: 0.42s;
}

/* ── ANIMAÇÃO WIPE ── */
@keyframes carrosselWipeIn {
    from {
        clip-path: inset(0 100% 0 0 round var(--radius));
    }

    to {
        clip-path: inset(0 0% 0 0 round var(--radius));
    }
}

.meu-carrossel-wrapper .card.active.anim-in {
    animation: carrosselWipeIn 0.52s var(--ease) forwards;
}

/* ── DOTS ── */
.meu-carrossel-wrapper .dots {
    display: flex;
    gap: 8px;
    justify-content: center;
    margin-top: 24px;
}

.meu-carrossel-wrapper .dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #fff;
    border: none;
    cursor: pointer;
    transition: all 0.35s ease;
    padding: 0;
}

.meu-carrossel-wrapper .dot.active {
    width: 28px;
    border-radius: 4px;
    background: var(--black);
}

/* ── SETAS ── */
.meu-carrossel-wrapper .arrow {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    z-index: 20;
    background: var(--black);
    color: var(--yellow);
    border: none;
    border-radius: 50%;
    width: 46px;
    height: 46px;
    font-size: 1.4rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s, transform 0.2s;
    line-height: 1;
}

.meu-carrossel-wrapper .arrow:hover {
    background: #2a2a2a;
    transform: translateY(-50%) scale(1.07);
}

.meu-carrossel-wrapper .arrow.left {
    left: 16px;
}

.meu-carrossel-wrapper .arrow.right {
    right: 16px;
}

/* ── LOADING ── */
.meu-carrossel-wrapper .carrossel-loading {
    display: flex;
    gap: 8px;
    justify-content: center;
    align-items: center;
    height: var(--card-h);
}

.meu-carrossel-wrapper .carrossel-loading span {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: rgba(0, 0, 0, 0.25);
    animation: carrosselBounce 0.9s infinite alternate;
}

.meu-carrossel-wrapper .carrossel-loading span:nth-child(2) {
    animation-delay: 0.2s;
}

.meu-carrossel-wrapper .carrossel-loading span:nth-child(3) {
    animation-delay: 0.4s;
}

@keyframes carrosselBounce {
    from {
        transform: translateY(0);
        opacity: 0.3;
    }

    to {
        transform: translateY(-12px);
        opacity: 1;
    }
}

.meu-carrossel-wrapper .carrossel-loading.hidden {
    display: none;
}