/* ==============================================
   1. VARIABLES & BASE STYLES
   ============================================== */
:root {
    /* Brand Colors (Navy/Blue/White) */
    --primary-navy: #002D62; /* Logo/Uniform Dark Blue */
    --accent-blue: #4A90E2; /* Uniform Vibrant Blue */
    --text-dark: #1D1D1D;
    --text-muted: #666666;
    --bg-white: #FFFFFF;
    --bg-light-grey: #F8F8F8;
    
    /* Layout Variables */
    --max-width: 1200px;
    --radius: 8px;
    --shadow: 0 4px 12px rgba(0, 0, 0, 0.08); /* Professional, subtle shadow */
    
    /* Typography */
    font-family: 'Open Sans', sans-serif;
    color-scheme: light;
}

*{ box-sizing: border-box; margin: 0; padding: 0; }
html, body { 
    height: 100%; 
    background: var(--bg-white); 
    color: var(--text-dark); 
}
.container { 
    max-width: var(--max-width); 
    margin: 0 auto; 
    padding: 0 20px; 
}
a { 
    color: var(--primary-navy); 
    text-decoration: none; 
    transition: color 0.2s;
}
a:hover { color: var(--accent-blue); }

/* Headings */
h1, h2, h3, h4 { 
    font-family: 'Poppins', sans-serif;
    color: var(--primary-navy);
}
h1 { font-size: 24px; }
h2 { font-size: 36px; margin-bottom: 15px; }
.section-title {
    font-size: 28px;
    margin-bottom: 25px;
    padding-top: 30px;
}
.muted-text { color: var(--text-muted); font-size: 15px; line-height: 1.6; }


/* ==============================================
   2. BUTTONS & CARDS
   ============================================== */
.btn {
    padding: 10px 20px;
    border: none;
    border-radius: var(--radius);
    font-weight: 600;
    cursor: pointer;
    transition: background 0.3s, transform 0.1s;
}
.btn-primary { 
    background: var(--primary-navy); 
    color: white;
}
.btn-primary:hover { 
    background: #004085; /* Slightly darker navy */
    transform: translateY(-1px);
}
.btn-secondary {
    background: var(--accent-blue);
    color: white;
}
.btn-secondary:hover { 
    background: #3A79C3; /* Slightly darker accent */
    transform: translateY(-1px);
}

.card {
    background: var(--bg-light-grey);
    padding: 25px;
    border-radius: var(--radius);
    border: 1px solid #EAEAEA;
    box-shadow: var(--shadow);
}


/* ==============================================
   3. HEADER & NAVIGATION
   ============================================== */
header {
    background: var(--bg-white);
    padding: 15px 0;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    border-bottom: 3px solid var(--accent-blue); /* Distinct bottom line */
    margin-bottom: 20px;
}
.brand { display: flex; align-items: center; gap: 12px; }
.logo img { 
    width: 50px; 
    height: 50px; 
    border-radius: 50%;
    object-fit: contain;
}
.motto-text { font-size: 13px; color: var(--text-muted); }
.motto-text span { color: var(--accent-blue); font-weight: 600; }

/* Desktop Navigation */
#desktop-nav { 
    display: flex; 
    gap: 25px; 
    font-weight: 600; 
}
#desktop-nav a.active {
    color: var(--accent-blue);
    border-bottom: 2px solid var(--accent-blue);
    padding-bottom: 3px;
}


/* --- HAMBURGER MENU ICON (BUTTON) STYLES --- */

/* Base style for the hamburger icon button */
.hamburger-menu {
    display: none; /* Keep hidden on desktop */
    width: 50px;
    height: 40px;
    background: transparent; 
    border: none;
    border-radius: var(--radius-small);
    cursor: pointer;
 /* CRITICAL FIX: Calculated vertical padding for balanced spacing */
    /* Target: Total Height (40px) - (3 * Bar Height 2px) = 34px remaining for padding/gaps.
       We aim for 4px top/bottom padding to give 32px of internal space,
       which leaves 26px for the two gaps (13px gap each). */
    padding: 10px; 
    
    flex-direction: column;
    justify-content: space-around; 
    align-items: center;
    position: relative; 
    z-index: 1001; 
}

/* Individual bar style */
.hamburger-menu .bar {
    display: block;
    width: 100%;
    /* CHANGE 3: Adjust height slightly for better balance */
    height: 3px; 
    background: var(--primary-navy);
    margin: 3px 0; 
    transition: all 0.3s ease;
    border-radius: 2px;
}

/* STATE 1: Transforming into the 'X' icon (Updated vertical translation) */
.hamburger-menu.is-active .top-bar {
    /* Adjusted the translation value for perfect center alignment */
    transform: translateY(5px) rotate(45deg); 
}

.hamburger-menu.is-active .middle-bar {
    opacity: 0; 
}

.hamburger-menu.is-active .bottom-bar {
    /* Adjusted the translation value for perfect center alignment */
    transform: translateY(-5px) rotate(-45deg);
}



/* Ensure the button is only visible on mobile */
@media (min-width: 900px) {
    .hamburger-menu {
        display: none;
    }
}


/* Mobile Navigation Overlay */
.mobile-nav-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: white; /* Dark overlay */
    color: var(--primary-navy); /* Dark overlay */
    z-index: 1000; 
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    padding-top: 60px; /* Space for the header */

    /* HIDDEN STATE (Starts off-screen) */
    transform: translateX(100%);
    transition: transform 0.4s ease-in-out;
}

/* VISIBLE STATE (Brought onto the screen) */
.mobile-nav-overlay.open {
    transform: translateX(0);
}

.mobile-nav-overlay a {
    color: var(--primary-navy);
    font-size: 24px;
    padding: 15px 0;
    width: 80%; /* Makes links easy to tap */
    text-align: center;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}
.mobile-nav-overlay a:last-child {
    border-bottom: none;
}


/* Media Query to show the hamburger icon on smaller screens */
@media (max-width: 900px) { /* Adjust breakpoint as needed */
    #desktop-nav {
        display: none;
    }
    .hamburger-menu {
        display: flex;
    }
}



/* ==============================================
   4. SECTIONS & LAYOUT
   ============================================== */
/* Hero */
.hero {
    display: grid;
    grid-template-columns: 1fr 450px;
    gap: 40px;
    align-items: center;
    padding: 40px 0;
}
.hero-image-panel {
    border-radius: var(--radius);
    overflow: hidden;
    box-shadow: var(--shadow);
}
.hero-image-panel img {
    width: 100%;
    height: auto;
    display: block;
    object-fit: cover;
}
.hero-text-panel h2 { margin-top: 0; }
.quickstats { display: flex; gap: 20px; margin-top: 20px; }
.stat {
    border: 1px solid #E0E0E0;
    background: var(--bg-light-grey);
    padding: 12px;
    border-radius: var(--radius);
    min-width: 100px;
    text-align: center;
    flex-grow: 1;
}
.stat b { display: block; font-size: 20px; color: var(--accent-blue); }
.hero-actions { display: flex; gap: 10px; margin-top: 20px; }

/* Grid Sections */
.grid-section { padding: 30px 0; }
.grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
}
.card-icon { 
    font-size: 36px; 
    color: var(--accent-blue); 
    margin-bottom: 10px;
}
.card h3 { margin-bottom: 10px; }

/* Accordion */
.accordion-group details {
    border: 1px solid #E0E0E0;
    background: var(--bg-white);
    padding: 15px 20px;
    border-radius: var(--radius);
    margin-bottom: 10px;
}
.accordion-group details summary {
    font-weight: 700;
    cursor: pointer;
    color: var(--primary-navy);
}
.accordion-group details .content {
    padding-top: 10px;
    font-size: 15px;
    color: var(--text-muted);
}

/* Facilities List */
.card-list {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}
.facility-item {
    background: var(--accent-blue);
    color: white;
    padding: 8px 15px;
    border-radius: 999px;
    font-size: 14px;
    font-weight: 600;
}

/* Contact */
.contact-section { padding: 30px 0 50px; }
.contact-grid {
    display: grid;
    grid-template-columns: 2fr 1.5fr;
    gap: 20px;
}
.contact-grid h4 { margin-bottom: 15px; }
.contact-grid form { display: grid; gap: 15px; }
input, textarea {
    padding: 12px;
    border-radius: var(--radius);
    border: 1px solid #E0E0E0;
    background: white;
    color: var(--text-dark);
}
.form-actions { display: flex; gap: 10px; margin-top: 5px; }
.accent-icon { color: var(--accent-blue); margin-right: 8px; font-size: 18px; }
.leadership-info { margin-top: 20px; padding-top: 15px; border-top: 1px dashed #E0E0E0; }

/* Footer */
footer {
    background: var(--primary-navy);
    color: white;
    padding: 30px 20px;
    margin-top: 50px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
}
.footer-details strong { color: var(--accent-blue); }
.footer-details .muted-text { color: rgba(255, 255, 255, 0.7); }
.footer-links a { color: white; margin: 0 5px; }
.copyright { color: rgba(255, 255, 255, 0.7); font-size: 14px; }

/* ======================= FOOTER SECTION ======================= */
.main-footer {
    background-color: var(--secondary-color);
    color: var(--text-light);
    padding-top: 60px;
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 40px;
    margin-bottom: 40px;
}

.footer-content h3 {
    color: var(--primary-color);
    margin-bottom: 15px;
}

.footer-content p {
    font-size: 0.95em;
    color: #ccc;
    line-height: 1.6;
}

.footer-links h4,
.footer-contact h4,
.footer-social h4 {
    font-size: 1.25em;
    font-weight: bold;
    margin-bottom: 20px;
    color: var(--text-light);
}

.footer-links ul {
    list-style: none;
    padding: 0;
}

.footer-links ul li {
    margin-bottom: 12px;
}

.footer-links a {
    color: #ccc;
    text-decoration: none;
    transition: color 0.3s ease;
}

.footer-links a:hover {
    color: var(--primary-color);
}

.footer-contact p {
    margin-bottom: 10px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.footer-contact i {
    color: var(--primary-color);
}

.social-icons a {
    color: var(--text-light);
    font-size: 1.5em;
    margin-right: 20px;
    transition: color 0.3s ease;
}

.social-icons a:hover {
    color: var(--primary-color);
}

.footer-bottom {
    background-color: #212529;
    text-align: center;
    padding: 20px 0;
    border-top: 1px solid #333;
}

.footer-bottom p {
    font-size: 0.85em;
    color: #999;
}


/* ==============================================
   5. JARVIS ASSISTANT STYLES (Navy/Blue Theme)
   ============================================== */
.jarvis-fab {
    position: fixed;
    right: 22px; bottom: 22px;
    width: 60px; height: 60px;
    border-radius: 999px;
    background: var(--accent-blue); /* Match accent color */
    display: flex; align-items: center; justify-content: center;
    font-size: 24px;
    box-shadow: 0 8px 25px rgba(74, 144, 226, 0.4);
    cursor: pointer;
    color: white;
    z-index: 100;
}
.jarvis-panel {
    position: fixed;
    right: 22px; bottom: 90px;
    width: 360px; max-width: calc(100% - 44px);
    background: white;
    border: 1px solid #E0E0E0;
    border-radius: var(--radius);
    padding: 15px;
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.2);
    display: flex; flex-direction: column; gap: 12px;
    z-index: 100;
}
.jarvis-header { display: flex; justify-content: space-between; align-items: center; }
.jarvis-messages {
    height: 250px;
    overflow-y: auto;
    padding: 8px;
    display: flex; flex-direction: column; gap: 8px;
}
.message { 
    max-width: 85%; 
    padding: 10px; 
    border-radius: 12px; 
    font-size: 14px;
}
.message.user { 
    align-self: flex-end; 
    background: var(--accent-blue); 
    color: white;
    border-bottom-right-radius: 3px;
}
.message.bot { 
    align-self: flex-start; 
    background: var(--bg-light-grey);
    color: var(--text-dark);
    border-bottom-left-radius: 3px;
}
.jarvis-input-group { display: flex; gap: 8px; }
.jarvis-input-group input { flex: 1; padding: 10px; }
.jarvis-tip { font-size: 12px; }


/* ==============================================
   6. RESPONSIVENESS (Mobile First)
   ============================================== */
@media (max-width: 1000px) {
    /* Tablet/Medium Screen adjustments */
    .hero { grid-template-columns: 1fr; }
    .hero-image-panel { order: -1; } /* Image on top on mobile */
    .grid { grid-template-columns: repeat(2, 1fr); }
    .contact-grid { grid-template-columns: 1fr; }
    footer { justify-content: center; text-align: center; }
    .footer-details, .footer-links, .copyright { width: 100%; margin: 5px 0; }
    .mobile-nav-overlay { padding-top: 80px; }
}

@media (max-width: 768px) {
    /* Mobile Screen */
    header { padding: 15px 15px; }
    #desktop-nav { display: none; } /* Hide desktop nav */
    .hamburger-menu { display: block; } /* Show hamburger icon */
    h2 { font-size: 30px; }
    .section-title { font-size: 24px; }
    .grid { grid-template-columns: 1fr; } /* One column on small screen */
    .hero { padding: 20px 0; }
    .quickstats { flex-direction: column; gap: 10px; }
    .stat { min-width: 100%; }
}

/* --- ABOUT PAGE SPECIFIC STYLES --- */
.page-hero {
    background: var(--primary-navy);
    color: white;
    padding: 60px 20px;
    margin-bottom: 30px;
    border-radius: 0 0 var(--radius) var(--radius);
    text-align: center;
}
.page-hero h2 {
    color: white;
    font-size: 42px;
}
.page-hero .muted-text {
    color: rgba(255, 255, 255, 0.8);
    font-size: 18px;
    margin-top: 10px;
}

.about-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 30px;
}

.achievement-grid {
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
    text-align: center;
}
.achievement-grid .stat {
    background: var(--bg-white);
    border: 1px solid #E0E0E0;
    padding: 25px;
}
.stat-large {
    display: block;
    font-size: 40px;
    color: var(--accent-blue);
    margin: 10px 0;
    font-family: 'Poppins', sans-serif;
    font-weight: 800;
}
.text-center { text-align: center; }

/* Leadership/Staff Section Styles */
.staff-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 20px;
    margin-top: 20px;
}
.teacher {
    text-align: center;
    padding: 25px;
}
.avatar-icon {
    font-size: 50px;
    color: var(--primary-navy);
    margin-bottom: 15px;
}
.teacher .name {
    font-weight: 700;
    color: var(--primary-navy);
    font-size: 18px;
}
.teacher .role {
    font-size: 14px;
    margin-bottom: 10px;
}
.bio-text {
    font-style: italic;
    font-size: 14px;
}

/* Call to Action */
.section-cta {
    background: var(--bg-light-grey);
    padding: 50px 20px;
    margin-top: 40px;
}
.section-cta h3 {
    margin-bottom: 10px;
}
.section-cta .btn {
    margin-top: 20px;
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .about-grid, .achievement-grid {
        grid-template-columns: 1fr;
    }
    .page-hero h2 {
        font-size: 30px;
    }
}



/* --- GALLERY PAGE SPECIFIC STYLES --- */

/* Page Hero adjustments for Gallery */
.hero-gallery {
    background: var(--primary-navy);
    padding: 60px 20px;
    margin-bottom: 30px;
    text-align: center;
}
.hero-gallery h2 {
    color: white;
    font-size: 42px;
}
.hero-gallery .muted-text {
    color: rgba(255, 255, 255, 0.8);
    font-size: 18px;
    margin-top: 10px;
}

/* Filter Buttons Styling (Reusing .card-list from index) */
.filter-buttons {
    justify-content: center;
    margin-bottom: 30px;
}
.filter-item {
    background: var(--bg-light-grey);
    color: var(--text-dark);
    padding: 10px 18px;
    border: 1px solid #E0E0E0;
    border-radius: 999px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
}
.filter-item:hover {
    background: #E0E0E0;
}
.filter-item.active {
    background: var(--accent-blue);
    color: white;
    border-color: var(--accent-blue);
    transform: translateY(-1px);
}

/* Gallery Grid Layout */
.photo-grid {
    display: grid;
    /* 3 columns on desktop, dynamic sizing */
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); 
    gap: 20px;
    margin-top: 20px;
}

.gallery-item {
    background: var(--bg-white);
    border-radius: var(--radius);
    overflow: hidden;
    box-shadow: var(--shadow);
    transition: transform 0.3s ease-in-out;
}
.gallery-item:hover {
    transform: scale(1.02);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.15);
}

.gallery-item img {
    width: 100%;
    height: 250px; /* Uniform height for visual appeal */
    object-fit: cover; /* Ensures images fill the space without distortion */
    display: block;
}

.gallery-item .caption {
    padding: 15px;
    font-size: 15px;
    font-weight: 600;
    color: var(--primary-navy);
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .photo-grid {
        grid-template-columns: 1fr; /* Single column on small mobile screens */
    }
    .filter-buttons {
        justify-content: flex-start; /* Align filters to the left on small screens */
        flex-wrap: wrap;
    }
}

/* --- LEADERSHIP PHOTO STYLES --- */
.profile-photo {
    width: 100px;         /* Set a fixed size */
    height: 100px;
    border-radius: 50%;   /* Make the image round */
    object-fit: cover;    /* Ensure the photo fills the circle */
    margin-bottom: 15px;
    border: 3px solid var(--accent-blue); /* Optional: Adds a subtle brand border */
}
/* Adjust the teacher card to account for the image */
.teacher {
    text-align: center;
    padding: 25px;
}

/* --- Proprietor Spotlight Section --- */
.proprietor-spotlight {
    margin-top: 30px;
    padding: 30px;
    background: var(--bg-light-grey); /* Lighter background for emphasis */
    border: 1px solid #e0e0e0;
}

.proprietor-content {
    display: flex;
    align-items: center; /* Vertically align image and text */
    gap: 30px; /* Space between image and text */
}

.director-photo {
    width: 250px; /* Larger size for the director's photo */
    height: 300px; /* Adjusted height to fit the original image's aspect ratio better */
    object-fit: cover; /* Crop to fit if aspect ratio differs */
    border-radius: var(--radius); /* Keep it slightly rounded, not fully circular */
    box-shadow: var(--shadow); /* Add a subtle shadow */
    flex-shrink: 0; /* Prevent the image from shrinking */
}

.proprietor-text .name {
    font-size: 24px;
    font-weight: 700;
    color: var(--primary-navy);
    margin-bottom: 5px;
}
.proprietor-text .role {
    font-size: 16px;
    color: var(--accent-blue);
    margin-bottom: 15px;
}
.proprietor-text .bio-text {
    font-size: 15px;
    line-height: 1.7;
    margin-bottom: 10px;
}

/* --- Responsive Adjustments for Proprietor Spotlight --- */
@media (max-width: 768px) {
    .proprietor-content {
        flex-direction: column; /* Stack image and text vertically on small screens */
        text-align: center;
    }
    .director-photo {
        width: 180px; /* Smaller image on mobile */
        height: 220px;
        margin-bottom: 20px; /* Add space below the photo */
    }
    .proprietor-text .name {
        font-size: 20px;
    }
    .proprietor-text .role {
        font-size: 14px;
    }
}

/* --- ADMISSIONS PAGE SPECIFIC STYLES --- */

/* Admissions Hero (can reuse .page-hero and customize) */
.hero-admissions {
    background: var(--primary-navy);
    color: white;
    padding: 60px 20px;
    margin-bottom: 40px;
    text-align: center;
}

/* Process Grid Styling */
.process-grid {
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
    text-align: center;
}
.step-card {
    padding: 30px 20px;
}
.step-number {
    display: inline-block;
    width: 30px;
    height: 30px;
    line-height: 30px;
    background: var(--accent-blue);
    color: white;
    border-radius: 50%;
    font-weight: 700;
    margin-bottom: 10px;
}
.step-icon {
    font-size: 36px;
    color: var(--primary-navy);
    margin: 15px 0;
}
.step-card h4 {
    margin-top: 0;
    margin-bottom: 10px;
    color: var(--accent-blue);
}
.btn-tertiary {
    background: var(--accent-blue);
    color: white;
    border: 1px solid var(--accent-blue);
    display: inline-block;
    padding: 8px 15px;
    border-radius: var(--radius-small);
    text-decoration: none;
    font-size: 14px;
    margin-top: 15px;
}

/* Requirements Section Grid */
.requirements-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
}
.requirements-grid h4 {
    color: var(--primary-navy);
    border-bottom: 2px solid var(--accent-blue);
    padding-bottom: 5px;
    margin-bottom: 15px;
}

/* Check List Styling */
.check-list {
    list-style: none;
    padding: 0;
}
.check-list li {
    margin-bottom: 10px;
    color: var(--text-dark);
    font-size: 15px;
}
.check-list li i {
    color: var(--accent-green); /* A nice checkmark color */
    margin-right: 8px;
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .process-grid {
        grid-template-columns: 1fr; /* Single column on mobile */
    }
}

/* Flyer Section */
.flyer-section {
    background-color: var(--white-color);
    color: var(--primary-color);
    text-align: center;
}

.flyer-section h2 {
    color: var(--primary-color);
    margin-bottom: 10px;
}

.flyer-section p {
    color: var(--primary-color);
    margin-bottom: 40px;
}

.flyer-image-container {
    display: flex;
    justify-content: center;
    padding: 20px;
}

.flyer-image-container img {
    max-width: 100%;
    height: auto;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

/* --- STAFF PAGE PROFESSIONAL STYLES --- */

.hero-staff {
    background: var(--primary-navy);
    padding: 60px 20px;
    margin-bottom: 40px;
    text-align: center;
    color: white;
}
.hero-staff .hero-title, .hero-staff .hero-subtitle {
    color: white;
}
.hero-staff .hero-subtitle {
    color: rgba(255, 255, 255, 0.8);
}

/* Leadership Spotlight (Proprietor) */
.proprietor-spotlight {
    display: flex;
    justify-content: center;
    margin: 40px auto 60px;
    padding: 30px;
    max-width: 800px;
    background: white;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.05);
}
.proprietor-content {
    display: flex;
    align-items: center;
    gap: 30px;
}
.director-photo {
    width: 150px;
    height: 150px;
    object-fit: cover;
    border-radius: 50%; /* Perfect Circle */
    border: 3px solid var(--accent-blue);
    flex-shrink: 0;
}
.proprietor-text .role-primary {
    font-size: 1.1em;
    font-weight: 700;
    color: var(--accent-blue);
    margin-bottom: 5px;
}

/* Staff Grid for Faculty and Core Staff */
.staff-grid {
    display: grid;
    /* Responsive grid: Min width 250px for each column */
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 30px;
    margin-top: 30px;
}

.staff-member {
    text-align: center;
    padding: 20px;
    background: white;
    transition: transform 0.3s ease;
}
.staff-member:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 15px rgba(0, 0, 0, 0.1);
}

.staff-member .profile-photo {
    width: 100px;
    height: 100px;
    object-fit: cover;
    border-radius: 50%;
    margin-bottom: 15px;
}
.staff-member .name {
    font-size: 1.1em;
    font-weight: 700;
    color: var(--primary-navy);
}
.staff-member .role {
    font-size: 0.95em;
    color: var(--accent-blue);
    margin-bottom: 5px;
}
.staff-member .role-department {
    font-weight: 600;
    color: var(--text-dark);
}

/* Mobile Adjustments for Proprietor Spotlight */
@media (max-width: 768px) {
    .proprietor-content {
        flex-direction: column;
        text-align: center;
    }
}

/* --- BLOG PAGE PROFESSIONAL STYLES --- */

/* 1. Page Hero/Header */
.hero-blog {
    /* Uses the school's primary color for a strong, branded header */
    background: var(--primary-navy); 
    padding: 60px 20px;
    margin-bottom: 40px;
    text-align: center;
}
.hero-blog .hero-title {
    color: white;
    font-size: 2.5em;
    margin-bottom: 5px;
}
.hero-blog .hero-subtitle {
    color: rgba(255, 255, 255, 0.8);
    font-size: 1.1em;
}

/* 2. Blog Post Grid Layout */
.blog-grid {
    display: grid;
    /* Professional two-column layout on desktop: min width 350px per column */
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 30px;
}

/* 3. Individual Post Card Styles */
.post-card {
    padding: 0; 
    overflow: hidden; /* Keeps content (like images) contained */
    background: white;
    border-radius: var(--radius-small);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
    transition: box-shadow 0.3s ease, transform 0.3s ease;
}
/* Subtle elevation effect on hover for professionalism */
.post-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
}

/* 4. Image/Placeholder Container Styles */
.post-image-placeholder {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    height: 220px; /* Fixed height for visual consistency */
    background: var(--bg-light-grey); 
    color: var(--text-dark);
    padding: 20px;
    font-size: 1em;
    font-weight: 600;
}
/* Ensure the icon is the school's primary color */
.post-image-placeholder i {
    color: var(--accent-blue) !important; 
    margin-bottom: 10px;
}

/* 5. Post Content Details */
.post-content {
    padding: 25px;
}

.post-meta {
    font-size: 0.85em;
    font-weight: 600;
    color: var(--accent-blue); /* Uses brand accent color for metadata */
    margin-bottom: 15px;
}
.post-meta i {
    margin-right: 5px;
}

.post-title {
    color: var(--primary-navy);
    font-size: 1.4em;
    line-height: 1.3;
    margin-bottom: 10px;
}

.post-snippet {
    font-size: 0.95em;
    margin-bottom: 20px;
}

.read-more, .btn-primary-outline {
    font-weight: 700;
    color: var(--accent-blue);
    text-decoration: none;
    transition: color 0.2s;
}
.read-more:hover {
    color: var(--primary-navy);
}

/* 6. Featured Card Style (e.g., for the 100% pass rate post) */
.post-card.card-featured {
    /* Visually highlights the most important news item */
    border: 3px solid var(--accent-blue);
    box-shadow: 0 5px 25px rgba(0, 0, 0, 0.15);
}


/* 7. Mobile Adjustments */
@media (max-width: 768px) {
    .blog-grid {
        grid-template-columns: 1fr; /* Single column on smaller screens */
    }
}

/* --- CUSTOM MODAL STYLES (REQUIRED FOR BLOG DETAIL POPUP) --- */

/* 1. Modal Overlay (The dimmed background when the modal is open) */
.modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.7); /* Dark, transparent overlay */
    display: none; /* Starts hidden */
    justify-content: center;
    align-items: center;
    z-index: 2000; /* Ensures it sits above everything else */
    overflow-y: auto; /* Allows scrolling if content is long */
}
.modal.open {
    display: flex; /* Show the modal when JavaScript adds the 'open' class */
}

/* 2. Modal Dialog (The container for the content) */
.modal-dialog {
    background: white;
    border-radius: var(--radius-medium);
    max-width: 800px;
    width: 90%;
    margin: 40px auto;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
    transform: scale(0.9);
    opacity: 0;
    transition: transform 0.3s ease-out, opacity 0.3s ease-out;
}
.modal.open .modal-dialog {
    transform: scale(1); /* Smooth entry animation */
    opacity: 1;
}

/* 3. Modal Header */
.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px;
    border-bottom: 1px solid var(--border-color);
    color: var(--primary-navy);
}
.modal-title {
    font-size: 1.5em;
    font-weight: 700;
}
.modal-header .btn-close {
    /* Style for the 'X' close button */
    background: none;
    border: none;
    font-size: 1.5em;
    color: var(--text-dark);
    cursor: pointer;
    line-height: 1;
}

/* 4. Modal Body (The content area) */
.modal-body {
    padding: 30px 20px;
    line-height: 1.6;
    color: var(--text-dark);
}
.modal-body h6 {
    margin-top: 20px;
    color: var(--accent-blue);
}
.modal-body ul {
    margin-left: 20px;
}

/* 5. Modal Footer */
.modal-footer {
    display: flex;
    justify-content: flex-end;
    padding: 15px 20px;
    border-top: 1px solid var(--border-color);
}


/* --- SINGLE BLOG POST STYLES (post-1-exam-results.html) --- */

.post-container {
    max-width: 900px; /* Standard width for comfortable reading */
    margin: 0 auto;
    padding: 20px;
    background: white;
    border-radius: var(--radius-medium);
}

.post-header {
    margin-bottom: 30px;
    border-bottom: 1px solid var(--border-color);
    padding-bottom: 15px;
}

.post-title-main {
    font-size: 2.2em;
    font-weight: 800;
    color: var(--primary-navy);
    line-height: 1.2;
    margin-bottom: 10px;
}

.post-meta-detail {
    font-size: 0.9em;
    color: var(--text-muted);
}
.post-meta-detail i {
    margin-right: 5px;
    color: var(--accent-blue);
}
.post-meta-detail span {
    margin-right: 15px;
}

/* Feature Image */
.post-feature-image {
    margin: 30px 0;
}
.post-feature-image img {
    width: 100%;
    max-height: 450px;
    object-fit: cover;
    border-radius: var(--radius-small);
}
.post-feature-image figcaption {
    text-align: center;
    font-style: italic;
    font-size: 0.9em;
    margin-top: 10px;
}

/* Content Body Readability */
.post-content-body {
    line-height: 1.7;
    font-size: 1.05em;
    color: var(--text-dark);
}
.lead-paragraph {
    font-size: 1.2em;
    font-weight: 500;
    color: var(--primary-navy);
}
.post-content-body h3 {
    color: var(--accent-blue);
    margin-top: 40px;
    margin-bottom: 15px;
    border-left: 4px solid var(--accent-blue);
    padding-left: 15px;
}

/* Testimonial Quote Style */
.testimonial {
    background: var(--bg-light-grey);
    padding: 25px;
    border-left: 5px solid var(--accent-blue);
    margin: 30px 0;
    font-style: italic;
    color: var(--text-dark);
}
.testimonial p {
    font-size: 1.1em;
    margin-bottom: 10px;
}
.testimonial footer {
    text-align: right;
    font-size: 0.9em;
    font-weight: 600;
    color: var(--text-muted);
    font-style: normal;
}
.testimonial i.fa-quote-left {
    color: var(--accent-blue);
    font-size: 1.5em;
    float: left;
    margin-right: 10px;
}

.back-link-area {
    margin-top: 40px;
    text-align: center;
}
.btn-back {
    font-size: 1.05em;
}

/* --- BLOG PAGE IMAGE STRUCTURE --- */

/* 1. Image Container (Defines height and shape) */
.post-card .post-image-container {
    /* Set a consistent height for all blog post images */
    height: 250px; 
    overflow: hidden;
    /* Apply rounded corners only to the top, blending with the card */
    border-radius: var(--radius-medium) var(--radius-medium) 0 0; 
}

/* 2. The Image (Ensures fill and centering) */
.post-card .post-image-container img.post-image {
    width: 100%;
    height: 100%;
    /* Key Property: Ensures the image covers the container without stretching */
    object-fit: cover; 
    /* Centers the image content */
    object-position: center;
    display: block;
    transition: transform 0.3s ease;
}

/* Optional: Slight hover effect for engagement */
.post-card:hover .post-image-container img.post-image {
    transform: scale(1.05);
}

/* --- BLOG GRID LAYOUT (Context for the cards) --- */
.blog-grid {
    display: grid;
    gap: 30px;
    /* Sets the default for standard cards */
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
}
/* Style for the featured card (usually spans more columns on desktop) */
.card-featured {
    grid-column: span 2;
}

@media (max-width: 900px) {
    .card-featured {
        /* On small screens, the featured card should only span one column */
        grid-column: span 1;
    }
}


/* --- HOMEPAGE IMAGE SLIDER STYLES --- */

#homepage-slider {
    position: relative;
    width: 100%;
    /* Fixed height for all images, adjust as needed */
    height: 500px; 
    overflow: hidden;
}

.slider-container {
    display: flex;
    height: 100%;
    /* Enables smooth transition between slides */
    transition: transform 0.5s ease-in-out; 
}

.slide {
    min-width: 100%;
    height: 100%;
    position: relative;
}

.slide img {
    width: 100%;
    height: 100%;
    /* Key: Ensures the image covers the area perfectly */
    object-fit: cover; 
    object-position: center;
}

/* Caption Text */
.slider-caption {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    padding: 15px 20px;
    background: rgba(0, 0, 0, 0.65);
    color: white;
    font-size: 1.1em;
    font-weight: 600;
}

/* Navigation Buttons (Arrows) */
.slider-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(0, 0, 0, 0.5);
    color: white;
    border: none;
    padding: 15px;
    cursor: pointer;
    font-size: 24px;
    z-index: 10;
    opacity: 0.8;
    transition: opacity 0.2s;
}
.slider-nav:hover {
    opacity: 1;
    background: var(--accent-blue);
}

.slider-nav.prev {
    left: 20px;
    border-radius: 0 5px 5px 0;
}

.slider-nav.next {
    right: 20px;
    border-radius: 5px 0 0 5px;
}

/* Indicator Dots */
.slider-dots {
    position: absolute;
    bottom: 15px;
    width: 100%;
    text-align: center;
    z-index: 10;
}
.dot {
    display: inline-block;
    height: 10px;
    width: 10px;
    margin: 0 5px;
    background-color: rgba(255, 255, 255, 0.5);
    border-radius: 50%;
    cursor: pointer;
    transition: background-color 0.6s ease;
}
.dot.active {
    background-color: var(--accent-blue);
    border: 1px solid white;
}

/* Mobile Adjustments */
@media (max-width: 768px) {
    #homepage-slider {
        /* Reduce height on smaller screens */
        height: 350px; 
    }
    .slider-caption {
        font-size: 0.9em;
        padding: 10px 15px;
    }
}


/* --- SLIDER GALLERY BUTTON STYLES --- */

.slider-gallery-btn {
    position: absolute;
    bottom: 50px; /* Position it 50px up from the bottom edge */
    left: 50%;
    transform: translateX(-50%); /* Centers the button perfectly */
    z-index: 20; /* Ensures the button is always visible above slides/dots */
    
    /* Enhance visibility and clickability */
    padding: 12px 30px; 
    font-size: 1.1em;
    font-weight: 700;
    
    /* Use a strong, contrasted style */
    background: var(--accent-blue); 
    color: white;
    border: 2px solid white; /* White border for extra pop */
    border-radius: var(--radius-small);
    text-decoration: none;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.3);
    transition: all 0.3s ease;
}

.slider-gallery-btn:hover {
    background: var(--primary-navy); /* Dark navy on hover */
    color: white;
    border-color: var(--primary-navy);
}

/* Mobile Adjustment for Slider Button */
@media (max-width: 768px) {
    .slider-gallery-btn {
        bottom: 20px; /* Moves it slightly closer to the edge */
        padding: 8px 18px; /* Significantly reduces the button size */
        font-size: 0.9em; /* Reduces font size */
    }
}



/* --- HOMEPAGE FEATURE SECTIONS (About & Staff) --- */

/* ABOUT US FEATURE CARD (To make it stand out) */
.feature-card {
    display: flex;
    align-items: center;
    border-radius: var(--radius-large);
    overflow: hidden;
    color: fffff; /* Text color for the primary-bg */
}

.feature-card .feature-content {
    padding: 40px;
    flex: 2; /* Takes up more space on desktop */
}

.feature-card .feature-title {
    font-size: 2.2em;
    margin-top: 0;
    margin-bottom: 20px;
    line-height: 1.2;
}

.feature-card .feature-snippet {
    font-size: 1.1em;
    line-height: 1.6;
    margin-bottom: 30px;
}

.feature-card .feature-image-container {
    flex: 1; /* Takes up less space on desktop */
    min-height: 350px;
}

.feature-card .feature-image-container img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* Overriding the default button style for this section */
.feature-card .btn-secondary-outline {
    background: white;
    color: var(--primary-navy);
    border-color: white;
}
.feature-card .btn-secondary-outline:hover {
    background: var(--accent-blue);
    border-color: var(--accent-blue);
    color: white;
}

/* Mobile Adjustments for Feature Card */
@media (max-width: 900px) {
    .feature-card {
        flex-direction: column; /* Stacks vertically */
        text-align: center;
    }
    .feature-card .feature-content {
        padding: 30px 20px;
        order: 2; /* Content below image on mobile */
    }
    .feature-card .feature-image-container {
        order: 1; /* Image above content on mobile */
        width: 100%;
        min-height: 250px;
    }
    .feature-card .feature-title {
        font-size: 1.8em;
    }
}


/* --- STAFF HIGHLIGHT CARD STYLING (Two-Column Layout) --- */
.highlight-card.staff-feature-grid {
    /* Use CSS Grid for the two-column layout */
    display: grid;
    grid-template-columns: 1fr 1.2fr; /* Text column (1) slightly smaller than Image column (1.2) */
    gap: 40px;
    align-items: center; 
    
    background: white;
    padding: 40px; 
    border-radius: var(--radius-medium);
    border: 1px solid var(--border-color);
    box-shadow: var(--shadow-small); 
    max-width: 1000px; 
    margin: 0 auto; 
    text-align: left;
}

/* Ensure text alignment is clean within the grid */
.staff-feature-grid .staff-text-content .section-title,
.staff-feature-grid .staff-text-content p {
    text-align: left;
}

/* --- STAFF IMAGE COLLAGE STYLING --- */
.staff-image-collage {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.staff-image-collage .collage-main-img {
    width: 100%;
    height: 300px;
    object-fit: cover;
    border-radius: var(--radius-small);
}

.staff-image-collage .collage-small-imgs {
    display: flex;
    gap: 10px;
}

.staff-image-collage .collage-small-imgs img {
    flex: 1;
    width: 100%;
    height: 100px;
    object-fit: cover;
    border-radius: var(--radius-small);
}

/* Mobile Responsiveness: Stack content vertically */
@media (max-width: 800px) {
    .highlight-card.staff-feature-grid {
        grid-template-columns: 1fr; /* Single column on mobile */
        padding: 30px;
        gap: 20px;
        text-align: center;
    }
    .staff-feature-grid .staff-text-content {
        order: 2; /* Text goes below the images */
    }
    .staff-feature-grid .staff-text-content .section-title,
    .staff-feature-grid .staff-text-content p {
        text-align: center;
    }
    .staff-image-collage {
        order: 1; /* Images go above the text */
    }
    .staff-image-collage .collage-main-img {
        height: 200px;
    }
    .staff-image-collage .collage-small-imgs img {
        height: 80px;
    }
}
