/* TrustRadar — Design System
   Palette : fond charbon très sombre, accent vert émeraude + ambre secondaire
   Même famille que PhishRadar/TrustRadar/VulnRadar mais identité visuelle propre.
*/

:root {
  --bg-primary:    #08090c;
  --bg-secondary:  #0d0f14;
  --bg-card:       #12141a;
  --bg-card-hover: #181b24;
  --border:        rgba(99,120,170,.18);
  --border-hover:  rgba(99,120,170,.35);

  /* Accent principal : vert émeraude */
  --accent:        #10b981;
  --accent-hover:  #34d399;
  --accent-dim:    rgba(16,185,129,.15);
  --accent-deep:   #064e3b;

  /* Accent secondaire : ambre (hérité PhishRadar, utilisé pour alertes/score) */
  --amber:         #f59e0b;
  --amber-dim:     rgba(245,158,11,.15);

  /* Status */
  --danger:        #ef4444;
  --danger-dim:    rgba(239,68,68,.12);
  --success:       #22c55e;
  --success-dim:   rgba(34,197,94,.12);
  --warning:       #f59e0b;
  --warning-dim:   rgba(245,158,11,.12);

  --text-primary:   #eef0f5;
  --text-secondary: #8b95aa;
  --text-muted:     #4a5268;

  --font-sans:    'Inter', system-ui, sans-serif;
  --font-heading: 'Bebas Neue', 'Syne', 'Inter', sans-serif;
  --font-mono:    'DM Mono', 'Consolas', monospace;
  --shadow: 0 4px 24px rgba(0,0,0,.45);
  --radius: 12px;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }

body {
  font-family: var(--font-sans);
  background: var(--bg-primary);
  color: var(--text-primary);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

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

/* ── Navbar ─────────────────────────────────────────────────────────────── */
.navbar {
  position: sticky; top: 0; z-index: 100;
  height: 60px;
  background: rgba(8,9,12,.92); backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
}
.navbar .container {
  display: flex; align-items: center; justify-content: space-between; height: 100%;
  max-width: 1400px;
}

.navbar-brand {
  display: flex; align-items: center; gap: 10px;
  font-size: 1.15rem; font-weight: 700; color: var(--text-primary);
  font-family: var(--font-heading);
  letter-spacing: .06em;
}

.navbar-brand svg { color: var(--accent); }
.navbar-brand .brand-word { color: var(--text-primary); transition: color .15s; }
.navbar-brand .accent-word { color: var(--accent); }
.navbar-brand:hover .brand-word { color: #059669; }

.navbar-links { display: flex; align-items: center; gap: 1.5rem; }
.navbar-links a { color: var(--text-secondary); font-size: 14px; font-weight: 500; transition: color .15s; }
.navbar-links a:hover, .navbar-links a.active { color: var(--text-primary); }

.lang-switcher {
  background: none; border: 1px solid var(--border); color: var(--text-secondary);
  border-radius: 6px; padding: 3px 8px; font-size: 12px; cursor: pointer;
  transition: border-color .15s, color .15s;
}
.lang-switcher:hover { border-color: var(--accent); color: var(--accent); }

/* ── Buttons ────────────────────────────────────────────────────────────── */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  padding: 10px 20px; border-radius: 8px; border: none;
  font-size: 14px; font-weight: 600; cursor: pointer;
  transition: background .15s, transform .1s, box-shadow .15s;
}
.btn:active { transform: scale(.98); }
.btn:disabled { opacity: .5; cursor: not-allowed; }

.btn-primary {
  background: var(--accent); color: #fff;
}
.btn-primary:hover:not(:disabled) { background: var(--accent-hover); box-shadow: 0 0 16px rgba(16,185,129,.35); }

.btn-outline {
  background: transparent; color: var(--accent); border: 1px solid var(--accent);
}
.btn-outline:hover:not(:disabled) { background: var(--accent-dim); }

.btn-danger {
  background: var(--danger-dim); color: var(--danger); border: 1px solid rgba(239,68,68,.3);
}
.btn-danger:hover:not(:disabled) { background: rgba(239,68,68,.22); }

.btn-sm { padding: 6px 12px; font-size: 13px; }
.btn-ghost { background: none; border: none; color: var(--text-secondary); cursor: pointer; }
.btn-ghost:hover { color: var(--text-primary); }

/* ── Cards ──────────────────────────────────────────────────────────────── */
.card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.5rem;
}
.card:hover { border-color: var(--border-hover); }

/* ── Hero section ───────────────────────────────────────────────────────── */
.hero {
  padding: 80px 0 60px;
  text-align: center;
  background: radial-gradient(ellipse 80% 50% at 50% -10%, rgba(16,185,129,.12) 0%, transparent 70%);
}

.hero-badge {
  display: inline-flex; align-items: center; gap: 6px;
  background: var(--accent-dim); border: 1px solid rgba(16,185,129,.3);
  color: var(--accent); font-size: 12px; font-weight: 600;
  padding: 4px 12px; border-radius: 99px; margin-bottom: 1.5rem;
  text-transform: uppercase; letter-spacing: .05em;
}

.hero h1 {
  font-family: var(--font-heading);
  font-size: clamp(2rem, 5vw, 3.2rem);
  font-weight: 800; line-height: 1.15;
  letter-spacing: -.02em; margin-bottom: 1rem;
  background: linear-gradient(135deg, var(--text-primary) 60%, var(--accent));
  -webkit-background-clip: text; -webkit-text-fill-color: transparent;
}

.hero p {
  font-size: 1.1rem; color: var(--text-secondary);
  max-width: 580px; margin: 0 auto 2rem;
}

.hero-ctas { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; }
.hero-split .hero-ctas { justify-content: flex-start; margin-left: 20px; }

/* Radar animation */
.radar-wrap {
  position: relative; width: 200px; height: 200px;
  margin: 3rem auto 0;
}
.radar-ring {
  position: absolute; border-radius: 50%;
  border: 1px solid rgba(16,185,129,.25);
  top: 50%; left: 50%; transform: translate(-50%,-50%);
}
.radar-ring:nth-child(1) { width: 60px; height: 60px; }
.radar-ring:nth-child(2) { width: 110px; height: 110px; }
.radar-ring:nth-child(3) { width: 160px; height: 160px; }
.radar-ring:nth-child(4) { width: 200px; height: 200px; border-color: rgba(16,185,129,.12); }
.radar-sweep {
  position: absolute; width: 100px; height: 2px;
  background: linear-gradient(90deg, transparent, var(--accent));
  top: 50%; left: 50%; transform-origin: left center;
  animation: sweep 3s linear infinite;
  border-radius: 2px;
}
@keyframes sweep { from { transform: rotate(0deg); } to { transform: rotate(360deg); } }
.radar-dot {
  position: absolute; width: 6px; height: 6px;
  background: var(--amber); border-radius: 50%;
  box-shadow: 0 0 8px var(--amber);
  animation: blink 1.5s ease-in-out infinite;
}
.radar-dot:nth-child(5) { top: 28%; left: 62%; animation-delay: .3s; }
.radar-dot:nth-child(6) { top: 55%; left: 75%; animation-delay: .9s; }
.radar-dot:nth-child(7) { top: 70%; left: 35%; animation-delay: 1.5s; }
@keyframes blink { 0%,100% { opacity: .3; } 50% { opacity: 1; } }

/* ── Features grid ──────────────────────────────────────────────────────── */
.features-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 1.25rem;
}

.feature-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.5rem;
  transition: border-color .2s, transform .2s;
}
.feature-card:hover { border-color: var(--accent); transform: translateY(-2px); }

.feature-icon {
  width: 40px; height: 40px; border-radius: 10px;
  background: var(--accent-dim); border: 1px solid rgba(16,185,129,.25);
  display: flex; align-items: center; justify-content: center;
  color: var(--accent); margin-bottom: 1rem;
}

.feature-card h3 { font-size: 15px; font-weight: 600; margin-bottom: .5rem; }
.feature-card p { font-size: 13.5px; color: var(--text-secondary); line-height: 1.65; }

/* ── Pricing ────────────────────────────────────────────────────────────── */
.pricing-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1.5rem; max-width: 860px; margin: 0 auto;
}

@media (max-width: 640px) {
  .pricing-grid { grid-template-columns: 1fr; }
}

.pricing-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 2rem;
  display: flex; flex-direction: column;
}
.pricing-card.featured {
  border-color: var(--accent);
  background: linear-gradient(160deg, var(--bg-card) 70%, rgba(16,185,129,.08));
  box-shadow: 0 0 40px rgba(16,185,129,.15);
}

.pricing-badge {
  display: inline-block; font-size: 11px; font-weight: 700;
  background: var(--accent); color: #fff;
  padding: 2px 10px; border-radius: 99px; margin-bottom: .75rem;
  text-transform: uppercase; letter-spacing: .05em; align-self: flex-start;
}

.pricing-name { font-size: 1rem; font-weight: 600; color: var(--text-secondary); margin-bottom: .5rem; }
.pricing-price {
  display: flex; align-items: flex-start; gap: 2px;
  line-height: 1; margin-bottom: .25rem;
}
.pricing-price .price-currency {
  font-size: 1.2rem; font-weight: 700; color: var(--text-secondary); padding-top: 5px;
}
.pricing-price .price-amount {
  font-size: 2.8rem; font-weight: 800; color: var(--text-primary); line-height: 1;
}
.pricing-price .price-custom {
  font-size: 1.5rem; font-weight: 700; color: var(--text-primary); line-height: 1; align-self: center;
}
.pricing-period { font-size: 13px; color: var(--text-muted); margin-bottom: 1.5rem; }

.pricing-features { list-style: none; flex: 1; margin-bottom: 1.5rem; }
.pricing-features li {
  display: flex; align-items: flex-start; gap: 8px;
  font-size: 13.5px; padding: .5rem 0;
}
.pricing-features .check { color: var(--success); flex-shrink: 0; margin-top: 2px; }

/* ── Dashboard ──────────────────────────────────────────────────────────── */
/* Brand selector bar (replaces sidebar) */
.brand-bar {
  display: flex; align-items: center; justify-content: space-between;
  gap: .75rem; margin-bottom: 1rem; flex-wrap: wrap;
  background: var(--bg-card); border: 1px solid var(--border);
  border-radius: 10px; padding: .6rem .9rem;
}

/* Legacy — kept for reference, no longer used for layout */
.dashboard-layout {
  padding: 1.5rem; max-width: 1400px; margin: 0 auto;
}
.sidebar { display: none; }

.brand-item {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 1rem;
  cursor: pointer;
  transition: border-color .15s, background .15s;
}
.brand-item:hover, .brand-item.active {
  border-color: var(--accent);
  background: var(--bg-card-hover);
}
.brand-item.active { border-left: 3px solid var(--accent); }

.brand-item-name { font-size: 14px; font-weight: 600; margin-bottom: 4px; }
.brand-item-meta { font-size: 12px; color: var(--text-muted); }
.brand-item-badge {
  display: inline-block; font-size: 11px; font-weight: 700;
  background: var(--danger-dim); color: var(--danger);
  padding: 1px 7px; border-radius: 99px; margin-left: 6px;
}

.main-panel { display: flex; flex-direction: column; gap: 1rem; }

/* Stats bar */
.stats-bar {
  display: grid; grid-template-columns: repeat(4, 1fr); gap: 1rem;
}
/* Barre à 5 indicateurs (vue d'ensemble) — cadres compacts pour tenir sur une ligne */
.stats-bar--five { grid-template-columns: repeat(5, 1fr); gap: .625rem; }
.stats-bar--five .stat-card { padding: .7rem .5rem; }
.stats-bar--five .stat-number { font-size: 1.4rem; }
.stats-bar--five .stat-label { font-size: 11px; }
.stats-bar--six { grid-template-columns: repeat(6, 1fr); gap: .625rem; }
.stats-bar--six .stat-card { padding: .7rem .5rem; }
.stats-bar--six .stat-number { font-size: 1.35rem; }
.stats-bar--six .stat-label { font-size: 11px; }
.stats-bar--four { grid-template-columns: repeat(4, 1fr); gap: .625rem; }
.stats-bar--four .stat-card { padding: .7rem .5rem; }
.stats-bar--four .stat-number { font-size: 1.35rem; }
.stats-bar--four .stat-label { font-size: 11px; }
.stats-bar--three { grid-template-columns: repeat(3, 1fr); gap: .625rem; }
.stats-bar--three .stat-card { padding: .7rem .5rem; }
.stats-bar--three .stat-number { font-size: 1.35rem; }
.stats-bar--three .stat-label { font-size: 11px; }
.stat-card {
  background: var(--bg-card); border: 1px solid var(--border);
  border-radius: 10px; padding: 1rem; text-align: center;
}
.stat-number { font-size: 1.75rem; font-weight: 700; line-height: 1; }
.stat-label { font-size: 12px; color: var(--text-muted); margin-top: 4px; }

/* Domains table */
.domains-table-wrap { overflow-x: auto; max-width: 100%; }
.domains-table {
  width: 100%; border-collapse: collapse; font-size: 13px;
  table-layout: fixed;
}
.domains-table th {
  text-align: left; padding: .6rem .75rem;
  color: var(--text-muted); font-weight: 500; font-size: 11.5px;
  border-bottom: 1px solid var(--border);
  white-space: nowrap; user-select: none;
}
.domains-table th.sortable { cursor: pointer; }
.domains-table th.sortable:hover { color: var(--text-primary); }
.domains-table th.sort-asc::after  { content: ' ↑'; color: var(--accent); }
.domains-table th.sort-desc::after { content: ' ↓'; color: var(--accent); }
/* Compact column widths (no overflow) */
.domains-table .col-risk_score   { width: 64px; }
.domains-table .col-score        { width: 64px; }
.domains-table .col-domain       { min-width: 160px; }
.domains-table .col-first_seen   { width: 120px; }
.domains-table .col-date         { width: 120px; }
.domains-table .col-discovery_source { width: 90px; }
.domains-table .col-source       { width: 90px; }
.domains-table .col-status       { width: 100px; }
.domains-table .col-toggle       { width: 44px; text-align: center; }
.domains-table td {
  padding: .6rem .75rem;
  border-bottom: 1px solid rgba(255,255,255,.04);
  vertical-align: middle; overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.domains-table tr.domain-row { cursor: pointer; }
.domains-table tr.domain-row:hover td { background: var(--bg-card-hover); }
.domains-table tr.detail-row td {
  padding: 0; background: var(--bg-secondary);
  border-bottom: 2px solid var(--border);
}

.risk-badge {
  display: inline-flex; align-items: center; align-self: stretch;
  font-size: 13px; font-weight: 700;
  padding: 4px 10px; border-radius: 6px; font-family: var(--font-mono);
}
.risk-critical { background: rgba(239,68,68,.15); color: #f87171; }
.risk-high     { background: rgba(245,158,11,.15); color: #fbbf24; }
.risk-medium   { background: rgba(234,179,8,.12); color: #facc15; }
.risk-low      { background: rgba(34,197,94,.12); color: #4ade80; }

.status-pill {
  display: inline-flex; align-items: center; align-self: stretch;
  font-size: 12px; font-weight: 600;
  padding: 4px 12px; border-radius: 99px;
}
.status-new          { background: var(--accent-dim); color: var(--accent); }
.status-confirmed    { background: var(--warning-dim); color: var(--warning); }
.status-dismissed    { background: rgba(255,255,255,.06); color: var(--text-muted); }
.status-takedown_sent { background: rgba(168,85,247,.15); color: #c084fc; }
.status-taken_down   { background: var(--success-dim); color: var(--success); }

.role-pill {
  display: inline-flex; align-items: center;
  font-size: 11px; font-weight: 600;
  padding: 3px 10px; border-radius: 99px;
  text-transform: uppercase; letter-spacing: .03em;
}
.role-owner   { background: var(--accent-dim); color: var(--accent); }
.role-analyst { background: rgba(34,197,94,.12); color: var(--success); }
.user-row-analyst { background: rgba(255,255,255,.015); }

.source-badge {
  display: inline-flex; align-items: center; align-self: stretch;
  font-size: 12px; font-weight: 600; font-family: var(--font-mono);
  background: rgba(255,255,255,.06); color: var(--text-secondary);
  padding: 4px 10px; border-radius: 4px;
}
.source-ct_log { background: rgba(16,185,129,.12); color: var(--accent); }

.mx-badge {
  font-size: 11px; font-weight: 700;
  padding: 1px 6px; border-radius: 4px;
}
.mx-yes { background: var(--danger-dim); color: var(--danger); }
.mx-no  { color: var(--text-muted); }

/* ── Modal ──────────────────────────────────────────────────────────────── */
.modal-overlay {
  position: fixed; inset: 0; z-index: 200;
  background: rgba(0,0,0,.7); backdrop-filter: blur(4px);
  display: flex; align-items: center; justify-content: center;
  padding: 1rem;
}
.modal-overlay.hidden { display: none; }

.modal-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 2rem;
  max-width: 540px; width: 100%;
  max-height: 88vh; overflow-y: auto;
  box-shadow: var(--shadow);
  position: relative;
}

.modal-close {
  position: absolute; top: 1rem; right: 1rem;
  background: none; border: none; color: var(--text-muted);
  font-size: 18px; cursor: pointer; line-height: 1; padding: 4px;
  border-radius: 4px;
}
.modal-close:hover { color: var(--text-primary); }

.modal-title { font-size: 1.1rem; font-weight: 700; margin-bottom: 1.5rem; }

/* ── Forms ──────────────────────────────────────────────────────────────── */
.form-group { margin-bottom: 1rem; }
.form-label { display: block; font-size: 13px; font-weight: 600; color: var(--text-secondary); margin-bottom: 6px; }
.form-control {
  width: 100%; padding: 10px 14px;
  background: var(--bg-secondary); border: 1px solid var(--border);
  border-radius: 8px; color: var(--text-primary); font-size: 14px;
  transition: border-color .15s;
  font-family: var(--font-sans);
}
.form-control:focus { outline: none; border-color: var(--accent); }
.form-control::placeholder { color: var(--text-muted); }
textarea.form-control { resize: vertical; min-height: 80px; }

select.form-control { cursor: pointer; }

/* ── Login page ─────────────────────────────────────────────────────────── */
.login-wrap {
  min-height: 100vh;
  display: flex; align-items: center; justify-content: center;
  background: radial-gradient(ellipse 60% 40% at 50% 20%, rgba(16,185,129,.08) 0%, transparent 70%);
}
.login-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 16px; padding: 2.5rem;
  width: 100%; max-width: 420px;
  box-shadow: var(--shadow);
}
.login-logo {
  display: flex; align-items: center; justify-content: center; gap: 10px;
  margin-bottom: 2rem; font-size: 1.2rem; font-weight: 700;
}
.login-logo svg { color: var(--accent); }
.login-error {
  background: var(--danger-dim); border: 1px solid rgba(239,68,68,.25);
  color: var(--danger); border-radius: 8px; padding: 10px 14px;
  font-size: 13px; margin-bottom: 1rem; display: none;
}
.login-toggle { text-align: center; font-size: 13px; color: var(--text-muted); margin-top: 1.5rem; }

/* ── Section helpers ────────────────────────────────────────────────────── */
.section { padding: 64px 0; }
.stats-band + .section { padding-top: 32px; }
.section-alt { background: var(--bg-secondary); }
.container { max-width: 1200px; margin: 0 auto; padding: 0 1.5rem; }
.section-title {
  font-size: clamp(1.5rem, 3vw, 2rem); font-weight: 800;
  letter-spacing: -.02em; margin-bottom: .5rem;
}
.section-subtitle { color: var(--text-secondary); font-size: 1rem; margin-bottom: 2.5rem; }
.text-center { text-align: center; }

/* ── Alerts / Toast ─────────────────────────────────────────────────────── */
.toast {
  /* bottom relevé + z-index au-dessus du widget chatbot (z-index 9998) pour ne pas être masqué par la pastille */
  position: fixed; bottom: 6rem; right: 1.5rem; z-index: 9999;
  background: var(--bg-card); border: 1px solid var(--border);
  border-radius: 10px; padding: .875rem 1.25rem;
  font-size: 13.5px; box-shadow: var(--shadow);
  opacity: 0; transform: translateY(calc(100% + 32px));
  transition: transform .3s ease, opacity .3s ease;
  max-width: 340px; pointer-events: none;
}
.toast.show { transform: translateY(0); opacity: 1; pointer-events: auto; }
.toast.success { border-color: rgba(34,197,94,.4); }
.toast.error   { border-color: rgba(239,68,68,.4); }

/* ── Loader ─────────────────────────────────────────────────────────────── */
.spinner {
  width: 20px; height: 20px; border-radius: 50%;
  border: 2px solid rgba(255,255,255,.1);
  border-top-color: var(--accent);
  animation: spin .7s linear infinite;
  display: inline-block;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* ── Empty state ────────────────────────────────────────────────────────── */
.empty-state {
  text-align: center; padding: 3rem 1rem;
  color: var(--text-muted); font-size: 14px;
}
.empty-state svg { margin-bottom: 1rem; opacity: .4; }

/* ── Responsive ─────────────────────────────────────────────────────────── */
@media (max-width: 768px) {
  .dashboard-layout { grid-template-columns: 1fr; }
  .stats-bar, .stats-bar--five, .stats-bar--six, .stats-bar--four { grid-template-columns: repeat(2, 1fr); }
  .stats-bar--three { grid-template-columns: repeat(3, 1fr); }
  .navbar-links { gap: .75rem; }
  .hero h1 { font-size: 1.75rem; }
}

/* ── Scrollbar ──────────────────────────────────────────────────────────── */
::-webkit-scrollbar { width: 6px; height: 6px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: rgba(255,255,255,.1); border-radius: 3px; }

/* ── Feature cards 3D ───────────────────────────────────────────────────── */
.features-grid {
  perspective: 1200px;
}
.feature-card {
  transform-style: preserve-3d;
  transition: transform .25s ease, border-color .2s, box-shadow .25s;
  will-change: transform;
}
.feature-card:hover {
  border-color: rgba(16,185,129,.55);
  box-shadow: 0 12px 40px rgba(0,0,0,.4), 0 0 0 1px rgba(16,185,129,.15);
  transform: translateY(-4px);
}
.feature-card.tilt {
  transition: none;
}

/* ── Radar amélioré (SVG, trainée dégradée façon PhishRadar) ───────────── */
.radar-wrap {
  position: relative; width: 320px; height: 320px;
  margin: 3.5rem auto 0;
}
.radar-svg { width: 100%; height: 100%; display: block; overflow: visible; }
.radar-sweep {
  transform-origin: 200px 200px;
  animation: radar-sweep-rotate 4s linear infinite;
}
@keyframes radar-sweep-rotate {
  from { transform: rotate(0deg); }
  to   { transform: rotate(360deg); }
}
.radar-ping { animation: radar-ping-pulse 4s ease-out infinite; }
.radar-ping-2 { animation-delay: 1.4s; }
.radar-ping-3 { animation-delay: 2.7s; }
@keyframes radar-ping-pulse {
  0%,70% { opacity: 0; r: 2; }
  75%    { opacity: 1; r: 4; }
  85%    { opacity: .8; r: 6; }
  100%   { opacity: 0; r: 8; }
}

/* ── Stats cards index (effet 3D) ───────────────────────────────────────── */
.stats-index-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 1.25rem;
  margin-top: 2rem;
}
.stat-index-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.75rem 1.5rem;
  text-align: center;
  position: relative; overflow: hidden;
  transition: border-color .2s, box-shadow .25s, transform .25s;
  transform-style: preserve-3d;
  will-change: transform;
}
.stat-index-card::before {
  content: ''; position: absolute; inset: 0;
  background: radial-gradient(ellipse 80% 60% at 50% -10%, rgba(16,185,129,.1), transparent);
  opacity: 0; transition: opacity .25s;
}
.stat-index-card:hover { border-color: rgba(16,185,129,.4); box-shadow: 0 8px 32px rgba(0,0,0,.35); transform: translateY(-3px); }
.stat-index-card:hover::before { opacity: 1; }
.stat-index-number { font-size: 2.4rem; font-weight: 800; color: var(--accent); line-height: 1; }
.stat-index-label { font-size: 13px; color: var(--text-secondary); margin-top: .5rem; }
::-webkit-scrollbar-thumb:hover { background: rgba(255,255,255,.2); }

/* ── Constellation background ──────────────────────────────────────────── */
#constellation-canvas {
  position: fixed; inset: 0; z-index: 0;
  pointer-events: none; width: 100%; height: 100%;
}
/* All content sits above the constellation canvas */
.navbar, .dashboard-layout, .hero, .hero-split, .section, .section-alt,
.stats-band, .login-wrap, footer { position: relative; z-index: 1; }

/* ── Dashboard tabs ─────────────────────────────────────────────────────── */
.dash-tab-bar { display: flex; gap: 0; border-bottom: 1px solid var(--border); margin-bottom: 1rem; }
.dash-tab { background: none; border: none; border-bottom: 2px solid transparent; margin-bottom: -1px; color: var(--text-muted); font-size: 13px; font-weight: 500; padding: .6rem 1.25rem .75rem; cursor: pointer; transition: color .15s, border-color .15s; }
.dash-tab:hover { color: var(--text-primary); }
.dash-tab.active { color: var(--accent); border-bottom-color: var(--accent); font-weight: 600; }

/* ── Notification settings modal tabs ──────────────────────────────────── */
.modal-tab-bar { display: flex; flex-wrap: wrap; gap: 0; border-bottom: 1px solid var(--border); margin: -.25rem 0 1.25rem; }
.modal-tab { background: none; border: none; border-bottom: 2px solid transparent; margin-bottom: -1px; color: var(--text-muted); font-size: 13px; font-weight: 500; padding: .5rem .85rem .65rem; cursor: pointer; transition: color .15s, border-color .15s; white-space: nowrap; }
.modal-tab:hover { color: var(--text-primary); }
.modal-tab.active { color: var(--accent); border-bottom-color: var(--accent); font-weight: 600; }

/* ── Legal page ─────────────────────────────────────────────────────────── */
.legal-tab {
  background: none; border: none; border-bottom: 2px solid transparent;
  color: var(--text-muted); font-size: 13px; font-weight: 500;
  padding: .5rem 1rem .75rem; cursor: pointer; transition: color .15s, border-color .15s;
}
.legal-tab:hover { color: var(--text-primary); }
.legal-tab.active { color: var(--accent); border-bottom-color: var(--accent); }
.legal-content h2 { font-size: 1.2rem; font-weight: 700; margin-bottom: .25rem; }
.legal-content h3 { font-size: .95rem; font-weight: 600; margin: 1.5rem 0 .5rem; color: var(--text-secondary); }
.legal-content p, .legal-content li { font-size: 14px; color: var(--text-secondary); line-height: 1.75; }
.legal-content ul { padding-left: 1.25rem; margin-bottom: .75rem; }
.legal-date { font-size: 12px; color: var(--text-muted); margin-bottom: 1.5rem; }
.legal-table { width: 100%; border-collapse: collapse; margin: .75rem 0 1rem; font-size: 13px; }
.legal-table th { text-align: left; padding: .5rem .75rem; background: var(--bg-secondary); color: var(--text-muted); font-weight: 500; }
.legal-table td { padding: .5rem .75rem; border-bottom: 1px solid var(--border); color: var(--text-secondary); }

/* ── Tickets page ───────────────────────────────────────────────────────── */
.ticket-list { display: flex; flex-direction: column; gap: .75rem; }
.ticket-item {
  background: var(--bg-card); border: 1px solid var(--border);
  border-radius: 10px; padding: 1rem; cursor: pointer;
  transition: border-color .15s, background .15s;
}
.ticket-item:hover { border-color: var(--accent); background: var(--bg-card-hover); }
.ticket-item-header { display: flex; justify-content: space-between; align-items: flex-start; gap: .5rem; margin-bottom: .25rem; }
.ticket-ref { font-size: 11px; color: var(--text-muted); font-family: var(--font-mono); }
.ticket-subject { font-size: 14px; font-weight: 600; }
.ticket-meta { font-size: 11.5px; color: var(--text-muted); }
.ticket-message {
  background: var(--bg-card); border: 1px solid var(--border);
  border-radius: 8px; padding: .75rem 1rem; font-size: 13.5px;
  line-height: 1.6; color: var(--text-secondary); white-space: pre-wrap;
}
.ticket-message.from-admin { border-left: 3px solid var(--accent); background: var(--accent-dim); }
.ticket-message.from-user  { border-left: 3px solid var(--border-hover); }
.priority-low      { color: var(--success); }
.priority-medium   { color: var(--warning); }
.priority-high, .priority-critical { color: var(--danger); }

/* Impression du devis Enterprise (admin) — n'imprimer que l'aperçu */
@media print {
  body.printing-devis * { visibility: hidden; }
  body.printing-devis #dv-preview, body.printing-devis #dv-preview * { visibility: visible; }
  body.printing-devis #dv-preview {
    position: absolute; left: 0; top: 0; width: 100%;
    border: none; box-shadow: none; background: #fff; color: #111;
  }
}
@media (max-width: 720px) { .devis-cols { grid-template-columns: 1fr !important; } }

/* ── Index page redesign ────────────────────────────────────────────────── */

.hero-split {
  padding: 60px 0 20px;
  background: radial-gradient(ellipse 90% 60% at 70% -5%, rgba(16,185,129,.10) 0%, transparent 65%);
}
.hero-split .container {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3rem;
  align-items: center;
}
.hero-left { padding-right: 1rem; min-width: 0; align-self: flex-start; margin-top: -10px; }
.hero-claim {
  font-family: var(--font-heading);
  font-size: clamp(2rem, 4.5vw, 3.5rem);
  font-weight: 800;
  line-height: 1.1;
  letter-spacing: -.02em;
  margin-bottom: 1.25rem;
}
.hero-claim .line1 { color: var(--text-secondary); display: block; }
.hero-claim .line2 {
  background: linear-gradient(125deg, var(--text-primary) 40%, var(--accent));
  -webkit-background-clip: text; -webkit-text-fill-color: transparent;
  display: block;
}
.hero-sub-new {
  font-size: .95rem;
  color: var(--text-secondary);
  line-height: 1.75;
  margin-bottom: 2rem;
  max-width: 480px;
}
.hero-right-col {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-end;
  gap: 1.25rem;
  min-width: 0;
  max-width: 100%;
  min-height: 360px;
}
.hero-right-col .radar-wrap {
  position: absolute;
  top: 46%; left: 50%;
  transform: translate(-50%, -50%);
  width: 512px; height: 512px;
  margin: 0;
  z-index: 0;
  pointer-events: none;
}

/* Threat ticker */
.threat-ticker-wrap {
  position: relative;
  z-index: 1;
  width: 100%;
  min-width: 0;
  max-width: 100%;
  display: flex;
  align-items: center;
  gap: 10px;
  overflow: hidden;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 8px 12px;
  margin-bottom: 70px;
  transition: box-shadow .25s, border-color .25s;
}
.threat-ticker-wrap:hover {
  border-color: rgba(16,185,129,.35);
  box-shadow: 0 0 26px rgba(16,185,129,.16);
}
.ticker-live-badge {
  flex-shrink: 0;
  background: var(--danger);
  color: #fff;
  font-size: 9px;
  font-weight: 700;
  letter-spacing: .08em;
  text-transform: uppercase;
  padding: 2px 6px;
  border-radius: 4px;
}
.ticker-track {
  flex: 1;
  overflow: hidden;
  min-width: 0;
}
.ticker-inner {
  display: inline-flex;
  white-space: nowrap;
  gap: 2.5rem;
  animation: tickerScroll 38s linear infinite;
  font-size: 12px;
  color: var(--text-secondary);
  font-family: var(--font-mono);
}
.ticker-item-domain { color: var(--accent); font-weight: 500; }
.ticker-item-tag { color: var(--amber); }
.ticker-sep { color: var(--text-muted); opacity: .6; }
@keyframes tickerScroll {
  from { transform: translateX(0); }
  to   { transform: translateX(-50%); }
}

/* Stats band */
.stats-band {
  position: relative;
  overflow: hidden;
  background: var(--bg-secondary);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  padding: 2.5rem 0;
}
.stats-band::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(260px circle at var(--mx, 50%) var(--my, 50%), rgba(16,185,129,.08), transparent 70%);
  opacity: 0;
  transition: opacity .3s;
  pointer-events: none;
}
.stats-band:hover::before { opacity: .7; }
.stats-band .container { position: relative; z-index: 1; }
.stats-band-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1rem;
  text-align: center;
}
.stat-band-num {
  font-family: var(--font-heading);
  font-size: 2.5rem;
  font-weight: 800;
  color: var(--accent);
  letter-spacing: -.02em;
  line-height: 1;
}
.stat-band-label {
  font-size: 12px;
  color: var(--text-muted);
  margin-top: 5px;
  text-transform: uppercase;
  letter-spacing: .06em;
}

/* Feature groups */
.feat-groups {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
}
.feat-group {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.5rem;
  transition: border-color .2s, transform .2s;
}
.feat-group:hover { border-color: var(--border-hover); transform: translateY(-2px); }
.feat-group:has(.feat-group-label.det):hover {
  border-color: rgba(16,185,129,.45);
  box-shadow: 0 10px 32px rgba(16,185,129,.14);
}
.feat-group:has(.feat-group-label.intel):hover {
  border-color: rgba(245,158,11,.45);
  box-shadow: 0 10px 32px rgba(245,158,11,.14);
}
.feat-group:has(.feat-group-label.resp):hover {
  border-color: rgba(34,197,94,.45);
  box-shadow: 0 10px 32px rgba(34,197,94,.14);
}
.feat-group:has(.feat-group-label.det):hover .feat-group-label.det     { box-shadow: 0 0 16px rgba(16,185,129,.45); }
.feat-group:has(.feat-group-label.intel):hover .feat-group-label.intel { box-shadow: 0 0 16px rgba(245,158,11,.45); }
.feat-group:has(.feat-group-label.resp):hover .feat-group-label.resp   { box-shadow: 0 0 16px rgba(34,197,94,.45); }
.feat-group-label {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: .12em;
  text-transform: uppercase;
  padding: 3px 10px;
  border-radius: 4px;
  margin-bottom: 1.25rem;
}
.feat-group-label.det   { background: rgba(16,185,129,.15);  color: var(--accent);  border: 1px solid rgba(16,185,129,.3); }
.feat-group-label.intel { background: rgba(245,158,11,.12);  color: var(--amber);   border: 1px solid rgba(245,158,11,.3); }
.feat-group-label.resp  { background: rgba(34,197,94,.12);   color: var(--success); border: 1px solid rgba(34,197,94,.3); }
.feat-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: .55rem;
}
.feat-item {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  font-size: 13px;
  color: var(--text-secondary);
  line-height: 1.5;
}
.feat-item-dot {
  width: 5px; height: 5px;
  border-radius: 50%;
  flex-shrink: 0;
  margin-top: 6px;
}
.feat-item-dot.det   { background: var(--accent); }
.feat-item-dot.intel { background: var(--amber); }
.feat-item-dot.resp  { background: var(--success); }

/* How it works */
.how-steps {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2.5rem;
  text-align: center;
}
.step-num {
  font-family: var(--font-heading);
  font-size: 3.5rem;
  color: var(--accent);
  opacity: .22;
  line-height: 1;
  margin-bottom: .75rem;
}
.step-title {
  font-size: 1rem;
  font-weight: 700;
  margin-bottom: .5rem;
}
.step-text {
  font-size: 13px;
  color: var(--text-secondary);
  line-height: 1.7;
}

/* CTA card */
.cta-index-card {
  background: linear-gradient(140deg, var(--bg-card) 55%, rgba(16,185,129,.09));
  border: 1px solid rgba(16,185,129,.22);
  border-radius: var(--radius);
  padding: 3.5rem 2rem;
  text-align: center;
}
.cta-index-card h2 {
  font-family: var(--font-heading);
  font-size: clamp(1.6rem, 3vw, 2.4rem);
  font-weight: 800;
  letter-spacing: -.01em;
  margin-bottom: .75rem;
}
.cta-index-card p {
  color: var(--text-secondary);
  font-size: .95rem;
  margin-bottom: 2rem;
}

/* Responsive index */
@media (max-width: 900px) {
  .hero-split .container { grid-template-columns: 1fr; text-align: center; }
  .hero-left { padding-right: 0; }
  .hero-sub-new { margin-left: auto; margin-right: auto; }
  .hero-split .hero-ctas { justify-content: center; margin-left: 0; }
  .hero-right-col { display: none; }
  .feat-groups { grid-template-columns: 1fr; }
  .how-steps { grid-template-columns: 1fr; gap: 1.5rem; }
  .stats-band-grid { grid-template-columns: repeat(2, 1fr); }
}

/* ── TrustRadar Dashboard shell (bootstrap Phase 0) ──────────────────────── */
.dash-shell {
  display: grid; grid-template-columns: 232px 1fr;
  max-width: 1400px; margin: 0 auto; min-height: calc(100vh - 60px);
  position: relative; z-index: 1;
}
.dash-sidebar {
  border-right: 1px solid var(--border);
  padding: 1.5rem .75rem; background: rgba(13,15,20,.4);
}
.dash-sidebar nav { display: flex; flex-direction: column; gap: 4px; position: sticky; top: 80px; }
.dash-nav-item {
  display: flex; align-items: center; gap: 10px;
  padding: 9px 12px; border-radius: 8px;
  color: var(--text-secondary); font-size: 14px; font-weight: 500;
  transition: background .15s, color .15s;
}
.dash-nav-item:hover { background: var(--bg-card-hover); color: var(--text-primary); }
.dash-nav-item.active { background: var(--accent-dim); color: var(--accent); }
.dash-nav-item svg { flex-shrink: 0; }

.dash-main { padding: 2rem 2rem 3rem; min-width: 0; }
.dash-section-head h1 {
  font-family: var(--font-heading); font-size: 1.8rem; letter-spacing: .01em;
  margin-bottom: .35rem;
}
.dash-section-head p { color: var(--text-secondary); font-size: .95rem; margin-bottom: 1.75rem; }

/* Carte score + jauge */
.dash-score-card {
  display: flex; align-items: center; gap: 2rem; flex-wrap: wrap;
  background: linear-gradient(140deg, var(--bg-card) 55%, rgba(16,185,129,.09));
  border: 1px solid var(--border); border-radius: var(--radius);
  padding: 1.75rem 2rem; margin-bottom: 1.5rem;
}
.dash-gauge {
  --pct: 0; width: 128px; height: 128px; border-radius: 50%; flex-shrink: 0;
  background: conic-gradient(var(--accent) calc(var(--pct) * 1%), var(--bg-card-hover) 0);
  display: flex; align-items: center; justify-content: center;
}
.dash-gauge-inner {
  width: 100px; height: 100px; border-radius: 50%;
  background: var(--bg-card); display: flex; align-items: center; justify-content: center;
}
.dash-gauge-num { font-family: var(--font-heading); font-size: 2rem; color: var(--accent); }
.dash-gauge-num small { font-size: 1rem; opacity: .7; }
.dash-score-meta { flex: 1; min-width: 220px; }
.dash-score-title { font-size: 1.1rem; font-weight: 700; margin-bottom: 6px; }
.dash-score-status { display: inline-flex; align-items: center; gap: 6px; font-size: 13px; color: var(--accent); font-weight: 600; }
.dash-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--accent); box-shadow: 0 0 8px var(--accent); }
.dash-score-note { font-size: 12px; color: var(--text-muted); margin-top: 8px; }

.dash-stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); gap: 1rem; margin-bottom: 2rem; }
.dash-stat { background: var(--bg-card); border: 1px solid var(--border); border-radius: var(--radius); padding: 1.25rem 1.5rem; }
.dash-stat-num { font-family: var(--font-heading); font-size: 1.6rem; color: var(--text-primary); }
.dash-stat-lbl { font-size: 12px; color: var(--text-muted); margin-top: 4px; }

.dash-cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 1rem; }
.dash-card {
  text-align: left; background: var(--bg-card); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 1.25rem 1.5rem; cursor: pointer;
  transition: border-color .2s, transform .2s;
}
.dash-card:hover { border-color: var(--accent); transform: translateY(-2px); }
.dash-card-badge {
  display: inline-block; font-size: 10px; font-weight: 700; text-transform: uppercase;
  letter-spacing: .05em; color: var(--accent); background: var(--accent-dim);
  border: 1px solid rgba(16,185,129,.3); border-radius: 99px; padding: 2px 8px; margin-bottom: 10px;
}
.dash-card-title { font-size: 1rem; font-weight: 700; margin-bottom: 4px; color: var(--text-primary); }
.dash-card-desc { font-size: 12.5px; color: var(--text-secondary); line-height: 1.5; }

.dash-soon {
  display: flex; flex-direction: column; align-items: center; gap: 10px;
  text-align: center; color: var(--text-muted);
  border: 1px dashed var(--border); border-radius: var(--radius);
  padding: 3rem 2rem; margin-top: 1rem;
}
.dash-soon-badge {
  font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: .05em;
  color: var(--accent); background: var(--accent-dim); border-radius: 99px; padding: 3px 10px;
}
.dash-soon svg { color: var(--accent); opacity: .7; }

@media (max-width: 720px) {
  .dash-shell { grid-template-columns: 1fr; }
  .dash-sidebar { border-right: none; border-bottom: 1px solid var(--border); }
  .dash-sidebar nav { flex-direction: row; flex-wrap: wrap; position: static; }
  .dash-main { padding: 1.5rem 1rem 2.5rem; }
}

/* ── Conformité NIS2 (Phase 1) : flux réel ──────────────────────────────── */
.dash-loading { color: var(--text-muted); padding: 2rem 0; font-size: 14px; }
.dash-muted { color: var(--text-muted); font-size: 13px; }
.dash-warn { color: #f59e0b; font-size: 13px; font-weight: 600; }
.dash-ok { color: var(--accent); font-size: 13px; font-weight: 600; background: var(--accent-dim);
  border: 1px solid rgba(16,185,129,.3); border-radius: 8px; padding: 8px 12px; margin: 6px 0 14px; }

.dash-orgbar { display: flex; align-items: center; gap: 10px; margin-bottom: 1rem; }
.dash-orgbar label { font-size: 12px; color: var(--text-muted); text-transform: uppercase; letter-spacing: .04em; }
.dash-orgbar select, .dash-form select, .dash-q-row select, .dash-item select {
  background: var(--bg-card); color: var(--text-primary); border: 1px solid var(--border);
  border-radius: 8px; padding: 7px 10px; font-size: 13px; font-family: inherit;
}
.dash-orgbar-quota { font-size: 12px; color: var(--text-muted); }
.dash-link { color: var(--accent); text-decoration: underline; }
.dash-set-check { display: flex; align-items: center; gap: 8px; font-size: 14px; color: var(--text-primary); }
.dash-set-check input { width: auto; }
.dash-set-sub { font-size: 15px; margin: 18px 0 4px; padding-top: 14px; border-top: 1px solid var(--border); }
.dash-set-danger { color: var(--danger, #ef4444); border-top-color: rgba(239,68,68,.35); }
.dash-domain-line { font-size: 13px; margin-bottom: 1.25rem; }

.dash-panel-card {
  background: var(--bg-card); border: 1px solid var(--border); border-radius: var(--radius);
  padding: 1.5rem 1.75rem; margin-bottom: 1.5rem;
}
.dash-panel-card h2 { font-family: var(--font-heading); font-size: 1.15rem; margin-bottom: .35rem; }
.dash-panel-card h3 { font-size: .95rem; margin-bottom: .35rem; color: var(--text-primary); }

.dash-form { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 1rem; }
.dash-form input {
  flex: 1 1 200px; background: var(--bg-card-hover); color: var(--text-primary);
  border: 1px solid var(--border); border-radius: 8px; padding: 9px 12px; font-size: 13px; font-family: inherit;
}
.dash-domain-form { margin-top: 12px; }
.dash-form-col { flex-direction: column; align-items: stretch; gap: 8px; }
.dash-form-col label { font-size: 12px; color: var(--text-muted); margin-bottom: -2px; }
.dash-form-col input, .dash-form-col select { flex: none; width: 100%; max-width: 440px; box-sizing: border-box; }
.dash-form-col > div { margin-top: 4px; }

.dash-stat.tone-ok .dash-stat-num { color: var(--accent); }
.dash-stat.tone-warn .dash-stat-num { color: #f59e0b; }
.dash-stat.tone-bad .dash-stat-num { color: #f87171; }

.dash-table { width: 100%; border-collapse: collapse; margin: 12px 0; }
.dash-table td { padding: 9px 8px; border-bottom: 1px solid var(--border); font-size: 13px; vertical-align: middle; }
.dash-table td.c-ref, .c-ref { font-family: var(--font-mono, monospace); font-size: 12px; color: var(--accent); white-space: nowrap; }

.dash-pill { display: inline-block; font-size: 11px; font-weight: 700; border-radius: 99px; padding: 2px 10px; }
.dash-pill.st-satisfied { background: rgba(16,185,129,.16); color: #34d399; }
.dash-pill.st-partial { background: rgba(245,158,11,.16); color: #fbbf24; }
.dash-pill.st-not_satisfied { background: rgba(220,38,38,.16); color: #f87171; }
.dash-pill.st-not_applicable { background: rgba(148,163,184,.16); color: #cbd5e1; }
.dash-pill.st-unknown { background: var(--bg-card-hover); color: var(--text-muted); }

.dash-q-row { display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: 11px 0; border-bottom: 1px solid var(--border); }
.dash-q-main { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; min-width: 0; }
.dash-q-title { font-size: 13.5px; color: var(--text-primary); }
.dash-badge { font-size: 10px; font-weight: 700; text-transform: uppercase; letter-spacing: .04em;
  border-radius: 99px; padding: 2px 8px; background: var(--bg-card-hover); color: var(--text-muted); }
.dash-badge.ek-declarative { background: rgba(59,130,246,.15); color: #93c5fd; }
.dash-badge.ek-fratrie { background: rgba(139,92,246,.15); color: #c4b5fd; }
.dash-badge.ek-connector { background: rgba(245,158,11,.15); color: #fbbf24; }

/* Preuve fratrie RadarCore (Phase 2) */
.dash-fratrie-row { padding: 14px 0; border-bottom: 1px solid var(--border); }
.dash-fratrie-row:last-child { border-bottom: 0; }
.dash-fratrie-head { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.dash-fratrie-name { font-size: 14px; font-weight: 600; color: var(--text-primary); }
.dash-fratrie-ctrl { font-size: 12.5px; color: var(--text-muted); margin: 4px 0 10px; }
.dash-fratrie-form { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.dash-fratrie-form input {
  flex: 1 1 220px; min-width: 0; background: var(--bg-card-hover); color: var(--text-primary);
  border: 1px solid var(--border); border-radius: 8px; padding: 8px 11px; font-size: 13px; font-family: inherit;
}
.dash-fratrie-linked { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.dash-fratrie-email { font-family: var(--font-mono, monospace); font-size: 12.5px; color: var(--accent);
  background: var(--accent-dim); border-radius: 6px; padding: 3px 9px; }

/* Connecteurs de preuve (Phase 3 — Google Workspace) */
.dash-err { color: #f87171; font-size: 13px; font-weight: 600; background: rgba(220,38,38,.12);
  border: 1px solid rgba(220,38,38,.3); border-radius: 8px; padding: 8px 12px; margin: 6px 0 14px; }
.dash-conn-configured { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin-bottom: 12px; }
.dash-conn-actions { display: flex; gap: 8px; margin-left: auto; }
.dash-conn-form { display: flex; flex-direction: column; gap: 6px; margin-top: 6px; }
.dash-conn-form input, .dash-conn-form textarea {
  background: var(--bg-card-hover); color: var(--text-primary); border: 1px solid var(--border);
  border-radius: 8px; padding: 8px 11px; font-size: 13px; font-family: inherit;
}
.dash-conn-form textarea { font-family: var(--font-mono, monospace); font-size: 12px; resize: vertical; }
.dash-conn-help { font-size: 12px; color: var(--text-muted); margin-top: 4px; }

.dash-actions-row { display: flex; flex-wrap: wrap; gap: 10px; }
.dash-ai-summary { background: var(--bg-card-hover); border-left: 3px solid var(--accent);
  border-radius: 8px; padding: 12px 16px; margin: 16px 0; font-size: 13px; line-height: 1.55; }

.dash-item { display: flex; align-items: center; gap: 12px; padding: 11px 0; border-bottom: 1px solid var(--border); }
.dash-item-main { flex: 1; min-width: 0; }
.dash-item-title { font-size: 13.5px; font-weight: 600; color: var(--text-primary); }
.dash-item-desc { font-size: 12px; color: var(--text-secondary); margin-top: 2px; line-height: 1.45; }
.dash-prio { font-size: 10px; font-weight: 700; text-transform: uppercase; letter-spacing: .04em;
  border-radius: 99px; padding: 3px 9px; white-space: nowrap; }
.dash-prio.prio-critical { background: rgba(220,38,38,.2); color: #fca5a5; }
.dash-prio.prio-high { background: rgba(245,110,60,.18); color: #fdba74; }
.dash-prio.prio-medium { background: rgba(245,158,11,.16); color: #fbbf24; }
.dash-prio.prio-low { background: var(--bg-card-hover); color: var(--text-muted); }

.dash-answer { font-size: 10px; font-weight: 700; text-transform: uppercase; letter-spacing: .04em;
  border-radius: 99px; padding: 3px 9px; white-space: nowrap; }
.dash-answer.ans-oui { background: var(--accent-dim); color: var(--accent); }
.dash-answer.ans-partiel { background: rgba(245,158,11,.16); color: #fbbf24; }
.dash-answer.ans-non { background: rgba(220,38,38,.2); color: #fca5a5; }
.dash-answer.ans-a_preciser { background: var(--bg-card-hover); color: var(--text-muted); }

/* Registres RGPD / AI Act */
.dash-reg-entry { border: 1px solid var(--border); border-radius: 10px; padding: 12px 14px; margin: 10px 0; background: var(--bg-card-hover); }
.dash-reg-entry-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 6px; }
.dash-reg-name { font-family: var(--font-heading); font-size: 1.02rem; color: var(--text-primary); }
.dash-reg-actions { display: flex; gap: 6px; flex-shrink: 0; }
.dash-reg-field { display: flex; gap: 10px; padding: 4px 0; border-bottom: 1px solid var(--border); font-size: 12.5px; }
.dash-reg-field:last-child { border-bottom: none; }
.dash-reg-label { flex: 0 0 190px; color: var(--text-secondary); font-weight: 600; }
.dash-reg-val { flex: 1; min-width: 0; color: var(--text-primary); word-break: break-word; }
.dash-reg-form { margin-top: 14px; padding-top: 14px; border-top: 1px dashed var(--border); }
.dash-reg-form h3 { font-family: var(--font-heading); font-size: 1rem; margin-bottom: 8px; color: var(--text-primary); }
.dash-reg-form label { display: block; margin: 8px 0 3px; font-size: 12px; color: var(--text-secondary); }
.dash-reg-form input { width: 100%; background: var(--bg-card); color: var(--text-primary); border: 1px solid var(--border);
  border-radius: 8px; padding: 8px 11px; font-size: 12.5px; font-family: var(--font-sans); }
.dash-reg-form textarea { width: 100%; background: var(--bg-card); color: var(--text-primary); border: 1px solid var(--border);
  border-radius: 8px; padding: 8px 11px; font-size: 12.5px; font-family: var(--font-sans); resize: vertical; }
.dash-reg-form-actions { display: flex; gap: 8px; margin-top: 12px; }
.dash-broker-consent { display: flex; align-items: flex-start; gap: 8px; margin: 12px 0 3px; font-size: 12px;
  color: var(--text-secondary); line-height: 1.4; cursor: pointer; }
.dash-broker-consent input { width: auto; margin-top: 2px; flex: 0 0 auto; }

/* Score de préparation rançongiciel — pastille de note globale */
.dash-rw-grade { font-family: var(--font-heading); font-size: 20px; letter-spacing: .04em;
  padding: 2px 12px; border-radius: 8px; white-space: nowrap; }
.dash-rw-grade.rw-ready { background: var(--accent-dim); color: var(--accent); }
.dash-rw-grade.rw-partial { background: rgba(245,158,11,.16); color: #fbbf24; }
.dash-rw-grade.rw-not_ready { background: rgba(220,38,38,.2); color: #fca5a5; }

.dash-trust-link { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; margin: 6px 0; }
.dash-trust-link input { flex: 1 1 240px; background: var(--bg-card-hover); color: var(--text-primary);
  border: 1px solid var(--border); border-radius: 8px; padding: 8px 12px; font-size: 12.5px; font-family: var(--font-mono, monospace); }

.dash-toast { position: fixed; bottom: 24px; left: 50%; transform: translateX(-50%) translateY(20px);
  background: var(--accent); color: #04231a; font-weight: 600; font-size: 13px;
  padding: 11px 20px; border-radius: 10px; box-shadow: 0 6px 24px rgba(0,0,0,.35);
  opacity: 0; pointer-events: none; transition: opacity .2s, transform .2s; z-index: 9999; }
.dash-toast.show { opacity: 1; transform: translateX(-50%) translateY(0); }
.dash-toast.is-err { background: #dc2626; color: #fff; }
