@font-face {
    font-family: 'theseasons';
    src: url('./fonts/the-seasons-regular.ttf');
}
@font-face {
    font-family: 'theseasons-bold';
    src: url('./fonts/the-seasons-bold.ttf');
}
@font-face {
    font-family: 'theseasons-light';
    src: url('./fonts/the-seasons-light.ttf');
}
@font-face {
    font-family: 'playfair';
    src: url('./fonts/PlayfairDisplay-VariableFont_wght.ttf');
}

:root {
  --light-gray: #f4f4f4;
  --light-green: #9DAF99;
  --green: #788672;
  --dark-green: #495849;
  --darker-green: #2D342D;
  --black: var(--darker-green);
  --border-radius: 3px;
}

html {
  scroll-behavior: smooth;
}

body {
  background-color: var(--light-gray);
  font-family: 'theseasons-bold';
  color: var(--black);
  margin: 0;
  padding: 3rem 0 1rem;
  overflow: hidden;
}

h1 {
  color: var(--green);
  margin: 3rem 0 1rem;
  text-align: center;
  font-size: 1.5rem;
  font-family: theseasons;
  font-weight: 500;
}


.mobile {
  display: block;
}
.desktop {
  display: none;
}

.button {
  font-family: playfair;
  text-align: center;
  background-color: var(--darker-green);
  color: white;
  text-decoration: none;
  font-size: 0.7rem;
  padding-bottom: 0.25rem;
  font-weight: 500;
  border-radius: var(--border-radius);
  transition: 0.3s;
  &:hover {
    opacity: 0.65;
  }
  width: 7rem;
  margin-top: 1rem;
  &.disabled {
    cursor: not-allowed;
    opacity: 0.5;
  }
}

.anchor-top {
  position: absolute;
  top: -3rem
}
.anchor {
  margin-top: -1.5rem;
  height: 1.5rem;
}

.bar {
  background-color: var(--black);
  width: 1px;
}

.topbar {
  position: fixed;
  margin-top: -3rem;
  z-index: 5;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0.5rem;
  height: 2rem;
  width: calc(100vw - 1rem);
  background-color: var(--light-gray);
  .ls {
    height: 1.75rem;
  }
  .right-buttons {
    position: absolute;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    top: 0;
    right: 0rem;
    padding: 0.5rem;
    height: 2rem;
    a {
      transition: 0.3s;
      &:hover {
        opacity: 0.5;
      }
      img {
        height: 1.5rem;
      }
    }
  }
}

.main-picture {
  position: relative;
  height: 25vh;
  width: 100vw;
  background: top url('montavent-couleur.jpg');
  background-size: cover;
  background-position: center bottom;
  color: white;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  font-family: theseasons;
  .mask {
    z-index: 1;
    position: absolute;
    height: 100%;
    width: 100%;
    background-color: #31313161;
  }
  h2 {
    z-index: 2;
    font-family: theseasons-light;
    font-weight: 600;
    font-size: 1.5rem;
    line-height: 2rem;
    margin: 0;
  }
  h1 {
    z-index: 2;
    font-size: 1.5rem;
    line-height: 2rem;
    margin: 0;
    color: white;
  }
}

.compte-a-rebours {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  height: 6rem;
  .tick {
    font-size: 1.5rem;
    font-family: theseasons;
  }
  .unite {
    font-size: 1rem;
    font-family: playfair;
    font-style: italic;
    color: var(--black);
  }
  .tick-flip-panel {
    background-color: var(--darker-green);
  }
}

.liste-mariage, .photos {
  display: flex;
  width: 100vw;
  .texte {
    flex: 1;
    display: flex;
    justify-content: normal;
    position: relative;
    background-color: white;
    .centered-box {
      display: flex;
      flex-direction: column;
      align-items: flex-start;
      padding: 1rem 1.5rem;
      h1 {
        text-align: left;
        font-family: theseasons;
        font-weight: 500;
        font-size: 1.25rem;
        margin: 0;
        margin-bottom: 0.5rem;
        color: var(--green);
      }
      p {
        color: var(--black);
        font-family: playfair;
        font-size: 0.6rem;
        margin: 0 0 0.5rem;
        margin-bottom: auto;
      }
    }
  }
  .image {
    flex: 1;
    img {
      width: 100%;
      height: 100%;
      object-fit: cover; /* l’image remplit la div sans déformation */
      display: block;
    }
  }
}

.adresses {
  #map {
    margin: 0 2rem 2rem;
    height: 30vh;
    border-radius: var(--border-radius);
  }
  .liste-adresses {
    display: flex;
    margin-bottom: 2rem;
    .adresse {
      flex: 1;
      display: flex;
      flex-direction: column;
      align-items: center;
      text-decoration: none;
      cursor: pointer;
      transition: opacity 0.2s;
      h1 {
        font-family: theseasons;
        color: var(--black);
        margin: 0 0 0.25rem;
      }
      h2, p {
        text-align: center;
        font-family: playfair;
        color: var(--black);
        margin: 0;
      }
      h2 {
        font-size: 0.75rem;
        line-height: 0.75rem;
        font-weight: 600;
        margin-bottom: 0.35rem;
      }
      p {
        line-height: 0.85rem;
        width: 75%;
        font-size: 0.75rem;
      }
      &:hover {
        opacity: 0.75;
      }
    }
  }
  .indications {
    font-family: playfair;
    padding: 0 2rem;
    p {
      font-size: 0.75rem;
      line-height: 0.75rem;
      margin-top: 0;
      margin-bottom: 0.5rem;
    }
  }
  .dessin {
    display: flex;
    justify-content: center;
    margin: 2rem 0 -2rem;
    img {
      height: auto;
      width: 70%;
    }
  }
}

.planning {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  .bar {
    position: absolute;
    z-index: 0;
    top: 0;
    height: 100%;
    width: 1px;
  }
  .planning-container {
    z-index: 1;
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    margin-top: 1rem;
    .item {
      display: flex;
      flex-direction: column;
      align-items: center;
      background-color: white;
      border: 0.5px solid var(--black);
      margin-bottom: 1rem;
      border-radius: var(--border-radius);
      padding: 0.5rem 1rem;
      h1 {
        font-size: 1.25rem;
        margin: 0;
      }
      h2 {
        font-family: playfair;
        color: var(--black);
        margin: 0;
        font-size: 1rem;
        font-weight: 600;
      }
      h3 {
        font-family: playfair;
        font-style: italic;
        color: var(--black);
        margin: 0;
        font-size: 0.65rem;
        font-weight: 400;
      }
    }
  }
}

.photos {
  .divided {
    display: flex;
    img {
      height: 4.4rem;
      padding: 0.5rem 0 0.5rem 1em;
    }
  }
}

.galerie {
  position: relative;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.25rem;
  justify-items: center; 
  margin-top: 4rem;
  width: 100vw;
  .image {
    position: relative;
    width: 100%;         
    aspect-ratio: 1 / 1; 
    background-size: cover;
    background-position: center;
    cursor: pointer;
    transition: 0.3s;
    &:hover {
      opacity: 0.7;
    }
    img {
      opacity: 0;
      height: 100%;
      width: 100%;
    }
  }

  .image-1 { background-image: url(galerie/1.png); }
  .image-2 { background-image: url(galerie/2.png); }
  .image-3 { background-image: url(galerie/3.png); }
  .image-4 { background-image: url(galerie/4.png); }
  .image-5 { background-image: url(galerie/5.png); }
  .image-6 { background-image: url(galerie/6.png); }
}

.protection {
  top: 0;
  left: 0;
  position: absolute;
  height: 100vh;
  width: 100vw;
  backdrop-filter: blur(20px);
  background-color: #FFFFFF84;
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
  .password-box {
    font-family: playfair;
    font-size: 1.25rem;
    display: flex;
    flex-direction: column;
    gap: 1rem;
    align-items: center;
    background-color: var(--light-gray);
    padding: 2rem;
    border: 1px solid var(--darker-green);
    border-radius: var(--border-radius);
    color: var(--dark-green);
    input {
      font-size: 1.25rem;
      font-family: 'theseasons-bold';
      background-color: transparent;
      text-align: center;
      height: 2rem;
      border: none;
      border-bottom: 3px solid var(--light-green);
      &::placeholder {
        font-size: 1rem;
        opacity: 0.5;
      }
    }
    .submit {
      all: unset;
      font-size: 1rem;
      width: calc(100% - 4rem);
      cursor: pointer;
      font-family: playfair;
      text-align: center;
      background-color: var(--darker-green);
      color: white;
      text-decoration: none;
      padding: 0rem 2rem 0.25rem;
      font-weight: 500;
      border-radius: var(--border-radius);
      transition: 0.3s;
      &:hover {
        opacity: 0.65;
      }
    }
  }
}