/* Video Edizione Shortcode Styles - Design Responsive */

.my-shortcodes-video-edizione {
    max-width: 1200px;
    margin: 0 auto;
    padding: 3rem 2rem;
    position: relative;
}

/* Header della sezione - STESSO STILE TESTIMONIANZE */
.video-edizione-header {
    text-align: center;
    margin-bottom: 3rem;
}

.video-edizione-subtitle {
    display: inline-block;
    font-size: 0.9rem;
    color: #fff;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 0.5rem;
    position: relative;
}

.video-edizione-subtitle::before,
.video-edizione-subtitle::after {
    content: "|";
    margin: 0 6px;
    color: #d94f34;
}

.video-edizione-title {
    font-size: 2.2rem;
    font-weight: 700;
    color: #fff;
    margin: 0 0 1rem 0;
}

.video-edizione-descrizione {
    font-size: 1.1rem;
    line-height: 1.6;
    color: #e5e7eb;
    margin: 0;
    max-width: 600px;
    margin: 0 auto;
}

/* Container principale */
.video-edizione-container {
    position: relative;
}

.video-edizione-content {
    position: relative;
}

/* Video Desktop (Orizzontale) */
.video-desktop {
    display: block;
    margin-bottom: 2rem;
}

.video-mobile {
    display: none;
}

.video-wrapper {
    position: relative;
    width: 100%;
    background: #000;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
    min-height: 400px; /* Altezza minima per evitare schermata nera */
}

.video-wrapper iframe {
    width: 100%;
    height: 400px; /* Altezza fissa invece di height: 0 + padding-bottom */
    border: none;
    display: block;
    position: relative; /* Cambiato da absolute a relative */
    top: auto; /* Rimosso posizionamento assoluto */
    left: auto;
}

/* Overlay con informazioni */
.video-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgba(0, 0, 0, 0.7) 0%, rgba(0, 0, 0, 0.3) 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 1;
    transition: opacity 0.3s ease;
    border-radius: 16px;
    z-index: 10;
}

.video-wrapper:hover .video-overlay {
    opacity: 1;
}

/* Nascondi overlay quando il video è in riproduzione */
.video-wrapper.playing .video-overlay {
    display: none !important;
}

.video-info {
    text-align: center;
    color: white;
    padding: 2rem;
}

.video-meta {
    display: flex;
    justify-content: center;
    gap: 2rem;
    margin-bottom: 1.5rem;
    flex-wrap: wrap;
}

.video-durata,
.video-visualizzazioni,
.video-data {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.9rem;
    font-weight: 500;
}

.video-durata i,
.video-visualizzazioni i,
.video-data i {
    font-size: 0.8rem;
    opacity: 0.8;
}

.video-actions {
    display: flex;
    justify-content: center;
    gap: 1rem;
    align-items: center;
}

.video-play-btn {
    background: #dc2626;
    color: white;
    border: none;
    padding: 0.75rem 1.5rem;
    border-radius: 25px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    transition: all 0.3s ease;
    box-shadow: 0 4px 12px rgba(220, 38, 38, 0.3);
}

.video-play-btn:hover {
    background: #b91c1c;
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(220, 38, 38, 0.4);
}

.video-share-btn {
    background: rgba(255, 255, 255, 0.2);
    color: white;
    border: 1px solid rgba(255, 255, 255, 0.3);
    padding: 0.75rem;
    border-radius: 50%;
    cursor: pointer;
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
}

.video-share-btn:hover {
    background: rgba(255, 255, 255, 0.3);
    transform: scale(1.1);
}



.banner-content {
    display: flex;
    align-items: center;
    gap: 2rem;
    flex-wrap: wrap;
}

.banner-icon {
    flex-shrink: 0;
    width: 60px;
    height: 60px;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    color: #fbbf24;
}

.banner-text {
    flex: 1;
    min-width: 300px;
}

.banner-text h3 {
    font-size: 1.5rem;
    font-weight: 700;
    color: white;
    margin: 0 0 0.5rem 0;
}

.banner-text p {
    font-size: 1rem;
    color: #e5e7eb;
    margin: 0;
    line-height: 1.5;
}

.banner-stats {
    display: flex;
    gap: 2rem;
    flex-shrink: 0;
}

.stat-item {
    text-align: center;
    color: white;
}

.stat-number {
    display: block;
    font-size: 1.8rem;
    font-weight: 700;
    color: #fbbf24;
    line-height: 1;
}

.stat-label {
    display: block;
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-top: 0.25rem;
    opacity: 0.9;
}

/* Animazioni */
.video-wrapper {
    animation: fadeInUp 0.8s ease forwards;
    opacity: 0;
    transform: translateY(30px);
}


@keyframes fadeInUp {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Responsive */
@media (max-width: 1023px) {
    .banner-content {
        flex-direction: column;
        text-align: center;
        gap: 1.5rem;
    }
    
    .banner-stats {
        justify-content: center;
    }
}

@media (max-width: 767px) {
    .my-shortcodes-video-edizione {
        padding: 2rem 1rem;
    }
    
    .video-edizione-title {
        font-size: 1.8rem;
    }
    
    .video-edizione-descrizione {
        font-size: 1rem;
    }
    
    /* Nascondi video desktop e mostra mobile */
    .video-desktop {
        display: none;
    }
    
    .video-mobile {
        display: block;
    }
    
    .video-meta {
        gap: 1rem;
        flex-direction: column;
        align-items: center;
    }
    
    .video-actions {
        flex-direction: column;
        gap: 0.75rem;
    }
    
    .video-play-btn {
        width: 100%;
        justify-content: center;
    }
    
    
    .banner-text h3 {
        font-size: 1.3rem;
    }
    
    .banner-text p {
        font-size: 0.9rem;
    }
    
    .banner-stats {
        gap: 1.5rem;
    }
    
    .stat-number {
        font-size: 1.5rem;
    }
    
    .stat-label {
        font-size: 0.75rem;
    }
}

/* Responsive per mantenere aspect ratio */
@media (min-width: 768px) {
    .video-wrapper iframe {
        height: 500px; /* Altezza maggiore per desktop */
    }
}

@media (max-width: 767px) {
    .video-wrapper iframe {
        height: 600px; /* Altezza maggiore per mobile per video verticali */
    }
    
    /* Adatta il wrapper per mobile */
    .video-wrapper {
        min-height: 600px; /* Altezza minima adattata per mobile */
    }
}

/* Effetti hover aggiuntivi */
.video-wrapper:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.4);
}

/* Loading state */
.video-wrapper.loading {
    background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
    background-size: 200% 100%;
    animation: loading 1.5s infinite;
}

@keyframes loading {
    0% {
        background-position: 200% 0;
    }
    100% {
        background-position: -200% 0;
    }
}

/* Video error state */
.video-error {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    height: 100%;
    color: white;
    text-align: center;
    padding: 2rem;
}

.video-error p {
    margin: 0 0 1rem 0;
    font-size: 1.1rem;
}

.retry-btn {
    background: #dc2626;
    color: white;
    border: none;
    padding: 0.75rem 1.5rem;
    border-radius: 8px;
    cursor: pointer;
    font-weight: 600;
    transition: all 0.3s ease;
}

.retry-btn:hover {
    background: #b91c1c;
    transform: translateY(-2px);
}

/* Assicurati che il video sia sempre visibile */
.video-wrapper iframe {
    opacity: 1 !important;
    visibility: visible !important;
}

/* Debug: mostra bordi per identificare problemi di layout */
.video-wrapper {
    border: 2px solid transparent;
}

.video-wrapper:hover {
    border-color: #dc2626;
}
