/* Créé par MS & LC */
/* ==========================================================================
   DESIGN TOKENS - Castanet Avocat
   Inspiré du design system DS Avocats - Élégant et professionnel
   ========================================================================== */

:root {
  /* --------------------------------------------------------------------------
     COULEURS PRINCIPALES
     -------------------------------------------------------------------------- */

  /* Couleurs de marque */
  --color-primary: #1a2b3c;           /* Bleu-noir profond - confiance et autorité */
  --color-primary-dark: #141414;      /* Noir profond - élégance */
  --color-primary-light: #21353d;     /* Bleu-gris foncé - sophistication */

  /* Accents */
  --color-accent: #c3945b;            /* Or chaud - prestige et excellence */
  --color-accent-light: #d4a96b;      /* Or clair - hover states */
  --color-accent-dark: #8c7c66;       /* Bronze - subtilité */
  --color-accent-text: #8f6530;       /* Or foncé - texte accessible sur fond clair (4.86:1) */
  --color-teal: #38b6ab;              /* Turquoise - modernité (usage ponctuel) */

  /* Textes - Contraste WCAG AA optimisé */
  --color-text: #0F172A;              /* Texte principal - Slate 900 - haute lisibilité */
  --color-text-muted: #475569;        /* Texte secondaire - Slate 600 - contraste amélioré */
  --color-text-light: #64748B;        /* Légendes et métadonnées - Slate 500 */

  /* Fonds */
  --color-bg: #ffffff;                /* Fond principal */
  --color-bg-alt: #f8f8f6;            /* Fond alternatif - légèrement crème */
  --color-bg-dark: #141414;           /* Fond sombre pour sections */

  /* Footer */
  --color-footer: #1a2b3c;            /* Fond footer - navy (même que header) */

  /* --------------------------------------------------------------------------
     PALETTE "PARCHEMIN" - Thème Clair Raffiné
     Ivoire et tons chauds - Élégance notariale traditionnelle
     -------------------------------------------------------------------------- */

  /* Fonds principaux - Tons ivoire/parchemin */
  --color-bg-light: #faf8f5;          /* Ivoire - fond principal */
  --color-bg-light-alt: #f3efe9;      /* Parchemin - sections alternées */
  --color-bg-card-light: #ffffff;     /* Blanc pur - cartes élevées */
  --color-bg-accent-light: #f7f4ef;   /* Ivoire légèrement relevé */

  /* Sections sombres - Pour contraste (header, footer, CTA) */
  --color-bg-dark-section: #1a2b3c;   /* Navy profond - sections sombres */
  --color-bg-dark-alt: #243445;       /* Navy moins intense */
  --color-bg-card-dark: #2a3a4a;      /* Cartes sur fond sombre */

  /* Textes sur fond clair - Contraste WCAG AA vérifié */
  --color-text-on-light: #2c2416;     /* Sépia foncé - texte principal (12:1) */
  --color-text-muted-on-light: #6b5d4d; /* Bronze doux - texte secondaire (6.5:1) */
  --color-text-light-on-light: #8a7a68; /* Bronze clair - légendes (4.5:1) */

  /* Textes sur fond sombre */
  --color-text-on-dark: #f5f2ed;      /* Ivoire clair (14:1) */
  --color-text-muted-on-dark: #c5bfb5; /* Beige clair (8:1) */
  --color-text-light-on-dark: #a09689; /* Taupe clair (5.5:1) */

  /* Bordures */
  --color-border-on-light: #e5dfd6;   /* Beige chaud */
  --color-border-on-dark: rgba(245, 242, 237, 0.15); /* Ivoire transparent */

  /* Ombres contextuelles */
  --shadow-on-light: 0 4px 16px rgba(44, 36, 22, 0.08);
  --shadow-on-dark: 0 4px 20px rgba(0, 0, 0, 0.25);
  --shadow-warm: 0 2px 12px rgba(195, 148, 91, 0.15);

  /* Bordures et séparateurs */
  --color-border: #e5dfd6;            /* Bordure standard - beige chaud */
  --color-border-light: #ebe6de;      /* Bordure légère */
  --color-border-accent: rgba(195, 148, 91, 0.4); /* Bordure dorée subtile */

  /* États */
  --color-success: #38b6ab;           /* Turquoise pour succès */
  --color-error: #c44536;             /* Rouge sobre pour erreurs */
  --color-warning: #c3945b;           /* Or pour avertissements */

  /* --------------------------------------------------------------------------
     TYPOGRAPHIE
     -------------------------------------------------------------------------- */

  /* Familles de polices */
  --font-heading: 'Playfair Display', 'Georgia', serif;  /* Titres - élégance classique */
  --font-body: 'Source Sans 3', 'Helvetica Neue', sans-serif; /* Corps - lisibilité moderne */
  --font-accent: 'Source Sans 3', 'Helvetica Neue', sans-serif; /* UI : nav, boutons, labels (= body, alias semantique) */

  /* Tailles de titres - fluides avec clamp(min, preferred, max) */
  --text-h1: clamp(32px, 4.5vw, 56px);   /* Titres principaux - impact */
  --text-h2: clamp(26px, 3.5vw, 40px);   /* Sections principales */
  --text-h3: clamp(22px, 2.5vw, 28px);   /* Sous-sections */
  --text-h4: clamp(18px, 2vw, 22px);     /* Cartes et éléments */
  --text-h5: clamp(16px, 1.5vw, 18px);   /* Labels importants */

  /* Tailles de corps */
  --text-body: 16px;            /* Texte standard */
  --text-body-lg: clamp(16px, 1.5vw, 18px); /* Texte mis en avant */
  --text-nav: 13px;             /* Navigation et labels UI compacts */
  --text-caption: 14px;         /* Légendes et notes */
  --text-small: 12px;           /* Mentions légales */

  /* Line heights */
  --leading-tight: 1.2;         /* Titres */
  --leading-display: 1.3;       /* Titres espaces (small-caps, display) */
  --leading-normal: 1.6;        /* Corps de texte */
  --leading-relaxed: 1.8;       /* Texte aéré */

  /* Letter spacing */
  --tracking-tight: -0.02em;    /* Grands titres */
  --tracking-normal: 0;         /* Corps */
  --tracking-wide: 0.05em;      /* Navigation uppercase */
  --tracking-wider: 0.1em;      /* Labels et tags */

  /* --------------------------------------------------------------------------
     ESPACEMENT (Base 8px)
     -------------------------------------------------------------------------- */

  --space-1: 8px;
  --space-2: 16px;
  --space-3: 24px;
  --space-4: 32px;
  --space-5: 40px;
  --space-6: 64px;
  --space-7: 80px;
  --space-8: 120px;

  /* --------------------------------------------------------------------------
     RAYONS DE BORDURE
     -------------------------------------------------------------------------- */

  --radius-sm: 3px;             /* Inputs, petits boutons */
  --radius: 4px;                /* Boutons standards */
  --radius-md: 8px;             /* Cartes */
  --radius-lg: 12px;            /* Conteneurs */
  --radius-xl: 16px;            /* Grandes sections */
  --radius-full: 50%;           /* Avatars, badges ronds */

  /* --------------------------------------------------------------------------
     OMBRES
     -------------------------------------------------------------------------- */

  --shadow-xs: 0 1px 2px rgba(18, 25, 97, 0.04);
  --shadow-sm: 0 1px 4px rgba(18, 25, 97, 0.08);
  --shadow-md: 0 4px 12px rgba(18, 25, 97, 0.1);
  --shadow-lg: 0 8px 24px rgba(18, 25, 97, 0.12);
  --shadow-xl: 0 16px 48px rgba(18, 25, 97, 0.16);

  /* Ombres colorées */
  --shadow-accent: 0 4px 16px rgba(195, 148, 91, 0.25);
  --shadow-primary: 0 4px 16px rgba(26, 43, 60, 0.2);

  /* --------------------------------------------------------------------------
     TRANSITIONS
     -------------------------------------------------------------------------- */

  --transition-fast: 0.15s ease;
  --transition-base: 0.25s ease;
  --transition-slow: 0.4s ease;
  --transition-bounce: 0.3s cubic-bezier(0.4, 0, 0.2, 1);

  /* --------------------------------------------------------------------------
     LAYOUT
     -------------------------------------------------------------------------- */

  --container: 1200px;
  --container-narrow: 800px;
  --container-wide: 1400px;

  /* --------------------------------------------------------------------------
     Z-INDEX
     -------------------------------------------------------------------------- */

  --z-dropdown: 100;
  --z-sticky: 200;
  --z-fixed: 300;
  --z-modal-backdrop: 400;
  --z-modal: 500;
  --z-tooltip: 600;
}

/* ==========================================================================
   RESPONSIVE SPACING
   La typographie est gérée par clamp() ci-dessus.
   ========================================================================== */

@media (max-width: 1023px) {
  :root {
    --space-6: 56px;
    --space-7: 64px;
  }
}

@media (max-width: 767px) {
  :root {
    --space-5: 32px;
    --space-6: 48px;
    --space-7: 56px;
  }
}
