/* =========================================================
   SADRIAA AGRICOLE — Feuille de style principale
   Palette inspirée du logo : vert profond, vert prairie, or,
   crème. Signature visuelle : anneau orbital animé (globe +
   avion du logo) et feuilles flottantes en arrière-plan.
   ========================================================= */

:root {
    --dark-green: #0f2a1e;
    --green: #1b4332;
    --green-mid: #2d6a4f;
    --green-light: #52b788;
    --gold: #c9a227;
    --gold-light: #e6c65c;
    --cream: #f7f5ee;
    --paper: #ffffff;
    --text: #172a20;
    --text-soft: #4b5c52;
    --shadow: 0 20px 45px rgba(15, 42, 30, 0.12);
    --radius: 14px;
    --font-display: 'Fraunces', 'Playfair Display', Georgia, serif;
    --font-body: 'Manrope', 'Segoe UI', Arial, sans-serif;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }

body {
    margin: 0;
    font-family: var(--font-body);
    color: var(--text);
    background: var(--cream);
    line-height: 1.65;
    overflow-x: hidden;
}

h1, h2, h3, h4 {
    font-family: var(--font-display);
    color: var(--green);
    margin: 0 0 .6em;
    line-height: 1.15;
    font-weight: 600;
}

p { margin: 0 0 1em; color: var(--text-soft); }
a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }
.container { max-width: 1180px; margin: 0 auto; padding: 0 1.5rem; }

/* ---------- Arrière-plan animé ambiant ---------- */
#leaf-canvas {
    position: fixed;
    inset: 0;
    z-index: 0;
    pointer-events: none;
    opacity: .55;
}

.bg-glow {
    position: fixed;
    inset: 0;
    z-index: 0;
    pointer-events: none;
    background:
        radial-gradient(600px 400px at 15% 20%, rgba(82,183,136,.15), transparent 60%),
        radial-gradient(700px 500px at 85% 75%, rgba(201,162,39,.14), transparent 60%);
    animation: drift 18s ease-in-out infinite alternate;
}

@keyframes drift {
    0%   { transform: translate(0,0) scale(1); }
    100% { transform: translate(-2%, 2%) scale(1.05); }
}

/* ---------- En-tête / navigation ---------- */
header.site-header {
    position: sticky;
    top: 0;
    z-index: 50;
    background: rgba(255,255,255,.85);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid rgba(27,67,50,.08);
}

.nav-wrap {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: .7rem 1.5rem;
    max-width: 1180px;
    margin: 0 auto;
}

.brand { display: flex; align-items: center; gap: .6rem; }
.brand img { height: 48px; width: auto; }
.brand-text { font-family: var(--font-display); font-weight: 700; color: var(--green); font-size: 1.15rem; letter-spacing: .5px; }
.brand-text span { display:block; font-family: var(--font-body); font-weight: 500; font-size: .65rem; letter-spacing: 2px; color: var(--gold); text-transform: uppercase; }

nav.main-nav { display: flex; gap: 1.6rem; }
nav.main-nav a {
    font-weight: 600;
    font-size: .92rem;
    color: var(--text);
    position: relative;
    padding: .3rem 0;
    transition: color .2s;
}
nav.main-nav a::after {
    content: '';
    position: absolute; left: 0; bottom: -4px;
    width: 0; height: 2px; background: var(--gold);
    transition: width .25s ease;
}
nav.main-nav a:hover, nav.main-nav a.active { color: var(--green); }
nav.main-nav a:hover::after, nav.main-nav a.active::after { width: 100%; }

.burger { display: none; background: none; border: 0; font-size: 1.6rem; color: var(--green); cursor: pointer; }

@media (max-width: 880px) {
    nav.main-nav {
        position: fixed; inset: 0 0 0 auto; top: 0;
        height: 100vh; width: 260px;
        background: var(--green);
        flex-direction: column;
        padding: 5rem 2rem;
        gap: 1.4rem;
        transform: translateX(100%);
        transition: transform .3s ease;
    }
    nav.main-nav.open { transform: translateX(0); }
    nav.main-nav a { color: #fff; }
    nav.main-nav a:hover, nav.main-nav a.active { color: var(--gold-light); }
    .burger { display: block; }
}

/* ---------- Hero ---------- */
.hero {
    position: relative;
    padding: 5.5rem 0 6rem;
    text-align: center;
    overflow: hidden;
}

.orbit-wrap {
    position: absolute;
    top: 50%; left: 50%;
    width: 640px; height: 640px;
    transform: translate(-50%, -50%);
    z-index: 0;
    opacity: .35;
}
.orbit-ring {
    position: absolute; inset: 0;
    border-radius: 50%;
    border: 2px solid transparent;
    border-top-color: var(--green-light);
    border-right-color: var(--gold);
    animation: spin 22s linear infinite;
}
.orbit-ring.r2 { inset: 40px; border-top-color: var(--gold); border-right-color: transparent; border-left-color: var(--green-light); animation-duration: 30s; animation-direction: reverse; }
@keyframes spin { to { transform: rotate(360deg); } }

.hero-content { position: relative; z-index: 2; max-width: 720px; margin: 0 auto; }
.eyebrow {
    display: inline-block;
    font-size: .75rem; letter-spacing: 3px; text-transform: uppercase;
    color: var(--gold); font-weight: 700; margin-bottom: 1rem;
}
.hero h1 { font-size: clamp(2.2rem, 5vw, 3.6rem); }
.hero p.lead { font-size: 1.15rem; max-width: 560px; margin: 1rem auto 2rem; }

.btn {
    display: inline-flex; align-items: center; gap: .5rem;
    padding: .85rem 1.6rem;
    border-radius: 999px;
    font-weight: 700;
    font-size: .95rem;
    cursor: pointer;
    border: 2px solid transparent;
    transition: transform .2s, box-shadow .2s;
}
.btn:hover { transform: translateY(-2px); }
.btn-primary { background: var(--green); color: #fff; box-shadow: 0 10px 25px rgba(27,67,50,.3); }
.btn-primary:hover { box-shadow: 0 14px 30px rgba(27,67,50,.4); }
.btn-gold { background: var(--gold); color: #1b2a1c; box-shadow: 0 10px 25px rgba(201,162,39,.35); }
.btn-outline { background: transparent; border-color: var(--green); color: var(--green); }
.btn-whatsapp { background: #25D366; color: #fff; }
.btn-row { display: flex; gap: 1rem; justify-content: center; flex-wrap: wrap; }

/* ---------- Sections génériques ---------- */
section { position: relative; z-index: 1; padding: 4.5rem 0; }
section.alt { background: var(--paper); }
.section-head { text-align: center; max-width: 640px; margin: 0 auto 3rem; }
.section-head .eyebrow { display:block; }

.grid-3 { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px,1fr)); gap: 1.8rem; }
.grid-2 { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px,1fr)); gap: 2rem; align-items: center; }

.card {
    background: var(--paper);
    border-radius: var(--radius);
    padding: 2rem 1.6rem;
    box-shadow: var(--shadow);
    border: 1px solid rgba(27,67,50,.06);
    transition: transform .25s ease, box-shadow .25s ease;
}
.card:hover { transform: translateY(-6px); box-shadow: 0 26px 55px rgba(15,42,30,.16); }
.card .icon {
    width: 56px; height: 56px; border-radius: 50%;
    background: linear-gradient(135deg, var(--green), var(--green-mid));
    display: flex; align-items: center; justify-content: center;
    color: #fff; font-size: 1.4rem; margin-bottom: 1.1rem;
}
.card.gold .icon { background: linear-gradient(135deg, var(--gold), var(--gold-light)); color: #3a2e05; }

.divider-gold {
    width: 70px; height: 3px; background: var(--gold);
    margin: .8rem auto 1.6rem; border-radius: 3px;
}

/* ---------- Galerie ---------- */
.gallery-grid {
    display: grid; grid-template-columns: repeat(auto-fill, minmax(240px,1fr));
    gap: 1.2rem;
}
.gallery-item {
    position: relative; overflow: hidden; border-radius: var(--radius);
    box-shadow: var(--shadow); aspect-ratio: 4/3;
}
.gallery-item img { width: 100%; height: 100%; object-fit: cover; transition: transform .4s; }
.gallery-item:hover img { transform: scale(1.08); }
.gallery-cap {
    position: absolute; left:0; right:0; bottom:0;
    background: linear-gradient(0deg, rgba(15,42,30,.85), transparent);
    color: #fff; padding: .9rem .8rem .6rem; font-size: .85rem; font-weight: 600;
}

/* ---------- Actualités ---------- */
.news-card { display: flex; flex-direction: column; overflow: hidden; padding: 0; }
.news-card img { height: 190px; object-fit: cover; width: 100%; }
.news-body { padding: 1.4rem 1.5rem 1.8rem; }
.news-date { font-size: .78rem; color: var(--gold); font-weight: 700; letter-spacing: 1px; text-transform: uppercase; margin-bottom: .4rem; }

/* ---------- Contact ---------- */
.contact-wrap { display: grid; grid-template-columns: 1.1fr .9fr; gap: 2.5rem; align-items: start; }
@media (max-width: 880px) { .contact-wrap { grid-template-columns: 1fr; } }
.form-group { margin-bottom: 1.1rem; }
.form-group label { display: block; font-weight: 700; font-size: .85rem; margin-bottom: .4rem; color: var(--green); }
.form-group input, .form-group textarea {
    width: 100%; padding: .8rem .9rem; border-radius: 8px;
    border: 1.5px solid #d8d8d0; font-family: var(--font-body); font-size: .95rem;
    background: #fff;
}
.form-group input:focus, .form-group textarea:focus { outline: none; border-color: var(--green-light); }
.contact-info-card { background: var(--green); color: #fff; border-radius: var(--radius); padding: 2.2rem; }
.contact-info-card h3 { color: #fff; }
.contact-info-card .item { display: flex; gap: .8rem; margin-bottom: 1.2rem; align-items: flex-start; }
.contact-info-card .item .ic { color: var(--gold-light); font-size: 1.1rem; margin-top: .1rem; }
.alert { padding: .9rem 1.1rem; border-radius: 8px; margin-bottom: 1.2rem; font-weight: 600; }
.alert-success { background: #e6f4ea; color: #1b4332; border: 1px solid #b7dfc2; }
.alert-error { background: #fdeceb; color: #a4161a; border: 1px solid #f3c1bd; }

/* ---------- WhatsApp flottant ---------- */
.wa-float {
    position: fixed; bottom: 22px; right: 22px; z-index: 90;
    background: #25D366; color: #fff; width: 60px; height: 60px;
    border-radius: 50%; display: flex; align-items: center; justify-content: center;
    box-shadow: 0 12px 30px rgba(37,211,102,.5);
    font-size: 1.7rem;
    animation: pulse 2.4s ease-in-out infinite;
}
@keyframes pulse {
    0%,100% { box-shadow: 0 12px 30px rgba(37,211,102,.5); }
    50% { box-shadow: 0 12px 30px rgba(37,211,102,.85), 0 0 0 10px rgba(37,211,102,.12); }
}

/* ---------- Footer ---------- */
footer.site-footer {
    background: var(--dark-green); color: #d8e6dd;
    padding: 3.5rem 0 1.6rem; position: relative; z-index: 1;
}
footer.site-footer h4 { color: #fff; font-size: 1rem; }
footer.site-footer a:hover { color: var(--gold-light); }
.footer-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px,1fr)); gap: 2rem; margin-bottom: 2.2rem; }
.footer-bottom { border-top: 1px solid rgba(255,255,255,.1); padding-top: 1.2rem; text-align: center; font-size: .82rem; color: #9db3a5; }

/* ---------- Utilitaires ---------- */
.text-center { text-align: center; }
.mt-2 { margin-top: 2rem; }
.badge { display:inline-block; background: rgba(201,162,39,.15); color: var(--gold); font-weight:700; font-size:.72rem; letter-spacing:1px; text-transform:uppercase; padding:.3rem .8rem; border-radius:999px; }

@media (prefers-reduced-motion: reduce) {
    * { animation-duration: .001ms !important; animation-iteration-count: 1 !important; transition-duration: .001ms !important; }
}
