runloopable / web /src /styles /sdlc81 /dashboard-kit.css
fsanyoto's picture
Deploy AIOS web (React glide grid + FastAPI slice)
8133df9 verified
Raw History Blame Contribute Delete
8.01 kB
.lp-dashboard, .lp-chart, .lp-kpi, .lp-app-tabs {
--lp-chart-navy: var(--lp-freeze-navy);
--lp-chart-gold: var(--lp-freeze-gold);
--lp-heatmap-navy: var(--lp-chart-navy);
--lp-heatmap-gold: var(--lp-freeze-gold);
--lp-heatmap-zero: var(--lp-surface-2);
--lp-heatmap-ink: rgb(from var(--lp-ink) calc(r / 8) calc(g / 8) calc(b / 8));
color: var(--lp-ink);
font-family: var(--lp-font, Inter, sans-serif);
font-size: var(--lp-fs-sm);
font-variant-numeric: tabular-nums;
}
.lp-dashboard { display: flex; flex-direction: column; gap: var(--lp-section-gap); min-width: 0; max-width: 100%; box-sizing: border-box; }
.lp-app-tabs { display: flex; align-items: stretch; gap: 24px; border-bottom: 1px solid var(--lp-line); overflow-x: auto; }
.lp-app-tabs button { appearance: none; border: 0; border-bottom: 2px solid transparent; background: transparent; color: var(--lp-muted); font: inherit; padding: 12px 0; white-space: nowrap; cursor: pointer; }
.lp-app-tabs button[aria-selected="true"] { color: var(--lp-chart-navy); border-bottom-color: var(--lp-chart-navy); font-weight: var(--lp-fw-semibold); }
.lp-app-tab-count { margin-left: 8px; font-size: var(--lp-fs-xs); }
.lp-app-tabs button:focus-visible, .lp-kpi:focus-visible, .lp-chart-source:focus-visible, .lp-chart-table summary:focus-visible { outline: 2px solid var(--lp-blue-deep); outline-offset: 3px; }
.lp-kpi-strip { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 190px), 1fr)); gap: 16px; }
.lp-kpi-row[data-row="headline"] .lp-kpi-strip { grid-template-columns: none; grid-auto-flow: column; grid-auto-columns: minmax(min(100%, 190px), 1fr); overflow-x: auto; }
.lp-kpi-strip > div { display: flex; min-width: 0; }
.lp-kpi-strip > [data-figure] { container: kpi-slot / inline-size; }
.lp-kpi { display: flex; flex: 1; flex-direction: column; align-items: flex-start; gap: 8px; text-align: left; background: var(--lp-surface); border: 1px solid var(--lp-line); border-radius: var(--lp-r-md); padding: 20px; min-width: 0; box-sizing: border-box; container: kpi-tile / inline-size; }
@container kpi-slot (max-width: 220px) {
.lp-kpi-strip .lp-kpi { padding-inline: 8px; }
}
button.lp-kpi { cursor: pointer; }
.lp-kpi-label { font-size: var(--lp-fs-sm); color: var(--lp-muted); }
.lp-kpi-value { font-size: var(--lp-fs-xl); font-weight: var(--lp-fw-semibold); line-height: 1.25; white-space: nowrap; }
.lp-kpi-change, .lp-kpi-period { font-size: var(--lp-fs-xs); color: var(--lp-muted); }
.lp-kpi-period { white-space: nowrap; }
@container kpi-tile (max-width: 280px) {
.lp-kpi-value { font-size: var(--lp-fs-lg); }
}
@container kpi-tile (max-width: 200px) {
.lp-kpi-value { font-size: var(--lp-fs-md); }
.lp-kpi-period { font-size: var(--lp-fs-2xs); }
}
.lp-kpi-change[data-sign="up"] { color: var(--lp-green-deep); background: var(--lp-green-tint); }
.lp-kpi-change[data-sign="down"] { color: var(--lp-red-deep); background: var(--lp-red-tint); }
.lp-dashboard-period { padding: 0; flex-wrap: wrap; gap: 16px; }
.lp-dashboard-period label { gap: 8px; }
.lp-dashboard-period input { color: var(--lp-ink); background: var(--lp-surface); font: inherit; border: 1px solid var(--lp-line); border-radius: var(--lp-r-sm); padding: 8px; min-height: 36px; box-sizing: border-box; }
.lp-dashboard-period input:focus-visible { outline: 2px solid var(--lp-blue-deep); outline-offset: 2px; }
.lp-dashboard-loading { display: grid; place-items: center; min-height: 280px; }
.lp-dashboard-chart { position: relative; min-width: 0; }
.lp-chart { margin: 0; padding: 20px; border: 1px solid var(--lp-line); border-radius: var(--lp-r-md); background: var(--lp-surface); overflow: hidden; }
.lp-chart figcaption { display: flex; justify-content: space-between; gap: 16px; font-size: var(--lp-fs-md); font-weight: var(--lp-fw-semibold); margin-bottom: 16px; }
.lp-chart-unit, .lp-chart-context { color: var(--lp-muted); font-size: var(--lp-fs-xs); font-weight: normal; }
.lp-chart-comparison { display: flex; flex-wrap: wrap; align-items: baseline; gap: 8px; margin-bottom: 8px; }
.lp-chart svg { width: 100%; height: auto; display: block; overflow: visible; }
.lp-chart-plot { overflow-x: auto; }
.lp-chart-plot:focus-visible { outline: 2px solid var(--lp-blue-deep); outline-offset: 2px; }
.lp-chart-plot svg { min-width: 640px; }
.lp-chart-axis line { stroke: var(--lp-line); stroke-width: 1; }
.lp-chart-axis text, .lp-chart-tick { fill: var(--lp-muted); font-size: var(--lp-fs-2xs); }
.lp-chart-navy { --lp-series-color: var(--lp-chart-navy); }
.lp-chart-gold { --lp-series-color: var(--lp-chart-gold); }
.lp-chart-series polyline { fill: none; stroke: var(--lp-series-color); stroke-width: 2.5; stroke-linejoin: round; }
.lp-chart-series circle, .lp-chart-series rect { fill: var(--lp-series-color); }
.lp-chart-series polygon { fill: var(--lp-series-color); fill-opacity: 0.2; stroke: var(--lp-series-color); stroke-width: 1.5; }
.lp-chart-direct { fill: var(--lp-ink); font-size: var(--lp-fs-2xs); }
.lp-heatmap-cell .lp-chart-direct { fill: var(--lp-heatmap-ink); }
.lp-heatmap-cell[data-heat-dark="true"] .lp-chart-direct { fill: var(--lp-surface); }
.lp-chart-legend { list-style: none; padding: 0; margin: 8px 0; display: flex; flex-wrap: wrap; gap: 16px; font-size: var(--lp-fs-xs); }
.lp-chart-legend li { display: flex; align-items: center; gap: 8px; }
.lp-chart-legend span { display: block; width: 10px; height: 10px; background: var(--lp-series-color); border-radius: 2px; }
.lp-heatmap-negative { --lp-series-color: var(--lp-heatmap-navy); }
.lp-heatmap-zero { --lp-series-color: var(--lp-heatmap-zero); }
.lp-heatmap-positive { --lp-series-color: var(--lp-heatmap-gold); }
.lp-heatmap-sequential span { background: linear-gradient(to right, var(--lp-heatmap-zero), var(--lp-heatmap-navy)); width: 32px; }
.lp-chart-table { margin-top: 16px; font-size: var(--lp-fs-xs); overflow-x: auto; }
.lp-chart-table summary { color: var(--lp-muted); cursor: pointer; width: fit-content; }
.lp-chart-table table { width: 100%; border-collapse: collapse; margin-top: 12px; }
.lp-chart-table td, .lp-chart-table th { border-bottom: 1px solid var(--lp-line); padding: 8px; text-align: left; font-weight: normal; }
.lp-chart-table td:last-child { text-align: right; }
.lp-chart-table tr[data-selected="true"] { background: var(--lp-blue-tint); }
.lp-chart-source { color: var(--lp-chart-navy); background: var(--lp-surface); border: 1px solid var(--lp-line); border-radius: var(--lp-r-sm); padding: 8px 12px; margin-top: 8px; font: inherit; cursor: pointer; }
.lp-figure-reason { color: var(--lp-muted); font-size: var(--lp-fs-sm); margin: 0; line-height: 1.5; }
.lp-figure-fold { color: var(--lp-muted); font-size: var(--lp-fs-sm); }
.lp-figure-fold summary { width: fit-content; cursor: pointer; list-style: none; display: flex; align-items: center; gap: 8px; border-radius: var(--lp-r-sm); }
.lp-figure-fold summary::-webkit-details-marker { display: none; }
.lp-figure-fold summary::before { content: ""; width: 6px; height: 6px; border-right: 1.5px solid currentColor; border-bottom: 1.5px solid currentColor; transform: rotate(-45deg); transition: transform var(--lp-motion-feedback-duration) var(--lp-motion-feedback-easing); }
.lp-figure-fold[open] summary::before { transform: rotate(45deg); }
.lp-figure-fold summary:focus-visible { outline: 2px solid var(--lp-blue-deep); outline-offset: 3px; }
.lp-figure-fold ul { list-style: none; margin: 8px 0 0; padding: 0; display: grid; gap: 4px; }
.lp-figure-fold li { line-height: 1.5; }
.lp-figure-fold-label { color: var(--lp-ink); }
@media (prefers-reduced-motion: reduce) { .lp-figure-fold summary::before { transition: none; } }
@media (max-width: 600px) {
.lp-kpi, .lp-chart { padding: 12px; }
.lp-dashboard-period { align-items: flex-start; }
}
@media (hover: hover) and (pointer: fine) {
.lp-app-tabs button:hover, .lp-chart-source:hover, button.lp-kpi:hover { background: var(--lp-wash); }
.lp-figure-fold summary:hover { color: var(--lp-ink); }
}