/* =============================================================================
   DMS Workspace 企业级样式表 (V-Final Unified Edition)
   文件路径: public/dc/css/style.css
   
   结构说明：
   1. CSS Variables (全局变量)
   2. Base Styles (基础样式)
   3. Layout (布局)
   4. Sidebar (左侧边栏)
   5. Main Content (主内容区)
   6. File List (文件列表)
   7. Details Panel (右侧详情面板)
   8. Modals (模态框)
   9. Context Menu (右键菜单)
   10. Form Elements (表单元素)
   11. Utility Classes (工具类)
============================================================================= */

/* ==================== 1. CSS Variables ==================== */
:root {
    /* 主色调 */
    --primary: #0052cc;
    --primary-hover: #0065ff;
    --primary-light: #deebff;
    
    /* 背景色 */
    --bg-body: #fafbfc;
    --bg-card: #ffffff;
    
    /* 文字颜色 */
    --text-primary: #172b4d;
    --text-secondary: #5e6c84;
    --text-muted: #97a0af;
    
    /* 边框与阴影 */
    --border: #dfe1e6;
    --shadow-card: 0 1px 1px rgba(9,30,66,.25), 0 0 1px 0 rgba(9,30,66,.31);
    --shadow-hover: 0 4px 8px -2px rgba(9,30,66,.25), 0 0 1px rgba(9,30,66,.31);
    
    /* 状态色 */
    --success: #36b37e;
    --warning: #ff991f;
    --danger: #de350b;
    
    /* 圆角 */
    --radius: 3px;
}

/* ==================== 2. Base Styles ==================== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Oxygen", "Ubuntu", "Helvetica Neue", sans-serif;
    background-color: var(--bg-body);
    color: var(--text-primary);
    font-size: 14px;
    line-height: 1.5;
}

.page-workspace {
    overflow: hidden;
    height: 100vh;
}

/* ==================== 3. Layout ==================== */
.workspace-layout {
    display: grid;
    grid-template-columns: 260px 1fr;
    height: 100vh;
    transition: grid-template-columns 0.3s ease-in-out;
}

/* ==================== 4. Sidebar (左侧边栏) ==================== */
.workspace-sidebar {
    background-color: var(--bg-card);
    border-right: 1px solid var(--border);
    overflow-y: auto;
    display: flex;
    flex-direction: column;
}

.sidebar-header {
    padding: 20px;
    border-bottom: 1px solid var(--border);
}

.sidebar-header a {
    text-decoration: none;
    color: var(--text-primary);
    display: flex;
    align-items: center;
    gap: 10px;
    transition: color 0.2s;
}

.sidebar-header a:hover {
    color: var(--primary);
}

.sidebar-header h3 {
    margin: 0;
    font-size: 16px;
    font-weight: 600;
}

.sidebar-nav {
    padding: 15px 0;
}

.sidebar-nav .nav-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 20px;
    color: var(--text-secondary);
    text-decoration: none;
    transition: all 0.2s;
    cursor: pointer;
}

.sidebar-nav .nav-item:hover,
.sidebar-nav .nav-item.active {
    background-color: var(--primary-light);
    color: var(--primary);
}

.sidebar-section-title {
    padding: 10px 20px;
    font-size: 11px;
    font-weight: 600;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.folder-tree {
    padding: 0 20px 20px 20px;
}

.folder-tree ul {
    list-style: none;
    padding-left: 16px;
    margin: 0;
}

.folder-tree li {
    padding: 8px 0;
    cursor: pointer;
    color: var(--text-secondary);
    transition: color 0.2s;
    font-size: 13px;
}

.folder-tree li:hover {
    color: var(--primary);
}

.folder-tree li i {
    margin-right: 6px;
}

/* ==================== 5. Main Content (主内容区) ==================== */
.workspace-main {
    display: flex;
    flex-direction: column;
    background-color: var(--bg-card);
    overflow-y: auto;
}

.main-header {
    padding: 20px 24px;
    border-bottom: 1px solid var(--border);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.breadcrumb {
    display: flex;
    align-items: center;
    gap: 5px;
    font-size: 14px;
}

.breadcrumb a {
    color: var(--primary);
    text-decoration: none;
    transition: text-decoration 0.2s;
}

.breadcrumb a:hover {
    text-decoration: underline;
}

.main-actions {
    display: flex;
    gap: 10px;
}

/* ==================== 6. File List (文件列表) ==================== */
.file-list-container {
    padding: 0 24px 24px 24px;
    flex: 1;
    overflow-y: auto;
}

.file-table {
    width: 100%;
    border-collapse: collapse;
}

.file-table thead {
    position: sticky;
    top: 0;
    background-color: var(--bg-card);
    z-index: 10;
}

.file-table th {
    padding: 12px;
    text-align: left;
    font-weight: 600;
    font-size: 12px;
    color: var(--text-secondary);
    text-transform: uppercase;
    border-bottom: 2px solid var(--border);
}

.file-table tbody tr {
    border-bottom: 1px solid var(--border);
    cursor: pointer;
    transition: background-color 0.15s;
}

.file-table tbody tr:hover {
    background-color: #f4f5f7;
}

.file-table tbody tr.selected {
    background-color: var(--primary-light) !important;
}

.file-table td {
    padding: 12px;
    font-size: 14px;
}

.file-icon {
    margin-right: 8px;
    color: var(--primary);
}

.status-badge {
    padding: 4px 8px;
    border-radius: 3px;
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    display: inline-block;
}

.status-draft {
    background-color: #f4f5f7;
    color: var(--text-muted);
}

.status-pending-review {
    background-color: #e0f2fe;
    color: #0284c7;
    border: 1px solid #bae6fd;
}

.status-in-process {
    background-color: #fff4e6;
    color: var(--warning);
}

.status-released {
    background-color: #e3fcef;
    color: var(--success);
}

.status-invalid {
    background-color: #ffebe6;
    color: var(--danger);
}

.badge-new {
    background-color: var(--success);
    color: white;
    font-size: 9px;
    padding: 2px 5px;
    border-radius: 3px;
    margin-left: 5px;
    vertical-align: middle;
    text-transform: uppercase;
    font-weight: 700;
}

.row-actions {
    text-align: center;
    color: var(--text-secondary);
}

.empty-folder-state,
.error-state,
.loading-state {
    text-align: center;
    padding: 60px 20px;
    color: var(--text-secondary);
}

/* ==================== 7. Details Panel (右侧详情面板) ==================== */
.workspace-details-panel {
    display: none;
    background-color: #f4f5f7;
    border-left: 1px solid var(--border);
    flex-direction: column;
    overflow-y: auto;
}

.panel-header {
    padding: 20px;
    background-color: var(--bg-card);
    border-bottom: 1px solid var(--border);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.panel-header h4 {
    margin: 0;
    font-size: 16px;
    font-weight: 600;
}

.close-panel {
    border: none;
    background: none;
    font-size: 20px;
    cursor: pointer;
    color: var(--text-secondary);
    transition: color 0.2s;
}

.close-panel:hover {
    color: var(--text-primary);
}

.panel-body {
    padding: 20px;
    flex: 1;
}

.details-tabs {
    display: flex;
    gap: 10px;
    margin-bottom: 20px;
    border-bottom: 1px solid var(--border);
}

.tab-button {
    padding: 10px 16px;
    border: none;
    background: none;
    cursor: pointer;
    border-bottom: 2px solid transparent;
    font-size: 14px;
    color: var(--text-secondary);
    transition: all 0.2s;
}

.tab-button:hover {
    color: var(--primary);
}

.tab-button.active {
    color: var(--primary);
    border-bottom-color: var(--primary);
}

.tab-content {
    display: none;
}

.tab-content.active {
    display: block;
}

/* 审批流程样式 */
.approval-flow {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.flow-item {
    display: flex;
    align-items: flex-start;
    gap: 16px;
    padding: 16px;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    transition: box-shadow 0.2s;
}

.flow-item:hover {
    box-shadow: var(--shadow-card);
}

.node-icon {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    flex-shrink: 0;
}

.node-icon.pending {
    background-color: #fff4e6;
    color: var(--warning);
}

.node-icon.completed {
    background-color: #e3fcef;
    color: var(--success);
}

.node-icon.rejected {
    background-color: #ffebe6;
    color: var(--danger);
}

.flow-info {
    flex-grow: 1;
}

.flow-info p {
    margin: 0 0 4px 0;
    font-size: 14px;
    color: var(--text-primary);
}

.flow-info small {
    font-size: 12px;
    color: var(--text-secondary);
}

.flow-comment {
    margin-top: 8px;
    padding: 10px 12px;
    background-color: #f4f5f7;
    border-left: 3px solid var(--border);
    font-size: 13px;
    color: var(--text-secondary);
    border-radius: 0 var(--radius) var(--radius) 0;
    line-height: 1.5;
}

.flow-item-actions {
    margin-top: 12px;
    display: flex;
    gap: 10px;
}

/* 审批历史手风琴 */
.workflow-history-item {
    background-color: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    margin-bottom: 12px;
    transition: all 0.2s;
}

.workflow-history-item[open] {
    box-shadow: var(--shadow-card);
    border-color: var(--primary);
}

.workflow-history-header {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    cursor: pointer;
    font-size: 14px;
    font-weight: 500;
    list-style: none;
}

.workflow-history-header::-webkit-details-marker {
    display: none;
}

.workflow-history-header::before {
    content: '\f054';
    font-family: 'Font Awesome 6 Free';
    font-weight: 900;
    transition: transform 0.2s;
    font-size: 10px;
    color: var(--text-secondary);
}

.workflow-history-item[open] > .workflow-history-header::before {
    transform: rotate(90deg);
}

.workflow-history-header .workflow-title {
    flex-grow: 1;
    color: var(--text-primary);
}

.workflow-history-header .workflow-date {
    font-size: 12px;
    color: var(--text-secondary);
}

.workflow-status-badge {
    padding: 3px 8px;
    border-radius: 12px;
    font-size: 10px;
    font-weight: 600;
    color: white;
}

.workflow-status-badge.status-in-process {
    background-color: var(--warning);
}

.workflow-status-badge.status-completed,
.workflow-status-badge.status-released {
    background-color: var(--success);
}

.workflow-status-badge.status-rejected {
    background-color: var(--danger);
}

.workflow-history-body {
    padding: 16px;
    border-top: 1px solid var(--border);
}

/* 版本历史 */
.versions-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.version-item {
    padding: 12px;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
}

.version-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 8px;
}

.version-tag {
    display: inline-block;
    padding: 4px 10px;
    background: var(--primary);
    color: white;
    font-size: 11px;
    font-weight: 600;
    border-radius: var(--radius);
}

.version-date {
    font-size: 12px;
    color: var(--text-secondary);
}

.version-uploader {
    font-size: 13px;
    color: var(--text-secondary);
    margin: 4px 0;
}

.version-log {
    margin-top: 8px;
    padding: 8px 10px;
    background: #f4f5f7;
    border-left: 3px solid var(--primary);
    font-size: 13px;
    color: var(--text-primary);
    border-radius: 0 var(--radius) var(--radius) 0;
}

/* 文件信息 */
.file-info-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 16px;
}

.info-item {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.info-item label {
    font-size: 11px;
    font-weight: 600;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.info-item span {
    font-size: 14px;
    color: var(--text-primary);
}

.empty-state {
    text-align: center;
    padding: 40px 20px;
    color: var(--text-muted);
    font-size: 13px;
}

/* ==================== 8. Modals (模态框) ==================== */
.modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 9999;
    display: none;
    justify-content: center;
    align-items: center;
    background-color: rgba(17, 24, 39, 0.6);
    backdrop-filter: blur(4px);
    opacity: 0;
    transition: opacity 0.2s;
}

.modal[style*="flex"] {
    opacity: 1;
}

.modal-content {
    background-color: var(--bg-card);
    border-radius: 8px;
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1);
    width: 90%;
    max-width: 500px;
    overflow: hidden;
    transform: scale(0.95);
    transition: transform 0.2s;
}

.modal[style*="flex"] .modal-content {
    transform: scale(1);
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 24px;
    border-bottom: 1px solid var(--border);
}

.modal-header h3 {
    margin: 0;
    font-size: 16px;
    font-weight: 600;
}

.close-modal {
    border: none;
    background: none;
    font-size: 24px;
    line-height: 1;
    color: var(--text-secondary);
    cursor: pointer;
    transition: color 0.2s;
}

.close-modal:hover {
    color: var(--text-primary);
}

.modal-body {
    padding: 24px;
}

.modal-actions {
    display: flex;
    justify-content: flex-end;
    gap: 12px;
    padding: 16px 24px;
    background-color: #f9fafb;
    border-top: 1px solid var(--border);
}

/* ==================== 9. Context Menu (右键菜单) ==================== */
.context-menu {
    position: fixed !important;
    z-index: 10000 !important;
    display: none;
    background-color: var(--bg-card) !important;
    border: 1px solid var(--border) !important;
    border-radius: var(--radius) !important;
    box-shadow: var(--shadow-hover) !important;
    padding: 8px 0 !important;
    min-width: 200px !important;
    animation: fadeIn 0.1s ease-out !important;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: scale(0.95);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

.context-menu ul {
    list-style: none !important;
    margin: 0 !important;
    padding: 0 !important;
}

.context-menu li {
    padding: 10px 16px !important;
    display: flex;
    align-items: center !important;
    gap: 12px !important;
    cursor: pointer !important;
    font-size: 13px !important;
    color: var(--text-primary) !important;
    transition: all 0.15s !important;
}

.context-menu li:hover {
    background-color: var(--primary-light) !important;
    color: var(--primary) !important;
}

.context-menu li i {
    width: 18px !important;
    text-align: center !important;
    color: var(--text-secondary) !important;
}

.context-menu li:hover i {
    color: var(--primary) !important;
}

.context-menu li.danger {
    color: var(--danger) !important;
}

.context-menu li.danger:hover {
    background-color: #ffebe6 !important;
    color: #b91c1c !important;
}

.context-menu li.danger:hover i {
    color: #b91c1c !important;
}

.context-menu hr {
    margin: 6px 0 !important;
    border: none !important;
    border-top: 1px solid var(--border) !important;
}

/* ==================== 10. Form Elements (表单元素) ==================== */
.form-group {
    margin-bottom: 16px;
}

.form-group label {
    display: block;
    font-size: 13px;
    font-weight: 500;
    color: var(--text-primary);
    margin-bottom: 6px;
}

.form-group label span {
    color: var(--danger);
    font-weight: 600;
}

.form-group select,
.form-group .form-control,
.form-group textarea {
    width: 100%;
    padding: 10px 12px;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    font-size: 14px;
    color: var(--text-primary);
    background-color: var(--bg-card);
    transition: all 0.2s;
}

.form-group select:focus,
.form-group .form-control:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px var(--primary-light);
}

.form-group textarea {
    resize: vertical;
    min-height: 80px;
}

/* Upload Zone */
#drop-zone,
#update-drop-zone {
    border: 2px dashed var(--border);
    border-radius: var(--radius);
    padding: 40px 20px;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s;
    background-color: #fafafa;
}

#drop-zone:hover,
#update-drop-zone:hover {
    border-color: var(--primary);
    background-color: var(--primary-light);
}

#drop-zone i,
#update-drop-zone i {
    font-size: 48px;
    color: var(--text-muted);
    display: block;
    margin-bottom: 16px;
}

#drop-zone p {
    font-size: 14px;
    color: var(--text-secondary);
    margin: 0;
}

#drop-zone p span {
    color: var(--primary);
    font-weight: 500;
    text-decoration: underline;
}

#file-preview-list {
    list-style: none;
    padding: 0;
    margin: 16px 0 0 0;
}

/* 文件夹树 (移动文件用) */
.folder-tree-move-container ul {
    list-style: none;
    padding-left: 20px;
}

.folder-tree-move-container li {
    padding: 2px 0;
}

.folder-tree-move-container .folder-item {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 12px;
    border-radius: var(--radius);
    cursor: pointer;
    font-size: 13px;
    transition: background-color 0.15s;
}

.folder-tree-move-container .folder-item:hover {
    background-color: #f4f5f7;
}

.folder-tree-move-container .folder-item.selected {
    background-color: var(--primary-light);
    color: var(--primary);
    font-weight: 600;
}

/* ==================== 11. Utility Classes (工具类 & 按钮) ==================== */
.btn {
    padding: 8px 16px;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    background: var(--bg-card);
    cursor: pointer;
    font-size: 14px;
    font-weight: 500;
    transition: all 0.2s;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.btn:hover {
    background-color: var(--bg-body);
}

.btn-primary {
    background-color: var(--primary);
    color: white;
    border-color: var(--primary);
}

.btn-primary:hover {
    background-color: var(--primary-hover);
}

.btn-success {
    background-color: var(--success);
    color: white;
    border: none;
}

.btn-success:hover {
    background-color: #2d9a6e;
}

.btn-danger {
    background-color: var(--danger);
    color: white;
    border: none;
}

.btn-danger:hover {
    background-color: #c52b0b;
}

.btn-sm {
    padding: 6px 12px;
    font-size: 13px;
}

.btn-default {
    background: white;
    border: 1px solid var(--border);
    color: var(--text-primary);
}

.btn-default:hover {
    background: #f4f5f7;
}


.trash-preview-list {
    list-style: none;
    padding: 10px;
    margin: 0;
}

.trash-preview-list li {
    display: flex;
    align-items: center;
    padding: 8px 12px;
    border-radius: 4px;
    font-size: 14px;
    color: var(--text-primary);
}

.trash-preview-list li:hover {
    background-color: var(--background-hover);
}

.trash-preview-list li .file-icon {
    margin-right: 12px;
    color: var(--text-secondary);
}

#details-panel .panel-header h4 {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 4px;
    line-height: 1.4;
}

.preview-title {
    font-size: 16px;
    font-weight: 600;
}

.preview-breadcrumb {
    font-size: 12px;
    color: var(--text-secondary);
    font-weight: 400;
}

.preview-breadcrumb a {
    color: var(--primary-color);
    text-decoration: none;
}

.preview-breadcrumb a:hover {
    text-decoration: underline;
}

/* 预览列表中的文件夹项 */
.trash-preview-list .preview-folder-item:hover {
    background-color: var(--background-hover);
}

.approver-name {
    display: inline-block;
    padding: 2px 6px;
    border-radius: 4px;
    margin: 0 2px;
}
.approver-name.approved {
    background-color: #dcfce7; /* 浅绿色背景 */
    color: #166534; /* 深绿色文字 */
}
.approver-name.approved .fa-check-circle {
    color: #22c55e; /* 绿色图标 */
}

.approvers-container {
    margin-top: 8px;
    display: flex;
    flex-direction: column;
    gap: 8px; /* 每个审批人之间的间距 */
}

.approver-item {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
}

.approver-badge {
    padding: 3px 10px;
    border-radius: 14px;
    font-size: 13px;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    border: 1px solid transparent;
}

.approver-badge.approved {
    color: #059669; background: #ecfdf5; border-color: #a7f3d0;
}
.approver-badge.rejected {
    color: #b91c1c; background: #fef2f2; border-color: #fecaca;
}
.approver-badge.pending {
    color: #4b5563; background: #f3f4f6; border-color: #e5e7eb;
}

.approver-comment {
    margin: 4px 0 0 16px; /* 左侧缩进，看起来像子项 */
    padding: 6px 10px;
    background-color: #f9fafb;
    border-left: 3px solid #d1d5db;
    font-size: 12px;
    color: #374151;
    width: calc(100% - 16px);
    border-radius: 0 4px 4px 0;
}

/* public/dc/css/workspace.css */

.approver-item {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    padding: 6px 0;
    border-bottom: 1px solid #f3f4f6;
}

.approver-item:last-child {
    border-bottom: none;
}

.approver-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
}

.approver-timestamp {
    font-size: 11px;
    color: #9ca3af;
    margin-left: auto;
}

.approver-badge {
    padding: 3px 10px;
    border-radius: 14px;
    font-size: 13px;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    border: 1px solid transparent;
}

.approver-badge.approved {
    color: #059669; 
    background: #ecfdf5; 
    border-color: #a7f3d0;
}

.approver-badge.rejected {
    color: #b91c1c; 
    background: #fef2f2; 
    border-color: #fecaca;
}

.approver-badge.pending {
    color: #4b5563; 
    background: #f3f4f6; 
    border-color: #e5e7eb;
}

.approver-comment {
    margin: 4px 0 0 0;
    padding: 6px 10px;
    background-color: #f9fafb;
    border-left: 3px solid #d1d5db;
    font-size: 12px;
    color: #374151;
    width: 100%;
    border-radius: 0 4px 4px 0;
}

.old-version-tag {
    display: inline-block;
    padding: 2px 8px;
    margin-left: 8px;
    background: #f3f4f6;
    color: #6b7280;
    font-size: 11px;
    border-radius: 10px;
    font-weight: normal;
}

/* 版本历史Tab下的样式 */
.versions-list .version-item {
    display: flex;
    align-items: flex-start;
    gap: 10px;
}
.versions-list .version-checkbox-area {
    padding-top: 8px;
}
.versions-list .version-details {
    flex-grow: 1;
}
.versions-list .version-compare-checkbox {
    cursor: pointer;
}
#version-compare-action {
    text-align: center;
}


/* ==================== 精致按钮样式 ==================== */

/* 1. 小型图标按钮（用于"追加"、"催办"等） */
.btn-icon-compact {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 4px 10px;
    font-size: 12px;
    border: 1px solid #d1d5db;
    background: white;
    color: #374151;
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.btn-icon-compact:hover {
    background: #f3f4f6;
    border-color: #9ca3af;
    transform: translateY(-1px);
}

.btn-icon-compact i {
    font-size: 11px;
}

.btn-icon-compact span {
    font-weight: 500;
}

/* 催办按钮（橙色变体） */
.btn-warning-compact {
    background: #fef3c7;
    border-color: #fbbf24;
    color: #92400e;
}

.btn-warning-compact:hover {
    background: #fde68a;
    border-color: #f59e0b;
}

/* 2. 操作按钮（批准/驳回） */
.btn-action-approve {
    padding: 6px 16px;
    font-size: 13px;
    font-weight: 500;
    border: none;
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
    color: white;
    border-radius: 5px;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 2px 4px rgba(16, 185, 129, 0.2);
}

.btn-action-approve:hover {
    background: linear-gradient(135deg, #059669 0%, #047857 100%);
    box-shadow: 0 4px 8px rgba(16, 185, 129, 0.3);
    transform: translateY(-2px);
}

.btn-action-reject {
    padding: 6px 16px;
    font-size: 13px;
    font-weight: 500;
    border: 1px solid #fca5a5;
    background: white;
    color: #dc2626;
    border-radius: 5px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.btn-action-reject:hover {
    background: #fef2f2;
    border-color: #f87171;
    transform: translateY(-2px);
}

/* 3. 文件信息页的操作按钮 */
.btn-action-primary, .btn-action-success, 
.btn-action-default, .btn-action-secondary {
    padding: 6px 14px;
    font-size: 12px;
    font-weight: 500;
    border-radius: 5px;
    cursor: pointer;
    transition: all 0.2s ease;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    border: none;
}

.btn-action-primary {
    background: #3b82f6;
    color: white;
}

.btn-action-primary:hover {
    background: #2563eb;
    box-shadow: 0 3px 8px rgba(59, 130, 246, 0.3);
}

.btn-action-success {
    background: #10b981;
    color: white;
}

.btn-action-success:hover {
    background: #059669;
    box-shadow: 0 3px 8px rgba(16, 185, 129, 0.3);
}

.btn-action-default {
    background: #6b7280;
    color: white;
}

.btn-action-default:hover {
    background: #4b5563;
    box-shadow: 0 3px 8px rgba(107, 114, 128, 0.3);
}

.btn-action-secondary {
    background: #8b5cf6;
    color: white;
}

.btn-action-secondary:hover {
    background: #7c3aed;
    box-shadow: 0 3px 8px rgba(139, 92, 246, 0.3);
}

/* 统一的按钮图标样式 */
.btn-action-primary i, .btn-action-success i,
.btn-action-default i, .btn-action-secondary i {
    font-size: 11px;
}

/* 选择模式下的样式调整 */
body.mode-picker {
        background-color: #fff !important;
        padding: 0 !important;
        overflow: hidden !important; /* 防止双滚动条 */
    }

    /* 1. 隐藏左侧侧边栏 (类名修正为 workspace-sidebar) */
    body.mode-picker .workspace-sidebar {
        display: none !important;
    }

    /* 2. 调整主内容区域宽度 (类名修正为 workspace-main) */
    body.mode-picker .workspace-main {
        margin-left: 0 !important;
        width: 100vw !important;
        height: 100vh !important;
        padding: 0 !important;
        display: flex;
        flex-direction: column;
    }

    /* 3. 隐藏顶部操作按钮 (上传、新建文件夹) */
    body.mode-picker .main-actions,
    body.mode-picker #upload-btn,
    body.mode-picker #new-folder-btn {
        display: none !important;
    }

    /* 4. 隐藏批量操作工具栏 */
    body.mode-picker #batch-actions-toolbar {
        display: none !important;
    }

    /* 5. 隐藏文件列表里的复选框 */
    body.mode-picker .file-item-checkbox,
    body.mode-picker #select-all-checkbox {
        display: none !important;
    }

    /* 6. 隐藏右侧详情面板 (类名修正为 workspace-details-panel) */
    body.mode-picker .workspace-details-panel {
        display: none !important;
    }

    /* 7. 调整面包屑导航栏样式 */
    body.mode-picker .main-header {
        padding: 10px 20px !important;
        border-bottom: 1px solid #eee;
        flex-shrink: 0; /* 防止被压缩 */
    }
    
    /* 8. 让文件列表占满剩余空间 */
    body.mode-picker .file-list-container {
        flex: 1;
        overflow-y: auto;
        padding: 0 20px;
    }