/* =========================================
   STYLES CONNECT3S ASSISTANCE NICE
   PALETTE STRICTE : Bleu #1e3a8a + Gris #4a4a4a
   Optimisé pour charte graphique Connect3S
   ========================================= */

:root { 
  /* Palette officielle Connect3S UNIQUEMENT */
  --brand-blue: #1e3a8a;
  --brand-blue-light: #2563eb;
  --brand-blue-dark: #1e40af;
  --brand-gray: #4a4a4a;
  --brand-gray-light: #6b7280;
  
  /* Couleurs système pour lisibilité */
  --text: #1a1a1a;
  --bg: #f7f9fc;
  --card: #ffffff;
  --border: #e6eef6;
  --shadow: rgba(30, 58, 138, 0.08);
  --success: #16a34a;
}

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

body {
  font-family: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  color: var(--text);
  background: var(--bg);
  line-height: 1.6;
}

.wrap { 
  max-width: 1100px; 
  margin: 0 auto; 
  padding: 24px;
}

/* ========== HEADER ========== */
header { 
  background: linear-gradient(135deg, var(--brand-blue) 0%, var(--brand-blue-dark) 100%);
  color: white;
  box-shadow: 0 2px 8px var(--shadow);
}

header .brand { 
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 20px 0;
}

header .brand img {
  max-width: 180px;
  height: auto;
  border-radius: 8px;
}

header .brand-name { 
  font-size: 1.8rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: white;
}

header p {
  font-size: 1rem;
  opacity: 0.95;
  margin-top: 4px;
  color: white;
}

/* ========== NAVIGATION ========== */
nav {
  background: var(--card);
  border-bottom: 3px solid var(--brand-blue);
  box-shadow: 0 1px 4px var(--shadow);
  position: sticky;
  top: 0;
  z-index: 1000;
}

nav ul {
  list-style: none;
  display: flex;
  gap: 0;
  flex-wrap: wrap;
}

nav li { 
  flex: 1; 
  min-width: 150px;
}

nav a {
  display: block;
  padding: 16px 24px;
  color: var(--brand-gray);
  text-decoration: none;
  font-weight: 600;
  text-align: center;
  transition: all 0.3s;
  border-bottom: 3px solid transparent;
}

nav a:hover {
  background: #f0f4f8;
  color: var(--brand-blue);
  border-bottom-color: var(--brand-blue);
}

nav a.active {
  background: var(--brand-blue);
  color: white;
  border-bottom-color: var(--brand-blue-dark);
}

/* ========== HERO SECTION ========== */
.hero {
  background: linear-gradient(135deg, var(--brand-blue) 0%, var(--brand-blue-dark) 100%);
  color: white;
  padding: 64px 32px;
  border-radius: 16px;
  text-align: center;
  margin: 32px 0;
  box-shadow: 0 8px 32px rgba(30, 58, 138, 0.2);
}

.hero h1 {
  font-size: 2.5rem;
  margin-bottom: 24px;
  line-height: 1.2;
  color: white;
}

.hero p {
  font-size: 1.2rem;
  max-width: 800px;
  margin: 0 auto;
  opacity: 0.95;
  color: white;
}

.hero .cta {
  display: inline-block;
  padding: 16px 40px;
  background: white;
  color: var(--brand-blue);
  text-decoration: none;
  font-weight: 700;
  border-radius: 8px;
  font-size: 1.1rem;
  transition: transform 0.2s;
  box-shadow: 0 4px 12px rgba(0,0,0,0.2);
  margin-top: 24px;
}

.hero .cta:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(0,0,0,0.3);
}

/* ========== GROS CTA MEGA PRIORITAIRE ========== */
.cta-mega {
  background: linear-gradient(135deg, var(--brand-blue-light) 0%, var(--brand-blue) 100%);
  border: 4px solid var(--brand-blue-dark);
  border-radius: 16px;
  padding: 48px 32px;
  margin: 32px 0 48px 0;
  text-align: center;
  box-shadow: 0 8px 32px rgba(30, 58, 138, 0.25);
  animation: pulse-border 2s ease-in-out infinite;
}

@keyframes pulse-border {
  0%, 100% {
    box-shadow: 0 8px 32px rgba(30, 58, 138, 0.25);
  }
  50% {
    box-shadow: 0 12px 48px rgba(30, 58, 138, 0.4);
  }
}

.cta-mega h2 {
  color: white;
  font-size: 2.2rem;
  margin: 0 0 16px 0;
  border: none;
  padding: 0;
  text-shadow: 2px 2px 4px rgba(0,0,0,0.3);
}

.cta-mega p {
  color: white;
  font-size: 1.3rem;
  margin-bottom: 32px;
  opacity: 0.95;
  text-shadow: 1px 1px 3px rgba(0,0,0,0.2);
}

.cta-mega .btn-primary {
  display: inline-block;
  background: white;
  color: var(--brand-blue);
  padding: 20px 60px;
  font-size: 1.4rem;
  font-weight: 700;
  text-decoration: none;
  border-radius: 12px;
  box-shadow: 0 6px 20px rgba(0,0,0,0.25);
  transition: all 0.3s;
  border: 3px solid white;
}

.cta-mega .btn-primary:hover {
  transform: translateY(-4px);
  box-shadow: 0 10px 30px rgba(0,0,0,0.35);
  background: var(--brand-gray);
  color: white;
}

/* ========== CTA FINAL ========== */
.cta-final {
  background: linear-gradient(135deg, var(--brand-blue) 0%, var(--brand-blue-dark) 100%);
  color: white;
  padding: 48px 32px;
  border-radius: 12px;
  text-align: center;
  margin: 48px 0;
  box-shadow: 0 4px 16px rgba(30, 58, 138, 0.2);
}

.cta-final h2 {
  color: white;
  margin-bottom: 16px;
  font-size: 2rem;
  border: none;
  padding: 0;
}

.cta-final p {
  font-size: 1.2rem;
  margin-bottom: 24px;
  opacity: 0.95;
  color: white;
}

.btn-cta {
  display: inline-block;
  background: white;
  color: var(--brand-blue);
  padding: 16px 40px;
  border-radius: 8px;
  text-decoration: none;
  font-weight: 700;
  font-size: 1.1rem;
  box-shadow: 0 4px 12px rgba(0,0,0,0.2);
  transition: all 0.3s;
}

.btn-cta:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(0,0,0,0.3);
  background: var(--brand-gray);
  color: white;
}

.btn-secondary {
  display: inline-block;
  background: transparent;
  color: white;
  padding: 16px 40px;
  border-radius: 8px;
  text-decoration: none;
  font-weight: 700;
  font-size: 1.1rem;
  border: 3px solid white;
  transition: all 0.3s;
}

.btn-secondary:hover {
  background: white;
  color: var(--brand-blue);
  transform: translateY(-2px);
}

/* ========== CARDS & GRID ========== */
.grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 24px;
  margin: 32px 0;
}

.card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 32px;
  box-shadow: 0 2px 8px var(--shadow);
  transition: all 0.3s;
}

.card:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 24px var(--shadow);
  border-color: var(--brand-blue);
}

.card h3 {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 16px;
  color: var(--brand-gray);
  font-size: 1.3rem;
}

.card h3::before {
  content: "◆";
  color: var(--brand-blue);
  font-size: 1.5rem;
}

.card ul {
  list-style: none;
  margin-top: 16px;
}

.card ul li {
  padding: 8px 0 8px 28px;
  position: relative;
  color: #555;
}

.card ul li::before {
  content: "✓";
  position: absolute;
  left: 0;
  color: var(--brand-blue);
  font-weight: 700;
  font-size: 1.1rem;
}

/* ========== SECTIONS ========== */
main {
  min-height: 60vh;
}

section {
  margin: 48px 0;
}

section h2 {
  color: var(--brand-blue);
  font-size: 2rem;
  margin-bottom: 24px;
  padding-bottom: 12px;
  border-bottom: 3px solid var(--brand-blue);
}

section > p {
  font-size: 1.1rem;
  line-height: 1.8;
  color: var(--brand-gray);
  margin-bottom: 24px;
}

/* ========== TABLEAUX ========== */
table {
  width: 100%;
  border-collapse: collapse;
  margin: 24px 0;
  background: var(--card);
  box-shadow: 0 2px 8px var(--shadow);
  border-radius: 8px;
  overflow: hidden;
}

thead {
  background: linear-gradient(135deg, var(--brand-blue) 0%, var(--brand-blue-dark) 100%);
  color: white;
}

th {
  padding: 16px;
  text-align: left;
  font-weight: 600;
}

tbody tr {
  border-bottom: 1px solid var(--border);
}

tbody tr:hover {
  background: #f0f4f8;
}

td {
  padding: 16px;
  color: var(--text);
}

/* Colonne recommandée */
th.recommended,
td.recommended {
  background: linear-gradient(135deg, #fffbeb 0%, #fef3c7 100%);
  font-weight: 600;
  color: #92400e;
}

/* ========== FOOTER ========== */
footer {
  background: linear-gradient(135deg, var(--brand-gray) 0%, #2d2d2d 100%);
  color: white;
  padding: 40px 0;
  margin-top: 64px;
  box-shadow: 0 -2px 8px rgba(0,0,0,0.1);
}

footer p {
  text-align: center;
  opacity: 0.9;
}

footer a {
  color: white;
  text-decoration: underline;
  opacity: 0.8;
  transition: opacity 0.2s;
}

footer a:hover {
  opacity: 1;
}

/* ========== RESPONSIVE ========== */
@media (max-width: 768px) {
  .wrap {
    padding: 16px;
  }
  
  header .brand {
    flex-direction: column;
    text-align: center;
  }
  
  header .brand img {
    max-width: 140px;
  }
  
  header .brand-name {
    font-size: 1.5rem;
  }
  
  nav ul {
    flex-direction: column;
  }
  
  nav li {
    width: 100%;
    min-width: 0;
  }
  
  .hero h1 {
    font-size: 1.8rem;
  }
  
  .hero p {
    font-size: 1rem;
  }
  
  .cta-mega h2 {
    font-size: 1.6rem;
  }
  
  .cta-mega p {
    font-size: 1.1rem;
  }
  
  .cta-mega .btn-primary {
    padding: 16px 32px;
    font-size: 1.2rem;
  }
  
  section h2 {
    font-size: 1.6rem;
  }
  
  .grid {
    grid-template-columns: 1fr;
  }
  
  table {
    font-size: 0.9rem;
  }
  
  th, td {
    padding: 12px 8px;
  }
}

/* ========== ACCESSIBILITÉ ========== */
/* Assurer des contrastes suffisants */
a:focus,
button:focus {
  outline: 3px solid var(--brand-blue);
  outline-offset: 2px;
}

/* Éviter les textes foncés sur fond foncé */
.card {
  color: var(--text); /* Texte noir sur fond blanc */
}

.hero,
.cta-mega,
.cta-final {
  color: white; /* Texte blanc sur fond bleu */
}

/* S'assurer que tous les liens sont visibles */
a {
  color: var(--brand-blue);
  text-decoration: underline;
}

a:hover {
  color: var(--brand-blue-dark);
}

/* Boutons avec contraste élevé */
.btn-primary,
.btn-cta,
.btn-secondary {
  min-width: 120px;
  min-height: 44px; /* Taille minimale pour accessibilité tactile */
}

/* ========== UTILITAIRES ========== */
.text-center {
  text-align: center;
}

.mt-2 {
  margin-top: 16px;
}

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

.mb-2 {
  margin-bottom: 16px;
}

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

strong {
  font-weight: 700;
  color: inherit;
}
