/* ==========================================
   1. GLOBAL VARIABLES & RESET
   ========================================== */
:root {
    --primary-blue: #e0f2f7;
    --primary-yellow: #ffc400;
    --primary-dark-blue: #0b6e14;
    --pastel-pink: #ffe8e0;
    --text-dark: #1a1a1a;
    --text-gray: #666;
    --nav-green: #016416; 
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Helvetica Neue', Arial, sans-serif;
}

body {
    color: var(--text-dark);
    line-height: 1.6;
    overflow-x: hidden;
}

/* ==========================================
   2. HEADER & NAVIGATION
   ========================================== */
.site-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 45px;
    background: #fff;
    border-bottom: 1px solid #f0f0f0;
    position: sticky;
    top: 0;
    z-index: 1000;
}

.logo-container a { display: block; text-decoration: none; }

.school-logo-full {
    width: clamp(220px, 35vw, 400px);
    height: auto;
    display: block;
}

.mobile-menu-btn {
    display: none; 
    background: transparent;
    border: none;
    font-size: 28px;
    color: var(--primary-dark-blue);
    cursor: pointer;
    padding: 5px;
}

.main-nav ul {
    display: flex;
    list-style: none;
    gap: 15px; 
    margin: 0;
    padding: 0;
}

.main-nav a {
    text-decoration: none;
    color: var(--nav-green);
    font-size: 14.5px;
    font-weight: 600;
    display: inline-block;
    padding: 8px 16px; 
    border-radius: 10px; 
    transition: all 0.3s ease;
}

.main-nav a:hover {
    background-color: var(--primary-dark-blue);
    color: #ffffff;
}

.main-nav a.active {
    background-color: rgba(11, 110, 20, 0.1); 
    color: var(--primary-dark-blue);
}

/* ==========================================
   3. HERO SECTION
   ========================================== */
.hero-learning {
    display: flex;
    min-height: 550px;
    align-items: stretch;
}

.hero-learning .hero-text {
    flex: 3;
    display: flex;
    flex-direction: column;
    justify-content: center;
    background-color: #f0f7f4;
    padding: 60px;
    z-index: 2;
}

.hero-text-inner { max-width: 500px; }

/* --- Image Slider --- */
.hero-image.hero-slider {
    flex: 7;
    position: relative;
    overflow: hidden;
    background-color: #f0f7f4;
    min-height: 500px;
}

.hero-slider .slide {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    
    /* Start completely off-screen to the right */
    transform: translateX(100%); 
    opacity: 0;
    
    /* Animate the slide and the fade at the same time */
    transition: transform 0.8s ease-in-out, opacity 0.8s ease-in-out;
    z-index: 1;
}

/* The active slide slides into the center */
.hero-slider .slide.active {
    transform: translateX(0); 
    opacity: 1;
    z-index: 2;
}

/* When the slide is moving out, push it to the left */
.hero-slider .slide.slide-out-left {
    transform: translateX(-100%);
    opacity: 0;
}

/* --- Custom H1 --- */
.custom-title {
    font-size: clamp(2.5rem, 5vw, 3.5rem); 
    line-height: 1.1;
    margin-bottom: 30px;
}

.custom-title .word-about {
    color: var(--primary-dark-blue); 
    font-weight: 800;
    text-decoration: underline; 
    text-decoration-color: var(--primary-yellow);
}

.custom-title .word-savannah {
    color: var(--nav-green); 
    font-weight: 400; 
    font-style: italic; 
}

.custom-title .word-school {
    color: var(--primary-yellow); 
    font-weight: 900;
    text-transform: uppercase; 
    letter-spacing: 2px;
}

.custom-title .keep-together {
    white-space: nowrap; 
    display: inline-block; 
}

.hero-learning .hero-text p {
    color: var(--text-gray);
    font-size: 1.05rem;
    margin-bottom: 20px;
    line-height: 1.8;
}

/* --- Hero BG Image --- */
.hero-learning.hero-with-bg .hero-text {
    background-image: 
        linear-gradient(rgba(11, 110, 20, 0.85), rgba(11, 110, 20, 0.85)), 
        url('assets/images/savannah-school-building.webp');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
}

.hero-learning.hero-with-bg .hero-text-inner p {
    color: #ffffff;
    font-weight: 500;
    text-shadow: 1px 1px 4px rgba(0,0,0,0.4); 
}

.hero-learning.hero-with-bg .custom-title .word-about {
    color: #ffffff;
    text-decoration-color: var(--primary-yellow);
}

.hero-learning.hero-with-bg .custom-title .word-savannah {
    color: var(--primary-yellow);
}

.hero-learning.hero-with-bg .custom-title .word-school {
    color: #ffffff;
}

/* ==========================================
   4. ABOUT SECTIONS (Headteacher & Mission)
   ========================================== */
.two-column-section {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    padding: 80px 10%;
}

.two-column-section .column img {
    width: 100%;
    height: 300px;
    object-fit: cover;
    margin-bottom: 30px;
}

.headteacher-photo {
    width: 100%;
    height: 450px;
    object-fit: cover;
    object-position: top center;
    border-radius: 10px;
    box-shadow: 0 8px 25px rgba(0,0,0,0.15);
    margin-bottom: 30px;
}

/* --- Accordion --- */
.accordion-wrapper {
    margin-top: 20px;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
    background-color: #ffffff;
    cursor: pointer; 
}

.accordion-title {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 25px;
    background-color: #ffffff;
    transition: background-color 0.3s ease;
}

.accordion-title h2 {
    color: var(--primary-dark-blue);
    margin: 0;
    font-size: 1.5rem;
}

.accordion-title i {
    color: var(--nav-green);
    font-size: 1.2rem;
    transition: transform 0.4s ease;
}

.accordion-content {
    max-height: 0;
    overflow: hidden;
    background-color: var(--primary-dark-blue);
    transition: max-height 0.4s ease-in-out;
    will-change: max-height;
}

.accordion-content-inner { padding: 0 25px; }

/* Desktop Hover */
@media (hover: hover) {
    .accordion-wrapper:hover .accordion-content {
        max-height: 1000px;
    }
    .accordion-wrapper:hover .accordion-content-inner {
        padding: 25px; 
    }
    .accordion-wrapper:hover .accordion-title {
        background-color: #f9f9f9;
    }
    .accordion-wrapper:hover .accordion-title i {
        transform: rotate(45deg);
        color: var(--primary-yellow);
    }
}

/* Text Styling */
.accordion-content p {
    color: #ffffff !important; 
    margin-bottom: 15px;
    line-height: 1.8;
}

.accordion-content .lead-text {
    font-size: 1.15rem;
    font-weight: 500;
}

.accordion-content .lead-text::first-letter {
    font-size: 4rem;
    font-weight: 800;
    color: var(--primary-yellow);
    float: left;
    line-height: 0.8;
    margin-right: 10px;
    margin-top: 5px;
}

.accordion-content .signature-block {
    border-top: 1px dashed rgba(255, 255, 255, 0.3);
    padding-top: 20px;
    margin-top: 20px;
}

.accordion-content .signature-block p,
.accordion-content .signature-block h3 {
    color: #ffffff;
}

.accordion-content .signature-block h3 {
    font-family: 'Brush Script MT', 'Courier New', cursive; 
    font-size: 2rem;
    font-weight: 500;
}

/* ==========================================
   5. CORE VALUES SECTION
   ========================================== */
.values-section {
    padding: 80px 10%;
    display: flex;
    justify-content: center;
    align-items: center;
}

.values-container {
    width: 100%;
    max-width: 800px;
}

.core-values-graphic {
    position: relative;
    width: 100%;
    padding-bottom: 100%;
}

.connector-ring {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 65%;
    height: 65%;
    border: 12px solid #d6fcb3;
    border-radius: 50%;
}

.core-values-center-text {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    text-align: center;
    line-height: 1;
    color: #006d1b;
}

.core-values-center-text .core {
    display: block;
    font-size: 2rem;
    font-weight: 400;
    letter-spacing: 2px;
}

.core-values-center-text .values {
    display: block;
    font-size: 3rem;
    font-weight: 800;
}

.value-node {
    position: absolute;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    width: 160px;
}

.icon-circle {
    width: 110px;
    height: 110px;
    background-color: #006d1b;
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    color: white;
    font-size: 3rem;
    margin-bottom: 15px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.2);
    transition: transform 0.3s ease;
}

.value-node:hover .icon-circle { transform: scale(1.1); }

.value-label {
    font-size: 1rem;
    font-weight: 800;
    color: #333;
    line-height: 1.2;
}

.value-node.top { top: 0; left: 50%; transform: translateX(-50%); }
.value-node.bottom-right { bottom: 5%; right: 15%; }
.value-node.bottom-left { bottom: 5%; left: 15%; }
.value-node.right { top: 40%; right: 0; transform: translateY(-50%); }
.value-node.left { top: 40%; left: 0; transform: translateY(-50%); }

/* ==========================================
   6. FACULTY & STAFF
   ========================================== */
.faculty-section { padding: 80px 10%; }

.faculty-container h2 {
    font-size: 2rem;
    color: var(--primary-dark-blue);
    margin-bottom: 10px;
}

.faculty-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
}

.staff-card-overlay {
    position: relative;
    width: 100%;
    height: 350px;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
}

.staff-card-overlay img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.staff-card-overlay:hover img { transform: scale(1.05); }

.overlay-info {
    position: absolute;
    bottom: -100%;
    left: 0;
    width: 100%;
    height: 60%;
    background-color: rgba(11, 110, 20, 0.95);
    color: white;
    padding: 20px 25px;
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    transition: bottom 0.4s ease-in-out;
    border-top: 4px solid var(--primary-yellow);
}

.staff-card-overlay:hover .overlay-info { bottom: 0; }

.overlay-info h3 {
    color: var(--primary-yellow);
    font-size: 1.3rem;
    margin-bottom: 5px;
}

.overlay-info .role {
    font-weight: bold;
    font-size: 0.8rem;
    margin-bottom: 10px;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.overlay-info .bio {
    font-size: 0.85rem;
    line-height: 1.4;
    margin-bottom: 10px;
}

.overlay-info a {
    color: white;
    text-decoration: none;
    border-bottom: 1px solid white;
    align-self: flex-start;
}

/* ==========================================
   7. FOOTER
   ========================================== */
.site-footer {
    display: grid;
    grid-template-columns: 1fr 1fr 1.5fr;
    padding: 60px 40px;
    gap: 40px;
    background: #fff;
    border-top: 1px solid #eee;
}

.footer-column h3 {
    font-size: 16px;
    margin-bottom: 20px;
    color: var(--primary-dark-blue);
}

.footer-column p, .footer-column li {
    font-size: 14px;
    color: var(--text-gray);
    margin-bottom: 10px;
}

.social-links { list-style: none; }

.social-links a {
    color: var(--text-gray);
    text-decoration: none;
    transition: color 0.3s;
}

.social-links a:hover { color: var(--primary-yellow); }

.footer-column form { display: flex; flex-direction: column; gap: 15px; }
.form-row { display: flex; gap: 15px; }

.footer-column input, .footer-column textarea {
    width: 100%;
    padding: 8px 0;
    border: none;
    border-bottom: 1px solid #333;
    background: transparent;
    outline: none;
    font-size: 14px;
}

.submit-btn {
    width: 100px;
    padding: 10px 0;
    background: transparent;
    color: var(--primary-dark-blue);
    border: none;
    border-bottom: 2px solid var(--primary-dark-blue);
    cursor: pointer;
    font-weight: bold;
    margin-top: 10px;
    transition: color 0.3s;
}

.submit-btn:hover {
    color: var(--primary-yellow);
    border-bottom: 2px solid var(--primary-yellow);
}

.footer-bottom {
    text-align: left;
    padding: 20px 40px;
    font-size: 12px;
    color: var(--text-gray);
    background: #fff;
}

/* ==========================================
   8. SCROLL ANIMATIONS
   ========================================== */
.animate-on-scroll {
    opacity: 0;
    transition: all 0.8s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.effect-fade-up { transform: translateY(40px); }
.effect-slide-left { transform: translateX(-50px); }
.effect-slide-right { transform: translateX(50px); }
.effect-zoom-in { transform: scale(0.9); }

.animate-on-scroll.active {
    opacity: 1;
    transform: translate(0, 0) scale(1);
}

.delay-1 { transition-delay: 0.2s; }
.delay-2 { transition-delay: 0.4s; }
.delay-3 { transition-delay: 0.6s; }
.delay-4 { transition-delay: 0.8s; }
.delay-5 { transition-delay: 1.0s; }

/* ==========================================
   9. RESPONSIVE DESIGN
   ========================================== */
@media (max-width: 1024px) {
    .site-header { padding: 10px 20px; flex-wrap: nowrap; }
    .mobile-menu-btn { display: block; }

    .main-nav {
        display: none; 
        position: absolute;
        top: 100%; 
        left: 0;
        width: 100%;
        background-color: #ffffff;
        box-shadow: 0 10px 15px rgba(0,0,0,0.1); 
        padding: 0; 
        z-index: 999;
    }

    .main-nav.active { display: block; }

    .main-nav ul { flex-direction: column; gap: 0; align-items: center; }
    .main-nav li { width: 100%; text-align: center; border-bottom: 1px solid #f0f0f0; }
    .main-nav a { display: block; width: 100%; padding: 15px 0; border-radius: 0; }

    .hero-image.hero-slider { width: 100%; min-height: 300px; flex: none; }
    .hero-learning { flex-direction: column; }
    .hero-learning .hero-text { padding: 40px 20px; }
    .hero-learning .hero-text .custom-title { font-size: clamp(2rem, 8vw, 3rem); }

    .animate-on-scroll { transform: translateY(30px) !important; }
    .animate-on-scroll.active { transform: translateY(0) !important; }

    .two-column-section {
        display: flex !important;
        flex-direction: column !important;
        gap: 40px;
        padding: 40px 20px;
    }

    .headteacher-photo { height: 350px; }
    .faculty-grid { grid-template-columns: 1fr 1fr; }

    .core-values-graphic { padding-bottom: 120%; }
    .connector-ring { width: 80%; height: 60%; }
    .core-values-center-text .core { font-size: 1.8rem; }
    .core-values-center-text .values { font-size: 2.2rem; }

    .icon-circle { width: 70px; height: 70px; font-size: 1.8rem; }
    .value-node { width: 110px; }
    .value-label { font-size: 0.8rem; }

    .value-node.bottom-right { bottom: 0; right: 5%; }
    .value-node.bottom-left { bottom: 0; left: 5%; }
    .value-node.right { top: 45%; right: 0; }
    .value-node.left { top: 45%; left: 0; }

    .site-footer { grid-template-columns: 1fr; padding: 40px 20px; }
}

@media (max-width: 600px) {
    .faculty-grid { grid-template-columns: 1fr; }
}