/* ==========================================================================
   Section: instagram-feed (Figma 1:2305)
   ========================================================================== */

.sec-instagram-feed {
    padding: 60px 0;
    background: var(--c-white);
    overflow: hidden;
}

.ig__inner {
    max-width: var(--content-max);
    margin-inline: auto;
    padding-inline: var(--pad-x);
}

/* Head: centered title + text */
.ig__head {
    max-width: 768px;
    margin: 0 auto 60px;
    text-align: center;
}

.ig__title {
    margin: 0;
    font-family: 'Roboto', var(--font-sans);
    font-weight: 700;
    font-size: clamp(32px, 3.4vw, 48px);
    line-height: 1.2;
    color: var(--c-black);
}

.ig__text {
    margin: 16px 0 0;
    font-size: 18px;
    line-height: 1.5;
    color: var(--c-text);
}

/* The one full-viewport-width carousel on the site: fixed-width slides,
   centered on the screen, cut by BOTH viewport edges */
.ig__swiper {
    width: 100%;
    /* Reserved track height: 450px active media + 16px gap + 85px product
       slot. Mid-transition no tile is at its full 450px, so without this
       the track would shrink for a moment and the nav bar would jump. */
    height: 551px;
}

/* Side tiles center vertically against the taller active one */
.ig__swiper .swiper-wrapper {
    height: 100%;
    align-items: center;
}

/* Instagram tile */
.igcard {
    display: flex;
    flex-direction: column;
    width: 296px;
    height: auto;
}

.igcard__media {
    position: relative;
    display: block;
    overflow: hidden;
    border-radius: 10px;
    background: #dbdbdb;
}

.igcard__img {
    display: block;
    width: 100%;
    height: 355px;
    object-fit: cover;
    transition: height 0.3s ease;
}

/* Active (centered) tile is taller, as designed */
.igcard.swiper-slide-active .igcard__img {
    height: 450px;
}

/* Play badge for VIDEO posts */
.igcard__play {
    position: absolute;
    top: 50%;
    left: 50%;
    width: 64px;
    height: 64px;
    transform: translate(-50%, -50%);
    background: rgba(23, 23, 23, 0.4);
    border-radius: 50%;
    pointer-events: none;
}

.igcard__play::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 54%;
    width: 0;
    height: 0;
    transform: translate(-50%, -50%);
    border-style: solid;
    border-width: 12px 0 12px 20px;
    border-color: transparent transparent transparent #fff;
}

/* Mini product block under a tile. Fixed height (thumbnail-driven) and
   always present — an empty slot on product-less tiles keeps every
   slide equally tall, so the centered images share one axis. */
.igcard__product {
    display: flex;
    align-items: center;
    gap: 16px;
    width: 100%;
    height: 85px;
    margin-top: 16px;
    color: var(--c-black);
}

.igcard__product-img {
    flex-shrink: 0;
    width: 80px;
    height: 85px;
    object-fit: cover;
    border-radius: 10px;
}

.igcard__product-info {
    flex: 1 1 0;
    min-width: 0;
    display: flex;
    flex-direction: column;
}

.igcard__product-name {
    font-family: 'Roboto', var(--font-sans);
    font-size: 18px;
    font-weight: 600;
    line-height: 1.5;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.igcard__product:hover .igcard__product-name,
.igcard__product:focus-visible .igcard__product-name {
    text-decoration: underline;
    text-underline-position: from-font;
}

.igcard__product-price {
    font-family: 'Roboto', var(--font-sans);
    font-size: 20px;
    font-weight: 600;
    line-height: 1.5;
}

.igcard__product-price del {
    margin-right: 8px;
    font-size: 16px;
    color: #969696;
}

.igcard__product-price ins {
    text-decoration: none;
}

.igcard__product .udi-icon {
    flex-shrink: 0;
}

/* Controls bar */
.ig__bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-top: 48px;
}

.ig__dots {
    display: flex;
    gap: 8px;
}

/* Custom dots (one per REAL post — slides are duplicated for loop mode) */
.ig__dot {
    width: 8px;
    height: 8px;
    padding: 0;
    border-radius: 50%;
    background: #000;
    opacity: 0.2;
    cursor: pointer;
    transition: opacity 0.2s ease;
}

.ig__dot.is-active {
    opacity: 1;
}

.ig__nav {
    display: flex;
    gap: 16px;
}

.ig__arrow {
    display: grid;
    place-items: center;
    width: 48px;
    height: 48px;
    background: var(--c-white);
    border: 1px solid var(--c-black);
    border-radius: 50%;
    color: var(--c-black);
    cursor: pointer;
    transition: background 0.15s ease, color 0.15s ease, opacity 0.15s ease;
}

.ig__arrow:hover,
.ig__arrow:focus-visible {
    background: var(--c-black);
    color: var(--c-white);
}

.ig__arrow.swiper-button-disabled {
    opacity: 0.3;
    pointer-events: none;
}

/* --------------------------------------------------------------------------
   Responsive
   -------------------------------------------------------------------------- */
@media (max-width: 767px) {
    .sec-instagram-feed {
        padding: 40px 0;
    }

    .ig__head {
        margin-bottom: 32px;
    }

    .ig__text {
        font-size: 16px;
    }

    .ig__bar {
        margin-top: 32px;
    }
}
