* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    background-color: #121212;
    font-family: system-ui, sans-serif;
    user-select: none;
    overflow: hidden;
}

#jeu {
    position: relative;
    flex-shrink: 0;
    transform-origin: center center;
    border: 3px solid #D4AF37;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
}

#hud {
    background-color: #D4AF37;
    color: #fff;
    padding: 10px 16px;
    font-weight: bold;
    font-size: 15px;
    border-bottom: 2px solid #967713;
}

#terrain {
    position: relative;
    width: 1250px;
    height: 700px;

    background-image: url('../Ressources\ Images/fond.png');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
}

#joueur {
    position: absolute;
    top: 0;
    left: 0;
    width: 200px;
    height: 200px;

    background-image: url('../Ressources\ Images/personnage-marche.png');
    background-size: fill;
    background-position: center;
    background-repeat: no-repeat;

    z-index: 10;
    will-change: transform;
    transform: translate(0px, calc(450px));
    transition: transform 0.8s ease-in-out;
}

#compteur-oubli {
    position: absolute;
    top: 5px;
    left: 10px;
    font-weight: bold;
    color: #fff;
    text-shadow: 0 2px 4px rgb(0 0 0 / 0.6);
    z-index: 21;
}

#mur-oubli {
    position: absolute;
    top: 0;
    left: 0;
    width: 0px;
    height: 100%;
    z-index: 20;
    pointer-events: none;
    background: linear-gradient(
        90deg,
        rgba(200, 215, 235, 0.88) 0%,
        rgba(220, 230, 245, 0.72) 75%,
        rgba(240, 248, 255, 0.45) 95%,
        rgba(255, 255, 255, 0.85) 100%
    );
    backdrop-filter: blur(5px) grayscale(60%);
    -webkit-backdrop-filter: blur(5px) grayscale(60%);
    border-right: 3px solid rgba(255, 255, 255, 0.9);
    box-shadow: 
        8px 0 25px rgba(180, 210, 255, 0.7),
        inset -15px 0 30px rgba(255, 255, 255, 0.6);
}

#mur-oubli::after {
    content: "";
    position: absolute;
    top: 0;
    right: -12px;
    width: 24px;
    height: 100%;
    background: radial-gradient(ellipse at center, rgba(255, 255, 255, 0.8) 0%, transparent 70%);
    animation: respirationBrume 3s ease-in-out infinite;
}

@keyframes respirationBrume {
    0%, 100% { opacity: 0.4; transform: scaleX(0.8); }
    50%      { opacity: 1;   transform: scaleX(1.3); }
}

.oublie {
    pointer-events: none;
    opacity: 0.3;
    filter: grayscale(100%);
    transition: opacity 0.5s, filter 0.5s;
}

.element {
    position: absolute;
    height: 300px;
    width: 225px;
    background-size: contain;
    background-position: center;
    background-repeat: no-repeat;
    border: 20px solid #D4AF37;
    cursor: pointer;
    z-index: 5;
    transition: transform 0.2s ease, filter 0.2s ease;
}

.element:hover {
    transform: scale(1.1);
    filter: drop-shadow(0 0 8px #D4AF37);
}

.element.oublie {
    filter: grayscale(100%) brightness(35%);
    opacity: 0.4;
    pointer-events: none;
    cursor: not-allowed;
}

#date1,
#date2,
#date3,
#date4 {
    position: absolute;
    top: 50px;
    color: #fff;
    background-color: #D4AF37;
    border: 2px solid #967713;
    border-radius: 6px;
    padding: 0 5px;
}

#date1 {
    left: 235px;
}

#date2 {
    left: 485px;
}

#date3 {
    left: 735px;
}

#date4 {
    left: 985px;
}

/* les éléments : */

#element-voiture-elec {
    left: 150px;
    top: 80px;
    background-image: url('../Ressources\ Images/affiche-voiture-elec.png');
}

#element-turing {
    left: 400px;
    top: 80px;
    background-image: url('../Ressources\ Images/affiche-turing.png');
}

#element-flappy-tesla {
    left: 650px;
    top: 80px;
    background-image: url('../Ressources\ Images/affiche-roadster.png');
}

#element-artemis {
    left: 900px;
    top: 80px;
    background-image: url('../Ressources\ Images/affiche-artemis-iv.png');
}

#notifications {
    position: absolute;
    bottom: 15px;
    color: #fff;
    background-color: #D4AF37;
    border: 2px solid #967713;
    border-radius: 6px;
    padding: 0 5px;
    z-index: 45;
}

/* fenêtre */

#fenetre {
    position: fixed;
    inset: 0;
    background-color: rgba(0, 0, 0, 0.75);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 100;
}

.cachee {
    display: none !important;
}

#fenetre-contenu {
    background-color: #D4AF37;
    color: #fff;
    width: 600px;
    max-width: 90%;
    max-height: 85vh;
    overflow-y: auto;
    border: 2px solid #967713;
    border-radius: 10px;
    padding: 20px;
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.8);
}

#fenetre-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid #967713;
    padding-bottom: 10px;
    margin-bottom: 15px;
}

#fenetre-titre {
    font-size: 1.2rem;
    color: #fff;
}

#btn-fermer {
    background: none;
    border: none;
    color: #fff;
    font-size: 2rem;
    cursor: pointer;
}

#btn-fermer:hover {
    color: #861115;
}