/* =====================================================
   MEDVIR PARALLAX / HERO BLOCK
   ===================================================== */

.medvir-parallax {
    position: relative;
    overflow: hidden;
    width: 100%;
}

/* -----------------------------------------------------
   FOND — image simple + couche arrière (layers)
   ----------------------------------------------------- */
.medvir-parallax__bg {
    position: absolute;
    inset: 0;                        /* ← plus de -20% */
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    background-attachment: fixed;
    z-index: 0;
}


/* -----------------------------------------------------
   AVANT-PLAN — couche layers
   ----------------------------------------------------- */
.medvir-parallax__fg {
    position: absolute;
    inset: 0;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    will-change: transform;
    transition: transform 0.1s linear;
    z-index: 1;
    pointer-events: none;
}

/* -----------------------------------------------------
   VIDÉO YOUTUBE / VIMEO
   ----------------------------------------------------- */
.medvir-parallax__video-wrap {
    position: absolute;
    inset: 0;
    z-index: 0;
    pointer-events: none;
    overflow: hidden;
}

.medvir-parallax__video-wrap iframe {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 177.78vh;  /* 16/9 ratio */
    height: 56.25vw;  /* 16/9 ratio */
    min-width: 100%;
    min-height: 100%;
}

/* -----------------------------------------------------
   CONTENU
   ----------------------------------------------------- */
.medvir-parallax__content {
    position: relative;
    z-index: 2;
}

.medvir-parallax__title {
    color: #fff;
    font-size: clamp(1.8rem, 5vw, 3.5rem);
    font-weight: 700;
    text-shadow: 0 2px 8px rgba(0, 0, 0, 0.4);
    margin-bottom: 1rem;
}

.medvir-parallax__subtitle {
    color: rgba(255, 255, 255, 0.9);
    font-size: clamp(1rem, 2.5vw, 1.4rem);
    text-shadow: 0 1px 4px rgba(0, 0, 0, 0.4);
    margin-bottom: 1.5rem;
    max-width: 600px;
}

.medvir-parallax__cta {
    font-size: 1.1rem;
    padding: 0.75rem 2rem;
    border-radius: 50px;
    text-decoration: none;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.medvir-parallax__cta:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.3);
}

.medvir-parallax__video-wrap iframe {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 177.78vh;
    height: 56.25vw;
    min-width: 100%;
    min-height: 100%;
    pointer-events: none; /* ← ajout */
}

/* -----------------------------------------------------
   RESPONSIVE
   ----------------------------------------------------- */
@media (max-width: 768px) {
    .medvir-parallax__bg {
        inset: -10%;
    }

    .medvir-parallax__video-wrap iframe {
        width: 300vw;
        height: 168.75vw;
    }
}