/* 🔒 [NE PAS MODIFIER] - DESIGN SYSTEM PORTAIL & ADMIN COMBINÉ */

/* --- CONFIGURATION DES VARIABLES GLOBALES --- */
:root {
  /* Dimensions */
  --sidebar-width: 260px;
  
  /* Couleurs de fond et cartes */
  --bg-portal: #0b0f19;
  --card-portal: #131a2c;
  --border-portal: rgba(255, 255, 255, 0.06);
  
  /* Couleurs d'accentuation (Ajoutées pour éviter les bugs) */
  --blue: #2563eb;
  --green: #10b981;
  --orange: #f97316;
  
  /* Typographies et Textes (Ajoutés) */
  --text-100: #ffffff;
  --text-muted: #94a3b8;
  --font-body: system-ui, -apple-system, sans-serif;
  --font-head: system-ui, -apple-system, sans-serif;
  
  /* Arrondis (Ajoutés) */
  --radius-sm: 6px;
  --radius-md: 12px;
}

/* --- DESIGN SYSTEM PORTAIL --- */
body.portal-body {
  background-color: var(--bg-portal);
  color: var(--text-100);
  margin: 0;
  font-family: var(--font-body);
  display: flex;
  min-height: 100vh;
}

/* --- SIDEBAR DU PORTAIL --- */
.portal-sidebar {
  width: var(--sidebar-width);
  background-color: var(--card-portal);
  border-right: 1px solid var(--border-portal);
  display: flex;
  flex-direction: column;
  position: fixed;
  top: 0;
  bottom: 0;
  left: 0;
  z-index: 100;
}

.sidebar-brand {
  padding: 24px;
  font-family: var(--font-head);
  font-size: 1.2rem;
  font-weight: 700;
  border-bottom: 1px solid var(--border-portal);
}

/* Ajout pour harmoniser la marque dans la sidebar */
.sidebar-brand span {
  color: var(--orange);
}

.sidebar-menu {
  list-style: none;
  padding: 20px 12px;
  margin: 0;
  flex-grow: 1;
}

.sidebar-menu li {
  margin-bottom: 8px;
}

.sidebar-menu a {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px;
  color: var(--text-muted);
  text-decoration: none;
  border-radius: var(--radius-sm);
  font-size: 0.95rem;
  transition: all 0.2s ease;
}

.sidebar-menu a:hover, 
.sidebar-menu a.active {
  color: #fff;
  background-color: rgba(255, 255, 255, 0.04);
}

.sidebar-menu a.active {
  border-left: 3px solid var(--blue);
  background-color: rgba(37, 99, 235, 0.1);
}

/* --- CONTENEUR PRINCIPAL --- */
.portal-container {
  margin-left: var(--sidebar-width);
  flex-grow: 1;
  padding: 40px;
  max-width: 1400px;
}

.portal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 32px;
  border-bottom: 1px solid var(--border-portal);
  padding-bottom: 20px;
}

/* --- COMPOSANT : BARRE DE PROGRESSION DU PARCOURS --- */
.parcours-progress-card {
  background: var(--card-portal);
  border: 1px solid var(--border-portal);
  border-radius: var(--radius-md);
  padding: 24px;
  margin-bottom: 32px;
}

.progress-track {
  width: 100%;
  height: 8px;
  background: rgba(255, 255, 255, 0.1);
  border-radius: 4px;
  margin-top: 12px;
  overflow: hidden;
}

.progress-bar {
  height: 100%;
  background: linear-gradient(90deg, var(--blue), var(--green));
  width: 35%; 
  transition: width 0.4s ease;
}

/* --- TABLEAU DE BORD : GRILLE DES COMPOSANTS --- */
.portal-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 24px;
}

.portal-card {
  background: var(--card-portal);
  border: 1px solid var(--border-portal);
  border-radius: var(--radius-md);
  padding: 24px;
}

/* --- DESIGN SYSTEM ADMIN --- */
body.admin-body {
  background-color: #080b11;
  color: #e2e8f0;
  font-family: var(--font-body); /* Aligné sur la police globale */
  margin: 0;
}

.admin-wrapper {
  display: flex;
}

.admin-content {
  margin-left: var(--sidebar-width); /* Utilise la même largeur de sidebar */
  padding: 40px;
  width: calc(100% - var(--sidebar-width));
}

/* --- TABLEAU DE BORD & INDICATEURS (KPI) --- */
.kpi-row {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
  margin-bottom: 32px;
}

.kpi-card {
  background: #111726;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: var(--radius-sm);
  padding: 20px;
}

.kpi-value {
  font-size: 1.8rem;
  font-weight: 700;
  margin-top: 8px;
  color: #fff;
}

.kpi-value.alert { color: #ef4444; }
.kpi-value.success { color: var(--green); }

/* --- GRILLE DE DONNÉES / TABLEAUX DE SUIVI --- */
.admin-table-wrapper {
  background: #111726;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: var(--radius-sm);
  overflow: hidden;
}

.admin-table {
  width: 100%;
  border-collapse: collapse;
  text-align: left;
}

.admin-table th {
  background: #172033;
  padding: 14px 20px;
  font-size: 0.85rem;
  text-transform: uppercase;
  color: var(--text-muted);
  letter-spacing: 0.05em;
}

.admin-table td {
  padding: 16px 20px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
  font-size: 0.92rem;
}

/* --- BADGES DE STATUT (CRÉATEURS / ENTREPRISES) --- */
.badge-status {
  padding: 4px 8px;
  border-radius: 4px;
  font-size: 0.75rem;
  font-weight: 600;
}

.badge-status.verification { background: rgba(245, 158, 11, 0.15); color: #f59e0b; }
.badge-status.actif { background: rgba(16, 185, 129, 0.15); color: #10b981; }
.badge-status.alerte { background: rgba(239, 68, 68, 0.15); color: #ef4444; }

/* ==========================================
   6. STYLES DU FOOTER (BAS DE PAGE)
   ========================================== */
footer {
  background-color: #060a13; /* Fond encore un peu plus sombre pour marquer la fin */
  border-top: 1px solid var(--border-color);
  padding: 60px 5% 40px 5%;
  margin-top: 80px;
}

.footer-inner {
  max-width: 1200px;
  margin: 0 auto;
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr repeat(2, 1fr); /* La colonne marque prend plus de place */
  gap: 40px;
}

.footer-col h4 {
  color: var(--text-100);
  font-size: 1rem;
  font-weight: 600;
  margin-top: 0;
  margin-bottom: 20px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.footer-col ul {
  list-style: none; /* Supprime les puces d'origines */
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 12px; /* Espace bien les liens */
}

.footer-col ul li a {
  color: var(--text-muted);
  text-decoration: none; /* Supprime le soulignement moche */
  font-size: 0.9rem;
  transition: color 0.2s ease;
}

.footer-col ul li a:hover {
  color: var(--text-100); /* Le lien devient blanc au survol */
}

/* Colonne de gauche avec le Logo */
.brand-col .footer-logo {
  font-size: 1.3rem;
  font-weight: 800;
  color: var(--text-100);
  margin-bottom: 16px;
}

.brand-col .footer-logo span {
  color: var(--orange);
}

.brand-col p {
  color: var(--text-muted);
  font-size: 0.9rem;
  line-height: 1.6;
  max-width: 320px;
  margin: 0;
}

/* Version Mobile / Tablettes */
@media (max-width: 768px) {
  .footer-grid {
    grid-template-columns: 1fr; /* Tout s'empile proprement sur mobile */
    gap: 32px;
  }
}