Turnpike/frontend/src/app.css

211 lines
8.2 KiB
CSS
Raw Normal View History

:root {
--c-bg: #0f1117;
--c-surface: #1a1d27;
--c-border: #2a2d3a;
--c-text: #e2e4ed;
--c-muted: #7a7f96;
--c-accent: #6366f1;
--c-accent-h: #818cf8;
--c-success: #22c55e;
--c-warn: #f59e0b;
--c-danger: #ef4444;
--radius: 6px;
--radius-lg: 10px;
--font: system-ui, -apple-system, sans-serif;
--transition: 150ms ease;
}
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html, body {
height: 100%;
background: var(--c-bg);
color: var(--c-text);
font-family: var(--font);
font-size: 15px;
line-height: 1.5;
-webkit-font-smoothing: antialiased;
}
a { color: var(--c-accent); text-decoration: none; }
a:hover { color: var(--c-accent-h); }
/* Layout */
.layout { display: flex; height: 100vh; overflow: hidden; }
.sidebar {
width: 220px; flex-shrink: 0;
background: var(--c-surface);
border-right: 1px solid var(--c-border);
display: flex; flex-direction: column;
padding: 1.5rem 0;
}
.sidebar-brand {
font-size: 1.1rem; font-weight: 700; letter-spacing: -0.02em;
padding: 0 1.25rem 1.25rem;
border-bottom: 1px solid var(--c-border);
margin-bottom: 0.5rem;
color: var(--c-text);
}
.sidebar-brand span { color: var(--c-accent); }
.nav-link {
display: flex; align-items: center; gap: 0.6rem;
padding: 0.5rem 1.25rem;
color: var(--c-muted); font-size: 0.9rem;
transition: color var(--transition), background var(--transition);
}
.nav-link:hover { color: var(--c-text); background: rgba(255,255,255,0.04); }
.nav-link.active { color: var(--c-text); background: rgba(99,102,241,0.12); }
.main { flex: 1; overflow-y: auto; display: flex; flex-direction: column; }
.page { padding: 2rem; flex: 1; }
.page-header {
display: flex; align-items: center; justify-content: space-between;
margin-bottom: 1.5rem;
}
.page-title { font-size: 1.4rem; font-weight: 700; letter-spacing: -0.02em; }
/* Cards */
.card { background: var(--c-surface); border: 1px solid var(--c-border); border-radius: var(--radius-lg); padding: 1.25rem; }
/* Stats */
.stats { display: grid; grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); gap: 1rem; margin-bottom: 1.5rem; }
.stat { background: var(--c-surface); border: 1px solid var(--c-border); border-radius: var(--radius-lg); padding: 1.1rem 1.25rem; }
.stat-label { font-size: 0.78rem; color: var(--c-muted); text-transform: uppercase; letter-spacing: 0.06em; }
.stat-value { font-size: 2rem; font-weight: 700; margin-top: 0.2rem; letter-spacing: -0.03em; }
/* Buttons */
.btn {
display: inline-flex; align-items: center; gap: 0.4rem;
padding: 0.45rem 1rem; border-radius: var(--radius);
border: 1px solid transparent;
font-size: 0.875rem; font-weight: 500; font-family: var(--font);
cursor: pointer; white-space: nowrap;
transition: background var(--transition), border-color var(--transition), opacity var(--transition);
}
.btn:disabled { opacity: 0.5; cursor: not-allowed; }
.btn-primary { background: var(--c-accent); color: #fff; }
.btn-primary:hover:not(:disabled) { background: var(--c-accent-h); }
.btn-ghost { background: transparent; color: var(--c-muted); border-color: var(--c-border); }
.btn-ghost:hover:not(:disabled) { color: var(--c-text); border-color: var(--c-text); }
.btn-danger { background: transparent; color: var(--c-danger); border-color: var(--c-danger); }
.btn-danger:hover:not(:disabled) { background: var(--c-danger); color: #fff; }
.btn-success { background: var(--c-success); color: #000; font-weight: 600; }
.btn-success:hover:not(:disabled) { filter: brightness(1.1); }
.btn-sm { padding: 0.3rem 0.65rem; font-size: 0.8rem; }
/* Forms */
.form-group { display: flex; flex-direction: column; gap: 0.35rem; margin-bottom: 1rem; }
label { font-size: 0.82rem; color: var(--c-muted); font-weight: 500; }
input, select, textarea {
background: var(--c-bg); border: 1px solid var(--c-border);
border-radius: var(--radius); color: var(--c-text);
font-size: 0.9rem; padding: 0.5rem 0.75rem;
width: 100%; font-family: var(--font);
transition: border-color var(--transition);
}
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--c-accent); }
input::placeholder { color: var(--c-muted); }
/* Search */
.search-bar { display: flex; gap: 0.5rem; align-items: center; margin-bottom: 1rem; }
.search-bar input { max-width: 320px; }
/* Table */
.table-wrap { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; font-size: 0.875rem; }
th {
text-align: left; font-size: 0.75rem; font-weight: 600;
color: var(--c-muted); text-transform: uppercase; letter-spacing: 0.06em;
padding: 0.6rem 1rem; border-bottom: 1px solid var(--c-border);
}
td { padding: 0.75rem 1rem; border-bottom: 1px solid var(--c-border); vertical-align: middle; }
tr:last-child td { border-bottom: none; }
tr:hover td { background: rgba(255,255,255,0.02); }
/* Badges */
.badge {
display: inline-flex; align-items: center;
padding: 0.18rem 0.55rem; border-radius: 99px;
font-size: 0.72rem; font-weight: 600;
text-transform: uppercase; letter-spacing: 0.04em;
}
.badge-checked { background: rgba(34,197,94,0.15); color: var(--c-success); }
.badge-confirmed { background: rgba(99,102,241,0.15); color: var(--c-accent-h); }
.badge-unchecked { background: rgba(122,127,150,0.15); color: var(--c-muted); }
.badge-partial { background: rgba(245,158,11,0.15); color: var(--c-warn); }
.badge-role { background: rgba(99,102,241,0.15); color: var(--c-accent-h); }
.badge-lead { background: rgba(245,158,11,0.15); color: var(--c-warn); }
/* Alerts */
.alert { padding: 0.75rem 1rem; border-radius: var(--radius); font-size: 0.875rem; margin-bottom: 1rem; }
.alert-error { background: rgba(239,68,68,0.12); border: 1px solid rgba(239,68,68,0.3); color: #fca5a5; }
.alert-success { background: rgba(34,197,94,0.12); border: 1px solid rgba(34,197,94,0.3); color: #86efac; }
/* Sync indicator */
.sync-bar {
display: flex; align-items: center; gap: 0.5rem;
padding: 0.5rem 1.25rem; margin-top: auto;
font-size: 0.78rem; color: var(--c-muted);
border-top: 1px solid var(--c-border);
}
.sync-dot { width: 7px; height: 7px; border-radius: 50%; flex-shrink: 0; background: var(--c-muted); }
.sync-dot.online { background: var(--c-success); }
.sync-dot.syncing { background: var(--c-warn); animation: pulse 1s infinite; }
.sync-dot.offline { background: var(--c-danger); }
/* Login */
.login-wrap { min-height: 100vh; display: flex; align-items: center; justify-content: center; }
.login-box { width: 100%; max-width: 380px; }
.login-title { font-size: 1.5rem; font-weight: 700; margin-bottom: 0.25rem; }
.login-sub { color: var(--c-muted); font-size: 0.875rem; margin-bottom: 2rem; }
/* Misc */
.dept-dot { display: inline-block; width: 10px; height: 10px; border-radius: 50%; flex-shrink: 0; }
.empty { text-align: center; padding: 3rem 1rem; color: var(--c-muted); }
.empty p { margin-top: 0.5rem; font-size: 0.875rem; }
.text-muted { color: var(--c-muted); }
.text-success { color: var(--c-success); }
.text-danger { color: var(--c-danger); }
.flex { display: flex; align-items: center; }
.spacer { flex: 1; }
.actions { display: flex; gap: 0.4rem; align-items: center; }
@keyframes pulse { 0%, 100% { opacity: 1; } 50% { opacity: 0.4; } }
2026-03-03 16:09:43 -06:00
/* Mobile header — hidden on desktop */
.mobile-header { display: none; }
@media (max-width: 640px) {
2026-03-03 16:09:43 -06:00
.mobile-header {
display: flex;
align-items: center;
gap: 0.75rem;
padding: 0.75rem 1rem;
background: var(--c-surface);
border-bottom: 1px solid var(--c-border);
}
.mobile-brand { font-weight: 700; font-size: 1rem; }
.mobile-brand .accent { color: var(--c-accent); }
.hamburger {
display: flex; flex-direction: column; gap: 4px;
background: none; border: none; padding: 4px; cursor: pointer;
}
.hamburger span {
display: block; width: 20px; height: 2px;
background: var(--c-text); border-radius: 1px;
transition: transform var(--transition), opacity var(--transition);
}
.sidebar {
position: fixed; top: 0; left: 0; bottom: 0; z-index: 100;
transform: translateX(-100%);
transition: transform 200ms ease;
}
.sidebar.open { transform: translateX(0); }
.nav-overlay {
position: fixed; inset: 0; z-index: 99;
background: rgba(0,0,0,0.5);
}
.page { padding: 1rem; }
.stats { grid-template-columns: repeat(2, 1fr); }
}