Splits the 2571-line cassandra.css into ten focused stylesheets: tokens (palette + fonts), layout (chrome), panels, dashboard, portfolio, log-chat, auth, settings, news, public. base.html and public_base.html load only what they need; auth pages (login, verify, unsubscribe confirm) load tokens + layout + auth. Brand drift-detection test repointed at tokens.css (where the palette now lives). 291 tests still pass.
185 lines
5 KiB
CSS
185 lines
5 KiB
CSS
/* Cassandra — structural layout: html/body, app shell, header, main grid,
|
|
* sticky markets bar, scrollbar. */
|
|
|
|
html, body {
|
|
margin: 0;
|
|
padding: 0;
|
|
background: var(--bg);
|
|
color: var(--text);
|
|
font-family: var(--font-mono);
|
|
font-size: 13px;
|
|
line-height: 1.5;
|
|
font-variant-numeric: tabular-nums;
|
|
}
|
|
|
|
a { color: var(--accent); text-decoration: none; }
|
|
a:hover { text-decoration: underline; }
|
|
|
|
/* --- Layout ---------------------------------------------------------- */
|
|
|
|
.app {
|
|
display: grid;
|
|
grid-template-columns: 1fr;
|
|
grid-template-rows: auto 1fr auto;
|
|
min-height: 100vh;
|
|
}
|
|
|
|
.app-header {
|
|
display: flex;
|
|
align-items: center;
|
|
justify-content: space-between;
|
|
border-bottom: 1px solid var(--border);
|
|
padding: 10px 18px;
|
|
background: var(--surface);
|
|
letter-spacing: 0.08em;
|
|
text-transform: uppercase;
|
|
position: sticky;
|
|
top: 0;
|
|
z-index: 50;
|
|
}
|
|
.app-header .brand {
|
|
color: var(--accent);
|
|
font-weight: 700;
|
|
text-decoration: none;
|
|
}
|
|
.app-header .brand:hover { color: var(--text); }
|
|
.app-header .brand::before { content: "▰ "; opacity: 0.6; }
|
|
.app-header nav a {
|
|
margin-left: 18px;
|
|
color: var(--muted);
|
|
}
|
|
.app-header nav a.active { color: var(--text); }
|
|
.app-header .meta { color: var(--muted); font-size: 11px; }
|
|
|
|
.app-header .header-right { display: flex; align-items: center; gap: 14px; }
|
|
.theme-toggle {
|
|
background: transparent;
|
|
border: 1px solid var(--border);
|
|
color: var(--muted);
|
|
padding: 3px 8px;
|
|
font-family: var(--font-mono);
|
|
font-size: 10px;
|
|
letter-spacing: 0.08em;
|
|
cursor: pointer;
|
|
text-transform: lowercase;
|
|
}
|
|
.theme-toggle:hover { color: var(--accent); border-color: var(--accent); }
|
|
.theme-toggle__label::before { content: "◐ light"; }
|
|
[data-theme="dark"] .theme-toggle__label::before { content: "◐ dark"; }
|
|
|
|
/* Tone toggle (segmented control: Novice | Intermediate) */
|
|
.tone-toggle {
|
|
display: inline-flex;
|
|
border: 1px solid var(--border);
|
|
font-family: var(--font-mono);
|
|
font-size: 10.5px;
|
|
letter-spacing: 0.06em;
|
|
text-transform: uppercase;
|
|
}
|
|
.tone-toggle button {
|
|
background: transparent;
|
|
color: var(--muted);
|
|
border: 0;
|
|
padding: 4px 10px;
|
|
cursor: pointer;
|
|
font: inherit;
|
|
letter-spacing: inherit;
|
|
text-transform: inherit;
|
|
}
|
|
.tone-toggle button + button { border-left: 1px solid var(--border); }
|
|
.tone-toggle button:hover { color: var(--accent); }
|
|
.tone-toggle[data-tone="NOVICE"] button[data-value="NOVICE"],
|
|
.tone-toggle[data-tone="INTERMEDIATE"] button[data-value="INTERMEDIATE"] {
|
|
background: var(--accent);
|
|
color: var(--bg);
|
|
}
|
|
|
|
/* Language toggle in the topbar — same visual rhythm as the tone
|
|
* toggle so the two controls read as a pair. Only EN and IT are
|
|
* visible here; the WIP languages (ES/FR/DE) live in /settings. */
|
|
.lang-toggle {
|
|
display: inline-flex;
|
|
border: 1px solid var(--border);
|
|
font-family: var(--font-mono);
|
|
font-size: 10.5px;
|
|
letter-spacing: 0.06em;
|
|
text-transform: uppercase;
|
|
}
|
|
.lang-toggle button {
|
|
background: transparent;
|
|
color: var(--muted);
|
|
border: 0;
|
|
padding: 4px 8px;
|
|
cursor: pointer;
|
|
font: inherit;
|
|
letter-spacing: inherit;
|
|
text-transform: inherit;
|
|
}
|
|
.lang-toggle button + button { border-left: 1px solid var(--border); }
|
|
.lang-toggle button:hover { color: var(--accent); }
|
|
.lang-toggle[data-lang="en"] button[data-value="en"],
|
|
.lang-toggle[data-lang="it"] button[data-value="it"] {
|
|
background: var(--accent);
|
|
color: var(--bg);
|
|
}
|
|
|
|
.app-main {
|
|
padding: 14px;
|
|
display: grid;
|
|
grid-template-columns: minmax(0, 2fr) minmax(0, 1fr);
|
|
grid-template-rows: auto auto auto auto;
|
|
grid-template-areas:
|
|
"header header"
|
|
"indicators log"
|
|
"portfolio log"
|
|
"news news";
|
|
gap: 14px;
|
|
}
|
|
@media (max-width: 1100px) {
|
|
.app-main {
|
|
grid-template-columns: 1fr;
|
|
grid-template-areas: "header" "indicators" "portfolio" "log" "news";
|
|
}
|
|
}
|
|
|
|
#dash-header-container { grid-area: header; }
|
|
#indicators-panel { grid-area: indicators; }
|
|
#portfolio-panel { grid-area: portfolio; }
|
|
#log-panel {
|
|
grid-area: log;
|
|
/* Don't stretch to fill both grid rows; if the log is shorter than
|
|
the portfolio next to it, the surplus below would render as a big
|
|
empty white box. Aligning to the start makes the panel shrink to
|
|
its content and the dashboard background fills any gap. */
|
|
align-self: start;
|
|
}
|
|
#news-panel { grid-area: news; }
|
|
|
|
|
|
/* Sticky bottom markets bar — uses the same .mkt chip styling as the
|
|
old dashboard header, extended with each market's headline index. */
|
|
.markets-bar {
|
|
position: sticky;
|
|
bottom: 0;
|
|
z-index: 50;
|
|
background: var(--surface);
|
|
border-top: 1px solid var(--border);
|
|
}
|
|
.markets-bar__inner {
|
|
display: grid;
|
|
grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
|
|
gap: 1px;
|
|
background: var(--border);
|
|
border: 0;
|
|
}
|
|
.markets-bar .mkt {
|
|
border: 0;
|
|
border-radius: 0;
|
|
}
|
|
|
|
/* --- Scrollbar -------------------------------------------------------- */
|
|
|
|
::-webkit-scrollbar { width: 8px; height: 8px; }
|
|
::-webkit-scrollbar-track { background: var(--bg); }
|
|
::-webkit-scrollbar-thumb { background: var(--dim); border-radius: 0; }
|
|
::-webkit-scrollbar-thumb:hover { background: var(--muted); }
|