.video-container {
    position: relative;
    width: 100%;
}

/* =========================
   LOADER
   ========================= */

.loader-wrapper {
    position: absolute;
    inset: 0;
    z-index: 999;

    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;

    background: rgba(0, 0, 0, 0.2);

    opacity: 0;
    visibility: hidden;
    pointer-events: none;

    transition:
        opacity 0.3s ease,
        visibility 0.3s ease;
}

.is-loading .loader-wrapper {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
}

/* =========================
   SPINNER
   ========================= */

.loader-spinner {
    width: 50px;
    height: 50px;

    border: 5px solid rgba(255, 255, 255, 0.1);
    border-top-color: #00d2ff;
    border-right-color: #3a7bd5;
    border-radius: 50%;

    animation: spin 1s cubic-bezier(0.5, 0, 0.5, 1) infinite;

    margin-bottom: 15px;

    box-shadow: 0 0 10px rgba(0, 210, 255, 0.5);
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

/* =========================
   TESTO LOADING
   ========================= */

.loading-text {
    color: #00d2ff !important;
    font-size: 14px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 2px;
    text-shadow: 0 0 5px rgba(0, 210, 255, 0.3);
}

/* =========================
   STATO DI CARICAMENTO
   ========================= */

.is-loading img {
    filter: brightness(0.3) blur(5px) !important;
}

.is-loading .play-button {
    display: none;
}


/* =========================
   VIDEO OVERLAY
   ========================= */

#video-overlay {
    position: fixed;
    inset: 0;
    z-index: 9999;

    display: flex;
    align-items: center;
    justify-content: center;

    background: rgba(0, 0, 0, 0.95);

    opacity: 0;
    visibility: hidden;
    pointer-events: none;

    transition:
        opacity 0.4s ease,
        visibility 0.4s ease;
}

#video-overlay.active {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
}

#video-wrapper {
    width: min(90%, 1000px);
}

#video-wrapper video {
    display: block;
    width: 100%;
    box-shadow: 0 0 50px #000;
}


/* =========================
   PAGE CURTAIN
   ========================= */

#page-curtain {
    position: fixed;
    inset: 0;
    z-index: 10000;

    background: #000;

    opacity: 0;
    visibility: hidden;
    pointer-events: none;

    transition: opacity 2s ease;
}

#page-curtain.active {
    opacity: 0.1;
    visibility: visible;
    pointer-events: auto;
}