/* 全局样式 */ * { margin: 0; padding: 0; box-sizing: border-box; } body { font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif; background-color: #f5f5f5; } /* 应用容器 */ .app-container { display: flex; flex-direction: column; height: 100vh; } /* 头部样式 */ .app-header { display: flex; justify-content: space-between; align-items: center; padding: 0 20px; height: 60px; background-color: #fff; box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1); } .header-left { display: flex; align-items: center; } .logo { height: 40px; margin-right: 10px; } .header-right { display: flex; align-items: center; gap: 20px; } .logout-btn { padding: 8px 16px; background-color: #f44336; color: white; border: none; border-radius: 4px; cursor: pointer; } .logout-btn:hover { background-color: #d32f2f; } /* 主内容区域 */ .app-main { display: flex; flex: 1; overflow: hidden; } /* 侧边栏 */ .sidebar { width: 240px; background-color: #fff; border-right: 1px solid #e0e0e0; overflow-y: auto; } .menu-list { list-style: none; padding: 20px 0; } .menu-item { display: flex; align-items: center; padding: 12px 20px; cursor: pointer; transition: all 0.3s ease; border-left: 3px solid transparent; } .menu-item:hover { background-color: #f5f5f5; border-left-color: #3498db; } .menu-item.active { background-color: #e3f2fd; border-left-color: #2196f3; color: #1976d2; } .menu-item.active .menu-icon { filter: brightness(0.8); } .menu-icon { width: 24px; height: 24px; margin-right: 12px; } .submenu { list-style: none; padding-left: 20px; } /* 内容区域 */ .content-area { flex: 1; overflow: hidden; } .page-content { width: 100%; height: 100%; border: none; } /* 故障窗口样式 */ .modal { display: none; position: fixed; top: 0; left: 0; width: 100%; height: 100%; background-color: rgba(0, 0, 0, 0.5); z-index: 1000; } .modal-content { position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%); background-color: white; padding: 20px; border-radius: 5px; min-width: 300px; text-align: center; } .modal-content h2 { color: #e74c3c; margin-bottom: 15px; } .modal-content p { margin-bottom: 20px; color: #333; } .close-btn { background-color: #3498db; color: white; border: none; padding: 8px 20px; border-radius: 4px; cursor: pointer; font-size: 14px; } .close-btn:hover { background-color: #2980b9; }