/* 侧边栏菜单样式 */
.menu-item {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 16px;
    cursor: pointer;
    color: #4b5563;
    font-size: 14px;
    transition: all 0.15s;
}
.menu-item:hover { background: #f3f4f6; color: #1d4ed8; }
.menu-item.active { background: #eff6ff; color: #1d4ed8; font-weight: 500; border-right: 3px solid #2563eb; }
.menu-item.sub { padding-left: 44px; }
.menu-group-title {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 16px;
    cursor: pointer;
    color: #4b5563;
    font-size: 14px;
    user-select: none;
}
.menu-group-title:hover { background: #f3f4f6; }
.menu-group-title .chevron { transition: transform 0.2s; }
.menu-group.collapsed .chevron { transform: rotate(-90deg); }
.menu-group.collapsed .menu-children { display: none; }

/* 页面容器 */
.page { display: none; padding: 24px; overflow-y: auto; height: 100%; }
.page.active { display: block; }

/* 统计卡片 */
.stat-card {
    background: white;
    border-radius: 12px;
    padding: 20px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.08);
    cursor: pointer;
    transition: all 0.2s;
}
.stat-card:hover { box-shadow: 0 4px 12px rgba(0,0,0,0.12); transform: translateY(-1px); }

/* 表格样式 */
.data-table { width: 100%; border-collapse: collapse; font-size: 14px; }
.data-table th { background: #f9fafb; padding: 12px; text-align: left; font-weight: 500; color: #6b7280; border-bottom: 1px solid #e5e7eb; }
.data-table td { padding: 12px; border-bottom: 1px solid #f3f4f6; color: #374151; }
.data-table tr:hover td { background: #f9fafb; }

/* 标签 */
.tag { display: inline-flex; align-items: center; padding: 2px 8px; border-radius: 4px; font-size: 12px; font-weight: 500; }
.tag-green { background: #dcfce7; color: #166534; }
.tag-red { background: #fee2e2; color: #991b1b; }
.tag-orange { background: #ffedd5; color: #9a3412; }
.tag-blue { background: #dbeafe; color: #1e40af; }
.tag-gray { background: #f3f4f6; color: #4b5563; }
.tag-purple { background: #f3e8ff; color: #6b21a8; }
.tag-indigo { background: #e0e7ff; color: #3730a3; }

/* 弹窗 */
.modal-overlay {
    position: fixed; inset: 0; background: rgba(0,0,0,0.5); z-index: 100;
    display: flex; align-items: center; justify-content: center;
    opacity: 0; pointer-events: none; transition: opacity 0.2s;
}
.modal-overlay.show { opacity: 1; pointer-events: auto; }
.modal {
    background: white; border-radius: 12px; padding: 24px;
    max-width: 600px; width: 90%; max-height: 80vh; overflow-y: auto;
    transform: scale(0.95); transition: transform 0.2s;
}
.modal-overlay.show .modal { transform: scale(1); }

/* 抽屉 */
.drawer-overlay {
    position: fixed; inset: 0; background: rgba(0,0,0,0.3); z-index: 100;
    opacity: 0; pointer-events: none; transition: opacity 0.2s;
}
.drawer-overlay.show { opacity: 1; pointer-events: auto; }
.drawer {
    position: fixed; top: 0; right: -480px; width: 480px; height: 100%;
    background: white; box-shadow: -4px 0 12px rgba(0,0,0,0.1);
    z-index: 101; transition: right 0.3s; overflow-y: auto; padding: 24px;
}
.drawer.show { right: 0; }

/* 开关组件 */
.toggle-switch { position: relative; display: inline-block; width: 36px; height: 20px; cursor: pointer; }
.toggle-switch input { opacity: 0; width: 0; height: 0; }
.toggle-slider { position: absolute; inset: 0; background: #d1d5db; border-radius: 20px; transition: 0.2s; }
.toggle-slider::before { content: ''; position: absolute; width: 16px; height: 16px; left: 2px; top: 2px; background: white; border-radius: 50%; transition: 0.2s; }
.toggle-switch input:checked + .toggle-slider { background: #22c55e; }
.toggle-switch input:checked + .toggle-slider::before { transform: translateX(16px); }

/* 通知面板 */
.notification-panel { position: absolute; top: 100%; right: 0; margin-top: 8px; width: 360px; background: white; border: 1px solid #e5e7eb; border-radius: 12px; box-shadow: 0 10px 40px rgba(0,0,0,0.12); z-index: 200; }
.notification-list { max-height: 380px; overflow-y: auto; }
.notification-item { padding: 12px 16px; border-bottom: 1px solid #f3f4f6; cursor: pointer; transition: background 0.1s; }
.notification-item:hover { background: #f9fafb; }
.notification-item.unread { background: #eff6ff; }
.notification-item.unread:hover { background: #dbeafe; }

/* 按钮 */
.btn { padding: 8px 16px; border-radius: 8px; font-size: 14px; font-weight: 500; cursor: pointer; transition: all 0.15s; border: none; }
.btn-primary { background: #2563eb; color: white; }
.btn-primary:hover { background: #1d4ed8; }
.btn-secondary { background: #f3f4f6; color: #374151; border: 1px solid #e5e7eb; }
.btn-secondary:hover { background: #e5e7eb; }
.btn-danger { background: #fee2e2; color: #dc2626; }
.btn-danger:hover { background: #fecaca; }

/* 表单 */
.form-label { display: block; font-size: 14px; font-weight: 500; color: #374151; margin-bottom: 4px; }
.form-input { width: 100%; padding: 8px 12px; border: 1px solid #d1d5db; border-radius: 8px; font-size: 14px; transition: all 0.15s; }
.form-input:focus { outline: none; border-color: #2563eb; box-shadow: 0 0 0 3px rgba(37,99,235,0.1); }
.form-select { width: 100%; padding: 8px 12px; border: 1px solid #d1d5db; border-radius: 8px; font-size: 14px; background: white; }

/* Tab */
.tab-bar { display: flex; border-bottom: 1px solid #e5e7eb; margin-bottom: 20px; }
.tab-item { padding: 10px 20px; font-size: 14px; color: #6b7280; cursor: pointer; border-bottom: 2px solid transparent; transition: all 0.15s; }
.tab-item:hover { color: #2563eb; }
.tab-item.active { color: #2563eb; border-bottom-color: #2563eb; font-weight: 500; }
.tab-content { display: none; }
.tab-content.active { display: block; }

/* 面包屑 */
.breadcrumb { font-size: 13px; color: #9ca3af; margin-bottom: 16px; }
.breadcrumb a { color: #6b7280; text-decoration: none; }
.breadcrumb a:hover { color: #2563eb; }

/* 分页器 */
.pagination { display: flex; align-items: center; justify-content: flex-end; gap: 4px; margin-top: 16px; }
.pagination button { padding: 6px 12px; border: 1px solid #e5e7eb; border-radius: 6px; font-size: 13px; cursor: pointer; background: white; }
.pagination button.active { background: #2563eb; color: white; border-color: #2563eb; }
.pagination button:hover:not(.active) { background: #f3f4f6; }

/* 开关 */
.toggle { position: relative; width: 44px; height: 24px; background: #d1d5db; border-radius: 12px; cursor: pointer; transition: background 0.2s; }
.toggle.on { background: #2563eb; }
.toggle::after { content: ''; position: absolute; top: 2px; left: 2px; width: 20px; height: 20px; background: white; border-radius: 50%; transition: transform 0.2s; }
.toggle.on::after { transform: translateX(20px); }

/* 卡片网格 */
.card-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); gap: 16px; }

/* 筛选区 */
.filter-bar { display: flex; flex-wrap: wrap; gap: 12px; align-items: flex-end; padding: 16px; background: white; border-radius: 12px; margin-bottom: 16px; box-shadow: 0 1px 3px rgba(0,0,0,0.08); }

/* 日历 */
.calendar-grid { display: grid; grid-template-columns: repeat(7, 1fr); gap: 2px; }
.calendar-cell { aspect-ratio: 1; display: flex; align-items: center; justify-content: center; font-size: 13px; border-radius: 6px; cursor: pointer; }
.calendar-cell:hover { background: #eff6ff; }
.calendar-cell.holiday { background: #fee2e2; color: #dc2626; }
.calendar-cell.company-holiday { background: #ffedd5; color: #9a3412; }
.calendar-cell.swap-day { background: #dbeafe; color: #1e40af; }
.calendar-cell.weekend { color: #9ca3af; }
.calendar-cell.today { border: 2px solid #2563eb; font-weight: 600; }

/* 进度条 */
.progress-bar { height: 6px; background: #e5e7eb; border-radius: 3px; overflow: hidden; }
.progress-bar-fill { height: 100%; background: #2563eb; border-radius: 3px; transition: width 0.3s; }

/* Toast */
.toast { position: fixed; top: 80px; right: 24px; padding: 12px 20px; background: #065f46; color: white; border-radius: 8px; font-size: 14px; z-index: 200; opacity: 0; transform: translateX(100%); transition: all 0.3s; }
.toast.show { opacity: 1; transform: translateX(0); }

