/* --- 1. BANDA PESTE IMAGINE (În Articol) --- */

.post-thumbnail.position-relative {
    position: relative !important;
    display: block !important;
}

.featured-gallery-strip {
    position: absolute !important;
    right: 15px !important;
    bottom: 15px !important;
    display: flex !important;
    gap: 10px !important;
    z-index: 99 !important;
    line-height: normal !important;
}

.fg-thumb {
    display: block !important;
    width: 140px !important;
    height: 110px !important;
    border: 2px solid #ffffff !important;
    border-radius: 8px !important;
    overflow: hidden !important;
    position: relative !important;
    box-shadow: 0 4px 12px rgba(0,0,0,0.4) !important;
    transition: transform 0.2s ease !important;
    text-decoration: none !important;
}

.fg-thumb:hover {
    transform: translateY(-3px) !important;
}

.fg-thumb img {
    width: 100% !important;
    height: 100% !important;
    object-fit: cover !important;
    display: block !important;
}

.fg-thumb--more::after {
    content: "" !important;
    position: absolute !important;
    inset: 0 !important;
    background: rgba(0, 0, 0, 0.6) !important;
    z-index: 1 !important;
}

.fg-more {
    position: absolute !important;
    inset: 0 !important;
    color: #ffffff !important;
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    justify-content: center !important;
    text-align: center !important;
    z-index: 2 !important;
}

.fg-more i {
    font-style: normal !important;
    font-size: 16px !important;
    font-weight: 700 !important;
    display: block !important;
}

.fg-more b {
    font-size: 11px !important;
    text-transform: uppercase !important;
    font-weight: 600 !important;
}

/* --- 2. CARDUL PENTRU POSTĂRI VECHI (În Text) --- */

.ego-gal-shortcode-card {
    margin: 30px auto !important;
    max-width: 100% !important;
    position: relative !important;
    border-radius: 12px !important;
    overflow: hidden !important;
}

.ego-gal-card-link img {
    width: 100% !important;
    height: 350px !important;
    object-fit: cover !important;
}

.ego-gal-card-overlay {
    position: absolute !important;
    inset: 0 !important;
    background: rgba(0,0,0,0.3) !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
}

.ego-gal-btn {
    background: #e50914 !important;
    color: #fff !important;
    padding: 14px 28px !important;
    border-radius: 50px !important;
    font-weight: bold !important;
    font-size: 16px !important;
    box-shadow: 0 4px 15px rgba(0,0,0,0.4) !important;
    text-decoration: none !important;
}

/* --- 3. PAGINA DE GALERIE (Viewer-ul Negru) --- */

.ego-gal-viewer {
    background: #000 !important;
    min-height: 100vh !important;
    width: 100% !important;
    position: relative !important;
    z-index: 9999 !important;
    padding: 20px 0 !important;
}

.ego-gal-title {
    font-size: 1.5rem !important;
    text-align: center !important;
    margin-bottom: 20px !important;
    color: #fff !important;
}

/* Containerul care centrează totul */
.ego-gal-image-holder {
    position: relative !important;
    display: flex !important;
    justify-content: center !important;
    align-items: center !important;
    width: 100% !important;
    text-align: center !important;
}

/* Wrapperul care "măsoară" imaginea pentru a ancora săgețile de ea */
.ego-gal-inner-wrap {
    position: relative !important;
    display: inline-block !important;
    max-width: 90% !important;
}

.ego-gal-inner-wrap img {
    max-width: 100% !important;
    max-height: 80vh !important;
    height: auto !important;
    display: block !important;
    margin: 0 auto !important;
}

/* Săgețile de navigație */
.ego-gal-nav-arrow {
    position: absolute !important;
    top: 50% !important;
    transform: translateY(-50%) !important;
    background: rgba(0, 0, 0, 0.5) !important;
    color: #ffffff !important;
    width: 60px !important;
    height: 60px !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    text-decoration: none !important;
    font-size: 40px !important;
    border-radius: 50% !important;
    z-index: 1000 !important;
    transition: all 0.2s ease !important;
}

.ego-gal-nav-arrow:hover {
    background: rgba(255, 193, 7, 0.9) !important;
    color: #000 !important;
}

.ego-gal-prev {
    left: -80px !important; /* Scoate săgeata în afara imaginii pe desktop */
}

.ego-gal-next {
    right: -80px !important; /* Scoate săgeata în afara imaginii pe desktop */
}

/* Grila de miniaturi de jos */
.ego-gal-thumbs-grid {
    display: flex !important;
    flex-wrap: wrap !important;
    justify-content: center !important;
    gap: 8px !important;
    margin-top: 20px !important;
    padding: 0 15px !important;
}

.ego-gal-thumb-link img {
    width: 65px !important;
    height: 65px !important;
    object-fit: cover !important;
    border-radius: 4px !important;
    opacity: 0.6 !important;
}

.ego-gal-thumb-link.is-active img {
    opacity: 1 !important;
    border: 2px solid #ffc107 !important;
}

/* --- RESPONSIVE (Mobil) --- */

@media (max-width: 1200px) {
    /* Pe ecrane medii, aducem săgețile peste imagine să nu iasă din ecran */
    .ego-gal-prev { left: 10px !important; }
    .ego-gal-next { right: 10px !important; }
}

@media (max-width: 768px) {
    .fg-thumb {
        width: 80px !important;
        height: 65px !important;
    }
    .fg-more i { font-size: 13px !important; }
    .fg-more b { font-size: 8px !important; }
    
    .ego-gal-card-link img { height: 250px !important; }

    .ego-gal-nav-arrow {
        width: 45px !important;
        height: 45px !important;
        font-size: 25px !important;
    }
}