/* ----------------- Premium Trek Gallery (Apple coverflow) ----------------- */

.trek-gallery-section {
    background: #ffffff;
    padding: 96px 0 120px;
    overflow: hidden;
}

.trek-gallery-header {
    max-width: 680px;
    margin-bottom: clamp(48px, 7vw, 80px);
}

.trek-gallery-header .section-subtitle {
    font-family: 'Poppins', sans-serif;
    font-size: 13px;
    font-weight: 600;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    color: #9ca3af;
    margin-bottom: 18px;
}

.trek-gallery-header .section-title {
    font-family: 'Poppins', sans-serif;
    font-weight: 600;
    font-size: clamp(1.85rem, 4vw, 2.65rem);
    letter-spacing: -0.03em;
    line-height: 1.15;
    color: #111827;
}

.trek-gallery-header .section-desc {
    font-family: 'Poppins', sans-serif;
    font-size: 1rem;
    line-height: 1.8;
    color: #6b7280;
    margin-top: 18px;
}

.trek-gallery {
    max-width: 1500px;
    margin: 0 auto;
    padding: 0 clamp(12px, 3vw, 32px);
}

.trek-gallery__shell {
    background: #ffffff;
    border-radius: clamp(28px, 4vw, 48px);
    padding: clamp(32px, 5vw, 56px) 0 clamp(24px, 3vw, 36px);
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.08);
    border: 1px solid rgba(0, 0, 0, 0.04);
    overflow: hidden;
}

.trek-gallery__stage {
    position: relative;
    overflow: hidden;
    padding: 12px 0 8px;
}

.trek-gallery__swiper {
    overflow: visible !important;
    padding: 28px 0 36px;
}

.trek-gallery__swiper .swiper-wrapper {
    align-items: center;
}

.trek-gallery__swiper .swiper-slide {
    width: clamp(220px, 28vw, 300px);
    height: auto;
    transform-style: preserve-3d;
    backface-visibility: hidden;
    transition: filter 0.5s cubic-bezier(0.25, 0.1, 0.25, 1),
                opacity 0.5s cubic-bezier(0.25, 0.1, 0.25, 1);
}

.trek-gallery__swiper .swiper-slide:not(.swiper-slide-active) {
    filter: brightness(0.94) saturate(0.92);
    opacity: 0.82;
}

.trek-gallery__swiper .swiper-slide-active {
    filter: brightness(1.04) saturate(1.02);
    opacity: 1;
    z-index: 2;
}

.trek-gallery__swiper .swiper-slide .tour-card-link {
    display: block;
    height: 100%;
    text-decoration: none !important;
}

/* Gallery card panel */
.trek-gallery-section .tour-card--gallery {
    --slide-progress: 0;
    --gallery-ease: 0.5s cubic-bezier(0.25, 0.1, 0.25, 1);
    position: relative;
    display: flex;
    flex-direction: column;
    height: clamp(380px, 48vh, 520px);
    font-family: 'Poppins', sans-serif;
    background: #ffffff;
    border: none;
    border-radius: 32px;
    overflow: hidden;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.08);
    transition:
        box-shadow var(--gallery-ease),
        height var(--gallery-ease);
}

.trek-gallery-section .swiper-slide-active .tour-card--gallery {
    height: clamp(440px, 54vh, 580px);
    box-shadow: 0 32px 90px rgba(0, 0, 0, 0.14);
}

.trek-gallery-section .tour-card--gallery:hover {
    box-shadow: 0 28px 80px rgba(0, 0, 0, 0.12);
    transform: none;
}

.trek-gallery-section .swiper-slide-active .tour-card--gallery:hover {
    box-shadow: 0 36px 100px rgba(0, 0, 0, 0.16);
}

/* Image area — full panel on side slides, cinematic on active */
.trek-gallery-section .tour-card--gallery .tour-image-container {
    position: relative;
    flex: 1 1 auto;
    min-height: 100%;
    border-radius: 32px;
    overflow: hidden;
    background: #f5f5f7;
    transition:
        min-height var(--gallery-ease),
        border-radius var(--gallery-ease);
}

.trek-gallery-section .swiper-slide-active .tour-card--gallery .tour-image-container {
    flex: 0 0 52%;
    min-height: 0;
    border-radius: 32px 32px 0 0;
}

.trek-gallery-section .tour-card--gallery .tour-image-container img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transform:
        translateX(calc(var(--slide-progress) * -24px))
        scale(calc(1.06 + min(abs(var(--slide-progress)), 1) * 0.02));
    transition: transform 0.5s cubic-bezier(0.25, 0.1, 0.25, 1);
}

.trek-gallery-section .swiper-slide-active .tour-card--gallery:hover .tour-image-container img {
    transform: translateX(0) scale(1.1);
}

/* Badges — subtle on image */
.trek-gallery-section .tour-card--gallery .tour-badge {
    top: 16px;
    padding: 5px 12px;
    border-radius: 999px;
    font-family: 'Poppins', sans-serif;
    font-size: 10px;
    font-weight: 600;
    letter-spacing: 0.08em;
    backdrop-filter: blur(10px);
    transition: opacity var(--gallery-ease);
}

.trek-gallery-section .swiper-slide:not(.swiper-slide-active) .tour-card--gallery .tour-badge {
    opacity: 0.85;
}

.trek-gallery-section .tour-card--gallery .badge-difficulty-easy,
.trek-gallery-section .tour-card--gallery .badge-difficulty-moderate,
.trek-gallery-section .tour-card--gallery .badge-difficulty-difficult {
    left: 16px;
}

.trek-gallery-section .tour-card--gallery .badge-category {
    right: 16px;
    background: rgba(255, 255, 255, 0.18);
    border: 1px solid rgba(255, 255, 255, 0.28);
}

/* Details — hidden on side slides, revealed on active */
.trek-gallery-section .tour-card--gallery .tour-details {
    flex: 1 1 auto;
    display: flex;
    flex-direction: column;
    padding: 0 24px;
    max-height: 0;
    opacity: 0;
    overflow: hidden;
    pointer-events: none;
    transition:
        max-height var(--gallery-ease),
        opacity var(--gallery-ease),
        padding var(--gallery-ease);
}

.trek-gallery-section .swiper-slide-active .tour-card--gallery .tour-details {
    max-height: 320px;
    opacity: 1;
    padding: 22px 24px 26px;
    pointer-events: auto;
}

.trek-gallery-section .tour-card--gallery .tour-location {
    font-family: 'Poppins', sans-serif;
    font-size: 12px;
    font-weight: 500;
    color: #6b7280;
    gap: 7px;
    margin-bottom: 8px;
}

.trek-gallery-section .tour-card--gallery .tour-location .trek-lucide,
.trek-gallery-section .tour-card--gallery .tour-location svg {
    width: 14px;
    height: 14px;
    color: #ff6a00;
    stroke: #ff6a00;
    flex-shrink: 0;
}

.trek-gallery-section .tour-card--gallery .tour-title {
    font-family: 'Poppins', sans-serif;
    font-size: clamp(1.1rem, 2vw, 1.35rem);
    font-weight: 700;
    color: #111827;
    letter-spacing: -0.02em;
    margin-bottom: 14px !important;
    line-height: 1.25;
}

.trek-gallery-section .tour-card--gallery .tour-meta-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px 12px;
    margin-bottom: 18px;
    padding-bottom: 0;
    border-bottom: none;
}

.trek-gallery-section .tour-card--gallery .tour-meta-item {
    font-family: 'Poppins', sans-serif;
    font-size: 11px;
    font-weight: 500;
    color: #6b7280;
    gap: 6px;
}

.trek-gallery-section .tour-card--gallery .tour-meta-item .trek-lucide,
.trek-gallery-section .tour-card--gallery .tour-meta-item svg {
    width: 14px;
    height: 14px;
    color: #155d3b;
    stroke: #155d3b;
    flex-shrink: 0;
}

.trek-gallery-section .tour-card--gallery .seats-left {
    color: #ff6a00;
}

.trek-gallery-section .tour-card--gallery .tour-price-booking {
    align-items: flex-end;
    gap: 12px;
    margin-top: auto;
}

.trek-gallery-section .tour-card--gallery .tour-price-label {
    font-family: 'Poppins', sans-serif;
    font-size: 9px;
    font-weight: 600;
    letter-spacing: 0.14em;
    color: #9ca3af;
    margin-bottom: 3px;
}

.trek-gallery-section .tour-card--gallery .tour-price-original {
    font-family: 'Poppins', sans-serif;
    font-size: 11px;
    color: #9ca3af;
    text-decoration: line-through;
    margin-bottom: 2px;
}

.trek-gallery-section .tour-card--gallery .tour-price-value {
    font-family: 'Poppins', sans-serif;
    font-size: clamp(1.25rem, 2vw, 1.5rem);
    font-weight: 700;
    color: #ff6a00;
    letter-spacing: -0.02em;
}

.trek-gallery-section .tour-card--gallery .tour-book-btn {
    font-family: 'Poppins', sans-serif;
    font-size: 13px;
    font-weight: 600;
    background: #155d3b;
    color: #ffffff;
    border: none;
    border-radius: 18px;
    padding: 11px 20px;
    white-space: nowrap;
    box-shadow: 0 10px 28px rgba(21, 93, 59, 0.22);
    transition:
        transform 0.5s cubic-bezier(0.25, 0.1, 0.25, 1),
        box-shadow 0.5s cubic-bezier(0.25, 0.1, 0.25, 1),
        background 0.35s ease;
}

.trek-gallery-section .tour-card--gallery:hover .tour-book-btn {
    background: #124a2f;
    transform: translateY(-2px);
    box-shadow: 0 14px 32px rgba(21, 93, 59, 0.28);
}

/* Hide swiper arrows */
.trek-gallery__swiper .swiper-button-next,
.trek-gallery__swiper .swiper-button-prev {
    display: none !important;
}

/* Minimal progress track (replaces dot pagination) */
.trek-gallery__footer {
    display: flex;
    justify-content: center;
    padding: 8px clamp(24px, 8vw, 120px) 0;
}

.trek-gallery__track {
    width: min(280px, 42vw);
    height: 3px;
    border-radius: 999px;
    background: rgba(0, 0, 0, 0.08);
    overflow: hidden;
}

.trek-gallery__track-fill {
    display: block;
    height: 100%;
    width: 0;
    border-radius: inherit;
    background: linear-gradient(90deg, #155d3b 0%, #1f7a4d 100%);
    transition: width 0.7s cubic-bezier(0.25, 0.1, 0.25, 1);
}

/* Skeleton loading */
.trek-gallery-section .skeleton-card {
    height: clamp(380px, 48vh, 520px);
    border-radius: 32px;
    border: none;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.06);
}

.trek-gallery-section .skeleton-card .skeleton-image {
    height: 100%;
    border-radius: 32px;
}

/* Empty / error states */
.trek-gallery-section .no-results,
.trek-gallery-section .data-state {
    font-family: 'Poppins', sans-serif;
    border: none;
    border-radius: 32px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.06);
    padding: 56px 32px;
    max-width: 520px;
    margin: 0 auto;
}

@media (min-width: 1024px) {
    .trek-gallery-section {
        padding: 110px 0 130px;
    }

    .trek-gallery__swiper .swiper-slide {
        width: 300px;
    }

    .trek-gallery__swiper {
        padding: 36px 0 44px;
    }
}

@media (min-width: 1280px) {
    .trek-gallery__swiper .swiper-slide {
        width: 320px;
    }
}

@media (max-width: 639px) {
    .trek-gallery-section {
        padding: 72px 0 88px;
    }

    .trek-gallery-header {
        margin-bottom: 40px;
    }

    .trek-gallery__shell {
        border-radius: 28px;
        padding: 24px 0 20px;
    }

    .trek-gallery-section .tour-card--gallery,
    .trek-gallery-section .swiper-slide-active .tour-card--gallery {
        height: clamp(360px, 62vh, 480px);
        border-radius: 28px;
    }

    .trek-gallery-section .tour-card--gallery .tour-image-container,
    .trek-gallery-section .swiper-slide-active .tour-card--gallery .tour-image-container {
        border-radius: 28px;
    }

    .trek-gallery-section .swiper-slide-active .tour-card--gallery .tour-image-container {
        border-radius: 28px 28px 0 0;
    }

    .trek-gallery-section .swiper-slide-active .tour-card--gallery .tour-details {
        padding: 18px 18px 22px;
    }

    .trek-gallery-section .tour-card--gallery .tour-meta-grid {
        grid-template-columns: 1fr;
    }

    .trek-gallery-section .tour-card--gallery .tour-price-booking {
        flex-direction: column;
        align-items: stretch;
    }

    .trek-gallery-section .tour-card--gallery .tour-book-btn {
        width: 100%;
        text-align: center;
    }
}

@media (prefers-reduced-motion: reduce) {
    .trek-gallery-section .tour-card--gallery,
    .trek-gallery-section .tour-card--gallery .tour-image-container,
    .trek-gallery-section .tour-card--gallery .tour-image-container img,
    .trek-gallery-section .tour-card--gallery .tour-details,
    .trek-gallery-section .tour-card--gallery .tour-book-btn,
    .trek-gallery__track-fill,
    .trek-gallery__swiper .swiper-slide {
        transition: none;
    }
}
