/* AZALYS V6.4 — Cockpit de validation des écritures comptables
   Réutilise les tokens premium (--az-*) avec repli si absents. */

.ec-cockpit { border-top: 3px solid var(--az-primary, #1f6feb); }
.ec-cockpit .card-head h3 { display: flex; align-items: center; gap: .55rem; }
.ec-cockpit-actions { display: flex; gap: .5rem; align-items: center; }

.ec-cockpit-list {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
  gap: .9rem;
  margin-top: .6rem;
}

.ec-card {
  background: var(--az-bg-1, var(--card, #fff));
  border: 1px solid var(--az-hairline, var(--cab-border, rgba(16,29,54,.10)));
  border-radius: var(--az-radius-lg, 14px);
  padding: .85rem .95rem;
  box-shadow: var(--az-shadow-md, 0 2px 10px rgba(16,29,54,.05));
  display: flex;
  flex-direction: column;
  gap: .6rem;
  transition: box-shadow .18s ease, transform .18s ease, border-color .18s ease;
}
.ec-card:hover {
  box-shadow: var(--az-shadow-lg, 0 8px 26px rgba(16,29,54,.12));
  border-color: var(--az-primary, #1f6feb);
  transform: translateY(-1px);
}

.ec-card-head { display: flex; justify-content: space-between; align-items: flex-start; gap: .6rem; }
.ec-card-head strong { display: block; color: var(--az-ink, var(--cab-text, #101d36)); font-size: .98rem; }
.ec-card-head small { color: var(--az-text-soft, var(--cab-text-muted, #6b7890)); font-size: .76rem; }

/* Tableau partie double */
.ec-table { width: 100%; border-collapse: collapse; font-size: .84rem; }
.ec-table th {
  text-align: left;
  font-weight: 600;
  font-size: .72rem;
  text-transform: uppercase;
  letter-spacing: .03em;
  color: var(--az-text-soft, #6b7890);
  border-bottom: 1px solid var(--az-hairline, rgba(16,29,54,.10));
  padding: .25rem .4rem;
}
.ec-table td {
  padding: .3rem .4rem;
  border-bottom: 1px solid var(--az-hairline, rgba(16,29,54,.06));
  color: var(--az-text, #243043);
  vertical-align: top;
}
.ec-table td em { color: var(--az-text-soft, #6b7890); font-style: normal; font-size: .78rem; }
.ec-table tfoot td {
  font-weight: 700;
  border-top: 2px solid var(--az-gold-line, var(--az-gold, #c9a14a));
  border-bottom: none;
  color: var(--az-ink, #101d36);
}
.ec-num { text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }
.ec-acct { font-variant-numeric: tabular-nums; font-weight: 700; color: var(--az-primary-600, var(--az-primary, #1f6feb)); }

.ec-anoms { display: flex; flex-wrap: wrap; gap: .35rem; }
.ec-anoms span {
  background: rgba(201,161,74,.12);
  color: var(--az-gold, #8a6d22);
  border: 1px solid rgba(201,161,74,.35);
  border-radius: 999px;
  padding: .12rem .55rem;
  font-size: .74rem;
}

.ec-card-actions { display: flex; align-items: center; gap: .5rem; margin-top: .1rem; }
.ec-rule { margin-left: auto; font-size: .68rem; color: var(--az-text-soft, #8a93a6); letter-spacing: .02em; }

/* Aperçu écriture dans le poste de travail */
.ec-preview { display: flex; flex-direction: column; gap: .55rem; }
.ec-preview-head { display: flex; justify-content: space-between; align-items: center; }
.ec-preview-head strong { color: var(--az-ink, #101d36); }

/* Badge ambre (manquant dans le thème de base) */
.badge.amber {
  background: rgba(201,161,74,.14);
  color: var(--az-gold, #8a6d22);
  border: 1px solid rgba(201,161,74,.4);
}

@media (max-width: 720px) {
  .ec-cockpit-list { grid-template-columns: 1fr; }
}
