/* Header Carousel */
.tsc-section-header-carousel {
    position: relative;
    overflow: hidden;
    background: #f8f8f8;
    font-family: "Noto Serif Hebrew", sans-serif;
}

.carousel-track {
    position: relative;
}

/* Slides: stacked via absolute positioning for smooth crossfade */
.carousel-slide {
    position: absolute;
    inset: 0;
    width: 100%;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.7s ease, visibility 0.7s ease;
}

.carousel-slide.is-active {
    position: relative;
    opacity: 1;
    visibility: visible;
}

/* Inner layout: text + image side by side */
.carousel-slide-inner {
    display: flex;
    align-items: stretch;
    gap: 50px;
    max-width: 1200px;
    margin: 0 auto;
    padding: 60px 40px;
}

/* Text column: title/subtitle top, CTA bottom */
.carousel-content {
    flex: 1 1 0;
    min-width: 280px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    text-align: right;
}

.carousel-content-top {
    display: flex;
    flex-direction: column;
}

.carousel-title {
    font-size: 38px;
    font-weight: 800;
    color: #1e293b;
    line-height: 1.25;
    margin: 0 0 20px;
    text-align: right;
}

.carousel-subtitle {
    font-size: 17px;
    font-weight: 400;
    color: #534045;
    line-height: 1.7;
    margin: 0;
    text-align: right;
}

/* CTA button */
.carousel-cta {
    display: inline-block;
    align-self: flex-start;
    padding: 14px 36px;
    background: #A62A44;
    color: #ffffff;
    font-size: 16px;
    font-weight: 600;
    border-radius: 8px;
    text-decoration: none;
    position: relative;
    overflow: hidden;
    z-index: 1;
    transition: color 0.35s ease, transform 0.35s ease, box-shadow 0.35s ease;
}

.carousel-cta::before {
    content: '';
    position: absolute;
    inset: 0;
    background: #6F1426;
    transform: scaleX(0);
    transform-origin: right;
    transition: transform 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: -1;
    border-radius: inherit;
}

.carousel-cta:hover {
    color: #ffffff;
    transform: translateY(-3px);
    box-shadow: 0 8px 24px rgba(166, 42, 68, 0.35);
}

.carousel-cta:hover::before {
    transform: scaleX(1);
    transform-origin: left;
}

.carousel-cta:active {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(166, 42, 68, 0.3);
}

/* Image area — fixed dimensions, contain fit */
.carousel-image {
    flex: 0 0 578px;
    width: 578px;
    height: 390px;
    border-radius: 16px;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
}

.carousel-image img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    display: block;
}

/* ── Staggered entrance animations (pure CSS) ── */
@keyframes carouselFadeUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.carousel-slide.is-active .carousel-title {
    animation: carouselFadeUp 0.5s ease both;
    animation-delay: 0.1s;
}

.carousel-slide.is-active .carousel-subtitle {
    animation: carouselFadeUp 0.5s ease both;
    animation-delay: 0.2s;
}

.carousel-slide.is-active .carousel-cta {
    animation: carouselFadeUp 0.5s ease both;
    animation-delay: 0.3s;
}

.carousel-slide.is-active .carousel-image {
    animation: carouselFadeUp 0.5s ease both;
    animation-delay: 0.15s;
}

/* Controls: arrows + dots, centered at bottom */
.carousel-controls {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 16px;
    padding: 0 40px 30px;
}

.carousel-arrow {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    border: 1px solid #cbd5e1;
    background: #ffffff;
    color: #534045;
    cursor: pointer;
    transition: background 0.2s ease, border-color 0.2s ease, color 0.2s ease;
    padding: 0;
}

.carousel-arrow:hover {
    background: #A62A44;
    border-color: #A62A44;
    color: #ffffff;
    transform: none;
    box-shadow: none;
}

.carousel-dots {
    display: flex;
    align-items: center;
    gap: 8px;
}

.carousel-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    border: none;
    background: #cbd5e1;
    cursor: pointer;
    padding: 0;
    transition: background 0.25s ease, transform 0.25s ease;
}

.carousel-dot:hover {
    background: #94a3b8;
    transform: none;
    box-shadow: none;
}

.carousel-dot.is-active {
    background: #A62A44;
    transform: scale(1.2);
    box-shadow: none;
}

/* ── Responsive ── */
@media (max-width: 992px) {
    .carousel-slide-inner {
        flex-direction: column;
        gap: 30px;
        padding: 40px 20px;
    }

    .carousel-content {
        text-align: center;
    }

    .carousel-cta {
        align-self: center;
    }

    .carousel-image {
        flex: none;
        width: 100%;
        max-width: 578px;
        height: 300px;
    }

    .carousel-title {
        font-size: 30px;
    }
}

@media (max-width: 480px) {
    .carousel-image {
        height: 220px;
        border-radius: 12px;
    }

    .carousel-title {
        font-size: 24px;
    }

    .carousel-subtitle {
        font-size: 15px;
    }

    .carousel-slide-inner {
        padding: 30px 16px;
    }

    .carousel-controls {
        padding: 0 16px 20px;
    }
}
