/* /Layout/MainLayout.razor.rz.scp.css */
.page[b-uyr50gxxhx] {
    position: relative;
    display: flex;
    flex-direction: column;
    background: var(--bg);
    min-height: 100vh;
}

.page-body[b-uyr50gxxhx] {
    display: flex;
    flex-direction: column;
    flex: 1;
    min-width: 0;
    min-height: 0;
}

main[b-uyr50gxxhx] {
    flex: 1;
    min-width: 0;
    background: var(--bg);
    display: flex;
    flex-direction: column;
}

.sidebar[b-uyr50gxxhx] {
    background: var(--bg);
    border-right: 1px solid var(--line);
}

.sidebar-desktop[b-uyr50gxxhx] {
    display: none;
}

.top-row[b-uyr50gxxhx] {
    background: var(--bg);
    border-bottom: 1px solid var(--line);
    height: 56px;
    display: flex;
    align-items: center;
    padding: 0 12px;
    padding-top: env(safe-area-inset-top, 0);
    gap: 10px;
    color: var(--ink);
    font-size: 13px;
    position: sticky;
    top: 0;
    z-index: 50;
    backdrop-filter: blur(8px);
    background: color-mix(in oklab, var(--bg) 88%, transparent);
}

.top-row .user[b-uyr50gxxhx] {
    color: var(--muted);
    font-size: 13px;
    font-weight: 500;
    white-space: nowrap;
}

/* Brand zone — on desktop it mirrors the sidebar column (240px, flush left) so
   the logo centers directly above the sidebar; on mobile it's natural width. */
.top-row-brand[b-uyr50gxxhx] {
    display: flex;
    align-items: center;
    flex-shrink: 0;
}

/* Center zone — holds the prominent active-application name. */
.top-row-center[b-uyr50gxxhx] {
    flex: 1;
    min-width: 0;
    display: flex;
    justify-content: center;
    align-items: center;
}

.top-row-module-name[b-uyr50gxxhx] {
    font-size: 18px;
    font-weight: 700;
    color: var(--ink);
    letter-spacing: -0.01em;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* Tablet module-menu trigger — the active application name rendered as a
   tappable pill with a caret.

   Only 601-767px. Below 601 the menu opens from .module-handle at the bottom
   of the screen; at >=768 the sidebar makes any trigger redundant. That band
   keeps the pill because it has no bottom nav for a handle to sit above, and
   .bottom-sheet becomes a *centred modal* at >=601px (app.css), so a
   bottom-anchored handle there would point at nothing. Three windows is one
   more than d-md-none can express, hence the explicit media query. */
.module-menu-trigger[b-uyr50gxxhx] {
    display: none;
    align-items: center;
    gap: 4px;
    max-width: 100%;
    min-height: 40px;
    padding: 5px 10px 5px 14px;
    /* Soft brand tint, no border — the `.pill.success` treatment. A --surface-2
       fill with a --line border (the .btn-apps-trigger recipe) reads as a grey
       OS button sitting on the bar; this reads as the current app's own chip. */
    border: 0;
    border-radius: 999px;
    background: linear-gradient(118deg, var(--primary-solid), var(--secondary-solid));
    color: var(--primary-ink);
    font-family: inherit;
    font-size: 17px;
    font-weight: 700;
    letter-spacing: -0.01em;
    cursor: pointer;
    transition: background var(--dur-fast) var(--ease-standard);
}

.module-menu-trigger:active[b-uyr50gxxhx] {
    background: color-mix(in oklab, var(--primary-soft) 82%, var(--primary));
}

.module-menu-trigger:focus-visible[b-uyr50gxxhx] {
    outline: 2px solid var(--primary);
    outline-offset: 2px;
}

.module-menu-label[b-uyr50gxxhx] {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.module-menu-trigger[b-uyr50gxxhx]  .module-menu-caret {
    flex-shrink: 0;
    color: var(--primary-ink);
    opacity: 0.7;
    transition: transform var(--dur-fast) var(--ease-standard);
}

.module-menu-trigger[aria-expanded="true"][b-uyr50gxxhx]  .module-menu-caret {
    transform: rotate(180deg);
}

@media (min-width: 601px) and (max-width: 767.98px) {
    .module-menu-trigger[b-uyr50gxxhx] { display: inline-flex; }
    /* The pill already carries the module name; don't print it twice. */
    .top-row-module-name.is-hidden-tablet[b-uyr50gxxhx] { display: none; }
}

/* ─── Mobile module handle ───────────────────────────────────────────────
   A drawer-handle tab whose flat bottom edge is flush with the top border of
   the bottom nav: it reads as something you pull up out of the bar, which a
   detached floating circle does not. Centred, so it never meets the FAB (on
   a 320px screen the FAB's left edge is at 248px; the handle spans 128-192px).
   <=600px only — see the .module-menu-trigger note above. */
.module-handle[b-uyr50gxxhx] {
    display: none;
    position: fixed;
    left: 50%;
    bottom: calc(env(safe-area-inset-bottom, 0px) + var(--bottom-nav-h, 0px));
    /* transform does double duty here: it centres the tab AND carries the bob.
       Every keyframe and every transform rule below must repeat the
       translateX(-50%) or the handle jumps half its width off-centre. */
    transform: translateX(-50%);
    z-index: 1051; /* above .bottom-nav (1050), below .fab (1100) and the sheet (1141) */
    width: 64px;
    height: 26px;
    padding: 0;
    border: 0;
    border-radius: 999px 999px 0 0;
    background: linear-gradient(118deg, var(--primary-solid), var(--secondary-solid));
    color: var(--primary-ink);
    box-shadow: 0 -4px 12px -6px rgb(0 0 0 / 0.35);
    cursor: pointer;
    place-items: center;
    transition: transform var(--dur-fast) var(--ease-standard),
                opacity var(--dur-fast) var(--ease-standard);
}

/* Invisible hit-area extension: 26px of visible tab, >=44px of touch target. */
.module-handle[b-uyr50gxxhx]::before {
    content: "";
    position: absolute;
    inset: -18px -8px 0;
}

/* Attention halo — see the animation note on .module-handle below. */
.module-handle[b-uyr50gxxhx]::after {
    content: "";
    position: absolute;
    inset: 0;
    border-radius: inherit;
    border: 2px solid var(--primary);
    opacity: 0;
    pointer-events: none;
}

.module-handle[b-uyr50gxxhx]  .module-handle-caret {
    transition: transform var(--dur-fast) var(--ease-standard);
}

.module-handle:active[b-uyr50gxxhx] { transform: translateX(-50%) scale(0.94); }

.module-handle:focus-visible[b-uyr50gxxhx] {
    outline: 2px solid var(--primary);
    outline-offset: 2px;
}

/* Open: the sheet grows from the bottom and would cover the handle anyway, so
   fade it out — but keep it in the DOM and rendered, because
   bizgoForms.releaseFocus returns focus to it when the sheet closes. */
.module-handle.is-open[b-uyr50gxxhx] {
    opacity: 0;
    pointer-events: none;
}

.module-handle.is-open[b-uyr50gxxhx]  .module-handle-caret { transform: rotate(180deg); }

@media (max-width: 600px) {
    /* Three cycles, then it rests. Chrome that animates forever stops reading
       as an invitation and starts reading as noise. Restarted on every module
       switch by the @key in MainLayout.razor. */
    .module-handle[b-uyr50gxxhx] {
        display: grid;
        animation: mh-bob-b-uyr50gxxhx 1.1s var(--ease-standard) 3;
    }
    .module-handle[b-uyr50gxxhx]::after { animation: mh-halo-b-uyr50gxxhx 1.1s var(--ease-standard) 3; }
}

@keyframes mh-bob-b-uyr50gxxhx {
    0%, 60%, 100% { transform: translateX(-50%) translateY(0); }
    30%           { transform: translateX(-50%) translateY(-4px); }
}

@keyframes mh-halo-b-uyr50gxxhx {
    0%   { opacity: 0.45; transform: scale(1); }
    60%  { opacity: 0;    transform: scale(1.6); }
    100% { opacity: 0;    transform: scale(1.6); }
}

@media (prefers-reduced-motion: reduce) {
    /* Still noticed (it appeared), but nothing moves. */
    .module-handle[b-uyr50gxxhx]::after { animation: none; }
    .module-handle[b-uyr50gxxhx] { animation: mh-fade-b-uyr50gxxhx 300ms var(--ease-standard); }
}

@keyframes mh-fade-b-uyr50gxxhx { from { opacity: 0; } to { opacity: 1; } }

.top-row .avatar-chip[b-uyr50gxxhx] {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: var(--surface-2);
    border: 1px solid var(--line);
    display: grid;
    place-items: center;
    font-weight: 600;
    font-size: 12px;
    color: var(--ink);
    letter-spacing: -0.01em;
}

    .top-row[b-uyr50gxxhx]  a, .top-row[b-uyr50gxxhx]  .btn-link {
        white-space: nowrap;
        text-decoration: none;
    }

    .top-row[b-uyr50gxxhx]  a:hover, .top-row[b-uyr50gxxhx]  .btn-link:hover {
        text-decoration: underline;
    }

.content[b-uyr50gxxhx] {
    padding: 16px;
    /* Clear whatever fixed chrome is at the bottom at this width. --bottom-nav-h
       is 64px only where the bottom nav actually renders (<=600px, app.css), and
       the 32px on top covers the 26px module handle that sits above the bar. At
       601-767px there is no bar, so this collapses to a plain 32px gutter. */
    padding-bottom: calc(env(safe-area-inset-bottom, 0px) + var(--bottom-nav-h, 0px) + 32px);
    flex: 1;
    min-width: 0;
}

@media (min-width: 768px) {
    .page-body[b-uyr50gxxhx] {
        flex-direction: row;
    }

    .sidebar-desktop[b-uyr50gxxhx] {
        display: block;
        width: 240px;
        height: calc(100vh - 56px);
        position: sticky;
        top: 56px;
        flex-shrink: 0;
    }

    .top-row[b-uyr50gxxhx] {
        /* No left padding so the brand zone sits flush above the sidebar column.
           Right padding keeps the controls off the edge. Spacing between zones is
           handled per-zone (below) rather than with a flex gap. */
        padding: 0 20px 0 0;
        gap: 0;
    }

    /* Match the sidebar width and centre the logo within it — independent of
       whether the sidebar is currently rendered. */
    .top-row-brand[b-uyr50gxxhx] {
        width: 240px;
        justify-content: center;
    }

    /* Sit just right of where the sidebar's right edge meets the bar. */
    .apps-anchor[b-uyr50gxxhx] {
        margin-left: 20px;
    }

    /* Center the active app name against the full bar (i.e. the viewport),
       not the leftover flex space. The brand column (240px) + Applications
       button make the left side wider than the right controls, so flex
       centering lands the name right-of-centre. Absolutely positioning it at
       left:50% of the (sticky, full-width) top-row centres it on the screen.
       .top-row-center stays flex:1 as an empty spacer that keeps the
       right-hand controls pinned to the edge; pointer-events:none ensures the
       overlaid name never intercepts clicks on the controls behind it. */
    .top-row-module-name[b-uyr50gxxhx] {
        position: absolute;
        left: 50%;
        top: 50%;
        transform: translate(-50%, -50%);
        max-width: 40vw;
        pointer-events: none;
        font-size: 20px;
    }

    .content[b-uyr50gxxhx] {
        padding: 24px 28px;
        padding-bottom: calc(env(safe-area-inset-bottom, 0px) + 28px);
    }
}

/* Brand lockup link — never underline the wordmark on hover. */
.top-row a.brand[b-uyr50gxxhx],
.top-row a.brand:hover[b-uyr50gxxhx] {
    display: inline-flex;
    align-items: center;
    text-decoration: none;
}

.apps-anchor[b-uyr50gxxhx] {
    position: relative;
}

.btn-apps-trigger[b-uyr50gxxhx] {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: var(--surface-2);
    border: 1px solid var(--line);
    color: var(--ink);
    padding: 6px 12px;
    border-radius: 8px;
    font-weight: 600;
}

.btn-apps-trigger:hover[b-uyr50gxxhx] {
    background: var(--surface-3);
}

.btn-apps-trigger[b-uyr50gxxhx]  svg {
    color: var(--ink-2);
}

.apps-modal-backdrop[b-uyr50gxxhx] {
    position: fixed;
    inset: 0;
    z-index: 40;
    background: transparent;
}

.apps-modal[b-uyr50gxxhx] {
    position: absolute;
    top: calc(100% + 8px);
    left: 0;
    z-index: 60;
    background: var(--surface);
    color: var(--ink);
    border: 1px solid var(--line);
    border-radius: 12px;
    box-shadow: var(--shadow-pop);
    width: min(420px, calc(100vw - 32px));
    max-height: calc(100vh - 96px);
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    animation: apps-modal-in-b-uyr50gxxhx 120ms ease-out;
}

@keyframes apps-modal-in-b-uyr50gxxhx {
    from { opacity: 0; transform: translateY(-4px); }
    to   { opacity: 1; transform: translateY(0); }
}

.apps-modal-header[b-uyr50gxxhx] {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 14px 18px;
    border-bottom: 1px solid var(--line);
}

.apps-modal-header h2[b-uyr50gxxhx] {
    margin: 0;
    font-size: 16px;
    font-weight: 600;
    color: var(--ink);
}

.apps-modal-grid[b-uyr50gxxhx] {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 10px;
    padding: 14px;
}

.apps-modal-tile[b-uyr50gxxhx] {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 18px 12px;
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: 10px;
    cursor: pointer;
    color: var(--ink);
    font: inherit;
    text-align: center;
    transition: background 80ms, border-color 80ms, transform 80ms;
    text-decoration: none;
}

.apps-modal-tile:hover[b-uyr50gxxhx] {
    background: linear-gradient(118deg, var(--primary-solid-hover), var(--secondary-solid-hover));
    /* background: var(--surface-2); */
    border-color: var(--line-strong);
    text-decoration: none;
}

.apps-modal-tile:focus-visible[b-uyr50gxxhx] {
    outline: 2px solid var(--primary);
    outline-offset: 2px;
}

.apps-modal-tile.active[b-uyr50gxxhx] {
    border-color: var(--primary);
    /* background: var(--primary-soft); */
    background: linear-gradient(118deg, var(--primary-solid), var(--secondary-solid));
}

.apps-modal-tile-icon[b-uyr50gxxhx] {
    display: inline-flex;
    width: 36px;
    height: 36px;
    align-items: center;
    justify-content: center;
    color: var(--ink);
}

.apps-modal-tile-icon .rail-icon[b-uyr50gxxhx] {
    width: 28px;
    height: 28px;
}

.apps-modal-tile-name[b-uyr50gxxhx] {
    font-size: 13px;
    font-weight: 600;
    color: var(--ink);
}

.apps-modal-hint[b-uyr50gxxhx] {
    padding: 0 18px 16px;
    color: var(--muted);
    font-size: 12px;
    text-align: center;
}
/* /Layout/NavMenu.razor.rz.scp.css */
/* The brand lockup lives in MainLayout's top-row (<BizGoLogo/>); NavMenu only
   renders the nav rail, so the old flat-ink .brand-* rules here were dead and
   have been removed. */

.nav-scrollable[b-ivjzwy8a7s] {
    padding: 12px 8px;
}

.rail-nav[b-ivjzwy8a7s] {
    display: flex;
    flex-direction: column;
    gap: 1px;
}

.nav-section-label[b-ivjzwy8a7s] {
    font-size: 10px;
    font-weight: 600;
    color: var(--primary-ink);
    letter-spacing: 0.08em;
    text-transform: uppercase;
    padding: 12px 10px 6px;
}

.rail-nav[b-ivjzwy8a7s]  a.rail-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 10px;
    border-radius: 8px;
    color: var(--ink-2);
    text-decoration: none;
    font-size: 13px;
    font-weight: 500;
    line-height: 1.2;
    transition: background 60ms, color 60ms;
    position: relative;
}

.rail-nav[b-ivjzwy8a7s]  a.rail-item:hover {
    background: var(--surface-2);
    color: var(--ink);
}

.rail-nav[b-ivjzwy8a7s]  a.rail-item.active {
    background: var(--surface-2);
    color: var(--primary-ink);
}

.rail-nav[b-ivjzwy8a7s]  a.rail-item.active::before {
    content: '';
    position: absolute;
    left: -8px;
    top: 8px;
    bottom: 8px;
    width: 2px;
    background: var(--primary);
    border-radius: 2px;
}

.rail-nav[b-ivjzwy8a7s]  a.rail-item .rail-icon {
    width: 18px;
    height: 18px;
    flex-shrink: 0;
    color: var(--muted);
    transition: color 60ms;
}

.rail-nav[b-ivjzwy8a7s]  a.rail-item:hover .rail-icon {
    color: var(--ink);
}

.rail-nav[b-ivjzwy8a7s]  a.rail-item.active .rail-icon {
    color: var(--primary-ink);
}

@media (min-width: 768px) {
    .nav-scrollable[b-ivjzwy8a7s] {
        height: calc(100vh - 56px);
        overflow-y: auto;
        padding: 14px 14px;
    }
    .rail-nav[b-ivjzwy8a7s]  a.rail-item.active::before { left: -6px; }
}
/* /Layout/PortalNavMenu.razor.rz.scp.css */
/* Staff portal sidebar rail. Deliberately the same recipe as NavMenu.razor.css
   (the owner app's module rail) so the two shells read as one product — see
   Dev_Docs/Staff_Portal_Desktop_Alignment_Plan.md §4. Kept as scoped css rather
   than folded into app.css because that is the existing pattern for nav rails.

   Only rendered at >=768px, so there is no mobile branch here. */

.nav-scrollable[b-8flfbic3jq] {
    padding: 14px;
    height: calc(100vh - var(--header-h));
    overflow-y: auto;
}

.rail-nav[b-8flfbic3jq] {
    display: flex;
    flex-direction: column;
    gap: 1px;
}

.rail-nav[b-8flfbic3jq]  a.rail-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 10px;
    border-radius: 8px;
    color: var(--ink-2);
    text-decoration: none;
    font-size: 13px;
    font-weight: 500;
    line-height: 1.2;
    transition: background 60ms, color 60ms;
    position: relative;
}

.rail-nav[b-8flfbic3jq]  a.rail-item:hover {
    background: var(--surface-2);
    color: var(--ink);
}

.rail-nav[b-8flfbic3jq]  a.rail-item:focus-visible {
    outline: 2px solid var(--primary);
    outline-offset: 2px;
}

.rail-nav[b-8flfbic3jq]  a.rail-item.active {
    background: var(--surface-2);
    color: var(--primary-ink);
}

.rail-nav[b-8flfbic3jq]  a.rail-item.active::before {
    content: '';
    position: absolute;
    left: -6px;
    top: 8px;
    bottom: 8px;
    width: 2px;
    background: var(--primary);
    border-radius: 2px;
}

.rail-nav[b-8flfbic3jq]  a.rail-item .rail-icon {
    width: 18px;
    height: 18px;
    flex-shrink: 0;
    color: var(--muted);
    transition: color 60ms;
}

.rail-nav[b-8flfbic3jq]  a.rail-item:hover .rail-icon {
    color: var(--ink);
}

.rail-nav[b-8flfbic3jq]  a.rail-item.active .rail-icon {
    color: var(--primary-ink);
}
/* /Pages/Inbox/InboxV2.razor.rz.scp.css */
/*
   Inbox v2 — three-column shell + nested component styles.

   Layout breakpoints:
     ≥ 1280px (xl): three columns side-by-side (rail │ thread │ context).
     960–1279px:    two columns (rail │ thread) — context rail collapses.
     < 960px:       single column; rail OR thread depending on selection.

   All component-scoped styles (.cv-, .bubble-, .thread-, .composer-, .ctx-)
   land here too because the child components are bundled with this page —
   tiny enough that splitting per-component CSS would add more friction than
   it removes. The cascade is layered top-to-bottom.
*/

.inbox-shell[b-9fqfqqtj4h] {
    display: grid;
    grid-template-columns: 320px minmax(0, 1fr) 320px;
    /* Single row pinned to the container height. Without an explicit row the
       implicit `auto` track grows with content, so a long conversation list or
       message thread would push the column past the viewport and scroll the
       composer/input out of sight. minmax(0, 1fr) caps the row at the shell
       height so the nested .rail-list / .thread-scroller own the overflow. */
    grid-template-rows: minmax(0, 1fr);
    height: calc(100vh - 56px); /* minus top-row */
    background: var(--bg);
    margin: -24px -28px;        /* expand into .content padding */
}

@media (max-width: 1279.98px) {
    .inbox-shell[b-9fqfqqtj4h] {
        grid-template-columns: 320px minmax(0, 1fr);
    }
    .inbox-shell[b-9fqfqqtj4h]  .ctx-rail {
        display: none;
    }
}

@media (max-width: 959.98px) {
    .inbox-shell[b-9fqfqqtj4h] {
        grid-template-columns: minmax(0, 1fr);
    }
    /* No-selection state on mobile: rail visible, thread + context hidden. */
    .inbox-shell.no-selection[b-9fqfqqtj4h]  .rail-root { display: flex; }
    .inbox-shell.no-selection[b-9fqfqqtj4h]  .thread-root,
    .inbox-shell.no-selection[b-9fqfqqtj4h]  .ctx-rail { display: none; }
    .inbox-shell.no-selection .thread-back-mobile[b-9fqfqqtj4h] { display: none; }

    /* Has-selection state on mobile: rail hidden, thread full-screen, with a
       back button to deselect (§I.4 follow-up). */
    .inbox-shell.has-selection[b-9fqfqqtj4h]  .rail-root { display: none; }
    .inbox-shell.has-selection[b-9fqfqqtj4h]  .ctx-rail { display: none; }
    .thread-back-mobile[b-9fqfqqtj4h] { display: inline-block; position: absolute; top: 8px; left: 8px; z-index: 5; background: var(--surface-2); border: 1px solid var(--line); border-radius: 999px; padding: 4px 12px; font-size: 12.5px; color: var(--ink-2); cursor: pointer; }
}

@media (min-width: 960px) {
    /* Mobile back button is mobile-only. */
    .thread-back-mobile[b-9fqfqqtj4h] { display: none; }
}

/* ── Mobile shell geometry ────────────────────────────────────────────────
   The bleed margins above are sized for the desktop .content padding
   (24px/28px). Below 768px .content switches to 16px all round and reserves
   ~72px at the bottom for the fixed bottom nav, so the desktop numbers pushed
   the shell 12px off each edge and — because the height still assumed the full
   viewport — parked the last ~56px of the composer underneath the bottom nav.
   Re-derive both from the mobile padding. */
@media (max-width: 767.98px) {
    .inbox-shell[b-9fqfqqtj4h] {
        /* Bottom margin cancels .content's bottom-nav reservation; the height
           below accounts for the nav instead, so the page never scrolls. */
        margin: -16px -16px calc(-1 * (env(safe-area-inset-bottom, 0px) + 72px));
        height: calc(100vh - 56px);
        height: calc(100dvh - 56px);
    }
}

@media (max-width: 600px) {
    /* The bottom nav is fixed, 64px tall plus the safe-area inset. End the
       shell exactly at its top edge so the composer is always fully visible. */
    .inbox-shell[b-9fqfqqtj4h] {
        height: calc(100vh - 120px);
        height: calc(100dvh - 56px - 64px - env(safe-area-inset-bottom, 0px));
    }
}

/* Compact density — tighten paddings + bubble sizing.
   Per Spec/WAHA_Messaging_UX_Plan.md §I.3 + Phase H.1. */
.inbox-shell.density-compact[b-9fqfqqtj4h]  .cv-row { padding: 6px 12px; }
.inbox-shell.density-compact[b-9fqfqqtj4h]  .cv-avatar { width: 30px; height: 30px; flex-basis: 30px; font-size: 11px; }
.inbox-shell.density-compact[b-9fqfqqtj4h]  .cv-name { font-size: 12.5px; }
.inbox-shell.density-compact[b-9fqfqqtj4h]  .cv-preview { font-size: 11.5px; }
.inbox-shell.density-compact[b-9fqfqqtj4h]  .cv-channel-pill { display: none; }
.inbox-shell.density-compact[b-9fqfqqtj4h]  .bubble { font-size: 12.5px; padding: 6px 10px; }
.inbox-shell.density-compact[b-9fqfqqtj4h]  .thread-scroller { padding: 14px 16px 10px; gap: 3px; }
.inbox-shell.density-compact[b-9fqfqqtj4h]  .thread-header { padding: 10px 16px; }
.inbox-shell.density-compact[b-9fqfqqtj4h]  .composer { padding: 10px 16px; }

/* ── Left rail ────────────────────────────────────────────────────────── */

.inbox-shell[b-9fqfqqtj4h]  .rail-root {
    display: flex;
    flex-direction: column;
    border-right: 1px solid var(--line);
    background: var(--surface);
    min-width: 0;
    min-height: 0;  /* allow the flex column to shrink so .rail-list can scroll */
    height: 100%;
}

.inbox-shell[b-9fqfqqtj4h]  .rail-header {
    padding: 12px;
    border-bottom: 1px solid var(--line);
}

.inbox-shell[b-9fqfqqtj4h]  .rail-search {
    width: 100%;
    height: 36px;
    padding: 0 12px;
    border: 1px solid var(--line);
    border-radius: 6px;
    background: var(--surface-2);
    color: var(--ink);
    font-size: 13px;
}

.inbox-shell[b-9fqfqqtj4h]  .rail-search:focus {
    outline: 2px solid var(--accent);
    outline-offset: -1px;
}

.inbox-shell[b-9fqfqqtj4h]  .rail-chips {
    display: flex;
    gap: 6px;
    padding: 8px 12px;
    border-bottom: 1px solid var(--line);
    overflow-x: auto;
    scrollbar-width: thin;
}

.inbox-shell[b-9fqfqqtj4h]  .rail-chip {
    background: var(--surface-2);
    border: 1px solid var(--line);
    color: var(--ink-2);
    font-size: 12px;
    font-weight: 500;
    padding: 4px 10px;
    border-radius: 999px;
    cursor: pointer;
    white-space: nowrap;
}

.inbox-shell[b-9fqfqqtj4h]  .rail-chip.is-active {
    background: var(--accent-soft);
    border-color: var(--accent);
    color: var(--accent-ink);
}

.inbox-shell[b-9fqfqqtj4h]  .rail-list {
    flex: 1;
    overflow-y: auto;
    padding: 4px 0;
}

.inbox-shell[b-9fqfqqtj4h]  .rail-empty {
    padding: 24px 16px;
    text-align: center;
    color: var(--muted);
    font-size: 13px;
}

.inbox-shell[b-9fqfqqtj4h]  .rail-empty-title {
    font-weight: 600;
    color: var(--ink);
    margin-bottom: 4px;
}

/* ── Conversation row ─────────────────────────────────────────────────── */

.inbox-shell[b-9fqfqqtj4h]  .cv-row {
    display: flex;
    gap: 10px;
    padding: 10px 14px;
    width: 100%;
    border: 0;
    background: transparent;
    text-align: left;
    cursor: pointer;
    border-bottom: 1px solid var(--line);
}

.inbox-shell[b-9fqfqqtj4h]  .cv-row:hover {
    background: var(--surface-2);
}

.inbox-shell[b-9fqfqqtj4h]  .cv-row.is-selected {
    background: var(--accent-soft);
}

.inbox-shell[b-9fqfqqtj4h]  .cv-row.is-unread .cv-name {
    font-weight: 700;
}

.inbox-shell[b-9fqfqqtj4h]  .cv-avatar {
    width: 38px;
    height: 38px;
    border-radius: 50%;
    background: var(--surface-3);
    color: var(--ink);
    font-size: 13px;
    font-weight: 600;
    display: grid;
    place-items: center;
    flex: 0 0 38px;
    overflow: hidden;
}

.inbox-shell[b-9fqfqqtj4h]  .cv-avatar-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 50%;
}

.inbox-shell[b-9fqfqqtj4h]  .cv-body {
    flex: 1;
    min-width: 0;
}

.inbox-shell[b-9fqfqqtj4h]  .cv-line-top,
.inbox-shell[b-9fqfqqtj4h]  .cv-line-bottom {
    display: flex;
    align-items: center;
    gap: 8px;
}

.inbox-shell[b-9fqfqqtj4h]  .cv-name {
    color: var(--ink);
    font-size: 13.5px;
    font-weight: 500;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    flex: 1;
    min-width: 0;
}

.inbox-shell[b-9fqfqqtj4h]  .cv-time {
    color: var(--muted);
    font-size: 11.5px;
    white-space: nowrap;
}

.inbox-shell[b-9fqfqqtj4h]  .cv-preview {
    color: var(--muted);
    font-size: 12.5px;
    flex: 1;
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.inbox-shell[b-9fqfqqtj4h]  .cv-direction {
    color: var(--accent-ink);
    font-weight: 600;
}

.inbox-shell[b-9fqfqqtj4h]  .cv-unread-badge {
    background: var(--accent);
    color: white;
    font-size: 11px;
    font-weight: 700;
    border-radius: 999px;
    padding: 1px 7px;
    line-height: 1.4;
}

.inbox-shell[b-9fqfqqtj4h]  .cv-channel-pill {
    margin-top: 2px;
    display: inline-block;
    color: var(--muted);
    font-size: 10.5px;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

/* Contact-row channel dots — which channels this contact has, lit when unread. */
.inbox-shell[b-9fqfqqtj4h]  .cv-channels {
    margin-top: 3px;
    display: flex;
    gap: 6px;
    align-items: center;
}

.inbox-shell[b-9fqfqqtj4h]  .cv-chan-dot {
    display: inline-grid;
    place-items: center;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    color: var(--muted);
    background: var(--surface-2);
}

.inbox-shell[b-9fqfqqtj4h]  .cv-chan-dot.is-unread {
    color: var(--accent-ink);
    background: var(--accent-soft);
}

.inbox-shell.density-compact[b-9fqfqqtj4h]  .cv-channels { display: none; }

/* ── Unknown (not-yet-customer) threads ───────────────────────────────── */

.inbox-shell[b-9fqfqqtj4h]  .cv-avatar-unknown {
    background: var(--surface-2);
    color: var(--muted);
    border: 1px dashed var(--line);
}

.inbox-shell[b-9fqfqqtj4h]  .cv-unknown-badge {
    display: inline-block;
    margin: 1px 0 2px;
    padding: 0 6px;
    border-radius: 999px;
    font-size: 10px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    color: #92400e;
    background: #fef3c7;
}

/* ── Thread pane ──────────────────────────────────────────────────────── */

.inbox-shell[b-9fqfqqtj4h]  .thread-root {
    display: flex;
    flex-direction: column;
    background: var(--bg);
    min-width: 0;
    min-height: 0;  /* allow the flex column to shrink so .thread-scroller scrolls
                       and the composer stays pinned at the bottom */
    height: 100%;
}

/* Unknown-sender thread chrome */
.inbox-shell[b-9fqfqqtj4h]  .thread-unknown-tag {
    color: #92400e;
    font-weight: 600;
}

.inbox-shell[b-9fqfqqtj4h]  .thread-unknown-banner {
    padding: 8px 16px;
    background: #fffbeb;
    border-bottom: 1px solid #fde68a;
    color: #78350f;
    font-size: 12.5px;
}

.inbox-shell[b-9fqfqqtj4h]  .composer-locked {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    color: var(--muted);
    font-size: 13px;
}

/* Claim ("Add as customer") dialog */
.inbox-shell[b-9fqfqqtj4h]  .claim-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.35);
    display: grid;
    place-items: center;
    z-index: 120;
}

.inbox-shell[b-9fqfqqtj4h]  .claim-dialog {
    width: min(420px, calc(100vw - 32px));
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: 12px;
    padding: 20px;
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.18);
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.inbox-shell[b-9fqfqqtj4h]  .claim-title {
    margin: 0;
    font-size: 16px;
    font-weight: 600;
    color: var(--ink);
}

.inbox-shell[b-9fqfqqtj4h]  .claim-label {
    display: flex;
    flex-direction: column;
    gap: 4px;
    font-size: 12.5px;
    color: var(--ink-2);
}

.inbox-shell[b-9fqfqqtj4h]  .claim-input {
    padding: 8px 10px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: var(--surface);
    color: var(--ink);
    font-size: 14px;
}

.inbox-shell[b-9fqfqqtj4h]  .claim-field {
    display: flex;
    gap: 8px;
    font-size: 13px;
    color: var(--ink);
}

.inbox-shell[b-9fqfqqtj4h]  .claim-field-label {
    color: var(--muted);
    min-width: 72px;
}

.inbox-shell[b-9fqfqqtj4h]  .claim-actions {
    display: flex;
    justify-content: flex-end;
    gap: 8px;
    margin-top: 4px;
}

/* Context rail unknown-sender block */
.inbox-shell[b-9fqfqqtj4h]  .ctx-avatar-unknown {
    background: var(--surface-2);
    color: var(--muted);
    border: 1px dashed var(--line);
}

.inbox-shell[b-9fqfqqtj4h]  .ctx-unknown-hint {
    margin: 12px 0 0;
    color: var(--muted);
    font-size: 12px;
}

.inbox-shell[b-9fqfqqtj4h]  .thread-empty {
    flex: 1;
    display: grid;
    place-items: center;
    color: var(--muted);
    text-align: center;
    padding: 32px;
}

.inbox-shell[b-9fqfqqtj4h]  .thread-empty-title {
    font-size: 15px;
    font-weight: 600;
    color: var(--ink);
    margin-bottom: 4px;
}

.inbox-shell[b-9fqfqqtj4h]  .thread-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 14px 20px;
    border-bottom: 1px solid var(--line);
    background: var(--surface);
    gap: 16px;
}

.inbox-shell[b-9fqfqqtj4h]  .thread-title {
    margin: 0;
    font-size: 15px;
    font-weight: 600;
    color: var(--ink);
}

.inbox-shell[b-9fqfqqtj4h]  .thread-sub {
    margin-top: 2px;
    color: var(--muted);
    font-size: 12px;
    display: flex;
    gap: 6px;
}

.inbox-shell[b-9fqfqqtj4h]  .thread-profile-link {
    color: var(--accent-ink);
    text-decoration: none;
    font-size: 12.5px;
}

/* Channel view toggle (All / WhatsApp / Email) under the thread header. */
.inbox-shell[b-9fqfqqtj4h]  .thread-channel-tabs {
    display: flex;
    gap: 6px;
    padding: 8px 20px;
    border-bottom: 1px solid var(--line);
    background: var(--surface);
}

.inbox-shell[b-9fqfqqtj4h]  .thread-chan-tab {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    background: var(--surface-2);
    border: 1px solid var(--line);
    color: var(--ink-2);
    font-size: 12px;
    font-weight: 500;
    padding: 4px 12px;
    border-radius: 999px;
    cursor: pointer;
}

.inbox-shell[b-9fqfqqtj4h]  .thread-chan-tab.is-active {
    background: var(--accent-soft);
    border-color: var(--accent);
    color: var(--accent-ink);
}

/* Per-bubble channel marker (merged "All" view). */
.inbox-shell[b-9fqfqqtj4h]  .bubble-chan {
    display: inline-flex;
    align-items: center;
    gap: 3px;
    font-size: 10px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.03em;
    opacity: 0.85;
}

.inbox-shell[b-9fqfqqtj4h]  .bubble-chan svg { vertical-align: middle; }

/* Composer send-on channel switch (merged view). A segmented pill where the
   active channel is filled with its brand colour, so the current send target
   is unmistakable and clicking gives obvious feedback. */
.inbox-shell[b-9fqfqqtj4h]  .composer-channel-switch {
    display: inline-flex;
    align-items: center;
    gap: 2px;
    padding: 2px;
    background: var(--surface-2);
    border: 1px solid var(--line);
    border-radius: 999px;
}

.inbox-shell[b-9fqfqqtj4h]  .composer-channel-label {
    font-size: 10px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--muted);
    padding: 0 6px 0 8px;
}

.inbox-shell[b-9fqfqqtj4h]  .composer-chan-btn {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    background: transparent;
    border: 1px solid transparent;
    color: var(--ink-2);
    font-size: 11.5px;
    font-weight: 600;
    padding: 4px 11px;
    border-radius: 999px;
    cursor: pointer;
    transition: background 0.12s ease, color 0.12s ease;
}

.inbox-shell[b-9fqfqqtj4h]  .composer-chan-btn:hover:not(:disabled):not(.is-active) {
    background: var(--surface);
    color: var(--ink);
}

.inbox-shell[b-9fqfqqtj4h]  .composer-chan-btn.is-active[data-channel="whatsapp"] {
    background: var(--wa);
    border-color: var(--wa);
    color: #fff;
}

.inbox-shell[b-9fqfqqtj4h]  .composer-chan-btn.is-active[data-channel="email"] {
    background: var(--info);
    border-color: var(--info);
    color: #fff;
}

.inbox-shell[b-9fqfqqtj4h]  .composer-chan-btn:disabled {
    cursor: not-allowed;
    opacity: 0.6;
}

/* The Send button echoes the active channel's colour — extra confirmation the
   toggle took effect. */
.inbox-shell[b-9fqfqqtj4h]  .composer[data-channel="whatsapp"] .composer-send:not(:disabled) { background: var(--wa); }
.inbox-shell[b-9fqfqqtj4h]  .composer[data-channel="email"] .composer-send:not(:disabled) { background: var(--info); }

.inbox-shell[b-9fqfqqtj4h]  .thread-profile-link:hover {
    text-decoration: underline;
}

.inbox-shell[b-9fqfqqtj4h]  .thread-scroller {
    flex: 1;
    overflow-y: auto;
    padding: 20px 20px 12px;
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.inbox-shell[b-9fqfqqtj4h]  .thread-day {
    align-self: center;
    color: var(--muted);
    font-size: 11.5px;
    background: var(--surface-2);
    padding: 3px 10px;
    border-radius: 999px;
    margin: 12px 0 6px;
}

.inbox-shell[b-9fqfqqtj4h]  .grp-sender {
    font-size: 11px;
    font-weight: 600;
    color: var(--accent-ink);
    margin-left: 4px;
    margin-top: 6px;
    margin-bottom: -2px;
}

.inbox-shell[b-9fqfqqtj4h]  .thread-loadmore {
    display: flex;
    justify-content: center;
    margin-bottom: 8px;
}

/* ── Bubbles ──────────────────────────────────────────────────────────── */

.inbox-shell[b-9fqfqqtj4h]  .bubble-row {
    display: flex;
    width: 100%;
}

.inbox-shell[b-9fqfqqtj4h]  .bubble-row.is-inbound { justify-content: flex-start; }
.inbox-shell[b-9fqfqqtj4h]  .bubble-row.is-outbound { justify-content: flex-end; }

.inbox-shell[b-9fqfqqtj4h]  .bubble {
    max-width: 70%;
    padding: 8px 12px;
    border-radius: 12px;
    font-size: 13.5px;
    line-height: 1.4;
    box-shadow: 0 1px 0 rgba(0,0,0,0.03);
}

.inbox-shell[b-9fqfqqtj4h]  .bubble-in {
    background: var(--surface);
    color: var(--ink);
    border: 1px solid var(--line);
    border-top-left-radius: 4px;
}

.inbox-shell[b-9fqfqqtj4h]  .bubble-out {
    background: var(--accent);
    color: white;
    border-top-right-radius: 4px;
}

.inbox-shell[b-9fqfqqtj4h]  .bubble-failed {
    background: var(--danger);
    color: #fff;
}

.inbox-shell[b-9fqfqqtj4h]  .bubble-content {
    white-space: pre-wrap;
    word-wrap: break-word;
}

.inbox-shell[b-9fqfqqtj4h]  .bubble-meta {
    margin-top: 4px;
    display: flex;
    justify-content: flex-end;
    align-items: center;
    gap: 4px;
    font-size: 10.5px;
    opacity: 0.8;
}

.inbox-shell[b-9fqfqqtj4h]  .bubble-out .bubble-time,
.inbox-shell[b-9fqfqqtj4h]  .bubble-out .bubble-ticks {
    color: rgba(255,255,255,0.85);
}

/* Read / opened / clicked — solid white ticks so "engaged" reads a step
   brighter than "delivered" (0.85). Outbound bubbles carry a saturated brand
   fill (WhatsApp green / email blue), so a literal WhatsApp-style blue tick
   would vanish on the blue email bubble; full-opacity white is the legible
   cross-channel signal. */
.inbox-shell[b-9fqfqqtj4h]  .bubble-out .bubble-ticks.is-read {
    color: #fff;
    font-weight: 700;
}

/* ── Per-channel bubble identity ──────────────────────────────────────────
   Makes WhatsApp vs Email obvious at a glance, especially in the merged
   "All" thread. Outbound bubbles take the channel's brand fill; inbound
   bubbles stay light with a coloured left edge. .bubble-failed keeps its
   danger fill (it is not overridden here). */
.inbox-shell[b-9fqfqqtj4h]  .bubble-out.chan-whatsapp:not(.bubble-failed) { background: var(--wa); }
.inbox-shell[b-9fqfqqtj4h]  .bubble-out.chan-email:not(.bubble-failed)    { background: var(--info); }

.inbox-shell[b-9fqfqqtj4h]  .bubble-in.chan-whatsapp { border-left: 3px solid var(--wa); }
.inbox-shell[b-9fqfqqtj4h]  .bubble-in.chan-email    { border-left: 3px solid var(--info); }

/* Channel chip in the meta line — brand-coloured on light inbound bubbles,
   light on the filled outbound bubbles. */
.inbox-shell[b-9fqfqqtj4h]  .bubble-in.chan-whatsapp .bubble-chan { color: var(--wa-ink); opacity: 1; }
.inbox-shell[b-9fqfqqtj4h]  .bubble-in.chan-email .bubble-chan    { color: var(--info-ink); opacity: 1; }
.inbox-shell[b-9fqfqqtj4h]  .bubble-out .bubble-chan              { color: rgba(255,255,255,0.92); opacity: 1; }

.inbox-shell[b-9fqfqqtj4h]  .bubble-error {
    margin-top: 4px;
    font-size: 11.5px;
    color: white;
    opacity: 0.9;
}

/* ── Composer ─────────────────────────────────────────────────────────── */

.inbox-shell[b-9fqfqqtj4h]  .composer {
    border-top: 1px solid var(--line);
    background: var(--surface);
    padding: 12px 20px;
    flex: 0 0 auto;
}

.inbox-shell[b-9fqfqqtj4h]  .composer-toolbar {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 4px;
    margin-bottom: 6px;
}

.inbox-shell[b-9fqfqqtj4h]  .composer-row {
    display: flex;
    gap: 10px;
    align-items: flex-end;
}

.inbox-shell[b-9fqfqqtj4h]  .composer-input {
    /* width, not flex: the parent .composer-input-wrap is a positioned BLOCK
       (it anchors the saved-replies palette), so `flex: 1` never applied and the
       textarea fell back to its intrinsic cols=20 width — ~165px that spilled
       straight over the attach/schedule/send buttons on a narrow screen. */
    width: 100%;
    flex: 1;
    min-width: 0;
    resize: none;
    padding: 8px 12px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: var(--surface-2);
    color: var(--ink);
    font-size: 13.5px;
    line-height: 1.4;
    font-family: inherit;
}

.inbox-shell[b-9fqfqqtj4h]  .composer-input:focus {
    outline: 2px solid var(--accent);
    outline-offset: -1px;
}

.inbox-shell[b-9fqfqqtj4h]  .composer-actions {
    display: flex;
    gap: 6px;
    flex: 0 0 auto;
}

/* inline-grid, not the default inline box: attach + voice-note are <label>s, and
   an inline element ignores width/height — they rendered shrink-wrapped around
   their icon and baseline-aligned, a few px shorter than the <button> beside
   them. Explicit color keeps the icons legible in dark mode (a bare <button>
   does not inherit it). */
.inbox-shell[b-9fqfqqtj4h]  .composer-icon-btn {
    display: inline-grid;
    place-items: center;
    flex: 0 0 auto;
    width: 36px;
    height: 36px;
    border-radius: 8px;
    border: 1px solid var(--line);
    background: var(--surface-2);
    color: var(--ink-2);
    cursor: pointer;
    font-size: 16px;
    line-height: 1;
}

.inbox-shell[b-9fqfqqtj4h]  .composer-icon-btn:hover {
    background: var(--surface-3);
}

.inbox-shell[b-9fqfqqtj4h]  .composer-send {
    height: 36px;
    padding: 0 16px;
    border: 0;
    border-radius: 8px;
    background: var(--accent);
    color: white;
    font-weight: 600;
    font-size: 13px;
    cursor: pointer;
}

.inbox-shell[b-9fqfqqtj4h]  .composer-send:disabled {
    background: var(--surface-3);
    color: var(--muted);
    cursor: not-allowed;
}

.inbox-shell[b-9fqfqqtj4h]  .composer-locked {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
    padding: 10px 12px;
    background: var(--surface-2);
    border: 1px solid var(--line);
    border-radius: 8px;
    font-size: 13px;
    color: var(--ink-2);
}

.inbox-shell[b-9fqfqqtj4h]  .composer-schedule {
    margin-top: 8px;
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 12.5px;
    color: var(--ink-2);
}

.inbox-shell[b-9fqfqqtj4h]  .composer-schedule input[type="datetime-local"] {
    padding: 4px 8px;
    border: 1px solid var(--line);
    border-radius: 6px;
    background: var(--surface);
    color: var(--ink);
}

.inbox-shell[b-9fqfqqtj4h]  .composer-hint {
    margin-top: 8px;
    font-size: 11.5px;
    color: var(--warn-ink);
}

/* ── 24-hour window chip + forced template mode ───────────────────────────
   Dev_Docs/WhatsApp_Template_Approval_Flow_Plan.md §Phase 3. */

.inbox-shell[b-9fqfqqtj4h]  .composer-window {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    margin-bottom: 6px;
    padding: 3px 10px;
    border-radius: 999px;
    font-size: 11.5px;
    font-weight: 600;
    border: 1px solid var(--line);
}

.inbox-shell[b-9fqfqqtj4h]  .composer-window.is-open {
    color: var(--ok-ink, var(--ink-2));
    background: var(--ok-bg, var(--surface-2));
}

.inbox-shell[b-9fqfqqtj4h]  .composer-window.is-closed {
    color: var(--warn-ink);
    background: var(--warn-bg, var(--surface-2));
}

.inbox-shell[b-9fqfqqtj4h]  .composer-template {
    display: flex;
    flex-direction: column;
    gap: 8px;
    padding: 10px 12px;
    background: var(--surface-2);
    border: 1px solid var(--line);
    border-radius: 8px;
}

.inbox-shell[b-9fqfqqtj4h]  .composer-template-info {
    font-size: 12.5px;
    color: var(--ink-2);
}

.inbox-shell[b-9fqfqqtj4h]  .composer-template-empty {
    font-size: 12.5px;
    color: var(--muted);
}

.inbox-shell[b-9fqfqqtj4h]  .composer-template-form {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.inbox-shell[b-9fqfqqtj4h]  .composer-template-form .composer-send {
    align-self: flex-end;
}

.inbox-shell[b-9fqfqqtj4h]  .composer-template-preview {
    padding: 8px 10px;
    border: 1px dashed var(--line);
    border-radius: 8px;
    background: var(--surface);
    font-size: 12.5px;
    color: var(--ink);
    white-space: pre-wrap;
}

.inbox-shell[b-9fqfqqtj4h]  .composer-attachment {
    margin-top: 8px;
    display: inline-flex;
    align-items: center;
    max-width: 100%;
    gap: 8px;
    padding: 4px 10px;
    background: var(--surface-2);
    border: 1px solid var(--line);
    border-radius: 999px;
    font-size: 12px;
    color: var(--ink-2);
}
/* Only the filename gives way — the size and the remove link stay readable. */
.inbox-shell[b-9fqfqqtj4h]  .composer-attachment-name {
    font-weight: 600;
    color: var(--ink);
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.inbox-shell[b-9fqfqqtj4h]  .composer-attachment-size { color: var(--muted); flex: 0 0 auto; }
.inbox-shell[b-9fqfqqtj4h]  .composer-attachment > svg,
.inbox-shell[b-9fqfqqtj4h]  .composer-attachment .btn-link { flex: 0 0 auto; }

/* ── Saved-replies palette (C.5) ──────────────────────────────────────── */

.inbox-shell[b-9fqfqqtj4h]  .composer-input-wrap {
    position: relative;
    flex: 1;
    min-width: 0;
}

.inbox-shell[b-9fqfqqtj4h]  .palette {
    position: absolute;
    bottom: calc(100% + 6px);
    left: 0;
    right: 0;
    max-height: 240px;
    overflow-y: auto;
    background: var(--surface);
    border: 1px solid var(--line-strong);
    border-radius: 8px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12);
    z-index: 20;
}

.inbox-shell[b-9fqfqqtj4h]  .palette-empty {
    padding: 10px 12px;
    color: var(--muted);
    font-size: 12.5px;
}

.inbox-shell[b-9fqfqqtj4h]  .palette-item {
    width: 100%;
    text-align: left;
    background: transparent;
    border: 0;
    border-bottom: 1px solid var(--line);
    padding: 8px 12px;
    cursor: pointer;
}

.inbox-shell[b-9fqfqqtj4h]  .palette-item:last-child { border-bottom: 0; }

.inbox-shell[b-9fqfqqtj4h]  .palette-item.is-active,
.inbox-shell[b-9fqfqqtj4h]  .palette-item:hover {
    background: var(--accent-soft);
}

.inbox-shell[b-9fqfqqtj4h]  .palette-item-name {
    font-size: 13px;
    font-weight: 600;
    color: var(--ink);
}

.inbox-shell[b-9fqfqqtj4h]  .palette-item-preview {
    font-size: 11.5px;
    color: var(--muted);
    margin-top: 2px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

/* ── Composer on phones ───────────────────────────────────────────────────
   One row cannot hold a textarea, three icon buttons and a "Send · WhatsApp"
   button at 390px. The actions block will not shrink below its content, so the
   input wrap was squeezed to ~98px — narrower than the textarea inside it,
   which is what put the message box on top of the attach button. Stack instead:
   message box on its own line, actions on a second line with Send pinned right,
   and the format toolbar scrolls sideways rather than wrapping into three rows
   that eat the thread.

   Placed after the desktop rules above: same specificity, so source order wins. */
@media (max-width: 600px) {
    .inbox-shell[b-9fqfqqtj4h]  .composer {
        padding: 8px 12px 10px;
    }

    .inbox-shell[b-9fqfqqtj4h]  .composer-toolbar {
        flex-wrap: nowrap;
        overflow-x: auto;
        scrollbar-width: none;
        -webkit-overflow-scrolling: touch;
    }

    .inbox-shell[b-9fqfqqtj4h]  .composer-toolbar::-webkit-scrollbar { display: none; }

    /* Nothing in the toolbar squashes — it scrolls instead. */
    .inbox-shell[b-9fqfqqtj4h]  .composer-toolbar > * { flex: 0 0 auto; }

    /* Drop the visible "Send via" caption: the two brand-coloured pills say it,
       and the ~70px it costs is what pushed the formatting buttons out of view.
       The group keeps its aria-label, so screen readers lose nothing. */
    .inbox-shell[b-9fqfqqtj4h]  .composer-channel-label { display: none; }
    .inbox-shell[b-9fqfqqtj4h]  .composer-channel-switch { padding-left: 2px; }

    .inbox-shell[b-9fqfqqtj4h]  .composer-row {
        flex-wrap: wrap;
        gap: 8px;
    }

    .inbox-shell[b-9fqfqqtj4h]  .composer-input-wrap { flex: 1 1 100%; }

    /* 16px keeps iOS Safari from zooming the page on focus — that zoom shifted
       the whole pinned composer sideways under the keyboard. */
    .inbox-shell[b-9fqfqqtj4h]  .composer-input,
    .inbox-shell[b-9fqfqqtj4h]  .composer-template .form-select,
    .inbox-shell[b-9fqfqqtj4h]  .composer-template .form-control,
    .inbox-shell[b-9fqfqqtj4h]  .composer-schedule input[type="datetime-local"] {
        font-size: 16px;
    }

    .inbox-shell[b-9fqfqqtj4h]  .composer-actions {
        flex: 1 1 100%;
        align-items: center;
    }

    /* Icons stay grouped at the left; Send claims the right end of the row. */
    .inbox-shell[b-9fqfqqtj4h]  .composer-actions .composer-send {
        margin-left: auto;
        max-width: 60%;
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap;
    }

    /* Comfortable thumb targets now that there is room for them. */
    .inbox-shell[b-9fqfqqtj4h]  .composer-icon-btn { width: 40px; height: 40px; }
    .inbox-shell[b-9fqfqqtj4h]  .composer-send { height: 40px; }

    /* Pill radius looks broken once the label wraps to two lines. */
    .inbox-shell[b-9fqfqqtj4h]  .composer-window {
        display: flex;
        border-radius: 10px;
        line-height: 1.35;
    }

    .inbox-shell[b-9fqfqqtj4h]  .composer-schedule {
        flex-wrap: wrap;
        margin-top: 6px;
    }

    .inbox-shell[b-9fqfqqtj4h]  .composer-schedule label {
        display: flex;
        align-items: center;
        gap: 8px;
        flex: 1 1 100%;
    }

    .inbox-shell[b-9fqfqqtj4h]  .composer-schedule input[type="datetime-local"] {
        flex: 1 1 auto;
        min-width: 0;
    }

    /* Full-width send in forced-template mode — it is the only action there. */
    .inbox-shell[b-9fqfqqtj4h]  .composer-template-form .composer-send {
        align-self: stretch;
        max-width: none;
    }
}

/* ── Customer context rail ────────────────────────────────────────────── */

.inbox-shell[b-9fqfqqtj4h]  .ctx-rail {
    border-left: 1px solid var(--line);
    background: var(--surface);
    overflow-y: auto;
    min-height: 0;  /* bound the grid item so its own overflow scrolls */
    padding: 20px 18px;
}

.inbox-shell[b-9fqfqqtj4h]  .ctx-empty {
    color: var(--muted);
    font-size: 13px;
    text-align: center;
    margin-top: 32px;
}

.inbox-shell[b-9fqfqqtj4h]  .ctx-header {
    display: flex;
    gap: 10px;
    align-items: center;
    margin-bottom: 16px;
}

.inbox-shell[b-9fqfqqtj4h]  .ctx-avatar {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: var(--surface-3);
    color: var(--ink);
    font-weight: 600;
    display: grid;
    place-items: center;
    flex: 0 0 44px;
    font-size: 14px;
    overflow: hidden;
}

.inbox-shell[b-9fqfqqtj4h]  .ctx-avatar-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 50%;
}

.inbox-shell[b-9fqfqqtj4h]  .ctx-name {
    font-size: 15px;
    font-weight: 600;
    color: var(--ink);
}

.inbox-shell[b-9fqfqqtj4h]  .ctx-sub {
    font-size: 12px;
    color: var(--muted);
    margin-top: 2px;
}

.inbox-shell[b-9fqfqqtj4h]  .ctx-list {
    display: grid;
    grid-template-columns: 80px 1fr;
    row-gap: 10px;
    column-gap: 8px;
    margin: 16px 0;
    font-size: 12.5px;
}

.inbox-shell[b-9fqfqqtj4h]  .ctx-list dt {
    color: var(--muted);
    font-weight: 500;
}

.inbox-shell[b-9fqfqqtj4h]  .ctx-list dd {
    color: var(--ink);
    margin: 0;
    word-break: break-word;
}

.inbox-shell[b-9fqfqqtj4h]  .ctx-consent-badge {
    display: inline-block;
    padding: 2px 8px;
    border-radius: 999px;
    font-size: 11px;
    font-weight: 600;
}

.inbox-shell[b-9fqfqqtj4h]  .ctx-consent-optedin   { background: var(--accent-soft); color: var(--accent-ink); }
.inbox-shell[b-9fqfqqtj4h]  .ctx-consent-optedout  { background: var(--danger-soft); color: var(--danger-ink); }
.inbox-shell[b-9fqfqqtj4h]  .ctx-consent-notasked  { background: var(--surface-2); color: var(--ink-2); }

.inbox-shell[b-9fqfqqtj4h]  .ctx-consent-source {
    font-size: 11px;
    color: var(--muted);
    margin-top: 4px;
}

.inbox-shell[b-9fqfqqtj4h]  .ctx-section {
    margin-top: 16px;
    border-top: 1px solid var(--line);
    padding-top: 12px;
}

.inbox-shell[b-9fqfqqtj4h]  .ctx-section-title {
    margin: 0 0 6px;
    font-size: 11.5px;
    font-weight: 600;
    color: var(--muted);
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.inbox-shell[b-9fqfqqtj4h]  .ctx-notes {
    white-space: pre-wrap;
    margin: 0;
    color: var(--ink);
    font-size: 12.5px;
    line-height: 1.5;
}

.inbox-shell[b-9fqfqqtj4h]  .ctx-actions {
    margin-top: 16px;
    display: flex;
    gap: 8px;
}
/* /Shared/BizGoLogo.razor.rz.scp.css */
.bizgo-logo[b-ci7tqqxzkl] {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    line-height: 1;
}

.bizgo-mark[b-ci7tqqxzkl] {
    display: block;
    flex-shrink: 0;
    /* Subtle teal lift, scaled down from the brand sheet's display shadow. */
    filter: drop-shadow(0 4px 10px rgba(10, 169, 194, 0.25));
}

.bizgo-wm[b-ci7tqqxzkl] {
    font-family: 'Sora', 'Geist', -apple-system, system-ui, sans-serif;
    font-weight: 800;
    letter-spacing: -0.04em;
    line-height: 1;
    /* "Biz" follows the theme ink so the lockup works on light and dark. */
    color: var(--ink);
    white-space: nowrap;
}

/* "Go" always carries the fixed brand accent gradient (Emerald → Teal). */
.bizgo-wm .go[b-ci7tqqxzkl] {
    background: linear-gradient(118deg, #19c88f, #0aa3c4);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    color: transparent;
}
