.gallery .section-head {
    max-width: 760px;
    margin: 0 auto 42px;
    text-align: center;
}

.gallery .section-title {
    margin: 0;
    font-family: var(--font-heading);
    font-size: clamp(1.9rem, 3vw, 3rem);
    line-height: 1.1;
    color: var(--heading);
}

.gallery-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 24px;
}

.gallery-card {
    margin: 0;
    overflow: hidden;
    border-radius: var(--radius-lg);
    background: var(--surface);
    box-shadow: var(--shadow-sm);
}

.gallery-card__image {
    display: block;
    width: 100%;
    height: 100%;
    min-height: 280px;
    max-height: 380px;
    object-fit: cover;
    transition: transform var(--transition);
}

.gallery-card:hover .gallery-card__image {
    transform: scale(1.04);
}

@media (max-width: 991px) {
    .gallery-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 767px) {
    .gallery .section-head {
        margin-bottom: 28px;
    }

    .gallery-grid {
        grid-template-columns: 1fr;
        gap: 18px;
    }

    .gallery-card__image {
        min-height: 240px;
        max-height: 320px;
    }
}

.gallery .section-head {
    max-width: 760px;
    margin: 0 auto 42px;
    text-align: center;
}

.gallery .section-title {
    margin: 0;
    font-family: var(--font-heading);
    font-size: clamp(1.9rem, 3vw, 3rem);
    line-height: 1.1;
    color: var(--heading);
}

.gallery-card {
    margin: 0;
    overflow: hidden;
    border-radius: var(--radius-lg);
    background: var(--surface);
    box-shadow: var(--shadow-sm);
}

.gallery-card__image {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform var(--transition);
}

.gallery-card:hover .gallery-card__image {
    transform: scale(1.04);
}

/* =========================
   GRID
========================= */

.gallery--grid .gallery-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 24px;
}

.gallery--grid .gallery-card__image {
    min-height: 280px;
    max-height: 380px;
}

/* =========================
   SLIDE
========================= */

.gallery--slide .gallery-slider {
    overflow-x: auto;
    overflow-y: hidden;
    padding-bottom: 8px;
    scroll-behavior: smooth;
    -webkit-overflow-scrolling: touch;
}

.gallery--slide .gallery-track {
    display: grid;
    grid-auto-flow: column;
    grid-auto-columns: minmax(280px, 360px);
    gap: 24px;
}

.gallery--slide .gallery-card {
    scroll-snap-align: start;
}

.gallery--slide .gallery-slider {
    scroll-snap-type: x mandatory;
}

.gallery--slide .gallery-card__image {
    min-height: 360px;
    max-height: 420px;
}

.gallery--slide .gallery-slider::-webkit-scrollbar {
    height: 8px;
}

.gallery--slide .gallery-slider::-webkit-scrollbar-thumb {
    background: rgba(17, 17, 17, 0.18);
    border-radius: 999px;
}

.gallery--slide .gallery-slider::-webkit-scrollbar-track {
    background: rgba(17, 17, 17, 0.06);
    border-radius: 999px;
}

/* =========================
   RESPONSIVE
========================= */

@media (max-width: 991px) {
    .gallery--grid .gallery-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .gallery--slide .gallery-track {
        grid-auto-columns: minmax(240px, 320px);
    }

    .gallery--slide .gallery-card__image {
        min-height: 300px;
        max-height: 360px;
    }
}

@media (max-width: 767px) {
    .gallery .section-head {
        margin-bottom: 28px;
    }

    .gallery--grid .gallery-grid {
        grid-template-columns: 1fr;
        gap: 18px;
    }

    .gallery--grid .gallery-card__image {
        min-height: 240px;
        max-height: 320px;
    }

    .gallery--slide .gallery-track {
        grid-auto-columns: 84%;
        gap: 18px;
    }

    .gallery--slide .gallery-card__image {
        min-height: 260px;
        max-height: 320px;
    }
}



.gallery {
    background-color: var(--bg);
}

.gallery__container {
    position: relative;
}

.gallery__header {
    max-width: 720px;
    margin: 0 auto 38px;
    text-align: center;
}

.gallery__header .section-title {
    color: var(--heading);
    margin-bottom: 12px;
}

.gallery__header .section-text {
    color: var(--text-muted);
}

.gallery__eight {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 18px;
}

.gallery__item {
    margin: 0;
    overflow: hidden;
    border-radius: var(--radius-lg);
    background: var(--surface);
    box-shadow: var(--shadow-sm);
    border: 1px solid var(--border);
    position: relative;
}

.gallery__item::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(
        180deg,
        rgba(255, 255, 255, 0) 55%,
        rgba(125, 79, 88, 0.06) 100%
    );
    pointer-events: none;
}

.gallery__item img {
    display: block;
    width: 100%;
    aspect-ratio: 1 / 1;
    object-fit: cover;
    transition: transform var(--transition);
}

.gallery__item:hover img {
    transform: scale(1.045);
}

/* Tablette */
@media (max-width: 992px) {
    .gallery__eight {
        grid-template-columns: repeat(3, 1fr);
        gap: 16px;
    }
}

/* Mobile */
@media (max-width: 768px) {
    .gallery {
        padding: 0;
    }

    .gallery__header {
        margin-bottom: 24px;
    }

    .gallery__eight {
        grid-template-columns: repeat(2, 1fr);
        gap: 12px;
    }

    .gallery__item {
        border-radius: var(--radius);
    }
}

/* Petit mobile */
@media (max-width: 420px) {
    .gallery__eight {
        grid-template-columns: repeat(2, 1fr);
        gap: 10px;
    }

    .gallery__item img {
        aspect-ratio: 0.9 / 1;
    }
}