/* CSS Variables & Theme */
:root {
    /* Brand Colors */
    --primary: #1EB53A;
    --primary-dark: #179E2E;
    --secondary: #E6F5E6;
    --accent: #00A651;
    
    /* Neutrals - Light Mode */
    --dark: #1A1A1A;
    --gray: #6B7280;
    --light-gray: #F3F4F6;
    --white: #FFFFFF;
    --off-white: #FAFBFC;
    --white-tint: #F8FBF8; /* Subtly tinted white */
    
    /* Structural Colors */
    --bg-body: var(--white-tint);
    --bg-header: var(--white);
    --bg-footer: #111827;
    --text-main: var(--dark);
    --text-muted: var(--gray);
    --border-color: #E5E7EB;
    
    /* Typography */
    --font-main: 'Inter', system-ui, sans-serif;
    
    /* Layout */
    --header-height: 72px;
    --container-max: 1200px;
    --radius: 12px;
    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
    --transition: 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Dark Mode Overrides */
@media (prefers-color-scheme: dark) {
    :root {
        --bg-body: #121212;
        --bg-header: #1E1E1E;
        --bg-footer: #0A0A0A;
        --text-main: #F9FAFB;
        --text-muted: #9CA3AF;
        --secondary: #132A18; /* Dark muted green for backgrounds */
        --light-gray: #1F2922; /* Dark card background */
        --off-white: #181C19;
        --white-tint: #121613;
        --border-color: #374151;
        --white: #1E1E1E; /* Re-map white for header/cards */
    }
}

/* Reset & Base */
*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
    font-size: 16px;
}

body {
    font-family: var(--font-main);
    background-color: var(--bg-body);
    color: var(--text-main);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}

body.no-scroll {
    overflow: hidden;
}

a {
    text-decoration: none;
    color: inherit;
    transition: color var(--transition);
}

img, svg {
    display: block;
    max-width: 100%;
}

/* Typography */
h1, h2, h3, h4 {
    font-weight: 700;
    line-height: 1.2;
    color: var(--text-main);
}

.tag {
    font-weight: 600;
    text-transform: uppercase;
    font-size: 0.75rem;
    letter-spacing: 0.05em;
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.75rem 1.5rem;
    border-radius: var(--radius);
    font-weight: 600;
    cursor: pointer;
    transition: all var(--transition);
    border: none;
    text-align: center;
}

.btn-primary {
    background-color: var(--primary);
    color: #FFFFFF !important;
}

.btn-primary:hover {
    background-color: var(--primary-dark);
    transform: scale(1.02);
    box-shadow: var(--shadow-md);
}

.btn-large {
    padding: 1rem 2rem;
    font-size: 1.125rem;
}

.btn-outline {
    background-color: transparent;
    color: var(--primary);
    border: 2px solid var(--primary);
}

.btn-outline:hover {
    background-color: var(--primary);
    color: #FFFFFF !important;
}

/* Header */
.site-header {
    position: sticky;
    top: 0;
    z-index: 100;
    background-color: var(--bg-header);
    border-bottom: 1px solid var(--border-color);
    height: var(--header-height);
    display: flex;
    align-items: center;
}

.header-container {
    width: 100%;
    max-width: var(--container-max);
    margin: 0 auto;
    padding: 0 1.5rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo-link {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.logo-text {
    font-weight: 700;
    font-size: 1.25rem;
    color: var(--text-main);
}

.main-nav {
    display: flex;
    align-items: center;
    gap: 2rem;
}

.nav-list {
    display: flex;
    list-style: none;
    gap: 2rem;
}

.nav-link {
    font-weight: 600;
    color: var(--text-muted);
}

.nav-link:hover, .nav-link.active {
    color: var(--primary);
}

.mobile-menu-toggle {
    display: none;
    background: none;
    border: none;
    cursor: pointer;
    padding: 0.5rem;
    z-index: 101;
}

.hamburger, .hamburger::before, .hamburger::after {
    display: block;
    width: 24px;
    height: 2px;
    background-color: var(--text-main);
    transition: transform 0.3s, opacity 0.3s;
}

.hamburger::before, .hamburger::after {
    content: '';
    position: absolute;
}

.hamburger::before { transform: translateY(-8px); }
.hamburger::after { transform: translateY(8px); }

/* Page Router */
.page {
    display: none;
}
.page[style*="display: block"] {
    animation: fadeIn 0.4s ease-out;
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

/* --- HOME PAGE SECTIONS --- */

/* Hero Section */
.hero {
    background: linear-gradient(135deg, var(--secondary) 0%, var(--bg-body) 100%);
    padding: 4rem 1.5rem;
    overflow: hidden;
    margin-top: 0;
}

.hero-container {
    max-width: var(--container-max);
    margin: 0 auto;
    display: flex;
    align-items: center;
    gap: 4rem;
}

.hero-content {
    flex: 1;
    max-width: 600px;
}

.hero-content h1 {
    font-size: clamp(2.5rem, 5vw, 3.5rem);
    margin-bottom: 1.5rem;
    color: var(--text-main);
}

.hero-content p {
    font-size: 1.125rem;
    color: var(--text-muted);
    margin-bottom: 2rem;
}

.hero-visual {
    flex: 1;
    position: relative;
    min-height: 400px;
    display: flex;
    justify-content: center;
    align-items: center;
}

/* Carousel */
.story-carousel {
    position: relative;
    width: 100%;
    max-width: 450px;
    height: 300px;
}

.carousel-slide {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    transition: opacity 1s ease-in-out;
    pointer-events: none;
}

.carousel-slide.active {
    opacity: 1;
    pointer-events: auto;
}

.story-card {
    background-color: var(--bg-header);
    padding: 2.5rem;
    border-radius: var(--radius);
    box-shadow: var(--shadow-lg);
    height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: center;
    border: 1px solid var(--border-color);
}

.story-icon {
    margin-bottom: 1.5rem;
    background-color: var(--secondary);
    width: 56px;
    height: 56px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.story-quote {
    font-size: 1.25rem;
    font-style: italic;
    margin-bottom: 1.5rem;
    color: var(--text-main);
}

.story-author {
    font-weight: 600;
    color: var(--primary);
}

/* Stats Section */
.stats {
    background-color: var(--primary-dark);
    padding: 3rem 1.5rem;
}

.stats-container {
    max-width: var(--container-max);
    margin: 0 auto;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 2rem;
    text-align: center;
}

.stat-item {
    color: #FFFFFF;
}

.stat-title {
    display: block;
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
}

.stat-desc {
    font-size: 0.875rem;
    opacity: 0.9;
}

/* Section Common */
.section-container {
    max-width: var(--container-max);
    margin: 0 auto;
    padding: 5rem 1.5rem;
}

.section-title {
    text-align: center;
    font-size: 2.25rem;
    margin-bottom: 3.5rem;
}

/* Process Section */
.process {
    background-color: var(--white); /* Explicitly requested white bg */
}

@media (prefers-color-scheme: dark) {
    .process {
        background-color: var(--bg-body); /* Adapt for dark mode */
    }
}

.timeline {
    display: flex;
    flex-direction: column;
    gap: 3rem;
    position: relative;
}

@media (min-width: 768px) {
    .timeline {
        flex-direction: row;
        justify-content: space-between;
        gap: 2rem;
    }
    
    .timeline::before {
        content: '';
        position: absolute;
        top: 40px;
        left: 50px;
        right: 50px;
        height: 2px;
        background-color: var(--border-color);
        z-index: 0;
    }
}

.timeline-step {
    flex: 1;
    text-align: center;
    position: relative;
    z-index: 1;
}

.step-icon {
    width: 80px;
    height: 80px;
    background-color: var(--bg-header);
    border: 2px solid var(--primary);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1.5rem;
    color: var(--primary);
    box-shadow: var(--shadow-sm);
}

.timeline-step h3 {
    font-size: 1.25rem;
    margin-bottom: 1rem;
}

.timeline-step p {
    color: var(--text-muted);
}

/* Benefits Section */
.benefits {
    background-color: var(--secondary);
}

.benefits-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
}

.benefit-card {
    background-color: var(--light-gray);
    padding: 2rem;
    border-radius: var(--radius);
    transition: transform var(--transition), box-shadow var(--transition);
    border: 1px solid transparent;
}

@media (prefers-color-scheme: dark) {
    .benefit-card {
        border-color: var(--border-color);
    }
}

.benefit-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-md);
}

.b-icon {
    width: 48px;
    height: 48px;
    color: var(--primary);
    margin-bottom: 1.5rem;
}

.benefit-card h3 {
    margin-bottom: 1rem;
    font-size: 1.25rem;
}

.benefit-card p {
    color: var(--text-muted);
}

/* Testimonials Section */
.testimonials {
    background-color: var(--off-white);
}

.testimo-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
}

.testimo-card {
    background-color: var(--bg-header);
    padding: 2rem;
    border-radius: var(--radius);
    box-shadow: var(--shadow-sm);
    border: 1px solid var(--border-color);
    display: flex;
    flex-direction: column;
}

.stars {
    color: #F59E0B;
    font-size: 1.25rem;
    margin-bottom: 1rem;
    letter-spacing: 2px;
}

.testimo-card .quote {
    font-style: italic;
    color: var(--text-main);
    margin-bottom: 2rem;
    flex-grow: 1;
}

.author-info {
    display: flex;
    flex-direction: column;
}

.author-info .name {
    font-weight: 700;
    color: var(--primary-dark);
}

.author-info .job {
    font-size: 0.875rem;
    color: var(--text-muted);
}

/* CTA Bottom */
.cta-bottom {
    background: linear-gradient(135deg, var(--primary-dark) 0%, #0c5417 100%);
    padding: 6rem 1.5rem;
    text-align: center;
    color: #FFFFFF;
}

.cta-container h2 {
    color: #FFFFFF;
    font-size: 2.5rem;
    margin-bottom: 1rem;
}

.cta-container p {
    font-size: 1.25rem;
    opacity: 0.9;
    margin-bottom: 2.5rem;
}

.cta-btn {
    background-color: #FFFFFF;
    color: var(--primary-dark) !important;
}

.cta-btn:hover {
    background-color: var(--off-white);
    color: var(--primary-dark) !important;
}

/* --- LEGAL PAGES --- */
.legal-wrapper {
    padding: 4rem 1.5rem;
    min-height: calc(100vh - var(--header-height));
}

#legal-privacy, #legal-terms {
    max-width: 780px;
    margin: 0 auto;
    color: var(--text-main);
    line-height: 1.8;
}

#legal-privacy h1, #legal-terms h1,
#legal-privacy h2, #legal-terms h2,
#legal-privacy h3, #legal-terms h3 {
    margin-top: 2.5rem;
    margin-bottom: 1rem;
    color: var(--primary-dark);
}

@media (prefers-color-scheme: dark) {
    #legal-privacy h1, #legal-terms h1,
    #legal-privacy h2, #legal-terms h2,
    #legal-privacy h3, #legal-terms h3 {
        color: var(--primary);
    }
}

#legal-privacy p, #legal-terms p,
#legal-privacy ul, #legal-terms ul {
    margin-bottom: 1.5rem;
    color: var(--text-muted);
}

#legal-privacy ul, #legal-terms ul {
    padding-left: 2rem;
}

#legal-privacy a, #legal-terms a {
    color: var(--primary);
    text-decoration: underline;
}

/* --- FOOTER --- */
.site-footer {
    background-color: var(--bg-footer);
    color: #D1D5DB;
    padding: 5rem 1.5rem 2rem;
}

.footer-container {
    max-width: var(--container-max);
    margin: 0 auto;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 3rem;
    margin-bottom: 4rem;
}

.footer-brand {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 1.5rem;
    color: #FFFFFF;
    font-weight: 700;
    font-size: 1.25rem;
}

.footer-desc {
    font-size: 0.875rem;
    line-height: 1.6;
}

.footer-col h4 {
    color: #FFFFFF;
    margin-bottom: 1.5rem;
    font-size: 1.125rem;
}

.footer-links {
    list-style: none;
}

.footer-links li {
    margin-bottom: 0.75rem;
}

.footer-links a {
    color: #9CA3AF;
}

.footer-links a:hover {
    color: var(--primary);
}

.footer-cta {
    margin-top: 1.5rem;
}

.footer-bottom {
    max-width: var(--container-max);
    margin: 0 auto;
    padding-top: 2rem;
    border-top: 1px solid #374151;
    text-align: center;
    font-size: 0.875rem;
    color: #6B7280;
}

/* --- ANIMATIONS --- */
.fade-in-up {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}

.fade-in-up.visible {
    opacity: 1;
    transform: translateY(0);
}

.delay-1 { transition-delay: 0.1s; }
.delay-2 { transition-delay: 0.2s; }
.delay-3 { transition-delay: 0.3s; }

/* --- RESPONSIVE --- */
@media (max-width: 992px) {
    .hero-container {
        flex-direction: column;
        text-align: center;
    }
    .hero-content {
        max-width: 100%;
    }
    .hero-actions {
        justify-content: center;
    }
    .hero-visual {
        width: 100%;
        min-height: auto;
    }
    .story-carousel {
        max-width: 100%;
        height: auto;
    }
    .carousel-slide {
        position: relative;
        height: auto;
        display: none;
    }
    .carousel-slide.active {
        display: block;
    }
    .story-card {
        height: auto;
    }
}

@media (max-width: 768px) {
    .mobile-menu-toggle {
        display: block;
    }
    
    .main-nav {
        position: fixed;
        top: var(--header-height);
        left: 0;
        width: 100%;
        height: calc(100vh - var(--header-height));
        background-color: var(--bg-header);
        flex-direction: column;
        justify-content: flex-start;
        padding: 2rem;
        gap: 2rem;
        transform: translateX(100%);
        transition: transform var(--transition);
        border-top: 1px solid var(--border-color);
        overflow-y: auto;
    }
    
    .main-nav.active {
        transform: translateX(0);
    }
    
    .nav-list {
        flex-direction: column;
        align-items: center;
        width: 100%;
    }
    
    .nav-link {
        font-size: 1.25rem;
        display: block;
        padding: 1rem;
    }
    
    .hamburger.active {
        background-color: transparent;
    }
    .hamburger.active::before {
        transform: rotate(45deg);
    }
    .hamburger.active::after {
        transform: rotate(-45deg);
    }
    
    .section-title {
        font-size: 1.75rem;
    }
}
