:root {
  --bg: #faf7f2;
  --surface: #ffffff;
  --fg: #201a14;
  --muted: #6b625a;
  --accent: #b4531f;
  --accent-hover: #9a4518;
  --accent-soft: #f6e7da;
  --border: #e8e1d8;
  --radius: 12px;
  --shadow-sm: 0 1px 2px rgba(32, 26, 20, .05);
  --shadow-md: 0 6px 20px rgba(32, 26, 20, .09);
  --font: 'Inter', system-ui, -apple-system, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.65;
  color: var(--fg);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }

.wrap { max-width: 1040px; margin: 0 auto; padding: 0 20px; }
.hidden { display: none; }
.muted { color: var(--muted); }
.small { font-size: 14px; }
.center { max-width: 460px; margin: 0 auto; }

/* --- Header --- */
.site-head {
  position: sticky; top: 0; z-index: 50;
  background: rgba(255, 255, 255, .88);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--border);
}
.site-head .wrap { display: flex; align-items: center; justify-content: space-between; height: 64px; }
.brand { font-weight: 700; font-size: 17px; letter-spacing: -0.01em; color: var(--fg); }
.brand:hover { text-decoration: none; }
.nav { display: flex; align-items: center; }
.nav a {
  margin-left: 6px; color: var(--fg); font-size: 15px; font-weight: 500;
  padding: 7px 12px; border-radius: 8px; transition: background .15s ease;
}
.nav a:hover { background: var(--accent-soft); text-decoration: none; }

/* --- Boutons --- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 11px 22px; border-radius: 10px;
  background: var(--accent); color: #fff; font-weight: 600; font-size: 15px; font-family: inherit;
  border: 1px solid var(--accent); cursor: pointer;
  transition: background .15s ease, box-shadow .15s ease, transform .05s ease;
  box-shadow: var(--shadow-sm);
}
.btn:hover { background: var(--accent-hover); text-decoration: none; box-shadow: var(--shadow-md); }
.btn:active { transform: translateY(1px); }
.btn.sec { background: transparent; color: var(--fg); border-color: var(--border); box-shadow: none; }
.btn.sec:hover { background: var(--accent-soft); }
.btn.sm { padding: 7px 14px; font-size: 13px; border-radius: 8px; }
.btn.block { width: 100%; }

/* --- Hero --- */
.hero {
  padding: 60px 0 52px;
  background: radial-gradient(900px 420px at 85% -20%, var(--accent-soft), transparent 62%);
}
.hero h1 {
  font-size: 44px; line-height: 1.12; letter-spacing: -0.025em;
  margin: 0 0 16px; max-width: 620px; font-weight: 800;
}
.hero .lead { font-size: 19px; color: var(--muted); max-width: 560px; margin: 0 0 28px; }
.hero .cta { display: flex; gap: 12px; flex-wrap: wrap; }

/* --- Typo --- */
h1 { font-size: 32px; line-height: 1.2; letter-spacing: -0.02em; }
h2 { font-size: 20px; letter-spacing: -0.01em; }
h3 { font-size: 16px; }
.lead { font-size: 18px; color: var(--muted); }
hr { border: none; border-top: 1px solid var(--border); margin: 28px 0; }

/* --- Cartes --- */
.card {
  background: var(--surface); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 24px;
  box-shadow: var(--shadow-sm);
}
.stack { display: flex; flex-direction: column; gap: 16px; }
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 18px; }
.grid .thumb {
  aspect-ratio: 4/3; background: #ece7df; border-radius: 8px;
  display: flex; align-items: center; justify-content: center; color: var(--muted);
}

/* --- Cartes d'accroche (accueil) --- */
.feature { transition: box-shadow .18s ease, transform .18s ease; }
.feature:hover { box-shadow: var(--shadow-md); transform: translateY(-3px); }
.feature h3 { margin: 0 0 6px; }

/* --- Formulaires --- */
.field { margin-bottom: 18px; }
.field label { display: block; margin-bottom: 6px; font-weight: 600; font-size: 14px; }
.field input, .field textarea, .field select {
  width: 100%; padding: 11px 13px; border: 1px solid var(--border); border-radius: 9px;
  font: inherit; background: #fff; color: var(--fg);
  transition: border-color .15s ease, box-shadow .15s ease;
}
.field input:focus, .field textarea:focus, .field select:focus {
  outline: none; border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(180, 83, 31, .13);
}
.field .check { display: flex; gap: 10px; align-items: flex-start; font-weight: 400; }
.field .check input { width: auto; margin-top: 4px; }
.hint { color: var(--muted); font-size: 13px; margin-top: 5px; }

/* --- Alertes --- */
.alert { padding: 13px 16px; border-radius: 10px; margin-bottom: 16px; font-size: 15px; }
.alert.err { background: #fdecea; border: 1px solid #f5c6c0; color: #9a3428; }
.alert.ok { background: #e7f4ec; border: 1px solid #bfe3cd; color: #18623a; }

/* --- Tableaux --- */
table { width: 100%; border-collapse: collapse; }
th, td { text-align: left; padding: 12px 14px; border-bottom: 1px solid var(--border); vertical-align: top; }
th { font-size: 12px; text-transform: uppercase; letter-spacing: .05em; color: var(--muted); font-weight: 600; }

/* --- Badges --- */
.badge { display: inline-block; padding: 3px 11px; border-radius: 999px; font-size: 12px; font-weight: 600; }
.badge.draft { background: #f0ede8; color: #5a524a; }
.badge.submitted { background: #fff3d6; color: #8a5d00; }
.badge.published { background: #e7f4ec; color: #18623a; }
.badge.correction_requested { background: #fdecea; color: #9a3428; }
.badge.paused { background: #f0ede8; color: #6b625a; }

/* --- Footer --- */
.site-foot { border-top: 1px solid var(--border); padding: 26px 0; margin-top: 64px; background: var(--surface); }
.site-foot .wrap { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; }

@media (max-width: 640px) {
  .hero h1 { font-size: 34px; }
  .hero { padding: 40px 0 36px; }
}
