/* ===== ANIMATION SESSION PARLEMENTAIRE ===== */

/* Container principal */
.session-animation-container {
    position: relative;
    width: 100%;
    height: 180px;
    border-radius: 12px;
    overflow: hidden;
    margin-top: 1rem;
    margin-bottom: 1.5rem;
    font-family: 'Courier New', monospace;
}

/* Fonds selon l'heure */
.session-animation-container.morning {
    background: linear-gradient(to bottom, #FFD89B 0%, #87CEEB 100%);
}
.session-animation-container.day {
    background: linear-gradient(to bottom, #87CEEB 0%, #E0F4FF 100%);
}
.session-animation-container.evening {
    background: linear-gradient(to bottom, #1a3a5c 0%, #2d5a7b 100%);
}
.session-animation-container.night {
    background: linear-gradient(to bottom, #0a1628 0%, #1a3a5c 100%);
}

/* Titre et date */
.session-title-pixel {
    position: absolute;
    top: 8px;
    left: 50%;
    transform: translateX(-50%);
    font-size: 18px;
    font-weight: bold;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    color: #333;
    text-shadow: 1px 1px 0 white;
    z-index: 20;
    white-space: nowrap;
}
.session-date-pixel {
    position: absolute;
    top: 32px;
    left: 50%;
    transform: translateX(-50%);
    font-size: 12px;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    color: #555;
    text-shadow: 1px 1px 0 white;
    z-index: 20;
    white-space: nowrap;
}

/* Mobile */
@media (max-width: 480px) {
    .session-title-pixel {
        font-size: 12px;
    }
    .session-date-pixel {
        font-size: 10px;
    }
}
.session-animation-container.evening .session-title-pixel,
.session-animation-container.evening .session-date-pixel,
.session-animation-container.night .session-title-pixel,
.session-animation-container.night .session-date-pixel {
    color: #E0E0E0;
    text-shadow: 1px 1px 0 #333;
}

/* Scène */
.pixel-scene {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 140px;
}

/* Sol */
.pixel-sol {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 12px;
    background: #228B22;
    border-top: 4px solid #006400;
}

/* Étoiles */
.pixel-etoiles {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 50px;
    pointer-events: none;
}
.pixel-star {
    position: absolute;
    width: 3px;
    height: 3px;
    background: white;
    opacity: 0;
}
.session-animation-container.night .pixel-star,
.session-animation-container.evening .pixel-star {
    opacity: 1;
    animation: twinkle 2s ease-in-out infinite;
}
@keyframes twinkle {
    0%, 100% { opacity: 0.3; }
    50% { opacity: 1; }
}

/* ===== PALAIS FÉDÉRAL ===== */
.pixel-palais {
    position: absolute;
    bottom: 12px;
    left: 50%;
    transform: translateX(-50%);
    width: 180px;
    height: 100px;
}

/* Ailes latérales */
.p-aile {
    position: absolute;
    bottom: 0;
    width: 44px;
    height: 36px;
    background: #D8D4C8;
    border: 2px solid #A0987C;
    z-index: 2;
}
.p-aile.gauche { left: 0; }
.p-aile.droite { right: 0; }

/* Fenêtres ailes */
.p-aile-niveau {
    position: absolute;
    left: 4px;
    right: 4px;
    display: flex;
    justify-content: space-between;
}
.p-aile-niveau.n1 { bottom: 3px; }
.p-aile-niveau.n2 { bottom: 14px; }
.p-aile-niveau.n3 { bottom: 24px; left: 5px; right: 5px; }

.p-win {
    width: 8px;
    height: 9px;
    background: #4A6A8A;
    border: 1px solid #2A4A6A;
    border-radius: 4px 4px 0 0;
}
.p-win.small {
    width: 6px;
    height: 6px;
    border-radius: 3px 3px 0 0;
}

/* Tours arrière-plan */
.p-tour {
    position: absolute;
    bottom: 28px;
    width: 24px;
    height: 30px;
    background: #C8C4B8;
    border: 2px solid #989080;
    z-index: 1;
}
.p-tour.gauche { left: 42px; }
.p-tour.droite { right: 42px; }

.p-tour-coupole {
    position: absolute;
    top: -8px;
    left: 50%;
    transform: translateX(-50%);
    width: 20px;
    height: 8px;
    background: #5AB8A8;
    border: 2px solid #3A9888;
    border-radius: 10px 10px 0 0;
}
.p-tour-fenetre {
    position: absolute;
    top: 4px;
    left: 50%;
    transform: translateX(-50%);
    width: 10px;
    height: 8px;
    background: #4A6A8A;
    border: 1px solid #2A4A6A;
    border-radius: 5px 5px 0 0;
}

/* Corps central */
.p-base {
    position: absolute;
    bottom: 0;
    left: 42px;
    width: 96px;
    height: 20px;
    background: #D8D4C8;
    border: 2px solid #A0987C;
    z-index: 3;
}

.p-arcades-row {
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 8px;
}
.p-arc {
    width: 14px;
    height: 16px;
    background: #3A3A3A;
    border: 2px solid #2A2A2A;
    border-radius: 7px 7px 0 0;
}
.p-arc.porte {
    width: 18px;
    height: 16px;
    background: #3A3A3A;
    border-color: #2A2A2A;
    border-radius: 9px 9px 0 0;
}

/* Colonnade */
.p-colonnade {
    position: absolute;
    bottom: 18px;
    left: 42px;
    width: 96px;
    height: 20px;
    background: #E4E0D4;
    border: 2px solid #A0987C;
    border-bottom: none;
    z-index: 3;
}
.p-cols {
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 10px;
}
.p-col {
    width: 4px;
    height: 16px;
    background: #F0ECE0;
    border: 1px solid #C0B8A0;
}

/* Fronton */
.p-fronton-base {
    position: absolute;
    bottom: 36px;
    left: 46px;
    width: 88px;
    height: 4px;
    background: #D8D4C8;
    border: 2px solid #8A8470;
    border-bottom: none;
    z-index: 10;
}
.p-fronton-triangle {
    position: absolute;
    bottom: 38px;
    left: 46px;
    width: 0;
    height: 0;
    border-left: 44px solid transparent;
    border-right: 44px solid transparent;
    border-bottom: 14px solid #8A8470;
    z-index: 10;
}
.p-fronton-triangle::before {
    content: '';
    position: absolute;
    top: 2px;
    left: -46px;
    width: 0;
    height: 0;
    border-left: 46px solid transparent;
    border-right: 46px solid transparent;
    border-bottom: 12px solid #D8D4C8;
    z-index: -1;
}

/* Bloc sous coupole */
.p-sous-coupole {
    position: absolute;
    bottom: 42px;
    left: 72px;
    width: 36px;
    height: 20px;
    background: #D8D4C8;
    border: 2px solid #A0987C;
    display: flex;
    justify-content: center;
    align-items: flex-start;
    gap: 3px;
    padding-top: 3px;
    z-index: 3;
}
.p-fenetre-haute {
    width: 8px;
    height: 8px;
    background: #4A6A8A;
    border: 1px solid #2A4A6A;
    border-radius: 4px 4px 0 0;
}

/* Coupole centrale */
.p-coupole-drum {
    position: absolute;
    bottom: 60px;
    left: 72px;
    width: 36px;
    height: 4px;
    background: #C8C4B8;
    border: 2px solid #989488;
    z-index: 5;
}
.p-coupole {
    position: absolute;
    bottom: 62px;
    left: 76px;
    width: 28px;
    height: 14px;
    background: #5AB8A8;
    border: 2px solid #3A9888;
    border-radius: 14px 14px 4px 4px;
    z-index: 5;
}
.p-lanterne {
    position: absolute;
    bottom: 74px;
    left: 84px;
    width: 12px;
    height: 5px;
    background: #5AB8A8;
    border: 2px solid #3A9888;
    border-radius: 6px 6px 0 0;
    z-index: 5;
}
.p-croix {
    position: absolute;
    bottom: 79px;
    left: 89px;
    width: 2px;
    height: 6px;
    background: #D4A020;
    z-index: 6;
}
.p-croix::before {
    content: '';
    position: absolute;
    top: 2px;
    left: -2px;
    width: 6px;
    height: 2px;
    background: #D4A020;
}

/* Éclairage soir - fenêtres allumées */
.session-animation-container.evening .p-win,
.session-animation-container.evening .p-fenetre-haute,
.session-animation-container.evening .p-tour-fenetre {
    background: #FFE082;
    border-color: #D4A030;
}
.session-animation-container.evening .p-arc {
    background: #2A2A2A;
}
.session-animation-container.evening .p-arc.porte {
    background: #2A2A2A;
}

/* Éclairage nuit - fenêtres sombres */
.session-animation-container.night .p-win,
.session-animation-container.night .p-fenetre-haute,
.session-animation-container.night .p-tour-fenetre {
    background: #2A3A4A;
    border-color: #1A2A3A;
}
.session-animation-container.night .p-arc {
    background: #1A1A1A;
}
.session-animation-container.night .p-arc.porte {
    background: #1A1A1A;
}

/* ===== PERSONNAGES ===== */
.pixel-personnages {
    position: absolute;
    bottom: 12px;
    left: 0;
    width: 100%;
    height: 24px;
    z-index: 10;
}

.pixel-perso {
    position: absolute;
    bottom: 0;
    width: 8px;
    height: 14px;
    opacity: 0;
}
.pixel-perso::before {
    content: '';
    position: absolute;
    top: 0;
    left: 1px;
    width: 6px;
    height: 6px;
    background: #FFDAB9;
    border: 1px solid #D2691E;
}
.pixel-perso::after {
    content: '';
    position: absolute;
    top: 7px;
    left: 0;
    width: 8px;
    height: 7px;
}

/* Couleurs des partis */
.pixel-perso.udc::after { background: #009F4D; }
.pixel-perso.plr::after { background: #0066CC; }
.pixel-perso.ps::after { background: #E41019; }
.pixel-perso.centre::after { background: #FF9900; }
.pixel-perso.verts::after { background: #84B414; }
.pixel-perso.vertlib::after { background: #A6CF42; }

/* Femmes */
.pixel-perso.femme::before {
    width: 8px;
    height: 8px;
    left: 0;
    border-radius: 0;
}

.pixel-perso.gauche { animation: marcheG 7s linear infinite; }
.pixel-perso.droite { animation: marcheD 8s linear infinite; }

@keyframes marcheG {
    0%, 5% { left: calc(50% - 120px); opacity: 0; }
    6% { left: calc(50% - 120px); opacity: 1; }
    50% { left: calc(50% - 30px); opacity: 1; }
    51%, 100% { left: calc(50% - 30px); opacity: 0; }
}

@keyframes marcheD {
    0%, 5% { right: calc(50% - 120px); left: auto; opacity: 0; }
    6% { right: calc(50% - 120px); left: auto; opacity: 1; }
    50% { right: calc(50% - 30px); left: auto; opacity: 1; }
    51%, 100% { right: calc(50% - 30px); left: auto; opacity: 0; }
}

/* Bulles */
.pixel-bulle {
    position: absolute;
    bottom: 85px;
    width: 20px;
    height: 14px;
    background: white;
    border: 2px solid #333;
    font-size: 8px;
    text-align: center;
    line-height: 10px;
    padding-bottom: 2px;
    opacity: 0;
    z-index: 15;
    display: none;
}
.pixel-bulle.g { left: calc(50% - 60px); }
.pixel-bulle.d { left: calc(50% + 40px); }
.pixel-bulle.active { display: block; animation: bulle 6s infinite; }
.pixel-bulle.d.active { animation-delay: 3s; }

@keyframes bulle {
    0%, 35% { opacity: 0; }
    40%, 60% { opacity: 1; }
    65%, 100% { opacity: 0; }
}
