/* navbar.css */
header {
  background-color: #fff4eb; /* Light orange/cream background */
  padding: 1rem 2rem;
  border-bottom: 2px solid #b34d6d; /* Dark pink/maroon border */
  box-shadow: 0 2px 5px rgba(0,0,0,0.05); /* Subtle shadow */
  font-family: 'Poppins', sans-serif;
}

.nav-container {
  display: flex;
  align-items: center;
  max-width: 100%; /* Optional: Constrain max width of navbar content */
  margin: 0 auto; /* Optional: Center the navbar content */
}

/* Menu Icon (Hamburger) */
.menu-icon {
    color: #9b2d4d; /* Darker pink/maroon */
    font-size: xx-large; /* Equivalent to about 32px-36px depending on browser */
    margin-right: 15px;
    cursor: pointer;
}

/* Logo */
.logo {
  font-family: 'Poppins', sans-serif;
  font-weight: bold;
  color: #b34d6d; /* Dark pink/maroon */
  font-size: 35px;
  margin-right: auto; /* Pushes the nav and dropdown to the right */
  text-decoration: none; /* Remove underline from link */
  cursor: pointer;
  transition: color 0.3s ease;
}

.logo:hover {
    color: #9b2d4d; /* Darker on hover */
}

/* Main Navigation Links */
nav {
  margin-right: 20px; /* Space between nav and search/profile */
}

nav a {
  margin: 0 1rem;
  text-decoration: none;
  color: #b34d6d; /* Dark pink/maroon */
  font-weight: bold;
  font-family: 'Poppins', sans-serif;
  position: relative;
  transition: color 0.3s ease;
  font-size: 1.05rem; /* Slightly larger font */
}

/* Underline effect on hover */
nav a::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -4px; /* Position below text */
  width: 100%;
  height: 2px;
  background-color: #b34d6d;
  transform: scaleX(0); /* Hidden by default */
  transform-origin: left;
  transition: transform 0.3s ease;
}

nav a:hover {
  color: #9b2d4d; /* Darker on hover */
}

nav a:hover::after {
  transform: scaleX(1); /* Reveal underline on hover */
}

/* Search Box */
.search-box {
  position: relative;
  display: flex; /* Ensures icon and input align */
  align-items: center;
  margin-right: 20px; /* Space between search and profile */
}

.search-box ion-icon {
  position: absolute;
  left: 10px; /* Position icon inside input field */
  color: #b34d6d;
  font-size: 18px;
}

.search-box input {
  padding: 0.5rem 0.8rem 0.5rem 2.2rem; /* Left padding for icon */
  border: 1px solid #d9a7a7; /* Light red/pink border */
  border-radius: 20px; /* Rounded corners */
  font-family: "Poppins", sans-serif;
  font-size: 0.9rem;
  outline: none; /* Remove default outline on focus */
  background-color: #fffaf5; /* Slightly off-white background */
  transition: border-color 0.3s ease, box-shadow 0.3s ease;
}

.search-box input:focus {
    border-color: #b34d6d; /* Highlight border on focus */
    box-shadow: 0 0 5px rgba(179, 77, 109, 0.3);
}

/* Profile Icon (part of dropdown) */
.profile {
  width: 38px; /* Adjusted size for better visual balance */
  height: 38px;
  border-radius: 50%;
  margin-left: 0; /* No extra margin here as it's part of the dropdown */
  cursor: pointer;
  object-fit: cover;
  border: 2px solid transparent; /* Transparent border for hover effect */
  transition: border-color 0.3s ease;
}

.profile:hover {
    border-color: #b34d6d; /* Highlight border on hover */
}

/* Dropdown specific styles */
.dropdown {
    position: relative;
    /* No margin-left here; it handles its own positioning within nav-container */
}

.dropdown-label {
    cursor: pointer;
    display: block; /* Ensures the label acts as a block for the image */
}

/* Hidden checkbox to control dropdown (from your provided CSS) */
#dropdown-btn:checked ~ .dropdown-content {
  display: block;
}

.dropdown-content {
  display: none; /* Hidden by default */
  position: absolute;
  background-color: #f9f9f9;
  min-width: 160px;
  box-shadow: 0px 8px 16px 0px rgba(0,0,0,0.2);
  z-index: 1000; /* Ensure it appears above other content */
  right: 0; /* Align to the right of the dropdown container */
  top: 100%; /* Position below the profile icon */
  border-radius: 5px;
  margin-top: 10px; /* Space between icon and dropdown menu */
}

.dropdown-content a {
  color: #333;
  padding: 12px 16px;
  text-decoration: none;
  display: block;
  text-align: left;
  transition: background-color 0.2s ease;
  font-family: "Courier Prime", monospace; /* Apply font to dropdown links */
  font-size: 0.95rem;
}

.dropdown-content a:hover {
  background-color: #ddd;
}

/* Optional: First and last child styling for rounded corners */
.dropdown-content a:first-child {
    border-top-left-radius: 5px;
    border-top-right-radius: 5px;
}

.dropdown-content a:last-child {
    border-bottom-left-radius: 5px;
    border-bottom-right-radius: 5px;
}


/* Dashboard Section - Provided in your CSS */
.dashboard-section {
  padding: 40px;
  background-color: #fff4eb; /* Matches header background */
  min-height: calc(100vh - 80px); /* Adjust height considering header padding and border */
  box-sizing: border-box; /* Include padding in height calculation */
}

/* Responsive Adjustments */
@media (max-width: 992px) {
    .nav-container {
        padding: 0 15px; /* Less padding on smaller screens */
    }

    nav {
        margin-right: 10px;
    }

    nav a {
        margin: 0 0.7rem;
        font-size: 1rem;
    }

    .search-box {
        margin-right: 10px;
    }
}

@media (max-width: 768px) {
    .search-box {
        display: none; /* Only hide search box on small screens */
    }
    .main-nav {
        display: flex;
        flex-direction: row;
        gap: 0.5rem;
        background: none;
        position: static;
        width: auto;
        margin: 0;
        padding: 0;
    }
    .logo {
        font-size: 28px;
        margin-left: 15px;
    }
    .nav-container {
        justify-content: space-between;
    }
}

@media (max-width: 480px) {
    header {
        padding: 0.8rem 1rem;
    }

    .logo {
        font-size: 24px;
        margin-left: 0px;
    }

    .menu-icon {
        font-size: x-large;
    }

    .profile {
        width: 30px;
        height: 30px;
    }

    .dashboard-section {
        padding: 20px;
    }
}