:root {
    --pf-bg: #f4f7fb;
    --pf-surface: #ffffff;
    --pf-primary: #2563eb;
    --pf-primary-dark: #1e3a8a;
    --pf-primary-soft: #e8f0ff;
    --pf-accent: #14b8a6;
    --pf-text: #0f172a;
    --pf-muted: #64748b;
    --pf-border: #dbe4f0;
    --pf-shadow: 0 12px 30px rgba(15, 23, 42, 0.08);
}

.customer-portal-body {
    min-height: 100vh;
    background:
        radial-gradient(circle at top left, rgba(37, 99, 235, 0.10), transparent 30rem),
        radial-gradient(circle at top right, rgba(20, 184, 166, 0.10), transparent 28rem),
        var(--pf-bg);
    color: var(--pf-text);
}

.customer-navbar {
    background: linear-gradient(90deg, #0f172a 0%, #1e3a8a 55%, #2563eb 100%);
    box-shadow: 0 10px 28px rgba(15, 23, 42, 0.18);
}

.customer-brand {
    display: inline-flex;
    align-items: center;
    gap: 0.65rem;
    color: #fff !important;
    font-weight: 700;
    letter-spacing: 0.01em;
}

.brand-mark {
    width: 34px;
    height: 34px;
    border-radius: 12px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, 0.18);
    border: 1px solid rgba(255, 255, 255, 0.25);
    color: #fff;
    font-size: 0.78rem;
    font-weight: 800;
}

.customer-navbar-toggler {
    border-color: rgba(255, 255, 255, 0.35);
}

.customer-navbar .navbar-toggler-icon {
    filter: invert(1) grayscale(100%);
}

.customer-nav-links .nav-link {
    color: rgba(255, 255, 255, 0.74) !important;
    border-radius: 999px;
    padding: 0.5rem 0.9rem !important;
    margin: 0 0.08rem;
    transition: all 0.16s ease-in-out;
}

.customer-nav-links .nav-link:hover,
.customer-nav-links .nav-link.active {
    color: #fff !important;
    background: rgba(255, 255, 255, 0.16);
}

.customer-account-box {
    display: flex;
    align-items: center;
    gap: 0.65rem;
}

.customer-account-name {
    max-width: 260px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    color: rgba(255, 255, 255, 0.88);
    font-size: 0.9rem;
}

.customer-signout-btn {
    border-radius: 999px;
    font-weight: 600;
    padding-left: 0.9rem;
    padding-right: 0.9rem;
    box-shadow: 0 6px 16px rgba(15, 23, 42, 0.12);
}

.customer-page-shell h1,
.customer-page-shell h2,
.customer-page-shell h3,
.customer-page-shell h4 {
    color: var(--pf-text);
}

.customer-page-shell .text-muted {
    color: var(--pf-muted) !important;
}

.customer-page-shell .card {
    border: 1px solid rgba(219, 228, 240, 0.92);
    border-radius: 18px;
    box-shadow: var(--pf-shadow) !important;
    overflow: hidden;
}

.customer-page-shell .card-header {
    background: linear-gradient(180deg, #ffffff 0%, #f8fbff 100%);
    border-bottom: 1px solid var(--pf-border);
}

.customer-page-shell .btn {
    border-radius: 10px;
    font-weight: 600;
}

.customer-page-shell .btn-primary {
    background: linear-gradient(135deg, var(--pf-primary), #1d4ed8);
    border-color: #1d4ed8;
    box-shadow: 0 8px 18px rgba(37, 99, 235, 0.20);
}

.customer-page-shell .btn-outline-primary {
    border-color: var(--pf-primary);
    color: var(--pf-primary);
}

.customer-page-shell .btn-outline-primary:hover {
    background: var(--pf-primary);
    color: #fff;
}

.customer-page-shell .badge {
    border-radius: 999px;
    padding: 0.45em 0.65em;
}

.customer-page-shell .table {
    --bs-table-hover-bg: #f6f9ff;
}

.customer-page-shell .table thead.table-light th,
.customer-page-shell .table .table-light th {
    background: #eef4ff !important;
    color: #334155;
    border-color: #dbeafe;
}

.customer-page-shell .alert {
    border-radius: 14px;
    border-width: 1px;
}

.customer-page-shell .progress {
    border-radius: 999px;
    background-color: #dbeafe;
}

.customer-page-shell .progress-bar {
    background: linear-gradient(90deg, #2563eb, #14b8a6);
}

.customer-page-shell .dashboard-snapshot-card .border.rounded,
.customer-page-shell .snapshot-render-target .border.rounded {
    border-color: var(--pf-border) !important;
    border-radius: 14px !important;
}

.customer-page-shell .dashboard-snapshot-card .bg-light,
.customer-page-shell .snapshot-render-target .bg-light {
    background: linear-gradient(180deg, #ffffff 0%, #f8fbff 100%) !important;
}

.customer-page-shell .col-xl-4 .card,
.customer-page-shell .col-md-4 .card,
.customer-page-shell .col-md-6 .card {
    transition: transform 0.14s ease-in-out, box-shadow 0.14s ease-in-out;
}

.customer-page-shell .col-xl-4 .card:hover,
.customer-page-shell .col-md-4 .card:hover,
.customer-page-shell .col-md-6 .card:hover {
    transform: translateY(-2px);
    box-shadow: 0 16px 36px rgba(15, 23, 42, 0.12) !important;
}

@media (max-width: 991.98px) {
    .customer-account-box {
        justify-content: space-between;
        padding-top: 0.75rem;
        border-top: 1px solid rgba(255, 255, 255, 0.18);
    }

    .customer-account-name {
        max-width: 65vw;
    }
}

/* Phase 1H - Customer account UX */
.customer-account-dropdown .dropdown-menu {
    border: 1px solid rgba(219, 228, 240, 0.95);
    border-radius: 14px;
    box-shadow: 0 18px 40px rgba(15, 23, 42, 0.18);
    padding: 0.55rem;
}

.customer-account-toggle {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    border-radius: 999px;
    font-weight: 700;
    box-shadow: 0 6px 16px rgba(15, 23, 42, 0.12);
}

.customer-account-avatar {
    width: 26px;
    height: 26px;
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #2563eb, #14b8a6);
    color: #fff;
    font-size: 0.78rem;
    font-weight: 800;
}

.customer-account-menu .dropdown-item {
    border-radius: 10px;
    font-weight: 600;
    padding: 0.55rem 0.75rem;
}

.customer-login-body {
    min-height: 100vh;
    background:
        radial-gradient(circle at 10% 10%, rgba(20, 184, 166, 0.28), transparent 28rem),
        radial-gradient(circle at 90% 0%, rgba(37, 99, 235, 0.34), transparent 26rem),
        linear-gradient(135deg, #0f172a 0%, #172554 48%, #1e40af 100%);
    color: #0f172a;
}

.customer-login-shell {
    min-height: 100vh;
    display: grid;
    grid-template-columns: 1.05fr 0.95fr;
}

.customer-login-hero {
    min-height: 100vh;
    align-items: center;
    padding: 5vw;
    color: #fff;
}

.customer-login-hero h1 {
    max-width: 660px;
    font-size: clamp(2.4rem, 4vw, 4.6rem);
    line-height: 1.02;
    font-weight: 800;
    letter-spacing: -0.04em;
}

.customer-login-hero .lead {
    max-width: 610px;
    color: rgba(255, 255, 255, 0.78);
}

.customer-login-logo {
    display: inline-flex;
    align-items: center;
    gap: 0.75rem;
    font-weight: 800;
    font-size: 1.15rem;
    letter-spacing: 0.01em;
}

.login-brand-mark {
    width: 42px;
    height: 42px;
    border-radius: 16px;
}

.customer-login-points {
    display: grid;
    gap: 0.8rem;
    max-width: 560px;
}

.customer-login-points div {
    position: relative;
    padding: 0.9rem 1rem 0.9rem 2.8rem;
    border: 1px solid rgba(255, 255, 255, 0.16);
    border-radius: 16px;
    background: rgba(255, 255, 255, 0.08);
    backdrop-filter: blur(8px);
    color: rgba(255, 255, 255, 0.9);
}

.customer-login-points div::before {
    content: "✓";
    position: absolute;
    left: 1rem;
    top: 0.82rem;
    width: 24px;
    height: 24px;
    border-radius: 999px;
    background: rgba(20, 184, 166, 0.25);
    color: #a7f3d0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-weight: 800;
}

.customer-login-panel {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem;
}

.customer-login-card {
    width: min(100%, 480px);
    padding: 2.1rem;
    border-radius: 28px;
    background: rgba(255, 255, 255, 0.96);
    box-shadow: 0 30px 80px rgba(15, 23, 42, 0.28);
    border: 1px solid rgba(255, 255, 255, 0.75);
}

.customer-login-kicker {
    display: inline-flex;
    align-items: center;
    padding: 0.35rem 0.7rem;
    border-radius: 999px;
    background: #e8f0ff;
    color: #1d4ed8;
    font-weight: 800;
    font-size: 0.78rem;
    text-transform: uppercase;
    letter-spacing: 0.08em;
}

.customer-login-card h2 {
    font-size: 2rem;
    font-weight: 800;
    letter-spacing: -0.03em;
}

.customer-login-card .form-control {
    border-radius: 14px;
    border-color: #dbe4f0;
    background: #f8fbff;
}

.customer-login-card .form-control:focus {
    border-color: #2563eb;
    box-shadow: 0 0 0 0.22rem rgba(37, 99, 235, 0.13);
}

.customer-login-submit {
    border-radius: 14px;
    padding: 0.82rem 1rem;
    font-weight: 800;
}

.customer-login-footer,
.customer-login-admin-link {
    display: flex;
    justify-content: center;
    gap: 0.4rem;
    color: var(--pf-muted);
}

.customer-login-footer a,
.customer-login-admin-link a {
    font-weight: 700;
    text-decoration: none;
}

.customer-status-icon {
    width: 76px;
    height: 76px;
    border-radius: 26px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #e8f0ff, #ccfbf1);
    font-size: 2.2rem;
}

@media (max-width: 991.98px) {
    .customer-login-shell {
        display: block;
    }

    .customer-login-panel {
        padding: 1.2rem;
    }

    .customer-login-card {
        padding: 1.5rem;
        border-radius: 22px;
    }
}

/* Phase 1I - Account dropdown visibility + report result polish */
.customer-navbar .customer-account-toggle {
    background: rgba(255, 255, 255, 0.96) !important;
    color: #0f172a !important;
    border: 1px solid rgba(255, 255, 255, 0.72) !important;
}

.customer-navbar .customer-account-toggle:hover,
.customer-navbar .customer-account-toggle:focus {
    background: #ffffff !important;
    color: #0f172a !important;
}

.customer-navbar .customer-account-toggle .customer-account-name {
    color: #0f172a !important;
    opacity: 1 !important;
}

.customer-navbar .customer-account-toggle::after {
    color: #0f172a !important;
}

.report-result-actions .btn {
    min-width: 118px;
}

@media print {
    .customer-navbar,
    .report-result-actions,
    details,
    .btn,
    .no-print {
        display: none !important;
    }

    body.customer-portal-body {
        background: #ffffff !important;
    }

    .customer-page-shell {
        padding: 0 !important;
    }

    .customer-page-shell .card {
        box-shadow: none !important;
        border: 1px solid #d1d5db !important;
        break-inside: avoid;
    }

    .customer-page-shell .table {
        font-size: 11px;
    }

    .customer-page-shell h2 {
        font-size: 20px;
    }
}


/* Phase 1J - Smart filter foundation */
#optionalFilterBox {
    border-radius: 18px;
    border: 1px solid rgba(219, 228, 240, 0.95);
    background: linear-gradient(180deg, #f8fbff 0%, #ffffff 100%) !important;
}

#optionalFilterBox .form-control,
#optionalFilterBox .form-select {
    border-radius: 12px;
}


.customer-login-shell-simple {
    grid-template-columns: minmax(320px, 520px);
    justify-content: center;
}

.customer-login-shell-simple .customer-login-panel {
    max-width: 520px;
}


/* Phase 1P - navigation/mobile polish */
.customer-report-nav-dropdown .dropdown-menu {
    min-width: 20rem;
    max-height: min(70vh, 34rem);
    overflow-y: auto;
    border: 0;
    border-radius: 1rem;
    box-shadow: 0 18px 45px rgba(15, 23, 42, 0.18);
    padding: 0.65rem;
}

.customer-report-nav-dropdown .dropdown-item {
    border-radius: 0.7rem;
    padding: 0.55rem 0.75rem;
    color: var(--pf-text);
    white-space: normal;
}

.customer-report-nav-dropdown .dropdown-item:hover,
.customer-report-nav-dropdown .dropdown-item:focus {
    background: var(--pf-primary-soft);
    color: var(--pf-primary-dark);
}

.customer-navbar-toggler {
    min-width: 42px;
    min-height: 38px;
    background: rgba(255, 255, 255, 0.14);
}

.customer-navbar .navbar-toggler-icon {
    width: 1.4rem;
    height: 1.4rem;
    filter: none !important;
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 30 30'%3e%3cpath stroke='rgba%28255,255,255,0.95%29' stroke-linecap='round' stroke-miterlimit='10' stroke-width='2.4' d='M4 7h22M4 15h22M4 23h22'/%3e%3c/svg%3e") !important;
}

.customer-navbar-toggler:focus {
    box-shadow: 0 0 0 0.18rem rgba(255, 255, 255, 0.28);
}

@media (max-width: 991.98px) {
    .customer-navbar {
        position: sticky;
        top: 0;
        z-index: 1030;
    }

    .customer-navbar .container-fluid {
        padding-left: 0.85rem !important;
        padding-right: 0.85rem !important;
    }

    .customer-brand {
        max-width: calc(100vw - 5rem);
        overflow: hidden;
    }

    .customer-brand span:last-child {
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap;
    }

    .customer-nav-links {
        padding-top: 0.85rem;
    }

    .customer-nav-links .nav-link {
        margin: 0.15rem 0;
        padding: 0.7rem 0.9rem !important;
        background: rgba(255, 255, 255, 0.06);
    }

    .customer-report-nav-dropdown .dropdown-menu {
        width: 100%;
        min-width: 0;
        max-height: 60vh;
        margin-top: 0.35rem;
    }

    .customer-account-box {
        border-top: 1px solid rgba(255, 255, 255, 0.16);
        margin-top: 0.75rem !important;
        padding-top: 0.75rem;
        width: 100%;
        justify-content: stretch;
    }

    .customer-account-dropdown,
    .customer-account-toggle {
        width: 100%;
    }

    .customer-account-toggle {
        justify-content: space-between;
        padding: 0.65rem 0.8rem;
    }
}

@media (max-width: 767.98px) {
    .customer-page-shell {
        padding-left: 0.85rem !important;
        padding-right: 0.85rem !important;
    }

    .customer-portal-body .table {
        font-size: 0.98rem;
    }

    .customer-portal-body .table.table-sm {
        font-size: 0.96rem;
    }

    .customer-portal-body .table th,
    .customer-portal-body .table td {
        padding: 0.65rem 0.7rem;
        vertical-align: middle;
    }

    .snapshot-render-target .small,
    .snapshot-render-target small,
    .snapshot-render-target .text-muted {
        font-size: 0.9rem !important;
    }

    .snapshot-render-target .fs-5 {
        font-size: 1.15rem !important;
    }

    .report-result-table,
    .table-responsive {
        -webkit-overflow-scrolling: touch;
    }
}


/* Phase 1Q - PixelsFirst logo branding polish */
:root {
    --pf-brand-red: #f51e2f;
    --pf-brand-red-dark: #9f1239;
}

.customer-brand-with-logo {
    gap: 0.7rem;
    min-width: 0;
}

.customer-brand-logo-wrap {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    height: 42px;
    max-width: 260px;
    padding: 0.3rem 0.75rem;
    border-radius: 16px;
    background: rgba(255, 255, 255, 0.97);
    box-shadow: 0 10px 24px rgba(15, 23, 42, 0.16);
    border: 1px solid rgba(255, 255, 255, 0.72);
}

.customer-brand-logo {
    display: block;
    width: 185px;
    max-width: 38vw;
    height: auto;
}

.customer-brand-portal-label {
    color: #fff;
    font-weight: 800;
    letter-spacing: 0.01em;
}

.customer-navbar {
    background:
        radial-gradient(circle at 0% 0%, rgba(245, 30, 47, 0.24), transparent 18rem),
        linear-gradient(90deg, #0f172a 0%, #1e3a8a 55%, #2563eb 100%);
}

.customer-nav-links .nav-link.active::after {
    content: "";
    display: block;
    height: 3px;
    width: 24px;
    margin: 0.18rem auto -0.18rem;
    border-radius: 999px;
    background: var(--pf-brand-red);
}

.customer-login-logo-card {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.55rem 0.9rem;
    border-radius: 18px;
    background: rgba(255, 255, 255, 0.97);
    box-shadow: 0 18px 45px rgba(15, 23, 42, 0.20);
    border: 1px solid rgba(255, 255, 255, 0.75);
}

.customer-login-logo-card img {
    display: block;
    width: min(270px, 68vw);
    height: auto;
}

.customer-login-body {
    background:
        radial-gradient(circle at 8% 12%, rgba(245, 30, 47, 0.22), transparent 27rem),
        radial-gradient(circle at 10% 10%, rgba(20, 184, 166, 0.20), transparent 28rem),
        radial-gradient(circle at 90% 0%, rgba(37, 99, 235, 0.30), transparent 26rem),
        linear-gradient(135deg, #0f172a 0%, #172554 48%, #1e40af 100%);
}

.customer-login-kicker {
    background: rgba(245, 30, 47, 0.10);
    color: #b91c1c;
}

.customer-login-card .form-control:focus {
    border-color: var(--pf-brand-red);
    box-shadow: 0 0 0 0.22rem rgba(245, 30, 47, 0.12);
}

@media (max-width: 991.98px) {
    .customer-brand-logo-wrap {
        height: 38px;
        padding: 0.25rem 0.55rem;
        border-radius: 14px;
        max-width: 190px;
    }

    .customer-brand-logo {
        width: 145px;
        max-width: 42vw;
    }

    .customer-brand-portal-label {
        font-size: 0.92rem;
    }
}

@media (max-width: 575.98px) {
    .customer-brand-with-logo {
        gap: 0.45rem;
    }

    .customer-brand-logo-wrap {
        max-width: 150px;
        padding: 0.22rem 0.45rem;
    }

    .customer-brand-logo {
        width: 118px;
        max-width: 40vw;
    }

    .customer-brand-portal-label {
        display: none;
    }

    .customer-login-logo-card img {
        width: min(235px, 74vw);
    }
}


/* Bridge 2B - dashboard/report polish */
.dashboard-metric-group-title {
    font-size: .78rem;
    font-weight: 800;
    letter-spacing: .08em;
    text-transform: uppercase;
    color: #475569;
    margin: .3rem 0 .55rem;
}
.dashboard-metric-card {
    border: 1px solid rgba(15, 23, 42, .08);
    border-radius: 1rem;
    padding: .85rem .9rem;
    background: #ffffff;
    box-shadow: 0 8px 24px rgba(15, 23, 42, .06);
    border-top: 4px solid #64748b;
}
.dashboard-metric-card .metric-label {
    color: #64748b;
    font-size: .78rem;
    font-weight: 700;
    line-height: 1.2;
}
.dashboard-metric-card .metric-value {
    color: #0f172a;
    font-size: 1.22rem;
    font-weight: 800;
    margin-top: .25rem;
}
.dashboard-metric-card.metric-today { border-top-color: #2563eb; background: linear-gradient(180deg, #eff6ff 0%, #ffffff 72%); }
.dashboard-metric-card.metric-month { border-top-color: #7c3aed; background: linear-gradient(180deg, #f5f3ff 0%, #ffffff 72%); }
.dashboard-metric-card.metric-payment { border-top-color: #0891b2; background: linear-gradient(180deg, #ecfeff 0%, #ffffff 72%); }
.dashboard-metric-card.metric-stock { border-top-color: #16a34a; background: linear-gradient(180deg, #f0fdf4 0%, #ffffff 72%); }
.dashboard-metric-card.metric-customer { border-top-color: #f59e0b; background: linear-gradient(180deg, #fffbeb 0%, #ffffff 72%); }
.dashboard-metric-card.metric-returns { border-top-color: #dc2626; background: linear-gradient(180deg, #fef2f2 0%, #ffffff 72%); }
.snapshot-section-card {
    border: 1px solid rgba(15, 23, 42, .09);
    border-radius: .95rem;
    overflow: hidden;
    background: #fff;
}
.snapshot-section-title {
    padding: .65rem .8rem;
    font-weight: 800;
    background: #f8fafc;
    border-bottom: 1px solid rgba(15, 23, 42, .08);
}
.snapshot-section-card.highlight-today-sales { border-color: rgba(37, 99, 235, .30); box-shadow: 0 8px 24px rgba(37, 99, 235, .08); }
.snapshot-section-card.highlight-payment { border-color: rgba(8, 145, 178, .35); box-shadow: 0 8px 24px rgba(8, 145, 178, .08); }
.snapshot-section-card.highlight-month-panel { border-color: rgba(124, 58, 237, .30); box-shadow: 0 8px 24px rgba(124, 58, 237, .08); }
.snapshot-section-card.highlight-inventory-credit { border-color: rgba(22, 163, 74, .32); box-shadow: 0 8px 24px rgba(22, 163, 74, .08); }
.snapshot-section-card.highlight-lowstock { border-color: rgba(220, 38, 38, .35); box-shadow: 0 8px 24px rgba(220, 38, 38, .08); }
.snapshot-section-card.highlight-expiry { border-color: rgba(245, 158, 11, .4); box-shadow: 0 8px 24px rgba(245, 158, 11, .08); }
.snapshot-section-card.highlight-transactions { border-color: rgba(37, 99, 235, .25); box-shadow: 0 8px 24px rgba(37, 99, 235, .07); }
.snapshot-section-card.highlight-today-sales .card-header,
.snapshot-section-card.highlight-today-sales .snapshot-section-title { background: linear-gradient(135deg, #1d4ed8, #38bdf8); color: #fff; }
.snapshot-section-card.highlight-payment .card-header,
.snapshot-section-card.highlight-payment .snapshot-section-title { background: linear-gradient(135deg, #0891b2, #06b6d4); color: #fff; }
.snapshot-section-card.highlight-month-panel .card-header,
.snapshot-section-card.highlight-month-panel .snapshot-section-title { background: linear-gradient(135deg, #7c3aed, #a855f7); color: #fff; }
.snapshot-section-card.highlight-inventory-credit .card-header,
.snapshot-section-card.highlight-inventory-credit .snapshot-section-title { background: linear-gradient(135deg, #16a34a, #22c55e); color: #fff; }
.snapshot-section-card.highlight-lowstock .card-header,
.snapshot-section-card.highlight-lowstock .snapshot-section-title { background: linear-gradient(135deg, #dc2626, #f97316); color: #fff; }
.snapshot-section-card.highlight-expiry .card-header,
.snapshot-section-card.highlight-expiry .snapshot-section-title { background: linear-gradient(135deg, #f59e0b, #f97316); color: #fff; }
.snapshot-section-card.highlight-transactions .card-header,
.snapshot-section-card.highlight-transactions .snapshot-section-title { background: linear-gradient(135deg, #2563eb, #4f46e5); color: #fff; }
.snapshot-section-card thead th {
    background: #e2e8f0;
    color: #0f172a;
    font-weight: 800;
    white-space: nowrap;
}
.snapshot-section-card.highlight-today-sales thead th { background: #dbeafe; color: #1e3a8a; }
.snapshot-section-card.highlight-payment thead th { background: #cffafe; color: #164e63; }
.snapshot-section-card.highlight-month-panel thead th { background: #ede9fe; color: #4c1d95; }
.snapshot-section-card.highlight-inventory-credit thead th { background: #dcfce7; color: #14532d; }
.snapshot-section-card.highlight-lowstock thead th { background: #fee2e2; color: #7f1d1d; }
.snapshot-section-card.highlight-expiry thead th { background: #fef3c7; color: #78350f; }
.snapshot-section-card.highlight-transactions thead th { background: #dbeafe; color: #1e3a8a; }
.transaction-drill-row { cursor: pointer; }
.transaction-drill-row:hover td { background: rgba(37, 99, 235, .06); }
.transaction-detail-summary {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: .65rem;
}
.transaction-detail-summary > div {
    border: 1px solid rgba(15, 23, 42, .08);
    border-radius: .75rem;
    padding: .65rem;
    background: #f8fafc;
}
.transaction-detail-summary span {
    display: block;
    color: #64748b;
    font-size: .76rem;
    font-weight: 700;
}
.transaction-detail-summary strong {
    display: block;
    color: #0f172a;
    font-size: .95rem;
    margin-top: .1rem;
}
@media (max-width: 767.98px) {
    .customer-page-shell .table {
        font-size: 1rem;
    }
    .customer-page-shell .table th,
    .customer-page-shell .table td {
        padding: .72rem .65rem;
    }
    .dashboard-metric-card .metric-value {
        font-size: 1.35rem;
    }
}


/* Bridge 2C - simple report center, receipt-style transaction popup, and dashboard expansion */
.report-center-simple .report-category-section {
    background: rgba(255,255,255,.72);
    border: 1px solid rgba(16,185,129,.13);
    border-radius: 20px;
    padding: 1rem;
}
.report-center-grid { align-items: stretch; }
.report-tile-col {
    flex: 0 0 20%;
    max-width: 20%;
}
.report-tile-card {
    display: flex;
    flex-direction: column;
    min-height: 205px;
    height: 100%;
    color: #102a43;
    text-decoration: none;
    padding: 0;
    border-radius: 18px;
    background: #ffffff;
    border: 1px solid rgba(16,185,129,.18);
    box-shadow: 0 12px 30px rgba(15, 23, 42, .08);
    overflow: hidden;
    transition: transform .18s ease, box-shadow .18s ease, border-color .18s ease;
}
.report-tile-card:hover {
    color: #063f2a;
    transform: translateY(-3px);
    border-color: rgba(16,185,129,.45);
    box-shadow: 0 18px 40px rgba(16, 185, 129, .16);
}
.report-tile-card.disabled { opacity: .7; pointer-events: none; }
.report-tile-header {
    min-height: 58px;
    display: flex;
    align-items: center;
    padding: .9rem 1.05rem;
    background: linear-gradient(135deg, #ecfdf5 0%, #d1fae5 100%);
    border-bottom: 1px solid rgba(16,185,129,.16);
}
.report-tile-header h5 {
    font-weight: 900;
    margin: 0;
    font-size: 1.02rem;
    color: #064e3b;
}
.report-tile-body {
    flex: 1 1 auto;
    padding: 1rem 1.05rem;
}
.report-tile-body p { color: #637381; font-size: .9rem; margin: 0; line-height: 1.42; }
.report-tile-footer {
    padding: .85rem 1.05rem 1rem;
    border-top: 1px solid rgba(16,185,129,.10);
    background: linear-gradient(180deg, #ffffff 0%, #f2fff8 100%);
}
.report-tile-action {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 88px;
    padding: .45rem .95rem;
    border-radius: 999px;
    font-weight: 800;
    background: linear-gradient(135deg, #10b981, #047857);
    color: #ffffff;
    box-shadow: 0 8px 18px rgba(16,185,129,.22);
}
@media (max-width: 1399px) { .report-tile-col { flex-basis: 25%; max-width: 25%; } }
@media (max-width: 991px) { .report-tile-col { flex-basis: 50%; max-width: 50%; } }
@media (max-width: 575px) { .report-tile-col { flex-basis: 100%; max-width: 100%; } .report-tile-card { min-height: 150px; } }

.receipt-modal-body {
    background: #f4f6f8;
}
.receipt-paper-shell {
    max-width: 960px;
    margin: 0 auto;
    padding: .25rem;
}
.receipt-paper {
    background: #fff;
    border-radius: 24px;
    border: 1px solid #e7e9ee;
    box-shadow: 0 22px 60px rgba(15, 23, 42, .12);
    overflow: hidden;
    color: #202124;
}
.receipt-top {
    display: flex;
    justify-content: space-between;
    gap: 1.25rem;
    padding: 2rem;
}
.receipt-brand { display: flex; align-items: center; gap: 1rem; min-width: 0; }
.receipt-brand-mark {
    width: 70px; height: 70px; border-radius: 18px;
    display: inline-flex; align-items: center; justify-content: center;
    color: #fff; font-weight: 900; letter-spacing: -.05em;
    background: linear-gradient(135deg, #2563eb, #1d4ed8);
    box-shadow: 0 12px 30px rgba(37,99,235,.24);
}
.receipt-brand h3 { margin: 0; font-weight: 900; font-size: 1.85rem; }
.receipt-brand div div { color: #8a8f99; font-weight: 600; }
.receipt-bill { text-align: right; text-transform: uppercase; letter-spacing: .18em; color: #9aa0a6; }
.receipt-bill strong { display: block; color: #202124; font-size: 1.65rem; letter-spacing: 0; margin-top: .35rem; }
.receipt-meta-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 1.25rem;
    padding: 0 2rem 1.8rem;
}
.receipt-meta-grid span,
.receipt-payments h6 {
    display: block;
    color: #9aa0a6;
    text-transform: uppercase;
    letter-spacing: .16em;
    font-size: .85rem;
    margin-bottom: .25rem;
}
.receipt-meta-grid strong { font-size: 1.05rem; }
.receipt-table { width: 100%; border-collapse: collapse; }
.receipt-table thead th {
    background: #f7f7f8;
    color: #8a8f99;
    font-weight: 800;
    border-top: 1px solid #eef0f2;
    border-bottom: 1px solid #eef0f2;
    padding: 1rem 1rem;
    white-space: nowrap;
}
.receipt-table tbody td {
    border-bottom: 1px solid #f0f1f3;
    padding: .95rem 1rem;
    vertical-align: top;
}
.receipt-table small { display: block; color: #64748b; margin-top: .25rem; font-size: .78rem; }
.receipt-money { font-weight: 900; text-align: right; }
.receipt-item-summary {
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-end;
    gap: .75rem;
    padding: 1rem 2rem 0;
}
.receipt-item-summary > div {
    min-width: 170px;
    border: 1px solid #eef0f2;
    border-radius: 14px;
    background: #fbfbfc;
    padding: .75rem .9rem;
    text-align: right;
}
.receipt-item-summary span {
    display: block;
    color: #8a8f99;
    text-transform: uppercase;
    letter-spacing: .12em;
    font-size: .72rem;
    font-weight: 800;
}
.receipt-item-summary strong {
    display: block;
    color: #202124;
    font-size: 1.2rem;
    margin-top: .15rem;
}
.receipt-totals {
    width: min(470px, calc(100% - 2rem));
    margin: 1.5rem 2rem 1.75rem auto;
}
.receipt-totals > div,
.receipt-payments > div {
    display: flex;
    justify-content: space-between;
    gap: 1rem;
    padding: .45rem 0;
    color: #6b7280;
}
.receipt-totals strong,
.receipt-payments strong { color: #202124; }
.receipt-grand {
    margin-top: .75rem;
    padding-top: 1rem !important;
    border-top: 1px solid #edf0f2;
    font-size: 1.25rem;
    font-weight: 900;
}
.receipt-grand strong { color: #2563eb; font-size: 1.75rem; }
.receipt-payments {
    border-top: 1px solid #eef0f2;
    padding: 1.5rem 2rem;
}
.receipt-footer-note {
    text-align: center;
    color: #9aa0a6;
    padding: 1.3rem 2rem;
    border-top: 1px solid #eef0f2;
    background: #fbfbfc;
}
.transaction-expand-controls .btn:disabled { opacity: .55; }
@media (max-width: 767px) {
    .receipt-top { padding: 1.25rem; }
    .receipt-brand-mark { width: 54px; height: 54px; border-radius: 14px; }
    .receipt-brand h3 { font-size: 1.35rem; }
    .receipt-meta-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); padding: 0 1.25rem 1.25rem; }
    .receipt-item-summary { justify-content: stretch; padding: .9rem 1.25rem 0; }
    .receipt-item-summary > div { flex: 1 1 140px; text-align: left; }
    .receipt-totals { margin-right: 1.25rem; }
    .receipt-payments { padding: 1.25rem; }
    .receipt-table thead th, .receipt-table tbody td { padding: .75rem .65rem; font-size: .9rem; }
}

/* Bridge 2G - Remote Operations / Quick Item Edit */
.quick-item-edit-page .card-header {
    background: linear-gradient(135deg, #f0fdf4 0%, #ecfdf5 100%);
    border-bottom-color: #bbf7d0;
}

.quick-item-search-results {
    max-height: 420px;
    overflow-y: auto;
}

.quick-item-readonly-chip {
    border: 1px solid #dbeafe;
    background: linear-gradient(180deg, #ffffff 0%, #f8fbff 100%);
    border-radius: 14px;
    padding: 0.85rem 1rem;
    min-height: 76px;
}

.quick-item-readonly-chip span {
    display: block;
    color: #64748b;
    font-size: 0.82rem;
    margin-bottom: 0.2rem;
}

.quick-item-readonly-chip strong {
    color: #0f172a;
    font-size: 1rem;
}

/* Bridge 2H - Quick Item Edit UX polish */
.quick-item-workspace {
    --qie-green: #059669;
    --qie-green-dark: #047857;
    --qie-blue: #2563eb;
    --qie-amber: #f59e0b;
    --qie-panel: #ffffff;
    --qie-border: #dbe7ef;
    --qie-soft: #f7fbff;
}

.quick-item-hero,
.quick-item-panel {
    background: var(--qie-panel);
    border: 1px solid var(--qie-border);
    border-radius: 22px;
    box-shadow: 0 16px 36px rgba(15, 23, 42, 0.07);
}

.quick-item-hero {
    padding: 1.35rem;
    background:
        radial-gradient(circle at top left, rgba(16, 185, 129, 0.12), transparent 32%),
        linear-gradient(135deg, #ffffff 0%, #f8fbff 100%);
}

.quick-item-eyebrow,
.quick-item-panel-kicker {
    font-size: .75rem;
    font-weight: 800;
    letter-spacing: .08em;
    text-transform: uppercase;
    color: var(--qie-green-dark);
}

.quick-item-refresh-btn {
    min-width: 132px;
    font-weight: 700;
}

.quick-item-bridge-strip {
    display: flex;
    flex-wrap: wrap;
    gap: .6rem;
}

.quick-item-step {
    display: inline-flex;
    align-items: center;
    gap: .45rem;
    padding: .5rem .75rem;
    border-radius: 999px;
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    color: #64748b;
    font-size: .84rem;
    font-weight: 700;
}

.quick-item-step span {
    width: .62rem;
    height: .62rem;
    border-radius: 999px;
    background: #cbd5e1;
    box-shadow: 0 0 0 3px rgba(203, 213, 225, .28);
}

.quick-item-step.is-ready {
    background: #ecfdf5;
    border-color: #bbf7d0;
    color: #047857;
}
.quick-item-step.is-ready span {
    background: #10b981;
    box-shadow: 0 0 0 3px rgba(16, 185, 129, .18);
}
.quick-item-step.is-busy {
    background: #eff6ff;
    border-color: #bfdbfe;
    color: #1d4ed8;
}
.quick-item-step.is-busy span {
    background: #3b82f6;
    box-shadow: 0 0 0 3px rgba(59, 130, 246, .18);
}

.operation-status {
    border-radius: 14px;
    padding: .7rem .9rem;
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    color: #475569;
    font-size: .92rem;
}
.operation-status.is-success {
    background: #ecfdf5;
    border-color: #bbf7d0;
    color: #047857;
}
.operation-status.is-error {
    background: #fef2f2;
    border-color: #fecaca;
    color: #b91c1c;
}
.operation-status.is-busy {
    background: #eff6ff;
    border-color: #bfdbfe;
    color: #1d4ed8;
}

.quick-item-panel {
    overflow: hidden;
}
.quick-item-panel-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    padding: 1.1rem 1.15rem;
    background: linear-gradient(135deg, #f0fdf4 0%, #f8fafc 100%);
    border-bottom: 1px solid #d8f3e3;
}
.quick-item-editor-header {
    background: linear-gradient(135deg, #eef2ff 0%, #f8fafc 100%);
    border-bottom-color: #dbeafe;
}
.quick-item-panel-body {
    padding: 1.1rem;
}
.quick-item-count-badge,
.quick-item-code-pill {
    border-radius: 999px;
    padding: .42rem .75rem;
    background: #ffffff;
    border: 1px solid #dbe7ef;
    color: #0f172a;
    font-weight: 800;
    font-size: .84rem;
}

.quick-item-searchbar {
    display: flex;
    gap: .85rem;
    align-items: end;
}
.quick-item-search-actions {
    display: flex;
    gap: .5rem;
    padding-bottom: 0;
}
.quick-item-live-note {
    border-left: 4px solid var(--qie-green);
    background: #ecfdf5;
    color: #065f46;
    border-radius: 12px;
    padding: .75rem .9rem;
    font-size: .9rem;
}
.quick-item-table-wrap {
    border: 1px solid #e2e8f0;
    border-radius: 16px;
    overflow: auto;
    max-height: 620px;
    background: #fff;
}
.quick-item-table thead th {
    position: sticky;
    top: 0;
    z-index: 1;
    background: #e6fffa;
    color: #064e3b;
    border-bottom: 1px solid #99f6e4;
    font-size: .84rem;
    white-space: nowrap;
}
.quick-item-table tbody td {
    font-size: .92rem;
    vertical-align: middle;
}
.quick-item-result-row {
    cursor: pointer;
}
.quick-item-result-row:hover {
    background: #f0fdf4;
}
.quick-item-result-row.is-selected {
    background: #dcfce7 !important;
    box-shadow: inset 4px 0 0 var(--qie-green);
}
.quick-item-edit-row-btn {
    min-width: 68px;
    font-weight: 800;
}

.quick-item-selected-summary {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: .65rem;
}
.quick-item-selected-summary > div,
.quick-item-readonly-chip {
    border: 1px solid #dbeafe;
    background: linear-gradient(180deg, #ffffff 0%, #f8fbff 100%);
    border-radius: 16px;
    padding: .8rem .85rem;
    min-height: 74px;
}
.quick-item-selected-summary span,
.quick-item-readonly-chip span {
    display: block;
    color: #64748b;
    font-size: .8rem;
    font-weight: 700;
    margin-bottom: .18rem;
}
.quick-item-selected-summary strong,
.quick-item-readonly-chip strong {
    color: #0f172a;
    font-size: .98rem;
}
.quick-item-empty-editor {
    border: 1px dashed #cbd5e1;
    background: #f8fafc;
    border-radius: 18px;
    padding: 2rem 1rem;
    text-align: center;
}
.quick-item-empty-icon {
    width: 54px;
    height: 54px;
    display: grid;
    place-items: center;
    margin: 0 auto .75rem;
    border-radius: 16px;
    background: #ecfdf5;
    color: #047857;
    font-size: 1.45rem;
    font-weight: 900;
}
.quick-item-edit-fields .form-label {
    font-weight: 700;
    color: #334155;
}
.quick-item-edit-fields .form-control,
.quick-item-edit-fields .form-select {
    border-radius: 12px;
    min-height: 44px;
}
.quick-item-save-bar {
    display: flex;
    flex-wrap: wrap;
    gap: .6rem;
    justify-content: flex-end;
    border-top: 1px solid #e2e8f0;
    padding-top: 1rem;
}
.quick-item-preview {
    border-radius: 18px;
    padding: 1rem;
    border: 1px solid #dbe7ef;
    background: #fff;
}
.quick-item-preview.is-valid {
    border-color: #bbf7d0;
    background: #f0fdf4;
}
.quick-item-preview.is-invalid {
    border-color: #fecaca;
    background: #fff7f7;
}
.quick-item-preview-title {
    font-weight: 900;
    margin-bottom: .65rem;
}

@media (max-width: 991px) {
    .quick-item-searchbar {
        flex-direction: column;
        align-items: stretch;
    }
    .quick-item-search-actions {
        justify-content: stretch;
    }
    .quick-item-search-actions .btn {
        flex: 1 1 0;
    }
    .quick-item-selected-summary {
        grid-template-columns: 1fr;
    }
    .quick-item-table-wrap {
        max-height: 520px;
    }
}

@media (max-width: 575px) {
    .quick-item-hero,
    .quick-item-panel-body,
    .quick-item-panel-header {
        padding: 1rem;
    }
    .quick-item-bridge-strip {
        display: grid;
        grid-template-columns: 1fr 1fr;
    }
    .quick-item-step {
        font-size: .78rem;
    }
}

.quick-item-cache-line {
    display: inline-flex;
    align-items: center;
    gap: .35rem;
    color: #0f766e;
    background: rgba(20, 184, 166, .10);
    border: 1px solid rgba(20, 184, 166, .22);
    border-radius: 999px;
    padding: .4rem .8rem;
    font-size: .85rem;
    font-weight: 700;
}

.quick-item-cache-line::before {
    content: "";
    width: .5rem;
    height: .5rem;
    border-radius: 999px;
    background: #10b981;
    box-shadow: 0 0 0 4px rgba(16,185,129,.12);
}


/* Remote Operations History */
.operation-history-shell {
    overflow: hidden;
}

.operation-history-filter {
    padding: 1rem;
    background: #f8fbff;
    border-bottom: 1px solid rgba(15, 23, 42, 0.08);
}

.operation-history-table-wrap {
    border-radius: 0 0 1rem 1rem;
}

.operation-history-table thead th {
    background: #dcfce7;
    color: #064e3b;
    border-bottom: 1px solid #0f766e;
    font-weight: 800;
    white-space: nowrap;
}

.operation-history-table tbody td {
    vertical-align: middle;
}

.operation-history-summary .badge {
    color: #064e3b !important;
}

@media (max-width: 768px) {
    .operation-history-table {
        font-size: 0.95rem;
    }

    .operation-history-filter {
        padding: 0.85rem;
    }
}


/* Remote Operation Detail */
.operation-detail-hero {
    padding: 1.15rem;
}

.operation-detail-title {
    display: flex;
    justify-content: space-between;
    gap: 1rem;
    align-items: flex-start;
    padding-bottom: 1rem;
    border-bottom: 1px solid rgba(15, 23, 42, 0.08);
}

.operation-detail-status {
    font-size: 0.9rem;
    padding: 0.55rem 0.85rem;
}

.operation-detail-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 0.9rem;
    margin-top: 1rem;
}

.operation-detail-label {
    color: #64748b;
    font-size: 0.82rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.operation-detail-value {
    font-weight: 800;
    color: #0f172a;
}

.operation-detail-card {
    overflow: hidden;
}

.operation-timeline {
    padding: 1rem;
}

.operation-timeline-row {
    display: grid;
    grid-template-columns: 18px 1fr;
    gap: 0.75rem;
    padding: 0.65rem 0;
    border-bottom: 1px solid rgba(15, 23, 42, 0.08);
}

.operation-timeline-row:last-child {
    border-bottom: 0;
}

.operation-timeline-dot {
    width: 12px;
    height: 12px;
    border-radius: 999px;
    margin-top: 0.28rem;
    box-shadow: 0 0 0 4px rgba(16, 185, 129, 0.11);
}

.operation-value-list {
    padding: 0.75rem 1rem 1rem;
}

.operation-value-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 0.75rem;
    border-bottom: 1px solid rgba(15, 23, 42, 0.08);
    padding: 0.62rem 0;
}

.operation-value-row span {
    color: #64748b;
    font-weight: 700;
}

.operation-value-row strong {
    color: #0f172a;
    text-align: right;
}

.operation-json {
    background: #0f172a;
    color: #e2e8f0;
    border-radius: 0.75rem;
    padding: 1rem;
    max-height: 420px;
    overflow: auto;
    font-size: 0.86rem;
}

@media (max-width: 992px) {
    .operation-detail-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 576px) {
    .operation-detail-title {
        flex-direction: column;
    }

    .operation-detail-grid {
        grid-template-columns: 1fr;
    }

    .operation-value-row {
        align-items: flex-start;
        flex-direction: column;
    }

    .operation-value-row strong {
        text-align: left;
    }
}


/* Remote Stock Adjustment */
.stock-adjustment-hero {
    border-left: 4px solid #16a34a;
}
.stock-adjustment-line-builder {
    background: #f0fdf4;
    border: 1px solid #bbf7d0;
    border-radius: 1rem;
    padding: 1rem;
}
.stock-adjustment-summary {
    background: #ecfdf5;
    color: #065f46;
    border: 1px solid #a7f3d0;
    border-radius: .85rem;
    padding: .75rem 1rem;
    font-weight: 800;
}
.operation-status.error { background: #fef2f2; color: #991b1b; border-color: #fecaca; }
.operation-status.success { background: #ecfdf5; color: #065f46; border-color: #a7f3d0; }
.operation-status.muted { background: #eff6ff; color: #1e40af; border-color: #bfdbfe; }


/* GRN Request */
.grn-request-hero {
    background: linear-gradient(120deg, rgba(236, 253, 245, 0.95), rgba(255, 255, 255, 0.9));
}

.grn-item-table thead th,
.grn-lines-table thead th {
    background: #d1fae5;
    color: #064e3b;
    border-bottom: 1px solid #059669;
    font-weight: 800;
    white-space: nowrap;
}

.grn-item-table tbody td,
.grn-lines-table tbody td {
    vertical-align: middle;
}

.grn-item-table-wrap {
    border: 1px solid rgba(16, 185, 129, 0.22);
    border-radius: 0.75rem;
    overflow: hidden;
}

.grn-total-chip {
    border-radius: 999px;
    background: #ecfdf5;
    color: #065f46;
    border: 1px solid #a7f3d0;
    padding: 0.4rem 0.8rem;
}

.grn-modal .modal-header {
    background: #ecfdf5;
    border-bottom-color: #a7f3d0;
}

@media (max-width: 768px) {
    .grn-item-table,
    .grn-lines-table {
        font-size: 0.95rem;
    }
}


/* Remote operation waiting overlay */
.remote-operation-wait-overlay {
    position: fixed;
    inset: 0;
    z-index: 1085;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 1rem;
    background: rgba(15, 23, 42, 0.35);
    backdrop-filter: blur(3px);
}

.remote-operation-wait-overlay.is-visible {
    display: flex;
}

.remote-operation-wait-card {
    width: min(460px, 92vw);
    border-radius: 1.25rem;
    border: 1px solid rgba(14, 165, 233, 0.18);
    background: #ffffff;
    box-shadow: 0 22px 70px rgba(15, 23, 42, 0.22);
    padding: 1.35rem;
    text-align: center;
}

.remote-operation-spinner {
    width: 3rem;
    height: 3rem;
    margin: 0 auto 1rem;
    border-radius: 50%;
    border: 0.35rem solid #dbeafe;
    border-top-color: #059669;
    animation: remote-operation-spin 0.8s linear infinite;
}

.remote-operation-wait-title {
    font-weight: 800;
    font-size: 1.1rem;
    margin-bottom: 0.35rem;
    color: #0f172a;
}

.remote-operation-wait-message {
    color: #475569;
    margin: 0;
}

.remote-operation-wait-note {
    margin-top: 0.85rem;
    font-size: 0.86rem;
    color: #64748b;
}

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

/* Remote Operations: advanced item edit fields */
.quick-item-section-title {
    font-size: .78rem;
    font-weight: 800;
    letter-spacing: .08em;
    text-transform: uppercase;
    color: #64748b;
    margin-bottom: .65rem;
}

.quick-item-advanced-box {
    border: 1px solid rgba(148, 163, 184, .45);
    border-radius: 16px;
    padding: .95rem 1rem 1rem;
    background: rgba(248, 250, 252, .78);
}

.quick-item-advanced-box summary {
    cursor: pointer;
    font-weight: 800;
    color: #0f172a;
}

.quick-item-advanced-note {
    margin-top: .55rem;
    padding: .55rem .7rem;
    border-radius: 12px;
    background: rgba(255, 247, 237, .9);
    color: #9a3412;
    font-size: .84rem;
}

.quick-item-check {
    min-height: 42px;
    display: flex;
    align-items: center;
    gap: .35rem;
    padding: .55rem .75rem;
    border: 1px solid rgba(148, 163, 184, .35);
    border-radius: 12px;
    background: #fff;
}

/* Customer operations: simple system state and item browser */
.operation-system-card {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1rem 1.1rem;
    border: 1px solid #bbf7d0;
    border-radius: 18px;
    background: #f0fdf4;
    color: #14532d;
}

.operation-system-card.is-offline {
    border-color: #fed7aa;
    background: #fff7ed;
    color: #9a3412;
}

.operation-system-icon {
    flex: 0 0 42px;
    width: 42px;
    height: 42px;
    display: grid;
    place-items: center;
    border-radius: 14px;
    background: #dcfce7;
    color: #047857;
    font-size: 1.2rem;
    font-weight: 900;
}

.operation-system-card.is-offline .operation-system-icon {
    background: #ffedd5;
    color: #c2410c;
}

.item-browser-shell {
    overflow: hidden;
}

.item-browser-table-wrap {
    max-height: 68vh;
    overflow: auto;
}

.item-browser-table thead th {
    position: sticky;
    top: 0;
    z-index: 1;
    background: #ecfdf5;
    color: #065f46;
    white-space: nowrap;
}

.item-browser-table tbody td {
    vertical-align: middle;
}

.quick-add-more {
    overflow: hidden;
}

.quick-add-more-summary {
    cursor: pointer;
    list-style: none;
    padding: 1rem 1.1rem;
    font-weight: 800;
    color: #0f172a;
    background: #f8fafc;
}

.quick-add-more-summary::-webkit-details-marker {
    display: none;
}

.quick-add-more-summary::after {
    content: '+';
    float: right;
    color: #047857;
    font-size: 1.25rem;
    line-height: 1;
}

.quick-add-more[open] .quick-add-more-summary::after {
    content: '–';
}

@media (max-width: 767px) {
    .operation-system-card {
        align-items: flex-start;
        flex-wrap: wrap;
    }

    .operation-system-card .btn {
        width: 100%;
    }

    .item-browser-table-wrap {
        max-height: none;
    }
}
