:root {
    --dark-bg: #0f172a;
    --darker-bg: #0a0f1f;
    --card-bg: #1e293b;
    --card-hover: #334155;
    --border-color: #334155;
    --accent: #818cf8;
    --accent-hover: #6366f1;
    --accent-light: rgba(129, 140, 248, 0.1);
    --danger: #ef4444;
    --success: #22c55e;
    --warning: #f59e0b;
    --text: #f1f5f9;
    --text-secondary: #94a3b8;
    --radius: 12px;
    --shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.3), 0 4px 6px -4px rgba(0, 0, 0, 0.3);
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

::-webkit-scrollbar {
    width: 14px;
    height: 14px;
}

::-webkit-scrollbar-track {
    background: linear-gradient(135deg, var(--darker-bg) 0%, rgba(30, 41, 59, 0.8) 100%);
    border-radius: 8px;
    box-shadow: inset 0 0 6px rgba(0, 0, 0, 0.4);
    border: 1px solid var(--border-color);
}

::-webkit-scrollbar-thumb {
    background: linear-gradient(135deg, var(--accent) 0%, #6366f1 50%, #4f46e5 100%);
    border-radius: 8px;
    border: 2px solid var(--darker-bg);
    box-shadow: 0 0 12px rgba(129, 140, 248, 0.4);
    transition: var(--transition);
}

::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(135deg, var(--accent-hover) 0%, #6366f1 50%, #4f46e5 100%);
    box-shadow: 0 0 18px rgba(129, 140, 248, 0.6);
    transform: scale(1.05);
}

::-webkit-scrollbar-thumb:active {
    background: linear-gradient(135deg, #6366f1 0%, #4f46e5 50%, #4338ca 100%);
}

::-webkit-scrollbar-corner {
    background: var(--darker-bg);
}

* {
    scrollbar-width: thin;
    scrollbar-color: var(--accent) var(--darker-bg);
}

.kanban-board::-webkit-scrollbar {
    height: 16px;
}

.kanban-board::-webkit-scrollbar-thumb {
    background: linear-gradient(90deg, var(--accent) 0%, #6366f1 50%, #4f46e5 100%);
}

.modal::-webkit-scrollbar,
.chat-messages::-webkit-scrollbar,
.users-list::-webkit-scrollbar {
    width: 10px;
}

.modal::-webkit-scrollbar-thumb,
.chat-messages::-webkit-scrollbar-thumb,
.users-list::-webkit-scrollbar-thumb {
    background: linear-gradient(135deg, var(--accent) 0%, #6366f1 100%);
    border: 1px solid var(--darker-bg);
}

::-webkit-scrollbar-thumb {
    animation: scrollbarAppear 0.5s ease;
}

@keyframes scrollbarAppear {
    from {
        opacity: 0;
        transform: scale(0.8);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Segoe UI', system-ui, -apple-system, sans-serif;
}

body {
    background: linear-gradient(135deg, var(--dark-bg) 0%, var(--darker-bg) 100%);
    color: var(--text);
    min-height: 100vh;
    overflow-x: hidden;
    line-height: 1.6;
}

#background-canvas {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
}

.screen {
    display: none;
    min-height: 100vh;
    flex-direction: column;
}

.screen.active {
    display: flex;
}

@keyframes fadeIn {
    from { 
        opacity: 0; 
        transform: translateY(20px) scale(0.95); 
    }
    to { 
        opacity: 1; 
        transform: translateY(0) scale(1); 
    }
}

@keyframes slideIn {
    from { transform: translateY(-100%); }
    to { transform: translateY(0); }
}

@keyframes pulse {
    0% { box-shadow: 0 0 0 0 rgba(129, 140, 248, 0.4); }
    70% { box-shadow: 0 0 0 10px rgba(129, 140, 248, 0); }
    100% { box-shadow: 0 0 0 0 rgba(129, 140, 248, 0); }
}

.notification-container {
    position: fixed;
    bottom: 20px;
    right: 20px;
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 10px;
    z-index: 2000;
    pointer-events: none;
    max-width: 400px;
}

.notification {
    background: linear-gradient(135deg, var(--warning) 0%, #d97706 100%);
    color: #000;
    padding: 1rem 1.5rem;
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    animation: slideInRight 0.4s forwards, fadeOutRight 0.4s forwards 3s;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 0.75rem;
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    opacity: 0;
    transform: translateX(100%);
}

.notification.success {
    background: linear-gradient(135deg, var(--success) 0%, #16a34a 100%);
    color: white;
}

.notification.error {
    background: linear-gradient(135deg, var(--danger) 0%, #dc2626 100%);
    color: white;
}

@keyframes slideInRight {
    from {
        opacity: 0;
        transform: translateX(100%);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes fadeOutRight {
    to {
        opacity: 0;
        transform: translateX(30px);
    }
}

.login-container {
    max-width: 420px;
    margin: auto;
    padding: 3rem 2.5rem;
    background: rgba(30, 41, 59, 0.7);
    backdrop-filter: blur(10px);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    text-align: center;
    border: 1px solid var(--border-color);
    animation: fadeIn 0.6s ease-out;
}

.login-container h1 {
    font-size: 3.5rem;
    margin-bottom: 2.5rem;
    color: var(--accent);
    font-weight: 800;
    letter-spacing: -1px;
    text-shadow: 0 0 20px rgba(129, 140, 248, 0.4);
}

.input-group {
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
    margin-bottom: 1.5rem;
}

.input-group input {
    padding: 1rem;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    background-color: rgba(15, 23, 42, 0.6);
    color: var(--text);
    font-size: 1rem;
    transition: var(--transition);
}

.input-group input:focus {
    outline: none;
    border-color: var(--accent);
    box-shadow: 0 0 0 3px rgba(129, 140, 248, 0.3);
}

button {
    padding: 0.9rem 1.75rem;
    background-color: var(--accent);
    color: white;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-weight: 600;
    transition: var(--transition);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

button:hover {
    background-color: var(--accent-hover);
    transform: translateY(-2px);
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.2), 0 2px 4px -2px rgba(0, 0, 0, 0.2);
}

header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.25rem 2.5rem;
    background-color: rgba(10, 15, 31, 0.8);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--border-color);
    position: sticky;
    top: 0;
    z-index: 100;
}

.logo {
    font-size: 1.8rem;
    font-weight: 800;
    color: var(--accent);
    display: flex;
    align-items: center;
    gap: 10px;
}

nav {
    display: flex;
    gap: 0.75rem;
}

nav button {
    background: rgba(129, 140, 248, 0.1);
    color: var(--text);
    border: 1px solid var(--border-color);
    font-size: 0.95rem;
}

nav button:hover {
    background-color: rgba(129, 140, 248, 0.2);
    border-color: var(--accent);
}

main {
    flex: 1;
    padding: 2rem 2.5rem;
}

.page {
    display: none;
    animation: fadeIn 0.4s ease;
}

.page.active {
    display: block;
}

h2 {
    font-size: 1.8rem;
    margin-bottom: 1.5rem;
    color: var(--text);
    font-weight: 700;
    display: flex;
    align-items: center;
    gap: 10px;
}

.board-selector {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1.5rem;
}

.board-selector label {
    margin-bottom: 0;
    font-weight: 500;
}

.kanban-board {
    display: flex;
    gap: 1.5rem;
    min-height: 400px;
    overflow-x: auto;
    padding: 0.5rem 0.5rem 2rem;
    align-items: flex-start;
}

.kanban-column {
    flex: 0 0 340px;
    background-color: var(--card-bg);
    border-radius: var(--radius);
    display: flex;
    flex-direction: column;
    box-shadow: var(--shadow);
    overflow: hidden;
    transition: var(--transition);
    border: 1px solid var(--border-color);
}

.kanban-column:hover {
    transform: translateY(-5px);
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.2), 0 8px 10px -6px rgba(0, 0, 0, 0.2);
}

.column-header {
    padding: 1.25rem;
    background-color: rgba(0, 0, 0, 0.2);
    border-bottom: 1px solid var(--border-color);
    text-align: center;
    font-weight: 700;
    font-size: 1.25rem;
    position: relative;
}

.column-header::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 40px;
    height: 4px;
    background: var(--accent);
    border-radius: 2px;
}

.column-content {
    flex: 1;
    padding: 1.25rem;
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.subsection-group {
    background-color: rgba(255, 255, 255, 0.05);
    border-radius: var(--radius);
    overflow: hidden;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -2px rgba(0, 0, 0, 0.1);
    animation: fadeIn 0.5s ease;
    margin-bottom: 1rem;
}

.subsection-group.collapsed .subsection-content {
    display: none;
}

.subsection-header {
    padding: 0.9rem 1.25rem;
    background-color: rgba(0, 0, 0, 0.15);
    font-weight: 600;
    color: var(--accent);
    display: flex;
    justify-content: space-between;
    align-items: center;
    cursor: pointer;
    transition: var(--transition);
}

.subsection-header:hover {
    background-color: rgba(0, 0, 0, 0.2);
}

.subsection-title {
    display: flex;
    align-items: center;
    gap: 8px;
}

.task-count {
    background: var(--accent-light);
    color: var(--accent);
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 500;
}

.toggle-subsection {
    background: none;
    border: none;
    color: var(--text);
    cursor: pointer;
    transition: var(--transition);
}

.subsection-group.collapsed .toggle-subsection {
    transform: rotate(-90deg);
}

.subsection-content {
    padding: 1rem;
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.task {
    background-color: rgba(15, 23, 42, 0.5);
    padding: 1.25rem;
    border-radius: var(--radius);
    cursor: grab;
    border-left: 4px solid var(--accent);
    transition: var(--transition);
    position: relative;
    overflow: hidden;
    flex-shrink: 0;
    animation: fadeIn 0.4s ease;
    backdrop-filter: blur(4px);
}

.task:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.2), 0 4px 6px -4px rgba(0, 0, 0, 0.2);
    background-color: var(--card-hover);
}

.task.dragging {
    opacity: 0.7;
    transform: rotate(2deg);
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.2), 0 8px 10px -6px rgba(0, 0, 0, 0.2);
}

.task.urgent {
    border-left-color: var(--danger);
    animation: pulse 2s infinite;
}

.task.completed {
    border-left-color: var(--success);
}

.task.archived {
    border-left-color: var(--text-secondary);
    opacity: 0.7;
}

.task-title {
    font-weight: 600;
    margin-bottom: 0.5rem;
    font-size: 1.1rem;
    display: flex;
    align-items: center;
    gap: 8px;
}

.task-subsection {
    font-size: 0.85rem;
    color: var(--accent);
    margin-bottom: 0.5rem;
    display: flex;
    align-items: center;
    gap: 6px;
    font-weight: 500;
}

.task-subsection i {
    font-size: 0.9rem;
}

.task-desc {
    margin-bottom: 0.75rem;
    color: var(--text-secondary);
    font-size: 0.95rem;
    line-height: 1.5;
}

.task-info {
    font-size: 0.9rem;
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.task-users {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-top: 0.5rem;
}

.user-badge {
    background-color: var(--accent-light);
    color: var(--accent);
    padding: 0.4rem 0.8rem;
    border-radius: 20px;
    font-size: 0.85rem;
    display: inline-flex;
    align-items: center;
    gap: 5px;
    font-weight: 500;
}

.task-deadline {
    font-size: 0.85rem;
    display: flex;
    align-items: center;
    gap: 6px;
    margin-top: 0.5rem;
    font-weight: 500;
}

.task-deadline.urgent {
    color: var(--danger);
    font-weight: 600;
}

.task-actions-horizontal {
    display: flex;
    gap: 0.5rem;
    margin-top: 1rem;
}

.task-actions-horizontal button {
    padding: 0.4rem 0.8rem;
    font-size: 0.8rem;
    background-color: rgba(255, 255, 255, 0.08);
}

.chat-btn {
    background-color: rgba(59, 130, 246, 0.2) !important;
    color: #3b82f6 !important;
}

.edit-task-btn {
    background-color: rgba(34, 197, 94, 0.2) !important;
    color: var(--success) !important;
}

.task-actions {
    display: flex;
    gap: 0.75rem;
    margin-top: 1rem;
}

.task-actions button {
    padding: 0.5rem 1rem;
    font-size: 0.85rem;
    background-color: rgba(255, 255, 255, 0.08);
}

.task-actions button:hover {
    background-color: rgba(129, 140, 248, 0.2);
}

.delete-btn {
    background-color: rgba(239, 68, 68, 0.2) !important;
    color: var(--danger) !important;
}

.delete-btn:hover {
    background-color: rgba(239, 68, 68, 0.3) !important;
}

.complete-btn {
    background-color: rgba(34, 197, 94, 0.2) !important;
    color: var(--success) !important;
}

.complete-btn:hover {
    background-color: rgba(34, 197, 94, 0.3) !important;
}

.archive-btn {
    background-color: rgba(168, 85, 247, 0.2) !important;
    color: #a855f7 !important;
}

.archive-btn:hover {
    background-color: rgba(168, 85, 247, 0.3) !important;
}

.urgent-badge {
    position: absolute;
    top: 0;
    right: 0;
    background: linear-gradient(45deg, var(--danger), #b91c1c);
    color: white;
    padding: 0.25rem 0.75rem;
    border-radius: 0 0 0 12px;
    font-size: 0.8rem;
    font-weight: 600;
    z-index: 10;
    display: flex;
    align-items: center;
    gap: 5px;
}

.form-group {
    margin-bottom: 1.5rem;
}

label {
    display: block;
    margin-bottom: 0.5rem;
    color: var(--text-secondary);
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 8px;
}

input, textarea, select {
    width: 100%;
    padding: 1rem;
    background-color: rgba(15, 23, 42, 0.5);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    color: var(--text);
    transition: var(--transition);
    font-size: 1rem;
}

input:focus, textarea:focus, select:focus {
    outline: none;
    border-color: var(--accent);
    box-shadow: 0 0 0 3px rgba(129, 140, 248, 0.3);
}

select[multiple] {
    height: 180px;
}

textarea {
    min-height: 120px;
    resize: vertical;
}

.select-wrapper {
    position: relative;
    margin-bottom: 1rem;
    border-radius: var(--radius);
    overflow: hidden;
    background: rgba(15, 23, 42, 0.5);
    border: 1px solid var(--border-color);
    transition: var(--transition);
}

.select-wrapper:hover {
    border-color: var(--accent);
}

.select-wrapper::after {
    content: '\f078';
    font-family: 'Font Awesome 6 Free';
    font-weight: 900;
    position: absolute;
    top: 50%;
    right: 15px;
    transform: translateY(-50%);
    color: var(--accent);
    pointer-events: none;
    transition: var(--transition);
}

.select-wrapper:hover::after {
    color: var(--accent-hover);
}

select {
    background: transparent;
    border: none;
    appearance: none;
    -webkit-appearance: none;
    -moz-appearance: none;
    cursor: pointer;
    padding-right: 40px;
    width: 100%;
    height: 100%;
}

select[multiple] {
    height: 180px;
    padding-right: 1rem;
    background-image: none;
}

select[multiple] option {
    padding: 0.8rem 1rem;
    border-bottom: 1px solid var(--border-color);
    transition: var(--transition);
}

select[multiple] option:hover {
    background-color: var(--accent-light);
}

select[multiple] option:checked {
    background-color: var(--accent);
    color: #000;
    font-weight: 600;
}

option {
    background-color: var(--card-bg);
    color: var(--text);
    padding: 0.8rem 1rem;
}

.admin-section {
    margin-bottom: 2.5rem;
    background-color: var(--card-bg);
    padding: 1.75rem;
    border-radius: var(--radius);
    border: 1px solid var(--border-color);
    box-shadow: var(--shadow);
}

.admin-section h3 {
    font-size: 1.4rem;
    margin-bottom: 1.25rem;
    color: var(--text);
    display: flex;
    align-items: center;
    gap: 10px;
}

.admin-section .input-group {
    display: flex;
    gap: 0.75rem;
    margin-top: 1.25rem;
}

.admin-section .input-group input {
    flex: 1;
}

table {
    width: 100%;
    border-collapse: collapse;
    margin: 1.25rem 0;
    background: rgba(15, 23, 42, 0.3);
    border-radius: var(--radius);
    overflow: hidden;
}

th, td {
    padding: 1rem;
    text-align: left;
    border-bottom: 1px solid var(--border-color);
}

th {
    background-color: rgba(0, 0, 0, 0.2);
    font-weight: 600;
}

tr:last-child td {
    border-bottom: none;
}

.sort-controls {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 1rem;
}

.sort-controls label {
    margin-bottom: 0;
}

.modal {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background-color: var(--card-bg);
    border-radius: var(--radius);
    z-index: 1001;
    min-width: 500px;
    max-width: 90vw;
    max-height: 90vh;
    overflow-y: auto;
    padding: 2rem;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5);
    border: 1px solid var(--border-color);
    animation: fadeIn 0.3s ease;
}

.modal h3 {
    font-size: 1.5rem;
    margin-bottom: 1.5rem;
    display: flex;
    align-items: center;
    gap: 10px;
    color: var(--accent);
}

.modal-actions {
    display: flex;
    justify-content: flex-end;
    gap: 1rem;
    margin-top: 1.5rem;
}

#modal-backdrop {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.7);
    z-index: 1000;
    backdrop-filter: blur(4px);
}

.hidden {
    display: none;
}

.users-select-container {
    position: relative;
    border: 1px solid var(--border-color);
    border-radius: var(--radius);
    background: rgba(15, 23, 42, 0.5);
    padding: 0.5rem;
    transition: var(--transition);
    min-height: 52px;
}

.users-select-container:focus-within {
    border-color: var(--accent);
    box-shadow: 0 0 0 3px rgba(129, 140, 248, 0.3);
}

.selected-users {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-bottom: 0.5rem;
}

.user-tag {
    background-color: var(--accent-light);
    color: var(--accent);
    padding: 0.4rem 0.8rem;
    border-radius: 20px;
    font-size: 0.9rem;
    display: inline-flex;
    align-items: center;
    gap: 5px;
    animation: fadeIn 0.3s ease;
}

.remove-tag {
    cursor: pointer;
    font-size: 1.1rem;
    padding: 0 0.25rem;
    transition: var(--transition);
}

.remove-tag:hover {
    color: var(--danger);
    transform: scale(1.1);
}

.users-dropdown {
    position: relative;
}

.users-search {
    width: 100%;
    padding: 0.75rem;
    border: none;
    background: transparent;
    color: var(--text);
    font-size: 0.95rem;
}

.users-search:focus {
    outline: none;
}

.users-list {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    max-height: 200px;
    overflow-y: auto;
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: var(--radius);
    z-index: 100;
    display: none;
    box-shadow: var(--shadow);
}

.users-dropdown:focus-within .users-list {
    display: block;
}

.user-item {
    padding: 0.75rem 1rem;
    cursor: pointer;
    transition: var(--transition);
    display: flex;
    align-items: center;
    gap: 10px;
}

.user-item:hover {
    background-color: var(--accent-light);
}

.user-item i {
    color: var(--accent);
}

.no-users {
    padding: 1rem;
    text-align: center;
    color: var(--text-secondary);
    font-size: 0.9rem;
}

.take-task-btn {
    background-color: rgba(34, 197, 94, 0.15);
    color: var(--success);
    border: none;
    width: 100%;
    margin-top: 0.5rem;
    padding: 0.5rem;
    border-radius: 6px;
    cursor: pointer;
    transition: var(--transition);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    font-weight: 500;
}

.take-task-btn:hover {
    background: rgba(34, 197, 94, 0.25);
}

.subsection-tag {
    background-color: rgba(129, 140, 248, 0.15);
    color: var(--accent);
    padding: 0.4rem 0.8rem;
    border-radius: 20px;
    font-size: 0.85rem;
    display: inline-flex;
    align-items: center;
    gap: 5px;
    margin: 0.25rem;
}

.board-tag {
    background-color: rgba(59, 130, 246, 0.15);
    color: #3b82f6;
    padding: 0.4rem 0.8rem;
    border-radius: 20px;
    font-size: 0.85rem;
    display: inline-flex;
    align-items: center;
    gap: 5px;
    margin: 0.25rem;
}

.view-tasks-btn {
    background-color: rgba(59, 130, 246, 0.15);
    color: #3b82f6;
    border: 1px solid rgba(59, 130, 246, 0.3);
    padding: 0.5rem 1rem;
    border-radius: 6px;
    cursor: pointer;
    transition: var(--transition);
    display: inline-flex;
    align-items: center;
    gap: 5px;
    font-weight: 500;
    margin-right: 0.5rem;
    font-size: 0.9rem;
}

.view-tasks-btn:hover {
    background-color: rgba(59, 130, 246, 0.25);
    transform: translateY(-1px);
}

.edit-user-btn {
    background-color: rgba(34, 197, 94, 0.15);
    color: var(--success);
    border: 1px solid rgba(34, 197, 94, 0.3);
    padding: 0.5rem 1rem;
    border-radius: 6px;
    cursor: pointer;
    transition: var(--transition);
    display: inline-flex;
    align-items: center;
    gap: 5px;
    font-weight: 500;
    margin-right: 0.5rem;
    font-size: 0.9rem;
}

.edit-user-btn:hover {
    background-color: rgba(34, 197, 94, 0.25);
    transform: translateY(-1px);
}

.task-count-badge {
    background-color: #3b82f6;
    color: white;
    border-radius: 50%;
    width: 20px;
    height: 20px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 0.75rem;
    font-weight: 600;
    margin-left: 5px;
}

.role-badge {
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 500;
}

.role-badge.user {
    background-color: rgba(59, 130, 246, 0.15);
    color: #3b82f6;
}

.role-badge.admin {
    background-color: rgba(239, 68, 68, 0.15);
    color: var(--danger);
}

.user-tasks-modal {
    max-width: 800px;
    width: 90%;
    max-height: 80vh;
    overflow-y: auto;
}

.user-tasks-header {
    display: flex;
    align-items: center;
    margin-bottom: 1.5rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid var(--border-color);
}

.user-tasks-header h3 {
    margin: 0;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.user-tasks-count {
    background-color: var(--accent-light);
    color: var(--accent);
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 500;
    margin-left: auto;
}

.user-tasks-list {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.user-task-item {
    background-color: rgba(15, 23, 42, 0.5);
    padding: 1.25rem;
    border-radius: var(--radius);
    border-left: 4px solid var(--accent);
    transition: var(--transition);
}

.user-task-item:hover {
    background-color: var(--card-hover);
    transform: translateY(-2px);
}

.user-task-title {
    font-weight: 600;
    margin-bottom: 0.5rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.user-task-info {
    font-size: 0.9rem;
    color: var(--text-secondary);
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.user-task-status {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 500;
}

.status-todo {
    background-color: rgba(129, 140, 248, 0.15);
    color: var(--accent);
}

.status-inprogress {
    background-color: rgba(245, 158, 11, 0.15);
    color: var(--warning);
}

.status-test {
    background-color: rgba(59, 130, 246, 0.15);
    color: #3b82f6;
}

.status-completed {
    background-color: rgba(34, 197, 94, 0.15);
    color: var(--success);
}

.user-task-deadline {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.deadline-urgent {
    color: var(--danger);
    font-weight: 600;
}

.no-tasks-message {
    text-align: center;
    padding: 2rem;
    color: var(--text-secondary);
    font-style: italic;
}

.chat-modal {
    max-width: 600px;
    width: 90%;
    max-height: 80vh;
    display: flex;
    flex-direction: column;
}

.chat-messages {
    flex: 1;
    overflow-y: auto;
    padding: 1rem;
    background: rgba(15, 23, 42, 0.3);
    border-radius: var(--radius);
    margin-bottom: 1rem;
    max-height: 400px;
}

.chat-message {
    margin-bottom: 1rem;
    padding: 0.75rem;
    border-radius: var(--radius);
    background: rgba(255, 255, 255, 0.05);
}

.chat-message.own-message {
    background: var(--accent-light);
    margin-left: 2rem;
}

.message-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.5rem;
    font-size: 0.85rem;
}

.message-header strong {
    color: var(--accent);
}

.message-time {
    color: var(--text-secondary);
    font-size: 0.8rem;
}

.message-content {
    word-wrap: break-word;
}

.chat-input-container {
    display: flex;
    gap: 0.5rem;
}

.chat-input-container input {
    flex: 1;
    margin-bottom: 0;
}

.chat-input-container button {
    padding: 0.75rem 1.5rem;
}

@media (max-width: 1200px) {
    .kanban-column {
        flex: 0 0 320px;
    }
}

@media (max-width: 992px) {
    .kanban-column {
        flex: 0 0 300px;
    }
    
    header {
        flex-direction: column;
        gap: 1rem;
        padding: 1rem;
    }
    
    nav {
        width: 100%;
        justify-content: center;
        flex-wrap: wrap;
    }
    
    main {
        padding: 1.5rem 1rem;
    }
}

@media (max-width: 768px) {
    .kanban-board {
        flex-direction: column;
        height: auto;
    }
    
    .kanban-column {
        flex: 1 1 auto;
        width: 100%;
    }
    
    .modal {
        min-width: 95%;
        padding: 1.5rem;
        margin: 1rem;
    }
    
    .select-wrapper::after {
        right: 10px;
    }
    
    .board-selector {
        flex-direction: column;
        align-items: flex-start;
    }
    
    table {
        display: block;
        overflow-x: auto;
    }
}

@media (max-width: 576px) {
    .login-container {
        padding: 2rem 1.5rem;
        width: 95%;
        margin: 1rem;
    }
    
    .kanban-column {
        flex: 1 1 auto;
    }
    
    .admin-section {
        padding: 1.25rem;
    }
    
    .select-wrapper::after {
        font-size: 0.8rem;
    }
    
    .task-actions-horizontal {
        flex-direction: column;
    }
    
    .modal-actions {
        flex-direction: column;
    }
    
    nav button {
        padding: 0.7rem 1rem;
        font-size: 0.85rem;
    }
}

@media (max-width: 480px) {
    .login-container h1 {
        font-size: 2.5rem;
    }
    
    header {
        padding: 0.75rem;
    }
    
    .logo {
        font-size: 1.4rem;
    }
    
    nav {
        gap: 0.5rem;
    }
    
    nav button {
        padding: 0.6rem 0.8rem;
        font-size: 0.8rem;
    }
    
    main {
        padding: 1rem 0.75rem;
    }
    
    h2 {
        font-size: 1.5rem;
    }
    
    .modal {
        padding: 1.25rem;
    }
}