/* ================================================
   Route Djibouti — Intro v5.0
   Fond blanc, engin SVG réaliste, route au centre
   ================================================ */

#rdi-intro {
    position: fixed;
    inset: 0;
    z-index: 9999999;
    background: #ffffff;
    overflow: hidden;
}

/* ── Route au centre ── */
#rdi-road {
    position: absolute;
    top: 50%;
    left: 0;
    width: 0%;
    height: 60px;
    transform: translateY(-50%);
    background: #1e1e1e;
    border-top: 5px solid #444;
    border-bottom: 5px solid #444;
    transition: none;
}

/* Pointillés jaunes */
#rdi-road::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 0;
    width: 100%;
    height: 4px;
    transform: translateY(-50%);
    background: repeating-linear-gradient(
        90deg,
        #f0b800 0px, #f0b800 32px,
        transparent 32px, transparent 64px
    );
}

/* ── Engin SVG ── */
#rdi-machine {
    position: absolute;
    top: calc(50% - 88px);
    left: -260px;
    width: 240px;
    height: 110px;
}

/* Rouleaux qui tournent via animation sur les rayons SVG */
#rdi-roller-front,
#rdi-roller-back {
    animation: roller-spin 0.45s linear infinite;
    transform-origin: center;
}

#rdi-roller-front { transform-origin: 52px 88px; }
#rdi-roller-back  { transform-origin: 188px 88px; }

@keyframes roller-spin {
    from { transform: rotate(0deg); }
    to   { transform: rotate(360deg); }
}

/* Fumée au dessus du tuyau */
.rdi-smoke {
    position: absolute;
    border-radius: 50%;
    background: rgba(90,90,90,0.55);
    animation: smoke-up 1.1s ease-out infinite;
    pointer-events: none;
}
.rdi-smoke.s1 { width:9px;  height:9px;  top:-14px; left:158px; animation-delay:0s;    }
.rdi-smoke.s2 { width:13px; height:13px; top:-24px; left:155px; animation-delay:0.37s; }
.rdi-smoke.s3 { width:17px; height:17px; top:-36px; left:152px; animation-delay:0.74s; }

@keyframes smoke-up {
    0%   { opacity: 0.75; transform: scale(0.6) translateY(0); }
    100% { opacity: 0;    transform: scale(1.8) translateY(-20px); }
}

/* ── Bouton Passer ── */
#rdi-skip {
    position: absolute;
    top: 18px;
    right: 22px;
    background: rgba(0,0,0,0.12);
    color: #333;
    border: 2px solid rgba(0,0,0,0.2);
    padding: 7px 16px;
    font-size: 13px;
    font-weight: 700;
    border-radius: 20px;
    cursor: pointer;
    font-family: Arial, sans-serif;
    letter-spacing: 0.5px;
    transition: background 0.2s;
    z-index: 10000001;
}
#rdi-skip:hover { background: rgba(0,0,0,0.22); }

/* ── Fondu blanc final ── */
#rdi-intro.closing {
    animation: fade-white 0.7s ease forwards;
}
@keyframes fade-white {
    to { opacity: 0; }
}
