/********** Template CSS **********/
:root {
    --primary: #0d6efd;
    --light: #fefefe;
    --dark: #181d38;
}

/* Accessibility: Skip link */
.skip-link {
    position: absolute;
    left: -999px;
    top: auto;
    width: 1px;
    height: 1px;
    overflow: hidden;
}
.skip-link:focus {
    left: 12px;
    top: 12px;
    width: auto;
    height: auto;
    padding: 8px 12px;
    background: #0d6efd;
    color: #ffffff;
    z-index: 9999;
    border-radius: 6px;
    text-decoration: none;
}

.visually-hidden { position: absolute !important; height: 1px; width: 1px; overflow: hidden; clip: rect(1px, 1px, 1px, 1px); white-space: nowrap; }

.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;
}

.navbar-logo {
    height: 60px; /* Adjust to desired size */
    max-height: 100%;
    width: auto;
    display: block;
}
.navbar-brand {
    padding-top: 0.25rem;
    padding-bottom: 0.25rem;
}

    /* Carousel image fit */
    .carousel-inner img {
        object-fit: cover;
        height: 100%;
        width: 100%;
        min-height: 320px;
        max-height: 320px;
    }
    .carousel-caption {
        left: 0;
        right: 0;
        bottom: 0;
        padding-bottom: 0.5rem;
    }
    .ticker-wrapper {
        height: 100%;
        width: 100%;
        overflow: hidden;
    }
    .ticker-items {
        display: flex;
        flex-direction: column;
        animation: ticker-scroll 12s linear infinite;
    }
    .ticker-item {
        min-height: 40px;
        padding: 0.5rem 1rem;
        border-bottom: 1px solid #f1f1f1;
        font-size: 1rem;
        background: transparent;
        transition: background 0.2s;
        text-align: center;
    }
    .ticker-item:hover {
        background: #f8f9fa;
        text-decoration: underline;
    }
    @keyframes ticker-scroll {
        0% { transform: translateY(0); }
        100% { transform: translateY(-50%); }
    }
    .ticker-wrapper:hover .ticker-items {
        animation-play-state: paused;
    }
    /* Responsive: stack on mobile, side by side on desktop */
    @media (max-width: 767.98px) {
        .row.g-4.align-items-stretch > .col-md-8,
        .row.g-4.align-items-stretch > .col-md-4 {
            flex: 0 0 100%;
            max-width: 100%;
        }
        .carousel-inner img,
        .carousel-inner {
            min-height: 180px;
            max-height: 180px;
        }
        .ticker-wrapper,
        .bg-white.border.rounded.shadow-sm.overflow-hidden.w-100.flex-grow-1 {
            height: 180px !important;
        }
    }

/*** 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: #ffffff00;
    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 #eeeeee00;
    }
}

.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(--primary);
    border-color: var(--primary);
}

.page-header {
    background: linear-gradient(rgba(24, 29, 56, .7), rgba(24, 29, 56, .7)), url(../img/carousal/C_1.png);
    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(--primary);
}

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

.service-item:hover * {
    color: var(--light) !important;
}


/*** 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;
    }
}

/* Admission CTA - modern rectangular style */
.admission-btn{
    display:inline-flex;
    align-items:center;
    gap:.6rem;
    padding:.55rem .9rem;
    font-weight:700;
    font-size:.98rem;
    color:#fff;
    background: linear-gradient(90deg,#ff6a00 0%, #ff7a18 40%, #ff4e50 100%);
    border: none;
    border-radius:8px; /* rectangular with subtle rounding */
    box-shadow: 0 8px 24px rgba(255,110,50,0.18), inset 0 -2px 6px rgba(255,255,255,0.06);
    transition: transform .14s ease, box-shadow .14s ease, opacity .14s ease;
    text-decoration:none;
}
.admission-btn:focus{ outline:none; box-shadow:0 8px 30px rgba(255,110,50,0.25); }
.admission-btn:hover{ transform:translateY(-3px); box-shadow:0 18px 38px rgba(255,110,50,0.22); }
.admission-btn .fa-user-graduate{ font-size:1.05rem; }
.admission-btn.active{ opacity:0.98; }

/* Mobile version when displayed as nav link */
.admission-mobile{ font-weight:700; color:var(--dark); }
.admission-mobile .fa-user-graduate{ margin-right:.5rem; color: #ff6a00 }

@media (max-width:991.98px){
    /* ensure mobile link is visible and comfortable to tap */
    .admission-mobile{ display:inline-flex; align-items:center; gap:.5rem; padding:.5rem 0; }
}

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

.testimonial-carousel .owl-item.center .testimonial-text {
    background: var(--primary) !important;
}

.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(--primary);
    border-color: var(--primary);
}


/*** Footer ***/
.footer .btn.btn-social {
    margin-right: 5px;
    width: 35px;
    height: 35px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--light);
    font-weight: normal;
    border: 1px solid #FFFFFF;
    border-radius: 35px;
    transition: .3s;
}

.footer .btn.btn-social:hover {
    color: var(--primary);
}

.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;
    box-shadow: none;
}

.footer .copyright {
    padding: 25px 0;
    font-size: 15px;
    border-top: 1px solid rgba(256, 256, 256, .1);
}

.footer .copyright a {
    color: var(--light);
}

.footer .footer-menu a {
    margin-right: 15px;
    padding-right: 15px;
    border-right: 1px solid rgba(255, 255, 255, .1);
}

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

/*** Modern Service Cards ***/
.service-card {
    position: relative;
    overflow: hidden;
    cursor: pointer;
}

.service-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.3), transparent);
    transition: left 0.5s ease;
    z-index: 0;
}

.service-card:hover::before {
    left: 100%;
}

.service-card:hover {
    transform: translateY(-8px) !important;
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.15) !important;
}

.service-card .icon-box {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 80px;
    height: 80px;
    transition: all 0.4s ease;
}

.service-card:hover .icon-box {
    transform: scale(1.1) rotate(5deg);
}

/*** Modern Category Cards ***/
.category-card {
    position: relative;
    cursor: pointer;
    overflow: hidden;
}

.category-card img {
    transition: transform 0.5s cubic-bezier(0.4, 0, 0.2, 1);
    width: 100%;
    height: 100%;
}

.category-card:hover img {
    transform: scale(1.1) !important;
}

.category-card:hover {
    box-shadow: 0 20px 50px rgba(255, 106, 0, 0.25) !important;
}

/*** Carousel Button Hover Effects ***/
.btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.2) !important;
}

.btn-lg:hover {
    transform: translateY(-3px) scale(1.02);
}

/*** Ticker Item Hover ***/
.ticker-item {
    padding: 0.875rem 0.75rem !important;
    border-bottom: 1px solid #e9ecef !important;
    transition: all 0.3s ease;
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
}

.ticker-item:hover {
    background: #f8f9fa;
    border-left: 4px solid #ff6a00;
    padding-left: calc(0.75rem - 4px) !important;
}

/*** Event Carousel Controls ***/
.carousel-control-prev,
.carousel-control-next {
    transition: all 0.3s ease;
    opacity: 0.6;
}

.carousel-control-prev:hover,
.carousel-control-next:hover {
    opacity: 1;
    background: rgba(0, 0, 0, 0.5) !important;
    transform: scale(1.1);
}

/*** Smooth Transitions ***/
.transition-all {
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1) !important;
}

/*** Floating Social Media Icons ***/
.floating-social-icons {
    position: fixed;
    right: 20px;
    top: 50%;
    transform: translateY(-50%);
    display: flex;
    flex-direction: column;
    gap: 15px;
    z-index: 98;
    align-items: center;
}

.floating-social-icons .social-icon {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    color: #ffffff;
    text-decoration: none;
    transition: all 0.3s ease;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.floating-social-icons .social-icon.facebook {
    background: linear-gradient(135deg, #1877F2 0%, #0A66C2 100%);
}

.floating-social-icons .social-icon.instagram {
    background: linear-gradient(135deg, #E1306C 0%, #C13584 50%, #833AB4 100%);
}

.floating-social-icons .social-icon.twitter {
    background: linear-gradient(135deg, #000000 0%, #1D1D1D 100%);
}

.floating-social-icons .social-icon.youtube {
    background: linear-gradient(135deg, #FF0000 0%, #CC0000 100%);
}

.floating-social-icons .social-icon:hover {
    transform: scale(1.15);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.25);
}

.floating-social-icons .social-icon.facebook:hover {
    background: linear-gradient(135deg, #0A66C2 0%, #1877F2 100%);
}

.floating-social-icons .social-icon.instagram:hover {
    background: linear-gradient(135deg, #833AB4 0%, #E1306C 100%);
}

.floating-social-icons .social-icon.twitter:hover {
    background: linear-gradient(135deg, #1D1D1D 0%, #333333 100%);
}

.floating-social-icons .social-icon.youtube:hover {
    background: linear-gradient(135deg, #CC0000 0%, #FF0000 100%);
}

/* Responsive: Hide on very small screens, adjust on medium screens */
@media (max-width: 768px) {
    .floating-social-icons {
        right: 10px;
        gap: 10px;
    }
    
    .floating-social-icons .social-icon {
        width: 45px;
        height: 45px;
        font-size: 20px;
    }
}

/* ============== COMPREHENSIVE MOBILE OPTIMIZATION ============== */

/* Container responsive padding */
.container, .container-sm, .container-md, .container-lg, .container-xl, .container-xxl {
    padding-left: 1rem;
    padding-right: 1rem;
}

/* Navbar optimization */
@media (max-width: 991px) {
    .navbar-brand {
        padding-left: 1rem;
        padding-right: 0.5rem;
    }
    
    .navbar-logo {
        height: 50px;
    }
    
    .navbar-nav {
        padding: 0.75rem 1rem !important;
    }
    
    .nav-link {
        padding: 0.5rem 0 !important;
        font-size: 0.95rem;
    }
}

@media (max-width: 576px) {
    .navbar {
        padding: 0.5rem 0 !important;
    }
    
    .navbar-brand {
        padding-left: 0.75rem;
    }
    
    .navbar-logo {
        height: 45px;
    }
    
    .navbar-toggler {
        margin-right: 0.75rem;
    }
    
    .navbar-nav {
        padding: 0.5rem 0.75rem !important;
    }
    
    .nav-link {
        font-size: 0.9rem;
        padding: 0.4rem 0 !important;
    }
}

/* Hero section optimization */
@media (max-width: 992px) {
    h1 {
        font-size: 1.75rem !important;
    }
    
    h2 {
        font-size: 1.5rem !important;
    }
    
    h3 {
        font-size: 1.25rem !important;
    }
}

@media (max-width: 768px) {
    h1 {
        font-size: 1.5rem !important;
        line-height: 1.3 !important;
    }
    
    h2 {
        font-size: 1.25rem !important;
        line-height: 1.3 !important;
    }
    
    h3 {
        font-size: 1.1rem !important;
    }
    
    .page-header {
        padding: 2rem 0 !important;
    }
    
    .container-fluid.py-5 {
        padding: 1.5rem 0 !important;
    }
}

@media (max-width: 576px) {
    h1 {
        font-size: 1.35rem !important;
    }
    
    h2 {
        font-size: 1.15rem !important;
    }
    
    h3 {
        font-size: 1rem !important;
    }
    
    h4 {
        font-size: 0.95rem !important;
    }
    
    p {
        font-size: 0.95rem !important;
        line-height: 1.5 !important;
    }
}

/* Button optimization */
@media (max-width: 768px) {
    .btn {
        padding: 0.5rem 1rem !important;
        font-size: 0.95rem !important;
    }
    
    .btn-lg {
        padding: 0.6rem 1.2rem !important;
        font-size: 1rem !important;
    }
}

@media (max-width: 576px) {
    .btn {
        padding: 0.45rem 0.9rem !important;
        font-size: 0.9rem !important;
    }
    
    .btn-lg {
        padding: 0.5rem 1rem !important;
        font-size: 0.95rem !important;
    }
}

/* Card and container spacing */
@media (max-width: 768px) {
    .card {
        margin-bottom: 1rem;
    }
    
    .row.g-4 {
        row-gap: 1.5rem !important;
    }
    
    .container-fluid {
        padding-left: 1rem;
        padding-right: 1rem;
    }
}

@media (max-width: 576px) {
    .row.g-4,
    .row.g-5 {
        row-gap: 1rem !important;
        column-gap: 0.75rem !important;
    }
}

/* Carousel optimization */
@media (max-width: 768px) {
    .carousel-inner img {
        min-height: 200px;
        max-height: 250px;
    }
    
    .carousel-caption {
        padding: 1rem 0.5rem;
    }
    
    .carousel-caption h5 {
        font-size: 1rem !important;
    }
    
    .carousel-caption p {
        font-size: 0.85rem !important;
    }
}

@media (max-width: 576px) {
    .carousel-inner img {
        min-height: 160px;
        max-height: 200px;
    }
    
    .carousel-caption {
        padding: 0.5rem 0.3rem;
    }
    
    .carousel-caption h5 {
        font-size: 0.9rem !important;
    }
    
    .carousel-caption p {
        font-size: 0.8rem !important;
    }
}

/* Table optimization */
@media (max-width: 768px) {
    table {
        font-size: 0.9rem;
    }
    
    .table th, .table td {
        padding: 0.5rem !important;
    }
}

@media (max-width: 576px) {
    table {
        font-size: 0.85rem;
    }
    
    .table th, .table td {
        padding: 0.4rem !important;
    }
}

/* Footer optimization */
@media (max-width: 768px) {
    footer h4 {
        font-size: 1.1rem !important;
        margin-bottom: 0.75rem !important;
    }
    
    footer p {
        font-size: 0.9rem !important;
        margin-bottom: 0.5rem !important;
    }
    
    .footer-menu a {
        font-size: 0.9rem !important;
        padding: 0.25rem 0 !important;
    }
}

@media (max-width: 576px) {
    footer h4 {
        font-size: 1rem !important;
    }
    
    footer p {
        font-size: 0.85rem !important;
    }
    
    .col-lg-3, .col-md-6 {
        margin-bottom: 1.5rem;
    }
}

/* Back to top button responsive */
@media (max-width: 576px) {
    .back-to-top {
        right: 20px;
        bottom: 20px;
        width: 45px;
        height: 45px;
    }
}

/* Admission/Hero CTA buttons */
@media (max-width: 768px) {
    .admission-cta-btn,
    .page-btn,
    .cta-btn {
        width: 100%;
        display: block;
        text-align: center;
        margin: 1rem 0 !important;
        padding: 0.75rem 1.5rem !important;
    }
}

@media (max-width: 576px) {
    .admission-cta-btn,
    .page-btn,
    .cta-btn {
        font-size: 0.9rem !important;
        padding: 0.6rem 1.2rem !important;
    }
}