/* ==========================================
   GLIGHTBOX CUSTOMIZATION - Federico Leone
   ========================================== */

/* Fix testo sotto le miniature - aumenta contrasto */
.box-item p {
    color: #6f6f6f !important;
    font-size: 12px !important;
    margin: 0 !important;
}

.box-item p:first-of-type {
    color: #3a3a3a !important;
    font-weight: 500 !important;
    line-height: 18px !important;
    padding-top: 7px !important;
}

.box-item p:last-of-type {
    color: #8a8a8a !important;
    padding-top: 0px !important;
    margin-top: -10px !important;
    line-height: 14px !important;
}

/* ==========================================
   LIGHTBOX BACKGROUND - Sfondo bianco
   ========================================== */

/* Sfondo principale del lightbox */
.goverlay {
    background: #ffffff !important;
}

/* Contenitore del video */
.gslide-media {
    background: transparent !important;
}

/* ==========================================
   LIGHTBOX DESCRIZIONE - Font come menu
   ========================================== */

/* Titolo del video */
.gslide-title {
    font-family: 'FuturaPT-Book', Arial, sans-serif !important;
    font-size: 14px !important;
    color: #3a3a3a !important;
    font-weight: 500 !important;
    text-transform: uppercase !important;
    letter-spacing: 0.05em !important;
    margin-bottom: 8px !important;
    text-align: center !important;
}

/* Descrizione del video */
.gslide-desc {
    font-family: 'FuturaPT-Book', Arial, sans-serif !important;
    font-size: 12px !important;
    color: #8a8a8a !important;
    font-weight: 400 !important;
    line-height: 1.6 !important;
    text-align: center !important;
}

/* Container della descrizione - centra tutto */
.gslide-description {
    background: #ffffff !important;
    font-family: 'FuturaPT-Book', Arial, sans-serif !important;
    text-align: center !important;
}

/* Container interno della descrizione GLightbox */
.gdesc-inner {
    text-align: center !important;
}

/* ==========================================
   CONTROLLI LIGHTBOX - Frecce e X NERO PIENO
   ========================================== */

/* Container dei controlli - forza visibilità */
.gclose,
.gnext,
.gprev {
    background: transparent !important;
    border: none !important;
    box-shadow: none !important;
    opacity: 1 !important;
    filter: none !important;
    -webkit-filter: none !important;
}

/* Hover effect */
.gclose:hover,
.gnext:hover,
.gprev:hover {
    background: rgba(0, 0, 0, 0.05) !important;
    opacity: 1 !important;
}

/* SVG delle frecce e X - NERO PIENO */
.gclose svg,
.gnext svg,
.gprev svg {
    stroke: #999 !important;
    stroke-width: 3px !important;
    fill: #999 !important;
    color: #999 !important;
    opacity: 1 !important;
    filter: none !important;
    -webkit-filter: none !important;
}

/* Forza TUTTI gli elementi interni degli SVG */
.gclose svg *,
.gnext svg *,
.gprev svg * {
    stroke: #999 !important;
    fill: #999 !important;
    color: #999 !important;
    opacity: 1 !important;
}

/* Path e line specifici */
.gclose svg path,
.gclose svg line,
.gnext svg path,
.gprev svg path {
    stroke: #999 !important;
    fill: none !important;
    stroke-width: 3px !important;
}

/* Icone GLightbox - forza co.gclose svg,
.gnext svg
lore nero */
.gclose .gclose-icon,
.gnext .gnext-icon,
.gprev .gprev-icon {
    color: #999 !important;
    stroke: #999 !important;
    fill: #999 !important;
}

/* Rimuovi completamente ombre e sfumature dal video container */
.gslide-media,
.ginner-container,
.gslide-inline,
.gslide-external {
    box-shadow: none !important;
    -webkit-box-shadow: none !important;
    -moz-box-shadow: none !important;
}

/* Rimuovi ombre dal contenitore principale */
.gslide {
    box-shadow: none !important;
}

/* Rimuovi ombre dal video player */
.plyr,
.plyr__video-wrapper {
    box-shadow: none !important;
}

/* ==========================================
   PLYR VIDEO PLAYER CUSTOMIZATION
   ========================================== */

/* Colori del player per match con il tuo sito */
.plyr--video {
    background: #fff;
}

.plyr__control--overlaid {
    background: rgba(255, 255, 255, 0.9);
}

.plyr__control--overlaid:hover {
    background: rgba(255, 255, 255, 1);
}

.plyr--full-ui input[type=range] {
    color: #fff;
}

.plyr__control.plyr__tab-focus,
.plyr__control:hover,
.plyr__control[aria-expanded=true] {
    background: rgba(255, 255, 255, 0.2);
}

/* ==========================================
   RESPONSIVE - Mobile fix
   ========================================== */

@media only screen and (max-width: 768px) {
    .gslide-title {
        font-size: 13px !important;
    }
    
    .gslide-desc {
        font-size: 11px !important;
    }
    
    /* Rende i controlli più grandi su mobile */
    .gnext,
    .gprev,
    .gclose {
        width: 50px !important;
        height: 50px !important;
    }
}

/* FORZA BRUTALE - deve vincere su tutto */
.gprev .garrow,
.gnext .garrow,
.gclose .garrow {
    stroke: #999 !important;
}

.glightbox-clean .gprev path,
.glightbox-clean .gnext path,
.glightbox-clean .gclose path {
    fill: #999 !important;
}

.gprev svg, .gnext svg, .gclose svg {
    color: #999 !important;
}

.gprev svg *, .gnext svg *, .gclose svg * {
    stroke: #999 !important;
    color: #999 !important;
}

/* ==========================================
   PLAY ICON SULLE MINIATURE VIDEO - Minimalista
   ========================================== */

/* Container per la miniatura con effetto hover */
.glightbox-video {
    position: relative;
    display: block;
    overflow: hidden;
}

/* Cerchio esterno trasparente con bordo */
.glightbox-video::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 35px;
    height: 35px;
    background: transparent;
    border: 2px solid rgba(255, 255, 255, 0.8);
    border-radius: 50%;
    z-index: 10;
    transition: all 0.3s ease;
    pointer-events: none;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.4);
}

/* Triangolo play dentro il cerchio */
.glightbox-video::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-35%, -50%);
    width: 0;
    height: 0;
    border-style: solid;
    border-width: 8px 0 8px 13px;
    border-color: transparent transparent transparent rgba(255, 255, 255, 0.95);
    z-index: 11;
    transition: all 0.3s ease;
    pointer-events: none;
    filter: drop-shadow(0 1px 3px rgba(0, 0, 0, 0.5));
}

/* Hover effects */
.glightbox-video:hover::before {
    border-color: rgba(255, 255, 255, 1);
    transform: translate(-50%, -50%) scale(1.15);
    box-shadow: 0 3px 12px rgba(0, 0, 0, 0.5);
}

.glightbox-video:hover::after {
    border-color: transparent transparent transparent rgba(255, 255, 255, 1);
}

/* Responsive - icona più piccola su mobile */
@media only screen and (max-width: 940px) {
    .glightbox-video::before {
        width: 40px;
        height: 40px;
    }
    
    .glightbox-video::after {
        border-width: 7px 0 7px 11px;
    }
}
/* Desktop - video più larghi - SOLUZIONE DEFINITIVA */
@media only screen and (min-width: 940px) {
    .gslide-video {
        max-width: 85vw !important;
    }
    
    /* Rimuovi tutti gli sfondi neri */
    .glightbox-clean .gslide-video,
    .plyr__video-wrapper {
        background: transparent !important;
    }
    
    /* FORZA il wrapper a contenere il video senza padding */
    .gslide-video .plyr__video-wrapper {
        aspect-ratio: auto !important;
        padding-bottom: 0 !important;
        height: auto !important;
        position: relative !important;
    }
    
    /* Video occupa spazio naturale */
    .gslide-video .plyr__video-wrapper video {
        position: static !important;
        display: block !important;
        width: 100% !important;
        height: auto !important;
    }
    
    /* Container Plyr si adatta al video */
    .gslide-video .plyr {
        height: auto !important;
    }
    
    /* I controlli si posizionano relativi al container Plyr */
    .gslide-video .plyr--video .plyr__controls {
        position: absolute !important;
        bottom: 0 !important;
        left: 0 !important;
        right: 0 !important;
    }
}


/* ==========================================
   VIDEO MOBILE - 100% larghezza su mobile
   ========================================== */

@media only screen and (max-width: 940px) {
    .gslide-video .gvideo-wrapper {
        width: 100% !important;
    }
}

/* Mostra frecce solo sopra 940px invece di 768px */
@media (min-width: 941px) {
    .glightbox-clean .gprev {
        top: 42% !important;
    }
    
    .glightbox-clean .gnext {
        top: 42% !important;
    }
}

/* Nascondi frecce sotto 940px */
@media (max-width: 940px) {
    .glightbox-clean .gprev,
    .glightbox-clean .gnext {
        top: -100% !important;
    }
}

/* ==========================================
   MOBILE LANDSCAPE - Video fullscreen, nascondi descrizione
   ========================================== */

@media only screen and (max-width: 940px) and (orientation: landscape) {
    /* Nascondi completamente titolo e descrizione */
    .gslide-description,
    .gslide-title,
    .gslide-desc,
    .glightbox-mobile .glightbox-container .gslide-description {
        display: none !important;
    }
    
    /* Video occupa tutto lo spazio disponibile */
    .gslide-video {
        height: 100vh !important;
        max-height: 100vh !important;
        background: #ffffff !important;
    }
    
    .gslide-video .gvideo-wrapper {
        height: 100% !important;
        background: #ffffff !important;
    }
    
    /* Player Plyr a tutto schermo */
    .plyr__video-wrapper {
        height: 100vh !important;
        background: #ffffff !important;
    }
    
    .plyr--video {
        background: #ffffff !important;
    }
    
    /* CRITICO: Sfondo bianco sul poster */
    .plyr__poster {
        background-color: #ffffff !important;
    }
    
    /* Controlli visibili in basso */
    .plyr--video .plyr__controls {
        position: fixed !important;
        bottom: 0 !important;
        left: 0 !important;
        right: 0 !important;
        z-index: 9999 !important;
    }
}



