/* ══════════════════════════════════════════════
   ROADMAP · Migration Sylius
   ══════════════════════════════════════════════ */

/* ── Tabs ─────────────────────────────────────── */
.rm-tabs {
  display: flex; gap: 4px;
  border-bottom: 1px solid var(--border);
  margin-bottom: 24px;
}
.rm-tab {
  padding: 10px 20px;
  font-family: 'DM Sans', sans-serif;
  font-size: 13px; font-weight: 500;
  color: var(--muted);
  background: none; border: none;
  border-bottom: 2px solid transparent;
  cursor: pointer;
  transition: color 0.15s, border-color 0.15s;
}
.rm-tab:hover { color: var(--text); }
.rm-tab.active {
  color: var(--accent);
  border-bottom-color: var(--accent);
  font-weight: 600;
}

/* ── Filters bar ──────────────────────────────── */
.rm-filters {
  display: flex; align-items: center; gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 16px;
}
.rm-filter-group {
  display: flex; align-items: center; gap: 4px;
}
.rm-filter-label {
  font-size: 10px; font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--muted);
}
.rm-filter-select {
  font-family: 'DM Sans', sans-serif;
  font-size: 12px; font-weight: 500;
  padding: 4px 8px;
  border: 1px solid var(--border);
  border-radius: 6px;
  background: #fff;
  color: var(--text);
  cursor: pointer;
}
.rm-filter-select:focus { outline: none; border-color: var(--accent); }
.rm-add-task-btn {
  margin-left: auto;
  display: flex; align-items: center; gap: 5px;
  padding: 6px 14px;
  font-family: 'DM Sans', sans-serif;
  font-size: 12px; font-weight: 600;
  color: #fff; background: var(--accent);
  border: none; border-radius: 8px;
  cursor: pointer;
  transition: opacity 0.15s;
}
.rm-add-task-btn:hover { opacity: 0.85; }

/* ── Gantt grid ───────────────────────────────── */
.rm-gantt-wrap {
  overflow-x: auto;
  border: 1px solid rgba(90,80,180,0.18);
  border-radius: 10px;
  background: #eeedfb;
  box-shadow: inset 0 1px 3px rgba(90,80,180,0.06);
}
.rm-gantt {
  min-width: 1500px;
  position: relative;
}

/* Month header */
.rm-gantt-header {
  display: flex;
  border-bottom: 2px solid rgba(91,77,232,0.18);
  position: sticky; top: 0;
  background: rgba(91,77,232,0.07);
  z-index: 5;
}
.rm-gantt-domain-col {
  width: 190px; min-width: 190px;
  padding: 10px 14px;
  font-size: 10px; font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--muted);
  border-right: 1px solid var(--border);
  background: rgba(255,255,255,0.3);
}
.rm-gantt-months {
  display: flex; flex: 1;
}
.rm-month-col {
  flex: 1;
  text-align: center;
  padding: 8px 0;
  font-family: 'DM Serif Display', serif;
  font-size: 14px; font-weight: 400;
  color: var(--text);
  border-right: 1px solid rgba(90,80,180,0.12);
  position: relative;
}
.rm-month-col:last-child { border-right: none; }
.rm-month-weeks {
  display: flex;
  font-family: 'DM Sans', sans-serif;
  font-size: 9px; font-weight: 500;
  color: var(--muted2);
  margin-top: 2px;
}
.rm-month-weeks span { flex: 1; }

/* Domain rows */
.rm-domain-row {
  display: flex;
  border-bottom: 1px solid rgba(90,80,180,0.10);
  min-height: 48px;
}
.rm-domain-row:last-child { border-bottom: none; }
.rm-domain-label {
  width: 190px; min-width: 190px;
  padding: 10px 12px;
  font-size: 12px; font-weight: 600;
  color: var(--domain-text, var(--text));
  border-right: 1px solid rgba(90,80,180,0.08);
  display: flex; align-items: center;
  background: var(--domain-bg, rgba(91,77,232,0.06));
  position: sticky; left: 0; z-index: 2;
  line-height: 1.3;
}
.rm-domain-timeline {
  flex: 1;
  position: relative;
  padding: 4px 0;
}

/* Per-domain soft pastel colors (label bg = stronger, row bg = faint continuation) */
.rm-domain-row.domain-infrastructure .rm-domain-label   { --domain-bg: rgba(91,77,232,0.10); --domain-text: #4338ca; }
.rm-domain-row.domain-infrastructure .rm-domain-timeline { background: rgba(91,77,232,0.04); }
.rm-domain-row.domain-securite .rm-domain-label         { --domain-bg: rgba(220,38,38,0.08); --domain-text: #b91c1c; }
.rm-domain-row.domain-securite .rm-domain-timeline      { background: rgba(220,38,38,0.03); }
.rm-domain-row.domain-catalogue .rm-domain-label        { --domain-bg: rgba(14,165,233,0.08); --domain-text: #0369a1; }
.rm-domain-row.domain-catalogue .rm-domain-timeline     { background: rgba(14,165,233,0.04); }
.rm-domain-row.domain-clients-b2b .rm-domain-label      { --domain-bg: rgba(124,58,237,0.08); --domain-text: #6d28d9; }
.rm-domain-row.domain-clients-b2b .rm-domain-timeline   { background: rgba(124,58,237,0.04); }
.rm-domain-row.domain-front .rm-domain-label            { --domain-bg: rgba(37,99,235,0.08); --domain-text: #1d4ed8; }
.rm-domain-row.domain-front .rm-domain-timeline         { background: rgba(37,99,235,0.04); }
.rm-domain-row.domain-fournisseurs .rm-domain-label     { --domain-bg: rgba(13,148,136,0.08); --domain-text: #0f766e; }
.rm-domain-row.domain-fournisseurs .rm-domain-timeline  { background: rgba(13,148,136,0.04); }
.rm-domain-row.domain-checkout .rm-domain-label         { --domain-bg: rgba(217,119,6,0.08); --domain-text: #b45309; }
.rm-domain-row.domain-checkout .rm-domain-timeline      { background: rgba(217,119,6,0.03); }
.rm-domain-row.domain-paiement .rm-domain-label         { --domain-bg: rgba(5,150,105,0.08); --domain-text: #047857; }
.rm-domain-row.domain-paiement .rm-domain-timeline      { background: rgba(5,150,105,0.04); }
.rm-domain-row.domain-migration .rm-domain-label        { --domain-bg: rgba(99,102,241,0.08); --domain-text: #4f46e5; }
.rm-domain-row.domain-migration .rm-domain-timeline     { background: rgba(99,102,241,0.04); }
.rm-domain-row.domain-recette .rm-domain-label          { --domain-bg: rgba(225,29,72,0.08); --domain-text: #be123c; }
.rm-domain-row.domain-recette .rm-domain-timeline       { background: rgba(225,29,72,0.03); }

/* Task bars */
.rm-task {
  position: absolute;
  height: 48px;
  border-radius: 6px;
  display: flex; flex-direction: column;
  justify-content: center;
  padding: 4px 10px;
  gap: 2px;
  cursor: grab;
  transition: box-shadow 0.15s, transform 0.15s;
  z-index: 1;
  user-select: none;
  overflow: hidden;
  /* Default (moyenne) */
  background: #faf9ff;
  border: 1px solid rgba(90,80,180,0.15);
  border-top: 3px solid #a09fc4;
  box-shadow: 0 1px 3px rgba(90,80,180,0.08);
}
.rm-task:hover {
  box-shadow: 0 3px 12px rgba(90,80,180,0.18);
  transform: translateY(-1px);
  z-index: 3;
}
.rm-task.dragging { opacity: 0.6; cursor: grabbing; z-index: 10; }

/* Priority card tints */
.rm-task.priority-critique {
  background: #fef2f2;
  border: 1px solid rgba(220,38,38,0.2);
  border-top: 3px solid #dc2626;
  box-shadow: 0 1px 3px rgba(220,38,38,0.1);
}
.rm-task.priority-haute {
  background: #fffbeb;
  border: 1px solid rgba(245,158,11,0.2);
  border-top: 3px solid #f59e0b;
  box-shadow: 0 1px 3px rgba(245,158,11,0.1);
}
.rm-task.priority-moyenne {
  background: #faf9ff;
  border: 1px solid rgba(90,80,180,0.12);
  border-top: 3px solid #a09fc4;
}
.rm-task.priority-basse {
  background: #f9fafb;
  border: 1px solid rgba(0,0,0,0.06);
  border-top: 3px solid #d1d5db;
}

/* Status treatments */
.rm-task.status-en_cours {
  box-shadow: 0 0 0 2px rgba(91,77,232,0.15), 0 1px 3px rgba(90,80,180,0.1);
}
.rm-task.status-bloque {
  background: #fef2f2 !important;
  border: 2px dashed #dc2626 !important;
  border-top: 3px dashed #dc2626 !important;
}
.rm-task.status-bloque .rm-task-title { color: #991b1b; }
.rm-task.status-termine {
  opacity: 0.5;
  background: #f3f4f6 !important;
  border-color: rgba(0,0,0,0.06) !important;
  border-top-color: #9ca3af !important;
}
.rm-task.status-termine .rm-task-title { text-decoration: line-through; color: var(--muted); }

.rm-task-title {
  font-size: 12px; font-weight: 600;
  color: var(--text);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  line-height: 1.3;
}
.rm-task-meta {
  display: flex; align-items: center; gap: 6px;
}
.rm-task-badge {
  font-size: 10px; font-weight: 600;
  padding: 0 6px;
  border-radius: 3px;
  background: rgba(91,77,232,0.08);
  color: var(--accent);
  white-space: nowrap;
  line-height: 1.6;
}
.rm-task-status-dot {
  width: 7px; height: 7px;
  border-radius: 50%;
  flex-shrink: 0;
}
.rm-task-status-dot.dot-todo       { background: transparent; border: 1.5px solid var(--muted2); }
.rm-task-status-dot.dot-en_cours   { background: var(--accent); animation: pulse-dot 2s ease-in-out infinite; }
.rm-task-status-dot.dot-termine    { background: #059669; }
.rm-task-status-dot.dot-bloque     { background: #dc2626; border-radius: 2px; }
@keyframes pulse-dot { 0%,100% { opacity:1; transform:scale(1); } 50% { opacity:0.5; transform:scale(0.8); } }

/* Dependency link indicator */
.rm-task-dep {
  font-size: 9px; color: var(--muted2);
  display: flex; align-items: center; gap: 2px;
}
.rm-task-dep svg { width: 10px; height: 10px; stroke: var(--muted2); fill: none; }

/* Tooltip (global floating element managed by JS) */
#rm-tooltip {
  position: fixed;
  z-index: 9999;
  min-width: 180px; max-width: 320px;
  padding: 8px 12px;
  background: var(--text);
  color: #fff;
  font-family: 'DM Sans', sans-serif;
  font-size: 12px; font-weight: 500;
  line-height: 1.5;
  border-radius: 6px;
  box-shadow: 0 4px 16px rgba(28,27,58,0.28);
  white-space: normal;
  word-break: break-word;
  pointer-events: none;
  opacity: 0;
  transition: opacity 120ms ease-out;
}
#rm-tooltip.visible { opacity: 1; }
#rm-tooltip::before {
  content: '';
  position: absolute; top: -4px; left: 14px;
  width: 8px; height: 8px;
  background: var(--text);
  transform: rotate(45deg);
}
#rm-tooltip .tt-title {
  font-weight: 600; font-size: 12px; margin-bottom: 2px;
}
#rm-tooltip .tt-meta {
  font-size: 11px; color: rgba(255,255,255,0.6);
}

/* Resize handle */
.rm-task-resize {
  position: absolute; right: 0; top: 0;
  width: 8px; height: 100%;
  cursor: ew-resize;
  z-index: 2;
}
.rm-task-resize:hover { background: rgba(91,77,232,0.15); }

/* Week grid lines */
.rm-week-line {
  position: absolute; top: 0; bottom: 0;
  width: 1px;
  background: rgba(90,80,180,0.06);
  z-index: 0;
}
.rm-week-line.month-line { background: rgba(91,77,232,0.15); }

/* Legend bar */
.rm-gantt-legend {
  display: flex; align-items: center; gap: 18px;
  padding: 8px 16px;
  border-bottom: 1px solid rgba(90,80,180,0.12);
  background: rgba(255,255,255,0.5);
  font-size: 10px; color: var(--muted); font-weight: 500;
}
.rm-legend-item { display: flex; align-items: center; gap: 5px; }
.rm-legend-swatch {
  width: 16px; height: 10px; border-radius: 2px;
}
.rm-legend-swatch.critique { background: #fef2f2; border-top: 2px solid #dc2626; }
.rm-legend-swatch.haute    { background: #fffbeb; border-top: 2px solid #f59e0b; }
.rm-legend-swatch.moyenne  { background: #faf9ff; border-top: 2px solid #a09fc4; }

/* ── Detail drawer ────────────────────────────── */
.rm-detail-field {
  margin-bottom: 16px;
}
.rm-detail-label {
  font-size: 10px; font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--muted);
  margin-bottom: 4px;
}
.rm-detail-value {
  font-size: 14px; color: var(--text);
}
.rm-detail-select {
  font-family: 'DM Sans', sans-serif;
  font-size: 13px;
  padding: 6px 10px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: #fff;
  color: var(--text);
  width: 100%;
}
.rm-detail-textarea {
  font-family: 'DM Sans', sans-serif;
  font-size: 13px;
  padding: 8px 10px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: #fff;
  color: var(--text);
  width: 100%;
  min-height: 80px;
  resize: vertical;
}
.rm-detail-input {
  font-family: 'DM Sans', sans-serif;
  font-size: 13px;
  padding: 6px 10px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: #fff;
  color: var(--text);
  width: 100%;
}
.rm-detail-delete {
  margin-top: 24px;
  padding: 8px 16px;
  font-family: 'DM Sans', sans-serif;
  font-size: 12px; font-weight: 600;
  color: var(--delete-txt);
  background: var(--delete-bg);
  border: 1px solid rgba(239,68,68,0.2);
  border-radius: 8px;
  cursor: pointer;
  width: 100%;
}
.rm-detail-delete:hover { background: rgba(239,68,68,0.15); }

/* ── Vision editor ────────────────────────────── */
.rm-vision-toolbar {
  display: flex; gap: 4px;
  margin-bottom: 8px;
}
.rm-vision-btn {
  padding: 4px 10px;
  font-family: 'DM Sans', sans-serif;
  font-size: 12px; font-weight: 600;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 6px;
  cursor: pointer;
  color: var(--muted);
  transition: background 0.1s;
}
.rm-vision-btn:hover { background: var(--accent-soft); color: var(--accent); }
.rm-vision-editor {
  min-height: 400px;
  padding: 20px 24px;
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 10px;
  font-family: 'DM Sans', sans-serif;
  font-size: 14px;
  line-height: 1.7;
  color: var(--text);
  outline: none;
}
.rm-vision-editor:focus { border-color: var(--accent); box-shadow: 0 0 0 2px rgba(91,77,232,0.1); }
.rm-vision-editor h2 { font-family: 'DM Serif Display', serif; font-size: 22px; margin: 20px 0 8px; }
.rm-vision-editor h3 { font-size: 16px; font-weight: 600; margin: 16px 0 6px; }
.rm-vision-editor ul, .rm-vision-editor ol { padding-left: 20px; margin: 8px 0; }
.rm-vision-editor li { margin: 4px 0; }
.rm-vision-editor strong { font-weight: 600; }
.rm-vision-status {
  font-size: 11px; color: var(--muted);
  margin-top: 8px; text-align: right;
}

/* ── Risks journal ────────────────────────────── */
.rm-risks-header {
  display: flex; align-items: center; justify-content: space-between;
  margin-bottom: 16px;
}
.rm-risks-title {
  font-family: 'DM Serif Display', serif;
  font-size: 20px; font-weight: 400;
  color: var(--text);
}
.rm-risk-card {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 16px 20px;
  margin-bottom: 12px;
  transition: box-shadow 0.15s;
}
.rm-risk-card:hover { box-shadow: var(--shadow-sm); }
.rm-risk-top {
  display: flex; align-items: center; gap: 8px;
  margin-bottom: 8px;
}
.rm-risk-date {
  font-size: 11px; color: var(--muted);
}
.rm-risk-type-badge {
  font-size: 10px; font-weight: 700;
  padding: 2px 8px; border-radius: 20px;
  text-transform: uppercase;
  letter-spacing: 0.03em;
}
.rm-risk-type-badge.type-risque {
  background: rgba(239,68,68,0.1); color: #dc2626;
}
.rm-risk-type-badge.type-decision {
  background: rgba(91,77,232,0.1); color: var(--accent);
}
.rm-risk-impact-badge {
  font-size: 10px; font-weight: 600;
  padding: 2px 8px; border-radius: 20px;
}
.rm-risk-impact-badge.impact-critique { background: rgba(239,68,68,0.1); color: #dc2626; }
.rm-risk-impact-badge.impact-fort     { background: rgba(245,158,11,0.1); color: #d97706; }
.rm-risk-impact-badge.impact-moyen    { background: rgba(91,77,232,0.1); color: var(--accent); }
.rm-risk-impact-badge.impact-faible   { background: rgba(0,0,0,0.04); color: var(--muted); }
.rm-risk-status-badge {
  font-size: 10px; font-weight: 700;
  padding: 2px 8px; border-radius: 20px;
  margin-left: auto;
}
.rm-risk-status-badge.status-ouvert        { background: rgba(245,158,11,0.1); color: #d97706; }
.rm-risk-status-badge.status-en_discussion { background: rgba(14,165,233,0.1); color: #0369a1; }
.rm-risk-status-badge.status-resolu        { background: rgba(16,185,129,0.1); color: #059669; }
.rm-risk-status-badge.status-accepte       { background: rgba(0,0,0,0.04); color: var(--muted); }
.rm-risk-title-text {
  font-size: 14px; font-weight: 600;
  color: var(--text);
  margin-bottom: 4px;
}
.rm-risk-desc {
  font-size: 13px; color: var(--muted);
  line-height: 1.5;
}
.rm-risk-footer {
  display: flex; align-items: center; gap: 8px;
  margin-top: 10px;
  font-size: 11px; color: var(--muted);
}
.rm-risk-actions {
  margin-left: auto;
  display: flex; gap: 4px;
}
.rm-risk-edit-btn, .rm-risk-delete-btn {
  font-family: 'DM Sans', sans-serif;
  font-size: 11px; font-weight: 500;
  padding: 3px 8px;
  border-radius: 6px;
  border: 1px solid var(--border);
  background: #fff;
  cursor: pointer;
  color: var(--muted);
}
.rm-risk-edit-btn:hover { color: var(--accent); border-color: var(--accent); }
.rm-risk-delete-btn:hover { color: var(--delete-txt); border-color: var(--delete-txt); }

/* ── Risk edit form ──────────────────────────── */
.rm-risk-form {
  background: #fff;
  border: 1px solid var(--accent);
  border-radius: 10px;
  padding: 16px 20px;
  margin-bottom: 12px;
  box-shadow: 0 0 0 2px rgba(91,77,232,0.1);
}
.rm-risk-form-row {
  display: flex; gap: 8px;
  margin-bottom: 8px;
}
.rm-risk-form-row > * { flex: 1; }
.rm-risk-form-actions {
  display: flex; gap: 8px; justify-content: flex-end;
  margin-top: 12px;
}
.rm-risk-form-btn {
  font-family: 'DM Sans', sans-serif;
  font-size: 12px; font-weight: 600;
  padding: 6px 16px;
  border-radius: 8px;
  border: none;
  cursor: pointer;
}
.rm-risk-form-btn.primary { background: var(--accent); color: #fff; }
.rm-risk-form-btn.secondary { background: var(--surface); color: var(--muted); border: 1px solid var(--border); }

/* ── View Switcher ───────────────────────────── */
.rm-view-switcher {
  display: flex; gap: 2px;
  background: var(--bg);
  border-radius: 8px;
  padding: 3px;
  margin-bottom: 12px;
  width: fit-content;
}
.rm-view-btn {
  display: flex; align-items: center; gap: 5px;
  padding: 6px 14px;
  font-family: 'DM Sans', sans-serif;
  font-size: 12px; font-weight: 500;
  color: var(--muted);
  background: transparent;
  border: none; border-radius: 6px;
  cursor: pointer;
  transition: background 0.15s, color 0.15s;
}
.rm-view-btn:hover { background: rgba(255,255,255,0.5); color: var(--text); }
.rm-view-btn.active { background: var(--accent); color: #fff; font-weight: 600; }
.rm-view-btn svg { flex-shrink: 0; }

/* ── List View (Notion-style table) ─────────── */
.rm-list-table {
  width: 100%;
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 10px;
  border-collapse: separate;
  border-spacing: 0;
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  font-family: 'DM Sans', sans-serif;
}
.rm-list-table thead { background: #faf9ff; }
.rm-list-th {
  padding: 8px 14px;
  font-size: 10px; font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--muted);
  cursor: pointer;
  user-select: none;
  white-space: nowrap;
  text-align: left;
  border-bottom: 1px solid var(--border);
  border-right: 1px solid rgba(90,80,180,0.06);
  transition: color 0.15s;
}
.rm-list-th:last-child { border-right: none; }
.rm-list-th:hover { color: var(--text); }
.rm-list-th-actions { width: 44px; cursor: default; }
.rm-list-sort-icon { vertical-align: middle; margin-left: 2px; color: var(--accent); }

.rm-list-row {
  transition: background 0.1s;
  cursor: pointer;
}
.rm-list-row:hover { background: rgba(91,77,232,0.03); }

.rm-list-td {
  padding: 10px 14px;
  font-size: 13px;
  color: var(--text);
  border-bottom: 1px solid rgba(90,80,180,0.06);
  border-right: 1px solid rgba(90,80,180,0.04);
  vertical-align: middle;
}
.rm-list-td:last-child { border-right: none; }
.rm-list-row:last-child .rm-list-td { border-bottom: none; }
.rm-list-td-title {
  font-weight: 600;
  max-width: 280px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.rm-list-td-date { white-space: nowrap; font-size: 12px; color: var(--muted); }
.rm-list-td-num { white-space: nowrap; font-size: 12px; color: var(--muted); text-align: center; }
.rm-list-td-actions { text-align: center; }

/* Domain tag in list */
.rm-list-domain-tag {
  display: inline-block;
  font-size: 11px; font-weight: 600;
  padding: 2px 8px;
  border-radius: 4px;
  white-space: nowrap;
  background: rgba(91,77,232,0.06);
  color: var(--accent);
}
.rm-list-domain-tag.domain-infrastructure { background: rgba(91,77,232,0.10); color: #4338ca; }
.rm-list-domain-tag.domain-securite       { background: rgba(220,38,38,0.08); color: #b91c1c; }
.rm-list-domain-tag.domain-catalogue      { background: rgba(14,165,233,0.08); color: #0369a1; }
.rm-list-domain-tag.domain-clients-b2b    { background: rgba(124,58,237,0.08); color: #6d28d9; }
.rm-list-domain-tag.domain-front          { background: rgba(37,99,235,0.08); color: #1d4ed8; }
.rm-list-domain-tag.domain-fournisseurs   { background: rgba(13,148,136,0.08); color: #0f766e; }
.rm-list-domain-tag.domain-checkout       { background: rgba(217,119,6,0.08); color: #b45309; }
.rm-list-domain-tag.domain-paiement       { background: rgba(5,150,105,0.08); color: #047857; }
.rm-list-domain-tag.domain-migration      { background: rgba(99,102,241,0.08); color: #4f46e5; }
.rm-list-domain-tag.domain-recette        { background: rgba(225,29,72,0.08); color: #be123c; }

/* Inline status/priority badges for list view */
.rm-list-status-pill {
  display: inline-flex; align-items: center; gap: 5px;
  font-size: 11px; font-weight: 600;
  padding: 2px 8px;
  border-radius: 20px;
  white-space: nowrap;
  line-height: 1.5;
}
.rm-list-status-pill.status-todo       { background: rgba(0,0,0,0.04); color: var(--muted); }
.rm-list-status-pill.status-en_cours   { background: rgba(91,77,232,0.1); color: var(--accent); }
.rm-list-status-pill.status-termine    { background: rgba(16,185,129,0.1); color: #059669; }
.rm-list-status-pill.status-bloque     { background: rgba(239,68,68,0.1); color: #dc2626; }

.rm-list-priority-pill {
  display: inline-flex; align-items: center;
  font-size: 11px; font-weight: 600;
  padding: 2px 8px;
  border-radius: 20px;
  white-space: nowrap;
  line-height: 1.5;
}
.rm-list-priority-pill.priority-critique { background: rgba(220,38,38,0.1); color: #dc2626; }
.rm-list-priority-pill.priority-haute    { background: rgba(245,158,11,0.1); color: #d97706; }
.rm-list-priority-pill.priority-moyenne  { background: rgba(91,77,232,0.08); color: var(--accent); }
.rm-list-priority-pill.priority-basse    { background: rgba(0,0,0,0.04); color: var(--muted); }

/* Row actions */
.rm-list-td-actions .rm-list-delete-btn {
  opacity: 0;
  transition: opacity 0.1s;
}
.rm-list-row:hover .rm-list-delete-btn { opacity: 1; }
.rm-list-delete-btn {
  display: inline-flex; align-items: center; justify-content: center;
  width: 28px; height: 28px;
  border: none; border-radius: 6px;
  background: transparent;
  color: var(--muted2);
  cursor: pointer;
  transition: background 0.1s, color 0.1s;
}
.rm-list-delete-btn:hover { background: var(--delete-bg); color: var(--delete-txt); }

/* Add row */
.rm-list-add-row {
  display: flex; align-items: center; gap: 6px;
  padding: 10px 14px;
  font-family: 'DM Sans', sans-serif;
  font-size: 13px; font-weight: 500;
  color: var(--muted);
  background: none;
  border: none;
  cursor: pointer;
  transition: background 0.1s, color 0.1s;
  width: 100%;
}
.rm-list-add-row:hover { background: rgba(91,77,232,0.03); color: var(--accent); }

/* ── Kanban View ─────────────────────────────── */
.rm-kanban-board {
  display: flex;
  gap: 14px;
  overflow-x: auto;
  padding-bottom: 8px;
  align-items: flex-start;
}
.rm-kanban-col {
  display: flex; flex-direction: column;
  min-width: 260px; max-width: 320px;
  flex: 1;
  border-radius: 10px;
  padding: 10px;
}

/* Column background tints by status */
.rm-kanban-col[data-status="todo"]     { background: rgba(0,0,0,0.025); }
.rm-kanban-col[data-status="en_cours"] { background: rgba(91,77,232,0.05); }
.rm-kanban-col[data-status="bloque"]   { background: rgba(239,68,68,0.04); }
.rm-kanban-col[data-status="termine"]  { background: rgba(16,185,129,0.04); }

.rm-kanban-col-header {
  display: flex; align-items: center; gap: 8px;
  padding: 6px 6px 10px;
  font-family: 'DM Sans', sans-serif;
  font-size: 12px; font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--muted);
}
.rm-kanban-col-title { flex: 1; }
.rm-kanban-col-count {
  font-size: 10px; font-weight: 700;
  padding: 1px 7px;
  border-radius: 20px;
  background: rgba(0,0,0,0.06);
  color: var(--muted);
  line-height: 1.5;
}

.rm-kanban-col-body {
  min-height: 40px;
  border: 2px solid transparent;
  border-radius: 8px;
  transition: border-color 0.15s, background 0.15s;
}
.rm-kanban-col-body.rm-kanban-drop-target {
  border-color: var(--accent);
  background: rgba(91,77,232,0.06);
}

.rm-kanban-card {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 10px 12px;
  margin-bottom: 8px;
  cursor: grab;
  transition: box-shadow 0.15s, transform 0.15s;
  border-left: 3px solid #a09fc4;
}
.rm-kanban-card:hover {
  box-shadow: 0 4px 14px rgba(90,80,180,0.14);
  transform: translateY(-1px);
}
.rm-kanban-card.rm-kanban-dragging { opacity: 0.5; cursor: grabbing; }

/* Priority left-border colors */
.rm-kanban-card.priority-critique { border-left-color: #dc2626; }
.rm-kanban-card.priority-haute    { border-left-color: #f59e0b; }
.rm-kanban-card.priority-moyenne  { border-left-color: #a09fc4; }
.rm-kanban-card.priority-basse    { border-left-color: #d1d5db; }

.rm-kanban-card-title {
  font-family: 'DM Sans', sans-serif;
  font-size: 13px; font-weight: 600;
  color: var(--text);
  margin-bottom: 6px;
  line-height: 1.35;
}
.rm-kanban-card-meta {
  display: flex; align-items: center; gap: 6px;
  flex-wrap: wrap;
  margin-bottom: 6px;
}
.rm-kanban-card-domain {
  font-size: 10px; font-weight: 600;
  padding: 1px 7px;
  border-radius: 4px;
  background: rgba(91,77,232,0.08);
  color: var(--accent);
  white-space: nowrap;
}
/* Domain colors for kanban cards */
.rm-kanban-card-domain.domain-infrastructure { background: rgba(91,77,232,0.10); color: #4338ca; }
.rm-kanban-card-domain.domain-securite       { background: rgba(220,38,38,0.08); color: #b91c1c; }
.rm-kanban-card-domain.domain-catalogue      { background: rgba(14,165,233,0.08); color: #0369a1; }
.rm-kanban-card-domain.domain-clients-b2b    { background: rgba(124,58,237,0.08); color: #6d28d9; }
.rm-kanban-card-domain.domain-front          { background: rgba(37,99,235,0.08); color: #1d4ed8; }
.rm-kanban-card-domain.domain-fournisseurs   { background: rgba(13,148,136,0.08); color: #0f766e; }
.rm-kanban-card-domain.domain-checkout       { background: rgba(217,119,6,0.08); color: #b45309; }
.rm-kanban-card-domain.domain-paiement       { background: rgba(5,150,105,0.08); color: #047857; }
.rm-kanban-card-domain.domain-migration      { background: rgba(99,102,241,0.08); color: #4f46e5; }
.rm-kanban-card-domain.domain-recette        { background: rgba(225,29,72,0.08); color: #be123c; }

.rm-kanban-card-footer {
  display: flex; align-items: center; justify-content: space-between;
}
.rm-kanban-card-priority {
  font-size: 10px; font-weight: 600;
  color: var(--muted);
}
.rm-kanban-card-contrib {
  font-size: 11px; font-weight: 500;
  color: var(--muted);
  display: flex; align-items: center; gap: 3px;
}
.rm-kanban-card-contrib::before {
  content: '';
  display: inline-block;
  width: 14px; height: 14px;
  border-radius: 50%;
  background: var(--accent-soft);
  flex-shrink: 0;
}

.rm-kanban-add-btn {
  display: flex; align-items: center; gap: 5px;
  width: 100%;
  padding: 8px 10px;
  margin-top: 4px;
  font-family: 'DM Sans', sans-serif;
  font-size: 12px; font-weight: 500;
  color: var(--muted);
  background: transparent;
  border: 1px dashed rgba(90,80,180,0.15);
  border-radius: 8px;
  cursor: pointer;
  transition: background 0.1s, color 0.1s, border-color 0.1s;
}
.rm-kanban-add-btn:hover {
  background: rgba(91,77,232,0.05);
  color: var(--accent);
  border-color: var(--accent);
}

/* ── Custom select in detail drawer ─────────── */
.rm-detail-field .custom-select { width: 100%; }
.rm-detail-field .cs-trigger { width: 100%; justify-content: space-between; border-radius: 8px; }
.rm-detail-field .cs-menu { width: 100%; }

/* ── Empty state ──────────────────────────────── */
.rm-empty {
  text-align: center;
  padding: 40px 20px;
  color: var(--muted);
  font-size: 14px;
}
