/* Mobius Help Desk - Custom Styles */

/* Status badges */
.badge {
    display: inline-block;
    padding: 2px 10px;
    border-radius: 9999px;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.025em;
}
/* Status badge colors are now inline via statusBadgeStyle() */

/* Priority badges */
.priority-low { color: #6b7280; }
.priority-normal { color: #2563eb; }
.priority-high { color: #ea580c; }
.priority-urgent { color: #dc2626; font-weight: 700; }

/* Comment bubbles */
.comment-client {
    background: #eff6ff;
    border-left: 3px solid #2563eb;
}
.comment-admin {
    background: #f0fdf4;
    border-left: 3px solid #16a34a;
}
.comment-internal {
    background: #fefce8;
    border-left: 3px solid #ca8a04;
}

/* Dropzone */
.dropzone-active {
    border-color: #2563eb !important;
    background: #eff6ff;
}
.dropzone-file-row {
    animation: dropzoneFadeIn 0.2s ease;
}
@keyframes dropzoneFadeIn {
    from { opacity: 0; transform: translateY(-4px); }
    to { opacity: 1; transform: translateY(0); }
}

/* Per-file upload progress */
.upload-file-progress-track {
    width: 80px;
    height: 6px;
    background: #e5e7eb;
    border-radius: 9999px;
    overflow: hidden;
}
.upload-file-progress-bar {
    height: 100%;
    background: #2563eb;
    border-radius: 9999px;
    transition: width 0.15s ease;
}

/* View toggle */
.view-toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 6px 10px;
    border: 1px solid #d1d5db;
    border-radius: 6px;
    background: #fff;
    cursor: pointer;
    color: #6b7280;
    transition: all 0.15s;
}
.view-toggle:hover { background: #f3f4f6; }
.view-toggle.active { background: #1f2937; color: #fff; border-color: #1f2937; }

/* Kanban board */
.kanban-board {
    display: flex;
    gap: 16px;
    overflow-x: auto;
    padding-bottom: 16px;
}
.kanban-column {
    min-width: 260px;
    flex: 1;
    display: flex;
    flex-direction: column;
}
.kanban-column-header {
    padding: 10px 14px;
    border-radius: 8px 8px 0 0;
    font-weight: 600;
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 0.03em;
    display: flex;
    align-items: center;
    justify-content: space-between;
}
/* Kanban header colors are now inline via statusThemes() */
.kanban-count {
    background: rgba(0,0,0,0.1);
    border-radius: 9999px;
    padding: 1px 8px;
    font-size: 0.7rem;
}
.kanban-cards {
    min-height: 120px;
    flex: 1;
    background: #f9fafb;
    border: 1px solid #e5e7eb;
    border-top: none;
    border-radius: 0 0 8px 8px;
    padding: 8px;
}
.kanban-cards.drag-over {
    background: #eff6ff;
    border-color: #2563eb;
    border-style: dashed;
}
.kanban-card {
    background: #fff;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    padding: 12px;
    margin-bottom: 8px;
    cursor: grab;
    transition: box-shadow 0.15s, opacity 0.15s;
}
.kanban-card:hover { box-shadow: 0 2px 8px rgba(0,0,0,0.08); }
.kanban-card.dragging { opacity: 0.4; cursor: grabbing; }
.kanban-card-title {
    display: block;
    font-weight: 600;
    font-size: 0.85rem;
    color: #2563eb;
    text-decoration: none;
    margin-bottom: 4px;
    line-height: 1.3;
}
.kanban-card-title:hover { text-decoration: underline; }
.kanban-card-meta {
    font-size: 0.75rem;
    color: #6b7280;
    margin-bottom: 6px;
}
.kanban-card-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

/* SLA indicators */
.sla-ok { color: #16a34a; font-size: 0.6rem; }
.sla-warning { color: #eab308; font-size: 0.6rem; }
.sla-breached { color: #dc2626; font-size: 0.6rem; animation: slaPulse 1.5s infinite; }
@keyframes slaPulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.4; }
}

/* Bulk action toolbar */
.bulk-toolbar {
    position: fixed;
    bottom: 1rem;
    left: 50%;
    transform: translateX(-50%);
    background: #1f2937;
    color: #fff;
    border-radius: 12px;
    box-shadow: 0 8px 24px rgba(0,0,0,0.2);
    padding: 12px 24px;
    display: flex;
    align-items: center;
    gap: 16px;
    z-index: 50;
}

/* Stats bars */
.stat-bar {
    height: 8px;
    border-radius: 9999px;
    transition: width 0.3s ease;
}

/* ========== Client Portal Themes ========== */

/* Theme switcher button */
.theme-switcher {
    position: relative;
}
.theme-menu {
    display: none;
    position: absolute;
    right: 0;
    top: 100%;
    margin-top: 6px;
    background: #fff;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    box-shadow: 0 4px 16px rgba(0,0,0,0.1);
    padding: 6px;
    z-index: 50;
    min-width: 150px;
}
.theme-menu.open { display: block; }
.theme-menu button {
    display: flex;
    align-items: center;
    gap: 8px;
    width: 100%;
    padding: 7px 10px;
    border: none;
    background: none;
    border-radius: 6px;
    font-size: 0.8rem;
    color: #374151;
    cursor: pointer;
    text-align: left;
}
.theme-menu button:hover { background: #f3f4f6; }
.theme-menu button.active { background: #eff6ff; color: #2563eb; font-weight: 600; }
.theme-swatch {
    width: 14px;
    height: 14px;
    border-radius: 50%;
    border: 2px solid rgba(0,0,0,0.1);
    flex-shrink: 0;
}

/* Dark theme */
[data-theme="dark"] body { background: #111827 !important; color: #e5e7eb; }
[data-theme="dark"] nav { background: #1f2937 !important; border-color: #374151 !important; }
[data-theme="dark"] nav a, [data-theme="dark"] nav span { color: #d1d5db !important; }
[data-theme="dark"] nav .font-bold { color: #f9fafb !important; }
[data-theme="dark"] main h1, [data-theme="dark"] main h2, [data-theme="dark"] main h3 { color: #f3f4f6 !important; }
[data-theme="dark"] .bg-white, [data-theme="dark"] form.bg-white { background: #1f2937 !important; border-color: #374151 !important; }
[data-theme="dark"] table { color: #d1d5db; }
[data-theme="dark"] thead { background: #1f2937 !important; }
[data-theme="dark"] thead th { color: #9ca3af !important; }
[data-theme="dark"] tbody tr { border-color: #374151 !important; }
[data-theme="dark"] tbody tr:hover { background: #374151 !important; }
[data-theme="dark"] td { color: #d1d5db !important; }
[data-theme="dark"] td.text-blue-600, [data-theme="dark"] .text-blue-600 { color: #60a5fa !important; }
[data-theme="dark"] .text-gray-800, [data-theme="dark"] .text-gray-700 { color: #e5e7eb !important; }
[data-theme="dark"] .text-gray-600, [data-theme="dark"] .text-gray-500 { color: #9ca3af !important; }
[data-theme="dark"] .border-gray-200, [data-theme="dark"] .border-gray-300 { border-color: #374151 !important; }
[data-theme="dark"] .bg-gray-50 { background: #111827 !important; }
[data-theme="dark"] input, [data-theme="dark"] textarea, [data-theme="dark"] select {
    background: #374151 !important; color: #e5e7eb !important; border-color: #4b5563 !important;
}
[data-theme="dark"] .comment-client { background: #1e3a5f !important; }
[data-theme="dark"] .comment-admin { background: #14532d !important; }
[data-theme="dark"] footer { color: #6b7280 !important; }
[data-theme="dark"] .theme-menu { background: #1f2937; border-color: #374151; }
[data-theme="dark"] .theme-menu button { color: #d1d5db; }
[data-theme="dark"] .theme-menu button:hover { background: #374151; }
[data-theme="dark"] .theme-menu button.active { background: #1e3a5f; color: #60a5fa; }
[data-theme="dark"] nav button.border { border-color: #4b5563 !important; color: #9ca3af !important; }
[data-theme="dark"] nav button.border:hover { background: #374151 !important; }
[data-theme="dark"] .dropzone-area { border-color: #4b5563 !important; }
[data-theme="dark"] .dropzone-area p { color: #9ca3af !important; }
[data-theme="dark"] a.bg-blue-50 { background: #1e3a5f !important; color: #60a5fa !important; }

/* Slate theme — soft dark nav, muted warm body */
[data-theme="slate"] body { background: #f1f5f9 !important; }
[data-theme="slate"] nav { background: #1e293b !important; border-color: #334155 !important; }
[data-theme="slate"] nav a, [data-theme="slate"] nav span { color: #cbd5e1 !important; }
[data-theme="slate"] nav .font-bold { color: #f1f5f9 !important; }
[data-theme="slate"] nav .text-red-600 { color: #fca5a5 !important; }
[data-theme="slate"] .bg-white { background: #f8fafc !important; }
[data-theme="slate"] .bg-gray-50 { background: #f1f5f9 !important; }
[data-theme="slate"] thead { background: #f1f5f9 !important; }
[data-theme="slate"] .border-gray-200 { border-color: #e2e8f0 !important; }
[data-theme="slate"] .text-gray-800 { color: #1e293b !important; }
[data-theme="slate"] .text-gray-600, [data-theme="slate"] .text-gray-500 { color: #64748b !important; }
[data-theme="slate"] .bg-blue-600, [data-theme="slate"] button.bg-blue-600 { background: #3b82f6 !important; }
[data-theme="slate"] .bg-blue-600:hover, [data-theme="slate"] button.bg-blue-600:hover { background: #2563eb !important; }
[data-theme="slate"] .text-blue-600 { color: #3b82f6 !important; }
[data-theme="slate"] .comment-client { background: #e0f2fe !important; border-color: #3b82f6 !important; }
[data-theme="slate"] .comment-admin { background: #ecfdf5 !important; border-color: #10b981 !important; }
[data-theme="slate"] input, [data-theme="slate"] textarea, [data-theme="slate"] select {
    background: #fff !important; border-color: #cbd5e1 !important;
}
[data-theme="slate"] .theme-menu { background: #f8fafc; border-color: #e2e8f0; }
[data-theme="slate"] nav button.border { border-color: #475569 !important; color: #94a3b8 !important; }
[data-theme="slate"] nav button.border:hover { background: #334155 !important; }

/* Ocean theme */
[data-theme="ocean"] nav { background: #0f766e !important; border-color: #0d9488 !important; }
[data-theme="ocean"] nav a, [data-theme="ocean"] nav span { color: #ccfbf1 !important; }
[data-theme="ocean"] nav .font-bold { color: #fff !important; }
[data-theme="ocean"] nav .text-red-600 { color: #fecdd3 !important; }
[data-theme="ocean"] .bg-blue-600, [data-theme="ocean"] button.bg-blue-600 { background: #0d9488 !important; }
[data-theme="ocean"] .bg-blue-600:hover, [data-theme="ocean"] button.bg-blue-600:hover { background: #0f766e !important; }
[data-theme="ocean"] .text-blue-600 { color: #0d9488 !important; }
[data-theme="ocean"] .comment-client { background: #f0fdfa !important; border-color: #14b8a6 !important; }
[data-theme="ocean"] .upload-file-progress-bar { background: #0d9488; }
[data-theme="ocean"] .dropzone-active { border-color: #0d9488 !important; background: #f0fdfa !important; }

/* Sunset theme */
[data-theme="sunset"] nav { background: #9a3412 !important; border-color: #c2410c !important; }
[data-theme="sunset"] nav a, [data-theme="sunset"] nav span { color: #ffedd5 !important; }
[data-theme="sunset"] nav .font-bold { color: #fff !important; }
[data-theme="sunset"] nav .text-red-600 { color: #fecdd3 !important; }
[data-theme="sunset"] body { background: #fffbeb !important; }
[data-theme="sunset"] .bg-blue-600, [data-theme="sunset"] button.bg-blue-600 { background: #ea580c !important; }
[data-theme="sunset"] .bg-blue-600:hover, [data-theme="sunset"] button.bg-blue-600:hover { background: #c2410c !important; }
[data-theme="sunset"] .text-blue-600 { color: #ea580c !important; }
[data-theme="sunset"] .comment-client { background: #fff7ed !important; border-color: #f97316 !important; }
[data-theme="sunset"] .upload-file-progress-bar { background: #ea580c; }
[data-theme="sunset"] .dropzone-active { border-color: #ea580c !important; background: #fff7ed !important; }

/* Lavender theme */
[data-theme="lavender"] nav { background: #6b21a8 !important; border-color: #7c3aed !important; }
[data-theme="lavender"] nav a, [data-theme="lavender"] nav span { color: #f3e8ff !important; }
[data-theme="lavender"] nav .font-bold { color: #fff !important; }
[data-theme="lavender"] nav .text-red-600 { color: #fecdd3 !important; }
[data-theme="lavender"] body { background: #faf5ff !important; }
[data-theme="lavender"] .bg-blue-600, [data-theme="lavender"] button.bg-blue-600 { background: #7c3aed !important; }
[data-theme="lavender"] .bg-blue-600:hover, [data-theme="lavender"] button.bg-blue-600:hover { background: #6b21a8 !important; }
[data-theme="lavender"] .text-blue-600 { color: #7c3aed !important; }
[data-theme="lavender"] .comment-client { background: #faf5ff !important; border-color: #a78bfa !important; }
[data-theme="lavender"] .upload-file-progress-bar { background: #7c3aed; }
[data-theme="lavender"] .dropzone-active { border-color: #7c3aed !important; background: #faf5ff !important; }
