/*
File: style.css
*/

/* ==================
   1. CSS Variables & Global Styles
   ================== */
:root {
    /* Triadic Color Scheme */
    --color-background: #E0E5EC;
    --color-primary-accent: #4E9A91; /* Muted Teal */
    --color-secondary-accent: #C97B63; /* Earthy Orange */
    
    /* Text & Shadow Colors */
    --color-text-dark: #333A45;
    --color-text-light: #FFFFFF;
    --color-shadow-light: #ffffff;
    --color-shadow-dark: #a3b1c6;
    
    /* Fonts */
    --font-heading: 'Montserrat', sans-serif;
    --font-body: 'Merriweather', serif;

    /* Neumorphism Shadows */
    --neumorphic-shadow: 8px 8px 16px var(--color-shadow-dark), -8px -8px 16px var(--color-shadow-light);
    --neumorphic-shadow-inset: inset 8px 8px 16px var(--color-shadow-dark), inset -8px -8px 16px var(--color-shadow-light);

    /* Spacing */
    --header-height: 80px;
}

*,
*::before,
*::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
    font-size: 16px;
}

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

.main-container {
    overflow: hidden; /* Contains biomorphic shapes */
    position: relative;
}

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

h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-heading);
    color: #222222;
    font-weight: 700;
    line-height: 1.3;
    margin-bottom: 1rem;
}

h1 { font-size: 3rem; }
h2 { font-size: 2.5rem; }
h3 { font-size: 1.75rem; }
h4 { font-size: 1.25rem; }

p {
    margin-bottom: 1rem;
}

a {
    color: var(--color-primary-accent);
    text-decoration: none;
    transition: color 0.3s ease;
}

a:hover {
    color: var(--color-secondary-accent);
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

/* Utility Classes */
.columns {
    display: flex;
    flex-wrap: wrap;
    margin: 0 -15px;
}

.column {
    padding: 0 15px;
    flex: 1;
}

.column.is-two-thirds {
    flex: 0 0 66.66%;
}

/* ==================
   2. Buttons & Inputs (Global)
   ================== */
.neumorphic-button, .neumorphic-input, .neumorphic-link {
    border-radius: 20px;
    background: var(--color-background);
    box-shadow: var(--neumorphic-shadow);
    border: none;
    transition: all 0.3s ease-in-out;
}

.neumorphic-button {
    padding: 15px 30px;
    font-family: var(--font-heading);
    font-weight: 700;
    color: var(--color-text-dark);
    cursor: pointer;
    font-size: 1rem;
}

.neumorphic-button:hover {
    color: var(--color-primary-accent);
}

.neumorphic-button:active {
    box-shadow: var(--neumorphic-shadow-inset);
    color: var(--color-secondary-accent);
}

.neumorphic-input {
    width: 100%;
    padding: 15px 20px;
    font-family: var(--font-body);
    color: var(--color-text-dark);
    font-size: 1rem;
    box-shadow: var(--neumorphic-shadow-inset);
}

.neumorphic-input:focus {
    outline: none;
    box-shadow: var(--neumorphic-shadow-inset), 0 0 0 2px var(--color-primary-accent);
}

.neumorphic-input::placeholder {
    color: #8a99b1;
}

/* ==================
   3. Header & Navigation
   ================== */
.site-header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    padding: 15px 0;
    background: rgba(224, 229, 236, 0.8);
    backdrop-filter: blur(10px);
    transition: all 0.3s ease;
}

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

.logo {
    font-family: var(--font-heading);
    font-size: 1.8rem;
    font-weight: 700;
    color: var(--color-text-dark);
}

.nav-links {
    display: flex;
    gap: 30px;
}

.nav-links a {
    font-family: var(--font-heading);
    font-weight: 700;
    color: var(--color-text-dark);
    position: relative;
    padding: 5px 0;
}

.nav-links a::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 3px;
    background-color: var(--color-primary-accent);
    transform: scaleX(0);
    transform-origin: right;
    transition: transform 0.3s ease-in-out;
}

.nav-links a:hover::after {
    transform: scaleX(1);
    transform-origin: left;
}

.burger-menu {
    display: none;
    background: none;
    border: none;
    cursor: pointer;
    z-index: 1001;
}

.burger-menu span {
    display: block;
    width: 25px;
    height: 3px;
    background-color: var(--color-text-dark);
    margin: 5px 0;
    transition: all 0.3s ease-in-out;
}

/* ==================
   4. Hero Section
   ================== */
.hero-section {
    position: relative;
    height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    background-attachment: fixed;
    color: var(--color-text-light);
    overflow: hidden;
}

.hero-content {
    z-index: 2;
    max-width: 800px;
    padding: 20px;
}

.hero-title {
    font-size: 3.5rem;
    margin-bottom: 1rem;
    color: var(--color-text-light);
}

.hero-subtitle {
    font-size: 1.2rem;
    margin-bottom: 2rem;
    color: var(--color-text-light);
}

.biomorphic-shape {
    position: absolute;
    background: linear-gradient(145deg, var(--color-primary-accent), var(--color-secondary-accent));
    opacity: 0.15;
    animation: morph 20s ease-in-out infinite alternate;
    z-index: 1;
}

.shape1 {
    width: 400px;
    height: 400px;
    top: 10%;
    left: 10%;
}

.shape2 {
    width: 300px;
    height: 300px;
    bottom: 15%;
    right: 5%;
    animation-direction: alternate-reverse;
    animation-duration: 25s;
}

@keyframes morph {
    0% {
        border-radius: 60% 40% 30% 70% / 60% 30% 70% 40%;
        transform: rotate(0deg) scale(1);
    }
    50% {
        border-radius: 30% 60% 70% 40% / 50% 60% 30% 60%;
        transform: rotate(180deg) scale(1.1);
    }
    100% {
        border-radius: 60% 40% 30% 70% / 60% 30% 70% 40%;
        transform: rotate(360deg) scale(1);
    }
}

/* ==================
   5. Content Sections
   ================== */
.content-section, .content-section-dark, .content-section-page {
    padding: 80px 0;
}

.content-section-dark {
    background: #2c323a;
    color: var(--color-text-light);
}

.content-section-dark h2, .content-section-dark h3, .content-section-dark p {
    color: var(--color-text-light);
}

.content-section-dark .section-title {
    text-shadow: 1px 1px 3px rgba(0,0,0,0.5);
}

.section-title {
    text-align: center;
    margin-bottom: 4rem;
}

.section-subtitle {
    text-align: center;
    max-width: 700px;
    margin: -3rem auto 3rem auto;
    font-size: 1.1rem;
}

/* For pages like privacy.html */
.content-section-page {
    padding-top: calc(var(--header-height) + 60px);
}

/* ==================
   6. Components
   ================== */
/* Cards (Blog, Projects) */
.card {
    display: flex;
    flex-direction: column;
    height: 100%;
    border-radius: 20px;
    background: var(--color-background);
    box-shadow: var(--neumorphic-shadow);
    overflow: hidden;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.card:hover {
    transform: translateY(-10px);
    box-shadow: 12px 12px 24px var(--color-shadow-dark), -12px -12px 24px var(--color-shadow-light);
}

.card-image {
    width: 100%;
    height: 250px; /* Fixed height for consistency */
    overflow: hidden;
}

.card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.4s ease;
}

.card:hover .card-image img {
    transform: scale(1.05);
}

.card-content {
    padding: 2rem;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
    text-align: center;
}

.card-content h3 {
    margin-bottom: 1rem;
}

.card-content p {
    flex-grow: 1;
}

.read-more {
    font-family: var(--font-heading);
    font-weight: 700;
    color: var(--color-secondary-accent);
    margin-top: 1.5rem;
    align-self: center;
    display: inline-block;
}

.read-more:hover {
    text-decoration: underline;
}

/* Stats Widgets */
.stats-widgets-container {
    display: flex;
    justify-content: space-around;
    flex-wrap: wrap;
    margin-top: 4rem;
    gap: 20px;
}

.stat-widget {
    text-align: center;
    padding: 20px;
}

.stat-widget h3 {
    font-size: 3rem;
    color: var(--color-primary-accent);
    margin-bottom: 0.5rem;
}

/* Our Process */
.process-steps {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 30px;
}

.process-step {
    text-align: center;
    padding: 2rem;
    border-radius: 20px;
    background: #333a45; /* Darker than section bg */
    box-shadow: var(--neumorphic-shadow);
}

.step-number {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background-color: var(--color-primary-accent);
    color: var(--color-text-light);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    font-weight: 700;
    margin: 0 auto 1.5rem auto;
}

.progress-indicator {
    width: 100%;
    height: 8px;
    background-color: #4a525f;
    border-radius: 4px;
    margin-top: 1.5rem;
    overflow: hidden;
}

.progress-bar {
    height: 100%;
    background: linear-gradient(90deg, var(--color-primary-accent), var(--color-secondary-accent));
    border-radius: 4px;
}

/* Custom Slider */
.custom-slider {
    position: relative;
}

.slider-wrapper {
    display: flex;
    overflow-x: hidden; /* Managed by JS */
    scroll-snap-type: x mandatory;
}

.slide {
    flex: 0 0 100%;
    scroll-snap-align: center;
    padding: 10px;
}

.slider-controls {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 100%;
    display: flex;
    justify-content: space-between;
    padding: 0 2rem;
    pointer-events: none;
}

.slider-prev, .slider-next {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    border: none;
    background-color: var(--color-background);
    color: var(--color-text-dark);
    font-size: 2rem;
    cursor: pointer;
    box-shadow: var(--neumorphic-shadow);
    pointer-events: all;
    transition: all 0.3s ease;
}

.slider-prev:active, .slider-next:active {
    box-shadow: var(--neumorphic-shadow-inset);
}

/* Methodology Toggles */
.toggle-container {
    display: flex;
    justify-content: center;
    gap: 2rem;
    flex-wrap: wrap;
    margin-bottom: 3rem;
}

.toggle-switch-wrapper {
    display: flex;
    align-items: center;
    gap: 10px;
}

.switch {
    position: relative;
    display: inline-block;
    width: 60px;
    height: 34px;
}

.switch input {
    opacity: 0;
    width: 0;
    height: 0;
}

.slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: #4a525f;
    box-shadow: var(--neumorphic-shadow-inset);
    transition: .4s;
}

.slider:before {
    position: absolute;
    content: "";
    height: 26px;
    width: 26px;
    left: 4px;
    bottom: 4px;
    background-color: var(--color-background);
    transition: .4s;
}

input:checked + .slider {
    background-color: var(--color-primary-accent);
}

input:checked + .slider:before {
    transform: translateX(26px);
}

.slider.round { border-radius: 34px; }
.slider.round:before { border-radius: 50%; }

.method-pane {
    display: none;
    text-align: center;
    max-width: 800px;
    margin: 0 auto;
}

.method-pane.active {
    display: block;
    animation: fadeIn .5s;
}

/* Accolades */
.accolades-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
}

.accolade-item {
    padding: 2rem;
    border-radius: 20px;
    box-shadow: var(--neumorphic-shadow);
    text-align: center;
}

/* External Resources */
.external-links-list {
    list-style: none;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 20px;
}

.neumorphic-link {
    display: block;
    padding: 15px 40px;
    text-align: center;
    min-width: 300px;
    color: var(--color-text-dark);
}
.neumorphic-link:hover {
    color: var(--color-primary-accent);
}
.neumorphic-link:active {
    box-shadow: var(--neumorphic-shadow-inset);
    color: var(--color-secondary-accent);
}

/* Contact Form */
.contact-form {
    max-width: 700px;
    margin: 2rem auto 0 auto;
    display: flex;
    flex-direction: column;
    gap: 2rem;
}

/* ==================
   7. Footer
   ================== */
.site-footer {
    background: #2c323a;
    color: #cdd6e4;
    padding: 60px 0 20px 0;
}

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

.footer-column h4 {
    color: var(--color-text-light);
    margin-bottom: 1.5rem;
    text-shadow: 1px 1px 3px rgba(0,0,0,0.5);
}

.footer-column ul {
    list-style: none;
}

.footer-column ul li {
    margin-bottom: 10px;
}

.footer-column a {
    color: #cdd6e4;
}

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

.social-links {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.copyright {
    text-align: center;
    padding-top: 20px;
    border-top: 1px solid #4a525f;
    font-size: 0.9rem;
}

/* ==================
   8. Specific Page Styles
   ================== */
/* Legal Pages */
.legal-content h2 {
    margin-top: 2rem;
    margin-bottom: 1rem;
}
.legal-content h2:first-of-type {
    margin-top: 0;
}
.legal-content {
    max-width: 800px;
}

/* Success Page */
.success-page {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 0;
}

.success-message h1 {
    font-size: 4rem;
    color: var(--color-primary-accent);
}

.success-message p {
    font-size: 1.2rem;
    margin-bottom: 2rem;
}


/* ==================
   9. Responsive Design
   ================== */
@media (max-width: 768px) {
    h1, .hero-title { font-size: 2.5rem; }
    h2, .section-title { font-size: 2rem; }

    .content-section, .content-section-dark {
        padding: 60px 0;
    }

    .column, .column.is-two-thirds {
        flex: 0 0 100%;
        margin-bottom: 2rem;
    }

    /* Header */
    .nav-links {
        position: fixed;
        top: 0;
        right: -100%; /* Initially hidden */
        width: 70%;
        height: 100vh;
        background: var(--color-background);
        flex-direction: column;
        justify-content: center;
        align-items: center;
        gap: 40px;
        transition: right 0.4s ease-in-out;
        box-shadow: -10px 0 20px rgba(0,0,0,0.1);
    }
    
    .nav-links.active {
        right: 0;
    }

    .burger-menu {
        display: block;
    }

    .burger-menu.active span:nth-child(1) {
        transform: translateY(8px) rotate(45deg);
    }
    .burger-menu.active span:nth-child(2) {
        opacity: 0;
    }
    .burger-menu.active span:nth-child(3) {
        transform: translateY(-8px) rotate(-45deg);
    }

    /* Hero */
    .biomorphic-shape { display: none; }

    /* Slider */
    .slider-controls { padding: 0; }
    .slider-prev, .slider-next { width: 40px; height: 40px; font-size: 1.5rem; }
}