/* ─────────────────────────────────────────────
   Givasso — site vitrine
   Palette officielle : voir CLAUDE.md du plugin
   ───────────────────────────────────────────── */

@font-face {
  font-family: "Fraunces";
  src: url("fonts/fraunces.woff2") format("woff2");
  font-weight: 100 900;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Fraunces";
  src: url("fonts/fraunces-italic.woff2") format("woff2");
  font-weight: 100 900;
  font-style: italic;
  font-display: swap;
}
@font-face {
  font-family: "Instrument Sans";
  src: url("fonts/instrument-sans.woff2") format("woff2");
  font-weight: 400 700;
  font-style: normal;
  font-display: swap;
}

:root {
  --primary: #1B6B4A;
  --primary-deep: #0F3F2B;
  --accent: #2ECC71;
  --surface: #F8FAF9;
  --paper: #EFF4F1;
  --text-main: #1A2E24;
  --text-secondary: #55665F;
  --border: #C6E0D6;
  --danger: #D64545;
  --success: #38A169;
  --stripe: #635BFF;
  --helloasso: #E2475F;

  --serif: "Fraunces", Georgia, "Times New Roman", serif;
  --sans: "Instrument Sans", "Segoe UI", system-ui, sans-serif;
  --mono: ui-monospace, "SF Mono", Menlo, Consolas, monospace;

  --radius: 16px;
  --radius-sm: 10px;
  --gutter: 16px;
  --max: 1160px;
}

*, *::before, *::after { box-sizing: border-box; }

html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--surface);
  color: var(--text-main);
  font-family: var(--sans);
  font-size: 17px;
  line-height: 1.6;
  overflow-x: hidden;
}

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

a { color: var(--primary); text-underline-offset: 3px; }
a:hover { color: var(--primary-deep); }

:focus-visible { outline: 3px solid var(--accent); outline-offset: 3px; border-radius: 4px; }

.skip-link {
  position: absolute; left: -9999px; top: 8px;
  background: var(--primary); color: #fff; padding: 8px 16px; border-radius: 8px; z-index: 100;
}
.skip-link:focus { left: 8px; color: #fff; }

.wrap { width: 100%; max-width: var(--max); margin: 0 auto; padding: 0 var(--gutter); }

h1, h2, h3 {
  font-family: var(--serif);
  font-weight: 500;
  font-variation-settings: "SOFT" 100, "WONK" 0;
  letter-spacing: -0.02em;
  line-height: 1.08;
  margin: 0;
}
h1 em, h2 em { font-style: italic; color: var(--primary); font-variation-settings: "SOFT" 100, "WONK" 1; }

.eyebrow {
  display: inline-flex; align-items: center; gap: 10px;
  font-size: 13px; font-weight: 600; letter-spacing: 0.12em; text-transform: uppercase;
  color: var(--primary);
}
.eyebrow::before { content: ""; width: 24px; height: 2px; background: currentColor; }

/* ── Boutons ─────────────────────────────── */

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  min-height: 48px; padding: 12px 24px;
  border-radius: 999px; border: 2px solid transparent;
  font: 600 16px/1.2 var(--sans); text-decoration: none; cursor: pointer;
  transition: transform .2s ease, background-color .2s ease, box-shadow .2s ease;
}
.btn:hover { transform: translateY(-2px); }
.btn--primary { background: var(--primary); color: #fff; box-shadow: 0 8px 24px -10px rgba(27, 107, 74, .7); }
.btn--primary:hover { background: var(--primary-deep); color: #fff; }
.btn--ghost { border-color: var(--border); color: var(--text-main); background: transparent; }
.btn--ghost:hover { border-color: var(--primary); color: var(--primary); }
.btn--light { background: var(--surface); color: var(--primary-deep); }
.btn--light:hover { background: #fff; color: var(--primary-deep); }
.btn svg { width: 18px; height: 18px; }

/* ── En-tête ─────────────────────────────── */

.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(248, 250, 249, .86);
  backdrop-filter: saturate(1.4) blur(12px);
  -webkit-backdrop-filter: saturate(1.4) blur(12px);
  border-bottom: 1px solid transparent;
  transition: border-color .3s ease;
}
.site-header.is-scrolled { border-bottom-color: var(--border); }
.site-header .wrap { display: flex; align-items: center; justify-content: space-between; height: 72px; gap: 16px; }

.logo { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; color: var(--text-main); }
.logo img { width: 34px; height: 34px; }
.logo span { font-family: var(--serif); font-size: 26px; font-weight: 600; letter-spacing: -0.03em; }

.nav { display: none; gap: 32px; }
.nav a { color: var(--text-secondary); text-decoration: none; font-weight: 500; font-size: 15px; }
.nav a:hover { color: var(--primary); }
.site-header .btn { min-height: 44px; padding: 10px 18px; font-size: 15px; }

@media (min-width: 900px) { .nav { display: flex; } }

/* ── Hero ────────────────────────────────── */

.hero { position: relative; padding: 56px 0 80px; overflow: hidden; }
.hero::before {
  content: ""; position: absolute; inset: -20% -10% auto auto; width: 720px; height: 720px;
  background: radial-gradient(circle at center, rgba(46, 204, 113, .18), rgba(46, 204, 113, 0) 65%);
  pointer-events: none;
}
.hero .wrap { position: relative; display: grid; gap: 56px; align-items: center; }

.hero h1 { font-size: clamp(42px, 8vw, 78px); margin: 20px 0 24px; }
.hero__lead { font-size: 19px; color: var(--text-secondary); max-width: 34em; margin: 0 0 32px; }
.hero__actions { display: flex; flex-wrap: wrap; gap: 12px; }
.hero__facts {
  display: flex; flex-wrap: wrap; gap: 8px 24px; margin: 32px 0 0; padding: 0; list-style: none;
  font-size: 14px; color: var(--text-secondary);
}
.hero__facts li { display: inline-flex; align-items: center; gap: 8px; }
.hero__facts li::before {
  content: ""; width: 8px; height: 8px; border-radius: 50%; background: var(--accent);
}

@media (min-width: 960px) {
  .hero { padding: 80px 0 120px; }
  .hero .wrap { grid-template-columns: 1.1fr 0.9fr; gap: 64px; }
}

/* ── Démo du formulaire (reprend le thème « givasso » du plugin) ── */

.demo { position: relative; padding: 0 0 136px; }

.demo-form {
  position: relative; z-index: 2;
  background: #fff; border: 1px solid var(--border); border-radius: 20px;
  padding: 28px 24px;
  box-shadow: 0 30px 60px -30px rgba(15, 63, 43, .35), 0 2px 6px rgba(15, 63, 43, .06);
}
.demo-form__tag {
  position: absolute; top: -12px; right: 20px;
  background: var(--text-main); color: #fff; font-size: 12px; font-weight: 600;
  padding: 4px 12px; border-radius: 999px; letter-spacing: .04em;
}
.demo-form h2 { font-size: 26px; margin-bottom: 18px; }
.demo-form__sub { margin: 0 0 20px; color: var(--text-secondary); font-size: 15px; }

.legend {
  margin: 0 0 8px; font-size: 12px; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; color: var(--text-secondary);
}
.amounts { display: grid; grid-template-columns: repeat(5, 1fr); gap: 6px; margin-bottom: 16px; }
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.field i { color: var(--danger); font-style: normal; }
.amount {
  min-height: 44px; padding: 0; border: 2px solid var(--border); border-radius: var(--radius-sm);
  background: var(--surface); font: 600 16px var(--sans); color: var(--text-main); cursor: pointer;
  transition: border-color .15s ease, background-color .15s ease, color .15s ease;
}
.amount:hover { border-color: var(--primary); }
.amount[aria-pressed="true"] { background: var(--primary); border-color: var(--primary); color: #fff; }

.field { display: block; margin-bottom: 12px; }
.field[hidden] { display: none; }
.field span { display: block; font-size: 13px; font-weight: 600; color: var(--text-secondary); margin-bottom: 6px; }
.field input {
  width: 100%; min-height: 48px; padding: 10px 14px;
  border: 2px solid var(--border); border-radius: var(--radius-sm);
  font: 16px var(--sans); color: var(--text-main); background: #fff;
}
.field input:focus { outline: none; border-color: var(--primary); }


.demo-form .btn { width: 100%; border-radius: var(--radius-sm); }

.secure {
  display: flex; align-items: center; justify-content: center; gap: 6px;
  margin: 12px 0 0; font-size: 13px; color: var(--text-secondary);
}
.secure svg { width: 14px; height: 14px; }
.secure b { color: var(--stripe); }

.demo-note { min-height: 22px; margin: 10px 0 0; font-size: 14px; color: var(--primary); text-align: center; }

.demo-gauge {
  position: absolute; z-index: 3; left: -8px; bottom: 0; width: min(300px, 82%);
  background: var(--primary-deep); color: #fff; border-radius: var(--radius);
  padding: 18px 20px; box-shadow: 0 24px 40px -20px rgba(15, 63, 43, .6);
  transform: rotate(-2deg);
}
.demo-gauge__label { font-size: 12px; letter-spacing: .1em; text-transform: uppercase; opacity: .75; margin: 0; }
.demo-gauge__title { font-family: var(--serif); font-size: 19px; margin: 2px 0 12px; }
.bar { height: 10px; border-radius: 999px; background: rgba(255, 255, 255, .15); overflow: hidden; }
.bar__fill {
  height: 100%; width: 0; border-radius: inherit; background: var(--accent);
  transition: width 1.6s cubic-bezier(.2, .8, .2, 1);
}
.demo-gauge.is-visible .bar__fill { width: var(--progress); }
.demo-gauge__stats { display: flex; justify-content: space-between; margin: 10px 0 0; font-size: 14px; }
.demo-gauge__stats b { font-family: var(--serif); font-size: 18px; font-weight: 600; }

@media (min-width: 960px) {
  .demo { padding: 0 0 136px 32px; }
  .demo-form { padding: 32px; transform: rotate(1deg); }
  .demo-gauge { left: -24px; }
}

/* ── Sections ────────────────────────────── */

.section { padding: 88px 0; }
.section--paper { background: var(--paper); }
.section__head { max-width: 720px; margin-bottom: 48px; }
.section__head h2 { font-size: clamp(34px, 5.5vw, 54px); margin: 16px 0 16px; }
.section__head p { color: var(--text-secondary); font-size: 18px; margin: 0; }

/* Fonctionnalités — liste éditoriale numérotée */
.features { display: grid; gap: 0; counter-reset: feature; border-top: 1px solid var(--border); }
.feature {
  counter-increment: feature;
  display: grid; grid-template-columns: 48px 1fr; gap: 16px;
  padding: 28px 0; border-bottom: 1px solid var(--border);
}
.feature::before {
  content: counter(feature, decimal-leading-zero);
  font-family: var(--serif); font-style: italic; font-size: 22px; color: var(--primary); line-height: 1.3;
}
.feature h3 { font-size: 24px; margin-bottom: 8px; }
.feature p { margin: 0; color: var(--text-secondary); }
.feature code, .faq code, .steps code {
  font-family: var(--mono); font-size: .88em; background: var(--paper);
  padding: 2px 6px; border-radius: 6px; color: var(--primary-deep);
}
.section--paper .feature code { background: #fff; }

@media (min-width: 800px) {
  .features { grid-template-columns: 1fr 1fr; column-gap: 64px; }
  .feature { grid-template-columns: 56px 1fr; }
}

/* Passerelles */
.gateways-grid { display: grid; gap: 20px; }
.gw-card {
  position: relative; background: #fff; border: 1px solid var(--border); border-radius: 20px;
  padding: 32px 28px; overflow: hidden;
}
.gw-card::after {
  content: ""; position: absolute; left: 0; top: 0; bottom: 0; width: 6px; background: var(--gw);
}
.gw-card--stripe { --gw: var(--stripe); }
.gw-card--helloasso { --gw: var(--helloasso); }
.gw-card h3 { font-size: 30px; margin-bottom: 4px; }
.gw-card__tagline { margin: 0 0 20px; font-weight: 600; color: var(--gw); }
.gw-card ul { margin: 0; padding: 0; list-style: none; display: grid; gap: 10px; }
.gw-card li { position: relative; padding-left: 28px; color: var(--text-secondary); }
.gw-card li::before {
  content: ""; position: absolute; left: 0; top: .5em; width: 14px; height: 8px;
  border-left: 2px solid var(--primary); border-bottom: 2px solid var(--primary); transform: rotate(-45deg);
}
@media (min-width: 800px) { .gateways-grid { grid-template-columns: 1fr 1fr; } }

/* Étapes */
.steps { display: grid; gap: 16px; margin: 0; padding: 0; list-style: none; counter-reset: step; }
.step {
  counter-increment: step; position: relative;
  background: #fff; border: 1px solid var(--border); border-radius: var(--radius); padding: 24px;
}
.step::before {
  content: counter(step);
  display: grid; place-items: center; width: 44px; height: 44px; margin-bottom: 16px;
  border-radius: 50%; background: var(--primary); color: #fff;
  font-family: var(--serif); font-size: 20px; font-weight: 600;
}
.step h3 { font-size: 21px; margin-bottom: 6px; }
.step p { margin: 0; color: var(--text-secondary); font-size: 16px; }
@media (min-width: 700px) { .steps { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1040px) { .steps { grid-template-columns: repeat(4, 1fr); } }

/* Shortcodes */
.code-panel {
  margin-top: 48px; background: var(--primary-deep); color: #E3F1EA;
  border-radius: 20px; padding: 32px 24px; display: grid; gap: 28px;
}
.code-panel h3 { color: #fff; font-size: 26px; }
.code-panel > div > p { margin: 8px 0 0; color: #B5D3C4; }
.shortcodes { display: grid; gap: 12px; }
.shortcode {
  background: rgba(255, 255, 255, .06); border: 1px solid rgba(255, 255, 255, .1);
  border-radius: var(--radius-sm); padding: 14px 16px;
}
.shortcode code {
  display: block; font-family: var(--mono); font-size: 14px; color: var(--accent);
  white-space: pre-wrap; word-break: break-word;
}
.shortcode span { display: block; font-size: 14px; color: #B5D3C4; margin-top: 4px; }
@media (min-width: 900px) {
  .code-panel { grid-template-columns: 0.8fr 1.2fr; padding: 48px; align-items: center; }
}

/* Confiance */
.trust { display: grid; gap: 40px; }
.trust__quote {
  font-family: var(--serif); font-size: clamp(28px, 4.2vw, 42px); line-height: 1.2; letter-spacing: -0.02em; margin: 0;
}
.trust__quote em { color: var(--primary); }
.trust__list { display: grid; gap: 20px; margin: 0; padding: 0; list-style: none; }
.trust__list li { padding-left: 20px; border-left: 3px solid var(--accent); }
.trust__list b { display: block; font-size: 17px; margin-bottom: 2px; }
.trust__list span { color: var(--text-secondary); font-size: 16px; }
@media (min-width: 900px) { .trust { grid-template-columns: 1fr 1fr; gap: 80px; align-items: start; } }

/* FAQ */
.faq { max-width: 820px; border-top: 1px solid var(--border); }
.faq details { border-bottom: 1px solid var(--border); }
.faq summary {
  display: flex; justify-content: space-between; align-items: center; gap: 16px;
  padding: 22px 0; cursor: pointer; list-style: none;
  font-family: var(--serif); font-size: 21px; font-weight: 500;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: "+"; flex: none; display: grid; place-items: center; width: 32px; height: 32px;
  border: 1.5px solid var(--border); border-radius: 50%;
  font-family: var(--sans); font-size: 20px; color: var(--primary); transition: transform .25s ease;
}
.faq details[open] summary::after { transform: rotate(45deg); }
.faq details p { margin: 0 0 22px; color: var(--text-secondary); max-width: 680px; }

/* Appel final */
.cta {
  position: relative; overflow: hidden;
  background: var(--primary); color: #fff; border-radius: 28px;
  padding: 56px 24px; text-align: center;
}
.cta::before, .cta::after {
  content: ""; position: absolute; border-radius: 50%; border: 1px solid rgba(255, 255, 255, .14);
}
.cta::before { width: 520px; height: 520px; left: -200px; top: -260px; }
.cta::after { width: 380px; height: 380px; right: -140px; bottom: -220px; }
.cta h2 { position: relative; font-size: clamp(34px, 6vw, 60px); color: #fff; }
.cta h2 em { color: var(--accent); }
.cta p { position: relative; max-width: 560px; margin: 16px auto 32px; color: #D6EBE0; font-size: 18px; }
.cta .btn { position: relative; }
.cta small { position: relative; display: block; margin-top: 16px; color: #B5D3C4; font-size: 14px; }

/* Pied de page */
.site-footer { padding: 56px 0 40px; border-top: 1px solid var(--border); margin-top: 88px; }
.site-footer .wrap { display: grid; gap: 32px; }
.site-footer p { margin: 8px 0 0; color: var(--text-secondary); font-size: 15px; max-width: 340px; }
.footer-links { display: grid; gap: 8px; margin: 0; padding: 0; list-style: none; font-size: 15px; }
.footer-links a { color: var(--text-secondary); text-decoration: none; }
.footer-links a:hover { color: var(--primary); }
.footer-title { font-size: 13px; font-weight: 600; letter-spacing: .1em; text-transform: uppercase; margin: 0 0 12px; }
.footer-bottom {
  grid-column: 1 / -1; padding-top: 24px; border-top: 1px solid var(--border);
  font-size: 14px; color: var(--text-secondary);
}
@media (min-width: 800px) { .site-footer .wrap { grid-template-columns: 2fr 1fr 1fr; } }

/* Pages de texte (mentions légales) */
.prose { max-width: 760px; padding: 64px 0 24px; }
.prose h1 { font-size: clamp(38px, 6vw, 56px); margin-bottom: 32px; }
.prose h2 { font-size: 26px; margin: 40px 0 12px; }
.prose p, .prose li { color: var(--text-secondary); }
.todo { background: #FFF4D6; color: #6B4E00; padding: 1px 6px; border-radius: 4px; font-weight: 600; }

/* ── Apparition au défilement ────────────── */

.reveal { opacity: 0; transform: translateY(24px); transition: opacity .7s ease, transform .7s ease; }
.reveal.is-visible { opacity: 1; transform: none; }

.hero-in > * { animation: rise .8s cubic-bezier(.2, .8, .2, 1) both; }
.hero-in > *:nth-child(2) { animation-delay: .08s; }
.hero-in > *:nth-child(3) { animation-delay: .16s; }
.hero-in > *:nth-child(4) { animation-delay: .24s; }
.hero-in > *:nth-child(5) { animation-delay: .32s; }
.demo { animation: rise 1s .3s cubic-bezier(.2, .8, .2, 1) both; }
@keyframes rise { from { opacity: 0; transform: translateY(28px); } to { opacity: 1; transform: none; } }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
  .reveal { opacity: 1; transform: none; }
}

/* Sans JavaScript, tout reste visible */
.no-js .reveal { opacity: 1; transform: none; }
.no-js .bar__fill { width: var(--progress); }

/* ── Guide d'installation ─────────────────────────────── */

.guide { max-width: 820px; }
.guide h1 { margin-top: 16px; }
.guide h2 { scroll-margin-top: 96px; }
.guide__lead { font-size: 19px; }
.guide ol, .guide ul { padding-left: 1.4em; }
.guide li { margin-bottom: 8px; }
.guide code {
  font-family: var(--mono); font-size: .88em; background: var(--paper);
  padding: 2px 6px; border-radius: 6px; color: var(--primary-deep);
}
.guide strong { color: var(--text-main); }
.guide figure { margin: 24px 0 32px; }
.guide figure img {
  width: 100%; height: auto; border-radius: var(--radius-sm);
  border: 1px solid var(--border); box-shadow: 0 12px 32px -18px rgba(15, 63, 43, .35);
}
.guide figcaption { margin-top: 10px; font-size: 14px; color: var(--text-secondary); text-align: center; }
.guide__box {
  background: var(--paper); border-left: 4px solid var(--primary);
  border-radius: var(--radius-sm); padding: 18px 22px; margin: 24px 0;
}
.guide__box--info { background: #FFF8E6; border-left-color: #B45309; }
.guide__box p, .guide__box ul { margin: 8px 0 0; }
.guide__toc {
  border: 1px solid var(--border); border-radius: var(--radius-sm); padding: 16px 22px; margin: 24px 0 8px;
}
.guide__toc ol { margin: 0; columns: 2; column-gap: 32px; }
.guide__toc a { text-decoration: none; }
.guide__faq { border-bottom: 1px solid var(--border); }
.guide__faq summary { cursor: pointer; padding: 16px 0; font-weight: 600; color: var(--text-main); }
.guide__faq p { margin: 0 0 16px; }
@media (max-width: 600px) { .guide__toc ol { columns: 1; } }
