/*MENU*/
.burger-btn {
    background-color: rgb(255, 204, 108);
    cursor: pointer;
    margin: 0.5%;
    padding: 0.5%;
    font-size: 20px;
    top: 0;
    right: 10px;
    position: fixed;
    z-index: 1000;
}

nav {
    position: fixed;
    top: 0;
    right: -300px;
    width: 300px;
    height: 100vh;
    background-color: #444;
    transition: right 0.3s;
    padding-top: 4rem;
    z-index: 999;
}

nav.open {
    right: 0;
}

nav ul {
    list-style: none;
}

nav ul li {
    padding: 0;
}

nav ul li a {
    display: block;
    color: white;
    text-decoration: none;
    padding: 1rem 2rem;
    transition: background-color 0.3s;
}

nav ul li a:hover {
    background-color: #555;
}

/*OVERLAY*/
.overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s, visibility 0.3s;
    z-index: 998;
}

.overlay.active {
    opacity: 1;
    visibility: visible;
}

/*GENERAL*/

*{  /* = deletes weird white borders around the screen */
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html, 
body{
    height: 100%;
}

html{
    scroll-behavior:smooth
}

body{
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    background-color: rgb(232, 184, 220);
    color: black;
}

div{
    text-align: center;
}

p {
    font-family: "Noto Sans", sans-serif;
    font-size: 100%;
}

img{
    border-radius: 10px;
    padding: 5px;
    background-color: rgb(255, 204, 108);
    max-width: 100%;
    height: auto;
}

a:hover {
    color: rgb(102, 22, 140);
}

.flag{
    height: 30px;
}

/*TITLES*/
.firstTitle {
    font-size: 50px;
}

.title {
    grid-column: 1;
    margin: 2%;
}

.titleSize {
    font-size: 40px;
}

/*BACKGROUND*/
.background{
    max-width: 100%;
    height: auto;
}

/*CARDS*/
.cards{
    display: flex;
    justify-content: space-evenly;
    padding: 1%;
    align-items: baseline;
    width: 99%;
}

.cardBorderB{
    border: 5px solid rgb(47, 193, 28);
}

.cardBorderA{
    border: 5px solid rgb(8, 171, 235);
}

.cardBorderS{
    border: 5px solid rgb(152, 8, 235);
}

.cardsList{
    display: flex;
    flex-wrap: wrap;
    justify-content: space-evenly;
    padding: 1%;
    align-items: baseline;
    width: 99%;
}

.cardsListName{
    margin-bottom: 2%;
}

/*ABOUT ME*/
.textBorder{
    border-radius: 10px;
    width: 40%;
    padding: 1%;
    background-color: rgb(255, 225, 192);
    margin: auto;
}

/*CONTACT ME*/
.contact{
    display: flex;
    justify-content: space-evenly;
    font-size: 20px;
    margin-bottom: 3%;
}

/*FAQ*/
.container {
    max-width: 800px;
    margin: 0 auto;
    background-color: white;
    padding: 40px;
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

h1 {
    text-align: center;
    margin-bottom: 30px;
}

.faq-item {
    border-bottom: 1px solid #e0e0e0;
    margin-bottom: 10px;
}

.faq-question {
    background-color: #f9f9f9;
    padding: 20px;
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: background-color 0.3s;
}

.faq-question:hover {
    background-color: #eeeeee;
}

.faq-question h3 {
    color: #2c3e50;
    font-size: 18px;
    font-weight: 600;
}

.faq-icon {
    font-size: 24px;
    color: #ff0000;
    transition: transform 0.3s;
}

.faq-icon.active {
    transform: rotate(180deg);
}

.faq-answer {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease-out, padding 0.3s ease-out;
    padding: 0 20px;
    background-color: white;
}

.faq-answer.active {
    max-height: 500px;
    padding: 20px;
}

.faq-answer p {
    color: #555;
    line-height: 1.6;
}

/*FOOTER*/
.footerFlex {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-evenly;
    align-items: center;
}

.footer,
.footerAbout
 {
    width: 100%;
    padding: 20px 0;
    margin-top: auto;
    background-color: #ffb949;
}

.logo{
    width: 100px;
    margin-right: 50%;
}

/*FORM*/
form {
  border: 1px solid rgba(153,153,153,0.6);
}
.form-container {
  width: 600px;
  margin: 100px auto;
}

form > div {
  margin: 30px 20px;
}

label {
  display: block;
  margin-bottom: 8px;
}

input {
  height: 20px;
  width: 40%;
}

button {
  margin-left: 20px;
  margin-bottom: 30px;
  padding: 10px 32px;
  cursor: pointer;
}

.message-error {
  border: 1px solid rgba(212, 42, 0, 1);
  color: rgb(212, 42, 0);
  background-color: rgba(212, 42, 0, 0.4);
  padding: 16px 32px;
  margin-bottom: 20px;
  display: none;
}

.message-succes {
  border: 1px solid rgb(81, 150, 2);
  color: rgb(81, 150, 2);
  background-color: rgba(113, 212, 0, 0.4);
  padding: 16px 32px;
  margin-bottom: 20px;
  display: none;
}

.success {
  border: 1px solid rgb(81, 150, 2);
  background-color: rgba(113, 212, 0, 0.4);
}

.message-error.visible {
  display: block;
}

.message-succes.visible {
  display: block;
}

.radio-group label{
  display: inline-flex;
  align-items: center;
  margin-right: 20px;
}

.radio-group input{
  width: auto;
  margin-right: 5px;
}

/*DARK MODE*/
.dark-mode-toggle {
    position: fixed;
    top: 10px;
    left: 10px;
    background-color: rgb(255, 204, 108);
    color: black;
    border: none;
    padding: 10px 15px;
    border-radius: 20px;
    cursor: pointer;
    font-size: 20px;
    box-shadow: 0 2px 5px rgba(0,0,0,0.3);
    transition: background-color 0.3s, transform 0.2s;
    z-index: 1001;
}

.dark-mode-toggle:hover {
    background-color: rgb(255, 180, 70);
    transform: scale(1.05);
}

body {
    transition: background-color 0.3s, color 0.3s;
}

body.dark-mode {
    background-color: rgb(45, 25, 50);
    color: rgb(230, 230, 230);
}

body.dark-mode img {
    background-color: rgb(80, 60, 90);
}

body.dark-mode h1,
body.dark-mode h3 {
    color: rgb(255, 204, 108);
}

body.dark-mode a {
    color: rgb(255, 180, 150);
}

body.dark-mode a:hover {
    color: rgb(255, 120, 200);
}

body.dark-mode .burger-btn {
    background-color: rgb(80, 60, 90);
    color: rgb(255, 204, 108);
}

body.dark-mode nav {
    background-color: rgb(40, 30, 50);
}

body.dark-mode nav ul li a {
    color: rgb(255, 204, 108);
}

body.dark-mode nav ul li a:hover {
    background-color: rgb(60, 45, 70);
}

body.dark-mode .container {
    background-color: rgb(50, 35, 60);
    box-shadow: 0 2px 10px rgba(0,0,0,0.5);
}

body.dark-mode .faq-question {
    background-color: rgb(60, 45, 70);
}

body.dark-mode .faq-question:hover {
    background-color: rgb(70, 55, 80);
}

body.dark-mode .faq-question h3 {
    color: rgb(255, 204, 108);
}

body.dark-mode .faq-icon {
    color: rgb(255, 100, 100);
}

body.dark-mode .faq-answer {
    background-color: rgb(50, 35, 60);
}

body.dark-mode .faq-answer p {
    color: rgb(200, 200, 200);
}

body.dark-mode .textBorder {
    background-color: rgb(60, 45, 70);
    color: rgb(230, 230, 230);
}

body.dark-mode .footer,
body.dark-mode .footerAbout {
    background-color: rgb(60, 45, 70);
}

body.dark-mode .logo {
    background-color: transparent;
}


/*Responsive : Phones*/

@media screen and (max-width: 600px){
    /*GENERAL*/
    body{
        font-size: 90%;
    }

    main {
        padding-top: 250px;
    }

    .firstTitle{
        font-size: 28px;
    }

    .titleSize{
        font-size: 24px;
    }

    /*CARDS*/
    .cards,
    .cardsList{
        flex-direction: column;
        align-items: center;
        width: 100%;
    }

    .cardsListName{
        width: 90%;
        margin-bottom: 20px;
    }

    .cards p{
        font-size: 90%;
        margin-bottom: 10px;
    }

    /*CONTACT*/
    .contact{
        flex-direction: column;
        align-items: center;
        gap: 10px;
        text-align: center;
    }

    /*FOOTER*/
    .footerFlex {
        flex-direction: column;
        text-align: center;
        gap: 10px;
    }

    .logo{
        width: 60px;
        margin: 10px 0;
    }
}

/* the title comes from the left and stops at the center with a little bounce after loading the page */
.animTitle{
    animation-name: slideFill;
    animation-duration: 2s;
    animation-timing-function: ease-in-out;
    animation-fill-mode: forwards;
}

@keyframes slideFill {
    0% {
        transform: translateX(-500px);
    }

    80% {
        transform: translateX(10px)
    }

    90% {
        transform: translateX(-10px)
    }

    100% {
        transform: translateX(0)
    }
}

/* the cards pulse, the one at the center pulsing a 0.5s after the others */
.animPulse{
    animation-name: pulse;
    animation-duration: 1s;
    animation-iteration-count: infinite;
}

@keyframes pulse {
    0% {
        transform: scale(1);
    }

    50% {
        transform: scale(1.05);
    }

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

.animPulse2{
    animation-delay: 0.5s;
}

/* the cards get a little bit bigger when the cursor hovers over them */
.animZoom{
    transition-duration: 1s;
    transition-property: transform;
}

.animZoom:hover{   
    transform: scale(1.20);
}

/* a loader pops on the screen after clicking the submit button, then disappear after 2s */
.animLoader {
    width: 100px;
    height: 100px;
    margin: auto;
    border-radius: 50%;
    border-top: solid 5px grey;
    animation: spin 0.8s linear infinite;
    display: none;
}

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

.animLoader.visible {
  display: block;
}

/* the form appears from the top when loading the page */
.animForm{
    animation-name: reveal;
    animation-duration: 1s;
    animation-fill-mode: forwards;
    animation-timing-function: ease-in-out;
}

@keyframes reveal {
    from {
        opacity: 0;
        transform: translateY(0)
    }

    to {
        opacity: 1;
        transform: translateY(30px)
    }
}
