/* Sticky Footer Layout */
html, body {
    height: 100%;
    margin: 0;
    padding: 0;
}

body {
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

main {
    flex: 1;
    display: flex;
    flex-direction: column;
}

/* Enhanced Navbar Styles */
.navbar-enhanced {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    box-shadow: 0 2px 20px rgba(0,0,0,0.1);
    padding: 12px 0;
    transition: all 0.3s ease;
    flex-shrink: 0;
}

.navbar-enhanced.scrolled {
    padding: 8px 0;
    box-shadow: 0 2px 30px rgba(0,0,0,0.15);
}

/* Enhanced Brand */
.enhanced-brand {
    color: white !important;
    font-weight: 700;
    font-size: 1.5rem;
    text-decoration: none;
    display: flex;
    align-items: center;
    transition: all 0.3s ease;
}

.enhanced-brand:hover {
    color: #f8f9fa !important;
    transform: scale(1.05);
}

.brand-icon {
    margin-right: 10px;
    transition: transform 0.3s ease;
}

.enhanced-brand:hover .brand-icon {
    transform: rotate(10deg);
}

.brand-text {
    background: linear-gradient(45deg, #ffffff, #e3f2fd);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* Enhanced Navigation Links */
.enhanced-nav-link {
    color: rgba(255,255,255,0.9) !important;
    font-weight: 500;
    padding: 8px 16px !important;
    margin: 0 2px;
    border-radius: 8px;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.enhanced-nav-link::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.2), transparent);
    transition: left 0.5s ease;
}

.enhanced-nav-link:hover {
    color: white !important;
    background: rgba(255,255,255,0.1);
    transform: translateY(-2px);
}

.enhanced-nav-link:hover::before {
    left: 100%;
}

.enhanced-nav-link.active {
    background: rgba(255,255,255,0.2);
    color: white !important;
}

/* Enhanced Navbar Search */
.navbar-search {
    margin: 0 15px;
}

.search-input-group {
    display: flex;
    border-radius: 25px;
    overflow: hidden;
    box-shadow: 0 3px 10px rgba(0,0,0,0.1);
    transition: all 0.3s ease;
}

.search-input-group:focus-within {
    box-shadow: 0 5px 20px rgba(0,0,0,0.2);
    transform: translateY(-1px);
}

.navbar-search-input {
    border: none;
    border-radius: 25px 0 0 25px;
    padding: 10px 15px;
    font-size: 0.9rem;
    background: rgba(255,255,255,0.95);
    transition: all 0.3s ease;
    min-width: 200px;
}

.navbar-search-input:focus {
    background: white;
    box-shadow: none;
    border-color: transparent;
}

.navbar-search-input::placeholder {
    color: #6c757d;
    font-style: italic;
}

.navbar-search-btn {
    background: #28a745;
    border: none;
    border-radius: 0 25px 25px 0;
    padding: 10px 15px;
    color: white;
    transition: all 0.3s ease;
}

.navbar-search-btn:hover {
    background: #218838;
    transform: scale(1.05);
    color: white;
}

.navbar-search-btn:active {
    transform: scale(0.95);
}

/* Enhanced Toggler */
.enhanced-toggler {
    border: 2px solid rgba(255,255,255,0.3);
    border-radius: 8px;
    padding: 6px 10px;
    transition: all 0.3s ease;
}

.enhanced-toggler:hover {
    border-color: rgba(255,255,255,0.5);
    background: rgba(255,255,255,0.1);
}

.enhanced-toggler:focus {
    box-shadow: 0 0 0 0.2rem rgba(255,255,255,0.25);
}

/* Enhanced Footer - Sticky at bottom */
.enhanced-footer {
    background: linear-gradient(135deg, #2c3e50 0%, #34495e 100%);
    color: white;
    padding: 30px 0;
    border-top: 3px solid #667eea;
    margin-top: auto;
    flex-shrink: 0;
}

.footer-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 15px;
}

.footer-brand {
    display: flex;
    align-items: center;
    gap: 8px;
}

.footer-icon {
    opacity: 0.8;
}

.footer-brand-text {
    font-weight: 600;
    font-size: 1.1rem;
    background: linear-gradient(45deg, #ffffff, #e3f2fd);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.footer-links {
    display: flex;
    align-items: center;
    gap: 15px;
}

.footer-link {
    color: rgba(255,255,255,0.8);
    text-decoration: none;
    transition: all 0.3s ease;
    padding: 5px 10px;
    border-radius: 5px;
}

.footer-link:hover {
    color: white;
    background: rgba(255,255,255,0.1);
}

.footer-separator {
    color: rgba(255,255,255,0.4);
}

.footer-copyright {
    color: rgba(255,255,255,0.7);
    font-size: 0.9rem;
}

/* Content area adjustments for pages that need containers */
.container-page {
    padding: 20px;
    flex: 1;
}

/* For pages that use container wrapper */
.container {
    flex: 1;
    display: flex;
    flex-direction: column;
}

.container main {
    flex: 1;
}

/* Hero section and full-width content adjustments */
.hero-section {
    flex-shrink: 0;
}

/* Responsive Design */
@media (max-width: 991px) {
    .navbar-search {
        margin: 10px 0;
        order: 3;
        width: 100%;
    }
    
    .search-input-group {
        width: 100%;
    }
    
    .navbar-search-input {
        min-width: auto;
        flex: 1;
    }
    
    .enhanced-nav-link {
        margin: 2px 0;
    }
}

@media (max-width: 768px) {
    .footer-content {
        flex-direction: column;
        text-align: center;
        gap: 10px;
    }
    
    .footer-links {
        flex-direction: column;
        gap: 8px;
    }
    
    .footer-separator {
        display: none;
    }
    
    .navbar-enhanced {
        padding: 8px 0;
    }
    
    .enhanced-brand {
        font-size: 1.3rem;
    }
}

@media (max-width: 576px) {
    .navbar-search-input {
        font-size: 0.85rem;
        padding: 8px 12px;
    }
    
    .navbar-search-btn {
        padding: 8px 12px;
    }
    
    .enhanced-nav-link {
        padding: 6px 12px !important;
    }
    
    .enhanced-footer {
        padding: 20px 0;
    }
}

/* Login partial enhancements */
.navbar-nav .nav-link.text-dark {
    color: rgba(255,255,255,0.9) !important;
    font-weight: 500;
    padding: 8px 16px !important;
    margin: 0 2px;
    border-radius: 8px;
    transition: all 0.3s ease;
}

.navbar-nav .nav-link.text-dark:hover {
    color: white !important;
    background: rgba(255,255,255,0.1);
    transform: translateY(-2px);
}

/* Animation for navbar items */
@keyframes fadeInDown {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.navbar-nav .nav-item {
    animation: fadeInDown 0.5s ease forwards;
}

.navbar-nav .nav-item:nth-child(1) { animation-delay: 0.1s; }
.navbar-nav .nav-item:nth-child(2) { animation-delay: 0.2s; }
.navbar-nav .nav-item:nth-child(3) { animation-delay: 0.3s; }
.navbar-nav .nav-item:nth-child(4) { animation-delay: 0.4s; }

/* Active page indicator */
.navbar-nav .nav-link.active,
.navbar-nav .nav-link[aria-current="page"] {
    background: rgba(255,255,255,0.2) !important;
    color: white !important;
}

/* Backdrop blur support */
@supports (backdrop-filter: blur(10px)) {
    .navbar-enhanced {
        backdrop-filter: blur(10px);
    }
}

.navbar-auth-link {
    color: #fff !important; /* White text for contrast */
    font-weight: 700;       /* Bolder font */
    letter-spacing: 0.04em; /* Slightly increased letter spacing */
    text-shadow:
        0 2px 8px rgba(60,0,60,0.18), /* Soft shadow for glow */
        0 0 2px #222,                  /* Subtle outline for contrast */
        0 0 1px #000;                  /* Extra outline for max contrast */
    font-size: 1.08em;      /* Slightly larger font */
    padding: 8px 18px !important;
    border-radius: 8px;
    transition: all 0.2s;
}

.navbar-auth-link:hover,
.navbar-auth-link:focus {
    color: #ffe066 !important; /* Soft yellow on hover for visibility */
    background: rgba(0,0,0,0.10); /* Subtle background for contrast */
    text-decoration: underline;
    text-shadow:
        0 2px 12px rgba(60,0,60,0.25),
        0 0 2px #222,
        0 0 1px #000;
}
