/* ============================================================
   BELHASSAN AGRO — Feuille de style
   Mobile-first • Responsive • Support RTL (arabe)
   Palette : vert frais + accents orange/jaune sur fond clair
   ============================================================ */

/* ---------- 1. Variables ---------- */
:root {
  --green: #1f8a3b;
  --green-dark: #15331f;
  --green-600: #197a34;
  --green-light: #a7e05a;
  --green-bg: #eafbe7;
  --orange: #ff8c1a;
  --orange-dark: #e67300;
  --yellow: #ffd24d;

  --ink: #15331f;
  --text: #2c3a31;
  --muted: #5d6b62;
  --line: #e4ebe5;
  --bg: #ffffff;
  --bg-alt: #f5faf3;

  --radius: 16px;
  --radius-sm: 10px;
  --shadow: 0 10px 30px rgba(21, 51, 31, .08);
  --shadow-lg: 0 18px 50px rgba(21, 51, 31, .14);

  --font-body: 'Inter', system-ui, -apple-system, 'Segoe UI', Arial, sans-serif;
  --font-head: 'Poppins', 'Inter', system-ui, Arial, sans-serif;

  --maxw: 1180px;
  --header-h: 76px;
}

/* Police arabe quand <html lang="ar"> */
html[lang="ar"] {
  --font-body: 'Cairo', 'Inter', system-ui, Arial, sans-serif;
  --font-head: 'Cairo', 'Poppins', system-ui, Arial, sans-serif;
}

/* ---------- 2. Reset ---------- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; scroll-padding-top: var(--header-h); -webkit-text-size-adjust: 100%; }
body {
  font-family: var(--font-body);
  color: var(--text);
  background: var(--bg);
  line-height: 1.65;
  font-size: 16px;
  overflow-x: hidden;
}
img, svg, iframe { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
ul { list-style: none; }
button { font-family: inherit; cursor: pointer; border: none; background: none; }
input, textarea, button { font-family: inherit; font-size: 1rem; }
:focus-visible { outline: 3px solid var(--green-light); outline-offset: 2px; border-radius: 4px; }

/* ---------- 3. Layout ---------- */
.container { width: 100%; max-width: var(--maxw); margin-inline: auto; padding-inline: 20px; }
.section { padding: 72px 0; }
.section--alt { background: var(--bg-alt); }

.section__head { text-align: center; max-width: 720px; margin: 0 auto 48px; }
.section__title {
  font-family: var(--font-head);
  font-weight: 700;
  font-size: clamp(1.6rem, 3.6vw, 2.4rem);
  line-height: 1.2;
  color: var(--ink);
  letter-spacing: -.01em;
}
.section__lead { color: var(--muted); margin-top: 14px; font-size: 1.05rem; }
.section__foot { text-align: center; margin-top: 44px; }

.eyebrow {
  display: inline-block;
  font-family: var(--font-head);
  font-weight: 600;
  font-size: .82rem;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--green);
  background: var(--green-bg);
  padding: 6px 14px;
  border-radius: 999px;
  margin-bottom: 14px;
}

/* ---------- 4. Boutons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  font-family: var(--font-head);
  font-weight: 600;
  font-size: .98rem;
  padding: 13px 26px;
  border-radius: 999px;
  transition: transform .18s ease, box-shadow .18s ease, background .18s ease, color .18s ease;
  white-space: nowrap;
}
.btn--sm { padding: 9px 18px; font-size: .9rem; }
.btn--block { width: 100%; }
.btn--primary { background: var(--green); color: #fff; box-shadow: 0 8px 20px rgba(31,138,59,.28); }
.btn--primary:hover { background: var(--green-600); transform: translateY(-2px); box-shadow: 0 12px 26px rgba(31,138,59,.34); }
.btn--ghost { background: #fff; color: var(--green-dark); border: 2px solid var(--line); }
.btn--ghost:hover { border-color: var(--green); color: var(--green); transform: translateY(-2px); }

/* ---------- 5. Header ---------- */
.header {
  position: fixed; inset: 0 0 auto 0; z-index: 1000;
  height: var(--header-h);
  background: rgba(255,255,255,.92);
  backdrop-filter: saturate(160%) blur(10px);
  border-bottom: 1px solid var(--line);
  transition: box-shadow .25s ease;
}
.header.is-scrolled { box-shadow: var(--shadow); }
.header__inner { height: var(--header-h); display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.header__logo img { height: 40px; width: auto; }

.nav { display: flex; align-items: center; gap: 28px; }
.nav__list { display: flex; align-items: center; gap: 6px; }
.nav__link {
  font-weight: 500; font-size: .96rem; color: var(--text);
  padding: 8px 12px; border-radius: 8px; position: relative;
  transition: color .15s ease, background .15s ease;
}
.nav__link:hover, .nav__link.is-active { color: var(--green); background: var(--green-bg); }
.nav__actions { display: flex; align-items: center; gap: 14px; }

.lang-switch { display: flex; gap: 2px; background: var(--bg-alt); border: 1px solid var(--line); border-radius: 999px; padding: 3px; }
.lang-switch__btn {
  font-family: var(--font-head); font-weight: 600; font-size: .82rem;
  padding: 5px 11px; border-radius: 999px; color: var(--muted); line-height: 1;
  transition: background .15s ease, color .15s ease;
}
.lang-switch__btn.is-active { background: var(--green); color: #fff; }

.burger { display: none; flex-direction: column; gap: 5px; padding: 8px; }
.burger span { width: 26px; height: 3px; background: var(--green-dark); border-radius: 3px; transition: transform .3s ease, opacity .3s ease; }
.burger.is-open span:nth-child(1) { transform: translateY(8px) rotate(45deg); }
.burger.is-open span:nth-child(2) { opacity: 0; }
.burger.is-open span:nth-child(3) { transform: translateY(-8px) rotate(-45deg); }

/* ---------- 6. Hero ---------- */
.hero {
  padding-top: calc(var(--header-h) + 48px);
  padding-bottom: 64px;
  background: radial-gradient(1100px 520px at 85% -10%, var(--green-bg) 0%, transparent 60%), var(--bg);
}
.hero__inner { display: grid; grid-template-columns: 1.05fr .95fr; align-items: center; gap: 48px; }
.hero__badge {
  display: inline-block; background: var(--green-bg); color: var(--green);
  font-family: var(--font-head); font-weight: 600; font-size: .85rem;
  padding: 7px 16px; border-radius: 999px; margin-bottom: 20px;
}
.hero__title {
  font-family: var(--font-head); font-weight: 800;
  font-size: clamp(2.1rem, 5vw, 3.4rem); line-height: 1.08;
  color: var(--ink); letter-spacing: -.02em;
}
.hero__subtitle { margin-top: 20px; font-size: 1.12rem; color: var(--muted); max-width: 540px; }
.hero__cta { display: flex; flex-wrap: wrap; gap: 14px; margin-top: 30px; }
.hero__stats { display: flex; gap: 32px; margin-top: 40px; flex-wrap: wrap; }
.hero__stats li { display: flex; flex-direction: column; }
.hero__stats strong { font-family: var(--font-head); font-weight: 800; font-size: 1.6rem; color: var(--green); }
.hero__stats span { font-size: .88rem; color: var(--muted); }
.hero__media img { width: 100%; aspect-ratio: 5 / 4; object-fit: cover; border-radius: var(--radius); filter: drop-shadow(0 24px 40px rgba(21,51,31,.12)); }

/* ---------- 7. À propos ---------- */
.about { display: grid; grid-template-columns: .9fr 1.1fr; gap: 52px; align-items: center; }
.about__media img { width: 100%; aspect-ratio: 16 / 10; object-fit: cover; border-radius: var(--radius); box-shadow: var(--shadow); }
.about__content p { color: var(--muted); margin-top: 16px; }
.about__values { margin-top: 26px; display: grid; gap: 14px; }
.about__values li { display: flex; align-items: flex-start; gap: 12px; }
.about__values .dot { width: 12px; height: 12px; border-radius: 50%; background: var(--orange); margin-top: 7px; flex: 0 0 auto; }
.about__values strong { color: var(--ink); }

/* ---------- 8. Grilles & cartes ---------- */
.grid { display: grid; gap: 26px; }
.grid--4 { grid-template-columns: repeat(4, 1fr); }
.grid--3 { grid-template-columns: repeat(3, 1fr); }

.card {
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius);
  overflow: hidden; transition: transform .22s ease, box-shadow .22s ease, border-color .22s ease;
}
.card:hover { transform: translateY(-6px); box-shadow: var(--shadow-lg); border-color: transparent; }
.card__media { aspect-ratio: 16 / 10; overflow: hidden; background: var(--bg-alt); }
.card__media img { width: 100%; height: 100%; object-fit: cover; }
.card__body { padding: 22px; }
.card__title { font-family: var(--font-head); font-weight: 600; font-size: 1.15rem; color: var(--ink); margin-bottom: 8px; }
.card__body p { color: var(--muted); font-size: .96rem; }

/* ---------- 9. Pourquoi nous (features) ---------- */
.features { margin-top: 8px; }
.feature {
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius);
  padding: 28px 24px; transition: transform .2s ease, box-shadow .2s ease;
}
.feature:hover { transform: translateY(-4px); box-shadow: var(--shadow); }
.feature__icon {
  width: 56px; height: 56px; border-radius: 14px;
  display: grid; place-items: center; margin-bottom: 16px;
  background: var(--green-bg); color: var(--green);
}
.feature__icon svg { width: 28px; height: 28px; }
.feature h3 { font-family: var(--font-head); font-weight: 600; font-size: 1.12rem; color: var(--ink); margin-bottom: 8px; }
.feature p { color: var(--muted); font-size: .96rem; }

/* ---------- 10. Processus (steps) ---------- */
.steps { display: grid; grid-template-columns: repeat(4, 1fr); gap: 26px; position: relative; }
.step { text-align: center; padding: 8px; position: relative; }
.step__num {
  width: 60px; height: 60px; margin: 0 auto 18px; border-radius: 50%;
  display: grid; place-items: center;
  font-family: var(--font-head); font-weight: 800; font-size: 1.4rem; color: #fff;
  background: linear-gradient(135deg, var(--green), var(--green-light));
  box-shadow: 0 10px 22px rgba(31,138,59,.3);
}
.step h3 { font-family: var(--font-head); font-weight: 600; font-size: 1.1rem; color: var(--ink); margin-bottom: 6px; }
.step p { color: var(--muted); font-size: .94rem; }
/* connecteur entre étapes */
.steps .step:not(:last-child)::after {
  content: ""; position: absolute; top: 30px; inset-inline-start: calc(50% + 38px);
  width: calc(100% - 76px); height: 2px;
  background: repeating-linear-gradient(to right, var(--green-light) 0 8px, transparent 8px 16px);
}

/* ---------- 11. Témoignages ---------- */
.quote { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 28px; box-shadow: var(--shadow); }
.quote__stars { color: var(--yellow); letter-spacing: 2px; margin-bottom: 12px; font-size: 1.1rem; }
.quote blockquote { color: var(--text); font-size: 1rem; }
.quote figcaption { margin-top: 18px; display: flex; flex-direction: column; }
.quote figcaption strong { color: var(--ink); font-family: var(--font-head); }
.quote figcaption span { color: var(--muted); font-size: .9rem; }
.disclaimer { text-align: center; color: var(--muted); font-size: .85rem; margin-top: 26px; font-style: italic; }

/* ---------- 12. Contact ---------- */
.contact { display: grid; grid-template-columns: 1fr 1fr; gap: 48px; align-items: start; }
.contact__info p { color: var(--muted); margin-top: 14px; max-width: 460px; }
.contact__list { margin-top: 28px; display: grid; gap: 18px; }
.contact__list li { display: flex; align-items: flex-start; gap: 14px; }
.contact__ic {
  width: 44px; height: 44px; border-radius: 12px; flex: 0 0 auto;
  display: grid; place-items: center; background: var(--green-bg); color: var(--green);
}
.contact__ic svg { width: 22px; height: 22px; }
.contact__label { display: block; font-size: .8rem; color: var(--muted); text-transform: uppercase; letter-spacing: .06em; }
.contact__list a:hover { color: var(--green); }
.contact__map { margin-top: 28px; border-radius: var(--radius); overflow: hidden; border: 1px solid var(--line); box-shadow: var(--shadow); }
.contact__map iframe { width: 100%; height: 240px; border: 0; }

/* ---------- 13. Formulaire ---------- */
.contact__form-wrap { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 32px; box-shadow: var(--shadow-lg); }
.form__row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.form__group { margin-bottom: 16px; display: flex; flex-direction: column; }
.form__group label { font-weight: 600; font-size: .9rem; color: var(--ink); margin-bottom: 6px; }
.form input, .form textarea {
  width: 100%; padding: 12px 14px; border: 1.5px solid var(--line); border-radius: var(--radius-sm);
  background: var(--bg-alt); color: var(--text); transition: border-color .15s ease, background .15s ease;
}
.form input:focus, .form textarea:focus { outline: none; border-color: var(--green); background: #fff; }
.form textarea { resize: vertical; min-height: 120px; }
.form input.is-error, .form textarea.is-error { border-color: #e74c3c; background: #fdecea; }
.form__hint { font-size: .82rem; color: var(--muted); margin-top: 12px; }
.form__status { margin-top: 14px; font-weight: 600; font-size: .95rem; min-height: 1.2em; }
.form__status.is-ok { color: var(--green); }
.form__status.is-err { color: #e74c3c; }
.hp-field { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

/* ---------- 14. Footer ---------- */
.footer { background: var(--green-dark); color: #d8e6da; padding-top: 56px; }
.footer__inner { display: grid; grid-template-columns: 2fr 1fr 1fr; gap: 40px; padding-bottom: 40px; }
.footer__brand img { height: 40px; margin-bottom: 16px; }
.footer__brand p { color: #aec4b3; max-width: 360px; font-size: .95rem; }
.footer__col h4 { font-family: var(--font-head); color: #fff; font-size: 1rem; margin-bottom: 16px; }
.footer__col ul { display: grid; gap: 10px; }
.footer__col a, .footer__col span { color: #aec4b3; font-size: .95rem; transition: color .15s ease; }
.footer__col a:hover { color: var(--green-light); }
.footer__bottom { border-top: 1px solid rgba(255,255,255,.1); padding: 20px 0; }
.footer__bottom p { color: #8fa896; font-size: .88rem; text-align: center; }

/* ---------- 15. WhatsApp flottant ---------- */
.whatsapp-float {
  position: fixed; bottom: 22px; inset-inline-end: 22px; z-index: 1100;
  display: inline-flex; align-items: center; gap: 0;
  background: #25D366; color: #fff;
  border-radius: 999px; padding: 14px;
  box-shadow: 0 10px 26px rgba(37,211,102,.45);
  transition: transform .22s ease, box-shadow .22s ease, padding .22s ease;
  overflow: hidden;
}
.whatsapp-float svg { width: 30px; height: 30px; flex: 0 0 auto; }
.whatsapp-float__label { max-width: 0; opacity: 0; white-space: nowrap; font-weight: 600; transition: max-width .3s ease, opacity .2s ease, margin .3s ease; }
.whatsapp-float:hover { transform: translateY(-3px); box-shadow: 0 14px 32px rgba(37,211,102,.55); }
.whatsapp-float:hover .whatsapp-float__label { max-width: 120px; opacity: 1; margin-inline-start: 10px; margin-inline-end: 6px; }
.whatsapp-float::after {
  content: ""; position: absolute; inset: 0; border-radius: 999px;
  box-shadow: 0 0 0 0 rgba(37,211,102,.55); animation: wa-pulse 2.4s infinite;
}
@keyframes wa-pulse { 0% { box-shadow: 0 0 0 0 rgba(37,211,102,.5); } 70% { box-shadow: 0 0 0 16px rgba(37,211,102,0); } 100% { box-shadow: 0 0 0 0 rgba(37,211,102,0); } }

/* ---------- 16. Retour en haut ---------- */
.to-top {
  position: fixed; bottom: 90px; inset-inline-end: 26px; z-index: 1090;
  width: 46px; height: 46px; border-radius: 50%;
  background: #fff; color: var(--green); border: 1px solid var(--line);
  display: grid; place-items: center; box-shadow: var(--shadow);
  opacity: 0; visibility: hidden; transform: translateY(10px);
  transition: opacity .25s ease, transform .25s ease, visibility .25s;
}
.to-top svg { width: 22px; height: 22px; }
.to-top.is-visible { opacity: 1; visibility: visible; transform: translateY(0); }
.to-top:hover { background: var(--green); color: #fff; }

/* ---------- 17. Animations au scroll ---------- */
.reveal { opacity: 0; transform: translateY(24px); transition: opacity .6s ease, transform .6s ease; }
.reveal.is-visible { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  * { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
  .reveal { opacity: 1; transform: none; }
}

/* ============================================================
   18. SUPPORT RTL (arabe)
   ============================================================ */
html[dir="rtl"] body { text-align: right; }
html[dir="rtl"] .hero__subtitle, html[dir="rtl"] .contact__info p { margin-inline: 0; }
html[dir="rtl"] .lang-switch__btn { font-size: .9rem; }
html[dir="rtl"] .nav__link { font-size: 1rem; }
/* le connecteur des étapes est géré par les propriétés logiques (inset-inline-start) */

/* ============================================================
   19. RESPONSIVE
   ============================================================ */
@media (max-width: 1024px) {
  .grid--4 { grid-template-columns: repeat(2, 1fr); }
  .steps { grid-template-columns: repeat(2, 1fr); gap: 32px; }
  .steps .step::after { display: none; }
  .hero__inner { gap: 32px; }
}

@media (max-width: 860px) {
  .nav {
    position: fixed; inset: var(--header-h) 0 auto 0;
    flex-direction: column; align-items: stretch; gap: 0;
    background: #fff; border-bottom: 1px solid var(--line);
    padding: 12px 20px 22px; box-shadow: var(--shadow-lg);
    transform: translateY(-130%); transition: transform .32s ease; max-height: calc(100vh - var(--header-h)); overflow-y: auto;
  }
  .nav.is-open { transform: translateY(0); }
  .nav__list { flex-direction: column; align-items: stretch; gap: 2px; }
  .nav__link { padding: 12px 14px; border-radius: 10px; }
  .nav__actions { flex-direction: column; align-items: stretch; gap: 14px; margin-top: 14px; }
  .lang-switch { justify-content: center; }
  .burger { display: flex; }

  .hero__inner { grid-template-columns: 1fr; text-align: center; }
  .hero__media { order: -1; max-width: 460px; margin-inline: auto; }
  .hero__cta, .hero__stats { justify-content: center; }
  .hero__subtitle { margin-inline: auto; }

  .about { grid-template-columns: 1fr; gap: 32px; }
  .about__media { max-width: 460px; margin-inline: auto; }
  .contact { grid-template-columns: 1fr; gap: 36px; }
  .footer__inner { grid-template-columns: 1fr 1fr; gap: 28px; }
  .footer__brand { grid-column: 1 / -1; }
}

@media (max-width: 560px) {
  .section { padding: 54px 0; }
  .grid--4, .grid--3, .steps { grid-template-columns: 1fr; }
  .form__row { grid-template-columns: 1fr; }
  .hero__stats { gap: 22px; }
  .hero__stats strong { font-size: 1.35rem; }
  .footer__inner { grid-template-columns: 1fr; }
  .contact__form-wrap { padding: 22px; }
  .whatsapp-float { bottom: 16px; inset-inline-end: 16px; }
  .to-top { bottom: 84px; inset-inline-end: 18px; }
}

/* ============================================================
   20. HARMONISATION AVEC LE LOGO (bleu marine + or)
   ============================================================ */
.header__logo { display:flex; align-items:center; gap:11px; text-decoration:none; }
.brand-badge { width:50px; height:50px; border-radius:50%; flex:0 0 auto; box-shadow:0 3px 9px rgba(15,37,70,.28); }
.brand-text { display:flex; flex-direction:column; line-height:1.05; }
.brand-text .bt-1 { font-family:var(--font-head); font-weight:800; font-size:1.12rem; color:#16315c; letter-spacing:.3px; }
.brand-text .bt-1 b { color:#bd9620; font-weight:800; }
.brand-text .bt-2 { font-size:.6rem; letter-spacing:2.4px; text-transform:uppercase; color:#bd9620; font-weight:700; margin-top:3px; }
html[dir="rtl"] .brand-text { text-align:right; }

/* Accent doré (eyebrow) + chip hero marine/or */
.eyebrow { background:rgba(201,162,39,.14); color:#9a7d18; }
.hero__badge { background:rgba(22,49,92,.07); color:#16315c; border:1px solid rgba(201,162,39,.5); }

/* Titres en bleu marine pour matcher le logo */
.section__title, .hero__title { color:#16315c; }

/* Pied de page marine */
.footer { background:linear-gradient(185deg,#16315c,#0f2546); }
.footer__brand p { color:#aebfd6; }
.footer__brand img { height:70px; width:70px; }
.footer__col h4 { color:#e0c25a; }
.footer__col a, .footer__col span { color:#c2cfe4; }
.footer__col a:hover { color:#e0c25a; }
.footer__bottom { border-top:1px solid rgba(255,255,255,.10); }
.footer__bottom p { color:#8ea2c2; }

/* Bouton secondaire : survol doré subtil */
.btn--ghost:hover { border-color:#c9a227; color:#16315c; }

@media (max-width:560px){ .brand-text .bt-1 { font-size:1rem; } .brand-badge{width:44px;height:44px} }

/* Taille du badge 