/* Navbar styles */
#navbar {
    background: #1C2A48;
    background-size: cover;
    padding: 15px;
    border-bottom: 1px solid #657186;
    width: 100%;
    min-height: 80px;
    position: fixed;
    top: 0;
    left: 0;
    z-index: 1000; /* Higher than alerts */
}

#navbar .container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    max-width: 1200px;
    margin: 0 auto;
}

#navbar a {
    color: #FFFFFF; /* Pure white text */
    text-decoration: none;
    padding: 8px 12px;
    border-radius: 4px;
    margin-right: 10px;
    transition: all 0.3s ease;
    font-weight: 600; /* Make font slightly bolder */
    text-shadow: 0 1px 2px rgba(0,0,0,0.3); /* Subtle text shadow for better contrast */
    position: relative;
}

#navbar a:hover {
    background: rgba(255,255,255,0.2); /* Semi-transparent white hover */
    color: #FFFFFF;
}

#navbar a.active {
    background: #D64545; /* Use your accent red color for active state */
    color: white;
    box-shadow: 0 2px 5px rgba(0,0,0,0.2);
}

#navbar a::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 50%;
    width: 0;
    height: 2px;
    background: #D64545;
    transition: all 0.3s ease;
    transform: translateX(-50%);
}

#navbar a:hover::after {
    width: 80%;
}

/* Search form styles */
.search-container {
    display: flex;
    align-items: center;
}

.search-form {
    display: flex;
    margin-left: auto;
}

.search-form input[type="text"] {
    padding: 8px;
    border: 1px solid #657186;
    border-radius: 4px 0 0 4px;
    width: 200px;
    background: rgba(244,246,248,0.9); /* Slightly transparent */
    color: #1A1A1A;
}

.search-form button {
    padding: 8px 12px;
    background: #D64545;
    color: white;
    border: none;
    border-radius: 0 4px 4px 0;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

.search-form button:hover {
    background: #c03939; /* Darker red for hover */
    transform: scale(1.02); /* Slight scale effect */
}

.error-message {
    color: #FF6B6B; /* Brighter red for errors */
    font-size: 14px;
    margin-left: 10px;
    font-weight: 500;
}

/* ========== RESPONSIVE STYLES ========== */
/* Smartphone (640px and below) */
@media(max-width:640px) {
    #navbar {
        padding: 10px 5px;
        min-height: 60px;
    }
    
    #navbar .container {
        flex-wrap: wrap;
        justify-content: center;
    }
    
    #navbar a {
        padding: 6px 8px;
        margin-right: 5px;
        margin-bottom: 5px;
        font-size: 0.85rem;
    }
    
    .search-container {
        order: 1;
        width: 100%;
        margin-top: 10px;
        justify-content: center;
    }
    
    .search-form {
        width: 100%;
        max-width: 300px;
    }
    
    .search-form input[type="text"] {
        width: 100%;
    }
}

/* Tablet (768px and below) */
@media(max-width:768px) {
    #navbar {
        padding: 12px 8px;
    }
    
    #navbar .container {
        justify-content: space-around;
    }
    
    #navbar a {
        padding: 7px 10px;
        margin-right: 8px;
        font-size: 0.9rem;
    }
    
    .search-form input[type="text"] {
        width: 150px;
    }
}

/* Desktop (1200px and below) */
@media(max-width:1200px) {
    #navbar .container {
        padding: 0 15px;
    }
    
    .search-form input[type="text"] {
        width: 180px;
    }
}

/* Large desktops (1400px and below) */
@media(max-width:1400px) {
    #navbar .container {
        max-width: 1100px;
    }
}

/* Additional responsive tweaks for very small screens */
@media(max-width:480px) {
    #navbar a {
        font-size: 0.8rem;
        padding: 5px 6px;
    }
    
    #navbar {
        min-height: 50px;
    }
}






