@import url("./fonts.css");

:root {
  --color-brown: #582900;
  --color-yellow: #ffb601;
  --color-blue: #00258c;
  --font-shoju: "Shojumaru";
  --font-special: "Special Elite";
  --font-rye: "Rye";
  --font-rubik: "Rubik Distressed";
}

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

ul {
  list-style: none;
}

a,
a:hover,
a:active,
a:focus,
a:visited {
  text-decoration: none;
  color: inherit;
}

header {
  position: relative;
  height: 160px;
  width: 100%;
  background-color: var(--color-brown);
  border: 3px solid var(--color-yellow);
  .logo-container {
    position: absolute;
    img {
      width: 160px;
      height: 160px;
    }
  }
  a,
  a:visited,
  a:active,
  a:focus {
    color: var(--color-yellow);
  }
  a:hover {
    color: #fffb01;
  }

  nav {
    position: relative;
    height: 100%;
    ul {
      height: 100%;
      display: flex;
      justify-content: center;
      align-items: center;
      gap: 20px;
      li {
        font-family: var(--font-rye);
        font-size: 32px;
        /* text-transform: uppercase; */
      }
      .login-button a {
        position: absolute;
        right: 20px;
        top: 50%;
        transform: translateY(-50%);
        padding: 16px 12px 8px 12px;
        background-color: var(--color-yellow);
        color: var(--color-brown);
        font-family: var(--font-special);
        border-radius: 3px;
        &:hover {
          color: #8b4100;
          background-color: #fffb01;
        }
        &:visited {
          color: var(--color-brown);
        }
      }
    }
  }
}

.burger {
  display: none;
}

main {
  background-image: url("../imgs/981.jpg");
  background-attachment: fixed;
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
}

footer {
  position: relative;
  height: 160px;
  width: 100%;
  background-color: var(--color-brown);
  border: 3px solid var(--color-yellow);
  color: var(--color-yellow);
  font-family: var(--font-shoju);
  font-size: 32px;
  text-align: center;
  align-content: center;
  .footer-container {
    display: flex;
    justify-content: center;
    align-items: center;
    margin-bottom: 1%;
    p {
      font-size: 65%;
      color: var(--color-yellow);
      width: 33%;
    }
    .avatar {
      justify-content: center;
      overflow: hidden;
      transform: translatey(0px);
      animation: float 6s ease-in-out infinite;
      img {
        width: 140px;
        /* height: 30%; */
        object-fit: cover;
        transition: all 0.3s ease-in-out;
      }
    }
  }
}

.footer-containerM {
  /* display: none; */
}

/******* image Footer **********/

@keyframes float {
  0% {
    transform: translatey(0px);
  }
  50% {
    transform: translatey(-25px);
  }
  100% {
    transform: translatey(0px);
  }
}

/**********Css pour modal**********/
.modal-window {
  position: fixed;
  top: 0;
  right: 0;
  bottom: 0;
  left: 0;
  z-index: 5;
  opacity: 0;
  pointer-events: none;
  transition: all 0.3s;
  backdrop-filter: blur(15px);
  &:target {
    visibility: visible;
    opacity: 6;
    pointer-events: auto;
  }
  & > div {
    width: 360px;
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    padding: 2em;
    background: #582900;
    color: var(--color-yellow);
    border: solid var(--color-yellow);
  }
  .modal-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    img {
      width: 50%;
    }
    .modal-close {
      font-size: 40px;
      &:hover {
        color: #fffb01;
      }
    }
    .formulaire {
      display: flex;
      flex-direction: column;
      align-items: center;
      justify-content: center;
      width: 100%;
      padding-bottom: 2%;
      border: none;
      input {
        width: 80%;
        padding: 10px;
        margin: 5px;
        border-radius: 5px;
        border: none;
        background-color: var(--color-yellow);
        color: noir;
        font-family: var(--font-rye);
        &:hover {
          color: #8b4100;
          background-color: #fffb01;
        }
        &:visited {
          color: var(--color-brown);
        }
      }
    }
  }
}

/**************************/

/* Responsive Tablets */
@media (max-width: 768px) {
  header {
    height: 100px;
    border: 2px solid var(--color-yellow);
    .logo-container {
      img {
        width: 100px;
        height: 100px;
      }
    }
    nav {
      ul {
        gap: 12px;
        li {
          font-size: 16px;
        }
      }
    }
  }
  footer {
    height: 160px;
    border: 2px solid var(--color-yellow);
    font-size: 28px;
  }

  .footer-container {
    p {
      width: 100%;
      margin-top: 6px;
    }
    p:last-child {
      margin-left: 20px;
    }
    img {
      width: 100%;
    }
  }

  .footer-containerM {
    display: none;
  }

  .avatar {
    justify-content: center;
    overflow: hidden;
    transform: translatey(0px);
    animation: float 6s ease-in-out infinite;
  }
}

/* Responsive Smartphones */
@media (max-width: 380px) {
  .desktop {
    display: none;
  }

  .login-button {
    background-color: red;
    a {
      position: absolute;
      right: 20px;
      top: 50%;
      transform: translateY(-50%);
      padding: 16px 12px 8px 12px;
      background-color: var(--color-yellow);
      color: var(--color-brown);
      font-family: var(--font-special);
      border-radius: 3px;
      &:hover {
        color: #8b4100;
        background-color: #fffb01;
      }
      &:visited {
        color: var(--color-brown);
      }
    }
  }

  .burger {
    z-index: 9;
    position: fixed;
    display: flex;
    align-items: center;
    justify-content: flex-start;
    top: 0;
    left: 0;
    right: 0;
    height: 80px;
    width: 100%;
    max-width: 380px;

    .burger-nav {
      position: fixed;
      text-align: center;
      display: flex;
      align-items: center;
      justify-content: center;
      top: 80px;
      left: 0;
      right: 0;
      height: 0;
      opacity: 1;
      overflow: hidden;
      width: 100%;
      max-width: 380px;
      ul {
        list-style: none;
        padding-left: 0;
        margin-top: 4px;
        flex-direction: column;
        gap: 0;
        li {
          text-align: center;
          font-size: 20px;
          padding-bottom: 6px;
        }
      }
    }

    .btn-burger {
      position: relative;
      display: flex;
      align-items: center;
      justify-content: center;
      width: 80px;
      height: 100%;
      cursor: pointer;
      transition: 0.4s;
      margin-left: 32px;
    }

    .icon-burger {
      display: block;
      position: relative;
      top: -8px;
      background-image: url(../imgs/header/skull-burger-top.png);
      background-size: contain;
      background-repeat: no-repeat;
      background-position-x: center;
      background-position-y: 0;
      width: 100%;
      height: 56px;
      transition: 0.4s;

      &::after,
      &::before {
        content: "";
        display: block;
        position: absolute;
        background-size: contain;
        background-repeat: no-repeat;
        background-position: center;
        width: 100%;
        height: 14px;
        transition: 0.4s;
      }
      &::after {
        background-image: url(../imgs/header/sword-burger-left.png);
        bottom: -12px;
        left: -4px;
        transform: rotate(22.5deg);
      }
      &::before {
        background-image: url(../imgs/header/sword-burger-right.png);
        bottom: -12px;
        left: 4px;
        transform: rotate(-22.5deg);
      }
    }

    .checkbox {
      display: none;

      &:checked {
        + label {
          height: 100%;
          .icon-burger {
            background-color: var(--color-brown);
            &::before,
            &::after {
              bottom: 0;
            }

            &::after {
              transform: rotate(-135deg);
              left: -32px;
            }

            &::before {
              transform: rotate(135deg);
              left: 32px;
            }
          }
        }
        ~ .burger-nav {
          z-index: 2;
          height: 248px;
          border-bottom: var(--color-yellow) solid 2px;
          background-color: var(--color-brown);
          ul {
            width: 100%;
            height: 100%;
            text-align: start;
            li {
              width: 100%;
              border: var(--color-yellow) solid 2px;
              border-top: none;
              padding: 12px 12px;
            }
          }
        }
      }
    }
  }

  /**********Css pour modal**********/
  .modal-window-smartphone {
    width: 100%;
    max-width: 380px;
    position: fixed;
    top: 0;
    right: 0;
    bottom: 0;
    left: 0;
    z-index: 5;
    opacity: 0;
    pointer-events: none;
    transition: all 0.3s;
    backdrop-filter: blur(15px);
    &:target {
      visibility: visible;
      opacity: 6;
      pointer-events: auto;
    }
    & > div {
      width: 100%;
      position: absolute;
      top: 50%;
      left: 50%;
      transform: translate(-50%, -50%);
      padding: 2em;
      background: #582900;
      color: var(--color-yellow);
      border: solid var(--color-yellow);
    }
    .modal-content {
      display: flex;
      flex-direction: column;
      align-items: center;
      justify-content: center;
      img {
        width: 50%;
      }
      .modal-close {
        font-size: 40px;
        &:hover {
          color: #fffb01;
        }
      }
      .formulaire {
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        width: 100%;
        padding-bottom: 2%;
        border: none;
        input {
          width: 80%;
          padding: 10px;
          margin: 5px;
          border-radius: 5px;
          border: none;
          background-color: var(--color-yellow);
          font-family: var(--font-rye);
          &:hover {
            color: #8b4100;
            background-color: #fffb01;
          }
          &:visited {
            color: var(--color-brown);
          }
        }
      }
    }
  }

  footer {
    height: 266px;
    .footer-container {
      display: flex;
      flex-direction: column;
      justify-content: center;
      align-items: center;

      p {
        font-size: 60%;
        color: var(--color-yellow);
        margin-bottom: 3%;
        text-align: center;
        margin-bottom: 5%;
        width: 100%;
      }
      p:first-child {
        order: 2;
      }

      p:last-child {
        order: 3;
      }
      .avatar {
        order: 1;
        img {
        }
      }
    }
  }
}
