/* ============================================
   SECOURS IMMÉDIAT AU DÉCÈS - REFONTE 2025
   Design moderne et accessible
   ============================================ */

:root {
  /* Palette de couleurs raffinée */
  --primary: #003A70;
  --primary-dark: #002750;
  --primary-light: #0052A0;
  --accent: #FFD200;
  --accent-dark: #E6BD00;
  --ink: #0f172a;
  --muted: #64748b;
  --surface: #ffffff;
  --border: #e2e8f0;
  --bg: #f8fafc;
  --bg-light: #ffffff;
  --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  
  /* Ombres élégantes */
  --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.08);
  --shadow-md: 0 4px 12px rgba(0, 58, 112, 0.08);
  --shadow-lg: 0 10px 40px rgba(0, 58, 112, 0.12);
  --shadow-xl: 0 20px 60px rgba(0, 58, 112, 0.15);
}

/* ============================================
   BASE STYLES
   ============================================ */

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  font-size: 16px;
}

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
  color: var(--ink);
  background: var(--bg);
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

a {
  color: var(--primary);
  text-decoration: none;
  transition: var(--transition);
}

a:hover {
  color: var(--primary-light);
  text-decoration: none;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

/* ============================================
   CONTAINER & LAYOUT
   ============================================ */

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
}

@media (min-width: 768px) {
  .container {
    padding: 0 40px;
  }
}

/* ============================================
   TOP BAR - Modernisée
   ============================================ */

.topbar {
  background: linear-gradient(135deg, var(--primary-dark) 0%, var(--primary) 100%);
  color: #ffffff;
  font-size: 13px;
  padding: 12px 0;
  box-shadow: var(--shadow-sm);
}

.topbar .container {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  justify-content: space-between;
  align-items: center;
}

.topbar a {
  color: #ffffff;
  text-decoration: none;
  padding: 4px 8px;
  border-radius: 4px;
  transition: var(--transition);
  font-weight: 500;
}

.topbar a:hover {
  background: rgba(255, 255, 255, 0.15);
  transform: translateY(-1px);
}

/* ============================================
   NAVIGATION - Design épuré avec logo proéminent
   ============================================ */

nav.site {
  position: sticky;
  top: 0;
  background: rgba(255, 255, 255, 0.98);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
  z-index: 1000;
  box-shadow: var(--shadow-sm);
  transition: var(--transition);
}

nav.site:hover {
  box-shadow: var(--shadow-md);
}

nav .wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 0;
  gap: 24px;
}

/* LOGO - Mise en valeur maximale */
.brand {
  display: flex;
  align-items: center;
  gap: 16px;
  font-weight: 800;
  font-size: 20px;
  color: var(--primary);
  text-decoration: none;
  transition: var(--transition);
  flex-shrink: 0;
}

.brand:hover {
  transform: translateY(-2px);
  color: var(--primary-dark);
}

.brand img {
  height: 100px;
  width: auto;
  object-fit: contain;
  filter: drop-shadow(0 4px 12px rgba(0, 58, 112, 0.15));
  transition: var(--transition);
}

.brand:hover img {
  filter: drop-shadow(0 6px 16px rgba(0, 58, 112, 0.25));
  transform: scale(1.03);
}

/* Menu de navigation */
.menu {
  display: none;
  gap: 8px;
  align-items: center;
  flex-wrap: wrap;
}

.menu a {
  padding: 10px 18px;
  border-radius: 8px;
  font-weight: 600;
  font-size: 15px;
  color: var(--ink);
  transition: var(--transition);
  position: relative;
}

.menu a::after {
  content: '';
  position: absolute;
  bottom: 6px;
  left: 50%;
  transform: translateX(-50%) scaleX(0);
  width: 80%;
  height: 3px;
  background: var(--accent);
  border-radius: 2px;
  transition: var(--transition);
}

.menu a:hover {
  color: var(--primary);
  background: rgba(0, 58, 112, 0.05);
}

.menu a:hover::after,
.menu a[aria-current="page"]::after {
  transform: translateX(-50%) scaleX(1);
}

.menu a[aria-current="page"] {
  color: var(--primary);
  background: rgba(0, 58, 112, 0.08);
}

/* Toggle menu mobile */
.toggle {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  border: 2px solid var(--border);
  background: var(--surface);
  padding: 10px 16px;
  border-radius: 10px;
  font-weight: 600;
  cursor: pointer;
  transition: var(--transition);
}

.toggle:hover {
  border-color: var(--primary);
  background: rgba(0, 58, 112, 0.05);
  transform: translateY(-2px);
  box-shadow: var(--shadow-sm);
}

@media (min-width: 860px) {
  .menu {
    display: flex;
  }
  .toggle {
    display: none;
  }
}

/* Menu mobile */
.mobile {
  display: none;
  border-top: 1px solid var(--border);
  padding: 20px 0;
  background: var(--bg-light);
  gap: 12px;
  flex-wrap: wrap;
}

.mobile a {
  padding: 8px 16px;
  border-radius: 6px;
  font-weight: 600;
  transition: var(--transition);
}

.mobile a:hover {
  background: rgba(0, 58, 112, 0.08);
  color: var(--primary);
}

/* ============================================
   HERO SECTION - Moderne et impactante
   ============================================ */

.hero {
  position: relative;
  padding: 80px 0;
  background: linear-gradient(135deg, #0b2540 0%, #003A70 50%, #224d74 100%);
  color: #ffffff;
  overflow: hidden;
}

.hero::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: 
    radial-gradient(circle at 20% 50%, rgba(255, 210, 0, 0.1) 0%, transparent 50%),
    radial-gradient(circle at 80% 80%, rgba(255, 210, 0, 0.08) 0%, transparent 50%);
  pointer-events: none;
}

.hero .container {
  position: relative;
  z-index: 1;
}

.hero h1 {
  font-size: clamp(32px, 6vw, 54px);
  line-height: 1.15;
  margin: 0 0 24px;
  font-weight: 800;
  letter-spacing: -0.02em;
  text-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
}

.hero p {
  font-size: clamp(17px, 2.5vw, 20px);
  color: #e2e8f0;
  margin: 0 0 32px;
  max-width: 720px;
  line-height: 1.7;
  font-weight: 400;
}

.hero .btn {
  margin: 8px 12px 8px 0;
}

/* ============================================
   BUTTONS - Design moderne
   ============================================ */

.btn {
  display: inline-block;
  padding: 14px 32px;
  border-radius: 50px;
  font-weight: 700;
  font-size: 16px;
  border: 2px solid transparent;
  cursor: pointer;
  transition: var(--transition);
  text-decoration: none;
  text-align: center;
  box-shadow: var(--shadow-md);
}

.btn-primary {
  background: var(--accent);
  color: #111111;
  border-color: var(--accent);
}

.btn-primary:hover {
  background: var(--accent-dark);
  transform: translateY(-3px);
  box-shadow: var(--shadow-lg);
}

.btn-outline {
  border-color: var(--accent);
  color: var(--accent);
  background: transparent;
  box-shadow: none;
}

.btn-outline:hover {
  background: var(--accent);
  color: #111111;
  transform: translateY(-3px);
  box-shadow: var(--shadow-md);
}

/* ============================================
   SECTIONS
   ============================================ */

.section {
  padding: 72px 0;
}

.h2 {
  font-size: clamp(28px, 4vw, 38px);
  color: var(--primary);
  margin: 0 0 20px;
  font-weight: 800;
  line-height: 1.2;
  letter-spacing: -0.01em;
}

/* ============================================
   CARDS - Design épuré et moderne
   ============================================ */

.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 32px;
  box-shadow: var(--shadow-sm);
  transition: var(--transition);
  height: 100%;
}

.card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-lg);
  border-color: var(--primary);
}

/* ============================================
   GRID SYSTEM
   ============================================ */

.grid {
  display: grid;
  gap: 24px;
  margin: 32px 0;
}

.grid-2 {
  grid-template-columns: repeat(1, 1fr);
}

.grid-3 {
  grid-template-columns: repeat(1, 1fr);
}

@media (min-width: 640px) {
  .grid-2 {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 768px) {
  .grid-3 {
    grid-template-columns: repeat(3, 1fr);
  }
}

/* ============================================
   KPI - Indicateurs clés modernisés
   ============================================ */

.kpi {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 20px;
  margin: 48px 0;
}

.kpi .tile {
  background: linear-gradient(135deg, #0b2540 0%, #003A70 100%);
  color: #ffffff;
  border-radius: 16px;
  padding: 32px 24px;
  text-align: center;
  box-shadow: var(--shadow-lg);
  transition: var(--transition);
  border: 2px solid transparent;
}

.kpi .tile:hover {
  transform: translateY(-8px) scale(1.02);
  box-shadow: var(--shadow-xl);
  border-color: var(--accent);
}

.kpi .tile .big {
  font-size: clamp(36px, 5vw, 48px);
  font-weight: 900;
  color: var(--accent);
  margin-bottom: 8px;
  text-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
  line-height: 1;
}

.kpi .tile div:last-child {
  font-size: 16px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  opacity: 0.95;
}

/* ============================================
   LISTS
   ============================================ */

ul.clean {
  list-style: none;
  margin: 16px 0;
  padding: 0;
}

ul.clean li {
  padding: 14px 0;
  border-bottom: 1px solid var(--border);
  transition: var(--transition);
  font-weight: 500;
}

ul.clean li:last-child {
  border-bottom: none;
}

ul.clean li:hover {
  padding-left: 8px;
  color: var(--primary);
}

ul.clean a {
  display: block;
  color: inherit;
}

/* ============================================
   IMAGES
   ============================================ */

img.responsive {
  width: 100%;
  height: auto;
  border-radius: 16px;
  border: 1px solid var(--border);
  margin-top: 20px;
  box-shadow: var(--shadow-md);
  transition: var(--transition);
}

img.responsive:hover {
  box-shadow: var(--shadow-lg);
  transform: scale(1.02);
}

/* ============================================
   FOOTER - Design moderne
   ============================================ */

footer {
  background: linear-gradient(135deg, #0b1220 0%, #1a2332 100%);
  color: #cbd5e1;
  padding: 64px 0 32px;
  margin-top: 80px;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
}

footer .container > div:first-child {
  text-align: center;
  margin-bottom: 48px;
  padding-top: 0;
}

footer img {
  max-height: 40px;
  width: auto;
  margin: 0 auto;
  filter: brightness(0) invert(1) drop-shadow(0 4px 12px rgba(255, 255, 255, 0.2));
}

footer a {
  color: #cbd5e1;
  transition: var(--transition);
  font-weight: 500;
}

footer a:hover {
  color: var(--accent);
  padding-left: 4px;
}

footer strong {
  color: #ffffff;
  font-size: 18px;
  display: block;
  margin-bottom: 16px;
  font-weight: 700;
}

footer .grid {
  margin: 32px 0;
}

footer p {
  margin: 8px 0;
  line-height: 1.8;
}

footer .small {
  text-align: center;
  padding-top: 32px;
  margin-top: 32px;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  opacity: 0.7;
}

/* ============================================
   FORMS
   ============================================ */

.form input,
.form textarea,
.form select {
  width: 100%;
  padding: 14px 18px;
  border: 2px solid var(--border);
  border-radius: 12px;
  background: var(--surface);
  color: var(--ink);
  font-family: inherit;
  font-size: 15px;
  transition: var(--transition);
  margin-bottom: 16px;
}

.form input:focus,
.form textarea:focus,
.form select:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 4px rgba(0, 58, 112, 0.1);
}

.form label {
  display: block;
  margin-bottom: 8px;
  font-weight: 600;
  color: var(--ink);
  font-size: 14px;
}

.form button {
  margin-top: 16px;
}

/* ============================================
   UTILITY CLASSES
   ============================================ */

.small {
  font-size: 13px;
  color: var(--muted);
  line-height: 1.6;
}

.text-center {
  text-align: center;
}

.mt-4 {
  margin-top: 32px;
}

.mb-4 {
  margin-bottom: 32px;
}

/* ============================================
   ANIMATIONS
   ============================================ */

@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.fade-in-up {
  animation: fadeInUp 0.6s ease-out;
}

/* ============================================
   RESPONSIVE IMPROVEMENTS
   ============================================ */

@media (max-width: 640px) {
  .hero {
    padding: 56px 0;
  }
  
  .section {
    padding: 48px 0;
  }
  
  .kpi {
    grid-template-columns: 1fr;
  }
  
  .btn {
    display: block;
    width: 100%;
    margin: 8px 0;
  }
}

/* ============================================
   ACCESSIBILITY
   ============================================ */

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

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

/* ============================================
   PRINT STYLES
   ============================================ */

@media print {
  nav.site,
  .topbar,
  footer {
    display: none;
  }
  
  .hero {
    background: white;
    color: black;
  }
  
  * {
    box-shadow: none !important;
  }
}
