/* =========================================================
   Component: header / classic
   Grand Academy Navbar — 3-state: transparent / fixed-white / inner-white.
   Uses CSS variables with fallbacks.
   ========================================================= */

.grand-top-bar {
    background-color: var(--topbar-bg, #0d2a5c);
    color: #fff;
    padding: 8px 0;
    font-size: 0.85rem;
    font-family: 'Roboto', sans-serif;
    position: relative;
    z-index: 1040;
}
.grand-top-bar a { color: #fff; text-decoration: none; margin-left: 20px; font-weight: 500; transition: color 0.2s ease; }
.grand-top-bar a:hover { color: var(--topbar-hover, #d11212); }
.grand-top-bar i  { margin-right: 6px; color: var(--topbar-hover, #d11212); }

.school-custom-font {
    font-family: 'Denmark', cursive, sans-serif;
    color: var(--primary-color, #0d2a5c);
    line-height: 1.1;
    letter-spacing: 0.5px;
    white-space: normal;
    word-wrap: break-word;
    max-width: 250px;
    display: inline-block;
    font-size: clamp(1.1rem, 3.5vw, 2.2rem);
    margin-top: 5px;
}
@media (min-width: 992px) {
    .school-custom-font { max-width: 400px; }
    .navbar-brand img   { height: 45px; }
}

#mainNavbar { transition: background-color 0.4s ease, box-shadow 0.4s ease, padding 0.3s ease; width: 100%; }

.navbar-absolute {
    position: absolute; z-index: 1030;
    background-color: rgba(255,255,255,0.15) !important;
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
    box-shadow: none !important;
    border-bottom: 1px solid rgba(255,255,255,0.3);
}
.navbar-fixed {
    position: fixed; top: 0; z-index: 1050;
    background-color: var(--navbar-scrolled-bg, #ffffff) !important;
    box-shadow: 0 4px 15px rgba(0,0,0,0.08) !important;
    animation: navSlideDown 0.4s ease forwards;
}
.navbar-inner {
    position: relative !important; z-index: 1030 !important;
    background-color: var(--navbar-scrolled-bg, #ffffff) !important;
    box-shadow: 0 4px 15px rgba(0,0,0,0.05) !important;
}
@keyframes navSlideDown {
    from { transform: translateY(-100%); }
    to   { transform: translateY(0); }
}

.navbar .nav-link {
    position: relative;
    padding-left: 0.5rem !important; padding-right: 0.5rem !important;
    transition: color 0.3s ease-in-out;
    white-space: nowrap;
    font-size: 0.95rem;
    color: var(--navbar-link-color, #333);
    text-transform: uppercase;
    font-weight: 600;
}
.navbar .nav-link::after {
    content: ''; position: absolute;
    bottom: 8px; left: 50%;
    transform: translateX(-50%) scaleX(0);
    width: 80%; height: 2px;
    background-color: var(--navbar-link-hover, #d11212);
    transition: transform 0.3s ease-in-out;
}
.navbar .nav-link:hover::after, .navbar .nav-link.active::after { transform: translateX(-50%) scaleX(1); }
.navbar .nav-link:hover, .navbar .nav-link.active { color: var(--navbar-link-hover, #d11212) !important; }

.dropdown-menu {
    border-radius: 8px; margin-top: 0;
    border: 1px solid rgba(255,255,255,0.4);
    background-color: rgba(255,255,255,0.85) !important;
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.1);
}
.dropdown-item { font-size: 0.9rem; font-weight: 500; padding: 8px 20px; transition: all 0.3s ease; background-color: transparent !important; }
.dropdown-item:hover { background-color: rgba(209,18,18,0.08) !important; color: var(--navbar-link-hover, #d11212); }
