/********** Template CSS **********/
:root {
    /* Primary Brand Colors */
    --primary: var(--primary);
    /* Pure Royal Blue */
    --primary-dark: #001a4d;
    --primary-light: #003399;

    /* Secondary/Accent Colors */
    --secondary: var(--secondary);
    /* Mustard Yellow */
    --secondary-light: var(--secondary-light);
    /* Light Mustard */

    /* Netural Colors */
    --dark: #0f172a;
    /* Slate 900 */
    --dark-blue: #000080;
    /* Keep existing legacy dark blue */
    --light: #f8fafc;
    /* Slate 50 */
    --gray: #64748b;
    /* Slate 500 */
    --white: #ffffff;

    /* Gradients */
    --gradient-primary: linear-gradient(135deg, var(--primary), var(--dark-blue));
    --gradient-accent: linear-gradient(135deg, var(--secondary), #B8860B);

    /* Shadows */
    --shadow-sm: 0 1px 2px 0 rgb(0 0 0 / 0.05);
    --shadow-md: 0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1);
    --shadow-lg: 0 10px 15px -3px rgb(0 0 0 / 0.1), 0 4px 6px -4px rgb(0 0 0 / 0.1);
    --shadow-glow: 0 0 15px rgba(218, 165, 32, 0.3);

    /* Typography */
    --font-heading: 'Nunito', sans-serif;
    --font-body: 'Heebo', sans-serif;
}

/* Glassmorphism Utilities */
.glass {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.glass-dark {
    background: rgba(0, 35, 102, 0.6);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.fw-medium {
    font-weight: 600 !important;
}

.fw-semi-bold {
    font-weight: 700 !important;
}

.back-to-top {
    position: fixed;
    display: none;
    right: 45px;
    bottom: 45px;
    z-index: 99;
}


/*** Spinner ***/
#spinner {
    opacity: 0;
    visibility: hidden;
    transition: opacity .5s ease-out, visibility 0s linear .5s;
    z-index: 99999;
}

#spinner.show {
    transition: opacity .5s ease-out, visibility 0s linear 0s;
    visibility: visible;
    opacity: 1;
}


/*** Button ***/
.btn {
    font-family: 'Nunito', sans-serif;
    font-weight: 600;
    transition: .5s;
}

.btn.btn-primary,
.btn.btn-secondary {
    color: #FFFFFF;
}

.btn-square {
    width: 38px;
    height: 38px;
}

.btn-sm-square {
    width: 32px;
    height: 32px;
}

.btn-lg-square {
    width: 48px;
    height: 48px;
}

.btn-square,
.btn-sm-square,
.btn-lg-square {
    padding: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: normal;
    border-radius: 0px;
}


/*** Navbar ***/
.navbar .dropdown-toggle::after {
    border: none;
    content: "\f107";
    font-family: "Font Awesome 5 Free";
    font-weight: 900;
    vertical-align: middle;
    margin-left: 8px;
}

.navbar-light .navbar-nav .nav-link {
    margin-right: 30px;
    padding: 25px 0;
    color: #FFFFFF;
    font-size: 15px;
    text-transform: uppercase;
    outline: none;
}

.navbar-light .navbar-nav .nav-link:hover,
.navbar-light .navbar-nav .nav-link.active {
    color: var(--primary);
}

@media (max-width: 991.98px) {
    .navbar-light .navbar-nav .nav-link {
        margin-right: 0;
        padding: 10px 0;
    }

    .navbar-light .navbar-nav {
        border-top: 1px solid #EEEEEE;
    }
}

/* Mobile-specific navbar contrast and accent tweaks */
@media (max-width: 991.98px) {

    /* Ensure collapsed menu has a clear background so links are readable */
    .navbar-collapse {
        background: #ffffff;
        padding-left: 1rem;
        padding-right: 1rem;
    }

    /* Make nav links dark on mobile for legibility and add yellow accent on hover/active */
    .navbar-light .navbar-nav .nav-link {
        color: var(--dark) !important;
        /* dark blue for contrast */
        padding: 12px 0;
        text-transform: uppercase;
    }

    .navbar-light .navbar-nav .nav-link:hover,
    .navbar-light .navbar-nav .nav-link.active {
        color: var(--secondary) !important;
        /* Mustard yellow accent */
        background: transparent !important;
    }

    /* Toggler styling: Highly visible blue button with white icon */
    .navbar-toggler {
        border: none !important;
        background-color: var(--primary) !important;
        padding: 8px 10px !important;
        border-radius: 6px;
        box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    }

    .navbar-toggler:focus {
        box-shadow: 0 0 0 3px rgba(0, 35, 102, 0.4) !important;
    }

    /* Use white SVG icon for maximum contrast */
    .navbar-toggler .navbar-toggler-icon {
        background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 30 30'%3e%3cpath stroke='white' stroke-linecap='round' stroke-miterlimit='10' stroke-width='2' d='M4 7h22M4 15h22M4 23h22'/%3e%3c/svg%3e") !important;
        width: 24px;
        height: 24px;
        display: block;
    }

    /* Remove the previous pseudo-element glyph */
    .navbar-toggler .navbar-toggler-icon::before {
        content: none !important;
    }

    /* Slight padding fix for mobile nav container */
    .navbar-nav.ms-auto.p-4.p-lg-0 {
        padding-top: 12px;
        padding-bottom: 12px;
    }
}

/* Make the collapsed mobile menu a clear, full-width overlay so links are always readable */
@media (max-width: 991.98px) {

    /* When the collapse is shown, make it sit under the navbar and overlay content */
    .navbar-collapse.show {
        display: block !important;
        position: absolute;
        top: 75px;
        /* matches .navbar height */
        left: 0;
        right: 0;
        background: #ffffff !important;
        z-index: 1051;
        padding-top: 0.5rem;
        padding-bottom: 0.5rem;
        box-shadow: 0 10px 30px rgba(0, 0, 0, 0.12);
        border-top: 1px solid rgba(0, 0, 0, 0.04);
    }

    /* Make nav links large, bold and separated for easier tapping */
    .navbar-light .navbar-nav .nav-link {
        color: var(--primary) !important;
        /* strong dark blue */
        font-weight: 700;
        font-size: 16px;
        padding: 14px 16px !important;
        display: block;
        border-bottom: 1px solid #f3f4f6;
    }

    /* Accent: light yellow background on hover/active for clarity */
    .navbar-light .navbar-nav .nav-link:hover,
    .navbar-light .navbar-nav .nav-link.active {
        color: #000000 !important;
        background: rgba(218, 165, 32, 0.12) !important;
        /* subtle mustard background */
    }

    /* Make the toggler clearly visible (yellow icon/border) */
    .navbar-toggler {
        border-color: var(--secondary) !important;
    }

    .navbar-toggler .navbar-toggler-icon::before {
        color: var(--secondary);
        /* mustard icon */
    }

    /* Ensure body content is not hidden under the overlay when opened (optional UX tweak) */
    body.nav-open {
        overflow: hidden;
    }
}

.navbar-light .navbar-brand,
.navbar-light a.btn {
    height: 75px;
}

.navbar-light .navbar-nav .nav-link {
    color: var(--dark);
    font-weight: 500;
}

.navbar-light.sticky-top {
    top: -100px;
    transition: .5s;
}

@media (min-width: 992px) {
    .navbar .nav-item .dropdown-menu {
        display: block;
        margin-top: 0;
        opacity: 0;
        visibility: hidden;
        transition: .5s;
    }

    .navbar .dropdown-menu.fade-down {
        top: 100%;
        transform: rotateX(-75deg);
        transform-origin: 0% 0%;
    }

    .navbar .nav-item:hover .dropdown-menu {
        top: 100%;
        transform: rotateX(0deg);
        visibility: visible;
        transition: .5s;
        opacity: 1;
    }
}


/*** Header carousel ***/
@media (max-width: 768px) {
    .header-carousel .owl-carousel-item {
        position: relative;
        min-height: 500px;
    }

    .header-carousel .owl-carousel-item img {
        position: absolute;
        width: 100%;
        height: 100%;
        object-fit: cover;
    }
}

.header-carousel .owl-nav {
    position: absolute;
    top: 50%;
    right: 8%;
    transform: translateY(-50%);
    display: flex;
    flex-direction: column;
}

.header-carousel .owl-nav .owl-prev,
.header-carousel .owl-nav .owl-next {
    margin: 7px 0;
    width: 45px;
    height: 45px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #FFFFFF;
    background: transparent;
    border: 1px solid #FFFFFF;
    font-size: 22px;
    transition: .5s;
}

.header-carousel .owl-nav .owl-prev:hover,
.header-carousel .owl-nav .owl-next:hover {
    background: var(--secondary) !important;
    /* Mustard Yellow */
    border-color: var(--secondary) !important;
    transform: scale(1.1);
    box-shadow: 0 5px 15px rgba(218, 165, 32, 0.4);
}

.page-header {
    background: linear-gradient(rgba(24, 29, 56, .7), rgba(24, 29, 56, .7)), url(../img/carousel-1.jpg);
    background-position: center center;
    background-repeat: no-repeat;
    background-size: cover;
}

.page-header-inner {
    background: rgba(15, 23, 43, .7);
}

.breadcrumb-item+.breadcrumb-item::before {
    color: var(--light);
}


/*** Section Title ***/
.section-title {
    position: relative;
    display: inline-block;
    text-transform: uppercase;
}

.section-title::before {
    position: absolute;
    content: "";
    width: calc(100% + 80px);
    height: 2px;
    top: 4px;
    left: -40px;
    background: var(--primary);
    z-index: -1;
}

.section-title::after {
    position: absolute;
    content: "";
    width: calc(100% + 120px);
    height: 2px;
    bottom: 5px;
    left: -60px;
    background: var(--primary);
    z-index: -1;
}

.section-title.text-start::before {
    width: calc(100% + 40px);
    left: 0;
}

.section-title.text-start::after {
    width: calc(100% + 60px);
    left: 0;
}


/*** Service ***/
.service-item {
    background: var(--light);
    transition: .5s;
}

.service-item:hover {
    margin-top: -10px;
    background: var(--secondary) !important;
    /* Mustard Yellow */
    transform: scale(1.02);
    box-shadow: 0 10px 25px rgba(218, 165, 32, 0.3);
}

.service-item * {
    transition: .5s;
}

.service-item:hover * {
    color: #1E3A8A !important;
    /* Dark Royal Blue for better contrast */
}


/*** Categories & Courses ***/
.category img,
.course-item img {
    transition: .5s;
}

.category a:hover img,
.course-item:hover img {
    transform: scale(1.1);
}


/*** Team ***/
.team-item img {
    transition: .5s;
}

.team-item:hover img {
    transform: scale(1.1);
}


/*** Testimonial ***/
.testimonial-carousel::before {
    position: absolute;
    content: "";
    top: 0;
    left: 0;
    height: 100%;
    width: 0;
    background: linear-gradient(to right, rgba(255, 255, 255, 1) 0%, rgba(255, 255, 255, 0) 100%);
    z-index: 1;
}

.testimonial-carousel::after {
    position: absolute;
    content: "";
    top: 0;
    right: 0;
    height: 100%;
    width: 0;
    background: linear-gradient(to left, rgba(255, 255, 255, 1) 0%, rgba(255, 255, 255, 0) 100%);
    z-index: 1;
}

@media (min-width: 768px) {

    .testimonial-carousel::before,
    .testimonial-carousel::after {
        width: 200px;
    }
}

@media (min-width: 992px) {

    .testimonial-carousel::before,
    .testimonial-carousel::after {
        width: 300px;
    }
}

.testimonial-carousel .owl-item .testimonial-text,
.testimonial-carousel .owl-item.center .testimonial-text * {
    transition: .5s;
}

.testimonial-carousel .owl-item.center .testimonial-text {
    background: var(--secondary) !important;
    /* Mustard Yellow */
}

.testimonial-carousel .owl-item.center .testimonial-text * {
    color: #FFFFFF !important;
}

.testimonial-carousel .owl-dots {
    margin-top: 24px;
    display: flex;
    align-items: flex-end;
    justify-content: center;
}

.testimonial-carousel .owl-dot {
    position: relative;
    display: inline-block;
    margin: 0 5px;
    width: 15px;
    height: 15px;
    border: 1px solid #CCCCCC;
    transition: .5s;
}

.testimonial-carousel .owl-dot.active {
    background: var(--secondary) !important;
    /* Mustard Yellow */
    border-color: var(--secondary) !important;
}


/*** Footer ***/
.footer {
    background: linear-gradient(135deg, var(--primary) 0%, var(--dark-blue) 100%) !important;
    color: #FFFFFF;
}

.footer .btn.btn-social {
    margin-right: 5px;
    width: 35px;
    height: 35px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #FFFFFF;
    font-weight: normal;
    border: 1px solid #FFFFFF;
    border-radius: 35px;
    transition: .3s;
    background: rgba(255, 255, 255, 0.1);
}

.footer .btn.btn-social:hover {
    color: var(--primary);
    background: var(--secondary);
    border-color: var(--secondary);
    transform: scale(1.1);
    box-shadow: 0 5px 15px rgba(218, 165, 32, 0.4);
}

.footer .btn.btn-link {
    display: block;
    margin-bottom: 5px;
    padding: 0;
    text-align: left;
    color: #FFFFFF;
    font-size: 15px;
    font-weight: normal;
    text-transform: capitalize;
    transition: .3s;
}

.footer .btn.btn-link::before {
    position: relative;
    content: "\f105";
    font-family: "Font Awesome 5 Free";
    font-weight: 900;
    margin-right: 10px;
}

.footer .btn.btn-link:hover {
    letter-spacing: 1px;
    color: var(--secondary);
    text-shadow: 0 0 5px rgba(218, 165, 32, 0.5);
}

.footer .copyright {
    padding: 25px 0;
    font-size: 15px;
    border-top: 1px solid rgba(255, 255, 255, 0.2);
    background: rgba(0, 35, 102, 0.8);
}

.footer .copyright a {
    color: var(--secondary);
    transition: all 0.3s ease;
}

.footer .copyright a:hover {
    color: var(--secondary-light);
    text-shadow: 0 0 5px rgba(255, 248, 220, 0.5);
}

.footer .footer-menu a {
    margin-right: 15px;
    padding-right: 15px;
    border-right: 1px solid rgba(255, 255, 255, 0.2);
    transition: all 0.3s ease;
}

.footer .footer-menu a:hover {
    color: var(--secondary);
    text-shadow: 0 0 5px rgba(218, 165, 32, 0.5);
}

.footer .footer-menu a:last-child {
    margin-right: 0;
    padding-right: 0;
    border-right: none;
}

/* Footer section titles and headings */
.footer h5,
.footer h6 {
    color: var(--secondary);
    text-shadow: 0 0 5px rgba(218, 165, 32, 0.3);
}

/* Footer text and descriptions */
.footer p {
    color: #FFFFFF;
    opacity: 0.9;
}

/* Footer contact info */
.footer .contact-info i {
    color: var(--secondary);
    margin-right: 10px;
}

/* Footer social media icons */
.footer .social-icons a {
    color: #FFFFFF;
    transition: all 0.3s ease;
}

.footer .social-icons a:hover {
    color: var(--secondary);
    transform: scale(1.2);
}

/* ===== ENHANCED FOOTER STYLES ===== */

/* Footer brand section */
.footer-brand h4 {
    font-weight: 700;
    letter-spacing: 1px;
}

.footer-features .d-flex {
    transition: all 0.3s ease;
}

.footer-features .d-flex:hover {
    transform: translateX(5px);
}

.footer-features i {
    font-size: 1.1rem;
}

/* Footer links */
.footer-links .btn-link {
    display: block;
    margin-bottom: 8px;
    padding: 0;
    text-align: left;
    color: #FFFFFF;
    font-size: 14px;
    font-weight: 500;
    text-transform: capitalize;
    transition: all 0.3s ease;
    text-decoration: none;
}

.footer-links .btn-link:hover {
    color: var(--secondary);
    transform: translateX(5px);
    text-shadow: 0 0 5px rgba(218, 165, 32, 0.5);
}

/* Footer programs */
.footer-programs .d-flex {
    transition: all 0.3s ease;
    padding: 8px 0;
}

.footer-programs .d-flex:hover {
    transform: translateX(5px);
    background: rgba(218, 165, 32, 0.1);
    border-radius: 8px;
    padding-left: 10px;
}

.footer-programs i {
    font-size: 1.1rem;
    min-width: 20px;
}

/* Footer contact */
.footer-contact .btn-sm-square {
    width: 35px;
    height: 35px;
    border-radius: 8px;
    transition: all 0.3s ease;
}

.footer-contact .btn-sm-square:hover {
    transform: scale(1.1);
    box-shadow: 0 5px 15px rgba(218, 165, 32, 0.4);
}

.footer-contact h6 {
    font-size: 0.9rem;
    margin-bottom: 5px;
}

.footer-contact p {
    font-size: 0.85rem;
    line-height: 1.4;
}

/* Social media buttons */
.btn-social {
    width: 40px;
    height: 40px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    border: none;
}

.btn-social:hover {
    transform: translateY(-3px) scale(1.1);
    box-shadow: 0 8px 20px rgba(218, 165, 32, 0.4);
}

/* Newsletter section */
.footer .input-group {
    border-radius: 25px;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
}

.footer .form-control {
    border: none;
    padding: 12px 20px;
    font-size: 14px;
}

.footer .form-control:focus {
    box-shadow: none;
    border-color: var(--secondary);
}

.footer .btn-warning {
    padding: 12px 25px;
    font-weight: 600;
    border: none;
    transition: all 0.3s ease;
}

.footer .btn-warning:hover {
    background: #B8860B !important;
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(218, 165, 32, 0.4);
}

/* Footer menu links */
.footer-menu a {
    color: #FFFFFF;
    text-decoration: none;
    font-size: 14px;
    transition: all 0.3s ease;
    position: relative;
}

.footer-menu a:hover {
    color: var(--secondary);
}

.footer-menu a::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 0;
    height: 1px;
    background: var(--secondary);
    transition: width 0.3s ease;
}

.footer-menu a:hover::after {
    width: 100%;
}

/* Responsive footer adjustments */
@media (max-width: 768px) {
    .footer .row.g-5 {
        margin: 0;
    }

    .footer .col-lg-4,
    .footer .col-lg-2,
    .footer .col-lg-3,
    .footer .col-md-6 {
        margin-bottom: 2rem;
    }

    .footer-contact .d-flex {
        flex-direction: column;
        text-align: center;
    }

    .footer-contact .btn-sm-square {
        margin: 0 auto 10px auto;
    }

    .btn-social {
        width: 35px;
        height: 35px;
        margin-right: 10px;
    }
}

/* ===== NEWSLETTER FORM STYLES ===== */

.newsletter-form .form-control {
    border: 2px solid transparent;
    transition: all 0.3s ease;
}

.newsletter-form .form-control:focus {
    border-color: var(--secondary);
    box-shadow: 0 0 0 0.2rem rgba(218, 165, 32, 0.25);
}

.newsletter-form .btn-warning:disabled {
    opacity: 0.7;
    cursor: not-allowed;
}

.newsletter-form .btn-loading {
    display: inline-flex;
    align-items: center;
}

.newsletter-form .form-feedback .alert {
    border: none;
    border-radius: 8px;
    font-size: 14px;
    padding: 12px 16px;
    margin: 0;
}

.newsletter-form .alert-success {
    background: rgba(40, 167, 69, 0.1);
    color: #28a745;
    border-left: 4px solid #28a745;
}

.newsletter-form .alert-danger {
    background: rgba(220, 53, 69, 0.1);
    color: #dc3545;
    border-left: 4px solid #dc3545;
}

.newsletter-form .alert i {
    font-size: 16px;
}

/* Newsletter form responsive adjustments */
@media (max-width: 768px) {
    .newsletter-form .input-group {
        flex-direction: column;
    }

    .newsletter-form .input-group .form-control {
        border-radius: 8px 8px 0 0;
        margin-bottom: 0;
    }

    .newsletter-form .input-group .btn {
        border-radius: 0 0 8px 8px;
        width: 100%;
    }
}

/* Z-index management */
.navbar {
    z-index: 1030;
}

.navbar-collapse {
    z-index: 1040;
}

.mobile-loading {
    z-index: 9999;
}

/* ===== ESSENTIAL MOBILE INTERACTIONS ===== */

/* Ripple effect for buttons */
.btn {
    position: relative;
    overflow: hidden;
}

.ripple {
    position: absolute;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.6);
    transform: scale(0);
    animation: ripple-animation 0.6s linear;
    pointer-events: none;
}

@keyframes ripple-animation {
    to {
        transform: scale(4);
        opacity: 0;
    }
}

/* Long press effects */
.long-press {
    transform: scale(0.95);
    background-color: rgba(0, 35, 102, 0.1) !important;
    /* Pure Royal Blue */
    transition: all 0.2s ease;
}

/* Enhanced touch feedback */
.touch-active {
    transform: scale(0.98);
    transition: transform 0.1s ease;
}

/* Carousel touching state */
.carousel-touching {
    cursor: grabbing;
}

.carousel-touching .owl-carousel-item {
    transition: none !important;
}

/* Focus states for accessibility */
.focused {
    outline: 3px solid var(--primary);
    outline-offset: 2px;
    border-radius: 8px;
}

/* Advanced mobile debugging and development */
@media (max-width: 767px) {

    /* Development mode indicators */
    .dev-mode .mobile-indicator {
        position: fixed;
        top: 10px;
        right: 10px;
        background: var(--primary);
        color: white;
        padding: 0.25rem 0.5rem;
        border-radius: 4px;
        font-size: 0.7rem;
        z-index: 9999;
    }

    /* Performance monitoring */
    .perf-monitor {
        position: fixed;
        bottom: 10px;
        left: 10px;
        background: rgba(0, 0, 0, 0.8);
        color: white;
        padding: 0.5rem;
        border-radius: 4px;
        font-size: 0.7rem;
        z-index: 9999;
        display: none;
    }

    .dev-mode .perf-monitor {
        display: block;
    }
}

/* ===== STRICT ROYAL BLUE & MUSTARD YELLOW COLOR SCHEME ===== */

/* Force all Bootstrap colors to use our scheme */
:root {
    --bs-primary: var(--primary) !important;
    /* Pure Royal Blue */
    --bs-secondary: var(--secondary) !important;
    /* Mustard Yellow */
    --bs-success: var(--primary) !important;
    /* Pure Royal Blue */
    --bs-info: var(--secondary) !important;
    /* Mustard Yellow */
    --bs-warning: var(--secondary) !important;
    /* Mustard Yellow */
    --bs-danger: var(--dark-blue) !important;
    /* Darker Pure Royal Blue */
    --bs-light: var(--secondary-light) !important;
    /* Mustard Yellow Light */
    --bs-dark: var(--dark-blue) !important;
    /* Darker Pure Royal Blue */
}

/* ===== ADVANCED HEADER ANIMATIONS ===== */

/* Animated Header Brand */
.animated-header-brand {
    position: relative;
    overflow: hidden;
    color: var(--secondary) !important;
    /* Mustard Yellow */
    text-shadow: 0 0 10px rgba(218, 165, 32, 0.3);
    animation: gentle-float 6s ease-in-out infinite;
    transition: all 0.5s ease;
}

.animated-header-brand:hover {
    transform: scale(1.05);
    animation: shimmer 0.8s ease-in-out, letter-spacing 0.5s ease-in-out;
}

/* Book Icon Animation */
.book-icon {
    display: inline-block;
    animation: book-bounce 2s ease-in-out infinite;
    transition: all 0.3s ease;
}

.book-icon:hover {
    transform: rotate(15deg) scale(1.2);
    color: var(--secondary) !important;
}

/* Academy Text Animation */
.academy-text {
    display: inline-block;
    animation: text-float 3s ease-in-out infinite;
    transition: all 0.3s ease;
}

.academy-text:hover {
    animation: text-shake 0.5s ease-in-out;
}

/* Moving Header Text (Carousel) */
.moving-header-text {
    position: relative;
    background: linear-gradient(45deg, var(--primary), var(--secondary), var(--dark-blue));
    background-size: 300% 300%;
    background-clip: text;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    animation:
        gradient-shift 4s ease-in-out infinite,
        text-float 3s ease-in-out infinite,
        text-glow 2s ease-in-out infinite alternate;
    transition: all 0.3s ease;
}

.moving-header-text:hover {
    transform: scale(1.1);
    animation:
        shimmer 1s ease-in-out,
        letter-spacing 0.8s ease-in-out,
        text-bounce 0.6s ease-in-out;
}

/* ===== KEYFRAME ANIMATIONS ===== */

@keyframes gradient-shift {
    0% {
        background-position: 0% 50%;
    }

    50% {
        background-position: 100% 50%;
    }

    100% {
        background-position: 0% 50%;
    }
}

@keyframes text-glow {
    0% {
        text-shadow: 0 0 5px rgba(0, 35, 102, 0.5),
            0 0 10px rgba(0, 35, 102, 0.3),
            0 0 15px rgba(0, 35, 102, 0.1);
    }

    100% {
        text-shadow: 0 0 10px rgba(218, 165, 32, 0.8),
            0 0 20px rgba(218, 165, 32, 0.6),
            0 0 30px rgba(218, 165, 32, 0.4);
    }
}

@keyframes shimmer {
    0% {
        background-position: -200% center;
        filter: brightness(1);
    }

    50% {
        filter: brightness(1.3);
    }

    100% {
        background-position: 200% center;
        filter: brightness(1);
    }
}

@keyframes letter-spacing {
    0% {
        letter-spacing: normal;
    }

    50% {
        letter-spacing: 0.2em;
    }

    100% {
        letter-spacing: normal;
    }
}

@keyframes book-bounce {

    0%,
    100% {
        transform: translateY(0);
    }

    50% {
        transform: translateY(-5px);
    }
}

@keyframes text-float {

    0%,
    100% {
        transform: translateY(0);
    }

    50% {
        transform: translateY(-3px);
    }
}

@keyframes gentle-float {

    0%,
    100% {
        transform: translateY(0) rotate(0deg);
        text-shadow: 0 0 10px rgba(218, 165, 32, 0.3);
    }

    25% {
        transform: translateY(-2px) rotate(0.5deg);
        text-shadow: 0 0 15px rgba(218, 165, 32, 0.5);
    }

    50% {
        transform: translateY(-1px) rotate(0deg);
        text-shadow: 0 0 20px rgba(218, 165, 32, 0.7);
    }

    75% {
        transform: translateY(-3px) rotate(-0.5deg);
        text-shadow: 0 0 15px rgba(218, 165, 32, 0.5);
    }
}

@keyframes text-shake {

    0%,
    100% {
        transform: translateX(0);
    }

    25% {
        transform: translateX(-2px);
    }

    75% {
        transform: translateX(2px);
    }
}

@keyframes text-bounce {

    0%,
    100% {
        transform: scale(1);
    }

    50% {
        transform: scale(1.05);
    }
}

/* ===== ENHANCED HEADER EFFECTS ===== */

/* Pattern Background Animation */
.animated-header-brand::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(218, 165, 32, 0.2), transparent);
    animation: pattern-move 2s linear infinite;
}

@keyframes pattern-move {
    0% {
        left: -100%;
    }

    100% {
        left: 100%;
    }
}

/* Enhanced Hover Effects */
.animated-header-brand:hover::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 100%;
    height: 2px;
    background: linear-gradient(90deg, var(--primary), var(--secondary), var(--dark-blue));
    animation: underline-grow 0.3s ease-in-out;
}

@keyframes underline-grow {
    0% {
        width: 0;
    }

    100% {
        width: 100%;
    }
}

/* Responsive Animations */
@media (max-width: 768px) {
    .animated-header-brand {
        animation: gradient-shift 4s ease-in-out infinite, text-glow 3s ease-in-out infinite alternate;
    }

    .moving-header-text {
        animation: gradient-shift 5s ease-in-out infinite, text-float 4s ease-in-out infinite;
    }
}

/* Performance Optimizations */
@media (prefers-reduced-motion: reduce) {

    .animated-header-brand,
    .moving-header-text,
    .book-icon,
    .academy-text {
        animation: none;
        transition: none;
    }

    .animated-header-brand:hover,
    .moving-header-text:hover {
        transform: none;
    }
}

/* ===== ADVANCED LEVEL SHOWCASE STYLES ===== */

.advanced-level-icon {
    position: relative;
    display: inline-block;
    transition: all 0.3s ease;
}

.advanced-level-icon:hover {
    transform: translateY(-5px);
}

.advanced-level-icon i {
    position: relative;
    z-index: 2;
    transition: all 0.3s ease;
}

.advanced-level-icon:hover i {
    color: var(--secondary) !important;
    transform: scale(1.1);
}

.icon-glow {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 80px;
    height: 80px;
    background: radial-gradient(circle, rgba(218, 165, 32, 0.2) 0%, transparent 70%);
    border-radius: 50%;
    opacity: 0;
    transition: all 0.3s ease;
    z-index: 1;
}

.advanced-level-icon:hover .icon-glow {
    opacity: 1;
    width: 100px;
    height: 100px;
    background: radial-gradient(circle, rgba(218, 165, 32, 0.4) 0%, transparent 70%);
}

.advanced-badge {
    transition: all 0.3s ease;
}

.advanced-badge:hover {
    transform: scale(1.05);
}

.advanced-badge .badge {
    transition: all 0.3s ease;
    border: 2px solid transparent;
}

.advanced-badge:hover .badge {
    border-color: var(--primary);
    box-shadow: 0 4px 15px rgba(218, 165, 32, 0.4);
}

/* Enhanced hover effects for the showcase section */
.advanced-level-icon:hover::after {
    content: '';
    position: absolute;
    bottom: -10px;
    left: 50%;
    transform: translateX(-50%);
    width: 60px;
    height: 3px;
    background: linear-gradient(90deg, var(--primary), var(--secondary), var(--dark-blue));
    border-radius: 2px;
    animation: underline-grow 0.3s ease-in-out;
}

@keyframes underline-grow {
    0% {
        width: 0;
    }

    100% {
        width: 60px;
    }
}

/* ===== CAROUSEL EDUCATIONAL LEVEL ICONS ===== */

.level-icon-container,
.stream-icon-container {
    padding: 15px 10px;
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.level-icon-container:hover,
.stream-icon-container:hover {
    background: rgba(218, 165, 32, 0.2);
    border-color: var(--secondary);
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(218, 165, 32, 0.3);
}

.level-icon-container::before,
.stream-icon-container::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(218, 165, 32, 0.1), transparent);
    transition: left 0.5s ease;
}

.level-icon-container:hover::before,
.stream-icon-container:hover::before {
    left: 100%;
}

.level-icon-container i,
.stream-icon-container i {
    transition: all 0.3s ease;
    position: relative;
    z-index: 2;
}

.level-icon-container:hover i,
.stream-icon-container:hover i {
    transform: scale(1.2);
    color: var(--secondary) !important;
}

.level-icon-container h6,
.stream-icon-container h6 {
    transition: all 0.3s ease;
    position: relative;
    z-index: 2;
}

.level-icon-container:hover h6,
.stream-icon-container:hover h6 {
    color: var(--secondary) !important;
}

.level-icon-container small,
.stream-icon-container small {
    transition: all 0.3s ease;
    position: relative;
    z-index: 2;
}

.level-icon-container:hover small,
.stream-icon-container:hover small {
    color: var(--secondary-light) !important;
}

/* Responsive adjustments for carousel icons */
@media (max-width: 768px) {

    .level-icon-container,
    .stream-icon-container {
        padding: 10px 8px;
        margin-bottom: 10px;
    }

    .level-icon-container i,
    .stream-icon-container i {
        font-size: 1.5rem !important;
    }

    .level-icon-container h6,
    .stream-icon-container h6 {
        font-size: 0.9rem;
    }

    .level-icon-container small,
    .stream-icon-container small {
        font-size: 0.75rem;
    }
}

/* ===== HEXCO COURSES ICONS ===== */

.hexco-icon-container {
    padding: 12px 8px;
    border-radius: 15px;
    background: rgba(255, 255, 255, 0.08);
    backdrop-filter: blur(15px);
    border: 1px solid rgba(255, 255, 255, 0.15);
    transition: all 0.4s ease;
    position: relative;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
}

.hexco-icon-container:hover {
    background: rgba(218, 165, 32, 0.25);
    border-color: var(--secondary);
    transform: translateY(-5px) scale(1.02);
    box-shadow: 0 12px 30px rgba(218, 165, 32, 0.4);
}

.hexco-icon-container::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(218, 165, 32, 0.15), transparent);
    transition: left 0.6s ease;
}

.hexco-icon-container:hover::before {
    left: 100%;
}

.hexco-icon-container::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    width: 0;
    height: 2px;
    background: linear-gradient(90deg, var(--secondary), var(--secondary-light), var(--secondary));
    transition: all 0.4s ease;
    transform: translateX(-50%);
}

.hexco-icon-container:hover::after {
    width: 80%;
}

.hexco-icon-container i {
    transition: all 0.4s ease;
    position: relative;
    z-index: 2;
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.3));
}

.hexco-icon-container:hover i {
    transform: scale(1.3) rotate(5deg);
    color: var(--secondary) !important;
    filter: drop-shadow(0 4px 8px rgba(218, 165, 32, 0.6));
}

.hexco-icon-container h6 {
    transition: all 0.4s ease;
    position: relative;
    z-index: 2;
    font-weight: 600;
}

.hexco-icon-container:hover h6 {
    color: var(--secondary) !important;
    transform: scale(1.05);
}

.hexco-icon-container small {
    transition: all 0.4s ease;
    position: relative;
    z-index: 2;
    opacity: 0.9;
}

.hexco-icon-container:hover small {
    color: var(--secondary-light) !important;
    opacity: 1;
}

/* HEXCO Icon Pulse Animation */
.hexco-icon-container:hover i {
    animation: hexco-pulse 0.6s ease-in-out;
}

@keyframes hexco-pulse {

    0%,
    100% {
        transform: scale(1.3) rotate(5deg);
    }

    50% {
        transform: scale(1.4) rotate(8deg);
    }
}

/* Responsive adjustments for HEXCO icons */
@media (max-width: 768px) {
    .hexco-icon-container {
        padding: 10px 6px;
        margin-bottom: 8px;
    }

    .hexco-icon-container i {
        font-size: 1.4rem !important;
    }

    .hexco-icon-container h6 {
        font-size: 0.8rem;
    }

    .hexco-icon-container small {
        font-size: 0.7rem;
    }
}

@media (max-width: 576px) {
    .hexco-icon-container {
        padding: 8px 4px;
    }

    .hexco-icon-container i {
        font-size: 1.2rem !important;
    }

    .hexco-icon-container h6 {
        font-size: 0.75rem;
    }

    .hexco-icon-container small {
        font-size: 0.65rem;
    }
}

/* ===== ENHANCED MOBILE RESPONSIVENESS ===== */

/* Mobile-specific improvements */
@media (max-width: 767px) {

    /* Navbar mobile enhancements */
    .navbar {
        padding: 0.5rem 1rem;
    }

    .navbar-brand {
        font-size: 1.2rem;
        font-weight: 700;
    }

    .navbar-nav .nav-link {
        padding: 0.75rem 0;
        font-size: 1rem;
        font-weight: 500;
        border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    }

    .navbar-nav .nav-link:last-child {
        border-bottom: none;
    }

    /* Carousel mobile optimizations */
    .header-carousel .owl-carousel-item {
        min-height: 400px;
    }

    .header-carousel h1 {
        font-size: 1.8rem;
        line-height: 1.2;
    }

    .header-carousel .display-3 {
        font-size: 2rem;
    }

    .header-carousel p {
        font-size: 0.9rem;
        line-height: 1.4;
    }

    /* Educational icons mobile layout */
    .level-icon-container,
    .stream-icon-container {
        padding: 12px 8px;
        margin-bottom: 8px;
    }

    .level-icon-container i,
    .stream-icon-container i {
        font-size: 1.5rem !important;
    }

    .level-icon-container h6,
    .stream-icon-container h6 {
        font-size: 0.85rem;
        margin-bottom: 0.25rem;
    }

    .level-icon-container small,
    .stream-icon-container small {
        font-size: 0.7rem;
    }

    /* HEXCO icons mobile layout */
    .hexco-icon-container {
        padding: 10px 6px;
        margin-bottom: 10px;
    }

    .hexco-icon-container i {
        font-size: 1.3rem !important;
    }

    .hexco-icon-container h6 {
        font-size: 0.8rem;
    }

    .hexco-icon-container small {
        font-size: 0.65rem;
    }

    /* Section titles mobile */
    .section-title {
        font-size: 0.9rem;
        padding: 0.5rem 1rem;
    }

    .section-title::before,
    .section-title::after {
        display: none;
    }

    /* Cards and content mobile */
    .card {
        margin-bottom: 1rem;
    }

    .card-body {
        padding: 1rem;
    }

    .card-title {
        font-size: 1.1rem;
    }

    .card-text {
        font-size: 0.9rem;
    }

    /* Buttons mobile */
    .btn {
        padding: 0.75rem 1.5rem;
        font-size: 0.9rem;
        border-radius: 8px;
    }

    .btn-lg {
        padding: 1rem 2rem;
        font-size: 1rem;
    }

    /* Footer mobile */
    .footer {
        padding: 2rem 0 1rem 0;
    }

    .footer h5 {
        font-size: 1.1rem;
        margin-bottom: 1rem;
    }

    .footer p {
        font-size: 0.9rem;
        line-height: 1.5;
    }

    /* Newsletter form mobile */
    .newsletter-form .input-group {
        flex-direction: column;
    }

    .newsletter-form .form-control {
        border-radius: 8px 8px 0 0;
        padding: 1rem;
        font-size: 1rem;
    }

    .newsletter-form .btn {
        border-radius: 0 0 8px 8px;
        width: 100%;
        padding: 1rem;
    }

    /* Testimonials mobile */
    .testimonial-item {
        padding: 0 1rem;
    }

    .testimonial-text {
        padding: 1rem !important;
        font-size: 0.9rem;
        line-height: 1.5;
    }

    /* Advanced level showcase mobile */
    .advanced-level-icon {
        margin-bottom: 1rem;
    }

    .advanced-level-icon i {
        font-size: 2.5rem;
    }

    .advanced-badge .badge {
        font-size: 0.8rem;
        padding: 0.5rem 0.75rem;
    }
}

/* Extra small devices */
@media (max-width: 575px) {
    .container {
        padding-left: 1rem;
        padding-right: 1rem;
    }

    .header-carousel h1 {
        font-size: 1.5rem;
    }

    .header-carousel .display-3 {
        font-size: 1.8rem;
    }

    .level-icon-container,
    .stream-icon-container {
        padding: 8px 4px;
    }

    .level-icon-container i,
    .stream-icon-container i {
        font-size: 1.2rem !important;
    }

    .hexco-icon-container {
        padding: 8px 4px;
    }

    .hexco-icon-container i {
        font-size: 1.1rem !important;
    }

    .btn {
        padding: 0.6rem 1.2rem;
        font-size: 0.85rem;
    }

    .btn-lg {
        padding: 0.8rem 1.5rem;
        font-size: 0.9rem;
    }
}

/* iPhone SE and very small screens */
@media (max-width: 375px) {
    .header-carousel h1 {
        font-size: 1.3rem;
    }

    .header-carousel .display-3 {
        font-size: 1.6rem;
    }

    .header-carousel p {
        font-size: 0.8rem;
    }

    .level-icon-container h6,
    .stream-icon-container h6 {
        font-size: 0.75rem;
    }

    .level-icon-container small,
    .stream-icon-container small {
        font-size: 0.6rem;
    }

    .hexco-icon-container h6 {
        font-size: 0.7rem;
    }

    .hexco-icon-container small {
        font-size: 0.6rem;
    }
}

/* Landscape orientation on mobile */
@media (max-width: 767px) and (orientation: landscape) {
    .header-carousel .owl-carousel-item {
        min-height: 300px;
    }

    .header-carousel h1 {
        font-size: 1.4rem;
    }

    .header-carousel .display-3 {
        font-size: 1.6rem;
    }

    .level-icon-container,
    .stream-icon-container {
        padding: 6px 4px;
    }

    .level-icon-container i,
    .stream-icon-container i {
        font-size: 1.1rem !important;
    }

    .hexco-icon-container {
        padding: 6px 4px;
    }

    .hexco-icon-container i {
        font-size: 1rem !important;
    }
}

/* Touch-friendly improvements */
@media (max-width: 767px) {

    /* Larger touch targets */
    .btn {
        min-height: 44px;
        min-width: 44px;
    }

    .nav-link {
        min-height: 44px;
        display: flex;
        align-items: center;
    }

    /* Better spacing for touch */
    .card {
        margin-bottom: 1.5rem;
    }

    .service-item {
        margin-bottom: 1.5rem;
    }

    /* Improved readability */
    body {
        font-size: 16px;
        line-height: 1.6;
    }

    h1,
    h2,
    h3,
    h4,
    h5,
    h6 {
        line-height: 1.3;
    }

    /* Better form inputs */
    .form-control {
        font-size: 16px;
        padding: 0.75rem;
        border-radius: 8px;
    }

    /* Improved navigation */
    .navbar-collapse {
        background: rgba(0, 35, 102, 0.95);
        backdrop-filter: blur(10px);
        border-radius: 0 0 12px 12px;
        margin-top: 0.5rem;
        padding: 1rem;
    }

    /* Better carousel navigation */
    .header-carousel .owl-nav .owl-prev,
    .header-carousel .owl-nav .owl-next {
        width: 40px;
        height: 40px;
        font-size: 18px;
    }

    /* Improved footer spacing */
    .footer .row.g-5 {
        margin: 0;
    }

    .footer .col-lg-4,
    .footer .col-lg-2,
    .footer .col-lg-3,
    .footer .col-md-6 {
        margin-bottom: 2rem;
    }
}

/* High DPI displays */
@media (-webkit-min-device-pixel-ratio: 2),
(min-resolution: 192dpi) {
    .navbar-brand img {
        image-rendering: -webkit-optimize-contrast;
        image-rendering: crisp-edges;
    }
}

/* Reduced motion for accessibility */
@media (prefers-reduced-motion: reduce) {

    .animated-header-brand,
    .moving-header-text,
    .level-icon-container,
    .stream-icon-container,
    .hexco-icon-container {
        animation: none;
        transition: none;
    }

    .header-carousel .owl-carousel-item {
        transition: none;
    }
}

/* ===== MOBILE TOUCH ENHANCEMENTS ===== */

/* Touch feedback for mobile devices */
@media (max-width: 767px) {

    /* Touch-active state for better feedback */
    .touch-active {
        transform: scale(0.98);
        transition: transform 0.1s ease;
    }

    /* Long press effect */
    .long-press {
        transform: scale(0.95);
        background-color: rgba(0, 35, 102, 0.1) !important;
        transition: all 0.2s ease;
    }

    /* Enhanced button interactions */
    .btn:active {
        transform: scale(0.96);
        transition: transform 0.1s ease;
    }

    /* Improved navigation touch targets */
    .navbar-nav .nav-link {
        min-height: 48px;
        display: flex;
        align-items: center;
        justify-content: center;
        padding: 12px 16px;
        margin: 4px 0;
        border-radius: 8px;
        transition: all 0.2s ease;
    }

    .navbar-nav .nav-link:active {
        background-color: rgba(218, 165, 32, 0.2);
        transform: scale(0.98);
    }

    /* Enhanced carousel touch */
    .header-carousel .owl-nav .owl-prev,
    .header-carousel .owl-nav .owl-next {
        min-width: 48px;
        min-height: 48px;
        display: flex;
        align-items: center;
        justify-content: center;
        background: rgba(0, 35, 102, 0.8) !important;
        border: 2px solid var(--secondary) !important;
        border-radius: 50%;
        transition: all 0.2s ease;
    }

    .header-carousel .owl-nav .owl-prev:active,
    .header-carousel .owl-nav .owl-next:active {
        transform: scale(0.9);
        background: var(--secondary) !important;
    }

    /* Enhanced card interactions */
    .hexco-card:active,
    .service-item:active,
    .card:active {
        transform: scale(0.98);
        transition: transform 0.1s ease;
    }

    /* Improved form interactions */
    .form-control:focus {
        border-color: var(--secondary);
        box-shadow: 0 0 0 0.2rem rgba(218, 165, 32, 0.25);
        transform: scale(1.02);
        transition: all 0.2s ease;
    }

    /* Enhanced icon interactions */
    .level-icon-container:active,
    .stream-icon-container:active,
    .hexco-icon-container:active {
        transform: scale(0.95);
        background: rgba(218, 165, 32, 0.3) !important;
        transition: all 0.1s ease;
    }

    /* Better footer interactions */
    .footer .btn-link:active {
        transform: translateX(8px);
        color: var(--secondary) !important;
        transition: all 0.2s ease;
    }

    .btn-social:active {
        transform: scale(0.9);
        background: var(--secondary) !important;
        transition: all 0.1s ease;
    }
}

/* ===== MOBILE PERFORMANCE OPTIMIZATIONS ===== */

/* Optimize animations for mobile */
@media (max-width: 767px) {

    /* Reduce animation complexity */
    .wow {
        animation-duration: 0.6s !important;
    }

    /* Optimize transitions */
    * {
        transition-duration: 0.2s !important;
    }

    /* Reduce shadow complexity */
    .card,
    .service-item,
    .hexco-card {
        box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1) !important;
    }

    /* Optimize gradients */
    .footer {
        background: var(--primary) !important;
    }

    /* Reduce backdrop-filter usage */
    .level-icon-container,
    .stream-icon-container,
    .hexco-icon-container {
        backdrop-filter: none;
        background: rgba(255, 255, 255, 0.15) !important;
    }
}

/* ===== MOBILE ACCESSIBILITY IMPROVEMENTS ===== */

/* Better focus indicators for mobile */
@media (max-width: 767px) {

    .btn:focus,
    .nav-link:focus,
    .form-control:focus {
        outline: 3px solid var(--secondary);
        outline-offset: 2px;
        border-radius: 8px;
    }

    /* Improved contrast for mobile */
    .text-muted {
        color: #6c757d !important;
    }

    /* Better text readability */
    p,
    span,
    div {
        text-rendering: optimizeLegibility;
        -webkit-font-smoothing: antialiased;
    }

    /* Enhanced button contrast */
    .btn-warning {
        color: var(--dark-blue) !important;
        font-weight: 600;
    }

    .btn-outline-light {
        border-width: 2px;
        font-weight: 500;
    }
}

/* ===== MOBILE LAYOUT IMPROVEMENTS ===== */

/* Better spacing for mobile */
@media (max-width: 767px) {
    .container {
        padding-left: 1rem;
        padding-right: 1rem;
    }

    .row {
        margin-left: -0.5rem;
        margin-right: -0.5rem;
    }

    .col,
    .col-1,
    .col-2,
    .col-3,
    .col-4,
    .col-5,
    .col-6,
    .col-7,
    .col-8,
    .col-9,
    .col-10,
    .col-11,
    .col-12,
    .col-sm,
    .col-md,
    .col-lg,
    .col-xl {
        padding-left: 0.5rem;
        padding-right: 0.5rem;
    }

    /* Better section spacing */
    .py-5 {
        padding-top: 3rem !important;
        padding-bottom: 3rem !important;
    }

    .mb-5 {
        margin-bottom: 3rem !important;
    }

    /* Improved card spacing */
    .card-body {
        padding: 1.25rem;
    }

    /* Better button spacing */
    .btn {
        margin: 0.25rem;
    }

    /* Enhanced footer spacing */
    .footer {
        padding-top: 2rem;
        padding-bottom: 1rem;
    }

    .footer .row.g-5 {
        margin: 0;
    }

    .footer .col-lg-4,
    .footer .col-lg-2,
    .footer .col-lg-3,
    .footer .col-md-6 {
        margin-bottom: 2rem;
    }
}

/* ===== MOBILE NAVIGATION ENHANCEMENTS ===== */

/* Improved mobile menu */
@media (max-width: 767px) {
    .navbar-collapse {
        background: rgba(0, 35, 102, 0.98);
        backdrop-filter: blur(10px);
        border-radius: 0 0 12px 12px;
        margin-top: 0.5rem;
        padding: 1rem;
        box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
    }

    .navbar-nav {
        padding: 0.5rem 0;
    }

    .navbar-nav .nav-item {
        margin: 0.25rem 0;
    }

    .navbar-nav .nav-link {
        border-radius: 8px;
        margin: 0.25rem 0;
        font-weight: 500;
        letter-spacing: 0.5px;
    }

    /* Enhanced mobile menu animation */
    .navbar-collapse.show {
        animation: slideDown 0.3s ease-out;
    }

    @keyframes slideDown {
        from {
            opacity: 0;
            transform: translateY(-10px);
        }

        to {
            opacity: 1;
            transform: translateY(0);
        }
    }
}

/* ===== MOBILE CAROUSEL OPTIMIZATIONS ===== */

/* Better mobile carousel */
@media (max-width: 767px) {
    .header-carousel .owl-carousel-item {
        position: relative;
        min-height: 450px;
    }

    .header-carousel .owl-carousel-item img {
        object-fit: cover;
        object-position: center;
    }

    .header-carousel .owl-nav {
        position: absolute;
        top: 50%;
        transform: translateY(-50%);
        width: 100%;
        display: flex;
        justify-content: space-between;
        padding: 0 1rem;
        pointer-events: none;
    }

    .header-carousel .owl-nav .owl-prev,
    .header-carousel .owl-nav .owl-next {
        pointer-events: auto;
        width: 48px;
        height: 48px;
        border-radius: 50%;
        background: rgba(0, 35, 102, 0.8) !important;
        border: 2px solid var(--secondary) !important;
        display: flex;
        align-items: center;
        justify-content: center;
        font-size: 18px;
        transition: all 0.2s ease;
    }

    .header-carousel .owl-nav .owl-prev:hover,
    .header-carousel .owl-nav .owl-next:hover {
        background: var(--secondary) !important;
        transform: scale(1.1);
    }

    /* Better carousel content */
    .header-carousel .position-absolute {
        padding: 2rem 1rem;
    }

    .header-carousel h1 {
        margin-bottom: 1rem;
        line-height: 1.2;
    }

    .header-carousel p {
        margin-bottom: 1.5rem;
        line-height: 1.5;
    }
}

/* ===== ADVANCED MOBILE CAROUSEL ===== */

/* Enhanced mobile carousel with advanced features */
@media (max-width: 767px) {

    /* Mobile carousel container */
    .header-carousel {
        position: relative;
        overflow: hidden;
        border-radius: 0 0 20px 20px;
    }

    .header-carousel .owl-carousel-item {
        position: relative;
        min-height: 500px;
        overflow: hidden;
    }

    .header-carousel .owl-carousel-item img {
        object-fit: cover;
        object-position: center;
        transition: transform 0.5s ease;
    }

    .header-carousel .owl-carousel-item:hover img {
        transform: scale(1.05);
    }

    /* Mobile carousel overlay - BACKGROUND REMOVED AS PER USER REQUEST */
    .header-carousel .position-absolute {
        padding: 2rem 1.5rem;
        border-radius: 0 0 20px 20px;
    }

    /* Mobile carousel content - FIXED FOR VISIBILITY */
    .header-carousel h1 {
        font-size: 2rem;
        font-weight: 700;
        line-height: 1.2;
        margin-bottom: 1rem;
        text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.8);
        animation: slideInLeft 0.8s ease;
        color: #FFFFFF !important;
        display: block !important;
        visibility: visible !important;
        opacity: 1 !important;
    }

    .header-carousel .display-3 {
        font-size: 2.5rem;
        font-weight: 800;
        color: #FFD700 !important;
        text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.8), 0 0 10px rgba(255, 215, 0, 0.5);
        animation: slideInRight 0.8s ease 0.2s both;
        display: block !important;
        visibility: visible !important;
        opacity: 1 !important;
        /* Remove the transparent text effect that was causing visibility issues */
        background: none !important;
        -webkit-background-clip: unset !important;
        -webkit-text-fill-color: unset !important;
        background-clip: unset !important;
    }

    .header-carousel p {
        font-size: 1rem;
        line-height: 1.6;
        margin-bottom: 1.5rem;
        opacity: 1 !important;
        color: #FFFFFF !important;
        text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.8);
        animation: slideInUp 0.8s ease 0.4s both;
        display: block !important;
        visibility: visible !important;
    }

    /* Ensure all carousel content is visible */
    .header-carousel .col-sm-10,
    .header-carousel .col-lg-8 {
        display: block !important;
        visibility: visible !important;
        opacity: 1 !important;
    }

    /* Educational icons mobile layout - ENHANCED VISIBILITY */
    .level-icon-container,
    .stream-icon-container,
    .hexco-icon-container {
        padding: 12px 8px;
        margin-bottom: 8px;
        background: rgba(255, 255, 255, 0.1);
        border-radius: 10px;
        border: 1px solid rgba(255, 215, 0, 0.3);
        display: block !important;
        visibility: visible !important;
        opacity: 1 !important;
    }

    .level-icon-container i,
    .stream-icon-container i,
    .hexco-icon-container i {
        font-size: 1.5rem !important;
        color: #FFD700 !important;
        text-shadow: 0 0 5px rgba(255, 215, 0, 0.5);
    }

    .level-icon-container h6,
    .stream-icon-container h6,
    .hexco-icon-container h6 {
        font-size: 0.85rem;
        margin-bottom: 0.25rem;
        color: #FFFFFF !important;
        text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.8);
        font-weight: 600;
    }

    .level-icon-container small,
    .stream-icon-container small,
    .hexco-icon-container small {
        font-size: 0.7rem;
        color: #FFD700 !important;
        text-shadow: 0 0 3px rgba(255, 215, 0, 0.5);
        font-weight: 500;
    }
}

.text-royal-blue {
    color: #4169E1 !important;
}