/* Variables */
:root {
    --primary-color: #ff5433;
    --secondary-color: #5689ff;
    --text-dark: #333;
    --text-light: #fff;
    --bg-light: #eaf1fd;
    --font-heading: 'Alegreya Sans', sans-serif;
    --font-body: 'Roboto', sans-serif;
}

/* Reset & Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: var(--font-body);
    color: var(--text-dark);
    line-height: 1.6;
    overflow-x: hidden;
}

h1,
h2,
h3,
h4 {
    font-family: var(--font-heading);
    font-weight: 500;
    margin-bottom: 1rem;
}

a {
    text-decoration: none;
    color: inherit;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

.section-padding {
    padding: 80px 0;
}

.bg-light {
    background-color: var(--bg-light);
}

.responsive-img {
    max-width: 100%;
    height: auto;
}

.shadow {
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    border-radius: 8px;
}

/* Header */
.site-header {
    background: #fff;
    padding: 15px 0;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    position: sticky;
    top: 0;
    z-index: 100;
}

.nav-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo img {
    height: 60px;
}

.main-nav ul {
    list-style: none;
    display: flex;
    gap: 30px;
}

.main-nav a {
    font-weight: 500;
    transition: color 0.3s ease;
}

.main-nav a:hover {
    color: var(--primary-color);
}

/* Contained Hero & Footer Sections */
.hero,
.site-footer {
    padding: 40px 0 60px 0;
}

.hero-box,
.footer-box {
    position: relative;
    color: var(--text-light);
    border-radius: 8px;
    overflow: hidden;
}

.hero-box {
    text-align: left;
    padding: 140px 60px;
}

.footer-box {
    text-align: center;
    padding: 120px 40px;
}

/* Background Layers for Parallax & Zoom */
.hero-bg,
.footer-bg {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
    /* Parallax effect */
    z-index: 0;
    transform: scale(1.15);
}

/* Overlays */
.hero-overlay,
.footer-overlay,
.card-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgba(255, 84, 51, 0.7) 0%, rgba(86, 137, 255, 0.7) 100%);
    z-index: 1;
}

/* Content Positioning */
.hero-content,
.footer-content {
    position: relative;
    z-index: 2;
}

.hero-content {
    max-width: 900px;
}

/* Corrected Hero Text Matching the Original Size */
.hero h1 {
    font-size: 5rem;
    line-height: 1.1;
    margin-bottom: 0;
}

.footer-content h2 {
    font-size: 2.2rem;
    max-width: 900px;
    margin: 0 auto 10px auto;
}

.footer-content h3 {
    font-size: 1.5rem;
    font-weight: 400;
    margin-bottom: 20px;
}

/* Intro Text */
.intro-text {
    text-align: center;
    font-size: 1.2rem;
    max-width: 900px;
    margin: 0 auto;
}

.intro-text p {
    margin-bottom: 20px;
}

/* Services Grid */
.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
}

.service-card {
    position: relative;
    background-size: cover;
    background-position: center;
    height: 350px;
    border-radius: 8px;
    overflow: hidden;
    color: var(--text-light);
    display: flex;
    align-items: flex-end;
    padding: 20px;
}

.card-overlay {
    background: linear-gradient(to top, rgba(0, 0, 0, 0.8) 0%, rgba(0, 0, 0, 0.1) 100%);
    transition: background 0.4s ease;
}

.service-card:hover .card-overlay {
    background: rgba(255, 84, 51, 0.85);
}

.card-content {
    position: relative;
    z-index: 2;
}

.hover-text {
    max-height: 0;
    opacity: 0;
    overflow: hidden;
    transition: all 0.4s ease;
    margin-top: 10px;
    font-size: 0.9rem;
}

.service-card:hover .hover-text {
    max-height: 200px;
    opacity: 1;
}

/* Two Column Layouts */
.two-col {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 50px;
    align-items: center;
}

/* Cascading Images */
.image-gallery {
    position: relative;
    height: 500px;
}

.image-gallery img {
    position: absolute;
    border-radius: 8px;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.15);
}

.img-back {
    width: 80%;
    top: 0;
    left: 0;
}

.img-front {
    width: 75%;
    bottom: 0;
    right: 0;
    z-index: 2;
}

/* Program Focus */
.focus-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
    margin-top: 40px;
}

/* Forms & Buttons */
.contact-form {
    display: flex;
    flex-direction: column;
    gap: 15px;
    margin-top: 20px;
}

.contact-form input,
.contact-form textarea {
    padding: 12px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-family: var(--font-body);
}

.btn {
    background: var(--primary-color);
    color: #fff;
    border: none;
    padding: 15px;
    border-radius: 4px;
    cursor: pointer;
    font-size: 1rem;
    font-weight: 600;
    transition: background 0.3s ease;
}

.btn:hover {
    background: var(--secondary-color);
}

/* Outlined Footer Button */
.btn-outline {
    display: inline-block;
    margin-top: 20px;
    padding: 8px 20px;
    font-size: 0.85rem;
    font-weight: 600;
    color: #fff;
    background: transparent;
    border: 2px solid rgba(255, 255, 255, 0.75);
    border-radius: 4px;
    transition: all 0.3s ease;
}

.btn-outline:hover {
    background: #fff;
    color: var(--primary-color);
}

/* =========================================
   ANIMATIONS
   ========================================= */

/* The Fade Up Animation (Matches WordPress behavior) */
.animate-on-scroll {
    opacity: 0;
    transform: translateY(60px);
    /* Slightly deeper drop */
    transition: opacity 1s cubic-bezier(0.165, 0.84, 0.44, 1),
        transform 1s cubic-bezier(0.165, 0.84, 0.44, 1);
}

.animate-on-scroll.is-visible {
    opacity: 1;
    transform: translateY(0);
}

/* Staggered Delays for Grid items */
.delay-1 {
    transition-delay: 0.15s;
}

.delay-2 {
    transition-delay: 0.30s;
}

.delay-3 {
    transition-delay: 0.45s;
}

/* The Parallax Zoom Animation */
.animate-zoom-out {
    animation: zoomOutReveal 2.5s cubic-bezier(0.25, 1, 0.33, 1) forwards;
}

/* Pause the animation for scroll-triggered elements until they are visible */
.hero-box .animate-zoom-out,
/* Runs instantly */
.footer-box:hover .animate-zoom-out

/* Just in case */
    {
    animation: zoomOutReveal 2.5s cubic-bezier(0.25, 1, 0.33, 1) forwards;
}

@keyframes zoomOutReveal {
    0% {
        transform: scale(1.15);
    }

    100% {
        transform: scale(1);
    }
}

/* Responsive */
@media (max-width: 768px) {
    .two-col {
        grid-template-columns: 1fr;
    }

    .hero-box {
        padding: 80px 30px;
    }

    .hero h1 {
        font-size: 3rem;
        /* Scales down smoothly for mobile */
    }

    .footer-box {
        padding: 80px 20px;
    }

    .footer-content h2 {
        font-size: 1.8rem;
    }

    .image-gallery {
        height: 350px;
    }
}