/* ==========================================================================
   Reel Slider — 9:16 vertical video/image cards in a horizontal slider
   ========================================================================== */

.reel-section {
    position: relative;
    background-color: #fff;
    color: #fff;
    padding: 2em 0 1.5em;
    margin: 0 auto 7em;
    width: 100%;
}

/* Dark variant */
.reel-section--dark {
    background-color: #111;
    color: #111;
}

.reel-section--dark .header__main,
.reel-section--dark .header__sub,
.reel-section--dark .caption {
    color: #fff;
}

.reel-section--dark .reel-nav--prev,
.reel-section--dark .reel-nav--next {
    background: rgba(255, 255, 255, 0.12);
}

.reel-section--dark .reel-nav--prev:hover,
.reel-section--dark .reel-nav--next:hover {
    background: rgba(255, 255, 255, 0.25);
}

.reel-section--dark .reel-nav--prev svg,
.reel-section--dark .reel-nav--next svg {
    fill: #fff;
}

.reel-section .header {
    padding-left: 5%;
    padding-right: 5%;
    margin-bottom: 1em;
}

.reel-section .caption {
    padding-left: 5%;
    padding-right: 5%;
    margin-bottom: 1em;
}

/* Swiper overrides for reel layout */
.reel-section .swiper {
    padding: 4px 5%;
    overflow: hidden;
    height: 399px;
}

.reel-section .swiper-wrapper {
    height: 100%;
}

/* Individual reel card — 9:16 portrait (standard reel format) */
.reel-card {
    width: 220px;
    height: 391px;
    flex-shrink: 0;
    border-radius: 0;
    overflow: hidden;
    position: relative;
    background-color: #000;
    cursor: pointer;
    transition: transform 300ms ease-out;
}

/* Rounded corners variant */
.reel-section--rounded .reel-card {
    border-radius: 12px;
}

.reel-card:hover {
    transform: translateY(-3px);
}

.reel-card video,
.reel-card img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: block;
    object-fit: cover;
}

/* Instagram handle bar */
.reel-handle {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 10px 12px;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.6), transparent);
    text-decoration: none;
    z-index: 4;
}

.reel-handle__icon {
    width: 16px;
    height: 16px;
    fill: #fff;
    flex-shrink: 0;
}

.reel-handle__name {
    color: #fff;
    font-size: 12px;
    font-weight: 500;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* Sound toggle button — above handle bar, or at bottom when no caption */
.reel-card--no-caption .reel-sound-btn {
    bottom: 12px;
}

.reel-sound-btn {
    position: absolute;
    bottom: 44px;
    right: 12px;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: rgba(0, 0, 0, 0.55);
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 5;
    transition: opacity 200ms ease-out;
    padding: 0;
}

.reel-sound-btn:hover {
    opacity: 0.8;
}

.reel-sound-btn svg {
    width: 18px;
    height: 18px;
    fill: #fff;
}

/* Edge fade overlays */
.reel-fade--left,
.reel-fade--right {
    position: absolute;
    top: 0;
    bottom: 0;
    width: 5%;
    z-index: 2;
    pointer-events: none;
}

.reel-fade--left {
    left: 0;
    background: linear-gradient(to right, currentColor, transparent);
}

.reel-fade--right {
    right: 0;
    background: linear-gradient(to left, currentColor, transparent);
}

/* Navigation arrows */
.reel-nav {
    display: flex;
    gap: 8px;
    justify-content: flex-end;
    padding: 0.75em 5% 0;
}

.reel-nav--prev,
.reel-nav--next {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: rgba(0, 0, 0, 0.08);
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0;
    transition: background 200ms ease-out;
}

.reel-nav--prev:hover,
.reel-nav--next:hover {
    background: rgba(0, 0, 0, 0.15);
}

.reel-nav--prev.swiper-button-disabled,
.reel-nav--next.swiper-button-disabled {
    opacity: 0.3;
    cursor: default;
}

.reel-nav--prev svg,
.reel-nav--next svg {
    width: 20px;
    height: 20px;
    fill: #333;
}

/* Responsive breakpoints */
@media (max-width: 639px) {
    .reel-section {
        margin-bottom: 4em;
        padding: 1.5em 0 1em;
    }

    .reel-card {
        width: 160px;
        height: 284px;
    }

    .reel-section .swiper {
        padding-left: 4%;
        padding-right: 4%;
        height: 292px;
    }

    .reel-fade--left,
    .reel-fade--right {
        width: 4%;
    }
}

@media (min-width: 1280px) {
    .reel-card {
        width: 260px;
        height: 462px;
    }

    .reel-section .swiper {
        height: 470px;
    }
}
