.lookup-page {
    max-width: 1080px;
    margin: 0 auto;
    animation: fadeInUp 0.45s ease;
    padding: 0 0.25rem;
}

.page-workspace-bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    margin: 0 0 0.85rem;
}

.page-workspace-bar__start {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 0.4rem 0.55rem;
    min-width: 0;
}

.page-workspace-bar__title {
    margin: 0;
    font-size: 1.125rem;
    font-weight: 700;
    letter-spacing: -0.02em;
    line-height: 1.2;
}

.labels-page {
    max-width: 1080px;
}

.labels-page .label-queue-panel {
    margin-top: 0;
}

.page-help {
    position: relative;
    flex-shrink: 0;
}

.page-help__trigger {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 2.25rem;
    height: 2.25rem;
    border: none;
    border-radius: var(--radius-md);
    background: transparent;
    color: var(--color-text-muted);
    cursor: pointer;
}

.page-help__trigger:hover {
    background: var(--color-surface-muted);
    color: var(--color-text);
}

.page-help__backdrop {
    position: fixed;
    inset: 0;
    z-index: 240;
    border: none;
    padding: 0;
    background: transparent;
    cursor: default;
}

.page-help__panel {
    position: absolute;
    top: calc(100% + 0.35rem);
    right: 0;
    z-index: 250;
    width: min(26rem, calc(100vw - 2rem));
    padding: 0.85rem 1rem 1rem;
    border: 1px solid var(--color-border);
    border-radius: var(--radius-lg);
    background: var(--color-surface);
    box-shadow: var(--shadow-lg);
}

.page-help__header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 0.75rem;
    margin-bottom: 0.65rem;
}

.page-help__title {
    margin: 0;
    font-size: 0.95rem;
    font-weight: 700;
}

.page-help__close {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 1.75rem;
    height: 1.75rem;
    border: none;
    border-radius: var(--radius-md);
    background: transparent;
    color: var(--color-text-muted);
    cursor: pointer;
}

.page-help__body {
    font-size: 0.875rem;
    color: var(--color-text-secondary);
    max-height: min(70vh, 36rem);
    overflow-y: auto;
}

.page-help__panel:has(.pos-register-help) {
    width: min(32rem, calc(100vw - 2rem));
}

.lookup-filters {
    margin-top: 0.85rem;
}

.lookup-filters__toolbar {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.5rem 0.75rem;
}

.lookup-filters__toggle {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    margin: 0;
    padding: 0.3rem 0.15rem;
    border: none;
    background: transparent;
    color: var(--color-text-muted);
    font-size: 0.8125rem;
    font-weight: 600;
    font-family: inherit;
    cursor: pointer;
}

.lookup-filters__toggle:hover:not(:disabled) {
    color: var(--color-text);
}

.lookup-filters__count {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 1.15rem;
    height: 1.15rem;
    padding: 0 0.3rem;
    border-radius: 999px;
    background: var(--color-surface-muted);
    color: var(--color-text);
    font-size: 0.6875rem;
}

.lookup-filters__chevron {
    font-size: 0.7rem;
    transition: transform var(--transition);
}

.lookup-filters__chevron--open {
    transform: rotate(90deg);
}

.lookup-filters__chips {
    display: flex;
    flex-wrap: wrap;
    gap: 0.35rem;
}

.lookup-filters__chip {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    margin: 0;
    padding: 0.25rem 0.55rem;
    border: 1px solid var(--color-border);
    border-radius: 999px;
    background: var(--color-surface);
    color: var(--color-text);
    font-size: 0.75rem;
    font-weight: 600;
    font-family: inherit;
    cursor: pointer;
}

.lookup-filters__chip:hover:not(:disabled) {
    background: var(--color-surface-muted);
}

.lookup-filters__panel {
    margin-top: 0.75rem;
    padding-top: 0.75rem;
    border-top: 1px solid var(--color-border);
}

/* ── Inline UI icons ──────────────────────────────────────────────────────────
   CSS-mask based (not <img>/fill'd SVG) so every icon inherits `currentColor`
   automatically -- one icon works unchanged across button/muted-text/badge
   contexts and hover/disabled states, replacing ad-hoc emoji glyphs that
   rendered inconsistently across OS emoji fonts. */
.ui-icon {
    display: inline-block;
    flex-shrink: 0;
    width: 1em;
    height: 1em;
    background-color: currentColor;
    -webkit-mask-repeat: no-repeat;
    mask-repeat: no-repeat;
    -webkit-mask-position: center;
    mask-position: center;
    -webkit-mask-size: contain;
    mask-size: contain;
    vertical-align: -0.15em;
}

.ui-icon--scan {
    -webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Crect x='1' y='2' width='1.5' height='12'/%3E%3Crect x='4' y='2' width='1' height='12'/%3E%3Crect x='6.5' y='2' width='2' height='12'/%3E%3Crect x='10' y='2' width='1' height='12'/%3E%3Crect x='12.5' y='2' width='2.5' height='12'/%3E%3C/svg%3E");
    mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Crect x='1' y='2' width='1.5' height='12'/%3E%3Crect x='4' y='2' width='1' height='12'/%3E%3Crect x='6.5' y='2' width='2' height='12'/%3E%3Crect x='10' y='2' width='1' height='12'/%3E%3Crect x='12.5' y='2' width='2.5' height='12'/%3E%3C/svg%3E");
}

.ui-icon--camera {
    -webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Crect x='1' y='4' width='14' height='10' rx='1.75'/%3E%3Crect x='5.5' y='1.5' width='5' height='2.5' rx='0.6'/%3E%3Ccircle cx='8' cy='9' r='2.75' fill='white'/%3E%3C/svg%3E");
    mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Crect x='1' y='4' width='14' height='10' rx='1.75'/%3E%3Crect x='5.5' y='1.5' width='5' height='2.5' rx='0.6'/%3E%3Ccircle cx='8' cy='9' r='2.75' fill='white'/%3E%3C/svg%3E");
}

.ui-icon--close {
    -webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath d='M3 3l10 10M13 3L3 13' fill='none' stroke='black' stroke-width='2' stroke-linecap='round'/%3E%3C/svg%3E");
    mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath d='M3 3l10 10M13 3L3 13' fill='none' stroke='black' stroke-width='2' stroke-linecap='round'/%3E%3C/svg%3E");
}

.ui-icon--chart {
    -webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Crect x='1' y='9' width='3' height='6'/%3E%3Crect x='6.5' y='5' width='3' height='10'/%3E%3Crect x='12' y='2' width='3' height='13'/%3E%3C/svg%3E");
    mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Crect x='1' y='9' width='3' height='6'/%3E%3Crect x='6.5' y='5' width='3' height='10'/%3E%3Crect x='12' y='2' width='3' height='13'/%3E%3C/svg%3E");
}

.ui-icon--trend {
    -webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpolyline points='1,13 6,7 9,10 15,2' fill='none' stroke='black' stroke-width='1.7' stroke-linecap='round' stroke-linejoin='round'/%3E%3Cpolyline points='10.5,2 15,2 15,6.5' fill='none' stroke='black' stroke-width='1.7' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
    mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpolyline points='1,13 6,7 9,10 15,2' fill='none' stroke='black' stroke-width='1.7' stroke-linecap='round' stroke-linejoin='round'/%3E%3Cpolyline points='10.5,2 15,2 15,6.5' fill='none' stroke='black' stroke-width='1.7' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
}

.ui-icon--tag {
    -webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath d='M2 2h6.5l6 6-6.5 6.5-6-6z'/%3E%3Ccircle cx='5' cy='5' r='1.15' fill='white'/%3E%3C/svg%3E");
    mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath d='M2 2h6.5l6 6-6.5 6.5-6-6z'/%3E%3Ccircle cx='5' cy='5' r='1.15' fill='white'/%3E%3C/svg%3E");
}

.ui-icon--cart {
    -webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath d='M0 1.5A.5.5 0 0 1 .5 1H2a.5.5 0 0 1 .485.379L2.89 3H14.5a.5.5 0 0 1 .491.592l-1.5 8A.5.5 0 0 1 13 12H4a.5.5 0 0 1-.491-.408L2.01 3.607 1.61 2H.5a.5.5 0 0 1-.5-.5zM5 12a2 2 0 1 0 0 4 2 2 0 0 0 0-4zm7 0a2 2 0 1 0 0 4 2 2 0 0 0 0-4z'/%3E%3C/svg%3E");
    mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath d='M0 1.5A.5.5 0 0 1 .5 1H2a.5.5 0 0 1 .485.379L2.89 3H14.5a.5.5 0 0 1 .491.592l-1.5 8A.5.5 0 0 1 13 12H4a.5.5 0 0 1-.491-.408L2.01 3.607 1.61 2H.5a.5.5 0 0 1-.5-.5zM5 12a2 2 0 1 0 0 4 2 2 0 0 0 0-4zm7 0a2 2 0 1 0 0 4 2 2 0 0 0 0-4z'/%3E%3C/svg%3E");
}

.ui-icon--search {
    -webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath d='M11.742 10.344a6.5 6.5 0 1 0-1.397 1.398h-.001q.044.06.098.115l3.85 3.85a1 1 0 0 0 1.415-1.414l-3.85-3.85a1.007 1.007 0 0 0-.115-.1zM12 6.5a5.5 5.5 0 1 1-11 0 5.5 5.5 0 0 1 11 0z'/%3E%3C/svg%3E");
    mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath d='M11.742 10.344a6.5 6.5 0 1 0-1.397 1.398h-.001q.044.06.098.115l3.85 3.85a1 1 0 0 0 1.415-1.414l-3.85-3.85a1.007 1.007 0 0 0-.115-.1zM12 6.5a5.5 5.5 0 1 1-11 0 5.5 5.5 0 0 1 11 0z'/%3E%3C/svg%3E");
}

.ui-icon--warning {
    -webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath d='M8 1.2l7.2 12.8H.8z'/%3E%3C/svg%3E");
    mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath d='M8 1.2l7.2 12.8H.8z'/%3E%3C/svg%3E");
}

.ui-icon--info {
    -webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Ccircle cx='8' cy='8' r='7'/%3E%3C/svg%3E");
    mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Ccircle cx='8' cy='8' r='7'/%3E%3C/svg%3E");
}

.ui-icon--chevron {
    -webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath d='M4 2l7 6-7 6' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
    mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath d='M4 2l7 6-7 6' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
}

.ui-icon--globe {
    -webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Ccircle cx='8' cy='8' r='6.5' fill='none' stroke='black' stroke-width='1.5'/%3E%3Cellipse cx='8' cy='8' rx='3' ry='6.5' fill='none' stroke='black' stroke-width='1.5'/%3E%3Cpath d='M1.5 8h13M2.5 5h11M2.5 11h11' fill='none' stroke='black' stroke-width='1.2'/%3E%3C/svg%3E");
    mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Ccircle cx='8' cy='8' r='6.5' fill='none' stroke='black' stroke-width='1.5'/%3E%3Cellipse cx='8' cy='8' rx='3' ry='6.5' fill='none' stroke='black' stroke-width='1.5'/%3E%3Cpath d='M1.5 8h13M2.5 5h11M2.5 11h11' fill='none' stroke='black' stroke-width='1.2'/%3E%3C/svg%3E");
}

.ui-icon--menu {
    -webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath d='M2 4h12M2 8h12M2 12h12' fill='none' stroke='black' stroke-width='2' stroke-linecap='round'/%3E%3C/svg%3E");
    mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath d='M2 4h12M2 8h12M2 12h12' fill='none' stroke='black' stroke-width='2' stroke-linecap='round'/%3E%3C/svg%3E");
}

.ui-icon--help {
    -webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Ccircle cx='8' cy='8' r='6.5' fill='none' stroke='black' stroke-width='1.6'/%3E%3Cpath d='M6.2 6.1a1.8 1.8 0 1 1 2.55 1.64c-.5.3-.85.78-.85 1.36V9.6' fill='none' stroke='black' stroke-width='1.5' stroke-linecap='round'/%3E%3Ccircle cx='8' cy='12' r='0.85'/%3E%3C/svg%3E");
    mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Ccircle cx='8' cy='8' r='6.5' fill='none' stroke='black' stroke-width='1.6'/%3E%3Cpath d='M6.2 6.1a1.8 1.8 0 1 1 2.55 1.64c-.5.3-.85.78-.85 1.36V9.6' fill='none' stroke='black' stroke-width='1.5' stroke-linecap='round'/%3E%3Ccircle cx='8' cy='12' r='0.85'/%3E%3C/svg%3E");
}

.ui-icon--more {
    -webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Ccircle cx='3.5' cy='8' r='1.4'/%3E%3Ccircle cx='8' cy='8' r='1.4'/%3E%3Ccircle cx='12.5' cy='8' r='1.4'/%3E%3C/svg%3E");
    mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Ccircle cx='3.5' cy='8' r='1.4'/%3E%3Ccircle cx='8' cy='8' r='1.4'/%3E%3Ccircle cx='12.5' cy='8' r='1.4'/%3E%3C/svg%3E");
}

.ui-icon--theme {
    -webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath d='M8 1.2a6.8 6.8 0 1 0 0 13.6A6.8 6.8 0 0 0 8 1.2z' fill='none' stroke='black' stroke-width='1.4'/%3E%3Cpath d='M8 1.2v13.6M8 1.2a6.8 6.8 0 0 1 0 13.6A6.8 6.8 0 0 1 8 1.2z' fill='black'/%3E%3C/svg%3E");
    mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath d='M8 1.2a6.8 6.8 0 1 0 0 13.6A6.8 6.8 0 0 0 8 1.2z' fill='none' stroke='black' stroke-width='1.4'/%3E%3Cpath d='M8 1.2v13.6M8 1.2a6.8 6.8 0 0 1 0 13.6A6.8 6.8 0 0 1 8 1.2z' fill='black'/%3E%3C/svg%3E");
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(12px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.lookup-hero {
    margin-bottom: 2rem;
}

.lookup-hero--compact {
    margin-bottom: 1.25rem;
}

.lookup-hero--compact h1 {
    font-size: clamp(1.65rem, 3.5vw, 2.15rem);
    margin-bottom: 0.5rem;
}

.lookup-hero--compact .lead {
    font-size: 1rem;
    margin-bottom: 0;
}

.lookup-hero__eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 0.75rem;
    padding: 0.35rem 0.85rem;
    border-radius: 999px;
    background: var(--color-brand-soft);
    color: var(--color-brand-hover);
    font-size: 0.6875rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.lookup-hero__trust {
    margin-top: 1rem;
    font-size: 0.8125rem;
    color: var(--color-text-muted);
    letter-spacing: 0.01em;
}

.lookup-hero h1 {
    font-size: clamp(1.85rem, 4vw, 2.5rem);
    font-weight: 700;
    line-height: 1.15;
    margin-bottom: 0.75rem;
}

.lookup-hero .lead {
    font-size: 1.05rem;
    color: var(--color-text-secondary);
    max-width: 38rem;
    line-height: 1.6;
}

.lookup-hero__features {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-top: 1.25rem;
}

.search-card {
    border: 1px solid var(--color-border);
    border-radius: var(--radius-xl);
    background: var(--color-surface);
    box-shadow: none;
    overflow: visible;
    position: relative;
}

.search-card .card-body {
    padding: 1.15rem;
}

/* ── Search composer (Phase A) ─────────────────────────────────────────────── */

.search-composer {
    margin-bottom: 0.5rem;
}

.search-composer__form {
    display: block;
}

.search-composer__row {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    align-items: stretch;
}

.search-composer__input-wrap {
    position: relative;
    flex: 1 1 280px;
    min-width: 0;
}

.search-composer__input {
    width: 100%;
    padding: 0.9rem 7.5rem 0.9rem 1rem;
    font-size: 1.05rem;
    font-variant-numeric: tabular-nums;
    border-radius: var(--radius-lg);
    border: 1px solid var(--color-border);
}

.search-composer__input:focus {
    border-color: rgba(20, 184, 166, 0.45);
    box-shadow: 0 0 0 3px rgba(20, 184, 166, 0.12);
}

.search-composer__adornments {
    position: absolute;
    top: 50%;
    right: 0.35rem;
    transform: translateY(-50%);
    display: inline-flex;
    align-items: center;
    gap: 0.15rem;
}

.search-composer__icon-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 2.25rem;
    height: 2.25rem;
    border: none;
    border-radius: var(--radius-md);
    background: transparent;
    color: var(--color-brand);
    cursor: pointer;
    transition: background var(--transition), color var(--transition);
}

.search-composer__icon-btn:hover:not(:disabled) {
    background: var(--color-brand-soft);
}

.search-composer__icon-btn:disabled {
    opacity: 0.45;
    cursor: not-allowed;
}

.search-composer__icon-btn--muted {
    color: var(--color-text-muted);
}

.search-composer__icon-btn .ui-icon {
    font-size: 1.1rem;
}

.search-composer__actions--desktop {
    display: flex;
    align-items: stretch;
    gap: 0.5rem;
}

.search-composer__actions--mobile {
    display: none;
    margin-top: 0.75rem;
}

.search-composer__analyze {
    white-space: nowrap;
    padding-left: 1.35rem;
    padding-right: 1.35rem;
}

.search-composer__cancel {
    padding-left: 0.85rem;
    padding-right: 0.85rem;
    min-width: 2.75rem;
}

.search-composer__photo {
    position: relative;
    display: inline-flex;
}

.search-composer__mobile-primary {
    display: flex;
    align-items: stretch;
    gap: 0.5rem;
}

.search-composer__file-label {
    position: relative;
    overflow: hidden;
    cursor: pointer;
}

.search-composer__file-input {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

/* ── Filter strip (Phase A) ────────────────────────────────────────────────── */

.filter-strip {
    margin-bottom: 0.25rem;
}

.filter-strip__scroll {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem 1.25rem;
    align-items: center;
    width: 100%;
}

.filter-strip__group--condition {
    margin-left: auto;
}

.filter-strip__group {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.5rem;
    min-width: 0;
}

.filter-strip__group-label {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--color-text-muted);
    white-space: nowrap;
}

.filter-strip__pills {
    display: flex;
    flex-wrap: wrap;
    gap: 0.4rem;
}

.filter-strip__pill {
    appearance: none;
    -webkit-appearance: none;
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    margin: 0;
    padding: 0.4rem 0.75rem;
    border: 1px solid transparent;
    border-radius: 999px;
    background: var(--color-surface-muted);
    color: var(--color-text-muted);
    font-size: 0.8125rem;
    font-weight: 500;
    font-family: inherit;
    line-height: 1.2;
    cursor: pointer;
    transition: all var(--transition);
    white-space: nowrap;
}

.filter-strip__pill-text {
    pointer-events: none;
}

.filter-strip__pill--active {
    border-color: var(--color-border);
    background: var(--color-surface);
    color: var(--color-text);
    box-shadow: inset 0 0 0 1px var(--color-border);
    font-weight: 600;
}

.filter-strip__pill--toggle {
    border-style: dashed;
}

.filter-strip__pill:disabled {
    opacity: 0.55;
    cursor: not-allowed;
}

.filter-strip__chevron {
    font-size: 0.75rem;
    transition: transform var(--transition);
}

.filter-strip__chevron--open {
    transform: rotate(90deg);
}

/* ── Unified result summary (Phase B) ──────────────────────────────────────── */

.lookup-result-summary {
    overflow: visible;
}

.lookup-result-summary__body {
    padding: 1.35rem 1.5rem;
}

.lookup-result-summary__main {
    display: grid;
    gap: 1.25rem;
    grid-template-columns: auto 1fr auto;
    align-items: start;
}

.lookup-result-summary__media {
    flex-shrink: 0;
    padding: 0.5rem;
    border-radius: var(--radius-lg);
    background: linear-gradient(145deg, var(--color-surface-gradient-start), var(--color-surface-gradient-end));
    border: 1px solid var(--color-border);
}

.lookup-result-summary__image {
    width: 88px;
    height: 88px;
    object-fit: contain;
    display: block;
}

.lookup-result-summary__meta {
    min-width: 0;
}

.lookup-result-summary__title {
    font-size: 1.2rem;
    font-weight: 700;
    line-height: 1.35;
    margin-bottom: 0.5rem;
}

.text-disclosure {
    position: relative;
    display: block;
}

.text-disclosure__toggle {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

.text-disclosure__label {
    display: block;
    margin: 0;
    font: inherit;
    color: inherit;
    cursor: pointer;
}

.text-disclosure__text {
    font: inherit;
    color: inherit;
}

@media (max-width: 639.98px) {
    .text-disclosure__toggle:not(:checked) + .text-disclosure__label .text-disclosure__text {
        display: -webkit-box;
        -webkit-box-orient: vertical;
        -webkit-line-clamp: 2;
        overflow: hidden;
    }

    .text-disclosure__toggle:not(:checked) + .text-disclosure__label::after {
        content: "Show more";
    }

    .text-disclosure__toggle:checked + .text-disclosure__label::after {
        content: "Show less";
    }

    .text-disclosure__label::after {
        display: block;
        margin-top: 0.2rem;
        font-size: 0.75rem;
        font-weight: 600;
        color: var(--color-brand);
    }
}

@media (min-width: 640px) {
    .text-disclosure__toggle {
        display: none;
    }

    .text-disclosure__label {
        pointer-events: none;
        cursor: default;
    }
}

.lookup-result-summary__tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.4rem;
    margin-bottom: 0.5rem;
}

.lookup-result-summary__meta-line {
    margin: 0;
    font-size: 0.8125rem;
    color: var(--color-text-muted);
}

.lookup-result-summary__pricing {
    text-align: right;
    min-width: 9.5rem;
}

.lookup-result-summary__pricing--pending {
    opacity: 0.85;
}

.lookup-result-summary__price-label {
    margin: 0 0 0.25rem;
    font-size: 0.6875rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--color-text-muted);
}

.lookup-result-summary__price-value {
    margin: 0 0 0.35rem;
    font-size: clamp(1.85rem, 4vw, 2.5rem);
    font-weight: 800;
    line-height: 1.05;
    font-variant-numeric: tabular-nums;
    background: linear-gradient(135deg, var(--color-brand) 0%, #2dd4bf 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.lookup-result-summary__price-value--muted {
    background: none;
    -webkit-text-fill-color: var(--color-text-muted);
    color: var(--color-text-muted);
    font-size: 1.35rem;
}

.lookup-result-summary__price-value--selected {
    filter: drop-shadow(0 0 12px rgba(20, 184, 166, 0.25));
}

.lookup-result-summary__price-value[role="button"] {
    cursor: pointer;
}

.lookup-result-summary__price-hint {
    font-size: 0.75rem;
    color: var(--color-text-muted);
}

.lookup-result-summary__alt-prices {
    display: flex;
    flex-wrap: wrap;
    gap: 0.45rem;
    justify-content: flex-end;
}

.lookup-result-summary__alt-price {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    padding: 0.45rem 0.65rem;
    border: 1px solid var(--color-border);
    border-radius: var(--radius-md);
    background: var(--color-bg);
    cursor: pointer;
    transition: border-color var(--transition), background var(--transition);
}

.lookup-result-summary__alt-price:disabled {
    cursor: default;
    opacity: 0.85;
}

.lookup-result-summary__alt-price--selected {
    border-color: var(--color-brand);
    background: var(--color-brand-soft);
}

.lookup-result-summary__alt-label {
    font-size: 0.625rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    color: var(--color-text-muted);
}

.lookup-result-summary__alt-value {
    font-size: 0.95rem;
    font-weight: 700;
    font-variant-numeric: tabular-nums;
}

.lookup-result-summary__actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-top: 1rem;
    padding-top: 1rem;
    border-top: 1px solid var(--color-border);
}

.lookup-action-bar {
    align-items: center;
}

.lookup-action-bar__primary {
    min-width: 7.5rem;
}

.lookup-overflow-menu {
    position: relative;
    display: inline-flex;
}

.lookup-overflow-menu__trigger,
.lookup-overflow-menu__icon-trigger {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
}

.lookup-overflow-menu__icon-trigger {
    color: var(--color-text-muted);
}

.lookup-overflow-menu__chevron {
    font-size: 0.7rem;
    transition: transform var(--transition);
}

.lookup-overflow-menu--open .lookup-overflow-menu__chevron {
    transform: rotate(90deg);
}

.lookup-overflow-menu__backdrop {
    position: fixed;
    inset: 0;
    z-index: 240;
    border: none;
    padding: 0;
    background: transparent;
    cursor: default;
}

.lookup-overflow-menu__panel {
    position: absolute;
    top: calc(100% + 0.35rem);
    right: 0;
    z-index: 250;
    min-width: 12rem;
    padding: 0.35rem;
    border: 1px solid var(--color-border);
    border-radius: var(--radius-lg);
    background: var(--color-surface);
    box-shadow: var(--shadow-lg);
}

.lookup-action-bar .lookup-overflow-menu__panel,
.search-composer__aux-row .lookup-overflow-menu__panel {
    top: auto;
    bottom: calc(100% + 0.35rem);
}

.lookup-overflow-menu__item {
    display: flex;
    align-items: center;
    width: 100%;
    border: none;
    background: none;
    padding: 0.5rem 0.75rem;
    border-radius: var(--radius-md);
    font-size: 0.875rem;
    text-align: left;
    color: var(--color-text);
    cursor: pointer;
}

.lookup-overflow-menu__item:hover:not(:disabled),
.lookup-overflow-menu__item:focus-visible {
    background: var(--color-brand-soft);
    color: var(--color-brand-hover);
}

.lookup-overflow-menu__item:disabled,
.lookup-overflow-menu__item--disabled {
    opacity: 0.55;
    cursor: not-allowed;
}

.alibris-session-banner {
    border-radius: var(--radius-lg);
}

/* ── Result details accordion (Phase B) ────────────────────────────────────── */

.lookup-result-details {
    border: 1px solid var(--color-border);
    border-radius: var(--radius-xl);
    background: var(--color-surface);
    overflow: hidden;
}

.lookup-result-details__summary {
    cursor: pointer;
    list-style: none;
    padding: 1rem 1.25rem;
    font-weight: 700;
    font-size: 0.95rem;
    border-bottom: 1px solid transparent;
    transition: background var(--transition);
}

.lookup-result-details__summary::-webkit-details-marker {
    display: none;
}

.lookup-result-details__summary::before {
    content: "▸";
    display: inline-block;
    margin-right: 0.5rem;
    color: var(--color-text-muted);
    transition: transform 0.15s ease;
}

.lookup-result-details[open] > .lookup-result-details__summary::before {
    transform: rotate(90deg);
}

.lookup-result-details[open] > .lookup-result-details__summary {
    border-bottom-color: var(--color-border);
    background: var(--color-surface-muted, #f8fafc);
}

.lookup-result-details__body {
    padding: 1.25rem;
}

.lookup-result-details__context {
    font-size: 0.875rem;
}

@media (max-width: 768px) {
    .search-composer__actions--desktop {
        display: none;
    }

    .search-composer__actions--mobile {
        display: block;
    }

    .search-composer__input {
        padding-right: 6.75rem;
        font-size: 1rem;
    }

    .filter-strip__scroll {
        flex-direction: column;
        flex-wrap: wrap;
        align-items: stretch;
        gap: 0.65rem;
        overflow: visible;
        padding-bottom: 0;
    }

    .filter-strip__group {
        flex-shrink: 1;
        width: 100%;
    }

    .filter-strip__group--condition {
        margin-left: 0;
        justify-content: space-between;
    }

    .filter-strip__pills {
        flex-wrap: wrap;
    }

    .lookup-result-summary__main {
        grid-template-columns: 1fr;
    }

    .lookup-result-summary__media {
        justify-self: start;
    }

    .lookup-result-summary__pricing {
        text-align: left;
    }

    .lookup-result-summary__alt-prices {
        justify-content: flex-start;
    }
}

.lookup-filters-row {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem 2rem;
    align-items: flex-start;
}

.lookup-filters-row__group {
    flex: 1 1 240px;
    min-width: 0;
}

.lookup-filters-row__category {
    flex: 1 1 100%;
    min-width: 0;
}

.ebay-category-filter {
    display: flex;
    flex-direction: column;
    gap: 0.65rem;
    padding: 0.85rem 1rem;
    border: 1px solid var(--color-border, #dbeafe);
    border-radius: var(--radius-lg, 0.75rem);
    background: var(--color-surface-muted, #f8fafc);
}

.ebay-category-filter__header {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-start;
    justify-content: space-between;
    gap: 0.5rem 1rem;
}

.ebay-category-filter__title {
    text-transform: none;
    letter-spacing: normal;
}

.ebay-category-filter__hint {
    display: block;
    margin-top: 0.15rem;
    font-size: 0.78rem;
    color: var(--color-brand, #0d9488);
}

.ebay-category-filter__actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
}

.ebay-category-filter__status {
    margin: 0;
    font-size: 0.85rem;
    color: var(--color-text-muted, #64748b);
}

.ebay-category-filter__status--error {
    color: #b45309;
}

.ebay-category-filter__prompt {
    margin: 0;
    font-size: 0.82rem;
    color: var(--color-text-muted, #64748b);
}

.ebay-category-filter__chip {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    max-width: 100%;
    padding: 0.25rem 0.55rem;
    border-radius: 999px;
    background: rgba(13, 148, 136, 0.1);
    border: 1px solid rgba(13, 148, 136, 0.25);
    font-size: 0.82rem;
    color: var(--color-text, #0f172a);
}

.ebay-category-filter__chip-remove {
    border: 0;
    background: transparent;
    color: inherit;
    font-size: 1rem;
    line-height: 1;
    padding: 0 0.15rem;
    cursor: pointer;
}

.ebay-category-filter__suggestions {
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
}

.ebay-category-filter__suggestion-list {
    display: flex;
    flex-wrap: wrap;
    gap: 0.4rem;
}

.ebay-category-filter__suggestion {
    max-width: 100%;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.ebay-category-picker {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem 1rem;
}

.ebay-category-picker__level {
    flex: 1 1 12rem;
    min-width: 10rem;
}

.alibris-session {
    margin-bottom: 1.25rem;
    padding: 1rem 1.1rem;
    border-radius: var(--radius-lg);
    border: 1px solid var(--color-border);
    background: var(--color-surface-muted, #f8fafc);
}

.alibris-session--pending {
    border-color: #fbbf24;
    background: var(--color-warning-soft);
}

.alibris-session--ready {
    border-color: #86efac;
    background: var(--color-success-soft);
}

.alibris-session__header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    margin-bottom: 0.35rem;
}

.alibris-session__text,
.alibris-session__status {
    color: var(--color-text-secondary);
    font-size: 0.92rem;
    line-height: 1.5;
}

.alibris-session__actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.search-card .input-group-lg > .form-control {
    padding: 0.9rem 1rem;
    font-size: 1.05rem;
    font-variant-numeric: tabular-nums;
    border-right: none;
}

.search-card .input-group-lg > .btn {
    padding-left: 1.25rem;
    padding-right: 1.25rem;
}

.search-card .input-group-lg > .btn-cancel-icon {
    padding-left: 0.85rem;
    padding-right: 0.85rem;
    min-width: 2.75rem;
    line-height: 1;
    font-size: 1.1rem;
}

.search-card .form-text {
    margin-top: 0.75rem;
    font-size: 0.875rem;
    color: var(--color-text-muted);
}

.search-card .form-text--warning {
    color: var(--color-warning);
}

/* Results panel */
.pricing-results {
    animation: fadeInUp 0.5s ease 0.1s both;
}

.panel-section {
    margin-bottom: 1.5rem;
}

.panel-section__header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    padding: 1rem 1.25rem;
    border-bottom: 1px solid var(--color-border);
}

.panel-section__title {
    display: flex;
    align-items: center;
    gap: 0.625rem;
    margin: 0;
    font-size: 1rem;
    font-weight: 700;
}

.panel-section__icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 2rem;
    height: 2rem;
    border-radius: var(--radius-md);
    background: var(--color-brand-soft);
    color: var(--color-brand);
    font-size: 1.05rem;
}

.panel-section__icon--accent {
    background: var(--color-accent-soft);
    color: var(--color-accent-strong);
}

.product-header {
    overflow: hidden;
}

.product-header .card-body {
    padding: 1.5rem;
}

.product-image-wrap {
    flex-shrink: 0;
    padding: 0.75rem;
    border-radius: var(--radius-lg);
    background: linear-gradient(145deg, var(--color-surface-gradient-start), var(--color-surface-gradient-end));
    border: 1px solid var(--color-border);
}

.product-image {
    width: 112px;
    height: 112px;
    object-fit: contain;
    display: block;
}

.product-meta {
    flex: 1;
    min-width: 0;
}

.product-upc {
    display: inline-block;
    margin-bottom: 0.5rem;
    padding: 0.25rem 0.65rem;
    border-radius: var(--radius-sm);
    background: var(--color-badge-muted-bg);
    color: var(--color-text-muted);
    font-family: var(--font-mono);
    font-size: 0.8125rem;
    letter-spacing: 0.04em;
}

.product-title {
    font-size: 1.25rem;
    font-weight: 700;
    line-height: 1.35;
    margin-bottom: 0.5rem;
}

.product-subtitle {
    font-size: 0.9rem;
    color: var(--color-text-muted);
}

.recommendation-grid {
    display: grid;
    gap: 1rem;
    grid-template-columns: 1.4fr 1fr 1fr;
}

.metric-card {
    position: relative;
    overflow: hidden;
    transition: transform var(--transition), box-shadow var(--transition);
}

.metric-card:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

.metric-card--selectable {
    cursor: pointer;
}

.metric-card--selectable:focus-visible {
    outline: 2px solid var(--color-brand);
    outline-offset: 2px;
}

.metric-card--selected {
    border-color: var(--color-brand);
    box-shadow: 0 0 0 2px rgba(20, 184, 166, 0.2), var(--shadow-md);
}

.metric-card--selected.recommendation-primary {
    border-color: var(--color-brand);
}

.metric-card .card-body {
    padding: 1.35rem;
}

.recommendation-primary {
    border: 1px solid rgba(20, 184, 166, 0.25);
    background: linear-gradient(145deg, var(--color-surface-gradient-start) 0%, var(--color-surface-gradient-accent-end) 100%);
    box-shadow: var(--shadow-md);
}

.recommendation-primary::after {
    content: '';
    position: absolute;
    top: 0;
    right: 0;
    width: 120px;
    height: 120px;
    background: radial-gradient(circle, rgba(20, 184, 166, 0.12) 0%, transparent 70%);
    pointer-events: none;
}

.metric-label {
    color: var(--color-text-muted);
    font-size: 0.75rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
    text-transform: uppercase;
    letter-spacing: 0.06em;
}

.metric-value {
    font-size: clamp(1.75rem, 3vw, 2.25rem);
    font-weight: 700;
    line-height: 1.1;
    margin-bottom: 0.35rem;
    color: var(--color-text);
    font-variant-numeric: tabular-nums;
}

.metric-value--primary {
    background: linear-gradient(135deg, var(--color-brand) 0%, #2dd4bf 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.metric-value--accent {
    color: var(--color-accent-strong);
}

.metric-hint {
    font-size: 0.875rem;
    color: var(--color-text-secondary);
}

.metric-hint strong {
    color: var(--color-success);
}

.recommendation-rationale {
    padding: 1rem 1.15rem;
    border-radius: var(--radius-lg);
    background: var(--color-bg-accent);
    border: 1px solid rgba(20, 184, 166, 0.12);
    font-size: 0.925rem;
    color: var(--color-text-secondary);
    line-height: 1.55;
}

/* ── Price recommendation card (hero price + secondary chips) ────────────────
   Replaces three equal-weight cards with one dominant "recommended" price plus
   two compact reference chips, so the single number a user acts on reads as
   the obvious primary decision rather than competing with two other numbers. */
.price-recommendation-card .card-body {
    padding: 1.5rem;
}

.price-recommendation-card__primary {
    position: relative;
    padding: 1.35rem 1.5rem;
    margin-bottom: 1rem;
    border-radius: var(--radius-lg);
    border: 1px solid rgba(20, 184, 166, 0.25);
    background: linear-gradient(145deg, var(--color-surface-gradient-start) 0%, var(--color-surface-gradient-accent-end) 100%);
    box-shadow: var(--shadow-md);
    overflow: hidden;
}

.price-recommendation-card__primary::after {
    content: '';
    position: absolute;
    top: 0;
    right: 0;
    width: 140px;
    height: 140px;
    background: radial-gradient(circle, rgba(20, 184, 166, 0.12) 0%, transparent 70%);
    pointer-events: none;
}

.price-recommendation-card__primary--selectable {
    cursor: pointer;
    transition: transform var(--transition), box-shadow var(--transition);
}

.price-recommendation-card__primary--selectable:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

.price-recommendation-card__primary--selectable:focus-visible {
    outline: 2px solid var(--color-brand);
    outline-offset: 2px;
}

.price-recommendation-card__primary--selected {
    border-color: var(--color-brand);
    box-shadow: 0 0 0 2px rgba(20, 184, 166, 0.2), var(--shadow-md);
}

.price-recommendation-card__value {
    font-size: clamp(2.25rem, 5vw, 3rem);
    font-weight: 800;
    line-height: 1.05;
    margin-bottom: 0.4rem;
    background: linear-gradient(135deg, var(--color-brand) 0%, #2dd4bf 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    font-variant-numeric: tabular-nums;
}

.price-recommendation-card__rationale {
    margin-bottom: 1rem;
}

.price-recommendation-card__secondary {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
}

.price-chip {
    flex: 1 1 160px;
    padding: 0.75rem 1rem;
    border-radius: var(--radius-lg);
    border: 1px solid var(--color-border);
    background: var(--color-bg);
    transition: border-color var(--transition), background var(--transition), transform var(--transition);
}

.price-chip--selectable {
    cursor: pointer;
}

.price-chip--selectable:hover {
    border-color: rgba(20, 184, 166, 0.3);
    background: var(--color-surface);
    transform: translateY(-1px);
}

.price-chip--selectable:focus-visible {
    outline: 2px solid var(--color-brand);
    outline-offset: 2px;
}

.price-chip--selected {
    border-color: var(--color-brand);
    box-shadow: 0 0 0 2px rgba(20, 184, 166, 0.2);
    background: linear-gradient(145deg, var(--color-surface-gradient-start) 0%, var(--color-surface-gradient-accent-end) 100%);
}

.price-chip__label {
    display: block;
    color: var(--color-text-muted);
    font-size: 0.6875rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 0.3rem;
}

.price-chip--selected .price-chip__label {
    color: var(--color-brand);
}

.price-chip__value {
    display: block;
    font-size: 1.15rem;
    font-weight: 700;
    color: var(--color-text);
    font-variant-numeric: tabular-nums;
    margin-bottom: 0.15rem;
}

.price-chip__hint {
    display: block;
    font-size: 0.75rem;
    color: var(--color-text-muted);
}

/* Stats/distribution/condition-breakdown are supporting evidence, not the primary
   decision -- tucked behind a disclosure so the price + sample listings (the parts
   people act on) aren't competing with them for attention by default. */
.pricing-detail-disclosure > .analysis-section__body {
    padding-top: 0.75rem;
}

.pricing-detail-disclosure__summary {
    padding: 0.85rem 1.1rem;
    border-radius: var(--radius-lg);
    background: var(--color-surface);
    border: 1px solid var(--color-border);
    font-weight: 600;
    font-size: 0.9rem;
}

.stats-grid {
    display: grid;
    gap: 0.875rem;
    grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
}

.stat-tile {
    padding: 1rem;
    border-radius: var(--radius-lg);
    background: var(--color-bg);
    border: 1px solid var(--color-border);
    transition: border-color var(--transition), background var(--transition);
}

.stat-tile:hover {
    border-color: rgba(20, 184, 166, 0.25);
    background: var(--color-surface);
}

.stat-tile--selectable {
    cursor: pointer;
}

.stat-tile--selectable:focus-visible {
    outline: 2px solid var(--color-brand);
    outline-offset: 2px;
}

.stat-tile--selected {
    border-color: var(--color-brand);
    box-shadow: 0 0 0 2px rgba(20, 184, 166, 0.2);
    background: linear-gradient(145deg, var(--color-surface-gradient-start) 0%, var(--color-surface-gradient-accent-end) 100%);
}

.stat-tile__selected-label {
    display: block;
    margin-top: 0.35rem;
    font-size: 0.6875rem;
    font-weight: 700;
    color: var(--color-brand);
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.stat-label {
    display: block;
    color: var(--color-text-muted);
    font-size: 0.6875rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    margin-bottom: 0.35rem;
}

.stat-value {
    display: block;
    font-size: 1.2rem;
    font-weight: 700;
    color: var(--color-text);
    font-variant-numeric: tabular-nums;
}

.distribution-row {
    display: grid;
    gap: 0.625rem;
    grid-template-columns: minmax(130px, 190px) 1fr minmax(88px, 100px);
    align-items: center;
    margin-bottom: 0.875rem;
}

.distribution-row:last-child {
    margin-bottom: 0;
}

.distribution-label,
.distribution-count {
    font-size: 0.875rem;
    color: var(--color-text-secondary);
}

.distribution-count {
    text-align: right;
    font-weight: 600;
    font-variant-numeric: tabular-nums;
}

.distribution-bar-track {
    background: #eef2ff;
    border-radius: 999px;
    height: 0.625rem;
    overflow: hidden;
}

.distribution-bar-fill {
    background: linear-gradient(90deg, var(--color-brand), #5eead4);
    height: 100%;
    min-width: 4%;
    border-radius: 999px;
    transition: width 0.6s cubic-bezier(0.22, 1, 0.36, 1);
}

.listings-table th .listings-table__sort-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    padding: 0;
    border: 0;
    background: transparent;
    color: inherit;
    font: inherit;
    font-weight: 600;
    text-align: inherit;
    cursor: pointer;
    white-space: nowrap;
}

.listings-table th .listings-table__sort-btn:hover,
.listings-table th .listings-table__sort-btn:focus-visible {
    color: var(--color-brand);
}

.listings-table th .listings-table__sort-btn--active {
    color: var(--color-brand);
}

.listings-table__sort-indicator {
    display: inline-block;
    width: 0.65rem;
    height: 0.65rem;
    opacity: 0.35;
    background: currentColor;
    mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath d='M8 3l4 5H4z'/%3E%3C/svg%3E") center / contain no-repeat;
}

.listings-table__sort-btn--active .listings-table__sort-indicator {
    opacity: 1;
}

.listings-table__sort-indicator--desc {
    transform: rotate(180deg);
}

.listings-table .listing-title {
    max-width: 420px;
    font-weight: 500;
    color: var(--color-text);
}

.listings-table__sold-date-col,
.listings-table .listing-sold-date {
    font-size: 0.75rem;
    line-height: 1.25;
    white-space: nowrap;
    font-variant-numeric: tabular-nums;
}

.listings-table .listing-price {
    font-weight: 700;
    color: var(--color-accent-strong);
    font-variant-numeric: tabular-nums;
}

.listings-table .view-link {
    display: inline-flex;
    align-items: center;
    padding: 0.3rem 0.65rem;
    border: 1px solid transparent;
    border-radius: var(--radius-sm);
    background: var(--color-brand-soft);
    color: var(--color-brand);
    font-size: 0.8125rem;
    font-weight: 600;
    line-height: 1.2;
    text-decoration: none;
    box-sizing: border-box;
    transition: background var(--transition), color var(--transition), border-color var(--transition);
}

.listings-table__action-group {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    flex-wrap: nowrap;
}

.listings-table .search-link {
    display: inline-flex;
    align-items: center;
    padding: 0.3rem 0.65rem;
    border-radius: var(--radius-sm);
    border: 1px solid var(--color-brand);
    background: transparent;
    color: var(--color-brand);
    font-size: 0.8125rem;
    font-weight: 600;
    line-height: 1.2;
    box-sizing: border-box;
    cursor: pointer;
    transition: background var(--transition), color var(--transition), border-color var(--transition);
}

.listings-table .search-link:hover {
    background: var(--color-brand);
    border-color: var(--color-brand);
    color: #fff;
}

/* Suppress the "Opens in a new window or tab" text that some browsers/OS
   accessibility layers inject as a pseudo-element on target="_blank" links. */
.listings-table .view-link::after,
.listings-table .view-link::before {
    content: none !important;
    display: none !important;
}

.listings-table .view-link:hover {
    background: var(--color-brand);
    border-color: var(--color-brand);
    color: #fff;
}

.listings-table__ignore-col {
    width: 5.75rem;
    white-space: nowrap;
}

.listings-table__ignore-cell {
    vertical-align: middle;
}

.listings-table__row--ignored {
    opacity: 0.72;
    background: repeating-linear-gradient(
        -45deg,
        color-mix(in srgb, var(--color-warning) 8%, transparent),
        color-mix(in srgb, var(--color-warning) 8%, transparent) 8px,
        transparent 8px,
        transparent 16px);
}

.listings-table__row--ignored .listing-title {
    color: var(--color-text-muted);
    text-decoration: line-through;
    text-decoration-color: color-mix(in srgb, var(--color-text-muted) 70%, transparent);
}

.listings-table__row--ignored .listing-price {
    color: var(--color-text-muted);
    font-weight: 500;
}

.listings-table__ignored-badge {
    margin-left: 0.45rem;
    vertical-align: middle;
    font-size: 0.6875rem;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.listing-ignore-toggle {
    min-width: 4.5rem;
}

.listing-section__table-wrap {
    position: relative;
}

.listing-section--validating-barcodes .listing-section__table-wrap {
    pointer-events: none;
    user-select: none;
}

.listing-barcode-validation-banner {
    padding: 0.75rem 1.25rem;
    border-color: var(--color-border) !important;
}

.listing-barcode-validation-overlay {
    position: absolute;
    inset: 0;
    z-index: 2;
    display: flex;
    align-items: center;
    justify-content: center;
    background: color-mix(in srgb, var(--color-surface, #fff) 78%, transparent);
    backdrop-filter: blur(2px);
}

.listing-barcode-validation-overlay__panel {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.35rem;
    padding: 1.25rem 1.5rem;
    border-radius: var(--radius-md);
    background: var(--color-surface, #fff);
    border: 1px solid var(--color-border);
    box-shadow: 0 8px 24px color-mix(in srgb, var(--color-text) 12%, transparent);
    text-align: center;
}

.listing-section--validating-barcodes .listing-upc,
.listing-section--validating-barcodes .listing-dimension-match {
    animation: listingUpcPulse 1.4s ease-in-out infinite;
}

.listing-dimension-match {
    font-weight: 600;
    letter-spacing: 0.04em;
}

@keyframes listingUpcPulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.45; }
}

.listing-exclusion-notice {
    font-size: 0.9375rem;
}

.condition-tag {
    display: inline-block;
    padding: 0.2rem 0.55rem;
    border-radius: var(--radius-sm);
    background: var(--color-badge-muted-bg);
    color: var(--color-text-secondary);
    font-size: 0.8125rem;
    font-weight: 500;
}

.empty-state-icon {
    font-size: 2rem;
    margin-bottom: 0.5rem;
}

.condition-filter {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.condition-filter__option {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    margin: 0;
    padding: 0.55rem 0.9rem;
    border: 1px solid var(--color-border);
    border-radius: 999px;
    background: var(--color-surface);
    color: var(--color-text-secondary);
    font-size: 0.875rem;
    font-weight: 600;
    cursor: pointer;
    transition: all var(--transition);
}

.condition-filter__option input {
    position: absolute;
    opacity: 0;
    pointer-events: none;
}

.condition-filter__option--active {
    border-color: rgba(20, 184, 166, 0.4);
    background: var(--color-brand-soft);
    color: var(--color-brand-hover);
    box-shadow: inset 0 0 0 1px rgba(20, 184, 166, 0.15);
}

.listing-counts {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.listing-counts__breakdown {
    margin: 0.5rem 0 0;
    font-size: 0.8125rem;
    color: var(--color-text-muted);
}

.condition-badge {
    display: inline-flex;
    align-items: center;
    padding: 0.3rem 0.65rem;
    border-radius: 999px;
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 0.02em;
}

.condition-badge--new {
    background: var(--color-brand-soft);
    color: var(--color-brand-hover);
}

.condition-badge--used {
    background: rgba(13, 148, 136, 0.12);
    color: var(--color-accent-strong);
}

.condition-badge--undetermined {
    background: rgba(217, 119, 6, 0.12);
    color: var(--color-warning);
}

.catalog-condition-badge {
    display: inline-flex;
    align-items: center;
    padding: 0.35rem 0.8rem;
    border-radius: 999px;
    font-size: 0.8rem;
    font-weight: 700;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    line-height: 1;
    border: none;
}

.catalog-condition-badge--new {
    background: var(--color-brand);
    color: #fff;
    box-shadow: 0 2px 6px rgba(20, 184, 166, 0.35);
}

.catalog-condition-badge--used {
    background: var(--color-accent);
    color: #fff;
    box-shadow: 0 2px 6px rgba(13, 148, 136, 0.35);
}

.catalog-condition-badge--unspecified {
    background: var(--color-warning);
    color: #fff;
    box-shadow: 0 2px 6px rgba(217, 119, 6, 0.35);
}

.square-admin-page__orgs .list-group {
    max-width: 28rem;
}

.square-how-to-page {
    max-width: 52rem;
    margin-inline: auto;
}

.square-how-to-page__section ol,
.square-how-to-page__section ul {
    padding-left: 1.25rem;
}

.square-how-to-page__section li + li {
    margin-top: 0.35rem;
}

.square-how-to-page__faq dt {
    font-weight: 600;
}

.square-admin-tabs {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.square-admin-tabs__tab {
    border: 1px solid var(--color-border);
    border-radius: 999px;
    background: var(--color-surface);
    color: var(--color-text-secondary);
    padding: 0.45rem 0.95rem;
    font-size: 0.82rem;
    font-weight: 600;
    transition: background 0.15s ease, color 0.15s ease, border-color 0.15s ease, box-shadow 0.15s ease;
}

.square-admin-tabs__tab:hover {
    border-color: rgba(20, 184, 166, 0.25);
    color: var(--color-brand);
}

.square-admin-tabs__tab--active {
    border-color: rgba(20, 184, 166, 0.35);
    background: var(--color-brand-soft);
    color: var(--color-brand);
    box-shadow: inset 0 0 0 1px rgba(20, 184, 166, 0.12);
}

.square-admin-tabs__tab:disabled {
    opacity: 0.45;
    cursor: not-allowed;
}

.square-admin-tabs__tab:disabled:hover {
    border-color: var(--color-border);
    color: var(--color-text-secondary);
}

.stripe-workspace-row {
    cursor: pointer;
}

.stripe-workspace-detail:focus {
    outline: none;
}

.sales-reports-tabs {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.sales-reports-tabs__tab {
    border: 1px solid var(--color-border);
    border-radius: 999px;
    background: var(--color-surface);
    color: var(--color-text-secondary);
    padding: 0.45rem 0.95rem;
    font-size: 0.82rem;
    font-weight: 600;
    transition: background 0.15s ease, color 0.15s ease, border-color 0.15s ease, box-shadow 0.15s ease;
}

.sales-reports-tabs__tab:hover {
    border-color: rgba(20, 184, 166, 0.25);
    color: var(--color-brand);
}

.sales-reports-tabs__tab--active {
    border-color: rgba(20, 184, 166, 0.35);
    background: var(--color-brand-soft);
    color: var(--color-brand);
    box-shadow: inset 0 0 0 1px rgba(20, 184, 166, 0.12);
}

a.sales-reports-tabs__tab {
    text-decoration: none;
    display: inline-flex;
    align-items: center;
}

.scan-activity-chart {
    display: flex;
    align-items: flex-end;
    gap: 0.35rem;
    min-height: 8.5rem;
    overflow-x: auto;
    padding-bottom: 0.25rem;
}

.scan-activity-chart__col {
    display: flex;
    flex-direction: column;
    align-items: center;
    min-width: 2.4rem;
    flex: 1 0 2.4rem;
}

.scan-activity-chart__bars {
    display: flex;
    align-items: flex-end;
    gap: 2px;
    height: 7rem;
}

.scan-activity-chart__bar {
    display: block;
    width: 0.45rem;
    border-radius: 0.2rem 0.2rem 0 0;
    background: #14b8a6;
}

.scan-activity-chart__bar--new { background: #38bdf8; }
.scan-activity-chart__bar--existing { background: #f59e0b; }

.pulse-stack__bar.scan-activity-fill--scans { background: #14b8a6; }

.scan-activity-chart__label {
    margin-top: 0.3rem;
    font-size: 0.65rem;
    color: var(--color-text-secondary, #94a3b8);
}

.scan-activity-legend span::before {
    content: "";
    display: inline-block;
    width: 0.55rem;
    height: 0.55rem;
    margin-right: 0.3rem;
    border-radius: 0.15rem;
    background: #14b8a6;
    vertical-align: -0.05rem;
}

.scan-activity-legend span.scan-activity-legend__new::before { background: #38bdf8; }
.scan-activity-legend span.scan-activity-legend__existing::before { background: #f59e0b; }

.sales-reports-orders__grid tbody tr {
    cursor: pointer;
}

.sales-reports-orders__row--selected {
    background: var(--color-brand-soft);
}

.sales-reports-orders__checkout-label {
    font-weight: 600;
    font-size: 0.875rem;
}

.sales-reports-orders__checkout-detail {
    margin-top: 1.25rem;
    padding-top: 1.25rem;
    border-top: 1px solid var(--color-border);
}

.app-modal__body .sales-reports-orders__checkout-detail {
    margin-top: 0;
    padding-top: 0;
    border-top: none;
}

.sales-reports-orders__hint {
    padding-top: 0.75rem;
    border-top: 1px dashed var(--color-border);
}

.sales-reports-orders__totals > div {
    border: 1px solid var(--color-border);
    border-radius: var(--radius-md);
    background: var(--color-surface-muted);
    padding: 0.65rem 0.75rem;
}

.sales-reports-orders__lines tfoot th {
    border-top-width: 2px;
    font-weight: 600;
}

.sales-reports-orders__meta {
    display: grid;
    gap: 0.45rem 1rem;
    margin: 0;
}

.sales-reports-orders__meta > div {
    display: grid;
    grid-template-columns: 6.5rem 1fr;
    gap: 0.5rem;
}

.sales-reports-orders__meta dt {
    margin: 0;
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--color-text-muted);
}

.sales-reports-orders__meta dd {
    margin: 0;
    font-size: 0.875rem;
    word-break: break-word;
}

.square-admin-stat {
    border: 1px solid var(--color-border);
    border-radius: var(--radius-lg);
    background: var(--color-surface);
    padding: 0.85rem 1rem;
}

.square-admin-stat__label {
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    color: var(--color-text-secondary);
    margin-bottom: 0.25rem;
}

.square-admin-stat__value {
    font-size: 1rem;
    font-weight: 700;
    color: var(--color-text-primary);
    word-break: break-word;
}

.inventory-aging-table__row--selected {
    background: var(--color-brand-soft);
}

button.inventory-aging-bucket {
    display: block;
    width: 100%;
    color: inherit;
    text-align: left;
    cursor: pointer;
}

button.inventory-aging-bucket--selected {
    border-color: rgba(20, 184, 166, 0.45);
    background: var(--color-brand-soft);
    box-shadow: inset 0 0 0 1px rgba(20, 184, 166, 0.2);
}

.square-admin-section .table {
    margin-bottom: 0;
}

.analysis-section {
    margin-bottom: 2rem;
    padding-top: 0.5rem;
}

.analysis-section__heading {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 1rem;
    margin-bottom: 1rem;
}

.analysis-section__title {
    margin: 0 0 0.25rem;
    font-size: 1.2rem;
    font-weight: 700;
}

.analysis-section__subtitle {
    color: var(--color-text-muted);
    font-size: 0.875rem;
}

.analysis-section__empty {
    margin-bottom: 0;
}

.analysis-section--undetermined {
    padding: 1.25rem;
    border: 1px dashed rgba(217, 119, 6, 0.35);
    border-radius: var(--radius-xl);
    background: rgba(217, 119, 6, 0.04);
}

.analysis-section--secondary {
    padding: 1.25rem;
    border: 1px dashed rgba(13, 110, 253, 0.25);
    border-radius: var(--radius-xl);
    background: rgba(13, 110, 253, 0.03);
}

.analysis-section--secondary .analysis-section__title {
    color: var(--color-text-muted, #6c757d);
}

.analysis-section--collapsible {
    border-radius: var(--radius-xl);
}

.analysis-section--collapsible > .analysis-section__summary {
    cursor: pointer;
    list-style: none;
    margin-bottom: 0;
}

.analysis-section--collapsible > .analysis-section__summary::-webkit-details-marker {
    display: none;
}

.analysis-section--collapsible > .analysis-section__summary::before {
    content: "▸";
    display: inline-block;
    margin-right: 0.5rem;
    color: var(--color-text-muted);
    font-size: 0.9rem;
    transition: transform 0.15s ease;
}

.analysis-section--collapsible[open] > .analysis-section__summary::before {
    transform: rotate(90deg);
}

.analysis-section--collapsible[open] > .analysis-section__summary {
    margin-bottom: 1rem;
}

.analysis-section--collapsible > .analysis-section__body {
    padding-top: 0.25rem;
}

.analysis-section__expand-hint {
    color: var(--color-text-muted);
    font-style: italic;
}

.analysis-section--collapsible[open] .analysis-section__expand-hint {
    display: none;
}

.variant-market-results__header {
    padding-bottom: 0.75rem;
    border-bottom: 1px solid var(--color-border);
}

.variant-market-results__counts {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.variant-market-results__section {
    padding: 1rem;
    border: 1px solid var(--color-border);
    border-radius: var(--radius-lg);
    background: var(--color-surface);
}

.variant-market-results__section + .variant-market-results__section {
    margin-top: 0.85rem;
}

.variant-market-results__section--primary {
    border-color: rgba(20, 184, 166, 0.2);
    background: linear-gradient(180deg, var(--color-surface) 0%, var(--color-surface-muted) 100%);
}

.variant-market-results__section--secondary {
    background: var(--color-surface-muted);
}

.variant-market-results__section-heading,
.variant-market-results__secondary-heading {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 0.5rem;
    margin-bottom: 0.75rem;
}

.variant-market-results__secondary {
    padding-top: 0.25rem;
    border-top: 1px dashed var(--color-border);
}

.catalog-market-analysis__apply {
    background: var(--color-bg-accent);
    border-radius: var(--radius-lg);
    padding: 1rem;
}

.catalog-merge-panel__targets {
    max-height: 16rem;
    overflow-y: auto;
}

.inventory-location-toggle {
    display: inline-flex;
    align-items: flex-start;
    gap: 0.35rem;
    max-width: 100%;
    padding: 0;
    border: 0;
    background: none;
    color: inherit;
    font: inherit;
    line-height: inherit;
    text-align: left;
}

.inventory-location-toggle:hover,
.inventory-location-toggle:focus-visible {
    color: var(--color-brand, #0f766e);
}

.inventory-location-toggle__chevron {
    flex: 0 0 auto;
    width: 0.8rem;
}

.inventory-location-row > td {
    background: var(--color-surface-muted, #f8fafc);
    border-top: none;
}

.inventory-location-row > td:first-child {
    box-shadow: inset 3px 0 0 var(--color-brand, #14b8a6);
}

.inventory-location-row__label {
    padding-left: 1.15rem;
    font-weight: 600;
}

.inventory-move-row > td {
    padding: 0.75rem 0.5rem;
    background: var(--color-surface-muted, #f8fafc);
    border-top: none;
}

.inventory-selection-bar {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-end;
    gap: 0.75rem 2.25rem;
}

.inventory-selection-bar__group {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-end;
    gap: 0.5rem;
}

.inventory-bulk-move-confirm {
    margin-top: 2.25rem;
    margin-bottom: 2rem;
}

.inventory-move-panel {
    scroll-margin-top: 5.5rem;
    background: var(--color-surface);
    border: 1px solid var(--color-border-strong);
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-lg);
    padding: 1rem 1.1rem;
}

.inventory-delete-confirm-row > td {
    padding: 0.75rem 0.5rem;
    background: var(--color-danger-soft);
    border-top: none;
    border-bottom: 2px solid rgba(220, 38, 38, 0.35);
}

.lookup-manual-add {
    border-top: 1px solid var(--color-border);
}

.inventory-manual-add {
    background: var(--color-surface-muted, #f8fafc);
    border-color: var(--color-border) !important;
}

.inventory-manual-add__similar {
    max-height: 14rem;
    overflow-y: auto;
}

.inventory-delete-confirm {
    background: var(--color-surface);
    border: 1px solid rgba(220, 38, 38, 0.35);
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-lg);
    padding: 1rem 1.1rem;
}

.inventory-lot-badge {
    display: inline-flex;
    align-items: center;
    max-width: 100%;
    padding: 0.25rem 0.55rem;
    border-radius: var(--radius-sm);
    font-size: 0.75rem;
    font-weight: 600;
    line-height: 1.25;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.inventory-lot-badge--assigned {
    background: var(--color-brand-soft);
    color: var(--color-brand-hover);
    border: 1px solid transparent;
}

.inventory-lot-badge--muted {
    background: var(--color-badge-muted-bg);
    color: var(--color-text-secondary);
    border: 1px solid var(--color-border);
}

.inventory-diagnostics-admin__group {
    background: var(--color-surface);
}

.inventory-diagnostics-admin__summary {
    cursor: pointer;
}

.inventory-diagnostics-admin__summary:hover {
    background: var(--color-surface-muted) !important;
}

.inventory-diagnostics-admin__method-badge {
    background: var(--color-brand-soft);
    color: var(--color-brand-hover);
    font-weight: 600;
    margin-right: 0.35rem;
}

.inventory-diagnostics-admin__detail {
    background: var(--color-surface-muted);
}

.inventory-diagnostics-admin__consolidate {
    background: var(--color-surface);
    border-color: var(--color-border) !important;
}

.inventory-diagnostics-admin__busy {
    padding: 0.25rem 0;
}

.inventory-diagnostics-admin__busy .progress {
    background: var(--color-badge-muted-bg);
}

.pos-page__header {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    align-items: flex-start;
    gap: 1rem;
    margin-bottom: 1.25rem;
}

.pos-cart-panel {
    min-height: 20rem;
}

.pos-cart-panel__lines {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    max-height: 24rem;
    overflow-y: auto;
}

.pos-cart-line {
    display: grid;
    grid-template-columns: 1fr auto auto auto;
    gap: 0.5rem 0.75rem;
    align-items: center;
    padding-bottom: 0.75rem;
    border-bottom: 1px solid var(--color-border);
}

.pos-cart-line__info {
    min-width: 0;
}

.pos-cart-line__qty {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
}

.pos-cart-line__qty-value {
    min-width: 1.5rem;
    text-align: center;
    font-weight: 600;
}

.pos-cart-line__total {
    font-weight: 700;
    min-width: 4.5rem;
    text-align: right;
}

.pos-cart-line__actions {
    display: inline-flex;
    align-items: center;
    gap: 0.25rem;
    justify-self: end;
}

.pos-cart-line__remove {
    padding-left: 0.35rem;
    padding-right: 0.35rem;
}

.pos-cart-line__custom-badge {
    font-size: 0.65rem;
    font-weight: 600;
    vertical-align: middle;
    margin-left: 0.35rem;
}

.pos-custom-item-modal__actions {
    display: flex;
    justify-content: flex-end;
    gap: 0.5rem;
    margin-top: 0.25rem;
}

.pos-cart-panel__total {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 1.15rem;
    padding-top: 0.5rem;
    border-top: 2px solid var(--color-border);
}

.pos-cash-tender__quick-buttons {
    display: flex;
    flex-wrap: wrap;
    gap: 0.35rem;
}

.pos-cash-tender__change {
    font-size: 1.1rem;
    font-weight: 700;
}

.pos-split-payment__summary {
    display: grid;
    grid-template-columns: 1fr auto;
    gap: 0.25rem 1rem;
}

.pos-split-payment__summary dt {
    margin: 0;
    font-weight: 600;
}

.pos-split-payment__summary dd {
    margin: 0;
    text-align: right;
}

.pos-customer-receipt__lines th,
.pos-customer-receipt__lines td {
    vertical-align: top;
}

.pos-customer-receipt__totals {
    display: grid;
    grid-template-columns: 1fr auto;
    gap: 0.35rem 1rem;
}

.pos-customer-receipt__totals dt {
    font-weight: 600;
    margin: 0;
}

.pos-customer-receipt__totals dd {
    margin: 0;
    text-align: right;
}

.pos-customer-receipt__grand-total dt,
.pos-customer-receipt__grand-total dd {
    font-size: 1.1rem;
    font-weight: 700;
}

.pos-customer-receipt__change dt,
.pos-customer-receipt__change dd {
    font-size: 1.05rem;
    font-weight: 700;
}

@media print {
    body * {
        visibility: hidden;
    }

    #pos-customer-receipt,
    #pos-customer-receipt * {
        visibility: visible;
    }

    #pos-customer-receipt {
        position: absolute;
        left: 0;
        top: 0;
        width: 100%;
    }

    .pos-customer-receipt__terminal-action,
    .pos-customer-receipt__actions {
        display: none !important;
    }
}

.square-terminal-panel__pairing-code {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 0.5rem;
}

@media (max-width: 768px) {
    .pos-cart-line {
        grid-template-columns: 1fr auto;
        grid-template-areas:
            "info total"
            "qty actions";
    }

    .pos-cart-line__info { grid-area: info; }
    .pos-cart-line__qty { grid-area: qty; }
    .pos-cart-line__total { grid-area: total; text-align: right; }
    .pos-cart-line__actions { grid-area: actions; justify-self: end; }
}

.variant-market-results__recommendations {
    grid-template-columns: repeat(3, minmax(0, 1fr));
}

.variant-market-results__recommendations .metric-value {
    font-size: 1.1rem;
}

.variant-market-results__stats .stats-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.variant-market-results__listings-summary {
    cursor: pointer;
    font-weight: 600;
}

.variant-market-results__listings-summary::-webkit-details-marker {
    display: none;
}

@media (max-width: 768px) {
    .variant-market-results__recommendations {
        grid-template-columns: 1fr;
    }
}

.condition-tag--undetermined {
    background: rgba(217, 119, 6, 0.12);
    color: #92400e;
}

.ebay-account-panel__header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 1rem;
}

.ebay-account-panel__actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
}

.ebay-research-status-grid dt {
    color: var(--bs-secondary-color, #6c757d);
    font-weight: 500;
}

.ebay-research-status-grid dd {
    margin-bottom: 0.35rem;
}

.ebay-remote-browser {
    border: 1px solid rgba(0, 0, 0, 0.12);
    border-radius: 0.5rem;
    background: #111;
    overflow: hidden;
}

.ebay-remote-browser__toolbar {
    padding: 0.5rem 0.75rem;
    background: rgba(255, 255, 255, 0.06);
    color: #ddd;
}

.ebay-remote-browser__frame-wrap {
    outline: none;
    max-height: 70vh;
    overflow: auto;
    background: #000;
}

.ebay-remote-browser__stage {
    position: relative;
    width: 100%;
}

.ebay-remote-browser__frame {
    display: block;
    width: 100%;
    height: auto;
    pointer-events: none;
    user-select: none;
}

.ebay-remote-browser__capture {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    margin: 0;
    padding: 0;
    border: 0;
    resize: none;
    overflow: hidden;
    opacity: 0;
    background: transparent;
    color: transparent;
    caret-color: transparent;
    cursor: crosshair;
    z-index: 1;
}

.ebay-remote-browser__capture:focus {
    outline: 2px solid rgba(20, 184, 166, 0.85);
    outline-offset: -2px;
}

.ebay-remote-browser__loading {
    color: #ccc;
    padding: 2rem;
    text-align: center;
}

/* ── Lookup results + Square inventory layout ─────────────────────────────── */

.square-inventory-panel .card-body {
    padding: 1.25rem;
}

.square-inventory-panel__match code {
    display: block;
    word-break: break-all;
    margin-top: 0.25rem;
}

.catalog-match-selector .list-group-item {
    padding: 0.75rem 1rem;
}

.image-search-identity-selector__thumb {
    width: 3.5rem;
    height: 3.5rem;
    object-fit: cover;
    border-radius: 0.35rem;
    border: 1px solid var(--color-border);
    background: var(--color-surface-muted);
}

.metadata-search-context-selector__title-options--scroll {
    max-height: 16.5rem;
    overflow-y: auto;
    padding-right: 0.25rem;
    margin-bottom: 0.75rem;
}

.metadata-search-context-selector__metadata {
    border-top: 1px solid var(--bs-border-color, #dee2e6);
    padding-top: 0.75rem;
}

.metadata-search-context-selector__metadata-group:last-child {
    margin-bottom: 0 !important;
}

.metadata-search-context-selector__header {
    gap: 0.75rem;
}

.metadata-search-context-selector__product-title {
    flex: 1 1 auto;
    min-width: 0;
    line-height: 1.35;
}

.metadata-search-context-selector__actions {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    gap: 0.75rem;
    margin-top: 1.25rem;
    padding-top: 1.25rem;
    border-top: 1px solid var(--color-border);
}

.metadata-search-context-selector__submit {
    width: 100%;
    min-height: 3.25rem;
    font-size: 1.125rem;
    font-weight: 700;
    letter-spacing: -0.015em;
    color: #fff;
    background: #c2410c;
    border: none;
    box-shadow: 0 12px 28px rgba(194, 65, 12, 0.35);
    transition: background var(--transition), box-shadow var(--transition), transform var(--transition);
}

.metadata-search-context-selector__submit--header {
    width: auto;
    min-width: 12.5rem;
    min-height: 2.75rem;
    align-self: flex-start;
    padding-inline: 1.25rem;
}

.metadata-search-context-selector__submit:not(:disabled):hover,
.metadata-search-context-selector__submit:not(:disabled):focus-visible {
    color: #fff;
    background: #9a3412;
    transform: translateY(-1px);
    box-shadow: 0 14px 32px rgba(194, 65, 12, 0.42);
}

.metadata-search-context-selector__submit:active:not(:disabled) {
    transform: translateY(0);
}

.metadata-search-context-selector__submit:disabled {
    color: #fff;
    background: #94a3b8;
    box-shadow: none;
    transform: none;
    opacity: 0.85;
}

.metadata-search-context-selector__skip {
    align-self: center;
    color: var(--color-text-muted);
    text-decoration: none;
}

.metadata-search-context-selector__skip:hover,
.metadata-search-context-selector__skip:focus-visible {
    color: var(--color-text-secondary);
    text-decoration: underline;
}

@media (min-width: 576px) {
    .metadata-search-context-selector__actions {
        align-items: flex-start;
    }

    .metadata-search-context-selector__submit {
        width: auto;
        min-width: 16rem;
        padding-inline: 1.75rem;
    }

    .metadata-search-context-selector__skip {
        align-self: flex-start;
        padding-inline: 0.25rem;
    }
}

.metadata-search-context-selector__options .list-group-item,
.metadata-search-context-selector__option {
    padding: 0.45rem 0.75rem;
    cursor: pointer;
}

.metadata-search-context-selector__option {
    gap: 0.625rem;
    align-items: center;
}

.metadata-search-context-selector__input {
    float: none;
    margin: 0;
}

.metadata-search-context-selector__option-body {
    display: flex;
    flex-direction: column;
    gap: 0.1rem;
    min-width: 0;
}

.metadata-search-context-selector__title {
    font-weight: 600;
    line-height: 1.25;
}

.metadata-search-context-selector__meta {
    line-height: 1.2;
}

.metadata-search-context-selector__contributor-option {
    display: block;
    border: 1px solid var(--color-border);
    border-radius: 0.5rem;
    padding: 0.55rem 0.75rem;
    background: var(--color-surface);
    cursor: pointer;
    transition: border-color 0.15s ease, background-color 0.15s ease, box-shadow 0.15s ease;
}

.metadata-search-context-selector__contributor-option:hover,
.metadata-search-context-selector__contributor-option:focus-visible {
    border-color: var(--color-brand);
    background: var(--color-bg-accent);
}

.metadata-search-context-selector__contributor-check {
    width: 1.1rem;
    font-size: 0.95rem;
    line-height: 1.4;
    color: var(--color-brand);
}

.metadata-search-context-selector__contributor-option--selected,
.metadata-search-context-selector__contributor-option:has(.metadata-search-context-selector__input:checked) {
    border-color: var(--color-brand);
    background: var(--color-bg-accent);
    box-shadow: 0 0 0 1px color-mix(in srgb, var(--color-brand) 18%, transparent);
}

.metadata-search-context-selector__contributor-row {
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
}

.metadata-search-context-selector__contributor-text {
    display: flex;
    flex-direction: column;
    gap: 0.2rem;
    min-width: 0;
}

.metadata-search-context-selector__contributor-name {
    display: block;
    font-weight: 600;
    line-height: 1.4;
}

.metadata-search-context-selector__contributor-full {
    display: block;
    line-height: 1.35;
}

.metadata-search-context-selector__option.active .metadata-search-context-selector__input {
    border-color: rgba(255, 255, 255, 0.85);
    background-color: transparent;
}

.metadata-search-context-selector__option.active .metadata-search-context-selector__input:checked {
    background-color: #fff;
    border-color: #fff;
}

/* ── Price tag panel ────────────────────────────────────────────────────── */

.price-tag-panel {
    margin-top: 1.5rem;
}

.price-picker__label {
    font-weight: 600;
    font-size: 0.875rem;
    color: var(--color-text-muted, #6c757d);
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.price-picker__options {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    align-items: flex-end;
}

.price-picker__btn {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 0.5rem 1rem;
    min-width: 110px;
    gap: 0.15rem;
}

.price-picker__btn--selected {
    box-shadow: 0 0 0 2px rgba(20, 184, 166, 0.25);
}

.price-picker__selected-label {
    font-size: 0.625rem;
    font-weight: 700;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    opacity: 0.9;
}

.price-picker__tier {
    font-size: 0.7rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    opacity: 0.75;
}

.price-picker__amount {
    font-size: 1.1rem;
    font-weight: 700;
}

.price-picker__custom {
    min-width: 130px;
}

.price-tag-price__label {
    font-size: 0.85rem;
    font-weight: 600;
    color: #475569;
}

.price-tag-price__amount {
    font-size: 1.35rem;
    font-weight: 800;
    letter-spacing: -0.02em;
}

/* ── Price tag preview card ─────────────────────────────────────────────── */

.price-tag-preview {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 0.25rem;
}

.price-tag-preview--thermal {
    gap: 0.75rem;
}

.price-tag-preview--thermal .lq-preview-pane {
    width: 100%;
}

.price-tag-preview--thermal .price-tag-card__guid,
.price-tag-preview--thermal .price-tag-actions,
.price-tag-preview--thermal .lq-add-row {
    width: 100%;
}

.lq-preview-pane__layout.lq-layout-select {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    margin: 0;
}

.lq-preview-pane__layout .lq-layout-select__control {
    width: auto;
    min-width: 6.5rem;
    max-width: 10rem;
}

/* ── Price tag preview (shared HPB layout — matches print output) ─────────── */

.hpb-tag {
    font-family: "Arial Narrow", "Helvetica Neue", Arial, sans-serif;
    color: #111;
    background: #fff;
    display: flex;
    flex-direction: column;
    align-items: stretch;
    justify-content: flex-start;
    overflow: hidden;
}

.hpb-accent {
    width: 100%;
    background: #000;
    flex-shrink: 0;
}

.hpb-topbar {
    width: 100%;
    flex-shrink: 0;
    display: flex;
    flex-direction: column;
}

.hpb-logo-bar {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    flex-shrink: 0;
    padding: 0.2mm 0.4mm;
}

.hpb-logo-slot {
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    flex-shrink: 0;
}

.hpb-logo {
    width: 100%;
    height: 100%;
    object-fit: contain;
    object-position: center center;
    display: block;
    filter: grayscale(100%);
}

.hpb-preview-shell {
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
}

.hpb-preview-format {
    font-size: 0.75rem;
    color: #64748b;
    letter-spacing: 0.02em;
}

.hpb-tag--qr-only {
    justify-content: center;
    align-items: center;
}

.hpb-qr-only-row {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.hpb-header {
    display: flex;
    align-items: center;
    gap: 1.1mm;
    width: 100%;
    min-width: 0;
    flex-shrink: 0;
}

.hpb-title {
    font-weight: 700;
    line-height: 1.14;
    flex: 1;
    min-width: 0;
    overflow: hidden;
    display: -webkit-box;
    -webkit-box-orient: vertical;
    word-break: break-word;
}

.hpb-rule {
    width: 100%;
    height: 0;
    border-top: 0.2mm solid #222;
    flex-shrink: 0;
}

.hpb-rule--light {
    border-top-color: #888;
}

.hpb-price-wrap {
    width: 100%;
    background: #fff;
    border-top: 0.2mm solid #222;
    border-bottom: 0.2mm solid #222;
    flex-shrink: 0;
}

.hpb-price {
    font-weight: 900;
    line-height: 1;
    text-align: center;
    width: 100%;
    max-width: 100%;
    letter-spacing: -0.03em;
    flex-shrink: 0;
    overflow: hidden;
    white-space: nowrap;
}

.hpb-details {
    width: 100%;
    text-align: center;
    line-height: 1.15;
    flex-shrink: 0;
    min-height: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
}


.hpb-upc,
.hpb-meta-detail {
    color: #111;
    font-family: Consolas, "Courier New", monospace;
    word-break: break-word;
    width: 100%;
    flex-shrink: 0;
}

.hpb-date {
    color: #444;
    font-style: italic;
    flex-shrink: 0;
    width: 100%;
}

.hpb-qr-row {
    width: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
    flex-shrink: 0;
    min-height: 0;
    overflow: hidden;
}

.hpb-qr {
    flex-shrink: 0;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
}

.hpb-qr svg {
    width: 100%;
    height: 100%;
    display: block;
}

.hpb-tag--land .hpb-body--land {
    display: flex;
    flex-direction: row;
    align-items: stretch;
    width: 100%;
    flex: 1 1 auto;
    min-height: 0;
    overflow: hidden;
}

.hpb-qr-col {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    overflow: hidden;
    height: 100%;
}

.hpb-content {
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    flex: 1 1 auto;
    min-width: 0;
    overflow: hidden;
}

.hpb-tag--land .hpb-price,
.hpb-tag--land .hpb-details {
    text-align: left;
}

.hpb-tag--land .hpb-details {
    align-items: flex-start;
}

.hpb-tag--opt2 {
    display: grid;
    box-sizing: border-box;
    width: 100%;
    height: 100%;
    min-height: 0;
    align-items: stretch;
    justify-items: stretch;
    font-family: Arial, Helvetica, sans-serif;
    grid-template-columns: var(--opt2-left) minmax(0, 1fr);
    grid-template-rows: minmax(0, 1fr) var(--opt2-title);
}

.hpb-opt2-id {
    grid-column: 1;
    grid-row: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
    min-width: 0;
    min-height: 0;
    overflow: hidden;
    gap: 0.05mm;
}

.hpb-opt2-sku {
    width: 100%;
    text-align: center;
    font-weight: 600;
    letter-spacing: 0.02em;
    line-height: 1;
    margin-top: 0;
    color: #111;
}

.hpb-opt2-stack {
    grid-column: 2;
    grid-row: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
    text-align: center;
    min-width: 0;
    min-height: 0;
    overflow: hidden;
    gap: 0.25mm;
}

.hpb-opt2-price {
    text-align: center;
    font-weight: 800;
    box-sizing: border-box;
    max-width: 100%;
    flex-shrink: 0;
    overflow: hidden;
    line-height: 1;
    white-space: nowrap;
    text-box-trim: trim-both;
    text-box-edge: cap alphabetic;
}

.hpb-opt2-condition {
    width: 100%;
    font-weight: 800;
    letter-spacing: 0.04em;
    line-height: 1.05;
    color: #111;
    flex-shrink: 0;
}

.hpb-opt2-logo {
    width: 100%;
    flex: 1 1 auto;
    min-height: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    line-height: 0;
    padding: 0.7mm 0.9mm;
    box-sizing: border-box;
}

.hpb-tag--opt2 .hpb-logo {
    filter: none;
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.hpb-opt2-date {
    width: 100%;
    font-weight: 500;
    color: #111;
    line-height: 1.1;
    flex-shrink: 0;
}

.hpb-opt2-title {
    grid-column: 1 / 3;
    grid-row: 2;
    font-weight: 800;
    line-height: 1.12;
    text-align: center;
    min-width: 0;
    min-height: 0;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    box-sizing: border-box;
}

.hpb-opt2-title-line {
    width: 100%;
    text-align: center;
    white-space: nowrap;
    overflow: hidden;
}

.hpb-opt2-title-line--last {
    text-overflow: ellipsis;
}

.hpb-tag--opt3 {
    display: grid;
    box-sizing: border-box;
    width: 100%;
    height: 100%;
    min-height: 0;
    align-items: stretch;
    justify-items: stretch;
    grid-template-columns: var(--opt3-left) minmax(0, 1fr);
    grid-template-rows: var(--opt3-price) var(--opt3-title);
}

.hpb-tag--opt3 .hpb-logo {
    filter: none;
}

.hpb-opt3-qr {
    grid-column: 1;
    grid-row: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 0;
    min-height: 0;
    overflow: hidden;
}

.hpb-opt3-logo {
    grid-column: 1;
    grid-row: 2;
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 0;
    min-height: 0;
    overflow: hidden;
    padding: 0.25mm 0.3mm;
}

.hpb-opt3-price {
    grid-column: 2;
    grid-row: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    min-width: 0;
    min-height: 0;
    overflow: hidden;
    white-space: nowrap;
}

.hpb-opt3-title {
    grid-column: 2;
    grid-row: 2;
    font-weight: 700;
    line-height: 1.14;
    text-align: left;
    min-width: 0;
    min-height: 0;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 0.15mm 0.35mm;
}

.hpb-opt3-title-line {
    width: 100%;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.hpb-tag--portrait-xl {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
    box-sizing: border-box;
    width: 100%;
    height: 100%;
    min-height: 0;
    text-align: center;
}

.hpb-tag--portrait-xl .hpb-logo {
    filter: none;
}

.hpb-portrait-xl-price {
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    font-weight: 700;
    line-height: 1.05;
    white-space: nowrap;
    overflow: hidden;
}

.hpb-portrait-xl-title {
    flex-shrink: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    width: 100%;
    font-weight: 700;
    line-height: 1.12;
    text-transform: uppercase;
    overflow: hidden;
}

.hpb-portrait-xl-title-line {
    width: 100%;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.hpb-portrait-xl-qr {
    flex: 1 1 auto;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    min-height: 0;
    overflow: hidden;
}

.hpb-portrait-xl-status {
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    font-weight: 700;
    line-height: 1.1;
    overflow: hidden;
}

.hpb-portrait-xl-logo {
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    overflow: hidden;
}

.hpb-portrait-xl-sku {
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    font-family: Consolas, "Courier New", monospace;
    letter-spacing: 0.12em;
    line-height: 1.1;
    overflow: hidden;
    white-space: nowrap;
}

.hpb-tag--thermal-land {
    justify-content: flex-start;
    min-height: 100%;
    height: 100%;
}

.hpb-tag--thermal-land .hpb-accent--bottom {
    margin-top: auto;
}

.hpb-tag--thermal-land .hpb-title-row {
    justify-content: flex-start;
    text-align: left;
}

.hpb-tag--thermal-land .hpb-title-row .hpb-title {
    text-align: left;
}

.hpb-tag--thermal-land .hpb-body--qr-right {
    flex-direction: row-reverse;
}

.hpb-tag--qr-focus {
    align-items: center;
    justify-content: flex-start;
    text-align: center;
}

.hpb-tag--thermal-land .hpb-body--thermal {
    display: flex;
    flex-direction: row;
    align-items: stretch;
    width: 100%;
    flex: 1 1 0;
    min-height: 0;
    overflow: hidden;
}

.hpb-tag--thermal-land .hpb-qr-col--thermal {
    display: flex;
    align-items: center;
    justify-content: center;
    flex: 0 0 auto;
    height: 100%;
    aspect-ratio: 1;
    width: auto;
    max-width: 50%;
    overflow: hidden;
    align-self: stretch;
}

.hpb-tag--thermal-land .hpb-qr-col--thermal .hpb-qr {
    width: 100%;
    height: 100%;
}

.hpb-tag--thermal-land .hpb-content--thermal {
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    flex: 1 1 auto;
    min-width: 0;
    min-height: 0;
    overflow: hidden;
    height: 100%;
}

.hpb-tag--thermal-land .hpb-details--thermal {
    flex: 0 1 auto;
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    min-height: 0;
}

.hpb-tag--thermal-land .hpb-price-wrap--thermal {
    flex-shrink: 0;
    border: 0;
    background: transparent;
}

.hpb-corner-logo-wrap {
    margin-top: auto;
    flex-shrink: 0;
    width: 100%;
    box-sizing: border-box;
    display: flex;
    align-items: flex-end;
    justify-content: center;
    overflow: hidden;
    line-height: 0;
}

.hpb-corner-logo-wrap--fill {
    flex: 1 1 auto;
    min-height: 0;
    align-items: center;
}

.hpb-logo-slot--corner {
    max-width: 100%;
    max-height: 100%;
}

.hpb-rule--double {
    border-top-width: 0.35mm;
    box-shadow: 0 0.35mm 0 #111;
}

.hpb-preview-wrap {
    position: relative;
    overflow: hidden;
    border: 1px solid #c8c8c8;
    border-radius: 4px;
    background: #fff;
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.08);
}

.hpb-preview-wrap--margins {
    background: #cbd5e1;
}

.hpb-preview-page {
    box-sizing: border-box;
    display: flex;
    flex-direction: column;
    align-items: stretch;
}

.hpb-preview-page .hpb-tag {
    background: #fff;
    width: 100%;
    height: 100%;
}

.hpb-preview-scale {
    transform-origin: top left;
}

.hpb-preview-scale--actual {
    transform: none;
}

.price-tag-card__guid {
    text-align: left;
    padding: 0.35rem 0 0;
}

/* Legacy preview card classes (retained for compatibility) */
.price-tag-card {
    border: 1px solid #c8c8c8;
    border-radius: 4px;
    padding: 0;
    width: 100%;
    max-width: 280px;
    text-align: left;
    background: #fff;
    box-shadow: 0 1px 4px rgba(0,0,0,.08);
    overflow: hidden;
}

.price-tag-card--hpb {
    max-width: 280px;
}

.price-tag-card--hpb::before {
    content: "";
    display: block;
    height: 4px;
    background: #000;
}

.price-tag-card__header {
    display: flex;
    align-items: flex-start;
    gap: 0.55rem;
    padding: 0.65rem 0.75rem 0.45rem;
    width: 100%;
    min-height: 2.4rem;
}

.price-tag-card__logo {
    width: 2.75rem;
    height: 2.1rem;
    object-fit: contain;
    object-position: left top;
    flex-shrink: 0;
}

.price-tag-card__title {
    font-size: 0.8rem;
    font-weight: 700;
    line-height: 1.25;
    margin-bottom: 0;
    word-break: break-word;
    flex: 1;
    min-width: 0;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.price-tag-card__upc {
    font-size: 0.75rem;
    color: var(--color-text-muted, #6c757d);
    margin-bottom: 0.5rem;
    font-family: monospace;
}

.price-tag-card__upc-label {
    font-weight: 600;
    margin-right: 0.25rem;
}

.price-tag-card__price {
    font-size: 2.35rem;
    font-weight: 900;
    line-height: 1;
    color: #111;
    margin: 0;
    text-align: center;
    width: 100%;
    padding: 0.45rem 0.75rem;
    background: #fff;
    border-top: 1px solid #222;
    border-bottom: 1px solid #222;
    letter-spacing: -0.03em;
}

.price-tag-card__meta {
    font-size: 0.68rem;
    color: #333;
    padding: 0.4rem 0.75rem 0;
    text-align: center;
    font-family: Consolas, "Courier New", monospace;
    line-height: 1.35;
    display: flex;
    flex-direction: column;
    gap: 0.15rem;
    width: 100%;
}

.price-tag-card__date {
    color: #666;
    font-style: italic;
    font-family: "Arial Narrow", Arial, sans-serif;
}

.price-tag-card__guid {
    text-align: center;
    padding: 0 0.75rem 0.5rem;
}

.price-tag-card__qr {
    width: 100%;
    display: flex;
    justify-content: center;
    padding: 0.5rem 0.75rem 0.65rem;
}

.price-tag-card__qr svg {
    width: 5.5rem;
    height: 5.5rem;
    display: block;
}

.price-tag-card__footer {
    font-size: 0.7rem;
    color: var(--color-text-muted, #6c757d);
    margin-top: 0.4rem;
}

/* ── Add-to-queue row inside PriceTagPanel ──────────────────────────────────── */

.lq-add-row {
    display: flex;
    flex-direction: column;
    gap: 0.4rem;
}

.lq-add-row__label {
    color: var(--color-text-muted, #6c757d);
    text-transform: uppercase;
    letter-spacing: 0.04em;
    font-size: 0.75rem;
}

.lq-add-row__controls {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    align-items: center;
}

.lq-add-row__qty {
    width: 100px;
}

/* ── Floating row "..." actions menu (e.g. Inventory catalog rows) ──────────── */

.row-actions-toggle {
    font-weight: 700;
    letter-spacing: 0.05em;
    line-height: 1;
}

.row-actions-menu-backdrop {
    position: fixed;
    inset: 0;
    z-index: 1040;
    background: transparent;
}

.row-actions-menu {
    position: fixed;
    z-index: 1050;
    display: none;
    min-width: 190px;
    padding: 0.35rem;
    background: var(--color-surface-elevated);
    border: 1px solid var(--color-border-strong);
    border-radius: 0.5rem;
    box-shadow: var(--shadow-lg);
}

.row-actions-menu__item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    width: 100%;
    border: none;
    background: none;
    padding: 0.45rem 0.6rem;
    font-size: 0.875rem;
    text-align: left;
    color: var(--color-text, #212529);
    border-radius: 0.35rem;
}

.row-actions-menu__item:hover:not(:disabled),
.row-actions-menu__item:focus-visible {
    background: var(--color-brand-soft);
}

.row-actions-menu__item:disabled {
    color: var(--color-text-muted, #6c757d);
    opacity: 0.6;
    cursor: not-allowed;
}

.row-actions-menu__item--danger {
    color: #dc3545;
}

.row-actions-menu__item--danger:hover:not(:disabled) {
    background: rgba(220, 53, 69, 0.08);
}

.row-actions-menu__divider {
    margin: 0.3rem 0;
    border: none;
    border-top: 1px solid rgba(0, 0, 0, 0.08);
}

/* ── Label queue panel ──────────────────────────────────────────────────────── */

.label-queue-panel {
    margin-top: 1.5rem;
}

.lq-choice--selected,
.btn.lq-choice--selected,
.btn.btn-outline-secondary.lq-choice--selected,
.btn.btn-primary.lq-choice--selected,
.btn.lq-choice--selected:hover,
.btn.lq-choice--selected:focus-visible,
.btn.btn-outline-secondary.lq-choice--selected:hover,
.btn.btn-outline-secondary.lq-choice--selected:focus-visible,
.btn.btn-primary.lq-choice--selected:hover,
.btn.btn-primary.lq-choice--selected:focus-visible {
    color: #fff;
    background: linear-gradient(135deg, var(--color-brand) 0%, var(--color-brand-hover) 100%);
    border: 1px solid var(--color-brand-hover);
    font-weight: 600;
    box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.18);
    transform: none;
}

.lq-profile {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    margin-bottom: 0.75rem;
}

.lq-profile__start {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 0.55rem 0.7rem;
    min-width: 0;
}

.lq-profile-chip {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.32rem 0.75rem 0.32rem 0.55rem;
    border: 1px solid var(--color-brand);
    border-radius: 999px;
    color: var(--color-text);
    background: transparent;
    font-size: 0.86rem;
    font-weight: 500;
    line-height: 1.2;
    white-space: nowrap;
}

.lq-bypass-chip {
    display: inline-flex;
    align-items: center;
    padding: 0.2rem 0.6rem;
    border-radius: 999px;
    border: 1px solid var(--color-border, #334155);
    font-size: 0.75rem;
    color: var(--color-text-muted, #94a3b8);
    white-space: nowrap;
}

.admin-bypass-table th {
    font-size: 0.8rem;
}

.lq-profile-chip__dot {
    width: 0.55rem;
    height: 0.55rem;
    border-radius: 50%;
    background: var(--color-brand);
    flex-shrink: 0;
}

.lq-profile-change {
    position: relative;
}

.lq-profile-change__btn {
    padding: 0;
    border: 0;
    background: none;
    color: var(--color-brand);
    font-size: 0.86rem;
    font-weight: 600;
    line-height: 1.2;
}

.lq-profile-change__btn:hover {
    color: var(--color-brand-hover);
    text-decoration: underline;
}

.lq-profile-popover-backdrop {
    position: fixed;
    inset: 0;
    z-index: 20;
}

.lq-profile-popover {
    position: absolute;
    top: calc(100% + 0.4rem);
    left: 0;
    z-index: 21;
    min-width: 16rem;
    max-width: min(22rem, calc(100vw - 2rem));
    padding: 0.75rem;
    background: var(--color-surface, #fff);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-lg, 8px);
    box-shadow: var(--shadow-lg, 0 12px 32px rgba(15, 23, 42, 0.18));
}

.lq-profile-popover .lq-layout-select__control {
    width: 100%;
}

.lq-profile-popover__section + .lq-profile-popover__section {
    margin-top: 0.7rem;
}

.lq-profile-popover__heading {
    font-size: 0.72rem;
    font-weight: 600;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: var(--color-text-muted);
    margin-bottom: 0.35rem;
}

.lq-profile-popover__pills {
    display: flex;
    flex-wrap: wrap;
    gap: 0.3rem;
}

.lq-layout-select {
    display: flex;
    flex-direction: column;
    gap: 0.3rem;
    min-width: 0;
}

.lq-layout-select__label {
    font-size: 0.72rem;
    font-weight: 600;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: var(--color-text-muted);
}

.lq-layout-select__control {
    max-width: 100%;
    min-width: 0;
}

.lq-toolbar .btn,
.lq-profile-popover .btn {
    cursor: pointer;
}

.lq-size-select {
    width: 100%;
    font-size: 0.82rem;
    font-variant-numeric: tabular-nums;
}

.lq-tmpl-btn {
    font-size: 0.78rem;
    white-space: nowrap;
}

.lq-status {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.5rem 0.75rem;
    margin-bottom: 0.75rem;
}

.lq-status__summary {
    font-size: 0.82rem;
    font-weight: 500;
    color: var(--color-text-muted);
}

.lq-page-progress {
    background: var(--color-border, #dee2e6);
    border-radius: 4px;
    height: 8px;
    overflow: hidden;
    flex: 1;
    min-width: 8rem;
    max-width: 16rem;
}

.lq-page-progress__bar {
    height: 100%;
    background: var(--color-primary, #0d6efd);
    border-radius: 4px;
    transition: width 0.3s ease;
}

.lq-actions {
    margin-top: 0.1rem;
}

.lq-queue-list {
    margin-bottom: 0.75rem;
}

.lq-queue-list__table th {
    font-size: 0.8rem;
    color: #6c757d;
    font-weight: 600;
}

.lq-queue-list__table td {
    vertical-align: middle;
}

/* ── Thermal label preview + margin controls ─────────────────────────────── */

.thermal-label-preview {
    display: flex;
    flex-wrap: wrap;
    gap: 1.25rem;
    align-items: flex-start;
    margin-top: 0;
    margin-bottom: 0.75rem;
    padding: 1rem;
    background: var(--color-surface, #fff);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-lg, 8px);
}

.lq-preview-pane {
    margin-top: 0;
    margin-bottom: 0.75rem;
    background: var(--color-surface, #fff);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-lg, 8px);
    overflow: hidden;
}

.lq-preview-pane__header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    padding: 0.45rem 0.7rem;
    border-bottom: 1px solid var(--color-border);
}

.lq-preview-pane--collapsed .lq-preview-pane__header {
    border-bottom: 0;
}

.lq-preview-pane__toggle {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    min-width: 0;
    padding: 0.1rem 0;
    border: 0;
    background: none;
    color: var(--color-text, #1e293b);
    font-size: 0.86rem;
    font-weight: 650;
    line-height: 1.2;
    cursor: pointer;
}

.lq-preview-pane__toggle:hover {
    color: var(--color-brand);
}

.lq-preview-pane__chevron {
    width: 0.45rem;
    height: 0.45rem;
    border-right: 1.6px solid currentColor;
    border-bottom: 1.6px solid currentColor;
    transform: rotate(45deg);
    margin-right: 0.15rem;
    flex-shrink: 0;
}

.lq-preview-pane--collapsed .lq-preview-pane__chevron {
    transform: rotate(-45deg);
    margin-top: 0.1rem;
}

.lq-preview-pane__title {
    letter-spacing: 0.01em;
}

.lq-preview-pane__hint {
    font-size: 0.75rem;
    font-weight: 500;
    color: var(--color-text-muted);
    white-space: nowrap;
}

.lq-preview-pane__tools {
    display: inline-flex;
    align-items: center;
    gap: 0.85rem;
    flex-shrink: 0;
    margin-left: auto;
}

.lq-preview-pane__rotate {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    margin: 0;
    font-size: 0.8rem;
}

.lq-preview-pane__rotate .form-check-input {
    margin: 0;
}

.lq-preview-pane__rotate .form-check-label {
    margin: 0;
    cursor: pointer;
}

.lq-preview-pane__body {
    height: var(--lq-preview-height, 240px);
    min-height: 160px;
    overflow: hidden;
    display: flex;
    align-items: stretch;
    justify-content: stretch;
    padding: 0;
}

.lq-preview-pane .hpb-preview-shell {
    gap: 0;
    flex: 0 0 auto;
    transform-origin: center center;
}

.lq-preview-pane .hpb-preview-wrap {
    box-shadow: none;
    border-radius: 2px;
}

.thermal-label-preview--surround {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr) auto;
    grid-template-rows: auto minmax(0, 1fr) auto;
    justify-content: stretch;
    justify-items: stretch;
    align-items: center;
    column-gap: 0.35rem;
    row-gap: 0;
    padding: 0 0.15rem;
    border: 0;
    background: transparent;
    margin: 0;
    width: 100%;
    max-width: 100%;
    height: 100%;
    min-height: 0;
}

.lq-preview-pane__resize {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 0.7rem;
    cursor: ns-resize;
    background: var(--color-surface, #fff);
    border-top: 1px solid var(--color-border);
    touch-action: none;
}

.lq-preview-pane__resize:hover,
.lq-preview-pane__resize:active {
    background: var(--color-bg-subtle, #f8fafc);
}

.lq-preview-pane__resize-grip {
    width: 2.1rem;
    height: 0.22rem;
    border-radius: 99px;
    background: #cbd5e1;
}

.thermal-label-preview__margin--top {
    grid-column: 2;
    grid-row: 1;
}

.thermal-label-preview__margin--left {
    grid-column: 1;
    grid-row: 2;
}

.thermal-label-preview--surround .thermal-label-preview__sample {
    grid-column: 2;
    grid-row: 2;
    display: flex;
    align-items: center;
    justify-content: center;
    justify-self: stretch;
    align-self: stretch;
    width: auto;
    height: auto;
    min-height: 0;
    min-width: 0;
    overflow: hidden;
}

.thermal-label-preview__margin--right {
    grid-column: 3;
    grid-row: 2;
}

.thermal-label-preview__margin--bottom {
    grid-column: 2;
    grid-row: 3;
}

.lq-preview-pane .thermal-label-preview__sample {
    width: auto;
    height: auto;
    flex: none;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.thermal-label-preview--surround .lq-thermal-margins__field {
    flex-direction: row;
    align-items: center;
    gap: 0.25rem;
    margin: 0;
}

.thermal-label-preview--surround .lq-thermal-margins__side {
    flex: 0 0 auto;
    min-width: 2rem;
    text-align: right;
    font-size: 0.68rem;
}

.thermal-label-preview--surround .lq-thermal-margins__field .form-control {
    width: 3.5rem;
    min-width: 3.5rem;
    padding: 0.1rem 0.25rem;
    font-size: 0.74rem;
}

.thermal-label-preview__margin--top,
.thermal-label-preview__margin--bottom {
    align-self: center;
    padding: 0;
}

.thermal-label-preview__margin .lq-thermal-margins__field {
    flex-direction: row;
    align-items: center;
    gap: 0.2rem;
}

.thermal-label-preview__margin--left .lq-thermal-margins__field,
.thermal-label-preview__margin--right .lq-thermal-margins__field {
    flex-direction: row;
}

.thermal-label-preview__margin .lq-thermal-margins__field .form-control {
    width: 3.5rem;
    min-width: 3.5rem;
}

.thermal-label-preview__sample {
    flex: 0 0 auto;
    min-width: 0;
}

.thermal-label-preview--surround .hpb-preview-format {
    display: none;
}

.thermal-label-preview__sample-note {
    max-width: 22rem;
}

.thermal-label-preview__controls {
    flex: 1 1 12rem;
    min-width: 12rem;
}

.thermal-label-preview__controls-header {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 0.5rem;
    margin-bottom: 0.5rem;
}

.thermal-label-preview__controls-title {
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--color-text, #1e293b);
}

.thermal-label-preview__controls .lq-layout-select {
    max-width: 14rem;
}

.thermal-label-preview__reset {
    padding: 0;
    font-size: 0.78rem;
    text-decoration: none;
}

.thermal-label-preview__reset:hover {
    text-decoration: underline;
}

.thermal-label-preview__margins {
    border-left: none;
    padding-left: 0;
    width: 100%;
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.4rem 0.65rem;
    align-items: center;
}

.thermal-label-preview__margins .lq-thermal-margins__label {
    grid-column: 1 / -1;
}

.thermal-label-preview__margins .lq-thermal-margins__field {
    min-width: 0;
}

.thermal-label-preview__margins .lq-thermal-margins__field .form-control {
    width: 100%;
    min-width: 0;
    max-width: 4.25rem;
}

.thermal-label-preview--controls-only {
    margin-top: 0;
    margin-bottom: 0;
    padding: 0.85rem;
    flex: 1 1 17rem;
    min-width: 17rem;
}

.lq-thermal-margins {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.35rem 0.55rem;
    width: 100%;
    padding-left: 0.65rem;
    border-left: 1px solid var(--color-border);
}

.lq-thermal-margins__label {
    font-size: 0.78rem;
    font-weight: 600;
    color: var(--color-text-muted);
    white-space: nowrap;
}

.lq-thermal-margins__field {
    display: inline-flex;
    align-items: center;
    gap: 0.25rem;
    margin: 0;
}

.lq-thermal-margins__side {
    font-size: 0.72rem;
    color: var(--color-text-muted);
    white-space: nowrap;
}

.lq-thermal-margins__field .form-control {
    width: 3.4rem;
    padding-left: 0.35rem;
    padding-right: 0.35rem;
    font-variant-numeric: tabular-nums;
}

.lq-thermal-margins.thermal-label-preview__margins {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.4rem 0.65rem;
    padding-left: 0;
    border-left: none;
}

@media (max-width: 576px) {
    .lq-thermal-margins {
        padding-left: 0;
        border-left: none;
    }
}

/* ── Owner queue management modal (Persistent Label Print Queue, phase 2) ────────────────────────── */

.lq-manage__search {
    max-width: 22rem;
}

.lq-manage__table th {
    font-size: 0.8rem;
    color: #6c757d;
    font-weight: 600;
}

.lq-manage__table td {
    vertical-align: middle;
}

.lq-family-btn {
    font-size: 0.78rem;
    white-space: nowrap;
}

/* ── App modal (catalog / Square inventory) ─────────────────────────────────── */

.app-modal {
    position: fixed;
    inset: 0;
    z-index: 1050;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1rem;
    background: rgba(15, 23, 42, 0.55);
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
    animation: bcs-fade-in 0.15s ease;
}

.app-modal__dialog {
    width: min(520px, 100%);
    max-height: min(90vh, 900px);
    display: flex;
    flex-direction: column;
    background: var(--color-surface);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-xl);
    box-shadow: var(--shadow-lg);
    overflow: hidden;
}

.app-modal__dialog--wide {
    width: min(720px, 100%);
}

.app-modal__dialog--catalog {
    width: min(60rem, calc(100vw - 2rem));
}

.app-modal__header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    padding: 1rem 1.25rem;
    border-bottom: 1px solid var(--color-border);
    background: var(--color-surface-muted);
    flex-shrink: 0;
}

.app-modal__title {
    margin: 0;
    font-size: 1.1rem;
    font-weight: 700;
}

.app-modal__close {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 2rem;
    height: 2rem;
    border: 1px solid var(--color-border);
    border-radius: var(--radius-sm);
    background: var(--color-surface);
    color: var(--color-text-muted);
    cursor: pointer;
    flex-shrink: 0;
    transition: background var(--transition), color var(--transition);
}

.app-modal__close:hover {
    background: var(--color-bg-accent);
    color: var(--color-text);
}

.app-modal__body {
    padding: 1.25rem;
    overflow-y: auto;
    flex: 1 1 auto;
    min-height: 0;
}

.square-inventory-panel--modal {
    margin: 0;
}

.square-inventory-panel--modal .square-inventory-panel__body {
    padding: 0;
}

.square-inventory-panel--modal .add-to-catalog-panel {
    border-top: 1px solid var(--color-border);
    margin-top: 0.75rem;
    padding-top: 0.75rem;
}

.square-inventory-panel--modal .add-to-catalog-panel > .h6 {
    display: none;
}

.square-inventory-panel--modal .square-inventory-panel__match,
.square-inventory-panel--modal .alert {
    margin-bottom: 0.75rem;
}

.add-catalog-compose {
    display: grid;
    gap: 0.75rem 1.25rem;
}

.add-catalog-compose--single {
    grid-template-columns: minmax(0, 1fr);
}

.add-catalog-price .add-to-catalog-panel__qty {
    margin-bottom: 0.75rem;
}

.add-catalog-compose__footer {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-end;
    justify-content: space-between;
    gap: 0.75rem;
}

.add-to-catalog-panel__qty .form-control {
    width: 5.5rem;
}

@media (min-width: 768px) {
    .add-catalog-compose {
        grid-template-columns: minmax(0, 1fr) 16rem;
        align-items: start;
    }

    .add-catalog-compose--single {
        grid-template-columns: minmax(0, 1fr);
    }

    .add-catalog-compose__side {
        position: sticky;
        top: 0;
    }
}

@media (max-width: 991px) {
    .app-modal .square-inventory-panel .btn-group {
        flex-direction: row;
        flex-wrap: wrap;
        width: auto;
    }

    .app-modal .square-inventory-panel .btn-group > .btn {
        width: auto;
        margin-left: -1px !important;
    }

    .app-modal .square-inventory-panel .btn-group > .btn:first-child {
        margin-left: 0 !important;
    }

    .app-modal .square-inventory-panel .add-to-catalog-panel .d-flex.flex-wrap.gap-2 > .btn,
    .app-modal .square-inventory-panel .d-flex.flex-wrap.gap-2 {
        flex-direction: row;
        align-items: center;
    }

    .app-modal .square-inventory-panel .add-to-catalog-panel .d-flex.flex-wrap.gap-2 > .btn,
    .app-modal .square-inventory-panel .d-flex.flex-wrap.gap-2 > .btn {
        width: auto;
    }
}

.catalog-action-prompt .fw-semibold {
    font-size: 0.95rem;
}

/* ── Barcode scanner camera overlay ─────────────────────────────────────────── */

/* Full-screen backdrop */
.bcs-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.88);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
    animation: bcs-fade-in 0.15s ease;
}

@keyframes bcs-fade-in {
    from { opacity: 0; }
    to   { opacity: 1; }
}

/* Dialog card */
.bcs-dialog {
    background: #111827;
    border-radius: 12px;
    overflow: hidden;
    width: min(460px, 95vw);
    box-shadow: 0 24px 48px rgba(0, 0, 0, 0.6);
}

.bcs-dialog--info {
    width: min(420px, 95vw);
}

/* Header bar */
.bcs-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    padding: 0.75rem 1rem;
    background: #0f172a;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.bcs-header-actions {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.bcs-torch-btn {
    background: #374151;
    border: 1px solid rgba(255, 255, 255, 0.15);
    color: #f1f5f9;
    border-radius: 6px;
    cursor: pointer;
    font-size: 1rem;
    line-height: 1;
    padding: 4px 10px;
    transition: background 0.15s;
}

.bcs-torch-btn--on {
    background: #d97706;
    border-color: #f59e0b;
}

.bcs-camera-select {
    width: 100%;
    margin-bottom: 1rem;
}

.bcs-camera-actions {
    display: flex;
    justify-content: flex-end;
}

.bcs-title {
    color: #f1f5f9;
    font-weight: 600;
    font-size: 1rem;
}

.bcs-cancel-btn {
    background: transparent;
    border: 1px solid rgba(255, 255, 255, 0.15);
    color: #94a3b8;
    border-radius: 6px;
    cursor: pointer;
    font-size: 0.82rem;
    padding: 4px 10px;
    transition: background 0.15s, color 0.15s;
}

.bcs-cancel-btn:hover {
    background: rgba(255, 255, 255, 0.1);
    color: #f1f5f9;
}

/* Viewfinder — video + overlay-UI layers */
.bcs-viewfinder-wrap {
    position: relative;
    background: #000;
    line-height: 0;          /* Remove gap below inline video */
}

.bcs-video {
    width: 100%;
    max-height: min(52vh, 480px);
    object-fit: contain;
    display: block;
    background: #000;
}

/* Translucent dimmer regions around the clear frame */
.bcs-overlay-ui {
    position: absolute;
    inset: 0;
    display: flex;
    flex-direction: column;
    pointer-events: none;
}

.bcs-dimmer {
    background: rgba(0, 0, 0, 0.45);
}

.bcs-dimmer--top,
.bcs-dimmer--bottom {
    flex: 1;
}

.bcs-dimmer-mid {
    display: flex;
    flex-direction: row;
    /* Clear window is 60% wide */
}

.bcs-dimmer--side {
    flex: 1;
}

/* The transparent "frame" window */
.bcs-frame {
    position: relative;
    width: 60%;
    aspect-ratio: 1.6 / 1;
}

/* Corner bracket marks */
.bcs-corner {
    position: absolute;
    width: 22px;
    height: 22px;
    border: 0 solid #3b82f6;   /* blue-500 */
    border-width: 0;
}

.bcs-corner--tl { top: 0; left: 0;  border-top-width: 3px; border-left-width: 3px;  border-top-left-radius: 4px; }
.bcs-corner--tr { top: 0; right: 0; border-top-width: 3px; border-right-width: 3px; border-top-right-radius: 4px; }
.bcs-corner--bl { bottom: 0; left: 0;  border-bottom-width: 3px; border-left-width: 3px;  border-bottom-left-radius: 4px; }
.bcs-corner--br { bottom: 0; right: 0; border-bottom-width: 3px; border-right-width: 3px; border-bottom-right-radius: 4px; }

/* Animated scan line */
.bcs-scan-line {
    position: absolute;
    left: 0;
    right: 0;
    top: 0;
    height: 2px;
    background: linear-gradient(90deg, transparent 0%, #3b82f6 40%, #60a5fa 60%, transparent 100%);
    animation: bcs-sweep 2s ease-in-out infinite;
}

@keyframes bcs-sweep {
    0%   { top: 0%;   opacity: 0; }
    10%  {             opacity: 1; }
    90%  {             opacity: 1; }
    100% { top: 100%; opacity: 0; }
}

/* Hint text below viewfinder */
.bcs-hint {
    text-align: center;
    color: #94a3b8;
    font-size: 0.82rem;
    margin: 0;
    padding: 0.6rem 1rem;
    background: #0f172a;
}

/* Info modal body */
.bcs-body {
    padding: 1.25rem 1.25rem 1rem;
    color: #cbd5e1;
    font-size: 0.92rem;
    line-height: 1.65;
}

.bcs-body p      { margin-bottom: 0.75rem; }
.bcs-body ol     { padding-left: 1.4rem; margin-bottom: 0; }
.bcs-body ol li  { margin-bottom: 0.4rem; }
.bcs-body strong { color: #f1f5f9; }

/* ── Product photo search (eBay image API) ─────────────────────────────────── */

body.ips-open {
    overflow: hidden;
}

.ips-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.88);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
    animation: bcs-fade-in 0.15s ease;
    padding: 1rem;
}

.ips-panel {
    background: #111827;
    border-radius: 12px;
    overflow: hidden;
    width: min(460px, 95vw);
    box-shadow: 0 24px 48px rgba(0, 0, 0, 0.6);
}

.ips-panel--modal {
    width: min(420px, 95vw);
}

.ips-header {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
    padding: 0.85rem 1rem;
    background: #0f172a;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    color: #f1f5f9;
}

.ips-hint {
    color: #94a3b8;
    font-size: 0.82rem;
}

.ips-video-wrap {
    position: relative;
    background: #000;
    line-height: 0;
}

.ips-video {
    width: 100%;
    max-height: min(52vh, 480px);
    object-fit: contain;
    display: block;
    background: #000;
}

.ips-frame {
    position: absolute;
    inset: 12%;
    border: 2px solid rgba(59, 130, 246, 0.85);
    border-radius: 8px;
    box-shadow: 0 0 0 9999px rgba(0, 0, 0, 0.35);
    pointer-events: none;
}

.ips-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    justify-content: flex-end;
    padding: 0.85rem 1rem;
    background: #0f172a;
}

.ips-modal-body {
    padding: 1rem;
    color: #cbd5e1;
    font-size: 0.92rem;
    line-height: 1.65;
}

.image-search-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    align-items: center;
}

.image-search-actions__file {
    cursor: pointer;
}

.image-search-actions__input {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

/* USB-scanner hint row below the search input */
.scan-hint {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.25rem 0.6rem;
    font-size: 0.82rem;
    color: var(--color-text-muted, #6c757d);
}

.scan-hint__sep {
    color: var(--color-border, #dee2e6);
}

/* Collapsible Help sections (default closed; state is not persisted) */
.help-disclosure {
    border: 1px solid var(--color-border);
    border-radius: var(--radius-md);
    background: var(--color-surface-muted);
}

.help-disclosure__summary {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.45rem 0.75rem;
    font-size: 0.8125rem;
    font-weight: 600;
    color: var(--color-text-secondary);
    cursor: pointer;
    list-style: none;
    user-select: none;
}

.help-disclosure__summary::-webkit-details-marker {
    display: none;
}

.help-disclosure__summary::before {
    content: "▸";
    display: inline-block;
    color: var(--color-text-muted);
    font-size: 0.85rem;
    transition: transform var(--transition);
}

.help-disclosure[open] > .help-disclosure__summary::before {
    transform: rotate(90deg);
}

.help-disclosure__body {
    padding: 0 0.75rem 0.65rem;
    color: var(--color-text-muted);
    font-size: 0.82rem;
    line-height: 1.45;
}

.help-disclosure__list {
    padding-left: 1.1rem;
    display: grid;
    gap: 0.35rem;
}

.label-queue-panel__help .help-disclosure__body {
    padding-top: 0.1rem;
}

/* Admin portal (Stage 2) */
.admin-user-table th {
    white-space: nowrap;
}

.square-owner-settings__meta dt {
    color: var(--color-text-muted, #6c757d);
}

.square-owner-settings__meta dd {
    margin-bottom: 0.5rem;
}

.square-owner-settings__token-form textarea {
    font-family: var(--bs-font-monospace, monospace);
    font-size: 0.82rem;
}

.square-connection-log {
    max-height: 28rem;
    overflow: auto;
}

.square-connection-log__row--error {
    background: color-mix(in srgb, var(--bs-danger, #dc3545) 8%, transparent);
}

.square-connection-log__details {
    margin-top: 0.15rem;
    word-break: break-word;
    white-space: pre-wrap;
}

.user-role-editor__checks .form-check {
    min-width: 7rem;
}

/* Feedback */
.feedback-page {
    max-width: 640px;
    margin: 0 auto;
    padding: 0.5rem 0 2rem;
    animation: fadeInUp 0.45s ease;
}

.feedback-page__card {
    border: 1px solid var(--color-border);
    box-shadow: var(--shadow-lg);
}

.feedback-page__card .card-body {
    padding: 2rem 2.25rem 1.75rem;
}

.feedback-page__header {
    text-align: center;
    margin-bottom: 2rem;
}

.feedback-page__header h1 {
    font-size: clamp(1.75rem, 4vw, 2.125rem);
    font-weight: 700;
    letter-spacing: -0.03em;
    margin-bottom: 0.75rem;
    color: var(--color-text);
}

.feedback-page__header p {
    margin: 0 auto;
    max-width: 34rem;
    font-size: 0.9375rem;
    line-height: 1.7;
    color: var(--color-text-secondary);
}

.feedback-page__card--success .card-body {
    padding: 2.25rem 2rem;
}

.feedback-page__footer {
    margin: 1.75rem 0 0;
    padding-top: 1.5rem;
    border-top: 1px solid var(--color-border);
    text-align: center;
    font-size: 0.875rem;
    color: var(--color-text-muted);
    line-height: 1.6;
}

.feedback-page__trust {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem 1.25rem;
    margin-top: 1.25rem;
    padding-top: 1.25rem;
    border-top: 1px solid var(--color-border);
    font-size: 0.8125rem;
    color: var(--color-text-muted);
}

.feedback-page__trust span::before {
    content: '✓';
    margin-right: 0.35rem;
    color: var(--color-brand);
    font-weight: 700;
}

@media (max-width: 640px) {
    .feedback-page__card .card-body {
        padding: 1.5rem 1.25rem 1.35rem;
    }

    .feedback-page__header {
        margin-bottom: 1.5rem;
    }
}

.feedback-form__context,
.feedback-admin__detail .feedback-form__context {
    padding: 0.85rem 1rem;
    border: 1px solid var(--color-border);
    border-radius: var(--radius-md);
    background: var(--color-surface-muted, #f8fafc);
}

.feedback-context-dl {
    display: grid;
    gap: 0.45rem 1rem;
}

.feedback-context-dl > div {
    display: grid;
    grid-template-columns: minmax(6rem, 8rem) 1fr;
    gap: 0.5rem 1rem;
    align-items: start;
}

.feedback-context-dl dt {
    margin: 0;
    font-size: 0.78rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    color: var(--color-text-muted);
}

.feedback-context-dl dd {
    margin: 0;
    font-size: 0.9rem;
    word-break: break-word;
}

.feedback-admin__list {
    max-height: 32rem;
    overflow-y: auto;
}

.feedback-admin__unread-dot {
    display: inline-block;
    width: 0.5rem;
    height: 0.5rem;
    margin-right: 0.35rem;
    border-radius: 50%;
    background: #ef4444;
    vertical-align: middle;
}

.notifications-page__unread-dot {
    display: inline-block;
    width: 0.5rem;
    height: 0.5rem;
    margin-right: 0.35rem;
    border-radius: 50%;
    background: #ef4444;
    vertical-align: middle;
}

.notifications-page__body,
.system-notification-modal__body {
    white-space: pre-wrap;
    word-break: break-word;
}

.notifications-admin__list,
.notifications-page__list {
    max-height: 24rem;
    overflow-y: auto;
}

.app-modal--blocking {
    z-index: 10050;
}

.app-modal--blocking .app-modal__dialog {
    pointer-events: auto;
}

.notifications-admin__org-list {
    max-height: 12rem;
    overflow-y: auto;
    border: 1px solid rgba(148, 163, 184, 0.25);
    border-radius: 0.375rem;
    padding: 0.75rem;
}

.feedback-admin__description {
    white-space: pre-wrap;
    word-break: break-word;
    font-size: 0.95rem;
}

.feedback-admin__attachment-list {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.feedback-admin__attachment-item {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    padding: 0.85rem 1rem;
    border: 1px solid var(--color-border);
    border-radius: var(--radius-md);
    background: var(--color-surface-muted);
}

.feedback-admin__attachment-meta {
    display: flex;
    flex-direction: column;
    gap: 0.2rem;
    min-width: 0;
}

.feedback-admin__empty {
    min-height: 12rem;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 1px dashed var(--color-border);
    border-radius: var(--radius-md);
    padding: 2rem;
    text-align: center;
}

.lookup-feedback-prompt {
    border-style: dashed;
}

.lookup-feedback-prompt .card-body {
    padding-top: 0.7rem;
    padding-bottom: 0.7rem;
}

.admin-tag-logo-preview {
    max-width: 120px;
    max-height: 72px;
    object-fit: contain;
    border: 1px solid var(--color-border);
    border-radius: var(--radius-md);
    padding: 0.35rem;
    background: var(--color-surface);
}

/* ── Performance admin ─────────────────────────────────────────────────────── */

.performance-admin__list {
    max-height: 32rem;
    overflow-y: auto;
}

.performance-admin__cached-scans-summary {
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    list-style: none;
}

.performance-admin__cached-scans-summary::-webkit-details-marker {
    display: none;
}

.performance-admin__cached-scans-summary::before {
    content: "▸";
    display: inline-block;
    margin-right: 0.45rem;
    color: var(--color-text-muted);
    transition: transform 0.15s ease;
}

.performance-admin__cached-scans[open] .performance-admin__cached-scans-summary::before {
    transform: rotate(90deg);
}

.performance-admin__cached-list {
    max-height: 20rem;
}

.performance-admin__cached-item {
    border-bottom: 1px solid var(--color-border);
}

.performance-admin__cached-item:last-child {
    border-bottom: none;
}

.performance-admin__cached-item-button {
    border: none;
    border-radius: 0;
}

.performance-admin__cached-item--selected .performance-admin__cached-item-button:not(.active) {
    background: rgba(20, 184, 166, 0.08);
}

.cache-admin__summary {
    background: var(--color-surface-muted);
}

.cache-admin__select-col {
    width: 2.5rem;
}

.cache-admin__key-cell {
    max-width: 24rem;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.cache-admin__call-cell {
    max-width: 28rem;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.cache-admin__payload {
    max-height: min(70vh, 40rem);
    overflow: auto;
    margin-bottom: 0;
    padding: 0.75rem;
    border-radius: 0.375rem;
    background: var(--color-surface-muted);
    font-size: 0.75rem;
    white-space: pre-wrap;
    word-break: break-word;
}

.performance-admin__summary-table {
    margin-bottom: 0;
}

.performance-admin__bar-track {
    height: 0.5rem;
    border-radius: 999px;
    background: var(--color-surface-muted);
    overflow: hidden;
}

.performance-admin__bar-fill {
    height: 100%;
    border-radius: inherit;
    background: linear-gradient(90deg, rgba(20, 184, 166, 0.85), rgba(45, 212, 191, 0.65));
    min-width: 0;
}

.performance-admin__bar-fill--detail {
    background: linear-gradient(90deg, rgba(59, 130, 246, 0.85), rgba(96, 165, 250, 0.65));
}

.performance-admin__breakdown {
    display: flex;
    flex-direction: column;
    gap: 0.85rem;
}

.performance-admin__empty {
    min-height: 12rem;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 1px dashed var(--color-border);
    border-radius: var(--radius-md);
    padding: 2rem;
    text-align: center;
}

.performance-admin__empty--compact {
    min-height: 8rem;
    padding: 1.5rem;
}

.performance-admin__log-search {
    min-width: 12rem;
    max-width: 18rem;
    flex: 1 1 12rem;
}

.performance-admin__http-table-wrap {
    max-height: 18rem;
    overflow: auto;
}

.performance-admin__http-table {
    margin-bottom: 0;
}

.performance-admin__http-url {
    max-width: 28rem;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.performance-admin__url-link {
    color: inherit;
    text-decoration: underline;
    text-underline-offset: 0.12em;
}

.performance-admin__url-link:hover {
    color: var(--bs-primary);
}

.performance-admin__stage-urls {
    padding-left: 0.75rem;
    border-left: 2px solid var(--color-border);
}

.performance-admin__stage-url + .performance-admin__stage-url {
    margin-top: 0.25rem;
}

.performance-admin__stage-url-meta {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.35rem;
    margin-bottom: 0.15rem;
}

.performance-admin__stage-url--cache {
    opacity: 0.92;
}

.performance-admin__result {
    display: inline-block;
    max-width: 100%;
    font-weight: 500;
}

.performance-admin__cache-badge {
    font-size: 0.65rem;
    font-weight: 600;
    letter-spacing: 0.02em;
}

.performance-admin__http-row--cache {
    --bs-table-bg: rgba(13, 202, 240, 0.08);
}

.performance-admin__timeline-legend {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem 1.25rem;
}

.performance-admin__timeline-legend-item {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
}

.performance-admin__timeline-swatch {
    width: 0.85rem;
    height: 0.55rem;
    border-radius: 0.2rem;
    border: 1px solid transparent;
    flex-shrink: 0;
}

.performance-admin__timeline-swatch--task {
    background: rgba(59, 130, 246, 0.28);
    border-color: rgba(59, 130, 246, 0.55);
}

.performance-admin__timeline-swatch--url {
    background: rgba(59, 130, 246, 0.88);
    border-color: rgba(37, 99, 235, 0.9);
}

.performance-admin__timeline-swatch--cache {
    background: rgba(13, 202, 240, 0.35);
    border-color: rgba(13, 202, 240, 0.75);
    border-style: dashed;
}

.performance-admin__timeline {
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
}

.performance-admin__timeline-axis,
.performance-admin__timeline-lane {
    display: grid;
    grid-template-columns: 9.5rem minmax(0, 1fr);
    gap: 0.65rem;
    align-items: center;
}

.performance-admin__timeline-axis-track,
.performance-admin__timeline-lane-track {
    position: relative;
    --timeline-row-height: 1.35rem;
    --timeline-row-gap: 0.15rem;
    --timeline-row-count: 1;
    min-height: calc(
        var(--timeline-row-count) * var(--timeline-row-height)
        + max(0, var(--timeline-row-count) - 1) * var(--timeline-row-gap)
        + 0.4rem);
    border-radius: 0.35rem;
    background: var(--color-surface-muted);
    border: 1px solid var(--color-border);
    overflow: hidden;
}

.performance-admin__timeline-axis-track {
    --timeline-row-count: 1;
    min-height: 1.35rem;
    background: transparent;
    border: none;
}

.performance-admin__timeline-tick {
    position: absolute;
    top: 0;
    transform: translateX(-50%);
    font-size: 0.68rem;
    font-family: var(--font-mono);
    color: var(--color-text-muted);
    white-space: nowrap;
}

.performance-admin__timeline-lane-label {
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--color-text-secondary);
    line-height: 1.2;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.performance-admin__timeline-bar {
    position: absolute;
    top: calc(0.2rem + var(--timeline-row-index, 0) * (var(--timeline-row-height) + var(--timeline-row-gap)));
    height: var(--timeline-row-height);
    border-radius: 0.25rem;
    min-width: 2px;
    overflow: hidden;
    display: flex;
    align-items: center;
    padding: 0 0.25rem;
    box-sizing: border-box;
}

.performance-admin__timeline-bar--task {
    background: rgba(59, 130, 246, 0.28);
    border: 1px solid rgba(59, 130, 246, 0.55);
    z-index: 1;
}

.performance-admin__timeline-bar--url {
    background: rgba(59, 130, 246, 0.88);
    border: 1px solid rgba(37, 99, 235, 0.9);
    z-index: 2;
}

.performance-admin__timeline-bar--cache {
    background: rgba(13, 202, 240, 0.35);
    border: 1px dashed rgba(13, 202, 240, 0.75);
    z-index: 2;
}

.performance-admin__timeline-bar-label {
    font-size: 0.62rem;
    font-family: var(--font-mono);
    color: #fff;
    text-shadow: 0 1px 1px rgba(0, 0, 0, 0.35);
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.performance-admin__timeline-bar--task .performance-admin__timeline-bar-label {
    color: var(--color-text);
    text-shadow: none;
}

@media (max-width: 767.98px) {
    .performance-admin__timeline-axis,
    .performance-admin__timeline-lane {
        grid-template-columns: 6.5rem minmax(0, 1fr);
        gap: 0.45rem;
    }

    .performance-admin__timeline-lane-label {
        font-size: 0.68rem;
    }
}

.scanner-status {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.5rem;
    margin-top: 0.75rem;
}

.scanner-status__chip {
    display: inline-flex;
    align-items: center;
    border-radius: 999px;
    padding: 0.2rem 0.7rem;
    background: #e8eef5;
    color: #1e293b;
    font-size: 0.82rem;
    font-weight: 650;
}

.scanner-status__notice {
    margin: 0.45rem 0 0;
    font-size: 0.85rem;
}

.scanner-pair {
    position: fixed;
    inset: 0;
    z-index: 11000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1rem;
    background: rgba(15, 23, 42, 0.48);
}

.scanner-pair__card {
    width: min(24rem, 100%);
    padding: 1.25rem;
    border-radius: 12px;
    background: #fff;
    color: #0f172a;
    box-shadow: 0 16px 48px rgba(15, 23, 42, 0.28);
}

.scanner-pair__qr {
    margin: 0.75rem 0 1rem;
}

.scanner-pair__qr svg,
.scanner-pair__qr img {
    display: block;
    width: min(18rem, 100%);
    height: auto;
    margin: 0 auto;
}

.grade-scale-backdrop {
    position: fixed;
    inset: 0;
    z-index: 10990;
    background: rgba(15, 23, 42, 0.45);
}

.grade-scale-panel {
    position: fixed;
    z-index: 11000;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: min(28rem, calc(100vw - 2rem));
    max-height: calc(100vh - 2rem);
    overflow: auto;
}

.grade-scale-list__row {
    display: grid;
    grid-template-columns: 6.5rem 1fr;
    gap: 0.5rem 0.75rem;
    padding: 0.35rem 0;
    border-top: 1px solid var(--color-border, #e2e8f0);
}

.grade-scale-list__row:first-child {
    border-top: none;
}

.grade-scale-list dt {
    font-weight: 600;
    margin: 0;
}

.grade-scale-list dd {
    margin: 0;
    color: var(--color-text-secondary, #64748b);
    font-size: 0.9rem;
}

.catalog-grade-picker__table th,
.catalog-grade-picker__table td {
    white-space: nowrap;
}

.catalog-existing-grades__heading {
    color: var(--color-text-secondary, #64748b);
    font-size: 0.7rem;
    font-weight: 600;
    letter-spacing: 0.02em;
    line-height: 1.2;
    margin-bottom: 0.25rem;
    text-transform: uppercase;
}

.catalog-existing-grades__list {
    display: flex;
    flex-wrap: wrap;
    gap: 0.25rem 0.35rem;
    line-height: 1.2;
}

.catalog-existing-grades__chip {
    align-items: baseline;
    background: var(--color-surface-muted, #f8fafc);
    border: 1px solid var(--color-border-subtle, #e2e8f0);
    border-radius: 0.25rem;
    display: inline-flex;
    font-size: 0.75rem;
    gap: 0.2rem;
    padding: 0.1rem 0.35rem;
    white-space: nowrap;
}

.catalog-existing-grades__chip--pending {
    border-color: var(--bs-primary, #0d6efd);
    box-shadow: inset 0 0 0 1px var(--bs-primary, #0d6efd);
}

.catalog-existing-grades__grade {
    font-weight: 600;
}

.catalog-existing-grades__meta {
    color: var(--color-text-secondary, #64748b);
    font-variant-numeric: tabular-nums;
}

.guidance-checklist.card,
.guidance-coach.card,
.guidance-callout {
    background-color: var(--color-guidance-bg);
    border-color: var(--color-guidance-border);
    color: var(--color-guidance-text);
}

.guidance-checklist a,
.guidance-coach a {
    color: var(--color-guidance-text);
    text-decoration: underline;
}

.guidance-checklist__header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 0.5rem;
}

.guidance-checklist__actions {
    display: flex;
    flex-shrink: 0;
    gap: 0.15rem;
}

.guidance-checklist__actions .btn {
    padding-top: 0;
    padding-bottom: 0;
    color: var(--color-guidance-text);
    font-weight: 650;
}

.guidance-checklist__actions .btn:hover,
.guidance-checklist__actions .btn:focus-visible {
    color: var(--color-guidance-text);
    text-decoration: underline;
}

.guidance-checklist--collapsed .card-body {
    padding-top: 0.55rem;
    padding-bottom: 0.55rem;
}

.guidance-checklist--collapsed .guidance-checklist__header {
    align-items: center;
}

.guidance-checklist--collapsed .h6 {
    margin-bottom: 0 !important;
}

.guidance-checklist__here {
    margin-left: 0.4rem;
    font-size: 0.75rem;
    font-weight: 650;
}

.guidance-checklist__list {
    list-style: none;
    margin: 0.75rem 0 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 0.65rem;
}

.guidance-checklist__item {
    display: flex;
    gap: 0.65rem;
    align-items: flex-start;
}

.guidance-checklist__mark {
    width: 1.1rem;
    color: var(--color-guidance-text);
    font-weight: 700;
}

.guidance-checklist__steps {
    margin: 0.25rem 0 0;
    padding-left: 1.15rem;
}

.guidance-checklist__ellipsis {
    display: inline-flex;
    align-items: center;
    min-height: 1.75rem;
    margin: 0.1rem 0 0;
    padding: 0 0.35rem 0 0;
    border: 0;
    background: transparent;
    color: inherit;
    font: inherit;
    letter-spacing: 0.14em;
    cursor: pointer;
}

.guidance-checklist__ellipsis:hover,
.guidance-checklist__ellipsis:focus-visible {
    color: var(--color-guidance-text);
}

.guidance-checklist__item--done {
    color: color-mix(in srgb, var(--color-guidance-text) 68%, transparent);
}

.guidance-callout {
    position: fixed;
    z-index: 1080;
    max-width: 22rem;
    max-height: min(70vh, 28rem);
    overflow: auto;
    padding: 0.9rem 1rem;
    border: 1px solid var(--color-guidance-border);
    border-radius: 0.75rem;
    background-color: var(--color-guidance-bg);
    color: var(--color-guidance-text);
    box-shadow: 0 0.75rem 1.5rem rgba(15, 23, 42, 0.18);
}

.guidance-callout__step {
    margin-bottom: 0.25rem;
    color: color-mix(in srgb, var(--color-guidance-text) 72%, transparent);
    font-size: 0.75rem;
}

.guidance-results-anchor {
    height: 1px;
}

.guidance-coach {
    border: 1px solid var(--color-guidance-border);
}

.square-import-review {
    display: grid;
    grid-template-columns: 11rem minmax(0, 1fr);
    gap: 1rem;
    align-items: start;
}

.square-import-filters {
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
}

.square-import-detail {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
}

@media (max-width: 767.98px) {
    .square-import-review,
    .square-import-detail {
        grid-template-columns: 1fr;
    }

    .square-import-filters {
        flex-direction: row;
        flex-wrap: wrap;
    }
}

