/* =====================================================================
   VS FINANCEMENTS — Feuille de style principale
   ---------------------------------------------------------------------
   POUR CHANGER LES COULEURS DE TOUT LE SITE :
   modifiez uniquement les variables ci-dessous (--brand, --accent...)
   avec les codes couleurs exacts de votre logo.
   ===================================================================== */

:root {
  /* --- Couleurs de marque (reprises du logo : bleu marine + vert) --- */
  --brand:        #0d2b52;   /* Bleu marine principal */
  --brand-dark:   #081d3a;   /* Bleu marine foncé (pied de page, survol) */
  --brand-light:  #e9f0f8;   /* Fond bleu très clair */
  --accent:       #8cc63f;   /* Vert lime (flamme du logo) */
  --accent-dark:  #6ea82e;   /* Vert plus soutenu */
  --green-deep:   #2f8f3e;   /* Vert profond du logo */

  /* --- Couleurs neutres --- */
  --ink:          #1c2733;
  --muted:        #5b6875;
  --line:         #e2e8ee;
  --bg:           #ffffff;
  --bg-soft:      #f5f8fc;
  --ok:           #2f8f3e;

  --radius:   14px;
  --radius-sm: 9px;
  --shadow:   0 10px 30px rgba(13,43,82,.10);
  --shadow-sm: 0 4px 14px rgba(13,43,82,.07);
  --maxw: 1160px;
  --font: "Segoe UI", system-ui, -apple-system, Roboto, Helvetica, Arial, sans-serif;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--font);
  color: var(--ink);
  background: var(--bg);
  line-height: 1.6;
  font-size: 17px;
}
h1, h2, h3, h4 { color: var(--brand-dark); line-height: 1.2; margin: 0 0 .5em; }
h1 { font-size: clamp(1.9rem, 4vw, 2.9rem); }
h2 { font-size: clamp(1.5rem, 3vw, 2.1rem); }
h3 { font-size: 1.2rem; }
p { margin: 0 0 1rem; }
a { color: var(--brand); }
img { max-width: 100%; display: block; }

.container { max-width: var(--maxw); margin: 0 auto; padding: 0 22px; }
.section { padding: 72px 0; }
.section-soft { background: var(--bg-soft); }
.center { text-align: center; }
.lead { font-size: 1.18rem; color: var(--muted); max-width: 720px; }
.center .lead { margin-left: auto; margin-right: auto; }
.eyebrow {
  text-transform: uppercase; letter-spacing: .14em; font-size: .8rem;
  font-weight: 700; color: var(--green-deep); margin-bottom: .6rem;
}

/* ---------- Boutons ---------- */
.btn {
  display: inline-flex; align-items: center; gap: .5rem;
  padding: .82rem 1.5rem; border-radius: 999px; font-weight: 600;
  text-decoration: none; cursor: pointer; border: 2px solid transparent;
  font-size: 1rem; transition: .18s ease;
}
.btn-primary { background: var(--brand); color: #fff; }
.btn-primary:hover { background: var(--brand-dark); transform: translateY(-1px); }
.btn-accent { background: var(--accent); color: #14320a; }
.btn-accent:hover { background: var(--accent-dark); }
.btn-ghost { background: transparent; color: var(--brand); border-color: var(--brand); }
.btn-ghost:hover { background: var(--brand); color: #fff; }
.btn-lg { padding: 1rem 1.9rem; font-size: 1.05rem; }

/* ---------- En-tête / navigation ---------- */
.site-header {
  position: sticky; top: 0; z-index: 50; background: #fff;
  border-bottom: 1px solid var(--line); box-shadow: 0 2px 12px rgba(13,43,82,.05);
}

/* Bandeau contact (au-dessus du menu) */
.topbar { background: var(--brand-dark); color: #cfe0f0; font-size: .84rem; }
.topbar-in { display: flex; align-items: center; justify-content: space-between; min-height: 40px; padding-top: 6px; padding-bottom: 6px; gap: 10px; flex-wrap: wrap; }
.topbar a { color: #dbe7f3; text-decoration: none; }
.topbar a:hover { color: #fff; }
.topbar-left { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.topbar .sep { opacity: .4; }
.topbar-broker { font-weight: 700; color: #fff !important; background: rgba(255,255,255,.10); padding: .3rem .8rem; border-radius: 999px; }
.topbar-broker:hover { background: var(--accent); color: #14320a !important; }

/* Barre de navigation */
.nav { display: flex; align-items: center; justify-content: space-between; height: 74px; }
.brand { display: flex; align-items: center; gap: .7rem; text-decoration: none; }
.brand .logo-box { width: 48px; height: 48px; flex: 0 0 auto; }
.brand > span { display: flex; flex-direction: column; line-height: 1.15; }
.brand .brand-name { font-weight: 800; color: var(--brand-dark); font-size: 1.2rem; }
.brand .brand-sub { font-size: .72rem; color: var(--muted); letter-spacing: .03em; }

.nav-links { display: flex; align-items: center; gap: .15rem; list-style: none; margin: 0; padding: 0; }
.nav-links > li { position: relative; }
.nav-links a {
  display: inline-flex; align-items: center; gap: .25rem;
  text-decoration: none; color: var(--ink); font-weight: 600; font-size: .95rem;
  padding: .55rem .8rem; border-radius: 9px; transition: .15s;
}
.nav-links a:hover { background: var(--brand-light); color: var(--brand-dark); }
/* Onglet actif : soulignement vert */
.nav-links > li > a.active { color: var(--brand); }
.nav-links > li > a.active::after {
  content: ""; position: absolute; left: .8rem; right: .8rem; bottom: -2px;
  height: 3px; border-radius: 3px; background: var(--accent);
}
.caret { font-style: normal; font-size: .7rem; opacity: .8; transition: transform .18s; }
.has-drop:hover .caret { transform: rotate(180deg); }
.nav-cta { margin-left: .5rem; }
.nav-cta a.btn { color: #14320a; padding: .6rem 1.1rem; }

/* Menu déroulant "Nos services" */
.drop {
  position: absolute; top: calc(100% + 8px); left: 0; min-width: 250px;
  background: #fff; border: 1px solid var(--line); border-radius: 12px;
  box-shadow: var(--shadow); padding: 8px; list-style: none; margin: 0;
  opacity: 0; visibility: hidden; transform: translateY(6px); transition: .16s;
}
.has-drop:hover .drop, .has-drop:focus-within .drop { opacity: 1; visibility: visible; transform: translateY(0); }
.drop::before { content: ""; position: absolute; top: -8px; left: 0; right: 0; height: 8px; }
.drop a { display: block; padding: .6rem .8rem; font-size: .92rem; font-weight: 600; border-radius: 8px; color: var(--ink); }
.drop a:hover { background: var(--brand-light); color: var(--brand); }

/* Bouton hamburger */
.nav-toggle { display: none; background: none; border: 0; cursor: pointer; padding: 8px; }
.nav-toggle span { display: block; width: 26px; height: 3px; background: var(--brand-dark); border-radius: 3px; margin: 5px 0; transition: .25s; }
.nav-toggle.is-open span:nth-child(1) { transform: translateY(8px) rotate(45deg); }
.nav-toggle.is-open span:nth-child(2) { opacity: 0; }
.nav-toggle.is-open span:nth-child(3) { transform: translateY(-8px) rotate(-45deg); }

@media (max-width: 1000px) {
  .topbar-in { justify-content: center; }
  .topbar .sep { display: none; }
  .nav-toggle { display: block; }
  .nav-links {
    position: absolute; top: 100%; left: 0; right: 0; background: #fff;
    flex-direction: column; align-items: stretch; gap: 2px; padding: 10px 16px 20px;
    border-bottom: 1px solid var(--line); box-shadow: var(--shadow);
    display: none; max-height: 80vh; overflow-y: auto;
  }
  .nav-links.open { display: flex; }
  .nav-links > li > a { padding: .85rem .6rem; }
  .nav-links > li > a.active::after { display: none; }
  .nav-links > li > a.active { background: var(--brand-light); }
  /* Sous-menu services affiché en liste indentée sur mobile */
  .drop {
    position: static; opacity: 1; visibility: visible; transform: none;
    box-shadow: none; border: 0; border-left: 3px solid var(--brand-light);
    border-radius: 0; padding: 0 0 0 12px; margin: 2px 0 6px 8px; min-width: 0;
  }
  .caret { display: none; }
  .nav-cta { margin: .6rem 0 0; }
  .nav-cta a.btn { justify-content: center; }
}

/* ---------- Hero ---------- */
.hero { background: linear-gradient(160deg, var(--brand-light) 0%, #fff 70%); padding: 80px 0 70px; }
.hero-grid { display: grid; grid-template-columns: 1.1fr .9fr; gap: 48px; align-items: center; }
.hero h1 span { color: var(--brand); }
.hero h1 .g { color: var(--green-deep); }
.hero-actions { display: flex; flex-wrap: wrap; gap: 14px; margin-top: 26px; }
.hero-badges { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 28px; }
.badge {
  background: #fff; border: 1px solid var(--line); border-radius: 999px;
  padding: .45rem .95rem; font-size: .86rem; font-weight: 600; color: var(--brand-dark);
  box-shadow: var(--shadow-sm);
}
.hero-card {
  background: #fff; border-radius: var(--radius); box-shadow: var(--shadow);
  padding: 26px; border: 1px solid var(--line);
}
.hero-card h3 { color: var(--brand); }
@media (max-width: 860px) { .hero-grid { grid-template-columns: 1fr; gap: 30px; } }

/* ---------- Grilles de cartes ---------- */
.grid { display: grid; gap: 24px; }
.grid-2 { grid-template-columns: repeat(2, 1fr); }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-4 { grid-template-columns: repeat(4, 1fr); }
@media (max-width: 900px) { .grid-3, .grid-4 { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 620px) { .grid-2, .grid-3, .grid-4 { grid-template-columns: 1fr; } }

.card {
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius);
  padding: 28px; box-shadow: var(--shadow-sm); transition: .18s ease;
}
.card:hover { transform: translateY(-3px); box-shadow: var(--shadow); }
.card .ico {
  width: 52px; height: 52px; border-radius: 12px; background: var(--brand-light);
  display: grid; place-items: center; margin-bottom: 16px; font-size: 1.5rem;
}
.card h3 { margin-bottom: .4rem; }
.card p { color: var(--muted); margin-bottom: .6rem; }
.card a.more { font-weight: 700; text-decoration: none; font-size: .95rem; color: var(--green-deep); }
.card a.more::after { content: " →"; }

.tag {
  display: inline-block; font-size: .72rem; font-weight: 700; text-transform: uppercase;
  letter-spacing: .06em; color: var(--green-deep); background: #eef7e4;
  padding: .25rem .6rem; border-radius: 6px; margin-bottom: .7rem;
}

/* ---------- Bandeau CTA ---------- */
.cta-band { background: linear-gradient(135deg, var(--brand), var(--brand-dark)); color: #fff; }
.cta-band h2 { color: #fff; }
.cta-band p { color: rgba(255,255,255,.85); }
.cta-band .btn-primary { background: var(--accent); color: #14320a; }
.cta-band .btn-primary:hover { background: var(--accent-dark); }
.cta-band .btn-ghost { color: #fff; border-color: rgba(255,255,255,.6); }
.cta-band .btn-ghost:hover { background: #fff; color: var(--brand-dark); }

/* ---------- Page header ---------- */
.page-head { background: var(--brand-light); padding: 54px 0 46px; border-bottom: 1px solid var(--line); }
.breadcrumb { font-size: .85rem; color: var(--muted); margin-bottom: .4rem; }
.breadcrumb a { color: var(--muted); text-decoration: none; }

/* ---------- Simulateurs ---------- */
.sim-tabs { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 26px; }
.sim-tab {
  border: 1px solid var(--line); background: #fff; color: var(--brand-dark);
  padding: .7rem 1.2rem; border-radius: 999px; font-weight: 700; cursor: pointer; font-size: .95rem;
}
.sim-tab.active { background: var(--brand); color: #fff; border-color: var(--brand); }
.sim-panel { display: none; }
.sim-panel.active { display: block; }
.sim-layout { display: grid; grid-template-columns: 1fr 1fr; gap: 28px; align-items: start; }
@media (max-width: 820px) { .sim-layout { grid-template-columns: 1fr; } }

.form-card, .result-card {
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius);
  padding: 26px; box-shadow: var(--shadow-sm);
}
.result-card { background: var(--brand-dark); color: #fff; border: 0; }
.result-card h3 { color: #fff; }
.field { margin-bottom: 18px; }
.field label { display: block; font-weight: 600; margin-bottom: .35rem; font-size: .95rem; }
.field .hint { font-size: .8rem; color: var(--muted); }
.field input, .field select {
  width: 100%; padding: .7rem .8rem; border: 1px solid var(--line); border-radius: var(--radius-sm);
  font-size: 1rem; font-family: inherit; color: var(--ink); background: #fff;
}
.field input:focus, .field select:focus { outline: 2px solid var(--brand); border-color: var(--brand); }
.range-row { display: flex; align-items: center; gap: 12px; }
.range-row input[type=range] { flex: 1; accent-color: var(--green-deep); }
.range-val { min-width: 96px; text-align: right; font-weight: 700; color: var(--brand); }

.result-hero { text-align: center; padding: 10px 0 18px; border-bottom: 1px solid rgba(255,255,255,.15); margin-bottom: 18px; }
.result-hero .amount { font-size: 2.6rem; font-weight: 800; color: var(--accent); line-height: 1; }
.result-hero .amount span { font-size: 1.1rem; font-weight: 600; }
.result-line { display: flex; justify-content: space-between; padding: .5rem 0; border-bottom: 1px dashed rgba(255,255,255,.15); }
.result-line:last-child { border-bottom: 0; }
.result-line b { color: #fff; }
.result-note { font-size: .8rem; color: rgba(255,255,255,.7); margin-top: 16px; }

/* ---------- Étapes / process ---------- */
.steps { counter-reset: step; display: grid; gap: 20px; }
.step { position: relative; padding-left: 62px; }
.step::before {
  counter-increment: step; content: counter(step);
  position: absolute; left: 0; top: 0; width: 42px; height: 42px; border-radius: 50%;
  background: var(--green-deep); color: #fff; display: grid; place-items: center; font-weight: 800;
}
.step h3 { margin-bottom: .2rem; }

/* ---------- Accordéon FAQ ---------- */
.accordion { border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; background: #fff; }
.acc-item + .acc-item { border-top: 1px solid var(--line); }
.acc-q {
  width: 100%; text-align: left; background: none; border: 0; cursor: pointer;
  padding: 18px 22px; font-size: 1.05rem; font-weight: 700; color: var(--brand-dark);
  display: flex; justify-content: space-between; align-items: center; gap: 12px;
}
.acc-q::after { content: "+"; font-size: 1.5rem; color: var(--green-deep); flex: 0 0 auto; }
.acc-item.open .acc-q::after { content: "−"; }
.acc-a { padding: 0 22px; max-height: 0; overflow: hidden; transition: .25s ease; color: var(--muted); }
.acc-item.open .acc-a { padding: 0 22px 20px; max-height: 500px; }

/* ---------- Embed formulaire ---------- */
.embed-slot {
  border: 2px dashed var(--brand); border-radius: var(--radius); background: var(--brand-light);
  padding: 34px; text-align: center; color: var(--brand-dark);
}
.embed-slot code { background: #fff; padding: .15rem .4rem; border-radius: 5px; font-size: .85rem; }
.embed-slot iframe { width: 100%; border: 0; min-height: 680px; background: #fff; border-radius: var(--radius); }

/* Cadre pour comparateur partenaire (assurance emprunteur) */
.embed-frame {
  border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden;
  box-shadow: var(--shadow-sm); background: #fff;
  height: 1100px; max-height: 88vh;
}
.embed-frame iframe { width: 100%; height: 100%; border: 0; display: block; }
@media (max-width: 640px) { .embed-frame { height: 1400px; max-height: none; } }

/* ---------- Article / prose ---------- */
.prose { max-width: 760px; }
.prose h2 { margin-top: 1.8em; }
.prose ul { padding-left: 1.2rem; }
.prose li { margin-bottom: .4rem; }
.callout {
  background: var(--brand-light); border-left: 4px solid var(--brand);
  padding: 16px 20px; border-radius: var(--radius-sm); margin: 1.4rem 0;
}
.callout.gold { background: #eef7e4; border-left-color: var(--green-deep); }

/* ---------- Espace courtiers ---------- */
.locked {
  background: linear-gradient(135deg, var(--brand-dark), #04162c); color: #fff;
  border-radius: var(--radius); padding: 40px; text-align: center; box-shadow: var(--shadow);
}
.locked h2 { color: #fff; }
.app-link {
  display: flex; align-items: center; gap: 14px; text-decoration: none;
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 18px 20px;
  color: var(--ink); font-weight: 600; transition: .16s; box-shadow: var(--shadow-sm);
}
.app-link:hover { transform: translateY(-2px); box-shadow: var(--shadow); border-color: var(--green-deep); }
.app-link .app-ico { width: 40px; height: 40px; border-radius: 9px; background: var(--brand-light); display: grid; place-items: center; font-size: 1.3rem; }

/* ---------- Pied de page ---------- */
.site-footer { background: var(--brand-dark); color: #cfdbe4; padding: 56px 0 26px; margin-top: 10px; }
.footer-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1fr; gap: 30px; }
@media (max-width: 820px) { .footer-grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 520px) { .footer-grid { grid-template-columns: 1fr; } }
.site-footer h4 { color: #fff; font-size: .95rem; text-transform: uppercase; letter-spacing: .08em; margin-bottom: 1rem; }
.site-footer a { color: #cfdbe4; text-decoration: none; display: block; padding: .28rem 0; font-size: .95rem; }
.site-footer a:hover { color: var(--accent); }
.footer-bottom {
  border-top: 1px solid rgba(255,255,255,.12); margin-top: 40px; padding-top: 20px;
  font-size: .82rem; color: #9fb3c1; display: flex; justify-content: space-between; flex-wrap: wrap; gap: 10px;
}

/* ---------- Divers ---------- */
.mono { font-variant-numeric: tabular-nums; }
.mt-0 { margin-top: 0; }
.stat { text-align: center; }
.stat .num { font-size: 2.3rem; font-weight: 800; color: var(--brand); line-height: 1; }
.stat .lbl { color: var(--muted); font-size: .95rem; margin-top: .3rem; }
.partner-row { display: flex; flex-wrap: wrap; gap: 14px; align-items: center; justify-content: center; }
.partner {
  background: #fff; border: 1px solid var(--line); border-radius: 10px; padding: .7rem 1.3rem;
  font-weight: 800; color: var(--brand-dark); box-shadow: var(--shadow-sm); letter-spacing: .02em;
}
.disclaimer { font-size: .8rem; color: var(--muted); }
