/* =============================================
   DEBANETIK – Styles pages légales
   ============================================= */

.legal {
  padding-top: calc(var(--header-h) + 3rem);
  padding-bottom: 5rem;
  min-height: 80vh;
}

.legal__header {
  margin-bottom: 3rem;
  padding-bottom: 2rem;
  border-bottom: 1px solid var(--border);
}

.legal__header h1 {
  font-size: clamp(1.75rem, 4vw, 2.5rem);
  font-weight: 800;
  letter-spacing: -.02em;
  margin-bottom: .5rem;
}

.text-muted { color: var(--text-muted); font-size: .9rem; }

.legal__section {
  margin-bottom: 2.5rem;
}

.legal__section h2 {
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--accent);
  margin-bottom: 1rem;
  letter-spacing: 0;
}

.legal__section p {
  color: var(--text-muted);
  line-height: 1.75;
  margin-bottom: .75rem;
}

.legal__section p a { color: var(--accent); }
.legal__section p a:hover { text-decoration: underline; }

.legal__list {
  list-style: none;
  margin: .75rem 0 .75rem 1rem;
  display: flex;
  flex-direction: column;
  gap: .4rem;
}

.legal__list li {
  color: var(--text-muted);
  padding-left: 1rem;
  position: relative;
  font-size: .95rem;
  line-height: 1.65;
}

.legal__list li::before {
  content: '–';
  position: absolute;
  left: 0;
  color: var(--accent);
}

.legal__back {
  margin-top: 3rem;
  padding-top: 2rem;
  border-top: 1px solid var(--border);
}

/* ---- Cookie Viewer ---- */
.cv-card {
  background: #0f172a;
  border: 1px solid rgba(255,255,255,.1);
  border-radius: 12px;
  padding: 1.5rem;
  margin: 1.5rem 0 2rem;
}

.cv-card__header {
  display: flex;
  align-items: center;
  gap: .75rem;
  flex-wrap: wrap;
  margin-bottom: 1.25rem;
}

.cv-card__title {
  font-size: 1rem;
  font-weight: 700;
  color: #f1f5f9;
  margin: 0;
  flex: 1;
  display: flex;
  align-items: center;
  gap: .5rem;
}

.cv-count {
  background: #1e293b;
  color: #94a3b8;
  font-size: .75rem;
  font-weight: 600;
  padding: .15rem .55rem;
  border-radius: 99px;
  border: 1px solid rgba(255,255,255,.08);
}

.cv-card__actions {
  display: flex;
  gap: .5rem;
  flex-wrap: wrap;
}

.cv-btn {
  font-family: Inter, system-ui, sans-serif;
  font-size: .8rem;
  font-weight: 600;
  border-radius: 6px;
  padding: .4rem .9rem;
  cursor: pointer;
  border: 1px solid rgba(255,255,255,.1);
  background: #1e293b;
  color: #94a3b8;
  transition: border-color .15s, color .15s;
}
.cv-btn:hover { border-color: #94a3b8; color: #f1f5f9; }
.cv-btn:disabled { opacity: .4; cursor: default; pointer-events: none; }

.cv-btn--danger {
  border-color: rgba(239,68,68,.3);
  color: #f87171;
  background: rgba(239,68,68,.08);
}
.cv-btn--danger:hover { border-color: #f87171; background: rgba(239,68,68,.15); color: #fca5a5; }

.cv-btn--primary {
  border-color: rgba(59,130,246,.4);
  color: #60a5fa;
  background: rgba(59,130,246,.08);
}
.cv-btn--primary:hover { border-color: #60a5fa; background: rgba(59,130,246,.15); }

.cv-notice {
  font-size: .78rem;
  color: #64748b;
  margin: 0 0 1.25rem;
  padding: .6rem .85rem;
  background: rgba(255,255,255,.03);
  border-radius: 6px;
  border-left: 3px solid #334155;
  line-height: 1.5;
}

#cv-list { display: flex; flex-direction: column; gap: .75rem; }

.cv-empty {
  color: #64748b;
  font-size: .9rem;
  text-align: center;
  padding: 1.5rem;
  margin: 0;
}
.cv-empty small { display: block; margin-top: .4rem; font-size: .8rem; }

.cv-item {
  background: #1e293b;
  border: 1px solid rgba(255,255,255,.06);
  border-radius: 8px;
  padding: .85rem 1rem;
}

.cv-item__top {
  display: flex;
  align-items: flex-start;
  gap: .75rem;
  margin-bottom: .4rem;
}

.cv-item__name-row {
  display: flex;
  align-items: center;
  gap: .5rem;
  flex: 1;
  flex-wrap: wrap;
  min-width: 0;
}

.cv-item__name {
  font-family: 'Courier New', monospace;
  font-size: .82rem;
  color: #e2e8f0;
  word-break: break-all;
}

.cv-item__badge {
  font-size: .7rem;
  font-weight: 600;
  padding: .15rem .5rem;
  border-radius: 99px;
  white-space: nowrap;
  flex-shrink: 0;
}

.cv-item__del {
  font-family: Inter, system-ui, sans-serif;
  font-size: .75rem;
  font-weight: 600;
  color: #f87171;
  background: rgba(239,68,68,.08);
  border: 1px solid rgba(239,68,68,.2);
  border-radius: 5px;
  padding: .2rem .6rem;
  cursor: pointer;
  white-space: nowrap;
  flex-shrink: 0;
  transition: background .15s, border-color .15s;
}
.cv-item__del:hover { background: rgba(239,68,68,.18); border-color: #f87171; }

.cv-item__label {
  font-size: .82rem;
  font-weight: 600;
  color: #cbd5e1;
  margin: 0 0 .4rem;
}

.cv-item__meta {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
  margin-bottom: .5rem;
}

.cv-item__meta span {
  font-size: .78rem;
  color: #64748b;
  display: flex;
  align-items: center;
  gap: .3rem;
}
.cv-item__meta svg { flex-shrink: 0; }

.cv-item__purpose {
  font-size: .8rem;
  color: #64748b;
  line-height: 1.55;
  margin: 0;
}

@media (max-width: 480px) {
  .cv-card { padding: 1.1rem; }
  .cv-item__top { flex-wrap: wrap; }
}
