/* ============================================================
   GALLINOO DESIGN SYSTEM — v1.0
   Palette coucher de soleil · Typographie Fraunces + Inter
   À charger en <link> sur toutes les pages du site.
   ============================================================ */

/* ---------- RESET MINIMAL ---------- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  font-size: 16px;
  line-height: 1.6;
  color: var(--brown-3);
  background: var(--cream);
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}
img, svg { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
button { font: inherit; cursor: pointer; border: none; background: none; color: inherit; }
input, select, textarea { font: inherit; color: inherit; }
h1, h2, h3, h4 {
  font-family: 'Fraunces', Georgia, serif;
  font-weight: 500;
  line-height: 1.1;
  letter-spacing: -0.02em;
}
em { font-style: italic; }

/* ---------- DESIGN TOKENS ---------- */
:root {
  /* Ciel (dégradé coucher de soleil) */
  --sky-top: #2a4a5e;
  --sky-mid: #4a7896;
  --sky-warm: #c89968;
  --sky-sun: #b87545;
  --sky-deep: #3d2418;

  /* Accents */
  --ambre: #f0c880;
  --ambre-deep: #c89040;
  --cuivre: #c8644a;
  --cuivre-deep: #a04828;
  --teal: #5a8a86;
  --teal-deep: #3d6b68;
  --vert: #8ab090;
  --danger: #c84a4a;

  /* Fonds crème chauds */
  --cream: #faf1e1;
  --cream-2: #f5ead5;
  --beige: #ebddc4;

  /* Textes terre */
  --brown-1: #6b5a48;
  --brown-2: #4a3a2a;
  --brown-3: #2a1f15;

  /* Géométrie */
  --radius-sm: 9px;
  --radius: 12px;
  --radius-lg: 16px;
  --radius-xl: 20px;

  /* Ombres */
  --shadow-sm: 0 4px 12px rgba(74, 58, 42, 0.08);
  --shadow-md: 0 12px 28px rgba(74, 58, 42, 0.14);
  --shadow-lg: 0 24px 48px rgba(74, 58, 42, 0.18);
  --shadow-cuivre: 0 8px 20px rgba(200, 100, 74, 0.3);

  /* Typographies */
  --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  --font-serif: 'Fraunces', Georgia, serif;

  /* Espacements standards */
  --space-xs: 4px;
  --space-sm: 8px;
  --space-md: 14px;
  --space-lg: 20px;
  --space-xl: 32px;
  --space-2xl: 48px;
  --space-3xl: 80px;
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    transition-duration: 0.01ms !important;
  }
  html { scroll-behavior: auto; }
}

/* ============================================================
   LAYOUT HELPERS
   ============================================================ */
.g-wrap {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
}
@media (min-width: 768px) { .g-wrap { padding: 0 40px; } }
@media (min-width: 1024px) { .g-wrap { padding: 0 64px; } }

.g-wrap-narrow {
  max-width: 760px;
  margin: 0 auto;
  padding: 0 20px;
}

.g-section { padding: 64px 0; }
.g-section-lg { padding: 80px 0; }
@media (min-width: 768px) {
  .g-section { padding: 80px 0; }
  .g-section-lg { padding: 96px 0; }
}

.g-section-alt { background: var(--cream-2); }
.g-section-warm { background: var(--beige); }

/* ============================================================
   NAV STICKY (à utiliser via _header.php)
   ============================================================ */
.g-nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 100;
  padding: 14px 20px;
  background: rgba(250, 241, 225, 0.92);
  backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px);
  border-bottom: 0.5px solid rgba(74, 58, 42, 0.08);
  transition: transform 0.3s ease;
}
.g-nav.is-hidden { transform: translateY(-100%); }
.g-nav-inner {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  gap: 12px;
}
.g-nav-logo {
  font-family: var(--font-serif);
  font-size: 22px;
  font-weight: 600;
  color: var(--brown-3);
  letter-spacing: -0.02em;
}
.g-nav-logo span { color: var(--cuivre); }

.g-nav-links {
  display: none;
  gap: 28px;
  margin-left: auto;
  font-size: 14px;
  font-weight: 500;
  color: var(--brown-2);
}
.g-nav-links a { transition: color 0.2s; }
.g-nav-links a:hover,
.g-nav-links a.is-active { color: var(--cuivre); }

.g-nav-cta {
  margin-left: auto;
  background: var(--teal);
  color: white;
  padding: 9px 18px;
  border-radius: 999px;
  font-size: 14px;
  font-weight: 500;
  transition: all 0.2s;
}
.g-nav-cta:hover {
  background: var(--teal-deep);
  transform: translateY(-1px);
}

.g-nav-burger {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 8px;
}
.g-nav-burger span {
  width: 20px; height: 2px;
  background: var(--brown-2);
  border-radius: 2px;
  transition: all 0.3s;
}

@media (min-width: 900px) {
  .g-nav-links { display: flex; }
  .g-nav-burger { display: none; }
  .g-nav-cta { margin-left: 28px; }
}

.g-mobile-menu {
  position: fixed; inset: 56px 0 0 0; z-index: 99;
  background: var(--cream);
  padding: 24px 20px;
  transform: translateX(100%);
  transition: transform 0.3s ease;
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.g-mobile-menu.is-open { transform: translateX(0); }
.g-mobile-menu a {
  padding: 16px 12px;
  font-size: 18px;
  font-weight: 500;
  border-bottom: 0.5px solid rgba(74, 58, 42, 0.1);
  color: var(--brown-2);
}
@media (min-width: 900px) { .g-mobile-menu { display: none; } }

.g-page-with-nav { padding-top: 72px; }

/* ============================================================
   TYPOGRAPHIE DE SECTION
   ============================================================ */
.g-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 12px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--teal);
  font-weight: 600;
  margin-bottom: 16px;
}
.g-eyebrow::before,
.g-eyebrow::after {
  content: '';
  width: 16px; height: 1px;
  background: var(--teal);
}
.g-eyebrow.is-solo::before,
.g-eyebrow.is-solo::after { display: none; }

.g-title {
  font-family: var(--font-serif);
  font-size: clamp(30px, 5vw, 48px);
  color: var(--brown-3);
  margin-bottom: 14px;
  line-height: 1.05;
  letter-spacing: -0.02em;
}
.g-title em { color: var(--cuivre); font-weight: 400; }

.g-subtitle {
  font-size: clamp(15px, 2vw, 18px);
  color: var(--brown-1);
  line-height: 1.5;
  max-width: 640px;
}

.g-section-head {
  text-align: center;
  margin: 0 auto 48px;
  display: flex;
  flex-direction: column;
  align-items: center;
}
@media (min-width: 768px) { .g-section-head { margin-bottom: 64px; } }

/* ============================================================
   BOUTONS
   ============================================================ */
.g-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 13px 24px;
  border-radius: var(--radius);
  font-size: 15px;
  font-weight: 600;
  transition: all 0.2s;
  white-space: nowrap;
  border: none;
  cursor: pointer;
  text-decoration: none;
}

.g-btn-primary {
  background: var(--cuivre);
  color: white;
  box-shadow: var(--shadow-cuivre);
}
.g-btn-primary:hover {
  background: var(--cuivre-deep);
  transform: translateY(-1px);
  box-shadow: 0 10px 24px rgba(200, 100, 74, 0.35);
}

.g-btn-teal {
  background: var(--teal);
  color: white;
  box-shadow: 0 8px 20px rgba(90, 138, 134, 0.28);
}
.g-btn-teal:hover {
  background: var(--teal-deep);
  transform: translateY(-1px);
}

.g-btn-secondary {
  background: white;
  color: var(--brown-2);
  border: 0.5px solid rgba(74, 58, 42, 0.2);
}
.g-btn-secondary:hover {
  background: var(--cream);
  border-color: var(--brown-1);
}

.g-btn-ghost {
  background: transparent;
  color: var(--brown-2);
  padding: 10px 14px;
}
.g-btn-ghost:hover { color: var(--cuivre); }

.g-btn-sm { padding: 9px 16px; font-size: 13.5px; }
.g-btn-lg { padding: 16px 28px; font-size: 16px; }
.g-btn-full { width: 100%; }

.g-btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
  transform: none;
}

/* ============================================================
   INPUTS
   ============================================================ */
.g-field { margin-bottom: 18px; }
.g-field:last-child { margin-bottom: 0; }

.g-label {
  display: block;
  font-size: 13px;
  font-weight: 600;
  color: var(--brown-2);
  margin-bottom: 7px;
}

.g-input {
  width: 100%;
  padding: 11px 14px;
  border: 0.5px solid rgba(74, 58, 42, 0.2);
  border-radius: var(--radius-sm);
  background: white;
  font-size: 15px;
  color: var(--brown-3);
  transition: border-color 0.2s, box-shadow 0.2s;
}
.g-input::placeholder {
  color: var(--brown-1);
  opacity: 0.55;
}
.g-input:focus {
  outline: none;
  border-color: var(--cuivre);
  box-shadow: 0 0 0 3px rgba(200, 100, 74, 0.12);
}

.g-select {
  appearance: none;
  -webkit-appearance: none;
  padding-right: 40px;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 14 14'><path fill='none' stroke='%236b5a48' stroke-width='2' stroke-linecap='round' d='M3 5l4 4 4-4'/></svg>");
  background-repeat: no-repeat;
  background-position: right 14px center;
  background-size: 12px;
}

.g-textarea {
  min-height: 100px;
  resize: vertical;
}

.g-input-help {
  font-size: 12px;
  color: var(--brown-1);
  margin-top: 6px;
}

.g-input-error { border-color: var(--danger); }
.g-input-error:focus { box-shadow: 0 0 0 3px rgba(200, 74, 74, 0.15); }

/* Checkbox stylisée dans un cadre */
.g-checkbox-field {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 12px 14px;
  background: var(--cream);
  border: 0.5px solid rgba(74, 58, 42, 0.1);
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: all 0.2s;
}
.g-checkbox-field:hover {
  background: var(--cream-2);
  border-color: rgba(200, 100, 74, 0.3);
}
.g-checkbox-field input[type="checkbox"] {
  width: 18px; height: 18px;
  accent-color: var(--cuivre);
  margin-top: 1px;
  flex-shrink: 0;
  cursor: pointer;
}
.g-checkbox-field-text {
  font-size: 13px;
  color: var(--brown-2);
  line-height: 1.5;
}
.g-checkbox-field-text strong {
  color: var(--brown-3);
  font-weight: 600;
  display: block;
  margin-bottom: 2px;
}
.g-checkbox-field-text small {
  color: var(--brown-1);
  font-size: 12px;
}

/* ============================================================
   CARTES
   ============================================================ */
.g-card {
  background: white;
  border: 0.5px solid rgba(74, 58, 42, 0.1);
  border-radius: var(--radius-lg);
  padding: 24px;
  transition: transform 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease;
}
.g-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-md);
  border-color: rgba(200, 100, 74, 0.25);
}

.g-card-title {
  font-family: var(--font-serif);
  font-size: 21px;
  font-weight: 500;
  color: var(--brown-3);
  margin-bottom: 6px;
}

.g-card-desc {
  font-size: 14.5px;
  line-height: 1.55;
  color: var(--brown-1);
}

/* Grille responsive de cartes */
.g-card-grid {
  display: grid;
  gap: 16px;
  grid-template-columns: 1fr;
}
@media (min-width: 640px) { .g-card-grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1024px) { .g-card-grid { grid-template-columns: repeat(3, 1fr); gap: 18px; } }

/* ============================================================
   BADGES & PILLS
   ============================================================ */
.g-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 14px;
  border-radius: 999px;
  background: rgba(255,255,255,0.12);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  border: 0.5px solid rgba(255,255,255,0.2);
  font-size: 13px;
  color: white;
}

.g-pill-light {
  background: var(--cream);
  border: 0.5px solid rgba(74, 58, 42, 0.1);
  color: var(--brown-2);
}

.g-badge {
  padding: 4px 10px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.02em;
}
.g-badge-cuivre { background: var(--cuivre); color: white; }
.g-badge-teal { background: var(--teal); color: white; }
.g-badge-ambre { background: var(--ambre); color: var(--brown-3); }
.g-badge-vert { background: var(--vert); color: white; }

/* ============================================================
   HERO SOMBRE (pattern principal)
   ============================================================ */
.g-hero-dark {
  position: relative;
  padding: 120px 20px 56px;
  background: linear-gradient(180deg, var(--sky-top) 0%, var(--sky-mid) 25%, var(--sky-warm) 55%, var(--sky-sun) 75%, var(--sky-deep) 100%);
  color: white;
  overflow: hidden;
}
.g-hero-dark::before {
  content: '';
  position: absolute;
  top: 30%; right: -10%;
  width: 500px; height: 500px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(255, 230, 180, 0.35) 0%, transparent 60%);
  pointer-events: none;
}
.g-hero-dark-inner {
  position: relative;
  max-width: 1200px;
  margin: 0 auto;
}
.g-hero-dark h1 {
  font-size: clamp(42px, 8vw, 80px);
  color: white;
  line-height: 0.98;
  margin-bottom: 18px;
}
.g-hero-dark h1 em {
  color: var(--ambre);
  font-weight: 400;
}
.g-hero-dark p {
  font-size: clamp(15px, 2vw, 17px);
  color: rgba(255,255,255,0.9);
  max-width: 560px;
  line-height: 1.55;
}

/* Hero "branding" plus court (pour les pages intérieures) */
.g-hero-brand {
  padding: 110px 20px 48px;
  background: linear-gradient(135deg, var(--brown-3) 0%, #5d3418 50%, #7a4028 100%);
  color: white;
  text-align: center;
  position: relative;
  overflow: hidden;
}
.g-hero-brand::before {
  content: '';
  position: absolute;
  top: -30%; right: -10%;
  width: 480px; height: 480px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(240, 200, 128, 0.28) 0%, transparent 60%);
  pointer-events: none;
}
.g-hero-brand-inner {
  position: relative;
  max-width: 800px;
  margin: 0 auto;
}
.g-hero-brand h1 {
  font-size: clamp(34px, 5vw, 54px);
  color: white;
  line-height: 1;
  margin-bottom: 14px;
}
.g-hero-brand h1 em { color: var(--ambre); font-weight: 400; }
.g-hero-brand p {
  font-size: clamp(15px, 2vw, 17px);
  color: rgba(255,255,255,0.9);
  max-width: 560px;
  margin: 0 auto;
}

/* Pill éditoriale dans hero */
.g-hero-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 7px 14px;
  border-radius: 999px;
  background: rgba(255,255,255,0.14);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  border: 0.5px solid rgba(255,255,255,0.22);
  font-size: 13px;
  margin-bottom: 18px;
  color: white;
}

/* ============================================================
   CTA FINAL (bloc sombre accent cuivre)
   ============================================================ */
.g-cta-final {
  padding: 72px 20px 96px;
  text-align: center;
  background: linear-gradient(180deg, var(--cream) 0%, var(--beige) 100%);
}
.g-cta-final-inner {
  max-width: 720px;
  margin: 0 auto;
  background: linear-gradient(135deg, var(--brown-3) 0%, var(--sky-deep) 100%);
  border-radius: var(--radius-xl);
  padding: 48px 28px;
  color: white;
  position: relative;
  overflow: hidden;
  box-shadow: var(--shadow-lg);
}
.g-cta-final-inner::before {
  content: '';
  position: absolute;
  top: -50%; right: -20%;
  width: 300px; height: 300px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(240, 200, 128, 0.3) 0%, transparent 70%);
  pointer-events: none;
}
.g-cta-final h2 {
  font-size: clamp(26px, 4vw, 40px);
  color: white;
  margin-bottom: 12px;
  position: relative;
  line-height: 1.1;
}
.g-cta-final h2 em { color: var(--ambre); }
.g-cta-final p {
  font-size: 16px;
  color: rgba(255,255,255,0.85);
  margin-bottom: 28px;
  position: relative;
  max-width: 520px;
  margin-left: auto;
  margin-right: auto;
}
.g-cta-final .g-btn { position: relative; }

/* ============================================================
   FAQ (details/summary)
   ============================================================ */
.g-faq-list {
  max-width: 760px;
  margin: 24px auto 0;
}
.g-faq-item {
  background: white;
  border: 0.5px solid rgba(74, 58, 42, 0.1);
  border-radius: var(--radius);
  margin-bottom: 10px;
  overflow: hidden;
  transition: border-color 0.2s;
}
.g-faq-item[open] { border-color: var(--cuivre); }
.g-faq-summary {
  padding: 18px 22px;
  font-size: 16px;
  font-weight: 600;
  color: var(--brown-3);
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
  list-style: none;
  gap: 16px;
}
.g-faq-summary::-webkit-details-marker { display: none; }
.g-faq-summary::after {
  content: '';
  width: 14px; height: 14px;
  flex-shrink: 0;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 14 14'><path fill='none' stroke='%232a1f15' stroke-width='2' stroke-linecap='round' d='M3 5l4 4 4-4'/></svg>");
  background-repeat: no-repeat;
  background-position: center;
  transition: transform 0.3s;
}
.g-faq-item[open] .g-faq-summary::after { transform: rotate(180deg); }
.g-faq-answer {
  padding: 0 22px 20px;
  font-size: 15px;
  color: var(--brown-1);
  line-height: 1.6;
}
.g-faq-answer strong { color: var(--brown-3); font-weight: 600; }

/* ============================================================
   FOOTER
   ============================================================ */
.g-footer {
  background: var(--brown-3);
  color: rgba(255,255,255,0.7);
  padding: 48px 20px 28px;
  font-size: 14px;
}
.g-footer-inner {
  max-width: 1200px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr;
  gap: 32px;
}
@media (min-width: 768px) {
  .g-footer-inner { grid-template-columns: 2fr 1fr 1fr 1fr; }
}
.g-footer-logo {
  font-family: var(--font-serif);
  font-size: 24px;
  font-weight: 600;
  color: white;
  margin-bottom: 10px;
}
.g-footer-logo span { color: var(--cuivre); }
.g-footer-tagline {
  color: rgba(255,255,255,0.55);
  font-size: 13px;
  max-width: 280px;
  line-height: 1.5;
}
.g-footer-col h4 {
  font-family: var(--font-sans);
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: rgba(255,255,255,0.5);
  margin-bottom: 14px;
  font-weight: 600;
}
.g-footer-col ul { list-style: none; }
.g-footer-col li { margin-bottom: 10px; }
.g-footer-col a {
  color: rgba(255,255,255,0.78);
  transition: color 0.2s;
}
.g-footer-col a:hover { color: var(--ambre); }
.g-footer-bottom {
  max-width: 1200px;
  margin: 32px auto 0;
  padding-top: 24px;
  border-top: 0.5px solid rgba(255,255,255,0.1);
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  justify-content: space-between;
  font-size: 12.5px;
  color: rgba(255,255,255,0.5);
}

/* ============================================================
   UTILITAIRES
   ============================================================ */
.g-sr-only {
  position: absolute;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.g-reveal {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}
.g-reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
}

.g-divider {
  height: 0.5px;
  background: rgba(74, 58, 42, 0.12);
  margin: 24px 0;
}

.g-text-muted { color: var(--brown-1); }
.g-text-cuivre { color: var(--cuivre); }
.g-text-teal { color: var(--teal); }
.g-text-center { text-align: center; }

.g-mt-sm { margin-top: 8px; }
.g-mt-md { margin-top: 16px; }
.g-mt-lg { margin-top: 24px; }
.g-mb-sm { margin-bottom: 8px; }
.g-mb-md { margin-bottom: 16px; }
.g-mb-lg { margin-bottom: 24px; }
