/* * The shell: sidebar, top bar, phone tab bar, "More" sheet, command palette * and account menu (components/shell/, components/portal/AccountMenu.tsx). * * Mobile first. Three shapes, one per range, each rendered and checked at * 390, 834 and 1440 (fleet nav contract rules 3, 7, 8): * < 768 top bar + bottom tab bar + "More" sheet; no sidebar * 768–1023 icon rail with labels; each section opens a flyout * ≥ 1024 full sidebar, collapsible to the rail (remembered) * Every control is at least --size-target (44px, 48px on touch) both ways. */ .shell { min-height: 100dvh; background: var(--color-surface-page); } .shell-column { display: flex; flex-direction: column; min-width: 0; min-height: 100dvh; padding-bottom: var(--shell-offset-bottom); } .shell-page { flex: 1; min-width: 0; /* The feedback launcher floats bottom-right above the tab bar; the last cards and copy of a page scroll fully clear of it (button + a gap). */ padding-bottom: calc(var(--widget-reserve, 0px) + 0.5rem); } .shell-skip { position: absolute; left: -100vw; } .shell-skip:focus { display: inline-flex; align-items: center; min-height: var(--size-target); left: 1rem; top: 0.5rem; z-index: 90; padding: 0.75rem 1rem; border: 1px solid var(--color-border-strong); background: var(--color-surface-page); } @media (min-width: 768px) { .shell { display: grid; grid-template-columns: var(--spacing-rail) minmax(0, 1fr); } } @media (min-width: 1024px) { html:not([data-rail='collapsed']) .shell { grid-template-columns: var(--spacing-sidebar) minmax(0, 1fr); } } /* ---------------------------------------------------------------- sidebar */ .shell-sidebar { display: none; } @media (min-width: 768px) { .shell-sidebar { position: sticky; top: 0; z-index: 35; display: flex; flex-direction: column; height: 100dvh; border-right: 1px solid var(--color-border-subtle); background: var(--color-surface-page); } } .shell-brand { display: flex; flex-shrink: 0; align-items: center; justify-content: center; height: var(--spacing-topbar); border-bottom: 1px solid var(--color-border-subtle); } .shell-brand-link, .shell-topbar-brand { display: inline-flex; align-items: center; gap: 0.6rem; min-width: var(--size-target); min-height: var(--size-target); justify-content: center; font: 600 1.125rem/1 var(--font-heading); letter-spacing: var(--tracking-display); color: var(--color-fg-primary); } .shell-brand-name { display: none; } .shell-nav-full { display: none; } .shell-nav-rail { display: flex; flex-direction: column; gap: 0.25rem; padding: 0.5rem; } .shell-rail-toggle { display: none; } @media (min-width: 1024px) { .shell-rail-toggle { display: inline-flex; align-items: center; justify-content: center; align-self: center; width: var(--size-target); height: var(--size-target); margin: auto 0 0.75rem; border-radius: 0.375rem; color: var(--color-fg-tertiary); cursor: pointer; } .shell-rail-toggle:hover { background: var(--color-surface-raised); color: var(--color-fg-primary); } html:not([data-rail='collapsed']) .shell-brand { justify-content: flex-start; padding: 0 1rem; } html:not([data-rail='collapsed']) .shell-brand-name { display: inline; } html:not([data-rail='collapsed']) .shell-nav-full { display: flex; flex-direction: column; gap: 0.125rem; padding: 0.75rem; overflow-y: auto; } html:not([data-rail='collapsed']) .shell-nav-rail { display: none; } html:not([data-rail='collapsed']) .shell-rail-toggle { align-self: flex-end; margin-right: 0.75rem; } } /* Full sidebar: sections (caps, with an icon) over pages (sentence case). */ .shell-section-toggle, .shell-link { display: flex; align-items: center; gap: 0.75rem; width: 100%; min-height: var(--size-target); padding: 0 0.75rem; border-radius: 0.375rem; text-align: left; color: var(--color-fg-secondary); } .shell-section-toggle { margin-top: 0.25rem; font-size: var(--text-label); font-weight: 600; letter-spacing: 0.12em; text-transform: uppercase; cursor: pointer; } /* Under the uppercase heading, in sentence case so it reads as a line, not a label. */ .shell-section-subtitle { display: block; font-size: var(--text-label); font-weight: 400; letter-spacing: normal; text-transform: none; color: var(--color-fg-tertiary); } .shell-link { font-size: 0.9rem; } .shell-link-top { margin-bottom: 0.25rem; } .shell-link-sub { padding-left: 2.75rem; } .shell-section-toggle:hover, .shell-link:hover { background: var(--color-surface-raised); color: var(--color-fg-primary); } .shell-section-toggle[data-here] { color: var(--color-fg-primary); } .shell-link[aria-current='page'] { background: var(--color-surface-raised); box-shadow: inset 2px 0 0 var(--color-fg-primary); color: var(--color-fg-primary); font-weight: 600; } .shell-chevron { width: 1rem; height: 1rem; color: var(--color-fg-muted); transition: transform 150ms ease; } .shell-section-toggle[aria-expanded='false'] .shell-chevron { transform: rotate(-90deg); } /* Rail: icon over label, because a tablet has no hover for a tooltip. */ .shell-flyout > summary { list-style: none; } .shell-flyout > summary::-webkit-details-marker { display: none; } .shell-rail-item { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 0.25rem; min-height: 3.5rem; padding: 0.375rem 0.25rem; border-radius: 0.375rem; font-size: var(--text-label); font-weight: 500; color: var(--color-fg-tertiary); text-align: center; cursor: pointer; } .shell-rail-item:hover, .shell-flyout[open] > .shell-rail-item { background: var(--color-surface-raised); color: var(--color-fg-primary); } .shell-rail-item[aria-current='page'], .shell-rail-item[data-here] { background: var(--color-surface-raised); box-shadow: inset 2px 0 0 var(--color-fg-primary); color: var(--color-fg-primary); } .shell-flyout-panel { position: fixed; left: calc(var(--spacing-rail) + 0.5rem); z-index: 45; width: min(20rem, calc(100vw - var(--spacing-rail) - 1rem)); max-height: calc(100dvh - 1rem); margin-top: -3.5rem; padding: 0.5rem; overflow-y: auto; border: 1px solid var(--color-border-strong); border-radius: 0.5rem; background: var(--color-surface-page); box-shadow: var(--shadow-overlay); } .shell-flyout-title { padding: 0.5rem 0.75rem 0; font-weight: 600; color: var(--color-fg-primary); } .shell-flyout-question { padding: 0.125rem 0.75rem 0.5rem; font-size: 0.78rem; color: var(--color-fg-tertiary); } /* A page with its one-line hint: flyouts and the "More" sheet. */ .shell-row { display: flex; flex-direction: column; justify-content: center; gap: 0.125rem; min-height: var(--size-target); padding: 0.5rem 0.75rem; border-radius: 0.375rem; } .shell-row:hover, .shell-row[aria-current='page'] { background: var(--color-surface-raised); } .shell-row[aria-current='page'] { box-shadow: inset 2px 0 0 var(--color-fg-primary); } .shell-row-label { font-size: 0.92rem; font-weight: 500; color: var(--color-fg-primary); } .shell-row-hint { font-size: 0.78rem; line-height: 1.35; color: var(--color-fg-tertiary); } /* ---------------------------------------------------------------- top bar */ .shell-topbar { position: sticky; top: 0; z-index: 30; display: flex; align-items: center; gap: 0.25rem; height: var(--spacing-topbar); padding: 0 0.5rem 0 1rem; border-bottom: 1px solid var(--color-border-subtle); background: color-mix(in srgb, var(--color-surface-page) 94%, transparent); backdrop-filter: blur(8px); } .shell-search { display: inline-flex; align-items: center; justify-content: center; gap: 0.6rem; min-width: var(--size-target); min-height: var(--size-target); margin-left: auto; border-radius: 0.5rem; color: var(--color-fg-secondary); cursor: pointer; } .shell-search-label, .shell-kbd, .shell-join, .shell-topbar-link { display: none; } /* The actions never shrink or wrap: the search box is the part that gives way (its label ellipsises down to the icon), so "Sign in" stays one line at every width, scrollbar or not. */ .shell-topbar-end { display: flex; flex-shrink: 0; align-items: center; gap: 0.5rem; } .shell-topbar-end > * { flex-shrink: 0; } .shell-ask, .shell-join, .shell-topbar-link, .account-menu-summary { white-space: nowrap; } @media (min-width: 768px) { .shell-topbar { gap: 1rem; padding: 0 1rem 0 1.5rem; } .shell-topbar-brand { display: none; } .shell-search { flex: 0 1 26rem; justify-content: flex-start; margin-left: 0; padding: 0 0.5rem 0 0.9rem; border: 1px solid var(--color-border-strong); background: var(--color-surface-raised); color: var(--color-fg-tertiary); font-size: 0.85rem; } .shell-search:hover { border-color: var(--color-fg-tertiary); } .shell-search-label { display: inline; flex: 1; min-width: 0; overflow: hidden; text-align: left; text-overflow: ellipsis; white-space: nowrap; } .shell-kbd { display: inline-flex; padding: 0.2rem 0.4rem; border: 1px solid var(--color-border-strong); border-radius: 0.3rem; font: var(--text-label)/1 var(--font-mono); } .shell-topbar-end { margin-left: auto; } .shell-join, .shell-topbar-link { display: inline-flex; align-items: center; min-height: var(--size-target); padding: 0 1rem; font-size: 0.85rem; color: var(--color-fg-secondary); } .shell-join { border: 1px solid var(--color-border-strong); color: var(--color-fg-primary); } .shell-join:hover, .shell-topbar-link:hover, .shell-topbar-link[aria-current='page'] { color: var(--color-fg-primary); } .shell-join[aria-current='page'] { border-color: var(--color-fg-primary); } } /* Phones: Ask sits in the bar (see components/shell/TopBar.tsx); from 768px up the floating dock button has room and this one hides. */ .shell-ask { display: inline-flex; align-items: center; min-height: var(--size-target); padding: 0 0.9rem; border-radius: 999px; background: var(--color-fg-primary); color: var(--color-surface-page); font-size: 0.75rem; font-weight: 650; letter-spacing: 0.08em; text-transform: uppercase; cursor: pointer; } @media (min-width: 768px) { .shell-ask { display: none; } }