/* ============================================================
   MAD SARL — Landing page
   Palette : violet #7A6ED0 + blanc (sobre & corporate)
   ============================================================ */

:root {
  /* Bleu nuit hérité -> repointé sur la gamme violette (surfaces sombres / encre) */
  --navy-900: #241c57;
  --navy-800: #322766;
  --navy-700: #5648a8;
  --ink: #241f45;
  --slate: #5b5680;
  --muted: #8a85a6;
  --line: #e8e6f3;
  --bg: #ffffff;
  --bg-soft: #f5f3fc;
  --bg-dark: #221a52;
  /* Accents "or" hérités -> repointés sur le violet principal */
  --gold: #695ec0;
  --gold-soft: #b6afe6;
  --violet: #7A6ED0;
  --violet-600: #695ec0;
  --violet-700: #5648a8;
  --violet-soft: #b6afe6;

  --radius: 12px;
  --radius-sm: 8px;
  --shadow-sm: 0 1px 2px rgba(36, 28, 87, .07);
  --shadow-md: 0 12px 30px -12px rgba(36, 28, 87, .2);

  --font-body: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  --font-head: "Fraunces", Georgia, "Times New Roman", serif;

  --container: 1140px;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
}

body {
  margin: 0;
  font-family: var(--font-body);
  color: var(--ink);
  background: var(--bg);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

h1, h2, h3 {
  font-family: var(--font-head);
  font-weight: 600;
  line-height: 1.15;
  letter-spacing: -0.01em;
  color: var(--navy-900);
  margin: 0;
}

p { margin: 0 0 1rem; }
a { color: inherit; text-decoration: none; }
img, svg { max-width: 100%; }
ul { margin: 0; padding: 0; list-style: none; }

.container {
  width: 100%;
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 24px;
}

.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  background: var(--navy-900);
  color: #fff;
  padding: 10px 16px;
  z-index: 1000;
  border-radius: 0 0 var(--radius-sm) 0;
}
.skip-link:focus { left: 0; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: .5rem;
  padding: 13px 26px;
  border-radius: var(--radius-sm);
  font-weight: 600;
  font-size: .95rem;
  letter-spacing: .01em;
  cursor: pointer;
  border: 1px solid transparent;
  transition: transform .15s ease, background .2s ease, box-shadow .2s ease, color .2s ease;
}
.btn:active { transform: translateY(1px); }

.btn-primary {
  background: var(--violet);
  color: #fff;
  box-shadow: 0 10px 26px -10px rgba(105, 94, 192, .6);
}
.btn-primary:hover { background: var(--violet-600); box-shadow: 0 14px 30px -10px rgba(105, 94, 192, .75); }

.btn-ghost {
  background: transparent;
  color: var(--navy-900);
  border-color: var(--line);
}
.btn-ghost:hover { border-color: var(--navy-900); }

.btn-purple {
  background: var(--violet);
  color: #fff;
  box-shadow: 0 10px 26px -10px rgba(105, 94, 192, .7);
}
.btn-purple:hover { background: var(--violet-600); box-shadow: 0 14px 30px -10px rgba(105, 94, 192, .8); }

.btn-outline-light {
  background: transparent;
  color: #fff;
  border-color: rgba(255, 255, 255, .55);
}
.btn-outline-light:hover { border-color: #fff; background: rgba(255, 255, 255, .08); }

.btn-block { width: 100%; }

/* ---------- Header ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(255, 255, 255, .88);
  backdrop-filter: saturate(180%) blur(10px);
  border-bottom: 1px solid var(--line);
}
.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 70px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-head);
  font-weight: 600;
}
.brand-logo {
  display: block;
  height: 46px;
  width: auto;
  border-radius: 6px;
}
.brand-logo--footer { height: 60px; }

.nav { display: flex; align-items: center; }
.nav-menu {
  display: flex;
  align-items: center;
  gap: 30px;
}
.nav-menu a {
  font-size: .93rem;
  font-weight: 500;
  color: var(--slate);
  transition: color .2s ease;
}
.nav-menu a:hover { color: var(--navy-900); }
.nav-cta {
  padding: 9px 18px;
  border-radius: var(--radius-sm);
  background: var(--violet);
  color: #fff !important;
}
.nav-cta:hover { background: var(--violet-600); }

.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: 0;
  padding: 8px;
  cursor: pointer;
}
.nav-toggle span {
  width: 24px;
  height: 2px;
  background: var(--navy-900);
  border-radius: 2px;
  transition: transform .25s ease, opacity .2s ease;
}

/* ---------- Hero (two columns, dark) ---------- */
.hero {
  position: relative;
  padding: clamp(72px, 11vw, 130px) 0 clamp(120px, 15vw, 190px);
  background:
    radial-gradient(900px 480px at 88% -5%, rgba(122, 110, 208, .45), transparent 60%),
    radial-gradient(700px 500px at 5% 115%, rgba(122, 110, 208, .22), transparent 60%),
    linear-gradient(155deg, #241c57 0%, #2b2065 55%, #1e1849 100%);
  color: #ece9f6;
  overflow: hidden;
}
.hero-inner {
  display: grid;
  grid-template-columns: 1.15fr .85fr;
  gap: clamp(36px, 6vw, 72px);
  align-items: center;
}

.eyebrow {
  display: inline-block;
  font-size: .8rem;
  font-weight: 600;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--violet-soft);
  margin-bottom: 20px;
}
.hero-title {
  font-family: var(--font-body);
  font-weight: 800;
  letter-spacing: -0.035em;
  line-height: 1.02;
  color: #fff;
  font-size: clamp(2.6rem, 6vw, 4.4rem);
  margin-bottom: 24px;
}
.hero-lead {
  font-size: clamp(1.05rem, 2vw, 1.2rem);
  color: #bcb6d6;
  max-width: 540px;
  margin-bottom: 34px;
}
.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
}

/* Hero visual panel */
.hero-visual { justify-self: end; width: 100%; max-width: 420px; }
.hero-panel {
  background: rgba(255, 255, 255, .05);
  border: 1px solid rgba(255, 255, 255, .12);
  border-radius: 18px;
  padding: 28px 26px;
  backdrop-filter: blur(6px);
  box-shadow: 0 30px 60px -30px rgba(0, 0, 0, .6);
}
.hero-panel-eyebrow {
  display: block;
  font-size: .74rem;
  font-weight: 700;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--violet-soft);
  margin-bottom: 20px;
}
.hero-flow {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 24px;
}
.hero-node {
  flex: 1;
  text-align: center;
  font-size: .82rem;
  font-weight: 600;
  color: #ddd8ee;
  padding: 12px 6px;
  border-radius: 10px;
  background: rgba(255, 255, 255, .06);
  border: 1px solid rgba(255, 255, 255, .1);
}
.hero-node--mid {
  color: #fff;
  background: linear-gradient(180deg, var(--violet), var(--violet-600));
  border-color: transparent;
  box-shadow: 0 10px 24px -10px rgba(105, 94, 192, .8);
}
.hero-link {
  width: 18px;
  height: 2px;
  flex: none;
  background: rgba(183, 173, 251, .6);
}
.hero-panel-list { display: grid; gap: 12px; }
.hero-panel-list li {
  position: relative;
  padding-left: 26px;
  font-size: .92rem;
  color: #c3bde0;
}
.hero-panel-list li::before {
  content: "";
  position: absolute;
  left: 0;
  top: .35em;
  width: 15px;
  height: 15px;
  border-radius: 4px;
  background: rgba(122, 110, 208, .25);
  border: 1px solid var(--violet);
}

/* ---------- Services : cartes chevauchantes ---------- */
.services-overlap {
  position: relative;
  z-index: 5;
  margin-top: clamp(-140px, -12vw, -100px);
  padding-bottom: clamp(56px, 8vw, 96px);
}
.feature-cards {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
  align-items: start;
}
.feature-card {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 34px 30px;
  box-shadow: 0 24px 50px -24px rgba(15, 23, 51, .32);
  transition: transform .22s ease, box-shadow .22s ease;
}
.feature-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 30px 60px -24px rgba(15, 23, 51, .4);
}
.feature-card--raised {
  transform: translateY(-28px);
  box-shadow: 0 34px 66px -22px rgba(15, 23, 51, .45);
}
.feature-card--raised:hover { transform: translateY(-36px); }

.feature-icon {
  display: grid;
  place-items: center;
  width: 52px;
  height: 52px;
  border-radius: 13px;
  background: linear-gradient(180deg, rgba(122, 110, 208, .16), rgba(122, 110, 208, .08));
  color: var(--violet-600);
  margin-bottom: 20px;
}
.feature-icon svg { width: 26px; height: 26px; }
.feature-card h3 { font-size: 1.22rem; margin-bottom: 12px; }
.feature-card p { color: var(--slate); font-size: .97rem; margin-bottom: 20px; }
.feature-link {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  font-weight: 600;
  font-size: .92rem;
  color: var(--violet-600);
  transition: gap .2s ease, color .2s ease;
}
.feature-link:hover { gap: 12px; color: var(--violet); }

/* ---------- Sections ---------- */
.section {
  padding: clamp(64px, 9vw, 108px) 0;
}
.section-alt { background: var(--bg-soft); }

.section-head { max-width: 640px; }
.section-head.center {
  margin: 0 auto 56px;
  text-align: center;
}
.kicker {
  font-size: .78rem;
  font-weight: 700;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 14px;
}
.kicker.light { color: var(--gold-soft); }
.section-head h2 {
  font-size: clamp(1.7rem, 3.5vw, 2.5rem);
  margin-bottom: 18px;
}
.section-intro {
  color: var(--slate);
  font-size: 1.08rem;
}
.section-intro.light { color: #c6c0e0; }

.grid-2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(32px, 6vw, 72px);
  align-items: start;
}
.section-body p { color: var(--slate); }

/* ---------- Cards ---------- */
.cards {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 22px;
}
.card {
  background: var(--bg);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 30px 26px;
  box-shadow: var(--shadow-sm);
  transition: transform .2s ease, box-shadow .2s ease, border-color .2s ease;
}
.card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
  border-color: #d7ddeb;
}
.card-icon {
  display: grid;
  place-items: center;
  width: 46px;
  height: 46px;
  border-radius: 10px;
  background: rgba(15, 35, 64, .06);
  color: var(--navy-900);
  margin-bottom: 18px;
}
.card-icon svg { width: 24px; height: 24px; }
.card h3 { font-size: 1.18rem; margin-bottom: 10px; }
.card p { color: var(--slate); font-size: .96rem; margin: 0; }

/* ---------- Sectors ---------- */
.sectors {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 14px;
}
.sectors li {
  background: var(--bg);
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  padding: 18px 20px;
  font-weight: 500;
  color: var(--ink);
  position: relative;
  padding-left: 40px;
}
.sectors li::before {
  content: "";
  position: absolute;
  left: 18px;
  top: 50%;
  transform: translateY(-50%);
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--gold);
}
.sectors-note {
  text-align: center;
  color: var(--muted);
  margin-top: 30px;
  font-size: .98rem;
}

/* ---------- Section dark (valeurs) ---------- */
.section-dark {
  background:
    radial-gradient(900px 400px at 90% 0%, rgba(122, 110, 208, .35), transparent 55%),
    linear-gradient(160deg, #241c57 0%, #2c2168 60%, #201a4e 100%);
  color: #e7e5f6;
}
.section-dark h2 { color: #fff; }
.values {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 26px 32px;
}
.value {
  padding: 22px 24px;
  border-radius: var(--radius);
  background: rgba(255, 255, 255, .04);
  border: 1px solid rgba(255, 255, 255, .09);
}
.value h3 {
  color: #fff;
  font-size: 1.15rem;
  margin-bottom: 8px;
}
.value h3::before {
  content: "";
  display: inline-block;
  width: 18px;
  height: 2px;
  background: var(--gold);
  vertical-align: middle;
  margin-right: 10px;
}
.value p { color: #bdb7da; font-size: .95rem; margin: 0; }

/* ---------- Stats ---------- */
.stats { background: var(--bg-soft); border-bottom: 1px solid var(--line); }
.stats-inner {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
  padding: clamp(44px, 6vw, 68px) 24px;
  text-align: center;
}
.stat-num {
  display: block;
  font-family: var(--font-head);
  font-size: clamp(2.2rem, 5vw, 3rem);
  font-weight: 600;
  color: var(--navy-900);
  line-height: 1;
  margin-bottom: 10px;
}
.stat-label {
  color: var(--slate);
  font-size: .95rem;
  display: block;
  max-width: 220px;
  margin: 0 auto;
}

/* ---------- Contact ---------- */
.contact-grid { align-items: start; }
.contact-info { margin-top: 30px; display: grid; gap: 18px; }
.contact-info li { display: grid; gap: 2px; }
.ci-label {
  font-size: .78rem;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--muted);
  font-weight: 600;
}
.contact-info a { color: var(--navy-800); font-weight: 500; }
.contact-info a:hover { color: var(--gold); }

.contact-form {
  background: var(--bg);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: clamp(24px, 4vw, 36px);
  box-shadow: var(--shadow-md);
}
.field { margin-bottom: 18px; display: grid; gap: 7px; }
.field-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}
.field label {
  font-size: .85rem;
  font-weight: 600;
  color: var(--ink);
}
.field input,
.field textarea {
  width: 100%;
  padding: 12px 14px;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  font-family: inherit;
  font-size: .96rem;
  color: var(--ink);
  background: var(--bg-soft);
  transition: border-color .2s ease, box-shadow .2s ease, background .2s ease;
}
.field input:focus,
.field textarea:focus {
  outline: none;
  border-color: var(--violet);
  background: #fff;
  box-shadow: 0 0 0 3px rgba(122, 110, 208, .2);
}
.field textarea { resize: vertical; }
.form-note {
  margin: 14px 0 0;
  font-size: .82rem;
  color: var(--muted);
  text-align: center;
}

/* ---------- Footer ---------- */
.site-footer {
  background: var(--navy-900);
  color: #bdb7da;
}
.footer-inner {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1.2fr;
  gap: 32px;
  padding: 56px 24px 40px;
}
.footer-brand .brand-text { color: #fff; }
.footer-brand .brand-sub { color: #9790b8; }
.footer-brand p { margin-top: 14px; color: #9790b8; font-size: .92rem; }
.footer-nav { display: grid; gap: 12px; align-content: start; }
.footer-nav a { color: #bdb7da; font-size: .93rem; }
.footer-nav a:hover { color: var(--gold); }
.footer-legal p { margin: 0 0 6px; font-size: .88rem; color: #9790b8; }
.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, .08);
}
.footer-bottom .container {
  display: flex;
  justify-content: center;
  padding-top: 20px;
  padding-bottom: 24px;
}
.footer-bottom p { margin: 0; font-size: .85rem; color: #8b83ab; }

/* ============================================================
   Responsive
   ============================================================ */
@media (max-width: 940px) {
  .cards { grid-template-columns: repeat(2, 1fr); }
  .sectors { grid-template-columns: repeat(2, 1fr); }
  .stats-inner { grid-template-columns: repeat(2, 1fr); }
  .footer-inner { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 880px) {
  .hero-inner { grid-template-columns: 1fr; }
  .hero-visual { display: none; }
  .hero { padding-bottom: clamp(130px, 22vw, 170px); }
  .feature-cards { grid-template-columns: 1fr; max-width: 460px; margin: 0 auto; }
  .feature-card--raised { transform: none; }
  .feature-card--raised:hover { transform: translateY(-6px); }
  .services-overlap { margin-top: clamp(-120px, -18vw, -90px); }
}

@media (max-width: 760px) {
  .nav-toggle { display: flex; }
  .nav-menu {
    position: absolute;
    top: 70px;
    left: 0;
    right: 0;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    background: #fff;
    border-bottom: 1px solid var(--line);
    box-shadow: var(--shadow-md);
    padding: 8px 0;
    max-height: 0;
    overflow: hidden;
    transition: max-height .28s ease;
  }
  .nav-menu.open { max-height: 360px; }
  .nav-menu li { border-top: 1px solid var(--line); }
  .nav-menu li:first-child { border-top: 0; }
  .nav-menu a {
    display: block;
    padding: 14px 24px;
  }
  .nav-cta {
    margin: 8px 24px;
    text-align: center;
    padding: 12px;
  }
  .nav-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
  .nav-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
  .nav-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

  .grid-2 { grid-template-columns: 1fr; }
  .values { grid-template-columns: 1fr; }
}

@media (max-width: 560px) {
  .cards { grid-template-columns: 1fr; }
  .sectors { grid-template-columns: 1fr; }
  .stats-inner { grid-template-columns: 1fr 1fr; }
  .field-row { grid-template-columns: 1fr; }
  .footer-inner { grid-template-columns: 1fr; }
  .hero-actions .btn { flex: 1; }
}
