@layer base { body { grid-template-rows: auto 1fr auto; } } @layer components { /* neferbar: black bars; one accent block (top left) with a 4-cell stepped fade. The fade is four hard-edged 1ch cells (not a blend): it is the bar's own glyph-grid look. */ .bar { display: flex; align-items: stretch; column-gap: 1ch; height: var(--bar-h); line-height: var(--bar-h); background: var(--bar); color: var(--bar-ink); white-space: nowrap; overflow: hidden; position: sticky; z-index: 20; & a { text-decoration: none; } & a:hover { text-decoration: underline; } & :focus-visible { outline-color: var(--accent); outline-offset: -2px; } & .blk { background: var(--accent); color: var(--on-accent); font-weight: bold; padding: 0 1ch; } & .fade { flex: none; width: 4ch; margin-left: -1ch; background: linear-gradient(to right, var(--fade-1) 0 25%, var(--fade-2) 25% 50%, var(--fade-3) 50% 75%, var(--fade-4) 75%); } } .top { top: 0; & .crumbs ol { display: flex; } & .crumbs li + li::before { content: "/"; color: var(--bar-dim); padding: 0 .5ch; } & .crumbs [aria-current] { color: #fff; font-weight: bold; } & .secs { margin-left: 2ch; overflow: hidden; } & .secs ul { display: flex; } & .secs li + li::before { content: "/"; color: var(--bar-dim); } & .secs a { display: inline-block; padding: 0 1ch; color: var(--bar-dim); } & .secs a:hover { color: var(--bar-ink); } & .secs a::first-letter { text-decoration: underline; } & .secs a[aria-current] { color: #fff; font-weight: bold; } & .secs a[aria-current]::before { content: "▸ "; } & .ref { flex: none; margin-left: auto; padding-right: 1ch; color: #fff; font-weight: bold; } & .ref .sha { font-weight: normal; color: var(--bar-dim); } & .ref:hover { text-decoration: underline; } } .status { bottom: 0; font-size: var(--fs-s); padding: 0 1ch; & > span, & .st-cmd { color: var(--bar-dim); } & .mode { color: #fff; font-weight: bold; } & .st-ctx { color: var(--bar-ink); } & .st-cmd { flex: none; } & .st-cmd .hi, & .st-cmd:hover { color: #fff; font-weight: bold; } & .st-sel { color: var(--bar-ink); } & .st-flash:empty { display: none; } & .st-flash { color: #fff; font-weight: bold; } & .st-hints { margin-left: auto; overflow: hidden; text-overflow: ellipsis; min-width: 0; } & .st-live::before { content: "○ "; } & .st-live[data-state="live"] { color: var(--bar-ink); } & .st-live[data-state="live"]::before { content: "● "; } & .st-owner { flex: none; display: flex; gap: 1ch; } & .st-owner span { color: var(--bar-ink); } & .st-owner button { color: var(--bar-dim); } & .st-owner button:hover { color: #fff; text-decoration: underline; } & .st-pos { min-width: 7ch; text-align: right; color: var(--bar-ink); } } /* work area: content + context rail. Tables and code take the free width and the rail is fixed; on prose pages the text is capped at the reading measure and the rail takes the rest, so no column is idle. */ .work { min-width: 0; } .rail { padding: 0 var(--pad) var(--lh); min-width: 0; } @media (min-width: 1100px) { /* app shell: the bars stay put, the content and the rail scroll on their own, so each column has its scrollbar at its own edge (the README's sits next to the README) */ body { height: 100dvh; overflow: hidden; } .work { display: grid; grid-template-columns: minmax(0, 1fr); min-height: 0; } .work.has-rail { grid-template-columns: minmax(0, 1fr) var(--rail); } .work.has-rail.read { grid-template-columns: minmax(0, calc(var(--measure) + 2 * var(--pad))) minmax(var(--rail), 1fr); } main, .rail { min-height: 0; overflow-y: auto; scrollbar-width: thin; scrollbar-color: var(--rule) transparent; } main:focus { outline: none; } .rail { border-left: 1px solid var(--rule); } :root { --stick: 0px; } } .rail-d > summary { display: none; } @media (max-width: 1099.98px) { /* the rail folds into one line above the content */ .work.has-rail { display: flex; flex-direction: column; } .rail { order: -1; border-bottom: 1px solid var(--rule); padding-bottom: 0; } .rail-d > summary { display: block; list-style: none; color: var(--ink-dim); overflow: hidden; white-space: nowrap; text-overflow: ellipsis; } .rail-d > summary::-webkit-details-marker { display: none; } .rail-d > summary::before { content: "▸ "; color: var(--ink); } .rail-d[open] > summary::before { content: "▾ "; } .rail-d[open] { padding-bottom: var(--lh); } } @media (max-width: 700px) { /* the sections drop to a second bar row instead of being cut off */ .top { flex-wrap: wrap; height: auto; } .top .secs { order: 10; flex-basis: 100%; margin: 0; border-top: 1px solid #202020; } .top .crumbs { flex: 1; min-width: 0; overflow: hidden; } .status .st-hints, .status .st-ctx { display: none; } .list .c-who, .list .c-desc, .list .c-sub, .list .c-ref, .list .c-size, .list .c-lang { display: none; } } /* rail blocks: a dim title rule, then key/value rows on the character grid */ .rail section { margin-top: var(--lh); } .rail h2 { display: flex; gap: 1ch; color: var(--ink-dim); font-weight: normal; &::after { content: ""; flex: 1; align-self: center; border-top: 1px solid var(--rule); } } .kv { display: grid; grid-template-columns: 11ch minmax(0, 1fr); column-gap: 1ch; & dt { color: var(--ink-mute); } & dd { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; } } .outline { & a { display: block; text-decoration: none; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; } & a:hover { text-decoration: underline; } & .l1 { font-weight: bold; } & .l3 { padding-left: 2ch; } & .l4, & .l5, & .l6 { padding-left: 4ch; } & a[aria-current]::before { content: "▸"; margin-left: -1ch; } } .rail .clone { border: 0; padding: 0; margin-top: 0; } .rail .clone-line { flex-wrap: wrap; } }