/**
* Agent Dashboard Styles
*/
/* Dashboard container */
.agent-dashboard {
position: fixed;
top: 0;
left: 0;
width: 350px;
height: 100vh;
background: var(--dashboard-bg, #ffffff);
border-right: 1px solid var(--dashboard-border, #e0e0e0);
box-shadow: 2px 0 8px rgba(0, 0, 0, 0.1);
z-index: 1000;
transform: translateX(-100%);
transition: transform 0.3s ease;
display: flex;
flex-direction: column;
overflow: hidden;
}
.agent-dashboard.visible {
transform: translateX(0);
}
.agent-dashboard.hidden {
transform: translateX(-100%);
}
/* Dashboard header */
.dashboard-header {
display: flex;
justify-content: space-between;
align-items: center;
padding: 16px 20px;
border-bottom: 1px solid var(--dashboard-border, #e0e0e0);
background: var(--dashboard-header-bg, #f8f9fa);
flex-shrink: 0;
}
.dashboard-header h3 {
margin: 0;
font-size: 1.1em;
font-weight: 600;
color: var(--dashboard-title, #333);
}
.dashboard-controls {
display: flex;
align-items: center;
gap: 8px;
}
.refresh-btn,
.toggle-btn {
background: var(--accent-color, #007acc);
color: white;
border: none;
padding: 6px 10px;
border-radius: 4px;
cursor: pointer;
transition: background 0.2s ease;
font-size: 0.9em;
}
.refresh-btn:hover,
.toggle-btn:hover {
background: var(--accent-hover, #005a9e);
}
/* Dashboard content */
.dashboard-content {
flex: 1;
overflow-y: auto;
padding: 16px 20px;
}
/* Dashboard sections */
.dashboard-section {
margin-bottom: 24px;
}
.dashboard-section h4 {
margin: 0 0 12px 0;
font-size: 1em;
font-weight: 600;
color: var(--section-title, #333);
border-bottom: 1px solid var(--section-border, #eee);
padding-bottom: 6px;
}
/* Statistics grid */
.stats-grid {
display: grid;
grid-template-columns: 1fr 1fr;
gap: 12px;
}
.stat-item {
background: var(--stat-bg, #f8f9fa);
border: 1px solid var(--stat-border, #e9ecef);
border-radius: 6px;
padding: 12px;
text-align: center;
}
.stat-label {
display: block;
font-size: 0.8em;
color: var(--text-muted, #666);
margin-bottom: 4px;
}
.stat-value {
display: block;
font-size: 1.2em;
font-weight: 600;
color: var(--accent-color, #007acc);
}
/* Analysis list */
.analysis-list {
display: flex;
flex-direction: column;
gap: 12px;
max-height: 300px;
overflow-y: auto;
}
.analysis-item {
background: var(--analysis-bg, #fff);
border: 1px solid var(--analysis-border, #e0e0e0);
border-radius: 6px;
padding: 12px;
transition: all 0.2s ease;
}
.analysis-item:hover {
border-color: var(--accent-color, #007acc);
box-shadow: 0 2px 4px rgba(0, 122, 204, 0.1);
}
.analysis-header {
display: flex;
justify-content: space-between;
align-items: center;
margin-bottom: 6px;
flex-wrap: wrap;
gap: 6px;
}
.analysis-symbol {
background: var(--accent-color, #007acc);
color: white;
padding: 2px 6px;
border-radius: 3px;
font-size: 0.8em;
font-weight: 500;
}
.analysis-type {
background: var(--type-bg, #e9ecef);
color: var(--type-text, #495057);
padding: 2px 6px;
border-radius: 3px;
font-size: 0.8em;
text-transform: capitalize;
}
.analysis-time {
font-size: 0.8em;
color: var(--text-muted, #666);
}
.analysis-query {
font-size: 0.85em;
color: var(--text-primary, #333);
margin-bottom: 6px;
line-height: 1.3;
}
.analysis-metrics {
display: flex;
gap: 8px;
flex-wrap: wrap;
}
.analysis-metrics .metric {
font-size: 0.75em;
color: var(--text-muted, #666);
background: var(--metric-bg, #f1f3f4);
padding: 2px 6px;
border-radius: 3px;
}
/* Action buttons */
.action-buttons {
display: flex;
flex-direction: column;
gap: 8px;
}
.action-btn {
background: var(--button-bg, #fff);
color: var(--button-text, #333);
border: 1px solid var(--button-border, #ddd);
padding: 8px 12px;
border-radius: 4px;
cursor: pointer;
transition: all 0.2s ease;
font-size: 0.9em;
}
.action-btn:hover {
background: var(--button-hover-bg, #f8f9fa);
border-color: var(--accent-color, #007acc);
}
.action-btn:active {
background: var(--button-active-bg, #e9ecef);
}
/* Empty state */
.empty-state {
text-align: center;
padding: 20px;
color: var(--text-muted, #666);
}
.empty-state p {
margin: 0;
font-style: italic;
font-size: 0.9em;
}
/* Toast notifications */
.dashboard-toast {
position: fixed;
top: 20px;
left: 370px; /* Position next to dashboard */
padding: 12px 20px;
border-radius: 6px;
color: white;
font-weight: 500;
z-index: 3000;
transform: translateX(-100%);
transition: transform 0.3s ease;
max-width: 300px;
}
.dashboard-toast.show {
transform: translateX(0);
}
.dashboard-toast.toast-success {
background: var(--success-color, #28a745);
}
.dashboard-toast.toast-error {
background: var(--danger-color, #dc3545);
}
/* Dark theme */
[data-theme="dark"] .agent-dashboard {
--dashboard-bg: #2d2d2d;
--dashboard-border: #444;
--dashboard-header-bg: #333;
--dashboard-title: #fff;
--section-title: #fff;
--section-border: #444;
--stat-bg: #333;
--stat-border: #444;
--text-muted: #aaa;
--text-primary: #fff;
--analysis-bg: #333;
--analysis-border: #444;
--type-bg: #444;
--type-text: #ccc;
--metric-bg: #404040;
--button-bg: #444;
--button-text: #fff;
--button-border: #555;
--button-hover-bg: #505050;
--button-active-bg: #555;
}
/* Responsive design */
@media (max-width: 768px) {
.agent-dashboard {
width: 100vw;
}
.dashboard-toast {
left: 20px;
right: 20px;
max-width: none;
}
.stats-grid {
grid-template-columns: 1fr;
}
}
/* Scrollbar styling */
.dashboard-content::-webkit-scrollbar,
.analysis-list::-webkit-scrollbar {
width: 6px;
}
.dashboard-content::-webkit-scrollbar-track,
.analysis-list::-webkit-scrollbar-track {
background: var(--scrollbar-track, #f1f1f1);
}
.dashboard-content::-webkit-scrollbar-thumb,
.analysis-list::-webkit-scrollbar-thumb {
background: var(--scrollbar-thumb, #c1c1c1);
border-radius: 3px;
}
.dashboard-content::-webkit-scrollbar-thumb:hover,
.analysis-list::-webkit-scrollbar-thumb:hover {
background: var(--scrollbar-thumb-hover, #a8a8a8);
}
/* Animation for stats updates */
.stat-value {
transition: color 0.3s ease;
}
.stat-value.updated {
color: var(--success-color, #28a745);
}
/* Performance indicators */
.stat-item.performance-good .stat-value {
color: var(--success-color, #28a745);
}
.stat-item.performance-warning .stat-value {
color: var(--warning-color, #ffc107);
}
.stat-item.performance-poor .stat-value {
color: var(--danger-color, #dc3545);
}
/* Loading state */
.dashboard-section.loading {
opacity: 0.6;
pointer-events: none;
}
.dashboard-section.loading::after {
content: '';
position: absolute;
top: 50%;
left: 50%;
width: 20px;
height: 20px;
margin: -10px 0 0 -10px;
border: 2px solid var(--accent-color, #007acc);
border-top: 2px solid transparent;
border-radius: 50%;
animation: spin 1s linear infinite;
}
@keyframes spin {
0% { transform: rotate(0deg); }
100% { transform: rotate(360deg); }
}