305 lines
6.5 KiB
CSS
305 lines
6.5 KiB
CSS
/* Theme mirrors python_app/gui/theme.py (light Fusion palette). */
|
|
:root {
|
|
--bg: #f3f6fb;
|
|
--panel: #ffffff;
|
|
--panel-alt: #fbfdff;
|
|
--border: #c9d4e1;
|
|
--border-soft: #d7dee8;
|
|
--text: #1f2937;
|
|
--muted: #6c7b8d;
|
|
--status: #35507a;
|
|
--accent: #2f7ee6;
|
|
--accent-hover: #3b8bf4;
|
|
--btn-bg: #f8fafc;
|
|
--btn-hover: #eef3f9;
|
|
--btn-press: #e4ebf4;
|
|
--disabled-text: #98a4b3;
|
|
--disabled-bg: #f3f5f8;
|
|
--danger: #f94144;
|
|
--mono: "DejaVu Sans Mono", ui-monospace, monospace;
|
|
--sans: "Segoe UI", system-ui, sans-serif;
|
|
}
|
|
|
|
* { box-sizing: border-box; }
|
|
|
|
html, body {
|
|
margin: 0;
|
|
height: 100%;
|
|
background: var(--bg);
|
|
color: var(--text);
|
|
font-family: var(--sans);
|
|
font-size: 13px;
|
|
}
|
|
|
|
body {
|
|
display: flex;
|
|
flex-direction: column;
|
|
height: 100vh;
|
|
overflow: hidden;
|
|
}
|
|
|
|
/* Top bar */
|
|
.topbar {
|
|
display: flex;
|
|
align-items: center;
|
|
justify-content: space-between;
|
|
padding: 10px 16px;
|
|
background: var(--panel);
|
|
border-bottom: 1px solid var(--border-soft);
|
|
gap: 12px;
|
|
}
|
|
|
|
.brand {
|
|
font-weight: 700;
|
|
font-size: 15px;
|
|
color: var(--status);
|
|
letter-spacing: 0.2px;
|
|
}
|
|
|
|
.controls { display: flex; gap: 8px; flex-wrap: wrap; }
|
|
|
|
/* Buttons */
|
|
.btn {
|
|
background: var(--btn-bg);
|
|
border: 1px solid var(--border);
|
|
border-radius: 8px;
|
|
padding: 7px 12px;
|
|
color: var(--text);
|
|
font-size: 13px;
|
|
font-family: inherit;
|
|
cursor: pointer;
|
|
transition: background 0.12s ease, border-color 0.12s ease;
|
|
}
|
|
.btn:hover:not(:disabled) { background: var(--btn-hover); }
|
|
.btn:active:not(:disabled) { background: var(--btn-press); }
|
|
.btn.primary {
|
|
background: var(--accent);
|
|
border-color: var(--accent);
|
|
color: #ffffff;
|
|
}
|
|
.btn.primary:hover:not(:disabled) { background: var(--accent-hover); }
|
|
.btn:disabled {
|
|
color: var(--disabled-text);
|
|
background: var(--disabled-bg);
|
|
border-color: var(--border-soft);
|
|
cursor: not-allowed;
|
|
}
|
|
|
|
/* Layout */
|
|
.layout {
|
|
flex: 1;
|
|
display: flex;
|
|
min-height: 0;
|
|
padding: 14px;
|
|
gap: 14px;
|
|
}
|
|
|
|
/* Plot */
|
|
.plot-panel {
|
|
flex: 1;
|
|
display: flex;
|
|
flex-direction: column;
|
|
min-width: 0;
|
|
background: var(--panel);
|
|
border: 1px solid var(--border-soft);
|
|
border-radius: 10px;
|
|
padding: 10px;
|
|
}
|
|
.plot-head {
|
|
display: flex;
|
|
align-items: baseline;
|
|
justify-content: space-between;
|
|
margin-bottom: 8px;
|
|
}
|
|
.plot-title { font-weight: 600; color: var(--status); }
|
|
.axes-label { color: var(--muted); font-family: var(--mono); font-size: 12px; }
|
|
.canvas-wrap {
|
|
flex: 1;
|
|
min-height: 0;
|
|
border: 1px solid var(--border);
|
|
border-radius: 8px;
|
|
background: #0f141c; /* matches the pyqtgraph plot background behind letterboxing */
|
|
overflow: hidden;
|
|
}
|
|
#plot { display: block; width: 100%; height: 100%; object-fit: contain; }
|
|
|
|
/* Side panel */
|
|
.side-panel {
|
|
width: 340px;
|
|
flex-shrink: 0;
|
|
display: flex;
|
|
flex-direction: column;
|
|
background: var(--panel);
|
|
border: 1px solid var(--border-soft);
|
|
border-radius: 10px;
|
|
overflow: hidden;
|
|
}
|
|
.panel-head {
|
|
display: flex;
|
|
align-items: center;
|
|
justify-content: space-between;
|
|
padding: 10px 12px;
|
|
cursor: pointer;
|
|
user-select: none;
|
|
border-bottom: 1px solid var(--border-soft);
|
|
}
|
|
.panel-title { font-weight: 600; color: var(--status); }
|
|
.chevron { color: var(--muted); transition: transform 0.15s ease; }
|
|
.side-panel.collapsed .chevron { transform: rotate(-90deg); }
|
|
.panel-body {
|
|
flex: 1;
|
|
min-height: 0;
|
|
display: flex;
|
|
flex-direction: column;
|
|
overflow: hidden;
|
|
}
|
|
.side-panel.collapsed .panel-body { display: none; }
|
|
|
|
.settings-fields {
|
|
flex: 1;
|
|
min-height: 0;
|
|
overflow-y: auto;
|
|
padding: 8px 12px;
|
|
}
|
|
.group-title {
|
|
margin: 12px 0 6px;
|
|
font-size: 11px;
|
|
text-transform: uppercase;
|
|
letter-spacing: 0.6px;
|
|
color: var(--muted);
|
|
font-weight: 700;
|
|
}
|
|
.group-title:first-child { margin-top: 4px; }
|
|
|
|
.field {
|
|
display: flex;
|
|
align-items: center;
|
|
justify-content: space-between;
|
|
gap: 8px;
|
|
padding: 3px 0;
|
|
}
|
|
.field label {
|
|
flex: 1;
|
|
font-size: 12px;
|
|
color: var(--text);
|
|
word-break: break-word;
|
|
}
|
|
.field input[type="text"],
|
|
.field input[type="number"],
|
|
.field select {
|
|
width: 140px;
|
|
flex-shrink: 0;
|
|
background: var(--panel);
|
|
border: 1px solid var(--border);
|
|
border-radius: 7px;
|
|
padding: 4px 7px;
|
|
color: var(--text);
|
|
font-family: var(--mono);
|
|
font-size: 12px;
|
|
}
|
|
.field input:focus,
|
|
.field select:focus {
|
|
outline: none;
|
|
border-color: var(--accent);
|
|
}
|
|
.field input[type="checkbox"] {
|
|
width: 16px;
|
|
height: 16px;
|
|
flex-shrink: 0;
|
|
accent-color: var(--accent);
|
|
}
|
|
.field textarea {
|
|
width: 160px;
|
|
flex-shrink: 0;
|
|
min-height: 52px;
|
|
resize: vertical;
|
|
background: var(--panel);
|
|
border: 1px solid var(--border);
|
|
border-radius: 7px;
|
|
padding: 4px 7px;
|
|
color: var(--text);
|
|
font-family: var(--mono);
|
|
font-size: 12px;
|
|
}
|
|
.field textarea:focus { outline: none; border-color: var(--accent); }
|
|
.on-start-hint { color: var(--muted); font-size: 11px; font-style: italic; }
|
|
|
|
.settings-actions {
|
|
display: flex;
|
|
gap: 8px;
|
|
padding: 10px 12px;
|
|
border-top: 1px solid var(--border-soft);
|
|
}
|
|
.settings-actions .btn { flex: 1; }
|
|
.note {
|
|
padding: 0 12px 10px;
|
|
color: var(--muted);
|
|
font-size: 11px;
|
|
min-height: 14px;
|
|
}
|
|
|
|
/* Status bar */
|
|
.statusbar {
|
|
display: flex;
|
|
gap: 18px;
|
|
align-items: center;
|
|
padding: 7px 16px;
|
|
background: var(--panel);
|
|
border-top: 1px solid var(--border-soft);
|
|
font-family: var(--mono);
|
|
font-size: 12px;
|
|
color: var(--status);
|
|
flex-wrap: wrap;
|
|
}
|
|
.stat b { color: var(--text); font-weight: 600; }
|
|
.stat.ok b { color: #1b7a3d; }
|
|
.stat.off b { color: var(--muted); }
|
|
#stat-stale {
|
|
margin-left: auto;
|
|
padding: 2px 9px;
|
|
border-radius: 999px;
|
|
background: #e4f0e6;
|
|
color: #1b7a3d;
|
|
font-weight: 600;
|
|
}
|
|
#stat-stale.stale {
|
|
background: #fde2e3;
|
|
color: var(--danger);
|
|
}
|
|
|
|
/* Toast */
|
|
.toast {
|
|
position: fixed;
|
|
bottom: 56px;
|
|
left: 50%;
|
|
transform: translateX(-50%) translateY(20px);
|
|
background: var(--status);
|
|
color: #ffffff;
|
|
padding: 9px 16px;
|
|
border-radius: 8px;
|
|
font-size: 13px;
|
|
opacity: 0;
|
|
pointer-events: none;
|
|
transition: opacity 0.2s ease, transform 0.2s ease;
|
|
max-width: 70vw;
|
|
}
|
|
.toast.show {
|
|
opacity: 1;
|
|
transform: translateX(-50%) translateY(0);
|
|
}
|
|
.toast.error { background: var(--danger); }
|
|
|
|
/* Narrow screens / phones: stack the plot above the settings, full-width controls. */
|
|
@media (max-width: 760px) {
|
|
.topbar { flex-wrap: wrap; }
|
|
.controls { width: 100%; }
|
|
.controls .btn { flex: 1 1 auto; }
|
|
.layout { flex-direction: column; padding: 10px; gap: 10px; }
|
|
.plot-panel { flex: none; height: 45vh; }
|
|
.side-panel { width: auto; flex: 1; min-height: 0; }
|
|
.field input[type="text"],
|
|
.field input[type="number"],
|
|
.field select { width: 130px; }
|
|
.statusbar { gap: 12px; }
|
|
}
|