/* Commento IA — feuille de style unique du site */

:root {
  --ink: #0f2a22;
  --ink-soft: #4a5f57;
  --bg: #f7f9f5;
  --surface: #ffffff;
  --surface-2: #eef4ea;
  --border: #dbe4d6;
  --brand: #003024;
  --brand-2: #0c4a38;
  --lime: #aaf051;
  --lime-soft: #e6f8cf;
  --link: #0b6b4c;
  --danger: #b3261e;
  --danger-bg: #fdecea;
  --ok: #1e6b34;
  --ok-bg: #e7f4ea;
  --radius: 14px;
  --radius-sm: 8px;
  --shadow: 0 10px 30px rgba(0, 48, 36, 0.08);
  --max: 1080px;
  color-scheme: light;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme='light']) {
    --ink: #e7efe9;
    --ink-soft: #a5b8ae;
    --bg: #0d1714;
    --surface: #13211c;
    --surface-2: #182a23;
    --border: #26392f;
    --brand: #aaf051;
    --brand-2: #c4f582;
    --lime: #aaf051;
    --lime-soft: #1f3a19;
    --link: #b9f070;
    --danger: #ffb4ab;
    --danger-bg: #3d1f1d;
    --ok: #9fd8ad;
    --ok-bg: #1d3524;
    --shadow: 0 10px 30px rgba(0, 0, 0, 0.35);
    color-scheme: dark;
  }
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font: 16px/1.6 -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
}
img { max-width: 100%; height: auto; }
a { color: var(--link); }
h1, h2, h3 { line-height: 1.2; letter-spacing: -0.01em; margin: 0 0 0.5em; }
h1 { font-size: clamp(2rem, 5vw, 3.2rem); }
h2 { font-size: clamp(1.5rem, 3.5vw, 2.1rem); }
h3 { font-size: 1.15rem; }
p { margin: 0 0 1em; }
[hidden] { display: none !important; }

.wrap { width: min(var(--max), 100% - 32px); margin-inline: auto; }
.narrow { width: min(460px, 100% - 32px); margin-inline: auto; }
.prose { width: min(760px, 100% - 32px); margin-inline: auto; }
.muted { color: var(--ink-soft); }
.center { text-align: center; }

/* ---------- En-tête / pied ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 10;
  background: color-mix(in srgb, var(--bg) 88%, transparent);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--border);
}
.site-header .wrap { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 64px; }
.logo { display: inline-flex; align-items: center; gap: 10px; color: var(--ink); font-weight: 800; text-decoration: none; font-size: 1.1rem; }
.logo img { width: 32px; height: 32px; }
.nav { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; justify-content: flex-end; }
.nav a { color: var(--ink); text-decoration: none; padding: 8px 10px; border-radius: 8px; font-weight: 600; font-size: 0.95rem; }
.nav a:hover { background: var(--surface-2); }
.nav .credits-pill { background: var(--lime-soft); color: var(--brand); }
@media (max-width: 560px) {
  .nav .hide-sm { display: none; }
}

.site-footer { margin-top: 80px; padding: 32px 0 40px; border-top: 1px solid var(--border); color: var(--ink-soft); font-size: 0.9rem; }
.site-footer .wrap { display: flex; flex-wrap: wrap; gap: 12px 24px; justify-content: space-between; }
.site-footer nav { display: flex; flex-wrap: wrap; gap: 8px 18px; }
.site-footer a { color: var(--ink-soft); }

/* ---------- Boutons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 22px;
  border-radius: 999px;
  border: 2px solid transparent;
  font: inherit;
  font-weight: 700;
  text-decoration: none;
  cursor: pointer;
  transition: transform 0.15s ease, background 0.15s ease;
}
.btn:hover { transform: translateY(-1px); }
.btn:disabled { opacity: 0.55; cursor: not-allowed; transform: none; }
.btn-primary { background: var(--brand); color: #fff; }
.btn-primary:hover { background: var(--brand-2); }
@media (prefers-color-scheme: dark) {
  :root:not([data-theme='light']) .btn-primary { color: #0d1714; }
}
.btn-lime { background: var(--lime); color: #003024; }
.btn-outline { border-color: var(--brand); color: var(--brand); background: transparent; }
.btn-outline:hover { background: var(--surface-2); }
.btn-danger { background: var(--danger); color: #fff; }
.btn-block { width: 100%; }
.btn img { width: 20px; height: 20px; }

/* ---------- Formulaires ---------- */
.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 24px;
  box-shadow: var(--shadow);
}
.form-page { padding: 56px 0; }
.form-page h1 { font-size: 1.8rem; }
label { display: block; font-weight: 600; margin-bottom: 14px; }
label small { font-weight: 400; color: var(--ink-soft); }
input[type='email'], input[type='password'], input[type='text'] {
  display: block;
  width: 100%;
  margin-top: 6px;
  padding: 12px 14px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--surface);
  color: var(--ink);
  font: inherit;
}
input:focus-visible, .btn:focus-visible, a:focus-visible, summary:focus-visible {
  outline: 3px solid var(--lime);
  outline-offset: 2px;
}
label.check { display: flex; gap: 10px; align-items: flex-start; font-weight: 400; }
label.check input { margin-top: 5px; width: 18px; height: 18px; flex: none; }
.form-links { margin-top: 16px; font-size: 0.95rem; }

.alert { padding: 12px 14px; border-radius: var(--radius-sm); margin-bottom: 16px; background: var(--danger-bg); color: var(--danger); }
.alert.ok { background: var(--ok-bg); color: var(--ok); }

/* ---------- Landing ---------- */
.hero { padding: 64px 0 40px; }
.hero .wrap { display: grid; grid-template-columns: 1.1fr 0.9fr; gap: 48px; align-items: center; }
@media (max-width: 860px) { .hero .wrap { grid-template-columns: 1fr; } }
.eyebrow { display: inline-block; padding: 4px 12px; border-radius: 999px; background: var(--lime-soft); color: var(--brand); font-weight: 700; font-size: 0.85rem; margin-bottom: 16px; }
.hero h1 em { font-style: normal; background: linear-gradient(transparent 62%, var(--lime) 62%); }
@media (prefers-color-scheme: dark) {
  :root:not([data-theme='light']) .hero h1 em { background: none; color: var(--lime); }
}
.lead { font-size: 1.2rem; color: var(--ink-soft); max-width: 36em; }
.cta-row { display: flex; flex-wrap: wrap; gap: 12px; margin: 24px 0 12px; }
.fine { font-size: 0.9rem; color: var(--ink-soft); }

/* Maquette du panneau */
.mock {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 18px;
  box-shadow: var(--shadow);
  overflow: hidden;
  font-size: 0.92rem;
}
.mock-top { display: flex; justify-content: space-between; align-items: center; padding: 12px 16px; border-bottom: 1px solid var(--border); font-weight: 700; }
.mock-top span:last-child { background: var(--lime-soft); color: var(--brand); padding: 2px 10px; border-radius: 999px; font-size: 0.8rem; }
.mock-body { padding: 16px; display: grid; gap: 10px; }
.mock-post { background: var(--surface-2); border-radius: 10px; padding: 10px 12px; color: var(--ink-soft); }
.mock-post strong { color: var(--ink); display: block; }
.mock-sugg { border: 1px solid var(--border); border-radius: 10px; padding: 10px 12px; }
.mock-sugg .tag { display: inline-block; font-size: 0.75rem; font-weight: 700; color: var(--link); margin-bottom: 2px; }

.section { padding: 64px 0; }
.section-alt { background: var(--surface-2); }
.section-head { max-width: 640px; margin-bottom: 32px; }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.grid-2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: 20px; }
@media (max-width: 860px) { .grid-3, .grid-2 { grid-template-columns: 1fr; } }
.step-num { display: grid; place-items: center; width: 36px; height: 36px; border-radius: 50%; background: var(--brand); color: var(--lime); font-weight: 800; margin-bottom: 12px; }
@media (prefers-color-scheme: dark) {
  :root:not([data-theme='light']) .step-num { color: #0d1714; }
}
.example { margin-top: 12px; padding: 12px; border-radius: var(--radius-sm); background: var(--surface-2); font-size: 0.92rem; }
.example .before { color: var(--ink-soft); font-style: italic; }
.example .arrow { display: block; margin: 6px 0; color: var(--link); font-weight: 700; }

.checks { list-style: none; padding: 0; margin: 0; display: grid; gap: 10px; }
.checks li { padding-left: 30px; position: relative; }
.checks li::before { content: ''; position: absolute; left: 0; top: 4px; width: 18px; height: 18px; border-radius: 50%; background: var(--lime); }
.checks li::after { content: ''; position: absolute; left: 6px; top: 8px; width: 6px; height: 9px; border: solid #003024; border-width: 0 2px 2px 0; transform: rotate(45deg); }

.pricing { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 20px; }
.price-card { display: flex; flex-direction: column; gap: 8px; }
.price-card.featured { border: 2px solid var(--brand); }
.price { font-size: 2rem; font-weight: 800; }
.price small { font-size: 0.95rem; font-weight: 500; color: var(--ink-soft); }
.price-card .btn { margin-top: auto; }

.faq details { border-bottom: 1px solid var(--border); padding: 16px 0; }
.faq summary { cursor: pointer; font-weight: 700; list-style: none; display: flex; justify-content: space-between; gap: 16px; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: '+'; font-size: 1.4rem; line-height: 1; color: var(--link); }
.faq details[open] summary::after { content: '–'; }
.faq details p { margin: 10px 0 0; color: var(--ink-soft); }

.final-cta { text-align: center; background: var(--brand); color: #fff; border-radius: 24px; padding: 48px 24px; }
.final-cta p { color: rgba(255, 255, 255, 0.85); }
@media (prefers-color-scheme: dark) {
  :root:not([data-theme='light']) .final-cta { background: var(--surface-2); color: var(--ink); }
  :root:not([data-theme='light']) .final-cta p { color: var(--ink-soft); }
}

/* Vidéos */
.video-frame { margin: 0; }
.video-frame video {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 16 / 9;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  background: #003024;
  box-shadow: var(--shadow);
}
.video-frame figcaption { margin-top: 8px; font-size: 0.9rem; color: var(--ink-soft); }
.video-demo { max-width: 820px; margin: 0 auto 32px; }

/* Bloc Cercle Initial (toujours sur fond sapin, quel que soit le thème) */
.cercle {
  display: grid;
  grid-template-columns: 1fr 1.1fr;
  gap: 40px;
  align-items: center;
  background: #003024;
  color: #fff;
  border-radius: 24px;
  padding: 40px;
}
@media (max-width: 860px) { .cercle { grid-template-columns: 1fr; padding: 28px 20px; gap: 28px; } }
.cercle .eyebrow { background: #aaf051; color: #003024; }
.cercle h2 { color: #fff; }
.cercle p { color: rgba(255, 255, 255, 0.85); }
.cercle .checks { margin-bottom: 20px; color: #fff; }
.cercle-tip { font-size: 0.95rem; border-left: 3px solid #aaf051; padding-left: 12px; }
.cercle .video-frame video { border-color: rgba(255, 255, 255, 0.18); }
.cercle .video-frame figcaption { color: rgba(255, 255, 255, 0.75); }
.cercle a:focus-visible, .cercle video:focus-visible { outline: 3px solid #aaf051; outline-offset: 2px; }

/* ---------- Compte / crédits ---------- */
.page { padding: 48px 0; }
.stack { display: grid; gap: 20px; }
.balance { display: flex; align-items: baseline; gap: 10px; flex-wrap: wrap; }
.balance strong { font-size: 2.6rem; line-height: 1; }
table { width: 100%; border-collapse: collapse; font-size: 0.95rem; }
th, td { text-align: left; padding: 10px 8px; border-bottom: 1px solid var(--border); }
th { color: var(--ink-soft); font-weight: 600; }
td.num { text-align: right; font-variant-numeric: tabular-nums; }
.pos { color: var(--ok); }
.neg { color: var(--ink-soft); }
.danger-zone { border-color: color-mix(in srgb, var(--danger) 40%, var(--border)); }
.table-scroll { overflow-x: auto; }

/* ---------- Pages légales ---------- */
.legal h1 { font-size: 2rem; }
.legal h2 { font-size: 1.3rem; margin-top: 2em; }
.legal .todo { background: var(--lime-soft); padding: 0 4px; border-radius: 4px; }
.notice-draft { padding: 12px 16px; border-radius: var(--radius-sm); background: var(--lime-soft); color: var(--brand); margin-bottom: 24px; }
.mt { margin-top: 12px; }
.waiver { max-width: 760px; margin: 8px 0 20px; }
