/* ── 全局 ──────────────────────────────────────────────── */ * { margin: 0; padding: 0; box-sizing: border-box; } :root { --bg: #0f1119; --card-bg: #1a1d2e; --border: #2a2d3e; --text: #e0e0e0; --text-dim: #8b8d9a; --accent: #6366f1; --accent2: #22d3ee; --success: #10b981; --warning: #f59e0b; --danger: #ef4444; --radius: 12px; } body { font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif; background: var(--bg); color: var(--text); min-height: 100vh; line-height: 1.6; } .container { max-width: 1400px; margin: 0 auto; padding: 20px; } /* ── Header ────────────────────────────────────────────── */ header { display: flex; justify-content: space-between; align-items: center; padding: 16px 24px; background: var(--card-bg); border-radius: var(--radius); margin-bottom: 20px; border: 1px solid var(--border); } header h1 { font-size: 1.4rem; font-weight: 600; } .header-right { display: flex; align-items: center; gap: 12px; font-size: 0.9rem; color: var(--text-dim); } .status-dot { width: 10px; height: 10px; border-radius: 50%; display: inline-block; } .status-dot.online { background: var(--success); } .status-dot.offline { background: var(--danger); } .uptime { color: var(--accent2); } /* ── 概览卡片 ──────────────────────────────────────────── */ .overview-cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 16px; margin-bottom: 20px; } .card { background: var(--card-bg); border: 1px solid var(--border); border-radius: var(--radius); padding: 18px 20px; display: flex; align-items: center; gap: 14px; transition: border-color 0.2s; } .card:hover { border-color: var(--accent); } .card-icon { font-size: 2rem; opacity: 0.8; } .card-data { flex: 1; } .card-value { font-size: 1.6rem; font-weight: 700; color: var(--text); } .card-label { font-size: 0.8rem; color: var(--text-dim); margin-top: 2px; } /* ── 图表网格 ──────────────────────────────────────────── */ .charts-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(420px, 1fr)); gap: 16px; margin-bottom: 20px; } .chart-panel { background: var(--card-bg); border: 1px solid var(--border); border-radius: var(--radius); padding: 18px; } .chart-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 14px; } .chart-header h3 { font-size: 1rem; font-weight: 600; } .chart-header select { background: var(--bg); color: var(--text); border: 1px solid var(--border); border-radius: 6px; padding: 4px 10px; font-size: 0.8rem; } canvas { width: 100% !important; max-height: 280px; } /* ── 表格 ──────────────────────────────────────────────── */ .table-wrap { max-height: 280px; overflow-y: auto; } .table-wrap table { width: 100%; border-collapse: collapse; font-size: 0.85rem; } .table-wrap th { text-align: left; padding: 8px 10px; border-bottom: 2px solid var(--border); color: var(--text-dim); font-weight: 600; position: sticky; top: 0; background: var(--card-bg); } .table-wrap td { padding: 6px 10px; border-bottom: 1px solid var(--border); } .table-wrap tr:hover td { background: rgba(99, 102, 241, 0.05); } .bar-wrap { display: flex; align-items: center; gap: 8px; } .bar-fill { height: 6px; border-radius: 3px; background: var(--accent); min-width: 2px; } /* ── Section ───────────────────────────────────────────── */ .section { background: var(--card-bg); border: 1px solid var(--border); border-radius: var(--radius); padding: 18px; margin-bottom: 20px; } .section h3 { font-size: 1rem; font-weight: 600; margin-bottom: 12px; } /* ── Footer ────────────────────────────────────────────── */ footer { text-align: center; padding: 16px; color: var(--text-dim); font-size: 0.8rem; display: flex; gap: 20px; justify-content: center; }