/* Réinitialisation et fond */
body {
    margin: 0;
    background-color: #000;
    color: #fff;
    font-family: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, 'Open Sans', 'Helvetica Neue', sans-serif;
    display: flex;
    justify-content: center;
    align-items: center;
    height: 100vh;
    overflow: hidden;
}

/* Conteneur principal pour la vidéo et l'UI */
.video-container {
    position: relative;
    width: 768px; /* Largeur de base */
    max-width: 100%;
    background-color: #000;
}

/* Style en plein écran */
.video-container:fullscreen {
    width: 100vw;
    height: 100vh;
}

.video-container:fullscreen #url_zone {
    width: 100%;
    height: 100%;
    object-fit: contain; /* Garde les proportions en plein écran */
}

#url_zone {
    width: 100%;
    height: auto;
    display: block;
}

/* Conteneur pour les boutons de contrôle */
.button-overlay {
    position: absolute;
    top: 10px;
    right: 10px;
    z-index: 20;
    display: flex;
    gap: 8px;
    /* Cache les boutons et les montre au survol du conteneur */
    opacity: 0;
    transition: opacity 0.3s ease;
}
.video-container:hover .button-overlay {
    opacity: 1;
}

/* Style des boutons Pause et Plein Écran */
.pause-btn, #fullscreen-btn {
    background-color: rgba(255, 255, 255, 0.8);
    border: none;
    border-radius: 50%;
    width: 40px;
    height: 40px;
    cursor: pointer;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 8px;
    box-shadow: 0 2px 5px rgba(0,0,0,0.3);
    transition: background-color 0.2s ease;
}
.pause-btn:hover, #fullscreen-btn:hover {
    background-color: rgba(255, 255, 255, 1);
}
.pause-btn svg, #fullscreen-btn svg {
    stroke: #333337;
}

/* Styles pour les écrans de début et de fin */
.black-overlay, .black-end {
    position: fixed;
    inset: 0;
    background-color: rgba(0, 0, 0, 1);
    z-index: 100;
    display: flex;
    justify-content: center;
    align-items: center;
    flex-direction: column;
    font-size: 2rem;
    text-align: center;
}
.black-end.hide-end {
    display: none;
}

/* Bouton "Commencer" */
.begin {
    font-size: 1.5rem;
    padding: 10px 20px;
    background-color: #fff;
    color: #000;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}
.begin:hover {
    transform: translateY(-5px);
    box-shadow: 0 5px 15px rgba(255, 255, 255, 0.2);
}

/* Conteneur des choix (nouveau style) */
.choice {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 10;
    
    /* Le dégradé demandé */
    background: linear-gradient(to top, rgba(0, 0, 0, 0.75), transparent);
    
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 15px;
    padding: 40px 20px;

    /* L'animation fluide */
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.5s ease-out, transform 0.5s ease-out;
    pointer-events: none; /* Invisible aux clics si caché */
}
.choice.choices-visible {
    opacity: 1;
    transform: translateY(0);
    pointer-events: auto; /* Clicable quand visible */
}

/* Style des boutons de choix */
.choice button {
    font-size: 1.1rem;
    padding: 12px 24px;
    background-color: rgba(255, 255, 255, 0.9);
    color: #000;
    border: none;
    border-radius: 25px;
    cursor: pointer;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.4);
    transition: background-color 0.2s ease, transform 0.2s ease;
}
.choice button:hover {
    background-color: #fff;
    transform: scale(1.05);
}

/* Bordure-Timer (nouveau) */
.timer-border {
    position: absolute;
    background-color: #f6e05e; /* Jaune */
    z-index: 15;
    opacity: 1;
    transition: opacity 0.3s ease; /* Pour le cacher en fondu */
}
#timer-top {
    top: 0; left: 0;
    height: 5px; width: 0; /* JS animera 'width' */
}
#timer-right {
    top: 0; right: 0;
    width: 5px; height: 0; /* JS animera 'height' */
}
#timer-bottom {
    bottom: 0; right: 0;
    height: 5px; width: 0; /* JS animera 'width' */
}
#timer-left {
    bottom: 0; left: 0;
    width: 5px; height: 0; /* JS animera 'height' */
}