@font-face {
    font-family: "Inter Variable";
    font-style: normal;
    font-weight: 100 900;
    font-display: swap;
    src: url("../fonts/InterVariable.woff2") format("woff2");
}

@font-face {
    font-family: "Inter Variable";
    font-style: italic;
    font-weight: 100 900;
    font-display: swap;
    src: url("../fonts/InterVariable-Italic.woff2") format("woff2");
}

@font-face {
    font-family: "Berkeley Mono";
    font-style: normal;
    font-weight: 100 900;
    font-display: swap;
    src: url("../fonts/Berkeley-Mono-Variable-v3.2.woff2") format("woff2");
}


:root {
    color-scheme: dark;
    /* Grid column headers (scraped Linear dark; InterfaceThemeCatalog carries the light values). */
    --grid-list-header-label-color: lch(61.399% 1.15 272 / 1);
    --grid-list-header-sort-color: lch(90.35% 1.15 272 / 1);
    --grid-list-header-sort-hover-bg: lch(9.92% 0.493 272 / 1);
    --grid-list-header-sort-hover-color: lch(100% 0 272 / 1);
    --grid-list-header-sort-icon-color: lch(61.399% 1.15 272 / 1);
    --font-regular: "Inter Variable", "SF Pro Display", -apple-system, "system-ui", "Segoe UI", Roboto, Oxygen, Ubuntu, Cantarell, "Open Sans", "Helvetica Neue", "Linear Thai", sans-serif;
    --font-mono: "Berkeley Mono", "SFMono-Regular", Consolas, "Liberation Mono", Menlo, monospace;
    --shell-sidebar-width: 220px;
    --settings-sidebar-width: 244px;
    --shell-nav-row-width: 220px;
    --shell-surface-radius: 12px;
    --shell-shadow: lch(0 0 0 / 0.04) 0 4px 4px -1px, lch(0 0 0 / 0.08) 0 1px 1px 0;
    --shell-bg-sidebar: lch(2.595% 0.4 272 / 1);
    --shell-bg-scroll: transparent;
    --shell-bg-surface: lch(5.52% 0.4 272 / 1);
    --shell-bg-active: lch(9.02% 0.45 272 / 1);
    --shell-bg-button: lch(10.691% 0.493 272 / 1);
    --shell-bg-hover: lch(10.691% 0.493 272 / 1);
    --shell-nav-active-bg: var(--shell-bg-active);
    --shell-nav-hover-bg: var(--shell-bg-hover);
    --shell-nav-text: var(--shell-text-secondary);
    --shell-nav-hover-text: var(--shell-text-primary);
    --shell-nav-active-text: var(--shell-text-primary);
    --shell-menu-bg: lch(9.92% 0.75 272 / 1);
    --shell-border: lch(8.84% 1.38 272 / 1);
    --shell-text-primary: lch(100 0 272);
    --shell-text-secondary: lch(60.307% 1 272);
    --chip-cell-label-color: lch(90.35% 1.15 272);
    --shell-text-tertiary: lch(90.077% 1 272);
    --shell-text-muted: lch(47% 0.9 272);
    --shell-sidebar-resize-guide: lch(100% 0 272 / 1);
    --shell-resize-guide-paint: linear-gradient( lch(from var(--shell-sidebar-resize-guide) l c h / 0) 0%, lch(from var(--shell-sidebar-resize-guide) l c h / 0.5) 15%, lch(from var(--shell-sidebar-resize-guide) l c h / 0.65) 50%, lch(from var(--shell-sidebar-resize-guide) l c h / 0.5) 85%, lch(from var(--shell-sidebar-resize-guide) l c h / 0) 100%);
    --shell-menu-text: lch(90.895% 1.375 272 / 1);
    --shell-menu-text-strong: lch(100 0 272 / 1);
    --shell-menu-text-danger: lch(65% 40 25 / 1);
    /* Create-modal surfaces (measured Linear light values live in the light blocks; these are
       the dark-ramp equivalents so the doc/panel/footer families theme like the rest of Qui). */
    --shell-create-panel-bg: lch(12.5% 1 272 / 1);
    --shell-create-panel-border: lch(19% 1.4 272 / 1);
    --shell-create-hairline: lch(19% 1.4 272 / 1);
    --shell-create-hover-bg: lch(20% 1 272 / 1);
    --shell-create-hover-bg-strong: lch(22% 1 272 / 1);
    --shell-create-text-title: lch(96% 0 272);
    --shell-create-text-primary: lch(88% 1 272);
    --shell-create-text-secondary: lch(62% 1 272);
    --shell-create-text-muted: lch(48% 1 272);
    --shell-create-placeholder: lch(45% 1 272);
    --shell-create-icon-bg: lch(35% 3 272 / 0.45);
    --shell-create-field-bg: lch(13% 1 272 / 1);
    --shell-create-row-hover: lch(17.5% 1 272 / 1);
    --shell-create-field-focus-border: lch(40% 1 272);
    --shell-sidebar-gutter: 8px;
    --shell-sidebar-peek-top: 42px;
    --shell-sidebar-peek-shadow: 0 0 0 0.5px lch(24% 1 272 / 1), 0 9px 48px lch(0 0 0 / 0.32), 0 6px 24px lch(0 0 0 / 0.36), 0 1px 1px lch(0 0 0 / 0.2);
    --shell-menu-hint: lch(63.582% 1.375 272 / 1);
    --shell-menu-indicator: lch(39.91% 1.375 272 / 1);
    --shell-menu-border: lch(22.88% 1.83 272 / 1);
    --shell-menu-divider: lch(22.88% 1.83 272 / 1);
    --shell-menu-item-hover: lch(15.32% 0.75 272 / 1);
    --assistant-border: lch(17.48% 1.38 272 / 1);
    --assistant-panel-shell-bg: lch(2.595% 0.4 272 / 1);
    --assistant-panel-content-bg: lch(7.67% 0.75 272 / 1);
    --assistant-panel-shadow: lch(0% 0 0 / 0.125) 0 3px 8px 0, lch(0% 0 0 / 0.125) 0 2px 5px 0, lch(0% 0 0 / 0.125) 0 1px 1px 0;
    --assistant-composer-bg: lch(9.599% 0.943 272 / 1);
    --assistant-composer-button-bg: lch(16.991% 1.393 272 / 1);
    --assistant-composer-border: var(--assistant-border);
    --assistant-composer-icon: lch(90.986% 1.6 272 / 1);
    --assistant-user-message-bg: lch(9.599% 0.943 272 / 1);
    --assistant-user-message-text: lch(90.668% 1.375 272 / 1);
    --assistant-user-message-shadow: lch(0% 0 0 / 0.04) 0 4px 4px -1px, lch(0% 0 0 / 0.08) 0 1px 1px 0;
    --shell-menu-shadow: lch(0 0 0 / 0.125) 0 3px 8px 0, lch(0 0 0 / 0.125) 0 2px 5px 0, lch(0 0 0 / 0.125) 0 1px 1px 0;
    --app-modal-overlay: rgba(0, 0, 0, 0.4);
    --app-modal-overlay-opacity: 0.95;
    --app-modal-shadow: lch(0 0 0 / 0.08) 0 9px 48px 0, lch(0 0 0 / 0.1) 0 6px 24px 0, lch(0 0 0 / 0.04) 0 1px 1px 0;
    --app-modal-animation: 220ms cubic-bezier(0.43, 0.07, 0.59, 0.94);
    --app-modal-resize-duration: 300ms;
    --app-modal-resize-ease: cubic-bezier(0.43, 0.07, 0.59, 0.94);
    --shell-avatar-green: lch(70% 60 140);
    --shell-placeholder: lch(12% 0.9 272 / 0.92);
    --shell-placeholder-soft: lch(14% 0.85 272 / 0.95);
    --shell-placeholder-line: color-mix(in srgb, var(--shell-border) 72%, transparent);
    --settings-section-header-bg: color-mix(in lch, var(--settings-card-bg, lch(7.67% 0.75 272 / 1)) 78%, var(--shell-bg-surface, lch(5.52% 0.4 272 / 1)) 22%);
    --ui-form-range-tooltip-bg: var(--shell-menu-bg);
    --ui-form-range-tooltip-border: var(--shell-menu-border);
    --ui-form-range-tooltip-text: var(--shell-menu-text);
}

*,
*::before,
*::after {
    box-sizing: border-box;
}

html,
body {
    width: 100%;
    height: 100%;
    margin: 0;
    padding: 0;
}

html {
    background: var(--shell-bg-sidebar);
}

body {
    overflow: hidden;
    font-family: var(--font-regular, Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif);
    font-weight: 400;
    font-synthesis: none;
    line-height: 1.5;
    color: var(--shell-text-primary);
    background: transparent;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    text-rendering: optimizeLegibility;
}

body.shell-sidebar-resizing,
body.shell-sidebar-resizing *,
body.grid-sidebar-resizing,
body.grid-sidebar-resizing *,
body.page-side-panel-resizing,
body.page-side-panel-resizing * {
    cursor: col-resize !important;
    user-select: none !important;
    -webkit-user-select: none !important;
}

a {
    color: inherit;
    text-decoration: none;
}

button,
input,
textarea,
select {
    font: inherit;
}

button {
    border: 0;
    background: transparent;
    color: inherit;
}

h1:focus {
    outline: none;
}

.app-shell,
.settings-shell {
    height: 100vh;
    min-height: 100vh;
    overflow: hidden;
    background: var(--shell-bg-sidebar);
    color: var(--shell-text-primary);
}

.app-shell__main-column,
.settings-shell__main-column {
    position: relative;
    display: flex;
    flex-direction: column;
    height: 100vh;
    min-height: 100vh;
    min-width: 0;
    overflow: hidden;
}

.app-shell__main-column {
    margin-left: var(--shell-sidebar-width);
}

.settings-shell__main-column {
    margin-left: var(--settings-sidebar-width);
}

.shell-sidebar-overlay__backdrop {
    display: none;
}


@media (width <= 1024px) {
    .app-shell__main-column,
    .settings-shell__main-column {
        margin-left: 0;
    }

    .shell-sidebar {
        z-index: 760;
        width: min(var(--shell-sidebar-width), calc(100vw - 40px), 330px);
        max-width: min(calc(100vw - 40px), 330px);
        background: var(--shell-bg-sidebar);
        opacity: 0;
        transform: translateX(-100%);
        transition:
            transform 350ms cubic-bezier(0.32, 0.72, 0, 1),
            opacity 50ms ease-in-out;
        will-change: transform;
    }

    .shell-sidebar--workspace {
        --shell-nav-row-width: calc(min(var(--shell-sidebar-width), calc(100vw - 40px), 330px) - 24px);
    }

    .shell-sidebar--settings {
        width: min(var(--settings-sidebar-width), calc(100vw - 40px), 330px);
        --shell-nav-row-width: calc(min(var(--settings-sidebar-width), calc(100vw - 40px), 330px) - 24px);
    }

    .app-shell--sidebar-overlay-open .shell-sidebar,
    .settings-shell--sidebar-overlay-open .shell-sidebar {
        opacity: 1;
        transform: translateX(0);
    }

    .shell-sidebar__resize-handle {
        display: none;
    }

    .shell-sidebar-overlay__backdrop {
        position: fixed;
        inset: 0;
        z-index: 740;
        display: block;
        border: 0;
        background: color-mix(in srgb, var(--shell-bg-sidebar) 62%, transparent);
        opacity: 0;
        pointer-events: none;
        transition: opacity 150ms ease-in-out;
    }

    .app-shell--sidebar-overlay-open .shell-sidebar-overlay__backdrop,
    .settings-shell--sidebar-overlay-open .shell-sidebar-overlay__backdrop {
        opacity: 1;
        pointer-events: auto;
    }
}

@media (prefers-reduced-motion: reduce) {
    .shell-sidebar,
    .shell-sidebar-overlay__backdrop {
        transition: none;
    }
}


.settings-sidebar__back-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 28px;
    height: 28px;
    margin-left: 4px;
    padding: 0 12px 0 6px;
    border: 0.5px solid transparent;
    border-radius: 9999px;
    background: transparent;
    color: var(--shell-text-secondary);
    font-size: 0.8125rem;
    font-weight: 500;
    line-height: normal;
    white-space: nowrap;
    transition-property: border, background-color, color, opacity;
    transition-duration: 120ms;
}

.settings-sidebar__back-link:hover,
.settings-sidebar__back-link:focus-visible {
    background-color: var(--shell-bg-hover, lch(10.691% 0.493 272 / 1));
    color: var(--shell-text-primary);
}

.settings-sidebar__back-link-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 14px;
    height: 14px;
    margin-right: 6px;
    flex: 0 0 auto;
}

.settings-sidebar__back-link-label {
    display: inline-flex;
    align-items: center;
}

.page-stub__body::-webkit-scrollbar {
    width: 8px;
}

.page-stub__body::-webkit-scrollbar-thumb {
    background: color-mix(in srgb, var(--shell-border) 65%, transparent);
    border-radius: 999px;
}

.app-shell__surface {
    display: flex;
    flex-direction: column;
    flex: 1 1 auto;
    min-width: 0;
    min-height: 0;
    margin: 8px 8px 8px 0;
    overflow: hidden;
    border: 0.5px solid var(--shell-surface-border, var(--shell-border));
    border-radius: var(--shell-surface-radius);
    background: var(--shell-bg-surface);
    box-shadow: var(--shell-shadow);
}

.app-shell__surface--settings {
    margin-left: 0;
    overflow-x: hidden;
    overflow-y: auto;
    scrollbar-width: none;
    -ms-overflow-style: none;
}

.app-shell__surface--settings::-webkit-scrollbar {
    display: none;
}

.app-shell__surface--test-scroll {
    overflow-x: hidden;
    overflow-y: auto;
    scrollbar-width: none;
    -ms-overflow-style: none;
}

.app-shell__surface--test-scroll::-webkit-scrollbar {
    display: none;
}

.app-shell__surface-wrap {
    display: flex;
    flex: 1 1 auto;
    min-height: 0;
    transform-origin: center top;
    transition: transform 180ms cubic-bezier(0.16, 1, 0.3, 1);
}

.app-shell__surface-wrap--assistant-maximized {
    transform: scale(0.98);
}

html:has(.auth-shell),
body:has(.auth-shell) {
    margin: 0;
    background: #090909;
}

.auth-shell {
    --auth-bg: #090909;
    --auth-text: #f4f4f5;
    --auth-muted: #8c8c90;
    --auth-button-bg: #1f1f20;
    --auth-button-hover-bg: #28282a;
    --auth-button-primary-bg: #626bdc;
    --auth-button-primary-hover-bg: #7179e2;
    --auth-border: #2b2c2f;
    --auth-input-bg: #111112;
    display: grid;
    box-sizing: border-box;
    min-height: 100vh;
    padding: 24px;
    overflow: hidden;
    place-items: center;
    background:
        radial-gradient(circle at 50% 42%, rgba(255, 255, 255, 0.018), transparent 290px),
        var(--auth-bg);
    color: var(--auth-text);
    font-family: var(--font-regular);
}

.auth-panel {
    display: flex;
    align-items: center;
    flex-direction: column;
    width: 288px;
    max-width: calc(100vw - 48px);
    margin-top: -20px;
    color: var(--auth-text);
    text-align: center;
}

.auth-panel--wide {
    width: 340px;
}

.auth-logo {
    display: grid;
    width: 48px;
    height: 48px;
    margin-bottom: 30px;
    place-items: center;
    color: #f0f0f0;
}

.auth-logo svg {
    display: block;
}

.auth-panel__copy {
    display: flex;
    align-items: center;
    flex-direction: column;
    gap: 22px;
    width: 100%;
}

.auth-panel h1 {
    margin: 0;
    color: var(--auth-text);
    font-size: 19px;
    font-weight: 450;
    letter-spacing: 0;
    line-height: 1.5rem;
}

.auth-panel__description {
    width: 100%;
    max-width: 250px;
    margin: -1px auto 14px;
    color: var(--auth-muted);
    font-size: 0.875rem;
    font-weight: 400;
    line-height: 1.25rem;
}

.auth-panel__description strong {
    color: var(--auth-text);
    font-weight: 450;
}

.auth-actions,
.auth-form {
    display: flex;
    flex-direction: column;
    gap: 16px;
    width: 100%;
    margin-top: 24px;
}

.auth-form {
    gap: 16px;
}

.auth-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    box-sizing: border-box;
    width: 100%;
    height: 44px;
    padding: 0 18px;
    border: 0;
    border-radius: 9999px;
    background: var(--auth-button-bg);
    color: var(--auth-text);
    cursor: default;
    font: inherit;
    font-size: 0.875rem;
    font-weight: 450;
    line-height: 1.125rem;
    text-decoration: none;
    transition:
        background 120ms ease,
        color 120ms ease,
        opacity 120ms ease;
}

.auth-button:hover,
.auth-button:focus-visible {
    background: var(--auth-button-hover-bg);
    color: #fff;
    outline: none;
}

.auth-button--primary {
    background: var(--auth-button-primary-bg);
    color: #fff;
}

.auth-button--primary:hover,
.auth-button--primary:focus-visible {
    background: var(--auth-button-primary-hover-bg);
}

.auth-button[disabled],
.auth-button[aria-disabled="true"] {
    opacity: 0.55;
    pointer-events: none;
}

.auth-input {
    box-sizing: border-box;
    width: 100%;
    height: 44px;
    padding: 0 13px;
    border: 1px solid var(--auth-border);
    border-radius: 8px;
    background: var(--auth-input-bg);
    color: var(--auth-text);
    font: inherit;
    font-size: 0.875rem;
    font-weight: 400;
    line-height: 1.25rem;
    outline: none;
    transition:
        border-color 120ms ease,
        box-shadow 120ms ease;
}

.auth-input::placeholder {
    color: #65666a;
}

.auth-input:focus {
    border-color: #363941;
    box-shadow: 0 0 0 2px rgba(88, 91, 98, 0.34);
}

.auth-form__error {
    margin: -4px 0 0;
    color: #f87171;
    font-size: 0.8125rem;
    font-weight: 450;
    line-height: 1.125rem;
    text-align: left;
}

.auth-form__help {
    margin: -2px 0 0;
    color: var(--auth-muted);
    font-size: 0.875rem;
    font-weight: 400;
    line-height: 1.25rem;
    text-align: center;
}

.auth-input--code {
    font-family: var(--font-mono, "SFMono-Regular", Consolas, "Liberation Mono", Menlo, monospace);
    font-size: 1rem;
    letter-spacing: 0.09em;
    text-align: center;
}

.auth-consent-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
    box-sizing: border-box;
    width: 100%;
    margin: 0;
    padding: 0;
    color: var(--auth-text);
    list-style: none;
    text-align: left;
}

.auth-consent-item {
    box-sizing: border-box;
    width: 100%;
    padding: 11px 12px;
    border: 1px solid var(--auth-border);
    border-radius: 8px;
    background: var(--auth-input-bg);
    color: var(--auth-text);
    font-size: 0.875rem;
    line-height: 1.25rem;
}

.auth-panel__footer,
.auth-link-row,
.auth-legal {
    color: var(--auth-muted);
    font-size: 0.875rem;
    font-weight: 400;
    line-height: 1.25rem;
}

.auth-panel__footer {
    margin-top: 30px;
}

.auth-link-row {
    margin-top: 18px;
}

.auth-link-row--compact {
    display: flex;
    justify-content: center;
    gap: 6px;
    margin-top: 8px;
}

.auth-legal {
    max-width: 260px;
    margin: 38px auto 0;
}

.auth-link {
    border: 0;
    background: transparent;
    color: var(--auth-text);
    cursor: default;
    font: inherit;
    text-decoration: none;
}

.auth-link-button {
    padding: 0;
}

.auth-link:hover,
.auth-link:focus-visible {
    color: #fff;
    outline: none;
}

.auth-spinner {
    display: block;
    width: 20px;
    height: 20px;
    margin-top: 34px;
    border: 2px solid rgba(255, 255, 255, 0.16);
    border-top-color: rgba(255, 255, 255, 0.76);
    border-radius: 50%;
    animation: auth-spin 800ms linear infinite;
}

@keyframes auth-spin {
    to {
        transform: rotate(360deg);
    }
}

@media (max-width: 520px) {
    .auth-shell {
        padding: 20px;
    }

    .auth-panel {
        width: min(288px, 100%);
        margin-top: -8px;
    }
}

/* ── Desktop collapse, measured from Linear: the layout slot animates (main column offset
   220 → the 8px gutter) while the rail translates fully off-canvas plus a 16px gap, both on the
   350ms shell curve and driven by the same state so they move in lockstep — the content card
   glides left rather than a panel flying off. No opacity fade. The rail keeps its width, so
   expansion restores it exactly. The page title bar's persistent toggle stays put; only its
   pane glyph animates. Hovering that toggle (or the 8px hot edge) PEEKS the rail: the same
   element lifts into a floating panel under the header row — card surface, measured corners
   and shadow — without a backdrop; clicking the toggle expands for real. ── */
@media (width > 1024px) {
    body:not(.shell-sidebar-resizing) .app-shell:has(.shell-sidebar[data-collapsed]) .app-shell__main-column {
        transition: margin-left 350ms cubic-bezier(0.32, 0.72, 0, 1);
    }

    .app-shell:has(.shell-sidebar[data-collapsed="true"]) .app-shell__main-column {
        margin-left: var(--shell-sidebar-gutter, 8px);
    }

    .app-shell:has(.shell-sidebar[data-collapsed]) .shell-sidebar {
        transition:
            transform 350ms cubic-bezier(0.32, 0.72, 0, 1),
            top 0s linear 350ms,
            border-radius 0s linear 350ms,
            background-color 0s linear 350ms,
            box-shadow 0s linear 350ms;
        will-change: transform;
    }

    .app-shell:has(.shell-sidebar[data-collapsed="true"]) .shell-sidebar {
        z-index: 760;
        background: var(--shell-bg-sidebar);
        transform: translateX(calc(-100% - 16px));
    }

    .app-shell:has(.shell-sidebar[data-collapsed="true"]) .shell-sidebar__resize-handle {
        display: none;
    }

    /* Peek: the rail lifts into a floating panel under the header row (measured top 41.5px,
       corners 0 12 12 0, card surface, modal shadow trio + hairline ring), sliding in on a
       shorter curve and back out with no fade. */
    .app-shell:has(.shell-sidebar[data-collapsed="true"][data-peek="true"]) .shell-sidebar, .app-shell--sidebar-overlay-open:has(.shell-sidebar[data-collapsed="true"]) .shell-sidebar {
        top: var(--shell-sidebar-peek-top, 42px);
        border-radius: 0 var(--shell-surface-radius, 12px) var(--shell-surface-radius, 12px) 0;
        background: var(--shell-bg-surface);
        box-shadow: var(--shell-sidebar-peek-shadow);
        transform: translateX(0);
        transition:
            transform 200ms cubic-bezier(0.32, 0.72, 0, 1),
            top 0s linear 0s,
            border-radius 0s linear 0s,
            background-color 0s linear 0s,
            box-shadow 0s linear 0s;
    }

    .app-shell:has(.shell-sidebar[data-collapsed="true"]) .shell-sidebar-overlay__backdrop {
        display: none;
    }

    .app-shell:has(.shell-sidebar[data-collapsed="true"]) .shell-sidebar__hot-edge {
        position: fixed;
        inset: 0 auto 0 0;
        width: var(--shell-sidebar-gutter, 8px);
        z-index: 759;
    }

    .app-shell:has(.shell-sidebar[data-collapsed="true"]) .page-title-bar__sidebar-toggle {
        display: grid;
    }

    .app-shell:has(.shell-sidebar[data-collapsed="true"]) .page-title-bar__title-slot {
        padding-left: 4px;
    }

    .app-shell:has(.shell-sidebar[data-collapsed="true"]) .basic-page.basic-page--with-shell-header {
        padding-top: 0;
    }

    .app-shell:has(.shell-sidebar[data-collapsed="true"]) .basic-page__mobile-shell-header {
        position: sticky;
        top: 0;
        z-index: 30;
        display: flex;
        align-items: center;
        min-height: 44px;
        padding: 0 8px;
        background: var(--shell-bg-surface, var(--shell-bg-sidebar));
        color: var(--shell-text-primary);
    }

    .app-shell:has(.shell-sidebar[data-collapsed="true"]) .basic-page__mobile-shell-header .page-title-bar {
        min-height: 44px;
    }

    .app-shell:has(.shell-sidebar[data-collapsed="true"]) .basic-page__mobile-shell-header .page-title-bar__sidebar-toggle {
        display: grid;
    }

    .app-shell:has(.shell-sidebar[data-collapsed="true"]) .basic-page__backbar-sidebar-toggle {
        display: grid;
        margin-right: 8px;
    }

    .app-shell:has(.shell-sidebar[data-collapsed="true"]) .basic-page.basic-page--with-shell-header:not(.basic-page--with-back) .basic-page__inner {
        margin-top: 48px;
    }

    .app-shell:has(.shell-sidebar[data-collapsed="true"]) .basic-page.basic-page--with-shell-header.basic-page--with-back .basic-page__backbar {
        flex-basis: 55px;
        height: 55px;
        padding-top: 1px;
    }
}

.shell-sidebar__hot-edge {
    display: none;
}

@media (width > 1024px) {
    .app-shell:has(.shell-sidebar[data-collapsed="true"]) .shell-sidebar__hot-edge {
        display: block;
    }
}

/* The optional expand affordance slot renders outside the inert rail while collapsed. */
.shell-sidebar__collapsed-affordance {
    position: fixed;
    top: 10px;
    left: 10px;
    z-index: 570;
}

/* Linear's model: with a persistent (collapse-capable) sidebar toggle the standalone shell header
   is part of the page on desktop too — the toggle is always the first item of the page header —
   so the same header treatment the narrow viewport uses applies whenever it hosts one. */
.basic-page.basic-page--with-shell-header:has(.page-title-bar__sidebar-toggle--persistent) {
    padding-top: 0;
}

.basic-page__mobile-shell-header:has(.page-title-bar__sidebar-toggle--persistent) {
    position: sticky;
    top: 0;
    z-index: 30;
    display: flex;
    align-items: center;
    min-height: 44px;
    padding: 0 8px;
    background: var(--shell-bg-surface, var(--shell-bg-sidebar));
    color: var(--shell-text-primary);
}

.basic-page__mobile-shell-header:has(.page-title-bar__sidebar-toggle--persistent) .page-title-bar {
    min-height: 44px;
}

.basic-page.basic-page--with-shell-header:not(.basic-page--with-back):has(.page-title-bar__sidebar-toggle--persistent) .basic-page__inner {
    margin-top: 48px;
}

.basic-page.basic-page--with-shell-header.basic-page--with-back:has(.page-title-bar__sidebar-toggle--persistent) .basic-page__backbar {
    flex-basis: 55px;
    height: 55px;
    padding-top: 1px;
}
