@charset "utf-8";

:root {
  --nav-height: 48px;
}

.navbar {
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
  background: #ffba53;
  padding: 4px 16px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  position: relative;
  z-index: 1000;
}

.navbar .logo-link,
.navbar .menu-logo {
  display: none;
}

.navbar.fixed {
  position: fixed;
  top: 0;
  width: 100%;
  background-color: #ffba53df;
}

.navbar.fixed .logo-link,
.navbar.fixed .menu-logo {
  display: flex;
  /* position:absolute; */
  height: var(--nav-height);
}

nav ul {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: center;
  list-style: none;
  margin: 4px auto;
  max-width: 800px;
  /* overflow: hidden; */
  padding: 0;
}

nav li {
  border-radius: 8px;
  flex: 1;
  text-align: center;
  background: #f5f5f5;
  min-width: 120px;
  max-width: 160px;
}

nav .nav-list a {
  border-radius: 8px;
  color: black;
  display: inline-block;
  font-weight: bold;
  line-height: var(--nav-height);
  text-align: center;
  text-decoration: none;
  width: 100%;
}

nav .nav-list a.active {
  background: rgb(255, 221, 157);
}

nav .nav-list a:hover {
  background: rgb(255, 221, 157);
}

.menu-toggle {
  display: none;
  flex-direction: column;
  position: absolute;
  right: 20px;
  cursor: pointer;
}

.menu-toggle .bar {
  width: 30px;
  height: 4px;
  background-color: rgb(0, 0, 0);
  border-radius: 20px;
  margin: 2px 0;
  transition: 0.4s;
}

@media (max-width: 860px) {
  .menu-toggle {
    display: flex;
  }
  .menu-toggle .label {
    display: flex;
    font-size: 11px;
    margin-left: -5px;
  }

  .navbar .menu-logo {
    display: block;
    max-height: var(--nav-height);
  }

  .navbar {
    height: var(--nav-height);
  }

  .nav-list {
    align-items: center;
    background-color: #ffba53df;
    border-radius: 0 0 16px 16px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.4);
    display: flex;
    flex-direction: column;
    margin: 0;
    max-width: 480px;
    opacity: 0;
    padding: 16px 32px;
    position: absolute;
    right: 0;
    top: var(--nav-height);
    transform: translateY(-10px);
    transition: all 0.5s ease;
    visibility: hidden;
    width: 100%;
  }

  .nav-list li {
    max-width: 100%;
    width: 100%;
  }

  .nav-list.active {
    opacity: 1;
    transform: translateY(0);
    visibility: visible;
  }
}