/* Photo Gallery Pro - CSS com alta especificidade para evitar conflitos de tema */

.pgp-gallery-wrap,
.pgp-gallery-wrap * {
    box-sizing: border-box;
}

.pgp-gallery-wrap {
    width: 100% !important;
    display: block !important;
    float: none !important;
}

/* ── Imagem principal ── */
.pgp-gallery-wrap .pgp-featured-box {
    position: relative !important;
    width: 100% !important;
    display: block !important;
    background: #111 !important;
    overflow: hidden !important;
    line-height: 0 !important;
    margin: 0 !important;
    padding: 0 !important;
}

.pgp-gallery-wrap .pgp-featured-img {
    width: 100% !important;
    height: auto !important;
    max-height: 520px !important;
    object-fit: cover !important;
    display: block !important;
    float: none !important;
    margin: 0 !important;
    padding: 0 !important;
    transition: opacity 0.25s !important;
    cursor: zoom-in !important;
}

.pgp-gallery-wrap .pgp-featured-img.pgp-fading {
    opacity: 0.3 !important;
}

.pgp-gallery-wrap .pgp-counter {
    position: absolute !important;
    bottom: 12px !important;
    right: 12px !important;
    top: auto !important;
    left: auto !important;
    background: rgba(0,0,0,0.55) !important;
    color: #fff !important;
    font-size: 13px !important;
    line-height: 1 !important;
    padding: 5px 12px !important;
    border-radius: 20px !important;
    pointer-events: none !important;
    display: block !important;
}

.pgp-gallery-wrap .pgp-fullscreen-btn {
    position: absolute !important;
    top: 10px !important;
    right: 10px !important;
    background: rgba(0,0,0,0.5) !important;
    border: none !important;
    border-radius: 5px !important;
    width: 36px !important;
    height: 36px !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    color: #fff !important;
    cursor: pointer !important;
    opacity: 0 !important;
    transition: opacity 0.2s !important;
    padding: 0 !important;
    margin: 0 !important;
    float: none !important;
}

.pgp-gallery-wrap .pgp-featured-box:hover .pgp-fullscreen-btn {
    opacity: 1 !important;
}

.pgp-gallery-wrap .pgp-featured-prev,
.pgp-gallery-wrap .pgp-featured-next {
    position: absolute !important;
    top: 50% !important;
    transform: translateY(-50%) !important;
    background: rgba(0,0,0,0.45) !important;
    border: 1px solid rgba(255,255,255,0.2) !important;
    border-radius: 50% !important;
    width: 42px !important;
    height: 42px !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    color: #fff !important;
    cursor: pointer !important;
    opacity: 0 !important;
    transition: opacity 0.2s !important;
    padding: 0 !important;
    margin: 0 !important;
    float: none !important;
}

.pgp-gallery-wrap .pgp-featured-prev { left: 12px !important; right: auto !important; }
.pgp-gallery-wrap .pgp-featured-next { right: 12px !important; left: auto !important; }

.pgp-gallery-wrap .pgp-featured-box:hover .pgp-featured-prev,
.pgp-gallery-wrap .pgp-featured-box:hover .pgp-featured-next {
    opacity: 1 !important;
}

.pgp-gallery-wrap .pgp-main-caption {
    display: block !important;
    width: 100% !important;
    background: #1c1c1c !important;
    color: rgba(255,255,255,0.65) !important;
    font-size: 13px !important;
    text-align: center !important;
    padding: 7px 14px !important;
    min-height: 32px !important;
    line-height: 18px !important;
    margin: 0 !important;
    float: none !important;
}

.pgp-gallery-wrap .pgp-caption-empty {
    min-height: 0 !important;
    padding: 0 !important;
}

/* ══════════════════════════════════════════
   FAIXA DE MINIATURAS — HORIZONTAL FORÇADO
   ══════════════════════════════════════════ */

.pgp-gallery-wrap .pgp-strip-bar {
    display: flex !important;
    flex-direction: row !important;
    flex-wrap: nowrap !important;
    align-items: center !important;
    justify-content: flex-start !important;
    background: #111 !important;
    padding: 8px 6px !important;
    gap: 4px !important;
    width: 100% !important;
    margin: 0 !important;
    overflow: hidden !important;
    float: none !important;
    clear: both !important;
}

.pgp-gallery-wrap .pgp-strip-prev-btn,
.pgp-gallery-wrap .pgp-strip-next-btn {
    flex: 0 0 30px !important;
    width: 30px !important;
    height: 30px !important;
    min-width: 30px !important;
    max-width: 30px !important;
    background: rgba(255,255,255,0.08) !important;
    border: none !important;
    border-radius: 4px !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    color: rgba(255,255,255,0.55) !important;
    cursor: pointer !important;
    padding: 0 !important;
    margin: 0 !important;
    float: none !important;
}

.pgp-gallery-wrap .pgp-strip-viewport {
    flex: 1 1 auto !important;
    min-width: 0 !important;
    overflow: hidden !important;
    display: block !important;
    height: 60px !important;
}

.pgp-gallery-wrap .pgp-strip-track {
    display: flex !important;
    flex-direction: row !important;
    flex-wrap: nowrap !important;
    align-items: center !important;
    gap: 6px !important;
    height: 100% !important;
    transition: transform 0.35s cubic-bezier(.4,0,.2,1) !important;
    will-change: transform !important;
    padding: 0 !important;
    margin: 0 !important;
    list-style: none !important;
}

.pgp-gallery-wrap .pgp-sthumb {
    flex: 0 0 76px !important;
    width: 76px !important;
    min-width: 76px !important;
    max-width: 76px !important;
    height: 56px !important;
    min-height: 56px !important;
    border-radius: 3px !important;
    overflow: hidden !important;
    cursor: pointer !important;
    border: 2px solid transparent !important;
    opacity: 0.5 !important;
    transition: opacity 0.2s, border-color 0.2s, transform 0.2s !important;
    display: block !important;
    float: none !important;
    margin: 0 !important;
    padding: 0 !important;
}

.pgp-gallery-wrap .pgp-sthumb img {
    width: 100% !important;
    height: 100% !important;
    object-fit: cover !important;
    display: block !important;
    float: none !important;
    margin: 0 !important;
    padding: 0 !important;
}

.pgp-gallery-wrap .pgp-sthumb:hover {
    opacity: 0.85 !important;
    transform: translateY(-2px) !important;
}

.pgp-gallery-wrap .pgp-sthumb.active {
    opacity: 1 !important;
    border-color: #fff !important;
    transform: translateY(-2px) !important;
}

/* ── Lightbox ── */
.pgp-lightbox {
    position: fixed !important;
    top: 0 !important; right: 0 !important; bottom: 0 !important; left: 0 !important;
    z-index: 999999 !important;
    display: none;
}

.pgp-lightbox .pgp-lb-bg {
    position: absolute !important;
    inset: 0 !important;
    background: rgba(8,8,8,0.96) !important;
}

.pgp-lightbox .pgp-lb-wrap {
    position: relative !important;
    z-index: 1 !important;
    width: 100% !important;
    height: 100% !important;
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    justify-content: center !important;
    padding: 20px !important;
}

.pgp-lightbox .pgp-lb-close {
    position: absolute !important;
    top: 14px !important; right: 14px !important;
    background: rgba(255,255,255,0.12) !important;
    border: none !important;
    border-radius: 50% !important;
    width: 42px !important; height: 42px !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    color: #fff !important;
    cursor: pointer !important;
    padding: 0 !important;
    z-index: 2 !important;
}

.pgp-lightbox .pgp-lb-count {
    position: absolute !important;
    top: 18px !important;
    left: 50% !important;
    transform: translateX(-50%) !important;
    color: rgba(255,255,255,0.65) !important;
    font-size: 13px !important;
    background: rgba(0,0,0,0.4) !important;
    padding: 4px 14px !important;
    border-radius: 20px !important;
    white-space: nowrap !important;
}

.pgp-lightbox .pgp-lb-stage {
    display: flex !important;
    flex-direction: row !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 14px !important;
    flex: 1 !important;
    width: 100% !important;
    max-height: calc(100vh - 190px) !important;
    min-height: 0 !important;
}

.pgp-lightbox .pgp-lb-imgwrap {
    position: relative !important;
    flex: 1 !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    min-height: 0 !important;
    max-height: 100% !important;
}

.pgp-lightbox .pgp-lb-img {
    max-width: 100% !important;
    max-height: calc(100vh - 190px) !important;
    object-fit: contain !important;
    display: block !important;
    border-radius: 3px !important;
    transition: opacity 0.2s !important;
}

.pgp-lightbox .pgp-lb-img.pgp-loading { opacity: 0 !important; }

.pgp-lightbox .pgp-lb-spin {
    position: absolute !important;
    inset: 0 !important;
    display: none !important;
    align-items: center !important;
    justify-content: center !important;
}
.pgp-lightbox .pgp-lb-spin.on { display: flex !important; }
.pgp-lightbox .pgp-lb-spin div {
    width: 36px !important; height: 36px !important;
    border: 3px solid rgba(255,255,255,0.15) !important;
    border-top-color: #fff !important;
    border-radius: 50% !important;
    animation: pgp-spin 0.7s linear infinite !important;
}
@keyframes pgp-spin { to { transform: rotate(360deg); } }

.pgp-lightbox .pgp-lb-prev,
.pgp-lightbox .pgp-lb-next {
    flex: 0 0 50px !important;
    width: 50px !important; height: 50px !important;
    background: rgba(255,255,255,0.1) !important;
    border: 1px solid rgba(255,255,255,0.15) !important;
    border-radius: 50% !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    color: #fff !important;
    cursor: pointer !important;
    padding: 0 !important;
    margin: 0 !important;
    float: none !important;
}

.pgp-lightbox .pgp-lb-cap {
    color: rgba(255,255,255,0.65) !important;
    font-size: 13px !important;
    text-align: center !important;
    min-height: 20px !important;
    padding: 6px 20px 0 !important;
    max-width: 600px !important;
    width: 100% !important;
    display: block !important;
}

.pgp-lightbox .pgp-lb-thumbs {
    display: flex !important;
    flex-direction: row !important;
    flex-wrap: nowrap !important;
    gap: 7px !important;
    overflow-x: auto !important;
    padding: 10px 0 4px !important;
    max-width: 860px !important;
    width: 100% !important;
    justify-content: center !important;
    scrollbar-width: thin !important;
    scrollbar-color: rgba(255,255,255,0.2) transparent !important;
    float: none !important;
    margin: 0 auto !important;
}

.pgp-lightbox .pgp-lb-th {
    flex: 0 0 66px !important;
    width: 66px !important; height: 48px !important;
    border-radius: 3px !important;
    overflow: hidden !important;
    cursor: pointer !important;
    opacity: 0.45 !important;
    border: 2px solid transparent !important;
    transition: opacity 0.2s, transform 0.2s, border-color 0.2s !important;
    display: block !important;
    float: none !important;
}
.pgp-lightbox .pgp-lb-th img {
    width: 100% !important; height: 100% !important;
    object-fit: cover !important; display: block !important;
}
.pgp-lightbox .pgp-lb-th:hover { opacity: 0.8 !important; transform: translateY(-2px) !important; }
.pgp-lightbox .pgp-lb-th.active { opacity: 1 !important; border-color: #fff !important; transform: translateY(-2px) !important; }

.pgp-lightbox.pgp-on { animation: pgp-fadein 0.2s ease !important; }
@keyframes pgp-fadein { from { opacity: 0; } to { opacity: 1; } }

@media (max-width: 600px) {
    .pgp-gallery-wrap .pgp-featured-img { max-height: 280px !important; }
    .pgp-gallery-wrap .pgp-sthumb { flex: 0 0 58px !important; width: 58px !important; min-width: 58px !important; height: 44px !important; }
    .pgp-gallery-wrap .pgp-strip-viewport { height: 48px !important; }
    .pgp-lightbox .pgp-lb-prev, .pgp-lightbox .pgp-lb-next { flex: 0 0 38px !important; width: 38px !important; height: 38px !important; }
}
