/* header.css */
header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 20px;
    border-bottom: 1px solid #e0e0e0;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    font-family: Arial, sans-serif;
    background: rgba(100, 200, 230, 0.8);
}

h1 {
    margin: 0;
    font-size: 24px;
    color: #333333;
}

nav {
    display: flex;
    align-items: center;
    margin: 0;
}

nav a {
    text-decoration: none;
    color: #007bff; /* Blue link color */
    font-weight: bold;
}

nav a:hover {
    color: #0056b3; /* Darker blue on hover */
}

form {
    display: flex;
    align-items: center;
    margin-left: auto;
}

input[type="text"] {
    padding: 8px 12px;
    border: 1px solid #cccccc;
    border-radius: 4px 0 0 4px;
    font-size: 14px;
}

input[type="text"]:disabled {
    background-color: #f0f0f0;
    cursor: not-allowed;
}

button {
    padding: 8px 12px;
    background-color: #007bff;
    color: #ffffff;
    border: none;
    border-radius: 0 4px 4px 0;
    cursor: pointer;
    font-size: 14px;
}

button:hover {
    background-color: #0056b3;
}

/* Modern navbar styling */
.navbar {
    background-color: #ffffff !important; /* Clean white background */
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1); /* Subtle shadow for depth */
    font-family: 'Arial', sans-serif; /* Modern font */
    font-weight: 500;
    width: 100%;
    margin: 0 20px;
}

.navbar-brand {
    font-size: 1.5rem;
    font-weight: bold;
    color: #007bff; /* Blue for brand */
}

.nav-link {
    color: #333 !important; /* Darker text for readability */
    transition: color 0.3s ease;
}

.nav-link:hover {
    color: #007bff !important; /* Hover color */
}

/* Inline dropdown toggle */
.nav-item.dropdown {
    display: flex;
    align-items: center;
}

.nav-item.dropdown .nav-link {
    padding-right: 0.25rem !important; /* Adjust padding for inline feel */
}

.nav-item.dropdown .dropdown-toggle {
    padding-left: 0.25rem !important;
    border-left: none; /* Remove any split borders if present */
}

/* Dropdown on hover */
@media (min-width: 992px) { /* Hover only on desktop */
    .nav-item.dropdown:hover .dropdown-menu {
        display: block;
        border-radius: 0.5rem; /* Rounded corners for modern look */
        box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15); /* Shadow for dropdown */
        border: none; /* Remove border for cleaner look */
    }
}

.dropdown-menu {
    background-color: #ffffff; /* White background */
    position: absolute;
    top: 100%;
    left: 0;
    padding: 0;
}

.dropdown-item {
    color: #333;
    transition: background-color 0.3s ease;
}

.dropdown-item:hover {
    background-color: #f8f9fa; /* Light hover background */
    color: #007bff;
}

/* Search form styling */
.form-control {
    border-radius: 0.5rem;
    border: 1px solid #ced4da;
}

.btn-outline-success {
    border-radius: 0.5rem;
    transition: background-color 0.3s ease, color 0.3s ease;
    padding: 0.375rem 0.5rem; /* Reduced horizontal padding for tighter fit around text */
    width: auto; /* Ensure it doesn't stretch */
    white-space: nowrap; /* Prevent text wrapping */
    overflow: visible; /* Ensure no cutoff */
    min-width: fit-content; /* Fit to content */
}

.btn-outline-success:hover {
    background-color: #28a745;
    color: #fff;
}

/* Mobile Optimizations */
@media (max-width: 991px) {
    .navbar-nav {
        padding: 0.5rem 0; /* Add padding for mobile menu */
    }
    .nav-item {
        margin-bottom: 0.5rem; /* Space between items */
    }
    .nav-item.dropdown {
        flex-direction: column;
        align-items: flex-start;
    }
    .nav-item.dropdown .nav-link {
        padding-right: 0 !important;
        width: 100%;
    }
    .nav-item.dropdown .dropdown-toggle {
        padding-left: 0 !important;
        width: 100%;
    }
    .dropdown-menu {
        position: static;
        margin-top: 0;
        box-shadow: none;
        border: none;
        background-color: transparent; /* Blend with mobile menu */
    }
    .dropdown-item {
        padding-left: 1rem; /* Indent sub-items */
    }
    .form-control {
        font-size: 0.95rem; /* Slightly smaller on mobile */
    }
    .btn-outline-success {
        font-size: 0.95rem;
        padding: 0.375rem 0.5rem; /* Consistent reduced padding on mobile */
        white-space: nowrap; /* Prevent text wrapping */
        overflow: visible; /* Ensure no cutoff */
        min-width: fit-content; /* Fit to content */
    }
    .navbar-brand {
        font-size: 1.25rem; /* Smaller brand on mobile */
    }
    .nav-link {
        font-size: 1rem; /* Adjust nav link size */
    }
}

/* Improve touch targets */
.nav-link, .dropdown-item, .btn {
    min-height: 44px;
    display: flex;
    align-items: center;
}

/* Header full width */
header {
    width: 100%; /* Full width coverage */
    padding-left: 0;
    padding-right: 0;
}

.container-fluid {
    padding-left: 0; /* Remove side padding for full-width effect */
    padding-right: 0;
}