/* Base Reset and Variables */
:root {
    --color-black: #000000;
    --color-white: #ffffff;
    --color-gray-50: #fafafa;
    --color-gray-100: #f5f5f5;
    --color-gray-200: #e5e5e5;
    --color-gray-300: #d4d4d4;
    --color-gray-400: #a3a3a3;
    --color-gray-500: #737373;
    --color-gray-600: #525252;
    --color-gray-700: #404040;
    --color-gray-800: #262626;
    --color-gray-900: #171717;
    --color-success: #22c55e;
    --color-error: #ef4444;
    --color-warning: #f59e0b;
    --border-radius: 12px;
    --border-radius-sm: 8px;
    --shadow-sm: 0 1px 2px 0 rgb(0 0 0 / 0.05);
    --shadow: 0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1);
    --shadow-md: 0 10px 15px -3px rgb(0 0 0 / 0.1), 0 4px 6px -4px rgb(0 0 0 / 0.1);
    --shadow-lg: 0 20px 25px -5px rgb(0 0 0 / 0.1), 0 8px 10px -6px rgb(0 0 0 / 0.1);
    --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, sans-serif;
    --navbar-height: 70px;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: var(--font-sans);
    background-color: var(--color-gray-50);
    color: var(--color-gray-900);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}

a {
    color: var(--color-black);
    text-decoration: none;
    transition: all 0.2s ease;
}

/* Navbar */
.navbar {
    background-color: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--color-gray-100);
    height: var(--navbar-height);
    position: sticky;
    top: 0;
    z-index: 1000;
    display: flex;
    align-items: center;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.02);
    overflow: visible;
}

.navbar-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
    position: relative;
    overflow: visible;
}

.navbar-left {
    display: flex;
    align-items: center;
}

.navbar-right {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    position: relative;
    z-index: 1001;
}

.navbar-nav {
    display: flex;
    align-items: center;
    gap: 0.25rem;
}

.navbar-divider {
    width: 1px;
    height: 24px;
    background-color: var(--color-gray-200);
    margin: 0 0.75rem;
}

.navbar-brand {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--color-black);
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 0.625rem;
    letter-spacing: -0.02em;
    transition: opacity 0.15s ease;
}

.navbar-brand:hover {
    opacity: 0.8;
}

.navbar-brand i {
    font-size: 1.375rem;
    color: var(--color-gray-700);
}

.navbar-link {
    color: var(--color-gray-600);
    text-decoration: none;
    padding: 0.5rem 0.875rem;
    border-radius: 8px;
    font-weight: 500;
    font-size: 0.875rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    transition: all 0.15s ease;
    position: relative;
}

.navbar-link i {
    font-size: 1.0625rem;
    transition: transform 0.15s ease;
}

.navbar-link:hover {
    color: var(--color-black);
    background-color: var(--color-gray-100);
}

.navbar-link:hover i {
    transform: scale(1.1);
}

.navbar-link.active {
    color: var(--color-white);
    background-color: var(--color-black);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
}

.navbar-link.active:hover {
    background-color: var(--color-gray-800);
}

.navbar-link.active i {
    transform: none;
}

/* Nav Dropdown (More menu) */
.nav-dropdown {
    position: relative;
    z-index: 1001;
}

.nav-dropdown-trigger {
    color: var(--color-gray-600);
    background: none;
    border: none;
    padding: 0.5rem 0.875rem;
    border-radius: 8px;
    font-weight: 500;
    font-size: 0.875rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    cursor: pointer;
    transition: all 0.15s ease;
    font-family: inherit;
}

.nav-dropdown-trigger i {
    font-size: 1.0625rem;
    transition: transform 0.15s ease;
}

.nav-dropdown-trigger:hover {
    color: var(--color-black);
    background-color: var(--color-gray-100);
}

.nav-dropdown-trigger:hover i {
    transform: scale(1.1);
}

.nav-dropdown-trigger.active {
    color: var(--color-white);
    background-color: var(--color-black);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
}

.nav-dropdown-trigger.active:hover {
    background-color: var(--color-gray-800);
}

.nav-dropdown-trigger.active i {
    transform: none;
}

.nav-dropdown-arrow {
    font-size: 0.625rem !important;
    margin-left: 0.125rem;
    transition: transform 0.2s ease !important;
}

.nav-dropdown:hover .nav-dropdown-arrow,
.nav-dropdown.open .nav-dropdown-arrow {
    transform: rotate(180deg) !important;
}

.nav-dropdown-menu {
    position: absolute;
    top: calc(100% + 0.5rem);
    left: 0;
    min-width: 180px;
    background-color: var(--color-white);
    border-radius: var(--border-radius);
    box-shadow: var(--shadow-lg);
    border: 1px solid var(--color-gray-100);
    padding: 0.5rem;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-8px);
    transition: all 0.2s ease;
    pointer-events: none;
}

.nav-dropdown:hover .nav-dropdown-menu,
.nav-dropdown.open .nav-dropdown-menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
    pointer-events: auto;
}

.nav-dropdown-menu .dropdown-item {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.625rem 0.875rem;
    color: var(--color-gray-700);
    border-radius: var(--border-radius-sm);
    font-size: 0.875rem;
    font-weight: 500;
    text-decoration: none;
    transition: all 0.15s ease;
    width: 100%;
    background: none;
    border: none;
    cursor: pointer;
    text-align: left;
    font-family: inherit;
}

.nav-dropdown-menu .dropdown-item i {
    font-size: 1rem;
    width: 18px;
    text-align: center;
    color: var(--color-gray-500);
}

.nav-dropdown-menu .dropdown-item:hover {
    background-color: var(--color-gray-50);
    color: var(--color-black);
}

.nav-dropdown-menu .dropdown-item:hover i {
    color: var(--color-gray-700);
}

.nav-dropdown-menu .dropdown-item.active {
    background-color: var(--color-black);
    color: var(--color-white);
}

.nav-dropdown-menu .dropdown-item.active i {
    color: var(--color-white);
}

.nav-dropdown-menu .dropdown-item.active:hover {
    background-color: var(--color-gray-800);
}

/* Profile Dropdown */
.profile-dropdown {
    position: relative;
    z-index: 1001;
    isolation: isolate;
}

.profile-trigger {
    background: var(--color-white);
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.25rem 0.75rem 0.25rem 0.25rem;
    border-radius: 9999px;
    transition: all 0.15s ease;
    border: 1px solid var(--color-gray-200);
}

.profile-trigger:hover {
    background-color: var(--color-gray-50);
    border-color: var(--color-gray-300);
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.04);
}

.profile-trigger:active {
    transform: scale(0.98);
}

.profile-avatar-small {
    width: 32px;
    height: 32px;
    background-color: var(--color-black);
    color: var(--color-white);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    font-size: 0.875rem;
}

.profile-name {
    font-weight: 600;
    font-size: 0.875rem;
    color: var(--color-gray-800);
}

.profile-trigger i {
    font-size: 0.625rem;
    color: var(--color-gray-500);
    margin-left: 0.125rem;
}

.profile-dropdown .dropdown-menu {
    position: absolute;
    top: calc(100% + 0.75rem);
    right: 0;
    width: 240px;
    background-color: var(--color-white);
    border-radius: var(--border-radius);
    box-shadow: var(--shadow-lg);
    border: 1px solid var(--color-gray-100);
    padding: 0.5rem;
    display: block;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: all 0.2s ease;
    z-index: 1001;
    pointer-events: none;
}

.profile-dropdown:hover .dropdown-menu,
.profile-dropdown.open .dropdown-menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
    pointer-events: auto;
}

.dropdown-header {
    padding: 0.75rem 1rem;
    border-bottom: 1px solid var(--color-gray-100);
    margin-bottom: 0.5rem;
}

.dropdown-user-name {
    display: block;
    font-weight: 600;
    color: var(--color-gray-900);
}

.dropdown-user-role {
    display: block;
    font-size: 0.75rem;
    color: var(--color-gray-500);
    margin-top: 0.125rem;
}

.dropdown-item {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.75rem 1rem;
    color: var(--color-gray-700);
    border-radius: var(--border-radius-sm);
    font-size: 0.875rem;
    font-weight: 500;
    width: 100%;
    background: none;
    border: none;
    cursor: pointer;
    text-align: left;
}

.dropdown-item:hover {
    background-color: var(--color-gray-50);
    color: var(--color-black);
    text-decoration: none;
}

.dropdown-item.text-danger {
    color: var(--color-error);
}

.dropdown-item.text-danger:hover {
    background-color: #fef2f2;
}

.dropdown-item.active {
    background-color: var(--color-primary-light);
    color: var(--color-primary);
}

.dropdown-item.active:hover {
    background-color: var(--color-primary-light);
}

.dropdown-divider {
    height: 1px;
    background-color: var(--color-gray-100);
    margin: 0.5rem 0;
}

.logout-form-dropdown {
    display: block;
}

/* Container */
.container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 2rem 1.5rem;
}

/* Page Header */
.page-header {
    margin-bottom: 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.page-header.project-detail-header {
    flex-direction: column;
    align-items: stretch;
    gap: 1rem;
}

.page-header .header-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.page-header .project-meta-badges {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.page-header h1 {
    font-size: 2rem;
    font-weight: 700;
    margin-top: 0;
}

.header-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 1rem;
}

.header-title-group {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    max-width: 100%;
    overflow: hidden;
}

/* Task name header with truncation */
.task-name-header {
    max-width: 600px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    cursor: default;
    flex-shrink: 1;
    min-width: 0;
}

.task-name-header[title]:not([title=""]) {
    cursor: help;
    position: relative;
}

.task-name-header[title]:not([title=""])::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    right: 0;
    height: 1px;
    background: var(--color-gray-300);
    opacity: 0;
    transition: opacity 0.2s ease;
}

.task-name-header[title]:not([title=""]):hover::after {
    opacity: 0.5;
}

.header-actions {
    display: flex;
    gap: 0.5rem;
}

.color-dot {
    width: 16px;
    height: 16px;
    border-radius: 50%;
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.625rem 1.25rem;
    font-size: 0.875rem;
    font-weight: 600;
    border: 1px solid transparent;
    border-radius: 9999px;
    cursor: pointer;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    text-decoration: none;
    letter-spacing: -0.01em;
    gap: 0.5rem;
}

.btn:hover {
    text-decoration: none;
    transform: translateY(-1px);
}

.btn:active {
    transform: translateY(0);
}

.btn-primary {
    background-color: var(--color-black);
    color: var(--color-white);
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
}

.btn-primary:hover {
    background-color: var(--color-gray-900);
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
}

.btn-outline {
    background-color: transparent;
    border-color: var(--color-gray-200);
    color: var(--color-gray-900);
}

.btn-outline:hover {
    background-color: var(--color-white);
    border-color: var(--color-gray-300);
    box-shadow: var(--shadow-sm);
}

.btn-danger {
    background-color: #fee2e2;
    color: #991b1b;
    border-color: transparent;
}

.btn-danger:hover {
    background-color: #fecaca;
    color: #7f1d1d;
}

.btn-block {
    width: 100%;
}

.btn-sm {
    padding: 0.375rem 0.75rem;
    font-size: 0.75rem;
}

/* Cards */
.card {
    background-color: var(--color-white);
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
    overflow: hidden;
    transition: box-shadow 0.2s;
}

.card:hover {
    box-shadow: var(--shadow-md);
}

.card-color-bar {
    height: 4px;
}

.card-body {
    padding: 1.25rem;
}

.card-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 0.5rem;
}

.card-title {
    font-size: 1.125rem;
    font-weight: 600;
    margin: 0;
}

.card-title a {
    color: var(--color-black);
}

.card-description {
    color: var(--color-gray-600);
    font-size: 0.875rem;
    margin-bottom: 0.75rem;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.card-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    font-size: 0.75rem;
    color: var(--color-gray-500);
    margin-bottom: 0.5rem;
}

.card-category {
    background-color: var(--color-gray-200);
    padding: 0.125rem 0.5rem;
    border-radius: 4px;
}

.card-stats {
    display: flex;
    gap: 1rem;
    font-size: 0.75rem;
    color: var(--color-gray-500);
}

.card-footer {
    display: flex;
    justify-content: space-between;
    font-size: 0.75rem;
    color: var(--color-gray-500);
}

.cards-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 1.5rem;
}

/* Project Card - Sleek Design */
.project-card {
    background: white;
    border: 1px solid var(--color-gray-200);
    border-left: 4px solid #000;
    border-radius: 12px;
    transition: all 0.2s ease;
}

.project-card:hover {
    border-color: var(--color-gray-300);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
}

.project-card-link {
    text-decoration: none;
    color: inherit;
    display: block;
    padding: 1rem;
}

.project-card-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 0.5rem;
}

.project-name {
    font-size: 1rem;
    font-weight: 600;
    margin: 0;
    color: var(--color-gray-900);
}

.project-description {
    font-size: 0.875rem;
    color: var(--color-gray-600);
    margin-bottom: 0.75rem;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    min-height: 2.625rem;
}

.project-description.no-description {
    color: var(--color-gray-400);
    font-style: italic;
}

.project-card-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    font-size: 0.75rem;
    color: var(--color-gray-500);
    margin-bottom: 0.75rem;
}

.project-category {
    background: var(--color-gray-100);
    padding: 0.125rem 0.5rem;
    border-radius: 4px;
}

.project-card-stats {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.75rem;
    color: var(--color-gray-500);
    padding-top: 0.75rem;
    border-top: 1px solid var(--color-gray-100);
}

.project-card-stats i {
    color: var(--color-gray-400);
}

/* Badges */
.badge {
    display: inline-flex;
    align-items: center;
    padding: 0.25rem 0.5rem;
    font-size: 0.75rem;
    font-weight: 500;
    border-radius: 4px;
    background-color: var(--color-gray-200);
}

.badge-private {
    background-color: var(--color-gray-800);
    color: var(--color-white);
}

.badge-public {
    background-color: var(--color-gray-200);
    color: var(--color-gray-700);
}

.badge-new {
    background-color: #dbeafe;
    color: #1e40af;
}

.badge-in_progress {
    background-color: #fef3c7;
    color: #92400e;
}

.badge-on_hold {
    background-color: #fee2e2;
    color: #991b1b;
}

.badge-planned {
    background-color: #e0e7ff;
    color: #3730a3;
}

.badge-done {
    background-color: #dcfce7;
    color: #166534;
}

/* Importance Badges */
.badge-importance-low {
    background-color: #e0e7ff;
    color: #3730a3;
}

.badge-importance-medium {
    background-color: #fef3c7;
    color: #92400e;
}

.badge-importance-high {
    background-color: #fee2e2;
    color: #991b1b;
}

/* Priority Badges */
.badge-priority-no {
    background-color: var(--color-gray-200);
    color: var(--color-gray-600);
}

.badge-priority-low {
    background-color: #dbeafe;
    color: #1e40af;
}

.badge-priority-medium {
    background-color: #fef3c7;
    color: #92400e;
}

.badge-priority-high {
    background-color: #fed7aa;
    color: #c2410c;
}

.badge-priority-very_high {
    background-color: #fee2e2;
    color: #991b1b;
}

/* Evaluation Section */
.evaluation-section {
    margin-bottom: 1.5rem;
}

.evaluation-section h2 {
    font-size: 1rem;
    font-weight: 600;
    margin-bottom: 1rem;
    color: var(--color-gray-900);
}

.evaluation-grid {
    display: flex;
    gap: 2rem;
    flex-wrap: wrap;
}

.evaluation-item {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.evaluation-label {
    font-size: 0.75rem;
    font-weight: 500;
    color: var(--color-gray-500);
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.evaluation-empty {
    font-size: 0.875rem;
    color: var(--color-gray-400);
    font-style: italic;
}

.evaluation-edit select {
    min-width: 120px;
}

.evaluation-status {
    margin-top: 0.75rem;
    font-size: 0.75rem;
    padding: 0.25rem 0.5rem;
    border-radius: 4px;
    display: inline-block;
}

.evaluation-status-saving {
    color: var(--color-gray-600);
    background-color: var(--color-gray-100);
}

.evaluation-status-success {
    color: #166534;
    background-color: #dcfce7;
}

.evaluation-status-error {
    color: #991b1b;
    background-color: #fee2e2;
}

/* Alerts */
.alert {
    padding: 1rem;
    border-radius: var(--border-radius);
    margin-bottom: 1.5rem;
}

.alert-success {
    background-color: #dcfce7;
    color: #166534;
    border: 1px solid #bbf7d0;
}

.alert-error {
    background-color: #fee2e2;
    color: #991b1b;
    border: 1px solid #fecaca;
}

/* Forms */
.form-card {
    background-color: var(--color-white);
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
    padding: 2rem;
    max-width: 600px;
    margin-bottom: 1.5rem;
}

.form-card h3 {
    margin-bottom: 1.5rem;
    font-size: 1.25rem;
}

.form-group {
    margin-bottom: 1.25rem;
}

.form-group label {
    display: block;
    font-weight: 500;
    margin-bottom: 0.5rem;
    font-size: 0.875rem;
}

.form-group input[type="text"],
.form-group input[type="email"],
.form-group input[type="password"],
.form-group input[type="number"],
.form-group input[type="date"],
.form-group input[type="url"],
.form-group textarea,
.form-group select {
    width: 100%;
    padding: 0.75rem;
    border: 1px solid var(--color-gray-300);
    border-radius: var(--border-radius);
    font-size: 1rem;
    transition: border-color 0.2s;
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
    outline: none;
    border-color: var(--color-black);
}

.form-group input[type="color"] {
    width: 60px;
    height: 40px;
    padding: 0;
    border: 1px solid var(--color-gray-300);
    border-radius: var(--border-radius);
    cursor: pointer;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
}

.form-help {
    font-size: 0.75rem;
    color: var(--color-gray-500);
    margin-top: 0.25rem;
}

.form-actions {
    display: flex;
    justify-content: flex-end;
    gap: 0.75rem;
    margin-top: 1.5rem;
}

.form-select {
    padding: 0.5rem;
    border: 1px solid var(--color-gray-300);
    border-radius: var(--border-radius);
    font-size: 0.875rem;
    min-width: 200px;
}

.checkbox-label {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    cursor: pointer;
}

.checkbox-label input[type="checkbox"] {
    width: 18px;
    height: 18px;
}

.field-error {
    color: var(--color-error);
    font-size: 0.75rem;
    margin-top: 0.25rem;
    display: block;
}

.inline-form {
    display: inline;
}

/* Auth Pages */
.auth-page {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: var(--color-gray-100);
    background-image: url('/images/background.JPG');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    background-attachment: fixed;
}

.auth-container {
    width: 100%;
    max-width: 400px;
    padding: 1.5rem;
}

.auth-card {
    background-color: var(--color-white);
    border-radius: var(--border-radius);
    box-shadow: var(--shadow-lg);
    padding: 2.5rem;
}

.auth-header {
    text-align: center;
    margin-bottom: 2rem;
}

.auth-title {
    font-size: 2rem;
    font-weight: 700;
}

.auth-subtitle {
    color: var(--color-gray-500);
    margin-top: 0.5rem;
}

.auth-form .form-group {
    margin-bottom: 1.25rem;
}

.auth-footer {
    text-align: center;
    margin-top: 1.5rem;
    color: var(--color-gray-500);
}

.auth-footer a {
    color: var(--color-black);
    font-weight: 500;
}

/* Stats */
.stats-section {
    margin-bottom: 2.5rem;
}

.stats-section h2 {
    margin-bottom: 1rem;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1rem;
}

.stat-card {
    background-color: var(--color-white);
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
    padding: 1.5rem;
    text-align: center;
}

.stat-value {
    font-size: 2.5rem;
    font-weight: 700;
}

.stat-label {
    color: var(--color-gray-500);
    font-size: 0.875rem;
    margin-top: 0.25rem;
}

/* Sections */
.section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
}

.section-header h2 {
    font-size: 1.5rem;
}

.projects-section,
.tasks-section {
    margin-bottom: 2.5rem;
}

/* Empty State */
.empty-state {
    text-align: center;
    padding: 3rem 2rem;
    background-color: var(--color-white);
    border-radius: var(--border-radius);
    color: var(--color-gray-500);
}

/* Detail Sections */
.detail-section {
    background-color: var(--color-white);
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
    padding: 1.5rem;
    margin-bottom: 1.5rem;
}

.project-description,
.task-description {
    color: var(--color-gray-700);
    margin-bottom: 1rem;
}

.project-meta,
.task-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 1.5rem;
}

.meta-item {
    font-size: 0.875rem;
    color: var(--color-gray-600);
}

/* Team Section */
.team-section {
    background-color: var(--color-white);
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
    padding: 1.5rem;
    margin-bottom: 1.5rem;
}

.team-section h3 {
    margin-bottom: 1rem;
}

.team-members {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    margin-bottom: 1rem;
}

.team-member {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    background-color: var(--color-gray-100);
    padding: 0.5rem 0.75rem;
    border-radius: var(--border-radius);
}

.add-member-form {
    display: flex;
    gap: 0.75rem;
    align-items: center;
}

/* Status Section */
.status-section {
    background-color: var(--color-white);
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
    padding: 1.5rem;
    margin-bottom: 1.5rem;
}

.status-section h3 {
    margin-bottom: 1rem;
}

.status-form {
    display: flex;
    gap: 0.75rem;
    align-items: center;
}


/* Assignees List with Avatar Badges */
.assignees-list {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-bottom: 1rem;
}

.assignee-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    background-color: var(--color-gray-100);
    padding: 0.375rem 0.5rem 0.375rem 0.375rem;
    border-radius: 9999px;
    transition: all 0.2s ease;
    position: relative;
}

.assignee-badge:hover {
    background-color: var(--color-gray-200);
    box-shadow: var(--shadow-sm);
}

/* Avatar Badges */
.assignee-avatar {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    font-size: 0.75rem;
    color: var(--color-white);
    background-color: var(--color-black);
    flex-shrink: 0;
}

/* Avatar color palette based on first letter */
.assignee-badge[data-name^="A"] .assignee-avatar,
.assignee-badge[data-name^="a"] .assignee-avatar {
    background-color: #ef4444;
}

.assignee-badge[data-name^="B"] .assignee-avatar,
.assignee-badge[data-name^="b"] .assignee-avatar {
    background-color: #f97316;
}

.assignee-badge[data-name^="C"] .assignee-avatar,
.assignee-badge[data-name^="c"] .assignee-avatar {
    background-color: #eab308;
}

.assignee-badge[data-name^="D"] .assignee-avatar,
.assignee-badge[data-name^="d"] .assignee-avatar {
    background-color: #22c55e;
}

.assignee-badge[data-name^="E"] .assignee-avatar,
.assignee-badge[data-name^="e"] .assignee-avatar {
    background-color: #14b8a6;
}

.assignee-badge[data-name^="F"] .assignee-avatar,
.assignee-badge[data-name^="f"] .assignee-avatar {
    background-color: #06b6d4;
}

.assignee-badge[data-name^="G"] .assignee-avatar,
.assignee-badge[data-name^="g"] .assignee-avatar {
    background-color: #3b82f6;
}

.assignee-badge[data-name^="H"] .assignee-avatar,
.assignee-badge[data-name^="h"] .assignee-avatar {
    background-color: #6366f1;
}

.assignee-badge[data-name^="I"] .assignee-avatar,
.assignee-badge[data-name^="i"] .assignee-avatar {
    background-color: #8b5cf6;
}

.assignee-badge[data-name^="J"] .assignee-avatar,
.assignee-badge[data-name^="j"] .assignee-avatar {
    background-color: #a855f7;
}

.assignee-badge[data-name^="K"] .assignee-avatar,
.assignee-badge[data-name^="k"] .assignee-avatar {
    background-color: #d946ef;
}

.assignee-badge[data-name^="L"] .assignee-avatar,
.assignee-badge[data-name^="l"] .assignee-avatar {
    background-color: #ec4899;
}

.assignee-badge[data-name^="M"] .assignee-avatar,
.assignee-badge[data-name^="m"] .assignee-avatar {
    background-color: #f43f5e;
}

.assignee-badge[data-name^="N"] .assignee-avatar,
.assignee-badge[data-name^="n"] .assignee-avatar {
    background-color: #ef4444;
}

.assignee-badge[data-name^="O"] .assignee-avatar,
.assignee-badge[data-name^="o"] .assignee-avatar {
    background-color: #f97316;
}

.assignee-badge[data-name^="P"] .assignee-avatar,
.assignee-badge[data-name^="p"] .assignee-avatar {
    background-color: #eab308;
}

.assignee-badge[data-name^="Q"] .assignee-avatar,
.assignee-badge[data-name^="q"] .assignee-avatar {
    background-color: #84cc16;
}

.assignee-badge[data-name^="R"] .assignee-avatar,
.assignee-badge[data-name^="r"] .assignee-avatar {
    background-color: #22c55e;
}

.assignee-badge[data-name^="S"] .assignee-avatar,
.assignee-badge[data-name^="s"] .assignee-avatar {
    background-color: #14b8a6;
}

.assignee-badge[data-name^="T"] .assignee-avatar,
.assignee-badge[data-name^="t"] .assignee-avatar {
    background-color: #06b6d4;
}

.assignee-badge[data-name^="U"] .assignee-avatar,
.assignee-badge[data-name^="u"] .assignee-avatar {
    background-color: #0ea5e9;
}

.assignee-badge[data-name^="V"] .assignee-avatar,
.assignee-badge[data-name^="v"] .assignee-avatar {
    background-color: #3b82f6;
}

.assignee-badge[data-name^="W"] .assignee-avatar,
.assignee-badge[data-name^="w"] .assignee-avatar {
    background-color: #6366f1;
}

.assignee-badge[data-name^="X"] .assignee-avatar,
.assignee-badge[data-name^="x"] .assignee-avatar {
    background-color: #8b5cf6;
}

.assignee-badge[data-name^="Y"] .assignee-avatar,
.assignee-badge[data-name^="y"] .assignee-avatar {
    background-color: #a855f7;
}

.assignee-badge[data-name^="Z"] .assignee-avatar,
.assignee-badge[data-name^="z"] .assignee-avatar {
    background-color: #d946ef;
}

.assignee-badge .assignee-name {
    font-size: 0.8125rem;
    font-weight: 500;
    color: var(--color-gray-700);
}

/* Remove Button */
.assignee-remove {
    width: 18px;
    height: 18px;
    border: none;
    background-color: transparent;
    color: var(--color-gray-400);
    cursor: pointer;
    font-size: 1rem;
    line-height: 1;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: all 0.15s ease;
    margin-left: 0.125rem;
}

.assignee-badge:hover .assignee-remove {
    opacity: 1;
}

.assignee-remove:hover {
    background-color: var(--color-error);
    color: var(--color-white);
}

/* Add Assignee Form */
.add-assignee-form {
    margin-top: 0.5rem;
}

.add-assignee-inline {
    display: flex;
    gap: 0.5rem;
    align-items: center;
}

.form-select-compact {
    padding: 0.375rem 0.625rem;
    border: 1px solid var(--color-gray-300);
    border-radius: var(--border-radius);
    font-size: 0.8125rem;
    min-width: 150px;
    background-color: var(--color-white);
}

.form-select-compact:focus {
    outline: none;
    border-color: var(--color-black);
}

/* Empty state inline */
.empty-state-inline {
    color: var(--color-gray-500);
    font-size: 0.875rem;
    padding: 0.5rem 0;
}

/* Comments */
.comments-section {
    margin-bottom: 2.5rem;
}

.comments-section h2 {
    margin-bottom: 1rem;
}

.comment-form {
    background-color: var(--color-white);
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
    padding: 1.5rem;
    margin-bottom: 1.5rem;
}

.comment-form textarea {
    width: 100%;
    padding: 0.75rem;
    border: 1px solid var(--color-gray-300);
    border-radius: var(--border-radius);
    font-size: 1rem;
    resize: vertical;
    margin-bottom: 1rem;
}

.comment-form textarea:focus {
    outline: none;
    border-color: var(--color-black);
}

.comments-list {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.comment-card {
    background-color: var(--color-white);
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
    padding: 1rem 1.25rem;
}

.comment-header {
    display: flex;
    justify-content: space-between;
    margin-bottom: 0.5rem;
}

.comment-author {
    font-weight: 600;
}

.comment-date {
    font-size: 0.75rem;
    color: var(--color-gray-500);
}

.comment-content {
    color: var(--color-gray-700);
}

.comment-actions {
    margin-top: 0.75rem;
}

/* History */
.history-container {
    background-color: var(--color-white);
    border-radius: var(--border-radius);
    box-shadow: var(--shadow-sm);
    border: 1px solid var(--color-gray-100);
    padding: 1.5rem;
}

.history-empty {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 4rem 2rem;
    text-align: center;
    color: var(--color-gray-500);
}

.history-empty .empty-icon {
    font-size: 3rem;
    margin-bottom: 1rem;
    color: var(--color-gray-300);
}

.history-empty h3 {
    margin: 0 0 0.5rem 0;
    color: var(--color-gray-700);
    font-size: 1.125rem;
}

.history-empty p {
    margin: 0;
    font-size: 0.875rem;
    max-width: 320px;
}

.history-loading {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    padding: 3rem 2rem;
    color: var(--color-gray-500);
}

.history-timeline {
    position: relative;
    padding-left: 2rem;
    padding-top: 0.5rem;
}

.history-timeline::before {
    content: '';
    position: absolute;
    left: 7px;
    top: 0;
    bottom: 0;
    width: 2px;
    background-color: var(--color-gray-300);
}

.history-entry {
    position: relative;
    padding-bottom: 1rem;
}

.history-dot {
    position: absolute;
    left: -2rem;
    top: 4px;
    width: 16px;
    height: 16px;
    background-color: var(--color-white);
    border: 2px solid var(--color-black);
    border-radius: 50%;
}

.history-content {
    background-color: var(--color-white);
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
    padding: 0.75rem 1rem;
    transition: box-shadow 0.2s ease;
}

.history-content:hover {
    box-shadow: var(--shadow-md, var(--shadow));
}

.history-content p {
    font-size: 0.875rem;
}

.history-content em {
    background-color: var(--color-gray-100);
    padding: 0.125rem 0.25rem;
    border-radius: 4px;
    font-style: normal;
}

.history-date {
    font-size: 0.75rem;
    color: var(--color-gray-500);
}

/* Profile */
.profile-card {
    background-color: var(--color-white);
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
    padding: 2rem;
    margin-bottom: 2rem;
}

.profile-info {
    display: flex;
    align-items: center;
    gap: 1.5rem;
    margin-bottom: 1.5rem;
}

.profile-avatar {
    width: 80px;
    height: 80px;
    background-color: var(--color-black);
    color: var(--color-white);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2rem;
    font-weight: 700;
}

.profile-details h2 {
    margin-bottom: 0.25rem;
}

.profile-details p {
    color: var(--color-gray-500);
    margin-bottom: 0.5rem;
}

.profile-meta {
    padding-top: 1rem;
    border-top: 1px solid var(--color-gray-200);
}

/* Dialog */
.dialog-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(0, 0, 0, 0.5);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 1000;
}

.dialog-overlay.active {
    display: flex;
}

.dialog {
    background-color: var(--color-white);
    border-radius: var(--border-radius);
    box-shadow: var(--shadow-lg);
    width: 100%;
    max-width: 500px;
    max-height: 90vh;
    overflow-y: auto;
}

.dialog-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.25rem;
    border-bottom: 1px solid var(--color-gray-200);
}

.dialog-title {
    font-size: 1.25rem;
    font-weight: 600;
}

.dialog-close {
    background: none;
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
    color: var(--color-gray-500);
}

.dialog-close:hover {
    color: var(--color-black);
}

.dialog-content {
    padding: 1.25rem;
}

.dialog>form {
    padding: 1.25rem;
}

.dialog-actions {
    padding: 1.25rem;
    display: flex;
    justify-content: flex-end;
    gap: 0.5rem;
    border-top: 1px solid var(--color-gray-200);
}

/* Project Detail Page */
.project-stats-bar {
    display: flex;
    gap: 1rem;
    background-color: var(--color-white);
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
    padding: 1rem 1.5rem;
    margin-bottom: 1.5rem;
    flex-wrap: wrap;
}

.project-stats-bar .stat-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 0.5rem 1rem;
    min-width: 80px;
}

.project-stats-bar .stat-number {
    font-size: 1.5rem;
    font-weight: 700;
}

.project-stats-bar .stat-label {
    font-size: 0.75rem;
    color: var(--color-gray-500);
}

.stat-new {
    color: #1e40af;
}

.stat-progress {
    color: #92400e;
}

.stat-done {
    color: #166534;
}

.project-layout {
    display: grid;
    grid-template-columns: 1fr 320px;
    gap: 1.5rem;
}

.project-main {
    min-width: 0;
}

.project-sidebar {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

/* Task Detail Layout */
.task-layout {
    display: grid;
    grid-template-columns: 1fr 320px;
    gap: 1.5rem;
}

.task-main {
    min-width: 0;
}

/* Task Detail Tabs */
.task-detail-tabs {
    display: flex;
    gap: 0;
    margin-bottom: 1.5rem;
    background: var(--color-gray-100);
    border-radius: 0.5rem;
    padding: 0.25rem;
}

.task-tab {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.75rem 1rem;
    background: transparent;
    border: none;
    color: var(--color-gray-500);
    cursor: pointer;
    border-radius: 0.375rem;
    transition: all 0.2s ease;
    font-size: 0.875rem;
    font-weight: 500;
}

.task-tab:hover {
    color: var(--color-gray-700);
}

.task-tab.active {
    color: var(--color-black);
    background: var(--color-white);
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05);
}

.task-tab i {
    font-size: 0.875rem;
}

.task-tab-content {
    display: none;
}

.task-tab-content.active {
    display: block;
}

.task-sidebar {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.sidebar-section {
    background-color: var(--color-white);
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
    padding: 1.25rem;
}

.sidebar-section h3 {
    font-size: 0.875rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--color-gray-500);
    margin-bottom: 1rem;
}

.detail-list {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.detail-item {
    display: flex;
    justify-content: space-between;
    font-size: 0.875rem;
}

.detail-label {
    color: var(--color-gray-500);
}

.detail-value {
    font-weight: 500;
}

/* Evaluation Sidebar Card */
.sidebar-evaluation h3 {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.sidebar-evaluation h3 i {
    font-size: 0.75rem;
    opacity: 0.7;
}

.evaluation-sidebar-grid {
    display: flex;
    flex-direction: column;
    gap: 0.875rem;
}

.evaluation-sidebar-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.evaluation-sidebar-label {
    font-size: 0.8125rem;
    color: var(--color-gray-500);
    font-weight: 500;
}

.evaluation-sidebar-item .form-select-compact {
    width: auto;
    min-width: 100px;
    font-size: 0.8125rem;
    padding: 0.375rem 0.625rem;
}

.evaluation-sidebar-item .badge {
    font-size: 0.75rem;
}

/* Time Tracking Sidebar Card */
.sidebar-time-tracking h3 {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.sidebar-time-tracking h3 i {
    font-size: 0.75rem;
    opacity: 0.7;
}

.time-tracker-display {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.75rem;
    margin-bottom: 1rem;
    padding: 0.875rem;
    background: var(--color-gray-50);
    border-radius: 0.5rem;
}

.time-tracker-current,
.time-tracker-total {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.25rem;
}

.time-tracker-value {
    font-size: 1.25rem;
    font-weight: 600;
    font-variant-numeric: tabular-nums;
    color: var(--color-gray-900);
    letter-spacing: -0.02em;
}

.time-tracker-total-value {
    font-size: 1rem;
    font-weight: 600;
    color: var(--color-primary);
}

.time-tracker-label {
    font-size: 0.6875rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--color-gray-500);
    font-weight: 500;
}

.time-tracker-actions {
    display: flex;
    gap: 0.5rem;
}

.btn-timer {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.375rem;
    padding: 0.5rem 0.75rem;
    border: none;
    border-radius: 0.375rem;
    font-size: 0.8125rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.15s ease;
}

.btn-timer i {
    font-size: 0.75rem;
}

.btn-timer-start {
    background: #171717;
    color: #fff;
}

.btn-timer-start:hover {
    background: #404040;
}

.btn-timer-stop {
    background: #ef4444;
    color: white;
}

.btn-timer-stop:hover {
    background: #dc2626;
}

.btn-timer-history {
    flex: 0 0 auto;
    padding: 0.5rem;
    background: var(--color-gray-100);
    color: var(--color-gray-600);
}

.btn-timer-history:hover {
    background: var(--color-gray-200);
    color: var(--color-gray-900);
}

/* Running timer animation */
.sidebar-time-tracking.timer-running .time-tracker-current {
    position: relative;
}

.sidebar-time-tracking.timer-running .time-tracker-value {
    color: #16a34a;
}

.sidebar-time-tracking.timer-running .time-tracker-current::before {
    content: '';
    position: absolute;
    top: -4px;
    right: -4px;
    width: 8px;
    height: 8px;
    background: #22c55e;
    border-radius: 50%;
    animation: pulse-dot 1.5s ease-in-out infinite;
}

@keyframes pulse-dot {
    0%, 100% { opacity: 1; transform: scale(1); }
    50% { opacity: 0.5; transform: scale(0.8); }
}

/* Quick Add Task */
.quick-add-section {
    background-color: var(--color-white);
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
    padding: 1rem;
    margin-bottom: 1.5rem;
}

.quick-add-form {
    display: flex;
    gap: 0.75rem;
    align-items: center;
}

.quick-add-input {
    flex: 1;
    padding: 0.75rem 1rem;
    border: 2px solid var(--color-gray-200);
    border-radius: var(--border-radius);
    font-size: 1rem;
    transition: border-color 0.2s;
}

.quick-add-input:focus {
    outline: none;
    border-color: var(--color-black);
}

/* Inline Task Details Expanded Section */
.task-details-expanded {
    margin-top: 1rem;
    padding-top: 1rem;
    border-top: 1px solid var(--color-gray-200);
    animation: slideDown 0.2s ease-out;
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.inline-task-fields {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.inline-task-fields-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
}

.inline-task-fields .form-group {
    margin-bottom: 0;
}

.inline-task-fields .form-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--color-gray-700);
}

.inline-task-fields .form-input {
    width: 100%;
    padding: 0.5rem 0.75rem;
    border: 1px solid var(--color-gray-200);
    border-radius: var(--border-radius);
    font-size: 0.875rem;
    transition: border-color 0.2s;
}

.inline-task-fields .form-input:focus {
    outline: none;
    border-color: var(--color-black);
}

.inline-task-fields .form-textarea {
    resize: vertical;
    min-height: 60px;
}

.inline-task-fields .form-color-input {
    padding: 0.25rem;
    height: 38px;
    cursor: pointer;
}

.inline-task-fields .form-group-checkbox {
    padding-top: 0.5rem;
}

.inline-task-fields .checkbox-label {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    cursor: pointer;
    font-size: 0.875rem;
}

.inline-task-fields .checkbox-label input[type="checkbox"] {
    width: 1rem;
    height: 1rem;
    cursor: pointer;
}

.inline-task-error {
    margin-top: 1rem;
    padding: 0.75rem;
    background-color: #fef2f2;
    border: 1px solid #fecaca;
    border-radius: var(--border-radius);
    color: #dc2626;
    font-size: 0.875rem;
}

@media (max-width: 600px) {
    .inline-task-fields-row {
        grid-template-columns: 1fr;
    }
}

/* Task List */
.task-list {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.task-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    background-color: var(--color-white);
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
    padding: 1rem;
    transition: box-shadow 0.2s;
}

.task-item:hover {
    box-shadow: var(--shadow-md);
}

.task-item.task-done {
    opacity: 0.7;
}

.task-item.task-done .task-name {
    text-decoration: line-through;
    color: var(--color-gray-500);
}

.task-color-indicator {
    width: 4px;
    height: 40px;
    border-radius: 2px;
    flex-shrink: 0;
}

.task-content {
    flex: 1;
    min-width: 0;
}

.task-header {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 0.25rem;
}

.task-name {
    font-weight: 500;
    color: var(--color-black);
    text-decoration: none;
}

.task-name:hover {
    text-decoration: underline;
}

.task-meta {
    display: flex;
    gap: 1rem;
    font-size: 0.75rem;
    color: var(--color-gray-500);
}

.task-category {
    background-color: var(--color-gray-100);
    padding: 0.125rem 0.5rem;
    border-radius: 4px;
}

.task-deadline.overdue {
    color: var(--color-error);
    font-weight: 500;
}

.task-actions {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    flex-shrink: 0;
}

.status-quick-form {
    display: inline;
}

.status-select {
    padding: 0.375rem 0.5rem;
    border: 1px solid var(--color-gray-300);
    border-radius: var(--border-radius);
    font-size: 0.75rem;
    background-color: var(--color-white);
    cursor: pointer;
}

.status-select:focus {
    outline: none;
    border-color: var(--color-black);
}

/* Team List */
.team-list {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.team-member-item {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.5rem;
    border-radius: var(--border-radius);
    transition: background-color 0.2s;
}

.team-member-item:hover {
    background-color: var(--color-gray-100);
}

.team-member-item.owner {
    background-color: var(--color-gray-100);
}

.member-avatar {
    width: 36px;
    height: 36px;
    background-color: var(--color-black);
    color: var(--color-white);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    font-size: 0.875rem;
    flex-shrink: 0;
}

.member-info {
    flex: 1;
    min-width: 0;
}

.member-name {
    display: block;
    font-weight: 500;
    font-size: 0.875rem;
}

.member-role {
    display: block;
    font-size: 0.75rem;
    color: var(--color-gray-500);
}

.btn-icon {
    width: 24px;
    height: 24px;
    border: none;
    background: none;
    color: var(--color-gray-400);
    cursor: pointer;
    font-size: 1.25rem;
    line-height: 1;
    border-radius: 4px;
    transition: all 0.2s;
}

.btn-icon:hover {
    background-color: var(--color-gray-200);
    color: var(--color-error);
}

.add-member-section {
    margin-top: 1rem;
    padding-top: 1rem;
    border-top: 1px solid var(--color-gray-200);
}

.add-member-form-compact {
    display: flex;
    gap: 0.5rem;
}

.form-select-sm {
    flex: 1;
    padding: 0.375rem 0.5rem;
    border: 1px solid var(--color-gray-300);
    border-radius: var(--border-radius);
    font-size: 0.75rem;
    min-width: 0;
}

/* Quick Actions */
.quick-actions {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.action-link {
    display: block;
    padding: 0.5rem 0;
    font-size: 0.875rem;
    color: var(--color-gray-700);
    text-decoration: none;
    transition: color 0.2s;
}

.action-link:hover {
    color: var(--color-black);
    text-decoration: none;
}

/* Empty State Enhanced */
.empty-state .empty-icon {
    font-size: 3rem;
    margin-bottom: 1rem;
}

.empty-state h3 {
    margin-bottom: 0.5rem;
    color: var(--color-gray-700);
}

.text-muted {
    color: var(--color-gray-500);
}

/* Task Count */
.task-count {
    font-size: 1rem;
    color: var(--color-gray-500);
    font-weight: normal;
}

/* Color Dot Large */
.color-dot.large {
    width: 24px;
    height: 24px;
}

/* Responsive - General Layout */
@media (max-width: 768px) {
    .cards-grid {
        grid-template-columns: 1fr;
    }

    .form-row {
        grid-template-columns: 1fr;
    }

    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .header-content {
        flex-direction: column;
        align-items: flex-start;
    }

    .profile-info {
        flex-direction: column;
        text-align: center;
    }

    .project-layout {
        grid-template-columns: 1fr;
    }

    .project-sidebar {
        order: -1;
    }

    .task-layout {
        grid-template-columns: 1fr;
    }

    .task-sidebar {
        order: -1;
    }

    .quick-add-form {
        flex-wrap: wrap;
    }

    .quick-add-input {
        width: 100%;
    }

    .task-item {
        flex-wrap: wrap;
    }

    .task-actions {
        width: 100%;
        justify-content: flex-end;
        margin-top: 0.5rem;
    }

    .project-stats-bar {
        justify-content: space-around;
    }

    .project-stats-bar .stat-item {
        min-width: 60px;
        padding: 0.5rem;
    }

    .add-assignee-inline {
        flex-wrap: wrap;
    }

    .form-select-compact {
        flex: 1;
        min-width: 120px;
    }

    /* Show remove button always on mobile (no hover) */
    .assignee-remove {
        opacity: 1;
    }
}

/* Modal Form Styles */
.dialog-form {
    max-width: 550px;
}

.modal-form .form-group {
    margin-bottom: 1rem;
}

.modal-form .form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
}

.modal-form label {
    display: block;
    margin-bottom: 0.375rem;
    font-weight: 500;
    font-size: 0.875rem;
}

.modal-form input[type="text"],
.modal-form input[type="number"],
.modal-form input[type="date"],
.modal-form textarea {
    width: 100%;
    padding: 0.625rem 0.75rem;
    border: 1px solid var(--color-gray-300);
    border-radius: var(--border-radius);
    font-size: 0.875rem;
    transition: border-color 0.2s;
}

.modal-form input[type="text"]:focus,
.modal-form input[type="number"]:focus,
.modal-form input[type="date"]:focus,
.modal-form textarea:focus {
    outline: none;
    border-color: var(--color-black);
}

.modal-form input[type="color"] {
    width: 100%;
    height: 38px;
    padding: 0.25rem;
    border: 1px solid var(--color-gray-300);
    border-radius: var(--border-radius);
    cursor: pointer;
}

.modal-form .checkbox-label {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    cursor: pointer;
}

.modal-form .checkbox-label input[type="checkbox"] {
    width: 1rem;
    height: 1rem;
}

.modal-form .form-help {
    font-size: 0.75rem;
    color: var(--color-gray-500);
    margin-top: 0.25rem;
}

.modal-form .form-error {
    background-color: #fef2f2;
    color: var(--color-error);
    padding: 0.75rem;
    border-radius: var(--border-radius);
    margin-bottom: 1rem;
    font-size: 0.875rem;
    border: 1px solid #fecaca;
}

.modal-form .form-actions {
    display: flex;
    justify-content: flex-end;
    gap: 0.75rem;
    margin-top: 1.5rem;
    padding-top: 1rem;
    border-top: 1px solid var(--color-gray-200);
}

.modal-form .btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

@media (max-width: 480px) {
    .modal-form .form-row {
        grid-template-columns: 1fr;
    }

    .modal-form .form-actions {
        flex-direction: column;
    }

    .modal-form .form-actions .btn {
        width: 100%;
    }
}

/* Files Section */
.files-section {
    margin-bottom: 2.5rem;
}

.files-section h2 {
    margin-bottom: 1rem;
}

.file-upload-form {
    background-color: var(--color-white);
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
    padding: 1.25rem;
    margin-bottom: 1rem;
}

.file-upload-form form {
    display: flex;
    gap: 1rem;
    align-items: center;
    flex-wrap: wrap;
}

.file-input-wrapper {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    flex: 1;
    min-width: 250px;
}

.file-input {
    display: none;
}

.file-input-label {
    cursor: pointer;
    white-space: nowrap;
}

.selected-file-name {
    font-size: 0.875rem;
    color: var(--color-gray-600);
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    max-width: 200px;
}

.upload-progress {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-top: 0.75rem;
    padding-top: 0.75rem;
    border-top: 1px solid var(--color-gray-200);
}

.progress-bar {
    flex: 1;
    height: 8px;
    background-color: var(--color-gray-200);
    border-radius: 4px;
    overflow: hidden;
}

.progress-fill {
    height: 100%;
    background-color: var(--color-black);
    border-radius: 4px;
    width: 0%;
    transition: width 0.2s ease;
}

.progress-text {
    font-size: 0.75rem;
    color: var(--color-gray-600);
    white-space: nowrap;
}

/* Files List */
.files-list {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.file-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    background-color: var(--color-white);
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
    padding: 1rem;
    transition: box-shadow 0.2s;
}

.file-item:hover {
    box-shadow: var(--shadow-md);
}

.file-icon {
    width: 48px;
    height: 48px;
    background-color: var(--color-gray-100);
    border-radius: var(--border-radius-sm);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 0.625rem;
    color: var(--color-gray-600);
    text-transform: uppercase;
    flex-shrink: 0;
}

.file-info {
    flex: 1;
    min-width: 0;
}

.file-name {
    font-weight: 500;
    font-size: 0.9375rem;
    color: var(--color-black);
    display: block;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.file-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 0.25rem;
    font-size: 0.75rem;
    color: var(--color-gray-500);
    margin-top: 0.25rem;
}

.file-separator {
    color: var(--color-gray-300);
}

.file-actions {
    display: flex;
    gap: 0.5rem;
    flex-shrink: 0;
}

@media (max-width: 768px) {
    .file-upload-form form {
        flex-direction: column;
        align-items: stretch;
    }

    .file-input-wrapper {
        flex-direction: column;
        align-items: flex-start;
    }

    .selected-file-name {
        max-width: 100%;
    }

    .file-item {
        flex-wrap: wrap;
    }

    .file-info {
        min-width: calc(100% - 64px);
    }

    .file-actions {
        width: 100%;
        justify-content: flex-end;
        margin-top: 0.5rem;
        padding-top: 0.5rem;
        border-top: 1px solid var(--color-gray-100);
    }
}

/* Links Section */
.links-section {
    margin-bottom: 2.5rem;
}

.links-section h2 {
    margin-bottom: 1rem;
}

.link-add-form {
    background-color: var(--color-white);
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
    padding: 1.25rem;
    margin-bottom: 1rem;
}

.link-add-form form {
    display: flex;
    gap: 1rem;
    align-items: center;
    flex-wrap: wrap;
}

.link-input-wrapper {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    flex: 1;
    min-width: 250px;
}

.link-input-wrapper .form-input {
    flex: 1;
    min-width: 150px;
}

.link-input-wrapper .form-input:first-child {
    flex: 2;
}

/* Links List */
.links-list {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.link-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    background-color: var(--color-white);
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
    padding: 1rem;
    transition: box-shadow 0.2s;
}

.link-item:hover {
    box-shadow: var(--shadow-md);
}

.link-icon {
    width: 48px;
    height: 48px;
    background-color: var(--color-gray-100);
    border-radius: var(--border-radius-sm);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 0.625rem;
    color: var(--color-gray-600);
    text-transform: uppercase;
    flex-shrink: 0;
}

.link-info {
    flex: 1;
    min-width: 0;
}

.link-name {
    font-weight: 500;
    font-size: 0.9375rem;
    color: var(--color-black);
    display: block;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    text-decoration: none;
}

.link-name:hover {
    text-decoration: underline;
}

.link-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 0.25rem;
    font-size: 0.75rem;
    color: var(--color-gray-500);
    margin-top: 0.25rem;
}

.link-url {
    max-width: 300px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.link-separator {
    color: var(--color-gray-300);
}

.link-actions {
    display: flex;
    gap: 0.5rem;
    flex-shrink: 0;
}

@media (max-width: 768px) {
    .link-add-form form {
        flex-direction: column;
        align-items: stretch;
    }

    .link-input-wrapper {
        flex-direction: column;
        align-items: stretch;
    }

    .link-input-wrapper .form-input {
        width: 100%;
    }

    .link-item {
        flex-wrap: wrap;
    }

    .link-info {
        min-width: calc(100% - 64px);
    }

    .link-url {
        max-width: 100%;
    }

    .link-actions {
        width: 100%;
        justify-content: flex-end;
        margin-top: 0.5rem;
        padding-top: 0.5rem;
        border-top: 1px solid var(--color-gray-100);
    }
}

/* Inline Description Editing */
.description-container {
    margin-bottom: 1rem;
}

/* Notes Card Styling for Description View */
.description-view {
    background: var(--color-white);
    border-radius: var(--border-radius-sm);
    border: 1px solid var(--color-gray-100);
    box-shadow: var(--shadow-sm);
    padding: 1rem 1.25rem;
    transition: all 0.15s ease;
}

.description-view.editable {
    cursor: pointer;
}

.description-view.editable:hover {
    border-color: var(--color-gray-200);
    box-shadow: var(--shadow);
}

.description-view .task-description {
    margin: 0;
}

.description-view.editable .task-description {
    cursor: pointer;
}

.description-view.editable .task-description::after {
    content: '';
    display: inline-block;
    width: 14px;
    height: 14px;
    margin-left: 0.5rem;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23a3a3a3' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M11 4H4a2 2 0 0 0-2 2v14a2 2 0 0 0 2 2h14a2 2 0 0 0 2-2v-7'%3E%3C/path%3E%3Cpath d='M18.5 2.5a2.121 2.121 0 0 1 3 3L12 15l-4 1 1-4 9.5-9.5z'%3E%3C/path%3E%3C/svg%3E");
    background-size: contain;
    background-repeat: no-repeat;
    vertical-align: middle;
    opacity: 0;
    transition: opacity 0.15s ease;
}

.description-view.editable .task-description:hover::after {
    opacity: 1;
}

.task-description-empty {
    color: var(--color-gray-400);
    font-style: italic;
}

/* Task Description Markdown Styles */
.task-description.markdown-content {
    cursor: pointer;
}

.task-description.markdown-content p:first-child {
    margin-top: 0;
}

.task-description.markdown-content p:last-child {
    margin-bottom: 0;
}

.task-description.markdown-content h1,
.task-description.markdown-content h2,
.task-description.markdown-content h3 {
    margin-top: 1em;
}

.task-description.markdown-content h1:first-child,
.task-description.markdown-content h2:first-child,
.task-description.markdown-content h3:first-child {
    margin-top: 0;
}

.description-edit {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.description-textarea {
    width: 100%;
    min-height: 120px;
    padding: 0.75rem;
    border: 2px solid var(--color-gray-300);
    border-radius: var(--border-radius);
    font-size: 1rem;
    font-family: inherit;
    line-height: 1.6;
    resize: vertical;
    transition: border-color 0.2s ease;
}

.description-textarea:focus {
    outline: none;
    border-color: var(--color-black);
}

.description-edit-actions {
    display: flex;
    gap: 0.5rem;
}

.description-edit-error {
    background-color: #fef2f2;
    color: var(--color-error);
    padding: 0.75rem;
    border-radius: var(--border-radius);
    font-size: 0.875rem;
    border: 1px solid #fecaca;
}

/* =====================================================
   ENHANCED MARKDOWN EDITOR
   A refined, editorial-style editor with split view
   ===================================================== */

/* Editor Container */
.description-editor-container {
    border: 1px solid var(--color-gray-200);
    border-radius: var(--border-radius);
    background: var(--color-white);
    overflow: hidden;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04);
}

/* Toolbar */
.description-editor-toolbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    padding: 0.5rem 0.75rem;
    background: linear-gradient(to bottom, var(--color-gray-50), var(--color-gray-100));
    border-bottom: 1px solid var(--color-gray-200);
}

.toolbar-section {
    display: flex;
    align-items: center;
    gap: 0.375rem;
}

.toolbar-section-left {
    gap: 0.5rem;
}

.toolbar-divider {
    width: 1px;
    height: 20px;
    background: var(--color-gray-300);
    margin: 0 0.25rem;
}

/* Format Buttons */
.format-btn-group {
    display: flex;
    gap: 2px;
    background: var(--color-white);
    padding: 3px;
    border-radius: 8px;
    border: 1px solid var(--color-gray-200);
}

.format-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 28px;
    border: none;
    background: transparent;
    color: var(--color-gray-600);
    border-radius: 5px;
    cursor: pointer;
    font-size: 0.8125rem;
    font-weight: 600;
    transition: all 0.15s ease;
}

.format-btn:hover {
    background: var(--color-gray-100);
    color: var(--color-gray-900);
}

.format-btn:active {
    background: var(--color-gray-200);
    transform: scale(0.95);
}

.format-btn i {
    font-size: 0.75rem;
}

/* View Mode Dropdown */
.view-mode-dropdown {
    position: relative;
}

.view-mode-trigger {
    display: inline-flex;
    align-items: center;
    gap: 0.375rem;
    padding: 0.375rem 0.625rem;
    background: var(--color-white);
    border: 1px solid var(--color-gray-200);
    border-radius: 6px;
    font-size: 0.75rem;
    font-weight: 500;
    color: var(--color-gray-700);
    cursor: pointer;
    transition: all 0.15s ease;
}

.view-mode-trigger:hover {
    border-color: var(--color-gray-300);
    background: var(--color-gray-50);
}

.view-mode-trigger i {
    font-size: 0.6875rem;
    transition: transform 0.2s ease;
}

.view-mode-dropdown.open .view-mode-trigger i:last-child {
    transform: rotate(180deg);
}

.view-mode-menu {
    position: absolute;
    top: calc(100% + 4px);
    left: 0;
    min-width: 140px;
    background: var(--color-white);
    border: 1px solid var(--color-gray-200);
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    opacity: 0;
    visibility: hidden;
    transform: translateY(-4px);
    transition: all 0.15s ease;
    z-index: 100;
    padding: 4px;
}

.view-mode-dropdown.open .view-mode-menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.view-mode-option {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 0.625rem;
    font-size: 0.8125rem;
    color: var(--color-gray-700);
    border-radius: 5px;
    cursor: pointer;
    transition: all 0.1s ease;
}

.view-mode-option:hover {
    background: var(--color-gray-100);
    color: var(--color-gray-900);
}

.view-mode-option.active {
    background: var(--color-gray-900);
    color: var(--color-white);
}

.view-mode-option i {
    width: 14px;
    text-align: center;
    font-size: 0.75rem;
}

/* Keyboard Hints */
.keyboard-hints {
    display: flex;
    align-items: center;
    gap: 0.625rem;
    font-size: 0.6875rem;
    color: var(--color-gray-400);
}

.kbd-combo {
    display: inline-flex;
    align-items: center;
    gap: 3px;
}

kbd {
    display: inline-block;
    padding: 2px 5px;
    font-size: 0.625rem;
    font-family: inherit;
    font-weight: 500;
    background: var(--color-white);
    border: 1px solid var(--color-gray-300);
    border-radius: 4px;
    box-shadow: 0 1px 0 var(--color-gray-200);
    color: var(--color-gray-600);
}

/* Action Buttons */
.editor-actions {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.editor-actions .btn-sm {
    padding: 0.375rem 0.875rem;
    font-size: 0.75rem;
    border-radius: 6px;
}

/* Editor Layout - Split View */
.description-editor-layout {
    display: grid;
    grid-template-columns: 1fr 1fr;
    min-height: 280px;
    max-height: 450px;
}

.description-editor-layout.editor-only {
    grid-template-columns: 1fr;
}

.description-editor-layout.editor-only .preview-panel {
    display: none;
}

.description-editor-layout.preview-only {
    grid-template-columns: 1fr;
}

.description-editor-layout.preview-only .editor-panel {
    display: none;
}

/* Panels */
.editor-panel,
.preview-panel {
    display: flex;
    flex-direction: column;
    min-height: 0;
    overflow: hidden;
}

.editor-panel {
    border-right: 1px solid var(--color-gray-200);
}

.description-editor-layout.editor-only .editor-panel {
    border-right: none;
}

.panel-header {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 0.75rem;
    background: var(--color-gray-50);
    border-bottom: 1px solid var(--color-gray-100);
    font-size: 0.6875rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--color-gray-500);
}

.panel-header i {
    font-size: 0.625rem;
}

/* CodeMirror Container */
.editor-wrapper {
    flex: 1;
    overflow: hidden;
}

/* Editor-only mode (no split view) */
.description-editor-container > .editor-wrapper {
    min-height: 200px;
    max-height: 400px;
    border-top: 1px solid var(--color-gray-100);
}

.description-editor-container > .editor-wrapper .CodeMirror {
    height: 100%;
    min-height: 200px;
    max-height: 400px;
}

.editor-wrapper .CodeMirror {
    height: 100%;
    font-family: 'SF Mono', 'Monaco', 'Inconsolata', 'Fira Code', 'Fira Mono', monospace;
    font-size: 0.875rem;
    line-height: 1.65;
    background: var(--color-white);
}

.editor-wrapper .CodeMirror-gutters {
    background: var(--color-gray-50);
    border-right: 1px solid var(--color-gray-100);
    padding-right: 4px;
}

.editor-wrapper .CodeMirror-linenumber {
    color: var(--color-gray-400);
    font-size: 0.75rem;
    padding: 0 8px 0 4px;
}

.editor-wrapper .CodeMirror-cursor {
    border-left-color: var(--color-gray-900);
}

.editor-wrapper .CodeMirror-selected {
    background: rgba(0, 0, 0, 0.08);
}

.editor-wrapper .CodeMirror-focused .CodeMirror-selected {
    background: rgba(0, 0, 0, 0.1);
}

/* Preview Panel */
.preview-wrapper {
    flex: 1;
    overflow-y: auto;
    background: var(--color-white);
}

.preview-content {
    padding: 1rem;
    font-size: 0.9375rem;
    line-height: 1.7;
    color: var(--color-gray-800);
}

.preview-content:empty::before {
    content: 'Preview will appear here...';
    color: var(--color-gray-400);
    font-style: italic;
}

/* Status Bar */
.editor-status-bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.375rem 0.75rem;
    background: var(--color-gray-50);
    border-top: 1px solid var(--color-gray-100);
    font-size: 0.6875rem;
    color: var(--color-gray-500);
}

.status-indicator {
    display: flex;
    align-items: center;
    gap: 0.375rem;
}

.status-indicator i {
    font-size: 0.5rem;
}

/* Responsive: Mobile */
@media (max-width: 768px) {
    .description-editor-toolbar {
        flex-wrap: wrap;
        gap: 0.5rem;
        padding: 0.5rem;
    }

    .toolbar-section-left {
        width: 100%;
        justify-content: space-between;
    }

    .keyboard-hints {
        display: none;
    }

    .description-editor-layout {
        grid-template-columns: 1fr;
        min-height: 200px;
        max-height: 350px;
    }

    .description-editor-layout .preview-panel {
        display: none;
    }

    .description-editor-layout.preview-only .preview-panel {
        display: flex;
    }

    .description-editor-layout.preview-only .editor-panel {
        display: none;
    }

    .editor-panel {
        border-right: none;
    }
}

/* =====================================================
   DARK MODE - Enhanced Editor
   ===================================================== */

body.dark-mode .description-editor-container {
    background: #1a1a1a;
    border-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .description-editor-toolbar {
    background: linear-gradient(to bottom, #262626, #1f1f1f);
    border-bottom-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .format-btn-group {
    background: #262626;
    border-color: rgba(255, 255, 255, 0.15);
}

body.dark-mode .format-btn {
    color: #a3a3a3;
}

body.dark-mode .format-btn:hover {
    background: #333333;
    color: #e5e5e5;
}

body.dark-mode .format-btn:active {
    background: #404040;
}

body.dark-mode .view-mode-trigger {
    background: #262626;
    border-color: rgba(255, 255, 255, 0.15);
    color: #a3a3a3;
}

body.dark-mode .view-mode-trigger:hover {
    background: #333333;
    border-color: rgba(255, 255, 255, 0.2);
}

body.dark-mode .view-mode-menu {
    background: #262626;
    border-color: rgba(255, 255, 255, 0.15);
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.4);
}

body.dark-mode .view-mode-option {
    color: #a3a3a3;
}

body.dark-mode .view-mode-option:hover {
    background: #333333;
    color: #e5e5e5;
}

body.dark-mode .view-mode-option.active {
    background: #e5e5e5;
    color: #171717;
}

body.dark-mode kbd {
    background: #262626;
    border-color: rgba(255, 255, 255, 0.2);
    box-shadow: 0 1px 0 rgba(255, 255, 255, 0.1);
    color: #a3a3a3;
}

body.dark-mode .panel-header {
    background: #1f1f1f;
    border-bottom-color: rgba(255, 255, 255, 0.08);
    color: #737373;
}

body.dark-mode .editor-panel {
    border-right-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .editor-wrapper .CodeMirror {
    background: #1a1a1a;
    color: #e5e5e5;
}

body.dark-mode .editor-wrapper .CodeMirror-gutters {
    background: #1f1f1f;
    border-right-color: rgba(255, 255, 255, 0.08);
}

body.dark-mode .editor-wrapper .CodeMirror-linenumber {
    color: #525252;
}

body.dark-mode .editor-wrapper .CodeMirror-cursor {
    border-left-color: #e5e5e5;
}

body.dark-mode .editor-wrapper .CodeMirror-selected {
    background: rgba(255, 255, 255, 0.1);
}

body.dark-mode .editor-wrapper .CodeMirror-focused .CodeMirror-selected {
    background: rgba(255, 255, 255, 0.15);
}

body.dark-mode .preview-wrapper {
    background: #1a1a1a;
}

body.dark-mode .preview-content {
    color: #d4d4d4;
}

body.dark-mode .preview-content:empty::before {
    color: #525252;
}

body.dark-mode .editor-status-bar {
    background: #1f1f1f;
    border-top-color: rgba(255, 255, 255, 0.08);
    color: #525252;
}

body.dark-mode .toolbar-divider {
    background: rgba(255, 255, 255, 0.15);
}

body.dark-mode .description-edit-error {
    background-color: rgba(239, 68, 68, 0.15);
    border-color: rgba(239, 68, 68, 0.3);
}

/* Project Description Inline Editing */
.project-description-container {
    margin-bottom: 1rem;
}

.project-description-view.editable .project-description {
    cursor: pointer;
    padding: 0.5rem;
    margin: -0.5rem;
    border-radius: var(--border-radius-sm);
    transition: background-color 0.15s ease;
}

.project-description-view.editable .project-description:hover {
    background-color: var(--color-gray-100);
}

.project-description-view.editable .project-description::after {
    content: '';
    display: inline-block;
    width: 12px;
    height: 12px;
    margin-left: 0.5rem;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23a3a3a3' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M11 4H4a2 2 0 0 0-2 2v14a2 2 0 0 0 2 2h14a2 2 0 0 0 2-2v-7'%3E%3C/path%3E%3Cpath d='M18.5 2.5a2.121 2.121 0 0 1 3 3L12 15l-4 1 1-4 9.5-9.5z'%3E%3C/path%3E%3C/svg%3E");
    background-size: contain;
    background-repeat: no-repeat;
    vertical-align: middle;
    opacity: 0;
    transition: opacity 0.15s ease;
}

.project-description-view.editable .project-description:hover::after {
    opacity: 1;
}

.project-description-empty {
    color: var(--color-gray-400);
    font-style: italic;
}

.project-description-edit {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.project-description-edit .description-textarea {
    min-height: 80px;
    font-size: 0.875rem;
}

/* Data Table */
.table-container {
    background-color: var(--color-white);
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
    overflow: hidden;
}

.data-table {
    width: 100%;
    border-collapse: collapse;
}

.data-table th,
.data-table td {
    padding: 0.875rem 1rem;
    text-align: left;
    border-bottom: 1px solid var(--color-gray-100);
}

.data-table th {
    background-color: var(--color-gray-50);
    font-weight: 600;
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--color-gray-600);
}

.data-table td {
    font-size: 0.875rem;
    color: var(--color-gray-700);
}

.data-table tbody tr:hover {
    background-color: var(--color-gray-50);
}

.data-table tbody tr:last-child td {
    border-bottom: none;
}

/* Filter Form */
.filter-form .form-row {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    align-items: flex-end;
}

.filter-form .form-group {
    margin-bottom: 0;
    flex: 1;
    min-width: 150px;
}

.filter-form .form-actions-inline {
    display: flex;
    gap: 0.5rem;
    flex: 0 0 auto;
    padding-bottom: 0;
}

.filter-form .form-control {
    width: 100%;
    padding: 0.625rem 0.75rem;
    border: 1px solid var(--color-gray-300);
    border-radius: var(--border-radius);
    font-size: 0.875rem;
}

.filter-form .form-control:focus {
    outline: none;
    border-color: var(--color-black);
}

@media (max-width: 768px) {
    .data-table {
        display: block;
        overflow-x: auto;
    }

    .filter-form .form-row {
        flex-direction: column;
    }

    .filter-form .form-group {
        width: 100%;
    }
}

/* Today's Schedule Section (Dashboard) */
.todays-schedule-section {
    margin-bottom: 2.5rem;
}

.todays-schedule-section .section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
}

.today-date {
    font-size: 0.875rem;
    color: var(--color-gray-500);
    font-weight: 500;
}

.todays-tasks-list {
    background-color: var(--color-white);
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
    overflow: hidden;
}

.todays-task-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1rem 1.25rem;
    border-bottom: 1px solid var(--color-gray-100);
    transition: background-color 0.15s ease;
}

.todays-task-item:last-child {
    border-bottom: none;
}

.todays-task-item:hover {
    background-color: var(--color-gray-50);
}

.todays-task-color {
    width: 4px;
    height: 40px;
    border-radius: 2px;
    flex-shrink: 0;
}

.todays-task-info {
    flex: 1;
    min-width: 0;
}

.todays-task-name {
    display: block;
    font-size: 0.9375rem;
    font-weight: 500;
    color: var(--color-black);
    text-decoration: none;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.todays-task-name:hover {
    text-decoration: underline;
}

.todays-task-project {
    display: block;
    font-size: 0.75rem;
    color: var(--color-gray-500);
    margin-top: 0.125rem;
}

.todays-task-meta {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    flex-shrink: 0;
}

.deadline-overdue {
    display: flex;
    align-items: center;
    gap: 0.25rem;
    font-size: 0.75rem;
    color: var(--color-error);
    font-weight: 500;
}

.deadline-overdue i {
    font-size: 0.75rem;
}

@media (max-width: 768px) {
    .todays-schedule-section .section-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.25rem;
    }

    .todays-task-item {
        flex-wrap: wrap;
    }

    .todays-task-meta {
        width: 100%;
        margin-top: 0.5rem;
    }
}

/* Calendar Styles */
.calendar-container {
    max-width: 1400px;
}

.calendar-layout {
    display: grid;
    grid-template-columns: 320px 1fr;
    gap: 1.5rem;
}

/* Task Panel (Left Sidebar) */
.calendar-sidebar {
    min-width: 0;
}

.task-panel {
    background-color: var(--color-white);
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
    overflow: hidden;
}

.panel-header {
    padding: 1rem 1.25rem;
    border-bottom: 1px solid var(--color-gray-100);
}

.panel-header h3 {
    font-size: 1rem;
    font-weight: 600;
    margin: 0;
}

.task-filters {
    padding: 1rem 1.25rem;
    border-bottom: 1px solid var(--color-gray-100);
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.task-search {
    width: 100%;
    padding: 0.625rem 0.875rem;
    border: 1px solid var(--color-gray-300);
    border-radius: var(--border-radius);
    font-size: 0.875rem;
}

.task-search:focus {
    outline: none;
    border-color: var(--color-black);
}

.filter-row {
    display: flex;
    gap: 0.5rem;
}

.filter-select {
    flex: 1;
    padding: 0.5rem;
    border: 1px solid var(--color-gray-300);
    border-radius: var(--border-radius);
    font-size: 0.75rem;
    background-color: var(--color-white);
}

.filter-select:focus {
    outline: none;
    border-color: var(--color-black);
}

/* Task List Panel */
.task-list-panel {
    max-height: calc(100vh - 400px);
    overflow-y: auto;
    padding: 0.75rem;
}

.draggable-task {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.75rem;
    background-color: var(--color-gray-50);
    border-radius: var(--border-radius-sm);
    margin-bottom: 0.5rem;
    cursor: grab;
    transition: all 0.15s ease;
    border: 1px solid transparent;
}

.draggable-task:hover {
    background-color: var(--color-white);
    border-color: var(--color-gray-200);
    box-shadow: var(--shadow-sm);
}

.draggable-task.dragging {
    opacity: 0.5;
    cursor: grabbing;
}

.draggable-task .task-color-bar {
    width: 4px;
    height: 32px;
    border-radius: 2px;
    flex-shrink: 0;
}

.draggable-task .task-info {
    flex: 1;
    min-width: 0;
}

.draggable-task .task-name {
    display: block;
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--color-gray-900);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.draggable-task .task-project {
    display: block;
    font-size: 0.75rem;
    color: var(--color-gray-500);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.draggable-task .task-status-badge {
    flex-shrink: 0;
    font-size: 0.625rem;
    padding: 0.125rem 0.375rem;
}

.empty-task-list {
    padding: 2rem 1rem;
    text-align: center;
    color: var(--color-gray-500);
}

/* Calendar Main Area */
.calendar-main {
    min-width: 0;
}

.calendar-header {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1rem;
    background-color: var(--color-white);
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
    padding: 1rem 1.25rem;
}

.calendar-header h2 {
    flex: 1;
    font-size: 1.25rem;
    font-weight: 600;
    text-align: center;
    margin: 0;
}

/* Calendar Grid */
.calendar-grid {
    background-color: var(--color-white);
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
    overflow: hidden;
}

.calendar-weekdays {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    background-color: var(--color-gray-50);
    border-bottom: 1px solid var(--color-gray-100);
}

.weekday {
    padding: 0.75rem;
    text-align: center;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--color-gray-500);
}

.calendar-days {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
}

.calendar-day {
    min-height: 100px;
    padding: 0.5rem;
    border-right: 1px solid var(--color-gray-100);
    border-bottom: 1px solid var(--color-gray-100);
    cursor: pointer;
    transition: background-color 0.15s ease;
}

.calendar-day:nth-child(7n) {
    border-right: none;
}

.calendar-day:hover {
    background-color: var(--color-gray-50);
}

.calendar-day.other-month {
    background-color: var(--color-gray-50);
}

.calendar-day.other-month .day-number {
    color: var(--color-gray-400);
}

.calendar-day.today {
    background-color: #fef3c7;
}

.calendar-day.today .day-number {
    background-color: var(--color-black);
    color: var(--color-white);
    border-radius: 50%;
    width: 28px;
    height: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.calendar-day.selected {
    background-color: #dbeafe;
}

.calendar-day.drag-over {
    background-color: #dcfce7;
    border: 2px dashed var(--color-success);
}

.day-number {
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--color-gray-700);
    margin-bottom: 0.25rem;
}

.day-events {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}

.calendar-event {
    font-size: 0.6875rem;
    padding: 0.125rem 0.375rem;
    background-color: var(--color-gray-100);
    border-radius: 3px;
    border-left: 3px solid var(--color-black);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.calendar-event.after-deadline {
    background-color: #fee2e2;
    color: #991b1b;
}

.calendar-event-more {
    font-size: 0.625rem;
    color: var(--color-gray-500);
    padding: 0.125rem 0.375rem;
}

/* Day View */
.day-view {
    margin-top: 1rem;
    background-color: var(--color-white);
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
}

.day-view-header {
    padding: 1rem 1.25rem;
    border-bottom: 1px solid var(--color-gray-100);
}

.day-view-header h3 {
    font-size: 1rem;
    font-weight: 600;
    margin: 0;
}

.day-view-content {
    padding: 1rem 1.25rem;
}

.empty-day-view {
    padding: 2rem;
    text-align: center;
    color: var(--color-gray-500);
}

.day-tasks-list {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.day-task-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 0.75rem;
    background-color: var(--color-gray-50);
    border-radius: var(--border-radius-sm);
}

.day-task-color {
    width: 4px;
    height: 40px;
    border-radius: 2px;
    flex-shrink: 0;
}

.day-task-info {
    flex: 1;
    min-width: 0;
}

.day-task-name {
    display: block;
    font-size: 0.9375rem;
    font-weight: 500;
    color: var(--color-black);
    text-decoration: none;
}

.day-task-name:hover {
    text-decoration: underline;
}

.day-task-project {
    display: block;
    font-size: 0.75rem;
    color: var(--color-gray-500);
}

.deadline-warning {
    display: flex;
    align-items: center;
    gap: 0.25rem;
    font-size: 0.75rem;
    color: var(--color-error);
    margin-top: 0.25rem;
}

.deadline-warning i {
    font-size: 0.75rem;
}

.day-task-actions {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    flex-shrink: 0;
}

/* Calendar Notification */
.calendar-notification {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    padding: 0.875rem 1.25rem;
    border-radius: var(--border-radius);
    background-color: var(--color-white);
    box-shadow: var(--shadow-lg);
    font-size: 0.875rem;
    font-weight: 500;
    z-index: 1001;
    transform: translateY(100px);
    opacity: 0;
    transition: all 0.3s ease;
}

.calendar-notification.show {
    transform: translateY(0);
    opacity: 1;
}

.calendar-notification.success {
    border-left: 4px solid var(--color-success);
}

.calendar-notification.error {
    border-left: 4px solid var(--color-error);
}

.calendar-notification.warning {
    border-left: 4px solid var(--color-warning);
}

/* Responsive Calendar */
@media (max-width: 1024px) {
    .calendar-layout {
        grid-template-columns: 280px 1fr;
    }
}

@media (max-width: 768px) {
    .calendar-layout {
        grid-template-columns: 1fr;
    }

    .calendar-sidebar {
        order: 2;
    }

    .task-list-panel {
        max-height: 300px;
    }

    .calendar-day {
        min-height: 60px;
        padding: 0.25rem;
    }

    .day-number {
        font-size: 0.75rem;
    }

    .calendar-event {
        font-size: 0.5625rem;
        padding: 0.0625rem 0.25rem;
    }

    .weekday {
        padding: 0.5rem 0.25rem;
        font-size: 0.625rem;
    }
}

/* Project Header Image Banner */
.project-header-banner {
    position: relative;
    width: 100%;
    height: 200px;
    border-radius: var(--border-radius);
    overflow: hidden;
    margin-bottom: 1.5rem;
}

.project-header-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.header-banner-actions {
    position: absolute;
    top: 1rem;
    right: 1rem;
    display: flex;
    gap: 0.5rem;
    opacity: 0;
    transition: opacity 0.2s ease;
}

.project-header-banner:hover .header-banner-actions {
    opacity: 1;
}

.header-banner-actions .btn {
    background-color: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(8px);
}

.add-header-image-section {
    margin-bottom: 1.5rem;
    display: flex;
    justify-content: center;
}

/* Header Image Preview (forms) */
.header-image-section {
    border-top: 1px solid var(--color-gray-200);
    padding-top: 1rem;
    margin-top: 1rem;
}

.header-image-preview-container {
    margin: 1rem 0;
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    align-items: flex-start;
}

.header-image-preview {
    max-width: 100%;
    max-height: 200px;
    border-radius: var(--border-radius-sm);
    object-fit: cover;
    border: 1px solid var(--color-gray-200);
}

.file-upload-section {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    flex-wrap: wrap;
}

.file-upload-section .file-name {
    font-size: 0.875rem;
    color: var(--color-gray-600);
    max-width: 200px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

@media (max-width: 768px) {
    .project-header-banner {
        height: 150px;
        border-radius: var(--border-radius-sm);
    }

    .header-banner-actions {
        opacity: 1;
    }

    .file-upload-section {
        flex-direction: column;
        align-items: flex-start;
    }
}

/* Time Tracking Section */
.time-tracking-section {
    margin-top: 1.5rem;
    padding-top: 1.5rem;
    border-top: 1px solid var(--color-gray-200);
}

.time-tracking-section h3 {
    font-size: 0.875rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--color-gray-500);
    margin-bottom: 1rem;
}

.time-tracking-content {
    display: flex;
    align-items: center;
    gap: 1.5rem;
    flex-wrap: wrap;
}

.timer-display {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    background-color: var(--color-gray-100);
    padding: 0.75rem 1rem;
    border-radius: var(--border-radius);
    min-width: 140px;
}

.timer-icon {
    font-size: 1.25rem;
}

.timer-value {
    font-size: 1.5rem;
    font-weight: 700;
    font-family: 'SF Mono', 'Monaco', 'Inconsolata', 'Roboto Mono', monospace;
    color: var(--color-gray-700);
}

.timer-value.timer-active {
    color: var(--color-success);
    animation: pulse 2s infinite;
}

@keyframes pulse {

    0%,
    100% {
        opacity: 1;
    }

    50% {
        opacity: 0.7;
    }
}

.time-tracking-info {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}

.total-time-label {
    font-size: 0.75rem;
    color: var(--color-gray-500);
}

.total-time-value {
    font-size: 1rem;
    font-weight: 600;
    color: var(--color-gray-900);
}

.time-tracking-actions {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.time-tracking-status {
    margin-top: 0.75rem;
    font-size: 0.75rem;
    padding: 0.5rem 0.75rem;
    border-radius: var(--border-radius-sm);
}

.time-tracking-status-success {
    background-color: #dcfce7;
    color: #166534;
}

.time-tracking-status-error {
    background-color: #fee2e2;
    color: #991b1b;
}

/* Time History Dialog */
.time-history-summary {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem;
    background-color: var(--color-gray-50);
    border-radius: var(--border-radius-sm);
    margin-bottom: 1rem;
}

.time-history-total-label {
    font-size: 0.875rem;
    color: var(--color-gray-600);
}

.time-history-total-value {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--color-black);
}

.time-history-list {
    max-height: 400px;
    overflow-y: auto;
}

.time-history-loading,
.time-history-empty,
.time-history-error {
    padding: 2rem;
    text-align: center;
    color: var(--color-gray-500);
}

.time-history-error {
    color: var(--color-error);
}

.time-history-item {
    padding: 1rem;
    border-bottom: 1px solid var(--color-gray-100);
}

.time-history-item:last-child {
    border-bottom: none;
}

.time-history-item-active {
    background-color: #dcfce7;
    border-radius: var(--border-radius-sm);
    margin-bottom: 0.5rem;
}

.time-history-item-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.5rem;
}

.time-history-user {
    font-weight: 600;
    font-size: 0.875rem;
    color: var(--color-gray-900);
}

.time-history-duration {
    font-weight: 600;
    font-size: 0.875rem;
    color: var(--color-black);
    background-color: var(--color-gray-100);
    padding: 0.25rem 0.5rem;
    border-radius: 4px;
}

.time-history-item-active .time-history-duration {
    background-color: var(--color-white);
}

.time-history-item-times {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}

.time-history-start,
.time-history-end {
    font-size: 0.75rem;
    color: var(--color-gray-500);
}

.time-history-running {
    color: var(--color-success);
    font-weight: 500;
}

@media (max-width: 768px) {
    .time-tracking-content {
        flex-direction: column;
        align-items: flex-start;
    }

    .timer-display {
        width: 100%;
        justify-content: center;
    }

    .time-tracking-info {
        width: 100%;
        flex-direction: row;
        justify-content: space-between;
        align-items: center;
    }

    .time-tracking-actions {
        width: 100%;
        justify-content: center;
    }
}

/* Task Box Styles */

/* Task Box Button on Login Page */
.taskbox-login-btn-container {
    margin-top: 1.5rem;
    text-align: center;
}

.btn-taskbox {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem 1.5rem;
    background-color: var(--color-white);
    border: 1px solid var(--color-gray-300);
    border-radius: var(--border-radius);
    color: var(--color-gray-700);
    font-weight: 500;
    transition: all 0.2s ease;
}

.btn-taskbox:hover {
    background-color: var(--color-gray-50);
    border-color: var(--color-gray-400);
    color: var(--color-black);
}

.btn-taskbox i {
    font-size: 1.125rem;
}

/* Task Box Section on Dashboard */
.taskbox-section {
    margin-bottom: 2rem;
}

.taskbox-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

.taskbox-count {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 1.5rem;
    height: 1.5rem;
    padding: 0 0.375rem;
    background-color: var(--color-error);
    color: var(--color-white);
    border-radius: 9999px;
    font-size: 0.75rem;
    font-weight: 600;
}

/* Task Box Dialog Description */
.dialog-description {
    color: var(--color-gray-600);
    margin-bottom: 1.5rem;
    font-size: 0.875rem;
}

/* Form Success Message */
.form-success {
    background-color: #dcfce7;
    border: 1px solid var(--color-success);
    color: #166534;
    padding: 0.75rem 1rem;
    border-radius: var(--border-radius-sm);
    font-size: 0.875rem;
    margin-bottom: 1rem;
}

/* Task Box Entries List */
.taskbox-entries-list {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    max-height: 60vh;
    overflow-y: auto;
}

.taskbox-entry-card {
    background-color: var(--color-white);
    border: 1px solid var(--color-gray-200);
    border-radius: var(--border-radius);
    padding: 1rem;
    transition: all 0.2s ease;
}

.taskbox-entry-card:hover {
    border-color: var(--color-gray-300);
    box-shadow: var(--shadow-sm);
}

.taskbox-entry-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 0.5rem;
}

.taskbox-entry-name {
    font-size: 1rem;
    font-weight: 600;
    color: var(--color-gray-900);
    margin: 0;
}

.taskbox-entry-date {
    font-size: 0.75rem;
    color: var(--color-gray-500);
    white-space: nowrap;
}

.taskbox-entry-description {
    font-size: 0.875rem;
    color: var(--color-gray-600);
    margin-bottom: 0.75rem;
    line-height: 1.5;
}

.taskbox-entry-contact {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.875rem;
    color: var(--color-gray-600);
    margin-bottom: 1rem;
}

.taskbox-entry-contact i {
    color: var(--color-gray-400);
}

.taskbox-entry-contact a {
    color: var(--color-gray-700);
}

.taskbox-entry-contact a:hover {
    color: var(--color-black);
    text-decoration: underline;
}

.taskbox-entry-actions {
    display: flex;
    justify-content: flex-end;
}

/* Project Selection Dialog */
.project-select-list {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    margin-bottom: 1rem;
}

.project-select-item {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.75rem 1rem;
    background-color: var(--color-white);
    border: 1px solid var(--color-gray-200);
    border-radius: var(--border-radius-sm);
    cursor: pointer;
    transition: all 0.15s ease;
}

.project-select-item:hover {
    background-color: var(--color-gray-50);
    border-color: var(--color-gray-300);
}

.project-select-item.loading {
    opacity: 0.6;
    pointer-events: none;
}

.project-select-color {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    flex-shrink: 0;
}

.project-select-info {
    display: flex;
    flex-direction: column;
    gap: 0.125rem;
}

.project-select-name {
    font-weight: 500;
    color: var(--color-gray-900);
}

.project-select-description {
    font-size: 0.75rem;
    color: var(--color-gray-500);
}

/* Large Dialog */
.dialog-large {
    max-width: 600px;
    width: 90%;
}

/* Responsive Task Box Styles */
@media (max-width: 768px) {
    .taskbox-entry-header {
        flex-direction: column;
        gap: 0.25rem;
    }

    .taskbox-entry-date {
        order: -1;
    }

    .dialog-large {
        max-width: 95%;
        margin: 1rem;
    }
}

/* ==================== */
/* Mobile Menu Styles   */
/* ==================== */

/* Hamburger Toggle Button */
.mobile-menu-toggle {
    display: none;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    width: 44px;
    height: 44px;
    padding: 0;
    margin-left: 0.75rem;
    background: transparent;
    border: none;
    cursor: pointer;
    border-radius: var(--border-radius-sm);
    transition: background-color 0.2s ease;
}

.mobile-menu-toggle:hover {
    background-color: var(--color-gray-100);
}

.mobile-menu-toggle:active {
    background-color: var(--color-gray-200);
}

.hamburger-line {
    display: block;
    width: 20px;
    height: 2px;
    background-color: var(--color-gray-700);
    border-radius: 2px;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.hamburger-line:nth-child(1) {
    transform: translateY(-6px);
}

.hamburger-line:nth-child(3) {
    transform: translateY(6px);
}

/* Hamburger Animation to X */
.mobile-menu-toggle.active .hamburger-line:nth-child(1) {
    transform: translateY(0) rotate(45deg);
}

.mobile-menu-toggle.active .hamburger-line:nth-child(2) {
    opacity: 0;
    transform: scaleX(0);
}

.mobile-menu-toggle.active .hamburger-line:nth-child(3) {
    transform: translateY(0) rotate(-45deg);
}

/* Mobile Menu Overlay */
.mobile-menu-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
    z-index: 998;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
}

.mobile-menu-overlay.active {
    opacity: 1;
    visibility: visible;
}

/* Mobile Menu Panel */
.mobile-menu {
    display: none;
    position: fixed;
    top: 0;
    right: 0;
    width: 280px;
    max-width: 85vw;
    height: 100vh;
    background-color: var(--color-white);
    box-shadow: -4px 0 24px rgba(0, 0, 0, 0.12);
    z-index: 999;
    transform: translateX(100%);
    transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    overflow-y: auto;
}

.mobile-menu.active {
    transform: translateX(0);
}

/* Mobile Menu Header */
.mobile-menu-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 1.25rem;
    border-bottom: 1px solid var(--color-gray-100);
}

.mobile-menu-title {
    font-weight: 600;
    font-size: 1rem;
    color: var(--color-gray-900);
}

.mobile-menu-close {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    background: transparent;
    border: none;
    cursor: pointer;
    border-radius: var(--border-radius-sm);
    color: var(--color-gray-500);
    transition: all 0.2s ease;
}

.mobile-menu-close:hover {
    background-color: var(--color-gray-100);
    color: var(--color-gray-700);
}

.mobile-menu-close i {
    font-size: 1.125rem;
}

/* Mobile Menu Navigation */
.mobile-menu-nav {
    display: flex;
    flex-direction: column;
    padding: 0.75rem;
}

.mobile-menu-link {
    display: flex;
    align-items: center;
    gap: 0.875rem;
    padding: 0.875rem 1rem;
    color: var(--color-gray-700);
    text-decoration: none;
    font-weight: 500;
    font-size: 0.9375rem;
    border-radius: var(--border-radius-sm);
    transition: all 0.2s ease;
}

.mobile-menu-link:hover {
    background-color: var(--color-gray-50);
    color: var(--color-black);
}

.mobile-menu-link i {
    font-size: 1.125rem;
    width: 24px;
    text-align: center;
    color: var(--color-gray-500);
    transition: color 0.2s ease;
}

.mobile-menu-link:hover i {
    color: var(--color-gray-700);
}

/* Mobile Menu Active State */
.mobile-menu-link.active {
    background-color: var(--color-black);
    color: var(--color-white);
}

.mobile-menu-link.active i {
    color: var(--color-white);
}

.mobile-menu-link.active:hover {
    background-color: var(--color-gray-800);
    color: var(--color-white);
}

/* Mobile Menu Divider */
.mobile-menu-divider {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.75rem 1rem;
    margin: 0.25rem 0;
}

.mobile-menu-divider::before,
.mobile-menu-divider::after {
    content: '';
    flex: 1;
    height: 1px;
    background-color: var(--color-gray-200);
}

.mobile-menu-divider span {
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--color-gray-400);
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

/* Mobile Menu Button (for AI Assist) */
.mobile-menu-button {
    display: flex;
    align-items: center;
    gap: 0.875rem;
    padding: 0.875rem 1rem;
    color: var(--color-gray-700);
    font-weight: 500;
    font-size: 0.9375rem;
    border-radius: var(--border-radius-sm);
    transition: all 0.2s ease;
    width: 100%;
    background: none;
    border: none;
    cursor: pointer;
    text-align: left;
    font-family: inherit;
}

.mobile-menu-button:hover {
    background-color: var(--color-gray-50);
    color: var(--color-black);
}

.mobile-menu-button i {
    font-size: 1.125rem;
    width: 24px;
    text-align: center;
    color: var(--color-gray-500);
    transition: color 0.2s ease;
}

.mobile-menu-button:hover i {
    color: var(--color-gray-700);
}

/* ================================ */
/* Responsive Breakpoints           */
/* ================================ */

/* Tablet (iPad) - 768px to 1024px */
@media (min-width: 768px) and (max-width: 1024px) {
    .mobile-menu-toggle {
        display: flex;
    }

    .mobile-menu,
    .mobile-menu-overlay {
        display: block;
    }

    .navbar-nav {
        display: none;
    }

    .navbar-divider {
        display: none;
    }

    .navbar-container {
        padding: 0 1.5rem;
    }

    .navbar-right {
        width: auto;
        justify-content: flex-end;
    }

    /* Show profile name on tablet */
    .profile-name {
        display: inline;
    }
}

/* Mobile (iPhone) - up to 767px */
@media (max-width: 767px) {
    .mobile-menu-toggle {
        display: flex;
    }

    .mobile-menu,
    .mobile-menu-overlay {
        display: block;
    }

    .navbar-nav {
        display: none;
    }

    .navbar-divider {
        display: none;
    }

    .navbar-container {
        padding: 0 1rem;
        flex-wrap: nowrap;
    }

    .navbar-right {
        width: auto;
        justify-content: flex-end;
        order: 0;
    }

    /* Hide profile name on mobile */
    .profile-name {
        display: none;
    }

    .profile-trigger {
        padding-right: 0.25rem;
    }

    .profile-trigger i.fa-chevron-down {
        display: none;
    }

    /* Make mobile menu full width on small phones */
    .mobile-menu {
        width: 100%;
        max-width: 100%;
    }
}

/* Real-time Updates Styles */
.realtime-notification {
    position: fixed;
    bottom: 1.5rem;
    right: 1.5rem;
    background-color: var(--color-black);
    color: var(--color-white);
    padding: 0.875rem 1.25rem;
    border-radius: var(--border-radius-sm);
    box-shadow: var(--shadow-lg);
    display: flex;
    align-items: center;
    gap: 0.75rem;
    z-index: 9999;
    transform: translateY(100px);
    opacity: 0;
    transition: all 0.3s ease;
    max-width: 400px;
}

.realtime-notification.show {
    transform: translateY(0);
    opacity: 1;
}

.realtime-notification-info {
    background-color: var(--color-black);
}

.realtime-notification-warning {
    background-color: var(--color-warning);
    color: var(--color-black);
}

.realtime-notification-icon {
    width: 8px;
    height: 8px;
    background-color: var(--color-success);
    border-radius: 50%;
    animation: pulse 2s infinite;
}

.realtime-notification-message {
    font-size: 0.875rem;
    font-weight: 500;
}

@keyframes pulse {
    0% {
        box-shadow: 0 0 0 0 rgba(34, 197, 94, 0.4);
    }

    70% {
        box-shadow: 0 0 0 8px rgba(34, 197, 94, 0);
    }

    100% {
        box-shadow: 0 0 0 0 rgba(34, 197, 94, 0);
    }
}

/* Highlight animation for updated elements */
.realtime-highlight {
    animation: highlight-flash 2s ease;
}

@keyframes highlight-flash {
    0% {
        background-color: rgba(34, 197, 94, 0.2);
    }

    100% {
        background-color: transparent;
    }
}

/* Fade out animation for deleted elements */
.fade-out {
    animation: fade-out 0.3s ease forwards;
}

@keyframes fade-out {
    from {
        opacity: 1;
        transform: scale(1);
    }

    to {
        opacity: 0;
        transform: scale(0.95);
    }
}

/* Connection status indicator */
#realtimeConnectionStatus {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    margin-left: 0.5rem;
}

#realtimeConnectionStatus.connected {
    background-color: var(--color-success);
}

#realtimeConnectionStatus.disconnected {
    background-color: var(--color-gray-400);
}

/* =====================================================
   PROJECT TABS
   ===================================================== */
.project-tabs {
    display: flex;
    gap: 0.5rem;
    margin-bottom: 1.5rem;
    border-bottom: 1px solid var(--color-gray-200);
    padding-bottom: 0;
}

.tab-btn {
    background: none;
    border: none;
    padding: 0.75rem 1.25rem;
    font-size: 0.9375rem;
    font-weight: 500;
    color: var(--color-gray-500);
    cursor: pointer;
    border-bottom: 2px solid transparent;
    margin-bottom: -1px;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.tab-btn:hover {
    color: var(--color-gray-700);
}

.tab-btn.active {
    color: var(--color-black);
    border-bottom-color: var(--color-black);
}

.tab-badge {
    background: var(--color-black);
    color: var(--color-white);
    font-size: 0.75rem;
    padding: 0.125rem 0.5rem;
    border-radius: 9999px;
    font-weight: 600;
}

.tab-content {
    min-height: 400px;
}

/* =====================================================
   CHAT CONTAINER
   ===================================================== */
.chat-container {
    display: flex;
    gap: 1rem;
    height: calc(100vh - var(--navbar-height) - 300px);
    min-height: 500px;
    max-height: 700px;
    background: var(--color-white);
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
    overflow: hidden;
}

/* Simplified chat container (no threads) */
.chat-container-simple {
    gap: 0;
}

.chat-container-simple .chat-main {
    width: 100%;
}

/* Chat Sidebar */
.chat-sidebar {
    width: 280px;
    background: var(--color-gray-50);
    border-right: 1px solid var(--color-gray-200);
    display: flex;
    flex-direction: column;
    transition: width 0.3s ease;
    position: relative;
}

.chat-sidebar.collapsed {
    width: 0;
    overflow: hidden;
}

.chat-sidebar-header {
    padding: 1rem;
    border-bottom: 1px solid var(--color-gray-200);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.chat-sidebar-header h3 {
    font-size: 0.9375rem;
    font-weight: 600;
    margin: 0;
}

.chat-sidebar-toggle {
    position: absolute;
    right: -12px;
    top: 50%;
    transform: translateY(-50%);
    width: 24px;
    height: 48px;
    background: var(--color-white);
    border: 1px solid var(--color-gray-200);
    border-radius: 0 8px 8px 0;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10;
}

.chat-sidebar.collapsed .chat-sidebar-toggle {
    right: -24px;
}

.chat-sidebar.collapsed .toggle-icon {
    transform: rotate(180deg);
}

.thread-list {
    flex: 1;
    overflow-y: auto;
    padding: 0.5rem;
}

.thread-item {
    padding: 0.75rem;
    border-radius: var(--border-radius-sm);
    cursor: pointer;
    transition: background-color 0.15s ease;
    margin-bottom: 0.25rem;
}

.thread-item:hover {
    background: var(--color-gray-100);
}

.thread-subject {
    font-weight: 500;
    font-size: 0.875rem;
    margin-bottom: 0.25rem;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.thread-meta {
    font-size: 0.75rem;
    color: var(--color-gray-500);
    display: flex;
    gap: 0.75rem;
}

.empty-threads {
    padding: 2rem 1rem;
    text-align: center;
    color: var(--color-gray-500);
    font-size: 0.875rem;
}

/* Main Chat Area */
.chat-main {
    flex: 1;
    display: flex;
    flex-direction: column;
    min-width: 0;
}

.chat-header {
    padding: 1rem 1.25rem;
    border-bottom: 1px solid var(--color-gray-200);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.chat-header-info h3 {
    font-size: 1rem;
    font-weight: 600;
    margin: 0 0 0.25rem 0;
}

.chat-stats {
    font-size: 0.8125rem;
    color: var(--color-gray-500);
}

/* Messages Area */
.chat-messages {
    flex: 1;
    overflow-y: auto;
    padding: 1rem;
    display: flex;
    flex-direction: column;
}

.chat-loading {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    padding: 2rem;
    color: var(--color-gray-500);
}

.chat-loading .spinner {
    width: 24px;
    height: 24px;
    border: 2px solid var(--color-gray-200);
    border-top-color: var(--color-black);
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

.chat-empty {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 3rem;
    text-align: center;
    color: var(--color-gray-500);
}

.chat-empty .empty-icon {
    font-size: 3rem;
    margin-bottom: 1rem;
}

.chat-empty h3 {
    margin: 0 0 0.5rem 0;
    color: var(--color-gray-700);
}

.messages-list {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.load-more-container {
    text-align: center;
    padding: 1rem;
}

/* Chat Message */
.chat-message {
    display: flex;
    gap: 0.75rem;
    padding: 0.75rem;
    border-radius: var(--border-radius-sm);
    transition: background-color 0.15s ease;
}

.chat-message:hover {
    background: var(--color-gray-50);
}

.chat-message.own-message {
    background: var(--color-gray-50);
}

.message-avatar {
    width: 36px;
    height: 36px;
    background: var(--color-black);
    color: var(--color-white);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    font-size: 0.875rem;
    flex-shrink: 0;
}

.message-body {
    flex: 1;
    min-width: 0;
}

.message-header {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 0.25rem;
    flex-wrap: wrap;
}

.message-author {
    font-weight: 600;
    font-size: 0.875rem;
}

.message-time {
    font-size: 0.75rem;
    color: var(--color-gray-500);
}

.edited-badge {
    font-size: 0.75rem;
    color: var(--color-gray-400);
    font-style: italic;
}

.message-content {
    font-size: 0.9375rem;
    line-height: 1.5;
    word-wrap: break-word;
}

.message-content .mention {
    background: var(--color-gray-100);
    padding: 0.125rem 0.375rem;
    border-radius: 4px;
    font-weight: 500;
    color: var(--color-black);
}

.message-content .task-ref {
    background: var(--color-gray-100);
    padding: 0.125rem 0.375rem;
    border-radius: 4px;
    color: var(--color-black);
    text-decoration: none;
}

.message-content .task-ref:hover {
    background: var(--color-gray-200);
}

.message-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.375rem;
    margin-top: 0.5rem;
}

.mention-badge {
    background: var(--color-gray-100);
    padding: 0.25rem 0.5rem;
    border-radius: 4px;
    font-size: 0.75rem;
    font-weight: 500;
}

.task-link-badge {
    padding: 0.25rem 0.5rem;
    border-radius: 4px;
    font-size: 0.75rem;
    text-decoration: none;
    background: var(--color-gray-100);
    border-left: 3px solid var(--color-gray-400);
}

.task-link-badge:hover {
    background: var(--color-gray-200);
}

.message-actions {
    display: none;
    gap: 0.25rem;
    margin-top: 0.5rem;
}

.chat-message:hover .message-actions {
    display: flex;
}

.message-actions .btn-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--color-gray-400);
    background: none;
    border: none;
    cursor: pointer;
    padding: 0.375rem;
    border-radius: 6px;
    transition: all 0.15s ease;
}

.message-actions .btn-icon:hover {
    background: var(--color-gray-100);
    color: var(--color-gray-700);
}

.message-actions .btn-icon svg {
    display: block;
}

.message-actions .btn-delete:hover {
    background: #fee2e2;
    color: #dc2626;
}

.message-actions .btn-edit:hover {
    background: #dbeafe;
    color: #2563eb;
}

.message-actions .btn-reply:hover {
    background: #f0fdf4;
    color: #16a34a;
}

/* Message Priority Styles */
.message-priority-badge {
    font-size: 0.6875rem;
    padding: 0.125rem 0.5rem;
    border-radius: 9999px;
    font-weight: 600;
    text-transform: uppercase;
}

.message-priority-badge.priority-low {
    background: #dbeafe;
    color: #1e40af;
}

.message-priority-badge.priority-medium {
    background: #fef3c7;
    color: #92400e;
}

.message-priority-badge.priority-high {
    background: #fee2e2;
    color: #991b1b;
}

.message-priority-badge.priority-urgent {
    background: #ef4444;
    color: white;
}

.chat-message.priority-urgent {
    border-left: 3px solid #ef4444;
}

.chat-message.priority-high {
    border-left: 3px solid #f59e0b;
}

/* Reply Tree Styles */
.message-replies {
    position: relative;
}

.message-replies.depth-1 {
    margin-left: 2.5rem;
    padding-left: 1rem;
    border-left: 2px solid var(--color-gray-200);
}

.message-replies.depth-2 {
    margin-left: 2rem;
    padding-left: 1rem;
    border-left: 2px solid var(--color-gray-300);
}

.message-replies.depth-3 {
    margin-left: 1.5rem;
    padding-left: 1rem;
    border-left: 2px dashed var(--color-gray-300);
}

.chat-message.reply-message {
    background: var(--color-gray-50);
    border-radius: var(--border-radius-sm);
    margin: 0.5rem 0;
    padding: 0.75rem;
}

.chat-message.reply-message .message-avatar {
    width: 28px;
    height: 28px;
    font-size: 0.75rem;
}

.chat-message.reply-message .message-body {
    font-size: 0.9375rem;
}

.message-connector {
    display: none;
}

.reply-message .message-connector {
    display: block;
    position: absolute;
    left: -1rem;
    top: 1.25rem;
    width: 0.75rem;
    height: 2px;
    background: var(--color-gray-300);
}

/* Reply to indicator (in message) */
.reply-to-indicator {
    font-size: 0.75rem;
    color: var(--color-gray-500);
    margin-bottom: 0.25rem;
    display: flex;
    align-items: center;
    gap: 0.25rem;
}

.reply-to-indicator .reply-arrow {
    color: var(--color-gray-400);
}

.reply-to-indicator strong {
    color: var(--color-gray-700);
    font-weight: 600;
}

/* Reply count badge */
.reply-count-badge {
    font-size: 0.6875rem;
    color: var(--color-gray-500);
    background: var(--color-gray-100);
    padding: 0.125rem 0.375rem;
    border-radius: 10px;
    margin-left: 0.5rem;
}

/* Reply button styling */
.btn-reply {
    color: var(--color-gray-500);
}

.btn-reply:hover {
    color: var(--color-black);
}

/* Highlight message being replied to */
.chat-message.replying-to {
    background: #fef3c7;
    border-color: #f59e0b;
    box-shadow: 0 0 0 2px rgba(245, 158, 11, 0.2);
}

.chat-message.replying-to::before {
    content: '';
    position: absolute;
    left: -4px;
    top: 0;
    bottom: 0;
    width: 4px;
    background: #f59e0b;
    border-radius: 2px;
}

/* Reply indicator in composer */
.reply-indicator {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.5rem 0.75rem;
    margin-bottom: 0.5rem;
    background: #fef3c7;
    border-radius: var(--border-radius-sm);
    border-left: 3px solid #f59e0b;
}

.reply-indicator-content {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.8125rem;
    overflow: hidden;
}

.reply-indicator-label {
    color: var(--color-gray-500);
    flex-shrink: 0;
}

.reply-indicator-author {
    font-weight: 600;
    color: var(--color-gray-700);
    flex-shrink: 0;
}

.reply-indicator-preview {
    color: var(--color-gray-500);
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.reply-indicator-cancel {
    background: none;
    border: none;
    font-size: 1.25rem;
    color: var(--color-gray-500);
    cursor: pointer;
    padding: 0.25rem;
    line-height: 1;
    border-radius: 4px;
    transition: all 0.15s ease;
}

.reply-indicator-cancel:hover {
    background: rgba(0, 0, 0, 0.05);
    color: var(--color-gray-700);
}

/* Chat Composer */
.chat-composer {
    padding: 1rem;
    border-top: 1px solid var(--color-gray-200);
    background: var(--color-gray-50);
}

.composer-container {
    display: flex;
    gap: 0.75rem;
    align-items: flex-end;
}

.composer-input-wrapper {
    flex: 1;
    position: relative;
}

.composer-textarea {
    width: 100%;
    padding: 0.75rem 1rem;
    border: 1px solid var(--color-gray-200);
    border-radius: var(--border-radius-sm);
    font-size: 0.9375rem;
    resize: none;
    min-height: 44px;
    max-height: 150px;
    font-family: inherit;
    transition: border-color 0.15s ease;
}

.composer-textarea:focus {
    outline: none;
    border-color: var(--color-black);
}

.composer-actions {
    display: flex;
    gap: 0.5rem;
    align-items: center;
}

.priority-select {
    padding: 0.5rem 0.75rem;
    border: 1px solid var(--color-gray-200);
    border-radius: var(--border-radius-sm);
    font-size: 0.8125rem;
    background: var(--color-white);
    cursor: pointer;
}

/* Autocomplete Dropdown */
.autocomplete-dropdown {
    position: absolute;
    bottom: 100%;
    left: 0;
    right: 0;
    background: var(--color-white);
    border: 1px solid var(--color-gray-200);
    border-radius: var(--border-radius-sm);
    box-shadow: var(--shadow-md);
    max-height: 200px;
    overflow-y: auto;
    margin-bottom: 0.5rem;
    z-index: 100;
}

.autocomplete-item {
    padding: 0.625rem 0.875rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    transition: background-color 0.1s ease;
}

.autocomplete-item:hover,
.autocomplete-item.selected {
    background: var(--color-gray-100);
}

.autocomplete-item .color-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    flex-shrink: 0;
}

.autocomplete-text {
    font-weight: 500;
    font-size: 0.875rem;
}

.autocomplete-subtext {
    font-size: 0.75rem;
    color: var(--color-gray-500);
    margin-left: auto;
}

/* Thread View */
.thread-view {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: var(--color-white);
    display: flex;
    flex-direction: column;
    z-index: 50;
}

.thread-view-header {
    padding: 1rem;
    border-bottom: 1px solid var(--color-gray-200);
    display: flex;
    align-items: center;
    gap: 1rem;
}

.thread-view-header h3 {
    font-size: 1rem;
    font-weight: 600;
    margin: 0;
}

.thread-messages {
    flex: 1;
    overflow-y: auto;
    padding: 1rem;
}

.thread-root-message {
    padding-bottom: 1rem;
    border-bottom: 1px solid var(--color-gray-200);
    margin-bottom: 1rem;
}

.thread-replies-header {
    font-size: 0.8125rem;
    color: var(--color-gray-500);
    font-weight: 500;
    margin-bottom: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.thread-composer {
    padding: 1rem;
    border-top: 1px solid var(--color-gray-200);
    background: var(--color-gray-50);
}

/* Chat responsive styles */
@media (max-width: 768px) {
    .chat-container {
        height: calc(100vh - var(--navbar-height) - 200px);
    }

    .chat-sidebar {
        position: absolute;
        left: 0;
        top: 0;
        bottom: 0;
        z-index: 40;
        width: 280px;
        transform: translateX(-100%);
    }

    .chat-sidebar:not(.collapsed) {
        transform: translateX(0);
    }

    .chat-sidebar-toggle {
        display: flex;
    }

    .composer-actions {
        flex-direction: column;
        align-items: stretch;
    }

    .composer-options {
        order: 1;
    }
}

/* =====================================================
   MODAL BASE STYLES
   ===================================================== */
.modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1rem;
}

.modal-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
}

/* Standalone modal overlay (used as modal container with id) */
.modal-overlay[id] {
    display: none;
    position: fixed;
    z-index: 1000;
    align-items: center;
    justify-content: center;
    padding: 1rem;
}

.modal-overlay[id].active {
    display: flex;
}

.modal-content {
    position: relative;
    background: var(--color-white);
    border-radius: var(--border-radius);
    box-shadow: var(--shadow-lg);
    width: 100%;
    max-width: 560px;
    max-height: 90vh;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    animation: modalFadeIn 0.2s ease;
}

@keyframes modalFadeIn {
    from {
        opacity: 0;
        transform: scale(0.95) translateY(-10px);
    }

    to {
        opacity: 1;
        transform: scale(1) translateY(0);
    }
}

.modal-header {
    padding: 1.25rem 1.5rem;
    border-bottom: 1px solid var(--color-gray-200);
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.modal-header h2 {
    font-size: 1.125rem;
    font-weight: 600;
    margin: 0;
}

.modal-close {
    width: 32px;
    height: 32px;
    border: none;
    background: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    color: var(--color-gray-500);
    border-radius: 6px;
    transition: all 0.15s ease;
}

.modal-close:hover {
    background: var(--color-gray-100);
    color: var(--color-black);
}

.modal-body {
    padding: 1.5rem;
    overflow-y: auto;
    flex: 1;
}

.modal-footer {
    padding: 1rem 1.5rem;
    border-top: 1px solid var(--color-gray-200);
    display: flex;
    justify-content: flex-end;
    gap: 0.75rem;
    background: var(--color-gray-50);
}

/* Modal responsive */
@media (max-width: 600px) {
    .modal {
        padding: 0;
        align-items: flex-end;
    }

    .modal-content {
        max-width: 100%;
        max-height: 85vh;
        border-radius: var(--border-radius) var(--border-radius) 0 0;
    }
}

/* Modal styles for new thread */
#newThreadModal .modal-content {
    max-width: 500px;
}

#newThreadModal .form-group {
    margin-bottom: 1rem;
}

#newThreadModal .form-group label {
    display: block;
    margin-bottom: 0.375rem;
    font-weight: 500;
    font-size: 0.875rem;
}

#newThreadModal .form-input,
#newThreadModal .form-textarea,
#newThreadModal .form-select {
    width: 100%;
    padding: 0.625rem 0.875rem;
    border: 1px solid var(--color-gray-200);
    border-radius: var(--border-radius-sm);
    font-size: 0.9375rem;
    font-family: inherit;
}

#newThreadModal .form-textarea {
    min-height: 100px;
    resize: vertical;
}

#newThreadModal .form-input:focus,
#newThreadModal .form-textarea:focus,
#newThreadModal .form-select:focus {
    outline: none;
    border-color: var(--color-black);
}

/* ==========================================
   Notes Feature Styles
   ========================================== */

.notes-container {
    display: flex;
    height: calc(100vh - var(--navbar-height));
    max-width: 100%;
    margin: 0;
    padding: 0;
    overflow: visible;
    position: relative;
}

/* Notes Sidebar */
.notes-sidebar {
    width: 320px;
    min-width: 320px;
    background: var(--color-white);
    border-right: 1px solid var(--color-gray-200);
    display: flex;
    flex-direction: column;
    height: 100%;
}

.notes-sidebar-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.25rem;
    border-bottom: 1px solid var(--color-gray-100);
}

.notes-sidebar-header h2 {
    font-size: 1.25rem;
    font-weight: 600;
    margin: 0;
}

.notes-search {
    padding: 0.75rem 1rem;
    border-bottom: 1px solid var(--color-gray-100);
}

.notes-search .form-input {
    width: 100%;
    padding: 0.5rem 0.75rem;
    border: 1px solid var(--color-gray-200);
    border-radius: var(--border-radius-sm);
    font-size: 0.875rem;
}

.notes-list {
    flex: 1;
    overflow-y: auto;
    padding: 0.75rem;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.notes-loading,
.notes-empty {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 2rem;
    color: var(--color-gray-500);
    text-align: center;
}

.notes-empty i {
    font-size: 2.5rem;
    margin-bottom: 1rem;
    color: var(--color-gray-300);
}

.notes-empty p {
    margin: 0.25rem 0;
}

.spinner {
    width: 24px;
    height: 24px;
    border: 2px solid var(--color-gray-200);
    border-top-color: var(--color-black);
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

/* Note List Item - Floating Card Style */
.note-item {
    padding: 0.875rem 1rem;
    background-color: var(--color-white);
    border-radius: var(--border-radius-sm);
    border: 1px solid transparent;
    box-shadow: var(--shadow-sm);
    cursor: pointer;
    transition: all 0.15s ease;
}

.note-item:hover {
    border-color: var(--color-gray-200);
    box-shadow: var(--shadow-md);
}

.note-item.active {
    background-color: var(--color-gray-900);
    color: var(--color-white);
    border-color: var(--color-gray-900);
    box-shadow: var(--shadow-md);
}

.note-item.active .note-item-preview,
.note-item.active .note-item-date,
.note-item.active .note-item-coauthors {
    color: var(--color-gray-300);
}

.note-item-header {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 0.25rem;
}

.note-item-title {
    font-size: 0.9375rem;
    font-weight: 500;
    margin: 0;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    flex: 1;
}

.note-shared-badge {
    font-size: 0.75rem;
    color: var(--color-gray-500);
}

.note-item.active .note-shared-badge {
    color: var(--color-gray-400);
}

.note-item-preview {
    font-size: 0.8125rem;
    color: var(--color-gray-500);
    margin: 0 0 0.5rem 0;
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.note-item-meta {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-size: 0.75rem;
    color: var(--color-gray-400);
}

.note-item-coauthors {
    display: flex;
    align-items: center;
    gap: 0.25rem;
}

/* Notes Editor Area */
.notes-editor-area {
    flex: 1;
    display: flex;
    flex-direction: column;
    background: var(--color-gray-50);
    min-width: 0;
}

.notes-editor-empty {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    color: var(--color-gray-500);
    text-align: center;
    padding: 2rem;
}

.empty-state-icon {
    width: 80px;
    height: 80px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--color-gray-100);
    border-radius: 50%;
    margin-bottom: 1.5rem;
}

.empty-state-icon i {
    font-size: 2.5rem;
    color: var(--color-gray-400);
}

.notes-editor-empty h3 {
    margin: 0 0 0.5rem 0;
    font-size: 1.25rem;
    font-weight: 600;
    color: var(--color-gray-700);
}

.notes-editor-container {
    flex: 1;
    display: flex;
    flex-direction: column;
    min-height: 0;
}

/* Note Header */
.note-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    padding: 1rem 1.5rem;
    background: var(--color-white);
    border-bottom: 1px solid var(--color-gray-200);
}

.note-title-container {
    flex: 1;
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.note-title-input {
    flex: 1;
    font-size: 1.25rem;
    font-weight: 600;
    border: none;
    background: transparent;
    padding: 0.25rem 0;
    outline: none;
}

.note-title-input:focus {
    background: var(--color-gray-50);
    padding: 0.25rem 0.5rem;
    border-radius: var(--border-radius-sm);
}

.note-title-input:disabled {
    color: var(--color-gray-900);
    cursor: default;
}

.note-save-status {
    font-size: 0.75rem;
    color: var(--color-gray-400);
    white-space: nowrap;
}

.note-save-status.status-saving {
    color: var(--color-warning);
}

.note-save-status.status-saved {
    color: var(--color-success);
}

.note-save-status.status-error {
    color: var(--color-error);
}

.note-actions {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.note-owner-badge {
    display: flex;
    align-items: center;
    gap: 0.375rem;
    font-size: 0.8125rem;
    color: var(--color-gray-500);
    background: var(--color-gray-100);
    padding: 0.375rem 0.625rem;
    border-radius: var(--border-radius-sm);
}

.co-author-count {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 18px;
    height: 18px;
    font-size: 0.6875rem;
    font-weight: 600;
    background: var(--color-gray-200);
    border-radius: 9px;
    margin-left: 0.25rem;
}

/* Editor Layout */
.note-editor-layout {
    flex: 1;
    display: grid;
    grid-template-columns: 1fr 1fr;
    min-height: 0;
}

.note-editor-panel,
.note-preview-panel {
    display: flex;
    flex-direction: column;
    min-height: 0;
    overflow: hidden;
}

.note-editor-panel {
    border-right: 1px solid var(--color-gray-200);
}

/* Split view (default) */
.note-editor-layout.split-view {
    grid-template-columns: 1fr 1fr;
}

/* Editor only (preview hidden) */
.note-editor-layout.preview-hidden {
    grid-template-columns: 1fr;
}

.note-editor-layout.preview-hidden .note-preview-panel {
    display: none;
}

.note-editor-layout.preview-hidden .note-editor-panel {
    border-right: none;
}

/* Preview only (editor hidden) */
.note-editor-layout.editor-hidden {
    grid-template-columns: 1fr;
}

.note-editor-layout.editor-hidden .note-editor-panel {
    display: none;
}

.note-editor-layout.editor-hidden .note-preview-panel {
    border-left: none;
}

.panel-header {
    display: flex;
    align-items: center;
    padding: 0.75rem 1rem;
    background: var(--color-white);
    border-bottom: 1px solid var(--color-gray-100);
}

.panel-title {
    font-size: 0.75rem;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--color-gray-500);
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.editor-wrapper {
    flex: 1;
    overflow: hidden;
}

.editor-wrapper .CodeMirror {
    height: 100%;
    font-size: 0.9375rem;
    font-family: 'SF Mono', 'Monaco', 'Inconsolata', 'Fira Mono', 'Droid Sans Mono', monospace;
    line-height: 1.6;
}

.editor-wrapper .CodeMirror-gutters {
    background: var(--color-gray-50);
    border-right: 1px solid var(--color-gray-200);
}

.preview-wrapper {
    flex: 1;
    overflow-y: auto;
    background: var(--color-white);
}

.preview-content {
    padding: 1.5rem;
    font-size: 0.9375rem;
    line-height: 1.7;
}

/* Markdown Preview Styles */
.preview-content h1,
.preview-content h2,
.preview-content h3,
.preview-content h4,
.preview-content h5,
.preview-content h6 {
    margin-top: 1.5em;
    margin-bottom: 0.5em;
    font-weight: 600;
    line-height: 1.3;
}

.preview-content h1 {
    font-size: 1.75rem;
}

.preview-content h2 {
    font-size: 1.5rem;
}

.preview-content h3 {
    font-size: 1.25rem;
}

.preview-content h4 {
    font-size: 1.125rem;
}

.preview-content h5 {
    font-size: 1rem;
}

.preview-content h6 {
    font-size: 0.9375rem;
}

.preview-content p {
    margin: 0 0 1em 0;
}

.preview-content pre {
    background: var(--color-gray-100);
    padding: 1rem;
    border-radius: var(--border-radius-sm);
    overflow-x: auto;
    font-size: 0.875rem;
    margin: 1em 0;
}

.preview-content code {
    background: var(--color-gray-100);
    padding: 0.2em 0.4em;
    border-radius: 3px;
    font-size: 0.875em;
    font-family: 'SF Mono', 'Monaco', 'Inconsolata', 'Fira Mono', 'Droid Sans Mono', monospace;
}

.preview-content pre code {
    background: none;
    padding: 0;
}

.preview-content blockquote {
    border-left: 4px solid var(--color-gray-300);
    margin: 1em 0;
    padding-left: 1rem;
    color: var(--color-gray-600);
}

.preview-content ul,
.preview-content ol {
    margin: 0 0 1em 0;
    padding-left: 1.5rem;
}

.preview-content li {
    margin-bottom: 0.25em;
}

.preview-content a {
    color: var(--color-black);
    text-decoration: underline;
}

.preview-content hr {
    border: none;
    border-top: 1px solid var(--color-gray-200);
    margin: 2em 0;
}

.preview-content table {
    width: 100%;
    border-collapse: collapse;
    margin: 1em 0;
}

.preview-content th,
.preview-content td {
    border: 1px solid var(--color-gray-200);
    padding: 0.5rem 0.75rem;
    text-align: left;
}

.preview-content th {
    background: var(--color-gray-50);
    font-weight: 600;
}

.preview-content img {
    max-width: 100%;
    height: auto;
    border-radius: var(--border-radius-sm);
}

/* Modal Styles for Notes */
.modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 1100;
    display: none;
    align-items: center;
    justify-content: center;
}

.modal.open {
    display: flex;
}

.modal-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
}

.modal-container {
    position: relative;
    background: var(--color-white);
    border-radius: var(--border-radius);
    box-shadow: var(--shadow-lg);
    max-width: 500px;
    width: 90%;
    max-height: 90vh;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.modal-container.modal-sm {
    max-width: 400px;
}

.modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1rem 1.25rem;
    border-bottom: 1px solid var(--color-gray-100);
}

.modal-header h3 {
    margin: 0;
    font-size: 1.125rem;
    font-weight: 600;
}

.modal-close {
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: none;
    border: none;
    border-radius: var(--border-radius-sm);
    cursor: pointer;
    color: var(--color-gray-500);
    transition: all 0.15s ease;
}

.modal-close:hover {
    background: var(--color-gray-100);
    color: var(--color-gray-900);
}

.modal-body {
    padding: 1.25rem;
    overflow-y: auto;
}

.modal-footer {
    display: flex;
    justify-content: flex-end;
    gap: 0.5rem;
    padding: 1rem 1.25rem;
    border-top: 1px solid var(--color-gray-100);
}

/* Co-Authors Modal */
.co-authors-add {
    margin-bottom: 1.5rem;
    padding-bottom: 1.5rem;
    border-bottom: 1px solid var(--color-gray-100);
}

.co-authors-add label,
.co-authors-list label {
    display: block;
    font-size: 0.6875rem;
    font-weight: 600;
    color: var(--color-gray-500);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 0.625rem;
}

.co-author-search {
    position: relative;
}

.co-author-search .form-input {
    width: 100%;
    padding: 0.625rem 0.875rem 0.625rem 2.5rem;
    border: 1px solid transparent;
    border-radius: var(--border-radius-md);
    font-size: 0.875rem;
    font-family: inherit;
    background-color: var(--color-gray-100);
    color: var(--color-gray-900);
    transition: all 0.15s ease;
}

.co-author-search .form-input::placeholder {
    color: var(--color-gray-400);
}

.co-author-search .form-input:hover {
    background-color: var(--color-gray-200);
}

.co-author-search .form-input:focus {
    outline: none;
    background-color: var(--color-white);
    border-color: var(--color-primary);
    box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.1);
}

.co-author-search::before {
    content: "\f002";
    font-family: "Font Awesome 6 Free";
    font-weight: 900;
    position: absolute;
    left: 0.875rem;
    top: 50%;
    transform: translateY(-50%);
    color: var(--color-gray-400);
    font-size: 0.8125rem;
    pointer-events: none;
    z-index: 1;
}

.co-author-search-results {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--color-white);
    border: 1px solid var(--color-gray-200);
    border-radius: var(--border-radius-md);
    box-shadow: var(--shadow-lg);
    max-height: 220px;
    overflow-y: auto;
    z-index: 10;
    margin-top: 0.5rem;
}

.search-result-item {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.75rem 1rem;
    cursor: pointer;
    transition: background-color 0.15s ease;
    border-bottom: 1px solid var(--color-gray-50);
}

.search-result-item:last-child {
    border-bottom: none;
}

.search-result-item:hover {
    background: var(--color-gray-50);
}

.search-result-item::before {
    content: "";
    width: 36px;
    height: 36px;
    background: linear-gradient(135deg, var(--color-primary), #818cf8);
    border-radius: 50%;
    flex-shrink: 0;
}

.search-result-info {
    display: flex;
    flex-direction: column;
    min-width: 0;
}

.search-result-name {
    font-weight: 600;
    font-size: 0.875rem;
    color: var(--color-gray-900);
}

.search-result-email {
    font-size: 0.75rem;
    color: var(--color-gray-500);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.search-no-results {
    padding: 1.5rem 1rem;
    text-align: center;
    color: var(--color-gray-400);
    font-size: 0.8125rem;
}

.co-authors-empty {
    text-align: center;
    padding: 2rem 1rem;
    color: var(--color-gray-400);
    font-size: 0.8125rem;
    background: var(--color-gray-50);
    border-radius: var(--border-radius-md);
    border: 1px dashed var(--color-gray-200);
}

.co-author-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.75rem 1rem;
    background: var(--color-white);
    border: 1px solid var(--color-gray-200);
    border-radius: var(--border-radius-md);
    margin-bottom: 0.5rem;
    transition: all 0.15s ease;
}

.co-author-item:hover {
    border-color: var(--color-gray-300);
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
}

.co-author-item:last-child {
    margin-bottom: 0;
}

.co-author-info {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    min-width: 0;
}

.co-author-avatar {
    width: 36px;
    height: 36px;
    background: linear-gradient(135deg, #f472b6, #ec4899);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-weight: 600;
    font-size: 0.8125rem;
    flex-shrink: 0;
    text-transform: uppercase;
}

.co-author-details {
    display: flex;
    flex-direction: column;
    min-width: 0;
}

.co-author-name {
    font-weight: 600;
    font-size: 0.875rem;
    color: var(--color-gray-900);
}

.co-author-email {
    font-size: 0.75rem;
    color: var(--color-gray-500);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.btn-remove-coauthor {
    width: 28px;
    height: 28px;
    padding: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    background: transparent;
    border: none;
    color: var(--color-gray-400);
    border-radius: var(--border-radius-sm);
    cursor: pointer;
    transition: all 0.15s ease;
    flex-shrink: 0;
}

.btn-remove-coauthor:hover {
    background: var(--color-red-50);
    color: var(--color-red-500);
}

.btn-remove-coauthor i {
    font-size: 0.75rem;
}

/* Dropdown for export */
.dropdown {
    position: relative;
}

.dropdown .dropdown-menu {
    position: absolute;
    top: 100%;
    right: 0;
    min-width: 180px;
    background: var(--color-white);
    border: 1px solid var(--color-gray-200);
    border-radius: var(--border-radius-sm);
    box-shadow: var(--shadow-md);
    z-index: 100;
    display: none;
    margin-top: 0.25rem;
}

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

.dropdown-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.625rem 0.875rem;
    font-size: 0.875rem;
    color: var(--color-gray-700);
    cursor: pointer;
    transition: background-color 0.15s ease;
}

.dropdown-item:hover {
    background: var(--color-gray-50);
}

/* Task Actions Dropdown */
.task-actions-dropdown {
    position: relative;
    display: flex;
    align-items: center;
}

.task-actions-trigger {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    padding: 0;
    background: transparent;
    border: 1px solid var(--color-gray-200);
    border-radius: 50%;
    color: var(--color-gray-600);
    cursor: pointer;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}

.task-actions-trigger:hover {
    background: var(--color-white);
    border-color: var(--color-gray-300);
    color: var(--color-gray-900);
    box-shadow: var(--shadow-sm);
    transform: translateY(-1px);
}

.task-actions-trigger:active {
    transform: translateY(0);
    box-shadow: none;
}

.task-actions-trigger i {
    font-size: 1rem;
}

.task-actions-menu {
    min-width: 180px;
    padding: 0.375rem;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-8px) scale(0.96);
    transform-origin: top right;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}

.task-actions-dropdown.open .task-actions-menu {
    display: block;
    opacity: 1;
    visibility: visible;
    transform: translateY(0) scale(1);
}

.task-actions-menu .dropdown-item {
    border-radius: var(--border-radius-sm);
    font-weight: 500;
    transition: all 0.15s ease;
}

.task-actions-menu .dropdown-item i {
    width: 16px;
    text-align: center;
    opacity: 0.7;
    transition: opacity 0.15s ease;
}

.task-actions-menu .dropdown-item:hover i {
    opacity: 1;
}

.task-actions-menu .dropdown-item.text-danger {
    color: var(--color-error);
}

.task-actions-menu .dropdown-item.text-danger:hover {
    background: #fef2f2;
    color: #dc2626;
}

.task-actions-menu .dropdown-divider {
    height: 1px;
    background: var(--color-gray-100);
    margin: 0.375rem 0;
}

.task-actions-menu .dropdown-form {
    margin: 0;
    padding: 0;
}

.task-actions-menu .dropdown-form button {
    width: 100%;
    border: none;
    background: none;
    text-align: left;
}

/* Dark mode for task actions dropdown */
body.dark-mode .task-actions-trigger {
    border-color: rgba(255, 255, 255, 0.15);
    color: #a3a3a3;
}

body.dark-mode .task-actions-trigger:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: rgba(255, 255, 255, 0.2);
    color: #fafafa;
}

body.dark-mode .task-actions-menu .dropdown-item.text-danger:hover {
    background: rgba(239, 68, 68, 0.15);
    color: #f87171;
}

body.dark-mode .task-actions-menu .dropdown-divider {
    background: rgba(255, 255, 255, 0.1);
}

/* Notifications */
.notification {
    position: fixed;
    bottom: 1.5rem;
    right: 1.5rem;
    padding: 0.875rem 1.25rem;
    background: var(--color-gray-900);
    color: var(--color-white);
    border-radius: var(--border-radius-sm);
    box-shadow: var(--shadow-lg);
    transform: translateY(20px);
    opacity: 0;
    transition: all 0.3s ease;
    z-index: 1200;
    max-width: 400px;
}

.notification.show {
    transform: translateY(0);
    opacity: 1;
}

.notification-success {
    background: var(--color-success);
}

.notification-error {
    background: var(--color-error);
}

.notification-info {
    background: var(--color-gray-800);
}

/* Responsive Notes Layout */
@media (max-width: 1024px) {
    .note-editor-layout {
        grid-template-columns: 1fr;
    }

    .note-preview-panel {
        display: none;
    }
}

@media (max-width: 768px) {
    .notes-container {
        flex-direction: column;
    }

    .notes-sidebar {
        width: 100%;
        min-width: auto;
        max-height: 40vh;
        border-right: none;
        border-bottom: 1px solid var(--color-gray-200);
    }

    .notes-editor-area {
        min-height: 60vh;
    }

    .note-header {
        flex-wrap: wrap;
        gap: 0.75rem;
    }

    .note-title-container {
        width: 100%;
    }

    .note-actions {
        width: 100%;
        justify-content: flex-end;
    }
}

/* Button Styles (add these if not already present) */
.btn-xs {
    padding: 0.25rem 0.5rem;
    font-size: 0.75rem;
}

/* Note Selection Menu (floating context menu) */
.note-selection-menu {
    position: absolute;
    z-index: 1050;
    display: flex;
    align-items: center;
    background: var(--color-white);
    border: 1px solid var(--color-gray-200);
    border-radius: 9999px;
    box-shadow: var(--shadow-lg);
    padding: 0.25rem;
    animation: selectionMenuFadeIn 0.15s ease;
}

@keyframes selectionMenuFadeIn {
    from {
        opacity: 0;
        transform: translateY(4px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.selection-menu-btn {
    display: flex;
    align-items: center;
    gap: 0.375rem;
    padding: 0.5rem 0.875rem;
    background: var(--color-black);
    color: var(--color-white);
    border: none;
    border-radius: 9999px;
    cursor: pointer;
    font-size: 0.8125rem;
    font-weight: 500;
    transition: all 0.15s ease;
    white-space: nowrap;
}

.selection-menu-btn:hover {
    background: var(--color-gray-800);
    transform: scale(1.02);
}

.selection-menu-btn:active {
    transform: scale(0.98);
}

.selection-menu-btn i {
    font-size: 0.875rem;
}

/* Form textarea styling */
.form-textarea {
    resize: vertical;
    min-height: 80px;
    font-family: var(--font-sans);
    line-height: 1.5;
}

.form-textarea[readonly] {
    background-color: var(--color-gray-50);
    cursor: default;
}

/* Form hint styling */
.form-hint {
    font-size: 0.8125rem;
    color: var(--color-gray-500);
    margin-top: 0.375rem;
    display: flex;
    align-items: center;
    gap: 0.375rem;
}

.form-hint i {
    font-size: 0.875rem;
}

/* ================================= */
/* File Upload & Preview Styles      */
/* ================================= */

/* From File Section */
.from-file-section {
    border-bottom: 1px solid var(--color-gray-100);
    padding-bottom: 1.5rem;
    margin-bottom: 1.5rem;
}

.from-file-description {
    font-size: 0.8125rem;
    color: var(--color-gray-500);
    margin-bottom: 1rem;
    line-height: 1.5;
}

/* File Upload Area */
.file-upload-area {
    border: 2px dashed var(--color-gray-300);
    border-radius: var(--border-radius);
    padding: 1.5rem;
    text-align: center;
    background-color: var(--color-gray-50);
    cursor: pointer;
    transition: all 0.2s ease;
}

.file-upload-area:hover {
    border-color: var(--color-gray-400);
    background-color: var(--color-white);
}

.file-upload-area.drag-over {
    border-color: var(--color-black);
    background-color: var(--color-white);
    box-shadow: 0 0 0 3px rgba(0, 0, 0, 0.1);
}

.file-upload-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
}

.file-upload-content i {
    font-size: 2rem;
    color: var(--color-gray-400);
}

.file-upload-text {
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--color-gray-700);
}

.file-upload-hint {
    font-size: 0.75rem;
    color: var(--color-gray-400);
}

.file-upload-types {
    font-size: 0.75rem;
    color: var(--color-gray-400);
    margin-top: 0.5rem;
}

/* File Preview Modal */
#filePreviewModal .modal-container {
    max-width: none;
    width: 80%;
    height: 80%;
    max-height: 90vh;
    display: flex;
    flex-direction: column;
}

.file-preview-header-info {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.file-preview-header-info i {
    font-size: 1.25rem;
    color: var(--color-gray-500);
}

.file-preview-header-info h3 {
    margin: 0;
    font-size: 1rem;
    font-weight: 600;
    max-width: 600px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.file-preview-body {
    padding: 0;
    flex: 1;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.file-preview-loading,
.file-preview-error {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 1rem;
    padding: 3rem;
    color: var(--color-gray-500);
    min-height: 300px;
}

.file-preview-error {
    color: var(--color-error);
}

.file-preview-error i {
    font-size: 2.5rem;
}

.file-preview-content {
    flex: 1;
    overflow: auto;
    display: flex;
    flex-direction: column;
}

/* PDF Preview */
.pdf-preview-container {
    display: flex;
    flex-direction: column;
    flex: 1;
}

.pdf-navigation {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 1rem;
    padding: 0.75rem 1rem;
    background-color: var(--color-gray-50);
    border-bottom: 1px solid var(--color-gray-200);
}

.pdf-page-info {
    font-size: 0.875rem;
    color: var(--color-gray-600);
}

.pdf-canvas-wrapper {
    position: relative;
    flex: 1;
    overflow: auto;
    padding: 1rem;
    background-color: var(--color-gray-100);
    display: flex;
    justify-content: center;
}

#pdfCanvas {
    background-color: white;
    box-shadow: var(--shadow);
}

.pdf-text-layer {
    position: absolute;
    top: 1rem;
    left: 50%;
    transform: translateX(-50%);
    overflow: hidden;
    opacity: 0.2;
    line-height: 1;
    pointer-events: auto;
}

.pdf-text-layer span {
    position: absolute;
    white-space: pre;
    cursor: text;
    color: transparent;
}

.pdf-text-layer span::selection {
    background-color: rgba(0, 100, 255, 0.4);
}

/* Markdown Preview */
.markdown-preview-container {
    padding: 1.5rem;
    overflow: auto;
    flex: 1;
}

.markdown-content {
    line-height: 1.7;
    color: var(--color-gray-800);
}

.markdown-content h1,
.markdown-content h2,
.markdown-content h3,
.markdown-content h4,
.markdown-content h5,
.markdown-content h6 {
    margin-top: 1.5em;
    margin-bottom: 0.5em;
    font-weight: 600;
    line-height: 1.3;
}

.markdown-content h1 {
    font-size: 1.75rem;
    border-bottom: 1px solid var(--color-gray-200);
    padding-bottom: 0.5rem;
}

.markdown-content h2 {
    font-size: 1.5rem;
}

.markdown-content h3 {
    font-size: 1.25rem;
}

.markdown-content p {
    margin-bottom: 1em;
}

.markdown-content ul,
.markdown-content ol {
    margin-bottom: 1em;
    padding-left: 2em;
}

.markdown-content li {
    margin-bottom: 0.25em;
}

.markdown-content code {
    background-color: var(--color-gray-100);
    padding: 0.2em 0.4em;
    border-radius: 4px;
    font-size: 0.875em;
    font-family: 'SF Mono', Monaco, 'Courier New', monospace;
}

.markdown-content pre {
    background-color: var(--color-gray-100);
    padding: 1rem;
    border-radius: var(--border-radius-sm);
    overflow-x: auto;
    margin-bottom: 1em;
}

.markdown-content pre code {
    background: none;
    padding: 0;
}

.markdown-content blockquote {
    border-left: 4px solid var(--color-gray-300);
    padding-left: 1rem;
    margin-left: 0;
    margin-bottom: 1em;
    color: var(--color-gray-600);
}

.markdown-content a {
    color: #0066cc;
    text-decoration: underline;
}

.markdown-content img {
    max-width: 100%;
    height: auto;
    border-radius: var(--border-radius-sm);
}

.markdown-content table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 1em;
}

.markdown-content th,
.markdown-content td {
    border: 1px solid var(--color-gray-200);
    padding: 0.5rem 0.75rem;
    text-align: left;
}

.markdown-content th {
    background-color: var(--color-gray-50);
    font-weight: 600;
}

.markdown-content hr {
    border: none;
    border-top: 1px solid var(--color-gray-200);
    margin: 2em 0;
}

/* File Preview Footer */
.file-preview-hint {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.8125rem;
    color: var(--color-gray-500);
}

.file-preview-hint i {
    color: var(--color-gray-400);
}

/* File Selection Menu (reuses note-selection-menu styles) */
.file-selection-menu {
    z-index: 1100;
}

/* ==================== */
/* Kanban Board Styles  */
/* ==================== */

.kanban-container {
    max-width: 100%;
    padding: 2rem 2rem;
}

.kanban-page-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 1rem;
    margin-bottom: 2rem;
}

.page-header-left {
    display: flex;
    align-items: center;
    gap: 1.5rem;
    flex-wrap: wrap;
}

.page-header-right {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.board-selector {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.board-select {
    padding: 0.5rem 1rem;
    border: 1px solid var(--color-gray-300);
    border-radius: var(--border-radius-sm);
    font-size: 0.875rem;
    font-weight: 500;
    background-color: var(--color-white);
    min-width: 150px;
}

.board-select:focus {
    outline: none;
    border-color: var(--color-black);
}

.btn-danger-outline {
    color: var(--color-error);
    border-color: var(--color-error);
}

.btn-danger-outline:hover {
    background-color: var(--color-error);
    color: var(--color-white);
}

.kanban-layout {
    display: grid;
    grid-template-columns: 320px 1fr;
    gap: 1.5rem;
    min-height: calc(100vh - 200px);
}

.kanban-sidebar {
    min-width: 0;
}

.kanban-main {
    min-width: 0;
    overflow-x: auto;
}

.kanban-board {
    display: flex;
    gap: 1rem;
    padding-bottom: 1rem;
    min-height: 400px;
}

/* Kanban Column */
.kanban-column {
    flex-shrink: 0;
    width: 300px;
    background-color: var(--color-gray-100);
    border-radius: var(--border-radius);
    display: flex;
    flex-direction: column;
    max-height: calc(100vh - 250px);
}

.kanban-column-header {
    padding: 1rem;
    background-color: var(--color-white);
    border-radius: var(--border-radius) var(--border-radius) 0 0;
    border-top: 3px solid var(--color-gray-400);
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-shrink: 0;
}

.column-header-left {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    min-width: 0;
}

.column-color-indicator {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    flex-shrink: 0;
}

.column-title {
    font-weight: 600;
    font-size: 0.9375rem;
    color: var(--color-gray-900);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.column-task-count {
    font-size: 0.75rem;
    color: var(--color-gray-500);
    background-color: var(--color-gray-100);
    padding: 0.125rem 0.5rem;
    border-radius: 9999px;
    flex-shrink: 0;
}

.column-task-count.wip-limit-reached {
    background-color: var(--color-warning);
    color: var(--color-white);
}

.column-header-right {
    display: flex;
    align-items: center;
    gap: 0.25rem;
    opacity: 0;
    transition: opacity 0.15s ease;
}

.kanban-column-header:hover .column-header-right {
    opacity: 1;
}

.column-action-btn {
    width: 28px;
    height: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: none;
    background: transparent;
    color: var(--color-gray-500);
    border-radius: var(--border-radius-sm);
    cursor: pointer;
    transition: all 0.15s ease;
}

.column-action-btn:hover {
    background-color: var(--color-gray-100);
    color: var(--color-gray-700);
}

.column-action-btn-danger:hover {
    background-color: #fef2f2;
    color: var(--color-error);
}

/* Kanban Column Tasks Container */
.kanban-column-tasks {
    flex: 1;
    padding: 0.75rem;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    min-height: 100px;
}

.kanban-column-tasks.drag-over {
    background-color: var(--color-gray-200);
}

/* Kanban Task Card */
.kanban-task-card {
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
    padding: 0.875rem;
    background-color: var(--color-white);
    border-radius: var(--border-radius-sm);
    box-shadow: var(--shadow-sm);
    cursor: grab;
    transition: all 0.15s ease;
    border: 1px solid transparent;
}

.kanban-task-card:hover {
    box-shadow: var(--shadow);
    border-color: var(--color-gray-200);
}

.kanban-task-card.dragging {
    opacity: 0.5;
    cursor: grabbing;
}

.kanban-task-color {
    width: 4px;
    height: 100%;
    min-height: 40px;
    border-radius: 2px;
    flex-shrink: 0;
}

.kanban-task-info {
    flex: 1;
    min-width: 0;
}

.kanban-task-name {
    display: block;
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--color-gray-900);
    text-decoration: none;
    margin-bottom: 0.375rem;
    line-height: 1.4;
}

.kanban-task-name:hover {
    color: var(--color-black);
    text-decoration: underline;
}

.kanban-task-meta {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}

.kanban-task-project {
    font-size: 0.75rem;
    color: var(--color-gray-500);
}

.kanban-task-deadline {
    font-size: 0.6875rem;
    color: var(--color-gray-400);
}

.kanban-task-deadline i {
    margin-right: 0.25rem;
}

.kanban-task-actions {
    opacity: 0;
    transition: opacity 0.15s ease;
}

.kanban-task-card:hover .kanban-task-actions {
    opacity: 1;
}

.kanban-task-remove {
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: none;
    background: transparent;
    color: var(--color-gray-400);
    border-radius: var(--border-radius-sm);
    cursor: pointer;
    transition: all 0.15s ease;
}

.kanban-task-remove:hover {
    background-color: #fef2f2;
    color: var(--color-error);
}

/* Drop Indicator */
.drop-indicator {
    height: 3px;
    background-color: var(--color-black);
    border-radius: 2px;
    margin: 0.25rem 0;
}

/* Task on board indicator */
.kanban-draggable-task.on-board {
    opacity: 0.5;
    background-color: var(--color-gray-100);
}

.kanban-draggable-task.on-board::after {
    content: 'On board';
    font-size: 0.625rem;
    color: var(--color-gray-500);
    margin-left: auto;
    flex-shrink: 0;
}

/* Kanban Notification */
.kanban-notification {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    padding: 0.875rem 1.25rem;
    background-color: var(--color-gray-900);
    color: var(--color-white);
    border-radius: var(--border-radius-sm);
    font-size: 0.875rem;
    box-shadow: var(--shadow-lg);
    transform: translateY(100px);
    opacity: 0;
    transition: all 0.3s ease;
    z-index: 9999;
}

.kanban-notification.show {
    transform: translateY(0);
    opacity: 1;
}

.kanban-notification.success {
    background-color: var(--color-success);
}

.kanban-notification.error {
    background-color: var(--color-error);
}

.kanban-notification.warning {
    background-color: var(--color-warning);
}

/* Responsive Kanban */
@media (max-width: 1200px) {
    .kanban-layout {
        grid-template-columns: 280px 1fr;
    }

    .kanban-column {
        width: 260px;
    }
}

@media (max-width: 992px) {
    .kanban-layout {
        grid-template-columns: 1fr;
    }

    .kanban-sidebar {
        order: 2;
    }

    .kanban-main {
        order: 1;
    }

    .kanban-board {
        overflow-x: auto;
        padding-bottom: 1rem;
    }

    .kanban-column {
        width: 280px;
        max-height: 400px;
    }
}

@media (max-width: 768px) {
    .kanban-container {
        padding: 0 1rem;
    }

    .kanban-page-header {
        flex-direction: column;
        align-items: flex-start;
    }

    .page-header-left {
        flex-direction: column;
        align-items: flex-start;
        width: 100%;
    }

    .board-selector {
        width: 100%;
    }

    .board-select {
        flex: 1;
    }

    .page-header-right {
        width: 100%;
        justify-content: flex-start;
    }

    .kanban-column {
        width: 260px;
        min-width: 260px;
    }
}

/* ========== Share Management Styles ========== */

/* Share Page Sections */
.share-sections {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
    margin-top: 2rem;
}

.share-section {
    background: var(--color-white);
    border: 1px solid var(--color-gray-200);
    border-radius: var(--border-radius);
    padding: 1.5rem;
}

.share-section-header {
    display: flex;
    gap: 1rem;
    margin-bottom: 1.25rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid var(--color-gray-100);
}

.share-section-icon {
    width: 48px;
    height: 48px;
    border-radius: var(--border-radius-sm);
    background: var(--color-gray-100);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.25rem;
    color: var(--color-gray-600);
    flex-shrink: 0;
}

.share-section-info h3 {
    font-size: 1.1rem;
    font-weight: 600;
    margin-bottom: 0.25rem;
}

.share-section-info p {
    font-size: 0.875rem;
    color: var(--color-gray-500);
    margin: 0;
}

.share-section-content {
    margin-top: 1rem;
}

.share-active {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.share-inactive {
    text-align: center;
    padding: 1.5rem;
    color: var(--color-gray-500);
}

.share-inactive p {
    margin-bottom: 1rem;
}

.share-status {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.share-created,
.share-expiry {
    font-size: 0.875rem;
    color: var(--color-gray-500);
}

.share-detail {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.share-detail label {
    font-size: 0.8rem;
    font-weight: 500;
    color: var(--color-gray-600);
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.input-with-copy {
    display: flex;
    gap: 0.5rem;
}

.input-with-copy input {
    flex: 1;
    padding: 0.75rem 1rem;
    border: 1px solid var(--color-gray-200);
    border-radius: var(--border-radius-sm);
    font-size: 0.875rem;
    background: var(--color-gray-50);
    font-family: monospace;
}

.password-display {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.password-masked {
    font-family: monospace;
    font-size: 1rem;
    color: var(--color-gray-600);
    letter-spacing: 0.1em;
}

.share-hint {
    font-size: 0.75rem;
    color: var(--color-gray-400);
}

.share-actions {
    display: flex;
    gap: 0.5rem;
    margin-top: 0.5rem;
}

/* Password Dialog */
.password-reveal {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1rem;
    background: var(--color-gray-50);
    border: 1px solid var(--color-gray-200);
    border-radius: var(--border-radius-sm);
    margin: 1rem 0;
}

.password-code {
    font-family: monospace;
    font-size: 1.25rem;
    font-weight: 600;
    letter-spacing: 0.05em;
    flex: 1;
}

/* Toast Notification */
.toast-notification {
    position: fixed;
    bottom: 2rem;
    left: 50%;
    transform: translateX(-50%) translateY(100px);
    background: var(--color-gray-900);
    color: var(--color-white);
    padding: 0.875rem 1.5rem;
    border-radius: var(--border-radius);
    font-size: 0.875rem;
    font-weight: 500;
    z-index: 10000;
    opacity: 0;
    transition: transform 0.3s ease, opacity 0.3s ease;
}

.toast-notification.show {
    transform: translateX(-50%) translateY(0);
    opacity: 1;
}

/* Public View Page Styles */
.public-view-page {
    background: var(--color-gray-50);
    min-height: 100vh;
}

.navbar-public {
    background: var(--color-white);
    border-bottom: 1px solid var(--color-gray-200);
    height: var(--navbar-height);
}

.navbar-badge {
    background: var(--color-gray-100);
    color: var(--color-gray-600);
    padding: 0.375rem 0.75rem;
    border-radius: var(--border-radius-sm);
    font-size: 0.75rem;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.public-error-state,
.public-password-form {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: calc(100vh - var(--navbar-height) - 4rem);
}

.public-error-state {
    flex-direction: column;
    gap: 1rem;
    text-align: center;
}

.public-error-state .error-icon {
    font-size: 3rem;
    color: var(--color-error);
}

.password-form-card {
    background: var(--color-white);
    border: 1px solid var(--color-gray-200);
    border-radius: var(--border-radius);
    padding: 2rem;
    max-width: 400px;
    width: 100%;
}

.password-form-header {
    text-align: center;
    margin-bottom: 1.5rem;
}

.password-form-header i {
    font-size: 2rem;
    color: var(--color-gray-400);
    margin-bottom: 0.75rem;
    display: block;
}

.password-form-header h2 {
    font-size: 1.25rem;
    font-weight: 600;
}

.password-form-body p {
    text-align: center;
    color: var(--color-gray-600);
    margin-bottom: 1.5rem;
}

.password-entry-form .form-group {
    margin-bottom: 1rem;
}

.password-entry-form .form-input {
    width: 100%;
    padding: 0.875rem 1rem;
    border: 1px solid var(--color-gray-200);
    border-radius: var(--border-radius-sm);
    font-size: 1rem;
    text-align: center;
}

.password-form-footer {
    margin-top: 1.5rem;
    text-align: center;
    font-size: 0.875rem;
    color: var(--color-gray-500);
}

.password-form-footer a {
    color: var(--color-black);
    font-weight: 500;
}

.public-project-view {
    margin-top: 2rem;
}

.task-item-readonly {
    cursor: default;
}

.task-item-readonly .task-name {
    cursor: default;
    pointer-events: none;
}

.task-description-preview {
    font-size: 0.8rem;
    color: var(--color-gray-500);
    margin-top: 0.5rem;
    line-height: 1.4;
}

.sidebar-cta {
    background: var(--color-gray-50);
    border: 1px dashed var(--color-gray-300);
    text-align: center;
}

.sidebar-cta h3 {
    margin-bottom: 0.5rem;
}

.sidebar-cta p {
    font-size: 0.875rem;
    color: var(--color-gray-500);
    margin-bottom: 1rem;
}

.cta-buttons {
    display: flex;
    gap: 0.75rem;
    justify-content: center;
}

/* Invite Registration Page */
.invite-project-name {
    font-size: 1.5rem;
    font-weight: 600;
    margin-top: 0.75rem;
    color: var(--color-black);
}

.invite-info {
    text-align: center;
    color: var(--color-gray-600);
    margin-bottom: 1.5rem;
    font-size: 0.9rem;
}

.auth-error-state {
    text-align: center;
}

.auth-error-state .error-message {
    padding: 2rem;
}

.auth-error-state .error-icon {
    font-size: 3rem;
    color: var(--color-error);
    margin-bottom: 1rem;
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .share-section {
        padding: 1rem;
    }

    .share-section-header {
        flex-direction: column;
        text-align: center;
    }

    .share-section-icon {
        margin: 0 auto;
    }

    .input-with-copy {
        flex-direction: column;
    }

    .input-with-copy input {
        text-align: left;
    }

    .share-actions {
        flex-direction: column;
    }

    .password-display {
        flex-direction: column;
        align-items: flex-start;
    }
}

/* Task Status Filter */
.task-filter-container {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-left: auto;
}

.task-filter-select {
    padding: 0.5rem 0.875rem;
    padding-right: 2rem;
    border: 1px solid var(--color-gray-300);
    border-radius: var(--border-radius-sm);
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--color-gray-700);
    background-color: var(--color-white);
    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='%23525252' d='M6 8L2 4h8z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 0.625rem center;
    transition: all 0.15s ease;
}

.task-filter-select:hover {
    border-color: var(--color-gray-400);
    background-color: var(--color-gray-50);
}

.task-filter-select:focus {
    outline: none;
    border-color: var(--color-black);
    box-shadow: 0 0 0 3px rgba(0, 0, 0, 0.05);
}

.filter-indicator {
    display: inline-flex;
    align-items: center;
    gap: 0.375rem;
    padding: 0.25rem 0.625rem;
    background-color: var(--color-gray-100);
    border-radius: 9999px;
    font-size: 0.75rem;
    font-weight: 500;
    color: var(--color-gray-600);
}

.filter-indicator i {
    font-size: 0.625rem;
}

/* Visually hidden for accessibility */
.visually-hidden {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

/* Section header updates for filter */
.tasks-section .section-header {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.tasks-section .section-header h2 {
    margin: 0;
}

.tasks-section .section-header .task-count {
    margin-right: auto;
}

/* Responsive task filter */
@media (max-width: 640px) {
    .task-filter-container {
        width: 100%;
        margin-left: 0;
        margin-top: 0.75rem;
    }

    .task-filter-select {
        flex: 1;
    }

    .tasks-section .section-header {
        flex-direction: column;
        align-items: flex-start;
    }

    .tasks-section .section-header .task-count {
        margin-right: 0;
    }
}

/* Project Choice Modal */
.dialog-choice {
    max-width: 480px;
}

.dialog-subtitle {
    color: var(--color-gray-600);
    font-size: 0.9375rem;
    margin-bottom: 1.5rem;
}

.choice-buttons {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.choice-btn {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
    padding: 1.5rem 1.25rem;
    background: var(--color-white);
    border: 2px solid var(--color-gray-200);
    border-radius: var(--border-radius-md);
    cursor: pointer;
    transition: all 0.2s ease;
    text-align: center;
}

.choice-btn:hover {
    border-color: var(--color-black);
    background: var(--color-gray-50);
}

.choice-btn:focus {
    outline: none;
    border-color: var(--color-black);
    box-shadow: 0 0 0 3px rgba(0, 0, 0, 0.1);
}

.choice-icon {
    font-size: 1.75rem;
    color: var(--color-gray-700);
    margin-bottom: 0.25rem;
}

.choice-title {
    font-size: 1rem;
    font-weight: 600;
    color: var(--color-gray-900);
}

.choice-description {
    font-size: 0.8125rem;
    color: var(--color-gray-500);
    line-height: 1.4;
}

/* Project Import Modal */
.import-instructions {
    color: var(--color-gray-600);
    font-size: 0.9375rem;
    margin-bottom: 1.5rem;
    line-height: 1.5;
}

.import-upload-area {
    margin-bottom: 1.5rem;
}

.import-file-info {
    background: var(--color-gray-50);
    border: 1px solid var(--color-gray-200);
    border-radius: var(--border-radius-md);
    padding: 1rem;
    margin-bottom: 1.5rem;
}

.import-file-details {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 1rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid var(--color-gray-200);
}

.import-file-details i {
    font-size: 1.5rem;
    color: var(--color-gray-500);
}

.import-file-details span:first-of-type {
    flex: 1;
    font-weight: 500;
    color: var(--color-gray-900);
    word-break: break-all;
}

.import-preview {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.import-preview-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.preview-label {
    font-size: 0.8125rem;
    color: var(--color-gray-500);
}

.preview-value {
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--color-gray-900);
}

/* Notification Styles */
.notification {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    padding: 1rem 1.5rem;
    border-radius: var(--border-radius-md);
    font-size: 0.9375rem;
    font-weight: 500;
    box-shadow: var(--shadow-lg);
    z-index: 10000;
    opacity: 0;
    transform: translateY(1rem);
    transition: all 0.3s ease;
}

.notification.show {
    opacity: 1;
    transform: translateY(0);
}

.notification-success {
    background: #065f46;
    color: white;
}

.notification-error {
    background: #991b1b;
    color: white;
}

.notification-info {
    background: var(--color-gray-900);
    color: white;
}

@media (max-width: 640px) {
    .notification {
        left: 1rem;
        right: 1rem;
        bottom: 1rem;
    }

    .choice-buttons {
        gap: 0.75rem;
    }

    .choice-btn {
        padding: 1.25rem 1rem;
    }
}

/* Project from Note Dialog Styles */
.project-from-note-dialog {
    max-width: 1100px;
    width: 95%;
    max-height: 90vh;
}

.project-from-note-dialog .dialog-content {
    display: flex;
    flex-direction: column;
    height: calc(90vh - 60px);
    overflow: hidden;
}

.project-from-note-layout {
    display: flex;
    gap: 1.5rem;
    flex: 1;
    min-height: 0;
    overflow: hidden;
}

/* Left Column: Note Editor (Full Height) */
.note-editor-panel {
    flex: 1.2;
    display: flex;
    flex-direction: column;
    background: var(--color-gray-50);
    border-radius: var(--border-radius-md);
    padding: 1rem;
    border: 1px solid var(--color-gray-200);
    min-height: 0;
}

/* Right Column: Project Config */
.project-config-panel {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 1rem;
    min-height: 0;
    overflow-y: auto;
}

.panel-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.75rem;
    padding-bottom: 0.75rem;
    border-bottom: 1px solid var(--color-gray-200);
}

.panel-header h3 {
    font-size: 1rem;
    font-weight: 600;
    color: var(--color-gray-900);
    margin: 0;
}

.panel-hint {
    font-size: 0.75rem;
    color: var(--color-gray-500);
}

.task-count-badge {
    background: var(--color-gray-900);
    color: white;
    font-size: 0.75rem;
    font-weight: 600;
    padding: 0.125rem 0.5rem;
    border-radius: 9999px;
    min-width: 1.5rem;
    text-align: center;
}

/* Note Upload Area */
.note-upload-area {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
}

.note-editor-container {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    min-height: 0;
}

.note-editor-toolbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-shrink: 0;
    margin-bottom: 0.75rem;
}

.note-editor-toolbar-actions {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.note-file-name {
    font-size: 0.875rem;
    color: var(--color-gray-600);
    font-weight: 500;
}

/* View Toggle Buttons */
.pfn-view-toggle {
    display: flex;
    border: 1px solid var(--color-gray-300);
    border-radius: var(--border-radius-md);
    overflow: hidden;
}

.view-toggle-btn {
    padding: 0.375rem 0.625rem;
    background: white;
    border: none;
    cursor: pointer;
    color: var(--color-gray-500);
    transition: all 0.15s ease;
}

.view-toggle-btn:not(:last-child) {
    border-right: 1px solid var(--color-gray-300);
}

.view-toggle-btn:hover {
    background: var(--color-gray-100);
    color: var(--color-gray-700);
}

.view-toggle-btn.active {
    background: var(--color-gray-900);
    color: white;
}

/* PFN Editor Layout */
.pfn-editor-layout {
    flex: 1;
    display: flex;
    min-height: 0;
    gap: 0;
    border: 1px solid var(--color-gray-300);
    border-radius: var(--border-radius-md);
    overflow: hidden;
    background: white;
}

.pfn-editor-layout.split-view {
    gap: 1px;
    background: var(--color-gray-300);
}

.pfn-editor-wrapper {
    flex: 1;
    min-height: 0;
    display: flex;
    flex-direction: column;
    background: white;
}

.pfn-editor-wrapper .CodeMirror {
    flex: 1;
    height: auto;
    font-family: 'Monaco', 'Menlo', 'Ubuntu Mono', monospace;
    font-size: 0.875rem;
    line-height: 1.6;
}

.pfn-preview-wrapper {
    flex: 1;
    min-height: 0;
    overflow-y: auto;
    padding: 1rem;
    background: white;
}

.pfn-preview-content {
    font-size: 0.9375rem;
    line-height: 1.7;
    color: var(--color-gray-800);
}

.pfn-preview-content h1,
.pfn-preview-content h2,
.pfn-preview-content h3,
.pfn-preview-content h4,
.pfn-preview-content h5,
.pfn-preview-content h6 {
    margin-top: 1.5em;
    margin-bottom: 0.5em;
    font-weight: 600;
    color: var(--color-gray-900);
}

.pfn-preview-content h1 { font-size: 1.5rem; }
.pfn-preview-content h2 { font-size: 1.25rem; }
.pfn-preview-content h3 { font-size: 1.125rem; }

.pfn-preview-content p {
    margin-bottom: 1em;
}

.pfn-preview-content ul,
.pfn-preview-content ol {
    margin-bottom: 1em;
    padding-left: 1.5em;
}

.pfn-preview-content li {
    margin-bottom: 0.25em;
}

.pfn-preview-content code {
    background: var(--color-gray-100);
    padding: 0.125rem 0.375rem;
    border-radius: 3px;
    font-family: 'Monaco', 'Menlo', 'Ubuntu Mono', monospace;
    font-size: 0.85em;
}

.pfn-preview-content pre {
    background: var(--color-gray-100);
    padding: 1rem;
    border-radius: var(--border-radius-md);
    overflow-x: auto;
    margin-bottom: 1em;
}

.pfn-preview-content pre code {
    background: none;
    padding: 0;
}

.pfn-preview-content blockquote {
    border-left: 3px solid var(--color-gray-300);
    padding-left: 1rem;
    margin: 0 0 1em 0;
    color: var(--color-gray-600);
}

.pfn-preview-content a {
    color: var(--color-primary);
    text-decoration: underline;
}

.pfn-preview-content table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 1em;
}

.pfn-preview-content th,
.pfn-preview-content td {
    border: 1px solid var(--color-gray-300);
    padding: 0.5rem;
    text-align: left;
}

.pfn-preview-content th {
    background: var(--color-gray-100);
    font-weight: 600;
}


.note-selection-actions {
    display: flex;
    justify-content: flex-end;
    padding-top: 0.5rem;
    flex-shrink: 0;
}

/* Project Details Section */
.project-config-panel .project-details-section {
    background: var(--color-gray-50);
    border-radius: var(--border-radius-md);
    padding: 1rem;
    border: 1px solid var(--color-gray-200);
    flex-shrink: 0;
}

.project-config-panel .project-details-section h3 {
    font-size: 0.9375rem;
    font-weight: 600;
    color: var(--color-gray-900);
    margin: 0 0 0.75rem 0;
    padding-bottom: 0.5rem;
    border-bottom: 1px solid var(--color-gray-200);
}

.project-config-panel .project-details-section .form-group {
    margin-bottom: 0.75rem;
}

.project-config-panel .project-details-section .form-group:last-child {
    margin-bottom: 0;
}

.project-config-panel .project-details-section label {
    font-size: 0.8125rem;
}

.input-with-color {
    display: flex;
    gap: 0.5rem;
}

.input-with-color .form-control:first-child {
    flex: 1;
}

.input-with-color .form-control-color {
    width: 44px;
    flex-shrink: 0;
}

/* Task List Panel in Right Column */
.project-config-panel .task-list-panel {
    flex: 1;
    display: flex;
    flex-direction: column;
    background: var(--color-gray-50);
    border-radius: var(--border-radius-md);
    padding: 1rem;
    border: 1px solid var(--color-gray-200);
    min-height: 150px;
    overflow: hidden;
}

/* Task List Styles */
.task-list-container {
    flex: 1;
    overflow-y: auto;
    min-height: 0;
}

.task-list-empty {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    color: var(--color-gray-400);
    padding: 1.5rem 1rem;
}

.task-list-empty i {
    font-size: 2rem;
    margin-bottom: 0.75rem;
}

.task-list-empty p {
    font-size: 0.9375rem;
    font-weight: 500;
    margin: 0 0 0.25rem 0;
    color: var(--color-gray-600);
}

.task-list-empty span {
    font-size: 0.75rem;
}

.task-list {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.task-list-item {
    display: flex;
    align-items: flex-start;
    gap: 0.5rem;
    background: white;
    padding: 0.625rem;
    border-radius: var(--border-radius-md);
    border: 1px solid var(--color-gray-200);
}

.task-list-item:hover {
    border-color: var(--color-gray-300);
}

.task-list-item-color {
    width: 3px;
    min-height: 100%;
    border-radius: 2px;
    flex-shrink: 0;
    align-self: stretch;
}

.task-list-item-content {
    flex: 1;
    min-width: 0;
}

.task-list-item-name {
    font-size: 0.8125rem;
    font-weight: 500;
    color: var(--color-gray-900);
    margin-bottom: 0.125rem;
    word-break: break-word;
}

.task-list-item-description {
    font-size: 0.6875rem;
    color: var(--color-gray-500);
    margin-bottom: 0.125rem;
    word-break: break-word;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.task-list-item-category {
    font-size: 0.6875rem;
    color: var(--color-gray-400);
}

.task-list-item-category i {
    margin-right: 0.25rem;
}

.task-list-item-delete {
    flex-shrink: 0;
    opacity: 0.5;
    transition: opacity 0.2s ease;
    padding: 0.25rem;
}

.task-list-item:hover .task-list-item-delete {
    opacity: 1;
}

/* Form Actions in Right Column */
.project-config-panel .form-actions {
    flex-shrink: 0;
    padding-top: 0.5rem;
}

.project-config-panel .form-error {
    flex-shrink: 0;
}

/* Responsive Styles */
@media (max-width: 900px) {
    .project-from-note-dialog {
        max-width: 100%;
        width: 100%;
        max-height: 100vh;
        border-radius: 0;
    }

    .project-from-note-dialog .dialog-content {
        height: calc(100vh - 60px);
    }

    .project-from-note-layout {
        flex-direction: column;
        overflow-y: auto;
    }

    .note-editor-panel {
        flex: none;
        min-height: 300px;
    }

    .project-config-panel {
        flex: none;
    }

    .note-editor {
        min-height: 200px;
    }
}

/* ============================================
   Project Note Tab Styles
   ============================================ */

.project-note-container {
    background: var(--color-white);
    border-radius: var(--border-radius);
    border: 1px solid var(--color-gray-200);
    overflow: hidden;
}

.note-toolbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.75rem 1rem;
    background: var(--color-gray-50);
    border-bottom: 1px solid var(--color-gray-200);
}

.note-view-mode-container {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.note-view-mode-label {
    font-size: 0.8125rem;
    font-weight: 500;
    color: var(--color-gray-600);
}

.note-view-mode-select {
    padding: 0.375rem 0.75rem;
    font-size: 0.8125rem;
    border: 1px solid var(--color-gray-200);
    border-radius: 6px;
    background: var(--color-white);
    cursor: pointer;
}

.note-view-mode-select:hover {
    border-color: var(--color-gray-300);
}

.note-view-mode-select:focus {
    outline: none;
    border-color: var(--color-black);
    box-shadow: 0 0 0 2px rgba(0, 0, 0, 0.1);
}

.note-save-status {
    display: flex;
    align-items: center;
    gap: 0.375rem;
    font-size: 0.75rem;
    color: var(--color-gray-500);
}

.note-save-status.saving .save-status-text {
    color: var(--color-warning);
}

.note-save-status.saved .save-status-text {
    color: var(--color-success);
}

.note-save-status.error .save-status-text {
    color: var(--color-error);
}

.note-content-area {
    display: block;
    min-height: 500px;
}

.note-editor-panel,
.note-preview-panel {
    width: 100%;
}

.note-editor-panel {
    display: flex;
    flex-direction: column;
}

.note-editor-panel textarea {
    flex: 1;
    width: 100%;
    min-height: 500px;
    padding: 1rem;
    font-family: 'SF Mono', 'Fira Code', 'Monaco', 'Consolas', monospace;
    font-size: 0.875rem;
    line-height: 1.6;
    border: none;
    resize: none;
    background: var(--color-white);
    color: var(--color-gray-900);
}

.note-editor-panel textarea:focus {
    outline: none;
}

.note-editor-panel textarea::placeholder {
    color: var(--color-gray-400);
}

.note-editor-panel textarea:disabled {
    background: var(--color-gray-50);
    color: var(--color-gray-600);
    cursor: not-allowed;
}

.note-preview-panel {
    display: flex;
    flex-direction: column;
    background: var(--color-white);
}

.note-preview-content {
    flex: 1;
    padding: 1rem;
    overflow-y: auto;
}

.note-preview-empty {
    color: var(--color-gray-400);
    font-style: italic;
}

/* Markdown styling in preview */
.note-preview-content.markdown-body h1 {
    font-size: 1.5rem;
    font-weight: 700;
    margin: 0 0 1rem 0;
    padding-bottom: 0.5rem;
    border-bottom: 1px solid var(--color-gray-200);
}

.note-preview-content.markdown-body h2 {
    font-size: 1.25rem;
    font-weight: 600;
    margin: 1.5rem 0 0.75rem 0;
}

.note-preview-content.markdown-body h3 {
    font-size: 1.125rem;
    font-weight: 600;
    margin: 1.25rem 0 0.5rem 0;
}

.note-preview-content.markdown-body p {
    margin: 0 0 1rem 0;
    line-height: 1.7;
}

.note-preview-content.markdown-body ul,
.note-preview-content.markdown-body ol {
    margin: 0 0 1rem 0;
    padding-left: 1.5rem;
}

.note-preview-content.markdown-body li {
    margin: 0.25rem 0;
}

.note-preview-content.markdown-body code {
    background: var(--color-gray-100);
    padding: 0.125rem 0.375rem;
    border-radius: 4px;
    font-size: 0.85em;
    font-family: 'SF Mono', 'Fira Code', monospace;
}

.note-preview-content.markdown-body pre {
    background: var(--color-gray-100);
    padding: 1rem;
    border-radius: 8px;
    overflow-x: auto;
    margin: 0 0 1rem 0;
}

.note-preview-content.markdown-body pre code {
    background: none;
    padding: 0;
}

.note-preview-content.markdown-body blockquote {
    border-left: 3px solid var(--color-gray-300);
    padding-left: 1rem;
    margin: 0 0 1rem 0;
    color: var(--color-gray-600);
}

.note-preview-content.markdown-body a {
    color: var(--color-black);
    text-decoration: underline;
}

.note-preview-content.markdown-body a:hover {
    color: var(--color-gray-600);
}

.note-preview-content.markdown-body table {
    width: 100%;
    border-collapse: collapse;
    margin: 0 0 1rem 0;
}

.note-preview-content.markdown-body th,
.note-preview-content.markdown-body td {
    padding: 0.5rem;
    border: 1px solid var(--color-gray-200);
    text-align: left;
}

.note-preview-content.markdown-body th {
    background: var(--color-gray-50);
    font-weight: 600;
}

.note-preview-content.markdown-body hr {
    border: none;
    border-top: 1px solid var(--color-gray-200);
    margin: 1.5rem 0;
}

.note-readonly-notice {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem 1rem;
    background: var(--color-gray-50);
    border-top: 1px solid var(--color-gray-200);
    color: var(--color-gray-600);
    font-size: 0.8125rem;
}

.note-readonly-notice i {
    color: var(--color-gray-400);
}

/* Selection menu for creating tasks from note */
.project-note-selection-menu {
    position: fixed;
    z-index: 10000;
    background: var(--color-white);
    border-radius: 8px;
    box-shadow: var(--shadow-lg);
    border: 1px solid var(--color-gray-200);
    padding: 0.25rem;
}

.project-note-selection-menu .selection-menu-btn {
    display: flex;
    align-items: center;
    gap: 0.375rem;
    padding: 0.5rem 0.75rem;
    background: none;
    border: none;
    cursor: pointer;
    font-size: 0.8125rem;
    font-weight: 500;
    color: var(--color-gray-700);
    border-radius: 6px;
    transition: all 0.15s ease;
}

.project-note-selection-menu .selection-menu-btn:hover {
    background: var(--color-gray-100);
    color: var(--color-black);
}

.project-note-selection-menu .selection-menu-btn i {
    font-size: 0.875rem;
}

/* Responsive styles for note tab */
@media (max-width: 768px) {
    .note-content-area {
        min-height: auto;
    }

    .note-editor-panel textarea {
        min-height: 300px;
    }

    .note-preview-content {
        min-height: 200px;
    }
}

/* ========================================
   Dashboard All Tasks Section
   ======================================== */

.all-tasks-section {
    margin-bottom: 2.5rem;
}

.all-tasks-section .section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
}

.all-tasks-section .section-header h2 {
    margin: 0;
}

#toggleFiltersBtn.active {
    background-color: var(--color-black);
    color: var(--color-white);
}

/* Tasks Filter Panel */
.tasks-filter-panel {
    background-color: var(--color-white);
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
    padding: 1.25rem;
    margin-bottom: 1rem;
}

.tasks-filter-panel .filter-row {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    align-items: flex-end;
}

.tasks-filter-panel .filter-row + .filter-row {
    margin-top: 1rem;
}

.tasks-filter-panel .filter-group {
    flex: 1;
    min-width: 150px;
}

.tasks-filter-panel .filter-group label {
    display: block;
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--color-gray-600);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 0.375rem;
}

.tasks-filter-panel .filter-select,
.tasks-filter-panel .filter-input {
    width: 100%;
    padding: 0.5rem 0.75rem;
    border: 1px solid var(--color-gray-300);
    border-radius: var(--border-radius-sm);
    font-size: 0.875rem;
    background-color: var(--color-white);
    transition: border-color 0.15s ease;
}

.tasks-filter-panel .filter-select:focus,
.tasks-filter-panel .filter-input:focus {
    outline: none;
    border-color: var(--color-black);
}

.tasks-filter-panel .filter-actions {
    display: flex;
    gap: 0.5rem;
    padding-bottom: 0;
}

/* Active Filters Indicator */
.active-filters {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-top: 1rem;
    padding-top: 1rem;
    border-top: 1px solid var(--color-gray-100);
}

.active-filters .filter-label {
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--color-gray-500);
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.filter-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.filter-tag {
    display: inline-flex;
    align-items: center;
    padding: 0.25rem 0.625rem;
    background-color: var(--color-gray-100);
    border-radius: 9999px;
    font-size: 0.75rem;
    color: var(--color-gray-700);
}

/* Task Table Container */
.task-table-container {
    max-height: 600px;
    overflow-y: auto;
    overflow-x: auto;
}

.task-table {
    min-width: 800px;
}

.task-table .col-color {
    width: 8px;
    padding: 0.5rem 0.25rem 0.5rem 0.5rem;
}

.task-table .col-name {
    min-width: 200px;
}

.task-table .col-project {
    min-width: 140px;
}

.task-table .col-status {
    width: 120px;
}

.task-table .col-assignees {
    min-width: 180px;
}

.task-table .col-created {
    width: 120px;
    white-space: nowrap;
}

.task-table .col-actions {
    width: 50px;
    text-align: center;
}

.task-color-indicator {
    width: 4px;
    height: 32px;
    border-radius: 2px;
}

.task-link {
    color: var(--color-black);
    text-decoration: none;
    font-weight: 500;
}

.task-link:hover {
    text-decoration: underline;
}

/* Project Badge in Table */
.project-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.375rem;
    padding: 0.25rem 0.5rem;
    border: 1px solid;
    border-radius: var(--border-radius-sm);
    font-size: 0.75rem;
    color: var(--color-gray-700);
    text-decoration: none;
    transition: background-color 0.15s ease;
}

.project-badge:hover {
    background-color: var(--color-gray-50);
}

.project-color-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    flex-shrink: 0;
}

/* Assignee Cell in Table */
.assignee-cell {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.assignee-badges {
    display: flex;
    gap: 0.25rem;
}

.assignee-tag {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 24px;
    height: 24px;
    background-color: var(--color-black);
    color: var(--color-white);
    border-radius: 50%;
    font-size: 0.625rem;
    font-weight: 600;
}

.assignee-empty {
    font-size: 0.8125rem;
    color: var(--color-gray-400);
    font-style: italic;
}

.assignee-select {
    padding: 0.25rem 0.5rem;
    border: 1px solid var(--color-gray-200);
    border-radius: var(--border-radius-sm);
    font-size: 0.75rem;
    background-color: var(--color-white);
    cursor: pointer;
    min-width: 100px;
}

.assignee-select:hover {
    border-color: var(--color-gray-400);
}

.assignee-select:focus {
    outline: none;
    border-color: var(--color-black);
}

/* Task Table Loading & Empty States */
.tasks-loading,
.tasks-empty {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 3rem 1rem;
    color: var(--color-gray-500);
    gap: 0.75rem;
}

.tasks-loading i,
.tasks-empty i {
    font-size: 2rem;
}

.tasks-empty p {
    margin: 0;
    font-size: 0.875rem;
}

/* Ghost button for actions */
.btn-ghost {
    background: transparent;
    border: none;
    padding: 0.375rem 0.5rem;
    color: var(--color-gray-400);
    cursor: pointer;
    border-radius: var(--border-radius-sm);
    transition: all 0.15s ease;
}

.btn-ghost:hover {
    background-color: var(--color-gray-100);
    color: var(--color-black);
}

/* Status badge variants for in-progress */
.badge-in-progress {
    background-color: #3b82f6;
    color: white;
}

.badge-on-hold {
    background-color: #f59e0b;
    color: white;
}

.badge-planned {
    background-color: #8b5cf6;
    color: white;
}

/* Responsive Adjustments for Tasks Table */
@media (max-width: 768px) {
    .all-tasks-section .section-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.75rem;
    }

    .tasks-filter-panel .filter-row {
        flex-direction: column;
    }

    .tasks-filter-panel .filter-group {
        width: 100%;
    }

    .tasks-filter-panel .filter-actions {
        width: 100%;
        justify-content: flex-end;
    }

    .task-table-container {
        max-height: 400px;
    }
}

/* ================================
   Tasks Page Specific Styles
   ================================ */

/* Tasks Statistics Bar - Card Grid */
.tasks-stats-bar {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 1rem;
    margin-bottom: 1.5rem;
}

.tasks-stats-bar .stat-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 1.25rem 1rem;
    background-color: var(--color-white);
    border-radius: var(--border-radius);
    box-shadow: var(--shadow-sm);
    border: 1px solid var(--color-gray-100);
    transition: all 0.2s ease;
}

.tasks-stats-bar .stat-item:hover {
    box-shadow: var(--shadow);
    transform: translateY(-2px);
}

.tasks-stats-bar .stat-number {
    font-size: 2rem;
    font-weight: 700;
    color: var(--color-gray-900);
    line-height: 1.2;
}

.tasks-stats-bar .stat-label {
    font-size: 0.75rem;
    color: var(--color-gray-500);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-top: 0.25rem;
}

/* Stat Card Color Accents */
.tasks-stats-bar .stat-item.stat-total {
    border-top: 3px solid var(--color-gray-900);
}

.tasks-stats-bar .stat-item.stat-new {
    border-top: 3px solid #3b82f6;
}

.tasks-stats-bar .stat-item.stat-new .stat-number {
    color: #3b82f6;
}

.tasks-stats-bar .stat-item.stat-progress {
    border-top: 3px solid #f59e0b;
}

.tasks-stats-bar .stat-item.stat-progress .stat-number {
    color: #f59e0b;
}

.tasks-stats-bar .stat-item.stat-done {
    border-top: 3px solid #22c55e;
}

.tasks-stats-bar .stat-item.stat-done .stat-number {
    color: #22c55e;
}

.tasks-stats-bar .stat-item.stat-overdue {
    border-top: 3px solid #ef4444;
}

.tasks-stats-bar .stat-item.stat-overdue .stat-number {
    color: #ef4444;
}

/* Inline Status Select */
.status-cell {
    position: relative;
}

.status-select {
    appearance: none;
    -webkit-appearance: none;
    -moz-appearance: none;
    padding: 0.25rem 1.5rem 0.25rem 0.5rem;
    font-size: 0.75rem;
    font-weight: 600;
    border-radius: 9999px;
    border: none;
    cursor: pointer;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 0.35rem center;
    background-size: 10px;
    transition: all 0.15s ease;
}

.status-select:hover {
    opacity: 0.9;
}

.status-select:focus {
    outline: none;
    box-shadow: 0 0 0 2px var(--color-gray-300);
}

.status-select-new {
    background-color: #e5e7eb;
    color: #374151;
}

.status-select-in-progress {
    background-color: #3b82f6;
    color: white;
}

.status-select-on-hold {
    background-color: #f59e0b;
    color: white;
}

.status-select-planned {
    background-color: #8b5cf6;
    color: white;
}

.status-select-done {
    background-color: #22c55e;
    color: white;
}

/* Deadline Column Styles */
.deadline-cell {
    white-space: nowrap;
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
}

.deadline-cell.deadline-overdue {
    color: #ef4444;
    font-weight: 600;
}

.deadline-cell.deadline-soon {
    color: #f59e0b;
}

.deadline-none {
    color: var(--color-gray-400);
    font-style: italic;
}

/* Sortable Columns */
.task-table th.sortable {
    cursor: pointer;
    user-select: none;
    transition: background-color 0.15s ease;
}

.task-table th.sortable:hover {
    background-color: var(--color-gray-100);
}

.task-table th.sortable .sort-icon {
    margin-left: 0.25rem;
    font-size: 0.75rem;
    color: var(--color-gray-400);
    transition: transform 0.15s ease;
}

.task-table th.sortable.sort-asc .sort-icon {
    color: var(--color-black);
}

.task-table th.sortable.sort-desc .sort-icon {
    color: var(--color-black);
    transform: rotate(180deg);
}

/* Checkbox Column */
.task-table .col-checkbox {
    width: 40px;
    padding: 0.5rem;
    text-align: center;
}

.task-table .col-checkbox input[type="checkbox"] {
    width: 16px;
    height: 16px;
    cursor: pointer;
}

/* Bulk Actions Panel */
.bulk-actions-panel {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.75rem 1rem;
    margin-bottom: 1rem;
    background-color: #f0f9ff;
    border: 1px solid #bae6fd;
    border-radius: var(--border-radius-sm);
}

.bulk-selection-info {
    display: flex;
    align-items: center;
    gap: 1rem;
    font-size: 0.875rem;
    color: var(--color-gray-700);
}

.bulk-selection-info #selectedCount {
    font-weight: 700;
}

.bulk-actions {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.bulk-actions .filter-select {
    min-width: 180px;
}

/* Section Header Adjustments for Tasks Page */
.all-tasks-section .section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
}

.all-tasks-section .section-header-left {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.all-tasks-section .section-header-right {
    font-size: 0.875rem;
    color: var(--color-gray-500);
}

.results-count {
    font-weight: 500;
}

/* Task Deadline Column */
.task-table .col-deadline {
    width: 130px;
    white-space: nowrap;
}

/* Responsive Tasks Page */
@media (max-width: 1024px) {
    .tasks-stats-bar {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (max-width: 768px) {
    .tasks-stats-bar {
        grid-template-columns: repeat(2, 1fr);
    }

    .tasks-stats-bar .stat-item {
        padding: 1rem 0.75rem;
    }

    .tasks-stats-bar .stat-number {
        font-size: 1.5rem;
    }

    .bulk-actions-panel {
        flex-direction: column;
        gap: 0.75rem;
    }

    .bulk-selection-info {
        flex-wrap: wrap;
        justify-content: center;
    }

    .bulk-actions {
        width: 100%;
        justify-content: center;
    }
}

@media (max-width: 480px) {
    .tasks-stats-bar {
        grid-template-columns: 1fr 1fr;
        gap: 0.75rem;
    }

    .tasks-stats-bar .stat-item:last-child {
        grid-column: span 2;
    }
}

/* Section Header Actions (Button Group) */
.section-header-actions {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

/* Dashboard Task Creation Modal */
#dashboardTaskModal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(0, 0, 0, 0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
}

#dashboardTaskModal .modal-content {
    background-color: var(--color-white);
    border-radius: var(--border-radius);
    box-shadow: var(--shadow-lg);
    width: 100%;
    max-width: 500px;
    max-height: 90vh;
    overflow-y: auto;
}

#dashboardTaskModal .modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.25rem 1.5rem;
    border-bottom: 1px solid var(--color-gray-100);
}

#dashboardTaskModal .modal-header h3 {
    margin: 0;
    font-size: 1.125rem;
    font-weight: 600;
}

#dashboardTaskModal .modal-close {
    background: none;
    border: none;
    font-size: 1.5rem;
    color: var(--color-gray-400);
    cursor: pointer;
    padding: 0;
    line-height: 1;
}

#dashboardTaskModal .modal-close:hover {
    color: var(--color-black);
}

#dashboardTaskModal .modal-body {
    padding: 1.5rem;
}

#dashboardTaskModal .modal-footer {
    display: flex;
    justify-content: flex-end;
    gap: 0.75rem;
    padding: 1rem 1.5rem;
    border-top: 1px solid var(--color-gray-100);
    background-color: var(--color-gray-50);
}

#dashboardTaskModal .form-group {
    margin-bottom: 1rem;
}

#dashboardTaskModal .form-group:last-child {
    margin-bottom: 0;
}

#dashboardTaskModal .form-group label {
    display: block;
    font-weight: 500;
    font-size: 0.875rem;
    margin-bottom: 0.375rem;
    color: var(--color-gray-700);
}

#dashboardTaskModal .form-group label .required {
    color: #ef4444;
}

#dashboardTaskModal .form-input,
#dashboardTaskModal .form-select,
#dashboardTaskModal .form-textarea {
    width: 100%;
    padding: 0.625rem 0.75rem;
    border: 1px solid var(--color-gray-300);
    border-radius: var(--border-radius-sm);
    font-size: 0.875rem;
    transition: border-color 0.15s ease;
}

#dashboardTaskModal .form-input:focus,
#dashboardTaskModal .form-select:focus,
#dashboardTaskModal .form-textarea:focus {
    outline: none;
    border-color: var(--color-black);
}

#dashboardTaskModal .form-textarea {
    resize: vertical;
    min-height: 80px;
}

#dashboardTaskModal .form-color {
    width: 60px;
    height: 38px;
    padding: 0.25rem;
    border: 1px solid var(--color-gray-300);
    border-radius: var(--border-radius-sm);
    cursor: pointer;
}

#dashboardTaskModal .form-row {
    display: flex;
    gap: 1rem;
}

#dashboardTaskModal .form-row .form-group {
    flex: 1;
}

#dashboardTaskModal .form-error {
    margin-top: 1rem;
    padding: 0.75rem;
    background-color: #fef2f2;
    border: 1px solid #fecaca;
    border-radius: var(--border-radius-sm);
    color: #dc2626;
    font-size: 0.875rem;
}

@media (max-width: 576px) {
    #dashboardTaskModal {
        padding: 0;
        align-items: stretch;
    }

    #dashboardTaskModal .modal-content {
        margin: 0;
        max-width: 100%;
        width: 100%;
        height: 100%;
        max-height: 100vh;
        border-radius: 0;
        display: flex;
        flex-direction: column;
    }

    #dashboardTaskModal .modal-header {
        padding: 1rem 1rem;
        padding-top: max(1rem, env(safe-area-inset-top));
        position: sticky;
        top: 0;
        background-color: var(--color-white);
        z-index: 10;
    }

    #dashboardTaskModal .modal-header h3 {
        font-size: 1.25rem;
    }

    #dashboardTaskModal .modal-close {
        width: 40px;
        height: 40px;
        display: flex;
        align-items: center;
        justify-content: center;
        border-radius: 50%;
        background-color: var(--color-gray-100);
        font-size: 1.25rem;
    }

    #dashboardTaskModal .modal-body {
        flex: 1;
        overflow-y: auto;
        padding: 1.25rem 1rem;
        -webkit-overflow-scrolling: touch;
    }

    #dashboardTaskModal .modal-footer {
        position: sticky;
        bottom: 0;
        padding: 1rem;
        padding-bottom: max(1rem, env(safe-area-inset-bottom));
        background-color: var(--color-white);
        border-top: 1px solid var(--color-gray-200);
        box-shadow: 0 -2px 10px rgba(0, 0, 0, 0.05);
    }

    #dashboardTaskModal .modal-footer .btn {
        flex: 1;
        padding: 0.875rem 1rem;
        font-size: 1rem;
    }

    #dashboardTaskModal .form-row {
        flex-direction: column;
        gap: 0;
    }

    #dashboardTaskModal .form-group {
        margin-bottom: 1.25rem;
    }

    #dashboardTaskModal .form-group label {
        font-size: 0.9375rem;
        margin-bottom: 0.5rem;
    }

    #dashboardTaskModal .form-input,
    #dashboardTaskModal .form-select,
    #dashboardTaskModal .form-textarea {
        padding: 0.875rem 1rem;
        font-size: 1rem;
        border-radius: var(--border-radius-sm);
    }

    #dashboardTaskModal .form-textarea {
        min-height: 100px;
    }

    #dashboardTaskModal .form-color {
        width: 100%;
        height: 48px;
    }
}

/* Dark mode for mobile full-screen modal */
@media (max-width: 576px) {
    body.dark-mode #dashboardTaskModal .modal-header {
        background-color: #171717;
    }

    body.dark-mode #dashboardTaskModal .modal-close {
        background-color: #262626;
        color: #e5e5e5;
    }

    body.dark-mode #dashboardTaskModal .modal-footer {
        background-color: #171717;
        border-top-color: rgba(255, 255, 255, 0.1);
        box-shadow: 0 -2px 10px rgba(0, 0, 0, 0.3);
    }
}

/* ============================================
   Project Dashboard Styles
   ============================================ */

.dashboard-container {
    padding: 1.5rem 0;
}

.dashboard-loading {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 4rem 2rem;
    gap: 1rem;
    color: var(--color-gray-500);
}

.dashboard-error {
    color: var(--color-error);
    text-align: center;
    padding: 2rem;
}

/* Dashboard Cards */
.dashboard-cards {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1rem;
    margin-bottom: 2rem;
}

.dashboard-card {
    background: var(--color-white);
    border-radius: var(--border-radius);
    padding: 1.25rem;
    display: flex;
    align-items: center;
    gap: 1rem;
    box-shadow: var(--shadow-sm);
    border: 1px solid var(--color-gray-100);
    position: relative;
    overflow: hidden;
}

.dashboard-card-health {
    background: linear-gradient(135deg, var(--color-white) 0%, #f0fdf4 100%);
}

.dashboard-card-warning.has-warning {
    background: linear-gradient(135deg, var(--color-white) 0%, #fef3c7 100%);
}

.dashboard-card-warning.has-warning .dashboard-card-icon {
    background-color: #fef3c7;
    color: #f59e0b;
}

.dashboard-card-icon {
    width: 48px;
    height: 48px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: var(--color-gray-100);
    color: var(--color-gray-600);
    font-size: 1.25rem;
    flex-shrink: 0;
}

.dashboard-card-health .dashboard-card-icon {
    background-color: #dcfce7;
    color: #22c55e;
}

.dashboard-card-content {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}

.dashboard-card-value {
    font-size: 1.75rem;
    font-weight: 700;
    color: var(--color-gray-900);
    line-height: 1.2;
}

.dashboard-card-label {
    font-size: 0.875rem;
    color: var(--color-gray-500);
}

.dashboard-card-indicator {
    position: absolute;
    top: 0;
    right: 0;
    width: 8px;
    height: 100%;
}

.dashboard-card-indicator.health-excellent {
    background: linear-gradient(to bottom, #22c55e, #16a34a);
}

.dashboard-card-indicator.health-good {
    background: linear-gradient(to bottom, #84cc16, #65a30d);
}

.dashboard-card-indicator.health-fair {
    background: linear-gradient(to bottom, #f59e0b, #d97706);
}

.dashboard-card-indicator.health-poor {
    background: linear-gradient(to bottom, #f97316, #ea580c);
}

.dashboard-card-indicator.health-critical {
    background: linear-gradient(to bottom, #ef4444, #dc2626);
}

/* Dashboard Charts Row */
.dashboard-charts-row {
    display: grid;
    grid-template-columns: 1fr 2fr;
    gap: 1.5rem;
    margin-bottom: 1.5rem;
}

.dashboard-charts-row:last-of-type {
    grid-template-columns: repeat(3, 1fr);
}

.dashboard-chart-container {
    background: var(--color-white);
    border-radius: var(--border-radius);
    padding: 1.25rem;
    box-shadow: var(--shadow-sm);
    border: 1px solid var(--color-gray-100);
}

.dashboard-chart-wide {
    grid-column: span 1;
}

.dashboard-chart-title {
    font-size: 0.9375rem;
    font-weight: 600;
    color: var(--color-gray-700);
    margin-bottom: 1rem;
}

.dashboard-chart-wrapper {
    position: relative;
    height: 220px;
}

/* Dashboard Details Row (Timeline & Deadlines) */
.dashboard-details-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
}

.dashboard-timeline-container,
.dashboard-deadlines-container {
    background: var(--color-white);
    border-radius: var(--border-radius);
    padding: 1.25rem;
    box-shadow: var(--shadow-sm);
    border: 1px solid var(--color-gray-100);
}

.dashboard-section-title {
    font-size: 0.9375rem;
    font-weight: 600;
    color: var(--color-gray-700);
    margin-bottom: 1rem;
    padding-bottom: 0.75rem;
    border-bottom: 1px solid var(--color-gray-100);
}

.dashboard-empty-text {
    color: var(--color-gray-400);
    font-size: 0.875rem;
    text-align: center;
    padding: 2rem 1rem;
}

/* Timeline Styles */
.timeline-list {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.timeline-item {
    display: flex;
    gap: 0.75rem;
    padding: 0.75rem;
    border-radius: var(--border-radius-sm);
    background-color: var(--color-gray-50);
    transition: background-color 0.15s;
}

.timeline-item:hover {
    background-color: var(--color-gray-100);
}

.timeline-marker {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background-color: var(--color-gray-400);
    flex-shrink: 0;
    margin-top: 0.35rem;
}

.timeline-marker.badge-done {
    background-color: #22c55e;
}

.timeline-marker.badge-in_progress {
    background-color: #f59e0b;
}

.timeline-marker.badge-new {
    background-color: #6366f1;
}

.timeline-marker.badge-on_hold {
    background-color: #94a3b8;
}

.timeline-marker.badge-planned {
    background-color: #8b5cf6;
}

.timeline-content {
    flex: 1;
    min-width: 0;
}

.timeline-task-name {
    font-weight: 500;
    color: var(--color-gray-900);
    text-decoration: none;
    display: block;
    margin-bottom: 0.375rem;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.timeline-task-name:hover {
    color: var(--color-black);
    text-decoration: underline;
}

.timeline-change {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 0.375rem;
}

.timeline-arrow {
    font-size: 0.625rem;
    color: var(--color-gray-400);
}

.timeline-meta {
    display: flex;
    gap: 0.75rem;
    font-size: 0.75rem;
    color: var(--color-gray-500);
}

/* Deadline Styles */
.deadline-section {
    margin-bottom: 1rem;
}

.deadline-section:last-child {
    margin-bottom: 0;
}

.deadline-section-title {
    font-size: 0.8125rem;
    font-weight: 600;
    color: var(--color-gray-600);
    margin-bottom: 0.75rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.deadline-overdue .deadline-section-title {
    color: #dc2626;
}

.deadline-upcoming .deadline-section-title {
    color: #6366f1;
}

.deadline-list {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.deadline-item {
    padding: 0.75rem;
    border-radius: var(--border-radius-sm);
    background-color: var(--color-gray-50);
    transition: background-color 0.15s;
}

.deadline-item:hover {
    background-color: var(--color-gray-100);
}

.deadline-task-name {
    font-weight: 500;
    color: var(--color-gray-900);
    text-decoration: none;
    display: block;
    margin-bottom: 0.375rem;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.deadline-task-name:hover {
    color: var(--color-black);
    text-decoration: underline;
}

.deadline-meta {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-size: 0.75rem;
}

.deadline-date {
    color: var(--color-gray-500);
}

.deadline-date.overdue {
    color: #dc2626;
    font-weight: 500;
}

.deadline-date.urgent {
    color: #dc2626;
    font-weight: 500;
}

.deadline-date.soon {
    color: #f59e0b;
    font-weight: 500;
}

/* Badge Small */
.badge-sm {
    font-size: 0.6875rem;
    padding: 0.125rem 0.375rem;
}

/* Responsive Dashboard Styles */
@media (max-width: 1200px) {
    .dashboard-cards {
        grid-template-columns: repeat(2, 1fr);
    }

    .dashboard-charts-row {
        grid-template-columns: 1fr;
    }

    .dashboard-charts-row:last-of-type {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .dashboard-cards {
        grid-template-columns: 1fr;
    }

    .dashboard-charts-row:last-of-type {
        grid-template-columns: 1fr;
    }

    .dashboard-details-row {
        grid-template-columns: 1fr;
    }

    .dashboard-chart-wrapper {
        height: 180px;
    }
}

/* ========================================
   Focus Mode Styles
   ======================================== */

/* Focus Mode Button on Dashboard */
.btn-focus-mode {
    background: linear-gradient(135deg, #1a1a2e 0%, #16213e 100%);
    color: #fff;
    border: none;
    padding: 0.75rem 1.5rem;
    font-weight: 600;
    box-shadow: 0 4px 15px rgba(26, 26, 46, 0.3);
}

.btn-focus-mode:hover {
    background: linear-gradient(135deg, #16213e 0%, #0f3460 100%);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(26, 26, 46, 0.4);
}

.btn-focus-mode i {
    margin-right: 0.25rem;
}

/* Focus Mode Body */
.focus-mode-body {
    background-color: #0a0a0f;
    color: #e5e5e5;
    height: 100vh;
    overflow: hidden;
}

/* Animated Background */
.focus-background {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 0;
    overflow: hidden;
    pointer-events: none;
}

.focus-bg-layer {
    position: absolute;
    width: 150%;
    height: 150%;
    top: -25%;
    left: -25%;
    background: radial-gradient(ellipse at center, rgba(30, 30, 60, 0.4) 0%, transparent 70%);
    animation: focusBgPulse 8s ease-in-out infinite;
}

.focus-bg-layer:nth-child(2) {
    background: radial-gradient(ellipse at 30% 70%, rgba(20, 50, 80, 0.3) 0%, transparent 60%);
    animation-delay: -2.5s;
    animation-duration: 10s;
}

.focus-bg-layer:nth-child(3) {
    background: radial-gradient(ellipse at 70% 30%, rgba(40, 20, 60, 0.25) 0%, transparent 50%);
    animation-delay: -5s;
    animation-duration: 12s;
}

@keyframes focusBgPulse {
    0%, 100% {
        transform: scale(1) rotate(0deg);
        opacity: 0.8;
    }
    50% {
        transform: scale(1.1) rotate(3deg);
        opacity: 1;
    }
}

/* Focus Header */
.focus-header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: 60px;
    background: rgba(15, 15, 25, 0.9);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 1.5rem;
    z-index: 100;
}

.focus-header-left {
    display: flex;
    align-items: center;
}

.focus-brand {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: #fff;
    text-decoration: none;
    transition: opacity 0.2s ease;
}

.focus-brand:hover {
    opacity: 0.8;
}

.focus-brand i {
    font-size: 1.25rem;
    color: #a0a0a0;
}

.focus-brand-name {
    font-size: 1.125rem;
    font-weight: 700;
    letter-spacing: -0.02em;
}

.focus-brand-divider {
    width: 1px;
    height: 20px;
    background: rgba(255, 255, 255, 0.2);
    margin: 0 0.25rem;
}

.focus-brand-mode {
    font-size: 0.875rem;
    font-weight: 500;
    color: #a0a0a0;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.focus-header-right {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.focus-session-indicator {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.75rem;
    color: #a0a0a0;
}

.focus-session-indicator i {
    font-size: 0.5rem;
    color: #22c55e;
    animation: sessionPulse 2s infinite;
}

.focus-session-indicator.session-warning i {
    color: #f59e0b;
}

@keyframes sessionPulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.4; }
}

.focus-filter-toggle {
    background: transparent;
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: #a0a0a0;
    width: 36px;
    height: 36px;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.focus-filter-toggle:hover,
.focus-filter-toggle.active {
    background: rgba(255, 255, 255, 0.1);
    color: #fff;
    border-color: rgba(255, 255, 255, 0.2);
}

.focus-theme-toggle {
    background: transparent;
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: #a0a0a0;
    width: 36px;
    height: 36px;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.focus-theme-toggle:hover {
    background: rgba(255, 255, 255, 0.1);
    color: #fbbf24;
    border-color: rgba(255, 255, 255, 0.2);
}

/* Focus Main Layout */
.focus-main {
    position: relative;
    z-index: 1;
    display: flex;
    justify-content: center;
    gap: 2rem;
    padding: 0 2rem;
    height: calc(100vh - 60px);
    margin-top: 60px;
    max-width: 1400px;
    margin-left: auto;
    margin-right: auto;
    overflow: hidden;
}

/* Pomodoro Timer Panel */
.focus-timer-panel {
    width: 30%;
    flex-shrink: 0;
    padding: 2rem 0;
    overflow: hidden;
}

.pomodoro-container {
    background: rgba(20, 20, 35, 0.8);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: 16px;
    padding: 2rem;
    text-align: center;
    width: 100%;
}

.pomodoro-display {
    position: relative;
    z-index: 1;
    margin-bottom: 1rem;
}

.pomodoro-time {
    font-size: 3.5rem;
    font-weight: 700;
    color: #fff;
    font-variant-numeric: tabular-nums;
    letter-spacing: -0.02em;
}

.pomodoro-label {
    font-size: 0.875rem;
    color: #a0a0a0;
    margin-top: 0.25rem;
    transition: all 0.3s ease;
}

.pomodoro-label.pomodoro-notification {
    color: #22c55e;
    font-weight: 600;
}

.pomodoro-progress {
    position: relative;
    width: 120px;
    height: 120px;
    margin: 0 auto 1.5rem;
}

.pomodoro-ring {
    width: 100%;
    height: 100%;
    transform: rotate(-90deg);
}

.pomodoro-ring-bg {
    fill: none;
    stroke: rgba(255, 255, 255, 0.1);
    stroke-width: 8;
}

.pomodoro-ring-progress {
    fill: none;
    stroke: #fff;
    stroke-width: 8;
    stroke-linecap: round;
    transition: stroke-dashoffset 0.5s ease, stroke 0.3s ease;
}

.pomodoro-controls {
    display: flex;
    justify-content: center;
    gap: 0.75rem;
    margin-bottom: 1.5rem;
}

.pomodoro-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.625rem 1.25rem;
    font-size: 0.875rem;
    font-weight: 600;
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 9999px;
    background: rgba(255, 255, 255, 0.05);
    color: #e5e5e5;
    cursor: pointer;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    gap: 0.5rem;
}

.pomodoro-btn:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: rgba(255, 255, 255, 0.3);
    color: #fff;
    transform: translateY(-1px);
}

.pomodoro-btn:active {
    transform: translateY(0);
}

.pomodoro-btn-main {
    background: #fff;
    border-color: #fff;
    color: #0a0a0f;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.3);
}

.pomodoro-btn-main:hover {
    background: #e5e5e5;
    border-color: #e5e5e5;
    color: #0a0a0f;
    box-shadow: 0 6px 10px -1px rgba(0, 0, 0, 0.4);
}

.pomodoro-settings {
    margin-top: 1rem;
    padding-top: 1rem;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
}

.pomodoro-settings-btn {
    background: transparent;
    border: none;
    color: #666;
    font-size: 0.75rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    width: 100%;
    padding: 0.5rem;
    border-radius: 6px;
    transition: all 0.2s ease;
}

.pomodoro-settings-btn:hover {
    color: #a0a0a0;
    background: rgba(255, 255, 255, 0.05);
}

.pomodoro-settings-panel {
    margin-top: 1rem;
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.pomodoro-setting {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 0.75rem;
}

.pomodoro-setting:last-child {
    margin-bottom: 0;
}

.pomodoro-setting label {
    font-size: 0.75rem;
    color: #a0a0a0;
}

.pomodoro-setting input {
    width: 70px;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: #fff;
    padding: 0.5rem 0.75rem;
    border-radius: 8px;
    text-align: center;
    font-size: 0.875rem;
    font-weight: 500;
    -moz-appearance: textfield;
}

.pomodoro-setting input::-webkit-outer-spin-button,
.pomodoro-setting input::-webkit-inner-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

.pomodoro-setting input:focus {
    outline: none;
    border-color: rgba(255, 255, 255, 0.4);
    background: rgba(255, 255, 255, 0.15);
}

/* Focus Tasks Panel */
.focus-tasks-panel {
    width: 60%;
    min-width: 0;
    height: 100%;
    display: flex;
    flex-direction: column;
    padding: 2rem 0;
}

.focus-tasks-panel::-webkit-scrollbar {
    width: 6px;
}

.focus-tasks-panel::-webkit-scrollbar-track {
    background: transparent;
}

.focus-tasks-panel::-webkit-scrollbar-thumb {
    background-color: rgba(255, 255, 255, 0.2);
    border-radius: 3px;
}

.focus-tasks-panel::-webkit-scrollbar-thumb:hover {
    background-color: rgba(255, 255, 255, 0.3);
}

/* Focus Filter Panel */
.focus-filter-panel {
    background: rgba(20, 20, 35, 0.8);
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: 12px;
    padding: 1rem;
    margin-bottom: 1rem;
}

.focus-filter-row {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
    align-items: flex-end;
}

.focus-filter-group {
    flex: 1;
    min-width: 150px;
}

.focus-filter-group label {
    display: block;
    font-size: 0.75rem;
    color: #666;
    margin-bottom: 0.375rem;
}

.focus-filter-select,
.focus-filter-input {
    width: 100%;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: #e5e5e5;
    padding: 0.5rem 0.75rem;
    border-radius: 8px;
    font-size: 0.875rem;
}

.focus-filter-select:focus,
.focus-filter-input:focus {
    outline: none;
    border-color: rgba(255, 255, 255, 0.2);
}

.focus-filter-select option {
    background: #1a1a2e;
    color: #e5e5e5;
}

.focus-filter-actions {
    display: flex;
    gap: 0.5rem;
}

.focus-btn {
    padding: 0.5rem 1rem;
    border-radius: 8px;
    font-size: 0.875rem;
    font-weight: 500;
    cursor: pointer;
    border: 1px solid rgba(255, 255, 255, 0.1);
    background: rgba(255, 255, 255, 0.05);
    color: #a0a0a0;
    transition: all 0.2s ease;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

.focus-btn:hover {
    background: rgba(255, 255, 255, 0.1);
    color: #fff;
}

.focus-btn-primary {
    background: #fff;
    color: #0a0a0f;
    border-color: #fff;
}

.focus-btn-primary:hover {
    background: #e5e5e5;
    color: #0a0a0f;
}

/* Focus Task Table */
.focus-task-table-container {
    background: rgba(20, 20, 35, 0.8);
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: 12px;
    overflow: hidden;
    flex: 1;
    overflow-y: auto;
    min-height: 0;
}

.focus-task-table {
    width: 100%;
    border-collapse: collapse;
    min-width: 800px;
}

.focus-task-table thead {
    position: sticky;
    top: 0;
    z-index: 10;
}

.focus-task-table th {
    background: rgba(30, 30, 50, 0.95);
    padding: 0.75rem 1rem;
    text-align: left;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: #a0a0a0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.focus-task-table td {
    padding: 0.75rem 1rem;
    font-size: 0.875rem;
    color: #e0e0e0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    vertical-align: middle;
}

.focus-task-table .col-color {
    width: 8px;
    padding: 0.5rem 0.25rem 0.5rem 0.75rem;
}

.focus-task-table .col-name {
    min-width: 200px;
}

.focus-task-table .col-project {
    min-width: 140px;
}

.focus-task-table .col-status {
    width: 130px;
}

.focus-task-table .col-assignees {
    min-width: 150px;
}

.focus-task-table .col-created {
    width: 110px;
    white-space: nowrap;
}

.focus-task-table .col-actions {
    width: 50px;
    text-align: center;
}

.focus-task-table .task-color-indicator {
    width: 4px;
    height: 32px;
    border-radius: 2px;
}

.focus-task-table .task-link {
    color: #fff;
    text-decoration: none;
    font-weight: 500;
    transition: color 0.15s ease;
}

.focus-task-table .task-link:hover {
    color: #60a5fa;
    text-decoration: underline;
}

.focus-task-table .project-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.375rem;
    padding: 0.25rem 0.5rem;
    border: 1px solid;
    border-radius: 6px;
    font-size: 0.75rem;
    color: #a0a0a0;
    text-decoration: none;
    transition: background-color 0.15s ease;
}

.focus-task-table .project-badge:hover {
    background-color: rgba(255, 255, 255, 0.05);
}

.focus-task-table .project-color-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    flex-shrink: 0;
}

/* Assignee styles for focus table */
.focus-task-table .assignee-badges {
    display: flex;
    gap: 0.25rem;
}

.focus-task-table .assignee-tag {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 24px;
    height: 24px;
    background-color: rgba(255, 255, 255, 0.1);
    color: #fff;
    border-radius: 50%;
    font-size: 0.625rem;
    font-weight: 600;
}

.focus-task-table .assignee-empty {
    font-size: 0.8125rem;
    color: #666;
    font-style: italic;
}

/* Focus task row styles */
.focus-task-row {
    transition: background-color 0.15s ease;
}

.focus-task-row:hover {
    background-color: rgba(255, 255, 255, 0.03);
}

.focus-task-row.focus-task-updated {
    background-color: rgba(34, 197, 94, 0.1);
}

.focus-task-table tbody tr:last-child td {
    border-bottom: none;
}

.focus-task-status {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: #a0a0a0;
    padding: 0.375rem 0.75rem;
    border-radius: 6px;
    font-size: 0.75rem;
    cursor: pointer;
}

.focus-task-status:focus {
    outline: none;
    border-color: rgba(255, 255, 255, 0.2);
}

.focus-task-status option {
    background: #1a1a2e;
}

.focus-task-status-new {
    background: rgba(59, 130, 246, 0.15);
    border-color: rgba(59, 130, 246, 0.3);
    color: #60a5fa;
}

.focus-task-status-in-progress {
    background: rgba(245, 158, 11, 0.15);
    border-color: rgba(245, 158, 11, 0.3);
    color: #fbbf24;
}

.focus-task-status-on-hold {
    background: rgba(239, 68, 68, 0.15);
    border-color: rgba(239, 68, 68, 0.3);
    color: #f87171;
}

.focus-task-status-planned {
    background: rgba(139, 92, 246, 0.15);
    border-color: rgba(139, 92, 246, 0.3);
    color: #a78bfa;
}

.focus-task-status-done {
    background: rgba(34, 197, 94, 0.15);
    border-color: rgba(34, 197, 94, 0.3);
    color: #4ade80;
}

.focus-task-view-btn {
    background: transparent;
    border: none;
    color: #666;
    cursor: pointer;
    padding: 0.5rem;
    border-radius: 6px;
    transition: all 0.2s ease;
}

.focus-task-view-btn:hover {
    color: #fff;
    background: rgba(255, 255, 255, 0.1);
}

/* Focus Loading and Empty States */
.focus-loading,
.focus-empty {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 1rem;
    padding: 3rem;
    color: #666;
}

.focus-loading i,
.focus-empty i {
    font-size: 2rem;
}

.focus-empty i {
    color: #22c55e;
}

/* Focus Modal */
.focus-modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(4px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    padding: 2rem;
}

.focus-modal {
    background: #1a1a2e;
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 16px;
    width: 100%;
    max-width: 480px;
    max-height: 80vh;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.focus-modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.25rem 1.5rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.focus-modal-header h3 {
    font-size: 1.125rem;
    font-weight: 600;
    color: #fff;
    margin: 0;
}

.focus-modal-close {
    background: transparent;
    border: none;
    color: #666;
    font-size: 1.5rem;
    cursor: pointer;
    padding: 0.25rem;
    line-height: 1;
    transition: color 0.2s ease;
}

.focus-modal-close:hover {
    color: #fff;
}

.focus-modal-body {
    padding: 1.5rem;
    overflow-y: auto;
}

.focus-modal-field {
    margin-bottom: 1.25rem;
}

.focus-modal-field:last-child {
    margin-bottom: 0;
}

.focus-modal-field label {
    display: block;
    font-size: 0.75rem;
    color: #666;
    margin-bottom: 0.375rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.focus-modal-field span,
.focus-modal-field p {
    color: #e5e5e5;
    font-size: 0.9375rem;
}

.focus-modal-field p {
    line-height: 1.6;
    margin: 0;
}

.focus-modal-footer {
    display: flex;
    justify-content: flex-end;
    gap: 0.75rem;
    padding: 1rem 1.5rem;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
}

/* Focus Mode Tabs */
.focus-tabs {
    display: flex;
    gap: 0;
    margin-bottom: 1rem;
    background: rgba(255, 255, 255, 0.03);
    border-radius: 0.75rem;
    padding: 0.25rem;
}

.focus-tab {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.75rem 1rem;
    background: transparent;
    border: none;
    color: rgba(255, 255, 255, 0.5);
    font-size: 0.875rem;
    font-weight: 500;
    cursor: pointer;
    border-radius: 0.5rem;
    transition: all 0.2s ease;
}

.focus-tab:hover {
    color: rgba(255, 255, 255, 0.8);
    background: rgba(255, 255, 255, 0.05);
}

.focus-tab.active {
    color: #fff;
    background: rgba(255, 255, 255, 0.1);
}

.focus-tab i {
    font-size: 0.875rem;
}

.focus-tab-content {
    display: none;
    flex-direction: column;
    flex: 1;
    min-height: 0;
}

.focus-tab-content.active {
    display: flex;
}

/* Focus Mode Task Selection Checkbox */
.focus-task-table .col-select {
    width: 40px;
    padding: 0.75rem 0.5rem 0.75rem 1rem;
}

.focus-task-checkbox {
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
}

.focus-task-checkbox input {
    display: none;
}

.focus-task-checkbox-mark {
    width: 18px;
    height: 18px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-radius: 4px;
    position: relative;
    transition: all 0.2s ease;
}

.focus-task-checkbox input:checked + .focus-task-checkbox-mark {
    background: #3b82f6;
    border-color: #3b82f6;
}

.focus-task-checkbox input:checked + .focus-task-checkbox-mark::after {
    content: '';
    position: absolute;
    left: 5px;
    top: 2px;
    width: 4px;
    height: 8px;
    border: solid #fff;
    border-width: 0 2px 2px 0;
    transform: rotate(45deg);
}

.focus-task-checkbox:hover .focus-task-checkbox-mark {
    border-color: rgba(255, 255, 255, 0.5);
}

/* Focus Board View */
.focus-board-header {
    display: flex;
    justify-content: flex-end;
    padding: 0 0 1rem 0;
}

.focus-board-actions {
    display: flex;
    gap: 0.5rem;
}

.focus-board-container {
    display: flex;
    gap: 1rem;
    flex: 1;
    min-height: 0;
    overflow-x: auto;
}

.focus-board-unassigned {
    flex-shrink: 0;
    width: 280px;
    background: rgba(255, 255, 255, 0.03);
    border-radius: 0.75rem;
    padding: 1rem;
    display: flex;
    flex-direction: column;
    max-height: 100%;
}

.focus-board-unassigned-header {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 1rem;
    padding-bottom: 0.75rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    color: rgba(255, 255, 255, 0.7);
    font-size: 0.875rem;
    font-weight: 500;
}

.focus-board-unassigned-header i {
    color: rgba(255, 255, 255, 0.4);
}

.focus-board-unassigned-count {
    background: rgba(255, 255, 255, 0.1);
    padding: 0.125rem 0.5rem;
    border-radius: 1rem;
    font-size: 0.75rem;
    margin-left: auto;
}

.focus-board-unassigned-tasks {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    overflow-y: auto;
    flex: 1;
}

.focus-board {
    display: flex;
    gap: 1rem;
    flex: 1;
    min-width: min-content;
}

.focus-board-column {
    flex-shrink: 0;
    width: 280px;
    background: rgba(255, 255, 255, 0.03);
    border-radius: 0.75rem;
    padding: 1rem;
    display: flex;
    flex-direction: column;
    max-height: 100%;
}

.focus-board-column-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 1rem;
    padding-bottom: 0.75rem;
    border-bottom: 2px solid;
}

.focus-board-column-title {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.875rem;
    font-weight: 500;
    color: rgba(255, 255, 255, 0.9);
}

.focus-board-column-color {
    width: 12px;
    height: 12px;
    border-radius: 3px;
}

.focus-board-column-count {
    background: rgba(255, 255, 255, 0.1);
    padding: 0.125rem 0.5rem;
    border-radius: 1rem;
    font-size: 0.75rem;
    color: rgba(255, 255, 255, 0.6);
}

.focus-board-column-actions {
    display: flex;
    gap: 0.25rem;
    opacity: 0;
    transition: opacity 0.2s ease;
}

.focus-board-column:hover .focus-board-column-actions {
    opacity: 1;
}

.focus-board-column-action {
    width: 28px;
    height: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: transparent;
    border: none;
    color: rgba(255, 255, 255, 0.5);
    cursor: pointer;
    border-radius: 4px;
    transition: all 0.2s ease;
}

.focus-board-column-action:hover {
    color: rgba(255, 255, 255, 0.9);
    background: rgba(255, 255, 255, 0.1);
}

.focus-board-column-action-danger:hover {
    color: #ef4444;
    background: rgba(239, 68, 68, 0.1);
}

.focus-board-column-tasks {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    overflow-y: auto;
    flex: 1;
}

/* Focus Board Task Cards */
.focus-board-task-card {
    background: rgba(255, 255, 255, 0.05);
    border-radius: 0.5rem;
    padding: 0.75rem;
    transition: all 0.2s ease;
}

.focus-board-task-card:hover {
    background: rgba(255, 255, 255, 0.08);
}

.focus-board-task-header {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 0.5rem;
}

.focus-board-task-color {
    width: 10px;
    height: 10px;
    border-radius: 2px;
}

.focus-board-task-status {
    font-size: 0.6875rem;
    padding: 0.125rem 0.375rem;
    border-radius: 3px;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.025em;
}

.focus-board-task-status-new {
    background: rgba(107, 114, 128, 0.2);
    color: #9ca3af;
}

.focus-board-task-status-in-progress {
    background: rgba(59, 130, 246, 0.2);
    color: #60a5fa;
}

.focus-board-task-status-on-hold {
    background: rgba(234, 179, 8, 0.2);
    color: #facc15;
}

.focus-board-task-status-planned {
    background: rgba(168, 85, 247, 0.2);
    color: #c084fc;
}

.focus-board-task-status-done {
    background: rgba(34, 197, 94, 0.2);
    color: #4ade80;
}

.focus-board-task-name {
    margin-bottom: 0.5rem;
}

.focus-board-task-name a {
    color: rgba(255, 255, 255, 0.9);
    text-decoration: none;
    font-size: 0.875rem;
    font-weight: 500;
    line-height: 1.4;
    display: block;
}

.focus-board-task-name a:hover {
    color: #fff;
    text-decoration: underline;
}

.focus-board-task-project {
    display: flex;
    align-items: center;
    gap: 0.375rem;
    font-size: 0.75rem;
    color: rgba(255, 255, 255, 0.5);
    margin-bottom: 0.75rem;
}

.focus-board-task-project .project-color-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
}

.focus-board-task-actions {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding-top: 0.5rem;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
}

.focus-board-task-column-select {
    flex: 1;
    background: rgba(0, 0, 0, 0.2);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 4px;
    color: rgba(255, 255, 255, 0.7);
    padding: 0.375rem 0.5rem;
    font-size: 0.75rem;
    cursor: pointer;
}

.focus-board-task-column-select:focus {
    outline: none;
    border-color: rgba(59, 130, 246, 0.5);
}

.focus-board-task-column-select option {
    background: #1f2937;
    color: #fff;
}

.focus-board-task-remove {
    width: 28px;
    height: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: transparent;
    border: none;
    color: rgba(255, 255, 255, 0.4);
    cursor: pointer;
    border-radius: 4px;
    transition: all 0.2s ease;
}

.focus-board-task-remove:hover {
    color: #ef4444;
    background: rgba(239, 68, 68, 0.1);
}

/* Focus Board Empty State */
.focus-board-empty {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 3rem;
    color: rgba(255, 255, 255, 0.4);
    text-align: center;
}

.focus-board-empty i {
    font-size: 3rem;
    margin-bottom: 1rem;
    opacity: 0.5;
}

.focus-board-empty p {
    font-size: 0.9375rem;
    margin: 0;
}

/* Focus Column Modal */
.focus-modal-sm {
    max-width: 400px;
}

.focus-color-picker {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.focus-color-picker input[type="color"] {
    width: 40px;
    height: 40px;
    padding: 0;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    background: transparent;
}

.focus-color-picker input[type="color"]::-webkit-color-swatch-wrapper {
    padding: 0;
}

.focus-color-picker input[type="color"]::-webkit-color-swatch {
    border: 2px solid rgba(255, 255, 255, 0.1);
    border-radius: 6px;
}

.focus-color-picker span {
    color: rgba(255, 255, 255, 0.6);
    font-family: monospace;
    font-size: 0.875rem;
}

/* Focus Mode Light Theme Adjustments for Tabs and Board */
.focus-mode-light .focus-tabs {
    background: rgba(0, 0, 0, 0.03);
}

.focus-mode-light .focus-tab {
    color: rgba(0, 0, 0, 0.5);
}

.focus-mode-light .focus-tab:hover {
    color: rgba(0, 0, 0, 0.8);
    background: rgba(0, 0, 0, 0.05);
}

.focus-mode-light .focus-tab.active {
    color: #000;
    background: rgba(0, 0, 0, 0.1);
}

.focus-mode-light .focus-task-checkbox-mark {
    border-color: rgba(0, 0, 0, 0.3);
}

.focus-mode-light .focus-task-checkbox:hover .focus-task-checkbox-mark {
    border-color: rgba(0, 0, 0, 0.5);
}

.focus-mode-light .focus-board-unassigned,
.focus-mode-light .focus-board-column {
    background: rgba(0, 0, 0, 0.03);
}

.focus-mode-light .focus-board-unassigned-header {
    color: rgba(0, 0, 0, 0.7);
    border-bottom-color: rgba(0, 0, 0, 0.05);
}

.focus-mode-light .focus-board-unassigned-header i {
    color: rgba(0, 0, 0, 0.4);
}

.focus-mode-light .focus-board-unassigned-count,
.focus-mode-light .focus-board-column-count {
    background: rgba(0, 0, 0, 0.1);
    color: rgba(0, 0, 0, 0.6);
}

.focus-mode-light .focus-board-column-title {
    color: rgba(0, 0, 0, 0.9);
}

.focus-mode-light .focus-board-column-action {
    color: rgba(0, 0, 0, 0.5);
}

.focus-mode-light .focus-board-column-action:hover {
    color: rgba(0, 0, 0, 0.9);
    background: rgba(0, 0, 0, 0.1);
}

.focus-mode-light .focus-board-task-card {
    background: rgba(0, 0, 0, 0.05);
}

.focus-mode-light .focus-board-task-card:hover {
    background: rgba(0, 0, 0, 0.08);
}

.focus-mode-light .focus-board-task-name a {
    color: rgba(0, 0, 0, 0.9);
}

.focus-mode-light .focus-board-task-name a:hover {
    color: #000;
}

.focus-mode-light .focus-board-task-project {
    color: rgba(0, 0, 0, 0.5);
}

.focus-mode-light .focus-board-task-actions {
    border-top-color: rgba(0, 0, 0, 0.05);
}

.focus-mode-light .focus-board-task-column-select {
    background: rgba(255, 255, 255, 0.8);
    border-color: rgba(0, 0, 0, 0.1);
    color: rgba(0, 0, 0, 0.7);
}

.focus-mode-light .focus-board-task-column-select option {
    background: #fff;
    color: #000;
}

.focus-mode-light .focus-board-task-remove {
    color: rgba(0, 0, 0, 0.4);
}

.focus-mode-light .focus-board-empty {
    color: rgba(0, 0, 0, 0.4);
}

.focus-mode-light .focus-color-picker input[type="color"]::-webkit-color-swatch {
    border-color: rgba(0, 0, 0, 0.1);
}

.focus-mode-light .focus-color-picker span {
    color: rgba(0, 0, 0, 0.6);
}

/* Focus Mode Responsive */
@media (max-width: 900px) {
    .focus-main {
        flex-direction: column;
        align-items: center;
        padding: 1rem;
        height: auto;
        min-height: calc(100vh - 60px);
        overflow: visible;
    }

    .focus-timer-panel {
        width: 100%;
        max-width: 400px;
        padding: 0;
        margin-bottom: 1rem;
        overflow: visible;
    }

    .focus-tasks-panel {
        width: 100%;
        height: auto;
        overflow: visible;
        padding: 0;
    }

    .pomodoro-container {
        display: flex;
        flex-wrap: wrap;
        align-items: center;
        justify-content: center;
        gap: 1.5rem;
        padding: 1.5rem;
    }

    .pomodoro-display {
        margin-bottom: 0;
    }

    .pomodoro-time {
        font-size: 2.5rem;
    }

    .pomodoro-progress {
        width: 80px;
        height: 80px;
        margin: 0;
    }

    .pomodoro-settings {
        width: 100%;
        border-top: 1px solid rgba(255, 255, 255, 0.05);
        margin-top: 0;
    }

    .focus-brand-name {
        display: none;
    }

    .focus-brand-divider {
        display: none;
    }
}

@media (max-width: 600px) {
    .focus-filter-row {
        flex-direction: column;
    }

    .focus-filter-group {
        min-width: 100%;
    }

    .focus-task-header {
        flex-direction: column;
        gap: 0.5rem;
    }

    .focus-task-project {
        align-self: flex-start;
    }
}

/* ==========================================
   Focus Mode Light Theme
   ========================================== */
.focus-mode-light.focus-mode-body {
    background-color: #fafafa;
    color: #171717;
}

/* Light mode animated background */
.focus-mode-light .focus-background {
    opacity: 0.5;
}

.focus-mode-light .focus-bg-layer {
    background: radial-gradient(ellipse at center, rgba(200, 200, 220, 0.4) 0%, transparent 70%);
}

.focus-mode-light .focus-bg-layer:nth-child(2) {
    background: radial-gradient(ellipse at 30% 70%, rgba(180, 200, 220, 0.3) 0%, transparent 60%);
}

.focus-mode-light .focus-bg-layer:nth-child(3) {
    background: radial-gradient(ellipse at 70% 30%, rgba(200, 180, 220, 0.25) 0%, transparent 50%);
}

/* Light mode header */
.focus-mode-light .focus-header {
    background: rgba(255, 255, 255, 0.9);
    border-bottom: 1px solid rgba(0, 0, 0, 0.08);
}

.focus-mode-light .focus-brand {
    color: #171717;
}

.focus-mode-light .focus-brand i {
    color: #525252;
}

.focus-mode-light .focus-brand-divider {
    background: rgba(0, 0, 0, 0.15);
}

.focus-mode-light .focus-brand-mode {
    color: #525252;
}

.focus-mode-light .focus-session-indicator {
    color: #525252;
}

.focus-mode-light .focus-filter-toggle,
.focus-mode-light .focus-theme-toggle {
    border-color: rgba(0, 0, 0, 0.1);
    color: #525252;
}

.focus-mode-light .focus-filter-toggle:hover,
.focus-mode-light .focus-filter-toggle.active,
.focus-mode-light .focus-theme-toggle:hover {
    background: rgba(0, 0, 0, 0.05);
    border-color: rgba(0, 0, 0, 0.15);
    color: #171717;
}

.focus-mode-light .focus-theme-toggle:hover {
    color: #6366f1;
}

/* Light mode Pomodoro timer */
.focus-mode-light .pomodoro-container {
    background: rgba(255, 255, 255, 0.9);
    border-color: rgba(0, 0, 0, 0.08);
}

.focus-mode-light .pomodoro-time {
    color: #171717;
}

.focus-mode-light .pomodoro-label {
    color: #525252;
}

.focus-mode-light .pomodoro-label.pomodoro-notification {
    color: #16a34a;
}

.focus-mode-light .pomodoro-ring-bg {
    stroke: rgba(0, 0, 0, 0.1);
}

.focus-mode-light .pomodoro-ring-progress {
    stroke: #171717;
}

.focus-mode-light .pomodoro-btn {
    border-color: rgba(0, 0, 0, 0.15);
    background: rgba(0, 0, 0, 0.03);
    color: #525252;
}

.focus-mode-light .pomodoro-btn:hover {
    background: rgba(0, 0, 0, 0.08);
    border-color: rgba(0, 0, 0, 0.2);
    color: #171717;
}

.focus-mode-light .pomodoro-btn-main {
    background: #171717;
    border-color: #171717;
    color: #fff;
}

.focus-mode-light .pomodoro-btn-main:hover {
    background: #262626;
    border-color: #262626;
    color: #fff;
}

.focus-mode-light .pomodoro-settings {
    border-top-color: rgba(0, 0, 0, 0.08);
}

.focus-mode-light .pomodoro-settings-btn {
    color: #737373;
}

.focus-mode-light .pomodoro-settings-btn:hover {
    color: #525252;
    background: rgba(0, 0, 0, 0.05);
}

.focus-mode-light .pomodoro-setting label {
    color: #525252;
}

.focus-mode-light .pomodoro-setting input {
    background: rgba(0, 0, 0, 0.03);
    border-color: rgba(0, 0, 0, 0.15);
    color: #171717;
}

.focus-mode-light .pomodoro-setting input:focus {
    border-color: rgba(0, 0, 0, 0.3);
    background: rgba(0, 0, 0, 0.05);
}

/* Light mode task panel scrollbar */
.focus-mode-light .focus-tasks-panel {
    scrollbar-color: rgba(0, 0, 0, 0.2) transparent;
}

.focus-mode-light .focus-tasks-panel::-webkit-scrollbar-thumb {
    background-color: rgba(0, 0, 0, 0.2);
}

.focus-mode-light .focus-tasks-panel::-webkit-scrollbar-thumb:hover {
    background-color: rgba(0, 0, 0, 0.3);
}

/* Light mode filter panel */
.focus-mode-light .focus-filter-panel {
    background: rgba(255, 255, 255, 0.9);
    border-color: rgba(0, 0, 0, 0.08);
}

.focus-mode-light .focus-filter-group label {
    color: #737373;
}

.focus-mode-light .focus-filter-select,
.focus-mode-light .focus-filter-input {
    background: rgba(0, 0, 0, 0.03);
    border-color: rgba(0, 0, 0, 0.1);
    color: #171717;
}

.focus-mode-light .focus-filter-select:focus,
.focus-mode-light .focus-filter-input:focus {
    border-color: rgba(0, 0, 0, 0.2);
}

.focus-mode-light .focus-filter-select option {
    background: #fff;
    color: #171717;
}

.focus-mode-light .focus-btn {
    border-color: rgba(0, 0, 0, 0.1);
    background: rgba(0, 0, 0, 0.03);
    color: #525252;
}

.focus-mode-light .focus-btn:hover {
    background: rgba(0, 0, 0, 0.08);
    color: #171717;
}

.focus-mode-light .focus-btn-primary {
    background: #171717;
    color: #fff;
    border-color: #171717;
}

.focus-mode-light .focus-btn-primary:hover {
    background: #262626;
    color: #fff;
}

/* Light mode task table */
.focus-mode-light .focus-task-table-container {
    background: rgba(255, 255, 255, 0.95);
    border-color: rgba(0, 0, 0, 0.1);
}

.focus-mode-light .focus-task-table th {
    background: rgba(245, 245, 245, 0.98);
    color: #525252;
    border-bottom-color: rgba(0, 0, 0, 0.1);
}

.focus-mode-light .focus-task-table td {
    color: #374151;
    border-bottom-color: rgba(0, 0, 0, 0.06);
}

.focus-mode-light .focus-task-row:hover {
    background-color: rgba(0, 0, 0, 0.02);
}

.focus-mode-light .focus-task-row.focus-task-updated {
    background-color: rgba(22, 163, 74, 0.1);
}

.focus-mode-light .focus-task-table .task-link {
    color: #171717;
}

.focus-mode-light .focus-task-table .task-link:hover {
    color: #2563eb;
}

.focus-mode-light .focus-task-table .project-badge {
    color: #525252;
}

.focus-mode-light .focus-task-table .project-badge:hover {
    background-color: rgba(0, 0, 0, 0.03);
}

.focus-mode-light .focus-task-table .assignee-tag {
    background-color: #262626;
    color: #fff;
}

.focus-mode-light .focus-task-table .assignee-empty {
    color: #9ca3af;
}

.focus-mode-light .focus-task-status {
    background: rgba(0, 0, 0, 0.03);
    border-color: rgba(0, 0, 0, 0.1);
    color: #525252;
}

.focus-mode-light .focus-task-status:focus {
    border-color: rgba(0, 0, 0, 0.2);
}

.focus-mode-light .focus-task-status option {
    background: #fff;
}

/* Light mode status badges - maintain visibility */
.focus-mode-light .focus-task-status-new {
    background: rgba(59, 130, 246, 0.12);
    border-color: rgba(59, 130, 246, 0.25);
    color: #2563eb;
}

.focus-mode-light .focus-task-status-in-progress {
    background: rgba(245, 158, 11, 0.12);
    border-color: rgba(245, 158, 11, 0.25);
    color: #d97706;
}

.focus-mode-light .focus-task-status-on-hold {
    background: rgba(239, 68, 68, 0.12);
    border-color: rgba(239, 68, 68, 0.25);
    color: #dc2626;
}

.focus-mode-light .focus-task-status-planned {
    background: rgba(139, 92, 246, 0.12);
    border-color: rgba(139, 92, 246, 0.25);
    color: #7c3aed;
}

.focus-mode-light .focus-task-status-done {
    background: rgba(34, 197, 94, 0.12);
    border-color: rgba(34, 197, 94, 0.25);
    color: #16a34a;
}

.focus-mode-light .focus-task-view-btn {
    color: #737373;
}

.focus-mode-light .focus-task-view-btn:hover {
    color: #171717;
    background: rgba(0, 0, 0, 0.05);
}

/* Light mode loading and empty states */
.focus-mode-light .focus-loading,
.focus-mode-light .focus-empty {
    color: #737373;
}

.focus-mode-light .focus-empty i {
    color: #16a34a;
}

/* Light mode modal */
.focus-mode-light .focus-modal-overlay {
    background: rgba(255, 255, 255, 0.8);
}

.focus-mode-light .focus-modal {
    background: #fff;
    border-color: rgba(0, 0, 0, 0.1);
}

.focus-mode-light .focus-modal-header {
    border-bottom-color: rgba(0, 0, 0, 0.08);
}

.focus-mode-light .focus-modal-header h3 {
    color: #171717;
}

.focus-mode-light .focus-modal-close {
    color: #737373;
}

.focus-mode-light .focus-modal-close:hover {
    color: #171717;
}

.focus-mode-light .focus-modal-field label {
    color: #737373;
}

.focus-mode-light .focus-modal-field span,
.focus-mode-light .focus-modal-field p {
    color: #171717;
}

.focus-mode-light .focus-modal-footer {
    border-top-color: rgba(0, 0, 0, 0.08);
}

/* ==================== Global Dark Mode ==================== */

/* Base body styles */
body.dark-mode {
    background-color: #0a0a0f;
    color: #e5e5e5;
}

/* Navbar dark mode */
body.dark-mode .navbar {
    background-color: rgba(23, 23, 23, 0.95);
    border-bottom-color: rgba(255, 255, 255, 0.1);
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.3);
}

body.dark-mode .navbar-brand {
    color: #fafafa;
}

body.dark-mode .navbar-brand i {
    color: #a3a3a3;
}

body.dark-mode .navbar-link {
    color: #a3a3a3;
}

body.dark-mode .navbar-link:hover {
    color: #fafafa;
    background-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .navbar-link.active {
    color: #171717;
    background-color: #fafafa;
}

body.dark-mode .navbar-link.active:hover {
    background-color: #e5e5e5;
}

body.dark-mode .navbar-divider {
    background-color: rgba(255, 255, 255, 0.1);
}

/* Profile dropdown dark mode */
body.dark-mode .profile-trigger {
    background: #262626;
    border-color: rgba(255, 255, 255, 0.1);
    color: #fafafa;
}

body.dark-mode .profile-trigger:hover {
    background-color: #404040;
    border-color: rgba(255, 255, 255, 0.2);
}

body.dark-mode .profile-name {
    color: #e5e5e5;
}

body.dark-mode .profile-trigger i {
    color: #a3a3a3;
}

body.dark-mode .dropdown-menu {
    background-color: #262626;
    border-color: rgba(255, 255, 255, 0.1);
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.5);
}

body.dark-mode .dropdown-header {
    border-bottom-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .dropdown-user-name {
    color: #fafafa;
}

body.dark-mode .dropdown-user-role {
    color: #737373;
}

body.dark-mode .dropdown-item {
    color: #e5e5e5;
}

body.dark-mode .dropdown-item:hover {
    background-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .dropdown-divider {
    background-color: rgba(255, 255, 255, 0.1);
}

/* Nav dropdown dark mode */
body.dark-mode .nav-dropdown-trigger {
    color: #a3a3a3;
}

body.dark-mode .nav-dropdown-trigger:hover {
    color: #fafafa;
    background-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .nav-dropdown-trigger.active {
    color: #000000;
    background-color: #fafafa;
}

body.dark-mode .nav-dropdown-trigger.active:hover {
    background-color: #e5e5e5;
}

body.dark-mode .nav-dropdown-menu {
    background-color: #171717;
    border-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .nav-dropdown-menu .dropdown-item {
    color: #e5e5e5;
}

body.dark-mode .nav-dropdown-menu .dropdown-item i {
    color: #737373;
}

body.dark-mode .nav-dropdown-menu .dropdown-item:hover {
    background-color: rgba(255, 255, 255, 0.1);
    color: #fafafa;
}

body.dark-mode .nav-dropdown-menu .dropdown-item:hover i {
    color: #a3a3a3;
}

body.dark-mode .nav-dropdown-menu .dropdown-item.active {
    background-color: #fafafa;
    color: #000000;
}

body.dark-mode .nav-dropdown-menu .dropdown-item.active i {
    color: #000000;
}

body.dark-mode .nav-dropdown-menu .dropdown-item.active:hover {
    background-color: #e5e5e5;
}

/* Mobile menu divider dark mode */
body.dark-mode .mobile-menu-divider::before,
body.dark-mode .mobile-menu-divider::after {
    background-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .mobile-menu-divider span {
    color: #525252;
}

/* Mobile menu button dark mode */
body.dark-mode .mobile-menu-button {
    color: #d4d4d4;
}

body.dark-mode .mobile-menu-button:hover {
    background-color: rgba(255, 255, 255, 0.1);
    color: #fafafa;
}

body.dark-mode .mobile-menu-button i {
    color: #737373;
}

body.dark-mode .mobile-menu-button:hover i {
    color: #a3a3a3;
}

/* Cards and containers dark mode */
body.dark-mode .card,
body.dark-mode .dashboard-card,
body.dark-mode .project-card,
body.dark-mode .task-card,
body.dark-mode .form-card {
    background-color: #171717;
    border-color: rgba(255, 255, 255, 0.1);
}

/* Project card dark mode */
body.dark-mode .project-card:hover {
    background: #262626;
    border-color: rgba(255, 255, 255, 0.2);
}

body.dark-mode .project-name {
    color: #fafafa;
}

body.dark-mode .project-description {
    color: #a3a3a3;
}

body.dark-mode .project-description.no-description {
    color: #525252;
}

body.dark-mode .project-card-meta {
    color: #737373;
}

body.dark-mode .project-category {
    background: rgba(255, 255, 255, 0.1);
}

body.dark-mode .project-card-stats {
    border-top-color: rgba(255, 255, 255, 0.1);
    color: #737373;
}

body.dark-mode .project-card-stats i {
    color: #525252;
}

body.dark-mode .card-header,
body.dark-mode .dashboard-card-header {
    border-bottom-color: rgba(255, 255, 255, 0.1);
    color: #fafafa;
}

body.dark-mode .card-title,
body.dark-mode .dashboard-card-title {
    color: #fafafa;
}

body.dark-mode .card-body {
    color: #e5e5e5;
}

/* Form card dark mode */
body.dark-mode .form-card h3 {
    color: #fafafa;
}

body.dark-mode .form-help {
    color: #737373;
}

body.dark-mode .preview-label {
    color: #a3a3a3;
}

/* Buttons dark mode */
body.dark-mode .btn {
    border-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .btn-secondary {
    background-color: #262626;
    color: #e5e5e5;
    border-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .btn-secondary:hover {
    background-color: #404040;
}

body.dark-mode .btn-outline {
    background-color: transparent;
    color: #e5e5e5;
    border-color: rgba(255, 255, 255, 0.2);
}

body.dark-mode .btn-outline:hover {
    background-color: rgba(255, 255, 255, 0.1);
}

/* Forms and inputs dark mode */
body.dark-mode input,
body.dark-mode textarea,
body.dark-mode select {
    background-color: #262626;
    color: #e5e5e5;
    border-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode input:focus,
body.dark-mode textarea:focus,
body.dark-mode select:focus {
    border-color: rgba(255, 255, 255, 0.3);
    box-shadow: 0 0 0 3px rgba(255, 255, 255, 0.1);
}

body.dark-mode input::placeholder,
body.dark-mode textarea::placeholder {
    color: #737373;
}

body.dark-mode .form-label {
    color: #a3a3a3;
}

body.dark-mode .form-group label {
    color: #a3a3a3;
}

/* Tables dark mode */
body.dark-mode table {
    background-color: #171717;
}

body.dark-mode th {
    background-color: #262626;
    color: #a3a3a3;
    border-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode td {
    color: #e5e5e5;
    border-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode tr:hover {
    background-color: rgba(255, 255, 255, 0.05);
}

body.dark-mode .table-container {
    background-color: #171717;
    border-color: rgba(255, 255, 255, 0.1);
}

/* Tasks Page dark mode */
body.dark-mode .tasks-stats-bar .stat-item {
    background-color: #171717;
    border-color: rgba(255, 255, 255, 0.1);
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.3);
}

body.dark-mode .tasks-stats-bar .stat-item:hover {
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.4);
}

body.dark-mode .tasks-stats-bar .stat-item.stat-total {
    border-top-color: #fafafa;
}

body.dark-mode .tasks-stats-bar .stat-item.stat-total .stat-number {
    color: #fafafa;
}

body.dark-mode .tasks-stats-bar .stat-number {
    color: #fafafa;
}

body.dark-mode .tasks-stats-bar .stat-label {
    color: #737373;
}

body.dark-mode .status-select {
    background-color: inherit;
}

body.dark-mode .status-select:focus {
    box-shadow: 0 0 0 2px rgba(255, 255, 255, 0.2);
}

body.dark-mode .status-select-new {
    background-color: #374151;
    color: #e5e5e5;
}

body.dark-mode .deadline-none {
    color: #737373;
}

body.dark-mode .task-table th.sortable:hover {
    background-color: rgba(255, 255, 255, 0.05);
}

body.dark-mode .task-table th.sortable .sort-icon {
    color: #737373;
}

body.dark-mode .task-table th.sortable.sort-asc .sort-icon,
body.dark-mode .task-table th.sortable.sort-desc .sort-icon {
    color: #fafafa;
}

body.dark-mode .bulk-actions-panel {
    background-color: rgba(59, 130, 246, 0.1);
    border-color: rgba(59, 130, 246, 0.3);
}

body.dark-mode .bulk-selection-info {
    color: #e5e5e5;
}

/* Modal/Dialog dark mode */
body.dark-mode .dialog-content,
body.dark-mode .modal-content {
    background-color: #171717;
    border-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .dialog-header,
body.dark-mode .modal-header {
    border-bottom-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .dialog-header h2,
body.dark-mode .dialog-header h3,
body.dark-mode .modal-header h2,
body.dark-mode .modal-header h3 {
    color: #fafafa;
}

body.dark-mode .dialog-body,
body.dark-mode .modal-body {
    color: #e5e5e5;
}

body.dark-mode .dialog-footer,
body.dark-mode .modal-footer {
    border-top-color: rgba(255, 255, 255, 0.1);
}

/* Alerts dark mode */
body.dark-mode .alert {
    border-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .alert-success {
    background-color: rgba(34, 197, 94, 0.15);
    color: #4ade80;
}

body.dark-mode .alert-error {
    background-color: rgba(239, 68, 68, 0.15);
    color: #f87171;
}

/* Page headers and titles dark mode */
body.dark-mode .page-header h1,
body.dark-mode .page-title,
body.dark-mode h1,
body.dark-mode h2,
body.dark-mode h3 {
    color: #fafafa;
}

body.dark-mode .page-header p,
body.dark-mode .page-subtitle {
    color: #a3a3a3;
}

/* Stats and metrics dark mode */
body.dark-mode .stat-card,
body.dark-mode .metric-card {
    background-color: #171717;
    border-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .stat-value,
body.dark-mode .metric-value {
    color: #fafafa;
}

body.dark-mode .stat-label,
body.dark-mode .metric-label {
    color: #a3a3a3;
}

/* Sidebar dark mode */
body.dark-mode .sidebar {
    background-color: #171717;
    border-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .sidebar-link {
    color: #a3a3a3;
}

body.dark-mode .sidebar-link:hover {
    background-color: rgba(255, 255, 255, 0.1);
    color: #fafafa;
}

body.dark-mode .sidebar-link.active {
    background-color: rgba(255, 255, 255, 0.1);
    color: #fafafa;
}

/* Links dark mode */
body.dark-mode a {
    color: #e5e5e5;
}

body.dark-mode a:hover {
    color: #fafafa;
}

/* Badges and tags dark mode */
body.dark-mode .badge,
body.dark-mode .tag {
    background-color: #262626;
    color: #e5e5e5;
}

/* Empty states dark mode */
body.dark-mode .empty-state {
    background: #171717;
    color: #737373;
}

body.dark-mode .empty-state i {
    color: #525252;
}

/* Notifications dark mode */
body.dark-mode .calendar-notification {
    background: #171717;
    color: #e5e5e5;
    border-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .notification {
    background: #171717;
    color: #e5e5e5;
}

body.dark-mode .notification-info {
    background: #262626;
    color: #e5e5e5;
}

body.dark-mode .toast-notification {
    background: #171717;
    color: #e5e5e5;
}

body.dark-mode .kanban-notification {
    background: #171717;
    color: #e5e5e5;
}

/* Kanban board dark mode */
body.dark-mode .kanban-column {
    background-color: #171717;
    border-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .kanban-column-header {
    background-color: #171717;
    border-bottom-color: rgba(255, 255, 255, 0.1);
    color: #fafafa;
}

body.dark-mode .column-title {
    color: #fafafa;
}

body.dark-mode .column-task-count {
    color: #d4d4d4;
    background-color: #404040;
}

body.dark-mode .kanban-task {
    background-color: #262626;
    border-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .kanban-task:hover {
    background-color: #404040;
}

/* Calendar dark mode */
body.dark-mode .calendar-header {
    color: #fafafa;
}

body.dark-mode .calendar-day {
    background-color: #171717;
    border-color: rgba(255, 255, 255, 0.1);
    color: #e5e5e5;
}

body.dark-mode .calendar-day:hover {
    background-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .calendar-day.today {
    background-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .calendar-day.other-month {
    color: #525252;
}

/* Notes dark mode */
body.dark-mode .note-card {
    background-color: #171717;
    border-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .note-title {
    color: #fafafa;
}

body.dark-mode .note-content {
    color: #a3a3a3;
}

/* Profile page dark mode */
body.dark-mode .profile-card {
    background-color: #171717;
    border-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .profile-email {
    color: #a3a3a3;
}

/* Lists dark mode */
body.dark-mode .list-item {
    border-bottom-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .list-item:hover {
    background-color: rgba(255, 255, 255, 0.05);
}

/* Mobile menu dark mode */
body.dark-mode .mobile-menu {
    background-color: #171717;
}

body.dark-mode .mobile-menu-header {
    border-bottom-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .mobile-menu-title {
    color: #fafafa;
}

body.dark-mode .mobile-menu-close {
    color: #a3a3a3;
}

body.dark-mode .mobile-menu-link {
    color: #e5e5e5;
}

body.dark-mode .mobile-menu-link:hover,
body.dark-mode .mobile-menu-link.active {
    background-color: rgba(255, 255, 255, 0.1);
    color: #fafafa;
}

/* Hamburger menu dark mode */
body.dark-mode .hamburger-line {
    background-color: #e5e5e5;
}

/* Scrollbar dark mode */
body.dark-mode ::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}

body.dark-mode ::-webkit-scrollbar-track {
    background: #171717;
}

body.dark-mode ::-webkit-scrollbar-thumb {
    background: #404040;
    border-radius: 4px;
}

body.dark-mode ::-webkit-scrollbar-thumb:hover {
    background: #525252;
}

/* Tooltips dark mode */
body.dark-mode .tooltip {
    background-color: #262626;
    color: #e5e5e5;
    border-color: rgba(255, 255, 255, 0.1);
}

/* Progress bars dark mode */
body.dark-mode .progress-bar {
    background-color: #262626;
}

/* Breadcrumbs dark mode */
body.dark-mode .breadcrumb {
    color: #a3a3a3;
}

body.dark-mode .breadcrumb a {
    color: #e5e5e5;
}

body.dark-mode .breadcrumb a:hover {
    color: #fafafa;
}

/* Dashboard specific dark mode */
body.dark-mode .welcome-section h1 {
    color: #fafafa;
}

body.dark-mode .welcome-section p {
    color: #a3a3a3;
}

body.dark-mode .dashboard-section-title {
    color: #fafafa;
}

/* Today's Schedule dark mode */
body.dark-mode .todays-tasks-list {
    background: #171717;
    border-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .todays-task-item {
    border-bottom-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .todays-task-item:hover {
    background-color: #262626;
}

body.dark-mode .todays-task-name {
    color: #e5e5e5;
}

body.dark-mode .todays-task-name:hover {
    color: #fafafa;
}

body.dark-mode .todays-task-project {
    color: #a3a3a3;
}

body.dark-mode .today-date {
    color: #a3a3a3;
}

/* Quick actions dark mode */
body.dark-mode .quick-action-btn {
    background-color: #262626;
    color: #e5e5e5;
    border-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .quick-action-btn:hover {
    background-color: #404040;
}

/* File upload dark mode */
body.dark-mode .file-upload-area {
    background-color: #262626;
    border-color: rgba(255, 255, 255, 0.2);
    color: #a3a3a3;
}

body.dark-mode .file-upload-area:hover {
    border-color: rgba(255, 255, 255, 0.3);
}

/* Description containers dark mode */
body.dark-mode .description-view {
    background: #262626;
    border-color: rgba(255, 255, 255, 0.1);
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.2);
}

body.dark-mode .description-view.editable:hover {
    background: #2a2a2a;
    border-color: rgba(255, 255, 255, 0.15);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.3);
}

body.dark-mode .description-edit {
    background-color: #262626;
    border-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .task-description,
body.dark-mode .project-description {
    color: #e5e5e5;
}

body.dark-mode .task-description-empty,
body.dark-mode .project-description-empty {
    color: #737373;
}

/* Time tracking dark mode */
body.dark-mode .time-tracking-section {
    background-color: #171717;
    border-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .timer-display {
    color: #fafafa;
}

/* Evaluation section dark mode */
body.dark-mode .evaluation-section {
    background-color: #171717;
    border-color: rgba(255, 255, 255, 0.1);
}

/* Sidebar Evaluation Dark Mode */
body.dark-mode .evaluation-sidebar-label {
    color: #a3a3a3;
}

/* Sidebar Time Tracking Dark Mode */
body.dark-mode .time-tracker-display {
    background: rgba(255, 255, 255, 0.05);
}

body.dark-mode .time-tracker-value {
    color: #fafafa;
}

body.dark-mode .time-tracker-total-value {
    color: #60a5fa;
}

body.dark-mode .time-tracker-label {
    color: #737373;
}

body.dark-mode .btn-timer-history {
    background: rgba(255, 255, 255, 0.1);
    color: #a3a3a3;
}

body.dark-mode .btn-timer-history:hover {
    background: rgba(255, 255, 255, 0.15);
    color: #fafafa;
}

body.dark-mode .sidebar-time-tracking.timer-running .time-tracker-value {
    color: #4ade80;
}

body.dark-mode .btn-timer-start {
    background: #fafafa;
    color: #171717;
}

body.dark-mode .btn-timer-start:hover {
    background: #e5e5e5;
}

/* Task box dark mode */
body.dark-mode .taskbox-item {
    background-color: #171717;
    border-color: rgba(255, 255, 255, 0.1);
}

/* Chart elements dark mode */
body.dark-mode .chart-container {
    background-color: #171717;
}

/* Project selection dialog dark mode */
body.dark-mode .project-select-item {
    background-color: #262626;
    border-color: rgba(255, 255, 255, 0.1);
    color: #e5e5e5;
}

body.dark-mode .project-select-item:hover {
    background-color: #404040;
}

/* ==================== Dark Mode - Extended Components ==================== */

/* Layout Containers */
body.dark-mode .project-layout,
body.dark-mode .task-layout,
body.dark-mode .kanban-layout,
body.dark-mode .calendar-layout {
    background-color: #0a0a0f;
}

body.dark-mode .project-main,
body.dark-mode .task-main,
body.dark-mode .kanban-main,
body.dark-mode .calendar-main {
    background-color: transparent;
}

/* Task Detail Tabs Dark Mode */
body.dark-mode .task-detail-tabs {
    background: rgba(255, 255, 255, 0.05);
}

body.dark-mode .task-tab {
    color: rgba(255, 255, 255, 0.5);
}

body.dark-mode .task-tab:hover {
    color: rgba(255, 255, 255, 0.7);
}

body.dark-mode .task-tab.active {
    color: #fff;
    background: rgba(255, 255, 255, 0.1);
    box-shadow: none;
}

body.dark-mode .project-sidebar,
body.dark-mode .task-sidebar,
body.dark-mode .kanban-sidebar,
body.dark-mode .calendar-sidebar {
    background-color: #171717;
    border-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .sidebar-section {
    background-color: #171717;
    border-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .sidebar-section h3 {
    color: #fafafa;
    border-bottom-color: rgba(255, 255, 255, 0.1);
}

/* Detail Lists */
body.dark-mode .detail-list {
    background-color: transparent;
}

body.dark-mode .detail-item {
    border-bottom-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .detail-label {
    color: #a3a3a3;
}

body.dark-mode .detail-value {
    color: #e5e5e5;
}

body.dark-mode .detail-value a {
    color: #e5e5e5;
}

body.dark-mode .detail-value a:hover {
    color: #fafafa;
}

/* Project Tabs */
body.dark-mode .project-tabs {
    background-color: #171717;
    border-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .tab-btn {
    color: #a3a3a3;
    background-color: transparent;
}

body.dark-mode .tab-btn:hover {
    color: #fafafa;
    background-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .tab-btn.active {
    color: #171717;
    background-color: #fafafa;
}

body.dark-mode .tab-content {
    background-color: #171717;
    border-color: rgba(255, 255, 255, 0.1);
}

/* Project Stats Bar */
body.dark-mode .project-stats-bar {
    background-color: #171717;
    border-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .project-stats-bar .stat-item {
    border-right-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .project-stats-bar .stat-number {
    color: #fafafa;
}

body.dark-mode .project-stats-bar .stat-label {
    color: #a3a3a3;
}

/* Quick Add Section */
body.dark-mode .quick-add-section {
    background-color: #171717;
    border-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .quick-add-form {
    background-color: transparent;
}

body.dark-mode .quick-add-input {
    background-color: #262626;
    color: #e5e5e5;
    border-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .quick-add-input::placeholder {
    color: #737373;
}

body.dark-mode .quick-add-input:focus {
    border-color: rgba(255, 255, 255, 0.3);
}

/* Inline Task Details */
body.dark-mode .task-details-expanded {
    border-top-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .inline-task-fields .form-group label {
    color: #a3a3a3;
}

body.dark-mode .inline-task-fields .form-input {
    background-color: #262626;
    color: #e5e5e5;
    border-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .inline-task-fields .form-input:focus {
    border-color: rgba(255, 255, 255, 0.3);
}

body.dark-mode .inline-task-fields .form-input::placeholder {
    color: #737373;
}

body.dark-mode .inline-task-fields .checkbox-label {
    color: #e5e5e5;
}

body.dark-mode .inline-task-error {
    background-color: rgba(220, 38, 38, 0.1);
    border-color: rgba(220, 38, 38, 0.3);
    color: #f87171;
}

/* Team Members */
body.dark-mode .team-member-item {
    background-color: #262626;
    border-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .team-member-item:hover {
    background-color: #404040;
}

body.dark-mode .member-avatar {
    background-color: #404040;
    color: #e5e5e5;
}

body.dark-mode .member-name {
    color: #e5e5e5;
}

body.dark-mode .member-role {
    background-color: #404040;
    color: #a3a3a3;
}

body.dark-mode .add-member-section {
    background-color: transparent;
}

body.dark-mode .add-member-form-compact input {
    background-color: #262626;
    color: #e5e5e5;
    border-color: rgba(255, 255, 255, 0.1);
}

/* Project Header */
body.dark-mode .project-header-banner {
    background-color: #171717;
    border-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .add-header-image-section {
    background-color: #171717;
    border-color: rgba(255, 255, 255, 0.2);
    color: #a3a3a3;
}

body.dark-mode .add-header-image-section:hover {
    background-color: #262626;
    border-color: rgba(255, 255, 255, 0.3);
}

body.dark-mode .header-actions {
    background-color: transparent;
}

body.dark-mode .header-row {
    border-bottom-color: rgba(255, 255, 255, 0.1);
}

/* Task Items in Lists */
body.dark-mode .task-item {
    background-color: #171717;
    border-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .task-item:hover {
    background-color: #262626;
}

body.dark-mode .task-item.task-done {
    opacity: 0.6;
}

body.dark-mode .task-item.task-done .task-name {
    color: #737373;
}

body.dark-mode .task-content {
    color: #e5e5e5;
}

body.dark-mode .task-header {
    color: #e5e5e5;
}

body.dark-mode .task-name {
    color: #e5e5e5;
}

body.dark-mode .task-name:hover {
    color: #fafafa;
}

body.dark-mode .task-meta {
    color: #737373;
}

body.dark-mode .task-category {
    background-color: #262626;
    color: #a3a3a3;
}

body.dark-mode .task-deadline {
    color: #a3a3a3;
}

body.dark-mode .task-deadline.overdue {
    color: #f87171;
}

body.dark-mode .task-actions {
    background-color: transparent;
}

body.dark-mode .status-select {
    background-color: #262626;
    color: #e5e5e5;
    border-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .status-select:focus {
    border-color: rgba(255, 255, 255, 0.3);
}

/* Comments Section */
body.dark-mode .comments-section {
    background-color: transparent;
}

body.dark-mode .comment-form {
    background-color: transparent;
}

body.dark-mode .comment-form textarea {
    background-color: #262626;
    color: #e5e5e5;
    border-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .comment-form textarea:focus {
    border-color: rgba(255, 255, 255, 0.3);
}

body.dark-mode .comments-list {
    background-color: transparent;
}

body.dark-mode .comment-card {
    background-color: #171717;
    border-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .comment-header {
    border-bottom-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .comment-author {
    color: #fafafa;
}

body.dark-mode .comment-date {
    color: #737373;
}

body.dark-mode .comment-content {
    color: #e5e5e5;
}

body.dark-mode .comment-actions button {
    color: #a3a3a3;
}

body.dark-mode .comment-actions button:hover {
    color: #fafafa;
}

/* Files Section */
body.dark-mode .files-section {
    background-color: transparent;
}

body.dark-mode .file-upload-form {
    background-color: transparent;
}

body.dark-mode .file-input-wrapper {
    background-color: transparent;
}

body.dark-mode .file-input-label {
    background-color: #262626;
    color: #e5e5e5;
    border-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .file-input-label:hover {
    background-color: #404040;
}

body.dark-mode .selected-file-name {
    color: #a3a3a3;
}

body.dark-mode .file-upload-error {
    color: #f87171;
}

body.dark-mode .upload-progress {
    background-color: #262626;
}

body.dark-mode .progress-bar {
    background-color: #262626;
}

body.dark-mode .progress-fill {
    background-color: #22c55e;
}

body.dark-mode .progress-text {
    color: #e5e5e5;
}

body.dark-mode .files-list {
    background-color: transparent;
}

body.dark-mode .file-item {
    background-color: #171717;
    border-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .file-item:hover {
    background-color: #262626;
}

body.dark-mode .file-icon {
    color: #a3a3a3;
}

body.dark-mode .file-name {
    color: #e5e5e5;
}

body.dark-mode .file-name:hover {
    color: #fafafa;
}

body.dark-mode .file-meta {
    color: #737373;
}

body.dark-mode .file-size,
body.dark-mode .file-date,
body.dark-mode .file-uploader {
    color: #737373;
}

body.dark-mode .file-separator {
    color: #525252;
}

body.dark-mode .file-actions button {
    color: #a3a3a3;
}

body.dark-mode .file-actions button:hover {
    color: #f87171;
}

/* Links Section */
body.dark-mode .links-section {
    background-color: transparent;
}

body.dark-mode .link-add-form {
    background-color: transparent;
}

body.dark-mode .link-input-wrapper input {
    background-color: #262626;
    color: #e5e5e5;
    border-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .link-input-wrapper input:focus {
    border-color: rgba(255, 255, 255, 0.3);
}

body.dark-mode .link-item {
    background-color: #171717;
    border-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .link-item:hover {
    background-color: #262626;
}

body.dark-mode .link-icon {
    color: #a3a3a3;
}

body.dark-mode .link-name {
    color: #e5e5e5;
}

body.dark-mode .link-name:hover {
    color: #fafafa;
}

body.dark-mode .link-meta {
    color: #737373;
}

body.dark-mode .link-url,
body.dark-mode .link-date,
body.dark-mode .link-adder {
    color: #737373;
}

body.dark-mode .link-separator {
    color: #525252;
}

body.dark-mode .link-actions button {
    color: #a3a3a3;
}

body.dark-mode .link-actions button:hover {
    color: #f87171;
}

/* History Section */
body.dark-mode .history-container {
    background-color: #171717;
    border-color: rgba(255, 255, 255, 0.1);
    box-shadow: none;
}

body.dark-mode .history-loading {
    color: #737373;
}

body.dark-mode .history-empty {
    color: #737373;
}

body.dark-mode .history-empty .empty-icon {
    color: #525252;
}

body.dark-mode .history-empty h3 {
    color: #e5e5e5;
}

body.dark-mode .history-empty p {
    color: #737373;
}

body.dark-mode .history-entries {
    background-color: transparent;
}

body.dark-mode .history-entry {
    color: #e5e5e5;
}

body.dark-mode .history-dot {
    background-color: #404040;
    border-color: #171717;
}

body.dark-mode .history-content {
    color: #e5e5e5;
}

body.dark-mode .history-date {
    color: #737373;
}

/* Calendar Components */
body.dark-mode .calendar-container {
    background-color: transparent;
}

body.dark-mode .task-panel {
    background-color: #171717;
    border-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .panel-header {
    background-color: #171717;
    border-bottom-color: rgba(255, 255, 255, 0.1);
    color: #fafafa;
}

body.dark-mode .task-filters {
    background-color: transparent;
}

body.dark-mode .task-search {
    background-color: #262626;
    color: #e5e5e5;
    border-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .task-search::placeholder {
    color: #737373;
}

body.dark-mode .task-search:focus {
    border-color: rgba(255, 255, 255, 0.3);
}

body.dark-mode .filter-row {
    background-color: transparent;
}

body.dark-mode .filter-select {
    background-color: #262626;
    color: #e5e5e5;
    border-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .filter-select:focus {
    border-color: rgba(255, 255, 255, 0.3);
}

body.dark-mode .task-list-panel {
    background-color: #171717;
}

body.dark-mode .draggable-task {
    background-color: #262626;
    border-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .draggable-task:hover {
    background-color: #404040;
}

body.dark-mode .draggable-task .task-color-bar {
    opacity: 0.8;
}

body.dark-mode .draggable-task .task-info {
    color: #e5e5e5;
}

body.dark-mode .draggable-task .task-name {
    color: #e5e5e5;
}

body.dark-mode .draggable-task .task-project {
    color: #737373;
}

body.dark-mode .task-status-badge {
    background-color: #404040;
    color: #a3a3a3;
}

body.dark-mode .empty-task-list {
    color: #737373;
}

body.dark-mode .calendar-grid {
    background-color: transparent;
}

body.dark-mode .calendar-weekdays {
    background-color: #262626;
}

body.dark-mode .weekday {
    color: #a3a3a3;
    background-color: #262626;
    border-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .calendar-days {
    background-color: transparent;
}

body.dark-mode .day-view {
    background-color: #171717;
    border-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .day-view-header {
    border-bottom-color: rgba(255, 255, 255, 0.1);
    color: #fafafa;
}

body.dark-mode .day-view-content {
    background-color: #171717;
}

body.dark-mode .empty-day-view {
    color: #737373;
}

/* Kanban Components */
body.dark-mode .kanban-container {
    background-color: transparent;
}

body.dark-mode .kanban-page-header {
    background-color: transparent;
}

body.dark-mode .page-header-left h1 {
    color: #fafafa;
}

body.dark-mode .board-selector {
    background-color: transparent;
}

body.dark-mode .board-select {
    background-color: #262626;
    color: #e5e5e5;
    border-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .board-select:focus {
    border-color: rgba(255, 255, 255, 0.3);
}

body.dark-mode .edit-board-btn,
body.dark-mode .delete-board-btn {
    color: #a3a3a3;
}

body.dark-mode .edit-board-btn:hover {
    color: #fafafa;
}

body.dark-mode .delete-board-btn:hover {
    color: #f87171;
}

body.dark-mode .create-board-btn,
body.dark-mode .add-column-btn {
    background-color: #262626;
    color: #e5e5e5;
    border-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .create-board-btn:hover,
body.dark-mode .add-column-btn:hover {
    background-color: #404040;
}

body.dark-mode .kanban-board {
    background-color: transparent;
}

body.dark-mode .kanban-draggable-task {
    background-color: #262626;
    border-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .kanban-draggable-task:hover {
    background-color: #404040;
}

/* Chat Components */
body.dark-mode .chat-container {
    background-color: #171717;
}

body.dark-mode .chat-main {
    background-color: #171717;
}

body.dark-mode .chat-header {
    background-color: #262626;
    border-bottom-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .chat-header-info h3 {
    color: #fafafa;
}

body.dark-mode .chat-header-info p {
    color: #737373;
}

body.dark-mode .chat-header-actions button {
    color: #a3a3a3;
}

body.dark-mode .chat-header-actions button:hover {
    color: #fafafa;
}

body.dark-mode .chat-messages {
    background-color: #171717;
}

body.dark-mode .chat-loading {
    color: #737373;
}

body.dark-mode .chat-empty {
    color: #737373;
}

body.dark-mode .messages-list {
    background-color: transparent;
}

body.dark-mode .chat-message {
    background-color: transparent;
}

body.dark-mode .chat-message:hover {
    background-color: rgba(255, 255, 255, 0.05);
}

body.dark-mode .chat-message.own-message {
    background-color: rgba(255, 255, 255, 0.05);
}

body.dark-mode .message-content {
    color: #e5e5e5;
}

body.dark-mode .message-author {
    color: #fafafa;
}

body.dark-mode .message-time {
    color: #a3a3a3;
}

body.dark-mode .edited-badge {
    color: #737373;
}

body.dark-mode .message-content .mention {
    background-color: #404040;
    color: #e5e5e5;
}

body.dark-mode .message-content .task-ref {
    background-color: #404040;
    color: #e5e5e5;
}

body.dark-mode .message-content .task-ref:hover {
    background-color: #525252;
}

body.dark-mode .load-more-container button {
    background-color: #262626;
    color: #e5e5e5;
    border-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .load-more-container button:hover {
    background-color: #404040;
}

body.dark-mode .chat-composer {
    background-color: #262626;
    border-top-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .reply-indicator {
    background-color: #262626;
    border-left-color: #f59e0b;
}

body.dark-mode .reply-indicator-content {
    color: #e5e5e5;
}

body.dark-mode .reply-indicator-label {
    color: #737373;
}

body.dark-mode .reply-indicator-author {
    color: #fafafa;
}

body.dark-mode .reply-indicator-preview {
    color: #a3a3a3;
}

body.dark-mode .reply-indicator-cancel {
    color: #a3a3a3;
}

body.dark-mode .reply-indicator-cancel:hover {
    color: #fafafa;
    background-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .composer-container {
    background-color: transparent;
}

body.dark-mode .composer-textarea {
    background-color: #171717;
    color: #e5e5e5;
    border-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .composer-textarea:focus {
    border-color: rgba(255, 255, 255, 0.3);
}

body.dark-mode .composer-textarea::placeholder {
    color: #737373;
}

body.dark-mode .autocomplete-dropdown {
    background-color: #262626;
    border-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .autocomplete-item {
    color: #e5e5e5;
}

body.dark-mode .autocomplete-item:hover,
body.dark-mode .autocomplete-item.selected {
    background-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .autocomplete-text {
    color: #e5e5e5;
}

body.dark-mode .autocomplete-subtext {
    color: #737373;
}

body.dark-mode .composer-actions button {
    background-color: #262626;
    color: #e5e5e5;
    border-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .composer-actions button:hover {
    background-color: #404040;
}

body.dark-mode .priority-select {
    background-color: #262626;
    color: #e5e5e5;
    border-color: rgba(255, 255, 255, 0.1);
}

/* Dashboard Tab Components */
body.dark-mode .dashboard-container {
    background-color: #171717;
}

body.dark-mode .dashboard-loading {
    color: #737373;
}

body.dark-mode .dashboard-content {
    background-color: transparent;
}

body.dark-mode .dashboard-cards {
    background-color: transparent;
}

body.dark-mode .dashboard-card-health,
body.dark-mode .dashboard-card-warning {
    background: #171717;
    border-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .dashboard-card-icon {
    color: #a3a3a3;
}

body.dark-mode .dashboard-card-health .dashboard-card-icon {
    background-color: rgba(34, 197, 94, 0.2);
    color: #22c55e;
}

body.dark-mode .dashboard-card-content {
    color: #e5e5e5;
}

body.dark-mode .dashboard-card-value {
    color: #fafafa;
}

body.dark-mode .dashboard-card-label {
    color: #a3a3a3;
}

body.dark-mode .dashboard-card-indicator {
    color: #e5e5e5;
}

body.dark-mode .dashboard-charts-row {
    background-color: transparent;
}

body.dark-mode .dashboard-chart-container {
    background-color: #171717;
    border-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .dashboard-chart-title {
    color: #fafafa;
}

body.dark-mode .dashboard-chart-wrapper {
    background-color: transparent;
}

body.dark-mode .dashboard-chart-wide {
    background-color: #171717;
    border-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .dashboard-details-row {
    background-color: transparent;
}

body.dark-mode .dashboard-timeline-container {
    background: #171717;
    border-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .dashboard-section-title {
    color: #fafafa;
}

body.dark-mode .dashboard-timeline {
    border-left-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .timeline-item {
    background-color: #262626;
}

body.dark-mode .timeline-item:hover {
    background-color: #404040;
}

body.dark-mode .timeline-task-name {
    color: #e5e5e5;
}

body.dark-mode .timeline-task-name:hover {
    color: #fafafa;
}

body.dark-mode .timeline-meta {
    color: #a3a3a3;
}

body.dark-mode .timeline-arrow {
    color: #737373;
}

body.dark-mode .dashboard-deadlines-container {
    background: #171717;
    border-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .dashboard-deadlines {
    background-color: transparent;
}

body.dark-mode .dashboard-empty-text {
    color: #737373;
}

/* Note Tab Components */
body.dark-mode .project-note-container {
    background-color: #171717;
}

body.dark-mode .note-toolbar {
    background-color: #262626;
    border-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .note-view-mode-container {
    background-color: transparent;
}

body.dark-mode .note-view-mode-label {
    color: #a3a3a3;
}

body.dark-mode .note-view-mode-select {
    background-color: #171717;
    color: #e5e5e5;
    border-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .note-save-status {
    color: #737373;
}

body.dark-mode .save-status-text {
    color: #737373;
}

body.dark-mode .note-content-area {
    background-color: #171717;
}

body.dark-mode .note-editor-panel {
    background-color: #171717;
    border-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .note-editor-panel textarea {
    background-color: #171717;
    color: #e5e5e5;
    border-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .note-preview-panel {
    background-color: #171717;
    border-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .note-preview-content {
    color: #e5e5e5;
}

body.dark-mode .note-preview-empty {
    color: #737373;
}

body.dark-mode .note-readonly-notice {
    background-color: #262626;
    color: #a3a3a3;
    border-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .markdown-body {
    color: #e5e5e5;
}

body.dark-mode .markdown-body h1,
body.dark-mode .markdown-body h2,
body.dark-mode .markdown-body h3,
body.dark-mode .markdown-body h4,
body.dark-mode .markdown-body h5,
body.dark-mode .markdown-body h6 {
    color: #fafafa;
    border-bottom-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .markdown-body code {
    background-color: #262626;
    color: #e5e5e5;
}

body.dark-mode .markdown-body pre {
    background-color: #262626;
    border-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .markdown-body blockquote {
    border-left-color: rgba(255, 255, 255, 0.2);
    color: #a3a3a3;
}

body.dark-mode .markdown-body table th {
    background-color: #262626;
    border-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .markdown-body table td {
    border-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .markdown-body hr {
    background-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .markdown-body a {
    color: #60a5fa;
}

/* Evaluation Grid */
body.dark-mode .evaluation-grid {
    background-color: transparent;
}

body.dark-mode .evaluation-item {
    background-color: #171717;
    border-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .evaluation-label {
    color: #a3a3a3;
}

body.dark-mode .evaluation-view {
    color: #e5e5e5;
}

body.dark-mode .evaluation-edit input,
body.dark-mode .evaluation-edit select,
body.dark-mode .evaluation-edit textarea {
    background-color: #262626;
    color: #e5e5e5;
    border-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .evaluation-empty {
    color: #525252;
}

body.dark-mode .evaluation-status {
    color: #737373;
}

body.dark-mode .evaluation-status-saving {
    color: #f59e0b;
}

body.dark-mode .evaluation-status-success {
    color: #4ade80;
}

body.dark-mode .evaluation-status-error {
    color: #f87171;
}

/* Assignees */
body.dark-mode .assignees-list {
    background-color: transparent;
}

body.dark-mode .assignee-badge {
    background-color: #262626;
    border-color: rgba(255, 255, 255, 0.1);
    color: #e5e5e5;
}

body.dark-mode .assignee-badge:hover {
    background-color: #404040;
}

body.dark-mode .assignee-avatar {
    background-color: #404040;
    color: #e5e5e5;
}

body.dark-mode .assignee-name {
    color: #e5e5e5;
}

body.dark-mode .assignee-remove {
    color: #737373;
}

body.dark-mode .assignee-remove:hover {
    color: #f87171;
}

body.dark-mode .add-assignee-form input {
    background-color: #262626;
    color: #e5e5e5;
    border-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .add-assignee-form input:focus {
    border-color: rgba(255, 255, 255, 0.3);
}

body.dark-mode .add-assignee-inline input {
    background-color: #262626;
    color: #e5e5e5;
    border-color: rgba(255, 255, 255, 0.1);
}

/* Form Elements */
body.dark-mode .form-group label {
    color: #a3a3a3;
}

body.dark-mode .form-input {
    background-color: #262626;
    color: #e5e5e5;
    border-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .form-input:focus {
    border-color: rgba(255, 255, 255, 0.3);
}

body.dark-mode .form-select {
    background-color: #262626;
    color: #e5e5e5;
    border-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .form-select:focus {
    border-color: rgba(255, 255, 255, 0.3);
}

/* Time Tracking Enhancements */
body.dark-mode .time-tracking-content {
    background-color: #171717;
}

body.dark-mode .timer-icon {
    color: #a3a3a3;
}

body.dark-mode .timer-value {
    color: #fafafa;
}

body.dark-mode .time-tracking-info {
    color: #e5e5e5;
}

body.dark-mode .total-time-label {
    color: #a3a3a3;
}

body.dark-mode .total-time-value {
    color: #fafafa;
}

body.dark-mode .time-tracking-actions button {
    background-color: #262626;
    color: #e5e5e5;
    border-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .time-tracking-actions button:hover {
    background-color: #404040;
}

body.dark-mode .time-tracking-status {
    color: #737373;
}

body.dark-mode .time-history-summary {
    background-color: #171717;
    border-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .time-history-total-label {
    color: #a3a3a3;
}

body.dark-mode .time-history-total-value {
    color: #fafafa;
}

body.dark-mode .time-history-list {
    background-color: transparent;
}

body.dark-mode .time-history-loading {
    color: #737373;
}

/* Empty States */
body.dark-mode .empty-state-inline {
    color: #737373;
}

body.dark-mode .empty-state-inline i {
    color: #525252;
}

/* Color Dot */
body.dark-mode .color-dot {
    box-shadow: 0 0 0 2px #171717;
}

/* Dialog Enhancements */
body.dark-mode .dialog-actions {
    border-top-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .dialog-close {
    color: #a3a3a3;
}

body.dark-mode .dialog-close:hover {
    color: #fafafa;
}

/* Thread View */
body.dark-mode .thread-view {
    background-color: #171717;
}

body.dark-mode .thread-view-header {
    border-bottom-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .thread-view-header h3 {
    color: #fafafa;
}

body.dark-mode .thread-messages {
    background-color: #171717;
}

body.dark-mode .thread-root-message {
    border-bottom-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .thread-replies-header {
    color: #737373;
}

body.dark-mode .thread-composer {
    border-top-color: rgba(255, 255, 255, 0.1);
}

/* ============================================
   NOTES PAGE DARK MODE (Full Page Version)
   ============================================ */

body.dark-mode .notes-container {
    background-color: #0a0a0f;
}

body.dark-mode .notes-sidebar {
    background-color: #171717;
    border-right-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .notes-sidebar-header {
    border-bottom-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .notes-sidebar-header h2 {
    color: #fafafa;
}

body.dark-mode .notes-search {
    border-bottom-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .notes-search .form-input {
    background-color: #262626;
    color: #e5e5e5;
    border-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .notes-search .form-input:focus {
    border-color: rgba(255, 255, 255, 0.3);
}

body.dark-mode .notes-list {
    background-color: #171717;
}

body.dark-mode .notes-loading,
body.dark-mode .notes-empty {
    color: #737373;
}

body.dark-mode .notes-empty i {
    color: #525252;
}

body.dark-mode .note-item {
    background-color: #262626;
    border-color: rgba(255, 255, 255, 0.1);
    box-shadow: none;
}

body.dark-mode .note-item:hover {
    background-color: #404040;
    border-color: rgba(255, 255, 255, 0.2);
}

body.dark-mode .note-item.active {
    background-color: #fafafa;
    color: #171717;
    border-color: #fafafa;
}

body.dark-mode .note-item-title {
    color: #e5e5e5;
}

body.dark-mode .note-item.active .note-item-title {
    color: #171717;
}

body.dark-mode .note-item-preview {
    color: #737373;
}

body.dark-mode .note-item-meta {
    color: #525252;
}

body.dark-mode .note-shared-badge {
    color: #737373;
}

body.dark-mode .notes-editor-area {
    background-color: #0a0a0f;
}

body.dark-mode .notes-editor-empty {
    color: #737373;
}

body.dark-mode .notes-editor-empty h3 {
    color: #a3a3a3;
}

body.dark-mode .empty-state-icon {
    background-color: #262626;
}

body.dark-mode .empty-state-icon i {
    color: #525252;
}

body.dark-mode .notes-editor-container {
    background-color: #0a0a0f;
}

body.dark-mode .note-header {
    background-color: #171717;
    border-bottom-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .note-title-input {
    color: #fafafa;
    background-color: transparent;
}

body.dark-mode .note-title-input:focus {
    background-color: #262626;
}

body.dark-mode .note-title-input:disabled {
    color: #a3a3a3;
}

body.dark-mode .note-owner-badge {
    background-color: #262626;
    color: #a3a3a3;
}

body.dark-mode .co-author-count {
    background-color: #404040;
    color: #e5e5e5;
}

body.dark-mode .note-editor-layout {
    background-color: #0a0a0f;
}

body.dark-mode .note-editor-panel {
    background-color: #171717;
    border-right-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .panel-header {
    background-color: #262626;
    border-bottom-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .panel-title {
    color: #737373;
}

body.dark-mode .editor-wrapper {
    background-color: #171717;
}

body.dark-mode .editor-wrapper .CodeMirror {
    background-color: #171717;
    color: #e5e5e5;
}

body.dark-mode .editor-wrapper .CodeMirror-gutters {
    background-color: #262626;
    border-right-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .editor-wrapper .CodeMirror-linenumber {
    color: #525252;
}

body.dark-mode .editor-wrapper .CodeMirror-cursor {
    border-left-color: #fafafa;
}

body.dark-mode .editor-wrapper .CodeMirror-selected {
    background-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .preview-wrapper {
    background-color: #171717;
}

body.dark-mode .preview-content {
    color: #e5e5e5;
}

body.dark-mode .preview-content h1,
body.dark-mode .preview-content h2,
body.dark-mode .preview-content h3,
body.dark-mode .preview-content h4,
body.dark-mode .preview-content h5,
body.dark-mode .preview-content h6 {
    color: #fafafa;
}

body.dark-mode .preview-content pre {
    background-color: #262626;
}

body.dark-mode .preview-content code {
    background-color: #262626;
    color: #e5e5e5;
}

body.dark-mode .preview-content blockquote {
    border-left-color: rgba(255, 255, 255, 0.2);
    color: #a3a3a3;
}

body.dark-mode .preview-content a {
    color: #60a5fa;
}

body.dark-mode .spinner {
    border-color: #404040;
    border-top-color: #fafafa;
}

/* ============================================
   CALENDAR DARK MODE ENHANCEMENTS
   ============================================ */

body.dark-mode .calendar-container {
    background-color: #0a0a0f;
}

body.dark-mode .calendar-layout {
    background-color: #0a0a0f;
}

body.dark-mode .calendar-sidebar {
    background-color: #171717;
    border-right-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .task-panel {
    background-color: #171717;
    border-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .task-panel .panel-header {
    background-color: #262626;
    border-bottom-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .task-panel .panel-header h3 {
    color: #fafafa;
}

body.dark-mode .task-filters {
    background-color: #171717;
    border-bottom-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .task-search {
    background-color: #262626;
    color: #e5e5e5;
    border-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .task-search:focus {
    border-color: rgba(255, 255, 255, 0.3);
}

body.dark-mode .filter-select {
    background-color: #262626;
    color: #e5e5e5;
    border-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .filter-select:focus {
    border-color: rgba(255, 255, 255, 0.3);
}

body.dark-mode .task-list-panel {
    background-color: #171717;
}

body.dark-mode .draggable-task {
    background-color: #262626;
    border-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .draggable-task:hover {
    background-color: #404040;
    border-color: rgba(255, 255, 255, 0.2);
}

body.dark-mode .draggable-task .task-name {
    color: #e5e5e5;
}

body.dark-mode .draggable-task .task-project {
    color: #737373;
}

body.dark-mode .empty-task-list {
    color: #737373;
}

body.dark-mode .calendar-main {
    background-color: #0a0a0f;
}

body.dark-mode .calendar-header {
    background-color: #171717;
    border-color: rgba(255, 255, 255, 0.1);
    box-shadow: none;
}

body.dark-mode .calendar-header h2 {
    color: #fafafa;
}

body.dark-mode .calendar-grid {
    background-color: #171717;
    box-shadow: none;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

body.dark-mode .calendar-weekdays {
    background-color: #262626;
    border-bottom-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .weekday {
    color: #a3a3a3;
}

body.dark-mode .calendar-day {
    background-color: #171717;
    border-color: rgba(255, 255, 255, 0.1);
    color: #e5e5e5;
}

body.dark-mode .calendar-day:hover {
    background-color: #262626;
}

body.dark-mode .calendar-day.other-month {
    background-color: #0a0a0f;
}

body.dark-mode .calendar-day.other-month .day-number {
    color: #525252;
}

body.dark-mode .calendar-day.today {
    background-color: rgba(251, 191, 36, 0.15);
}

body.dark-mode .calendar-day.today .day-number {
    background-color: #fafafa;
    color: #171717;
}

body.dark-mode .calendar-day.selected {
    background-color: rgba(96, 165, 250, 0.15);
}

body.dark-mode .calendar-day.drag-over {
    background-color: rgba(74, 222, 128, 0.15);
    border-color: #4ade80;
}

body.dark-mode .day-number {
    color: #a3a3a3;
}

body.dark-mode .calendar-event {
    background-color: #262626;
    color: #e5e5e5;
    border-left-color: #fafafa;
}

body.dark-mode .calendar-event.after-deadline {
    background-color: rgba(248, 113, 113, 0.15);
    color: #f87171;
}

body.dark-mode .calendar-event-more {
    color: #737373;
}

body.dark-mode .day-view {
    background-color: #171717;
    box-shadow: none;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

body.dark-mode .day-view-header {
    border-bottom-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .day-view-header h3 {
    color: #fafafa;
}

/* ============================================
   HISTORY CARDS DARK MODE
   ============================================ */

body.dark-mode .history-content {
    background-color: #171717;
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: none;
}

body.dark-mode .history-content p {
    color: #e5e5e5;
}

body.dark-mode .history-content em {
    background-color: #262626;
    color: #a3a3a3;
}

body.dark-mode .history-dot {
    background-color: #171717;
    border-color: #fafafa;
}

body.dark-mode .history-timeline::before {
    background-color: rgba(255, 255, 255, 0.1);
}

/* ============================================
   DIALOG DARK MODE - All Dialog Windows
   ============================================ */

/* Base Dialog Container */
body.dark-mode .dialog {
    background-color: #171717;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5);
}

body.dark-mode .dialog-title {
    color: #fafafa;
}

body.dark-mode .dialog-description {
    color: #a3a3a3;
}

body.dark-mode .dialog-subtitle {
    color: #a3a3a3;
}

/* Modal Container */
body.dark-mode .modal-container {
    background-color: #171717;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5);
}

body.dark-mode .modal-close {
    color: #a3a3a3;
}

body.dark-mode .modal-close:hover {
    background-color: rgba(255, 255, 255, 0.1);
    color: #fafafa;
}

/* Co-Authors Modal (Notes Page) */
body.dark-mode .co-authors-add {
    border-bottom-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .co-authors-add label,
body.dark-mode .co-authors-list label {
    color: #737373;
}

body.dark-mode .co-author-search .form-input {
    background-color: #262626;
    color: #e5e5e5;
    border-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .co-author-item {
    background-color: #262626;
    border-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .co-author-item:hover {
    background-color: #404040;
}

body.dark-mode .co-author-name {
    color: #e5e5e5;
}

body.dark-mode .co-author-email {
    color: #737373;
}

/* Dashboard Task Modal */
body.dark-mode #dashboardTaskModal .modal-content {
    background-color: #171717;
    border-color: rgba(255, 255, 255, 0.1);
}

/* Form Elements Inside Dialogs/Modals */
body.dark-mode .dialog .form-group label,
body.dark-mode .modal-container .form-group label {
    color: #a3a3a3;
}

body.dark-mode .dialog .form-input,
body.dark-mode .dialog .form-select,
body.dark-mode .dialog textarea,
body.dark-mode .modal-container .form-input,
body.dark-mode .modal-container .form-select,
body.dark-mode .modal-container textarea {
    background-color: #262626;
    color: #e5e5e5;
    border-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .dialog .form-input:focus,
body.dark-mode .dialog .form-select:focus,
body.dark-mode .dialog textarea:focus,
body.dark-mode .modal-container .form-input:focus,
body.dark-mode .modal-container .form-select:focus,
body.dark-mode .modal-container textarea:focus {
    border-color: rgba(255, 255, 255, 0.3);
}

body.dark-mode .dialog .form-help,
body.dark-mode .modal-container .form-help {
    color: #737373;
}

/* Form Actions in Dark Mode */
body.dark-mode .modal-form .form-actions {
    border-top-color: rgba(255, 255, 255, 0.1);
    background-color: transparent;
}

/* Project From Note Dialog (CodeMirror) */
body.dark-mode .project-from-note-dialog .CodeMirror {
    background-color: #171717;
    color: #e5e5e5;
}

body.dark-mode .project-from-note-dialog .CodeMirror-gutters {
    background-color: #262626;
    border-right-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .project-from-note-dialog .CodeMirror-linenumber {
    color: #525252;
}

/* File Preview Modal */
body.dark-mode #filePreviewModal .modal-container {
    background-color: #171717;
}

body.dark-mode .file-preview-content {
    background-color: #171717;
    color: #e5e5e5;
}

/* Task Box Dialogs */
body.dark-mode .taskbox-entry {
    background-color: #262626;
    border-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .taskbox-entry:hover {
    background-color: #404040;
}

body.dark-mode .taskbox-entry-title {
    color: #e5e5e5;
}

body.dark-mode .taskbox-entry-description {
    color: #a3a3a3;
}

body.dark-mode .taskbox-entry-date {
    color: #737373;
}

/* Time History Dialog */
body.dark-mode .time-history-item {
    background-color: #262626;
    border-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .time-history-item:hover {
    background-color: #404040;
}

body.dark-mode .time-history-duration {
    color: #fafafa;
}

body.dark-mode .time-history-date {
    color: #737373;
}

/* Share Password Dialog */
body.dark-mode .password-display {
    background-color: #262626;
    color: #fafafa;
    border-color: rgba(255, 255, 255, 0.1);
}

/* Dialog Choice Options */
body.dark-mode .dialog-choice-option {
    background-color: #262626;
    border-color: rgba(255, 255, 255, 0.1);
    color: #e5e5e5;
}

body.dark-mode .dialog-choice-option:hover {
    background-color: #404040;
    border-color: rgba(255, 255, 255, 0.2);
}

body.dark-mode .dialog-choice-option-icon {
    color: #a3a3a3;
}

body.dark-mode .dialog-choice-option-title {
    color: #fafafa;
}

body.dark-mode .dialog-choice-option-description {
    color: #737373;
}

/* ============================================
   User Dashboard Charts Styles
   ============================================ */

.stats-with-trend {
    display: grid;
    grid-template-columns: auto 1fr;
    gap: 1.5rem;
    align-items: stretch;
    min-width: 0;
    overflow: hidden;
}

.stats-cards-column {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    min-width: 180px;
}

.stats-cards-column .stat-card {
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.trend-chart-card {
    background: var(--color-white);
    border-radius: var(--border-radius);
    padding: 1.25rem;
    box-shadow: var(--shadow-sm);
    border: 1px solid var(--color-gray-100);
    display: flex;
    flex-direction: column;
    overflow: hidden;
    min-width: 0;
}

.trend-chart-container {
    position: relative;
    flex: 1;
    min-height: 120px;
    min-width: 0;
}

.trend-loading {
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--color-gray-400);
    padding: 1rem;
}

.user-dashboard-charts-section {
    margin-bottom: 2rem;
}

.user-dashboard-content {
    padding: 0;
}

.user-charts-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1.5rem;
    min-width: 0;
}

.user-charts-grid-2 {
    grid-template-columns: repeat(2, 1fr);
}

.user-chart-card {
    background: var(--color-white);
    border-radius: var(--border-radius);
    padding: 1.25rem;
    box-shadow: var(--shadow-sm);
    border: 1px solid var(--color-gray-100);
    overflow: hidden;
    min-width: 0;
}

.user-chart-title {
    font-size: 0.9375rem;
    font-weight: 600;
    color: var(--color-gray-700);
    margin: 0 0 1rem 0;
}

.user-chart-container {
    position: relative;
    height: 220px;
    min-width: 0;
}

@media (max-width: 768px) {
    .stats-with-trend {
        grid-template-columns: 1fr;
    }

    .stats-cards-column {
        flex-direction: row;
        min-width: auto;
    }

    .stats-cards-column .stat-card {
        flex: 1;
    }

    .trend-chart-card {
        margin: 0 -0.5rem;
        border-radius: 0;
        padding: 1rem;
    }

    .trend-chart-container {
        min-height: 180px;
    }

    .user-charts-grid,
    .user-charts-grid-2 {
        grid-template-columns: 1fr;
    }

    .user-chart-card {
        padding: 1rem;
    }

    .user-chart-container {
        height: 200px;
    }
}

/* iPhone and small mobile devices */
@media (max-width: 480px) {
    .stats-with-trend {
        gap: 1rem;
    }

    .stats-cards-column {
        gap: 0.75rem;
    }

    .stats-cards-column .stat-card {
        padding: 1rem;
    }

    .stats-cards-column .stat-value {
        font-size: 1.75rem;
    }

    .trend-chart-card {
        margin: 0;
        border-radius: var(--border-radius);
    }

    .trend-chart-container {
        min-height: 150px;
    }

    .user-dashboard-charts-section {
        margin-bottom: 1.5rem;
    }

    .user-chart-card {
        padding: 0.875rem;
    }

    .user-chart-title {
        font-size: 0.875rem;
        margin-bottom: 0.75rem;
    }

    .user-chart-container {
        height: 180px;
    }
}

/* Extra small devices (iPhone SE, etc.) */
@media (max-width: 375px) {
    .stats-cards-column .stat-card {
        padding: 0.75rem;
    }

    .stats-cards-column .stat-value {
        font-size: 1.5rem;
    }

    .stats-cards-column .stat-label {
        font-size: 0.75rem;
    }

    .trend-chart-container {
        min-height: 130px;
    }

    .user-chart-container {
        height: 160px;
    }
}

/* Dark mode for User Dashboard Charts */
body.dark-mode .trend-chart-card {
    background-color: #1a1a1a;
    border-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .user-chart-card {
    background-color: #1a1a1a;
    border-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .user-chart-title {
    color: #e5e5e5;
}

/* ==========================================
   PUBLIC INBOX STYLES
   ========================================== */

/* Public Inbox Section in Sidebar */
.public-inbox-section {
    background: linear-gradient(135deg, #f0f9ff 0%, #e0f2fe 100%);
    border: 1px solid #bae6fd;
    border-radius: var(--border-radius);
    padding: 1rem;
}

.public-inbox-section h3 {
    color: #0369a1;
    margin-bottom: 0.75rem;
    font-size: 0.875rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.public-inbox-loading {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--color-gray-500);
    font-size: 0.875rem;
}

.spinner-sm {
    width: 16px;
    height: 16px;
    border: 2px solid var(--color-gray-200);
    border-top-color: var(--color-gray-500);
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

/* Inbox Status */
.inbox-status-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    margin-bottom: 0.75rem;
}

.inbox-status-badge {
    display: inline-flex;
    align-items: center;
    padding: 0.25rem 0.75rem;
    border-radius: 9999px;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.025em;
}

.inbox-status-badge.inbox-disabled {
    background-color: var(--color-gray-200);
    color: var(--color-gray-600);
}

.inbox-status-badge.inbox-active {
    background-color: #dcfce7;
    color: #166534;
}

.inbox-status-badge.inbox-warning {
    background-color: #fef3c7;
    color: #92400e;
}

/* Inbox Enabled Settings */
.inbox-enabled-settings {
    margin-top: 0.75rem;
}

.inbox-link-section {
    margin-bottom: 0.75rem;
}

.inbox-link-section label {
    display: block;
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--color-gray-600);
    margin-bottom: 0.25rem;
}

.inbox-link-container {
    display: flex;
    gap: 0.25rem;
}

.inbox-link-container input {
    flex: 1;
    padding: 0.375rem 0.5rem;
    border: 1px solid var(--color-gray-300);
    border-radius: var(--border-radius-sm);
    font-size: 0.75rem;
    background: white;
    color: var(--color-gray-700);
}

.inbox-actions {
    display: flex;
    gap: 0.5rem;
}

.inbox-actions .btn {
    flex: 1;
    font-size: 0.75rem;
    padding: 0.375rem 0.5rem;
}

/* Form Input Small */
.form-input-sm {
    padding: 0.375rem 0.5rem;
    font-size: 0.875rem;
}

/* Checkbox Group */
.checkbox-group {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.checkbox-label {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.875rem;
    cursor: pointer;
}

.checkbox-label input[type="checkbox"] {
    width: 16px;
    height: 16px;
    cursor: pointer;
}

.checkbox-label input[type="checkbox"]:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

/* Dark Mode Public Inbox */
body.dark-mode .public-inbox-section {
    background: linear-gradient(135deg, #1e293b 0%, #0f172a 100%);
    border-color: #334155;
}

body.dark-mode .public-inbox-section h3 {
    color: #7dd3fc;
}

body.dark-mode .inbox-status-badge.inbox-disabled {
    background-color: #374151;
    color: #9ca3af;
}

body.dark-mode .inbox-link-section label {
    color: #9ca3af;
}

body.dark-mode .inbox-link-container input {
    background-color: #1f2937;
    border-color: #374151;
    color: #e5e7eb;
}

/* Form Hint */
.form-hint {
    display: block;
    margin-top: 0.25rem;
    font-size: 0.75rem;
    color: var(--color-gray-500);
}

body.dark-mode .form-hint {
    color: #9ca3af;
}

/* ============================================
   PHOTOS SECTION - Task Photo Gallery
   ============================================ */

.photos-section {
    margin-bottom: 2.5rem;
}

.photos-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 1.25rem;
}

.photos-header h2 {
    display: flex;
    align-items: center;
    gap: 0.625rem;
    margin: 0;
    font-size: 1.125rem;
    font-weight: 600;
}

.photos-header h2 i {
    color: var(--color-gray-400);
    font-size: 1rem;
}

.photo-counter {
    display: inline-flex;
    align-items: center;
    gap: 0.125rem;
    padding: 0.375rem 0.75rem;
    background: var(--color-gray-100);
    border-radius: 9999px;
    font-size: 0.8125rem;
    font-weight: 600;
    font-variant-numeric: tabular-nums;
}

.photo-counter-current {
    color: var(--color-gray-900);
}

.photo-counter-separator {
    color: var(--color-gray-400);
}

.photo-counter-max {
    color: var(--color-gray-500);
}

/* Upload Dropzone */
.photo-upload-area {
    margin-bottom: 1.5rem;
}

.photo-input-hidden {
    position: absolute;
    opacity: 0;
    pointer-events: none;
}

.photo-upload-dropzone {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 1rem;
    padding: 2.5rem 2rem;
    background: linear-gradient(135deg, var(--color-gray-50) 0%, var(--color-white) 100%);
    border: 2px dashed var(--color-gray-300);
    border-radius: var(--border-radius);
    cursor: pointer;
    transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
}

.photo-upload-dropzone::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, rgba(0, 0, 0, 0.02) 0%, transparent 100%);
    opacity: 0;
    transition: opacity 0.25s;
}

.photo-upload-dropzone:hover:not(.disabled) {
    border-color: var(--color-gray-500);
    background: linear-gradient(135deg, var(--color-gray-100) 0%, var(--color-gray-50) 100%);
    transform: translateY(-2px);
    box-shadow: 0 8px 25px -5px rgba(0, 0, 0, 0.08);
}

.photo-upload-dropzone:hover:not(.disabled)::before {
    opacity: 1;
}

.photo-upload-dropzone.disabled {
    cursor: not-allowed;
    opacity: 0.6;
    background: var(--color-gray-100);
}

.photo-upload-dropzone.drag-over {
    border-color: var(--color-black);
    background: var(--color-gray-100);
    transform: scale(1.01);
}

.photo-upload-icon {
    width: 56px;
    height: 56px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--color-white);
    border-radius: 50%;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
}

.photo-upload-icon i {
    font-size: 1.5rem;
    color: var(--color-gray-600);
    transition: transform 0.25s, color 0.25s;
}

.photo-upload-dropzone:hover:not(.disabled) .photo-upload-icon i {
    transform: translateY(-3px);
    color: var(--color-black);
}

.photo-upload-text {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.375rem;
    text-align: center;
}

.photo-upload-primary {
    font-weight: 500;
    font-size: 0.9375rem;
    color: var(--color-gray-700);
}

.photo-upload-primary.photo-limit-reached {
    color: var(--color-warning);
}

.photo-upload-hint {
    font-size: 0.8125rem;
    color: var(--color-gray-500);
}

/* Upload Progress */
.photo-progress {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-top: 1rem;
    padding: 1rem;
    background: var(--color-white);
    border-radius: var(--border-radius-sm);
    box-shadow: var(--shadow-sm);
}

.photo-progress-bar {
    flex: 1;
    height: 6px;
    background: var(--color-gray-200);
    border-radius: 3px;
    overflow: hidden;
}

.photo-progress-fill {
    height: 100%;
    width: 0%;
    background: linear-gradient(90deg, var(--color-black) 0%, var(--color-gray-700) 100%);
    border-radius: 3px;
    transition: width 0.2s ease-out;
}

.photo-progress-text {
    font-size: 0.8125rem;
    font-weight: 500;
    color: var(--color-gray-600);
    white-space: nowrap;
}

/* Upload Error */
.photo-error {
    margin-top: 0.75rem;
    padding: 0.75rem 1rem;
    background: #fef2f2;
    border: 1px solid #fecaca;
    border-radius: var(--border-radius-sm);
    color: #dc2626;
    font-size: 0.875rem;
    font-weight: 500;
}

/* Empty State */
.photo-empty-state {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 3rem 2rem;
    background: var(--color-white);
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
    text-align: center;
}

.photo-empty-icon {
    width: 64px;
    height: 64px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--color-gray-100);
    border-radius: 50%;
    margin-bottom: 1rem;
}

.photo-empty-icon i {
    font-size: 1.75rem;
    color: var(--color-gray-400);
}

.photo-empty-state p {
    color: var(--color-gray-500);
    font-size: 0.9375rem;
    margin: 0;
}

/* Photo Gallery Grid */
.photo-gallery {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: 1rem;
}

.photo-card {
    background: var(--color-white);
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
    overflow: hidden;
    transition: transform 0.25s cubic-bezier(0.4, 0, 0.2, 1), box-shadow 0.25s;
}

.photo-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 28px -8px rgba(0, 0, 0, 0.15);
}

.photo-card-image {
    position: relative;
    aspect-ratio: 1;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    background-color: var(--color-gray-100);
    cursor: pointer;
    overflow: hidden;
}

.photo-card-overlay {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.25s;
}

.photo-card-overlay i {
    color: white;
    font-size: 1.5rem;
    opacity: 0;
    transform: scale(0.8);
    transition: opacity 0.25s, transform 0.25s;
}

.photo-card-image:hover .photo-card-overlay {
    background: rgba(0, 0, 0, 0.4);
}

.photo-card-image:hover .photo-card-overlay i {
    opacity: 1;
    transform: scale(1);
}

.photo-card-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.5rem;
    padding: 0.75rem;
    border-top: 1px solid var(--color-gray-100);
}

.photo-card-info {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 0.125rem;
}

.photo-card-name {
    font-size: 0.8125rem;
    font-weight: 500;
    color: var(--color-gray-900);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.photo-card-size {
    font-size: 0.75rem;
    color: var(--color-gray-500);
}

.photo-card-delete {
    flex-shrink: 0;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: transparent;
    border: none;
    border-radius: 8px;
    color: var(--color-gray-400);
    cursor: pointer;
    transition: all 0.2s;
}

.photo-card-delete:hover {
    background: #fef2f2;
    color: #dc2626;
}

.photo-card-delete i {
    font-size: 0.875rem;
}

/* ============================================
   PHOTO LIGHTBOX - Full Screen Viewer
   ============================================ */

.photo-lightbox {
    position: fixed;
    inset: 0;
    z-index: 2000;
    display: none;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.photo-lightbox.active {
    display: flex;
    flex-direction: column;
}

.photo-lightbox.visible {
    opacity: 1;
}

.photo-lightbox-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.95);
}

.photo-lightbox-container {
    position: relative;
    z-index: 1;
    display: flex;
    flex-direction: column;
    height: 100%;
    width: 100%;
}

/* Lightbox Header */
.photo-lightbox-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1rem 1.5rem;
    background: linear-gradient(to bottom, rgba(0, 0, 0, 0.6), transparent);
}

.photo-lightbox-info {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.photo-lightbox-counter {
    padding: 0.375rem 0.75rem;
    background: rgba(255, 255, 255, 0.15);
    border-radius: 6px;
    font-size: 0.8125rem;
    font-weight: 600;
    color: white;
    font-variant-numeric: tabular-nums;
    backdrop-filter: blur(8px);
}

.photo-lightbox-filename {
    font-size: 0.875rem;
    color: rgba(255, 255, 255, 0.8);
    max-width: 300px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.photo-lightbox-actions {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.photo-lightbox-btn {
    width: 44px;
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, 0.1);
    border: none;
    border-radius: 10px;
    color: white;
    cursor: pointer;
    text-decoration: none;
    transition: all 0.2s;
    backdrop-filter: blur(8px);
}

.photo-lightbox-btn:hover {
    background: rgba(255, 255, 255, 0.2);
    transform: scale(1.05);
}

.photo-lightbox-btn i {
    font-size: 1.125rem;
}

.photo-lightbox-close:hover {
    background: rgba(239, 68, 68, 0.8);
}

/* Lightbox Content */
.photo-lightbox-content {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0 1rem;
    position: relative;
    min-height: 0;
}

.photo-lightbox-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 52px;
    height: 52px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, 0.1);
    border: none;
    border-radius: 50%;
    color: white;
    cursor: pointer;
    transition: all 0.2s;
    backdrop-filter: blur(8px);
    z-index: 10;
}

.photo-lightbox-nav:hover:not(:disabled) {
    background: rgba(255, 255, 255, 0.25);
    transform: translateY(-50%) scale(1.1);
}

.photo-lightbox-nav:disabled {
    opacity: 0.3;
    cursor: not-allowed;
}

.photo-lightbox-nav i {
    font-size: 1.25rem;
}

.photo-lightbox-prev {
    left: 1.5rem;
}

.photo-lightbox-next {
    right: 1.5rem;
}

.photo-lightbox-image-wrapper {
    position: relative;
    max-width: calc(100% - 140px);
    max-height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.photo-lightbox-loader {
    position: absolute;
    display: flex;
    align-items: center;
    justify-content: center;
}

.photo-lightbox-spinner {
    width: 40px;
    height: 40px;
    border: 3px solid rgba(255, 255, 255, 0.2);
    border-top-color: white;
    border-radius: 50%;
    animation: lightbox-spin 0.8s linear infinite;
}

@keyframes lightbox-spin {
    to { transform: rotate(360deg); }
}

.photo-lightbox-image {
    max-width: 100%;
    max-height: calc(100vh - 200px);
    object-fit: contain;
    border-radius: 4px;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.photo-lightbox-image.loaded {
    opacity: 1;
}

/* Lightbox Thumbnails */
.photo-lightbox-thumbnails {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 1rem;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.6), transparent);
    overflow-x: auto;
}

.photo-lightbox-thumb {
    width: 56px;
    height: 56px;
    flex-shrink: 0;
    background-size: cover;
    background-position: center;
    border-radius: 6px;
    cursor: pointer;
    opacity: 0.5;
    transition: all 0.2s;
    border: 2px solid transparent;
}

.photo-lightbox-thumb:hover {
    opacity: 0.8;
}

.photo-lightbox-thumb.active {
    opacity: 1;
    border-color: white;
    transform: scale(1.1);
}

/* ============================================
   PHOTOS - Dark Mode
   ============================================ */

body.dark-mode .photo-counter {
    background: var(--color-gray-800);
}

body.dark-mode .photo-counter-current {
    color: var(--color-gray-100);
}

body.dark-mode .photo-upload-dropzone {
    background: linear-gradient(135deg, var(--color-gray-800) 0%, var(--color-gray-900) 100%);
    border-color: var(--color-gray-600);
}

body.dark-mode .photo-upload-dropzone:hover:not(.disabled) {
    border-color: var(--color-gray-400);
    background: linear-gradient(135deg, var(--color-gray-700) 0%, var(--color-gray-800) 100%);
}

body.dark-mode .photo-upload-icon {
    background: var(--color-gray-700);
}

body.dark-mode .photo-upload-icon i {
    color: var(--color-gray-300);
}

body.dark-mode .photo-upload-dropzone:hover:not(.disabled) .photo-upload-icon i {
    color: white;
}

body.dark-mode .photo-upload-primary {
    color: var(--color-gray-200);
}

body.dark-mode .photo-progress {
    background: var(--color-gray-800);
}

body.dark-mode .photo-progress-bar {
    background: var(--color-gray-700);
}

body.dark-mode .photo-progress-fill {
    background: linear-gradient(90deg, white 0%, var(--color-gray-300) 100%);
}

body.dark-mode .photo-error {
    background: #450a0a;
    border-color: #7f1d1d;
    color: #fca5a5;
}

body.dark-mode .photo-empty-state {
    background: var(--color-gray-800);
}

body.dark-mode .photo-empty-icon {
    background: var(--color-gray-700);
}

body.dark-mode .photo-card {
    background: var(--color-gray-800);
}

body.dark-mode .photo-card-image {
    background-color: var(--color-gray-700);
}

body.dark-mode .photo-card-footer {
    border-top-color: var(--color-gray-700);
}

body.dark-mode .photo-card-name {
    color: var(--color-gray-100);
}

body.dark-mode .photo-card-delete:hover {
    background: #450a0a;
    color: #fca5a5;
}

/* ============================================
   PHOTOS - Responsive
   ============================================ */

@media (max-width: 768px) {
    .photos-header {
        flex-wrap: wrap;
        gap: 0.75rem;
    }

    .photo-upload-dropzone {
        padding: 2rem 1.5rem;
    }

    .photo-gallery {
        grid-template-columns: repeat(2, 1fr);
        gap: 0.75rem;
    }

    .photo-lightbox-header {
        padding: 0.75rem 1rem;
    }

    .photo-lightbox-filename {
        display: none;
    }

    .photo-lightbox-nav {
        width: 44px;
        height: 44px;
    }

    .photo-lightbox-prev {
        left: 0.5rem;
    }

    .photo-lightbox-next {
        right: 0.5rem;
    }

    .photo-lightbox-image-wrapper {
        max-width: calc(100% - 100px);
    }

    .photo-lightbox-image {
        max-height: calc(100vh - 180px);
    }

    .photo-lightbox-thumbnails {
        padding: 0.75rem;
        gap: 0.375rem;
    }

    .photo-lightbox-thumb {
        width: 44px;
        height: 44px;
    }
}

@media (max-width: 480px) {
    .photo-gallery {
        grid-template-columns: 1fr;
    }

    .photo-card-image {
        aspect-ratio: 4/3;
    }
}

/* ============================================
   SPLIT LOGIN PAGE - Swiss Brutalist Design
   ============================================ */

.auth-split-page {
    margin: 0;
    padding: 0;
    min-height: 100vh;
    background-color: var(--color-white);
}

.auth-split-container {
    display: flex;
    min-height: 100vh;
    width: 100%;
}

/* Left Brand Panel */
.auth-brand-panel {
    flex: 1;
    background-color: var(--color-black);
    background-image: url('/images/background.JPG');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow: hidden;
}

/* Dark overlay for better text contrast */
.auth-brand-panel::after {
    content: '';
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.7);
    z-index: 0;
}

/* Subtle grain texture overlay */
.auth-brand-panel::before {
    content: '';
    position: absolute;
    inset: 0;
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 400 400' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noiseFilter'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noiseFilter)'/%3E%3C/svg%3E");
    opacity: 0.05;
    pointer-events: none;
    z-index: 1;
}

/* Geometric accent line */
.auth-brand-accent {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg,
        transparent 0%,
        var(--color-gray-700) 20%,
        var(--color-white) 50%,
        var(--color-gray-700) 80%,
        transparent 100%);
    z-index: 2;
}

.auth-brand-content {
    text-align: center;
    z-index: 2;
    animation: brandFadeIn 0.8s ease-out;
}

@keyframes brandFadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.auth-brand-icon-wrapper {
    margin-bottom: 2rem;
}

.auth-brand-icon-wrapper i {
    font-size: 5rem;
    color: var(--color-white);
    filter: drop-shadow(0 4px 20px rgba(255, 255, 255, 0.1));
    animation: iconPulse 3s ease-in-out infinite;
}

@keyframes iconPulse {
    0%, 100% {
        transform: scale(1);
        opacity: 1;
    }
    50% {
        transform: scale(1.02);
        opacity: 0.9;
    }
}

.auth-brand-title {
    font-family: var(--font-sans);
    font-size: 3.5rem;
    font-weight: 800;
    color: var(--color-white);
    letter-spacing: -0.03em;
    margin-bottom: 0.75rem;
    line-height: 1;
}

.auth-brand-subtitle {
    font-family: var(--font-sans);
    font-size: 1rem;
    font-weight: 400;
    color: var(--color-gray-500);
    letter-spacing: 0.05em;
    text-transform: uppercase;
}

/* Right Form Panel */
.auth-form-panel {
    flex: 1;
    background-color: var(--color-white);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 3rem;
}

.auth-form-content {
    width: 100%;
    max-width: 380px;
    animation: formSlideIn 0.6s ease-out 0.2s both;
}

@keyframes formSlideIn {
    from {
        opacity: 0;
        transform: translateX(20px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

.auth-form-header {
    margin-bottom: 2.5rem;
}

.auth-form-title {
    font-family: var(--font-sans);
    font-size: 1.875rem;
    font-weight: 700;
    color: var(--color-black);
    letter-spacing: -0.02em;
    margin-bottom: 0.5rem;
}

.auth-form-description {
    font-size: 1rem;
    color: var(--color-gray-500);
    font-weight: 400;
}

/* Form Styles */
.auth-split-form {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.auth-input-group {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.auth-input-label {
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--color-gray-700);
    letter-spacing: 0.01em;
}

.auth-input {
    width: 100%;
    padding: 1rem 1.25rem;
    font-size: 1rem;
    font-family: var(--font-sans);
    color: var(--color-black);
    background-color: var(--color-gray-50);
    border: 2px solid transparent;
    border-radius: var(--border-radius);
    outline: none;
    transition: all 0.2s ease;
}

.auth-input::placeholder {
    color: var(--color-gray-400);
}

.auth-input:hover {
    background-color: var(--color-gray-100);
}

.auth-input:focus {
    background-color: var(--color-white);
    border-color: var(--color-black);
    box-shadow: 0 0 0 4px rgba(0, 0, 0, 0.05);
}

/* Submit Button */
.auth-submit-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    width: 100%;
    padding: 1rem 1.5rem;
    margin-top: 0.5rem;
    font-size: 1rem;
    font-weight: 600;
    font-family: var(--font-sans);
    color: var(--color-white);
    background-color: var(--color-black);
    border: none;
    border-radius: var(--border-radius);
    cursor: pointer;
    transition: all 0.2s ease;
}

.auth-submit-btn:hover {
    background-color: var(--color-gray-800);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.auth-submit-btn:active {
    transform: translateY(0);
    box-shadow: none;
}

.auth-submit-btn i {
    font-size: 0.875rem;
    transition: transform 0.2s ease;
}

.auth-submit-btn:hover i {
    transform: translateX(4px);
}

/* Form Footer */
.auth-form-footer {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    margin-top: 2rem;
    padding-top: 2rem;
    border-top: 1px solid var(--color-gray-200);
    font-size: 0.9375rem;
    color: var(--color-gray-500);
}

.auth-register-link {
    color: var(--color-black);
    font-weight: 600;
    text-decoration: none;
    position: relative;
}

.auth-register-link::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 100%;
    height: 2px;
    background-color: var(--color-black);
    transform: scaleX(0);
    transform-origin: right;
    transition: transform 0.3s ease;
}

.auth-register-link:hover::after {
    transform: scaleX(1);
    transform-origin: left;
}

/* TaskBox Section */
.auth-taskbox-container {
    margin-top: 2rem;
}

.auth-taskbox-divider {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1.5rem;
    color: var(--color-gray-400);
    font-size: 0.875rem;
    text-transform: lowercase;
}

.auth-taskbox-divider::before,
.auth-taskbox-divider::after {
    content: '';
    flex: 1;
    height: 1px;
    background-color: var(--color-gray-200);
}

.auth-taskbox-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.625rem;
    width: 100%;
    padding: 0.875rem 1.25rem;
    font-size: 0.9375rem;
    font-weight: 500;
    font-family: var(--font-sans);
    color: var(--color-gray-700);
    background-color: var(--color-white);
    border: 2px solid var(--color-gray-200);
    border-radius: var(--border-radius);
    cursor: pointer;
    transition: all 0.2s ease;
}

.auth-taskbox-btn:hover {
    color: var(--color-black);
    border-color: var(--color-gray-300);
    background-color: var(--color-gray-50);
}

.auth-taskbox-btn i {
    font-size: 1rem;
    color: var(--color-gray-500);
    transition: color 0.2s ease;
}

.auth-taskbox-btn:hover i {
    color: var(--color-black);
}

/* Alert Overrides for Split Form */
.auth-form-content .alert {
    margin-bottom: 1.5rem;
    padding: 1rem 1.25rem;
    border-radius: var(--border-radius);
    font-size: 0.9375rem;
    font-weight: 500;
}

.auth-form-content .alert-success {
    background-color: #ecfdf5;
    color: #065f46;
    border: 1px solid #a7f3d0;
}

.auth-form-content .alert-error {
    background-color: #fef2f2;
    color: #991b1b;
    border: 1px solid #fecaca;
}

/* Responsive Design */
@media (max-width: 1024px) {
    .auth-brand-title {
        font-size: 2.75rem;
    }

    .auth-brand-icon-wrapper i {
        font-size: 4rem;
    }
}

@media (max-width: 768px) {
    .auth-split-container {
        flex-direction: column;
    }

    .auth-brand-panel {
        flex: none;
        min-height: 35vh;
        padding: 3rem 2rem;
    }

    .auth-brand-accent {
        display: none;
    }

    .auth-brand-icon-wrapper i {
        font-size: 3.5rem;
    }

    .auth-brand-title {
        font-size: 2.25rem;
    }

    .auth-brand-subtitle {
        font-size: 0.875rem;
    }

    .auth-form-panel {
        flex: 1;
        padding: 2.5rem 1.5rem;
        align-items: flex-start;
        padding-top: 2rem;
    }

    .auth-form-content {
        max-width: 100%;
    }

    .auth-form-header {
        margin-bottom: 2rem;
    }

    .auth-form-title {
        font-size: 1.5rem;
    }
}

@media (max-width: 480px) {
    .auth-brand-panel {
        min-height: 30vh;
        padding: 2rem 1.5rem;
    }

    .auth-brand-icon-wrapper {
        margin-bottom: 1.25rem;
    }

    .auth-brand-icon-wrapper i {
        font-size: 2.75rem;
    }

    .auth-brand-title {
        font-size: 1.875rem;
    }

    .auth-form-panel {
        padding: 2rem 1.25rem;
    }

    .auth-input {
        padding: 0.875rem 1rem;
    }

    .auth-submit-btn {
        padding: 0.875rem 1.25rem;
    }
}

/* ============================================
   PROGRESSIVE DISCLOSURE LOGIN STEPS
   ============================================ */

/* Step Container */
.auth-step {
    display: none;
    opacity: 0;
    transform: translateY(10px);
    transition: opacity 0.25s ease, transform 0.25s ease;
}

.auth-step-active {
    display: block;
    opacity: 1;
    transform: translateY(0);
}

.auth-step-exit {
    display: none;
    opacity: 0;
    transform: translateY(-10px);
    pointer-events: none;
}

/* Continue Button */
.auth-continue-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    width: 100%;
    padding: 1rem 1.5rem;
    margin-top: 1.5rem;
    font-size: 1rem;
    font-weight: 600;
    font-family: var(--font-sans);
    color: var(--color-white);
    background-color: var(--color-black);
    border: none;
    border-radius: var(--border-radius);
    cursor: pointer;
    transition: all 0.2s ease;
}

.auth-continue-btn:hover {
    background-color: var(--color-gray-800);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.auth-continue-btn:active {
    transform: translateY(0);
    box-shadow: none;
}

.auth-continue-btn i {
    font-size: 0.875rem;
    transition: transform 0.2s ease;
}

.auth-continue-btn:hover i {
    transform: translateX(4px);
}

/* Email Display (Step 2) */
.auth-email-display {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1rem 1.25rem;
    margin-bottom: 1.5rem;
    background-color: var(--color-gray-50);
    border-radius: var(--border-radius);
    border: 1px solid var(--color-gray-200);
}

.auth-email-info {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    color: var(--color-gray-700);
    font-weight: 500;
    font-size: 0.9375rem;
    min-width: 0;
}

.auth-email-info i {
    font-size: 1.25rem;
    color: var(--color-gray-400);
    flex-shrink: 0;
}

.auth-email-info span {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

/* Back Button */
.auth-back-btn {
    display: flex;
    align-items: center;
    gap: 0.375rem;
    padding: 0.5rem 0.75rem;
    font-size: 0.8125rem;
    font-weight: 500;
    font-family: var(--font-sans);
    color: var(--color-gray-500);
    background: transparent;
    border: none;
    border-radius: var(--border-radius-sm);
    cursor: pointer;
    transition: all 0.15s ease;
    flex-shrink: 0;
}

.auth-back-btn:hover {
    color: var(--color-black);
    background-color: var(--color-gray-100);
}

.auth-back-btn i {
    font-size: 0.6875rem;
}

/* Input Error State */
.auth-input-error {
    display: block;
    margin-top: 0.5rem;
    font-size: 0.8125rem;
    color: var(--color-error);
    opacity: 0;
    transform: translateY(-5px);
    transition: opacity 0.2s ease, transform 0.2s ease;
    height: 0;
    overflow: hidden;
}

.auth-error-visible {
    opacity: 1;
    transform: translateY(0);
    height: auto;
    margin-top: 0.5rem;
}

.auth-input-error-state {
    border-color: var(--color-error) !important;
    background-color: #fef2f2 !important;
}

.auth-input-error-state:focus {
    box-shadow: 0 0 0 4px rgba(239, 68, 68, 0.1) !important;
}

/* Shake Animation */
@keyframes authShake {
    0%, 100% { transform: translateX(0); }
    10%, 30%, 50%, 70%, 90% { transform: translateX(-4px); }
    20%, 40%, 60%, 80% { transform: translateX(4px); }
}

.auth-shake {
    animation: authShake 0.5s ease;
}

/* Header Fade Animation */
.auth-header-fade-out {
    opacity: 0;
    transform: translateY(-8px);
    transition: opacity 0.2s ease, transform 0.2s ease;
}

.auth-header-fade-in {
    animation: authHeaderFadeIn 0.3s ease;
}

@keyframes authHeaderFadeIn {
    from {
        opacity: 0;
        transform: translateY(8px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Responsive Adjustments */
@media (max-width: 480px) {
    .auth-email-display {
        padding: 0.875rem 1rem;
    }

    .auth-email-info {
        font-size: 0.875rem;
    }

    .auth-continue-btn {
        padding: 0.875rem 1.25rem;
    }
}

/* ============================================
   DASHBOARD CUSTOMIZATION
   ============================================ */

/* Header Actions Container */
.header-actions {
    display: flex;
    gap: 0.75rem;
    align-items: center;
}

/* Customize Dashboard Modal */
.dialog-customize-dashboard {
    max-width: 500px;
}

.dialog-description {
    color: var(--color-gray-600);
    margin-bottom: 1rem;
    font-size: 0.875rem;
}

.dashboard-components-list {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.dashboard-component-item {
    display: flex;
    align-items: center;
    padding: 0.75rem 1rem;
    background: var(--color-white);
    border: 1px solid var(--color-gray-200);
    border-radius: var(--border-radius-sm);
    cursor: grab;
    transition: all 0.2s ease;
    user-select: none;
}

.dashboard-component-item:hover {
    background: var(--color-gray-50);
    border-color: var(--color-gray-300);
}

.dashboard-component-item.dragging {
    opacity: 0.5;
    cursor: grabbing;
}

.dashboard-component-item.drag-over {
    border-color: var(--color-black);
    background: rgba(0, 0, 0, 0.02);
}

.component-drag-handle {
    color: var(--color-gray-400);
    margin-right: 0.75rem;
    cursor: grab;
}

.component-name {
    flex: 1;
    font-weight: 500;
    color: var(--color-gray-900);
}

/* Toggle Switch */
.component-toggle {
    position: relative;
    width: 44px;
    height: 24px;
    flex-shrink: 0;
}

.component-toggle input {
    opacity: 0;
    width: 0;
    height: 0;
}

.toggle-slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: var(--color-gray-300);
    transition: 0.3s;
    border-radius: 24px;
}

.toggle-slider:before {
    position: absolute;
    content: "";
    height: 18px;
    width: 18px;
    left: 3px;
    bottom: 3px;
    background-color: white;
    transition: 0.3s;
    border-radius: 50%;
    box-shadow: var(--shadow-sm);
}

.component-toggle input:checked + .toggle-slider {
    background-color: var(--color-black);
}

.component-toggle input:checked + .toggle-slider:before {
    transform: translateX(20px);
}

/* Dark mode overrides for dashboard customization */
body.dark-mode .dashboard-component-item {
    background: #2a2a2a;
    border-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .dashboard-component-item:hover {
    background: #333;
    border-color: rgba(255, 255, 255, 0.2);
}

body.dark-mode .dashboard-component-item.drag-over {
    border-color: var(--color-white);
    background: rgba(255, 255, 255, 0.05);
}

body.dark-mode .component-name {
    color: #e5e5e5;
}

body.dark-mode .component-drag-handle {
    color: #666;
}

body.dark-mode .toggle-slider {
    background-color: #555;
}

body.dark-mode .component-toggle input:checked + .toggle-slider {
    background-color: var(--color-white);
}

body.dark-mode .component-toggle input:checked + .toggle-slider:before {
    background-color: #333;
}

body.dark-mode .dialog-description {
    color: #888;
}

/* Responsive adjustments for header actions */
@media (max-width: 600px) {
    .header-actions {
        gap: 0.5rem;
    }

    .header-actions .btn span {
        display: none;
    }

    .header-actions .btn {
        padding: 0.5rem 0.75rem;
    }
}
/* ============================================
   MEETINGS FEATURE STYLES
   ============================================ */

/* Meeting List Page */
.meetings-container {
    padding: 2rem;
    max-width: 1400px;
    margin: 0 auto;
}

.meetings-section {
    margin-bottom: 2.5rem;
}

.section-title {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--color-gray-700);
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.section-title i {
    color: var(--color-gray-500);
}

.status-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background-color: var(--color-gray-400);
}

.status-dot.in-progress {
    background-color: #22c55e;
    animation: pulse 2s ease-in-out infinite;
}

@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.5; }
}

.meetings-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 1rem;
}

.meetings-grid.past {
    opacity: 0.7;
}

.meeting-card {
    background: white;
    border: 1px solid var(--color-gray-200);
    border-radius: 12px;
    padding: 1rem;
    transition: all 0.2s ease;
}

.meeting-card:hover {
    border-color: var(--color-gray-300);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
}

.meeting-card.in-progress {
    border-color: #22c55e;
    box-shadow: 0 0 0 1px rgba(34, 197, 94, 0.2);
}

.meeting-card.past {
    opacity: 0.7;
}

.meeting-card-link {
    text-decoration: none;
    color: inherit;
    display: block;
}

.meeting-card-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 0.75rem;
}

.meeting-name {
    font-size: 1rem;
    font-weight: 600;
    color: var(--color-gray-900);
    margin: 0;
}

.meeting-status-badge {
    font-size: 0.7rem;
    padding: 0.25rem 0.5rem;
    border-radius: 9999px;
    background: var(--color-gray-100);
    color: var(--color-gray-600);
}

.meeting-status-badge.in-progress {
    background: #dcfce7;
    color: #166534;
}

.meeting-recurrence-badge {
    color: var(--color-gray-500);
    font-size: 0.875rem;
}

.meeting-card-date,
.meeting-card-time {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.875rem;
    color: var(--color-gray-600);
    margin-bottom: 0.5rem;
}

.meeting-card-date i,
.meeting-card-time i {
    width: 16px;
    color: var(--color-gray-400);
}

.meeting-card-participants {
    margin-top: 0.75rem;
    padding-top: 0.75rem;
    border-top: 1px solid var(--color-gray-100);
}

.participant-avatars {
    display: flex;
    gap: -8px;
}

.participant-avatar {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: var(--color-gray-200);
    color: var(--color-gray-600);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.75rem;
    font-weight: 600;
    border: 2px solid white;
    margin-left: -8px;
}

.participant-avatar:first-child {
    margin-left: 0;
}

.participant-avatar.owner {
    background: var(--color-gray-900);
    color: white;
}

.participant-avatar.more {
    background: var(--color-gray-300);
    font-size: 0.65rem;
}

/* Meeting Detail Page */
.meeting-detail-container {
    padding: 2rem;
    max-width: 1200px;
    margin: 0 auto;
}

.meeting-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 1.5rem;
    gap: 2rem;
}

.meeting-header-left {
    flex: 1;
}

.back-link {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--color-gray-500);
    text-decoration: none;
    font-size: 0.875rem;
    margin-bottom: 0.5rem;
}

.back-link:hover {
    color: var(--color-gray-700);
}

.meeting-title {
    font-size: 1.75rem;
    font-weight: 700;
    color: var(--color-gray-900);
    margin: 0 0 0.5rem 0;
}

.meeting-description {
    color: var(--color-gray-600);
    margin: 0;
}

.meeting-header-right {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 1rem;
}

.meeting-actions {
    display: flex;
    gap: 0.5rem;
}

/* Meeting Info Bar */
.meeting-info-bar {
    display: flex;
    flex-wrap: wrap;
    gap: 1.5rem;
    padding: 1rem;
    background: var(--color-gray-50);
    border-radius: 8px;
    margin-bottom: 1.5rem;
}

.meeting-info-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.875rem;
    color: var(--color-gray-700);
}

.meeting-info-item i {
    color: var(--color-gray-500);
}

/* Participants Bar */
.meeting-participants-bar {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1rem;
    background: white;
    border: 1px solid var(--color-gray-200);
    border-radius: 8px;
    margin-bottom: 1.5rem;
    flex-wrap: wrap;
}

.bar-project-section {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--color-gray-600);
}

.bar-project-section i {
    font-size: 0.875rem;
}

.bar-project-select {
    padding: 0.375rem 0.75rem;
    font-size: 0.875rem;
    border: 1px solid var(--color-gray-300);
    border-radius: 6px;
    background: white;
    color: var(--color-gray-900);
    cursor: pointer;
    min-width: 140px;
    transition: border-color 0.2s;
}

.bar-project-select:focus {
    outline: none;
    border-color: var(--color-gray-500);
}

.bar-project-select:hover {
    border-color: var(--color-gray-400);
}

.bar-divider {
    width: 1px;
    height: 24px;
    background: var(--color-gray-300);
}

.participants-label {
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--color-gray-600);
}

.participant-list {
    display: flex;
    gap: 0.5rem;
    overflow-x: auto;
    flex: 1;
    padding: 0.25rem 0;
    scrollbar-width: thin;
    min-width: 0;
}

.participant-list::-webkit-scrollbar {
    height: 4px;
}

.participant-list::-webkit-scrollbar-track {
    background: var(--color-gray-100);
    border-radius: 2px;
}

.participant-list::-webkit-scrollbar-thumb {
    background: var(--color-gray-300);
    border-radius: 2px;
}

.participant-chip {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.25rem 0.75rem 0.25rem 0.25rem;
    background: var(--color-gray-100);
    border-radius: 9999px;
    font-size: 0.875rem;
    flex-shrink: 0;
    white-space: nowrap;
}

.participant-chip.owner {
    background: var(--color-gray-900);
    color: white;
}

.participant-avatar-sm {
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: var(--color-gray-300);
    color: var(--color-gray-700);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.7rem;
    font-weight: 600;
}

.participant-chip.owner .participant-avatar-sm {
    background: rgba(255, 255, 255, 0.2);
    color: white;
}

.owner-badge {
    font-size: 0.65rem;
    font-weight: 600;
    text-transform: uppercase;
    opacity: 0.7;
}

/* Participant Add Dropdown */
.participant-add-dropdown {
    display: none;
    position: relative;
}

.participant-add-dropdown.active {
    display: block;
}

.participant-add-dropdown select {
    min-width: 180px;
    padding: 0.375rem 0.75rem;
    font-size: 0.875rem;
    border: 1px solid var(--color-gray-300);
    border-radius: 6px;
    background: white;
    color: var(--color-gray-900);
    cursor: pointer;
}

.participant-add-dropdown select:focus {
    outline: none;
    border-color: var(--color-gray-400);
}

/* Removable Participant Chip */
.participant-chip.removable {
    padding-right: 0.25rem;
}

.participant-remove-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 20px;
    height: 20px;
    border: none;
    background: transparent;
    color: var(--color-gray-400);
    cursor: pointer;
    border-radius: 50%;
    transition: all 0.15s;
    margin-left: 0.25rem;
}

.participant-remove-btn:hover {
    background: rgba(239, 68, 68, 0.1);
    color: #ef4444;
}

/* Meeting Tabs */
.meeting-tabs {
    display: flex;
    gap: 0.5rem;
    padding: 0.5rem;
    background: var(--color-gray-100);
    border-radius: 10px;
    margin-bottom: 1.5rem;
}

.meeting-tab {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.625rem 1rem;
    background: transparent;
    border: none;
    border-radius: 6px;
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--color-gray-600);
    cursor: pointer;
    transition: all 0.2s ease;
}

.meeting-tab:hover {
    background: rgba(255, 255, 255, 0.5);
    color: var(--color-gray-900);
}

.meeting-tab.active {
    background: white;
    color: var(--color-gray-900);
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

.meeting-tab i {
    font-size: 0.875rem;
}

.tab-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 20px;
    height: 20px;
    padding: 0 6px;
    background: var(--color-gray-200);
    border-radius: 10px;
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--color-gray-700);
}

.meeting-tab.active .tab-badge {
    background: var(--color-gray-900);
    color: white;
}

/* Meeting Tab Content */
.meeting-tab-content {
    display: none;
}

.meeting-tab-content.active {
    display: block;
}

/* Meeting Tasks Bar */
.meeting-tasks-bar {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 0.75rem 1rem;
    background: white;
    border: 1px solid var(--color-gray-200);
    border-radius: 8px;
    margin-bottom: 1.5rem;
}

.tasks-bar-label {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--color-gray-600);
    flex-shrink: 0;
}

.tasks-bar-label i {
    color: var(--color-gray-500);
}

.meeting-tasks-bar .btn-sm {
    flex-shrink: 0;
}

.meeting-tasks-bar .meeting-tasks-list {
    flex: 1;
    min-width: 0;
}

/* Meeting Content Grid */
.meeting-content-grid {
    display: grid;
    grid-template-columns: 1fr 350px;
    gap: 1.5rem;
}

.meeting-main-content {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.meeting-sidebar {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

/* Section Header */
.section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
}

.section-header h3 {
    font-size: 1rem;
    font-weight: 600;
    color: var(--color-gray-900);
    margin: 0;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.section-header h3 i {
    color: var(--color-gray-500);
}

/* Project Section */
.meeting-project-section {
    background: white;
    border: 1px solid var(--color-gray-200);
    border-radius: 12px;
    padding: 1.25rem;
}

.project-selector {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.project-hint {
    font-size: 0.75rem;
    color: var(--color-gray-500);
    margin: 0;
}

/* Notes Section */
.meeting-notes-section {
    background: white;
    border: 1px solid var(--color-gray-200);
    border-radius: 12px;
    padding: 1.25rem;
    flex: 1;
}

.notes-status {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.75rem;
    color: var(--color-gray-500);
}

.notes-status .status-indicator {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--color-gray-400);
}

.notes-status.saving .status-indicator {
    background: #f59e0b;
    animation: pulse 1s ease-in-out infinite;
}

.notes-status.saved .status-indicator {
    background: #22c55e;
}

.notes-status.error .status-indicator {
    background: #ef4444;
}

.notes-editor-container {
    border: 1px solid var(--color-gray-200);
    border-radius: 8px;
    overflow: hidden;
}

.notes-toolbar {
    display: flex;
    align-items: center;
    gap: 0.25rem;
    padding: 0.5rem;
    background: var(--color-gray-50);
    border-bottom: 1px solid var(--color-gray-200);
}

.toolbar-btn {
    width: 32px;
    height: 32px;
    border: none;
    background: transparent;
    color: var(--color-gray-600);
    border-radius: 6px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
}

.toolbar-btn:hover {
    background: var(--color-gray-200);
    color: var(--color-gray-900);
}

.toolbar-btn.active {
    background: var(--color-gray-900);
    color: white;
}

.toolbar-divider {
    width: 1px;
    height: 20px;
    background: var(--color-gray-300);
    margin: 0 0.5rem;
}

.notes-editor {
    width: 100%;
    min-height: 300px;
    padding: 1rem;
    border: none;
    outline: none;
    resize: vertical;
    font-family: 'Monaco', 'Menlo', 'Ubuntu Mono', monospace;
    font-size: 0.875rem;
    line-height: 1.6;
}

.notes-preview {
    padding: 1rem;
    min-height: 300px;
    font-size: 0.875rem;
    line-height: 1.6;
}

.notes-preview h1,
.notes-preview h2,
.notes-preview h3 {
    margin-top: 1rem;
    margin-bottom: 0.5rem;
}

.notes-preview p {
    margin-bottom: 0.5rem;
}

.notes-preview ul {
    padding-left: 1.5rem;
    margin-bottom: 0.5rem;
}

.notes-preview code {
    background: var(--color-gray-100);
    padding: 0.125rem 0.375rem;
    border-radius: 4px;
    font-size: 0.85em;
}

.notes-preview pre {
    background: var(--color-gray-100);
    padding: 1rem;
    border-radius: 8px;
    overflow-x: auto;
}

.notes-preview pre code {
    background: transparent;
    padding: 0;
}

.empty-preview {
    color: var(--color-gray-400);
    font-style: italic;
}

/* Task Section */
.meeting-task-section {
    background: white;
    border: 1px solid var(--color-gray-200);
    border-radius: 12px;
    padding: 1.25rem;
}

.meeting-task-section.disabled {
    opacity: 0.5;
    pointer-events: none;
}

.disabled-hint {
    color: var(--color-gray-500);
    font-size: 0.875rem;
    margin: 0;
}

.task-section-content {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.meeting-tasks-list {
    display: flex;
    gap: 0.5rem;
    overflow-x: auto;
    flex: 1;
    padding: 0.25rem 0;
    scrollbar-width: thin;
}

.meeting-tasks-list::-webkit-scrollbar {
    height: 4px;
}

.meeting-tasks-list::-webkit-scrollbar-track {
    background: var(--color-gray-100);
    border-radius: 2px;
}

.meeting-tasks-list::-webkit-scrollbar-thumb {
    background: var(--color-gray-300);
    border-radius: 2px;
}

.meeting-task-tag {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 0.75rem;
    background: var(--color-gray-100);
    border-radius: 6px;
    cursor: pointer;
    white-space: nowrap;
    flex-shrink: 0;
    font-size: 0.875rem;
    transition: background 0.15s, transform 0.15s;
}

.meeting-task-tag:hover {
    background: var(--color-gray-200);
    transform: translateY(-1px);
}

.meeting-task-tag.task-tag-new {
    animation: taskTagSlideIn 0.3s ease;
}

@keyframes taskTagSlideIn {
    from {
        opacity: 0;
        transform: translateX(20px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

.task-tag-color {
    width: 8px;
    height: 8px;
    border-radius: 2px;
    flex-shrink: 0;
}

.task-tag-name {
    color: var(--color-gray-700);
}

.task-tag-status {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    flex-shrink: 0;
}

.task-tag-status.todo { background: #6b7280; }
.task-tag-status.in_progress { background: #3b82f6; }
.task-tag-status.done { background: #22c55e; }
.task-tag-status.blocked { background: #ef4444; }

.create-task-form .form-row {
    display: flex;
    gap: 0.75rem;
    align-items: center;
}

.create-task-form .form-input {
    flex: 1;
}

/* Activity Feed Section */
/* Meeting Description Card */
.meeting-description-card {
    background: white;
    border: 1px solid var(--color-gray-200);
    border-radius: 12px;
    padding: 1.25rem;
}

.meeting-description-card .description-text {
    color: var(--color-gray-600);
    font-size: 0.875rem;
    line-height: 1.6;
    margin: 0;
}

.activity-feed-section {
    background: white;
    border: 1px solid var(--color-gray-200);
    border-radius: 12px;
    padding: 1.25rem;
    height: fit-content;
    max-height: 600px;
    display: flex;
    flex-direction: column;
}

.activity-feed {
    flex: 1;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.activity-item {
    display: flex;
    gap: 0.75rem;
    padding: 0.75rem;
    background: var(--color-gray-50);
    border-radius: 8px;
    animation: slideIn 0.3s ease;
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.activity-item.activity-new {
    background: #eff6ff;
}

.activity-icon {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: var(--color-gray-200);
    color: var(--color-gray-600);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.75rem;
    flex-shrink: 0;
}

.activity-item.USER_ENTERED .activity-icon {
    background: #dcfce7;
    color: #166534;
}

.activity-item.USER_EXITED .activity-icon {
    background: #fee2e2;
    color: #991b1b;
}

.activity-item.NOTES_UPDATED .activity-icon {
    background: #dbeafe;
    color: #1e40af;
}

.activity-item.TASK_CREATED .activity-icon {
    background: #fef3c7;
    color: #92400e;
}

.activity-content {
    flex: 1;
    min-width: 0;
}

.activity-description {
    font-size: 0.875rem;
    color: var(--color-gray-700);
    display: block;
}

.activity-time {
    font-size: 0.75rem;
    color: var(--color-gray-500);
}

.empty-activity {
    text-align: center;
    padding: 2rem;
    color: var(--color-gray-500);
}

/* Empty State */
.empty-state {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 3rem;
    color: var(--color-gray-500);
}

.empty-state i {
    font-size: 3rem;
    margin-bottom: 1rem;
    color: var(--color-gray-300);
}

/* Meeting Modal */
#createMeetingModal,
#editMeetingModal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(4px);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    padding: 1rem;
}

#createMeetingModal.active,
#editMeetingModal.active {
    display: flex;
}

#createMeetingModal .modal-content,
#editMeetingModal .modal-content {
    position: relative;
    background: white;
    border-radius: 12px;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
    width: 100%;
    max-width: 560px;
    max-height: 90vh;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    animation: modalFadeIn 0.2s ease;
}

#createMeetingModal .modal-content.modal-lg,
#editMeetingModal .modal-content.modal-lg {
    max-width: 640px;
}

#createMeetingModal .modal-header,
#editMeetingModal .modal-header {
    padding: 1.25rem 1.5rem;
    border-bottom: 1px solid var(--color-gray-200);
    display: flex;
    align-items: center;
    justify-content: space-between;
}

#createMeetingModal .modal-header h2,
#editMeetingModal .modal-header h2 {
    font-size: 1.125rem;
    font-weight: 600;
    margin: 0;
}

#createMeetingModal .modal-close,
#editMeetingModal .modal-close {
    width: 32px;
    height: 32px;
    border: none;
    background: transparent;
    color: var(--color-gray-500);
    cursor: pointer;
    border-radius: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
}

#createMeetingModal .modal-close:hover,
#editMeetingModal .modal-close:hover {
    background: var(--color-gray-100);
    color: var(--color-gray-900);
}

#createMeetingModal .modal-body,
#editMeetingModal .modal-body {
    padding: 1.5rem;
    overflow-y: auto;
    flex: 1;
}

#createMeetingModal .modal-footer,
#editMeetingModal .modal-footer {
    padding: 1rem 1.5rem;
    border-top: 1px solid var(--color-gray-200);
    display: flex;
    justify-content: flex-end;
    gap: 0.75rem;
    background: var(--color-gray-50);
}

#createMeetingModal .form-group,
#editMeetingModal .form-group {
    margin-bottom: 1rem;
}

#createMeetingModal .form-group label,
#editMeetingModal .form-group label {
    display: block;
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--color-gray-700);
    margin-bottom: 0.5rem;
}

#createMeetingModal .form-row,
#editMeetingModal .form-row {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1rem;
}

#createMeetingModal .form-input,
#editMeetingModal .form-input,
#createMeetingModal .form-select,
#editMeetingModal .form-select {
    width: 100%;
    padding: 0.625rem 0.875rem;
    font-size: 0.875rem;
    border: 1px solid var(--color-gray-300);
    border-radius: 8px;
    background: white;
    transition: border-color 0.2s;
}

#createMeetingModal .form-input:focus,
#editMeetingModal .form-input:focus,
#createMeetingModal .form-select:focus,
#editMeetingModal .form-select:focus {
    outline: none;
    border-color: var(--color-gray-900);
}

#createMeetingModal textarea.form-input,
#editMeetingModal textarea.form-input {
    resize: vertical;
    min-height: 80px;
}

/* Dark mode modal styles */
body.dark-mode #createMeetingModal,
body.dark-mode #editMeetingModal {
    background: rgba(0, 0, 0, 0.7);
}

body.dark-mode #createMeetingModal .modal-content,
body.dark-mode #editMeetingModal .modal-content {
    background: #171717;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

body.dark-mode #createMeetingModal .modal-header,
body.dark-mode #editMeetingModal .modal-header {
    border-bottom-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode #createMeetingModal .modal-header h2,
body.dark-mode #editMeetingModal .modal-header h2 {
    color: #fafafa;
}

body.dark-mode #createMeetingModal .modal-close,
body.dark-mode #editMeetingModal .modal-close {
    color: #a3a3a3;
}

body.dark-mode #createMeetingModal .modal-close:hover,
body.dark-mode #editMeetingModal .modal-close:hover {
    background: #262626;
    color: #fafafa;
}

body.dark-mode #createMeetingModal .modal-footer,
body.dark-mode #editMeetingModal .modal-footer {
    background: #0a0a0f;
    border-top-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode #createMeetingModal .form-group label,
body.dark-mode #editMeetingModal .form-group label {
    color: #a3a3a3;
}

body.dark-mode #createMeetingModal .form-input,
body.dark-mode #editMeetingModal .form-input,
body.dark-mode #createMeetingModal .form-select,
body.dark-mode #editMeetingModal .form-select {
    background: #262626;
    border-color: rgba(255, 255, 255, 0.1);
    color: #e5e5e5;
}

body.dark-mode #createMeetingModal .form-input:focus,
body.dark-mode #editMeetingModal .form-input:focus,
body.dark-mode #createMeetingModal .form-select:focus,
body.dark-mode #editMeetingModal .form-select:focus {
    border-color: rgba(255, 255, 255, 0.3);
}

/* Create Task Modal */
#createTaskModal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(4px);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    padding: 1rem;
}

#createTaskModal.active {
    display: flex;
}

#createTaskModal .modal-content {
    position: relative;
    background: white;
    border-radius: 12px;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
    width: 100%;
    max-width: 560px;
    max-height: 90vh;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    animation: modalFadeIn 0.2s ease;
}

#createTaskModal .modal-content.modal-lg {
    max-width: 640px;
}

#createTaskModal .modal-header {
    padding: 1.25rem 1.5rem;
    border-bottom: 1px solid var(--color-gray-200);
    display: flex;
    align-items: center;
    justify-content: space-between;
}

#createTaskModal .modal-header h2 {
    font-size: 1.125rem;
    font-weight: 600;
    margin: 0;
}

#createTaskModal .modal-close {
    width: 32px;
    height: 32px;
    border: none;
    background: transparent;
    color: var(--color-gray-500);
    cursor: pointer;
    border-radius: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
}

#createTaskModal .modal-close:hover {
    background: var(--color-gray-100);
    color: var(--color-gray-900);
}

#createTaskModal .modal-body {
    padding: 1.5rem;
    overflow-y: auto;
    flex: 1;
}

#createTaskModal .modal-footer {
    padding: 1rem 1.5rem;
    border-top: 1px solid var(--color-gray-200);
    display: flex;
    justify-content: flex-end;
    gap: 0.75rem;
    background: var(--color-gray-50);
}

#createTaskModal .form-group {
    margin-bottom: 1rem;
}

#createTaskModal .form-group label {
    display: block;
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--color-gray-700);
    margin-bottom: 0.5rem;
}

#createTaskModal .form-input,
#createTaskModal .form-select {
    width: 100%;
    padding: 0.625rem 0.875rem;
    font-size: 0.875rem;
    border: 1px solid var(--color-gray-300);
    border-radius: 8px;
    background: white;
    transition: border-color 0.2s;
}

#createTaskModal .form-input:focus,
#createTaskModal .form-select:focus {
    outline: none;
    border-color: var(--color-gray-900);
}

#createTaskModal textarea.form-input {
    resize: vertical;
    min-height: 80px;
}

/* Assignee Checkboxes */
.assignee-checkboxes {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.assignee-checkbox {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 0.75rem;
    background: var(--color-gray-100);
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.15s ease;
    border: 2px solid transparent;
}

.assignee-checkbox:hover {
    background: var(--color-gray-200);
}

.assignee-checkbox input[type="checkbox"] {
    display: none;
}

.assignee-checkbox input[type="checkbox"]:checked + .assignee-avatar {
    background: var(--color-gray-900);
    color: white;
}

.assignee-checkbox:has(input:checked) {
    border-color: var(--color-gray-900);
    background: var(--color-gray-50);
}

.assignee-avatar {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: var(--color-gray-300);
    color: var(--color-gray-700);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.75rem;
    font-weight: 600;
    transition: all 0.15s ease;
}

.assignee-name {
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--color-gray-700);
}

.assignee-badge {
    font-size: 0.625rem;
    font-weight: 600;
    text-transform: uppercase;
    padding: 0.125rem 0.375rem;
    background: var(--color-gray-200);
    color: var(--color-gray-600);
    border-radius: 4px;
}

/* Dark mode - Create Task Modal */
body.dark-mode #createTaskModal {
    background: rgba(0, 0, 0, 0.7);
}

body.dark-mode #createTaskModal .modal-content {
    background: #171717;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

body.dark-mode #createTaskModal .modal-header {
    border-bottom-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode #createTaskModal .modal-header h2 {
    color: #fafafa;
}

body.dark-mode #createTaskModal .modal-close {
    color: #a3a3a3;
}

body.dark-mode #createTaskModal .modal-close:hover {
    background: #262626;
    color: #fafafa;
}

body.dark-mode #createTaskModal .modal-footer {
    background: #0a0a0f;
    border-top-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode #createTaskModal .form-group label {
    color: #a3a3a3;
}

body.dark-mode #createTaskModal .form-input,
body.dark-mode #createTaskModal .form-select {
    background: #262626;
    border-color: rgba(255, 255, 255, 0.1);
    color: #e5e5e5;
}

body.dark-mode #createTaskModal .form-input:focus,
body.dark-mode #createTaskModal .form-select:focus {
    border-color: rgba(255, 255, 255, 0.3);
}

/* Dark mode - Assignee Checkboxes */
body.dark-mode .assignee-checkboxes .assignee-checkbox {
    background: #262626;
}

body.dark-mode .assignee-checkboxes .assignee-checkbox:hover {
    background: #333333;
}

body.dark-mode .assignee-checkbox:has(input:checked) {
    border-color: #a3a3a3;
    background: #1a1a1a;
}

body.dark-mode .assignee-checkbox input[type="checkbox"]:checked + .assignee-avatar {
    background: #fafafa;
    color: #171717;
}

body.dark-mode .assignee-avatar {
    background: #404040;
    color: #a3a3a3;
}

body.dark-mode .assignee-name {
    color: #e5e5e5;
}

body.dark-mode .assignee-badge {
    background: #333333;
    color: #a3a3a3;
}

.participant-selector {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.selected-participants {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    min-height: 32px;
}

.participant-tag {
    display: flex;
    align-items: center;
    gap: 0.375rem;
    padding: 0.25rem 0.5rem;
    background: var(--color-gray-100);
    border-radius: 6px;
    font-size: 0.875rem;
}

.participant-tag button {
    border: none;
    background: transparent;
    color: var(--color-gray-500);
    cursor: pointer;
    font-size: 1rem;
    line-height: 1;
    padding: 0;
}

.participant-tag button:hover {
    color: var(--color-gray-900);
}

/* Calendar Meeting Event */
.calendar-event.meeting-event {
    background: #dbeafe;
    color: #1e40af;
    border-left-color: #4A90A4;
}

.calendar-event.meeting-event:hover {
    background: #bfdbfe;
}

.calendar-event.meeting-event i {
    margin-right: 0.25rem;
    font-size: 0.65rem;
}

/* Responsive */
@media (max-width: 1024px) {
    .meeting-content-grid {
        grid-template-columns: 1fr;
    }

    .meeting-sidebar {
        order: -1;
    }
}

@media (max-width: 768px) {
    .meeting-header {
        flex-direction: column;
    }

    .meeting-header-right {
        align-items: flex-start;
        flex-direction: row;
    }

    .meeting-info-bar {
        flex-direction: column;
        gap: 0.75rem;
    }

    .meetings-grid {
        grid-template-columns: 1fr;
    }

    .create-task-form .form-row {
        flex-direction: column;
    }
}

/* Dark Mode */
body.dark-mode .meetings-container,
body.dark-mode .meeting-detail-container {
    color: #e5e5e5;
}

body.dark-mode .section-title {
    color: #a3a3a3;
}

body.dark-mode .meeting-card {
    background: #171717;
    border-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .meeting-card:hover {
    background: #262626;
    border-color: rgba(255, 255, 255, 0.2);
}

body.dark-mode .meeting-card.in-progress {
    border-color: #22c55e;
}

body.dark-mode .meeting-name {
    color: #fafafa;
}

body.dark-mode .meeting-card-date,
body.dark-mode .meeting-card-time {
    color: #a3a3a3;
}

body.dark-mode .meeting-card-participants {
    border-top-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .participant-avatar {
    border-color: #171717;
    background: #404040;
    color: #e5e5e5;
}

body.dark-mode .meeting-title {
    color: #fafafa;
}

body.dark-mode .meeting-info-bar {
    background: #171717;
}

body.dark-mode .meeting-info-item {
    color: #a3a3a3;
}

body.dark-mode .meeting-participants-bar {
    background: #171717;
    border-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .bar-project-section {
    color: #a3a3a3;
}

body.dark-mode .bar-project-select {
    background: #262626;
    border-color: rgba(255, 255, 255, 0.1);
    color: #e5e5e5;
}

body.dark-mode .bar-project-select:hover {
    border-color: rgba(255, 255, 255, 0.2);
}

body.dark-mode .bar-project-select:focus {
    border-color: rgba(255, 255, 255, 0.3);
}

body.dark-mode .bar-divider {
    background: rgba(255, 255, 255, 0.1);
}

body.dark-mode .participant-chip {
    background: #262626;
    color: #e5e5e5;
}

body.dark-mode .participant-list::-webkit-scrollbar-track {
    background: #262626;
}

body.dark-mode .participant-list::-webkit-scrollbar-thumb {
    background: #404040;
}

body.dark-mode .participant-add-dropdown select {
    background: #262626;
    border-color: rgba(255, 255, 255, 0.1);
    color: #e5e5e5;
}

body.dark-mode .participant-add-dropdown select:hover {
    border-color: rgba(255, 255, 255, 0.2);
}

body.dark-mode .participant-remove-btn {
    color: #737373;
}

body.dark-mode .participant-remove-btn:hover {
    background: rgba(239, 68, 68, 0.2);
    color: #f87171;
}

body.dark-mode .meeting-tabs {
    background: #262626;
}

body.dark-mode .meeting-tab {
    color: #a3a3a3;
}

body.dark-mode .meeting-tab:hover {
    background: rgba(255, 255, 255, 0.1);
    color: #e5e5e5;
}

body.dark-mode .meeting-tab.active {
    background: #171717;
    color: #e5e5e5;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.3);
}

body.dark-mode .tab-badge {
    background: #404040;
    color: #a3a3a3;
}

body.dark-mode .meeting-tab.active .tab-badge {
    background: #e5e5e5;
    color: #171717;
}

body.dark-mode .meeting-tasks-bar {
    background: #171717;
    border-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .tasks-bar-label {
    color: #a3a3a3;
}

body.dark-mode .tasks-bar-label i {
    color: #737373;
}

body.dark-mode .meeting-project-section,
body.dark-mode .meeting-notes-section,
body.dark-mode .meeting-task-section,
body.dark-mode .meeting-description-card {
    background: #171717;
    border-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .meeting-description-card .description-text {
    color: #a3a3a3;
}

body.dark-mode .activity-feed-section {
    background: #171717;
    border-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .section-header h3 {
    color: #fafafa;
}

body.dark-mode .meeting-task-tag {
    background: #262626;
}

body.dark-mode .meeting-task-tag:hover {
    background: #333333;
}

body.dark-mode .task-tag-name {
    color: #e5e5e5;
}

body.dark-mode .meeting-tasks-list::-webkit-scrollbar-track {
    background: #262626;
}

body.dark-mode .meeting-tasks-list::-webkit-scrollbar-thumb {
    background: #404040;
}

body.dark-mode .notes-editor-container {
    border-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .notes-toolbar {
    background: #262626;
    border-bottom-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .toolbar-btn {
    color: #a3a3a3;
}

body.dark-mode .toolbar-btn:hover {
    background: #404040;
    color: #fafafa;
}

body.dark-mode .notes-editor {
    background: #0a0a0f;
    color: #e5e5e5;
}

body.dark-mode .notes-preview {
    background: #0a0a0f;
    color: #e5e5e5;
}

body.dark-mode .notes-preview code {
    background: #262626;
}

body.dark-mode .notes-preview pre {
    background: #262626;
}

body.dark-mode .activity-item {
    background: #262626;
}

body.dark-mode .activity-item.activity-new {
    background: rgba(59, 130, 246, 0.2);
}

body.dark-mode .activity-description {
    color: #e5e5e5;
}

body.dark-mode .empty-state {
    color: #737373;
}

body.dark-mode .calendar-event.meeting-event {
    background: rgba(74, 144, 164, 0.3);
    color: #7dd3fc;
}

body.dark-mode .calendar-event.meeting-event:hover {
    background: rgba(74, 144, 164, 0.4);
}

/* ============================
   Meeting Attachments Section
   ============================ */

.meeting-attachments-section {
    margin-top: 1.5rem;
    background: var(--color-white);
    border-radius: var(--border-radius);
    padding: 1.5rem;
    border: 1px solid var(--color-gray-200);
}

.meeting-attachments-section .section-header {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 1rem;
}

.meeting-attachments-section .section-header h3 {
    margin: 0;
    font-size: 1rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.attachment-counter {
    font-size: 0.875rem;
    color: var(--color-gray-500);
    font-weight: normal;
}

/* Upload Area */
.attachment-upload-area {
    margin-bottom: 1.5rem;
}

.attachment-input-hidden {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

.attachment-upload-dropzone {
    border: 2px dashed var(--color-gray-300);
    border-radius: var(--border-radius);
    padding: 2rem;
    text-align: center;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.75rem;
}

.attachment-upload-dropzone:hover,
.attachment-upload-dropzone.drag-over {
    border-color: var(--color-black);
    background: var(--color-gray-50);
}

.attachment-upload-icon {
    font-size: 2rem;
    color: var(--color-gray-400);
}

.attachment-upload-dropzone:hover .attachment-upload-icon,
.attachment-upload-dropzone.drag-over .attachment-upload-icon {
    color: var(--color-black);
}

.attachment-upload-text {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}

.attachment-upload-primary {
    font-weight: 500;
    color: var(--color-gray-700);
}

.attachment-upload-hint {
    font-size: 0.75rem;
    color: var(--color-gray-500);
}

.attachment-error {
    margin-top: 0.75rem;
    padding: 0.75rem;
    background: #fef2f2;
    border: 1px solid #fecaca;
    border-radius: var(--border-radius-sm);
    color: #dc2626;
    font-size: 0.875rem;
}

.attachment-progress {
    margin-top: 0.75rem;
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.attachment-progress-bar {
    flex: 1;
    height: 6px;
    background: var(--color-gray-200);
    border-radius: 3px;
    overflow: hidden;
}

.attachment-progress-fill {
    height: 100%;
    background: var(--color-black);
    border-radius: 3px;
    width: 0%;
    transition: width 0.3s ease;
}

.attachment-progress-text {
    font-size: 0.75rem;
    color: var(--color-gray-600);
    min-width: 80px;
}

/* Empty State */
.attachment-empty-state {
    text-align: center;
    padding: 2rem;
    color: var(--color-gray-400);
}

.attachment-empty-state i {
    font-size: 2.5rem;
    margin-bottom: 0.5rem;
}

.attachment-empty-state p {
    margin: 0;
    font-size: 0.875rem;
}

/* Attachment Grid */
.attachment-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
    gap: 1rem;
}

.attachment-card {
    background: var(--color-white);
    border-radius: var(--border-radius-sm);
    border: 1px solid var(--color-gray-200);
    overflow: hidden;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.attachment-card:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

/* Attachment Preview Thumbnails */
.attachment-preview {
    height: 100px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    position: relative;
    overflow: hidden;
}

.attachment-preview-photo {
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
}

.attachment-preview-overlay {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s ease;
}

.attachment-preview-overlay i {
    color: white;
    font-size: 1.25rem;
    opacity: 0;
    transition: opacity 0.2s ease;
}

.attachment-preview:hover .attachment-preview-overlay {
    background: rgba(0, 0, 0, 0.4);
}

.attachment-preview:hover .attachment-preview-overlay i {
    opacity: 1;
}

.attachment-preview-pdf,
.attachment-preview-markdown {
    background: var(--color-gray-100);
    font-size: 2.5rem;
}

.attachment-preview-pdf i {
    color: #e74c3c;
}

.attachment-preview-markdown i {
    color: #2196f3;
}

.attachment-preview-pdf:hover,
.attachment-preview-markdown:hover {
    background: var(--color-gray-200);
}

/* Card Footer */
.attachment-card-footer {
    padding: 0.75rem;
    border-top: 1px solid var(--color-gray-100);
}

.attachment-info {
    display: flex;
    flex-direction: column;
    gap: 0.125rem;
    margin-bottom: 0.5rem;
}

.attachment-name {
    font-size: 0.8125rem;
    font-weight: 500;
    color: var(--color-gray-800);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.attachment-size {
    font-size: 0.75rem;
    color: var(--color-gray-500);
}

.attachment-actions {
    display: flex;
    gap: 0.5rem;
}

.attachment-action-btn {
    width: 28px;
    height: 28px;
    border-radius: 4px;
    border: none;
    background: var(--color-gray-100);
    color: var(--color-gray-600);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.75rem;
    transition: all 0.2s ease;
    text-decoration: none;
}

.attachment-action-btn:hover {
    background: var(--color-gray-200);
    color: var(--color-gray-800);
}

.attachment-delete-btn:hover {
    background: #fef2f2;
    color: #dc2626;
}

/* Attachment Preview Modal */
#attachmentPreviewModal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 1000;
}

#attachmentPreviewModal.active {
    display: flex;
}

.attachment-preview-modal {
    max-width: 900px;
}

.attachment-preview-header-info {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.attachment-preview-header-info i {
    font-size: 1.25rem;
    color: var(--color-gray-500);
}

.attachment-preview-body {
    min-height: 300px;
    max-height: 70vh;
    overflow: auto;
    position: relative;
}

.attachment-preview-loading {
    position: absolute;
    inset: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 1rem;
    background: var(--color-white);
}

.attachment-preview-loading .spinner {
    width: 32px;
    height: 32px;
    border: 3px solid var(--color-gray-200);
    border-top-color: var(--color-black);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* Photo Preview Container */
.attachment-preview-photo-container {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1rem;
}

.attachment-preview-photo-container img {
    max-width: 100%;
    max-height: 60vh;
    border-radius: var(--border-radius-sm);
}

/* PDF Preview Container */
.attachment-preview-pdf-container {
    padding: 1rem;
}

.pdf-navigation {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 1rem;
    margin-bottom: 1rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid var(--color-gray-200);
}

.pdf-page-info {
    font-size: 0.875rem;
    color: var(--color-gray-600);
}

.pdf-canvas-container {
    display: flex;
    justify-content: center;
    overflow: auto;
}

.pdf-canvas-container canvas {
    max-width: 100%;
    border: 1px solid var(--color-gray-200);
    border-radius: var(--border-radius-sm);
}

/* Markdown Preview Container */
.attachment-preview-markdown-container {
    padding: 1.5rem;
}

.attachment-preview-markdown-container .markdown-content {
    font-size: 0.9375rem;
    line-height: 1.7;
}

.attachment-preview-markdown-container .markdown-content h1,
.attachment-preview-markdown-container .markdown-content h2,
.attachment-preview-markdown-container .markdown-content h3 {
    margin-top: 1.5rem;
    margin-bottom: 0.75rem;
}

.attachment-preview-markdown-container .markdown-content code {
    background: var(--color-gray-100);
    padding: 0.125rem 0.375rem;
    border-radius: 4px;
    font-size: 0.875em;
}

.attachment-preview-markdown-container .markdown-content pre {
    background: var(--color-gray-100);
    padding: 1rem;
    border-radius: var(--border-radius-sm);
    overflow-x: auto;
}

.attachment-preview-markdown-container .markdown-content pre code {
    background: none;
    padding: 0;
}

/* Photo Lightbox */
.photo-lightbox {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 9999;
    display: none;
}

.photo-lightbox.active {
    display: flex;
    align-items: center;
    justify-content: center;
}

.lightbox-overlay {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.9);
}

.lightbox-content {
    position: relative;
    max-width: 90vw;
    max-height: 90vh;
    display: flex;
    align-items: center;
    justify-content: center;
}

.lightbox-content img {
    max-width: 100%;
    max-height: 90vh;
    object-fit: contain;
    border-radius: var(--border-radius-sm);
}

.lightbox-close {
    position: absolute;
    top: -40px;
    right: 0;
    width: 36px;
    height: 36px;
    border: none;
    background: rgba(255, 255, 255, 0.1);
    color: white;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1rem;
    transition: background 0.2s ease;
}

.lightbox-close:hover {
    background: rgba(255, 255, 255, 0.2);
}

.lightbox-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 44px;
    height: 44px;
    border: none;
    background: rgba(255, 255, 255, 0.1);
    color: white;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1rem;
    transition: background 0.2s ease;
}

.lightbox-nav:hover {
    background: rgba(255, 255, 255, 0.2);
}

.lightbox-nav:disabled {
    opacity: 0.3;
    cursor: not-allowed;
}

.lightbox-prev {
    left: -60px;
}

.lightbox-next {
    right: -60px;
}

.lightbox-info {
    position: absolute;
    bottom: -40px;
    left: 50%;
    transform: translateX(-50%);
    color: rgba(255, 255, 255, 0.7);
    font-size: 0.875rem;
    white-space: nowrap;
}

/* ============================
   Canvas Section (Meeting Detail)
   ============================ */

.meeting-canvas-section {
    margin-top: 1.5rem;
    background: var(--color-white);
    border-radius: var(--border-radius);
    padding: 1.5rem;
    border: 1px solid var(--color-gray-200);
}

.meeting-canvas-section .section-header {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 1.25rem;
}

.meeting-canvas-section .section-header h3 {
    margin: 0;
    font-size: 1rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.canvas-counter {
    font-size: 0.875rem;
    color: var(--color-gray-500);
    font-weight: normal;
    margin-right: auto;
}

/* Empty State */
.canvas-empty-state {
    text-align: center;
    padding: 3rem 1.5rem;
    color: var(--color-gray-500);
}

.canvas-empty-state i {
    font-size: 2.5rem;
    margin-bottom: 0.75rem;
    opacity: 0.5;
}

.canvas-empty-state p {
    margin: 0;
    font-size: 0.875rem;
}

/* Canvas Grid */
.canvas-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 1rem;
}

.canvas-card {
    background: var(--color-gray-50);
    border: 1px solid var(--color-gray-200);
    border-radius: var(--border-radius);
    overflow: hidden;
    transition: all 0.2s ease;
}

.canvas-card:hover {
    border-color: var(--color-gray-300);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

.canvas-card-preview {
    height: 120px;
    background: linear-gradient(135deg, var(--color-gray-100) 0%, var(--color-gray-200) 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: background 0.2s ease;
}

.canvas-card-preview i {
    font-size: 2rem;
    color: var(--color-gray-400);
    transition: color 0.2s ease;
}

.canvas-card:hover .canvas-card-preview {
    background: linear-gradient(135deg, var(--color-gray-200) 0%, var(--color-gray-300) 100%);
}

.canvas-card:hover .canvas-card-preview i {
    color: var(--color-gray-600);
}

.canvas-card-info {
    padding: 0.875rem;
    border-top: 1px solid var(--color-gray-200);
}

.canvas-name {
    display: block;
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--color-gray-900);
    margin-bottom: 0.25rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.canvas-meta {
    font-size: 0.75rem;
    color: var(--color-gray-500);
}

.canvas-card-actions {
    display: flex;
    gap: 0.5rem;
    padding: 0 0.875rem 0.875rem;
}

.canvas-action-btn {
    width: 28px;
    height: 28px;
    border-radius: 4px;
    border: none;
    background: var(--color-gray-100);
    color: var(--color-gray-600);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.75rem;
    transition: all 0.2s ease;
}

.canvas-action-btn:hover {
    background: var(--color-gray-200);
    color: var(--color-gray-800);
}

.canvas-delete-btn:hover {
    background: #fef2f2;
    color: #dc2626;
}

/* Dark Mode Styles for Attachments */
body.dark-mode .meeting-attachments-section {
    background: #1a1a1f;
    border-color: #262626;
}

body.dark-mode .attachment-upload-dropzone {
    border-color: #404040;
}

body.dark-mode .attachment-upload-dropzone:hover,
body.dark-mode .attachment-upload-dropzone.drag-over {
    border-color: #e5e5e5;
    background: #262626;
}

body.dark-mode .attachment-upload-icon {
    color: #737373;
}

body.dark-mode .attachment-upload-dropzone:hover .attachment-upload-icon,
body.dark-mode .attachment-upload-dropzone.drag-over .attachment-upload-icon {
    color: #e5e5e5;
}

body.dark-mode .attachment-upload-primary {
    color: #e5e5e5;
}

body.dark-mode .attachment-upload-hint {
    color: #737373;
}

body.dark-mode .attachment-error {
    background: rgba(220, 38, 38, 0.1);
    border-color: rgba(220, 38, 38, 0.3);
}

body.dark-mode .attachment-progress-bar {
    background: #404040;
}

body.dark-mode .attachment-progress-fill {
    background: #e5e5e5;
}

body.dark-mode .attachment-empty-state {
    color: #737373;
}

body.dark-mode .attachment-card {
    background: #1a1a1f;
    border-color: #262626;
}

body.dark-mode .attachment-preview-pdf,
body.dark-mode .attachment-preview-markdown {
    background: #262626;
}

body.dark-mode .attachment-preview-pdf:hover,
body.dark-mode .attachment-preview-markdown:hover {
    background: #333333;
}

body.dark-mode .attachment-card-footer {
    border-color: #262626;
}

body.dark-mode .attachment-name {
    color: #e5e5e5;
}

body.dark-mode .attachment-size {
    color: #737373;
}

body.dark-mode .attachment-action-btn {
    background: #262626;
    color: #a3a3a3;
}

body.dark-mode .attachment-action-btn:hover {
    background: #333333;
    color: #e5e5e5;
}

body.dark-mode .attachment-delete-btn:hover {
    background: rgba(220, 38, 38, 0.2);
    color: #f87171;
}

body.dark-mode #attachmentPreviewModal {
    background: rgba(0, 0, 0, 0.7);
}

body.dark-mode .attachment-preview-modal .modal-content,
body.dark-mode #attachmentPreviewModal .modal-content {
    background: #1a1a1f;
}

body.dark-mode .attachment-preview-loading {
    background: #1a1a1f;
}

body.dark-mode .attachment-preview-loading .spinner {
    border-color: #404040;
    border-top-color: #e5e5e5;
}

body.dark-mode .pdf-navigation {
    border-color: #262626;
}

body.dark-mode .pdf-canvas-container canvas {
    border-color: #262626;
}

body.dark-mode .attachment-preview-markdown-container .markdown-content code {
    background: #262626;
}

body.dark-mode .attachment-preview-markdown-container .markdown-content pre {
    background: #262626;
}

/* Dark Mode Canvas Section */
body.dark-mode .meeting-canvas-section {
    background: #1a1a1f;
    border-color: #262626;
}

body.dark-mode .canvas-empty-state {
    color: #737373;
}

body.dark-mode .canvas-card {
    background: #262626;
    border-color: #333333;
}

body.dark-mode .canvas-card:hover {
    border-color: #404040;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
}

body.dark-mode .canvas-card-preview {
    background: linear-gradient(135deg, #1a1a1f 0%, #262626 100%);
}

body.dark-mode .canvas-card-preview i {
    color: #525252;
}

body.dark-mode .canvas-card:hover .canvas-card-preview {
    background: linear-gradient(135deg, #262626 0%, #333333 100%);
}

body.dark-mode .canvas-card:hover .canvas-card-preview i {
    color: #737373;
}

body.dark-mode .canvas-card-info {
    border-color: #333333;
}

body.dark-mode .canvas-name {
    color: #e5e5e5;
}

body.dark-mode .canvas-meta {
    color: #737373;
}

body.dark-mode .canvas-action-btn {
    background: #333333;
    color: #a3a3a3;
}

body.dark-mode .canvas-action-btn:hover {
    background: #404040;
    color: #e5e5e5;
}

body.dark-mode .canvas-delete-btn:hover {
    background: rgba(220, 38, 38, 0.2);
    color: #f87171;
}

/* ==================== */
/* AI Quick Widget      */
/* ==================== */

.ai-quick-section {
    background: var(--color-white);
    border-radius: var(--border-radius);
    padding: 1.5rem;
    margin-bottom: 1.5rem;
    box-shadow: var(--shadow-sm);
    border: 1px solid var(--color-gray-200);
}

.ai-quick-section .section-header {
    margin-bottom: 1rem;
}

.ai-quick-section .section-header h2 {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 1.125rem;
    font-weight: 600;
}

.ai-quick-section .section-header h2 i {
    color: var(--color-black);
}

.ai-quick-content {
    position: relative;
}

.ai-quick-response {
    background: linear-gradient(135deg, #f8f9fa 0%, #ffffff 100%);
    border-radius: 1rem;
    padding: 1.25rem;
    margin-bottom: 1rem;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    border: 1px solid var(--color-gray-200);
    position: relative;
    animation: aiResponseSlideIn 0.3s ease-out;
}

@keyframes aiResponseSlideIn {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.ai-quick-response-header {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 0.75rem;
    padding-bottom: 0.75rem;
    border-bottom: 1px solid var(--color-gray-200);
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--color-gray-600);
}

.ai-quick-response-header i {
    color: var(--color-black);
}

.ai-quick-response-close {
    margin-left: auto;
    padding: 0.25rem;
    background: none;
    border: none;
    cursor: pointer;
    color: var(--color-gray-400);
    border-radius: 4px;
    transition: all 0.2s ease;
}

.ai-quick-response-close:hover {
    color: var(--color-gray-700);
    background: var(--color-gray-100);
}

.ai-quick-response-content {
    font-size: 0.9375rem;
    line-height: 1.7;
    color: var(--color-gray-800);
}

.ai-quick-response-content p {
    margin-bottom: 0.75rem;
}

.ai-quick-response-content p:last-child {
    margin-bottom: 0;
}

.ai-quick-response-content code {
    background: var(--color-gray-100);
    padding: 0.125rem 0.375rem;
    border-radius: 4px;
    font-size: 0.875em;
    font-family: 'SF Mono', Monaco, monospace;
}

.ai-quick-response-content pre {
    background: var(--color-gray-900);
    color: var(--color-gray-100);
    padding: 1rem;
    border-radius: 8px;
    overflow-x: auto;
    margin: 0.75rem 0;
}

.ai-quick-response-content pre code {
    background: none;
    padding: 0;
    color: inherit;
}

.ai-quick-response-content ul,
.ai-quick-response-content ol {
    margin: 0.5rem 0;
    padding-left: 1.5rem;
}

.ai-quick-response-content li {
    margin-bottom: 0.25rem;
}

.ai-quick-response-content h2,
.ai-quick-response-content h3,
.ai-quick-response-content h4 {
    margin: 1rem 0 0.5rem;
    font-weight: 600;
}

.ai-quick-response-content h2 {
    font-size: 1.25rem;
}

.ai-quick-response-content h3 {
    font-size: 1.125rem;
}

.ai-quick-response-content h4 {
    font-size: 1rem;
}

.ai-quick-input-row {
    display: flex;
    gap: 0.75rem;
    align-items: center;
}

.ai-quick-input {
    flex: 1;
    padding: 0.875rem 1rem;
    font-size: 1rem;
    border: 2px solid var(--color-gray-200);
    border-radius: 12px;
    transition: all 0.2s ease;
    background: var(--color-white);
}

.ai-quick-input:focus {
    outline: none;
    border-color: var(--color-black);
    box-shadow: 0 0 0 3px rgba(0, 0, 0, 0.05);
}

.ai-quick-input::placeholder {
    color: var(--color-gray-400);
}

.ai-quick-send-btn {
    width: 48px;
    height: 48px;
    border-radius: 12px;
    background: var(--color-black);
    color: var(--color-white);
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.1rem;
    transition: all 0.2s ease;
    flex-shrink: 0;
}

.ai-quick-send-btn:hover {
    background: var(--color-gray-800);
    transform: scale(1.05);
}

.ai-quick-send-btn:active {
    transform: scale(0.95);
}

.ai-quick-send-btn:disabled {
    background: var(--color-gray-400);
    cursor: not-allowed;
    transform: none;
}

.ai-quick-loading {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1.5rem;
    color: var(--color-gray-500);
    font-size: 1.5rem;
}

.ai-typing-indicator {
    display: flex;
    gap: 4px;
}

.ai-typing-indicator span {
    width: 8px;
    height: 8px;
    background: var(--color-gray-400);
    border-radius: 50%;
    animation: aiTypingBounce 1.4s infinite ease-in-out both;
}

.ai-typing-indicator span:nth-child(1) {
    animation-delay: -0.32s;
}

.ai-typing-indicator span:nth-child(2) {
    animation-delay: -0.16s;
}

@keyframes aiTypingBounce {
    0%, 80%, 100% {
        transform: scale(0.6);
        opacity: 0.5;
    }
    40% {
        transform: scale(1);
        opacity: 1;
    }
}

/* AI Quick Widget - Focused State */
.ai-quick-section.ai-quick-focused {
    border-color: var(--color-gray-300);
    box-shadow: var(--shadow);
}

/* AI Quick Widget - Dark Mode */
body.dark-mode .ai-quick-section {
    background: #1a1a1f;
    border-color: #262626;
}

body.dark-mode .ai-quick-section .section-header h2 i {
    color: #ffffff;
}

body.dark-mode .ai-quick-response {
    background: linear-gradient(135deg, #262626 0%, #1a1a1f 100%);
    border-color: #333333;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
}

body.dark-mode .ai-quick-response-header {
    border-color: #333333;
    color: #a3a3a3;
}

body.dark-mode .ai-quick-response-header i {
    color: #ffffff;
}

body.dark-mode .ai-quick-response-close {
    color: #525252;
}

body.dark-mode .ai-quick-response-close:hover {
    color: #a3a3a3;
    background: #333333;
}

body.dark-mode .ai-quick-response-content {
    color: #e5e5e5;
}

body.dark-mode .ai-quick-response-content code {
    background: #333333;
    color: #e5e5e5;
}

body.dark-mode .ai-quick-response-content pre {
    background: #0a0a0a;
    border: 1px solid #333333;
}

body.dark-mode .ai-quick-input {
    background: #262626;
    border-color: #333333;
    color: #e5e5e5;
}

body.dark-mode .ai-quick-input:focus {
    border-color: #525252;
    box-shadow: 0 0 0 3px rgba(255, 255, 255, 0.05);
}

body.dark-mode .ai-quick-input::placeholder {
    color: #525252;
}

body.dark-mode .ai-quick-send-btn {
    background: #ffffff;
    color: #000000;
}

body.dark-mode .ai-quick-send-btn:hover {
    background: #e5e5e5;
}

body.dark-mode .ai-quick-send-btn:disabled {
    background: #404040;
    color: #737373;
}

body.dark-mode .ai-quick-loading {
    color: #737373;
}

body.dark-mode .ai-typing-indicator span {
    background: #525252;
}

body.dark-mode .ai-quick-section.ai-quick-focused {
    border-color: #404040;
}

/* AI Quick Widget - Responsive */
@media (max-width: 768px) {
    .ai-quick-section {
        padding: 1rem;
    }

    .ai-quick-input-row {
        gap: 0.5rem;
    }

    .ai-quick-input {
        padding: 0.75rem;
        font-size: 0.9375rem;
    }

    .ai-quick-send-btn {
        width: 44px;
        height: 44px;
    }

    .ai-quick-response {
        padding: 1rem;
    }

    .ai-quick-response-content {
        font-size: 0.875rem;
    }
}

/* ============================
   Desk Calendar Styles
   ============================ */

/* Container */
.desk-calendar-container {
    padding: 0;
    max-width: 100%;
    height: calc(100vh - 60px);
    overflow: hidden;
}

.desk-calendar-layout {
    display: flex;
    height: 100%;
    position: relative;
}

/* Mobile Sidebar Toggle */
.sidebar-toggle-btn {
    display: none;
    position: fixed;
    bottom: 1.5rem;
    right: 1.5rem;
    z-index: 100;
    background: var(--color-black);
    color: var(--color-white);
    border: none;
    border-radius: 50px;
    padding: 0.75rem 1.25rem;
    font-size: 0.875rem;
    font-weight: 500;
    cursor: pointer;
    box-shadow: var(--shadow-lg);
    align-items: center;
    gap: 0.5rem;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.sidebar-toggle-btn:hover {
    transform: scale(1.05);
    box-shadow: var(--shadow-xl);
}

/* Sidebar */
.desk-calendar-sidebar {
    width: 320px;
    min-width: 320px;
    background: var(--color-white);
    border-right: 1px solid var(--color-gray-200);
    display: flex;
    flex-direction: column;
    height: 100%;
}

.sidebar-overlay {
    display: none;
}

.sidebar-content {
    display: flex;
    flex-direction: column;
    height: 100%;
    overflow: hidden;
}

.sidebar-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1.25rem 1rem;
    border-bottom: 1px solid var(--color-gray-200);
}

.sidebar-header h3 {
    margin: 0;
    font-size: 1.125rem;
    font-weight: 600;
}

.sidebar-close-btn {
    display: none;
    background: none;
    border: none;
    font-size: 1.25rem;
    color: var(--color-gray-500);
    cursor: pointer;
    padding: 0.25rem;
}

.sidebar-close-btn:hover {
    color: var(--color-black);
}

/* Task Filters in Sidebar */
.desk-calendar-sidebar .task-filters {
    padding: 1rem;
    border-bottom: 1px solid var(--color-gray-100);
}

.desk-calendar-sidebar .task-search {
    width: 100%;
    padding: 0.625rem 0.75rem;
    border: 1px solid var(--color-gray-300);
    border-radius: var(--border-radius-sm);
    font-size: 0.875rem;
    margin-bottom: 0.75rem;
}

.desk-calendar-sidebar .filter-row {
    display: flex;
    gap: 0.5rem;
    margin-bottom: 0.5rem;
}

.desk-calendar-sidebar .filter-row:last-child {
    margin-bottom: 0;
}

.desk-calendar-sidebar .filter-select {
    flex: 1;
    padding: 0.5rem;
    border: 1px solid var(--color-gray-300);
    border-radius: var(--border-radius-sm);
    font-size: 0.8125rem;
    background: var(--color-white);
}

/* Task List Panel */
.desk-calendar-sidebar .task-list-panel {
    flex: 1;
    overflow-y: auto;
    padding: 0.75rem;
}

.desk-calendar-sidebar .draggable-task {
    display: flex;
    align-items: center;
    gap: 0.625rem;
    padding: 0.625rem 0.75rem;
    background: var(--color-white);
    border: 1px solid var(--color-gray-200);
    border-radius: var(--border-radius-sm);
    margin-bottom: 0.5rem;
    cursor: grab;
    transition: box-shadow 0.2s ease, transform 0.2s ease;
}

.desk-calendar-sidebar .draggable-task:hover {
    box-shadow: var(--shadow-sm);
    transform: translateY(-1px);
}

.desk-calendar-sidebar .draggable-task.dragging {
    opacity: 0.5;
    cursor: grabbing;
}

.desk-calendar-sidebar .task-color-bar {
    width: 4px;
    height: 32px;
    border-radius: 2px;
    flex-shrink: 0;
}

.desk-calendar-sidebar .task-info {
    flex: 1;
    min-width: 0;
}

.desk-calendar-sidebar .task-name {
    display: block;
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--color-gray-800);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.desk-calendar-sidebar .task-project {
    display: block;
    font-size: 0.75rem;
    color: var(--color-gray-500);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.desk-calendar-sidebar .task-status-badge {
    font-size: 0.625rem;
    padding: 0.125rem 0.375rem;
    border-radius: 3px;
    text-transform: uppercase;
    font-weight: 600;
    flex-shrink: 0;
}

/* Scroll Container */
.desk-calendar-scroll {
    flex: 1;
    overflow-y: auto;
    overflow-x: hidden;
    background: var(--color-gray-50);
    scroll-behavior: smooth;
}

.desk-calendar-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1.25rem 1.5rem;
    background: var(--color-white);
    border-bottom: 1px solid var(--color-gray-200);
    position: sticky;
    top: 0;
    z-index: 10;
}

.desk-calendar-header h1 {
    margin: 0;
    font-size: 1.5rem;
    font-weight: 600;
}

/* Day Cards Container */
.day-cards-container {
    padding: 1rem 1.5rem;
    max-width: 900px;
    margin: 0 auto;
}

/* Loading Indicator */
.loading-indicator {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 2rem;
    color: var(--color-gray-500);
    font-size: 0.875rem;
}

.loading-indicator i {
    font-size: 1.25rem;
}

/* Load More Trigger */
.load-more-trigger {
    height: 1px;
    width: 100%;
}

/* Day Card */
.day-card {
    display: grid;
    grid-template-columns: 100px 1fr;
    gap: 1rem;
    background: var(--color-white);
    border-radius: var(--border-radius);
    border: 1px solid var(--color-gray-200);
    margin-bottom: 1rem;
    overflow: hidden;
    transition: box-shadow 0.2s ease;
}

.day-card:hover {
    box-shadow: var(--shadow-sm);
}

.day-card.is-past {
    opacity: 0.7;
}

.day-card.is-past:hover {
    opacity: 1;
}

/* Day Card Date Section */
.day-card-date {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 1.25rem 0.75rem;
    background: var(--color-gray-50);
    border-right: 1px solid var(--color-gray-200);
    text-align: center;
}

.day-weekday {
    font-size: 0.75rem;
    font-weight: 500;
    color: var(--color-gray-500);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 0.25rem;
}

.day-number {
    font-size: 2.5rem;
    font-weight: 700;
    line-height: 1;
    color: var(--color-gray-800);
    margin-bottom: 0.25rem;
}

.day-month {
    font-size: 0.75rem;
    color: var(--color-gray-500);
}

/* Today Card Styles */
.day-card.is-today .day-card-date {
    background: var(--color-black);
}

.day-card.is-today .day-weekday,
.day-card.is-today .day-number,
.day-card.is-today .day-month {
    color: var(--color-white);
}

.day-card.is-today {
    border-color: var(--color-black);
    box-shadow: var(--shadow-md);
}

/* Day Card Content Section */
.day-card-content {
    padding: 1rem;
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

/* Day Note Section */
.day-note-section {
    position: relative;
}

.day-note-input {
    width: 100%;
    min-height: 60px;
    padding: 0.75rem;
    border: 1px solid var(--color-gray-200);
    border-radius: var(--border-radius-sm);
    font-size: 0.875rem;
    font-family: inherit;
    resize: vertical;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.day-note-input:focus {
    outline: none;
    border-color: var(--color-black);
    box-shadow: 0 0 0 2px rgba(0, 0, 0, 0.1);
}

.day-note-input::placeholder {
    color: var(--color-gray-400);
}

.note-save-indicator {
    position: absolute;
    bottom: 0.5rem;
    right: 0.5rem;
    font-size: 0.6875rem;
    padding: 0.125rem 0.375rem;
    border-radius: 3px;
}

.note-save-indicator.saving {
    background: var(--color-gray-100);
    color: var(--color-gray-600);
}

.note-save-indicator.saved {
    background: #dcfce7;
    color: #16a34a;
}

.note-save-indicator.error {
    background: #fef2f2;
    color: #dc2626;
}

/* Day Tasks Section */
.day-tasks-section {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.day-tasks-list {
    display: flex;
    flex-direction: column;
    gap: 0.375rem;
}

.day-task-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 0.625rem;
    background: var(--color-gray-50);
    border-radius: var(--border-radius-sm);
    transition: background-color 0.2s ease;
}

.day-task-item:hover {
    background: var(--color-gray-100);
}

.task-color-indicator {
    width: 4px;
    height: 24px;
    border-radius: 2px;
    flex-shrink: 0;
}

.task-item-content {
    flex: 1;
    min-width: 0;
}

.task-item-name {
    display: block;
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--color-gray-800);
    text-decoration: none;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.task-item-name:hover {
    color: var(--color-black);
    text-decoration: underline;
}

.task-item-project {
    display: block;
    font-size: 0.6875rem;
    color: var(--color-gray-500);
}

.task-deadline-warning {
    color: #dc2626;
    font-size: 0.875rem;
    flex-shrink: 0;
}

.task-remove-btn {
    background: none;
    border: none;
    color: var(--color-gray-400);
    cursor: pointer;
    padding: 0.25rem;
    font-size: 0.75rem;
    opacity: 0;
    transition: opacity 0.2s ease, color 0.2s ease;
}

.day-task-item:hover .task-remove-btn {
    opacity: 1;
}

.task-remove-btn:hover {
    color: #dc2626;
}

/* Drop Zone */
.day-drop-zone {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.75rem;
    border: 2px dashed var(--color-gray-300);
    border-radius: var(--border-radius-sm);
    color: var(--color-gray-400);
    font-size: 0.8125rem;
    transition: all 0.2s ease;
}

.day-drop-zone.drag-over {
    border-color: #22c55e;
    background: rgba(34, 197, 94, 0.1);
    color: #16a34a;
}

/* Day Meetings Section */
.day-meetings-section {
    padding-top: 0.75rem;
    border-top: 1px solid var(--color-gray-100);
}

.day-meetings-header {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--color-gray-500);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 0.5rem;
}

.day-meetings-header i {
    color: #4A90A4;
}

.day-meetings-list {
    display: flex;
    flex-direction: column;
    gap: 0.375rem;
}

.day-meeting-item {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.5rem 0.625rem;
    background: rgba(74, 144, 164, 0.1);
    border-radius: var(--border-radius-sm);
    border-left: 3px solid #4A90A4;
    cursor: pointer;
    transition: background-color 0.2s ease;
}

.day-meeting-item:hover {
    background: rgba(74, 144, 164, 0.15);
}

.meeting-time {
    font-size: 0.8125rem;
    font-weight: 600;
    color: #4A90A4;
    min-width: 45px;
}

.meeting-info {
    flex: 1;
    min-width: 0;
}

.meeting-title {
    display: block;
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--color-gray-800);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.meeting-participants {
    display: block;
    font-size: 0.6875rem;
    color: var(--color-gray-500);
}

/* Touch Drag Ghost */
.touch-drag-ghost {
    position: fixed;
    z-index: 1000;
    padding: 0.5rem 1rem;
    border-radius: var(--border-radius-sm);
    color: var(--color-white);
    font-size: 0.8125rem;
    font-weight: 500;
    white-space: nowrap;
    max-width: 200px;
    overflow: hidden;
    text-overflow: ellipsis;
    box-shadow: var(--shadow-lg);
    pointer-events: none;
    transform: translate(-50%, -50%);
}

/* ============================
   Desk Calendar Responsive
   ============================ */

/* iPad and smaller */
@media (max-width: 1024px) {
    .desk-calendar-sidebar {
        width: 280px;
        min-width: 280px;
    }

    .day-card {
        grid-template-columns: 90px 1fr;
    }

    .day-number {
        font-size: 2rem;
    }

    .day-cards-container {
        padding: 1rem;
    }
}

/* Tablet */
@media (max-width: 768px) {
    .sidebar-toggle-btn {
        display: flex;
    }

    .desk-calendar-sidebar {
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        max-width: 320px;
        height: 100%;
        z-index: 200;
        transform: translateX(-100%);
        transition: transform 0.3s ease;
    }

    .desk-calendar-sidebar.open {
        transform: translateX(0);
    }

    .desk-calendar-sidebar.open .sidebar-overlay {
        display: block;
        position: fixed;
        top: 0;
        left: 0;
        width: 100vw;
        height: 100vh;
        background: rgba(0, 0, 0, 0.5);
        z-index: -1;
    }

    .sidebar-close-btn {
        display: block;
    }

    .day-card {
        grid-template-columns: 80px 1fr;
    }

    .day-number {
        font-size: 1.75rem;
    }

    .day-card-date {
        padding: 1rem 0.5rem;
    }

    .desk-calendar-header {
        padding: 1rem;
    }

    .desk-calendar-header h1 {
        font-size: 1.25rem;
    }

    .day-cards-container {
        padding: 0.75rem;
    }
}

/* Mobile */
@media (max-width: 480px) {
    .day-card {
        grid-template-columns: 70px 1fr;
        gap: 0.5rem;
    }

    .day-card-date {
        padding: 0.75rem 0.375rem;
    }

    .day-number {
        font-size: 1.5rem;
    }

    .day-weekday,
    .day-month {
        font-size: 0.6875rem;
    }

    .day-card-content {
        padding: 0.75rem;
    }

    .day-note-input {
        min-height: 50px;
        padding: 0.625rem;
        font-size: 0.8125rem;
    }

    .task-item-name {
        font-size: 0.8125rem;
    }

    .meeting-title {
        font-size: 0.8125rem;
    }

    .desk-calendar-header {
        padding: 0.75rem 1rem;
    }

    .desk-calendar-header h1 {
        font-size: 1.125rem;
    }
}

/* ============================
   Desk Calendar Dark Mode
   ============================ */

body.dark-mode .desk-calendar-container {
    background: var(--color-gray-900);
}

body.dark-mode .desk-calendar-sidebar {
    background: var(--color-gray-800);
    border-right-color: var(--color-gray-700);
}

body.dark-mode .sidebar-header {
    border-bottom-color: var(--color-gray-700);
}

body.dark-mode .sidebar-header h3 {
    color: var(--color-white);
}

body.dark-mode .sidebar-close-btn {
    color: var(--color-gray-400);
}

body.dark-mode .sidebar-close-btn:hover {
    color: var(--color-white);
}

body.dark-mode .desk-calendar-sidebar .task-filters {
    border-bottom-color: var(--color-gray-700);
}

body.dark-mode .desk-calendar-sidebar .task-search {
    background: var(--color-gray-700);
    border-color: var(--color-gray-600);
    color: var(--color-white);
}

body.dark-mode .desk-calendar-sidebar .task-search::placeholder {
    color: var(--color-gray-400);
}

body.dark-mode .desk-calendar-sidebar .filter-select {
    background: var(--color-gray-700);
    border-color: var(--color-gray-600);
    color: var(--color-white);
}

body.dark-mode .desk-calendar-sidebar .draggable-task {
    background: var(--color-gray-700);
    border-color: var(--color-gray-600);
}

body.dark-mode .desk-calendar-sidebar .task-name {
    color: var(--color-white);
}

body.dark-mode .desk-calendar-sidebar .task-project {
    color: var(--color-gray-400);
}

body.dark-mode .desk-calendar-scroll {
    background: var(--color-gray-900);
}

body.dark-mode .desk-calendar-header {
    background: var(--color-gray-800);
    border-bottom-color: var(--color-gray-700);
}

body.dark-mode .desk-calendar-header h1 {
    color: var(--color-white);
}

body.dark-mode .day-card {
    background: var(--color-gray-800);
    border-color: var(--color-gray-700);
}

body.dark-mode .day-card-date {
    background: var(--color-gray-750, #2d3748);
    border-right-color: var(--color-gray-700);
}

body.dark-mode .day-weekday,
body.dark-mode .day-month {
    color: var(--color-gray-400);
}

body.dark-mode .day-number {
    color: var(--color-white);
}

body.dark-mode .day-card.is-today .day-card-date {
    background: var(--color-white);
}

body.dark-mode .day-card.is-today .day-weekday,
body.dark-mode .day-card.is-today .day-number,
body.dark-mode .day-card.is-today .day-month {
    color: var(--color-black);
}

body.dark-mode .day-card.is-today {
    border-color: var(--color-white);
}

body.dark-mode .day-note-input {
    background: var(--color-gray-700);
    border-color: var(--color-gray-600);
    color: var(--color-white);
}

body.dark-mode .day-note-input::placeholder {
    color: var(--color-gray-400);
}

body.dark-mode .day-note-input:focus {
    border-color: var(--color-white);
    box-shadow: 0 0 0 2px rgba(255, 255, 255, 0.1);
}

body.dark-mode .note-save-indicator.saving {
    background: var(--color-gray-700);
    color: var(--color-gray-300);
}

body.dark-mode .day-task-item {
    background: var(--color-gray-700);
}

body.dark-mode .day-task-item:hover {
    background: var(--color-gray-600);
}

body.dark-mode .task-item-name {
    color: var(--color-white);
}

body.dark-mode .task-item-name:hover {
    color: var(--color-gray-200);
}

body.dark-mode .task-item-project {
    color: var(--color-gray-400);
}

body.dark-mode .task-remove-btn {
    color: var(--color-gray-500);
}

body.dark-mode .task-remove-btn:hover {
    color: #f87171;
}

body.dark-mode .day-drop-zone {
    border-color: var(--color-gray-600);
    color: var(--color-gray-500);
}

body.dark-mode .day-drop-zone.drag-over {
    border-color: #22c55e;
    background: rgba(34, 197, 94, 0.2);
    color: #4ade80;
}

body.dark-mode .day-meetings-section {
    border-top-color: var(--color-gray-700);
}

body.dark-mode .day-meetings-header {
    color: var(--color-gray-400);
}

body.dark-mode .day-meeting-item {
    background: rgba(74, 144, 164, 0.2);
}

body.dark-mode .day-meeting-item:hover {
    background: rgba(74, 144, 164, 0.3);
}

body.dark-mode .meeting-title {
    color: var(--color-white);
}

body.dark-mode .meeting-participants {
    color: var(--color-gray-400);
}

body.dark-mode .loading-indicator {
    color: var(--color-gray-400);
}

body.dark-mode .sidebar-toggle-btn {
    background: var(--color-white);
    color: var(--color-black);
}

body.dark-mode .touch-drag-ghost {
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.5);
}

/* Empty Task List Styling */
.desk-calendar-sidebar .empty-task-list {
    text-align: center;
    padding: 2rem 1rem;
    color: var(--color-gray-400);
}

body.dark-mode .desk-calendar-sidebar .empty-task-list {
    color: var(--color-gray-500);
}

/* ============================================
   QR CODE DIALOG STYLES
   ============================================ */

.dialog-qrcode {
    max-width: 400px;
    text-align: center;
}

.dialog-qrcode .dialog-description {
    color: var(--color-gray-600);
    font-size: 0.9375rem;
    margin-bottom: 1.5rem;
    line-height: 1.5;
}

.qrcode-display {
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 1.5rem;
    background-color: var(--color-white);
    border: 1px solid var(--color-gray-200);
    border-radius: var(--border-radius);
    margin-bottom: 1.5rem;
    min-height: 232px;
}

.qrcode-canvas {
    border-radius: 8px;
}

.qrcode-error {
    color: var(--color-error);
    font-size: 0.875rem;
}

.api-url-display {
    text-align: left;
    margin-bottom: 1rem;
}

.api-url-display label {
    display: block;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--color-gray-500);
    margin-bottom: 0.5rem;
}

.api-url-copyable {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem 1rem;
    background-color: var(--color-gray-100);
    border: 1px solid var(--color-gray-200);
    border-radius: 8px;
}

.api-url-copyable code {
    flex: 1;
    font-family: 'SF Mono', Monaco, 'Courier New', monospace;
    font-size: 0.8125rem;
    color: var(--color-gray-800);
    word-break: break-all;
}

.btn-copy {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    padding: 0;
    background: none;
    border: 1px solid var(--color-gray-300);
    border-radius: 8px;
    color: var(--color-gray-500);
    cursor: pointer;
    transition: all 0.2s ease;
    flex-shrink: 0;
}

.btn-copy:hover {
    background-color: var(--color-gray-200);
    color: var(--color-gray-700);
}

.btn-copy.copied {
    background-color: var(--color-success);
    border-color: var(--color-success);
    color: var(--color-white);
}

.qrcode-help {
    display: flex;
    align-items: flex-start;
    gap: 0.5rem;
    padding: 0.875rem 1rem;
    background-color: var(--color-gray-50);
    border-radius: 8px;
    font-size: 0.8125rem;
    color: var(--color-gray-600);
    text-align: left;
    line-height: 1.5;
}

.qrcode-help i {
    color: var(--color-gray-400);
    margin-top: 0.125rem;
    flex-shrink: 0;
}

/* QR Code Dialog - Dark Mode */
body.dark-mode .dialog-qrcode .dialog-description {
    color: #a3a3a3;
}

body.dark-mode .qrcode-display {
    background-color: #ffffff;
    border-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .api-url-display label {
    color: #a3a3a3;
}

body.dark-mode .api-url-copyable {
    background-color: #262626;
    border-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .api-url-copyable code {
    color: #e5e5e5;
}

body.dark-mode .btn-copy {
    border-color: rgba(255, 255, 255, 0.2);
    color: #a3a3a3;
}

body.dark-mode .btn-copy:hover {
    background-color: #404040;
    color: #fafafa;
}

body.dark-mode .qrcode-help {
    background-color: #262626;
    color: #a3a3a3;
}

body.dark-mode .qrcode-help i {
    color: #737373;
}

/* QR Code Dialog - Responsive */
@media (max-width: 480px) {
    .dialog-qrcode {
        max-width: 100%;
        margin: 1rem;
    }

    .qrcode-display {
        padding: 1rem;
    }

    .api-url-copyable {
        flex-direction: column;
        gap: 0.75rem;
    }

    .btn-copy {
        width: 100%;
        height: auto;
        padding: 0.625rem;
    }
}

/* ===== Project Management Tab ===== */

.management-container {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.management-section {
    background-color: var(--color-white);
    border-radius: var(--border-radius);
    box-shadow: var(--shadow-sm);
    border: 1px solid var(--color-gray-100);
    padding: 1.5rem;
}

.management-section-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 1rem;
}

.management-section-header h3 {
    margin: 0;
    font-size: 1rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.management-section-header h3 i {
    color: var(--color-gray-500);
}

.management-overview-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.25rem;
}

.management-field {
    display: flex;
    flex-direction: column;
    gap: 0.375rem;
}

.management-field label {
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.025em;
    color: var(--color-gray-500);
}

.management-field input,
.management-field select,
.management-field textarea {
    padding: 0.5rem 0.75rem;
    border: 1px solid var(--color-gray-200);
    border-radius: var(--border-radius);
    font-size: 0.875rem;
    background-color: var(--color-white);
    color: var(--color-gray-900);
    transition: border-color 0.2s ease;
}

.management-field input:focus,
.management-field select:focus,
.management-field textarea:focus {
    outline: none;
    border-color: var(--color-black);
}

.management-field textarea {
    min-height: 80px;
    resize: vertical;
}

.management-field-full {
    grid-column: 1 / -1;
}

.management-actions {
    grid-column: 1 / -1;
    display: flex;
    justify-content: flex-end;
    gap: 0.5rem;
    padding-top: 0.5rem;
}

/* Status badges for management */
.badge-status-planning {
    background-color: #e0e7ff;
    color: #3730a3;
}

.badge-status-active {
    background-color: #dcfce7;
    color: #166534;
}

.badge-status-on_hold {
    background-color: #fef3c7;
    color: #92400e;
}

.badge-status-completed {
    background-color: var(--color-gray-200);
    color: var(--color-gray-700);
}

.badge-status-cancelled {
    background-color: #fee2e2;
    color: #991b1b;
}

/* Severity/Importance badges */
.badge-severity-low,
.badge-importance-low-mgmt {
    background-color: #dbeafe;
    color: #1e40af;
}

.badge-severity-medium,
.badge-importance-medium-mgmt {
    background-color: #fef3c7;
    color: #92400e;
}

.badge-severity-high,
.badge-importance-high-mgmt {
    background-color: #fed7aa;
    color: #c2410c;
}

.badge-severity-critical,
.badge-importance-critical-mgmt {
    background-color: #fee2e2;
    color: #991b1b;
}

/* Budget progress bar */
.budget-progress-container {
    grid-column: 1 / -1;
    margin-top: 0.25rem;
}

.budget-progress-bar {
    width: 100%;
    height: 8px;
    background-color: var(--color-gray-200);
    border-radius: 4px;
    overflow: hidden;
}

.budget-progress-fill {
    height: 100%;
    border-radius: 4px;
    transition: width 0.3s ease;
    background-color: var(--color-black);
}

.budget-progress-fill.over-budget {
    background-color: #ef4444;
}

.budget-progress-fill.near-budget {
    background-color: #f59e0b;
}

.budget-progress-label {
    font-size: 0.75rem;
    color: var(--color-gray-500);
    margin-top: 0.25rem;
}

/* Event timeline */
.management-event-list {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.management-event-item {
    display: flex;
    align-items: flex-start;
    gap: 1rem;
    padding: 0.75rem 1rem;
    border: 1px solid var(--color-gray-100);
    border-radius: var(--border-radius);
    transition: box-shadow 0.2s ease;
}

.management-event-item:hover {
    box-shadow: var(--shadow-sm);
}

.management-event-date {
    flex-shrink: 0;
    text-align: center;
    min-width: 60px;
}

.management-event-date .day {
    font-size: 1.25rem;
    font-weight: 700;
    line-height: 1;
}

.management-event-date .month-year {
    font-size: 0.625rem;
    text-transform: uppercase;
    color: var(--color-gray-500);
    letter-spacing: 0.05em;
}

.management-event-content {
    flex: 1;
    min-width: 0;
}

.management-event-content .event-title {
    font-weight: 600;
    font-size: 0.875rem;
    margin-bottom: 0.125rem;
}

.management-event-content .event-description {
    font-size: 0.8125rem;
    color: var(--color-gray-600);
    margin-bottom: 0.25rem;
}

.management-event-meta {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.75rem;
    color: var(--color-gray-500);
}

.management-event-actions {
    flex-shrink: 0;
}

/* Document cards */
.management-document-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
    gap: 0.75rem;
}

.management-document-card {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.75rem 1rem;
    border: 1px solid var(--color-gray-100);
    border-radius: var(--border-radius);
    transition: box-shadow 0.2s ease;
}

.management-document-card:hover {
    box-shadow: var(--shadow-sm);
}

.management-document-icon {
    flex-shrink: 0;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.25rem;
    color: var(--color-gray-500);
    background-color: var(--color-gray-100);
    border-radius: var(--border-radius);
}

.management-document-info {
    flex: 1;
    min-width: 0;
}

.management-document-info .doc-name {
    font-weight: 600;
    font-size: 0.8125rem;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.management-document-info .doc-meta {
    font-size: 0.75rem;
    color: var(--color-gray-500);
}

.management-document-actions {
    flex-shrink: 0;
    display: flex;
    gap: 0.25rem;
}

/* Document upload drop zone */
.document-drop-zone {
    border: 2px dashed var(--color-gray-300);
    border-radius: var(--border-radius);
    padding: 2rem;
    text-align: center;
    color: var(--color-gray-500);
    cursor: pointer;
    transition: all 0.2s ease;
    margin-bottom: 1rem;
}

.document-drop-zone:hover,
.document-drop-zone.drag-over {
    border-color: var(--color-black);
    background-color: var(--color-gray-50, #f9fafb);
}

.document-drop-zone i {
    font-size: 2rem;
    margin-bottom: 0.5rem;
    display: block;
}

.document-drop-zone p {
    margin: 0;
    font-size: 0.875rem;
}

/* Risk cards */
.management-risk-list {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.management-risk-card {
    padding: 0.75rem 1rem;
    border: 1px solid var(--color-gray-100);
    border-radius: var(--border-radius);
    border-left: 4px solid var(--color-gray-300);
    transition: box-shadow 0.2s ease;
}

.management-risk-card:hover {
    box-shadow: var(--shadow-sm);
}

.management-risk-card.severity-low {
    border-left-color: #3b82f6;
}

.management-risk-card.severity-medium {
    border-left-color: #f59e0b;
}

.management-risk-card.severity-high {
    border-left-color: #f97316;
}

.management-risk-card.severity-critical {
    border-left-color: #ef4444;
}

.management-risk-card.resolved {
    opacity: 0.6;
    border-left-color: var(--color-gray-300);
}

.management-risk-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 0.375rem;
}

.management-risk-header .risk-title {
    font-weight: 600;
    font-size: 0.875rem;
}

.management-risk-body {
    font-size: 0.8125rem;
    color: var(--color-gray-600);
    margin-bottom: 0.375rem;
}

.management-risk-body .mitigation-label {
    font-weight: 600;
    color: var(--color-gray-700);
}

.management-risk-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-size: 0.75rem;
    color: var(--color-gray-500);
}

.management-risk-actions {
    display: flex;
    gap: 0.25rem;
}

/* Budget cost cards */
.management-budget-cost-list {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.management-budget-cost-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 0.75rem 1rem;
    border: 1px solid var(--color-gray-100);
    border-radius: var(--border-radius);
    transition: box-shadow 0.2s ease;
}

.management-budget-cost-item:hover {
    box-shadow: var(--shadow-sm);
}

.budget-cost-info {
    flex: 1;
    min-width: 0;
}

.budget-cost-name {
    font-weight: 600;
    font-size: 0.875rem;
    margin-bottom: 0.25rem;
}

.budget-cost-meta {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    flex-wrap: wrap;
    font-size: 0.75rem;
    color: var(--color-gray-500);
}

.budget-cost-doc {
    color: var(--color-gray-600);
}

.budget-cost-doc i {
    margin-right: 0.125rem;
}

.budget-cost-date {
    color: var(--color-gray-500);
}

.badge-recurrent {
    background-color: #dbeafe;
    color: #1d4ed8;
    font-size: 0.6875rem;
    padding: 0.125rem 0.5rem;
    border-radius: 999px;
    font-weight: 500;
}

.budget-cost-amount {
    font-weight: 700;
    font-size: 0.9375rem;
    white-space: nowrap;
    color: var(--color-gray-900);
}

.budget-cost-actions {
    display: flex;
    gap: 0.25rem;
}

.budget-cost-total {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 1rem;
    font-size: 0.9375rem;
    color: var(--color-gray-700);
    border-bottom: 1px solid var(--color-gray-100);
    margin-bottom: 0.75rem;
}

.budget-cost-total strong {
    font-size: 1.125rem;
    color: var(--color-gray-900);
}

/* Dark mode budget costs */
body.dark-mode .management-budget-cost-item {
    border-color: var(--color-gray-700);
}

body.dark-mode .budget-cost-amount {
    color: var(--color-gray-100);
}

body.dark-mode .budget-cost-total {
    color: var(--color-gray-400);
    border-bottom-color: var(--color-gray-700);
}

body.dark-mode .budget-cost-total strong {
    color: var(--color-gray-100);
}

body.dark-mode .badge-recurrent {
    background-color: #1e3a5f;
    color: #93c5fd;
}

/* Filter bar for events/documents/risks */
.management-filter-bar {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.management-filter-bar select {
    padding: 0.375rem 0.625rem;
    border: 1px solid var(--color-gray-200);
    border-radius: var(--border-radius);
    font-size: 0.8125rem;
    background-color: var(--color-white);
    color: var(--color-gray-700);
}

.management-empty-state {
    text-align: center;
    padding: 2rem;
    color: var(--color-gray-500);
    font-size: 0.875rem;
}

.management-empty-state i {
    font-size: 2rem;
    margin-bottom: 0.5rem;
    display: block;
    color: var(--color-gray-300);
}

/* Management loading state */
.management-loading {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    padding: 3rem 2rem;
    color: var(--color-gray-500);
}

/* Small icon buttons used in management */
.btn-icon-sm {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 28px;
    border: 1px solid var(--color-gray-200);
    border-radius: var(--border-radius);
    background: var(--color-white);
    color: var(--color-gray-500);
    cursor: pointer;
    transition: all 0.2s ease;
    font-size: 0.75rem;
}

.btn-icon-sm:hover {
    background: var(--color-gray-100);
    color: var(--color-gray-700);
}

.btn-icon-sm.danger:hover {
    background: #fee2e2;
    color: #991b1b;
    border-color: #fecaca;
}

/* Dark mode for management tab */
body.dark-mode .management-section {
    background-color: var(--color-gray-800);
    border-color: var(--color-gray-700);
}

body.dark-mode .management-field input,
body.dark-mode .management-field select,
body.dark-mode .management-field textarea {
    background-color: var(--color-gray-900);
    border-color: var(--color-gray-700);
    color: var(--color-gray-100);
}

body.dark-mode .management-field input:focus,
body.dark-mode .management-field select:focus,
body.dark-mode .management-field textarea:focus {
    border-color: var(--color-gray-500);
}

body.dark-mode .management-event-item,
body.dark-mode .management-document-card,
body.dark-mode .management-risk-card,
body.dark-mode .management-budget-cost-item {
    border-color: var(--color-gray-700);
}

body.dark-mode .management-document-icon {
    background-color: var(--color-gray-700);
    color: var(--color-gray-400);
}

body.dark-mode .document-drop-zone {
    border-color: var(--color-gray-600);
    color: var(--color-gray-400);
}

body.dark-mode .document-drop-zone:hover,
body.dark-mode .document-drop-zone.drag-over {
    border-color: var(--color-gray-400);
    background-color: var(--color-gray-800);
}

body.dark-mode .btn-icon-sm {
    background: var(--color-gray-800);
    border-color: var(--color-gray-700);
    color: var(--color-gray-400);
}

body.dark-mode .btn-icon-sm:hover {
    background: var(--color-gray-700);
    color: var(--color-gray-200);
}

body.dark-mode .management-filter-bar select {
    background-color: var(--color-gray-900);
    border-color: var(--color-gray-700);
    color: var(--color-gray-300);
}

body.dark-mode .budget-progress-bar {
    background-color: var(--color-gray-700);
}

/* Management Summary Row */
.mgmt-summary-row {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1rem;
    margin-bottom: 0.5rem;
}

.mgmt-summary-status-badge {
    display: inline-block;
    padding: 0.2rem 0.75rem;
    border-radius: 999px;
    font-size: 0.875rem;
    font-weight: 600;
    letter-spacing: 0.025em;
}

/* Management Card Layouts */
.mgmt-card-body {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.mgmt-card-2col {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.25rem;
}

.mgmt-card-3col {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    gap: 1.25rem;
}

/* Timeline Visual */
.mgmt-timeline-visual {
    width: 100%;
    height: 6px;
    background-color: var(--color-gray-200);
    border-radius: 3px;
    overflow: hidden;
}

.mgmt-timeline-progress {
    height: 100%;
    background-color: var(--color-black);
    border-radius: 3px;
    transition: width 0.3s ease;
}

/* Budget progress bar height override in card layout */
.mgmt-card-body .budget-progress-bar {
    height: 12px;
    border-radius: 6px;
}

/* Inline save button in section header */
.management-section-header .btn {
    margin-left: auto;
}

/* Dark mode: summary row */
body.dark-mode .mgmt-summary-row .dashboard-card {
    background-color: var(--color-gray-800);
    border-color: var(--color-gray-700);
}

body.dark-mode .mgmt-summary-row .dashboard-card-icon {
    background-color: var(--color-gray-700);
    color: var(--color-gray-400);
}

body.dark-mode .mgmt-summary-row .dashboard-card-value {
    color: var(--color-gray-100);
}

body.dark-mode .mgmt-timeline-visual {
    background-color: var(--color-gray-700);
}

body.dark-mode .mgmt-timeline-progress {
    background-color: var(--color-gray-300);
}

/* Responsive management */
@media (max-width: 1200px) {
    .mgmt-summary-row {
        grid-template-columns: repeat(2, 1fr);
    }

    .mgmt-card-3col {
        grid-template-columns: 1fr 1fr;
    }
}

@media (max-width: 768px) {
    .mgmt-summary-row {
        grid-template-columns: 1fr;
    }

    .mgmt-card-2col,
    .mgmt-card-3col {
        grid-template-columns: 1fr;
    }

    .management-overview-grid {
        grid-template-columns: 1fr;
    }

    .management-document-grid {
        grid-template-columns: 1fr;
    }

    .management-event-item {
        flex-direction: column;
        gap: 0.5rem;
    }

    .management-event-date {
        text-align: left;
    }
}
