/* =============================================================
   Event Sponsor Carousel Styles
   File: wp-content/themes/educal-child/sponsor-carousel.css
   Brand color: #C1272D (matches the single-event.php palette)
   ============================================================= */

/* ---------- Section wrapper ---------- */
.event-sponsors-section {
    width: 100%;
    padding: 64px 0 56px;
    background: #f9fafb;
    border-top: 1px solid #e5e7eb;
    margin-top: 56px;
}

/* ---------- Inner constraint ---------- */
.sponsors-section-inner {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 24px;
}

/* ---------- Section heading ---------- */
.sponsors-header {
    text-align: center;
    margin-bottom: 48px;
}

.sponsors-title {
    font-size: 28px;
    font-weight: 800;
    color: #2C3E50;
    margin: 0 0 12px;
    letter-spacing: -0.3px;
}

/* Decorative underline bar */
.sponsors-title-bar {
    width: 56px;
    height: 4px;
    background: linear-gradient(90deg, #C1272D 0%, #FF9800 100%);
    border-radius: 99px;
    margin: 0 auto;
}

/* ---------- Carousel wrapper ---------- */
.sponsors-carousel-wrapper {
    position: relative;
    /* Extra padding ensures arrows don't clip */
    padding: 0 52px;
}

/* ---------- Swiper overrides ---------- */
.sponsors-swiper {
    overflow: hidden; /* required by Swiper */
    padding-bottom: 48px; /* room for dots */
}

/* ---------- Individual sponsor slide ---------- */
.sponsor-slide {
    display: flex;
    align-items: center;
    justify-content: center;
    /* Fixed height so cards align */
    height: auto;
}

/* ---------- Logo link / container ---------- */
.sponsor-logo-link {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 110px;
    background: #ffffff;
    border: 1px solid #e5e7eb;
    border-radius: 16px;
    padding: 20px 24px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
    transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
    text-decoration: none;
    overflow: hidden;
}

.sponsor-logo-link:hover {
    transform: translateY(-4px);
    box-shadow: 0 10px 28px rgba(193, 39, 45, 0.12);
    border-color: #C1272D;
}

/* ---------- Logo image ---------- */
.sponsor-logo-img {
    max-width: 100%;
    max-height: 70px;
    width: auto;
    height: auto;
    object-fit: contain;
    /* Desaturate by default, colour on hover for a premium feel */
    filter: grayscale(60%) opacity(0.75);
    transition: filter 0.3s ease;
}

.sponsor-logo-link:hover .sponsor-logo-img {
    filter: grayscale(0%) opacity(1);
}

/* ---------- Navigation arrows ---------- */
.sponsors-swiper .swiper-button-prev,
.sponsors-swiper .swiper-button-next {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: #ffffff;
    border: 2px solid #C1272D;
    color: #C1272D;
    box-shadow: 0 2px 12px rgba(193, 39, 45, 0.15);
    top: calc(50% - 24px); /* centre vertically, offset for dots */
    transition: background 0.2s, color 0.2s;
}

.sponsors-swiper .swiper-button-prev {
    left: -4px;
}

.sponsors-swiper .swiper-button-next {
    right: -4px;
}

.sponsors-swiper .swiper-button-prev:hover,
.sponsors-swiper .swiper-button-next:hover {
    background: #C1272D;
    color: #ffffff;
}

/* Arrow icon resize */
.sponsors-swiper .swiper-button-prev::after,
.sponsors-swiper .swiper-button-next::after {
    font-size: 14px;
    font-weight: 900;
}

/* ---------- Pagination dots ---------- */
.sponsors-swiper .swiper-pagination {
    bottom: 4px;
}

.sponsors-swiper .swiper-pagination-bullet {
    background: #C1272D;
    opacity: 0.35;
    width: 8px;
    height: 8px;
    transition: opacity 0.2s, width 0.2s;
}

.sponsors-swiper .swiper-pagination-bullet-active {
    opacity: 1;
    width: 24px;
    border-radius: 4px;
}

/* ---------- Responsive ---------- */

/* Tablet ≤ 1024px */
@media (max-width: 1024px) {
    .event-sponsors-section {
        padding: 48px 0 40px;
    }

    .sponsors-carousel-wrapper {
        padding: 0 44px;
    }

    .sponsors-title {
        font-size: 24px;
    }
}

/* Mobile ≤ 767px */
@media (max-width: 767px) {
    .event-sponsors-section {
        padding: 40px 0 32px;
        margin-top: 40px;
    }

    .sponsors-section-inner {
        padding: 0 16px;
    }

    .sponsors-carousel-wrapper {
        padding: 0 36px;
    }

    .sponsors-title {
        font-size: 20px;
    }

    .sponsor-logo-link {
        height: 90px;
        padding: 16px 18px;
    }

    .sponsor-logo-img {
        max-height: 52px;
    }

    .sponsors-swiper .swiper-button-prev,
    .sponsors-swiper .swiper-button-next {
        width: 32px;
        height: 32px;
    }

    .sponsors-swiper .swiper-button-prev::after,
    .sponsors-swiper .swiper-button-next::after {
        font-size: 11px;
    }
}

/* Very small screens ≤ 400px */
@media (max-width: 400px) {
    .sponsors-carousel-wrapper {
        padding: 0 28px;
    }
}

/* ---------- Elementor compatibility ---------- */
/* Prevent Elementor column padding from breaking the wrapper */
.elementor-widget-shortcode .event-sponsors-section {
    margin-left: -24px;
    margin-right: -24px;
    width: calc(100% + 48px);
}

/* ---------- Admin demo-mode notice ---------- */
/* Shown only to logged-in admins when no ACF sponsors have been added yet */
.event-sponsors-section.sponsors-demo-mode {
    border-top-style: dashed;
    border-top-color: #f59e0b;
}

.sponsors-demo-notice {
    margin-top: 14px;
    font-size: 13px;
    color: #92400e;
    background: #fef3c7;
    border: 1px dashed #f59e0b;
    border-radius: 8px;
    padding: 8px 14px;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    line-height: 1.5;
}

.sponsors-demo-badge {
    background: #f59e0b;
    color: #fff;
    font-size: 11px;
    font-weight: 700;
    padding: 2px 8px;
    border-radius: 4px;
    white-space: nowrap;
    letter-spacing: 0.03em;
}

.sponsors-demo-notice a {
    color: #92400e;
    font-weight: 700;
    text-decoration: underline;
}
