/* css/style.css */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', 'Segoe UI', 'Poppins', sans-serif;
    background: radial-gradient(circle at 20% 30%, #0a0f1e, #03050b);
    color: #eef2ff;
    min-height: 100vh;
    overflow-x: hidden;
    position: relative;
}

/* ===== 暗黑背景光晕与线条 ===== */
body::before {
    content: '';
    position: fixed;
    top: 0; left: 0;
    width: 100%; height: 100%;
    pointer-events: none; z-index: -1;
    background:
        radial-gradient(ellipse at 15% 20%, rgba(56,189,248,0.08) 0%, transparent 60%),
        radial-gradient(ellipse at 85% 80%, rgba(168,85,247,0.06) 0%, transparent 55%),
        radial-gradient(ellipse at 50% 10%, rgba(56,189,248,0.05) 0%, transparent 50%),
        radial-gradient(ellipse at 20% 90%, rgba(16,185,129,0.05) 0%, transparent 50%),
        radial-gradient(ellipse at 90% 30%, rgba(249,115,22,0.04) 0%, transparent 45%);
}
body::after {
    content: '';
    position: fixed;
    top: 0; left: 0;
    width: 100%; height: 100%;
    pointer-events: none; z-index: -1;
    background-image:
        linear-gradient(135deg, transparent 49.8%, rgba(56,189,248,0.03) 49.8%, rgba(56,189,248,0.03) 50.2%, transparent 50.2%),
        linear-gradient(225deg, transparent 49.8%, rgba(168,85,247,0.02) 49.8%, rgba(168,85,247,0.02) 50.2%, transparent 50.2%),
        linear-gradient(180deg, transparent 24.8%, rgba(56,189,248,0.015) 24.8%, rgba(56,189,248,0.015) 25.2%, transparent 25.2%),
        linear-gradient(180deg, transparent 49.8%, rgba(168,85,247,0.012) 49.8%, rgba(168,85,247,0.012) 50.2%, transparent 50.2%),
        linear-gradient(180deg, transparent 74.8%, rgba(56,189,248,0.015) 74.8%, rgba(56,189,248,0.015) 75.2%, transparent 75.2%),
        linear-gradient(90deg, transparent 19.8%, rgba(16,185,129,0.012) 19.8%, rgba(16,185,129,0.012) 20.2%, transparent 20.2%),
        linear-gradient(90deg, transparent 39.8%, rgba(249,115,22,0.01) 39.8%, rgba(249,115,22,0.01) 40.2%, transparent 40.2%),
        linear-gradient(90deg, transparent 59.8%, rgba(56,189,248,0.012) 59.8%, rgba(56,189,248,0.012) 60.2%, transparent 60.2%),
        linear-gradient(90deg, transparent 79.8%, rgba(168,85,247,0.01) 79.8%, rgba(168,85,247,0.01) 80.2%, transparent 80.2%);
    background-size: 100% 100%;
}

/* 毛玻璃 */
.glass {
    background: rgba(15,25,45,0.6);
    backdrop-filter: blur(12px);
    border-radius: 24px;
    border: 1px solid rgba(255,255,255,0.08);
    box-shadow: 0 8px 20px rgba(0,0,0,0.3);
}

/* 侧边栏 */
.sidebar {
    position: fixed; left: 0; top: 0; width: 260px; height: 100vh;
    background: rgba(10,18,28,0.75); backdrop-filter: blur(16px);
    border-right: 1px solid rgba(255,255,255,0.05);
    padding: 24px 16px; display: flex; flex-direction: column; z-index: 100;
}
.logo {
    font-size: 1.6rem; font-weight: 700;
    background: linear-gradient(135deg, #a5f3fc, #38bdf8);
    -webkit-background-clip: text; background-clip: text; color: transparent;
    margin-bottom: 40px; text-align: center; letter-spacing: -0.5px;
}
.nav-links { flex: 1; display: flex; flex-direction: column; gap: 12px; }
.nav-links a {
    color: #ccd6f0; text-decoration: none; padding: 12px 18px; border-radius: 14px;
    font-weight: 500; transition: all 0.2s; display: flex; align-items: center; gap: 12px;
    font-size: 0.95rem; background: transparent;
}
.nav-links a i { width: 24px; text-align: center; font-style: normal; font-weight: 600; }
.nav-links a:hover { background: rgba(56,189,248,0.15); color: #bae6fd; transform: translateX(4px); }
.nav-links a.active { background: rgba(56,189,248,0.25); color: #7dd3fc; border-left: 3px solid #38bdf8; }
.logout-btn { margin-top: auto; color: #f87171 !important; }
.logout-btn:hover { background: rgba(248,113,113,0.2) !important; }

/* 主内容区域 - 顶部内边距统一为 5px */
.main-content {
    margin-left: 260px;
    padding: 5px 32px 28px 32px;
    min-height: 100vh;
}

.card {
    background: rgba(18,28,40,0.6);
    backdrop-filter: blur(8px);
    border-radius: 28px;
    padding: 24px;
    margin-bottom: 24px;
    border: 1px solid rgba(255,255,255,0.05);
    box-shadow: 0 4px 12px rgba(0,0,0,0.2);
}
.card h3, .card h2 { font-weight: 600; margin-bottom: 16px; color: #e2e8ff; }

table { width: 100%; border-collapse: collapse; color: #e2e8f0; }
th, td { padding: 12px 8px; border-bottom: 1px solid rgba(255,255,255,0.1); text-align: left; }
th { font-weight: 600; color: #94a3b8; }

button, .btn-sm {
    background: rgba(56,189,248,0.2);
    border: 1px solid rgba(56,189,248,0.5);
    color: #bae6fd;
    padding: 8px 16px;
    border-radius: 40px;
    cursor: pointer;
    font-weight: 500;
    transition: all 0.2s;
}
button:hover, .btn-sm:hover { background: #38bdf8; color: #0a0f1e; border-color: #38bdf8; }

input, select, textarea {
    background: rgba(0,0,0,0.4);
    border: 1px solid rgba(255,255,255,0.2);
    border-radius: 16px;
    padding: 12px 14px;
    color: white;
    font-size: 14px;
    width: 100%;
    transition: all 0.2s;
}
input:focus, select:focus, textarea:focus {
    outline: none;
    border-color: #38bdf8;
    background: rgba(0,0,0,0.6);
}
input[type="date"]::-webkit-calendar-picker-indicator { filter: invert(1); cursor: pointer; }

.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.7);
    backdrop-filter: blur(4px);
    justify-content: center;
    align-items: center;
    z-index: 1000;
}
.modal-content {
    background: rgba(20,30,45,0.95);
    backdrop-filter: blur(20px);
    border-radius: 32px;
    width: 500px;
    max-width: 90%;
    padding: 28px;
    border: 1px solid rgba(255,255,255,0.2);
    display: flex;
    flex-direction: column;
    gap: 20px;
    overflow-y: auto;
    max-height: 80vh;
}
.modal-content > div { display: flex; gap: 12px; justify-content: flex-end; }
.modal-content > div button { margin: 0; flex: 1; }
.modal-content input, .modal-content select, .modal-content textarea { margin: 0; }

.share-container {
    max-width: 1000px;
    margin: 40px auto;
    background: rgba(0,0,0,0.6);
    backdrop-filter: blur(12px);
    border-radius: 32px;
    padding: 32px;
}

.custom-modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.8);
    backdrop-filter: blur(8px);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 10000;
}
.custom-modal {
    background: rgba(20,30,45,0.95);
    backdrop-filter: blur(20px);
    border-radius: 32px;
    width: 400px;
    padding: 28px;
    text-align: center;
    border: 1px solid rgba(255,255,255,0.2);
    overflow-y: auto;
    max-height: 80vh;
}
.custom-modal p { margin-bottom: 24px; font-size: 16px; }
.custom-modal-buttons { display: flex; gap: 12px; justify-content: center; }
.custom-modal-buttons button { padding: 8px 24px; }

/* flatpickr 暗色 */
.flatpickr-calendar { background: #1e293b !important; border: 1px solid #38bdf8 !important; box-shadow: 0 8px 20px rgba(0,0,0,0.3) !important; border-radius: 16px !important; }
.flatpickr-calendar .flatpickr-months { background: #0f172a !important; border-radius: 16px 16px 0 0 !important; }
.flatpickr-calendar .flatpickr-month { color: #e2e8f0 !important; }
.flatpickr-calendar .flatpickr-current-month .flatpickr-monthDropdown-months,
.flatpickr-calendar .flatpickr-current-month input.cur-year { color: #e2e8f0 !important; }
.flatpickr-calendar .flatpickr-weekdays { background: #0f172a !important; }
.flatpickr-calendar .flatpickr-weekday { color: #38bdf8 !important; }
.flatpickr-calendar .flatpickr-day { color: #cbd5e1 !important; border-color: #334155 !important; }
.flatpickr-calendar .flatpickr-day.selected,
.flatpickr-calendar .flatpickr-day.startRange,
.flatpickr-calendar .flatpickr-day.endRange { background: #38bdf8 !important; border-color: #38bdf8 !important; color: #0a0f1e !important; }
.flatpickr-calendar .flatpickr-day:hover { background: #334155 !important; border-color: #38bdf8 !important; }
.flatpickr-calendar .flatpickr-day.today { border-color: #38bdf8 !important; }
.flatpickr-calendar .flatpickr-day.today:hover { background: #38bdf8 !important; color: #0a0f1e !important; }
.flatpickr-calendar .flatpickr-day.prevMonthDay,
.flatpickr-calendar .flatpickr-day.nextMonthDay { color: #64748b !important; }
.flatpickr-calendar .flatpickr-current-month .flatpickr-monthDropdown-months:hover,
.flatpickr-calendar .flatpickr-current-month input.cur-year:hover { background: #334155 !important; }
.flatpickr-calendar .flatpickr-time { border-top: 1px solid #334155 !important; }
.flatpickr-calendar .flatpickr-time input,
.flatpickr-calendar .flatpickr-time .flatpickr-time-separator,
.flatpickr-calendar .flatpickr-time .flatpickr-am-pm { color: #e2e8f0 !important; }
.flatpickr-calendar .flatpickr-time input:hover,
.flatpickr-calendar .flatpickr-time .flatpickr-am-pm:hover { background: #334155 !important; }
.flatpickr-months .flatpickr-prev-month svg,
.flatpickr-months .flatpickr-next-month svg,
.flatpickr-current-month .numInputWrapper .arrowUp,
.flatpickr-current-month .numInputWrapper .arrowDown { fill: #ffffff !important; stroke: #ffffff !important; }
.flatpickr-current-month .numInputWrapper .arrowUp:after,
.flatpickr-current-month .numInputWrapper .arrowDown:after { border-color: #ffffff transparent !important; }

/* 导航分组 */
.nav-group { margin-bottom: 4px; }
.nav-group-title {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 18px;
    border-radius: 14px;
    font-weight: 500;
    color: #ccd6f0;
    cursor: pointer;
    transition: all 0.2s;
    user-select: none;
}
.nav-group-title:hover { background: rgba(56,189,248,0.15); color: #bae6fd; }
.nav-group-title.active { background: rgba(56,189,248,0.25); color: #7dd3fc; border-left: 3px solid #38bdf8; }
.nav-group-title i { width: 24px; text-align: center; font-style: normal; font-weight: 600; }
.arrow { margin-left: auto; font-size: 12px; transition: transform 0.2s; }
.arrow.expanded { transform: rotate(90deg); }
.nav-submenu { padding-left: 20px; margin-top: 4px; display: flex; flex-direction: column; gap: 4px; }
.nav-submenu a {
    color: #ccd6f0;
    text-decoration: none;
    padding: 10px 18px;
    border-radius: 12px;
    font-weight: 500;
    transition: all 0.2s;
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 0.9rem;
}
.nav-submenu a i { width: 24px; text-align: center; font-style: normal; font-weight: 600; }
.nav-submenu a:hover { background: rgba(56,189,248,0.15); color: #bae6fd; }
.nav-submenu a.active { background: rgba(56,189,248,0.25); color: #38bdf8; border-left: 3px solid #38bdf8; }

/* 底部操作区 */
.sidebar-bottom {
    margin-top: auto;
    display: flex;
    flex-direction: column;
    gap: 8px;
}
.theme-toggle {
    background: transparent;
    border: 1px solid rgba(56,189,248,0.4);
    color: #38bdf8;
    padding: 8px 12px;
    border-radius: 20px;
    cursor: pointer;
    font-size: 13px;
    transition: all 0.2s;
    text-align: center;
}
.theme-toggle:hover { background: rgba(56,189,248,0.15); }

/* ===================== 亮色主题 ===================== */
body.light-theme {
    background: linear-gradient(135deg, #f2f3f5 0%, #e9ecef 100%);
    color: #212529;
}
body.light-theme::before,
body.light-theme::after { opacity: 0.2; }

body.light-theme .sidebar {
    background: rgba(245,246,248,0.95);
    border-right: 1px solid #dde0e4;
    backdrop-filter: blur(12px);
    color: #212529;
}
body.light-theme .sidebar .logo {
    background: linear-gradient(135deg, #4f6ef7, #3b82f6);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}
body.light-theme .nav-links a,
body.light-theme .nav-group-title { color: #495057; }
body.light-theme .nav-links a:hover,
body.light-theme .nav-group-title:hover { background: rgba(79,110,247,0.08); color: #1e40af; }
body.light-theme .nav-links a.active,
body.light-theme .nav-group-title.active { background: rgba(79,110,247,0.12); color: #1e3a8a; border-left: 3px solid #4f6ef7; }
body.light-theme .nav-submenu a { color: #6c757d; }
body.light-theme .nav-submenu a:hover { background: rgba(79,110,247,0.08); color: #1e40af; }
body.light-theme .nav-submenu a.active { background: rgba(79,110,247,0.12); color: #1e3a8a; }

body.light-theme .card {
    background: #f8f9fa;
    border: 1px solid #e0e3e8;
    box-shadow: 0 2px 8px rgba(0,0,0,0.04);
}
body.light-theme .card h3, body.light-theme .card h2 { color: #1e293b; }
body.light-theme table { color: #212529; background: #f8f9fa; }
body.light-theme th { color: #495057; border-bottom-color: #dee2e6; }
body.light-theme td { border-bottom-color: #e9ecef; }
body.light-theme tr:hover td { background: #eef1f5; }

body.light-theme button,
body.light-theme .btn-sm {
    background: rgba(79,110,247,0.08);
    border: 1px solid rgba(79,110,247,0.3);
    color: #1e40af;
}
body.light-theme button:hover,
body.light-theme .btn-sm:hover {
    background: #4f6ef7;
    color: #ffffff;
    border-color: #4f6ef7;
}

body.light-theme input,
body.light-theme select,
body.light-theme textarea {
    background: #f2f3f5;
    border: 1px solid #ced4da;
    color: #212529;
}
body.light-theme input:focus,
body.light-theme select:focus,
body.light-theme textarea:focus {
    border-color: #4f6ef7;
    box-shadow: 0 0 0 2px rgba(79,110,247,0.15);
    background: #ffffff;
}

body.light-theme .modal-content,
body.light-theme .custom-modal,
body.light-theme .field-modal,
body.light-theme .preview-content,
body.light-theme .view-modal-content {
    background: #f8f9fa;
    border: 1px solid #dde0e4;
    color: #212529;
}
body.light-theme .modal-content > div button,
body.light-theme .custom-modal-buttons button,
body.light-theme .modal-actions button {
    color: #1e40af;
    background: rgba(79,110,247,0.1);
    border-color: rgba(79,110,247,0.3);
}
body.light-theme .modal-content > div button:hover,
body.light-theme .custom-modal-buttons button:hover,
body.light-theme .modal-actions button:hover {
    background: #4f6ef7;
    color: #fff;
}
body.light-theme .custom-modal-overlay { background: rgba(0,0,0,0.4); }

body.light-theme .detail-container {
    background: #f8f9fa;
    border: 1px solid #e0e3e8;
}
body.light-theme .top-bar { color: #495057; }
body.light-theme .page-badge {
    background: rgba(79,110,247,0.1);
    color: #4f6ef7;
    border-color: #4f6ef7;
}

body.light-theme .kanban-column { background: #f4f5f7; border: 1px solid #e0e3e8; }
body.light-theme .task-card { background: #ffffff; border: 1px solid #e0e3e8; box-shadow: 0 1px 4px rgba(0,0,0,0.03); }
body.light-theme .task-card:hover { background: #f0f2f5; }

body.light-theme .doc-list-item,
body.light-theme .view-attachment-item,
body.light-theme .file-item,
body.light-theme .view-doc-content {
    background: #f8f9fa;
    border: 1px solid #e9ecef;
    color: #212529;
}
body.light-theme .doc-list-item:hover,
body.light-theme .file-item:hover { background: #eef1f5; }
body.light-theme .doc-title { color: #212529; }
body.light-theme .doc-meta,
body.light-theme .file-meta { color: #6c757d; }

body.light-theme .file-list { background: #f8f9fa; }

body.light-theme .project-card {
    background: #f8f9fa;
    border: 1px solid #e0e3e8;
    color: #212529;
    box-shadow: 0 2px 8px rgba(0,0,0,0.03);
}
body.light-theme .project-card:hover {
    background: #eef1f5;
    border-color: #4f6ef7;
}
body.light-theme .model-sidebar {
    background: #f0f2f5;
    border-right: 1px solid #dee2e6;
}
body.light-theme .panel {
    background: #f8f9fa;
    border-left: 1px solid #dee2e6;
}
body.light-theme #docEditorPage { background: #f0f2f5 !important; }
body.light-theme #docEditorPage > div {
    background: #f8f9fa !important;
    border: 1px solid #dee2e6 !important;
    color: #212529;
}
body.light-theme #docEditorPage .backToListBtn {
    background: transparent;
    border: 1px solid #4f6ef7;
    color: #4f6ef7;
}
body.light-theme #docEditorPage .backToListBtn:hover {
    background: #4f6ef7;
    color: #ffffff;
}
body.light-theme #docEditorPage .editor-title { color: #212529; }

body.light-theme .EasyMDEContainer .CodeMirror {
    background: #ffffff !important;
    color: #212529 !important;
    border-color: #ced4da !important;
}
body.light-theme .EasyMDEContainer .CodeMirror-gutters {
    background: #f8f9fa !important;
    border-right-color: #dee2e6 !important;
    color: #6c757d !important;
}
body.light-theme .EasyMDEContainer .CodeMirror-cursor { border-left-color: #4f6ef7 !important; }
body.light-theme .EasyMDEContainer .CodeMirror-selected { background: rgba(79,110,247,0.15) !important; }
body.light-theme .EasyMDEContainer .editor-toolbar {
    background: #f8f9fa !important;
    border-bottom-color: #dee2e6 !important;
}
body.light-theme .EasyMDEContainer .editor-toolbar button { color: #495057 !important; }
body.light-theme .EasyMDEContainer .editor-toolbar button:hover { background: rgba(79,110,247,0.08) !important; }
body.light-theme .EasyMDEContainer .editor-toolbar button.active { background: rgba(79,110,247,0.12) !important; color: #1e40af !important; }
body.light-theme .EasyMDEContainer .editor-preview,
body.light-theme .EasyMDEContainer .editor-preview-active,
body.light-theme .EasyMDEContainer .editor-preview-side {
    background: #ffffff !important;
    color: #212529 !important;
}
body.light-theme .EasyMDEContainer .editor-preview a { color: #4f6ef7 !important; }
body.light-theme .EasyMDEContainer .editor-preview code { background: #e9ecef !important; color: #212529 !important; }
body.light-theme .EasyMDEContainer .editor-preview pre { background: #e9ecef !important; border-color: #dee2e6 !important; }
body.light-theme .EasyMDEContainer .CodeMirror-linenumber { color: #6c757d !important; }
body.light-theme .CodeMirror-statusbar {
    background: #f0f2f5 !important;
    color: #6c757d !important;
    border-top: 1px solid #e0e3e8 !important;
}
body.light-theme .attachment-upload-area {
    background: #f0f2f5;
    border-color: #ced4da;
    color: #212529;
}
body.light-theme .attachment-upload-area h4 { color: #212529; }
body.light-theme .attachment-list-item {
    background: #ffffff;
    border: 1px solid #e0e3e8;
    color: #212529;
}
body.light-theme .editor-footer .auto-save-status { color: #6c757d; }
body.light-theme .view-doc-content {
    background: #f8f9fa;
    border-color: #e0e3e8;
}
body.light-theme .model-card {
    background: #f8f9fa;
    border: 1px solid #cbd5e1;
    color: #212529;
    box-shadow: 0 2px 8px rgba(0,0,0,0.06);
}
body.light-theme .model-card .card-header { background: rgba(79,110,247,0.2) !important; color: #1e3a8a; }
body.light-theme .model-card .field-name { color: #212529; }
body.light-theme .model-card .field-type { color: #6c757d; }
body.light-theme .model-card .card-footer { color: #6c757d; border-top-color: #dee2e6; }
body.light-theme .toolbar {
    background: #f0f2f5;
    border-bottom: 1px solid #dee2e6;
}
body.light-theme .toolbar button { color: #495057; }
body.light-theme .toolbar button:hover { background: rgba(79,110,247,0.1); color: #1e40af; }
body.light-theme .canvas-info { color: #6c757d; }
body.light-theme .preview-modal { background: rgba(0,0,0,0.75); }
body.light-theme .preview-content {
    background: #f8f9fa;
    border: 1px solid #dde0e4;
    color: #212529;
}
body.light-theme .global-toast {
    background: #f8f9fa;
    color: #212529;
    border: 1px solid #4f6ef7;
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}
body.light-theme .disk-container .upload-area {
    background: #f8f9fa;
    border: 1px dashed #adb5bd;
}
body.light-theme .kanban-column .column-header span:last-child {
    background: #e9ecef;
    color: #212529;
}
body.light-theme .stat-card {
    background: #f8f9fa;
    border: 1px solid #e0e3e8;
    color: #212529;
    box-shadow: 0 2px 8px rgba(0,0,0,0.03);
}
body.light-theme .stat-card:hover {
    background: #eef1f5;
    border-color: #4f6ef7;
}
body.light-theme .stat-number { color: #4f6ef7; }
body.light-theme .stat-label { color: #6c757d; }
body.light-theme .todo-card {
    background: #f8f9fa;
    border: 1px solid #e0e3e8;
    color: #212529;
    box-shadow: 0 2px 8px rgba(0,0,0,0.03);
}
body.light-theme .todo-card h3 { color: #1e293b; border-bottom-color: #dee2e6; }
body.light-theme .todo-item {
    background: #ffffff;
    border: 1px solid #e9ecef;
    color: #212529;
}
body.light-theme .todo-item:hover { background: #eef1f5; }
body.light-theme .todo-title { color: #212529; }
body.light-theme .todo-meta { color: #6c757d; }
body.light-theme .flatpickr-calendar { background: #ffffff !important; border: 1px solid #ced4da !important; }
body.light-theme .flatpickr-month,
body.light-theme .flatpickr-weekday,
body.light-theme .flatpickr-day { color: #212529 !important; }
body.light-theme .flatpickr-day.today { border-color: #4f6ef7 !important; }
body.light-theme .flatpickr-day.selected { background: #4f6ef7 !important; color: #fff !important; }
body.light-theme .flatpickr-day:hover { background: #e9ecef !important; }
body.light-theme .flatpickr-months { background: #f8f9fa !important; }
body.light-theme .flatpickr-current-month .flatpickr-monthDropdown-months,
body.light-theme .flatpickr-current-month input.cur-year { color: #212529 !important; }
body.light-theme .flatpickr-prev-month svg,
body.light-theme .flatpickr-next-month svg { fill: #6c757d !important; }
body.light-theme .theme-toggle {
    color: #4f6ef7;
    border-color: #4f6ef7;
}
body.light-theme .theme-toggle:hover { background: rgba(79,110,247,0.12); }

/* ===== 统一滚动条样式 ===== */
::-webkit-scrollbar { width: 6px; height: 6px; background: transparent; }
::-webkit-scrollbar-track { background: transparent; border-radius: 3px; }
::-webkit-scrollbar-thumb { background: rgba(255,255,255,0.12); border-radius: 3px; min-height: 30px; }
::-webkit-scrollbar-thumb:hover { background: rgba(255,255,255,0.25); }
::-webkit-scrollbar-corner { background: transparent; }
body.light-theme ::-webkit-scrollbar-thumb { background: rgba(0,0,0,0.12); }
body.light-theme ::-webkit-scrollbar-thumb:hover { background: rgba(0,0,0,0.25); }

/* ========== 移动端适配 ========== */
@media screen and (max-width: 768px) {
    .sidebar {
        transform: translateX(-100%);
        transition: transform 0.3s ease;
        width: 260px;
        z-index: 1000;
        position: fixed;
        top: 0;
        left: 0;
        height: 100%;
        background: rgba(10,18,28,0.95);
        backdrop-filter: blur(16px);
    }
    .sidebar.open { transform: translateX(0); }
    .main-content {
        margin-left: 0;
        padding: 5px 16px 28px 16px;
        width: 100%;
    }
    .menu-toggle {
        position: fixed;
        top: 12px;
        left: 12px;
        z-index: 1001;
        background: rgba(56,189,248,0.2);
        border: 1px solid #38bdf8;
        border-radius: 8px;
        padding: 8px 12px;
        font-size: 20px;
        cursor: pointer;
        color: #38bdf8;
        backdrop-filter: blur(4px);
    }
    .sidebar-overlay {
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        background: rgba(0,0,0,0.5);
        z-index: 999;
        display: none;
    }
    .sidebar-overlay.active { display: block; }
    .card { padding: 16px; border-radius: 20px; }
    table { display: block; overflow-x: auto; white-space: nowrap; -webkit-overflow-scrolling: touch; }
    table th, table td { padding: 10px 8px; font-size: 13px; }
    button, .btn-sm, .btn-primary { padding: 6px 12px; font-size: 13px; }
    input, select, textarea { padding: 10px 12px; font-size: 14px; }
    .dashboard-cards { grid-template-columns: repeat(2, 1fr); gap: 12px; }
    .kanban-board { grid-template-columns: 1fr !important; gap: 16px; }
    .file-item { flex-direction: column; align-items: flex-start; gap: 8px; }
    .file-actions { width: 100%; display: flex; flex-wrap: wrap; gap: 8px; }
    .image-grid { grid-template-columns: repeat(auto-fill, minmax(100px, 1fr)); gap: 8px; }
    .image-item { width: 100%; }
    .modal-content, .custom-modal { width: 90%; margin: 0 auto; padding: 20px; }
    .detail-container { padding: 20px; margin: 16px; }
    .send-container, .transfer-container { width: 95%; padding: 20px; margin: 10px auto; }
    .code-input-area { flex-direction: column; }
}
@media screen and (max-width: 480px) {
    .dashboard-cards { grid-template-columns: 1fr; }
    .todo-section { grid-template-columns: 1fr; }
    .stat-number { font-size: 1.8rem; }
    .page-badge, .back-link { font-size: 12px; }
    .btn-icon { font-size: 14px; }
}

/* ========== 项目详情页专用样式（统一放在此处） ========== */
.project-header {
    margin-bottom: 24px;
}
.project-header h2 {
    margin-bottom: 12px;
}
.project-summary {
    background: rgba(0,0,0,0.3);
    border-radius: 20px;
    padding: 16px 20px;
    margin-bottom: 24px;
    display: flex;
    flex-wrap: wrap;
    gap: 16px;
    font-size: 14px;
    color: #cbd5e1;
}
.project-summary-item {
    display: flex;
    align-items: baseline;
    gap: 6px;
}
.project-summary-label {
    font-weight: 500;
    color: #94a3b8;
}
.project-summary-value {
    color: #e2e8f0;
}
.tabs {
    display: flex;
    gap: 8px;
    border-bottom: 1px solid rgba(255,255,255,0.1);
    margin-bottom: 24px;
    padding-bottom: 8px;
    flex-wrap: wrap;
}
.tab-btn {
    background: transparent;
    border: none;
    padding: 8px 20px;
    border-radius: 30px;
    color: #cbd5e1;
    cursor: pointer;
    transition: all 0.2s;
}
.tab-btn.active {
    background: rgba(56,189,248,0.2);
    color: #38bdf8;
    border: 1px solid #38bdf8;
}
.tab-content {
    display: none;
}
.tab-content.active {
    display: block;
}
.dimension-tabs {
    display: flex;
    gap: 12px;
    margin-bottom: 20px;
    border-bottom: 1px solid rgba(255,255,255,0.1);
    padding-bottom: 12px;
    flex-wrap: wrap;
}
.dimension-tab {
    background: transparent;
    border: none;
    color: #cbd5e1;
    cursor: pointer;
    padding: 8px 16px;
    border-radius: 24px;
    transition: all 0.2s;
}
.dimension-tab.active {
    background: rgba(56,189,248,0.2);
    color: #38bdf8;
    border: 1px solid #38bdf8;
}
.kanban-board {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
    overflow-x: auto;
    padding-bottom: 16px;
}
.kanban-column {
    background: rgba(18,28,40,0.6);
    border-radius: 20px;
    padding: 16px;
    backdrop-filter: blur(8px);
    min-width: 250px;
}
.column-header {
    font-weight: 600;
    font-size: 1rem;
    margin-bottom: 12px;
    padding-bottom: 8px;
    border-bottom: 1px solid rgba(255,255,255,0.1);
    display: flex;
    justify-content: space-between;
}
.task-card {
    background: rgba(0,0,0,0.3);
    border-radius: 16px;
    padding: 12px;
    margin-bottom: 12px;
    cursor: pointer;
    transition: background 0.2s;
}
.task-card:hover {
    background: rgba(56,189,248,0.15);
}
.task-name {
    font-weight: 500;
    margin-bottom: 6px;
    font-size: 13px;
}
.task-meta {
    font-size: 10px;
    color: #94a3b8;
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-top: 6px;
}
.empty-column {
    text-align: center;
    padding: 20px;
    color: #94a3b8;
    font-style: italic;
}
.section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 16px;
    flex-wrap: wrap;
    gap: 12px;
}
@media (max-width: 768px) {
    .kanban-board {
        grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    }
    .project-summary {
        flex-direction: column;
        gap: 8px;
    }
}