/* --- CSS Variables for exact colors --- */
:root {
    --primary-red: #eb3916;
    --text-blue: #2b459e;
    --footer-bg: #c3e8f5;
    --yellow-highlight: #ffeb3b;
    --font-heading: 'Merriweather', serif;
    --font-body: 'Open Sans', sans-serif;
}

/* --- General Reset & Base Styles --- */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}
html {
    scroll-behavior: smooth;
}
body {
    font-family: var(--font-body);
    color: #333;
    overflow-x: hidden;
    background-color: #fff;
}
a {
    text-decoration: none;
    color: inherit;
    transition: color 0.3s ease;
}

/* --- Keyframe Animations --- */
@keyframes fadeInDown {
    from { opacity: 0; transform: translateY(-20px); }
    to { opacity: 1; transform: translateY(0); }
}
@keyframes fadeInUp {
    from { opacity: 0; transform: translateY(30px); }
    to { opacity: 1; transform: translateY(0); }
}
@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

/* Animation Classes */
.anim-fade-down { animation: fadeInDown 0.8s ease forwards; }
.anim-fade-up { animation: fadeInUp 0.8s ease forwards; }
.anim-fade-in { animation: fadeIn 1.2s ease forwards; }

/* --- Top Red Bar --- */
.top-bar {
    background-color: var(--primary-red);
    color: white;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 5%;
    font-size: 14px;
    font-weight: 700;
    font-family: var(--font-heading);
    font-style: italic;
}
.top-bar-left, .top-bar-right {
    display: flex;
    align-items: center;
    gap: 25px;
}
.top-bar i {
    margin-right: 8px;
    font-style: normal;
}

/* --- Header & Navigation --- */
.site-header {
    position: relative;
    z-index: 99999; /* CRITICAL FIX: Lifts the entire header above the marquee */
    background-color: white;
}

.main-header {
    display: flex;
    align-items: center;
    padding: 0px 5%;
    background-color: white;
}
.logo {
    height: 85px;
    margin-right: 15px;
    transition: transform 0.3s ease;
}
/* .logo:hover {
    transform: scale(1.05);
} */

.navbar {
    padding: 0 5%;
    background-color: white;
    border-bottom: 1px solid #eee;
    position: relative;
    z-index: 9999; 
}
.navbar > ul {
    list-style: none;
    display: flex;
    gap: 35px;
}
.navbar li {
    position: relative;
}
.navbar a {
    font-size: 14px;
    font-weight: bold;
    color: #111;
    text-transform: uppercase;
    padding: 18px 0;
    display: block;
    cursor: pointer;
}

/* Navigation Hover Animation */
.navbar > ul > li > a::after {
    content: '';
    position: absolute;
    width: 0;
    height: 3px;
    bottom: 10px;
    left: 0;
    background-color: var(--text-blue);
    transition: width 0.3s ease;
}
.navbar > ul > li > a:hover::after {
    width: 100%;
}
.navbar a:hover {
    color: var(--text-blue);
}
.navbar .fa-chevron-down {
    font-size: 10px;
    margin-left: 5px;
    transition: transform 0.3s;
}
.navbar li.active > a .fa-chevron-down {
    transform: translateY(3px) rotate(180deg);
}

/* --- Dropdown Menu Styles --- */
/* --- Dropdown Menu Styles (Hover to Open) --- */
.dropdown-menu {
    position: absolute;
    top: 100%;
    left: 0;
    background-color: #fff;
    box-shadow: 0 5px 15px rgba(0,0,0,0.2);
    min-width: 220px;
    list-style: none;
    display: flex; /* Changed to flex */
    flex-direction: column;
    gap: 0;
    z-index: 100000;
    border-top: 3px solid var(--primary-red);
    
    /* Hidden by default */
    opacity: 0;
    visibility: hidden;
    transform: translateY(10px);
    transition: all 0.3s ease;
}

/* Show dropdown when hovering over the parent li */
.navbar li.dropdown-toggle:hover .dropdown-menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

/* Rotate the chevron icon on hover */
.navbar li.dropdown-toggle:hover > a .fa-chevron-down {
    transform: translateY(3px) rotate(180deg);
}

.dropdown-menu li {
    width: 100%;
}

.dropdown-menu a {
    padding: 12px 20px;
    font-size: 13px;
    text-transform: capitalize;
    border-bottom: 1px solid #f1f1f1;
}

.dropdown-menu a::after {
    display: none; 
}

.dropdown-menu a:hover {
    background-color: #f9f9f9;
    color: var(--primary-red);
    padding-left: 25px;
}

/* --- Admission Banner (Marquee Style) --- */
.admission-banner {
    background-color: var(--primary-red);
    padding: 12px 0;
    overflow: hidden;
    display: flex;
    white-space: nowrap;
    position: relative;
    z-index: 10;
}
.marquee-content {
    display: flex;
    animation: marqueeScroll 15s linear infinite;
}
.admission-banner a {
    color: var(--yellow-highlight);
    font-weight: 700;
    font-size: 14px;
    text-decoration: underline;
    padding-right: 50px;
}
@keyframes marqueeScroll {
    0% { transform: translateX(0); }
    100% { transform: translateX(-50%); } 
}
.admission-banner:hover .marquee-content {
    animation-play-state: paused;
}
/* --- Carousel / Hero Section --- */
.hero {
    position: relative;
    width: 100%;
    height: 480px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 2%;
    overflow: hidden;
    background-color: #f0f0f0; /* Fallback background */
}

.carousel-container {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
}

.carousel-slide {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    transition: opacity 1s ease-in-out;
    background-size: cover;
    background-position: center top;
}

.carousel-slide img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* CSS Auto-Rotate Animation for 2 images */
.carousel-slide.active {
    animation: fadeSlide1 10s infinite;
}
.carousel-slide:not(.active) {
    animation: fadeSlide2 10s infinite;
}

@keyframes fadeSlide1 {
    0%, 45% { opacity: 1; }
    55%, 100% { opacity: 0; }
}

@keyframes fadeSlide2 {
    0%, 45% { opacity: 0; }
    55%, 100% { opacity: 1; }
}

.hero-arrow {
    width: 55px;
    height: 55px;
    background-color: #f26b5e;
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    color: white;
    font-size: 20px;
    cursor: pointer;
    z-index: 10; /* Keeps arrows above images */
    transition: all 0.3s ease;
    box-shadow: 0 4px 10px rgba(0,0,0,0.2);
}

.hero-arrow:hover {
    background-color: var(--primary-red);
    transform: scale(1.1);
}

/* --- Carousel / Hero Section --- */
/* .hero {
    position: relative;
    width: 100%;
    height: 480px;
    background-image: url('https://images.unsplash.com/photo-1503676260728-1c00da094a0b?ixlib=rb-4.0.3&auto=format&fit=crop&w=1920&q=80');
    background-size: cover;
    background-position: center top;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 2%;
    overflow: hidden;
}
.hero-arrow {
    width: 55px;
    height: 55px;
    background-color: #f26b5e;
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    color: white;
    font-size: 20px;
    cursor: pointer;
    z-index: 10;
    transition: all 0.3s ease;
    box-shadow: 0 4px 10px rgba(0,0,0,0.2);
}
.hero-arrow:hover {
    background-color: var(--primary-red);
    transform: scale(1.1);
} */

/* --- Welcome Section --- */
.welcome-section {
    text-align: center;
    padding: 60px 5%;
}
.welcome-section h1 {
    color: var(--text-blue);
    font-family: var(--font-heading);
    font-size: 42px;
    margin-bottom: 15px;
    font-weight: 400;
}
.welcome-section p {
    font-size: 18px;
    color: #555;
    margin-bottom: 50px;
    font-family: var(--font-heading);
}

.features-container {
    display: flex;
    justify-content: space-between;
    gap: 25px;
}
.feature-card {
    flex: 1;
    text-align: center;
    cursor: pointer;
}
.feature-img-wrapper {
    overflow: hidden;
    border: 2px dashed #f0a8b8;
    padding: 5px;
    margin-bottom: 20px;
    background-color: white;
    transition: box-shadow 0.3s ease, transform 0.3s ease;
}
.feature-card img {
    width: 100%;
    height: 180px;
    object-fit: cover;
    display: block;
    transition: transform 0.5s ease;
}
/* .feature-card:hover .feature-img-wrapper {
    box-shadow: 0 10px 20px rgba(0,0,0,0.1);
    transform: translateY(-5px);
}
.feature-card:hover img {
    transform: scale(1.08);
} */
.feature-card h3 {
    font-size: 19px;
    font-weight: 400;
    color: #222;
    font-family: var(--font-body);
    line-height: 1.4;
}

/* --- Dotted Background Pattern --- */
.bg-dotted-lines {
    position: relative;
    background-image: url("data:image/svg+xml,%3Csvg width='400' height='400' viewBox='0 0 400 400' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M-50,50 Q100,-20 200,50 T450,100' stroke='%2389cff0' stroke-width='2' fill='none' stroke-dasharray='8,8'/%3E%3Cpath d='M-50,300 Q100,400 250,300 T450,350' stroke='%2389cff0' stroke-width='2' fill='none' stroke-dasharray='8,8'/%3E%3C/svg%3E");
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
}

/* --- History Section --- */
.history-section {
    display: flex;
    align-items: center;
    padding: 80px 10%;
    gap: 60px;
    position: relative;
}
.history-text {
    flex: 1.2;
}
.history-text h2 {
    color: var(--primary-red);
    font-family: var(--font-heading);
    font-size: 40px;
    font-weight: 700;
    margin-bottom: 25px;
    font-style: italic;
}
.history-text p {
    font-family: var(--font-heading);
    font-size: 18px;
    line-height: 1.7;
    margin-bottom: 25px;
    text-align: justify;
    font-style: italic;
    font-weight: 700;
}
.read-more {
    color: #666;
    font-size: 14px;
    letter-spacing: 1px;
    transition: color 0.3s ease, padding-left 0.3s ease;
    display: inline-block;
}
.read-more:hover {
    color: var(--primary-red);
    padding-left: 5px;
}
.history-image {
    flex: 0.8;
    border: 8px solid #c81e6d;
    padding: 8px;
    background-color: white;
    box-shadow: 0 10px 30px rgba(0,0,0,0.15);
    transition: transform 0.4s ease;
}
.history-image:hover {
    transform: rotate(2deg) scale(1.02);
}
.history-image img {
    width: 100%;
    display: block;
}

/* --- Headmistress Section --- */
.headmistress-section {
    display: flex;
    align-items: center;
    padding: 40px 10% 100px;
    gap: 60px;
}
.hm-image {
    flex: 1;
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
}
.hm-image img {
    width: 100%;
    display: block;
    border: 1px solid #ccc;
}
.hm-text {
    flex: 1.2;
}
.hm-text h2 {
    color: var(--primary-red);
    font-family: var(--font-heading);
    font-size: 38px;
    font-weight: 700;
    margin-bottom: 15px;
    font-style: italic;
}
.hm-quote {
    color: #2c62c9;
    font-family: var(--font-heading);
    font-size: 22px;
    font-weight: 700;
    font-style: italic;
    margin-bottom: 20px;
}
.hm-text p {
    font-family: var(--font-heading);
    font-size: 17px;
    line-height: 1.7;
    margin-bottom: 15px;
    text-align: justify;
    font-weight: 700;
}
.hm-signature {
    font-family: var(--font-heading);
    font-weight: 700;
    font-size: 18px;
    margin-top: 20px;
}

/* --- Footer with Exact Brushed Border --- */
.footer {
    background-color: var(--footer-bg);
    padding: 80px 8% 70px; 
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    position: relative;
    margin-top: 50px; /* Space for the brush stroke */
}

/* The High-Resolution Brushed SVG Effect */
.footer::before {
    content: '';
    position: absolute;
    top: -40px; /* Pulls it up to overlap the white space */
    left: 0;
    width: 100%;
    height: 45px;
    /* Base64 Encoded SVG creating a jagged paint brush effect */
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 1200 60' preserveAspectRatio='none'%3E%3Cpath d='M0,30 C10,28 15,15 25,20 C35,25 40,40 50,42 C60,44 65,30 75,28 C85,26 90,35 100,35 C110,35 115,20 125,22 C135,24 140,45 150,48 C160,51 165,35 175,32 C185,29 190,40 200,42 C210,44 215,25 225,22 C235,19 240,38 250,40 C260,42 265,30 275,28 C285,26 290,15 300,18 C310,21 315,35 325,38 C335,41 340,25 350,22 C360,19 365,45 375,48 C385,51 390,40 400,38 C410,36 415,22 425,20 C435,18 440,42 450,45 C460,48 465,30 475,28 C485,26 490,15 500,18 C510,21 515,40 525,42 C535,44 540,25 550,22 C560,19 565,38 575,40 C585,42 590,30 600,28 C610,26 615,15 625,18 C635,21 640,35 650,38 C660,41 665,25 675,22 C685,19 690,45 700,48 C710,51 715,40 725,38 C735,36 740,22 750,20 C760,18 765,42 775,45 C785,48 790,30 800,28 C810,26 815,15 825,18 C835,21 840,40 850,42 C860,44 865,25 875,22 C885,19 890,38 900,40 C910,42 915,30 925,28 C935,26 940,15 950,18 C960,21 965,35 975,38 C985,41 990,25 1000,22 C1010,19 1015,45 1025,48 C1035,51 1040,40 1050,38 C1060,36 1065,22 1075,20 C1085,18 1090,42 1100,45 C1110,48 1115,30 1125,28 C1135,26 1140,15 1150,18 C1160,21 1165,40 1175,42 C1185,44 1190,30 1200,28 L1200,60 L0,60 Z' fill='%23c3e8f5'/%3E%3C/svg%3E");
    background-size: 100% 100%;
    background-repeat: no-repeat;
    z-index: 1;
}

/* White background mask behind the brush stroke */
.footer::after {
    content: '';
    position: absolute;
    top: -42px;
    left: 0;
    width: 100%;
    height: 45px;
    background-color: #fff;
    z-index: 0;
}

.footer-col {
    flex: 1;
    padding: 0 20px;
    position: relative;
    z-index: 2; /* Keep content above the brush stroke */
}
.footer-col.logo-col {
    flex: 1.2;
    text-align: center;
}
.footer-col.logo-col img {
    height: 85px;
    margin-bottom: 15px;
    transition: transform 0.3s;
}
.footer-col.logo-col img:hover {
    transform: scale(1.1);
}
.footer-col.logo-col h4 {
    font-family: 'Arial Black', sans-serif;
    font-size: 16px;
    margin-bottom: 15px;
    color: #000;
}
.footer-col.logo-col p {
    font-family: var(--font-body);
    font-size: 15px;
    color: #333;
    text-align: left;
    line-height: 1.6;
}
.footer-col h3 {
    color: var(--text-blue);
    margin-bottom: 25px;
    font-size: 20px;
    font-weight: 700;
}
.footer-col ul {
    list-style: none;
}
.footer-col ul li {
    margin-bottom: 15px;
    font-size: 16px;
    font-family: var(--font-body);
    color: #333;
}
.footer-col ul li a {
    display: flex;
    align-items: center;
}
.footer-col ul li a::before {
    content: "•";
    color: var(--text-blue);
    font-weight: bold;
    font-size: 20px;
    margin-right: 10px;
    transition: color 0.3s, transform 0.3s;
}
.footer-col ul li a:hover {
    color: var(--text-blue);
}
.footer-col ul li a:hover::before {
    transform: translateX(5px);
}

.footer-info-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 15px;
}

.footer-col.contact-col p {
    margin-bottom: 18px;
    font-family: var(--font-body);
    font-size: 16px;
    color: #333;
    display: flex;
    align-items: flex-start;
    gap: 12px;
    line-height: 1.5;
}
.footer-col.contact-col i {
    color: var(--text-blue);
    margin-top: 4px;
}

/* --- Floating Social Sidebar --- */
.social-sidebar {
    position: fixed;
    right: 0;
    top: 50%;
    transform: translateY(-50%);
    display: flex;
    flex-direction: column;
    gap: 8px;
    z-index: 100;
}
.social-icon {
    width: 55px;
    height: 55px;
    display: flex;
    justify-content: center;
    align-items: center;
    color: white;
    font-size: 24px;
    border-top-left-radius: 30px;
    border-bottom-left-radius: 30px;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: -2px 2px 10px rgba(0,0,0,0.2);
}
.social-icon:hover {
    transform: translateX(-10px);
}
.social-icon.school { background-color: #0b63b6; }
.social-icon.youtube { background-color: #e60000; }
.social-icon.facebook { background-color: #1877f2; }
.social-icon.phone { background-color: #e60000; }

/* --- Back to Top Button --- */
.back-to-top {
    position: fixed;
    bottom: 30px;
    right: 25px;
    width: 45px;
    height: 45px;
    background-color: white;
    border: 1px solid #ddd;
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    color: #666;
    cursor: pointer;
    box-shadow: 0 4px 10px rgba(0,0,0,0.15);
    z-index: 100;
    transition: all 0.3s ease;
    opacity: 0;
    visibility: hidden;
}
.back-to-top.show {
    opacity: 1;
    visibility: visible;
}
.back-to-top:hover {
    background-color: var(--text-blue);
    color: white;
    transform: translateY(-5px);
}
/* =========================================================
   RESPONSIVE DESIGN (Mobile & Tablet)
   ========================================================= */

/* Hide the hamburger button on Desktop */
.mobile-menu-btn {
    display: none;
    font-size: 28px;
    color: #111;
    cursor: pointer;
    margin-left: auto; /* Pushes it to the right */
}

/* --- Tablet View (Max Width 992px) --- */
@media (max-width: 992px) {
    /* Features: 2x2 Grid */
    .features-container {
        flex-wrap: wrap;
    }
    .feature-card {
        flex: 1 1 45%;
        margin-bottom: 20px;
    }

    /* History & Headmistress: Stack vertically */
    .history-section, .headmistress-section {
        flex-direction: column;
        padding: 50px 5%;
        text-align: center;
    }
    .history-text p, .hm-text p {
        text-align: center;
    }
    .history-image, .hm-image {
        width: 80%;
        margin: 0 auto;
    }

    /* Footer: Stack into 2 columns */
    .footer {
        flex-wrap: wrap;
        padding: 60px 5% 40px;
    }
    .footer-col {
        flex: 1 1 50%;
        margin-bottom: 30px;
    }
}

/* --- Mobile View (Max Width 768px) --- */
@media (max-width: 768px) {
    /* Top Bar: Hide location on small screens */
    .top-bar {
        flex-direction: column;
        gap: 5px;
        text-align: center;
        padding: 10px 5%;
    }
    .top-bar-left, .top-bar-right {
        flex-direction: column;
        gap: 5px;
    }
    .top-bar-left span:nth-child(2) {
        display: none; /* Hides the long address */
    }

    /* Decrease Logo Size */
    .logo {
        height: 55px; 
    }

    /* Mobile Navigation */
    .mobile-menu-btn {
        display: block; /* Show hamburger */
    }

    .navbar {
        display: none; /* Hide menu by default on mobile */
        position: absolute;
        top: 100%;
        left: 0;
        width: 100%;
        background-color: white;
        box-shadow: 0 5px 15px rgba(0,0,0,0.1);
        padding: 10px 5%;
        z-index: 999;
    }

    /* Class added by JS to show menu */
    .navbar.active {
        display: block;
    }

    .navbar > ul {
        flex-direction: column;
        gap: 0;
    }

    .navbar li {
        width: 100%;
        border-bottom: 1px solid #eee;
    }
    
    .navbar li:last-child {
        border-bottom: none;
    }

    .navbar a {
        padding: 15px 0;
        font-size: 15px;
    }

    /* Mobile Dropdowns */
    .dropdown-menu {
        position: static;
        box-shadow: none;
        border-top: none;
        background-color: #f9f9f9;
        display: none; /* Keep hidden */
        opacity: 1;
        visibility: visible;
        transform: none;
        padding-left: 15px;
    }

    /* Show mobile dropdown on hover/click */
    .navbar li.dropdown-toggle:hover .dropdown-menu {
        display: block;
    }

    /* Hero Section */
    .hero {
        height: 250px;
    }
    .hero-arrow {
        width: 40px;
        height: 40px;
        font-size: 16px;
    }

    /* Typography Resizing */
    .welcome-section h1 { font-size: 28px; }
    .welcome-section p { font-size: 16px; }
    .history-text h2, .hm-text h2 { font-size: 30px; }
    .hm-quote { font-size: 18px; }

    /* Features: 1 Column */
    .feature-card {
        flex: 1 1 100%;
    }

    /* --- MOBILE FOOTER FIX --- */
    .footer {
        flex-direction: column;
        padding: 50px 5% 70px 5%; 
        text-align: center; 
    }
    
    .footer-col {
        flex: 1 1 100%;
        width: 100%;
        padding: 0;
        margin-bottom: 35px; 
    }
    
    .footer-col:last-child {
        margin-bottom: 0;
    }

    .footer-col.logo-col p {
        text-align: center;
        margin-top: 15px;
        font-size: 14px;
        padding: 0 10px;
    }

    /* FIX: Force 2 columns for information links */
    .footer-info-grid {
        display: grid !important;
        grid-template-columns: 1fr 1fr !important;
        gap: 10px;
        text-align: left; 
        max-width: 260px; 
        margin: 0 auto;   
    }

    .footer-info-grid ul {
        width: 100%;
    }

    .footer-col ul li a {
        font-size: 15px;
    }

    .footer-col.contact-col h3 {
        margin-bottom: 15px;
    }

    /* Reach Us Section */
    .footer-col.contact-col p {
        justify-content: flex-start;
        text-align: left;
        flex-direction: row; 
        align-items: flex-start;
        max-width: 280px;
        margin: 0 auto 15px auto; 
        font-size: 14px;
        gap: 10px;
    }
    
    .footer-col.contact-col i {
        margin-top: 3px;
        font-size: 16px;
    }

    /* Office timings */
    .footer-col.contact-col p[style] {
        text-align: center !important;
        justify-content: center !important;
        margin-top: 20px;
        font-size: 15px !important;
    }

    /* Social Sidebar: Keep on the Right Side */
    .social-sidebar {
        flex-direction: column;
        top: 50%;
        right: 0;
        bottom: auto;
        transform: translateY(-50%);
        width: auto;
        background-color: transparent;
        box-shadow: none;
    }
    
    .social-icon {
        width: 40px;
        height: 40px;
        font-size: 16px;
        border-radius: 20px 0 0 20px; 
    }
    
    .social-icon:hover {
        transform: translateX(-5px);
    }

    /* Back to top button position */
    .back-to-top {
        bottom: 20px;
        right: 15px;
        width: 40px;
        height: 40px;
    }
}


/* =========================================================
   ABOUT PAGE: ANIMATED CLOUD BANNER
   ========================================================= */

.page-banner {
    position: relative;
    width: 100%;
    height: 350px;
    /* Blue education pattern background */
    background-color: #4364f7;
    background-image: url("data:image/svg+xml,%3Csvg width='100' height='100' viewBox='0 0 100 100' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M20 20h10v10H20zM40 40h5v5h-5zM70 60h15v15H70z' fill='%23ffffff' fill-opacity='0.05'/%3E%3C/svg%3E"); /* Placeholder pattern */
    display: flex;
    justify-content: center;
    align-items: center;
    overflow: hidden;
}

/* To get the exact doodle background, replace the above background-image with your actual pattern image */
.page-banner {
    background-image: url('https://www.transparenttextures.com/patterns/black-scales.png'); /* Temporary texture */
    background-color: #3a5cff; /* The blue color from your image */
}

.banner-content {
    text-align: center;
    color: white;
    z-index: 10;
    margin-bottom: 50px; /* Push up slightly to make room for clouds */
}

.banner-content h1 {
    font-family: var(--font-heading);
    font-size: 52px;
    font-weight: 400;
    margin-bottom: 10px;
}

.breadcrumbs {
    font-family: var(--font-body);
    font-size: 15px;
    font-weight: 700;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 10px;
    color: rgba(255, 255, 255, 0.8);
}

.breadcrumbs a:hover {
    color: white;
}

.breadcrumbs .current-page {
    color: white;
}

/* --- Cloud Animation Logic --- */
.clouds-container {
    position: absolute;
    bottom: -5px; /* Slight overlap to prevent white lines */
    left: 0;
    width: 100%;
    height: 120px;
    pointer-events: none; /* Allows clicking through clouds */
}

.cloud-layer {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 200%; /* 200% width to allow seamless scrolling */
    height: 100%;
    background-repeat: repeat-x;
    background-position: 0 bottom;
    background-size: 50% 100%; /* Fits 2 sets of clouds in the 200% width */
}

/* Front Clouds: Solid White */
.front-clouds {
    /* SVG Cloud Shape */
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 1000 120' preserveAspectRatio='none'%3E%3Cpath d='M0,120 L0,90 C50,90 100,40 150,40 C200,40 230,70 280,70 C340,70 360,20 430,20 C480,20 510,60 560,60 C630,60 660,10 730,10 C790,10 820,50 870,50 C910,50 960,20 1000,30 L1000,120 Z' fill='%23ffffff'/%3E%3C/svg%3E");
    z-index: 2;
    animation: moveCloudsRight 25s linear infinite;
}

/* Back Clouds: Slightly Transparent for Depth */
.back-clouds {
    /* Different SVG Cloud Shape */
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 1000 120' preserveAspectRatio='none'%3E%3Cpath d='M0,120 L0,60 C80,60 120,20 200,20 C260,20 300,60 380,60 C450,60 500,10 580,10 C650,10 700,50 780,50 C850,50 900,30 1000,30 L1000,120 Z' fill='%23e6f0ff' fill-opacity='0.8'/%3E%3C/svg%3E");
    z-index: 1;
    height: 90%; /* Slightly shorter than front clouds */
    animation: moveCloudsLeft 35s linear infinite;
}

/* Keyframes to move the clouds */
@keyframes moveCloudsRight {
    0% { transform: translateX(0); }
    100% { transform: translateX(-50%); } /* Moves exactly half its width (one full cycle of the pattern) */
}

@keyframes moveCloudsLeft {
    0% { transform: translateX(-50%); }
    100% { transform: translateX(0); }
}


/* =========================================================
   HEADMISTRESS PAGE SPECIFIC STYLES
   ========================================================= */

/* Main wrapper for the page content */
.headmistress-page-bg {
    position: relative;
    /* Reversing the column layout so Image is on the right, Text on the left (like your screenshot) */
    flex-direction: row-reverse; 
    padding: 80px 10% 100px;
    background-color: #fff;
    overflow: hidden; /* Keeps the decorative lines inside the section */
}

/* Decorative dashed lines background */
.headmistress-page-bg::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 0;
    pointer-events: none; /* Allows you to select text over the background */
    
    /* Multiple SVG paths to create the scattered dashed circles and lines */
    background-image: 
        /* Large swooping line on the right */
        url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 500 500'%3E%3Cpath d='M450,-50 C550,100 400,300 500,550' stroke='%2334a8d9' stroke-width='2' stroke-dasharray='8,8' fill='none'/%3E%3C/svg%3E"),
        /* Circle bottom right */
        url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 200 200'%3E%3Ccircle cx='100' cy='100' r='80' stroke='%2334a8d9' stroke-width='2' stroke-dasharray='8,8' fill='none'/%3E%3C/svg%3E"),
        /* Wavy line bottom left */
        url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 300 300'%3E%3Cpath d='M-50,150 Q50,50 150,150 T350,150' stroke='%2334a8d9' stroke-width='2' stroke-dasharray='8,8' fill='none'/%3E%3C/svg%3E"),
        /* Small circle left */
        url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 100 100'%3E%3Ccircle cx='50' cy='50' r='40' stroke='%2334a8d9' stroke-width='2' stroke-dasharray='8,8' fill='none'/%3E%3C/svg%3E"),
        /* Vertical squiggle near image */
        url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 200 400'%3E%3Cpath d='M50,-50 C150,100 0,200 100,450' stroke='%2334a8d9' stroke-width='2' stroke-dasharray='8,8' fill='none'/%3E%3C/svg%3E");

    /* Position the paths around the screen */
    background-position: 
        right -50px top 50px,   /* Swooping line */
        right 50px bottom 50px, /* Bottom right circle */
        left -50px bottom 50px, /* Bottom left wave */
        left 50px top 150px,    /* Small left circle */
        right 400px top 100px;  /* Squiggle near image */
        
    background-repeat: no-repeat;
    background-size: 
        400px, 
        200px, 
        300px, 
        100px, 
        150px;
}

/* Ensure text and image sit above the background lines */
.headmistress-page-bg .hm-image,
.headmistress-page-bg .hm-text {
    position: relative;
    z-index: 1;
}

/* Adjusting the image wrapper to match the screenshot (no extra border) */
.headmistress-page-bg .hm-image {
    box-shadow: none;
    flex: 0.9;
}

.headmistress-page-bg .hm-image img {
    border: none;
}

/* Adjusting the text area */
.headmistress-page-bg .hm-text {
    flex: 1.2;
    padding-right: 40px; /* Space between text and image */
}

/* Mobile Responsive adjustments for this page */
@media (max-width: 992px) {
    .headmistress-page-bg {
        flex-direction: column-reverse; /* Put image on top on mobile */
        padding: 50px 5%;
    }
    .headmistress-page-bg .hm-text {
        padding-right: 0;
    }
    .headmistress-page-bg::before {
        /* Shrink background sizes on mobile */
        background-size: 200px, 100px, 150px, 80px, 100px;
    }
}

/* =========================================================
   ADMISSION PAGE STYLES
   ========================================================= */

.admission-content-section {
    padding: 60px 10%;
    max-width: 1100px;
    margin: 0 auto;
    font-family: var(--font-heading);
    color: #333;
}

/* Alert Box for Birth Certificate */
.admission-alert {
    background-color: #fff3cd;
    color: #856404;
    padding: 15px 20px;
    border-left: 5px solid #ffeeba;
    border-radius: 4px;
    font-size: 18px;
    font-weight: 700;
    margin-bottom: 40px;
    display: flex;
    align-items: center;
    gap: 10px;
}

/* Sections */
.admission-block {
    margin-bottom: 40px;
}

.section-title {
    color: var(--primary-red);
    font-family: var(--font-heading);
    font-size: 24px;
    font-weight: 700;
    margin-bottom: 20px;
    font-style: italic;
    border-bottom: 2px solid #eee;
    padding-bottom: 10px;
}

/* Lists */
.admission-list {
    list-style: none;
    padding-left: 0;
}

.admission-list li {
    position: relative;
    padding-left: 25px;
    margin-bottom: 15px;
    font-size: 16px;
    line-height: 1.6;
    font-weight: 700;
}

/* Custom bullet point */
.admission-list li::before {
    content: "•";
    color: var(--text-blue);
    font-size: 24px;
    position: absolute;
    left: 0;
    top: -4px;
}

.link-blue {
    color: var(--text-blue);
    text-decoration: underline;
}

/* Notes */
.admission-note {
    background-color: #f9f9f9;
    padding: 15px;
    border-left: 4px solid var(--text-blue);
    font-size: 16px;
    margin-top: 20px;
    font-weight: 700;
}

/* Apply Button Section */
.apply-btn-container {
    text-align: center;
    margin-top: 60px;
    padding-top: 40px;
    border-top: 1px dashed #ccc;
}

.apply-btn {
    display: inline-block;
    background-color: var(--primary-red);
    color: white;
    font-size: 20px;
    font-weight: 700;
    padding: 15px 50px;
    border-radius: 30px;
    text-transform: uppercase;
    box-shadow: 0 4px 15px rgba(235, 57, 22, 0.3);
    transition: all 0.3s ease;
    font-family: var(--font-body);
}

.apply-btn:hover {
    background-color: #c92f11;
    transform: translateY(-3px);
    box-shadow: 0 6px 20px rgba(235, 57, 22, 0.5);
    color: white;
}

.final-note {
    margin-top: 20px;
    color: var(--primary-red);
    font-size: 16px;
    font-weight: 700;
}

/* --- Mobile Responsiveness for Admission Page --- */
@media (max-width: 768px) {
    .admission-content-section {
        padding: 40px 5%;
    }
    .section-title {
        font-size: 20px;
    }
    .admission-list li {
        font-size: 15px;
    }
    .apply-btn {
        width: 100%;
        padding: 15px;
    }
}


/* =========================================================
   ADMISSION FORM STYLES
   ========================================================= */

.form-section {
    padding: 60px 10%;
    max-width: 1100px;
    margin: 0 auto;
    background-color: #fff;
}

.form-header {
    text-align: center;
    margin-bottom: 40px;
}

.form-header h2 {
    color: var(--text-blue);
    font-family: var(--font-heading);
    font-size: 36px;
    margin-bottom: 10px;
}

.fee-badge {
    display: inline-block;
    background-color: var(--primary-red);
    color: white;
    padding: 8px 20px;
    border-radius: 20px;
    font-weight: 700;
    font-size: 16px;
}

.admission-form {
    background-color: #f9fbfd;
    padding: 40px;
    border-radius: 10px;
    box-shadow: 0 5px 20px rgba(0,0,0,0.05);
    border-top: 5px solid var(--text-blue);
}

/* Section Blocks */
.form-group-container {
    margin-bottom: 40px;
    background: #fff;
    padding: 25px;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.03);
    border: 1px solid #eef2f5;
}

.form-section-title {
    color: var(--primary-red);
    font-family: var(--font-heading);
    font-size: 22px;
    margin-bottom: 25px;
    display: flex;
    align-items: center;
    border-bottom: 2px solid #f1f1f1;
    padding-bottom: 15px;
}

.form-section-title span {
    background-color: var(--text-blue);
    color: white;
    width: 30px;
    height: 30px;
    display: inline-flex;
    justify-content: center;
    align-items: center;
    border-radius: 50%;
    margin-right: 15px;
    font-size: 16px;
    font-family: var(--font-body);
}

/* Grid Layouts */
.form-grid {
    display: flex;
    gap: 30px;
}

.form-grid-1 {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.input-fields {
    flex: 1;
}

.form-row {
    display: flex;
    gap: 20px;
    margin-bottom: 20px;
}

.form-row:last-child {
    margin-bottom: 0;
}

.form-group {
    flex: 1;
    display: flex;
    flex-direction: column;
}

.form-group.full-width {
    flex: 1 1 100%;
}

/* Labels & Inputs */
.form-group label {
    font-size: 14px;
    font-weight: 700;
    color: #444;
    margin-bottom: 8px;
    font-family: var(--font-body);
}

.req {
    color: var(--primary-red);
}

.form-group input[type="text"],
.form-group input[type="date"],
.form-group input[type="email"],
.form-group input[type="tel"],
.form-group select,
.form-group textarea {
    padding: 12px 15px;
    border: 1px solid #ccc;
    border-radius: 5px;
    font-family: var(--font-body);
    font-size: 14px;
    background-color: #fafafa;
    transition: all 0.3s ease;
    width: 100%;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    border-color: var(--text-blue);
    background-color: #fff;
    outline: none;
    box-shadow: 0 0 5px rgba(43, 69, 158, 0.2);
}

/* Photo Upload Box */
.photo-upload-box {
    width: 150px;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.photo-upload-box label {
    font-size: 14px;
    font-weight: 700;
    color: #444;
    margin-bottom: 8px;
}

.photo-placeholder {
    width: 120px;
    height: 150px;
    border: 2px dashed #ccc;
    border-radius: 8px;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 30px;
    color: #ccc;
    margin-bottom: 10px;
    background-color: #fafafa;
}

.photo-upload-box input[type="file"] {
    width: 100%;
    font-size: 12px;
}

/* Attachments Grid */
.attachments-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

.file-upload-group {
    display: flex;
    flex-direction: column;
}

.file-upload-group label {
    font-size: 14px;
    font-weight: 700;
    color: #444;
    margin-bottom: 8px;
}

.file-upload-group input[type="file"] {
    padding: 10px;
    border: 1px solid #ccc;
    border-radius: 5px;
    background-color: #fafafa;
    font-family: var(--font-body);
}

/* Sibling Blocks */
.sibling-block {
    background-color: #fafafa;
    padding: 15px;
    border-radius: 5px;
    margin-bottom: 15px;
    border-left: 3px solid var(--text-blue);
}

.sibling-block h4 {
    color: var(--text-blue);
    margin-bottom: 15px;
    font-size: 18px;
}

.sibling-block .form-row {
    margin-bottom: 0;
}

/* Declaration */
.declaration-box p {
    font-family: var(--font-body);
    font-size: 15px;
    line-height: 1.6;
    color: #444;
    margin-bottom: 20px;
}

.checkbox-group {
    display: flex;
    align-items: center;
    gap: 10px;
    background: #eaf2f8;
    padding: 15px;
    border-radius: 5px;
    border: 1px solid #bce0fd;
}

.checkbox-group input[type="checkbox"] {
    width: 20px;
    height: 20px;
    cursor: pointer;
}

.checkbox-group label {
    font-weight: 700;
    margin-bottom: 0;
    cursor: pointer;
}

/* Submit Button */
.form-submit-area {
    text-align: center;
    margin-top: 40px;
}

.submit-btn {
    background-color: var(--primary-red);
    color: white;
    font-size: 18px;
    font-weight: 700;
    padding: 15px 50px;
    border: none;
    border-radius: 30px;
    cursor: pointer;
    text-transform: uppercase;
    box-shadow: 0 4px 15px rgba(235, 57, 22, 0.3);
    transition: all 0.3s ease;
    font-family: var(--font-body);
}

.submit-btn:hover {
    background-color: #c92f11;
    transform: translateY(-3px);
    box-shadow: 0 6px 20px rgba(235, 57, 22, 0.5);
}

/* --- Mobile Responsiveness for Form --- */
@media (max-width: 768px) {
    .form-section {
        padding: 30px 5%;
    }
    
    .admission-form {
        padding: 20px;
    }

    .form-grid {
        flex-direction: column-reverse; /* Puts photo on top on mobile */
        align-items: center;
    }

    .input-fields {
        width: 100%;
    }

    .form-row {
        flex-direction: column;
        gap: 15px;
        margin-bottom: 15px;
    }

    .attachments-grid {
        grid-template-columns: 1fr; /* 1 column for file uploads on mobile */
    }
    
    .photo-upload-box {
        margin-bottom: 20px;
    }
}

/* =========================================================
   CONTACT PAGE STYLES
   ========================================================= */

.contact-section {
    padding: 60px 10%;
    max-width: 1200px;
    margin: 0 auto;
    background-color: #fff;
}

.text-center {
    text-align: center;
}

.contact-header {
    margin-bottom: 50px;
}

.contact-header h2 {
    color: var(--text-blue);
    font-family: var(--font-heading);
    font-size: 36px;
    margin-bottom: 10px;
}

.contact-header p {
    color: #555;
    font-size: 16px;
    font-family: var(--font-body);
}

/* Two Column Layout */
.contact-wrapper {
    display: flex;
    gap: 40px;
    align-items: stretch;
}

/* Left Side: Contact Info */
.contact-info {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 20px;
    justify-content: center;
}

.info-card {
    display: flex;
    align-items: flex-start;
    background: #f9fbfd;
    padding: 25px;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.05);
    border-left: 4px solid var(--primary-red);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.info-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 25px rgba(0,0,0,0.1);
}

.info-icon {
    width: 50px;
    height: 50px;
    background-color: var(--text-blue);
    color: white;
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 22px;
    margin-right: 20px;
    flex-shrink: 0;
}

.info-text h4 {
    color: var(--text-blue);
    font-family: var(--font-heading);
    font-size: 18px;
    margin-bottom: 8px;
}

.info-text p, 
.info-text a {
    color: #444;
    font-family: var(--font-body);
    font-size: 15px;
    line-height: 1.6;
    font-weight: 600;
}

.info-text a:hover {
    color: var(--primary-red);
    text-decoration: underline;
}

/* Right Side: Map */
.contact-map {
    flex: 1;
    min-height: 400px;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
    border: 5px solid white;
}

/* Responsive adjustments */
@media (max-width: 992px) {
    .contact-wrapper {
        flex-direction: column;
    }
    .contact-info {
        flex: 1 1 100%;
    }
    .contact-map {
        flex: 1 1 100%;
        height: 400px;
    }
}

@media (max-width: 768px) {
    .contact-section {
        padding: 40px 5%;
    }
    .contact-header h2 {
        font-size: 28px;
    }
    .info-card {
        padding: 15px;
    }
    .info-icon {
        width: 40px;
        height: 40px;
        font-size: 18px;
        margin-right: 15px;
    }
    .contact-map {
        height: 300px;
    }
}

/* Popup Overlay */
.popup-overlay {
    display: none;               
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.85); /* Slightly darker background to make image pop */
    z-index: 99999;              /* THIS IS THE FIX: Ensures it sits above the header */
    justify-content: center;
    align-items: center;
    animation: fadeIn 0.4s ease;
}

.popup-overlay.active {
    display: flex;
}

.popup-content {
    position: relative;
    max-width: 90%;
    max-height: 90%;
    animation: popIn 0.4s ease;
}

.popup-content img {
    display: block;
    max-width: 100%;
    max-height: 85vh;
    border-radius: 10px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.4);
}

.popup-close {
    position: absolute;
    top: -15px;
    right: -15px;
    width: 38px;
    height: 38px;
    background: #fff;
    color: #333;
    border-radius: 50%;
    font-size: 26px;
    font-weight: bold;
    line-height: 36px;
    text-align: center;
    cursor: pointer;
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.3);
    transition: transform 0.2s;
}

.popup-close:hover {
    transform: scale(1.1);
    background: #f0f0f0;
}

@keyframes fadeIn {
    from { opacity: 0; }
    to   { opacity: 1; }
}

@keyframes popIn {
    from { transform: scale(0.7); opacity: 0; }
    to   { transform: scale(1); opacity: 1; }
}