/* File: header.css */

/* === Header Container === */
/* === Header Container === */
header {
  background: linear-gradient(180deg, #2a2a2a, #444444);
  color: #f4efe7;
  display: flex;
  align-items: center;
  justify-content: space-between;
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  width: 100%;
  box-sizing: border-box;
  z-index: 100;

  max-height: 60px;   /* 🔹 bikin tinggi header konsisten */
  padding: 0 5px;    /* 🔹 beri padding horizontal */
}


/* === Header Text === */
header h5 {
  margin: 0;
  font-size: 1.2em;
  padding: 20px;
}

/* === Hamburger Menu === */
.hamburger {
  display: none;
  cursor: pointer;
  font-size: 24px;
  padding: 20px;
  transition: transform 0.3s;
}

.hamburger:active {
  transform: scale(0.95);
}

/* === Navbar Styling === */
nav {
  margin-left: auto;
}

nav ul {
  list-style: none;
  display: flex;
  justify-content: flex-end;
  align-items: center;
  padding: 0;
  margin: 0;
}

nav ul li {
  margin: 0 15px;
}

nav ul li a {
  color: #f4efe7;
  text-decoration: none;
  position: relative;
  transition: color 0.5s;
}

nav ul li a::after {
  content: '';
  position: absolute;
  left: 0;
  bottom: -10px;
  width: 100%;
  height: 1px;
  background-color: #f4efe7;
  transform: scaleX(0);
  transition: transform 0.3s;
}

nav ul li a:hover::after {
  transform: scaleX(1.2);
}

/* === Visibility Class Handling === */
.navbar-hidden {
  display: none !important;
}

.visible {
  display: flex;
  flex-direction: column;
  position: absolute;
  top: 60px;
  right: 30px;
  background-color: #333;
  padding: 30px 50px;
  border-radius: 5px;
  z-index: 99;
}

/* === Mobile: Responsive === */
@media screen and (max-width: 996px) {
  .hamburger {
    display: block;
  }

  nav {
    position: relative;
  }

  nav ul {
    flex-direction: column;
    align-items: center;
  }

  nav ul li {
    margin: 10px 0;
  }
}

/* === Desktop: Show Navbar Without Hamburger === */
@media screen and (min-width: 997px) {
  nav#navbar {
    display: flex !important;
    position: static;
    flex-direction: row;
    background: none;
    padding: 0;
    border-radius: 0;
  }

  .hamburger {
    display: none !important;
  }

  .navbar-hidden,
  .visible {
    display: flex !important;
    flex-direction: row;
    position: static;
  }
}
