th {
  font-weight: bold !important;
}

.task-manager-section {
    display: flex;
    flex-direction: column;
    gap: 0;
    border-radius: 8px;
    overflow: hidden;
    width: 100%;
}

.task-manager-header {
    display: flex;
    flex-direction: row;
    justify-content: space-between;
    align-items: center;
    padding: 16px 24px;
}

.task-manager-title {
    font-size: 1.8rem;
    font-weight: 600;
    color: #1a1a2e;
    margin: 0;
}

.add-task-btn, .import-task-btn, .ai-assist-btn {
    background-color: #2563eb;
    color: #ffffff;
    border: none;
    border-radius: 8px;
    padding: 10px 20px;
    font-size: 0.95rem;
    font-weight: 600;
    cursor: pointer;
    transition: background-color 0.2s ease;
}

.view-subtasks-btn {
    background-color: #2563eb;
    color: #ffffff;
    border: none;
    border-radius: 8px;
    padding: 0px 10px;
    font-size: 0.75rem;
    font-weight: 600;
    width: 110px;
    height: 30px;
    cursor: pointer;
    margin-top: 5%;
    transition: background-color 0.2s ease;
}

.add-task-btn:hover, .import-task-btn:hover, .ai-assist-btn:hover {
    background-color: #1d4ed8;
}

/* ── Row 2: Toolbar ── */
.task-manager-toolbar {
    display: flex;
    flex-direction: row;
    justify-content: space-between;
    align-items: center;
    padding: 0px 24px;
}

.view-toggle {
    display: flex;
    flex-direction: row;
    gap: 6px;
}

.toggle-btn {
    display: flex;
    align-items: center;
    gap: 6px;

    background-color: #ffffff;
    color: #374151;
    border: 1px solid #d1d5db;
    border-radius: 6px;
    padding: 6px 14px;
    font-size: 0.9rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
}

.toggle-btn:hover:not(.view-active) {
    background-color: #f3f4f6;
}

/* ── Right Controls: Search + Filter ── */
.task-controls {
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 10px;
}

/* ── Search Box ── */
.search-box {
    display: flex;
    align-items: center;
    gap: 8px;

    background-color: #ffffff;
    border: 1px solid #d1d5db;
    border-radius: 6px;
    padding: 6px 14px;
}

.search-box svg {
    color: #9ca3af;
    flex-shrink: 0;
}

.search-box input {
    border: none;
    outline: none;
    font-size: 0.9rem;
    color: #374151;
    background: transparent;
    width: 180px;
}

.search-box input::placeholder {
    color: #9ca3af;
}

/* ── Filter Button ── */
.filter-btn, button.filter-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;

    -webkit-appearance: none;
    appearance: none;
    background-color: #ffffff !important;
    color: #374151 !important;
    border: 1px solid #d1d5db !important;
    border-radius: 6px;
    padding: 6px 14px;
    font-size: 0.9rem;
    font-weight: 500;
    cursor: pointer;
    transition: background-color 0.2s ease;
}

.filter-btn:hover, button.filter-btn:hover {
    background-color: #f3f4f6 !important;
}

.kanban-board {
    display: flex;
    gap: 20px;
    padding: 20px;
    overflow-x: auto;
    height: calc(100vh - 100px);
    align-items: flex-start;
}

.kanban-column {
    background: #f4f5f7;
    border-radius: 10px;
    min-width: 225px;
    max-width: 275px;
    padding: 15px;
    flex-shrink: 0;
    display: flex;
    flex-direction: column;
    height: fit-content;
    min-height: 500px;
    box-shadow: 0 0 0 0.2rem rgba(0,123,255,.25);
}

.kanban-column h3 {
    text-align: center;
    font-size: 16px;
    margin-bottom: 15px;
    color: #333;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.task-card {
    background: white;
    border-radius: 8px;
    padding: 12px;
    margin-bottom: 12px;
    font-size: 13px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    border-left: 4px solid #999;
    cursor: pointer;
    transition: box-shadow 0.2s ease;
}

.task-card:hover {
    box-shadow: 0 4px 8px rgba(0,0,0,0.15);
}

.task-card.priority-1 { border-left-color: #e53935; }
.task-card.priority-2 { border-left-color: #fbc02d; }
.task-card.priority-3 { border-left-color: #43a047; }

.task-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 8px;
}

.task-title {
    font-weight: 600;
    font-size: 14px;
    color: #172b4d;
    line-height: 1.4;
    flex: 1;
    margin-right: 8px;
}

.priority-icon {
    width: 16px;
    height: 16px;
    border-radius: 50%;
    flex-shrink: 0;
}

.priority-1 .priority-icon { background-color: #e53935; }
.priority-2 .priority-icon { background-color: #fbc02d; }
.priority-3 .priority-icon { background-color: #43a047; }

.task-meta {
    font-size: 12px;
    color: #5e6c84;
    margin-bottom: 8px;
}

.task-meta-item {
    margin-bottom: 2px;
}

.assignee {
    display: flex;
    align-items: center;
    margin-bottom: 8px;
}

.assignee-avatar {
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background-color: #0052cc;
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 10px;
    font-weight: 600;
    margin-right: 8px;
    flex-shrink: 0;
}

.assignee-name {
    font-size: 12px;
    color: #5e6c84;
}

.progress-section {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.progress-bar {
    background: #dfe1e6;
    border-radius: 3px;
    overflow: hidden;
    height: 6px;
    flex: 1;
    margin-right: 8px;
}

.progress-fill {
    height: 6px;
    background: #4caf50;
    border-radius: 3px;
}

.progress-text {
    font-size: 11px;
    color: #5e6c84;
    font-weight: 500;
}

.no-tasks {
    font-size: 12px;
    color: #8993a4;
    text-align: center;
    padding: 20px;
    font-style: italic;
}
.kanban-column.drag-over {
    outline: 3px dashed rgba(13,110,253,0.5);
    background: rgba(13,110,253,0.03);
}
/* List view styles */
.list-view { padding: 20px; }
.list-table { width: 100%; border-collapse: collapse; }
.list-table thead th { text-align: left; padding: 10px; background: #999898; border-bottom: 1px solid #e0e6ef; font-size: 13px; }
.list-table tbody td { padding: 10px; border-bottom: 1px solid #f0f2f5; vertical-align: middle; font-size: 13px; }
.list-row { cursor: pointer; }
/* .list-row:hover { background: #cacacb; } */
/* More specific selectors to override the sortable striping on odd rows */
/* .list-table.sortable tbody tr:hover,
.list-table.sortable tbody tr.list-row:hover,
.list-table.sortable tbody tr:hover td {
    background-color: #cacacb !important;
    color: inherit !important;
} */
.list-table tr:nth-child(even) {
    background-color: #ffffff !important; 
}
.view-active { background-color: #0d6efd; color: white; border-color: #0d6efd; }

/* Subtask toggle styles */
.subtask-toggle {
    width: 20px;
    height: 20px;
    border: none;
    background: transparent;
    padding: 0;
    margin-right: 8px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    flex-shrink: 0;
}

.subtask-toggle .arrow {
    display: inline-block;
    width: 0;
    height: 0;
    border-top: 6px solid transparent;
    border-bottom: 6px solid transparent;
    border-left: 8px solid #374151; /* right-pointing arrow */
    transition: transform 0.15s ease;
}

.subtask-toggle[aria-expanded="true"] .arrow {
    transform: rotate(90deg);
}

.subtasks-container {
    margin-top: 8px;
    padding-left: 28px;
    font-size: 13px;
    color: #374151;
}

.subtask-item { display: flex; justify-content: space-between; gap: 8px; padding: 4px 0; }

/* Badges for Status and Priority */
.badge, .badge2 {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 4px 12px;
    border-radius: 6px;
    font-size: 0.82rem;
    font-weight: 600;
}

.badge-backlog {
    background-color: #ffe5fb;
    color: #ed0bf5;
    border: 1px solid #fc4df3;
}

.badge-on-hold {
    background-color: #fff4e5;
    color: #f59e0b;
    border: 1px solid #fcd34d;
}

.badge-in-progress {
    background-color: #eff6ff;
    color: #2563eb;
    border: 1px solid #93c5fd;
}

.badge-in-review {
    background-color: #fffeef;
    color: #d4eb25;
    border: 1px solid #f8fd93;
}

.badge-done {
    background-color: #f0fdf4;
    color: #16a34a;
    border: 1px solid #86efac;
}

.badge-high {
    background-color: #fff1f1;
    color: #ef4444;
    border: 1px solid #fca5a5;
}

.badge-medium {
    background-color: #fefce8;
    color: #ca8a04;
    border: 1px solid #fde047;
}

.badge-low {
    background-color: #f0fdf4;
    color: #16a34a;
    border: 1px solid #86efac;
}

/*Dropdown menu*/

.dropdown-wrapper {
    position: relative;
    display: inline-block;
}

/* ── Trigger Button ── */
.action-btn {
    display: inline-flex;
    align-items: center;
    gap: 1px;

    background-color: #2563eb;
    color: #ffffff;
    border: none;
    border-radius: 8px;
    padding: 8px 10px;
    font-size: 0.9rem;
    font-weight: 600;
    cursor: pointer;
    transition: background-color 0.2s ease;
    margin-top: auto;
}

.action-btn:hover {
    background-color: #1d4ed8;
}

.dropdown-menu {
    display: none; /* Hidden by default */
    position: absolute;
    top: calc(100% + 4px); /* Just below the button (reduced) */
    right: 0;              /* Align to right edge of button */
    z-index: 100;

    background-color: #ffffff;
    /* remove visible border so hover backgrounds can reach the very top/bottom */
    border: 0;
    border-radius: 8px;
    box-shadow: 0 6px 18px rgba(0, 0, 0, 0.12);

    min-width: 160px;
    overflow: hidden;
    padding: 0; /* ensure no extra internal spacing */
}

.dropdown-menu.open {
    display: block;
}

.dropdown-menu ul {
    list-style: none;
    margin: 0;
    padding: 0;
}

.dropdown-menu li {
    margin: 0;
    padding: 0;
    line-height: 1;
}

.dropdown-item {
    display: block;
    width: 100%;
    padding: 6px 12px; /* tighter vertical spacing */
    margin: 0;

    background: none;
    border: none;
    text-align: left;

    font-size: 0.9rem;
    font-weight: 400;
    color: #374151;
    cursor: pointer;

    transition: background-color 0.15s ease;
    border-radius: 0; /* let the menu's rounding handle corners */
}

/* Ensure hover/background covers rounded corners at top/bottom */
.dropdown-item:first-child,
.dropdown-item:last-child {
    /* no per-item rounding to avoid tiny gaps at edges */
    border-radius: 0;
}

.dropdown-item:hover {
    background-color: #f3f4f6;
}

/* Filter panel styles */
.filter-panel {
    position: absolute;
    top: 64px; /* below the toolbar */
    right: 24px;
    z-index: 1200;
    background: #ffffff;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    padding: 12px;
    box-shadow: 0 8px 24px rgba(15,23,42,0.12);
    min-width: 260px;
}
.filter-row { display:flex; flex-direction: column; gap:6px; margin-bottom:8px; }
.filter-row label { font-size: 0.8rem; color: #374151; font-weight:600; }
.filter-row select, .filter-row input { padding:6px 8px; border:1px solid #d1d5db; border-radius:6px; font-size:0.9rem; }
.filter-actions { display:flex; gap:8px; justify-content:flex-end; margin-top:6px; }

/* Ensure filter panel doesn't cover kanban scrollbar on small screens */
@media (max-width: 900px){
    .filter-panel { right: 12px; left: 12px; top: auto; bottom: 20px; }
}

.col-comments { position: relative; }

.comment-unread-counter {
	position: relative;
	top: -2px;
	right: -2px;
	background: #dc3545; /* bootstrap danger red */
	color: #ffffff;
	border-radius: 50%;
	min-width: 18px;
	height: 18px;
	padding: 0 5px;
	font-size: 0.65rem;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	box-shadow: 0 1px 3px rgba(0,0,0,0.2);
}