/* ===================================================================
   Gallery Page – Page Header + Tabs + Full-Width Masonry + Lightbox
   =================================================================== */

/* ─── Page Header ──────────────────────────────────────────────────── */
.gp-page-header {
    background: linear-gradient(135deg, var(--title-color, #1a1a2e) 0%, #2d1520 60%, var(--theme-color, #980d1a) 100%);
    padding: 100px 0 40px;
    position: relative;
    overflow: hidden;
}

.gp-page-header::before {
    content: '';
    position: absolute;
    top: -40%;
    right: -10%;
    width: 500px;
    height: 500px;
    background: radial-gradient(circle, rgba(255,255,255,0.04) 0%, transparent 70%);
    border-radius: 50%;
    pointer-events: none;
}

.gp-page-header__inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 12px;
}

.gp-page-header__title {
    font-family: var(--title-font, 'Poppins', sans-serif);
    font-size: 42px;
    font-weight: 800;
    color: #fff;
    margin: 0;
    letter-spacing: 0.5px;
}

.gp-page-header__breadcrumb {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    gap: 8px;
    font-size: 14px;
}

.gp-page-header__breadcrumb li {
    color: rgba(255,255,255,0.6);
}

.gp-page-header__breadcrumb li + li::before {
    content: '/';
    margin-right: 8px;
    color: rgba(255,255,255,0.3);
}

.gp-page-header__breadcrumb a {
    color: rgba(255,255,255,0.85);
    text-decoration: none;
    font-weight: 500;
    transition: color 0.2s;
}

.gp-page-header__breadcrumb a:hover {
    color: #fff;
}

/* ─── Gallery Section ──────────────────────────────────────────────── */
.gp-gallery {
    padding: 0;
    background: #fff;
}

/* ─── Tabs ─────────────────────────────────────────────────────────── */
.gp-tabs {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 8px;
    padding: 30px 20px;
    background: #f9f8f6;
}

.gp-tab {
    position: relative;
    border: none;
    background: #fff;
    color: var(--title-color, #1a1a2e);
    font-family: var(--title-font, 'Poppins', sans-serif);
    font-size: 15px;
    font-weight: 600;
    padding: 10px 28px;
    border-radius: 50px;
    cursor: pointer;
    box-shadow: 0 2px 8px rgba(0,0,0,0.06);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    letter-spacing: 0.3px;
}

.gp-tab:hover {
    background: var(--theme-color, #980d1a);
    color: #fff;
    box-shadow: 0 4px 16px rgba(152, 13, 26, 0.3);
}

.gp-tab.active {
    background: var(--theme-color, #980d1a);
    color: #fff;
    box-shadow: 0 4px 16px rgba(152, 13, 26, 0.35);
}

/* ─── Masonry Grid (zero-gap, edge-to-edge) ────────────────────────── */
.gp-masonry {
    margin: 0;
    padding: 0;
    background: #fff;
}

.gp-sizer,
.gp-brick {
    width: 20%;
}

.gp-brick--wide {
    width: 40%;
}

/* ─── Brick ────────────────────────────────────────────────────────── */
.gp-brick__link {
    display: block;
    position: relative;
    overflow: hidden;
    border: 2px solid #fff;
}

.gp-brick__link img {
    width: 100%;
    height: 280px;
    object-fit: cover;
    display: block;
    transition: transform 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

.gp-brick--wide .gp-brick__link img {
    height: 280px;
}

.gp-brick--tall .gp-brick__link img {
    height: 400px;
}

/* ─── Hover Overlay ────────────────────────────────────────────────── */
.gp-brick__hover {
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, rgba(152,13,26,0.1) 0%, rgba(152,13,26,0.55) 100%);
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    padding: 20px 12px;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.gp-brick__icon {
    position: relative;
    top: auto;
    left: auto;
    transform: scale(0.7);
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background: rgba(255,255,255,0.95);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.gp-brick__icon i {
    font-size: 18px;
    color: var(--theme-color, #980d1a);
}

/* Hover States */
.gp-brick__link:hover {
    z-index: 2;
}

.gp-brick__link:hover img {
    transform: scale(1.08);
}

.gp-brick__link:hover .gp-brick__hover {
    opacity: 1;
}

.gp-brick__link:hover .gp-brick__icon {
    transform: scale(1);
}

/* ─── Lightbox Caption Styling ─────────────────────────────────────── */
.gp-lightbox .mfp-title {
    text-align: center;
    padding: 16px 20px;
    font-family: var(--title-font, 'Poppins', sans-serif);
}

.gp-lb-caption {
    font-size: 16px;
    font-weight: 500;
    color: #fff;
    line-height: 1.5;
}

.gp-lightbox .mfp-counter {
    font-size: 13px;
    color: rgba(255,255,255,0.7);
    font-weight: 400;
}

.gp-lightbox .mfp-bottom-bar {
    margin-top: -4px;
    padding-top: 12px;
}

.gp-lightbox .mfp-close {
    font-size: 36px;
    opacity: 0.7;
    transition: opacity 0.2s;
}

.gp-lightbox .mfp-close:hover {
    opacity: 1;
}

.gp-lightbox .mfp-arrow {
    opacity: 0.8;
    transition: opacity 0.2s;
}

.gp-lightbox .mfp-arrow:hover {
    opacity: 1;
}

/* ─── Responsive ───────────────────────────────────────────────────── */
@media (max-width: 1399px) {
    .gp-sizer,
    .gp-brick {
        width: 25%;
    }
    .gp-brick--wide {
        width: 50%;
    }
}

@media (max-width: 991px) {
    .gp-page-header {
        padding: 90px 0 30px;
    }

    .gp-page-header__title {
        font-size: 32px;
    }

    .gp-sizer,
    .gp-brick,
    .gp-brick--wide {
        width: 33.333%;
    }

    .gp-brick__link img,
    .gp-brick--wide .gp-brick__link img,
    .gp-brick--tall .gp-brick__link img {
        height: 220px;
    }

    .gp-tabs {
        gap: 8px;
        padding: 24px 16px;
    }

    .gp-tab {
        font-size: 14px;
        padding: 10px 22px;
    }
}

@media (max-width: 575px) {
    .gp-page-header {
        padding: 85px 0 24px;
    }

    .gp-page-header__title {
        font-size: 26px;
    }

    .gp-page-header__inner {
        flex-direction: column;
        align-items: flex-start;
        gap: 8px;
    }

    .gp-sizer,
    .gp-brick,
    .gp-brick--wide {
        width: 50%;
    }

    .gp-brick__link img,
    .gp-brick--wide .gp-brick__link img,
    .gp-brick--tall .gp-brick__link img {
        height: 180px;
    }

    .gp-brick__link {
        border-width: 1px;
    }

    .gp-tabs {
        gap: 6px;
        padding: 20px 12px;
        overflow-x: auto;
        flex-wrap: nowrap;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: none;
        justify-content: flex-start;
    }

    .gp-tabs::-webkit-scrollbar {
        display: none;
    }

    .gp-tab {
        font-size: 13px;
        padding: 8px 18px;
        white-space: nowrap;
        flex-shrink: 0;
    }
}
