/* --- src/styles/tokens.css --- */ /* * Semantic Design Tokens for Antigravity Usage & Speed Monitor. * All visual tokens derive from host CSS variables and perceptual color-mix(), * eliminating hardcoded hex colors across components and views. */ :root { /* Architectural Geometry: Only Top Nav uses --radius-pill */ --radius-pill: 999px; --radius-sm: 4px; --radius-xs: 2px; /* Host-Bridged Surfaces (Clean, zero-muddy-gray light mode) */ --surface-bg: var(--background, hsl(0 0% 100%)); --surface-panel: var(--card, hsl(0 0% 100%)); --surface-subtle: color-mix(in srgb, var(--surface-panel) 97%, var(--text-primary) 3%); --surface-track: color-mix(in srgb, var(--border-hairline) 42%, var(--surface-panel)); --surface-elevated: var(--surface-panel); --surface-hover: color-mix(in srgb, var(--accent-primary) 6%, var(--surface-panel)); --surface-active: color-mix(in srgb, var(--accent-primary) 12%, var(--surface-panel)); --surface-backdrop: color-mix(in srgb, var(--surface-bg) 78%, transparent); /* Crisp 1px Hairline Borders */ --border-hairline: color-mix(in srgb, var(--border, hsl(214 18% 88%)) 82%, var(--surface-panel)); --border-strong: color-mix(in srgb, var(--border-hairline) 72%, var(--text-primary) 28%); --border-focus: var(--accent-primary); /* Typography Hierarchy */ --text-primary: var(--foreground, hsl(215 22% 15%)); --text-secondary: var(--muted-foreground, hsl(215 12% 44%)); --text-muted: color-mix(in srgb, var(--text-secondary) 74%, var(--surface-panel) 26%); --text-inverse: var(--surface-panel); /* Semantic Telemetry Accents */ --accent-primary: var(--primary, hsl(217 82% 51%)); --accent-primary-soft: color-mix(in srgb, var(--accent-primary) 13%, transparent); --accent-primary-border: color-mix(in srgb, var(--accent-primary) 38%, var(--border-hairline)); --metric-speed: hsl(14 76% 52%); --metric-speed-soft: color-mix(in srgb, var(--metric-speed) 14%, transparent); --metric-ok: hsl(145 64% 38%); --metric-ok-soft: color-mix(in srgb, var(--metric-ok) 14%, transparent); --metric-warn: hsl(34 86% 44%); --metric-warn-soft: color-mix(in srgb, var(--metric-warn) 15%, transparent); --metric-danger: var(--destructive, hsl(0 74% 50%)); --metric-danger-soft: color-mix(in srgb, var(--metric-danger) 15%, transparent); /* Context Window 6-Channel Palette */ --ctx-messages: hsl(217 82% 51%); --ctx-system-tools: hsl(22 86% 50%); --ctx-mcp-tools: hsl(268 72% 56%); --ctx-skills: hsl(145 64% 38%); --ctx-system-prompt: hsl(190 80% 38%); --ctx-user-rules: hsl(340 76% 52%); /* Legacy 4-Channel Palette (retained for compatibility) */ --ctx-cached: hsl(217 82% 51%); --ctx-input: hsl(22 86% 50%); --ctx-thinking: hsl(145 64% 38%); --ctx-output: hsl(190 80% 38%); /* Elevation & Shadows */ --shadow-popover: 0 6px 20px color-mix(in srgb, var(--text-primary) 14%, transparent); --shadow-glider: 0 1px 2px color-mix(in srgb, var(--text-primary) 10%, transparent); /* Fast Hardware-Accelerated Motion Tokens */ --ease-fast: cubic-bezier(0.22, 1, 0.36, 1); --dur-instant: 90ms; --dur-fast: 140ms; --dur-normal: 180ms; /* Spacing & Density */ --space-1: 4px; --space-2: 6px; --space-3: 8px; --space-4: 10px; --space-5: 12px; --space-6: 14px; } /* --- src/styles/base.css --- */ /* * Base reset, viewport-locked shell (preventing ultra-long px scroll pages), * and precision tabular typography. */ * { box-sizing: border-box; scrollbar-width: none; -ms-overflow-style: none; } *::-webkit-scrollbar { width: 0 !important; height: 0 !important; display: none !important; } [hidden] { display: none !important; } html, body { margin: 0; padding: 0; width: 100%; height: 100dvh; max-height: 100dvh; overflow: hidden; background: var(--surface-bg); color: var(--text-primary); font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", Roboto, sans-serif; font-size: 12.5px; line-height: 1.4; font-variant-numeric: tabular-nums; -webkit-font-smoothing: antialiased; } button, input { font-family: inherit; font-size: inherit; color: inherit; } .app-shell { display: flex; flex-direction: column; width: 100%; max-width: 560px; height: 100dvh; max-height: 100dvh; margin: 0 auto; padding: var(--space-3) var(--space-4); gap: var(--space-3); overflow: hidden; position: relative; } .top-deck { display: flex; flex-direction: column; gap: var(--space-2); flex-shrink: 0; } .viewport-stage { flex: 1; min-height: 0; display: flex; flex-direction: column; overflow: hidden; position: relative; } .view-pane { flex: 1; min-height: 0; display: flex; flex-direction: column; gap: var(--space-3); overflow-y: auto; overflow-x: hidden; padding-right: 1px; } .svg-icon { display: inline-block; vertical-align: middle; flex-shrink: 0; } .text-muted { color: var(--text-secondary); } .text-mono { font-variant-numeric: tabular-nums; } /* --- src/styles/animations.css --- */ /* * Fast, hardware-accelerated transitions (120ms-160ms) with zero sluggish bounce. */ @keyframes anim-spin { from { transform: rotate(0deg); } to { transform: rotate(360deg); } } @keyframes anim-pulse-dot { 0%, 100% { transform: scale(1); opacity: 1; } 50% { transform: scale(1.22); opacity: 0.62; } } @keyframes anim-view-fade { from { opacity: 0; transform: translate3d(0, 3px, 0); } to { opacity: 1; transform: translate3d(0, 0, 0); } } @keyframes anim-popover-in { from { opacity: 0; transform: translate3d(0, -3px, 0) scale(0.985); } to { opacity: 1; transform: translate3d(0, 0, 0) scale(1); } } .view-pane { animation: anim-view-fade var(--dur-fast) var(--ease-fast); } .is-spinning .svg-icon { animation: anim-spin 520ms linear infinite; } .is-pulsing { animation: anim-pulse-dot 950ms ease-in-out infinite; } /* --- src/styles/components.css --- */ /* * Component Stylesheet for Antigravity Usage & Speed Monitor Monitor. * Enforces: * 1. Top Long-Pill Navigation Bar (--radius-pill) * 2. Internal 2px-4px micro-bezel precision grid (--radius-xs / --radius-sm) * 3. Zero hardcoded colors (all tokens from tokens.css) */ /* --- Row 1: Top Session Control Header --- */ .session-header { display: flex; align-items: center; justify-content: space-between; gap: var(--space-2); padding: 5px var(--space-3); background: var(--surface-panel); border: 1px solid var(--border-hairline); border-radius: var(--radius-sm); } .session-left { display: flex; align-items: center; gap: var(--space-2); flex: 1; min-width: 0; } .session-right { display: flex; align-items: center; gap: 5px; flex-shrink: 0; } .status-tag { display: inline-flex; align-items: center; gap: 4px; padding: 2px 6px; font-size: 11px; font-weight: 600; border-radius: var(--radius-xs); border: 1px solid color-mix(in srgb, var(--metric-ok) 32%, var(--border-hairline)); background: var(--metric-ok-soft); color: var(--metric-ok); } .status-tag.state-running { color: var(--metric-speed); background: var(--metric-speed-soft); border-color: color-mix(in srgb, var(--metric-speed) 35%, var(--border-hairline)); } .status-tag.state-synced { color: var(--accent-primary); background: var(--accent-primary-soft); border-color: var(--accent-primary-border); } .status-tag.state-warn { color: var(--metric-warn); background: var(--metric-warn-soft); border-color: color-mix(in srgb, var(--metric-warn) 35%, var(--border-hairline)); } .icon-btn { display: inline-flex; align-items: center; justify-content: center; gap: 4px; height: 24px; min-width: 24px; padding: 0 6px; background: var(--surface-panel); color: var(--text-secondary); border: 1px solid var(--border-hairline); border-radius: var(--radius-xs); cursor: pointer; user-select: none; transition: background-color var(--dur-instant) var(--ease-fast), color var(--dur-instant) var(--ease-fast), border-color var(--dur-instant) var(--ease-fast), transform var(--dur-instant) var(--ease-fast); } .icon-btn:hover { background: var(--surface-hover); color: var(--text-primary); border-color: var(--border-strong); } .icon-btn:active { transform: scale(0.95); } .icon-btn.is-active { background: var(--accent-primary-soft); color: var(--accent-primary); border-color: var(--accent-primary-border); } /* --- Row 2: Top Long-Pill Navigation Bar (唯一长药丸功能分割顶栏) --- */ .long-pill-nav { position: relative; display: grid; grid-template-columns: repeat(var(--pill-count, 4), 1fr); align-items: center; padding: 3px; background: var(--surface-panel); border: 1px solid var(--border-hairline); border-radius: var(--radius-pill); user-select: none; } .pill-glider { position: absolute; top: 3px; bottom: 3px; left: 3px; width: calc((100% - 6px) / var(--pill-count, 4)); background: var(--accent-primary-soft); border: 1px solid var(--accent-primary-border); border-radius: var(--radius-pill); transform: translate3d(calc(var(--active-index, 0) * 100%), 0, 0); transition: transform var(--dur-fast) var(--ease-fast); pointer-events: none; z-index: 0; } .pill-tab { position: relative; z-index: 1; display: inline-flex; align-items: center; justify-content: center; gap: 5px; height: 26px; padding: 0 var(--space-2); border: none; background: transparent; color: var(--text-secondary); font-size: 12px; font-weight: 500; line-height: 1; border-radius: var(--radius-pill); cursor: pointer; white-space: nowrap; transition: color var(--dur-instant) var(--ease-fast); } .pill-tab .svg-icon { display: block; width: 14px; height: 14px; stroke-width: 1.65; flex-shrink: 0; } .pill-tab-label, .pill-tab-badge { display: inline-flex; align-items: center; height: 14px; line-height: 1; } .pill-tab-badge { margin-left: -2px; font-size: 11.5px; opacity: 0.85; } .pill-tab:hover { color: var(--text-primary); } .pill-tab.is-active { color: var(--accent-primary); font-weight: 600; } .pill-tab.is-active .svg-icon { color: var(--accent-primary); stroke-width: 1.8; } .pill-tab.is-active .pill-tab-badge { color: var(--accent-primary); opacity: 0.92; } /* --- Bespoke Custom Select (零原生 ) --- */ .number-input { display: inline-flex; align-items: stretch; height: 28px; background: var(--surface-panel); border: 1px solid var(--border-hairline); border-radius: var(--radius-xs); overflow: hidden; } .number-input:focus-within { border-color: var(--accent-primary); } .num-step-btn { display: inline-flex; align-items: center; justify-content: center; width: 28px; border: none; background: var(--surface-panel); color: var(--text-secondary); cursor: pointer; transition: background-color var(--dur-instant) var(--ease-fast), color var(--dur-instant) var(--ease-fast); } .num-step-btn:hover { background: var(--surface-hover); color: var(--text-primary); } .num-step-btn:active { background: var(--surface-active); } .num-field { flex: 1; min-width: 90px; padding: 0 var(--space-3); border: none; border-left: 1px solid var(--border-hairline); border-right: 1px solid var(--border-hairline); background: transparent; color: var(--text-primary); font-weight: 600; font-variant-numeric: tabular-nums; outline: none; } /* --- Bespoke Custom DateTime Picker (零原生 ) --- */ .datetime-picker { position: relative; display: inline-flex; flex: 1; min-width: 145px; } .dt-trigger { display: flex; align-items: center; justify-content: space-between; gap: var(--space-2); width: 100%; height: 26px; padding: 0 var(--space-2); background: var(--surface-panel); color: var(--text-primary); border: 1px solid var(--border-hairline); border-radius: var(--radius-xs); font-size: 11.5px; cursor: pointer; } .dt-trigger:hover { border-color: var(--border-strong); } .dt-popover { position: absolute; top: calc(100% + 4px); left: 0; width: 248px; background: var(--surface-panel); border: 1px solid var(--border-strong); border-radius: var(--radius-xs); box-shadow: var(--shadow-popover); padding: var(--space-3); z-index: 70; display: flex; flex-direction: column; gap: var(--space-2); animation: popover-in var(--dur-fast) var(--ease-fast); } .dt-nav { display: flex; align-items: center; justify-content: space-between; font-weight: 600; font-size: 12px; } .dt-weekdays, .dt-days { display: grid; grid-template-columns: repeat(7, 1fr); gap: 2px; text-align: center; } .dt-weekday { font-size: 10.5px; color: var(--text-secondary); padding: 2px 0; } .dt-day { height: 22px; border: none; background: transparent; color: var(--text-primary); font-size: 11px; border-radius: var(--radius-xs); cursor: pointer; } .dt-day:hover { background: var(--surface-hover); } .dt-day.is-selected { background: var(--accent-primary); color: var(--text-inverse); font-weight: 600; } .dt-day.is-outside { color: var(--text-muted); } .dt-time-row { display: flex; align-items: center; justify-content: space-between; gap: var(--space-2); padding-top: var(--space-2); border-top: 1px solid var(--border-hairline); font-size: 11.5px; } .dt-time-controls { display: inline-flex; align-items: center; gap: 4px; } .dt-mini-step { display: inline-flex; align-items: center; gap: 2px; background: var(--surface-panel); border: 1px solid var(--border-hairline); border-radius: var(--radius-xs); padding: 1px 3px; } .dt-mini-btn { border: none; background: transparent; color: var(--text-secondary); cursor: pointer; padding: 1px 3px; } .dt-mini-btn:hover { color: var(--text-primary); } /* --- Micro-Bezel Segmented Control --- */ .segmented { display: inline-flex; align-items: center; gap: 2px; padding: 0; background: transparent; border: none; } .seg-btn { display: inline-flex; align-items: center; justify-content: center; gap: 4px; height: 22px; padding: 0 7px; border: none; background: transparent; color: var(--text-secondary); font-size: 11px; border-radius: var(--radius-xs); cursor: pointer; transition: background-color var(--dur-instant) var(--ease-fast), color var(--dur-instant) var(--ease-fast); } .seg-btn:hover { color: var(--text-primary); background: var(--surface-hover); } .seg-btn.is-active { background: var(--accent-primary-soft); color: var(--accent-primary); font-weight: 600; } /* --- Architectural Precision Panels & Metric Matrices --- */ .panel { display: flex; flex-direction: column; flex-shrink: 0; gap: var(--space-3); padding: var(--space-4) var(--space-5); background: var(--surface-panel); border: 1px solid var(--border-hairline); border-radius: var(--radius-sm); } .panel-header { display: flex; align-items: center; justify-content: space-between; gap: var(--space-2); } .panel-title { display: inline-flex; align-items: center; gap: 6px; font-size: 12px; font-weight: 600; color: var(--text-primary); } .panel-meta { display: inline-flex; align-items: center; gap: 6px; font-size: 11.5px; color: var(--text-secondary); } /* 4-Cell Telemetry Matrix */ .telemetry-matrix { display: grid; grid-template-columns: repeat(4, 1fr); flex-shrink: 0; border: 1px solid var(--border-hairline); border-radius: var(--radius-xs); background: var(--border-hairline); gap: 1px; overflow: hidden; } .matrix-cell { display: flex; flex-direction: column; gap: 2px; padding: 7px 9px; background: var(--surface-panel); min-width: 0; } .cell-label { display: flex; align-items: center; justify-content: space-between; font-size: 11px; color: var(--text-secondary); } .cell-value { font-size: 14.5px; font-weight: 700; color: var(--text-primary); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; } .cell-value.accent-speed { color: var(--metric-speed); } .cell-value.accent-ok { color: var(--metric-ok); } .cell-sub { font-size: 10.5px; color: var(--text-secondary); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; } /* Context Segment Meter & Progress Bars */ .progress-track { width: 100%; height: 6px; background: var(--surface-track); border-radius: var(--radius-xs); overflow: hidden; display: flex; } .progress-seg { height: 100%; width: var(--seg-w, 0%); transition: width var(--dur-normal) var(--ease-fast); } .progress-seg.seg-messages { background: var(--ctx-messages); } .progress-seg.seg-system-tools { background: var(--ctx-system-tools); } .progress-seg.seg-mcp-tools { background: var(--ctx-mcp-tools); } .progress-seg.seg-skills { background: var(--ctx-skills); } .progress-seg.seg-system-prompt { background: var(--ctx-system-prompt); } .progress-seg.seg-user-rules { background: var(--ctx-user-rules); } .progress-seg.seg-cached { background: var(--ctx-cached); } .progress-seg.seg-input { background: var(--ctx-input); } .progress-seg.seg-thinking { background: var(--ctx-thinking); } .progress-seg.seg-output { background: var(--ctx-output); } .progress-fill { height: 100%; width: var(--fill-w, 0%); background: var(--accent-primary); transition: width var(--dur-normal) var(--ease-fast); } .progress-fill.tone-warn { background: var(--metric-warn); } .progress-fill.tone-danger { background: var(--metric-danger); } .ctx-legend-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 5px var(--space-4); padding: 2px 0 0 0; background: transparent; border: none; font-size: 11.5px; } .legend-item { display: flex; align-items: center; justify-content: space-between; gap: var(--space-2); } .legend-left { display: inline-flex; align-items: center; gap: 5px; color: var(--text-secondary); } .swatch { width: 7px; height: 7px; border-radius: 1px; display: inline-block; } .swatch.seg-messages { background: var(--ctx-messages); } .swatch.seg-system-tools { background: var(--ctx-system-tools); } .swatch.seg-mcp-tools { background: var(--ctx-mcp-tools); } .swatch.seg-skills { background: var(--ctx-skills); } .swatch.seg-system-prompt { background: var(--ctx-system-prompt); } .swatch.seg-user-rules { background: var(--ctx-user-rules); } .swatch.seg-cached { background: var(--ctx-cached); } .swatch.seg-input { background: var(--ctx-input); } .swatch.seg-thinking { background: var(--ctx-thinking); } .swatch.seg-output { background: var(--ctx-output); } /* Dual Consumption Comparison Grid */ .dual-grid { display: grid; grid-template-columns: 1fr 1fr; gap: var(--space-3); } @media (max-width: 390px) { .telemetry-matrix { grid-template-columns: repeat(2, 1fr); } .dual-grid { grid-template-columns: 1fr; } } .ledger-box { display: flex; flex-direction: column; gap: 5px; padding: var(--space-3) var(--space-4); background: var(--surface-panel); border: 1px solid var(--border-hairline); border-radius: var(--radius-xs); } .ledger-box.is-primary { background: color-mix(in srgb, var(--accent-primary) 4%, var(--surface-panel)); border-color: var(--accent-primary-border); } .ledger-top { display: flex; align-items: center; justify-content: space-between; gap: var(--space-2); } .ledger-tag { font-size: 10.5px; padding: 0; background: transparent; border: none; color: var(--text-secondary); } .ledger-main { display: flex; align-items: baseline; justify-content: space-between; gap: var(--space-2); } .ledger-tokens { font-size: 16px; font-weight: 700; color: var(--text-primary); } .ledger-cost { font-size: 13px; font-weight: 600; color: var(--metric-speed); } .ledger-foot { font-size: 11px; color: var(--text-secondary); padding-top: 4px; border-top: 1px solid var(--border-hairline); } /* --- Rich Consumption Analytics Dashboard (5-Section Layout) --- */ .cons-overview-head { flex-wrap: wrap; gap: 6px; } .cons-badge { font-size: 11px; font-weight: 500; padding: 0; background: transparent; border: none; color: var(--text-secondary); } .cons-box { display: flex; flex-direction: column; gap: var(--space-3); padding: var(--space-3) var(--space-4); background: var(--surface-panel); border: 1px solid var(--border-hairline); border-radius: var(--radius-xs); } .cons-unified-matrix { gap: 0; padding: 0; border: none; border-top: 1px solid var(--border-hairline); border-bottom: 1px solid var(--border-hairline); border-radius: 0; overflow: hidden; } .cons-split-3 { display: grid; grid-template-columns: repeat(3, 1fr); } .cons-split-2 { display: grid; grid-template-columns: 1fr 1fr; } .cons-matrix-bottom { border-top: 1px solid var(--border-hairline); } .cons-col { display: flex; flex-direction: column; gap: 3px; padding: 8px 10px; min-width: 0; } .cons-col:first-child { padding-left: 0; } .cons-col:last-child { padding-right: 0; } .cons-col.is-bordered-col, .cons-col.is-right-col { border-left: 1px solid var(--border-hairline); } .cons-baseline { display: flex; align-items: baseline; gap: 5px; flex-wrap: wrap; } .cons-hero-num { font-size: 17px; font-weight: 700; color: var(--text-primary); letter-spacing: -0.02em; } .cons-hero-cost { font-size: 17px; font-weight: 700; color: var(--accent-primary); letter-spacing: -0.02em; } .cons-hero-cache { font-size: 17px; font-weight: 700; color: var(--ctx-cached); letter-spacing: -0.02em; } .cons-mid-num { font-size: 13px; font-weight: 700; color: var(--text-primary); } .dot-swatch { width: 6px; height: 6px; border-radius: var(--radius-pill); display: inline-block; flex-shrink: 0; } .dot-swatch.seg-input { background: var(--ctx-input); } .dot-swatch.seg-cached { background: var(--ctx-cached); } .dot-swatch.seg-output { background: var(--ctx-output); } .dot-swatch.seg-thinking { background: var(--ctx-thinking); } /* Uniform 12px / 20px Row Header Alignment for Popular Models & Sources */ .cons-row-title { display: inline-flex; align-items: center; height: 20px; line-height: 20px; font-size: 12px; font-weight: 600; color: var(--text-primary); } .cons-row-metrics { display: inline-flex; align-items: center; gap: 8px; height: 20px; } .cons-share-pill { display: inline-flex; align-items: center; justify-content: center; height: 20px; line-height: 1; padding: 0 6px; font-size: 12px; font-weight: 600; color: var(--metric-ok); background: color-mix(in srgb, var(--metric-ok) 11%, transparent); border: none; border-radius: var(--radius-xs); box-sizing: border-box; } .cons-row-tok { display: inline-flex; align-items: center; height: 20px; line-height: 1; font-size: 12px; font-weight: 500; color: var(--text-secondary); } .cons-row-cost { display: inline-flex; align-items: center; height: 20px; line-height: 1; font-size: 12px; font-weight: 700; color: var(--text-primary); } .cons-seg-bar { height: 5px; } /* Historical Trend SVG Chart */ .trend-chart-wrap { position: relative; width: 100%; padding-top: 8px; } .trend-svg { width: 100%; height: 112px; display: block; overflow: visible; } .trend-grid line { stroke: var(--border-hairline); stroke-width: 1; stroke-dasharray: 2 3; } .trend-line { stroke: var(--ctx-cached); stroke-width: 2; stroke-linecap: round; } .trend-peak-dot { fill: var(--ctx-cached); stroke: var(--surface-panel); stroke-width: 1.5; } .trend-peak-pill { position: absolute; top: 2px; left: var(--peak-x, 50%); transform: translateX(-50%); font-size: 10px; font-weight: 600; padding: 1px 6px; color: var(--text-primary); background: color-mix(in srgb, var(--ctx-cached) 16%, var(--surface-panel)); border: none; border-radius: var(--radius-xs); pointer-events: none; white-space: nowrap; } .trend-anchors { display: grid; grid-template-columns: repeat(3, 1fr); padding-top: 2px; font-size: 11px; } .trend-anchor-col { display: flex; flex-direction: column; gap: 1px; } .trend-anchor-col.is-center { align-items: center; } .trend-anchor-col.is-end { align-items: flex-end; } /* Popular Models & Sources Rows */ .cons-item-list { display: flex; flex-direction: column; gap: var(--space-4); } .cons-item-row { display: flex; flex-direction: column; gap: 6px; } .cons-item-foot { display: flex; align-items: center; flex-wrap: wrap; gap: 4px 10px; font-size: 11px; color: var(--text-secondary); } .cons-item-foot strong { color: var(--text-primary); font-weight: 600; } /* 12-Month Stacked Bar Chart */ .monthly-grid { display: grid; grid-template-columns: repeat(12, 1fr); gap: 3px; align-items: end; padding-top: var(--space-2); } .month-col { display: flex; flex-direction: column; align-items: center; gap: 3px; min-width: 0; } .month-cost { font-size: 9.5px; color: var(--text-secondary); min-height: 14px; white-space: nowrap; } .month-bar-well { width: 100%; height: 82px; display: flex; align-items: flex-end; justify-content: center; } .month-stack { width: 72%; max-width: 20px; height: var(--bar-h, 0%); display: flex; flex-direction: column; border-radius: 2px 2px 0 0; overflow: hidden; transition: height var(--dur-normal) var(--ease-fast); } .month-seg { width: 100%; height: var(--seg-h, 0%); } .month-seg.seg-input { background: var(--ctx-input); } .month-seg.seg-cached { background: var(--ctx-cached); } .month-seg.seg-output { background: var(--ctx-output); } .month-seg.seg-thinking { background: var(--ctx-thinking); } .month-zero-dot { width: 3px; height: 3px; border-radius: var(--radius-pill); background: var(--border-strong); margin-bottom: 4px; } .month-label { font-size: 10px; color: var(--text-secondary); padding: 1px 3px; border-radius: var(--radius-xs); white-space: nowrap; } .month-label.is-current { color: var(--ctx-cached); background: color-mix(in srgb, var(--ctx-cached) 14%, transparent); font-weight: 600; } .month-tok { font-size: 9px; color: var(--text-muted); min-height: 12px; white-space: nowrap; } .monthly-legend { display: flex; align-items: center; justify-content: center; gap: var(--space-4); padding-top: var(--space-2); font-size: 11px; color: var(--text-secondary); } /* --- Bespoke Custom Scrollbar (Dedicated Layout Gutter, Never Overlaps Content) --- */ .custom-scroll-host { position: relative; display: flex; flex-direction: row; align-items: stretch; gap: 5px; min-height: 0; overflow: hidden; } .custom-scroll-host[hidden] { display: none !important; } .table-scroll-host { flex: 1; min-height: 0; gap: 4px; padding-top: 2px; padding-right: 0; border: none; border-top: 1px solid var(--border-hairline); border-radius: 0; background: var(--surface-panel); } .custom-scroll-content { flex: 1; min-width: 0; min-height: 0; overflow-y: auto; overflow-x: hidden; scrollbar-width: none; -ms-overflow-style: none; } .custom-scroll-content::-webkit-scrollbar { width: 0 !important; height: 0 !important; display: none !important; } .scrollbar-rail { position: relative; flex-shrink: 0; width: 5px; margin: 2px 0; border-radius: var(--radius-pill); background: color-mix(in srgb, var(--border-hairline) 35%, transparent); z-index: 15; opacity: 0.85; transition: opacity var(--dur-fast) var(--ease-fast), background-color var(--dur-fast) var(--ease-fast); cursor: pointer; } .custom-scroll-host:hover .scrollbar-rail, .scrollbar-rail.is-dragging { opacity: 1; background: color-mix(in srgb, var(--border-hairline) 65%, transparent); } .scrollbar-rail.is-inactive { display: none !important; opacity: 0 !important; pointer-events: none; } .scrollbar-thumb { width: 100%; height: var(--thumb-h, 0px); border-radius: var(--radius-pill); background: color-mix(in srgb, var(--text-secondary) 32%, transparent); transform: translate3d(0, var(--thumb-y, 0px), 0); will-change: transform, height; transition: background-color var(--dur-instant) var(--ease-fast); } .scrollbar-rail:hover .scrollbar-thumb, .scrollbar-rail.is-dragging .scrollbar-thumb { background: color-mix(in srgb, var(--accent-primary) 72%, transparent); } .table-viewport { flex: 1; min-height: 0; overflow-y: auto; overflow-x: hidden; background: var(--surface-panel); } .data-table { width: 100%; border-collapse: collapse; font-size: 11px; } .data-table th, .data-table td { padding: 5px 4px; text-align: left; border-bottom: 1px solid var(--border-hairline); white-space: nowrap; } .data-table th:first-child, .data-table td:first-child { padding-left: 7px; } .data-table th:last-child, .data-table td:last-child { text-align: right; padding-right: 10px; } .data-table th { position: sticky; top: 0; z-index: 2; background: var(--surface-panel); color: var(--text-secondary); font-weight: 600; } .data-table tbody tr:hover { background: var(--surface-hover); } /* Settings Form Layout */ .form-row { display: flex; flex-direction: column; gap: 5px; } .form-label { font-size: 11.5px; font-weight: 500; color: var(--text-secondary); } .btn-primary { display: inline-flex; align-items: center; justify-content: center; gap: 6px; height: 28px; padding: 0 var(--space-5); background: var(--accent-primary); color: var(--text-inverse); border: 1px solid var(--accent-primary); border-radius: var(--radius-xs); font-weight: 600; font-size: 12px; cursor: pointer; transition: opacity var(--dur-instant) var(--ease-fast), transform var(--dur-instant) var(--ease-fast); } .btn-primary:hover { opacity: 0.92; } .btn-primary:active { transform: scale(0.98); }