/* ==========================================================================
   ScanORDO Direct Hors HDS - Styles Communs & Variables de Design
   Inspiration éditoriale (L'Express) & Support Marque Blanche
   ========================================================================== */

/* Typographies éditoriales : Lora (Serif de presse) pour les titres, Inter pour la lecture et les formulaires */
@import url('https://fonts.googleapis.com/css2?family=Lora:ital,wght@0,500;0,600;0,700;1,400&family=Inter:wght@300;400;500;600;700&display=swap');

:root {
  /* Marque blanche dynamique : personnalisable par groupement */
  --brand-primary: #b81414;        /* Rouge éditorial signature L'Express (ou couleur groupement) */
  --brand-secondary: #1a365d;      /* Bleu institutionnel sobre */
  --primary-color: var(--brand-primary);
  --primary-dark: #911010;

  /* Teintes de fond et d'encre */
  --bg-light: #f8f9fa;             /* Fond blanc cassé/ivoire doux de lecture */
  --bg-white: #ffffff;             /* Fond blanc pur */
  --text-dark: #121212;            /* Noir encre profond */
  --text-muted: #595959;           /* Gris minéral pour métadonnées */
  --border-color: #e5e7eb;         /* Ligne de séparation fine et sobre */

  /* Couleurs de statut */
  --status-success: #15803d;       /* Vert institutionnel */
  --status-warning: #b45309;       /* Ambre sobre */
  --status-danger: #b91c1c;        /* Rouge alerte */

  /* Typographies */
  --font-heading: 'Lora', Georgia, 'Times New Roman', serif;
  --font-body: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;

  /* Rayons de courbure et ombres nettes */
  --radius-sm: 3px;
  --radius-md: 6px;
  --radius-lg: 8px;
  --radius-pill: 40px;
  --shadow-soft: 0 10px 25px rgba(0, 0, 0, 0.08);
  --shadow-card: 0 1px 3px rgba(0, 0, 0, 0.05), 0 1px 2px rgba(0, 0, 0, 0.03);

  /* Transitions */
  --transition-normal: all 0.2s ease-in-out;
  --transition-slide: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

/* Réinitialisation de base */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  background-color: var(--bg-light);
  font-family: var(--font-body);
  color: var(--text-dark);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-heading);
  font-weight: 700;
  line-height: 1.2;
}

a {
  color: inherit;
  text-decoration: none;
}

button {
  font-family: var(--font-heading);
  cursor: pointer;
  border: none;
  outline: none;
  background: none;
}

/* ==========================================================================
   ANIMATION SIGNATURE DROP2DESK : BASCULE DE CARTES "EMAIL -> DESK"
   ========================================================================== */

.brand-animated {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
  user-select: none;
}

.brand-animated .brand-symbol {
  height: 48px;
  width: auto;
  object-fit: contain;
  transition: transform 0.25s ease;
  filter: drop-shadow(0 2px 8px rgba(0, 0, 0, 0.08));
}

.brand-animated:hover .brand-symbol {
  transform: scale(1.05);
}

.brand-animated .brand-text {
  font-family: 'Montserrat', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  font-size: 1.85rem;
  font-weight: 800;
  letter-spacing: -0.6px;
  line-height: 1;
  display: inline-flex;
  align-items: center;
}

/* Version compacte pour les navbars */
.brand-animated.brand-sm {
  gap: 8px;
}
.brand-animated.brand-sm .brand-symbol {
  height: 32px;
}
.brand-animated.brand-sm .brand-text {
  font-size: 1.3rem;
  letter-spacing: -0.4px;
}

/* 1. Mot "Drop" */
.brand-animated .part-drop {
  color: #0f172a;
  opacity: 0;
  animation: animDropFadeIn 0.35s ease-out forwards;
}

@keyframes animDropFadeIn {
  0% { opacity: 0; transform: translateX(-8px); }
  100% { opacity: 1; transform: translateX(0); }
}

/* 2. Chiffre "2" furtif supersonique */
.brand-animated .part-two {
  display: inline-block;
  color: #0d9488;
  opacity: 0;
  margin: 0 1px;
  animation: animTwoFurtif 0.45s cubic-bezier(0.15, 0.85, 0.35, 1.2) 0.35s forwards;
}

@keyframes animTwoFurtif {
  0% {
    opacity: 0;
    transform: scale(2.8) translateY(-10px);
    filter: blur(6px);
    color: #06b6d4;
  }
  60% {
    opacity: 1;
    transform: scale(0.9) translateY(0);
    filter: blur(0);
    color: #06b6d4;
    text-shadow: 0 0 12px rgba(6, 182, 212, 0.8);
  }
  100% {
    opacity: 1;
    transform: scale(1);
    color: #0d9488;
    text-shadow: none;
  }
}

/* 3. Emplacement 3D pour la bascule de cartes ("email" -> "Desk") */
.brand-animated .card-slot {
  position: relative;
  display: inline-flex;
  align-items: center;
  perspective: 600px;
  transform-style: preserve-3d;
  min-width: 82px;
  height: 1.25em;
}

.brand-animated.brand-sm .card-slot {
  min-width: 58px;
}

/* Carte 1 : "email" avec trait rouge barré */
.brand-animated .card-word {
  position: absolute;
  left: 0;
  top: 0;
  height: 100%;
  display: flex;
  align-items: center;
  backface-visibility: hidden;
  transform-origin: center bottom;
}

.brand-animated .card-email {
  color: #ef4444;
  opacity: 0;
  animation: animCardEmail 1.8s ease-in-out 0.6s forwards;
}

/* Trait de barrage rouge */
.brand-animated .card-email .strike-bar {
  position: absolute;
  left: -2px;
  top: 50%;
  width: 0;
  height: 3px;
  background: #dc2626;
  border-radius: 2px;
  transform: translateY(-50%) rotate(-4deg);
  box-shadow: 0 0 6px rgba(220, 38, 38, 0.6);
  animation: animStrikeThrough 0.35s ease-out 1.2s forwards;
}

@keyframes animStrikeThrough {
  0% { width: 0%; }
  100% { width: 108%; }
}

@keyframes animCardEmail {
  0% {
    opacity: 0;
    transform: translateY(-6px) rotateX(20deg);
  }
  20% {
    opacity: 1;
    transform: translateY(0) rotateX(0deg);
  }
  70% {
    opacity: 1;
    transform: rotateX(0deg) translateY(0);
  }
  100% {
    opacity: 0;
    transform: rotateX(100deg) translateY(18px) rotateZ(-12deg);
    pointer-events: none;
  }
}

/* Carte 2 : "Desk" qui prend la place définitive */
.brand-animated .card-desk {
  color: #0d9488;
  opacity: 0;
  transform: rotateX(-95deg) translateY(-14px);
  animation: animCardDesk 0.55s cubic-bezier(0.2, 0.9, 0.3, 1.2) 2.05s forwards;
}

@keyframes animCardDesk {
  0% {
    opacity: 0;
    transform: rotateX(-95deg) translateY(-14px);
  }
  70% {
    opacity: 1;
    transform: rotateX(10deg) translateY(0);
  }
  100% {
    opacity: 1;
    transform: rotateX(0deg) translateY(0);
  }
}
