/* =========================================================
   EBO — Expert Bâtiment Occitanie
   Design system — refonte 2026
   ========================================================= */

:root {
  /* Palette — directement issue du logo EBO :
     marine profond #031c44, orange #e2620c, jaune #ffbc00 */
  --ink:        #0b1f3a;   /* texte principal, marine très foncé */
  --slate:      #031c44;   /* marine du logo — fonds sombres */
  --slate-700:  #0d3168;   /* marine un peu plus clair */
  --slate-500:  #2b5a9e;   /* bleu moyen pour liens/accents froids */
  --accent:     #e2620c;   /* ORANGE du logo — accent principal */
  --accent-600: #c9540a;
  --gold:       #ffbc00;   /* jaune du logo — touche secondaire */
  /* dégradé marine unique, utilisé sur TOUS les fonds sombres (hero, stats, cta) */
  --grad-dark:  linear-gradient(160deg, #0a2c5e 0%, #031c44 100%);
  --paper:      #f4f7fb;   /* "blanc" très légèrement bleuté, pas pur */
  --bg:         #dde5f0;   /* bleu-gris franc — fond de page assumé */
  --bg-2:       #cdd8e8;
  --line:       #c2cee0;
  --muted:      #4a5870;
  --ok:         #1f8a5b;
  --err:        #c0392b;

  --radius:     14px;
  --radius-sm:  9px;
  --shadow-sm:  0 1px 2px rgba(20,32,46,.06), 0 2px 8px rgba(20,32,46,.05);
  --shadow:     0 8px 30px rgba(20,32,46,.10);
  --shadow-lg:  0 20px 60px rgba(20,32,46,.16);

  --maxw: 1140px;
  --ff-sans: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  --ff-serif: "Fraunces", "Iowan Old Style", Georgia, "Times New Roman", serif;
}

/* ---------- reset ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: var(--ff-sans);
  color: var(--ink);
  background: var(--bg);
  line-height: 1.65;
  font-size: 17px;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
img { max-width: 100%; display: block; }
a { color: var(--slate-700); text-decoration: none; transition: color .15s ease; }
a:hover { color: var(--accent-600); }
h1, h2, h3 { font-family: var(--ff-serif); line-height: 1.12; font-weight: 600; letter-spacing: -.01em; margin: 0 0 .5em; }
h1 { font-size: clamp(2.1rem, 1.4rem + 2.8vw, 3.5rem); }
h2 { font-size: clamp(1.7rem, 1.2rem + 1.8vw, 2.5rem); }
h3 { font-size: 1.25rem; font-weight: 600; }
p  { margin: 0 0 1rem; }

/* ---------- layout ---------- */
.wrap { width: 100%; max-width: var(--maxw); margin-inline: auto; padding-inline: 22px; }
.section { padding-block: clamp(48px, 5.5vw, 88px); }
.section--tight { padding-block: clamp(34px, 4vw, 60px); }
.section--alt { background: var(--paper); }
/* fond marine — densifie, casse le "tout blanc" */
.section--dark { background: var(--grad-dark); color:#fff; }
.section--dark h2 { color:#fff; }
.section--dark .lead { color: rgba(255,255,255,.82); }
.section--dark .eyebrow { color: var(--gold); }
.section--dark .eyebrow::before { background: var(--gold); }
.lead { font-size: 1.18rem; color: var(--muted); max-width: 62ch; }
.eyebrow {
  display: inline-flex; align-items: center; gap: .5em;
  font-family: var(--ff-sans); font-weight: 600; font-size: .8rem;
  letter-spacing: .14em; text-transform: uppercase; color: var(--accent-600);
  margin-bottom: 1rem;
}
.eyebrow::before { content: ""; width: 26px; height: 3px; background: var(--accent); border-radius: 2px; }
.center { text-align: center; }
.center .lead { margin-inline: auto; }

/* ---------- buttons ---------- */
.btn {
  display: inline-flex; align-items: center; gap: .55em;
  font-weight: 600; font-size: .98rem;
  padding: .8em 1.4em; border-radius: 999px;
  border: 1.5px solid transparent; cursor: pointer;
  transition: transform .12s ease, box-shadow .15s ease, background .15s ease, color .15s ease;
  white-space: nowrap;
}
.btn:active { transform: translateY(1px); }
.btn--primary { background: var(--accent); color: #fff; box-shadow: 0 6px 18px rgba(200,116,58,.30); }
.btn--primary:hover { background: var(--accent-600); color: #fff; box-shadow: 0 10px 26px rgba(200,116,58,.38); }
.btn--dark { background: var(--slate); color: #fff; }
.btn--dark:hover { background: var(--slate-700); color: #fff; }
.btn--ghost { background: transparent; color: var(--slate); border-color: var(--line); }
.btn--ghost:hover { border-color: var(--slate-500); color: var(--slate-700); }
.btn--lg { padding: .95em 1.7em; font-size: 1.05rem; }

/* ---------- header / nav ---------- */
.site-header {
  position: sticky; top: 0; z-index: 100;
  background: rgba(246,244,241,.85);
  backdrop-filter: saturate(150%) blur(10px);
  border-bottom: 1px solid var(--line);
}
.nav { display: flex; align-items: center; gap: 1.5rem; height: 74px; }
.brand { display: flex; align-items: center; gap: .65rem; font-weight: 700; color: var(--ink); }
.brand img { height: 40px; width: auto; }
.brand b { font-family: var(--ff-serif); font-size: 1.15rem; letter-spacing: -.01em; }
.brand span { display: block; font-family: var(--ff-sans); font-weight: 500; font-size: .72rem; color: var(--muted); letter-spacing: .03em; }
.nav-links { display: flex; align-items: center; gap: .35rem; margin-left: auto; }
.nav-links a {
  font-weight: 500; font-size: .96rem; color: var(--ink);
  padding: .5em .8em; border-radius: 8px;
}
.nav-links a:hover { background: var(--bg-2); color: var(--ink); }
.nav-links a.active { color: var(--accent-600); }
.nav-cta { margin-left: .4rem; }

/* dropdown */
.has-drop { position: relative; }
.drop {
  position: absolute; top: calc(100% + 6px); left: 0;
  min-width: 230px; background: var(--paper);
  border: 1px solid var(--line); border-radius: var(--radius-sm);
  box-shadow: var(--shadow); padding: 6px;
  opacity: 0; visibility: hidden; transform: translateY(6px);
  transition: opacity .15s ease, transform .15s ease, visibility .15s;
}
.has-drop:hover .drop, .has-drop:focus-within .drop { opacity: 1; visibility: visible; transform: translateY(0); }
.drop a { display: block; padding: .55em .7em; border-radius: 7px; font-size: .93rem; color: var(--ink); }
.drop a:hover { background: var(--bg); color: var(--accent-600); }
.drop-toggle::after { content: "▾"; font-size: .7em; margin-left: .35em; color: var(--muted); }

/* burger */
.burger { display: none; margin-left: auto; background: none; border: 0; cursor: pointer; padding: 8px; }
.burger span { display: block; width: 24px; height: 2px; background: var(--ink); margin: 5px 0; border-radius: 2px; transition: .25s; }
.mobile-menu { display: none; }

/* ---------- hero ---------- */
.hero { position: relative; overflow: hidden; background: var(--slate); color: #fff; }
.hero::before {
  content: ""; position: absolute; inset: 0;
  background:
    radial-gradient(1100px 500px at 80% -10%, rgba(226,98,12,.22), transparent 60%),
    var(--grad-dark);
}
.hero .wrap { position: relative; display: grid; grid-template-columns: 1.05fr .95fr; gap: 48px; align-items: center; padding-block: clamp(56px, 8vw, 112px); }
.hero h1 { color: #fff; }
.hero .lead { color: rgba(255,255,255,.82); }
.hero-actions { display: flex; flex-wrap: wrap; gap: .8rem; margin-top: 1.8rem; }
.hero-media { position: relative; }
.hero-media img { border-radius: var(--radius); box-shadow: var(--shadow-lg); aspect-ratio: 4/3; object-fit: cover; }
.hero-badge {
  position: absolute; bottom: 18px; left: -16px;
  background: #fff; color: var(--ink);
  border-radius: var(--radius-sm); padding: 12px 16px 12px 12px; box-shadow: var(--shadow-lg);
  display: flex; align-items: center; gap: .8rem; max-width: 250px;
}
.hero-badge .num {
  flex: none; width: 50px; height: 50px; border-radius: 12px;
  background: var(--grad-dark); color: #fff;
  display: grid; place-items: center; line-height: 1;
}
.hero-badge .num b { font-family: var(--ff-serif); font-size: 1.5rem; color: var(--gold); white-space: nowrap; }
.hero-badge .num span { display:none; }
.hero-badge small { font-size: .82rem; color: var(--muted); line-height: 1.3; }

/* hero variant for inner pages */
.page-hero { background: var(--slate); color: #fff; position: relative; overflow: hidden; }
.page-hero::before { content:""; position:absolute; inset:0; background: radial-gradient(900px 400px at 90% -20%, rgba(226,98,12,.18), transparent 60%), var(--grad-dark); }
.page-hero .wrap { position: relative; padding-block: clamp(48px, 6vw, 84px); }
.page-hero h1 { color: #fff; max-width: 18ch; }
.page-hero .lead { color: rgba(255,255,255,.82); }
.crumb { font-size: .85rem; color: rgba(255,255,255,.6); margin-bottom: 1rem; }
.crumb a { color: rgba(255,255,255,.75); }
.crumb a:hover { color: #fff; }

/* ---------- cards / grids ---------- */
.grid { display: grid; gap: 22px; }
.grid-2 { grid-template-columns: repeat(2, 1fr); }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.card {
  background: #fff; border: 1px solid var(--line);
  border-radius: var(--radius); padding: 26px;
  box-shadow: var(--shadow-sm); transition: transform .18s ease, box-shadow .18s ease, border-color .18s;
}
.card--link:hover { transform: translateY(-4px); box-shadow: var(--shadow); border-color: var(--slate-500); }
.card .ico {
  width: 46px; height: 46px; border-radius: 11px;
  display: grid; place-items: center; margin-bottom: 16px;
  background: linear-gradient(135deg, rgba(200,116,58,.16), rgba(200,116,58,.06));
  color: var(--accent-600);
}
.card .ico svg { width: 24px; height: 24px; }
.card h3 { margin-bottom: .35em; }
.card p { color: var(--muted); font-size: .98rem; margin: 0; }
.card .more { display: inline-flex; align-items: center; gap: .3em; margin-top: 1rem; font-weight: 600; font-size: .92rem; color: var(--accent-600); }

/* split content */
.split { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(32px, 5vw, 64px); align-items: center; }
.split img { border-radius: var(--radius); box-shadow: var(--shadow); aspect-ratio: 4/3; object-fit: cover; width: 100%; }
.split img.portrait { aspect-ratio: 4/5; max-width: 380px; object-position: top center; }
.split--reverse .split-media { order: 2; }

/* feature list */
.checks { list-style: none; padding: 0; margin: 1.2rem 0 0; display: grid; gap: .7rem; }
.checks li { display: flex; gap: .7rem; align-items: flex-start; }
.checks li::before {
  content: ""; flex: none; margin-top: .35em; width: 18px; height: 18px; border-radius: 50%;
  background: var(--accent) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='3.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='20 6 9 17 4 12'/%3E%3C/svg%3E") center/11px no-repeat;
}

/* stats band */
.stats { display: grid; grid-template-columns: repeat(4,1fr); gap: 22px; }
.stat { text-align: center; }
.stat b { display: block; font-family: var(--ff-serif); font-size: clamp(2rem,1.4rem+1.6vw,2.8rem); color: var(--slate-700); }
.stat span { color: var(--muted); font-size: .92rem; }
.section--dark .stat b { color: var(--gold); }
.section--dark .stat span { color: rgba(255,255,255,.7); }
h2 em { font-style: italic; color: var(--accent); }

/* certs strip */
.certs { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: clamp(28px,5vw,60px); }
.certs img { height: 64px; width: auto; opacity: .85; filter: saturate(.9); transition: opacity .2s, filter .2s; }
.certs img:hover { opacity: 1; filter: none; }

/* image en tête de contenu — flotte à droite, le texte l'enveloppe */
.feature-img {
  float: right; width: 44%; max-width: 420px; margin: .4rem 0 1.4rem 2rem;
  border-radius: var(--radius); box-shadow: var(--shadow);
  aspect-ratio: 4/3; object-fit: cover; object-position: center;
}
.feature-img--left { float: left; margin: .4rem 2rem 1.4rem 0; }
@media (max-width: 680px) {
  .feature-img, .feature-img--left { float: none; width: 100%; max-width: none; margin: 0 0 1.8rem; aspect-ratio: 16/9; }
}

/* carte conseil avec photo */
.card-photo { overflow: hidden; padding: 0; display: flex; flex-direction: column; }
.card-photo img { width: 100%; height: 200px; aspect-ratio: 16/10; object-fit: cover; flex: none; }
.card-photo .body { padding: 22px 24px 26px; }
.card-photo h3 { margin: 0 0 .35em; }
.card-photo p { color: var(--muted); font-size: .96rem; margin: 0; }
.card-photo .more { display: inline-flex; align-items: center; gap: .3em; margin-top: 1rem; font-weight: 600; font-size: .92rem; color: var(--accent-600); }

/* ---------- article (prose) ---------- */
.prose { max-width: 72ch; }
.prose::after { content: ""; display: block; clear: both; }
/* quand la prose contient une image flottante, on l'élargit pour laisser la place */
.prose:has(.feature-img) { max-width: 900px; }
.prose h2 { margin-top: 1.6em; }
.prose p { color: #34424f; }
.prose ul { padding-left: 1.2em; color: #34424f; }
.prose li { margin-bottom: .4em; }
.callout {
  clear: both;
  background: linear-gradient(135deg, rgba(31,58,82,.05), rgba(200,116,58,.06));
  border: 1px solid var(--line); border-left: 4px solid var(--accent);
  border-radius: var(--radius-sm); padding: 18px 22px; margin: 1.6rem 0;
}
/* les titres h2 dégagent aussi les images flottantes pour éviter tout chevauchement */
.prose h2 { clear: both; }
.callout strong { color: var(--slate-700); }

/* ---------- pricing ---------- */
.price-table { width: 100%; border-collapse: separate; border-spacing: 0; background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow-sm); }
.price-table th, .price-table td { padding: 16px 20px; text-align: left; border-bottom: 1px solid var(--line); }
.price-table thead th { background: var(--slate); color: #fff; font-family: var(--ff-sans); font-weight: 600; font-size: .85rem; letter-spacing: .03em; text-transform: uppercase; }
.price-table tbody tr:last-child td { border-bottom: 0; }
.price-table tbody tr:hover { background: var(--bg); }
.price-table .svc { font-weight: 600; color: var(--ink); }
.price-table .price { font-family: var(--ff-serif); font-size: 1.35rem; color: var(--accent-600); white-space: nowrap; }
.price-table small { color: var(--muted); font-weight: 400; display: block; font-size: .82rem; }
.price-note { color: var(--muted); font-size: .92rem; margin-top: 1rem; }

.price-cards { display: grid; grid-template-columns: repeat(3,1fr); gap: 22px; }
.price-card { background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius); padding: 28px; box-shadow: var(--shadow-sm); display: flex; flex-direction: column; }
.price-card h3 { margin-bottom: .2em; }
.price-card .amount { font-family: var(--ff-serif); font-size: 2.4rem; color: var(--slate-700); margin: .2em 0; }
.price-card .amount small { font-size: .9rem; color: var(--muted); font-family: var(--ff-sans); }
.price-card p { color: var(--muted); font-size: .95rem; }

/* ---------- contact / form ---------- */
.form-grid { display: grid; grid-template-columns: 1.1fr .9fr; gap: clamp(28px,4vw,52px); align-items: start; }
.field { margin-bottom: 1.1rem; }
.field label { display: block; font-weight: 600; font-size: .9rem; margin-bottom: .4rem; color: var(--ink); }
.field .req { color: var(--accent-600); }
.field input, .field select, .field textarea {
  width: 100%; font: inherit; font-size: 1rem; color: var(--ink);
  padding: .75em .9em; border: 1.5px solid var(--line); border-radius: var(--radius-sm);
  background: var(--paper); transition: border-color .15s, box-shadow .15s;
}
.field input:focus, .field select:focus, .field textarea:focus {
  outline: none; border-color: var(--slate-500); box-shadow: 0 0 0 3px rgba(63,111,156,.15);
}
.field textarea { resize: vertical; min-height: 140px; }
.form-msg { padding: .85em 1.1em; border-radius: var(--radius-sm); font-size: .95rem; margin-bottom: 1rem; display: none; }
.form-msg.show { display: block; }
.form-msg.ok { background: rgba(31,138,91,.12); color: var(--ok); border: 1px solid rgba(31,138,91,.3); }
.form-msg.err { background: rgba(192,57,43,.10); color: var(--err); border: 1px solid rgba(192,57,43,.3); }
.contact-aside { background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius); padding: 28px; box-shadow: var(--shadow-sm); }
.contact-item { display: flex; gap: .85rem; align-items: flex-start; margin-bottom: 1.2rem; }
.contact-item:last-child { margin-bottom: 0; }
.contact-item .ico { flex: none; width: 40px; height: 40px; border-radius: 10px; display: grid; place-items: center; background: rgba(31,58,82,.08); color: var(--slate-700); }
.contact-item .ico svg { width: 20px; height: 20px; }
.contact-item b { display: block; font-size: .95rem; }
.contact-item span, .contact-item a { color: var(--muted); font-size: .95rem; }

/* ---------- CTA band ---------- */
.cta-band { background: var(--grad-dark); color: #fff; border-radius: var(--radius); padding: clamp(34px,5vw,56px); text-align: center; position: relative; overflow: hidden; }
.cta-band::before { content:""; position:absolute; inset:0; background: radial-gradient(700px 300px at 50% -40%, rgba(226,98,12,.28), transparent 60%); }
.cta-band > * { position: relative; }
.cta-band h2 { color: #fff; }
.cta-band p { color: rgba(255,255,255,.82); max-width: 56ch; margin-inline: auto; }

/* ---------- footer ---------- */
.site-footer { background: var(--ink); color: rgba(255,255,255,.72); padding-block: 56px 28px; font-size: .94rem; }
.footer-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr; gap: 40px; }
.site-footer h4 { font-family: var(--ff-sans); color: #fff; font-size: .82rem; letter-spacing: .1em; text-transform: uppercase; margin: 0 0 1rem; }
.site-footer a { color: rgba(255,255,255,.72); display: block; padding: .22em 0; }
.site-footer a:hover { color: #fff; }
.footer-brand img { height: 44px; margin-bottom: 1rem; filter: brightness(0) invert(1); opacity: .92; }
.footer-bottom { border-top: 1px solid rgba(255,255,255,.12); margin-top: 40px; padding-top: 20px; display: flex; justify-content: space-between; flex-wrap: wrap; gap: 12px; font-size: .85rem; color: rgba(255,255,255,.55); }

/* ---------- utilities ---------- */
.mt-0 { margin-top: 0; }
.muted { color: var(--muted); }
.hide { display: none !important; }

/* ---------- responsive ---------- */
@media (max-width: 940px) {
  .hero .wrap { grid-template-columns: 1fr; }
  .hero-media { order: -1; max-width: 460px; }
  .split, .form-grid { grid-template-columns: 1fr; }
  .split--reverse .split-media { order: 0; }
  .grid-3, .price-cards { grid-template-columns: repeat(2,1fr); }
  .stats { grid-template-columns: repeat(2,1fr); }
  .footer-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 720px) {
  body { font-size: 16px; }
  .nav-links { display: none; }
  .burger { display: block; }
  .nav-cta.desktop-only { display: none; }
  .mobile-menu.open { display: block; background: var(--paper); border-bottom: 1px solid var(--line); padding: 14px 0; }
  .mobile-menu a { display: block; padding: .7em 22px; font-weight: 500; color: var(--ink); }
  .mobile-menu a:hover { background: var(--bg); }
  .mobile-menu .sub { padding-left: 38px; font-size: .92rem; color: var(--muted); }
  .grid-2, .grid-3, .price-cards { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr; gap: 28px; }
  .price-table thead { display: none; }
  .price-table, .price-table tbody, .price-table tr, .price-table td { display: block; width: 100%; }
  .price-table tr { border-bottom: 2px solid var(--line); padding: 8px 0; }
  .price-table td { border: 0; padding: 6px 20px; }
  .price-table td.price { padding-bottom: 14px; }
}
@media (prefers-reduced-motion: reduce) { * { scroll-behavior: auto !important; transition: none !important; } }
