/**
 * APC Instagram Feed — Swiper slider
 */

.igf-swiper-wrap {
    display: flex;
    align-items: center;
    gap: 12px;
}

.igf-swiper-wrap .swiper {
    flex: 1;
    min-width: 0;
}

.igf-nav-prev,
.igf-nav-next {
    flex-shrink: 0;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    border: 1px solid #ddd;
    background: #fff;
    cursor: pointer;
    font-size: 1rem;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s;
    color: #333;
}

.igf-nav-prev:hover,
.igf-nav-next:hover {
    background: #f0f0f0;
}

.igf-nav-prev:disabled,
.igf-nav-next:disabled {
    opacity: 0.3;
    cursor: default;
}

.igf-item a {
    display: block;
    text-decoration: none;
}

/* Hauteur fixe identique pour tous les types */
.igf-thumb {
    position: relative;
    width: 100%;
    aspect-ratio: 4 / 5; /* ratio Instagram portrait standard — essaie 9/16 si tu veux encore plus haut */
    height: auto;        /* annule tout height fixe résiduel */
    overflow: hidden;
}

.igf-thumb img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.3s ease, opacity 0.3s ease;
}

/* Vidéo : même comportement que l'image */
.igf-video-thumb video {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.igf-video-overlay-link {
    position: absolute;
    inset: 0;
    z-index: 2;
}

/* Hover sur image uniquement (pas sur vidéo) */
.igf-item a:hover .igf-thumb img,
.igf-item a:focus .igf-thumb img {
    transform: scale(1.05);
    opacity: 0.85;
}

.igf-item a:hover .igf-thumb img,
.igf-item a:focus .igf-thumb img {
    transform: scale(1.05);
    opacity: 0.85;
}

/* Icône lecture vidéo */
.igf-play-icon {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-size: 2.5rem;
    color: #fff;
    text-shadow: 0 2px 6px rgba(0, 0, 0, 0.5);
    pointer-events: none;
    line-height: 1;
}

/* Icône carrousel */
.igf-carousel-icon {
    position: absolute;
    top: 8px;
    right: 8px;
    font-size: 1.25rem;
    color: #fff;
    text-shadow: 0 1px 4px rgba(0, 0, 0, 0.6);
    pointer-events: none;
    line-height: 1;
}

/* Date accessible */
.igf-date.screen-reader-text {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip: rect(1px, 1px, 1px, 1px);
    white-space: nowrap;
}

/* États */
.igf-error {
    color: #dc3232;
    border-left: 4px solid #dc3232;
    padding: 8px 12px;
    background: #fef0f0;
}

.igf-empty {
    color: #666;
    font-style: italic;
}
