/**
 * Widget: video|middle-text
 * Video con altezza massima 80vh e overlay con titolo PERMANENTE (non scompare).
 */

/* Container */
.video-middle-text-container {
    position: relative;
    width: 100%;
    max-height: 80vh;
    overflow: hidden;
    background-color: #000;
}

.video-middle-text-player {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

/* -----------------------------------------------------------------------
   Overlay permanente: il titolo resta sempre visibile sopra al video.
   pointer-events: none così non blocca i controlli del componente video.
   Il bottone Play torna interattivo con pointer-events: auto.
----------------------------------------------------------------------- */
.vmt-overlay {
    position: absolute;
    inset: 0;
    z-index: 5;
    display: flex;
    align-items: center;
    justify-content: center;
    /* Gradiente radiale: garantisce contrasto WCAG AA per il testo bianco
       indipendentemente dal frame video sottostante */
    background:
        radial-gradient(ellipse at center, rgba(0, 0, 0, 0.45) 0%, rgba(0, 0, 0, 0.60) 100%);
    pointer-events: none;
}

.vmt-inner {
    text-align: center;
    color: #fff;
    padding: 1rem 1.5rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1.75rem;
    max-width: 800px;
}

.vmt-title {
    color: #fff;
    line-height: 1.2;
    margin: 0;
    text-shadow: 0 2px 8px rgba(0, 0, 0, 0.4);
    font-size: 4.125rem;
    font-weight: 500;
}

.vmt-title span.font-title-emphasis {
    font-style: italic;
}

/* Play button (solo quando autoplay = NO) */
.vmt-play {
    width: 80px;
    height: 80px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0;
    background: #fff;
    color: #3D3D3D;
    border: 2px solid transparent;
    border-radius: 50%;
    cursor: pointer;
    pointer-events: auto;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.30);
    transition: background-color 0.2s ease, transform 0.2s ease, box-shadow 0.2s ease;
}

.vmt-play svg {
    margin-left: 4px; /* compensazione ottica triangolo play */
}

.vmt-play:hover {
    background: #f5f5f5;
    transform: scale(1.05);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.36);
}

.vmt-play:focus-visible {
    outline: 3px solid #fff;
    outline-offset: 4px;
}

.vmt-play:active {
    transform: scale(0.97);
}

.vmt-play[hidden] {
    display: none;
}

@media (max-width: 600px) {
    .vmt-play {
        width: 64px;
        height: 64px;
    }
}

@media (prefers-reduced-motion: reduce) {
    .vmt-play {
        transition: none;
    }

    .vmt-play:hover,
    .vmt-play:active {
        transform: none;
    }
}

/*============================================================
 *  Responsive titolo
 */
@media (max-width: 767px) {
    .vmt-title {
        font-size: 3rem;
    }
}

