Spaces:
Paused
Paused
dushyantsingh0 commited on
Commit ·
6150554
1
Parent(s): 1fdd745
backend stabilization
Browse files- api/v1/escalations.py +3 -1
- frontend/apps/internal/src/components/DashboardOverview.module.css +4 -4
- frontend/apps/internal/src/components/TopBar.module.css +36 -10
- frontend/apps/internal/src/components/TopBar.tsx +16 -2
- frontend/apps/internal/src/main.tsx +8 -6
- frontend/packages/shared/src/contexts/ThemeContext.tsx +60 -0
- frontend/packages/shared/src/index.ts +1 -0
- frontend/packages/shared/src/styles/theme.css +93 -79
api/v1/escalations.py
CHANGED
|
@@ -7,6 +7,7 @@ from uuid import UUID
|
|
| 7 |
from fastapi import APIRouter, Depends, HTTPException, status
|
| 8 |
from sqlalchemy.ext.asyncio import AsyncSession
|
| 9 |
from sqlalchemy import select, and_, String, cast, func
|
|
|
|
| 10 |
|
| 11 |
from core.deps import get_db, get_current_user
|
| 12 |
from core.permissions import require_roles, WORKSPACE_ADMIN_ROLES, ALL_SC_ROLES, get_effective_context
|
|
@@ -169,6 +170,7 @@ async def list_active_breaches(
|
|
| 169 |
# 1. Fetch tickets and ACTIVE rules
|
| 170 |
stmt = (
|
| 171 |
select(Ticket, EscalationRule.threshold_minutes)
|
|
|
|
| 172 |
.join(EscalationRule, and_(
|
| 173 |
EscalationRule.workspace_id == Ticket.workspace_id,
|
| 174 |
EscalationRule.priority_level == cast(Ticket.priority, String),
|
|
@@ -210,7 +212,7 @@ async def list_active_breaches(
|
|
| 210 |
"title": ticket.title,
|
| 211 |
"priority": ticket.priority,
|
| 212 |
"status": ticket.status,
|
| 213 |
-
"assigned_name": ticket.
|
| 214 |
"age_minutes": round(age_mins, 1),
|
| 215 |
"threshold": limit,
|
| 216 |
"risk_score": risk_score,
|
|
|
|
| 7 |
from fastapi import APIRouter, Depends, HTTPException, status
|
| 8 |
from sqlalchemy.ext.asyncio import AsyncSession
|
| 9 |
from sqlalchemy import select, and_, String, cast, func
|
| 10 |
+
from sqlalchemy.orm import joinedload
|
| 11 |
|
| 12 |
from core.deps import get_db, get_current_user
|
| 13 |
from core.permissions import require_roles, WORKSPACE_ADMIN_ROLES, ALL_SC_ROLES, get_effective_context
|
|
|
|
| 170 |
# 1. Fetch tickets and ACTIVE rules
|
| 171 |
stmt = (
|
| 172 |
select(Ticket, EscalationRule.threshold_minutes)
|
| 173 |
+
.options(joinedload(Ticket.assignee))
|
| 174 |
.join(EscalationRule, and_(
|
| 175 |
EscalationRule.workspace_id == Ticket.workspace_id,
|
| 176 |
EscalationRule.priority_level == cast(Ticket.priority, String),
|
|
|
|
| 212 |
"title": ticket.title,
|
| 213 |
"priority": ticket.priority,
|
| 214 |
"status": ticket.status,
|
| 215 |
+
"assigned_name": ticket.assignee.full_name if ticket.assignee else "UNASSIGNED",
|
| 216 |
"age_minutes": round(age_mins, 1),
|
| 217 |
"threshold": limit,
|
| 218 |
"risk_score": risk_score,
|
frontend/apps/internal/src/components/DashboardOverview.module.css
CHANGED
|
@@ -254,10 +254,10 @@
|
|
| 254 |
}
|
| 255 |
|
| 256 |
.card {
|
| 257 |
-
background:
|
| 258 |
backdrop-filter: blur(8px);
|
| 259 |
-webkit-backdrop-filter: blur(8px);
|
| 260 |
-
border: 1px solid
|
| 261 |
border-radius: var(--radius-lg);
|
| 262 |
padding: 28px;
|
| 263 |
box-shadow: 0 8px 32px rgba(0, 0, 0, 0.05);
|
|
@@ -444,7 +444,7 @@
|
|
| 444 |
flex: 1;
|
| 445 |
overflow-x: auto;
|
| 446 |
overflow-y: hidden;
|
| 447 |
-
background:
|
| 448 |
border-radius: var(--radius-md);
|
| 449 |
border: 1px solid var(--border-subtle);
|
| 450 |
}
|
|
@@ -480,7 +480,7 @@
|
|
| 480 |
text-transform: uppercase;
|
| 481 |
letter-spacing: 0.1em;
|
| 482 |
padding: 12px 16px;
|
| 483 |
-
background:
|
| 484 |
border-bottom: 1px solid var(--border-subtle);
|
| 485 |
}
|
| 486 |
|
|
|
|
| 254 |
}
|
| 255 |
|
| 256 |
.card {
|
| 257 |
+
background: var(--bg-card);
|
| 258 |
backdrop-filter: blur(8px);
|
| 259 |
-webkit-backdrop-filter: blur(8px);
|
| 260 |
+
border: 1px solid var(--border-subtle);
|
| 261 |
border-radius: var(--radius-lg);
|
| 262 |
padding: 28px;
|
| 263 |
box-shadow: 0 8px 32px rgba(0, 0, 0, 0.05);
|
|
|
|
| 444 |
flex: 1;
|
| 445 |
overflow-x: auto;
|
| 446 |
overflow-y: hidden;
|
| 447 |
+
background: var(--bg-card);
|
| 448 |
border-radius: var(--radius-md);
|
| 449 |
border: 1px solid var(--border-subtle);
|
| 450 |
}
|
|
|
|
| 480 |
text-transform: uppercase;
|
| 481 |
letter-spacing: 0.1em;
|
| 482 |
padding: 12px 16px;
|
| 483 |
+
background: var(--bg-hover);
|
| 484 |
border-bottom: 1px solid var(--border-subtle);
|
| 485 |
}
|
| 486 |
|
frontend/apps/internal/src/components/TopBar.module.css
CHANGED
|
@@ -52,7 +52,7 @@
|
|
| 52 |
.title {
|
| 53 |
font-size: clamp(16px, 2.5vw, 24px);
|
| 54 |
font-weight: 800;
|
| 55 |
-
color:
|
| 56 |
letter-spacing: -0.02em;
|
| 57 |
white-space: nowrap;
|
| 58 |
overflow: hidden;
|
|
@@ -62,7 +62,7 @@
|
|
| 62 |
.subtitle {
|
| 63 |
font-size: 11px;
|
| 64 |
font-weight: 700;
|
| 65 |
-
color:
|
| 66 |
letter-spacing: 0.1em;
|
| 67 |
text-transform: uppercase;
|
| 68 |
margin-top: -2px;
|
|
@@ -144,12 +144,12 @@
|
|
| 144 |
|
| 145 |
.searchInput {
|
| 146 |
width: 100%;
|
| 147 |
-
background:
|
| 148 |
-
border: 1px solid
|
| 149 |
border-radius: 8px;
|
| 150 |
padding: 8px 12px 8px 32px;
|
| 151 |
font-size: 13px;
|
| 152 |
-
color:
|
| 153 |
outline: none;
|
| 154 |
transition: all 0.2s;
|
| 155 |
}
|
|
@@ -300,10 +300,10 @@
|
|
| 300 |
display: flex;
|
| 301 |
align-items: center;
|
| 302 |
gap: 8px;
|
| 303 |
-
background:
|
| 304 |
padding: 6px 12px;
|
| 305 |
border-radius: 20px;
|
| 306 |
-
border: 1px solid
|
| 307 |
}
|
| 308 |
|
| 309 |
.dot {
|
|
@@ -324,19 +324,45 @@
|
|
| 324 |
.statusText {
|
| 325 |
font-size: 11px;
|
| 326 |
font-weight: 900;
|
| 327 |
-
color:
|
| 328 |
letter-spacing: 0.05em;
|
| 329 |
}
|
| 330 |
|
| 331 |
.timeText {
|
| 332 |
font-size: 11px;
|
| 333 |
font-weight: 600;
|
| 334 |
-
color:
|
| 335 |
-
border-left: 1px solid
|
| 336 |
padding-left: 8px;
|
| 337 |
margin-left: 4px;
|
| 338 |
}
|
| 339 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 340 |
/* Notifications */
|
| 341 |
.notificationWrapper {
|
| 342 |
position: relative;
|
|
|
|
| 52 |
.title {
|
| 53 |
font-size: clamp(16px, 2.5vw, 24px);
|
| 54 |
font-weight: 800;
|
| 55 |
+
color: var(--text-main);
|
| 56 |
letter-spacing: -0.02em;
|
| 57 |
white-space: nowrap;
|
| 58 |
overflow: hidden;
|
|
|
|
| 62 |
.subtitle {
|
| 63 |
font-size: 11px;
|
| 64 |
font-weight: 700;
|
| 65 |
+
color: var(--text-muted);
|
| 66 |
letter-spacing: 0.1em;
|
| 67 |
text-transform: uppercase;
|
| 68 |
margin-top: -2px;
|
|
|
|
| 144 |
|
| 145 |
.searchInput {
|
| 146 |
width: 100%;
|
| 147 |
+
background: var(--bg-card);
|
| 148 |
+
border: 1px solid var(--border-subtle);
|
| 149 |
border-radius: 8px;
|
| 150 |
padding: 8px 12px 8px 32px;
|
| 151 |
font-size: 13px;
|
| 152 |
+
color: var(--text-main);
|
| 153 |
outline: none;
|
| 154 |
transition: all 0.2s;
|
| 155 |
}
|
|
|
|
| 300 |
display: flex;
|
| 301 |
align-items: center;
|
| 302 |
gap: 8px;
|
| 303 |
+
background: var(--bg-hover);
|
| 304 |
padding: 6px 12px;
|
| 305 |
border-radius: 20px;
|
| 306 |
+
border: 1px solid var(--border-subtle);
|
| 307 |
}
|
| 308 |
|
| 309 |
.dot {
|
|
|
|
| 324 |
.statusText {
|
| 325 |
font-size: 11px;
|
| 326 |
font-weight: 900;
|
| 327 |
+
color: var(--text-main);
|
| 328 |
letter-spacing: 0.05em;
|
| 329 |
}
|
| 330 |
|
| 331 |
.timeText {
|
| 332 |
font-size: 11px;
|
| 333 |
font-weight: 600;
|
| 334 |
+
color: var(--text-muted);
|
| 335 |
+
border-left: 1px solid var(--border-subtle);
|
| 336 |
padding-left: 8px;
|
| 337 |
margin-left: 4px;
|
| 338 |
}
|
| 339 |
|
| 340 |
+
/* Theme Switcher */
|
| 341 |
+
.themeWrapper {
|
| 342 |
+
display: flex;
|
| 343 |
+
align-items: center;
|
| 344 |
+
}
|
| 345 |
+
|
| 346 |
+
.themeBtn {
|
| 347 |
+
background: var(--bg-card);
|
| 348 |
+
border: 1px solid var(--border-subtle);
|
| 349 |
+
width: 38px;
|
| 350 |
+
height: 38px;
|
| 351 |
+
border-radius: 8px;
|
| 352 |
+
display: flex;
|
| 353 |
+
align-items: center;
|
| 354 |
+
justify-content: center;
|
| 355 |
+
color: var(--text-muted);
|
| 356 |
+
cursor: pointer;
|
| 357 |
+
transition: all 0.2s;
|
| 358 |
+
}
|
| 359 |
+
|
| 360 |
+
.themeBtn:hover {
|
| 361 |
+
background: var(--bg-hover);
|
| 362 |
+
color: var(--primary);
|
| 363 |
+
transform: scale(1.05);
|
| 364 |
+
}
|
| 365 |
+
|
| 366 |
/* Notifications */
|
| 367 |
.notificationWrapper {
|
| 368 |
position: relative;
|
frontend/apps/internal/src/components/TopBar.tsx
CHANGED
|
@@ -1,6 +1,6 @@
|
|
| 1 |
import React, { useState, useEffect } from 'react';
|
| 2 |
-
import { useAuth, api, getWsUrl, getStorageKey } from '@nexus/shared';
|
| 3 |
-
import { Menu } from 'lucide-react';
|
| 4 |
import styles from './TopBar.module.css';
|
| 5 |
|
| 6 |
interface TopBarProps {
|
|
@@ -21,6 +21,7 @@ export const TopBar: React.FC<TopBarProps> = ({ title, subtitle, logoUrl, onTick
|
|
| 21 |
const [showNotifications, setShowNotifications] = useState(false);
|
| 22 |
const searchRef = React.useRef<HTMLFormElement>(null);
|
| 23 |
const { logout, user } = useAuth();
|
|
|
|
| 24 |
const [notifications, setNotifications] = useState<any[]>([]);
|
| 25 |
const [hasUnread, setHasUnread] = useState(false);
|
| 26 |
const [isLoadingMore, setIsLoadingMore] = useState(false);
|
|
@@ -251,6 +252,19 @@ export const TopBar: React.FC<TopBarProps> = ({ title, subtitle, logoUrl, onTick
|
|
| 251 |
<span className={styles.timeText}>{time.toLocaleTimeString('en-GB')}</span>
|
| 252 |
</div>
|
| 253 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 254 |
<div className={styles.notificationWrapper}>
|
| 255 |
<button className={styles.iconButton} onClick={() => {
|
| 256 |
setShowNotifications(!showNotifications);
|
|
|
|
| 1 |
import React, { useState, useEffect } from 'react';
|
| 2 |
+
import { useAuth, api, getWsUrl, getStorageKey, useTheme } from '@nexus/shared';
|
| 3 |
+
import { Menu, Sun, Moon, Zap, Shield } from 'lucide-react';
|
| 4 |
import styles from './TopBar.module.css';
|
| 5 |
|
| 6 |
interface TopBarProps {
|
|
|
|
| 21 |
const [showNotifications, setShowNotifications] = useState(false);
|
| 22 |
const searchRef = React.useRef<HTMLFormElement>(null);
|
| 23 |
const { logout, user } = useAuth();
|
| 24 |
+
const { theme, setTheme } = useTheme();
|
| 25 |
const [notifications, setNotifications] = useState<any[]>([]);
|
| 26 |
const [hasUnread, setHasUnread] = useState(false);
|
| 27 |
const [isLoadingMore, setIsLoadingMore] = useState(false);
|
|
|
|
| 252 |
<span className={styles.timeText}>{time.toLocaleTimeString('en-GB')}</span>
|
| 253 |
</div>
|
| 254 |
|
| 255 |
+
<div className={styles.themeWrapper}>
|
| 256 |
+
<button
|
| 257 |
+
className={styles.themeBtn}
|
| 258 |
+
onClick={() => setTheme(theme === 'light' ? 'dark' : theme === 'dark' ? 'midnight' : theme === 'midnight' ? 'emerald' : 'light')}
|
| 259 |
+
title={`Switch Theme: ${theme.toUpperCase()}`}
|
| 260 |
+
>
|
| 261 |
+
{theme === 'light' && <Sun size={18} />}
|
| 262 |
+
{theme === 'dark' && <Moon size={18} />}
|
| 263 |
+
{theme === 'midnight' && <Zap size={18} />}
|
| 264 |
+
{theme === 'emerald' && <Shield size={18} />}
|
| 265 |
+
</button>
|
| 266 |
+
</div>
|
| 267 |
+
|
| 268 |
<div className={styles.notificationWrapper}>
|
| 269 |
<button className={styles.iconButton} onClick={() => {
|
| 270 |
setShowNotifications(!showNotifications);
|
frontend/apps/internal/src/main.tsx
CHANGED
|
@@ -1,17 +1,19 @@
|
|
| 1 |
import { StrictMode } from 'react'
|
| 2 |
import { createRoot } from 'react-dom/client'
|
| 3 |
import './index.css'
|
| 4 |
-
import { AuthProvider, NexusProvider, setPortalType } from '@nexus/shared'
|
| 5 |
import App from './App.tsx'
|
| 6 |
|
| 7 |
setPortalType('internal');
|
| 8 |
|
| 9 |
createRoot(document.getElementById('root')!).render(
|
| 10 |
<StrictMode>
|
| 11 |
-
<
|
| 12 |
-
<
|
| 13 |
-
<
|
| 14 |
-
|
| 15 |
-
|
|
|
|
|
|
|
| 16 |
</StrictMode>,
|
| 17 |
);
|
|
|
|
| 1 |
import { StrictMode } from 'react'
|
| 2 |
import { createRoot } from 'react-dom/client'
|
| 3 |
import './index.css'
|
| 4 |
+
import { AuthProvider, NexusProvider, setPortalType, ThemeProvider } from '@nexus/shared'
|
| 5 |
import App from './App.tsx'
|
| 6 |
|
| 7 |
setPortalType('internal');
|
| 8 |
|
| 9 |
createRoot(document.getElementById('root')!).render(
|
| 10 |
<StrictMode>
|
| 11 |
+
<ThemeProvider>
|
| 12 |
+
<AuthProvider>
|
| 13 |
+
<NexusProvider>
|
| 14 |
+
<App />
|
| 15 |
+
</NexusProvider>
|
| 16 |
+
</AuthProvider>
|
| 17 |
+
</ThemeProvider>
|
| 18 |
</StrictMode>,
|
| 19 |
);
|
frontend/packages/shared/src/contexts/ThemeContext.tsx
ADDED
|
@@ -0,0 +1,60 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
import React, { createContext, useContext, useState, useEffect } from 'react';
|
| 2 |
+
|
| 3 |
+
export type ThemeType = 'light' | 'dark' | 'midnight' | 'emerald';
|
| 4 |
+
|
| 5 |
+
interface ThemeContextType {
|
| 6 |
+
theme: ThemeType;
|
| 7 |
+
setTheme: (theme: ThemeType) => void;
|
| 8 |
+
toggleDarkMode: () => void;
|
| 9 |
+
isDark: boolean;
|
| 10 |
+
}
|
| 11 |
+
|
| 12 |
+
const ThemeContext = createContext<ThemeContextType | undefined>(undefined);
|
| 13 |
+
|
| 14 |
+
export const ThemeProvider: React.FC<{ children: React.ReactNode }> = ({ children }) => {
|
| 15 |
+
const [theme, setTheme] = useState<ThemeType>(() => {
|
| 16 |
+
const saved = localStorage.getItem('nexus_internal_theme');
|
| 17 |
+
return (saved as ThemeType) || 'light';
|
| 18 |
+
});
|
| 19 |
+
|
| 20 |
+
useEffect(() => {
|
| 21 |
+
// Apply theme to document element
|
| 22 |
+
const root = document.documentElement;
|
| 23 |
+
|
| 24 |
+
// Remove all theme classes
|
| 25 |
+
root.classList.remove('theme-light', 'theme-dark', 'theme-midnight', 'theme-emerald');
|
| 26 |
+
|
| 27 |
+
// Add active theme class
|
| 28 |
+
root.classList.add(`theme-${theme}`);
|
| 29 |
+
|
| 30 |
+
// Persist
|
| 31 |
+
localStorage.setItem('nexus_internal_theme', theme);
|
| 32 |
+
|
| 33 |
+
// Handle standard dark mode media query if necessary
|
| 34 |
+
if (theme === 'dark' || theme === 'midnight') {
|
| 35 |
+
root.style.colorScheme = 'dark';
|
| 36 |
+
} else {
|
| 37 |
+
root.style.colorScheme = 'light';
|
| 38 |
+
}
|
| 39 |
+
}, [theme]);
|
| 40 |
+
|
| 41 |
+
const toggleDarkMode = () => {
|
| 42 |
+
setTheme(prev => (prev === 'light' ? 'dark' : 'light'));
|
| 43 |
+
};
|
| 44 |
+
|
| 45 |
+
const isDark = theme === 'dark' || theme === 'midnight';
|
| 46 |
+
|
| 47 |
+
return (
|
| 48 |
+
<ThemeContext.Provider value={{ theme, setTheme, toggleDarkMode, isDark }}>
|
| 49 |
+
{children}
|
| 50 |
+
</ThemeContext.Provider>
|
| 51 |
+
);
|
| 52 |
+
};
|
| 53 |
+
|
| 54 |
+
export const useTheme = () => {
|
| 55 |
+
const context = useContext(ThemeContext);
|
| 56 |
+
if (!context) {
|
| 57 |
+
throw new Error('useTheme must be used within a ThemeProvider');
|
| 58 |
+
}
|
| 59 |
+
return context;
|
| 60 |
+
};
|
frontend/packages/shared/src/index.ts
CHANGED
|
@@ -9,6 +9,7 @@ export * from './components/ApprovalCard';
|
|
| 9 |
export * from './components/MentionOverlay';
|
| 10 |
export * from './hooks/useAuth';
|
| 11 |
export { AuthProvider } from './contexts/AuthContext';
|
|
|
|
| 12 |
export { NexusProvider, useNexusContext } from './contexts/NexusContext';
|
| 13 |
export { NexusLogo } from './components/NexusLogo';
|
| 14 |
export { NeuralBackground } from './components/NeuralBackground';
|
|
|
|
| 9 |
export * from './components/MentionOverlay';
|
| 10 |
export * from './hooks/useAuth';
|
| 11 |
export { AuthProvider } from './contexts/AuthContext';
|
| 12 |
+
export { ThemeProvider, useTheme } from './contexts/ThemeContext';
|
| 13 |
export { NexusProvider, useNexusContext } from './contexts/NexusContext';
|
| 14 |
export { NexusLogo } from './components/NexusLogo';
|
| 15 |
export { NeuralBackground } from './components/NeuralBackground';
|
frontend/packages/shared/src/styles/theme.css
CHANGED
|
@@ -1,66 +1,106 @@
|
|
| 1 |
:root {
|
| 2 |
-
/*
|
| 3 |
-
|
| 4 |
-
/* Background Levels */
|
| 5 |
-
--bg-dark: #fbfcfe; /* Minimal Slate-50 (Body) */
|
| 6 |
-
--bg-card: #ffffff; /* Pure White (Surface) */
|
| 7 |
-
--bg-hover: #f1f5f9; /* Slate-100 (Active/Hover) */
|
| 8 |
-
--bg-panel: hsla(215, 28%, 17%, 0.04);
|
| 9 |
-
--bg-popover: #0f172a; /* Deep Slate for dark dropdowns */
|
| 10 |
-
|
| 11 |
-
/* Primary Branding (Enterprise Violet) */
|
| 12 |
-
--primary: #7c3aed; /* Mission Violet */
|
| 13 |
-
--primary-light: #a78bfa;
|
| 14 |
-
--primary-glow: rgba(124, 58, 237, 0.08);
|
| 15 |
-
--secondary: #4338ca; /* Indigo-700 */
|
| 16 |
-
|
| 17 |
-
/* Neural Horizon Overhaul - Refined Contrast */
|
| 18 |
-
--bg-obsidian: #0c0e14; /* Darker Slate-950 (Authority Dark) */
|
| 19 |
-
--neural-accent-violet: #a855f7;
|
| 20 |
-
--neural-accent-cyan: #06b6d4;
|
| 21 |
-
--neural-accent-amber: #fbbf24;
|
| 22 |
-
--neural-accent-indigo: #6366f1;
|
| 23 |
-
--brand-gradient: linear-gradient(135deg, var(--neural-accent-indigo) 0%, var(--neural-accent-violet) 100%);
|
| 24 |
-
|
| 25 |
-
/* Typography Hierarchy */
|
| 26 |
-
--text-main: #0f172a; /* Slate-900 (High hierarchy) */
|
| 27 |
-
--text-muted: #64748b; /* Slate-500 (Secondary) */
|
| 28 |
-
--text-dim: #94a3b8; /* Slate-400 (Metadata) */
|
| 29 |
-
--text-on-dark: #ffffff;
|
| 30 |
-
--text-inverse: #ffffff;
|
| 31 |
-
--text-popover: #f1f5f9;
|
| 32 |
-
|
| 33 |
-
/* Borders & Accents */
|
| 34 |
-
--border-subtle: #e2e8f0;
|
| 35 |
-
--border-hi: #cbd5e1;
|
| 36 |
-
--border-active: #7c3aed;
|
| 37 |
-
|
| 38 |
-
/* Semantic States */
|
| 39 |
-
--success: #10b981;
|
| 40 |
-
--warning: #f59e0b;
|
| 41 |
-
--error: #ef4444;
|
| 42 |
-
|
| 43 |
-
/* Layout Constants */
|
| 44 |
-
--banner-gradient: linear-gradient(135deg, #6d28d9 0%, #7c3aed 100%);
|
| 45 |
-
--glass-bg: rgba(255, 255, 255, 0.7);
|
| 46 |
-
--glass-border: rgba(0, 0, 0, 0.04);
|
| 47 |
-
--glass-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
|
| 48 |
-
|
| 49 |
-
/* Spacing & Radii */
|
| 50 |
--radius-sm: 8px;
|
| 51 |
--radius-md: 12px;
|
| 52 |
--radius-lg: 20px;
|
| 53 |
-
|
| 54 |
-
/* Modern Dashboard Constants */
|
| 55 |
-
--hero-mesh: linear-gradient(135deg, #f1f5f9 0%, #ffffff 100%);
|
| 56 |
--radius-xl: 32px;
|
| 57 |
--radius-full: 9999px;
|
| 58 |
-
|
| 59 |
-
/* Fonts */
|
| 60 |
--font-sans: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
|
| 61 |
--font-heading: 'Manrope', var(--font-sans);
|
| 62 |
--font-mono: 'JetBrains Mono', 'Fira Code', monospace;
|
| 63 |
--font-main: var(--font-sans);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 64 |
}
|
| 65 |
|
| 66 |
/* Premium Selection & Scrollbars */
|
|
@@ -149,29 +189,3 @@ input, textarea, select {
|
|
| 149 |
from { opacity: 0; transform: translateY(10px); }
|
| 150 |
to { opacity: 1; transform: translateY(0); }
|
| 151 |
}
|
| 152 |
-
@keyframes meshGradient {
|
| 153 |
-
0% { background-position: 0% 50%; }
|
| 154 |
-
50% { background-position: 100% 50%; }
|
| 155 |
-
100% { background-position: 0% 50%; }
|
| 156 |
-
}
|
| 157 |
-
|
| 158 |
-
@keyframes gridFloat {
|
| 159 |
-
from { transform: translateY(0); }
|
| 160 |
-
to { transform: translateY(20px); }
|
| 161 |
-
}
|
| 162 |
-
|
| 163 |
-
.tactical-grid {
|
| 164 |
-
position: absolute;
|
| 165 |
-
top: -50%;
|
| 166 |
-
left: -50%;
|
| 167 |
-
right: -50%;
|
| 168 |
-
bottom: -50%;
|
| 169 |
-
background-image:
|
| 170 |
-
linear-gradient(rgba(255, 255, 255, 0.03) 1px, transparent 1px),
|
| 171 |
-
linear-gradient(90deg, rgba(255, 255, 255, 0.03) 1px, transparent 1px);
|
| 172 |
-
background-size: 30px 30px;
|
| 173 |
-
mask-image: radial-gradient(circle at center, black 30%, transparent 70%);
|
| 174 |
-
pointer-events: none;
|
| 175 |
-
animation: gridFloat 20s linear infinite;
|
| 176 |
-
z-index: 1;
|
| 177 |
-
}
|
|
|
|
| 1 |
:root {
|
| 2 |
+
/* 1. Base Primitives (Inherited by all themes) */
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 3 |
--radius-sm: 8px;
|
| 4 |
--radius-md: 12px;
|
| 5 |
--radius-lg: 20px;
|
|
|
|
|
|
|
|
|
|
| 6 |
--radius-xl: 32px;
|
| 7 |
--radius-full: 9999px;
|
|
|
|
|
|
|
| 8 |
--font-sans: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
|
| 9 |
--font-heading: 'Manrope', var(--font-sans);
|
| 10 |
--font-mono: 'JetBrains Mono', 'Fira Code', monospace;
|
| 11 |
--font-main: var(--font-sans);
|
| 12 |
+
|
| 13 |
+
/* Semantic Colors (Constant across themes) */
|
| 14 |
+
--success: #10b981;
|
| 15 |
+
--warning: #f59e0b;
|
| 16 |
+
--error: #ef4444;
|
| 17 |
+
|
| 18 |
+
/* Theme: Light (Default) */
|
| 19 |
+
--bg-dark: #fbfcfe;
|
| 20 |
+
--bg-card: #ffffff;
|
| 21 |
+
--bg-hover: #f1f5f9;
|
| 22 |
+
--bg-panel: hsla(215, 28%, 17%, 0.04);
|
| 23 |
+
--bg-popover: #0f172a;
|
| 24 |
+
--primary: #7c3aed;
|
| 25 |
+
--primary-light: #a78bfa;
|
| 26 |
+
--primary-glow: rgba(124, 58, 237, 0.08);
|
| 27 |
+
--secondary: #4338ca;
|
| 28 |
+
--text-main: #0f172a;
|
| 29 |
+
--text-muted: #64748b;
|
| 30 |
+
--text-dim: #94a3b8;
|
| 31 |
+
--text-inverse: #ffffff;
|
| 32 |
+
--border-subtle: #e2e8f0;
|
| 33 |
+
--border-hi: #cbd5e1;
|
| 34 |
+
--glass-bg: rgba(255, 255, 255, 0.7);
|
| 35 |
+
--glass-border: rgba(0, 0, 0, 0.04);
|
| 36 |
+
--banner-gradient: linear-gradient(135deg, #6d28d9 0%, #7c3aed 100%);
|
| 37 |
+
--glass-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
|
| 38 |
+
}
|
| 39 |
+
|
| 40 |
+
/* 2. Theme: High-Contrast Dark */
|
| 41 |
+
.theme-dark {
|
| 42 |
+
--bg-dark: #0f172a;
|
| 43 |
+
--bg-card: #1e293b;
|
| 44 |
+
--bg-hover: #334155;
|
| 45 |
+
--bg-panel: rgba(255, 255, 255, 0.05);
|
| 46 |
+
--bg-popover: #1e293b;
|
| 47 |
+
--primary: #8b5cf6;
|
| 48 |
+
--primary-light: #c4b5fd;
|
| 49 |
+
--primary-glow: rgba(139, 92, 246, 0.15);
|
| 50 |
+
--secondary: #6366f1;
|
| 51 |
+
--text-main: #f8fafc;
|
| 52 |
+
--text-muted: #94a3b8;
|
| 53 |
+
--text-dim: #64748b;
|
| 54 |
+
--text-inverse: #0f172a;
|
| 55 |
+
--border-subtle: #334155;
|
| 56 |
+
--border-hi: #475569;
|
| 57 |
+
--glass-bg: rgba(15, 23, 42, 0.8);
|
| 58 |
+
--glass-border: rgba(255, 255, 255, 0.1);
|
| 59 |
+
--banner-gradient: linear-gradient(135deg, #4c1d95 0%, #7c3aed 100%);
|
| 60 |
+
}
|
| 61 |
+
|
| 62 |
+
/* 3. Theme: Deep Midnight (Obsidian) */
|
| 63 |
+
.theme-midnight {
|
| 64 |
+
--bg-dark: #020617;
|
| 65 |
+
--bg-card: #0c0e14;
|
| 66 |
+
--bg-hover: #1e1b4b;
|
| 67 |
+
--bg-panel: rgba(99, 102, 241, 0.05);
|
| 68 |
+
--bg-popover: #0f172a;
|
| 69 |
+
--primary: #a855f7;
|
| 70 |
+
--primary-light: #d8b4fe;
|
| 71 |
+
--primary-glow: rgba(168, 85, 247, 0.2);
|
| 72 |
+
--secondary: #6366f1;
|
| 73 |
+
--text-main: #ffffff;
|
| 74 |
+
--text-muted: #94a3b8;
|
| 75 |
+
--text-dim: #475569;
|
| 76 |
+
--text-inverse: #000000;
|
| 77 |
+
--border-subtle: #1e293b;
|
| 78 |
+
--border-hi: #334155;
|
| 79 |
+
--glass-bg: rgba(2, 6, 23, 0.9);
|
| 80 |
+
--glass-border: rgba(255, 255, 255, 0.05);
|
| 81 |
+
--banner-gradient: linear-gradient(135deg, #020617 0%, #4c1d95 100%);
|
| 82 |
+
}
|
| 83 |
+
|
| 84 |
+
/* 4. Theme: Emerald Mission (Operations Green) */
|
| 85 |
+
.theme-emerald {
|
| 86 |
+
--bg-dark: #022c22;
|
| 87 |
+
--bg-card: #064e3b;
|
| 88 |
+
--bg-hover: #065f46;
|
| 89 |
+
--bg-panel: rgba(52, 211, 153, 0.05);
|
| 90 |
+
--bg-popover: #022c22;
|
| 91 |
+
--primary: #10b981;
|
| 92 |
+
--primary-light: #6ee7b7;
|
| 93 |
+
--primary-glow: rgba(16, 185, 129, 0.2);
|
| 94 |
+
--secondary: #059669;
|
| 95 |
+
--text-main: #ecfdf5;
|
| 96 |
+
--text-muted: #a7f3d0;
|
| 97 |
+
--text-dim: #34d399;
|
| 98 |
+
--text-inverse: #022c22;
|
| 99 |
+
--border-subtle: #065f46;
|
| 100 |
+
--border-hi: #059669;
|
| 101 |
+
--glass-bg: rgba(2, 44, 34, 0.9);
|
| 102 |
+
--glass-border: rgba(255, 255, 255, 0.1);
|
| 103 |
+
--banner-gradient: linear-gradient(135deg, #064e3b 0%, #10b981 100%);
|
| 104 |
}
|
| 105 |
|
| 106 |
/* Premium Selection & Scrollbars */
|
|
|
|
| 189 |
from { opacity: 0; transform: translateY(10px); }
|
| 190 |
to { opacity: 1; transform: translateY(0); }
|
| 191 |
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|