Open raw ↗/* Reference UI — mobile-first, fluid, fills any screen (the pattern GOV-B7 mandates
and the fix model for the Dashboard/Help-Hub alignment defect DEF-093):
no fixed page width; one fluid grid; a wide-screen content cap that CENTERS;
tables and threads scroll horizontally INSIDE their boxes, never the page. */
:root {
--bg: #0f1117;
--panel: #171a23;
--line: #262b38;
--text: #e8eaf0;
--muted: #9aa3b5;
--accent: #4f8cff;
--accent-ink: #ffffff;
--danger: #ff6b6b;
--me: #24406e;
}
* { box-sizing: border-box; }
html, body {
margin: 0;
min-height: 100%;
background: var(--bg);
color: var(--text);
font: 16px/1.55 system-ui, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}
.shell {
display: grid;
grid-template-rows: 1fr;
min-height: 100dvh; /* fills the full screen on phone and desktop */
padding: clamp(12px, 3vw, 32px);
}
.panel {
width: min(100%, 26rem); /* centered, never overflows */
margin: auto;
background: var(--panel);
border: 1px solid var(--line);
border-radius: 14px;
padding: clamp(18px, 4vw, 32px);
}
h1 { font-size: clamp(1.15rem, 4vw, 1.5rem); margin: 0 0 .25rem; }
.sub { color: var(--muted); margin: 0 0 1.25rem; font-size: .9rem; }
.stack { display: grid; gap: .5rem; }
.stack label { font-size: .85rem; color: var(--muted); }
input, textarea, button {
font: inherit;
color: inherit;
background: var(--bg);
border: 1px solid var(--line);
border-radius: 8px;
padding: .6rem .75rem;
width: 100%;
}
textarea { resize: vertical; min-height: 2.6rem; }
button { cursor: pointer; width: auto; }
.primary { background: var(--accent); color: var(--accent-ink); border-color: var(--accent); font-weight: 600; }
.ghost { background: transparent; color: var(--muted); }
button:hover { filter: brightness(1.1); }
.error { color: var(--danger); font-size: .9rem; }
/* chat layout: fluid rows, full height */
#chat-view {
display: grid;
grid-template-rows: auto 1fr auto auto;
gap: .75rem;
min-height: 100dvh;
max-width: 64rem; /* a reading cap on ultrawide screens … */
margin-inline: auto; /* … that CENTERS instead of hugging the left */
}
.bar {
display: flex;
align-items: center;
justify-content: space-between;
gap: .75rem;
flex-wrap: wrap; /* narrow screens wrap instead of overflow */
background: var(--panel);
border: 1px solid var(--line);
border-radius: 12px;
padding: .6rem .9rem;
}
.bar-right { display: flex; align-items: center; gap: .6rem; }
.engine { color: var(--muted); font-size: .8rem; border: 1px solid var(--line); border-radius: 999px; padding: .1rem .6rem; }
.thread {
list-style: none;
margin: 0;
padding: .9rem;
background: var(--panel);
border: 1px solid var(--line);
border-radius: 12px;
overflow: auto; /* long content scrolls HERE, not the page */
display: grid;
gap: .6rem;
align-content: start;
overflow-wrap: anywhere; /* long tokens never push the layout wide */
}
.thread li { max-width: 92%; border-radius: 10px; padding: .5rem .8rem; background: var(--bg); }
.thread li.me { background: var(--me); justify-self: end; }
.thread li.engine { justify-self: start; }
.composer { display: grid; grid-template-columns: 1fr auto; gap: .5rem; align-items: end; }
.composer textarea { min-height: 2.8rem; }
@media (max-width: 30rem) { /* phones: single-column composer */
.composer { grid-template-columns: 1fr; }
.composer .primary { width: 100%; }
.thread li { max-width: 100%; }
}
@media (prefers-reduced-motion: reduce) {
* { transition: none !important; animation: none !important; }
}