/* ========== 全局样式 ========== */ * { box-sizing: border-box; margin: 0; padding: 0; } body { font-family: -apple-system, "PingFang SC", "Microsoft YaHei", sans-serif; background: #0f1923; color: #e8eaed; font-size: 14px; min-height: 100vh; } a { color: #4fc3f7; text-decoration: none; } a:hover { text-decoration: underline; } .container { max-width: 1200px; margin: 0 auto; padding: 20px 16px; display: grid; grid-template-columns: 1fr 1fr; gap: 16px; } /* ========== 顶部栏 ========== */ .topbar { background: #1a2332; border-bottom: 1px solid #2a3441; padding: 0 20px; display: flex; align-items: center; height: 56px; gap: 32px; position: sticky; top: 0; z-index: 100; } .logo { font-size: 18px; font-weight: bold; color: #4fc3f7; } .nav { display: flex; gap: 4px; } .nav-link { padding: 8px 16px; border-radius: 6px; color: #9aa0a6; transition: all 0.2s; } .nav-link:hover { background: #2a3441; color: #e8eaed; text-decoration: none; } .nav-link.active { background: #263238; color: #4fc3f7; } .status-bar { margin-left: auto; display: flex; gap: 12px; } .status-item { padding: 4px 12px; border-radius: 12px; font-size: 12px; font-weight: bold; } .status-item.setting { background: #1b3a2f; color: #4caf50; } .status-item.running { background: #2a2a1b; color: #ffeb3b; } .status-item.paused { background: #3a2a1a; color: #ff9800; } .status-item.idle { background: #2a2a2a; color: #9aa0a6; } /* ========== 卡片 ========== */ .card { background: #1a2332; border-radius: 12px; padding: 20px; border: 1px solid #2a3441; } .card h2 { font-size: 16px; margin-bottom: 16px; color: #4fc3f7; } /* ========== 状态卡片 ========== */ .grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; margin-bottom: 16px; } .status-card { background: #0f1923; border-radius: 8px; padding: 16px; text-align: center; border: 1px solid #2a3441; } .status-card.ok { border-color: #2e7d32; background: #0d1f14; } .status-card.error { border-color: #c62828; background: #1f0d0d; } .status-icon { font-size: 24px; margin-bottom: 8px; } .status-label { font-size: 12px; color: #9aa0a6; margin-bottom: 4px; } .status-value { font-size: 14px; font-weight: bold; } /* ========== 按钮 ========== */ .btn { padding: 8px 16px; border-radius: 6px; border: none; cursor: pointer; font-size: 14px; transition: all 0.2s; background: #263238; color: #e8eaed; font-family: inherit; } .btn:hover:not(:disabled) { background: #37474f; } .btn:disabled { opacity: 0.5; cursor: not-allowed; } .btn-primary { background: #0277bd; color: #fff; } .btn-primary:hover:not(:disabled) { background: #0288d1; } .btn-secondary { background: #37474f; } .btn-danger { background: #d32f2f; color: #fff; } .btn-danger:hover:not(:disabled) { background: #f44336; } .btn-success { background: #2e7d32; color: #fff; } .btn-success:hover:not(:disabled) { background: #388e3c; } .btn-warning { background: #e65100; color: #fff; } .btn-error { background: #c62828; color: #fff; } .btn-large { padding: 12px 24px; font-size: 16px; } .btn-small { padding: 4px 10px; font-size: 12px; } .btn-icon { background: none; border: none; cursor: pointer; font-size: 14px; padding: 4px; } .btn-row { display: flex; gap: 8px; margin-top: 12px; flex-wrap: wrap; } /* ========== 表单 ========== */ .form-group { margin-bottom: 12px; } .form-group label { display: block; font-size: 12px; color: #9aa0a6; margin-bottom: 4px; } .form-group input, .form-group select { width: 100%; padding: 8px 12px; background: #0f1923; border: 1px solid #2a3441; border-radius: 6px; color: #e8eaed; font-size: 14px; font-family: inherit; } .form-group input:focus, .form-group select:focus { outline: none; border-color: #4fc3f7; } .form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; } /* ========== Tabs ========== */ .tabs { background: #1a2332; border-bottom: 1px solid #2a3441; padding: 0 20px; display: flex; gap: 4px; } .tab { padding: 12px 20px; background: none; border: none; color: #9aa0a6; cursor: pointer; font-size: 14px; border-bottom: 2px solid transparent; font-family: inherit; } .tab.active { color: #4fc3f7; border-bottom-color: #4fc3f7; } .tab:hover { color: #e8eaed; } /* ========== 摄像头预览 ========== */ .camera-preview { width: 100%; max-width: 480px; border-radius: 8px; overflow: hidden; margin: 0 auto 16px; background: #000; } .camera-preview img, .camera-full img { width: 100%; display: block; aspect-ratio: 16/9; object-fit: cover; } .camera-full { width: 100%; border-radius: 8px; overflow: hidden; background: #000; } /* ========== 关节控制 ========== */ .joints-panel { margin-top: 16px; } .joints-panel h3 { margin-bottom: 12px; font-size: 14px; } .joint-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; } .joint-control { background: #0f1923; border-radius: 8px; padding: 12px; text-align: center; border: 1px solid #2a3441; } .joint-control label { font-size: 12px; color: #4fc3f7; font-weight: bold; } .joint-value { font-size: 18px; font-weight: bold; color: #fff; margin: 4px 0; } .joint-buttons { display: flex; align-items: center; gap: 4px; justify-content: center; } .joint-buttons button { width: 32px; height: 32px; border-radius: 4px; border: 1px solid #2a3441; background: #263238; color: #e8eaed; cursor: pointer; font-size: 14px; } .joint-buttons input { width: 60px; padding: 4px; text-align: center; background: #0f1923; border: 1px solid #2a3441; border-radius: 4px; color: #e8eaed; font-size: 12px; } /* ========== 点位列表 ========== */ .point-item { background: #0f1923; border: 1px solid #2a3441; border-radius: 8px; padding: 12px; margin-bottom: 12px; } .point-header { display: flex; align-items: center; gap: 8px; margin-bottom: 8px; } .point-name { font-weight: bold; font-size: 15px; } .point-coords { font-size: 12px; color: #9aa0a6; margin-bottom: 8px; } .badge { padding: 2px 8px; border-radius: 10px; font-size: 11px; background: #263238; color: #4fc3f7; } .pose-list { margin-top: 8px; } .pose-item { display: flex; align-items: center; gap: 8px; padding: 6px 0; border-bottom: 1px solid #2a3441; font-size: 13px; } .angles { color: #9aa0a6; font-size: 11px; font-family: monospace; } .pose-add { display: flex; gap: 8px; align-items: center; margin-top: 8px; } .pose-add input { flex: 1; padding: 6px 10px; background: #1a2332; border: 1px solid #2a3441; border-radius: 4px; color: #e8eaed; font-size: 13px; } .pose-add select { padding: 6px; background: #1a2332; border: 1px solid #2a3441; border-radius: 4px; color: #e8eaed; } .empty-hint { color: #9aa0a6; text-align: center; padding: 20px; } .hint { font-size: 12px; color: #9aa0a6; margin-top: 8px; } .alert { padding: 12px 16px; border-radius: 8px; margin-bottom: 12px; } .alert-error { background: #1f0d0d; border: 1px solid #c62828; color: #ef5350; } .checkbox-group { display: flex; gap: 16px; } .checkbox-group label { display: flex; align-items: center; gap: 6px; cursor: pointer; color: #e8eaed; } /* ========== 运行页面 ========== */ .running-header { display: flex; align-items: center; gap: 20px; margin-bottom: 16px; } .running-status { font-size: 18px; font-weight: bold; display: flex; align-items: center; gap: 8px; } .running-status.idle { color: #9aa0a6; } .running-status.running { color: #4caf50; } .running-status.paused { color: #ff9800; } .pulse { width: 10px; height: 10px; border-radius: 50%; background: currentColor; animation: pulse 1.5s infinite; } @keyframes pulse { 0%, 100% { opacity: 1; transform: scale(1); } 50% { opacity: 0.5; transform: scale(0.8); } } .running-progress { flex: 1; display: flex; align-items: center; gap: 12px; } .progress-bar { flex: 1; height: 8px; background: #2a3441; border-radius: 4px; overflow: hidden; } .progress-fill { height: 100%; background: #4fc3f7; border-radius: 4px; transition: width 0.3s; } /* ========== 报告 ========== */ .report-summary { display: flex; gap: 16px; margin-bottom: 16px; } .stat { padding: 8px 16px; border-radius: 8px; background: #0f1923; border: 1px solid #2a3441; } .stat.ok { border-color: #2e7d32; color: #4caf50; } .stat.error { border-color: #c62828; color: #ef5350; } .report-item { padding: 8px 12px; background: #0f1923; border-radius: 6px; margin-bottom: 8px; border: 1px solid #2a3441; } .report-point { display: flex; align-items: center; gap: 8px; font-weight: bold; } .report-status { font-size: 16px; } .report-pose { font-size: 12px; color: #9aa0a6; padding-left: 24px; margin-top: 4px; } /* ========== 响应式 ========== */ @media (max-width: 768px) { .container { grid-template-columns: 1fr; } .grid-3 { grid-template-columns: 1fr; } .form-row { grid-template-columns: 1fr; } .joint-grid { grid-template-columns: repeat(2, 1fr); } .form-row { grid-template-columns: 1fr; } } /* AGV 移动控制面板 */ .agv-status-bar { display: flex; gap: 16px; align-items: center; padding: 10px 14px; background: #0f1923; border-radius: 8px; margin-bottom: 16px; font-size: 13px; color: #9aa0a6; flex-wrap: wrap; } .agv-status-bar strong { color: #e8eaed; } .agv-control-panel { display: flex; flex-direction: column; align-items: center; gap: 6px; max-width: 280px; margin: 0 auto; } .agv-dir-row { display: grid; grid-template-columns: 80px 80px 80px; gap: 6px; width: 100%; } .agv-dir-placeholder { width: 80px; height: 44px; } .agv-btn { height: 44px; border-radius: 8px; border: 1px solid #2a3441; background: #263238; color: #e8eaed; cursor: pointer; font-size: 13px; font-family: inherit; transition: background 0.15s; display: flex; align-items: center; justify-content: center; gap: 4px; user-select: none; } .agv-btn:active, .agv-btn:focus { outline: none; } .agv-btn-up { background: #1b3a2f; border-color: #2e7d32; color: #4caf50; } .agv-btn-down { background: #3a1b1b; border-color: #7d2e2e; color: #f44336; } .agv-btn-left { background: #1b2d3a; border-color: #1565c0; color: #42a5f5; } .agv-btn-right { background: #2d2a1b; border-color: #7d6e2e; color: #ffc107; } .agv-btn-stop { background: #37474f; border-color: #546e7a; } .agv-btn-up:active { background: #1e4d38; } .agv-btn-down:active { background: #4d2020; } .agv-btn-left:active { background: #1e3a4d; } .agv-btn-right:active { background: #3d3820; } .agv-btn-stop:active { background: #455a64; } .agv-btn-lateral { background: #2d1b4a; border-color: #7c4dff; color: #b388ff; font-size: 13px; min-width: 120px; } .agv-btn-lateral:active { background: #3d2560; } .agv-lateral-row { display: flex; gap: 12px; justify-content: center; margin-top: 8px; max-width: 280px; width: 100%; } .speed-control { display: flex; align-items: center; gap: 10px; } .speed-value { min-width: 44px; text-align: right; font-weight: bold; color: #4fc3f7; } /* 双摄像头预览布局 */ .camera-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin-top: 12px; } .camera-box { background: #111; border-radius: 8px; overflow: hidden; } .camera-label { padding: 8px 12px; font-size: 13px; color: #aaa; background: #1a1a1a; border-bottom: 1px solid #333; } .camera-img { width: 100%; display: block; aspect-ratio: 4/3; object-fit: cover; } .camera-placeholder { width: 100%; aspect-ratio: 4/3; display: flex; align-items: center; justify-content: center; color: #666; font-size: 14px; } /* ========== 地图标记 ========== */ .map-marker { position: absolute; transform: translate(-50%, -100%); font-size: 20px; cursor: pointer; filter: drop-shadow(0 2px 4px rgba(0,0,0,0.5)); z-index: 10; } .map-marker:hover { transform: translate(-50%, -100%) scale(1.2); } /* ========== 任务配置 M×N 网格 ========== */ .mission-grid-wrap { margin-top: 12px; overflow-x: auto; } .mission-grid { display: grid; gap: 4px; grid-template-columns: 80px repeat(var(--cols,4), 90px); } .grid-cell { min-width: 80px; min-height: 48px; display: flex; align-items: center; justify-content: center; border-radius: 6px; font-size: 12px; cursor: pointer; border: 1px solid #2a3441; background: #0f1923; transition: background 0.15s, border-color 0.15s; } .grid-cell.active { background: #1b3a2f; border-color: #2e7d32; color: #4caf50; } .grid-cell.active:hover { background: #234; } .grid-cell.selected { border-color: #4fc3f7 !important; box-shadow: 0 0 0 2px #4fc3f7; } .grid-header { background: transparent; border-color: transparent; cursor: default; font-weight: bold; color: #9aa0a6; font-size: 12px; } /* 机器配置表单 */ .machine-form { background: #0f1923; border: 1px solid #2a3441; border-radius: 8px; padding: 16px; margin-top: 12px; } .machine-form h3 { font-size: 14px; color: #4fc3f7; margin-bottom: 10px; } .machine-form h4 { font-size: 13px; color: #9aa0a6; margin: 8px 0 6px; } /* 姿态列表 */ .pose-list { margin-top: 8px; } .pose-item { display: flex; align-items: center; gap: 8px; padding: 6px 0; border-bottom: 1px solid #2a3441; font-size: 13px; } .pose-name { font-weight: bold; min-width: 80px; } .pose-angles { color: #9aa0a6; font-size: 11px; font-family: monospace; flex: 1; } .pose-add { display: flex; gap: 8px; align-items: center; margin-top: 8px; } .pose-add input { flex: 1; padding: 6px 10px; background: #1a2332; border: 1px solid #2a3441; border-radius: 4px; color: #e8eaed; font-size: 13px; } /* 蛇形序列预览 */ .sequence-preview { display: flex; flex-direction: column; gap: 4px; max-height: 320px; overflow-y: auto; } .sequence-step { display: flex; align-items: center; gap: 10px; padding: 6px 12px; background: #0f1923; border-radius: 6px; border: 1px solid #2a3441; font-size: 13px; } .step-index { background: #263238; color: #4fc3f7; border-radius: 10px; min-width: 28px; height: 22px; display: flex; align-items: center; justify-content: center; font-size: 11px; font-weight: bold; } .step-info { flex: 1; } .step-side { padding: 2px 8px; border-radius: 8px; font-size: 11px; font-weight: bold; } .step-side:contains('正面') { background: #1b3a2f; color: #4caf50; } .step-side:contains('背面') { background: #3a1b2f; color: #ce93d8; } /* 网格单元格点位配置 */ .cell-machine { font-size: 11px; font-weight: bold; color: #2c3e50; } .cell-points { margin-top: 2px; font-size: 9px; } .point-row { display: flex; align-items: center; gap: 2px; padding: 1px 2px; background: #f8f9fa; border-radius: 3px; cursor: pointer; margin: 1px 0; } .point-row:hover { background: #e9ecef; } .point-label { color: #666; min-width: 24px; } .point-coords { color: #0366d6; font-family: monospace; font-size: 8px; flex: 1; } .btn-icon-small { background: none; border: none; cursor: pointer; font-size: 10px; padding: 1px 3px; border-radius: 3px; } .btn-icon-small:hover { background: #ddd; } /* ========== 任务配置 弹窗 + 网格增强样式 ========== */ /* 弹窗遮罩 */ .modal-overlay { position: fixed; inset: 0; background: rgba(0,0,0,0.65); display: flex; align-items: center; justify-content: center; z-index: 1000; } .modal-box { background: #1a1f2e; border: 1px solid #2a3a50; border-radius: 12px; padding: 20px 24px; min-width: 380px; max-width: 500px; box-shadow: 0 8px 32px rgba(0,0,0,0.5); } .modal-box h3 { margin: 0 0 8px; color: #e0e6f0; font-size: 16px; } /* 点位行单元格 */ .point-cell { cursor: pointer; flex-direction: column; gap: 2px; } .point-cell:hover { border-color: #4fc3f7; background: #162030; } .point-cell.point-filled { background: #0d2535; border-color: #1565c0; } .point-coords { font-size: 10px; color: #64b5f6; font-family: monospace; } .point-empty { font-size: 10px; color: #455a64; } /* 机器行单元格 */ .machine-cell { cursor: pointer; } .machine-cell:hover { border-color: #4caf50; background: #1b3a2f; } .machine-cell.active { background: #1b3a2f; border-color: #2e7d32; color: #4caf50; } .machine-icon { font-size: 18px; } .machine-empty { font-size: 16px; color: #455a64; } /* ========== 任务配置 弹窗 + 网格增强样式 ========== */ /* 弹窗遮罩 */ .modal-overlay { position: fixed; inset: 0; background: rgba(0,0,0,0.65); display: flex; align-items: center; justify-content: center; z-index: 1000; } .modal-box { background: #1a1f2e; border: 1px solid #2a3a50; border-radius: 12px; padding: 20px 24px; min-width: 380px; max-width: 500px; box-shadow: 0 8px 32px rgba(0,0,0,0.5); } .modal-box h3 { margin: 0 0 8px; color: #e0e6f0; font-size: 16px; } /* 点位行单元格 */ .point-cell { cursor: pointer; flex-direction: column; gap: 2px; } .point-cell:hover { border-color: #4fc3f7; background: #162030; } .point-cell.point-filled { background: #0d2535; border-color: #1565c0; } .point-coords { font-size: 10px; color: #64b5f6; font-family: monospace; } .point-empty { font-size: 10px; color: #455a64; } /* 机器行单元格 */ .machine-cell { cursor: pointer; } .machine-cell:hover { border-color: #4caf50; background: #1b3a2f; } .machine-cell.active { background: #1b3a2f; border-color: #2e7d32; color: #4caf50; } .machine-icon { font-size: 18px; } .machine-empty { font-size: 16px; color: #455a64; } /* 点位编辑弹窗 */ .modal-overlay .modal-box { min-width: 420px; } .modal-overlay .form-row { gap: 8px; } .modal-overlay .btn-row { gap: 8px; flex-wrap: wrap; } /* 地图坐标点覆盖层 */ .map-container { position: relative; } .map-overlay { position: absolute; top: 0; left: 0; right: 0; bottom: 0; pointer-events: none; } .map-dot { position: absolute; transform: translate(-50%, -50%); } .point-dot { width: 10px; height: 10px; background: #f39c12; border-radius: 50%; border: 2px solid #fff; box-shadow: 0 0 6px rgba(243,156,18,0.9); }