/* ==========================================================================
   Diane Massé — dianemasse.com — V1 locale
   DA de référence : doc/da-infographies.md
   ========================================================================== */

:root {
  /* Couleurs — da-infographies.md */
  --ink: #37005B;
  --violet: #9452E7;
  --violet-deep: #380058;
  --violet-mid: #6430A8;
  --violet-light: #A068E8;
  --teal: #1E989C;
  --orange: #EC6600;
  --amber: #ECA500;
  --rose: #ED67B7;
  --green: #3BAE3B;

  --bg-lavande-clair: #ECE7F7;
  --bg-teal-clair: #C5EDF5;
  --bg-orange-clair: #FFE8D6;
  --bg-rose-clair: #FFD5EE;
  --bg-vert-clair: #D7F1C6;

  --white: #FFFFFF;
  --grid-line: rgba(148, 82, 231, 0.09);
  --border-lavande: #E3D8F7;

  --font-text: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  --font-title: 'Bricolage Grotesque', 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  --font-note: 'Gaegu', cursive;

  --radius-surface: 20px;
  --radius-card: 16px;
  --shadow-violet: 0 12px 32px rgba(148, 82, 231, 0.14);
  --section-gap: 32px;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--font-text);
  color: var(--ink);
  background: var(--white);
  -webkit-font-smoothing: antialiased;
}

.wrap {
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 24px;
}

.page {
  max-width: 1280px;
  margin: 0 auto;
  padding: var(--section-gap) 24px 0;
  display: flex;
  flex-direction: column;
  gap: var(--section-gap);
}

h1, h2, h3 {
  font-family: var(--font-title);
  font-weight: 800;
  letter-spacing: -0.02em;
  line-height: 1.1;
  margin: 0;
}

p { line-height: 1.6; margin: 0; }

a { color: inherit; text-decoration: none; }

img { max-width: 100%; display: block; }

/* ---------- Surfaces (fond dégradé + grille / fond foncé) ---------- */

.surface-light {
  background:
    repeating-linear-gradient(90deg, var(--grid-line) 0 1px, transparent 1px 25px),
    repeating-linear-gradient(0deg, var(--grid-line) 0 1px, transparent 1px 25px),
    linear-gradient(180deg, #FFFFFF 0%, #F9F5FF 45%, #F3E9FF 100%);
  border-radius: var(--radius-surface);
  border: 1px solid var(--border-lavande);
}

.surface-dark {
  background: linear-gradient(160deg, var(--ink) 0%, var(--violet-mid) 100%);
  border-radius: var(--radius-surface);
}

/* ---------- Pills / tags ---------- */

.pill {
  display: inline-block;
  font-size: 13px;
  font-weight: 600;
  padding: 6px 14px;
  border-radius: 100px;
  margin-bottom: 20px;
}

.pill-accent-violet { background: var(--bg-lavande-clair); color: var(--violet); }
.pill-accent-teal { background: var(--bg-teal-clair); color: var(--teal); }

.tag {
  display: inline-block;
  font-family: 'SF Mono', 'Menlo', monospace;
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  padding: 4px 10px;
  border-radius: 6px;
  margin-bottom: 14px;
}

.tag-violet { background: var(--bg-lavande-clair); color: var(--violet); }
.tag-teal { background: var(--bg-teal-clair); color: var(--teal); }
.tag-orange { background: var(--bg-orange-clair); color: var(--orange); }
.tag-rose { background: var(--bg-rose-clair); color: var(--rose); }

/* ---------- Buttons ---------- */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-family: var(--font-text);
  font-weight: 700;
  font-size: 15px;
  padding: 14px 24px;
  border-radius: 10px;
  border: none;
  cursor: pointer;
  transition: transform 0.15s ease, box-shadow 0.15s ease, background 0.15s ease;
  white-space: nowrap;
}

.btn-primary {
  background: var(--ink);
  color: var(--white);
}
.btn-primary:hover { transform: translateY(-1px); box-shadow: var(--shadow-violet); }

.btn-small { padding: 10px 18px; font-size: 14px; }

.btn-ghost {
  background: var(--white);
  color: var(--ink);
  border: 1.5px solid var(--border-lavande);
}
.btn-ghost:hover { background: var(--bg-lavande-clair); }

.btn-white {
  background: var(--white);
  color: var(--ink);
}
.btn-white:hover { transform: translateY(-1px); }

/* ---------- Nav ---------- */

.nav {
  position: sticky;
  top: 16px;
  z-index: 50;
}

.nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: rgba(255, 255, 255, 0.85);
  backdrop-filter: blur(10px);
  border: 1px solid var(--border-lavande);
  border-radius: var(--radius-surface);
  box-shadow: 0 8px 24px rgba(148, 82, 231, 0.10);
  padding: 12px 20px;
}

.logo { display: flex; align-items: center; }
.logo-img { height: 26px; width: auto; }

.nav-right {
  display: flex;
  align-items: center;
  gap: 32px;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 32px;
}

.nav-links > a {
  font-size: 14px;
  font-weight: 600;
  color: var(--ink);
  opacity: 0.75;
}
.nav-links > a:hover { opacity: 1; }

.has-dropdown { position: relative; }

.has-dropdown > a {
  display: inline-block;
  font-size: 14px;
  font-weight: 600;
  color: var(--ink);
  opacity: 0.75;
  padding: 8px 0;
}
.has-dropdown:hover > a, .has-dropdown:focus-within > a { opacity: 1; }

.mega-menu {
  position: absolute;
  top: 100%;
  left: 50%;
  transform: translateX(-50%);
  padding-top: 14px;
  display: none;
  z-index: 60;
}

.has-dropdown:hover .mega-menu,
.has-dropdown:focus-within .mega-menu {
  display: block;
}

.mega-menu-card {
  display: grid;
  grid-template-columns: 240px 230px;
  gap: 4px;
  background: var(--white);
  border: 1px solid var(--border-lavande);
  border-radius: 18px;
  box-shadow: var(--shadow-violet);
  padding: 10px;
}

.mega-preview {
  position: relative;
  border-radius: 12px;
  overflow: hidden;
  height: 230px;
  background: var(--ink);
}

.mega-preview-img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: top;
  transition: opacity 0.12s ease;
}

.mega-preview-caption {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  padding: 32px 14px 12px;
  background: linear-gradient(0deg, rgba(55, 0, 91, 0.92) 0%, rgba(55, 0, 91, 0) 100%);
}

.mega-preview-caption strong {
  display: block;
  color: var(--white);
  font-size: 13.5px;
  font-weight: 700;
}

.mega-preview-caption span {
  display: block;
  color: rgba(255, 255, 255, 0.75);
  font-size: 11.5px;
  margin-top: 2px;
}

.mega-list {
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding: 4px;
}

.mega-list-item {
  display: block;
  padding: 10px 12px;
  border-radius: 10px;
  transition: background 0.15s ease;
}
.mega-list-item:hover, .mega-list-item.active { background: var(--bg-lavande-clair); }

.mega-list-item strong {
  display: block;
  font-size: 13.5px;
  color: var(--ink);
  transition: color 0.15s ease;
}
.mega-list-item.active strong { color: var(--violet); }

.mega-list-item span {
  display: block;
  font-size: 12px;
  opacity: 0.6;
  margin-top: 3px;
}

/* ---------- Hero ---------- */

.hero { padding: 56px 48px; }

.hero-inner {
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  gap: 56px;
  align-items: center;
}

.hero h1 {
  font-size: 44px;
  margin-bottom: 22px;
}

.hero-sub {
  font-size: 18px;
  max-width: 46ch;
  margin-bottom: 32px;
  opacity: 0.88;
}

.hero-cta {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin-bottom: 22px;
}

.hero-trust {
  font-size: 13px;
  opacity: 0.55;
}

.hero-visual { position: relative; display: flex; justify-content: center; }

.hero-photo-frame {
  position: relative;
  width: 100%;
  max-width: 360px;
}

.hero-photo {
  width: 100%;
  aspect-ratio: 4 / 5;
  object-fit: cover;
  border-radius: 24px;
  box-shadow: var(--shadow-violet);
  border: 1px solid var(--border-lavande);
}

.floating-pill {
  position: absolute;
  background: var(--white);
  border: 1px solid var(--border-lavande);
  box-shadow: 0 8px 20px rgba(148, 82, 231, 0.12);
  border-radius: 100px;
  padding: 9px 16px;
  font-size: 13px;
  font-weight: 700;
  color: var(--ink);
}

.pill-1 { top: 8%; left: -12%; }
.pill-2 { top: 44%; right: -16%; }
.pill-3 { bottom: 6%; left: -8%; }

/* ---------- Ressources ---------- */

.resources { padding: 64px 48px; }

.section-head {
  max-width: 560px;
  margin: 0 auto 40px;
  text-align: center;
}

.section-head h2 {
  font-size: 32px;
  margin-bottom: 14px;
  color: var(--ink);
}

.section-head p {
  font-size: 16px;
  color: var(--ink);
  opacity: 0.75;
}

.resources .section-head h2 { color: var(--white); }
.resources .section-head p { color: rgba(255, 255, 255, 0.75); opacity: 1; }

.tabs-nav {
  display: flex;
  justify-content: center;
  gap: 4px;
  width: fit-content;
  margin: 0 auto 32px;
  background: rgba(255, 255, 255, 0.1);
  padding: 6px;
  border-radius: 100px;
}

.tab-btn {
  background: none;
  border: none;
  cursor: pointer;
  padding: 10px 22px;
  border-radius: 100px;
  font-family: var(--font-text);
  font-weight: 700;
  font-size: 14px;
  color: rgba(255, 255, 255, 0.65);
  transition: background 0.15s ease, color 0.15s ease;
}
.tab-btn:hover { color: var(--white); }
.tab-btn.active { background: var(--white); color: var(--ink); }

.tabs-panels-card {
  background: var(--white);
  border-radius: var(--radius-card);
  box-shadow: 0 20px 48px rgba(30, 0, 50, 0.25);
  overflow: hidden;
}

.tab-panel { display: none; padding: 40px; }
.tab-panel.active { display: block; }

.tab-panel-grid {
  display: grid;
  grid-template-columns: 0.8fr 1.2fr;
  gap: 40px;
  align-items: center;
}

.tab-panel-text h3 { font-size: 24px; margin-bottom: 12px; }
.tab-panel-text p { font-size: 15px; opacity: 0.75; margin-bottom: 24px; max-width: 40ch; }

.tab-panel-visual img {
  width: 100%;
  border-radius: 12px;
  border: 1px solid var(--border-lavande);
  box-shadow: 0 12px 28px rgba(148, 82, 231, 0.14);
}

/* ---------- Derniers articles ---------- */

.articles { padding: 8px 48px; }

.articles-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
}

.article-card {
  background: var(--white);
  border: 1px solid var(--border-lavande);
  border-radius: var(--radius-card);
  box-shadow: var(--shadow-violet);
  overflow: hidden;
  padding: 4px;
  display: flex;
  justify-content: center;
}

.article-card .substack-post-embed {
  width: 100%;
}

/* ---------- Bandeau newsletter (clôture) ---------- */

.closing-cta {
  padding: 64px 48px;
  text-align: center;
}

.closing-inner { max-width: 620px; margin: 0 auto; }

.closing-logo {
  height: 34px;
  width: auto;
  margin: 0 auto 32px;
}

.closing-punchline {
  color: var(--ink);
  font-size: 34px;
  margin-bottom: 32px;
}

.closing-embed {
  display: flex;
  justify-content: center;
}

.closing-embed iframe {
  width: 100%;
  max-width: 480px;
  border-radius: 12px;
  box-shadow: var(--shadow-violet);
}

.closing-fineprint {
  color: var(--ink);
  opacity: 0.5;
  font-size: 13px;
  margin-top: 18px;
}

/* ---------- Footer ---------- */

.footer { padding: 40px 0 40px; }

.footer-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 16px;
  border-top: 1px solid var(--border-lavande);
  padding-top: 32px;
}

.footer-identity {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 14px;
  font-weight: 600;
}

.avatar {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  object-fit: cover;
  border: 1px solid var(--border-lavande);
}

.footer-links { display: flex; gap: 24px; }
.footer-links a { font-size: 14px; font-weight: 600; opacity: 0.7; }
.footer-links a:hover { opacity: 1; }

.footer-copy {
  width: 100%;
  font-size: 12px;
  opacity: 0.45;
  margin-top: 8px;
}

/* ---------- Responsive ---------- */

@media (max-width: 900px) {
  .hero, .resources { padding: 40px 24px; }
  .hero-inner { grid-template-columns: 1fr; }
  .hero-visual { order: -1; margin-bottom: 12px; }
  .hero h1 { font-size: 32px; }
  .nav-links { display: none; }
  .floating-pill { display: none; }
  .tab-panel-grid { grid-template-columns: 1fr; }
  .tab-panel { padding: 24px; }
  .tabs-nav { max-width: 100%; overflow-x: auto; }
  .articles { padding: 8px 24px; }
  .articles-grid { grid-template-columns: 1fr; }
  .closing-cta { padding: 48px 24px; }
  .closing-punchline { font-size: 26px; }
}
