/* =========================================================================
   SIL ENERGY Company — feuille de style
   Palette reprise des emballages SIL : vert #60A030, argent, anthracite.
   Écrite en propriétés logiques : la version arabe (RTL) se retourne seule.
   ========================================================================= */

:root {
  --green-bright: #60A030;   /* le vert exact des bidons SIL */
  --green: #4A8221;          /* variante accessible (AA sur blanc) */
  --green-dark: #3D6B1A;
  --lime: #8CB444;
  --ink: #232A2E;
  --ink-soft: #5A646B;
  --muted: #838D93;
  --steel: #9CA5AC;
  --line: #E4E8E3;
  --bg: #ffffff;
  --bg-soft: #F4F6F3;
  --green-wash: rgba(96, 160, 48, .09);
  --radius: 14px;
  --shadow: 0 1px 2px rgba(35, 42, 46, .05), 0 8px 24px rgba(35, 42, 46, .06);
  --shadow-lg: 0 4px 12px rgba(35, 42, 46, .08), 0 20px 48px rgba(35, 42, 46, .10);
  --max: 1180px;
  --header-h: 72px;
}

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

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: "Inter", "Noto Sans Arabic", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  color: var(--ink);
  background: var(--bg);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

/* l'arabe respire mieux un cran plus grand */
html[lang="ar"] body { font-size: 17px; line-height: 1.75; }
html[lang="ar"] .card__name, html[lang="ar"] .chip { letter-spacing: 0; }

img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
button { font: inherit; cursor: pointer; }

h1, h2, h3 { line-height: 1.2; letter-spacing: -.02em; margin: 0 0 .5em; font-weight: 700; }
html[lang="ar"] h1, html[lang="ar"] h2, html[lang="ar"] h3 { letter-spacing: 0; line-height: 1.35; }
h1 { font-size: clamp(2rem, 5vw, 3.1rem); }
h2 { font-size: clamp(1.5rem, 3.4vw, 2.1rem); }
h3 { font-size: 1.05rem; }
p  { margin: 0 0 1em; }

.wrap { max-width: var(--max); margin-inline: auto; padding-inline: 20px; }
.section { padding-block: clamp(48px, 7vw, 88px); }
.section--soft { background: var(--bg-soft); }
/* .center centre le texte ET recentre les blocs a largeur limitee
   (un h1 en max-width resterait colle au bord sans marge auto). */
.center { text-align: center; }
.center h1, .center h2, .center h3, .center p { margin-inline: auto; }
.lead { font-size: 1.08rem; color: var(--ink-soft); max-width: 62ch; }
.center .lead { margin-inline: auto; }

.eyebrow {
  display: inline-block; font-size: .74rem; font-weight: 700; letter-spacing: .14em;
  text-transform: uppercase; color: var(--green); margin-bottom: .6rem;
}
html[lang="ar"] .eyebrow { letter-spacing: .04em; }

/* ---------------------------------------------------------------- header */
.header {
  position: sticky; top: 0; z-index: 60;
  background: rgba(255, 255, 255, .93);
  backdrop-filter: saturate(180%) blur(12px);
  border-bottom: 1px solid var(--line);
}
.header__inner {
  height: var(--header-h);
  display: flex; align-items: center; gap: 18px;
  max-width: var(--max); margin-inline: auto; padding-inline: 20px;
}

.logo { display: flex; align-items: center; gap: 12px; flex: none; }
.logo__mark { width: auto; height: 34px; flex: none; }
.logo__text {
  display: flex; flex-direction: column; line-height: 1.05;
  padding-inline-start: 12px; border-inline-start: 1px solid var(--line);
}
.logo__name { font-weight: 800; font-size: 1rem; letter-spacing: -.01em; color: var(--ink); }
.logo__sub { font-size: .64rem; letter-spacing: .14em; text-transform: uppercase; color: var(--muted); }
/* dans le pied de page le logo respire davantage */
.footer .logo__mark { height: 46px; }
.footer .logo__name { font-size: 1.08rem; }

.nav { display: flex; align-items: center; gap: 4px; margin-inline-start: auto; }
.nav a {
  padding: 9px 14px; border-radius: 9px; font-size: .94rem; font-weight: 500;
  color: var(--ink-soft); transition: background .15s, color .15s;
}
.nav a:hover { background: var(--bg-soft); color: var(--ink); }
.nav a.is-active { color: var(--green); font-weight: 600; }

.header__actions { display: flex; align-items: center; gap: 8px; flex: none; }

.icon-btn {
  position: relative; display: inline-flex; align-items: center; gap: 8px;
  height: 40px; padding-inline: 12px; border: 1px solid var(--line);
  border-radius: 10px; background: #fff; color: var(--ink);
  font-size: .9rem; font-weight: 500; transition: border-color .15s, background .15s;
}
.icon-btn:hover { border-color: var(--green-bright); background: var(--bg-soft); }
.icon-btn svg { width: 18px; height: 18px; }

.badge {
  min-width: 20px; height: 20px; padding-inline: 6px; border-radius: 99px;
  background: var(--green); color: #fff; font-size: .72rem; font-weight: 700;
  display: inline-grid; place-items: center;
}
.badge[hidden] { display: none; }

.burger { display: none; }

/* --------------------------------------------------- sélecteur de langue */
.lang { position: relative; flex: none; }
.lang__btn {
  display: inline-flex; align-items: center; gap: 7px;
  height: 40px; padding-inline: 10px; border: 1px solid var(--line);
  border-radius: 10px; background: #fff; color: var(--ink);
  font-size: .88rem; font-weight: 600; transition: border-color .15s, background .15s;
}
.lang__btn:hover { border-color: var(--green-bright); background: var(--bg-soft); }
.lang__caret { width: 14px; height: 14px; color: var(--muted); transition: transform .18s; }
.lang.is-open .lang__caret { transform: rotate(180deg); }
.lang__code { letter-spacing: .04em; }

.flag {
  display: inline-block; width: 22px; height: 15px; flex: none;
  border-radius: 3px; overflow: hidden; box-shadow: 0 0 0 1px rgba(35, 42, 46, .12);
}
.flag svg { width: 100%; height: 100%; display: block; }

.lang__menu {
  position: absolute; z-index: 70; top: calc(100% + 8px); inset-inline-end: 0;
  min-width: 178px; background: #fff; border: 1px solid var(--line);
  border-radius: 12px; box-shadow: var(--shadow-lg); padding: 6px;
  display: none;
}
.lang.is-open .lang__menu { display: block; }
.lang__menu button {
  display: flex; align-items: center; gap: 10px; width: 100%;
  padding: 9px 10px; border: 0; border-radius: 8px; background: none;
  font-size: .92rem; color: var(--ink); text-align: start;
}
.lang__menu button:hover { background: var(--bg-soft); }
.lang__menu button.is-on { background: var(--green-wash); color: var(--green-dark); font-weight: 600; }

/* ----------------------------------------------------------------- boutons */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  height: 46px; padding-inline: 22px; border-radius: 11px; border: 1px solid transparent;
  font-weight: 600; font-size: .95rem; transition: transform .12s, background .15s, box-shadow .15s;
}
.btn:active { transform: translateY(1px); }
.btn--primary { background: var(--green); color: #fff; }
.btn--primary:hover { background: var(--green-dark); }
.btn--ghost { background: #fff; color: var(--ink); border-color: var(--line); }
.btn--ghost:hover { background: var(--bg-soft); border-color: var(--green-bright); }
.btn--dark { background: var(--ink); color: #fff; }
.btn--dark:hover { background: #000; }
.btn--sm { height: 38px; padding-inline: 14px; font-size: .88rem; }
.btn--block { width: 100%; }
.btn svg { width: 18px; height: 18px; }

/* -------------------------------------------------------------------- hero */
.hero {
  background:
    radial-gradient(900px 420px at 88% -12%, rgba(96, 160, 48, .16), transparent 62%),
    linear-gradient(180deg, #fff 0%, var(--bg-soft) 100%);
  border-bottom: 1px solid var(--line);
  padding-block: clamp(52px, 8vw, 96px);
}
.hero__badge {
  display: inline-flex; align-items: center; gap: 8px;
  background: #fff; border: 1px solid var(--line); border-radius: 99px;
  padding: 6px 14px; font-size: .82rem; font-weight: 600; color: var(--ink-soft);
  box-shadow: var(--shadow); margin-bottom: 22px;
}
.hero__badge b { color: var(--green-dark); }
.hero h1 { max-width: 18ch; }
.hero h1 em { font-style: normal; color: var(--green); }
.hero__cta { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 26px; }

/* Le bloc d'accroche est centre */
.hero .wrap { text-align: center; }
.hero h1, .hero .lead, .hero .searchbar { margin-inline: auto; }
.hero .hero__cta { justify-content: center; }
/* la saisie, elle, reste alignee sur l'icone de recherche */
.hero .searchbar input { text-align: start; }

/* ------------------------------------------------------------ barre recherche */
.searchbar { position: relative; max-width: 620px; margin-top: 30px; }
.searchbar input {
  width: 100%; height: 58px; padding-inline: 50px 54px;
  border: 1px solid var(--line); border-radius: 14px; background: #fff;
  font: inherit; font-size: 1rem; color: var(--ink); box-shadow: var(--shadow);
  transition: border-color .15s, box-shadow .15s;
}
.searchbar input:focus { outline: none; border-color: var(--green-bright); box-shadow: 0 0 0 4px rgba(96, 160, 48, .16); }
.searchbar__icon {
  position: absolute; inset-inline-start: 18px; top: 50%; transform: translateY(-50%);
  width: 20px; height: 20px; color: var(--muted); pointer-events: none;
}
.searchbar__clear {
  position: absolute; inset-inline-end: 12px; top: 50%; transform: translateY(-50%);
  width: 30px; height: 30px; border: 0; border-radius: 8px; background: var(--bg-soft);
  color: var(--ink-soft); display: none; place-items: center;
}
.searchbar.has-value .searchbar__clear { display: grid; }

.suggest {
  position: absolute; z-index: 40; top: calc(100% + 8px); inset-inline: 0;
  background: #fff; border: 1px solid var(--line); border-radius: 14px;
  box-shadow: var(--shadow-lg); overflow: hidden; display: none;
  max-height: 340px; overflow-y: auto;
}
.suggest.is-open { display: block; }
.suggest a { display: block; padding: 12px 18px; border-bottom: 1px solid var(--line); }
.suggest a:last-child { border-bottom: 0; }
.suggest a:hover, .suggest a.is-hl { background: var(--bg-soft); }
.suggest__name { display: block; font-weight: 600; font-size: .95rem; }
.suggest__meta { display: block; font-size: .8rem; color: var(--muted); }
.suggest__empty { padding: 16px 18px; color: var(--muted); font-size: .92rem; }

/* ------------------------------------------------------------------ grilles */
.grid { display: grid; gap: 18px; }
.grid--2 { grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); }
.grid--3 { grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); }
.grid--4 { grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); }

/* -------------------------------------------------------------- carte produit */
.card {
  position: relative; display: flex; flex-direction: column;
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius);
  overflow: hidden; transition: border-color .15s, box-shadow .15s, transform .15s;
}
.card:hover { border-color: var(--green-bright); box-shadow: var(--shadow); transform: translateY(-2px); }

.card__media {
  aspect-ratio: 4 / 3; background: #fff;
  display: grid; place-items: center; border-bottom: 1px solid var(--line); position: relative;
}
.card__link { display: block; width: 100%; height: 100%; }
.card__media img { width: 100%; height: 100%; object-fit: contain; padding: 12px; }
.card__body { padding: 16px; display: flex; flex-direction: column; gap: 8px; flex: 1; }
.card__fam { font-size: .72rem; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); }
.card__name { font-size: 1rem; font-weight: 700; letter-spacing: -.01em; margin: 0; }
.card__name a:hover { color: var(--green-dark); }
.card__desc {
  font-size: .87rem; color: var(--ink-soft); margin: 0;
  display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden;
}
.card__specs {
  font-size: .76rem; color: var(--muted); border-top: 1px solid var(--line);
  padding-top: 10px; margin-top: auto;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}
.card__foot { padding: 0 16px 16px; display: flex; gap: 8px; }

.chip {
  display: inline-flex; align-items: center; gap: 6px;
  background: var(--green-wash); border: 1px solid rgba(96, 160, 48, .22); border-radius: 99px;
  padding: 3px 10px; font-size: .76rem; font-weight: 700; color: var(--green-dark);
}

.fav-btn {
  position: absolute; top: 10px; inset-inline-end: 10px; z-index: 2;
  width: 36px; height: 36px; border-radius: 50%; border: 1px solid var(--line);
  background: rgba(255, 255, 255, .95); color: var(--muted);
  display: grid; place-items: center; transition: color .15s, border-color .15s, transform .12s;
}
.fav-btn:hover { color: var(--green); border-color: var(--green-bright); transform: scale(1.06); }
.fav-btn svg { width: 19px; height: 19px; fill: none; stroke: currentColor; stroke-width: 1.9; }
.fav-btn.is-on { color: var(--green); border-color: var(--green-bright); }
.fav-btn.is-on svg { fill: var(--green-bright); stroke: var(--green-dark); }

/* -------------------------------------------------------------- catalogue */
.catalog { display: grid; grid-template-columns: 260px 1fr; gap: 30px; align-items: start; }

.filters {
  position: sticky; top: calc(var(--header-h) + 20px);
  border: 1px solid var(--line); border-radius: var(--radius); padding: 20px; background: #fff;
}
.filters h3 { font-size: .78rem; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); margin-bottom: 12px; }
.filters__group + .filters__group { margin-top: 24px; padding-top: 22px; border-top: 1px solid var(--line); }
.filters label {
  display: flex; align-items: center; gap: 9px; padding: 5px 0;
  font-size: .89rem; color: var(--ink-soft); cursor: pointer;
}
.filters label:hover { color: var(--ink); }
.filters input[type="radio"], .filters input[type="checkbox"] { accent-color: var(--green); width: 15px; height: 15px; flex: none; }
.filters .count { margin-inline-start: auto; font-size: .76rem; color: var(--muted); }

.toolbar { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; margin-bottom: 20px; }
.toolbar__count { color: var(--muted); font-size: .9rem; }
.toolbar__count b { color: var(--ink); }
.toolbar .spacer { margin-inline-start: auto; }

.select {
  height: 40px; padding-inline: 12px; border: 1px solid var(--line); border-radius: 10px;
  background: #fff; font: inherit; font-size: .9rem; color: var(--ink);
}

.empty {
  border: 1px dashed var(--line); border-radius: var(--radius);
  padding: 56px 24px; text-align: center; color: var(--muted); background: var(--bg-soft);
}

/* --------------------------------------------------------------- catégories */
.cat-card {
  display: block; border: 1px solid var(--line); border-radius: var(--radius);
  padding: 24px; background: #fff; transition: border-color .15s, box-shadow .15s, transform .15s;
}
.cat-card:hover { border-color: var(--green-bright); box-shadow: var(--shadow); transform: translateY(-2px); }
.cat-card__icon {
  width: 42px; height: 42px; border-radius: 11px; background: var(--green-wash);
  color: var(--green-dark); display: grid; place-items: center; margin-bottom: 14px;
}
.cat-card__icon svg { width: 22px; height: 22px; }
.cat-card h3 { margin-bottom: 4px; }
.cat-card p { font-size: .88rem; color: var(--ink-soft); margin: 0; }
.cat-card .n { font-size: .8rem; color: var(--muted); margin-top: 10px; display: block; }

/* ------------------------------------------------------------- fiche produit */
.crumb { font-size: .85rem; color: var(--muted); margin-bottom: 18px; display: flex; flex-wrap: wrap; gap: 6px; }
.crumb a:hover { color: var(--green-dark); }
.crumb span { color: var(--steel); }

.pd { display: grid; grid-template-columns: minmax(280px, 460px) 1fr; gap: 40px; align-items: start; }
.pd__media {
  border: 1px solid var(--line); border-radius: 18px; background: #fff;
  padding: 24px; position: relative; display: grid; place-items: center;
}
.pd__media img { max-height: 460px; width: auto; object-fit: contain; }
.pd__fam { font-size: .76rem; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--green); }
.pd h1 { font-size: clamp(1.7rem, 3.6vw, 2.4rem); margin-block: 8px 14px; }
.pd__lead { font-size: 1.05rem; color: var(--ink-soft); }
.pd__tags { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 22px; }
.pd__actions { display: flex; flex-wrap: wrap; gap: 10px; margin-block: 26px; }

.spec-table { width: 100%; border-collapse: collapse; font-size: .93rem; }
.spec-table th {
  text-align: start; width: 34%; padding: 12px 14px; color: var(--muted);
  font-weight: 600; border-bottom: 1px solid var(--line); vertical-align: top;
}
.spec-table td { padding: 12px 14px; border-bottom: 1px solid var(--line); }
.spec-table tr:last-child th, .spec-table tr:last-child td { border-bottom: 0; }
.norm-list { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 8px; }
.norm-list li {
  background: var(--bg-soft); border: 1px solid var(--line); border-radius: 8px;
  padding: 5px 11px; font-size: .84rem; font-weight: 600; color: var(--ink-soft);
}

/* ---------------------------------------------------------------- tableau devis */
.qtable { width: 100%; border-collapse: collapse; font-size: .92rem; }
.qtable th {
  text-align: start; font-size: .74rem; letter-spacing: .08em; text-transform: uppercase;
  color: var(--muted); font-weight: 700; padding: 0 12px 10px; border-bottom: 1px solid var(--line);
}
.qtable td { padding: 14px 12px; border-bottom: 1px solid var(--line); vertical-align: middle; }
.qtable .p-thumb { width: 54px; height: 54px; object-fit: contain; border: 1px solid var(--line); border-radius: 9px; background: #fff; padding: 4px; }
.qtable .p-name { font-weight: 600; }
.qtable .p-fam { font-size: .8rem; color: var(--muted); }
.qtable input[type="number"] {
  width: 92px; height: 38px; padding-inline: 10px; font: inherit;
  border: 1px solid var(--line); border-radius: 9px; font-size: .92rem;
}
.qtable .rm { border: 0; background: none; color: var(--muted); font-size: 1.25rem; line-height: 1; padding: 4px 8px; }
.qtable .rm:hover { color: #C0392B; }
.table-scroll { overflow-x: auto; }

/* ------------------------------------------------------------------ formulaire */
.form { display: grid; gap: 16px; }
.form .row { display: grid; gap: 16px; grid-template-columns: 1fr 1fr; }
.field { display: grid; gap: 6px; }
.field label { font-size: .86rem; font-weight: 600; color: var(--ink-soft); }
.field label .req { color: #C0392B; }
.field input, .field textarea, .field select {
  width: 100%; padding: 12px 14px; border: 1px solid var(--line); border-radius: 10px;
  font: inherit; font-size: .95rem; background: #fff; color: var(--ink);
  transition: border-color .15s, box-shadow .15s;
}
.field input:focus, .field textarea:focus, .field select:focus {
  outline: none; border-color: var(--green-bright); box-shadow: 0 0 0 4px rgba(96, 160, 48, .16);
}
.field textarea { min-height: 120px; resize: vertical; }
.hint { font-size: .82rem; color: var(--muted); }

.panel { border: 1px solid var(--line); border-radius: var(--radius); padding: 24px; background: #fff; }
.panel--soft { background: var(--bg-soft); }

/* -------------------------------------------------------------------- contact */
.contact-item { display: flex; gap: 14px; align-items: flex-start; padding: 16px 0; border-bottom: 1px solid var(--line); }
.contact-item:last-child { border-bottom: 0; }
.contact-item__icon {
  width: 40px; height: 40px; flex: none; border-radius: 10px;
  background: var(--green-wash); color: var(--green-dark); display: grid; place-items: center;
}
.contact-item__icon svg { width: 19px; height: 19px; }
.contact-item__label { font-size: .76rem; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); font-weight: 600; }
.contact-item__value { font-weight: 600; font-size: 1.02rem; }
.contact-item a.contact-item__value:hover { color: var(--green-dark); }

.map-frame { border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; height: 340px; }
.map-frame iframe { width: 100%; height: 100%; border: 0; }

/* ------------------------------------------------------------------ à propos */
.stat { text-align: center; padding: 22px 16px; }
.stat b { display: block; font-size: 2rem; font-weight: 800; color: var(--green); letter-spacing: -.03em; }
.stat span { font-size: .88rem; color: var(--ink-soft); }

.feature { padding: 22px; border: 1px solid var(--line); border-radius: var(--radius); background: #fff; }
.feature__icon {
  width: 40px; height: 40px; border-radius: 10px; background: var(--green-wash);
  color: var(--green-dark); display: grid; place-items: center; margin-bottom: 12px;
}
.feature__icon svg { width: 20px; height: 20px; }
.feature h3 { margin-bottom: 6px; }
.feature p { font-size: .9rem; color: var(--ink-soft); margin: 0; }

/* ---------------------------------------------------------------------- CTA */
.cta {
  background: linear-gradient(150deg, var(--ink), #1a2b16);
  color: #fff; border-radius: 20px;
  padding: clamp(32px, 5vw, 56px); text-align: center;
}
.cta h2 { color: #fff; }
.cta p { color: rgba(255, 255, 255, .74); max-width: 56ch; margin-inline: auto; }
.cta .btn--ghost { background: transparent; color: #fff; border-color: rgba(255, 255, 255, .3); }
.cta .btn--ghost:hover { background: rgba(255, 255, 255, .12); border-color: rgba(255, 255, 255, .55); }

/* ------------------------------------------------------------------- footer */
.footer { border-top: 1px solid var(--line); background: var(--bg-soft); padding-block: 52px 28px; margin-top: 20px; }
.footer__grid { display: grid; gap: 32px; grid-template-columns: 1.6fr 1fr 1fr; }
.footer h4 { font-size: .76rem; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); margin: 0 0 14px; }
.footer ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 9px; }
.footer li { font-size: .92rem; color: var(--ink-soft); }
.footer a:hover { color: var(--green-dark); }
.footer__legal {
  margin-top: 36px; padding-top: 20px; border-top: 1px solid var(--line);
  display: flex; flex-wrap: wrap; gap: 10px 18px; justify-content: space-between;
  font-size: .84rem; color: var(--muted);
}
.footer__legal .sep { color: var(--steel); margin-inline: 2px; }
.credit {
  color: var(--ink-soft); font-weight: 600;
  border-bottom: 1px solid var(--line); transition: color .15s, border-color .15s;
}
.credit:hover { color: var(--green-dark); border-color: var(--green-bright); }

/* --------------------------------------------------------- réseaux sociaux */
.socials { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 18px; }
.social {
  width: 40px; height: 40px; border-radius: 11px; display: grid; place-items: center;
  background: #fff; border: 1px solid var(--line); color: var(--ink-soft);
  transition: color .15s, border-color .15s, transform .12s, background .15s;
}
.social svg { width: 20px; height: 20px; fill: currentColor; }
.social:hover {
  color: #fff; background: var(--social, var(--green)); border-color: var(--social, var(--green));
  transform: translateY(-2px);
}

/* variante nommee, mise en avant sur la page contact */
.socials--lg { justify-content: center; gap: 12px; }
.social--lg {
  width: auto; height: 52px; padding-inline: 20px; gap: 10px;
  display: inline-flex; align-items: center; border-radius: 14px;
  font-weight: 700; font-size: .95rem; color: var(--social, var(--green));
  border-color: color-mix(in srgb, var(--social, var(--green)) 32%, var(--line));
  background: color-mix(in srgb, var(--social, var(--green)) 7%, #fff);
}
.social--lg svg { width: 22px; height: 22px; }
.social--lg:hover { color: #fff; }
@media (max-width: 460px) {
  .social--lg { height: 48px; padding-inline: 16px; font-size: .9rem; }
}

/* --------------------------------------------------------------- whatsapp fab */
.fab {
  position: fixed; inset-block-end: 22px; inset-inline-end: 22px; z-index: 70;
  width: 54px; height: 54px; border-radius: 50%; background: #25d366; color: #fff;
  display: grid; place-items: center; box-shadow: 0 8px 24px rgba(37, 211, 102, .38);
  transition: transform .15s;
}
.fab:hover { transform: scale(1.07); }
.fab svg { width: 27px; height: 27px; fill: currentColor; }

/* ---------------------------------------------------------------------- toast */
.toast {
  position: fixed; inset-block-end: 24px; left: 50%; transform: translate(-50%, 20px);
  z-index: 90; background: var(--ink); color: #fff; padding: 12px 20px; border-radius: 11px;
  font-size: .9rem; font-weight: 500; box-shadow: var(--shadow-lg); max-width: min(92vw, 460px);
  text-align: center; opacity: 0; pointer-events: none; transition: opacity .2s, transform .2s;
}
.toast.is-on { opacity: 1; transform: translate(-50%, 0); }

/* ------------------------------------------------------------------ responsive */
@media (max-width: 1000px) {
  .pd { grid-template-columns: 1fr; gap: 26px; }
  .pd__media img { max-height: 340px; }
}

@media (max-width: 960px) {
  .catalog { grid-template-columns: 1fr; }
  .filters { position: static; }
  .footer__grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 860px) {
  .burger {
    display: grid; place-items: center; width: 40px; height: 40px;
    border: 1px solid var(--line); border-radius: 10px; background: #fff; color: var(--ink);
  }
  .burger svg { width: 20px; height: 20px; }
  .header__inner { gap: 8px; }
  .icon-btn .label { display: none; }
  .logo__text { display: none; }
  .lang__code { display: none; }
  .form .row { grid-template-columns: 1fr; }
  .footer__grid { grid-template-columns: 1fr; }
}

@media (max-width: 460px) {
  .grid--3, .grid--4 { grid-template-columns: repeat(auto-fill, minmax(158px, 1fr)); }
  .card__body { padding: 13px; }
  .card__foot { padding: 0 13px 13px; }
  .logo__sub { display: none; }
  .spec-table th { width: 42%; }
}

/* =========================================================================
   PAGE CONTACT
   Ecrite mobile d'abord : la base vaut pour le telephone, les paliers
   min-width n'ajoutent que ce qui a du sens sur grand ecran.
   ========================================================================= */

/* ------------------------------------------- tuiles d'action immediates */
.ctiles { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }

.ctile {
  display: flex; flex-direction: column; gap: 10px;
  min-height: 132px; padding: 16px;
  border: 1px solid var(--line); border-radius: 16px; background: #fff;
  transition: border-color .15s, box-shadow .15s, transform .12s;
}
.ctile:active { transform: scale(.985); }
.ctile:hover { border-color: var(--green-bright); box-shadow: var(--shadow); }
.ctile__icon {
  width: 44px; height: 44px; flex: none; border-radius: 13px;
  background: var(--green-wash); color: var(--green-dark);
  display: grid; place-items: center;
}
.ctile__icon svg { width: 21px; height: 21px; }
.ctile__label {
  font-size: .72rem; font-weight: 700; letter-spacing: .09em;
  text-transform: uppercase; color: var(--muted);
}
html[lang="ar"] .ctile__label { letter-spacing: .02em; }
.ctile__value { font-weight: 700; font-size: .98rem; line-height: 1.3; margin-top: auto; }
.ctile--wa .ctile__icon { background: rgba(37, 211, 102, .14); color: #128C43; }
.ctile--wa:hover { border-color: #25D366; }

/* --------------------------------------------------- corps de la page */
.contact-grid { display: grid; gap: 20px; }

.addr {
  display: flex; gap: 14px; align-items: flex-start;
  padding: 18px; border: 1px solid var(--line); border-radius: 16px; background: #fff;
}
.addr__icon {
  width: 42px; height: 42px; flex: none; border-radius: 12px;
  background: var(--green-wash); color: var(--green-dark); display: grid; place-items: center;
}
.addr__icon svg { width: 20px; height: 20px; }
.addr__label { font-size: .72rem; font-weight: 700; letter-spacing: .09em; text-transform: uppercase; color: var(--muted); }
.addr__text { font-weight: 600; line-height: 1.45; margin: 4px 0 10px; }

/* ------------------------------------------------- bandeau de reassurance */
.creassure { display: grid; gap: 10px; }
.creassure div {
  display: flex; align-items: center; gap: 11px;
  padding: 14px 16px; border: 1px solid var(--line); border-radius: 13px;
  background: #fff; font-size: .93rem; font-weight: 600; color: var(--ink-soft);
}
.creassure svg { width: 20px; height: 20px; flex: none; color: var(--green); }

/* ------------------------------------------------------ paliers superieurs */
@media (min-width: 640px) {
  .ctiles { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .creassure { grid-template-columns: repeat(3, 1fr); }
}

@media (min-width: 980px) {
  .contact-grid { grid-template-columns: 1.25fr 1fr; gap: 28px; align-items: start; }
  .map-frame { height: 420px; }
}

/* =========================================================================
   NAVIGATION MOBILE
   Tiroir lateral, barre d'onglets fixe, feuille de filtres.
   Tout est masque au-dessus de 860 px : le desktop garde sa barre classique.
   ========================================================================= */

.scrim, .drawer, .sheet, .tabbar, .filters__trigger { display: none; }

body.is-locked { overflow: hidden; }

@media (max-width: 860px) {

  /* --------------------------------------------------------- generalites */
  :root { --header-h: 62px; --tabbar-h: 64px; }

  body {
    /* de la place pour la barre d'onglets, encoches iPhone comprises */
    padding-bottom: calc(var(--tabbar-h) + env(safe-area-inset-bottom));
  }

  .section { padding-block: clamp(36px, 8vw, 56px); }
  .footer { padding-block: 40px 24px; }

  /* l'ancien menu deroulant laisse place au tiroir */
  .nav { display: none !important; }

  /* .nav portait le margin-inline-start:auto qui repoussait la barre vers la
     fin ; masque, il ne compte plus dans la mise en page. On confie donc la
     poussee au bloc d'actions : logo au debut, boutons a la fin. */
  .header__actions { margin-inline-start: auto; }

  /* ------------------------------------------------------------- voile */
  .scrim {
    display: block; position: fixed; inset: 0; z-index: 80;
    background: rgba(20, 28, 20, .48); backdrop-filter: blur(2px);
    opacity: 0; pointer-events: none; transition: opacity .26s ease;
  }
  .scrim.is-on { opacity: 1; pointer-events: auto; }

  /* ------------------------------------------------------- tiroir menu */
  .drawer {
    display: flex; flex-direction: column;
    position: fixed; inset-block: 0; inset-inline-end: 0; z-index: 90;
    width: min(88vw, 370px); background: #fff;
    box-shadow: -18px 0 48px rgba(20, 28, 20, .18);
    transform: translateX(100%);
    transition: transform .3s cubic-bezier(.32, .72, 0, 1);
    padding-bottom: env(safe-area-inset-bottom);
    overscroll-behavior: contain;
  }
  html[dir="rtl"] .drawer { transform: translateX(-100%); box-shadow: 18px 0 48px rgba(20, 28, 20, .18); }
  .drawer.is-open { transform: none; }

  .drawer__head {
    display: flex; align-items: center; gap: 12px;
    padding: 14px 18px; border-bottom: 1px solid var(--line);
  }
  .drawer__head .logo__mark { height: 30px; }
  .drawer__close {
    margin-inline-start: auto; width: 42px; height: 42px; flex: none;
    border: 1px solid var(--line); border-radius: 12px; background: #fff;
    color: var(--ink-soft); display: grid; place-items: center;
  }
  .drawer__close svg { width: 20px; height: 20px; }

  .drawer__body { flex: 1; overflow-y: auto; padding: 10px 14px 24px; }

  .drawer__label {
    font-size: .7rem; font-weight: 700; letter-spacing: .12em; text-transform: uppercase;
    color: var(--muted); padding: 20px 8px 8px;
  }
  html[lang="ar"] .drawer__label { letter-spacing: .03em; }

  .drawer__link {
    display: flex; align-items: center; gap: 14px;
    min-height: 54px; padding: 8px 12px; border-radius: 13px;
    font-size: 1.02rem; font-weight: 600; color: var(--ink);
  }
  .drawer__link svg { width: 22px; height: 22px; flex: none; color: var(--muted); }
  .drawer__link:active { background: var(--bg-soft); }
  .drawer__link.is-active { background: var(--green-wash); color: var(--green-dark); }
  .drawer__link.is-active svg { color: var(--green); }
  .drawer__link .chev { margin-inline-start: auto; width: 18px; height: 18px; color: var(--steel); }
  .drawer__link .badge { margin-inline-start: auto; }

  /* choix de la langue : trois drapeaux cote a cote */
  .drawer__langs { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; padding: 0 8px; }
  .drawer__langs button {
    display: flex; flex-direction: column; align-items: center; gap: 7px;
    padding: 12px 6px; border: 1px solid var(--line); border-radius: 13px;
    background: #fff; font-size: .8rem; font-weight: 600; color: var(--ink-soft);
  }
  .drawer__langs button.is-on {
    border-color: var(--green-bright); background: var(--green-wash); color: var(--green-dark);
  }
  .drawer__langs .flag { width: 30px; height: 20px; }

  .drawer__actions { display: grid; gap: 8px; padding: 0 8px; }
  .drawer__actions .btn { height: 50px; justify-content: flex-start; padding-inline: 16px; }

  /* -------------------------------------------------- barre d'onglets */
  .tabbar {
    display: grid; grid-auto-flow: column; grid-auto-columns: 1fr;
    position: fixed; inset-inline: 0; inset-block-end: 0; z-index: 70;
    background: rgba(255, 255, 255, .96);
    backdrop-filter: saturate(180%) blur(14px);
    border-top: 1px solid var(--line);
    padding-bottom: env(safe-area-inset-bottom);
  }
  .tabbar a {
    position: relative;
    display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px;
    height: var(--tabbar-h); font-size: .68rem; font-weight: 600; color: var(--muted);
    letter-spacing: .01em;
  }
  .tabbar svg { width: 23px; height: 23px; stroke-width: 1.7; }
  .tabbar a.is-active { color: var(--green-dark); }
  .tabbar a.is-active::before {
    content: ""; position: absolute; top: 0; inset-inline: 26%;
    height: 3px; border-radius: 0 0 3px 3px; background: var(--green-bright);
  }
  .tabbar .badge {
    position: absolute; top: 6px; inset-inline-start: 56%;
    font-size: .64rem; min-width: 17px; height: 17px;
  }

  /* le bouton WhatsApp remonte au-dessus de la barre */
  .fab {
    inset-block-end: calc(var(--tabbar-h) + env(safe-area-inset-bottom) + 14px);
    width: 50px; height: 50px;
  }
  .fab svg { width: 25px; height: 25px; }

  /* -------------------------------------------- feuille de filtres */
  .hide-mobile { display: none !important; }

  .filters__trigger {
    display: inline-flex; align-items: center; gap: 8px;
    height: 42px; padding-inline: 16px; border: 1px solid var(--line);
    border-radius: 12px; background: #fff; font-weight: 600; font-size: .92rem;
  }
  .filters__trigger svg { width: 18px; height: 18px; }
  .filters__trigger .count-pill {
    min-width: 20px; height: 20px; padding-inline: 6px; border-radius: 99px;
    background: var(--green); color: #fff; font-size: .7rem; font-weight: 700;
    display: inline-grid; place-items: center;
  }
  .filters__trigger .count-pill:empty { display: none; }

  .catalog { display: block; }

  .sheet {
    display: flex; flex-direction: column;
    position: fixed; inset-inline: 0; inset-block-end: 0; z-index: 90;
    max-height: 86vh; background: #fff;
    border-radius: 22px 22px 0 0; box-shadow: 0 -18px 48px rgba(20, 28, 20, .18);
    transform: translateY(100%);
    transition: transform .3s cubic-bezier(.32, .72, 0, 1);
    padding-bottom: env(safe-area-inset-bottom);
    overscroll-behavior: contain;
  }
  .sheet.is-open { transform: none; }
  .sheet__grip {
    width: 44px; height: 5px; border-radius: 99px; background: var(--line);
    margin: 10px auto 2px; flex: none;
  }
  .sheet__head {
    display: flex; align-items: center; gap: 12px;
    padding: 8px 18px 12px; border-bottom: 1px solid var(--line);
  }
  .sheet__head h2 { margin: 0; font-size: 1.05rem; }
  .sheet__body { overflow-y: auto; padding: 4px 18px 12px; flex: 1; }
  .sheet__foot {
    padding: 12px 18px 16px; border-top: 1px solid var(--line); background: #fff;
  }

  /* dans la feuille, la colonne de filtres perd son cadre */
  .sheet .filters { border: 0; padding: 0; position: static; }
  .sheet .filters label { min-height: 46px; padding-block: 8px; font-size: .95rem; }
  .sheet .filters input[type="radio"], .sheet .filters input[type="checkbox"] { width: 19px; height: 19px; }
  .sheet .filters__group:first-child { padding-top: 6px; }

  /* ------------------------------------------------ confort tactile */
  .header__inner { gap: 6px; }
  .btn { height: 48px; }
  .btn--sm { height: 40px; }
  .icon-btn, .lang__btn { height: 42px; }
  .card__foot .btn { height: 42px; }
  .toolbar { gap: 10px; }
  .searchbar input { height: 52px; font-size: 1rem; }
  .toast { inset-block-end: calc(var(--tabbar-h) + env(safe-area-inset-bottom) + 14px); }
}

@media (max-width: 460px) {
  .grid--3, .grid--4 { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
  .card__desc { -webkit-line-clamp: 2; }
  .card__specs { display: none; }
  .pd__actions .btn { width: 100%; }
}

/* mouvement reduit : on respecte le reglage systeme */
@media (prefers-reduced-motion: reduce) {
  .drawer, .sheet, .scrim, .card, .btn { transition: none !important; }
}

@media print {
  .header, .footer, .fab, .filters, .pd__actions, .lang,
  .tabbar, .drawer, .scrim, .sheet { display: none !important; }
  .card, .panel { break-inside: avoid; }
  body { padding-bottom: 0; }
}
