/* ═══════════════════════════════════════════════════════════════════════
   Layout — sidebar + contenu principal, et vue auth centrée
   ═══════════════════════════════════════════════════════════════════════ */

.shell { display: flex; height: 100%; }

/* ─── Sidebar de navigation (en verre) ─── */
.sidebar {
  width: var(--sidebar-w); flex-shrink: 0;
  background: var(--glass);
  backdrop-filter: blur(16px) saturate(1.1);
  -webkit-backdrop-filter: blur(16px) saturate(1.1);
  border-right: 1px solid var(--border);
  display: flex; flex-direction: column;
  padding: 14px 12px;
}
.nav-item {
  display: flex; align-items: center; gap: 9px;
  height: 32px; padding: 0 9px; border-radius: var(--radius-sm);
  color: var(--text-muted); font-weight: 450; font-size: 13px;
  letter-spacing: var(--tracking);
  cursor: pointer; transition: background var(--t-fast) var(--ease), color var(--t-fast) var(--ease),
              box-shadow var(--t-fast) var(--ease);
  margin-bottom: 2px; border: none; background: none; width: 100%; text-align: left;
  font-family: var(--font-body);
}
.nav-item:hover { background: var(--bg-hover); color: var(--text); }
.nav-item.active {
  background: var(--accent-soft); color: var(--text); font-weight: 500;
  box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--accent) 30%, transparent),
              0 0 16px color-mix(in srgb, var(--accent) 12%, transparent);
}
.nav-item.active .nav-ico svg { color: var(--accent); filter: drop-shadow(0 0 5px color-mix(in srgb, var(--accent) 70%, transparent)); }
.nav-item .nav-ico {
  width: 16px; height: 16px; flex-shrink: 0;
  display: inline-flex; align-items: center; justify-content: center;
}
.nav-item .nav-ico svg { width: 16px; height: 16px; display: block; opacity: 0.9; }
.nav-item .nav-badge {
  margin-left: auto; font-family: var(--font-mono); font-size: 10px;
  background: var(--danger-soft); color: var(--danger);
  padding: 1px 7px; border-radius: 10px;
}

/* ─── Groupes de navigation ─── */
.nav-group { margin-bottom: 10px; }
.nav-group:last-of-type { margin-bottom: 0; }
.nav-group-title {
  font-size: 10.5px; font-weight: 600;
  letter-spacing: 0.07em; text-transform: uppercase; color: var(--text-dim);
  padding: 6px 8px 5px;
}

.nav-spacer { flex: 1; }
.nav-foot {
  font-size: 11px; color: var(--text-dim); padding: 8px 12px;
  border-top: 1px solid var(--border); margin-top: 8px;
}
.nav-foot .ok { color: var(--success); }
.nav-foot .warn { color: var(--warning); }
.nav-foot-org { display: flex; align-items: center; gap: 6px; }
.nav-foot-ico { width: 13px; height: 13px; flex: none; display: inline-flex; align-items: center; }
.nav-foot-ico svg { width: 13px; height: 13px; display: block; }

/* ─── Contenu principal ─── */
.main {
  flex: 1; overflow-y: auto; padding: 24px 28px;
  display: flex; flex-direction: column; gap: 20px;
}
.page-head {
  display: flex; align-items: center; justify-content: space-between;
  gap: 16px; flex-wrap: wrap;
}
.page-title { font-size: 22px; font-weight: 700; letter-spacing: -0.3px; }
.page-sub { font-size: 13px; color: var(--text-muted); margin-top: 2px; }
.page-actions { display: flex; gap: 10px; align-items: center; }

/* ─── Vue authentification (setup / login) centrée ─── */
.auth-wrap {
  height: 100%; display: flex; align-items: center; justify-content: center;
  background:
    radial-gradient(900px 500px at 50% -10%, rgba(88,166,255,0.10), transparent 70%),
    var(--bg);
}
.auth-card {
  width: 400px; max-width: 92vw;
  background: var(--bg-surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 34px 34px 30px;
  box-shadow: var(--shadow-lg);
  animation: modal-in 0.3s var(--ease-spring) both;
}
.auth-logo {
  text-align: center; margin-bottom: 6px;
  font-weight: 800; font-size: 22px; letter-spacing: 3px;
}
.auth-logo span { color: var(--accent); }
.auth-tag {
  text-align: center; font-family: var(--font-mono); font-size: 11px;
  letter-spacing: 2px; color: var(--text-muted); text-transform: uppercase;
  margin-bottom: 26px;
}
.auth-title { font-size: 16px; font-weight: 700; margin-bottom: 6px; }
.auth-desc { font-size: 13px; color: var(--text-muted); line-height: 1.6; margin-bottom: 22px; }
.auth-field { margin-bottom: 16px; }
.auth-foot { margin-top: 18px; font-size: 12px; color: var(--text-dim); text-align: center; }

/* ─── Footer global de l'application ─── */
.app-footer {
  border-top: 1px solid var(--border);
  padding: 16px 28px;
  display: flex; align-items: center; gap: 18px; flex-wrap: wrap;
  font-size: 12px; color: var(--text-dim); margin-top: auto;
}
.app-footer a { color: var(--text-muted); cursor: pointer; }
.app-footer a:hover { color: var(--text); text-decoration: underline; }
.app-footer .footer-copy { margin-left: auto; }
@media (max-width: 640px) {
  .app-footer { flex-direction: column; align-items: flex-start; gap: 8px; }
  .app-footer .footer-copy { margin-left: 0; }
}

/* ─── Brackets HUD (coins de panneaux) — réutilisable par les écrans ─── */
.hud { position: relative; }
.hud .bk { position: absolute; width: 13px; height: 13px; pointer-events: none; opacity: 0.55; z-index: 1; }
.hud .bk.tl { top: 9px; left: 9px; border-top: 1.5px solid var(--accent); border-left: 1.5px solid var(--accent); }
.hud .bk.br { bottom: 9px; right: 9px; border-bottom: 1.5px solid var(--accent2); border-right: 1.5px solid var(--accent2); }

/* ─── Responsive : sous 760px, la sidebar fixe (236px) deviendrait envahissante ─── */
/* → elle passe en barre de navigation horizontale scrollable, le contenu prend toute */
/*   la largeur (audit UI-1 : shell non responsive < ~760px). */
@media (max-width: 760px) {
  .shell { flex-direction: column; }
  .sidebar {
    width: 100%; flex-direction: row; align-items: center; gap: 4px;
    overflow-x: auto; padding: 8px 10px;
    border-right: none; border-bottom: 1px solid var(--border);
  }
  .nav-group { display: flex; align-items: center; gap: 4px; margin-bottom: 0; }
  .nav-group-title, .nav-spacer, .nav-foot { display: none; }
  .nav-item { width: auto; white-space: nowrap; margin-bottom: 0; }
  .main { padding: 16px; }
  .page-title { font-size: 18px; }
}
