/* ====================
   VARIABLES GLOBALES
   ==================== */
:root {
  --primary:       #1E3A5F;     /* Bleu foncé principal */
  --accent:        #FF6B35;     /* Orange mécanique */
  --text:          #333;        /* Texte principal */
  --light-text:    #666;        /* Texte secondaire */
  --bg-light:      #f9f9f9;     /* Fond clair site */
  --bg-card:       #f0f8ff;     /* Fond spécial (checklist) */
  --border:        #ddd;        /* Bordures grises */
  --shadow:        0 0 10px rgba(0, 0, 0, 0.1);
  --font-main:     'Open Sans', sans-serif;
  --font-title:    'Montserrat', sans-serif;
  --radius:        8px;
  --transition:    all 0.3s ease;
}

/* ====================
   RÉINITIALISATION
   ==================== */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

/* ====================
   BASE & TYPOGRAPHIE
   ==================== */
body {
  font-family: var(--font-main);
  background-color: var(--bg-light);
  color: var(--text);
  line-height: 1.6;
}

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-title);
  font-weight: 700;
  color: var(--primary);
}

/* ====================
   HEADER & NAVIGATION
   ==================== */
header {
  background-color: var(--primary);
  color: white;
  text-align: center;
  padding: 20px;
}

/* Force les titres et textes dans le header à être blancs */
header h1,
header h2,
header h3,
header p,
header a {
  color: white !important;
}

nav {
  background-color: #0f1a2c;
  display: flex;
  justify-content: center;
  padding: 12px 0;
}

nav a {
  color: white;
  margin: 0 15px;
  text-decoration: none;
  font-weight: bold;
  transition: color 0.3s ease;
}

nav a:hover {
  text-decoration: underline;
  color: var(--accent);
}

/* ====================
   CONTENEUR PRINCIPAL
   ==================== */
.container {
  max-width: 1000px;
  margin: auto;
  padding: 40px 20px;
}

@media (max-width: 768px) {
  .container {
    padding: 20px;
  }
}

/* ====================
   TITRES CENTRÉS
   ==================== */
h1 {
  text-align: center;
  margin-bottom: 10px;
}

h2 {
  text-align: center;
  margin: 30px 0 15px;
}

/* ====================
   MÉTADONNÉES (ARTICLES)
   ==================== */
.meta {
  text-align: center;
  color: var(--light-text);
  font-size: 0.9rem;
  margin-bottom: 30px;
}

/* ====================
   IMAGES
   ==================== */
img {
  width: 100%;
  height: auto;
  border-radius: var(--radius);
  margin: 20px 0;
}

/* ====================
   CHECKLIST (ARTICLE)
   ==================== */
.checklist {
  background-color: var(--bg-card);
  border-left: 4px solid var(--primary);
  padding: 15px;
  margin: 30px 0;
  border-radius: 0 var(--radius) var(--radius) 0;
}

.checklist ul {
  padding-left: 20px;
}

.checklist li {
  margin: 8px 0;
}

/* ====================
   CALL TO ACTION (CTA)
   ==================== */
.cta {
  background-color: var(--accent);
  color: white;
  padding: 20px;
  text-align: center;
  border-radius: var(--radius);
  margin: 40px 0;
}

.cta a {
  color: white;
  font-weight: bold;
  text-decoration: underline;
}

.cta a:hover {
  opacity: 0.9;
}

/* ====================
   SECTIONS & LISTES
   ==================== */
.section-title,
.category-title {
  color: var(--primary);
  border-bottom: 2px solid var(--accent);
  padding-bottom: 8px;
  margin-bottom: 20px;
}

ul {
  list-style: none;
  padding-left: 0;
  margin: 10px 0;
}

ul li::before {
  content: "🔧 ";
  color: var(--accent);
}

/* ====================
   FORMULAIRES
   ==================== */
input[type="text"],
textarea {
  width: 100%;
  padding: 10px;
  margin: 10px 0;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  font-family: var(--font-main);
  font-size: 1rem;
}

button {
  background-color: var(--accent);
  color: white;
  border: none;
  padding: 10px 20px;
  border-radius: var(--radius);
  cursor: pointer;
  font-size: 1rem;
  font-weight: 600;
  transition: var(--transition);
}

button:hover {
  opacity: 0.9;
  transform: translateY(-1px);
}

/* ====================
   VIDEOS - GRILLE & CARDS
   ==================== */
.video-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 20px;
}

.video-card {
  background: white;
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
  transition: var(--transition);
}

.video-card:hover {
  transform: translateY(-5px);
}

.video-card iframe {
  width: 100%;
  height: 180px;
  border: none;
}

.video-info {
  padding: 15px;
}

.video-info h3 {
  margin: 0 0 10px;
  font-size: 1.1rem;
}

.video-info p {
  font-size: 0.9rem;
  color: var(--light-text);
}

/* ====================
   BARRE DE RECHERCHE
   ==================== */
.search-bar {
  display: flex;
  justify-content: center;
  margin: 20px 0;
}

.search-bar input {
  width: 70%;
  max-width: 500px;
  padding: 12px;
  border: 1px solid var(--border);
  border-radius: 6px 0 0 6px;
  font-size: 1rem;
}

.search-bar button {
  padding: 12px 20px;
  background-color: var(--accent);
  color: white;
  border: none;
  border-radius: 0 6px 6px 0;
  cursor: pointer;
  font-weight: 600;
  transition: var(--transition);
}

.search-bar button:hover {
  opacity: 0.9;
}

/* ====================
   ARTICLES SIMILAIRES
   ==================== */
.related {
  margin-top: 50px;
  padding-top: 20px;
  border-top: 1px dashed var(--border);
}

.related a {
  color: var(--primary);
  text-decoration: none;
  font-weight: 500;
}

.related a:hover {
  text-decoration: underline;
}

/* ====================
   COMMENTAIRES
   ==================== */
.comments {
  margin-top: 50px;
  padding: 20px;
  background-color: var(--bg-light);
  border-radius: var(--radius);
}

/* ====================
   FOOTER
   ==================== */
footer {
  text-align: center;
  padding: 30px 20px;
  background-color: var(--primary);
  color: white;
  font-size: 0.9rem;
}

footer a {
  color: white;
  text-decoration: underline;
  transition: color 0.3s ease;
}

footer a:hover {
  text-decoration: none;
  color: var(--accent);
}