/* Modern Government Educational Institution Style */
:root {
    --primary-blue: #004b87;
    --secondary-green: #008000;
    --light-bg: #EAE5E1;
    --dark-text: #212529;
    
    /* Font System */
    --font-body-bn: 'Noto Sans Bengali', sans-serif;
    --font-heading-bn: 'Noto Serif Bengali', serif;
    --font-en-nav-btn: 'Montserrat', var(--font-body-bn);
    --font-footer: 'Lato', var(--font-body-bn);
}
html, body {
    overflow-x: hidden;
    -ms-overflow-style: none;  
    scrollbar-width: none;  
}

::-webkit-scrollbar {
    display: none;
}
body {
    font-family: var(--font-body-bn);
    color: var(--dark-text);
    background-color: var(--light-bg);
}

h1, h2, h3, h4, h5, h6, .section-title {
    font-family: var(--font-heading-bn);
}

/* Topbar */
.topbar {
    background-color: var(--primary-blue);
    color: white;
    font-size: 0.9rem;
    padding: 5px 0;
}
.topbar a { color: white; text-decoration: none; }
.topbar a:hover { text-decoration: underline; }

/* Header */
.header-section {
    background-color: white;
    padding: 45px 0;
    border-bottom: 2px solid var(--secondary-green);
}
.school-title {
    font-family: 'Montserrat', var(--font-heading-bn);
    color: #003366;
    font-weight: bold;
    margin-bottom: 0;
    text-shadow: 1px 1px 3px rgba(255,255,255,0.9), 0 0 8px rgba(255,255,255,0.8);
}
.school-subtitle {
    color: #222;
    font-size: 1.1rem;
    font-weight: 600;
    text-shadow: 1px 1px 2px rgba(255,255,255,0.9);
}

/* Navbar */
.navbar-custom {
    background-color: var(--primary-blue);
    padding-top: 0;
    padding-bottom: 0;
}
.navbar-custom .nav-link {
    font-family: var(--font-en-nav-btn);
    color: white !important;
    font-weight: 500;
    padding-top: 15px !important;
    padding-bottom: 15px !important;
}
.navbar-custom .nav-link:hover {
    color: #ffc107 !important;
}
.dropdown-menu { 
    border: none; 
    box-shadow: 0 4px 6px rgba(0,0,0,0.1); 
    border-top-left-radius: 0; 
    border-top-right-radius: 0; 
    margin-top: 0 !important;
}
.dropdown-item {
    padding: 10px 20px;
    transition: all 0.2s ease;
}
.dropdown-item:hover, .dropdown-item:focus {
    background-color: #ffc107;
    color: #004b87;
}

/* Dropdown Hover Animation */
@media all and (min-width: 992px) {
    .navbar .nav-item .dropdown-menu {
        display: none;
        margin-top: 0;
    }
    .navbar .nav-item:hover .dropdown-menu {
        display: block;
        animation: fade-down .3s ease forwards;
    }
}
@keyframes fade-down {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}
/* Notice Ticker */
.notice-ticker-wrapper {
    background: #fff3cd;
    border-bottom: 1px solid #ffe69c;
    padding: 5px 0;
    display: flex;
    align-items: center;
}
.notice-label {
    background: #dc3545;
    color: white;
    padding: 2px 10px;
    font-weight: bold;
    margin-right: 15px;
    border-radius: 3px;
    white-space: nowrap;
}

/* New Footer Design */
.footer {
    background-color: #ffffff;
    color: #8c2d47;
    padding: 40px 0 0 0;
    margin-top: 50px;
    font-family: var(--font-footer);
}
.footer-heading {
    font-family: var(--font-heading-bn);
    font-size: 1.4rem;
    border-bottom: 1px solid #8c2d47;
    padding-bottom: 10px;
    margin-bottom: 20px;
    font-weight: normal;
}
.footer-school-name {
    font-size: 1.3rem;
    margin-bottom: 15px;
}
.footer-contact p {
    margin-bottom: 5px;
    font-size: 0.95rem;
}
.footer-links {
    list-style: none;
    padding-left: 0;
}
.footer-links li {
    margin-bottom: 6px;
    font-size: 0.85rem;
}
.footer-links a {
    color: #8c2d47;
    text-decoration: none;
}
.footer-links a:hover {
    text-decoration: underline;
}
.footer-separator {
    width: 100%;
    min-height: 50px;
    background: url('../images/edu-3.png') repeat-x bottom;
    background-color: #345277;
    margin-top: 20px;
    opacity: 0.8;
}
.footer-bottom {
    background-color: #345277;
    color: white;
    padding: 20px 0;
    font-family: var(--font-footer);
    text-align: center;
}
.footer-bottom h4 {
    font-family: var(--font-heading-bn);
    color: #d67a89;
    font-weight: normal;
    margin-bottom: 10px;
}
.footer-bottom p {
    margin-bottom: 0;
    font-size: 0.85rem;
}

/* Utility */
.section-title {
    color: var(--primary-blue);
    font-weight: bold;
    margin-bottom: 30px;
    position: relative;
    padding-bottom: 10px;
}
.section-title::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 50px;
    height: 3px;
    background-color: var(--secondary-green);
}
.section-title.text-center::after {
    left: 50%;
    transform: translateX(-50%);
}
.card { border: none; box-shadow: 0 2px 10px rgba(0,0,0,0.05); transition: transform 0.3s; }
.card:hover { transform: translateY(-5px); }

/* Buttons */
.btn {
    font-family: var(--font-en-nav-btn);
}

/* ==========================================================================
   Responsive Adjustments (Tablet & Mobile)
   ========================================================================== */

/* Tablet & Mobile (Max width: 991px) */
@media (max-width: 991px) {
    .topbar .container {
        flex-direction: column !important;
        text-align: center;
        gap: 3px;
        padding-top: 5px;
        padding-bottom: 5px;
    }
    .topbar .d-flex {
        justify-content: center;
        flex-wrap: wrap;
        width: 100%;
    }
    .topbar > .container > div {
        width: 100%;
        justify-content: center;
    }
    
    .header-section {
        text-align: center;
    }
    .school-title {
        font-size: 1.8rem;
    }
    .school-subtitle {
        font-size: 1.1rem;
    }
    
    /* Adjust Slider Height for tablets */
    .carousel-item img {
        min-height: 350px !important;
        max-height: 350px !important;
    }
    .hero-section {
        min-height: 350px !important;
    }
    
    /* Remove border-right when stacked */
    .col-lg-8.border-end {
        border-right: none !important;
        border-bottom: 2px solid var(--primary-blue) !important;
    }
}

/* Mobile Portrait (Max width: 767px) */
@media (max-width: 767px) {
    /* Topbar text scaling */
    .topbar {
        font-size: 0.85rem;
    }
    .topbar span {
        margin-right: 8px !important;
    }
    .topbar i {
        margin-left: 5px;
    }
    
    /* Header adjustments */
    .header-section {
        padding: 15px 0 !important;
    }
    .school-title {
        font-size: 1.4rem;
    }
    .school-subtitle {
        font-size: 1rem;
    }
    .header-section img {
        max-height: 70px !important;
    }
    
    /* Adjust Slider Height for mobiles */
    .carousel-item img {
        min-height: 250px !important;
        max-height: 250px !important;
    }
    .hero-section {
        min-height: 250px !important;
    }
    
    /* Quick Links */
    .quick-link-card i {
        font-size: 2rem !important;
        margin-bottom: 0.5rem !important;
    }
    .quick-link-card h5 {
        font-size: 1rem !important;
    }
    .quick-link-card .card-body {
        padding: 1.25rem 0.5rem !important;
    }
    
    /* Section Titles */
    h3[style*="font-size: 22px"], 
    h3[style*="font-size: 24px"] {
        font-size: 1.25rem !important;
    }
    
    /* Headmaster Message */
    .d-flex.flex-column.flex-sm-row {
        text-align: center;
    }
    
    /* Calendar height */
    #homeCalendar {
        min-height: 380px !important;
    }
    
    /* Notice Ticker */
    .notice-ticker-wrapper .container {
        overflow: hidden;
    }
    .notice-label {
        font-size: 0.8rem;
        padding: 3px 8px;
        margin-right: 10px;
    }
    
    /* Footer */
    .footer {
        padding: 30px 0 0 0;
    }
    .footer-heading {
        font-size: 1.25rem;
    }
    .footer-contact p, .footer-links li {
        font-size: 0.95rem;
        word-wrap: break-word;
    }
    .footer-bottom {
        padding: 15px 0;
    }
    .footer-bottom h4 {
        font-size: 1.2rem;
    }
    
    /* Prevent overflow on small screens */
    img, iframe, .card {
        max-width: 100%;
    }
}
