/* Base Reset */
*,
*::before,
*::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
    font-size: 16px;
}

:root {
    /* Colors */
    --color-bg: #FDFBF7;
    /* Warm off-white */
    --color-bg-alt: #F2F5F0;
    /* Very light sage green for alternate sections */
    --color-text: #2C3E35;
    /* Deep forest green */
    --color-text-light: #5A6D63;
    --color-accent: #86A789;
    /* Stronger sage green */
    --color-accent-dark: #648167;
    --color-accent-light: #D2E3D4;
    --color-white: #FFFFFF;

    /* Typography */
    --font-heading: 'Playfair Display', serif;
    --font-body: 'Inter', sans-serif;

    /* Variables */
    --transition: all 0.3s ease;
    --border-radius: 12px;
}

body {
    background-color: var(--color-bg);
    color: var(--color-text);
    font-family: var(--font-body);
    line-height: 1.6;
    overflow-x: hidden;
}

/* Sections wrappers for full width backgrounds */
.hero-section {
    width: 100%;
    background: linear-gradient(135deg, #F2F5F0 0%, #D2E3D4 100%);
    position: relative;
    z-index: 1;
}

.philosophy-section {
    width: 100%;
    background-color: var(--color-bg-alt);
    /* Light sage */
}

/* Typography Elements */
h1,
h2,
h3,
h4,
h5,
h6 {
    font-family: var(--font-heading);
    font-weight: 500;
    margin-bottom: 1rem;
    color: var(--color-text);
}

h1 {
    font-size: clamp(2.5rem, 5vw, 4rem);
    line-height: 1.1;
}

h2 {
    font-size: clamp(2rem, 4vw, 3rem);
}

h3 {
    font-size: 1.5rem;
}

p {
    margin-bottom: 1.5rem;
    color: var(--color-text-light);
}

a {
    text-decoration: none;
    color: inherit;
    transition: var(--transition);
}

/* Navigation */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    background-color: rgba(44, 62, 53, 0.98);
    /* Deep forest green / color-text with slight transparency */
    backdrop-filter: blur(10px);
    z-index: 1000;
    padding: 1rem 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    transition: var(--transition);
}

.nav-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.nav-brand {
    font-family: var(--font-heading);
    font-size: 1.2rem;
    font-weight: 700;
    display: flex;
    flex-direction: column;
    color: var(--color-white);
}

.brand-subtitle {
    font-family: var(--font-body);
    font-size: 0.8rem;
    font-weight: 400;
    color: var(--color-accent-light);
    letter-spacing: 1px;
    text-transform: uppercase;
}

.nav-links {
    list-style: none;
    display: flex;
    gap: 2.5rem;
    align-items: center;
}

.nav-links a {
    font-size: 0.95rem;
    font-weight: 500;
    color: var(--color-white);
}

.nav-links a:hover {
    color: var(--color-accent-light);
}

.mobile-menu-btn {
    display: none;
    background: none;
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
    color: var(--color-white);
}

/* Buttons */
.btn-primary {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    background-color: var(--color-accent);
    color: var(--color-white);
    padding: 0.8rem 1.8rem;
    border-radius: 30px;
    font-weight: 500;
    border: 1px solid var(--color-accent);
    transition: var(--transition);
}

.btn-primary:hover {
    background-color: var(--color-accent-dark);
    border-color: var(--color-accent-dark);
    color: var(--color-white);
}

.btn-secondary {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    background-color: transparent;
    color: var(--color-text);
    padding: 0.8rem 1.8rem;
    border-radius: 30px;
    font-weight: 500;
    border: 1px solid var(--color-text);
    transition: var(--transition);
}

.btn-secondary:hover {
    background-color: var(--color-text);
    color: var(--color-white);
}

/* Hero Section */
.hero {
    max-width: 1200px;
    margin: 0 auto;
    padding: 8rem 2rem 4rem;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
    min-height: 100vh;
}

.hero-section::before {
    content: '';
    position: absolute;
    top: -10%;
    right: -5%;
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, var(--color-white) 0%, transparent 70%);
    opacity: 0.6;
    z-index: -1;
    border-radius: 50%;
}

.eyebrow {
    display: inline-block;
    color: var(--color-accent-dark);
    text-transform: uppercase;
    letter-spacing: 2px;
    font-size: 0.85rem;
    font-weight: 600;
    margin-bottom: 1rem;
}

.hero-description {
    font-size: 1.1rem;
    max-width: 480px;
}

.hero-actions {
    display: flex;
    gap: 1rem;
    margin-top: 2rem;
}

.hero-image-wrapper {
    position: relative;
    border-radius: var(--border-radius);
    overflow: hidden;
    box-shadow: 0 20px 40px rgba(44, 62, 53, 0.08);
}

.hero-image {
    width: 100%;
    height: auto;
    display: block;
    aspect-ratio: 4/5;
    object-fit: cover;
}

.image-accent {
    position: absolute;
    bottom: -20px;
    left: -20px;
    width: 150px;
    height: 150px;
    background-color: var(--color-accent-light);
    border-radius: 50%;
    z-index: -1;
}

/* About Section */
.about {
    background-color: var(--color-white);
    /* Changed to white to contrast with the green hero and green philosophy */
    padding: 6rem 2rem;
    position: relative;
    overflow: hidden;
}

.about::before {
    content: '';
    position: absolute;
    bottom: -10%;
    left: -5%;
    width: 400px;
    height: 400px;
    background: radial-gradient(circle, var(--color-bg-alt) 0%, transparent 70%);
    opacity: 0.8;
    z-index: 0;
    border-radius: 50%;
}

.about-container {
    max-width: 1000px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
    position: relative;
    z-index: 1;
}

.about-image-wrapper {
    position: relative;
    border-radius: var(--border-radius);
    overflow: hidden;
    box-shadow: 0 15px 35px rgba(44, 62, 53, 0.1);
}

.about-image-wrapper::after {
    content: '';
    position: absolute;
    top: 5%;
    left: 5%;
    width: 90%;
    height: 90%;
    border: 1px solid var(--color-white);
    border-radius: var(--border-radius);
    z-index: 1;
    pointer-events: none;
}

.about-image {
    width: 100%;
    height: auto;
    object-fit: cover;
    aspect-ratio: 1/1;
    border-radius: var(--border-radius);
}

.highlight-text {
    font-size: 1.4rem;
    font-family: var(--font-heading);
    font-style: italic;
    color: var(--color-accent-dark);
    margin-bottom: 2rem;
    border-left: 3px solid var(--color-accent);
    padding-left: 1.5rem;
}

/* Philosophy Section */
.philosophy {
    padding: 6rem 2rem;
    max-width: 1200px;
    margin: 0 auto;
}

.text-center {
    text-align: center;
    margin-bottom: 4rem;
}

.philosophy-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
}

.card {
    background: var(--color-white);
    padding: 2.5rem 2rem;
    border-radius: var(--border-radius);
    box-shadow: 0 10px 30px rgba(44, 62, 53, 0.03);
    transition: var(--transition);
    border: 1px solid var(--color-white);
    position: relative;
    overflow: hidden;
    z-index: 1;
}

.card::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(180deg, rgba(210, 227, 212, 0.2) 0%, transparent 100%);
    opacity: 0;
    z-index: -1;
    transition: opacity 0.4s ease;
}

.card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 4px;
    background: var(--color-accent);
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 0.4s ease;
}

.card:hover {
    transform: translateY(-8px);
    box-shadow: 0 20px 40px rgba(44, 62, 53, 0.08);
    border-color: var(--color-accent-light);
}

.card:hover::before {
    transform: scaleX(1);
}

.card:hover::after {
    opacity: 1;
}

.card:hover .card-icon {
    transform: scale(1.1) translateY(-5px);
    color: var(--color-accent);
}

.card-icon {
    font-size: 2.2rem;
    color: var(--color-accent-dark);
    margin-bottom: 1.5rem;
    transition: transform 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275), color 0.4s ease;
    display: inline-block;
}

.card h3 {
    font-size: 1.2rem;
    margin-bottom: 1rem;
}

.card p {
    font-size: 0.95rem;
    margin-bottom: 0;
}

/* Contact Section */
.contact {
    background-color: var(--color-text);
    color: var(--color-white);
    padding: 6rem 2rem;
}

.contact-box {
    max-width: 600px;
    margin: 0 auto;
    text-align: center;
}

.contact h2 {
    color: var(--color-white);
}

.contact p {
    color: rgba(255, 255, 255, 0.8);
    margin-bottom: 3rem;
}

.contact-form {
    background: var(--color-white);
    padding: 3rem;
    border-radius: var(--border-radius);
    text-align: left;
}

.form-group {
    margin-bottom: 1.5rem;
}

.form-group label {
    display: block;
    color: var(--color-text);
    font-weight: 500;
    margin-bottom: 0.5rem;
    font-size: 0.9rem;
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 0.8rem 1rem;
    border: 1px solid rgba(44, 62, 53, 0.2);
    border-radius: 8px;
    font-family: var(--font-body);
    font-size: 1rem;
    color: var(--color-text);
    transition: var(--transition);
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--color-accent);
    box-shadow: 0 0 0 3px rgba(163, 184, 153, 0.2);
}

.btn-submit {
    width: 100%;
    justify-content: center;
    padding: 1rem;
    font-size: 1.1rem;
    margin-top: 1rem;
    cursor: pointer;
}

/* Footer */
.footer {
    background-color: #202D26;
    color: rgba(255, 255, 255, 0.8);
    padding: 4rem 2rem 2rem;
}

.footer-container {
    max-width: 1200px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 3rem;
    margin-bottom: 3rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    padding-bottom: 3rem;
}

.footer-brand h3 {
    color: var(--color-white);
    margin-bottom: 0.5rem;
}

.footer-links {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.footer-links a:hover {
    color: var(--color-accent);
}

.footer-social {
    display: flex;
    gap: 1rem;
}

.footer-social a {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background-color: rgba(255, 255, 255, 0.1);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--color-white);
    transition: var(--transition);
}

.footer-social a:hover {
    background-color: var(--color-accent);
    transform: translateY(-3px);
}

.footer-bottom {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.85rem;
}

.customdev-credit a {
    color: var(--color-accent);
    font-weight: 600;
}

/* Animations */
.fade-in-up {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.8s ease-out, transform 0.8s ease-out;
}

.fade-in-up.active {
    opacity: 1;
    transform: translateY(0);
}

/* Responsive */
@media (max-width: 900px) {
    .hero {
        grid-template-columns: 1fr;
        padding-top: 8rem;
        text-align: center;
    }

    .hero-actions {
        justify-content: center;
    }

    .about-container {
        grid-template-columns: 1fr;
    }

    .about-image-wrapper {
        order: -1;
    }
}

@media (max-width: 768px) {
    .nav-links {
        display: none;
        /* Hide on mobile by default, handeled in JS */
        flex-direction: column;
        position: absolute;
        top: 100%;
        left: 0;
        width: 100%;
        background-color: var(--color-text);
        padding: 2rem;
        box-shadow: 0 10px 20px rgba(0, 0, 0, 0.2);
    }

    .nav-links.active {
        display: flex;
    }

    .mobile-menu-btn {
        display: block;
    }

    .hero-actions {
        flex-direction: column;
    }

    .footer-bottom {
        flex-direction: column;
        gap: 1rem;
        text-align: center;
    }
}