/* ================================
   QUORIX - CSS Unifié
   Charte fondation + Styles spécifiques
   ================================ */

/* --- Variables de couleur --- */
:root {
  /* Palette principale */
  --color-primary: #1E5D44;   /* Vert profond */
  --color-secondary: #2E8C6A; /* Vert moyen */
  --color-accent: #E8C547;    /* Jaune naturel */

  /* Couleurs neutres */
  --color-light: #F5F5F5;
  --color-dark: #1A1A1A;
  --color-gray: #777;

  /* États / alertes */
  --color-success: #2E8C6A;
  --color-warning: #E8C547;
  --color-error: #C0392B;

  /* Typographie */
  --font-primary: 'Roboto', sans-serif;
  --font-secondary: 'Merriweather', serif;

  /* Tailles */
  --max-width: 1200px;
}

/* --- Reset rapide --- */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: var(--font-primary);
  font-size: 16px;
  line-height: 1.6;
  background: var(--color-light);
  color: var(--color-dark);
}

/* --- Liens --- */
a {
  color: var(--color-secondary);
  text-decoration: none;
}
a:hover {
  text-decoration: underline;
}

/* ================================
   HEADER / NAVBAR
   ================================ */
header, footer {
  background: var(--color-primary);
  color: white;
  padding: 1.5rem 2rem;
}
header h1, footer h1 {
  font-family: var(--font-secondary);
}

.navbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  background-color: white;
  padding: 1em 2em;
  border-bottom: 1px solid #e5e7eb;
  flex-wrap: wrap;
}
.logo {
  font-weight: bold;
  font-size: 1.4em;
  color: var(--color-primary);
}
.burger {
  display: none;
  font-size: 1.8em;
  background: none;
  border: none;
  cursor: pointer;
}
.navbar-right {
  display: flex;
  gap: 1.5em;
}
.navbar-right a {
  font-weight: 500;
}

/* ================================
   BOUTONS
   ================================ */
.btn,
.cta-button {
  display: inline-block;
  padding: 0.7em 1.2em;
  border-radius: 6px;
  font-weight: bold;
  cursor: pointer;
  border: none;
  transition: background 0.3s ease;
}
.btn-primary,
.cta-button {
  background: var(--color-primary);
  color: white;
}
.btn-primary:hover,
.cta-button:hover {
  background: var(--color-secondary);
}
.btn-secondary {
  background: var(--color-secondary);
  color: white;
}
.btn-secondary:hover {
  background: var(--color-primary);
}
.btn-disabled {
  background: var(--color-gray);
  color: #ccc;
  cursor: not-allowed;
}

/* ================================
   PAGE ACCUEIL
   ================================ */
.main-content {
  text-align: center;
  margin-top: 10vh;
  padding: 2em;
}
.main-content h1 {
  font-size: 2em;
  margin-bottom: 0.5em;
  color: var(--color-primary);
}
.main-content p {
  max-width: 600px;
  margin: 0 auto;
  line-height: 1.6;
  font-size: 1rem;
}

/* ================================
   FORMULAIRES
   ================================ */
.form-container {
  max-width: 800px;
  margin: 8vh auto;
  background-color: white;
  padding: 2.5em;
  border-radius: 12px;
  box-shadow: 0 0 10px rgba(0,0,0,0.05);
}
.form-container h2 {
  text-align: center;
  margin-bottom: 1.5em;
  color: var(--color-primary);
}
.form-container form {
  display: flex;
  flex-direction: column;
  gap: 1.2em;
}
.form-container label {
  font-weight: 500;
  color: var(--color-dark);
  margin-bottom: 0.3em;
}
.form-container input,
.form-container select,
.form-container textarea {
  width: 100%;
  padding: 0.6em;
  border: 1px solid var(--color-gray);
  border-radius: 4px;
  font-family: var(--font-primary);
  font-size: 1em;
}
.form-container input:focus,
.form-container select:focus,
.form-container textarea:focus {
  outline: none;
  border-color: var(--color-primary);
  box-shadow: 0 0 5px rgba(30, 93, 68, 0.3);
}
.form-container button {
  background-color: var(--color-primary);
  color: white;
  font-weight: bold;
  border: none;
  border-radius: 6px;
  cursor: pointer;
  padding: 0.7em;
}
.form-container button:hover {
  background-color: var(--color-secondary);
}

/* ================================
   TABLEAUX & DASHBOARD
   ================================ */
.dashboard-container {
  padding: 2em;
  max-width: 1000px;
  margin: 0 auto;
}
.filter-form {
  display: flex;
  flex-wrap: wrap;
  gap: 1em;
  margin-bottom: 1.5em;
  align-items: center;
}
.filter-form input,
.filter-form select,
.filter-form button {
  padding: 0.5em;
  border: 1px solid #d1d5db;
  border-radius: 6px;
  font-size: 0.95em;
}
.filter-form button {
  background-color: var(--color-primary);
  color: white;
  font-weight: bold;
  cursor: pointer;
}
.filter-form button:hover {
  background-color: var(--color-secondary);
}
.table-wrapper {
  overflow-x: auto;
}
table {
  width: 100%;
  border-collapse: collapse;
}
th, td {
  padding: 0.75em;
  border: 1px solid #e5e7eb;
  text-align: left;
}
th {
  background-color: var(--color-primary);
  color: white;
}
.etat {
  font-weight: bold;
  padding: 0.2em 0.6em;
  border-radius: 4px;
}
.etat.ok {
  background-color: #bbf7d0;
  color: var(--color-primary);
}
.etat.en_attente {
  background-color: #fecaca;
  color: #7f1d1d;
}

/* ================================
   CARTES / CARDS
   ================================ */
.card {
  background: white;
  border-radius: 6px;
  padding: 1.5rem;
  box-shadow: 0 2px 6px rgba(0,0,0,0.05);
  margin-bottom: 1.5rem;
}

/* ================================
   FLASH MESSAGES
   ================================ */
.flash-container {
  max-width: 1000px;
  margin: 1em auto;
}
.flash-message {
  background-color: #dcfce7;
  padding: 1em;
  border-left: 5px solid #22c55e;
  margin-bottom: 1em;
  border-radius: 6px;
}

/* ================================
   RESPONSIVE
   ================================ */
@media (max-width: 768px) {
  header, footer {
    text-align: center;
  }
  .navbar {
    flex-direction: column;
    align-items: flex-start;
  }
  .burger {
    display: block;
  }
  .navbar-right {
    display: none;
    flex-direction: column;
    width: 100%;
    margin-top: 1em;
  }
  .navbar-right.show {
    display: flex;
  }
  .main-content h1 {
    font-size: 1.5em;
  }
  .main-content p {
    font-size: 0.95em;
  }
  .form-container {
    margin: 4vh 1em;
    padding: 1.5em;
    max-width: 100%;
  }
  .form-container form {
    gap: 1em;
  }
  .dashboard-container {
    padding: 1.5em;
  }
  .filter-form {
    flex-direction: column;
    align-items: stretch;
  }
  table {
    font-size: 0.9em;
  }
  .btn, .cta-button {
    width: 100%;
    text-align: center;
  }
}
/* ================================
   PAGE D'ACCUEIL - Styles spécifiques
   ================================ */
  .tagline {
    margin-top: 0.3em;
    font-size: 1.1em;
    font-weight: 300;
  }
  .logo-home {
    max-width: 250px;
    margin-bottom: 1.5em;
  }
  .text-center {
    text-align: center;
  }
