Files
inventory/templates/assets/css/index.css
Nathan Woodburn 0ce79935d7
All checks were successful
Check Code Quality / RuffCheck (push) Successful in 1m4s
Build Docker / BuildImage (push) Successful in 1m26s
feat: Initial code
2026-03-26 23:07:05 +11:00

344 lines
5.5 KiB
CSS

:root {
--bg: #0e1117;
--panel: #171b23;
--ink: #e6edf3;
--muted: #9aa6b2;
--line: #2d3748;
--accent: #2f81f7;
--good: #2ea043;
--bad: #f85149;
--warn: #d29922;
}
* {
box-sizing: border-box;
}
body {
margin: 0;
font-family: "IBM Plex Sans", "Segoe UI", sans-serif;
color: var(--ink);
background:
radial-gradient(1200px 600px at 5% -10%, #1f2937 0%, transparent 65%),
radial-gradient(1000px 500px at 95% 0%, #102a43 0%, transparent 55%),
var(--bg);
}
.dashboard {
max-width: 1240px;
margin: 0 auto;
padding: 2rem 1rem 3rem;
}
.hero {
display: flex;
justify-content: space-between;
align-items: end;
gap: 1rem;
margin-bottom: 1.25rem;
}
h1 {
margin: 0;
font-family: "Space Grotesk", "IBM Plex Sans", sans-serif;
font-size: clamp(1.9rem, 4.5vw, 2.9rem);
}
.subtitle,
.meta {
margin: 0.2rem 0;
color: var(--muted);
}
.hero-actions {
display: flex;
flex-direction: column;
align-items: end;
gap: 0.5rem;
}
button {
border: none;
border-radius: 999px;
padding: 0.65rem 1rem;
background: var(--accent);
color: #ffffff;
font-weight: 700;
cursor: pointer;
}
button:disabled {
opacity: 0.7;
cursor: wait;
}
.stats-grid {
display: grid;
grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
gap: 0.75rem;
margin-bottom: 0.9rem;
}
.stat-card,
.panel,
.topology-card,
.source-card {
background: color-mix(in srgb, var(--panel) 95%, #000000);
border: 1px solid var(--line);
border-radius: 14px;
}
.stat-card {
padding: 0.85rem;
}
.stat-card span {
color: var(--muted);
font-size: 0.85rem;
}
.stat-card strong {
display: block;
font-size: 1.6rem;
}
.panel {
padding: 0.95rem;
margin-top: 0.9rem;
}
.panel h2 {
margin: 0 0 0.8rem;
font-size: 1.1rem;
}
.topology-grid {
display: grid;
grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
gap: 0.7rem;
}
.topology-card,
.source-card {
padding: 0.75rem;
}
.topology-card h3,
.source-card h3 {
margin: 0 0 0.35rem;
font-size: 1rem;
}
.topology-card p,
.source-card p {
margin: 0.2rem 0;
color: var(--muted);
font-size: 0.9rem;
}
.source-list {
display: grid;
grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
gap: 0.7rem;
}
.source-card {
display: flex;
justify-content: space-between;
align-items: center;
gap: 0.8rem;
}
.panel-header {
display: flex;
justify-content: space-between;
align-items: center;
gap: 0.8rem;
flex-wrap: wrap;
}
.filters {
display: flex;
gap: 0.5rem;
flex-wrap: wrap;
}
input,
select {
border: 1px solid var(--line);
border-radius: 8px;
padding: 0.5rem 0.55rem;
background: #0f141b;
color: var(--ink);
}
input {
min-width: 220px;
}
.table-wrap {
overflow-x: auto;
margin-top: 0.7rem;
}
table {
width: 100%;
border-collapse: collapse;
min-width: 720px;
}
thead th {
text-align: left;
font-weight: 700;
color: var(--muted);
border-bottom: 1px solid var(--line);
padding: 0.5rem;
}
tbody td {
border-bottom: 1px solid #202734;
padding: 0.56rem;
font-size: 0.93rem;
}
.asset-row {
cursor: pointer;
}
.asset-row:hover td {
background: #1a2230;
}
.status-badge {
border-radius: 999px;
padding: 0.2rem 0.55rem;
font-size: 0.8rem;
font-weight: 700;
text-transform: lowercase;
}
.status-online {
background: color-mix(in srgb, var(--good) 20%, #ffffff);
color: var(--good);
}
.status-offline {
background: color-mix(in srgb, var(--bad) 18%, #ffffff);
color: var(--bad);
}
.status-unknown {
background: color-mix(in srgb, var(--warn) 22%, #ffffff);
color: var(--warn);
}
.empty-state {
color: var(--muted);
}
.hidden {
display: none;
}
.modal {
position: fixed;
inset: 0;
background: rgba(5, 10, 15, 0.72);
display: flex;
align-items: center;
justify-content: center;
z-index: 1000;
padding: 1rem;
}
.modal.hidden {
display: none;
}
.modal-card {
width: min(900px, 100%);
max-height: 88vh;
overflow: auto;
overflow-x: hidden;
background: #111722;
border: 1px solid var(--line);
border-radius: 12px;
padding: 1rem;
}
.modal-header {
display: flex;
justify-content: space-between;
align-items: center;
gap: 1rem;
}
.modal-header h3 {
margin: 0;
}
.modal-body h4 {
margin: 1rem 0 0.4rem;
}
.modal-body {
overflow-wrap: anywhere;
}
.detail-grid {
display: grid;
grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
gap: 0.7rem;
}
.detail-grid div {
background: #151d2b;
border: 1px solid #293547;
border-radius: 8px;
padding: 0.6rem;
display: flex;
flex-direction: column;
gap: 0.2rem;
min-width: 0;
}
.detail-grid strong {
color: var(--muted);
font-size: 0.8rem;
}
.modal pre {
background: #0b111b;
border: 1px solid #243146;
border-radius: 8px;
padding: 0.65rem;
overflow: auto;
color: #c9d7e8;
white-space: pre-wrap;
word-break: break-word;
overflow-wrap: anywhere;
}
table a {
color: #58a6ff;
text-decoration: none;
}
table a:hover {
text-decoration: underline;
}
@media (max-width: 760px) {
.hero {
flex-direction: column;
align-items: flex-start;
}
.hero-actions {
align-items: flex-start;
}
input {
min-width: 100%;
}
}