/* =============================================
   KANBAN MODULE — Minya App
   Premium Dark Theme
   ============================================= */

/* --- Avatars --- */
.kanban-avatar {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  font-weight: 700;
  color: #fff;
  flex-shrink: 0;
  overflow: hidden;
  vertical-align: middle;
  letter-spacing: -0.02em;
  border: 2px solid rgba(255, 255, 255, 0.1);
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.2);
}
.kanban-avatar.has-img {
  background: transparent;
  border-color: rgba(200, 119, 67, 0.3);
}
.kanban-avatar.has-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 50%;
  display: block;
}

/* --- Avatar button in subtabs --- */
.kanban-avatar-btn {
  margin-left: auto;
  padding: 5px 12px;
  border-radius: 8px;
  border: 1px solid rgba(58, 42, 30, 0.3);
  background: transparent;
  color: var(--text-muted);
  font-size: 1rem;
  cursor: pointer;
  transition: all 0.2s ease;
  display: flex;
  align-items: center;
  gap: 6px;
}
.kanban-avatar-btn:hover {
  color: var(--primary);
  border-color: rgba(200, 119, 67, 0.3);
  background: rgba(200, 119, 67, 0.06);
}

/* --- Avatar Editor Modal --- */
.avatar-editor {
  display: flex;
  gap: 24px;
  align-items: flex-start;
}
.avatar-preview-wrap {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
}
.avatar-preview {
  width: 120px;
  height: 120px;
  border-radius: 50%;
  overflow: hidden;
  border: 3px solid rgba(200, 119, 67, 0.3);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3), 0 0 0 4px rgba(200, 119, 67, 0.08);
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(38, 26, 18, 0.8);
}
.avatar-preview img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.avatar-preview-empty {
  font-size: 3rem;
  color: rgba(58, 42, 30, 0.4);
}
.avatar-preview-name {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-main);
}
.avatar-form {
  flex: 1;
  min-width: 0;
}

/* Position grid */
.avatar-pos-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 4px;
  width: 100px;
}
.avatar-pos-btn {
  width: 100%;
  aspect-ratio: 1;
  border-radius: 6px;
  border: 2px solid rgba(58, 42, 30, 0.3);
  background: rgba(38, 26, 18, 0.5);
  cursor: pointer;
  transition: all 0.15s ease;
  position: relative;
}
.avatar-pos-btn::after {
  content: '';
  position: absolute;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--text-muted);
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  opacity: 0.4;
}
.avatar-pos-btn:hover {
  border-color: rgba(200, 119, 67, 0.4);
  background: rgba(200, 119, 67, 0.08);
}
.avatar-pos-btn.active {
  border-color: var(--primary);
  background: rgba(200, 119, 67, 0.15);
}
.avatar-pos-btn.active::after {
  background: var(--primary);
  opacity: 1;
  width: 8px;
  height: 8px;
}

/* --- Animations --- */
@keyframes kanbanFadeIn {
  from {
    opacity: 0;
    transform: translateY(8px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes kanbanSlideIn {
  from {
    opacity: 0;
    transform: translateX(-12px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

@keyframes kanbanPulse {
  0%, 100% {
    box-shadow: 0 0 0 2px rgba(200, 119, 67, 0.3);
  }
  50% {
    box-shadow: 0 0 0 5px rgba(200, 119, 67, 0.12);
  }
}

@keyframes kanbanCheckmark {
  0% { transform: scale(0.8); }
  50% { transform: scale(1.15); }
  100% { transform: scale(1); }
}

@keyframes kanbanOverduePulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.6; }
}

/* =============================================
   LAYOUT
   ============================================= */

.kanban-wrapper {
  display: flex;
  height: 100%;
  gap: 0;
  background: var(--bg-body);
}

/* --- Sidebar --- */
.kanban-sidebar {
  width: 250px;
  min-width: 250px;
  background: linear-gradient(180deg, rgba(38, 26, 18, 0.85) 0%, rgba(20, 12, 7, 0.95) 100%);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-right: 1px solid rgba(58, 42, 30, 0.4);
  display: flex;
  flex-direction: column;
  overflow-y: auto;
  position: relative;
}

.kanban-sidebar::after {
  content: '';
  position: absolute;
  top: 0;
  right: 0;
  width: 1px;
  height: 100%;
  background: linear-gradient(180deg, transparent, rgba(200, 119, 67, 0.15), transparent);
  pointer-events: none;
}

.kanban-sidebar-header {
  padding: 16px 18px;
  border-bottom: 1px solid rgba(58, 42, 30, 0.3);
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: rgba(255, 255, 255, 0.02);
}

.kanban-sidebar-header h6 {
  margin: 0;
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 1.2px;
  color: var(--text-muted);
  font-weight: 600;
}

.kanban-sidebar-header button {
  background: rgba(200, 119, 67, 0.1);
  border: 1px solid rgba(200, 119, 67, 0.2);
  color: var(--primary);
  padding: 4px 8px;
  font-size: 0.75rem;
  cursor: pointer;
  border-radius: 6px;
  transition: all 0.2s ease;
}

.kanban-sidebar-header button:hover {
  background: rgba(200, 119, 67, 0.2);
  border-color: var(--primary);
  box-shadow: 0 0 12px rgba(200, 119, 67, 0.15);
}

.kanban-board-list {
  flex: 1;
  overflow-y: auto;
  padding: 8px 10px;
}

.kanban-board-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 9px 12px;
  border-radius: 8px;
  cursor: pointer;
  color: var(--text-main);
  font-size: 0.84rem;
  transition: all 0.2s ease;
  border: 1px solid transparent;
  margin-bottom: 2px;
  position: relative;
}

.kanban-board-item:hover {
  background: rgba(47, 29, 20, 0.5);
  box-shadow: 0 0 0 1px rgba(58, 42, 30, 0.3);
}

.kanban-board-item.active {
  background: rgba(200, 119, 67, 0.08);
  border-left: 3px solid var(--primary);
  padding-left: 9px;
  box-shadow: 0 0 16px rgba(200, 119, 67, 0.06);
}

.kanban-board-item .board-color-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  flex-shrink: 0;
  box-shadow: 0 0 6px rgba(255, 255, 255, 0.1);
}

/* Notification badge */
.kanban-notif-badge {
  background: linear-gradient(135deg, #c0455a, #a33a4c);
  color: #fff;
  font-size: 0.65rem;
  font-weight: 700;
  min-width: 18px;
  height: 18px;
  line-height: 18px;
  text-align: center;
  border-radius: 9px;
  padding: 0 5px;
  margin-left: auto;
  margin-right: 4px;
  flex-shrink: 0;
  box-shadow: 0 2px 6px rgba(184, 70, 92, 0.4);
  animation: kanbanPulse 2s ease-in-out infinite;
}

.kanban-board-item .board-name {
  flex: 1;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-weight: 500;
}

.kanban-board-item .board-actions {
  opacity: 0;
  display: flex;
  gap: 2px;
  transition: opacity 0.2s ease;
}

.kanban-board-item:hover .board-actions {
  opacity: 1;
}

.kanban-board-item .board-actions button {
  background: none;
  border: none;
  color: var(--text-muted);
  padding: 3px 5px;
  font-size: 0.75rem;
  cursor: pointer;
  border-radius: 5px;
  transition: all 0.15s ease;
}

.kanban-board-item .board-actions button:hover {
  color: var(--text-main);
  background: rgba(255, 255, 255, 0.08);
}

/* =============================================
   MAIN CONTENT
   ============================================= */

.kanban-main {
  flex: 1;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  min-width: 0;
}

.kanban-board-wrapper {
  flex: 1;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  min-height: 0;
}

/* =============================================
   TOOLBAR
   ============================================= */

.kanban-toolbar {
  padding: 14px 24px;
  border-bottom: 1px solid rgba(58, 42, 30, 0.3);
  display: flex;
  align-items: center;
  gap: 14px;
  flex-wrap: wrap;
  background: rgba(38, 26, 18, 0.6);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}

.kanban-toolbar .board-title {
  font-size: 1.2rem;
  font-weight: 700;
  color: var(--text-main);
  margin: 0;
  letter-spacing: -0.01em;
}

.kanban-toolbar .board-desc {
  font-size: 0.8rem;
  color: var(--text-muted);
  margin: 0;
  max-width: 300px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.kanban-board-stats {
  display: flex;
  gap: 8px;
  align-items: center;
}

.kanban-board-stats .stat-badge {
  font-size: 0.7rem;
  padding: 3px 10px;
  border-radius: 20px;
  background: rgba(47, 29, 20, 0.6);
  color: var(--text-muted);
  border: 1px solid rgba(58, 42, 30, 0.3);
  font-weight: 500;
  display: flex;
  align-items: center;
  gap: 4px;
}

.kanban-board-stats .stat-badge .stat-value {
  color: var(--text-main);
  font-weight: 600;
}

.kanban-view-tabs {
  display: flex;
  gap: 3px;
  margin-left: auto;
  background: rgba(20, 12, 7, 0.5);
  border-radius: 10px;
  padding: 3px;
  border: 1px solid rgba(58, 42, 30, 0.2);
}

.kanban-view-tab {
  padding: 5px 14px;
  border-radius: 8px;
  border: none;
  background: transparent;
  color: var(--text-muted);
  font-size: 0.8rem;
  cursor: pointer;
  transition: all 0.25s ease;
  display: flex;
  align-items: center;
  gap: 5px;
  font-weight: 500;
}

.kanban-view-tab i {
  font-size: 0.75rem;
}

.kanban-view-tab:hover {
  color: var(--text-main);
  background: rgba(255, 255, 255, 0.04);
}

.kanban-view-tab.active {
  background: var(--primary);
  color: #fff;
  box-shadow: 0 2px 10px rgba(200, 119, 67, 0.3), 0 0 20px rgba(200, 119, 67, 0.1);
}

/* =============================================
   FILTERS
   ============================================= */

.kanban-filters {
  padding: 10px 24px;
  border-bottom: 1px solid rgba(58, 42, 30, 0.25);
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  background: rgba(20, 12, 7, 0.4);
}

.kanban-filters label {
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: var(--text-muted);
  font-weight: 600;
}

.kanban-filters .form-select,
.kanban-filters .form-control {
  background-color: var(--bg-input);
  border: 1px solid rgba(58, 42, 30, 0.4);
  color: var(--text-main);
  font-size: 0.8rem;
  padding: 5px 10px;
  height: auto;
  max-width: 180px;
  border-radius: 7px;
  transition: all 0.2s ease;
}

.kanban-filters .form-select:focus,
.kanban-filters .form-control:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(200, 119, 67, 0.15), 0 0 12px rgba(200, 119, 67, 0.08);
  outline: none;
}

.kanban-filters .form-select option {
  background: var(--bg-card);
  color: var(--text-main);
}

/* =============================================
   BOARD VIEW (COLUMNS)
   ============================================= */

.kanban-board-view {
  flex: 1;
  display: flex;
  gap: 16px;
  padding: 20px 24px;
  overflow-x: auto;
  overflow-y: hidden;
  align-items: flex-start;
}

.kanban-column {
  min-width: 300px;
  max-width: 300px;
  width: 300px;
  background: linear-gradient(180deg, rgba(38, 26, 18, 0.9) 0%, rgba(38, 26, 18, 0.7) 100%);
  border-radius: 12px;
  border: 1px solid rgba(58, 42, 30, 0.3);
  display: flex;
  flex-direction: column;
  max-height: 100%;
  flex-shrink: 0;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15), 0 1px 3px rgba(0, 0, 0, 0.1);
  animation: kanbanSlideIn 0.3s ease forwards;
  transition: border-color 0.3s ease, box-shadow 0.3s ease;
}

.kanban-column.column-dragging {
  opacity: 0.4;
  transform: scale(0.95);
}

.kanban-column.column-drag-over {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(200, 119, 67, 0.3), 0 8px 24px rgba(200, 119, 67, 0.15);
}

.col-drag-handle {
  cursor: grab;
  opacity: 0.4;
  padding: 2px 4px;
  border-radius: 4px;
  transition: opacity 0.2s, background 0.2s;
  user-select: none;
  display: flex;
  align-items: center;
}
.col-drag-handle:hover {
  opacity: 1;
  background: rgba(255, 255, 255, 0.08);
}
.col-drag-handle:active,
.kanban-column.column-dragging .col-drag-handle {
  cursor: grabbing;
  opacity: 1;
}

.kanban-column.drag-over {
  border-color: var(--primary);
  box-shadow: 0 0 0 2px rgba(200, 119, 67, 0.25), 0 4px 20px rgba(200, 119, 67, 0.15);
  animation: kanbanPulse 1.5s ease-in-out infinite;
}

.kanban-column-header {
  padding: 12px 14px;
  display: flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
  position: relative;
  border-top: 3px solid transparent;
  border-radius: 12px 12px 0 0;
  background: rgba(255, 255, 255, 0.02);
}

.kanban-column-header .col-name {
  font-weight: 600;
  font-size: 0.85rem;
  color: var(--text-main);
  flex: 1;
  letter-spacing: 0.01em;
}

.kanban-column-header .col-count {
  font-size: 0.68rem;
  background: rgba(47, 29, 20, 0.7);
  color: var(--text-muted);
  padding: 2px 9px;
  border-radius: 20px;
  font-weight: 600;
  border: 1px solid rgba(58, 42, 30, 0.3);
}

.kanban-column-header .col-actions {
  display: flex;
  gap: 2px;
}

.kanban-column-header .col-actions button {
  background: none;
  border: none;
  color: var(--text-muted);
  padding: 3px 5px;
  font-size: 0.75rem;
  cursor: pointer;
  border-radius: 5px;
  transition: all 0.15s ease;
}

.kanban-column-header .col-actions button:hover {
  color: var(--text-main);
  background: rgba(255, 255, 255, 0.08);
}

.kanban-column-color {
  width: 4px;
  height: 20px;
  border-radius: 2px;
  flex-shrink: 0;
}

.kanban-column-body {
  flex: 1;
  overflow-y: auto;
  padding: 8px 10px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  min-height: 0;
}

.kanban-column-footer {
  padding: 8px 10px;
  border-top: 1px solid rgba(58, 42, 30, 0.2);
  flex-shrink: 0;
}

.kanban-quick-add {
  width: 100%;
  background: transparent;
  border: 1px dashed rgba(58, 42, 30, 0.4);
  border-radius: 8px;
  color: var(--text-muted);
  padding: 7px 12px;
  font-size: 0.8rem;
  cursor: pointer;
  text-align: left;
  transition: all 0.25s ease;
}

.kanban-quick-add:hover {
  border-color: var(--primary);
  color: var(--primary);
  background: rgba(200, 119, 67, 0.05);
  box-shadow: 0 0 12px rgba(200, 119, 67, 0.06);
}

.kanban-quick-add-input {
  width: 100%;
  background: var(--bg-input);
  border: 1px solid var(--primary);
  border-radius: 8px;
  color: var(--text-main);
  padding: 7px 12px;
  font-size: 0.8rem;
  outline: none;
  box-shadow: 0 0 0 3px rgba(200, 119, 67, 0.12);
  transition: box-shadow 0.2s ease;
}

.kanban-quick-add-input:focus {
  box-shadow: 0 0 0 3px rgba(200, 119, 67, 0.2), 0 0 16px rgba(200, 119, 67, 0.08);
}

/* --- Assign picker (on card create) --- */
.kanban-assign-picker {
  animation: kanbanFadeIn 0.2s ease;
}
.kanban-assign-list {
  display: flex;
  flex-direction: column;
  gap: 2px;
  max-height: 200px;
  overflow-y: auto;
}
.kanban-assign-option {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 7px 10px;
  border-radius: 8px;
  cursor: pointer;
  font-size: 0.8rem;
  color: var(--text-main);
  transition: background 0.15s ease;
}
.kanban-assign-option:hover {
  background: rgba(200, 119, 67, 0.12);
}

/* --- Add column button --- */
.kanban-add-column {
  min-width: 300px;
  width: 300px;
  flex-shrink: 0;
  display: flex;
  align-items: flex-start;
  justify-content: center;
  padding-top: 0;
}

.kanban-add-column button {
  background: rgba(38, 26, 18, 0.4);
  border: 1px dashed rgba(58, 42, 30, 0.4);
  border-radius: 12px;
  color: var(--text-muted);
  padding: 14px 20px;
  cursor: pointer;
  font-size: 0.85rem;
  width: 100%;
  transition: all 0.25s ease;
}

.kanban-add-column button:hover {
  border-color: var(--primary);
  color: var(--primary);
  background: rgba(200, 119, 67, 0.04);
  box-shadow: 0 0 20px rgba(200, 119, 67, 0.06);
}

/* =============================================
   CARDS
   ============================================= */

.kanban-card {
  background: linear-gradient(135deg, rgba(20, 12, 7, 0.9) 0%, rgba(38, 26, 18, 0.6) 100%);
  border: 1px solid rgba(58, 42, 30, 0.3);
  border-radius: 10px;
  padding: 0;
  cursor: pointer;
  transition: all 0.2s ease;
  position: relative;
  overflow: hidden;
  animation: kanbanFadeIn 0.25s ease forwards;
  flex-shrink: 0;
}

.kanban-card:hover {
  transform: translateY(-2px);
  border-color: rgba(200, 119, 67, 0.4);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.25), 0 2px 8px rgba(0, 0, 0, 0.15), 0 0 0 1px rgba(200, 119, 67, 0.1);
}

.kanban-card .kanban-card-content {
  padding: 10px 12px;
}

.kanban-card.dragging {
  opacity: 0.5;
  transform: rotate(2deg) scale(1.02);
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.4);
}

/* Card cover image (inside card-inner, below title) */
.kanban-card-cover {
  width: 100%;
  height: 140px;
  object-fit: cover;
  display: block;
  border-radius: 6px;
}

.kanban-card-cover-wrap {
  position: relative;
  overflow: hidden;
  border-radius: 6px;
  margin-top: 6px;
  margin-bottom: 4px;
}

.kanban-card-cover-wrap::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 30px;
  background: linear-gradient(transparent, rgba(20, 12, 7, 0.4));
  pointer-events: none;
}

/* Priority accent */
.kanban-card-priority {
  position: absolute;
  top: 0;
  left: 0;
  width: 3px;
  height: 100%;
  border-radius: 10px 0 0 10px;
  z-index: 1;
}

.kanban-card-priority.critical { background: linear-gradient(180deg, var(--danger), #a33a4c); }
.kanban-card-priority.high { background: linear-gradient(180deg, #cf7a35, var(--warning)); }
.kanban-card-priority.medium { background: linear-gradient(180deg, #facc15, #eab308); }
.kanban-card-priority.low { background: var(--border-color); }

/* Labels */
.kanban-card-labels {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  margin-bottom: 7px;
}

.kanban-label-badge {
  font-size: 0.62rem;
  padding: 2px 8px;
  border-radius: 20px;
  color: #fff;
  font-weight: 600;
  letter-spacing: 0.02em;
  opacity: 0.9;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.2);
}
#kc-labels .kanban-label-badge {
  cursor: pointer;
  transition: opacity 0.15s, transform 0.1s;
  user-select: none;
}
#kc-labels .kanban-label-badge:hover {
  transform: scale(1.05);
}
#kc-labels .kanban-label-badge.kanban-label-inactive {
  opacity: 0.25;
  filter: grayscale(0.5);
}

/* Card inner content */
.kanban-card-inner {
  padding: 10px 14px 28px 16px;
}

/* Card top row (done toggle + title) */
.kanban-card-top-row {
  display: flex;
  align-items: flex-start;
  gap: 8px;
}

.kanban-card-done-toggle {
  background: none;
  border: none;
  padding: 0;
  margin-top: 1px;
  cursor: pointer;
  color: rgba(162, 143, 127, 0.5);
  font-size: 0.95rem;
  flex-shrink: 0;
  transition: all 0.2s ease;
  line-height: 1;
}

.kanban-card-done-toggle:hover {
  color: var(--success);
  transform: scale(1.15);
}

.kanban-card-done-toggle.done {
  color: var(--success);
}

.kanban-card.done {
  opacity: 0.6;
}

.kanban-card.done .kanban-card-title {
  text-decoration: line-through;
  color: var(--text-muted);
}

/* Drag scroll cursor */
.kanban-board-view {
  cursor: grab;
}

.kanban-board-view.drag-scrolling {
  cursor: grabbing;
  user-select: none;
}

.kanban-board-view .kanban-card,
.kanban-board-view .kanban-column-footer button,
.kanban-board-view .kanban-add-column button {
  cursor: pointer;
}

/* Card title */
.kanban-card-title {
  font-size: 0.85rem;
  font-weight: 500;
  color: var(--text-main);
  margin-bottom: 8px;
  line-height: 1.4;
}

/* Card meta */
.kanban-card-meta {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  font-size: 0.7rem;
  color: var(--text-muted);
}

.kanban-card-meta .meta-item {
  display: flex;
  align-items: center;
  gap: 3px;
}

.kanban-card-meta .meta-item i {
  font-size: 0.65rem;
  opacity: 0.7;
}

.kanban-card-meta .due-overdue {
  color: var(--danger);
  font-weight: 600;
  animation: kanbanOverduePulse 2s ease-in-out infinite;
}

.kanban-card-meta .due-soon {
  color: var(--warning);
  font-weight: 500;
}

/* Assignee avatar */
.kanban-card-assignee-avatar {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.65rem;
  font-weight: 700;
  color: #fff;
  position: absolute;
  bottom: 10px;
  right: 10px;
  border: 2px solid rgba(20, 12, 7, 0.8);
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.2);
}

/* Checklist bar */
.kanban-card-checklist-bar {
  width: 44px;
  height: 4px;
  background: rgba(47, 29, 20, 0.6);
  border-radius: 2px;
  overflow: hidden;
}

.kanban-card-checklist-bar .bar-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--success), #6bb383);
  border-radius: 2px;
  transition: width 0.4s ease;
}

/* Card hover actions */
.kanban-card-actions {
  position: absolute;
  top: 6px;
  right: 6px;
  display: flex;
  gap: 3px;
  opacity: 0;
  transition: opacity 0.2s ease;
  z-index: 2;
}

.kanban-card:hover .kanban-card-actions {
  opacity: 1;
}

.kanban-card-actions button {
  background: rgba(20, 12, 7, 0.75);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  border: 1px solid rgba(58, 42, 30, 0.3);
  color: var(--text-muted);
  padding: 3px 6px;
  font-size: 0.7rem;
  cursor: pointer;
  border-radius: 6px;
  transition: all 0.15s ease;
}

.kanban-card-actions button:hover {
  color: var(--text-main);
  background: rgba(38, 26, 18, 0.9);
  border-color: var(--primary);
}

.kanban-card-actions button.delete-btn:hover {
  color: var(--danger);
  border-color: var(--danger);
}

/* =============================================
   AVATAR COLORS (data-color system)
   ============================================= */

[data-color="0"] { background: linear-gradient(135deg, #c87743, #9c5a2c); }
[data-color="1"] { background: linear-gradient(135deg, #a94c60, #8e3d50); }
[data-color="2"] { background: linear-gradient(135deg, #4f9d69, #059669); }
[data-color="3"] { background: linear-gradient(135deg, #cf7a35, #b4682d); }
[data-color="4"] { background: linear-gradient(135deg, #ec4899, #db2777); }
[data-color="5"] { background: linear-gradient(135deg, #14b8a6, #0d9488); }
[data-color="6"] { background: linear-gradient(135deg, #a94c60, #4f46e5); }
[data-color="7"] { background: linear-gradient(135deg, #f43f5e, #e11d48); }

/* =============================================
   CARD DETAIL MODAL
   ============================================= */

.kanban-modal-body {
  display: flex;
  gap: 24px;
}

.kanban-modal-main {
  flex: 1;
  min-width: 0;
}

.kanban-modal-sidebar {
  width: 220px;
  flex-shrink: 0;
}

.kanban-modal-sidebar .sidebar-section {
  margin-bottom: 20px;
  padding-bottom: 16px;
  border-bottom: 1px solid rgba(58, 42, 30, 0.2);
}

.kanban-modal-sidebar .sidebar-section:last-child {
  border-bottom: none;
}

.kanban-modal-sidebar .sidebar-section label {
  font-size: 0.68rem;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: var(--text-muted);
  margin-bottom: 6px;
  display: block;
  font-weight: 600;
}

.kanban-modal-sidebar .sidebar-section select,
.kanban-modal-sidebar .sidebar-section input {
  background-color: var(--bg-input);
  border: 1px solid rgba(58, 42, 30, 0.4);
  color: var(--text-main);
  border-radius: 7px;
  padding: 6px 10px;
  font-size: 0.82rem;
  width: 100%;
  transition: all 0.2s ease;
}

.kanban-modal-sidebar .sidebar-section select:focus,
.kanban-modal-sidebar .sidebar-section input:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(200, 119, 67, 0.12);
  outline: none;
}

/* Cover preview in modal */
.kanban-modal-cover-preview {
  width: 100%;
  height: 200px;
  border-radius: 10px;
  overflow: hidden;
  position: relative;
  margin-bottom: 16px;
  background: var(--bg-input);
}

.kanban-modal-cover-preview img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.kanban-modal-cover-preview img.kanban-cover-clickable {
  cursor: zoom-in;
  transition: filter 0.2s ease;
}
.kanban-modal-cover-preview img.kanban-cover-clickable:hover {
  filter: brightness(1.1);
}

.kanban-modal-cover-preview .cover-actions {
  position: absolute;
  bottom: 10px;
  right: 10px;
  display: flex;
  gap: 6px;
  opacity: 0;
  transition: opacity 0.2s ease;
}

.kanban-modal-cover-preview:hover .cover-actions {
  opacity: 1;
}

.kanban-modal-cover-preview .cover-actions button {
  background: rgba(20, 12, 7, 0.8);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  border: 1px solid rgba(58, 42, 30, 0.4);
  color: var(--text-main);
  padding: 5px 12px;
  font-size: 0.75rem;
  border-radius: 6px;
  cursor: pointer;
  transition: all 0.15s ease;
}

.kanban-modal-cover-preview .cover-actions button:hover {
  border-color: var(--primary);
  background: rgba(38, 26, 18, 0.9);
}

/* Description preview (markdown) */
.kanban-desc-preview {
  font-size: 0.85rem;
  color: var(--text-main);
  line-height: 1.6;
  min-height: 60px;
  padding: 12px 14px;
  background: rgba(47, 29, 20, 0.25);
  border-radius: 8px;
  cursor: pointer;
  border: 1px solid transparent;
  transition: all 0.2s ease;
}

.kanban-desc-preview:hover {
  border-color: rgba(58, 42, 30, 0.3);
  background: rgba(47, 29, 20, 0.35);
}

.kanban-desc-preview:empty::after {
  content: "Cliquer pour ajouter une description...";
  color: var(--text-muted);
  font-style: italic;
}

.kanban-desc-preview strong { font-weight: 700; }
.kanban-desc-preview em { font-style: italic; color: rgba(244, 235, 225, 0.8); }
.kanban-desc-preview code {
  background: rgba(0, 0, 0, 0.35);
  padding: 2px 6px;
  border-radius: 4px;
  font-size: 0.8em;
  font-family: 'JetBrains Mono', 'Fira Code', monospace;
  color: #e9ecef;
}

.kanban-desc-preview a {
  color: var(--primary);
  text-decoration: none;
}

.kanban-desc-preview a:hover {
  text-decoration: underline;
}

/* Checklist */
.kanban-checklist-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 6px 8px;
  border-radius: 6px;
  transition: background 0.15s ease;
  margin-bottom: 2px;
}

.kanban-checklist-item:hover {
  background: rgba(47, 29, 20, 0.25);
}

/* Custom checkbox */
.kanban-checklist-item input[type="checkbox"] {
  -webkit-appearance: none;
  appearance: none;
  width: 18px;
  height: 18px;
  border: 2px solid rgba(58, 42, 30, 0.5);
  border-radius: 5px;
  background: transparent;
  cursor: pointer;
  flex-shrink: 0;
  position: relative;
  transition: all 0.2s ease;
}

.kanban-checklist-item input[type="checkbox"]:hover {
  border-color: var(--primary);
}

.kanban-checklist-item input[type="checkbox"]:checked {
  background: var(--primary);
  border-color: var(--primary);
  animation: kanbanCheckmark 0.25s ease;
}

.kanban-checklist-item input[type="checkbox"]:checked::after {
  content: '';
  position: absolute;
  top: 2px;
  left: 5px;
  width: 4px;
  height: 8px;
  border: solid #fff;
  border-width: 0 2px 2px 0;
  transform: rotate(45deg);
}

.kanban-checklist-item .check-text {
  flex: 1;
  font-size: 0.85rem;
  color: var(--text-main);
  transition: all 0.2s ease;
}

.kanban-checklist-item .check-text.checked {
  text-decoration: line-through;
  color: var(--text-muted);
  opacity: 0.6;
}

.kanban-checklist-item .check-delete {
  opacity: 0;
  background: none;
  border: none;
  color: var(--text-muted);
  cursor: pointer;
  padding: 2px 4px;
  border-radius: 4px;
  font-size: 0.7rem;
  transition: all 0.15s ease;
}

.kanban-checklist-item:hover .check-delete {
  opacity: 1;
}

.kanban-checklist-item .check-delete:hover {
  color: var(--danger);
}

.kanban-checklist-progress {
  height: 6px;
  background: rgba(47, 29, 20, 0.4);
  border-radius: 3px;
  margin: 8px 0 14px;
  overflow: hidden;
}

.kanban-checklist-progress .progress-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--primary), var(--success));
  border-radius: 3px;
  transition: width 0.4s ease;
}

/* Comments */
.kanban-comment {
  display: flex;
  gap: 12px;
  padding: 14px 0;
  border-bottom: 1px solid rgba(58, 42, 30, 0.15);
}

.kanban-comment:last-child {
  border-bottom: none;
}

.kanban-comment-avatar {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.8rem;
  font-weight: 700;
  flex-shrink: 0;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
}

.kanban-comment-body {
  flex: 1;
  min-width: 0;
}

.kanban-comment-header {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 5px;
}

.kanban-comment-header .author {
  font-weight: 600;
  font-size: 0.82rem;
  color: var(--text-main);
}

.kanban-comment-header .date {
  font-size: 0.7rem;
  color: var(--text-muted);
}

.kanban-comment-content {
  font-size: 0.85rem;
  color: var(--text-main);
  line-height: 1.5;
  opacity: 0.9;
}

/* Links */
.kanban-link-item {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 6px 8px;
  font-size: 0.82rem;
  border-radius: 6px;
  transition: background 0.15s ease;
  margin-bottom: 2px;
}

.kanban-link-item:hover {
  background: rgba(47, 29, 20, 0.25);
}

.kanban-link-item i {
  color: var(--text-muted);
  font-size: 0.75rem;
  flex-shrink: 0;
}

.kanban-link-item a {
  color: var(--primary);
  text-decoration: none;
  flex: 1;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  transition: color 0.15s ease;
}

.kanban-link-item a:hover {
  color: var(--primary-hover);
  text-decoration: underline;
}

.kanban-link-item .link-delete {
  opacity: 0;
  background: none;
  border: none;
  color: var(--text-muted);
  cursor: pointer;
  padding: 2px 4px;
  font-size: 0.7rem;
  transition: all 0.15s ease;
}

.kanban-link-item:hover .link-delete {
  opacity: 1;
}

.kanban-link-item .link-delete:hover {
  color: var(--danger);
}

/* =============================================
   ASSIGNEE DROPDOWN
   ============================================= */

.kanban-assignee-dropdown {
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  background: var(--bg-card);
  border: 1px solid rgba(58, 42, 30, 0.4);
  border-radius: 10px;
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.4), 0 4px 12px rgba(0, 0, 0, 0.2);
  z-index: 100;
  max-height: 220px;
  overflow-y: auto;
  padding: 4px;
  animation: kanbanFadeIn 0.15s ease;
}

.kanban-assignee-option {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 10px;
  border-radius: 7px;
  cursor: pointer;
  transition: background 0.15s ease;
  font-size: 0.82rem;
  color: var(--text-main);
}

.kanban-assignee-option:hover {
  background: rgba(200, 119, 67, 0.1);
}

.kanban-assignee-option .avatar {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.7rem;
  font-weight: 700;
  color: #fff;
  flex-shrink: 0;
}

.kanban-assignee-dropdown-wrap {
  position: relative;
}

.kanban-assignee-selected {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 5px 10px;
  background: rgba(47, 29, 20, 0.3);
  border-radius: 7px;
  font-size: 0.82rem;
  color: var(--text-main);
  cursor: pointer;
  transition: background 0.15s ease;
}

.kanban-assignee-selected:hover {
  background: rgba(47, 29, 20, 0.5);
}

.kanban-assignee-selected .avatar {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.65rem;
  font-weight: 700;
  color: #fff;
}

/* =============================================
   LIST VIEW
   ============================================= */

.kanban-list-view {
  flex: 1;
  overflow: auto;
  padding: 20px 24px;
}

.kanban-list-table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
}

.kanban-list-table th {
  position: sticky;
  top: 0;
  background: var(--bg-card);
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.8px;
  color: var(--text-muted);
  padding: 10px 14px;
  border-bottom: 1px solid var(--border-color);
  cursor: pointer;
  user-select: none;
  white-space: nowrap;
  font-weight: 600;
  z-index: 2;
  transition: color 0.15s ease;
}

.kanban-list-table th:hover {
  color: var(--text-main);
}

.kanban-list-table th .sort-icon {
  margin-left: 4px;
  font-size: 0.65rem;
  opacity: 0.5;
}

.kanban-list-table td {
  padding: 10px 14px;
  border-bottom: 1px solid rgba(58, 42, 30, 0.15);
  font-size: 0.83rem;
  color: var(--text-main);
  vertical-align: middle;
}

.kanban-list-table tr {
  cursor: pointer;
  transition: all 0.15s ease;
}

.kanban-list-table tbody tr:hover {
  background: rgba(200, 119, 67, 0.04);
}

.kanban-list-table tbody tr:hover td {
  border-bottom-color: rgba(200, 119, 67, 0.1);
}

/* Cover thumbnail in list */
.kanban-list-table .cover-thumb {
  width: 32px;
  height: 32px;
  border-radius: 5px;
  object-fit: cover;
  vertical-align: middle;
}

.kanban-priority-badge {
  font-size: 0.7rem;
  padding: 3px 10px;
  border-radius: 20px;
  font-weight: 600;
  display: inline-block;
}

.kanban-priority-badge.critical { background: rgba(184, 70, 92, 0.15); color: var(--danger); border: 1px solid rgba(184, 70, 92, 0.2); }
.kanban-priority-badge.high { background: rgba(154, 138, 78, 0.15); color: var(--warning); border: 1px solid rgba(154, 138, 78, 0.2); }
.kanban-priority-badge.medium { background: rgba(154, 138, 78, 0.15); color: #eab308; border: 1px solid rgba(154, 138, 78, 0.2); }
.kanban-priority-badge.low { background: rgba(162, 143, 127, 0.15); color: var(--text-muted); border: 1px solid rgba(162, 143, 127, 0.15); }

/* =============================================
   CALENDAR VIEW
   ============================================= */

.kanban-calendar-view {
  flex: 1;
  overflow: auto;
  padding: 20px 24px;
}

.kanban-calendar-nav {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 20px;
}

.kanban-calendar-nav button {
  background: rgba(47, 29, 20, 0.4);
  border: 1px solid rgba(58, 42, 30, 0.3);
  color: var(--text-main);
  padding: 6px 14px;
  border-radius: 8px;
  cursor: pointer;
  font-size: 0.85rem;
  transition: all 0.2s ease;
}

.kanban-calendar-nav button:hover {
  border-color: var(--primary);
  background: rgba(200, 119, 67, 0.08);
}

.kanban-calendar-nav .month-label {
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--text-main);
  min-width: 180px;
  text-align: center;
  letter-spacing: -0.01em;
}

.kanban-calendar-grid {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 1px;
  background: rgba(58, 42, 30, 0.2);
  border: 1px solid rgba(58, 42, 30, 0.2);
  border-radius: 12px;
  overflow: hidden;
}

.kanban-calendar-day-header {
  background: rgba(38, 26, 18, 0.8);
  padding: 8px;
  text-align: center;
  font-size: 0.72rem;
  font-weight: 600;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.kanban-calendar-day {
  background: var(--bg-body);
  min-height: 110px;
  padding: 6px;
  vertical-align: top;
  transition: background 0.15s ease;
}

.kanban-calendar-day:hover {
  background: rgba(38, 26, 18, 0.3);
}

.kanban-calendar-day.other-month {
  opacity: 0.25;
}

.kanban-calendar-day.today {
  background: rgba(200, 119, 67, 0.06);
  box-shadow: inset 0 0 0 1px rgba(200, 119, 67, 0.15);
}

.kanban-calendar-day .day-number {
  font-size: 0.75rem;
  color: var(--text-muted);
  padding: 2px 6px;
  margin-bottom: 4px;
  font-weight: 500;
}

.kanban-calendar-day.today .day-number {
  color: var(--primary);
  font-weight: 700;
  background: rgba(200, 119, 67, 0.12);
  border-radius: 12px;
  display: inline-block;
}

.kanban-calendar-card {
  font-size: 0.68rem;
  padding: 3px 7px;
  border-radius: 5px;
  margin-bottom: 3px;
  cursor: pointer;
  color: #fff;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  transition: all 0.15s ease;
  font-weight: 500;
}

.kanban-calendar-card:hover {
  opacity: 0.85;
  transform: translateX(1px);
}

.kanban-calendar-card.critical { background: linear-gradient(90deg, var(--danger), #a33a4c); }
.kanban-calendar-card.high { background: linear-gradient(90deg, #cf7a35, var(--warning)); }
.kanban-calendar-card.medium { background: linear-gradient(90deg, var(--primary), #9c5a2c); }
.kanban-calendar-card.low { background: rgba(58, 42, 30, 0.6); }

/* =============================================
   PUSH MANAGER
   ============================================= */

/* =============================================
   PUSH MANAGER — Complete Redesign
   ============================================= */

.push-manager {
  height: calc(100% - 42px);
  overflow: auto;
  padding: 16px 20px;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

/* --- Stats Row --- */
.push-stats-row {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 12px;
  flex-shrink: 0;
}

.push-stat-card {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 16px 18px;
  border-radius: 14px;
  border: 1px solid rgba(58, 42, 30, 0.2);
  background: linear-gradient(135deg, rgba(38, 26, 18, 0.7) 0%, rgba(38, 26, 18, 0.4) 100%);
  transition: all 0.3s ease;
}
.push-stat-card:hover { transform: translateY(-2px); box-shadow: 0 6px 20px rgba(0,0,0,0.2); }

.push-stat-icon {
  width: 42px; height: 42px;
  border-radius: 12px;
  display: flex; align-items: center; justify-content: center;
  font-size: 1.15rem;
}
.stat-pending .push-stat-icon { background: rgba(154, 138, 78, 0.15); color: #d9963c; }
.stat-approved .push-stat-icon { background: rgba(200, 119, 67, 0.15); color: #c87743; }
.stat-pushed .push-stat-icon { background: rgba(91, 155, 112, 0.15); color: #4f9d69; }
.stat-critical .push-stat-icon { background: rgba(184, 70, 92, 0.15); color: #c0455a; }

.push-stat-info { display: flex; flex-direction: column; }
.push-stat-value { font-size: 1.5rem; font-weight: 700; color: var(--text-main); line-height: 1; }
.push-stat-label { font-size: 0.72rem; color: var(--text-muted); margin-top: 3px; }

/* --- Main Layout --- */
.push-layout {
  display: grid;
  grid-template-columns: 340px 1fr;
  gap: 16px;
  flex: 1;
  min-height: 0;
}

/* --- Table Sidebar --- */
.push-tables-sidebar {
  display: flex;
  flex-direction: column;
  background: linear-gradient(180deg, rgba(38, 26, 18, 0.8) 0%, rgba(38, 26, 18, 0.5) 100%);
  border: 1px solid rgba(58, 42, 30, 0.25);
  border-radius: 14px;
  overflow: hidden;
}

.push-tables-header {
  display: flex; align-items: center; justify-content: space-between;
  padding: 12px 14px;
  border-bottom: 1px solid rgba(58, 42, 30, 0.2);
}
.push-tables-header h6 { margin: 0; font-size: 0.85rem; font-weight: 700; color: var(--text-main); }

.push-table-filter-btns { display: flex; gap: 4px; }
.push-diff-filter {
  padding: 3px 10px; border-radius: 6px;
  border: 1px solid rgba(58, 42, 30, 0.3);
  background: transparent; color: var(--text-muted);
  font-size: 0.7rem; cursor: pointer;
  transition: all 0.2s ease;
}
.push-diff-filter:hover { color: var(--text-main); border-color: rgba(58, 42, 30, 0.5); }
.push-diff-filter.active { background: var(--primary); color: #fff; border-color: var(--primary); }

.push-table-search {
  margin: 8px 10px;
  padding: 7px 12px;
  border-radius: 8px;
  border: 1px solid rgba(58, 42, 30, 0.3);
  background: rgba(20, 12, 7, 0.5);
  color: var(--text-main);
  font-size: 0.8rem;
  outline: none;
  transition: border-color 0.2s;
}
.push-table-search:focus { border-color: var(--primary); }
.push-table-search::placeholder { color: var(--text-muted); }

.push-db-tabs {
  display: flex; gap: 4px;
  padding: 0 10px 8px;
}
.push-db-tab {
  flex: 1;
  padding: 6px 8px; border-radius: 8px;
  border: 1px solid rgba(58, 42, 30, 0.2);
  background: transparent; color: var(--text-muted);
  font-size: 0.75rem; cursor: pointer;
  display: flex; align-items: center; justify-content: center; gap: 6px;
  transition: all 0.2s ease;
}
.push-db-tab:hover { color: var(--text-main); background: rgba(255,255,255,0.03); }
.push-db-tab.active { background: rgba(200, 119, 67,0.12); color: var(--primary); border-color: rgba(200, 119, 67,0.25); }
.push-db-count {
  font-size: 0.65rem; padding: 1px 6px;
  border-radius: 10px; background: rgba(58, 42, 30,0.3);
}
.push-db-tab.active .push-db-count { background: rgba(200, 119, 67,0.25); }

.push-table-list-wrap {
  flex: 1; overflow-y: auto;
  padding: 4px 6px;
}

.push-table-list { display: flex; flex-direction: column; gap: 1px; }

.kanban-push-table-row {
  display: grid;
  grid-template-columns: 20px 1fr auto;
  align-items: center;
  gap: 8px;
  padding: 7px 10px;
  border-radius: 8px;
  font-size: 0.78rem;
  transition: background 0.15s ease;
  cursor: pointer;
}
.kanban-push-table-row:hover { background: rgba(47, 29, 20, 0.35); }
.kanban-push-table-row.selected { background: rgba(200, 119, 67,0.08); }

.kanban-push-table-row input[type="checkbox"] {
  -webkit-appearance: none; appearance: none;
  width: 15px; height: 15px;
  border: 2px solid rgba(58, 42, 30, 0.5);
  border-radius: 4px; background: transparent;
  cursor: pointer; position: relative;
  transition: all 0.2s ease; flex-shrink: 0;
}
.kanban-push-table-row input[type="checkbox"]:checked { background: var(--primary); border-color: var(--primary); }
.kanban-push-table-row input[type="checkbox"]:checked::after {
  content: ''; position: absolute; top: 1px; left: 4px;
  width: 4px; height: 7px;
  border: solid #fff; border-width: 0 2px 2px 0;
  transform: rotate(45deg);
}

.kanban-push-table-row .table-name { color: var(--text-main); font-weight: 500; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.kanban-push-table-row .table-rows {
  font-size: 0.65rem; color: var(--text-muted);
  background: rgba(47, 29, 20, 0.4);
  padding: 2px 8px; border-radius: 10px;
  white-space: nowrap;
}

.push-table-diff {
  font-size: 0.65rem; font-weight: 600;
  padding: 2px 8px; border-radius: 10px;
  white-space: nowrap;
}
.push-table-diff.positive { background: rgba(91, 155, 112,0.12); color: #4f9d69; }
.push-table-diff.negative { background: rgba(184, 70, 92,0.12); color: #c0455a; }
.push-table-diff.neutral { background: rgba(58, 42, 30,0.2); color: var(--text-muted); }
.push-table-diff.new-table { background: rgba(192, 95, 116,0.12); color: #a855f7; }

/* --- Selected Bar --- */
.push-selected-bar {
  border-top: 1px solid rgba(58, 42, 30,0.2);
  padding: 10px 12px;
  display: flex; flex-direction: column; gap: 8px;
  background: rgba(20, 12, 7,0.3);
}
.push-selected-count { font-size: 0.75rem; color: var(--text-muted); font-weight: 600; }
.push-selected-badges { display: flex; flex-wrap: wrap; gap: 4px; max-height: 52px; overflow-y: auto; }
.push-selected-badges .badge {
  font-size: 0.65rem; padding: 3px 8px;
  border-radius: 6px; background: rgba(200, 119, 67,0.15);
  color: var(--primary); border: 1px solid rgba(200, 119, 67,0.2);
  display: flex; align-items: center; gap: 4px;
}
.push-selected-badges .badge .bi-x { cursor: pointer; opacity: 0.7; transition: opacity 0.15s; }
.push-selected-badges .badge .bi-x:hover { opacity: 1; }

.push-create-btn {
  padding: 8px 16px; border-radius: 10px;
  border: none; cursor: pointer;
  background: linear-gradient(135deg, #c87743 0%, #9c5a2c 100%);
  color: #fff; font-size: 0.8rem; font-weight: 600;
  display: flex; align-items: center; justify-content: center; gap: 8px;
  transition: all 0.25s ease;
  box-shadow: 0 2px 10px rgba(200, 119, 67,0.25);
}
.push-create-btn:hover:not(:disabled) { transform: translateY(-1px); box-shadow: 0 4px 16px rgba(200, 119, 67,0.35); }
.push-create-btn:disabled { opacity: 0.4; cursor: not-allowed; }

/* --- Pipeline View --- */
.push-pipeline {
  display: flex; flex-direction: column;
  background: linear-gradient(180deg, rgba(38, 26, 18, 0.6) 0%, rgba(38, 26, 18, 0.3) 100%);
  border: 1px solid rgba(58, 42, 30, 0.25);
  border-radius: 14px;
  overflow: hidden;
}

.push-pipeline-header {
  display: flex; align-items: center; justify-content: space-between;
  padding: 12px 16px;
  border-bottom: 1px solid rgba(58, 42, 30, 0.2);
}
.push-pipeline-header h6 { margin: 0; font-size: 0.85rem; font-weight: 700; color: var(--text-main); }

.push-pipeline-filters { display: flex; gap: 8px; align-items: center; }
.push-filter-select {
  padding: 5px 10px; border-radius: 7px;
  border: 1px solid rgba(58, 42, 30, 0.3);
  background-color: rgba(20, 12, 7, 0.5);
  color: var(--text-main); font-size: 0.72rem;
  outline: none; cursor: pointer;
}
.push-filter-search {
  padding: 5px 10px; border-radius: 7px;
  border: 1px solid rgba(58, 42, 30, 0.3);
  background: rgba(20, 12, 7, 0.5);
  color: var(--text-main); font-size: 0.72rem;
  outline: none; width: 140px;
  transition: border-color 0.2s;
}
.push-filter-search:focus { border-color: var(--primary); }
.push-filter-search::placeholder { color: var(--text-muted); }

.push-pipeline-tabs {
  display: flex; gap: 4px;
  padding: 8px 12px;
  border-bottom: 1px solid rgba(58, 42, 30, 0.15);
}
.push-pipeline-tab {
  padding: 5px 14px; border-radius: 7px;
  border: none; background: transparent;
  color: var(--text-muted); font-size: 0.75rem;
  cursor: pointer; transition: all 0.2s;
}
.push-pipeline-tab:hover { color: var(--text-main); background: rgba(255,255,255,0.03); }
.push-pipeline-tab.active { background: rgba(200, 119, 67,0.12); color: var(--primary); }

.push-pipeline-content {
  flex: 1; overflow: auto; padding: 12px;
}

/* Pipeline columns */
.push-pipeline-columns {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 12px;
  height: 100%;
}

.push-pipeline-col {
  display: flex; flex-direction: column;
  background: rgba(20, 12, 7, 0.3);
  border-radius: 10px;
  overflow: hidden;
}

.push-pipeline-col-header {
  padding: 10px 12px;
  font-size: 0.75rem; font-weight: 700;
  display: flex; align-items: center; gap: 8px;
  border-bottom: 2px solid transparent;
}
.push-pipeline-col-header .col-dot {
  width: 8px; height: 8px;
  border-radius: 50%;
}
.push-pipeline-col-header .col-count {
  margin-left: auto;
  font-size: 0.65rem; padding: 1px 8px;
  border-radius: 10px; background: rgba(58, 42, 30,0.3);
}

.push-pcol-pending .push-pipeline-col-header { border-color: #d9963c; color: #d9963c; }
.push-pcol-pending .col-dot { background: #d9963c; }
.push-pcol-approved .push-pipeline-col-header { border-color: #c87743; color: #c87743; }
.push-pcol-approved .col-dot { background: #c87743; }
.push-pcol-pushed .push-pipeline-col-header { border-color: #4f9d69; color: #4f9d69; }
.push-pcol-pushed .col-dot { background: #4f9d69; }
.push-pcol-other .push-pipeline-col-header { border-color: #8b7461; color: #8b7461; }
.push-pcol-other .col-dot { background: #8b7461; }

.push-pipeline-col-body {
  flex: 1; overflow-y: auto;
  padding: 8px;
  display: flex; flex-direction: column; gap: 8px;
}

/* Push request cards */
.kanban-push-request-card {
  background: linear-gradient(135deg, rgba(38, 26, 18, 0.8) 0%, rgba(38, 26, 18, 0.5) 100%);
  border: 1px solid rgba(58, 42, 30, 0.25);
  border-radius: 10px;
  padding: 12px 14px;
  cursor: pointer;
  transition: all 0.2s ease;
}
.kanban-push-request-card:hover {
  border-color: rgba(200, 119, 67, 0.4);
  transform: translateY(-1px);
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.25);
}

.push-card-header { display: flex; align-items: center; gap: 6px; margin-bottom: 6px; }
.push-card-id { font-size: 0.68rem; color: var(--text-muted); font-weight: 600; }
.push-card-priority {
  width: 6px; height: 6px; border-radius: 50%; flex-shrink: 0;
}
.push-card-priority.critical { background: #c0455a; box-shadow: 0 0 6px rgba(184, 70, 92,0.5); }
.push-card-priority.high { background: #d9963c; }
.push-card-priority.normal { background: #c87743; }
.push-card-priority.low { background: #8b7461; }

.push-card-title { font-size: 0.8rem; font-weight: 600; color: var(--text-main); margin-bottom: 6px; line-height: 1.3; }
.push-card-meta {
  display: flex; align-items: center; gap: 8px;
  font-size: 0.68rem; color: var(--text-muted);
}
.push-card-tables {
  display: flex; flex-wrap: wrap; gap: 3px;
  margin-top: 6px;
}
.push-card-tables .table-tag {
  font-size: 0.6rem; padding: 1px 6px;
  border-radius: 4px; background: rgba(58, 42, 30,0.3);
  color: var(--text-muted);
  display: inline-flex; align-items: center; gap: 0;
}
.table-tag-db {
  font-weight: 700;
  color: var(--primary);
  margin-right: 3px;
  font-size: 0.55rem;
  text-transform: uppercase;
  letter-spacing: 0.02em;
}
.table-tag-db::after {
  content: ".";
  color: var(--text-muted);
  opacity: 0.5;
}

/* Status & Type badges */
.kanban-push-status {
  font-size: 0.65rem; padding: 3px 10px;
  border-radius: 20px; font-weight: 600;
  display: inline-flex; align-items: center; gap: 4px;
  letter-spacing: 0.02em;
}
.kanban-push-status.pending { background: rgba(154, 138, 78,0.12); color: #d9963c; border: 1px solid rgba(154, 138, 78,0.2); }
.kanban-push-status.approved { background: rgba(200, 119, 67,0.12); color: #c87743; border: 1px solid rgba(200, 119, 67,0.2); }
.kanban-push-status.pushed { background: rgba(91, 155, 112,0.12); color: #4f9d69; border: 1px solid rgba(91, 155, 112,0.2); }
.kanban-push-status.cancelled { background: rgba(162, 143, 127,0.12); color: var(--text-muted); border: 1px solid rgba(162, 143, 127,0.15); }
.kanban-push-status.rejected { background: rgba(184, 70, 92,0.12); color: #c0455a; border: 1px solid rgba(184, 70, 92,0.2); }
.kanban-push-status.comment { background: rgba(192, 95, 116,0.12); color: #a855f7; border: 1px solid rgba(192, 95, 116,0.2); }
.kanban-push-status.created { background: rgba(122, 74, 42,0.12); color: #a94c60; border: 1px solid rgba(122, 74, 42,0.2); }

.kanban-push-type {
  font-size: 0.65rem; padding: 3px 10px;
  border-radius: 20px; font-weight: 600;
  display: inline-block;
}
.kanban-push-type.reboot { background: rgba(184, 70, 92,0.1); color: #c0455a; border: 1px solid rgba(184, 70, 92,0.15); }
.kanban-push-type.hotpush { background: rgba(91, 155, 112,0.1); color: #4f9d69; border: 1px solid rgba(91, 155, 112,0.15); }
.kanban-push-type.manual { background: rgba(162, 143, 127,0.1); color: var(--text-muted); border: 1px solid rgba(162, 143, 127,0.12); }

/* --- List view in pipeline --- */
.push-list-view { display: flex; flex-direction: column; gap: 6px; }
.push-list-item {
  display: grid;
  grid-template-columns: 50px 2fr 100px 100px 100px 80px 100px;
  align-items: center; gap: 10px;
  padding: 10px 14px; border-radius: 8px;
  background: rgba(38, 26, 18,0.4);
  border: 1px solid rgba(58, 42, 30,0.15);
  cursor: pointer; font-size: 0.78rem;
  transition: all 0.15s;
}
.push-list-item:hover { background: rgba(47, 29, 20,0.35); border-color: rgba(200, 119, 67,0.2); }
.push-list-header {
  display: grid;
  grid-template-columns: 50px 2fr 100px 100px 100px 80px 100px;
  align-items: center; gap: 10px;
  padding: 8px 14px; font-size: 0.7rem;
  color: var(--text-muted); font-weight: 600;
  text-transform: uppercase; letter-spacing: 0.05em;
}

/* --- Timeline view --- */
.push-timeline { padding: 8px 0; }
.push-timeline-item {
  display: flex; gap: 16px;
  padding: 0 0 20px 0;
  position: relative;
}
.push-timeline-item::before {
  content: '';
  position: absolute; left: 15px; top: 32px; bottom: 0;
  width: 2px; background: rgba(58, 42, 30,0.3);
}
.push-timeline-item:last-child::before { display: none; }
.push-timeline-dot {
  width: 32px; height: 32px;
  border-radius: 50%; flex-shrink: 0;
  display: flex; align-items: center; justify-content: center;
  font-size: 0.75rem; z-index: 1;
}
.push-timeline-dot.created { background: rgba(122, 74, 42,0.2); color: #a94c60; }
.push-timeline-dot.pending { background: rgba(154, 138, 78,0.2); color: #d9963c; }
.push-timeline-dot.approved { background: rgba(200, 119, 67,0.2); color: #c87743; }
.push-timeline-dot.pushed { background: rgba(91, 155, 112,0.2); color: #4f9d69; }
.push-timeline-dot.cancelled { background: rgba(162, 143, 127,0.2); color: #b49a82; }
.push-timeline-dot.rejected { background: rgba(184, 70, 92,0.2); color: #c0455a; }
.push-timeline-dot.comment { background: rgba(192, 95, 116,0.2); color: #a855f7; }
.push-timeline-body { flex: 1; }
.push-timeline-title { font-size: 0.8rem; font-weight: 600; color: var(--text-main); }
.push-timeline-detail { font-size: 0.72rem; color: var(--text-muted); margin-top: 2px; }
.push-timeline-time { font-size: 0.65rem; color: var(--text-muted); opacity: 0.7; margin-top: 3px; }

/* --- Detail modal improvements --- */
.push-detail-section {
  margin-bottom: 16px; padding-bottom: 16px;
  border-bottom: 1px solid rgba(58, 42, 30,0.2);
}
.push-detail-section:last-child { border-bottom: none; margin-bottom: 0; }

.push-detail-grid {
  display: grid; grid-template-columns: 1fr 1fr;
  gap: 12px;
}
.push-detail-field label {
  font-size: 0.7rem; color: var(--text-muted);
  text-transform: uppercase; letter-spacing: 0.04em; font-weight: 600;
  display: block; margin-bottom: 4px;
}

.push-comment-input-wrap {
  display: flex; gap: 8px; margin-top: 12px;
}
.push-comment-input {
  flex: 1; padding: 8px 12px;
  border-radius: 8px;
  border: 1px solid rgba(58, 42, 30,0.3);
  background: rgba(20, 12, 7,0.5);
  color: var(--text-main); font-size: 0.8rem;
  outline: none; resize: none;
}
.push-comment-input:focus { border-color: var(--primary); }
.push-comment-send {
  padding: 8px 14px; border-radius: 8px;
  border: none; background: var(--primary);
  color: #fff; cursor: pointer; font-size: 0.8rem;
  transition: all 0.2s;
}
.push-comment-send:hover { background: #9c5a2c; }

/* Push card picker & linked cards */
.push-card-picker-selects {
  display: flex; gap: 8px;
}
.push-card-picker-selects select {
  flex: 1; font-size: 0.78rem;
  background-color: #241710 !important;
}
.push-linked-cards-list {
  display: flex; flex-direction: column; gap: 4px; margin-top: 8px;
}
.push-linked-card-badge {
  display: flex; align-items: center; gap: 8px;
  padding: 6px 10px; border-radius: 8px;
  background: rgba(200, 119, 67, 0.08);
  border: 1px solid rgba(200, 119, 67, 0.15);
}
.push-linked-card-info {
  flex: 1; min-width: 0; font-size: 0.78rem;
  display: flex; align-items: center; gap: 8px;
}
.push-linked-card-info strong {
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.push-linked-card-nav {
  flex: 1; min-width: 0; font-size: 0.78rem;
  display: flex; align-items: center; gap: 4px;
  cursor: pointer; border-radius: 4px; padding: 2px 4px;
  transition: background 0.15s;
}
.push-linked-card-nav:hover {
  background: rgba(200, 119, 67, 0.12);
}
.push-linked-card-nav strong {
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.push-linked-card-remove {
  background: none; border: none; color: var(--text-muted);
  cursor: pointer; padding: 2px 4px; border-radius: 4px;
  font-size: 0.85rem; line-height: 1;
  transition: all 0.15s;
}
.push-linked-card-remove:hover {
  background: rgba(184, 70, 92, 0.15); color: #c0455a;
}
.push-card-linked {
  font-size: 0.65rem; color: #c87743;
  display: flex; align-items: center; gap: 3px;
  margin-top: 4px;
}

/* =============================================
   SUB-TABS
   ============================================= */

.kanban-subtabs {
  display: flex;
  gap: 4px;
  padding: 10px 24px;
  background: rgba(38, 26, 18, 0.4);
  border-bottom: 1px solid rgba(58, 42, 30, 0.2);
}

.kanban-subtab {
  padding: 7px 18px;
  border-radius: 8px;
  border: 1px solid transparent;
  background: transparent;
  color: var(--text-muted);
  font-size: 0.83rem;
  cursor: pointer;
  transition: all 0.25s ease;
  font-weight: 500;
  position: relative;
}

.kanban-subtab:hover {
  color: var(--text-main);
  background: rgba(255, 255, 255, 0.03);
}

.kanban-subtab.active {
  background: var(--primary);
  color: #fff;
  box-shadow: 0 2px 10px rgba(200, 119, 67, 0.25);
}

.subtab-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 16px;
  height: 16px;
  padding: 0 4px;
  border-radius: 20px;
  font-size: 0.6rem;
  font-weight: 700;
  line-height: 1;
  margin-left: 6px;
  background: #c0455a;
  color: #fff;
  animation: subtabBadgePop 0.25s ease;
}

.kanban-subtab.active .subtab-badge {
  background: rgba(255, 255, 255, 0.25);
  color: #fff;
}

@keyframes subtabBadgePop {
  0% { transform: scale(0); }
  60% { transform: scale(1.2); }
  100% { transform: scale(1); }
}

.subtab-mark-read {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 30px;
  height: 30px;
  border: 1px solid rgba(58, 42, 30, 0.35);
  background: rgba(20, 12, 7, 0.5);
  color: var(--text-muted);
  font-size: 0.85rem;
  cursor: pointer;
  border-radius: 7px;
  margin-left: auto;
  transition: all 0.2s ease;
}
.subtab-mark-read:hover {
  color: #6bb383;
  border-color: rgba(107, 179, 131, 0.4);
  background: rgba(107, 179, 131, 0.08);
}

.subtab-undo-btn {
  font-size: 0.72rem;
  padding: 2px 10px;
  border-radius: 5px;
  vertical-align: middle;
}

/* =============================================
   MODAL OVERRIDES
   ============================================= */

#kanbanCardModal .modal-content,
#kanbanBoardModal .modal-content,
#kanbanPushModal .modal-content,
#kanbanPushDetailModal .modal-content,
#kanbanAvatarModal .modal-content {
  background: linear-gradient(180deg, var(--bg-card) 0%, rgba(20, 12, 7, 0.98) 100%);
  border: 1px solid rgba(58, 42, 30, 0.3);
  color: var(--text-main);
  border-radius: 14px;
  box-shadow: 0 24px 64px rgba(0, 0, 0, 0.5), 0 8px 24px rgba(0, 0, 0, 0.3);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
}

#kanbanCardModal .modal-header,
#kanbanBoardModal .modal-header,
#kanbanPushModal .modal-header,
#kanbanPushDetailModal .modal-header,
#kanbanAvatarModal .modal-header {
  border-bottom: 1px solid rgba(58, 42, 30, 0.2);
  padding: 16px 20px;
}

#kanbanCardModal .modal-footer,
#kanbanBoardModal .modal-footer,
#kanbanPushModal .modal-footer,
#kanbanPushDetailModal .modal-footer,
#kanbanAvatarModal .modal-footer {
  border-top: 1px solid rgba(58, 42, 30, 0.2);
  padding: 14px 20px;
}

#kanbanCardModal .modal-body,
#kanbanBoardModal .modal-body,
#kanbanPushModal .modal-body,
#kanbanPushDetailModal .modal-body,
#kanbanAvatarModal .modal-body {
  padding: 20px;
}

#kanbanCardModal .modal-title,
#kanbanBoardModal .modal-title,
#kanbanPushModal .modal-title,
#kanbanPushDetailModal .modal-title,
#kanbanAvatarModal .modal-title {
  font-weight: 700;
  font-size: 1rem;
}

/* Modal form inputs */
#kanbanCardModal .form-control,
#kanbanBoardModal .form-control,
#kanbanPushModal .form-control,
#kanbanPushDetailModal .form-control,
#kanbanAvatarModal .form-control,
#kanbanCardModal .form-select,
#kanbanBoardModal .form-select,
#kanbanPushModal .form-select,
#kanbanPushDetailModal .form-select,
#kanbanAvatarModal .form-select {
  background-color: var(--bg-input);
  border: 1px solid rgba(58, 42, 30, 0.4);
  color: var(--text-main);
  border-radius: 7px;
  transition: all 0.2s ease;
}

#kanbanCardModal .form-control:focus,
#kanbanBoardModal .form-control:focus,
#kanbanPushModal .form-control:focus,
#kanbanPushDetailModal .form-control:focus,
#kanbanAvatarModal .form-control:focus,
#kanbanCardModal .form-select:focus,
#kanbanBoardModal .form-select:focus,
#kanbanPushModal .form-select:focus,
#kanbanPushDetailModal .form-select:focus,
#kanbanAvatarModal .form-select:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(200, 119, 67, 0.12);
}

#kanbanCardModal .btn-close,
#kanbanBoardModal .btn-close,
#kanbanPushModal .btn-close,
#kanbanPushDetailModal .btn-close,
#kanbanAvatarModal .btn-close {
  filter: invert(1) brightness(0.7);
  opacity: 0.6;
  transition: opacity 0.15s ease;
}

#kanbanCardModal .btn-close:hover,
#kanbanBoardModal .btn-close:hover,
#kanbanPushModal .btn-close:hover,
#kanbanPushDetailModal .btn-close:hover,
#kanbanAvatarModal .btn-close:hover {
  opacity: 1;
}

/* =============================================
   CUSTOM SCROLLBARS
   ============================================= */

/* --- Column body scrollbar (visible & styled) --- */
.kanban-column-body::-webkit-scrollbar {
  width: 6px;
}
.kanban-column-body::-webkit-scrollbar-track {
  background: rgba(20, 12, 7, 0.3);
  border-radius: 3px;
  margin: 4px 0;
}
.kanban-column-body::-webkit-scrollbar-thumb {
  background: linear-gradient(180deg, rgba(200, 119, 67, 0.45), rgba(122, 74, 42, 0.45));
  border-radius: 3px;
  border: 1px solid rgba(200, 119, 67, 0.15);
}
.kanban-column-body::-webkit-scrollbar-thumb:hover {
  background: linear-gradient(180deg, rgba(200, 119, 67, 0.7), rgba(122, 74, 42, 0.7));
}

/* --- Other scrollbars (discret) --- */
.kanban-board-view::-webkit-scrollbar,
.kanban-push-table-list::-webkit-scrollbar,
.kanban-sidebar::-webkit-scrollbar,
.kanban-list-view::-webkit-scrollbar,
.kanban-calendar-view::-webkit-scrollbar,
.kanban-push-section::-webkit-scrollbar,
.kanban-assignee-dropdown::-webkit-scrollbar {
  width: 5px;
  height: 5px;
}

.kanban-board-view::-webkit-scrollbar-track,
.kanban-push-table-list::-webkit-scrollbar-track,
.kanban-sidebar::-webkit-scrollbar-track,
.kanban-list-view::-webkit-scrollbar-track,
.kanban-calendar-view::-webkit-scrollbar-track,
.kanban-push-section::-webkit-scrollbar-track,
.kanban-assignee-dropdown::-webkit-scrollbar-track {
  background: transparent;
}

.kanban-board-view::-webkit-scrollbar-thumb,
.kanban-push-table-list::-webkit-scrollbar-thumb,
.kanban-sidebar::-webkit-scrollbar-thumb,
.kanban-list-view::-webkit-scrollbar-thumb,
.kanban-calendar-view::-webkit-scrollbar-thumb,
.kanban-push-section::-webkit-scrollbar-thumb,
.kanban-assignee-dropdown::-webkit-scrollbar-thumb {
  background: rgba(58, 42, 30, 0.4);
  border-radius: 3px;
}

.kanban-board-view::-webkit-scrollbar-thumb:hover,
.kanban-push-table-list::-webkit-scrollbar-thumb:hover,
.kanban-sidebar::-webkit-scrollbar-thumb:hover,
.kanban-list-view::-webkit-scrollbar-thumb:hover,
.kanban-calendar-view::-webkit-scrollbar-thumb:hover,
.kanban-push-section::-webkit-scrollbar-thumb:hover,
.kanban-assignee-dropdown::-webkit-scrollbar-thumb:hover {
  background: rgba(58, 42, 30, 0.6);
}

/* =============================================
   EMPTY STATES
   ============================================= */

.kanban-empty-state {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  height: 240px;
  color: var(--text-muted);
  text-align: center;
  padding: 20px;
}

.kanban-empty-state i {
  font-size: 2.8rem;
  margin-bottom: 14px;
  opacity: 0.4;
  background: linear-gradient(135deg, var(--primary), var(--text-muted));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.kanban-empty-state p {
  font-size: 0.9rem;
  max-width: 300px;
  line-height: 1.5;
}

.kanban-empty-state .empty-hint {
  font-size: 0.78rem;
  color: rgba(162, 143, 127, 0.6);
  margin-top: 4px;
}

/* =============================================
   ACTIVITY VIEW
   ============================================= */

.kanban-activity-view {
  flex: 1;
  overflow-y: auto;
  padding: 20px 24px;
}

.kanban-activity-feed {
  max-width: 700px;
  margin: 0 auto;
}

.kanban-activity-item {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 12px 16px;
  border-radius: 10px;
  background: rgba(38, 26, 18, 0.5);
  border: 1px solid rgba(58, 42, 30, 0.2);
  margin-bottom: 8px;
  animation: kanbanFadeIn 0.2s ease forwards;
}

.kanban-activity-item .activity-body {
  flex: 1;
  min-width: 0;
}

.kanban-activity-item .activity-text {
  font-size: 0.84rem;
  color: var(--text-main);
  line-height: 1.4;
}

.kanban-activity-item .activity-entity {
  background: rgba(200, 119, 67, 0.12);
  color: var(--primary);
  padding: 1px 6px;
  border-radius: 4px;
  font-size: 0.8rem;
  font-weight: 500;
}

.kanban-activity-item .activity-time {
  font-size: 0.72rem;
  color: var(--text-muted);
  margin-top: 2px;
}

.kanban-activity-item .activity-icon {
  font-size: 1rem;
  margin-top: 2px;
  flex-shrink: 0;
}

.kanban-activity-empty {
  text-align: center;
  padding: 60px 20px;
  color: var(--text-muted);
}

.kanban-activity-empty i {
  font-size: 2.5rem;
  opacity: 0.3;
  display: block;
  margin-bottom: 12px;
}

.kanban-activity-loading {
  text-align: center;
  padding: 40px;
  color: var(--text-muted);
}

/* =============================================
   @MENTIONS
   ============================================= */

.kanban-mention {
  background: rgba(200, 119, 67, 0.15);
  color: var(--primary);
  padding: 1px 4px;
  border-radius: 3px;
  font-weight: 600;
  font-size: 0.85em;
}

.kanban-mention-dropdown {
  position: absolute;
  bottom: 100%;
  left: 0;
  right: 0;
  background: var(--bg-card);
  border: 1px solid rgba(58, 42, 30, 0.5);
  border-radius: 8px;
  box-shadow: 0 -4px 16px rgba(0, 0, 0, 0.3);
  z-index: 100;
  max-height: 200px;
  overflow-y: auto;
  margin-bottom: 4px;
}

.mention-option {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 7px 12px;
  cursor: pointer;
  font-size: 0.82rem;
  color: var(--text-main);
  transition: background 0.1s ease;
}

.mention-option:hover,
.mention-option.active {
  background: rgba(200, 119, 67, 0.12);
}

/* =============================================
   DEPENDENCIES
   ============================================= */

.kanban-deps-section {
  margin-bottom: 8px;
}

.deps-label {
  font-size: 0.72rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  display: block;
  margin-bottom: 4px;
}

.deps-label.blocked-by {
  color: var(--danger);
}

.deps-label.blocks {
  color: var(--warning);
}

.kanban-dep-item {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 6px 10px;
  border-radius: 6px;
  background: rgba(47, 29, 20, 0.3);
  border: 1px solid rgba(58, 42, 30, 0.2);
  margin-bottom: 4px;
  font-size: 0.82rem;
}

.kanban-dep-item .dep-title {
  flex: 1;
  color: var(--text-main);
}

/* =============================================
   BULK ACTIONS
   ============================================= */

.kanban-bulk-bar {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 16px;
  background: linear-gradient(135deg, rgba(200, 119, 67, 0.12), rgba(122, 74, 42, 0.08));
  border: 1px solid rgba(200, 119, 67, 0.3);
  border-radius: 10px;
  margin: 8px 24px 0;
  animation: kanbanFadeIn 0.2s ease;
}

.kanban-bulk-bar .bulk-count {
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--primary);
  white-space: nowrap;
}

/* Bulk select checkbox – bas gauche de la carte */
.kanban-card-bulk-label {
  position: absolute;
  bottom: 6px;
  left: 8px;
  z-index: 3;
  cursor: pointer;
  opacity: 0;
  transition: opacity 0.2s ease;
  margin: 0;
  line-height: 1;
}
.kanban-card:hover .kanban-card-bulk-label,
.kanban-card.bulk-selected .kanban-card-bulk-label {
  opacity: 1;
}
.kanban-card-bulk-check {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}
.kanban-card-bulk-box {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 20px;
  height: 20px;
  border-radius: 6px;
  border: 2px solid rgba(119, 100, 84, 0.5);
  background: rgba(20, 12, 7, 0.6);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  color: transparent;
  font-size: 0.7rem;
  transition: all 0.15s ease;
}
.kanban-card-bulk-label:hover .kanban-card-bulk-box {
  border-color: var(--primary);
  background: rgba(200, 119, 67, 0.15);
}
.kanban-card-bulk-check:checked + .kanban-card-bulk-box {
  background: var(--primary);
  border-color: var(--primary);
  color: #fff;
  box-shadow: 0 0 8px rgba(200, 119, 67, 0.4);
}

.kanban-card.bulk-selected {
  border-color: var(--primary) !important;
  box-shadow: 0 0 0 2px rgba(200, 119, 67, 0.25) !important;
}

/* =============================================
   LIGHTBOX
   ============================================= */

.kanban-lightbox {
  position: fixed;
  inset: 0;
  z-index: 99999;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: opacity 0.25s ease;
}
.kanban-lightbox.visible {
  opacity: 1;
}
.kanban-lightbox-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.85);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}
.kanban-lightbox-img {
  position: relative;
  max-width: 90vw;
  max-height: 90vh;
  object-fit: contain;
  border-radius: 8px;
  box-shadow: 0 16px 64px rgba(0, 0, 0, 0.5);
  z-index: 1;
  animation: lightboxZoom 0.3s ease;
}
@keyframes lightboxZoom {
  from { transform: scale(0.85); opacity: 0; }
  to { transform: scale(1); opacity: 1; }
}
.kanban-lightbox-close {
  position: absolute;
  top: 20px;
  right: 20px;
  z-index: 2;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  border: none;
  background: rgba(255, 255, 255, 0.1);
  color: #fff;
  font-size: 1.1rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.2s ease;
  backdrop-filter: blur(4px);
}
.kanban-lightbox-close:hover {
  background: rgba(255, 255, 255, 0.2);
}

/* =============================================
   MOVE TO BOARD POPOVER
   ============================================= */

.kanban-move-popover {
  position: fixed;
  z-index: 9999;
  width: 260px;
  background: linear-gradient(180deg, rgba(25, 35, 55, 0.98) 0%, rgba(20, 12, 7, 0.98) 100%);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid rgba(200, 119, 67, 0.3);
  border-radius: 14px;
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.45), 0 0 0 1px rgba(200, 119, 67, 0.1), 0 0 30px rgba(200, 119, 67, 0.06);
  animation: kmpFadeIn 0.2s ease forwards;
  overflow: hidden;
}

@keyframes kmpFadeIn {
  from { opacity: 0; transform: translateY(-6px) scale(0.96); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}

.kmp-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 14px;
  border-bottom: 1px solid rgba(58, 42, 30, 0.25);
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--text-main);
}

.kmp-header i {
  color: var(--primary);
  margin-right: 6px;
}

.kmp-close {
  background: none;
  border: none;
  color: var(--text-muted);
  cursor: pointer;
  padding: 2px 4px;
  border-radius: 4px;
  font-size: 0.75rem;
  transition: all 0.15s;
}
.kmp-close:hover {
  color: var(--text-main);
  background: rgba(255, 255, 255, 0.08);
}

.kmp-body {
  padding: 12px 14px 14px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.kmp-label {
  font-size: 0.7rem;
  font-weight: 600;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.kmp-select {
  width: 100%;
  background: rgba(20, 12, 7, 0.6);
  border: 1px solid rgba(58, 42, 30, 0.4);
  border-radius: 8px;
  color: var(--text-main);
  font-size: 0.8rem;
  padding: 7px 10px;
  outline: none;
  transition: border-color 0.2s, box-shadow 0.2s;
  cursor: pointer;
  appearance: none;
  -webkit-appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%2394a3b8' d='M2.5 4.5l3.5 3.5 3.5-3.5'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 10px center;
}

.kmp-select:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(200, 119, 67, 0.15);
}

.kmp-select option {
  background: var(--bg-card);
  color: var(--text-main);
}

.kmp-select option:disabled {
  color: var(--text-muted);
  font-style: italic;
}

.kmp-btn {
  margin-top: 4px;
  width: 100%;
  padding: 8px 0;
  border: none;
  border-radius: 8px;
  background: linear-gradient(135deg, var(--primary), #4f46e5);
  color: #fff;
  font-size: 0.8rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
}

.kmp-btn:hover:not(:disabled) {
  background: linear-gradient(135deg, #9c5a2c, #4338ca);
  box-shadow: 0 4px 14px rgba(200, 119, 67, 0.3);
  transform: translateY(-1px);
}

.kmp-btn:disabled {
  opacity: 0.4;
  cursor: not-allowed;
}

.kc-move-board:hover {
  color: var(--primary) !important;
  border-color: var(--primary) !important;
}
.kc-quick-archive:hover {
  color: var(--warning) !important;
  border-color: var(--warning) !important;
}

/* =============================================
   ARCHIVE VIEW
   ============================================= */

.kanban-archive-view {
  padding: 24px;
  overflow-y: auto;
  flex: 1;
}

.kanban-archive-empty {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 60px 20px;
  color: var(--text-muted);
}
.kanban-archive-empty i {
  font-size: 3rem;
  margin-bottom: 16px;
  opacity: 0.3;
}
.kanban-archive-empty p {
  font-size: 1.1rem;
  font-weight: 600;
  margin-bottom: 4px;
  color: var(--text-main);
}

.kanban-archive-header {
  margin-bottom: 20px;
}
.kanban-archive-header h6 {
  color: var(--text-main);
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 8px;
}
.kanban-archive-header h6 i {
  color: var(--warning);
}

.kanban-archive-board-group {
  margin-bottom: 24px;
}
.kanban-archive-board-title {
  padding: 6px 12px;
  margin-bottom: 10px;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-main);
  display: flex;
  align-items: center;
  gap: 8px;
  background: rgba(38, 26, 18, 0.4);
  border-radius: 6px;
}
.kanban-archive-board-title i {
  font-size: 0.8rem;
  opacity: 0.8;
}

.kanban-archive-grid {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.kanban-archived-card {
  display: flex;
  align-items: stretch;
  background: linear-gradient(135deg, rgba(20, 12, 7, 0.7) 0%, rgba(38, 26, 18, 0.5) 100%);
  border: 1px solid rgba(58, 42, 30, 0.25);
  border-radius: 10px;
  overflow: hidden;
  transition: all 0.2s ease;
  animation: kanbanFadeIn 0.2s ease forwards;
}
.kanban-archived-card:hover {
  border-color: rgba(58, 42, 30, 0.5);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.kac-priority {
  width: 4px;
  flex-shrink: 0;
}
.kac-priority.critical { background: var(--danger); }
.kac-priority.high { background: #cf7a35; }
.kac-priority.medium { background: #facc15; }
.kac-priority.low { background: var(--border-color); }

.kac-body {
  flex: 1;
  padding: 12px 14px;
  min-width: 0;
}
.kac-title {
  font-weight: 600;
  font-size: 0.85rem;
  color: var(--text-main);
  margin-bottom: 6px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.kac-meta {
  display: flex;
  gap: 14px;
  font-size: 0.72rem;
  align-items: center;
}
.kac-meta span {
  display: flex;
  align-items: center;
  gap: 4px;
}

.kac-actions {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 8px 12px;
}
.kac-actions button {
  background: rgba(20, 12, 7, 0.6);
  border: 1px solid rgba(58, 42, 30, 0.3);
  color: var(--text-muted);
  padding: 6px 10px;
  font-size: 0.78rem;
  cursor: pointer;
  border-radius: 7px;
  transition: all 0.15s ease;
}
.kac-actions .kav-restore:hover {
  color: #4f9d69;
  border-color: #4f9d69;
  background: rgba(91, 155, 112, 0.1);
}
.kac-actions .kav-delete:hover {
  color: var(--danger);
  border-color: var(--danger);
  background: rgba(184, 70, 92, 0.1);
}

/* =============================================
   DUE DATE REMINDERS
   ============================================= */

.kanban-due-reminder {
  margin: 0 24px;
  animation: kanbanFadeIn 0.3s ease forwards;
}

.kdr-content {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  padding: 12px 16px;
  background: linear-gradient(135deg, rgba(38, 26, 18, 0.8) 0%, rgba(20, 12, 7, 0.9) 100%);
  border: 1px solid rgba(58, 42, 30, 0.3);
  border-radius: 10px;
  position: relative;
}

.kdr-icon {
  color: var(--warning);
  font-size: 1.1rem;
  flex-shrink: 0;
  margin-top: 2px;
  animation: kanbanOverduePulse 2s ease-in-out infinite;
}

.kdr-section {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.kdr-badge {
  font-size: 0.72rem;
  font-weight: 700;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 2px 8px;
  border-radius: 12px;
}
.kdr-badge-danger { background: rgba(184, 70, 92, 0.15); color: #d4707f; }
.kdr-badge-warning { background: rgba(154, 138, 78, 0.15); color: #e0a851; }
.kdr-badge-info { background: rgba(200, 119, 67, 0.15); color: #d98b53; }

.kdr-cards {
  display: flex;
  flex-wrap: wrap;
  gap: 4px 8px;
}

.kdr-card-link {
  font-size: 0.72rem;
  color: var(--text-muted);
  cursor: pointer;
  transition: color 0.15s;
  white-space: nowrap;
  max-width: 180px;
  overflow: hidden;
  text-overflow: ellipsis;
}
.kdr-card-link:hover {
  color: var(--primary);
  text-decoration: underline;
}

.kdr-dismiss {
  position: absolute;
  top: 8px;
  right: 8px;
  background: none;
  border: none;
  color: var(--text-muted);
  cursor: pointer;
  padding: 2px 6px;
  border-radius: 4px;
  font-size: 0.7rem;
  transition: all 0.15s;
}
.kdr-dismiss:hover {
  color: var(--text-main);
  background: rgba(255, 255, 255, 0.08);
}

/* =============================================
   SAVED VIEWS
   ============================================= */

.kanban-saved-views-wrap {
  display: flex;
  align-items: center;
  gap: 4px;
}

.kanban-saved-views-wrap .form-select {
  max-width: 180px;
}

.kanban-save-view-btn {
  background: rgba(20, 12, 7, 0.6);
  border: 1px solid rgba(58, 42, 30, 0.4);
  color: var(--text-muted);
  padding: 5px 9px;
  font-size: 0.82rem;
  cursor: pointer;
  border-radius: 7px;
  transition: all 0.2s ease;
  flex-shrink: 0;
}
.kanban-save-view-btn:hover {
  color: var(--primary);
  border-color: var(--primary);
  background: rgba(200, 119, 67, 0.08);
}

.kanban-delete-view-btn {
  background: rgba(20, 12, 7, 0.6);
  border: 1px solid rgba(58, 42, 30, 0.4);
  color: var(--text-muted);
  padding: 5px 8px;
  font-size: 0.75rem;
  cursor: pointer;
  border-radius: 7px;
  transition: all 0.2s ease;
  flex-shrink: 0;
}
.kanban-delete-view-btn:hover {
  color: var(--danger);
  border-color: var(--danger);
  background: rgba(184, 70, 92, 0.08);
}

/* =============================================
   CARD HISTORY
   ============================================= */

.kanban-history-toggle {
  display: flex;
  align-items: center;
  gap: 4px;
  transition: color 0.15s;
}
.kanban-history-toggle:hover {
  color: var(--text-main) !important;
}

.kanban-history-list {
  max-height: 300px;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 0;
  border-left: 2px solid rgba(58, 42, 30, 0.25);
  margin-left: 4px;
  padding-left: 12px;
}

.kanban-history-item {
  display: flex;
  gap: 8px;
  padding: 8px 0;
  border-bottom: 1px solid rgba(58, 42, 30, 0.1);
  animation: kanbanFadeIn 0.2s ease forwards;
}
.kanban-history-item:last-child {
  border-bottom: none;
}

.khi-avatar {
  flex-shrink: 0;
  margin-top: 1px;
}

.khi-body {
  font-size: 0.73rem;
  color: var(--text-muted);
  line-height: 1.5;
}

.khi-user {
  font-weight: 600;
  color: var(--text-main);
}

.khi-values {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-top: 3px;
  font-size: 0.7rem;
}
.khi-values i {
  font-size: 0.55rem;
  color: var(--text-muted);
  opacity: 0.6;
}

.khi-old {
  color: #d4707f;
  text-decoration: line-through;
  opacity: 0.8;
}

.khi-new {
  color: #6bb383;
  font-weight: 600;
}

.khi-date {
  font-size: 0.65rem;
  color: var(--text-muted);
  opacity: 0.6;
  margin-top: 2px;
}

.kanban-history-list::-webkit-scrollbar {
  width: 4px;
}
.kanban-history-list::-webkit-scrollbar-track {
  background: transparent;
}
.kanban-history-list::-webkit-scrollbar-thumb {
  background: rgba(58, 42, 30, 0.3);
  border-radius: 2px;
}
.kanban-history-list::-webkit-scrollbar-thumb:hover {
  background: rgba(58, 42, 30, 0.5);
}

/* =============================================
   SUGGESTIONS SYSTEM
   ============================================= */

/* --- Container & Layout --- */
.sugg-container {
  display: flex;
  flex-direction: column;
  gap: 16px;
  padding: 16px 0;
  height: 100%;
  min-height: 0;
  overflow: hidden;
}

.sugg-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
}

/* --- Stats Row --- */
.sugg-stats {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.sugg-stat {
  display: flex;
  align-items: center;
  gap: 6px;
  background: rgba(20, 12, 7, 0.5);
  border: 1px solid rgba(58, 42, 30, 0.25);
  border-radius: 8px;
  padding: 6px 12px;
  font-size: 0.78rem;
  color: var(--text-muted);
}

.sugg-stat .sugg-stat-value {
  font-weight: 700;
  color: var(--text-main);
  font-size: 0.9rem;
}

.sugg-stat i {
  font-size: 0.85rem;
  opacity: 0.7;
}

/* --- New Suggestion Button --- */
.sugg-new-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: linear-gradient(135deg, var(--primary), #a94c60);
  color: #fff;
  border: none;
  border-radius: 8px;
  padding: 8px 16px;
  font-size: 0.82rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
  box-shadow: 0 2px 8px rgba(200, 119, 67, 0.25);
}
.sugg-new-btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 14px rgba(200, 119, 67, 0.35);
  filter: brightness(1.1);
}
.sugg-new-btn:active {
  transform: translateY(0);
}

/* --- View Tabs (Active / Archives validées / Archives refusées) --- */
.sugg-view-tabs {
  display: flex;
  gap: 4px;
  padding: 0 16px 8px;
  border-bottom: 1px solid rgba(58, 42, 30, 0.2);
  margin-bottom: 8px;
}
.sugg-view-tab {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 14px;
  border: 1px solid rgba(58, 42, 30, 0.25);
  border-radius: 8px;
  background: transparent;
  color: var(--text-muted);
  font-size: 0.78rem;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s ease;
}
.sugg-view-tab:hover {
  background: rgba(122, 74, 42, 0.08);
  border-color: rgba(122, 74, 42, 0.3);
  color: var(--text-primary);
}
.sugg-view-tab.active {
  background: rgba(122, 74, 42, 0.15);
  border-color: rgba(122, 74, 42, 0.5);
  color: #a5b4fc;
  font-weight: 600;
}
.sugg-view-count {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 18px;
  height: 18px;
  padding: 0 5px;
  border-radius: 9px;
  background: rgba(122, 74, 42, 0.2);
  color: #a5b4fc;
  font-size: 0.7rem;
  font-weight: 700;
  line-height: 1;
}
.sugg-view-count:empty {
  display: none;
}

/* --- Archive / Restore Buttons on Cards --- */
.sugg-archive-btn,
.sugg-restore-btn {
  position: absolute;
  top: 6px;
  right: 6px;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  border: 1px solid rgba(58, 42, 30, 0.3);
  border-radius: 6px;
  background: rgba(20, 12, 7, 0.6);
  color: var(--text-muted);
  font-size: 0.82rem;
  cursor: pointer;
  opacity: 0;
  transition: all 0.2s ease;
  z-index: 2;
}
.sugg-card:hover .sugg-archive-btn,
.sugg-card:hover .sugg-restore-btn {
  opacity: 1;
}
.sugg-archive-btn:hover {
  background: rgba(154, 138, 78, 0.15);
  border-color: rgba(154, 138, 78, 0.5);
  color: #e0a851;
}
.sugg-restore-btn:hover {
  background: rgba(90, 168, 115, 0.15);
  border-color: rgba(90, 168, 115, 0.5);
  color: #7cc194;
}

/* --- Filters Bar --- */
.sugg-filters {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.sugg-filter-wrap {
  display: flex;
  align-items: center;
  gap: 2px;
}

.sugg-filter-add-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  border: 1px solid rgba(58, 42, 30, 0.35);
  background: rgba(20, 12, 7, 0.6);
  color: var(--text-muted);
  font-size: 0.75rem;
  cursor: pointer;
  border-radius: 6px;
  transition: all 0.15s ease;
  flex-shrink: 0;
}
.sugg-filter-add-btn:hover {
  color: var(--primary);
  border-color: var(--primary);
  background: rgba(200, 119, 67, 0.08);
}

.sugg-filters .form-select,
.sugg-filters .form-control {
  background-color: rgba(20, 12, 7, 0.6);
  border: 1px solid rgba(58, 42, 30, 0.35);
  color: var(--text-main);
  font-size: 0.8rem;
  padding: 5px 10px;
  border-radius: 7px;
  max-width: 170px;
  transition: border-color 0.2s;
}
.sugg-filters .form-select {
  background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3e%3cpath fill='none' stroke='%2394a3b8' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='m2 5 6 6 6-6'/%3e%3c/svg%3e");
  background-repeat: no-repeat;
  background-position: right 0.5rem center;
  background-size: 14px 10px;
  padding-right: 28px;
}
.sugg-filters .form-select:focus,
.sugg-filters .form-control:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 2px rgba(200, 119, 67, 0.15);
}

.sugg-filters .form-control[type="search"] {
  max-width: 220px;
}

/* --- Suggestion List --- */
.sugg-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
  overflow-y: auto;
  flex: 1;
  min-height: 0;
  padding-right: 4px;
}

.sugg-list::-webkit-scrollbar {
  width: 5px;
}
.sugg-list::-webkit-scrollbar-track {
  background: transparent;
}
.sugg-list::-webkit-scrollbar-thumb {
  background: linear-gradient(180deg, rgba(122, 74, 42, 0.4), rgba(200, 119, 67, 0.4));
  border-radius: 3px;
}
.sugg-list::-webkit-scrollbar-thumb:hover {
  background: linear-gradient(180deg, rgba(122, 74, 42, 0.6), rgba(200, 119, 67, 0.6));
}

/* --- Empty State --- */
.sugg-empty {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 48px 20px;
  color: var(--text-muted);
  text-align: center;
  gap: 10px;
}
.sugg-empty i {
  font-size: 2.5rem;
  opacity: 0.3;
}
.sugg-empty span {
  font-size: 0.85rem;
  opacity: 0.6;
}

/* --- Suggestion Card --- */
.sugg-card {
  display: flex;
  gap: 0;
  background: rgba(20, 12, 7, 0.5);
  border: 1px solid rgba(58, 42, 30, 0.25);
  border-radius: 10px;
  overflow: hidden;
  cursor: pointer;
  transition: all 0.2s ease;
  flex-shrink: 0;
}
.sugg-card:hover {
  border-color: rgba(122, 74, 42, 0.4);
  background: rgba(20, 12, 7, 0.7);
  transform: translateX(2px);
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.15);
}

/* --- Vote Block (left side of card) --- */
.sugg-vote-block {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2px;
  padding: 10px 8px;
  min-width: 68px;
  background: rgba(20, 12, 7, 0.4);
  border-right: 1px solid rgba(58, 42, 30, 0.15);
  flex-shrink: 0;
}

.sugg-vote-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  border: none;
  background: transparent;
  color: var(--text-muted);
  font-size: 0.85rem;
  cursor: pointer;
  border-radius: 6px;
  transition: all 0.15s ease;
}
.sugg-vote-btn:hover {
  background: rgba(122, 74, 42, 0.12);
  color: #c05f74;
}
.sugg-vote-btn.active-up,
.sugg-vote-up.active {
  color: #6bb383;
  background: rgba(107, 179, 131, 0.12);
}
.sugg-vote-btn.active-down,
.sugg-vote-down.active {
  color: #d4707f;
  background: rgba(212, 120, 138, 0.12);
}

.sugg-score {
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--text-main);
  line-height: 1;
  min-width: 20px;
  text-align: center;
}
.sugg-score.positive {
  color: #6bb383;
}
.sugg-score.negative {
  color: #d4707f;
}

/* --- Vote Ratio (below score in vote block) --- */
.sugg-vote-ratio {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1px;
  margin-top: 4px;
  font-size: 0.58rem;
  line-height: 1.3;
}
.sugg-vote-ratio .svr-up {
  color: #6bb383;
  display: flex;
  align-items: center;
  gap: 2px;
}
.sugg-vote-ratio .svr-down {
  color: #d4707f;
  display: flex;
  align-items: center;
  gap: 2px;
}
.sugg-vote-ratio .svr-total {
  color: var(--text-muted);
  opacity: 0.6;
  font-size: 0.55rem;
  margin-top: 1px;
}
.sugg-vote-ratio i {
  font-size: 0.5rem;
}

/* --- Card Body (right side) --- */
.sugg-card-body {
  flex: 1;
  padding: 10px 14px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  min-width: 0;
  transition: background 0.3s ease;
  position: relative;
}
.sugg-card-body.sugg-body-positive {
  background: rgba(107, 179, 131, 0.06);
  border-left: 2px solid rgba(107, 179, 131, 0.25);
}
.sugg-card-body.sugg-body-negative {
  background: rgba(212, 120, 138, 0.06);
  border-left: 2px solid rgba(212, 120, 138, 0.25);
}

.sugg-card-top {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
}

/* --- Category Badge --- */
.sugg-cat-badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 0.68rem;
  font-weight: 600;
  padding: 2px 8px;
  border-radius: 20px;
  text-transform: uppercase;
  letter-spacing: 0.3px;
  line-height: 1.6;
}
.sugg-cat-badge[data-cat="gameplay"] {
  background: rgba(200, 119, 67, 0.15);
  color: #d98b53;
  border: 1px solid rgba(200, 119, 67, 0.25);
}
.sugg-cat-badge[data-cat="ui"] {
  background: rgba(192, 95, 116, 0.15);
  color: #c084fc;
  border: 1px solid rgba(192, 95, 116, 0.25);
}
.sugg-cat-badge[data-cat="balance"] {
  background: rgba(154, 138, 78, 0.15);
  color: #e0a851;
  border: 1px solid rgba(154, 138, 78, 0.25);
}
.sugg-cat-badge[data-cat="social"] {
  background: rgba(184, 70, 92, 0.15);
  color: #f472b6;
  border: 1px solid rgba(184, 70, 92, 0.25);
}
.sugg-cat-badge[data-cat="content"] {
  background: rgba(90, 168, 115, 0.15);
  color: #7cc194;
  border: 1px solid rgba(90, 168, 115, 0.25);
}
.sugg-cat-badge[data-cat="technical"] {
  background: rgba(58, 42, 30, 0.25);
  color: #b49a82;
  border: 1px solid rgba(58, 42, 30, 0.35);
}
.sugg-cat-badge[data-cat="other"] {
  background: rgba(58, 42, 30, 0.15);
  color: #b49a82;
  border: 1px solid rgba(58, 42, 30, 0.25);
}

/* --- Status Badge --- */
.sugg-status-badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 0.68rem;
  font-weight: 600;
  padding: 2px 8px;
  border-radius: 20px;
  line-height: 1.6;
}
.sugg-status-badge[data-status="new"] {
  background: rgba(200, 119, 67, 0.15);
  color: #d98b53;
  border: 1px solid rgba(200, 119, 67, 0.25);
}
.sugg-status-badge[data-status="under_review"] {
  background: rgba(154, 138, 78, 0.15);
  color: #e0a851;
  border: 1px solid rgba(154, 138, 78, 0.25);
}
.sugg-status-badge[data-status="planned"] {
  background: rgba(122, 74, 42, 0.15);
  color: #c05f74;
  border: 1px solid rgba(122, 74, 42, 0.25);
}
.sugg-status-badge[data-status="in_progress"] {
  background: rgba(184, 129, 63, 0.15);
  color: #d98b53;
  border: 1px solid rgba(184, 129, 63, 0.25);
}
.sugg-status-badge[data-status="done"] {
  background: rgba(90, 168, 115, 0.15);
  color: #7cc194;
  border: 1px solid rgba(90, 168, 115, 0.25);
}
.sugg-status-badge[data-status="rejected"] {
  background: rgba(184, 70, 92, 0.12);
  color: #d4707f;
  border: 1px solid rgba(184, 70, 92, 0.2);
}
.sugg-status-badge[data-status="duplicate"] {
  background: rgba(58, 42, 30, 0.2);
  color: #b49a82;
  border: 1px solid rgba(58, 42, 30, 0.3);
}

/* --- Linked Badge --- */
.sugg-linked-badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 0.65rem;
  font-weight: 600;
  padding: 2px 7px;
  border-radius: 20px;
  background: rgba(90, 168, 115, 0.12);
  color: #7cc194;
  border: 1px solid rgba(90, 168, 115, 0.2);
  line-height: 1.6;
}
.sugg-linked-badge i {
  font-size: 0.6rem;
}

/* --- Card Title & Description --- */
.sugg-card-title {
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--text-main);
  line-height: 1.3;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.sugg-card-desc {
  font-size: 0.76rem;
  color: var(--text-muted);
  line-height: 1.45;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* --- Card Meta --- */
.sugg-card-meta {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 0.7rem;
  color: var(--text-muted);
  opacity: 0.7;
  margin-top: 2px;
}
.sugg-card-meta i {
  font-size: 0.65rem;
  margin-right: 2px;
}

/* --- No Vote Indicator --- */
.sugg-no-vote-indicator {
  position: absolute;
  right: 10px;
  top: 50%;
  transform: translateY(-50%);
  display: flex;
  align-items: center;
  gap: 4px;
  font-size: 0.65rem;
  font-weight: 600;
  color: #e0a851;
  background: rgba(154, 138, 78, 0.1);
  border: 1px solid rgba(154, 138, 78, 0.25);
  border-radius: 20px;
  padding: 3px 10px;
  white-space: nowrap;
  animation: subtabBadgePop 0.3s ease;
}
.sugg-no-vote-indicator i {
  font-size: 0.7rem;
}

/* =============================================
   SUGGESTION MODAL
   ============================================= */

.sugg-modal-layout {
  display: flex;
  gap: 20px;
  min-height: 350px;
}

.sugg-modal-main {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.sugg-modal-sidebar {
  width: 200px;
  flex-shrink: 0;
  display: flex;
  flex-direction: column;
  gap: 14px;
  padding-left: 20px;
  border-left: 1px solid rgba(58, 42, 30, 0.2);
}

.sugg-modal-sidebar label {
  font-size: 0.72rem;
  font-weight: 600;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.4px;
  margin-bottom: 4px;
}

.sugg-modal-sidebar .form-select {
  background-color: rgba(20, 12, 7, 0.6);
  background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3e%3cpath fill='none' stroke='%2394a3b8' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='m2 5 6 6 6-6'/%3e%3c/svg%3e");
  background-repeat: no-repeat;
  background-position: right 0.5rem center;
  background-size: 14px 10px;
  border: 1px solid rgba(58, 42, 30, 0.35);
  color: var(--text-main);
  font-size: 0.8rem;
  padding: 5px 8px;
  padding-right: 28px;
  border-radius: 7px;
}

/* --- Modal Vote Section --- */
.sugg-modal-vote {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 16px;
  background: rgba(20, 12, 7, 0.4);
  border-radius: 10px;
  border: 1px solid rgba(58, 42, 30, 0.2);
}

.sugg-modal-vote .sugg-vote-btn {
  width: 36px;
  height: 36px;
  font-size: 1rem;
}

.sugg-modal-vote .sugg-score {
  font-size: 1.2rem;
}

.sugg-vote-detail {
  font-size: 0.72rem;
  color: var(--text-muted);
  margin-left: auto;
  display: flex;
  gap: 10px;
}
.sugg-vote-detail span {
  display: flex;
  align-items: center;
  gap: 3px;
}

/* --- Comments Section --- */
.sugg-comments-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
  max-height: 260px;
  overflow-y: auto;
  padding-right: 4px;
}

.sugg-comments-list::-webkit-scrollbar {
  width: 4px;
}
.sugg-comments-list::-webkit-scrollbar-track {
  background: transparent;
}
.sugg-comments-list::-webkit-scrollbar-thumb {
  background: rgba(58, 42, 30, 0.3);
  border-radius: 2px;
}

.sugg-comment {
  display: flex;
  gap: 10px;
  padding: 10px;
  background: rgba(20, 12, 7, 0.35);
  border-radius: 8px;
  border: 1px solid rgba(58, 42, 30, 0.12);
  animation: kanbanFadeIn 0.2s ease forwards;
}

.sugg-comment-avatar {
  flex-shrink: 0;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--primary), #a94c60);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.7rem;
  font-weight: 700;
  color: #fff;
  text-transform: uppercase;
}

.sugg-comment-body {
  flex: 1;
  min-width: 0;
}

.sugg-comment-header {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 4px;
}

.sugg-comment-header strong {
  font-size: 0.78rem;
  color: var(--text-main);
}

.sugg-comment-header time {
  font-size: 0.65rem;
  color: var(--text-muted);
  opacity: 0.6;
}

.sugg-comment-text {
  font-size: 0.8rem;
  color: var(--text-muted);
  line-height: 1.5;
  word-break: break-word;
}

/* --- Linked Card Info --- */
.sugg-linked-info {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 14px;
  background: rgba(90, 168, 115, 0.06);
  border: 1px solid rgba(90, 168, 115, 0.18);
  border-radius: 8px;
  font-size: 0.8rem;
  color: #7cc194;
}
.sugg-linked-info i {
  font-size: 0.9rem;
}
.sugg-linked-info span {
  color: var(--text-muted);
  font-size: 0.75rem;
}

/* --- Comment Input Area --- */
.sugg-comment-input-wrap {
  display: flex;
  gap: 8px;
  margin-top: 8px;
}

.sugg-comment-input-wrap textarea {
  flex: 1;
  background: rgba(20, 12, 7, 0.6);
  border: 1px solid rgba(58, 42, 30, 0.35);
  color: var(--text-main);
  font-size: 0.8rem;
  padding: 8px 10px;
  border-radius: 8px;
  resize: none;
  min-height: 38px;
  max-height: 100px;
  transition: border-color 0.2s;
}
.sugg-comment-input-wrap textarea:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 2px rgba(200, 119, 67, 0.12);
  outline: none;
}

.sugg-comment-input-wrap button {
  align-self: flex-end;
  background: var(--primary);
  color: #fff;
  border: none;
  border-radius: 8px;
  padding: 8px 14px;
  font-size: 0.78rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.15s;
  flex-shrink: 0;
}
.sugg-comment-input-wrap button:hover {
  filter: brightness(1.15);
}
.sugg-comment-input-wrap button:disabled {
  opacity: 0.4;
  cursor: not-allowed;
}

/* --- Convert Popover --- */
.sugg-convert-popover {
  position: absolute;
  z-index: 1060;
  background: var(--bg-card, #241710);
  border: 1px solid rgba(58, 42, 30, 0.4);
  border-radius: 10px;
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.4);
  padding: 14px;
  min-width: 260px;
  max-width: 320px;
  animation: kanbanFadeIn 0.15s ease forwards;
}

.sugg-convert-popover h6 {
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--text-main);
  margin-bottom: 10px;
  display: flex;
  align-items: center;
  gap: 6px;
}

.sugg-convert-popover .form-select {
  background-color: rgba(20, 12, 7, 0.6);
  background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3e%3cpath fill='none' stroke='%2394a3b8' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='m2 5 6 6 6-6'/%3e%3c/svg%3e");
  background-repeat: no-repeat;
  background-position: right 0.5rem center;
  background-size: 14px 10px;
  border: 1px solid rgba(58, 42, 30, 0.35);
  color: var(--text-main);
  font-size: 0.8rem;
  padding: 5px 8px;
  padding-right: 28px;
  border-radius: 7px;
  margin-bottom: 8px;
  width: 100%;
}

.sugg-convert-popover button.btn-primary {
  width: 100%;
  font-size: 0.8rem;
  padding: 7px 0;
  border-radius: 7px;
}

/* --- New Suggestion Modal Form --- */
.sugg-new-form {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.sugg-new-form label {
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--text-muted);
  margin-bottom: 2px;
}

.sugg-new-form .form-control,
.sugg-new-form .form-select {
  background-color: rgba(20, 12, 7, 0.6);
  border: 1px solid rgba(58, 42, 30, 0.35);
  color: var(--text-main);
  font-size: 0.82rem;
  padding: 7px 10px;
  border-radius: 8px;
}
.sugg-new-form .form-select {
  background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3e%3cpath fill='none' stroke='%2394a3b8' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='m2 5 6 6 6-6'/%3e%3c/svg%3e");
  background-repeat: no-repeat;
  background-position: right 0.6rem center;
  background-size: 14px 10px;
  padding-right: 30px;
}
.sugg-new-form .form-control:focus,
.sugg-new-form .form-select:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 2px rgba(200, 119, 67, 0.15);
}

.sugg-new-form textarea {
  min-height: 80px;
  resize: vertical;
}

/* --- Option Modal (category/source picker) --- */
.sugg-option-overlay {
  position: fixed;
  inset: 0;
  z-index: 1070;
  background: rgba(0, 0, 0, 0);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.2s ease;
}
.sugg-option-overlay.visible {
  background: rgba(0, 0, 0, 0.55);
}
.sugg-option-overlay.visible .sugg-option-modal {
  transform: scale(1);
  opacity: 1;
}

.sugg-option-modal {
  background: var(--bg-card, #241710);
  border: 1px solid rgba(58, 42, 30, 0.4);
  border-radius: 14px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
  width: 380px;
  max-width: 90vw;
  transform: scale(0.9);
  opacity: 0;
  transition: all 0.2s ease;
}

.sugg-option-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 18px;
  border-bottom: 1px solid rgba(58, 42, 30, 0.2);
  font-size: 0.9rem;
  font-weight: 700;
  color: var(--text-main);
}
.sugg-option-header i {
  margin-right: 6px;
  opacity: 0.7;
}
.sugg-option-close {
  background: none;
  border: none;
  color: var(--text-muted);
  cursor: pointer;
  font-size: 0.85rem;
  padding: 4px;
  border-radius: 6px;
  transition: all 0.15s;
}
.sugg-option-close:hover {
  color: var(--text-main);
  background: rgba(255, 255, 255, 0.06);
}

.sugg-option-body {
  padding: 16px 18px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.sugg-option-body label {
  font-size: 0.72rem;
  font-weight: 600;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.4px;
}

.sugg-option-input {
  background: rgba(20, 12, 7, 0.6);
  border: 1px solid rgba(58, 42, 30, 0.4);
  color: var(--text-main);
  font-size: 0.85rem;
  padding: 8px 12px;
  border-radius: 8px;
  outline: none;
  transition: border-color 0.2s;
}
.sugg-option-input:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 2px rgba(200, 119, 67, 0.15);
}
.sugg-option-input.shake {
  animation: shakeInput 0.35s ease;
}
@keyframes shakeInput {
  0%, 100% { transform: translateX(0); }
  25% { transform: translateX(-6px); }
  50% { transform: translateX(6px); }
  75% { transform: translateX(-4px); }
}

/* Color Picker */
.sugg-color-picker {
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.sugg-color-presets {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}
.sugg-color-swatch {
  width: 28px;
  height: 28px;
  border-radius: 8px;
  border: 2px solid transparent;
  cursor: pointer;
  transition: all 0.15s ease;
  position: relative;
}
.sugg-color-swatch:hover {
  transform: scale(1.15);
}
.sugg-color-swatch.selected {
  border-color: #fff;
  box-shadow: 0 0 0 2px rgba(255, 255, 255, 0.3);
}
.sugg-color-swatch.selected::after {
  content: "\F272";
  font-family: "bootstrap-icons";
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-size: 0.7rem;
  text-shadow: 0 1px 2px rgba(0,0,0,0.4);
}
.sugg-color-custom {
  display: flex;
  align-items: center;
  gap: 8px;
}
.sugg-color-custom input[type="color"] {
  width: 36px;
  height: 30px;
  border: 1px solid rgba(58, 42, 30, 0.4);
  border-radius: 6px;
  padding: 2px;
  cursor: pointer;
  background: transparent;
}
.sugg-color-custom input[type="color"]::-webkit-color-swatch-wrapper {
  padding: 0;
}
.sugg-color-custom input[type="color"]::-webkit-color-swatch {
  border: none;
  border-radius: 4px;
}
.sugg-color-hex {
  font-size: 0.78rem;
  color: var(--text-muted);
  font-family: monospace;
}

/* Icon Picker */
.sugg-icon-picker {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
}
.sugg-icon-option {
  width: 34px;
  height: 34px;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px solid rgba(58, 42, 30, 0.3);
  background: rgba(20, 12, 7, 0.4);
  color: var(--text-muted);
  font-size: 0.95rem;
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.15s ease;
}
.sugg-icon-option:hover {
  color: var(--text-main);
  border-color: rgba(122, 74, 42, 0.4);
  background: rgba(122, 74, 42, 0.08);
}
.sugg-icon-option.selected {
  color: var(--primary);
  border-color: var(--primary);
  background: rgba(200, 119, 67, 0.12);
  box-shadow: 0 0 0 2px rgba(200, 119, 67, 0.2);
}
.sugg-icon-custom {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 2px;
}
.sugg-icon-custom input {
  flex: 1;
  background: rgba(20, 12, 7, 0.6);
  border: 1px solid rgba(58, 42, 30, 0.4);
  color: var(--text-main);
  font-size: 0.8rem;
  padding: 5px 10px;
  border-radius: 7px;
  font-family: monospace;
  outline: none;
}
.sugg-icon-custom input:focus {
  border-color: var(--primary);
}
.sugg-icon-preview {
  width: 34px;
  height: 34px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(20, 12, 7, 0.5);
  border: 1px solid rgba(58, 42, 30, 0.3);
  border-radius: 8px;
  color: var(--primary);
  font-size: 1rem;
}

/* Footer */
.sugg-option-footer {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
  padding: 12px 18px;
  border-top: 1px solid rgba(58, 42, 30, 0.2);
}
.sugg-option-cancel {
  background: transparent;
  border: 1px solid rgba(58, 42, 30, 0.4);
  color: var(--text-muted);
  padding: 6px 16px;
  font-size: 0.8rem;
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.15s;
}
.sugg-option-cancel:hover {
  color: var(--text-main);
  border-color: rgba(58, 42, 30, 0.6);
}
.sugg-option-confirm {
  background: linear-gradient(135deg, var(--primary), #a94c60);
  border: none;
  color: #fff;
  padding: 6px 18px;
  font-size: 0.8rem;
  font-weight: 600;
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.15s;
}
.sugg-option-confirm:hover {
  filter: brightness(1.1);
}

/* --- Manage List --- */
.sugg-manage-list {
  padding: 10px 18px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  max-height: 300px;
  overflow-y: auto;
}
.sugg-manage-list::-webkit-scrollbar { width: 4px; }
.sugg-manage-list::-webkit-scrollbar-track { background: transparent; }
.sugg-manage-list::-webkit-scrollbar-thumb { background: rgba(58, 42, 30,0.3); border-radius: 2px; }

.sugg-manage-row {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 10px;
  background: rgba(20, 12, 7, 0.4);
  border: 1px solid rgba(58, 42, 30, 0.2);
  border-radius: 8px;
  transition: all 0.2s;
}
.sugg-manage-row:hover {
  border-color: rgba(58, 42, 30, 0.35);
  background: rgba(20, 12, 7, 0.55);
}

.sugg-manage-color {
  width: 30px;
  height: 30px;
  border: 1px solid rgba(58, 42, 30, 0.4);
  border-radius: 6px;
  padding: 1px;
  cursor: pointer;
  background: transparent;
  flex-shrink: 0;
}
.sugg-manage-color::-webkit-color-swatch-wrapper { padding: 0; }
.sugg-manage-color::-webkit-color-swatch { border: none; border-radius: 4px; }

.sugg-manage-name {
  font-size: 0.84rem;
  font-weight: 600;
  color: var(--text-main);
  flex: 1;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.sugg-manage-slug {
  font-size: 0.68rem;
  font-family: monospace;
  opacity: 0.5;
}

.sugg-manage-icon-preview {
  width: 30px;
  height: 30px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(20, 12, 7, 0.5);
  border: 1px solid rgba(58, 42, 30, 0.3);
  border-radius: 6px;
  color: var(--primary);
  font-size: 0.95rem;
  flex-shrink: 0;
}

.sugg-manage-icon-input {
  width: 100px;
  background: rgba(20, 12, 7, 0.6);
  border: 1px solid rgba(58, 42, 30, 0.35);
  color: var(--text-main);
  font-size: 0.75rem;
  padding: 4px 8px;
  border-radius: 6px;
  font-family: monospace;
  outline: none;
}
.sugg-manage-icon-input:focus {
  border-color: var(--primary);
}

.sugg-manage-delete {
  background: none;
  border: none;
  color: var(--text-muted);
  cursor: pointer;
  padding: 4px 6px;
  border-radius: 6px;
  font-size: 0.8rem;
  transition: all 0.15s;
  flex-shrink: 0;
  opacity: 0.5;
}
.sugg-manage-row:hover .sugg-manage-delete {
  opacity: 1;
}
.sugg-manage-delete:hover {
  color: #c0455a;
  background: rgba(184, 70, 92, 0.1);
}

/* --- Responsive --- */
@media (max-width: 768px) {
  .sugg-modal-layout {
    flex-direction: column;
  }
  .sugg-modal-sidebar {
    width: 100%;
    padding-left: 0;
    border-left: none;
    border-top: 1px solid rgba(58, 42, 30, 0.2);
    padding-top: 14px;
  }
  .sugg-stats {
    justify-content: center;
  }
}


/* =============================================
   PROJECTS MODULE — Minya App
   Premium Dark Theme
   ============================================= */

/* --- 1. Container & Layout --- */
.proj-container { padding: 16px 20px; display: flex; flex-direction: column; gap: 16px; height: 100%; min-height: 0; overflow: hidden; }
.proj-header { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
.proj-header-title { font-size: 1.1rem; font-weight: 600; color: #e9ecef; display: flex; align-items: center; gap: 8px; }
.proj-header-title i { color: #a94c60; }
.proj-new-btn { background: linear-gradient(135deg, #a94c60, #8e3d50); border: none; color: #fff; padding: 8px 16px; border-radius: 8px; font-size: 0.8rem; font-weight: 600; cursor: pointer; transition: all 0.2s; display: flex; align-items: center; gap: 6px; }
.proj-new-btn:hover { transform: translateY(-1px); box-shadow: 0 4px 15px rgba(184, 70, 92, 0.4); }

/* --- 2. Filters bar --- */
.proj-filters { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.proj-filters .form-select, .proj-filters .form-control {
  background: rgba(38, 26, 18, 0.8); border: 1px solid rgba(58, 42, 30, 0.4);
  color: #e9ecef; font-size: 0.8rem; border-radius: 8px; padding: 6px 10px;
  max-width: 160px;
}
.proj-filters .form-select {
  background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3e%3cpath fill='none' stroke='%2394a3b8' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='m2 5 6 6 6-6'/%3e%3c/svg%3e");
  background-repeat: no-repeat; background-position: right 8px center; background-size: 12px;
  padding-right: 28px; appearance: none;
}
.proj-search { max-width: 200px; }

/* --- 3. Projects grid (card list) --- */
.proj-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); gap: 14px; overflow-y: auto; flex: 1; padding-right: 4px; align-content: start; }
.proj-grid::-webkit-scrollbar { width: 5px; }
.proj-grid::-webkit-scrollbar-thumb { background: rgba(119, 100, 84, 0.3); border-radius: 3px; }

.proj-card {
  background: linear-gradient(135deg, rgba(20, 12, 7, 0.85) 0%, rgba(38, 26, 18, 0.6) 100%);
  border: 1px solid rgba(58, 42, 30, 0.3); border-radius: 12px;
  padding: 0; cursor: pointer; transition: all 0.25s ease;
  overflow: hidden; animation: projCardIn 0.3s ease both;
  display: flex; flex-direction: column;
}
.proj-card:hover { border-color: rgba(184, 70, 92, 0.4); transform: translateY(-3px); box-shadow: 0 8px 30px rgba(0, 0, 0, 0.2); }

.proj-card-cover { width: 100%; height: 140px; object-fit: cover; border-bottom: 1px solid rgba(58, 42, 30, 0.2); }
.proj-card-no-cover { width: 100%; height: 60px; background: linear-gradient(135deg, rgba(184, 70, 92, 0.15), rgba(200, 119, 67, 0.1)); display: flex; align-items: center; justify-content: center; border-bottom: 1px solid rgba(58, 42, 30, 0.2); }
.proj-card-no-cover i { font-size: 1.5rem; color: rgba(184, 70, 92, 0.4); }

.proj-card-body { padding: 14px 16px; flex: 1; display: flex; flex-direction: column; gap: 8px; }
.proj-card-title { font-size: 0.95rem; font-weight: 600; color: #e9ecef; line-height: 1.3; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.proj-card-desc { font-size: 0.8rem; color: #b49a82; line-height: 1.4; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.proj-card-author { display: flex; align-items: center; gap: 6px; font-size: 0.78rem; color: #b49a82; }

.proj-card-footer { display: flex; align-items: center; justify-content: space-between; padding: 10px 16px; border-top: 1px solid rgba(58, 42, 30, 0.2); }
.proj-card-stats { display: flex; gap: 12px; font-size: 0.75rem; color: #8b7461; }
.proj-card-stats span { display: flex; align-items: center; gap: 4px; }
.proj-card-stats .stat-up { color: #4f9d69; }
.proj-card-stats .stat-down { color: #c0455a; }

/* --- 4. Status badges --- */
.proj-status { display: inline-flex; align-items: center; gap: 4px; padding: 2px 8px; border-radius: 20px; font-size: 0.7rem; font-weight: 600; text-transform: uppercase; letter-spacing: 0.5px; }
.proj-status-draft { background: rgba(119, 100, 84, 0.2); color: #b49a82; border: 1px solid rgba(119, 100, 84, 0.3); }
.proj-status-pending { background: rgba(154, 138, 78, 0.15); color: #e0a851; border: 1px solid rgba(154, 138, 78, 0.3); }
.proj-status-approved { background: rgba(91, 155, 112, 0.15); color: #6bb383; border: 1px solid rgba(91, 155, 112, 0.3); }
.proj-status-rejected { background: rgba(184, 70, 92, 0.15); color: #d4707f; border: 1px solid rgba(184, 70, 92, 0.3); }
.proj-status-archived { background: rgba(58, 42, 30, 0.2); color: #8b7461; border: 1px solid rgba(58, 42, 30, 0.3); }

/* --- 5. Detail view (2-column layout) --- */
.proj-detail { display: grid; grid-template-columns: 1fr 300px; grid-template-rows: minmax(0, 1fr); gap: 20px; flex: 1; min-height: 0; overflow: hidden; }
.proj-detail-main { overflow-y: auto; min-height: 0; padding-right: 8px; display: flex; flex-direction: column; gap: 20px; }
.proj-detail-main::-webkit-scrollbar { width: 5px; }
.proj-detail-main::-webkit-scrollbar-thumb { background: rgba(119, 100, 84, 0.3); border-radius: 3px; }
.proj-detail-sidebar { overflow-y: auto; min-height: 0; display: flex; flex-direction: column; gap: 14px; }

/* Back button */
.proj-back-btn { background: none; border: 1px solid rgba(58, 42, 30, 0.4); color: #b49a82; padding: 6px 12px; border-radius: 8px; font-size: 0.8rem; cursor: pointer; transition: all 0.15s; display: flex; align-items: center; gap: 6px; }
.proj-back-btn:hover { color: #e9ecef; border-color: rgba(184, 70, 92, 0.5); }

/* Detail header */
.proj-detail-header { display: flex; flex-direction: column; gap: 10px; }
.proj-detail-title { font-size: 1.4rem; font-weight: 700; color: #efe0cd; line-height: 1.3; }
.proj-detail-meta { display: flex; align-items: center; gap: 12px; font-size: 0.8rem; color: #b49a82; flex-wrap: wrap; }

/* Markdown content rendered */
.proj-md-content { background: rgba(20, 12, 7, 0.4); border: 1px solid rgba(58, 42, 30, 0.2); border-radius: 10px; padding: 20px; color: #d6c3ae; font-size: 0.9rem; line-height: 1.7; }
.proj-md-content h1 { font-size: 1.4rem; font-weight: 700; color: #efe0cd; margin: 16px 0 8px; border-bottom: 1px solid rgba(58, 42, 30, 0.3); padding-bottom: 6px; }
.proj-md-content h2 { font-size: 1.2rem; font-weight: 600; color: #e9ecef; margin: 14px 0 6px; }
.proj-md-content h3 { font-size: 1.05rem; font-weight: 600; color: #e9ecef; margin: 12px 0 4px; }
.proj-md-content strong { color: #efe0cd; }
.proj-md-content em { color: #a5b4fc; font-style: italic; }
.proj-md-content del { color: #8b7461; }
.proj-md-content code { background: rgba(184, 70, 92, 0.15); color: #e0a3ae; padding: 2px 6px; border-radius: 4px; font-size: 0.85em; font-family: 'Consolas', monospace; }
.proj-md-content pre { background: rgba(20, 12, 7, 0.8); border: 1px solid rgba(58, 42, 30, 0.3); border-radius: 8px; padding: 14px; overflow-x: auto; margin: 10px 0; }
.proj-md-content pre code { background: none; padding: 0; color: #e9ecef; }
.proj-md-content blockquote { border-left: 3px solid rgba(184, 70, 92, 0.5); padding-left: 12px; color: #b49a82; font-style: italic; margin: 8px 0; }
.proj-md-content a { color: #c05f74; text-decoration: none; }
.proj-md-content a:hover { text-decoration: underline; }
.proj-md-content hr { border: none; border-top: 1px solid rgba(58, 42, 30, 0.3); margin: 16px 0; }
.proj-md-content li { margin-left: 20px; margin-bottom: 4px; }
.proj-md-content img { max-width: 100%; border-radius: 8px; margin: 8px 0; }

/* --- 6. Image gallery --- */
.proj-section-title { font-size: 0.85rem; font-weight: 600; color: #b49a82; text-transform: uppercase; letter-spacing: 0.5px; margin-bottom: 8px; display: flex; align-items: center; gap: 6px; }
.proj-section-title i { color: #a94c60; font-size: 0.8rem; }

.proj-gallery { display: grid; grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); gap: 8px; }
.proj-gallery-item { position: relative; aspect-ratio: 16/10; border-radius: 8px; overflow: hidden; cursor: pointer; border: 1px solid rgba(58, 42, 30, 0.3); transition: all 0.2s; }
.proj-gallery-item:hover { border-color: rgba(184, 70, 92, 0.5); transform: scale(1.02); }
.proj-gallery-item img { width: 100%; height: 100%; object-fit: cover; }
.proj-gallery-item .proj-gallery-delete { position: absolute; top: 4px; right: 4px; background: rgba(184, 70, 92, 0.8); color: #fff; border: none; border-radius: 50%; width: 22px; height: 22px; font-size: 0.65rem; cursor: pointer; opacity: 0; transition: opacity 0.2s; display: flex; align-items: center; justify-content: center; }
.proj-gallery-item:hover .proj-gallery-delete { opacity: 1; }

/* --- 7. Files & links list --- */
.proj-files-list { display: flex; flex-direction: column; gap: 6px; }
.proj-file-item { display: flex; align-items: center; gap: 10px; padding: 8px 12px; background: rgba(38, 26, 18, 0.5); border: 1px solid rgba(58, 42, 30, 0.2); border-radius: 8px; transition: all 0.15s; }
.proj-file-item:hover { border-color: rgba(58, 42, 30, 0.4); background: rgba(38, 26, 18, 0.7); }
.proj-file-icon { width: 32px; height: 32px; border-radius: 6px; display: flex; align-items: center; justify-content: center; font-size: 0.9rem; }
.proj-file-icon.pdf { background: rgba(184, 70, 92, 0.15); color: #d4707f; }
.proj-file-icon.link { background: rgba(200, 119, 67, 0.15); color: #d98b53; }
.proj-file-icon.image { background: rgba(184, 70, 92, 0.15); color: #d16e81; }
.proj-file-name { flex: 1; font-size: 0.82rem; color: #e9ecef; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.proj-file-size { font-size: 0.72rem; color: #8b7461; }
.proj-file-actions { display: flex; gap: 4px; }
.proj-file-actions button { background: none; border: none; color: #8b7461; cursor: pointer; padding: 4px; font-size: 0.8rem; transition: color 0.15s; }
.proj-file-actions button:hover { color: #e9ecef; }
.proj-file-actions button.delete:hover { color: #d4707f; }

/* --- 8. Sidebar blocks (vote, actions, upload) --- */
.proj-sidebar-block { background: rgba(38, 26, 18, 0.6); border: 1px solid rgba(58, 42, 30, 0.3); border-radius: 12px; padding: 16px; }
.proj-sidebar-title { font-size: 0.78rem; font-weight: 600; color: #b49a82; text-transform: uppercase; letter-spacing: 0.5px; margin-bottom: 12px; }

/* Vote block */
.proj-vote-buttons { display: flex; gap: 10px; justify-content: center; margin-bottom: 10px; }
.proj-vote-btn { display: flex; align-items: center; gap: 6px; padding: 8px 18px; border-radius: 8px; border: 1px solid rgba(58, 42, 30, 0.4); background: rgba(20, 12, 7, 0.5); color: #b49a82; cursor: pointer; font-size: 0.85rem; font-weight: 500; transition: all 0.2s; }
.proj-vote-btn:hover { transform: translateY(-1px); }
.proj-vote-btn.up:hover, .proj-vote-btn.up.active { border-color: rgba(91, 155, 112, 0.5); background: rgba(91, 155, 112, 0.15); color: #6bb383; }
.proj-vote-btn.down:hover, .proj-vote-btn.down.active { border-color: rgba(184, 70, 92, 0.5); background: rgba(184, 70, 92, 0.15); color: #d4707f; }
.proj-vote-btn.up.active, .proj-vote-btn.down.active { font-weight: 600; box-shadow: 0 0 10px rgba(0,0,0,0.1); }

.proj-vote-bar { height: 8px; border-radius: 4px; background: rgba(184, 70, 92, 0.25); overflow: hidden; margin: 8px 0; }
.proj-vote-bar-fill { height: 100%; background: linear-gradient(90deg, #4f9d69, #6bb383); border-radius: 4px; transition: width 0.4s ease; }
.proj-vote-ratio { display: flex; justify-content: space-between; font-size: 0.75rem; color: #8b7461; }
.proj-vote-total { text-align: center; font-size: 0.75rem; color: #8b7461; margin-top: 4px; }

/* Actions block */
.proj-action-btn { width: 100%; padding: 8px 12px; border-radius: 8px; border: 1px solid rgba(58, 42, 30, 0.4); background: rgba(20, 12, 7, 0.5); color: #d6c3ae; cursor: pointer; font-size: 0.8rem; transition: all 0.15s; display: flex; align-items: center; gap: 8px; margin-bottom: 6px; }
.proj-action-btn:hover { border-color: rgba(184, 70, 92, 0.5); background: rgba(184, 70, 92, 0.1); }
.proj-action-btn.approve { border-color: rgba(91, 155, 112, 0.3); }
.proj-action-btn.approve:hover { border-color: rgba(91, 155, 112, 0.6); background: rgba(91, 155, 112, 0.15); color: #6bb383; }
.proj-action-btn.reject { border-color: rgba(184, 70, 92, 0.3); }
.proj-action-btn.reject:hover { border-color: rgba(184, 70, 92, 0.6); background: rgba(184, 70, 92, 0.15); color: #d4707f; }
.proj-action-btn.danger { border-color: rgba(184, 70, 92, 0.3); }
.proj-action-btn.danger:hover { border-color: rgba(184, 70, 92, 0.6); background: rgba(184, 70, 92, 0.15); color: #d4707f; }

/* --- 9. Chat (Discord-style) --- */
.proj-chat { display: flex; flex-direction: column; height: 380px; background: rgba(20, 12, 7, 0.5); border: 1px solid rgba(58, 42, 30, 0.3); border-radius: 12px; overflow: hidden; }
.proj-chat-header { padding: 10px 14px; border-bottom: 1px solid rgba(58, 42, 30, 0.3); font-size: 0.85rem; font-weight: 600; color: #b49a82; display: flex; align-items: center; gap: 6px; }
.proj-chat-header i { color: #a94c60; }
.proj-chat-messages { flex: 1; overflow-y: auto; padding: 10px 14px; display: flex; flex-direction: column; gap: 2px; }
.proj-chat-messages::-webkit-scrollbar { width: 4px; }
.proj-chat-messages::-webkit-scrollbar-thumb { background: rgba(119, 100, 84, 0.3); border-radius: 2px; }

.proj-chat-load-more { text-align: center; padding: 8px; }
.proj-chat-load-more button { background: none; border: 1px solid rgba(58, 42, 30, 0.3); color: #8b7461; padding: 4px 12px; border-radius: 6px; font-size: 0.75rem; cursor: pointer; transition: all 0.15s; }
.proj-chat-load-more button:hover { color: #e9ecef; border-color: rgba(184, 70, 92, 0.4); }

.proj-chat-msg { display: flex; gap: 10px; padding: 6px 8px; border-radius: 6px; transition: background 0.15s; position: relative; }
.proj-chat-msg:hover { background: rgba(255, 255, 255, 0.03); }
.proj-chat-msg-avatar { flex-shrink: 0; margin-top: 2px; }
.proj-chat-msg-body { flex: 1; min-width: 0; }
.proj-chat-msg-header { display: flex; align-items: baseline; gap: 8px; }
.proj-chat-msg-author { font-weight: 600; font-size: 0.85rem; color: #e9ecef; }
.proj-chat-msg-time { font-size: 0.7rem; color: #4a3021; }
.proj-chat-msg-edited { font-size: 0.65rem; color: #4a3021; font-style: italic; }
.proj-chat-msg-text { font-size: 0.88rem; line-height: 1.45; color: #d6c3ae; word-break: break-word; margin-top: 2px; }
.proj-chat-msg-deleted .proj-chat-msg-text { color: #4a3021; font-style: italic; }

/* Reply quote */
.proj-chat-msg-reply { font-size: 0.78rem; padding: 4px 10px; background: rgba(184, 70, 92, 0.08); border-left: 3px solid rgba(184, 70, 92, 0.4); border-radius: 0 4px 4px 0; margin-bottom: 4px; color: #8b7461; cursor: pointer; display: flex; align-items: center; gap: 6px; }
.proj-chat-msg-reply:hover { background: rgba(184, 70, 92, 0.12); }
.proj-chat-msg-reply-author { font-weight: 600; color: #b49a82; }

/* Message hover actions */
.proj-chat-msg-actions { position: absolute; top: -8px; right: 8px; display: flex; gap: 2px; opacity: 0; transition: opacity 0.15s; background: rgba(20, 12, 7, 0.9); border: 1px solid rgba(58, 42, 30, 0.3); border-radius: 6px; padding: 2px; }
.proj-chat-msg:hover .proj-chat-msg-actions { opacity: 1; }
.proj-chat-msg-actions button { background: none; border: none; color: #8b7461; cursor: pointer; padding: 3px 6px; font-size: 0.72rem; border-radius: 4px; transition: all 0.1s; }
.proj-chat-msg-actions button:hover { color: #e9ecef; background: rgba(255, 255, 255, 0.05); }
.proj-chat-msg-actions button.delete:hover { color: #d4707f; }

/* Chat input */
.proj-chat-input-wrap { padding: 10px 14px; border-top: 1px solid rgba(58, 42, 30, 0.3); background: rgba(20, 12, 7, 0.6); }
.proj-chat-reply-preview { display: flex; align-items: center; gap: 8px; font-size: 0.78rem; color: #b49a82; padding: 6px 10px; background: rgba(184, 70, 92, 0.08); border-left: 3px solid rgba(184, 70, 92, 0.4); border-radius: 0 6px 6px 0; margin-bottom: 8px; }
.proj-chat-reply-preview .close-reply { background: none; border: none; color: #8b7461; cursor: pointer; margin-left: auto; font-size: 0.75rem; }
.proj-chat-input-row { display: flex; gap: 8px; }
.proj-chat-input { flex: 1; background: rgba(38, 26, 18, 0.6); border: 1px solid rgba(58, 42, 30, 0.3); border-radius: 8px; padding: 9px 14px; color: #e9ecef; font-size: 0.85rem; outline: none; transition: border-color 0.2s; }
.proj-chat-input:focus { border-color: rgba(184, 70, 92, 0.5); }
.proj-chat-input::placeholder { color: #4a3021; }
.proj-chat-send-btn { background: linear-gradient(135deg, #a94c60, #8e3d50); border: none; color: #fff; padding: 0 14px; border-radius: 8px; cursor: pointer; font-size: 0.85rem; transition: all 0.15s; }
.proj-chat-send-btn:hover { box-shadow: 0 2px 10px rgba(184, 70, 92, 0.4); }
.proj-chat-send-btn:disabled { opacity: 0.4; cursor: not-allowed; }

/* --- 10. Updates timeline --- */
.proj-updates-timeline { display: flex; flex-direction: column; gap: 16px; position: relative; padding-left: 20px; }
.proj-updates-timeline::before { content: ''; position: absolute; left: 7px; top: 0; bottom: 0; width: 2px; background: rgba(184, 70, 92, 0.2); }
.proj-update-item { position: relative; background: rgba(38, 26, 18, 0.5); border: 1px solid rgba(58, 42, 30, 0.25); border-radius: 10px; padding: 14px 16px; }
.proj-update-item::before { content: ''; position: absolute; left: -16px; top: 18px; width: 10px; height: 10px; border-radius: 50%; background: #a94c60; border: 2px solid rgba(20, 12, 7, 0.8); }
.proj-update-header { display: flex; align-items: center; justify-content: space-between; margin-bottom: 8px; }
.proj-update-title { font-size: 0.9rem; font-weight: 600; color: #e9ecef; }
.proj-update-date { font-size: 0.72rem; color: #8b7461; }
.proj-update-content { font-size: 0.85rem; color: #b49a82; line-height: 1.5; }
.proj-update-delete { background: none; border: none; color: #4a3021; cursor: pointer; font-size: 0.75rem; transition: color 0.15s; }
.proj-update-delete:hover { color: #d4707f; }

/* --- 11. Modal (creation/edition) --- */
.proj-modal-overlay { position: fixed; inset: 0; background: rgba(0, 0, 0, 0.7); backdrop-filter: blur(4px); z-index: 9000; display: flex; align-items: center; justify-content: center; opacity: 0; transition: opacity 0.2s; pointer-events: none; }
.proj-modal-overlay.visible { opacity: 1; pointer-events: all; }
.proj-modal { background: linear-gradient(135deg, #1a0f07 0%, #241710 100%); border: 1px solid rgba(58, 42, 30, 0.4); border-radius: 16px; width: 90%; max-width: 800px; max-height: 85vh; display: flex; flex-direction: column; transform: scale(0.95); transition: transform 0.2s; box-shadow: 0 25px 60px rgba(0, 0, 0, 0.5); }
.proj-modal-overlay.visible .proj-modal { transform: scale(1); }
.proj-modal-header { display: flex; align-items: center; justify-content: space-between; padding: 16px 20px; border-bottom: 1px solid rgba(58, 42, 30, 0.3); }
.proj-modal-header span { font-size: 1rem; font-weight: 600; color: #e9ecef; display: flex; align-items: center; gap: 8px; }
.proj-modal-header span i { color: #a94c60; }
.proj-modal-close { background: none; border: none; color: #8b7461; cursor: pointer; font-size: 1.1rem; transition: color 0.15s; }
.proj-modal-close:hover { color: #e9ecef; }
.proj-modal-body { flex: 1; overflow-y: auto; padding: 20px; display: flex; flex-direction: column; gap: 16px; }
.proj-modal-body::-webkit-scrollbar { width: 5px; }
.proj-modal-body::-webkit-scrollbar-thumb { background: rgba(119, 100, 84, 0.3); border-radius: 3px; }
.proj-modal-body label { font-size: 0.8rem; font-weight: 600; color: #b49a82; margin-bottom: 4px; }
.proj-modal-body input[type="text"], .proj-modal-body textarea { width: 100%; background: rgba(20, 12, 7, 0.6); border: 1px solid rgba(58, 42, 30, 0.4); border-radius: 8px; padding: 10px 14px; color: #e9ecef; font-size: 0.85rem; outline: none; transition: border-color 0.2s; }
.proj-modal-body input[type="text"]:focus, .proj-modal-body textarea:focus { border-color: rgba(184, 70, 92, 0.5); }
.proj-modal-body textarea { min-height: 200px; resize: vertical; font-family: 'Consolas', 'Monaco', monospace; line-height: 1.6; }
.proj-modal-footer { display: flex; align-items: center; justify-content: flex-end; gap: 8px; padding: 14px 20px; border-top: 1px solid rgba(58, 42, 30, 0.3); }
.proj-modal-btn { padding: 8px 18px; border-radius: 8px; font-size: 0.82rem; font-weight: 500; cursor: pointer; transition: all 0.15s; border: none; }
.proj-modal-btn.cancel { background: rgba(58, 42, 30, 0.3); color: #b49a82; }
.proj-modal-btn.cancel:hover { background: rgba(58, 42, 30, 0.5); color: #e9ecef; }
.proj-modal-btn.primary { background: linear-gradient(135deg, #a94c60, #8e3d50); color: #fff; }
.proj-modal-btn.primary:hover { box-shadow: 0 4px 15px rgba(184, 70, 92, 0.4); }
.proj-modal-btn.submit { background: linear-gradient(135deg, #d9963c, #d97706); color: #fff; }
.proj-modal-btn.submit:hover { box-shadow: 0 4px 15px rgba(154, 138, 78, 0.4); }

/* --- 12. Markdown Editor --- */
.proj-editor-wrap { display: flex; flex-direction: column; }
.proj-editor-wrap label { margin-bottom: 6px; }

.proj-md-toolbar { display: flex; align-items: center; gap: 1px; flex-wrap: wrap; padding: 5px 8px; background: rgba(20, 12, 7, 0.8); border: 1px solid rgba(58, 42, 30, 0.4); border-bottom: none; border-radius: 8px 8px 0 0; }
.proj-md-toolbar .md-tb-group { display: flex; gap: 1px; align-items: center; }
.proj-md-toolbar button { background: none; border: 1px solid transparent; color: #8b7461; padding: 5px 7px; border-radius: 4px; cursor: pointer; font-size: 0.78rem; transition: all 0.15s; white-space: nowrap; }
.proj-md-toolbar button:hover { color: #e9ecef; background: rgba(184, 70, 92, 0.15); border-color: rgba(184, 70, 92, 0.3); }
.proj-md-toolbar button.active,
.proj-md-toolbar .md-tb-toggle.active { background: rgba(184, 70, 92, 0.2); color: #d16e81; border-color: rgba(184, 70, 92, 0.4); }
.proj-md-toolbar .sep { width: 1px; height: 20px; background: rgba(58, 42, 30, 0.3); margin: 0 5px; flex-shrink: 0; }
.proj-md-toolbar .md-tb-right { display: flex; gap: 2px; margin-left: auto; }

/* Dropdown in toolbar */
.md-tb-dropdown { position: relative; }
.md-tb-dropdown-trigger { display: flex; align-items: center; gap: 3px; }
.md-tb-dropdown-menu { display: none; position: absolute; top: 100%; left: 0; z-index: 50; min-width: 150px; background: #241710; border: 1px solid rgba(58, 42, 30, 0.5); border-radius: 8px; padding: 4px; box-shadow: 0 8px 24px rgba(0,0,0,0.4); margin-top: 4px; }
.md-tb-dropdown-menu.open { display: flex; flex-direction: column; }
.md-tb-dropdown-menu button { justify-content: space-between; width: 100%; text-align: left; padding: 6px 10px; font-size: 0.78rem; border-radius: 5px; }
.md-tb-dropdown-menu button:hover { background: rgba(184, 70, 92, 0.15); }
.md-shortcut { color: #4a3021; font-size: 0.68rem; font-weight: 600; }

/* Editor area */
.proj-editor-area { display: flex; flex-direction: column; min-height: 0; }
.proj-editor-area textarea { border-radius: 0; border-top: none; min-height: 250px; flex: 1; }
.proj-editor-area.split-active { flex-direction: row; }
.proj-editor-area.split-active textarea { width: 50%; min-height: 300px; border-radius: 0 0 0 8px; border-right: 1px solid rgba(58, 42, 30, 0.3); }
.proj-editor-area.split-active .proj-md-split-preview { display: block !important; width: 50%; overflow-y: auto; padding: 14px; border: 1px solid rgba(58, 42, 30, 0.4); border-top: none; border-left: none; border-radius: 0 0 8px 0; background: rgba(20, 12, 7, 0.4); max-height: 400px; }
.proj-editor-area.preview-only textarea { display: none !important; }
.proj-editor-area.preview-only .proj-md-split-preview { display: block !important; width: 100%; overflow-y: auto; padding: 14px; border: 1px solid rgba(58, 42, 30, 0.4); border-top: none; border-radius: 0 0 8px 8px; background: rgba(20, 12, 7, 0.4); min-height: 250px; max-height: 500px; }

/* Footer counter */
.proj-editor-footer { display: flex; align-items: center; justify-content: space-between; padding: 5px 10px; background: rgba(20, 12, 7, 0.5); border: 1px solid rgba(58, 42, 30, 0.4); border-top: none; border-radius: 0 0 8px 8px; }
.proj-editor-counter { font-size: 0.68rem; color: #4a3021; }
.proj-editor-hint { font-size: 0.68rem; color: #4a3021; }

/* Fullscreen modal */
.proj-modal-fullscreen { width: 100% !important; max-width: 100% !important; max-height: 100vh !important; height: 100vh; border-radius: 0 !important; }
.proj-modal-fullscreen .proj-editor-area textarea { min-height: 50vh; }
.proj-modal-fullscreen .proj-editor-area.split-active .proj-md-split-preview { max-height: 60vh; }

/* --- Rendered markdown extras --- */
.proj-md-content mark { background: rgba(250, 204, 21, 0.25); color: #fde68a; padding: 1px 4px; border-radius: 3px; }
.proj-md-content u { text-decoration-color: rgba(184, 70, 92, 0.5); text-underline-offset: 2px; }
.proj-md-content h4 { font-size: 0.92rem; font-weight: 600; color: #d6c3ae; margin: 10px 0 4px; }
.proj-md-content .md-check { list-style: none; display: flex; align-items: center; gap: 6px; padding: 3px 0; }
.proj-md-content .md-check input[type="checkbox"] { accent-color: #a94c60; width: 15px; height: 15px; cursor: default; }
.proj-md-content .md-check.checked { color: #8b7461; text-decoration: line-through; }
.proj-md-content .proj-md-table { width: 100%; border-collapse: collapse; margin: 8px 0; font-size: 0.82rem; }
.proj-md-content .proj-md-table th { background: rgba(38, 26, 18, 0.8); padding: 8px 12px; text-align: left; font-weight: 600; color: #e9ecef; border: 1px solid rgba(58, 42, 30, 0.4); }
.proj-md-content .proj-md-table td { padding: 7px 12px; border: 1px solid rgba(58, 42, 30, 0.3); color: #d6c3ae; }
.proj-md-content .proj-md-table tr:nth-child(even) td { background: rgba(20, 12, 7, 0.3); }
.proj-md-content .proj-md-table tr:hover td { background: rgba(184, 70, 92, 0.05); }
.proj-md-content details { margin: 8px 0; border: 1px solid rgba(58, 42, 30, 0.3); border-radius: 8px; overflow: hidden; }
.proj-md-content details summary { padding: 8px 14px; background: rgba(38, 26, 18, 0.5); cursor: pointer; font-weight: 500; color: #e9ecef; font-size: 0.85rem; transition: background 0.15s; }
.proj-md-content details summary:hover { background: rgba(38, 26, 18, 0.8); }
.proj-md-content details[open] summary { border-bottom: 1px solid rgba(58, 42, 30, 0.3); }
.proj-md-content details > *:not(summary) { padding: 0 14px; }

/* --- 13. Upload drop zone --- */
.proj-dropzone { border: 2px dashed rgba(58, 42, 30, 0.4); border-radius: 10px; padding: 24px; text-align: center; color: #8b7461; font-size: 0.82rem; transition: all 0.2s; cursor: pointer; }
.proj-dropzone:hover, .proj-dropzone.drag-over { border-color: rgba(184, 70, 92, 0.5); background: rgba(184, 70, 92, 0.05); color: #d16e81; }
.proj-dropzone i { font-size: 1.5rem; display: block; margin-bottom: 6px; }
.proj-dropzone-hint { font-size: 0.72rem; margin-top: 4px; }

/* --- 14. Empty state --- */
.proj-empty { display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 60px 20px; color: #4a3021; }
.proj-empty i { font-size: 3rem; margin-bottom: 12px; color: rgba(184, 70, 92, 0.3); }
.proj-empty p { font-size: 0.95rem; color: #8b7461; margin-bottom: 4px; }
.proj-empty span { font-size: 0.8rem; color: #4a3021; }

/* --- 15. Animations --- */
@keyframes projCardIn { from { opacity: 0; transform: translateY(12px); } to { opacity: 1; transform: translateY(0); } }
.proj-chat-msg-new { animation: projMsgIn 0.4s ease; }
@keyframes projMsgIn {
  0% { opacity: 0; transform: translateY(6px); }
  50% { opacity: 1; transform: translateY(0); background-color: rgba(122, 74, 42,0.06); }
  100% { opacity: 1; transform: translateY(0); background-color: transparent; }
}

/* --- 16. Lightbox with navigation --- */
.proj-lightbox { position: fixed; inset: 0; z-index: 10000; display: flex; align-items: center; justify-content: center; opacity: 0; transition: opacity 0.2s; }
.proj-lightbox.visible { opacity: 1; }
.proj-lightbox-backdrop { position: absolute; inset: 0; background: rgba(0, 0, 0, 0.85); backdrop-filter: blur(8px); }
.proj-lightbox img { position: relative; max-width: 90vw; max-height: 90vh; object-fit: contain; border-radius: 8px; box-shadow: 0 0 40px rgba(0, 0, 0, 0.5); }
.proj-lightbox-close { position: absolute; top: 16px; right: 16px; background: rgba(38, 26, 18, 0.8); border: 1px solid rgba(58, 42, 30, 0.4); color: #e9ecef; width: 36px; height: 36px; border-radius: 50%; font-size: 1rem; cursor: pointer; display: flex; align-items: center; justify-content: center; transition: all 0.15s; z-index: 1; }
.proj-lightbox-close:hover { background: rgba(184, 70, 92, 0.5); border-color: rgba(184, 70, 92, 0.6); }
.proj-lightbox-nav { position: absolute; top: 50%; transform: translateY(-50%); background: rgba(38, 26, 18, 0.8); border: 1px solid rgba(58, 42, 30, 0.4); color: #e9ecef; width: 40px; height: 40px; border-radius: 50%; font-size: 1.1rem; cursor: pointer; display: flex; align-items: center; justify-content: center; transition: all 0.15s; z-index: 1; }
.proj-lightbox-nav:hover { background: rgba(184, 70, 92, 0.4); border-color: rgba(184, 70, 92, 0.5); }
.proj-lightbox-prev { left: 16px; }
.proj-lightbox-next { right: 16px; }
.proj-lightbox-counter { position: absolute; bottom: 16px; left: 50%; transform: translateX(-50%); background: rgba(20, 12, 7, 0.8); color: #b49a82; padding: 4px 12px; border-radius: 20px; font-size: 0.78rem; z-index: 1; }
