/* ======================================
   La Maison de l'Espoir - Styles
   ====================================== */

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

:root {
    --color-primary: #2E7D4F;
    --color-primary-dark: #1B5E35;
    --color-primary-light: #E8F5E9;
    --color-accent: #E8892F;
    --color-accent-dark: #D4751A;
    --color-text: #2C2C2C;
    --color-text-light: #5A5A5A;
    --color-bg: #FFFFFF;
    --color-bg-alt: #F7F5F2;
    --color-bg-dark: #1A2E1A;
    --font-heading: 'Georgia', 'Times New Roman', serif;
    --font-body: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    --max-width: 1200px;
    --radius: 8px;
    --shadow: 0 2px 12px rgba(0,0,0,0.08);
    --shadow-lg: 0 8px 30px rgba(0,0,0,0.12);
    --transition: 0.3s ease;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-body);
    color: var(--color-text);
    background: var(--color-bg);
    line-height: 1.7;
    font-size: 16px;
    zoom: 0.85;
    -webkit-font-smoothing: antialiased;
}

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

a {
    color: var(--color-primary);
    text-decoration: none;
    transition: color var(--transition);
}

a:hover {
    color: var(--color-primary-dark);
}

.container {
    max-width: var(--max-width);
    margin: 0 auto;
    padding: 0 24px;
}

/* --- Navigation --- */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    background: transparent;
    transition: all var(--transition);
    padding: 16px 0;
}

.navbar.scrolled {
    background: rgba(255,255,255,0.97);
    box-shadow: var(--shadow);
    padding: 8px 0;
}

.nav-container {
    max-width: var(--max-width);
    margin: 0 auto;
    padding: 0 24px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.nav-logo {
    font-family: var(--font-heading);
    font-size: 1.3rem;
    font-weight: 700;
    color: #fff;
    transition: color var(--transition);
}

.navbar.scrolled .nav-logo {
    color: var(--color-primary-dark);
}

.nav-menu {
    display: flex;
    list-style: none;
    gap: 8px;
    align-items: center;
}

.nav-menu a {
    color: rgba(255,255,255,0.9);
    font-size: 0.9rem;
    font-weight: 500;
    padding: 8px 14px;
    border-radius: var(--radius);
    transition: all var(--transition);
    white-space: nowrap;
}

.navbar.scrolled .nav-menu a {
    color: var(--color-text);
}

.nav-menu a:hover {
    background: rgba(255,255,255,0.15);
    color: #fff;
}

.navbar.scrolled .nav-menu a:hover {
    background: var(--color-primary-light);
    color: var(--color-primary-dark);
}

.nav-cta {
    background: var(--color-accent) !important;
    color: #fff !important;
    font-weight: 600 !important;
    border-radius: var(--radius) !important;
    white-space: nowrap;
}

.nav-cta:hover {
    background: var(--color-accent-dark) !important;
}

.nav-toggle {
    display: none;
    flex-direction: column;
    gap: 5px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 8px;
}

.nav-toggle span {
    width: 24px;
    height: 2px;
    background: #fff;
    transition: all var(--transition);
}

.navbar.scrolled .nav-toggle span {
    background: var(--color-text);
}

/* --- Hero --- */
.hero {
    position: relative;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    text-align: center;
    overflow: hidden;
}

.hero::before {
    content: '';
    position: absolute;
    inset: -10px;
    background: url('../images/repas-solidaire.jpg') center/cover no-repeat;
    filter: blur(4px);
    z-index: 0;
}

.hero-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(
        135deg,
        rgba(27, 94, 53, 0.85) 0%,
        rgba(26, 46, 26, 0.8) 100%
    );
    z-index: 1;
}

.hero-content {
    position: relative;
    z-index: 2;
    max-width: 800px;
    padding: 0 24px;
}

.hero h1 {
    font-family: var(--font-heading);
    font-size: clamp(2.5rem, 6vw, 4rem);
    font-weight: 700;
    margin-bottom: 16px;
    line-height: 1.15;
}

.hero-subtitle {
    font-size: clamp(1.1rem, 2.5vw, 1.4rem);
    margin-bottom: 12px;
    opacity: 0.95;
    font-weight: 300;
}

.hero-tagline {
    font-size: 1.05rem;
    opacity: 0.85;
    margin-bottom: 36px;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

.hero-actions {
    display: flex;
    gap: 16px;
    justify-content: center;
    flex-wrap: wrap;
}

/* --- Buttons --- */
.btn {
    display: inline-block;
    padding: 14px 32px;
    font-size: 1rem;
    font-weight: 600;
    border-radius: var(--radius);
    transition: all var(--transition);
    cursor: pointer;
    border: 2px solid transparent;
    text-align: center;
}

.btn-primary {
    background: var(--color-accent);
    color: #fff;
    border-color: var(--color-accent);
}

.btn-primary:hover {
    background: var(--color-accent-dark);
    border-color: var(--color-accent-dark);
    color: #fff;
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(232,137,47,0.4);
}

.btn-secondary {
    background: rgba(255,255,255,0.15);
    color: #fff;
    border-color: rgba(255,255,255,0.5);
}

.btn-secondary:hover {
    background: rgba(255,255,255,0.25);
    color: #fff;
}

.btn-outline {
    background: transparent;
    color: #fff;
    border-color: rgba(255,255,255,0.6);
}

.btn-outline:hover {
    background: rgba(255,255,255,0.1);
    border-color: #fff;
    color: #fff;
}

/* --- Stats --- */
.stats {
    background: var(--color-primary);
    color: #fff;
    padding: 48px 0;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 32px;
    text-align: center;
}

.stat-item {
    opacity: 0;
    transform: translateY(20px);
    transition: all 0.5s ease;
}

.stat-item.visible {
    opacity: 1;
    transform: translateY(0);
}

.stat-number {
    display: block;
    font-family: var(--font-heading);
    font-size: 3rem;
    font-weight: 700;
    line-height: 1.1;
}

.stat-label {
    font-size: 0.9rem;
    opacity: 0.9;
    margin-top: 4px;
    display: block;
}

/* --- Sections --- */
.section {
    padding: 96px 0;
}

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

.section-title {
    font-family: var(--font-heading);
    font-size: clamp(1.8rem, 3.5vw, 2.5rem);
    color: var(--color-primary-dark);
    margin-bottom: 16px;
    text-align: center;
}

.section-title-left {
    text-align: left;
}

.section-title-light {
    color: #fff;
}

.section-intro {
    text-align: center;
    font-size: 1.1rem;
    color: var(--color-text-light);
    max-width: 700px;
    margin: 0 auto 48px;
    line-height: 1.8;
}

.section-intro-light {
    color: rgba(255,255,255,0.85);
}

.section-note {
    text-align: center;
    font-size: 0.95rem;
    color: var(--color-text-light);
    margin-top: 40px;
    font-style: italic;
}

/* --- Objectives List --- */
.objectives-list {
    list-style: none;
    max-width: 700px;
    margin: 8px auto 0;
}

.objectives-list li {
    position: relative;
    padding: 14px 0 14px 32px;
    font-size: 1.05rem;
    line-height: 1.7;
    color: var(--color-text);
    border-bottom: 1px solid #e8e4df;
}

.objectives-list li:last-child {
    border-bottom: none;
}

.objectives-list li::before {
    content: '';
    position: absolute;
    left: 0;
    top: 22px;
    width: 10px;
    height: 10px;
    background: var(--color-primary);
    border-radius: 50%;
}

/* --- Timeline --- */
.timeline {
    position: relative;
    max-width: 800px;
    margin: 48px auto 0;
    padding-left: 40px;
}

.timeline::before {
    content: '';
    position: absolute;
    left: 8px;
    top: 0;
    bottom: 0;
    width: 3px;
    background: var(--color-primary);
    border-radius: 2px;
}

.timeline-item {
    position: relative;
    margin-bottom: 40px;
    opacity: 0;
    transform: translateX(-20px);
    transition: all 0.5s ease;
}

.timeline-item.visible {
    opacity: 1;
    transform: translateX(0);
}

.timeline-item::before {
    content: '';
    position: absolute;
    left: -36px;
    top: 6px;
    width: 14px;
    height: 14px;
    background: var(--color-primary);
    border: 3px solid #fff;
    border-radius: 50%;
    box-shadow: 0 0 0 3px var(--color-primary);
}

.timeline-item:last-child::before {
    background: var(--color-accent);
    box-shadow: 0 0 0 3px var(--color-accent);
}

.timeline-date {
    font-size: 0.85rem;
    font-weight: 700;
    color: var(--color-primary);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 4px;
}

.timeline-item:last-child .timeline-date {
    color: var(--color-accent);
}

.timeline-content h3 {
    font-family: var(--font-heading);
    font-size: 1.15rem;
    margin-bottom: 4px;
    color: var(--color-text);
}

.timeline-content p {
    color: var(--color-text-light);
    font-size: 0.95rem;
}

/* --- Features Grid (La Maison) --- */
.maison-intro {
    text-align: center;
    max-width: 750px;
    margin: 0 auto 48px;
    font-size: 1.1rem;
    color: var(--color-text-light);
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 32px;
}

.feature-card {
    border-radius: var(--radius);
    overflow: hidden;
    background: #fff;
    box-shadow: var(--shadow);
    transition: all 0.5s ease;
    opacity: 0;
    transform: translateY(30px);
}

.feature-card.visible {
    opacity: 1;
    transform: translateY(0);
}

.feature-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-lg);
}

.feature-card img {
    width: 100%;
    height: 220px;
    object-fit: cover;
}

img.blur {
    filter: blur(3px);
}

.feature-text {
    padding: 24px;
}

.feature-text h3 {
    font-family: var(--font-heading);
    font-size: 1.15rem;
    margin-bottom: 8px;
    color: var(--color-primary-dark);
}

.feature-text p {
    font-size: 0.95rem;
    color: var(--color-text-light);
}

/* --- Projet --- */
.projet-layout {
    display: grid;
    grid-template-columns: 1.2fr 0.8fr;
    gap: 64px;
    align-items: center;
}

.projet-highlight {
    font-family: var(--font-heading);
    font-size: 1.4rem;
    color: var(--color-primary-dark);
    margin-bottom: 20px;
    line-height: 1.5;
}

.projet-text p {
    margin-bottom: 16px;
    color: var(--color-text-light);
}

.projet-cost {
    margin-top: 28px;
    padding: 20px 24px;
    background: var(--color-primary-light);
    border-left: 4px solid var(--color-primary);
    border-radius: 0 var(--radius) var(--radius) 0;
}

.projet-cost-amount {
    display: block;
    font-family: var(--font-heading);
    font-size: 1.8rem;
    font-weight: 700;
    color: var(--color-primary-dark);
}

.projet-cost-label {
    font-size: 0.9rem;
    color: var(--color-text-light);
}

.projet-image img {
    border-radius: var(--radius);
    box-shadow: var(--shadow-lg);
}

/* --- Activités --- */
.activites-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 32px;
}

.activite-card {
    border-radius: var(--radius);
    overflow: hidden;
    background: #fff;
    box-shadow: var(--shadow);
    transition: all 0.5s ease;
    opacity: 0;
    transform: translateY(30px);
}

.activite-card.visible {
    opacity: 1;
    transform: translateY(0);
}

.activite-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-lg);
}

.activite-card img {
    width: 100%;
    height: 200px;
    object-fit: cover;
}

.activite-text {
    padding: 20px;
}

.activite-text h3 {
    font-family: var(--font-heading);
    font-size: 1.1rem;
    margin-bottom: 8px;
    color: var(--color-primary-dark);
}

.activite-text p {
    font-size: 0.9rem;
    color: var(--color-text-light);
}

/* --- Presse --- */
.presse-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
    margin-top: 32px;
}

.presse-card {
    background: #fff;
    border-radius: var(--radius);
    padding: 28px;
    box-shadow: var(--shadow);
    transition: all 0.5s ease;
    display: block;
    color: var(--color-text);
    opacity: 0;
    transform: translateY(20px);
}

.presse-card.visible {
    opacity: 1;
    transform: translateY(0);
}

.presse-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-lg);
    color: var(--color-text);
}

.presse-source {
    display: inline-block;
    font-size: 0.8rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--color-accent);
    margin-bottom: 8px;
}

.presse-card p {
    font-size: 0.95rem;
    line-height: 1.6;
}

/* --- CTA / Soutenir --- */
.section-cta {
    background: linear-gradient(135deg, var(--color-primary-dark) 0%, var(--color-primary) 100%);
    color: #fff;
}

.soutenir-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 32px;
    margin-bottom: 40px;
}

.soutenir-card {
    background: rgba(255,255,255,0.1);
    border: 1px solid rgba(255,255,255,0.2);
    border-radius: var(--radius);
    padding: 36px 28px;
    text-align: center;
    transition: all 0.5s ease;
    opacity: 0;
    transform: translateY(30px);
}

.soutenir-card.visible {
    opacity: 1;
    transform: translateY(0);
}

.soutenir-card:hover {
    background: rgba(255,255,255,0.15);
    transform: translateY(-4px);
}

.soutenir-icon {
    width: 48px;
    height: 48px;
    margin: 0 auto 20px;
    color: var(--color-accent);
}

.soutenir-icon svg {
    width: 100%;
    height: 100%;
}

.soutenir-card h3 {
    font-family: var(--font-heading);
    font-size: 1.2rem;
    margin-bottom: 12px;
}

.soutenir-card p {
    font-size: 0.95rem;
    opacity: 0.85;
    margin-bottom: 24px;
    line-height: 1.7;
}

.soutenir-card .btn {
    width: 100%;
}

.virement-info {
    text-align: center;
    padding: 20px;
    background: rgba(255,255,255,0.08);
    border-radius: var(--radius);
    font-size: 0.95rem;
    opacity: 0.85;
}

/* --- Footer --- */
.footer {
    background: var(--color-bg-dark);
    color: rgba(255,255,255,0.85);
    padding: 64px 0 32px;
}

.footer-grid {
    display: grid;
    grid-template-columns: 1.2fr 1fr 0.8fr;
    gap: 48px;
    margin-bottom: 48px;
}

.footer h3 {
    font-family: var(--font-heading);
    font-size: 1.1rem;
    color: #fff;
    margin-bottom: 16px;
}

.footer p {
    font-size: 0.9rem;
    line-height: 1.7;
}

.footer-address {
    margin-top: 12px;
    font-style: normal;
}

.footer-contact {
    list-style: none;
}

.footer-contact li {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 12px;
    font-size: 0.9rem;
}

.footer-contact li svg {
    width: 18px;
    height: 18px;
    flex-shrink: 0;
    opacity: 0.7;
}

.footer-contact a {
    color: rgba(255,255,255,0.85);
    word-break: break-all;
}

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

.footer-social {
    display: flex;
    gap: 12px;
    margin-bottom: 16px;
}

.footer-social a {
    width: 42px;
    height: 42px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: rgba(255,255,255,0.1);
    color: #fff;
    transition: all var(--transition);
}

.footer-social a:hover {
    background: var(--color-accent);
    transform: translateY(-2px);
}

.footer-social svg {
    width: 20px;
    height: 20px;
}

.footer-helloasso a {
    color: var(--color-accent);
    font-size: 0.9rem;
    font-weight: 600;
}

.footer-helloasso a:hover {
    text-decoration: underline;
}

.footer-bottom {
    border-top: 1px solid rgba(255,255,255,0.1);
    padding-top: 24px;
    text-align: center;
    font-size: 0.85rem;
    opacity: 0.6;
}

/* --- Legal Page --- */
.legal-page {
    padding: 120px 0 64px;
}

.legal-page h1 {
    font-family: var(--font-heading);
    font-size: clamp(1.8rem, 3.5vw, 2.5rem);
    color: var(--color-primary-dark);
    margin-bottom: 40px;
}

.legal-page section {
    margin-bottom: 36px;
}

.legal-page h2 {
    font-family: var(--font-heading);
    font-size: 1.3rem;
    color: var(--color-primary-dark);
    margin-bottom: 12px;
    padding-bottom: 8px;
    border-bottom: 2px solid var(--color-primary-light);
}

.legal-page p {
    color: var(--color-text-light);
    margin-bottom: 12px;
    font-size: 0.95rem;
}

.legal-page a {
    color: var(--color-primary);
}

.legal-page a:hover {
    text-decoration: underline;
}

.footer-bottom a {
    color: rgba(255,255,255,0.7);
}

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

/* --- Responsive --- */
@media (max-width: 968px) {
    .objectives-grid,
    .features-grid {
        grid-template-columns: 1fr;
    }

    .projet-layout {
        grid-template-columns: 1fr;
        gap: 40px;
    }

    .projet-image {
        order: -1;
    }

    .activites-grid,
    .presse-grid,
    .soutenir-grid {
        grid-template-columns: 1fr;
        max-width: 500px;
        margin-left: auto;
        margin-right: auto;
    }

    .soutenir-grid {
        margin-bottom: 32px;
    }

    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 24px;
    }

    .footer-grid {
        grid-template-columns: 1fr;
        gap: 32px;
    }
}

@media (max-width: 768px) {
    .nav-toggle {
        display: flex;
    }

    .nav-menu {
        position: fixed;
        top: 0;
        right: -100%;
        width: 280px;
        height: 100vh;
        background: var(--color-bg-dark);
        flex-direction: column;
        padding: 80px 32px 32px;
        gap: 4px;
        transition: right var(--transition);
        box-shadow: -4px 0 20px rgba(0,0,0,0.2);
    }

    .nav-menu.active {
        right: 0;
    }

    .nav-menu a {
        color: rgba(255,255,255,0.85) !important;
        padding: 12px 16px;
        font-size: 1rem;
    }

    .nav-menu a:hover {
        background: rgba(255,255,255,0.1) !important;
        color: #fff !important;
    }

    .section {
        padding: 64px 0;
    }

    .section-title {
        margin-bottom: 12px;
    }

    .section-intro {
        margin-bottom: 36px;
    }

    .hero {
        min-height: 90vh;
    }

    .feature-card img,
    .activite-card img {
        height: 180px;
    }
}

@media (max-width: 480px) {
    .stats-grid {
        grid-template-columns: 1fr 1fr;
        gap: 16px;
    }

    .stat-number {
        font-size: 2.2rem;
    }

    .hero-actions {
        flex-direction: column;
        align-items: center;
    }

    .btn {
        width: 100%;
        max-width: 280px;
    }
}
