/*******************************************************
GENERAUX
*******************************************************/

* {
    margin: 0;
    padding: 0;
    font-family: 'Comic Sans MS', 'Comic Neue', cursive, sans-serif;
}

a {
    text-decoration: none;
}


body {
    background-image: url(../img/background-4.jpg);
    background-attachment: fixed;
    background-repeat: no-repeat;
    background-position: center;
    background-size: cover;
    display: flex;
    flex-direction: column;
    align-items: center;
}

/*******************************************************
EN TETE
*******************************************************/

.header-site {
    height: 15vh;
    background-color: rgba(255, 30, 0, 0.8);
    display: flex;
    position: relative;
    align-items: center;
    width: 100%;
}

.header-title {
    color: rgba(255, 255, 255, 1);
    margin: 30px;
    width: 100%;
}

.header-nav {
    color: rgba(255, 255, 255, 1);
    position: absolute;
    transform: translate(-100%, -100%);
    top: 100%;
    left: 98%;
    width: 33%;
    display: flex;
    justify-content: flex-end;
    align-items: center;
}

.nav-list {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.nav-list-item {
    margin: 10px;
    background-color: rgba(0, 0, 255, 0.5);
    border-radius: 20px;
    padding: 10px;
    list-style: none;
}

.nav-list-item-link {
    color: rgba(255, 255, 255, 1);
}

#menu-burger {
    display: none;
    width: 40px;
    position: absolute;
    transform: translate(-100%, -100%);
    left: 95%;
    top: 95%;
}

.burger {
    width: 100%;
}

/*******************************************************
CORPS
*******************************************************/

main {
    width: 46%;
    background-color: rgba(255, 255, 255, 1);
    padding: 1%;
}

/*************** Titre de la page ******************/

.titleContainer {
    display: flex;
    justify-content: center;
    align-items: center;
    flex-direction: column;
    margin: 2%;
    text-align: center;
}

h2 {
    font-size: 2rem;
    color: rgb(255, 81, 81);
}

h3 {
    font-size: 1.5rem;
    color: rgb(255, 81, 81);
}

/*************** Modale ***********/

#open-modal {
    position: fixed;
    transform: translate(-100%, 0);
    top: 16%;
    left: 96%;
    width: 60px;
    border-radius: 10px;
    border-style: none;
    background-color: rgb(255, 0, 0);
    color: rgb(255, 255, 255);
    padding: 0.5%;
    z-index: 3;
    box-shadow: 1px 1px 1px 1px rgb(184, 184, 184);
}

#open-modal:hover {
    background-color: rgb(216, 0, 0);
    box-shadow: none;
}

/* Modale caché */
.modal {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.5); /* fond noir semi-transparent */
  justify-content: center;
  align-items: center;
  z-index: 9;
}

/* Contenu de la modale */
.modal-content {
  background-color: rgb(255, 255, 255);
  padding: 20px;
  border-radius: 10px;
  width: 80%;
  max-width: 500px;
  position: relative;
  animation: popup 0.3s ease;
  text-align: left;
}

@keyframes popup {

    0% {
        transform: scale(0.7);
        opacity: 0;
    }

    100% {
        transform: scale(1);
        opacity: 1;
    }
    
}

.modal-content > ul {
    list-style-type: none;
}

/* Bouton de fermeture (croix) */
.close-button {
  position: absolute;
  top: 10px;
  right: 15px;
  font-size: 24px;
  cursor: pointer;
  color: rgb(100, 100, 100);
}

/*************** Calculatrice *************************/

#calculator-container {
  background-color: rgb(255, 224, 178); /* orange pastel */
  border-radius: 24px;
  padding: 1rem;
  max-width: 360px;
  margin: 0.5%;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
  position: fixed;
  top: 25%;
  left: 5%;
  transform: translate(0, 0);
}

#calculator-container .display {
  background-color: rgb(255, 255, 255);
  color: rgb(51, 51, 51);
  font-size: 2rem;
  padding: 1rem;
  border-radius: 16px;
  text-align: right;
  margin-bottom: 1rem;
  box-shadow: inset 0 0 6px rgba(0, 0, 0, 0.1);
}

#calculator-container .buttons {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0.5rem;
}

#calculator-container button {
  font-size: 1.5rem;
  padding: 1rem;
  border: none;
  border-radius: 16px;
  background-color: rgb(255, 204, 128); /* orange clair */
  color: rgb(51, 51, 51);
  cursor: pointer;
  transition: background-color 0.3s ease;
  box-shadow: 1px 1px rgb(184, 184, 184);
}

#calculator-container button:hover {
  background-color: rgb(255, 183, 77); /* orange plus vif */
  box-shadow: none;
}

#calculator-container button:active {
  transform: scale(0.95);
}

#calculator-container .equal {
  grid-column: span 3; /* Le bouton occupe 3 cases sur la ligne */
  background-color: rgb(255, 176, 58);
  font-weight: bold;
}

#calculator-container .equal:hover {
  grid-column: span 3; /* Le bouton occupe 3 cases sur la ligne */
  background-color: rgb(255, 153, 0);
}

#calculator-container .plus {
    grid-row: span 2;
}

#calculator-container .delet {
    background-color: rgb(255, 81, 81);
    color: rgb(255, 255, 255);
}

#calculator-container .delet:hover {
    background-color: rgb(255, 24, 24);
    color: rgb(255, 255, 255);
}

/*************** Questions ************************/

.questions-container {
    margin: 30px;
}

h4 {
    margin: 1% 0;
    color: rgb(255, 98, 59);
    font-size: 1.2rem;
}

.s1 , .s2 {
    margin: 2%;
}

h5 {
    margin: 1% 0;
    color: rgb(255, 98, 59);
    font-size: 1.1rem;
}

.answearQ {
    margin: 1%;
    border-radius: 7px;
    border-style: none;
    box-shadow: 1px 1px 2px 1px rgba(184, 184, 184, 1);
}

.btn-check {
    background-color: rgb(255, 224, 178);
    border-style: none;
    border-radius: 10px;
    width: 100px;
    padding: 2px;
    margin: 0 1%;
    color: rgb(255, 0, 0);
    box-shadow: 1px 1px 2px 1px rgba(184, 184, 184, 1);
    position: relative;
}

.btn-check:hover {
    background-color: rgb(252, 202, 125);
    box-shadow: none;
}

/* .vf {
    left: 5%;
} */

.trueOrFalse {
    margin: 2% 1% 1% 1%;
}

/*******************************************************
FOOTER
*******************************************************/

.footer-site {
    height: 10vh;
    background-color: rgba(255, 30, 0, 0.8);
    display: flex;
    position: relative;
    align-items: flex-end;
    justify-content: center;
    margin-bottom: 0;
    width: 100%;
    color: rgb(255, 255, 255);
}

.copyright-site {
    position: absolute;
    transform: translate(-50%, -50%);
    top: 50%;
    left: 50%;
}

/********************************************************
QUERY MEDIA : RESPONSIVE
********************************************************/

@media (max-width : 1024px) {
    main {
        width: 100%;
    }

    #calculator-container {
        position: relative;
        transform: translate(-50%, 0);
        left: 50%;
        max-width: 260px;
    }

    .header-nav {
        display: none;
    }

    #menu-burger {
        display: block;
    }

}