html {
  scroll-behavior: smooth;
}

body {
    background: #212121;
    color: #fff;
    font-size: 16px;
    font-family: "Elms Sans", system-ui, 'Open Sans';
    font-weight: normal;
    margin: 0;
    &.modal-open {
        overflow: hidden;
    }
}

header{
    margin: 0 auto;
    align-items: center;
    text-align: center;
    display: flex;
    flex-flow: row wrap;
    align-items: center;
    justify-content: space-between;
    border-bottom: 1px #fff solid;
    background-color : #181818;
    padding: 0 20px;
    .logoContainer {
      display: flex;
      flex-flow: row wrap;
    }
    h1{
        display: flex;
        align-items: center;
        text-align: center;
        z-index: 1;
        text-underline-offset: 15px;
    }
    .logo{
        max-width: 200px;
        position: relative;
        z-index: 0;
    }
    nav {
    display: flex;
    gap: 25px;
    max-width: max-content;
    align-items: center;

    a {
        color: #fff;
        text-decoration: none;
        border: 1px #fff solid;
        padding: 12px;
        min-width: 50px;
        text-align: center;
        border-radius: 12px;
        display: flex;
        align-items: center;
        justify-content: center;

        &:hover {
            color: #f58e8e;
        }
    }
}
}

#container {
    display: flex;           
    flex-wrap: wrap;         
    gap: 10px;              
    align-items: stretch;   
    justify-content: center;
}

.section {
    max-width: 90%;
    margin: 50px auto ;
    padding: 25px;
    background-color : #262626;
    border-radius: 25px;
}
#contact {
  
  display: flex;
  flex-direction: column;
  span a {
    color: #fff;
    text-decoration: none;
    &:hover {
      text-decoration: underline;
    }
  }
}


/* Images */
#container img {
    height: 200px;          
    width: 100%;            
    object-fit: cover;      
    flex: 1 1 auto;         
    min-width: 150px;       
    max-width: 100%;       
    border-radius: 12.5px; 
    height: auto;
    max-height: 27em;
}



/* modal */
.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.97);
    overflow: auto;
    justify-content: center;
    align-items: center;
}

.modal-content {
    max-width: 90%;
    max-height: 90%;
    margin: auto;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 12px white solid;
}

.close {
    position: absolute;
    top: 20px;
    right: 30px;
    color: white;
    font-size: 35px;
    font-weight: bold;
    cursor: pointer;
}

/* Footer */
footer {
    background-color: #181818;
    padding: 50px;
    font-size: 14px;
    text-align: center;
}



.filters {
  display: flex;
  justify-content: flex-start;
  gap: 2rem;
  flex-wrap: wrap;
  align-items: center;
  margin-bottom: 1.5rem;
  padding: 1rem;
  align-items: end;
}

.filter-group {
  display: flex;
  flex-direction: row;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.3rem;
  font-family: "Inter", sans-serif;
  color: #eee;
}

.filter-group label {
  font-size: 0.9rem;
  opacity: 0.8;
}

.filter-group select {
  background-color: #111;
  color: #eee;
  border: 1px solid #444;
  border-radius: 8px;
  padding: 0.5rem 1rem;
  font-size: 0.95rem;
  cursor: pointer;
  transition: all 0.2s ease;
  appearance: none;
}

.filter-group select:hover {
  border-color: #888;
  background-color: #1a1a1a;
}

.filter-group select:focus {
  outline: none;
  border-color: #fff;
}

.reset-btn {
  background: none;
  border: 1px solid #444;
  color: #eee;
  border-radius: 8px;
  padding: 0.5rem 0.8rem;
  font-size: 1rem;
  cursor: pointer;
  transition: all 0.2s ease;
  align-self: flex-end;
    background-color: #111111;
}

.reset-btn:hover {
  background-color: #1a1a1a;
  border-color: #888;
  color: #fff;
}

.reset-btn i {
  pointer-events: none; /* pour éviter les clics sur l'icône au lieu du bouton */
}

@media (max-width: 768px) {
  .reset-btn {
    align-self: center;
    margin-top: 0.8rem;
  }
}

.img-ctnr {
  max-width: 98%;
  margin: auto;
  display: flex;
  flex-flow: row wrap;
  justify-content: space-between;
  align-items: baseline;
  h2 {
    text-align: center;
    font-size: 3rem;
  }
}





h2 {
  text-decoration: overline;
    font-weight: 100;
    font-family: "Climate Crisis", sans-serif;
}

#about {
  div {
    display: flex;
    flex-flow: row wrap;
    align-items: center;
    justify-content: space-between;
    
    div {
        max-width: calc(100% - 300px);
    }
  }
  img {
    width: 300px;
  }
  
  quote {
    font-size: 22px;
  }
}


.img-wrapper {
    position: relative;
    display: flex;
    overflow: hidden;
    flex: auto;
}

.img-wrapper img {
    display: block;
    width: 100%;
    height: auto;
    transition: transform 0.4s ease;
}

.img-wrapper:hover img {
    transform: scale(1.05);
}

.img-overlay {
    content: "";
    position: absolute;
    bottom: 0;
    left: 0;
    height: 100%; /* couvre toute la photo */
    background: rgba(0, 0, 0, 0.6);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.3s ease;
    font-size: 1rem;
    text-align: center;
    padding: 0 21px;
    width: calc(100% - 42px);
}

.img-wrapper:hover .img-overlay {
  pointer-events: none;
    opacity: 1;
}


@media screen and (max-width: 768px) {
  #about div {
      flex-direction: column ;
      div {
        max-width: 100% ;
      }
  }
  .logoContainer {
    justify-content: center;
  }  
}

@media all and (max-width: 1024px){
  header {
    flex-direction: column;
  }
  nav {
    margin-bottom: 2em;
  }
  .img-ctnr h2 {
    width: 100%;
  }
  .filters {
    width: 100%;
    justify-content: center;
    .filter-group {
      flex-direction: column;
    }
  }
}

@media all and (max-width: 540px){
  .section{
    margin: 20px 20px;
  }
  .insta {
    display: none;
  }
  .img-ctnr h2 {
    font-size: 40px;
  }
}

@media all and (min-width: 768px) and (max-width: 1024px){
  .img-ctnr h2 {
    margin: 50px auto 20px auto;
  }
}