   /* ═══════════════════════════════════════════════════════════════ */
    /*  MATERIAL SYMBOLS BASE                                        */
    /* ═══════════════════════════════════════════════════════════════ */
    .material-symbols-outlined {
        font-variation-settings: 'FILL' 0, 'wght' 400, 'GRAD' 0, 'opsz' 24;
        display: inline-block;
        vertical-align: middle;
        line-height: 1;
        font-size: 18px;
    }

    /* ═══════════════════════════════════════════════════════════════ */
    /*  PAGE WRAPPER - fill viewport, no page scroll                  */
    /* ═══════════════════════════════════════════════════════════════ */
    .so-page-wrapper {
        display: flex;
        flex-direction: column;
        min-height: 0;
        height: calc(100vh - 64px);
        overflow: hidden;
        padding-bottom: 0;
    }

    /* ═══════════════════════════════════════════════════════════════ */
    /*  CSS VARIABLES                                                 */
    /* ═══════════════════════════════════════════════════════════════ */
    :root {
        --so-primary: #7c3aed;
        --so-primary-light: #a78bfa;
        --so-primary-dark: #5b21b6;
        --so-primary-50: #f5f3ff;
        --so-primary-100: #ede9fe;
        --so-primary-900: rgba(124, 58, 237, 0.15);
        --so-surface: #ffffff;
        --so-surface-hover: #fafafa;
        --so-surface-selected: #f5f3ff;
        --so-border: #e5e7eb;
        --so-border-light: #f3f4f6;
        --so-text-primary: #111827;
        --so-text-secondary: #6b7280;
        --so-text-muted: #9ca3af;
        --so-radius-sm: 6px;
        --so-radius-md: 10px;
        --so-radius-lg: 14px;
        --so-shadow-sm: 0 1px 2px rgba(0,0,0,0.04), 0 1px 3px rgba(0,0,0,0.06);
        --so-shadow-md: 0 4px 6px -1px rgba(0,0,0,0.06), 0 2px 4px -2px rgba(0,0,0,0.06);
        --so-shadow-lg: 0 10px 15px -3px rgba(0,0,0,0.08), 0 4px 6px -4px rgba(0,0,0,0.06);
        --so-shadow-xl: 0 20px 25px -5px rgba(0,0,0,0.08), 0 8px 10px -6px rgba(0,0,0,0.04);
        --so-transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    }

    .dark {
        --so-primary: #a78bfa;
        --so-primary-light: #c4b5fd;
        --so-primary-dark: #7c3aed;
        --so-primary-50: rgba(124, 58, 237, 0.1);
        --so-primary-100: rgba(124, 58, 237, 0.15);
        --so-primary-900: rgba(124, 58, 237, 0.25);
        --so-surface: #18181b;
        --so-surface-hover: #1f1f23;
        --so-surface-selected: rgba(124, 58, 237, 0.15);
        --so-border: #27272a;
        --so-border-light: #1f1f23;
        --so-text-primary: #f4f4f5;
        --so-text-secondary: #a1a1aa;
        --so-text-muted: #71717a;
        --so-shadow-sm: 0 1px 2px rgba(0,0,0,0.2);
        --so-shadow-md: 0 4px 6px rgba(0,0,0,0.25);
        --so-shadow-lg: 0 10px 15px rgba(0,0,0,0.3);
        --so-shadow-xl: 0 20px 25px rgba(0,0,0,0.35);
    }

    /* ═══════════════════════════════════════════════════════════════ */
    /*  HEADER                                                        */
    /* ═══════════════════════════════════════════════════════════════ */
    .so-header {
        margin-bottom: 20px;
    }

    .so-header-inner {
        display: flex;
        align-items: center;
        justify-content: space-between;
        flex-wrap: wrap;
        gap: 16px;
    }

    .so-header-left {
        display: flex;
        align-items: center;
        gap: 14px;
    }

    .so-header-title {
        font-size: 22px;
        font-weight: 700;
        color: var(--so-text-primary);
        letter-spacing: -0.02em;
        line-height: 1.2;
        margin: 0;
    }

    .so-header-subtitle {
        font-size: 13px;
        color: var(--so-text-muted);
        margin: 2px 0 0 0;
    }

    /* ═══════════════════════════════════════════════════════════════ */
    /*  BUTTONS                                                       */
    /* ═══════════════════════════════════════════════════════════════ */
    .so-btn {
        display: inline-flex;
        align-items: center;
        justify-content: center;
        gap: 6px;
        padding: 0 18px;
        border: none;
        border-radius: var(--so-radius-sm);
        font-size: 13px;
        font-weight: 600;
        cursor: pointer;
        transition: var(--so-transition);
        white-space: nowrap;
        letter-spacing: 0.01em;
        height: 36px;
        line-height: 1;
        box-sizing: border-box;
    }

    .so-btn:active {
        transform: scale(0.97);
    }

    .so-btn-icon {
        font-size: 18px;
    }

    .so-btn-primary {
        background: linear-gradient(135deg, var(--so-primary), var(--so-primary-dark));
        color: white;
        box-shadow: 0 2px 8px rgba(124, 58, 237, 0.3);
    }

    .so-btn-primary:hover {
        box-shadow: 0 4px 16px rgba(124, 58, 237, 0.4);
        transform: translateY(-1px);
    }

    .so-btn-secondary {
        background: var(--so-surface);
        color: var(--so-text-primary);
        border: 1px solid var(--so-border);
        box-shadow: var(--so-shadow-sm);
    }

    .so-btn-secondary:hover {
        background: var(--so-surface-hover);
        border-color: var(--so-primary-light);
        color: var(--so-primary);
        box-shadow: var(--so-shadow-md);
    }

    /* ═══════════════════════════════════════════════════════════════ */
    /*  FILTER PANEL                                                  */
    /* ═══════════════════════════════════════════════════════════════ */
    .so-filter-panel {
        background: var(--so-surface);
        border: 1px solid var(--so-border);
        border-radius: var(--so-radius-lg);
        padding: 16px 20px;
        margin-bottom: 16px;
        box-shadow: var(--so-shadow-sm);
        flex-shrink: 0;
    }

    .so-filter-row {
        display: flex;
        flex-wrap: wrap;
        align-items: flex-end;
        gap: 12px;
    }

    .so-filter-group {
        display: flex;
        flex-direction: column;
        gap: 4px;
    }

    .so-filter-group--grow {
        flex: 0 1 auto;
        min-width: 200px;
    }

    .so-filter-group--action {
        margin-top: auto;
    }

    .so-filter-group--actions {
        margin-top: auto;
    }

    .so-filter-actions-row {
        display: flex;
        gap: 8px;
        align-items: center;
    }

    .so-filter-label {
        display: flex;
        align-items: center;
        gap: 4px;
        font-size: 11px;
        font-weight: 600;
        color: var(--so-text-muted);
        text-transform: uppercase;
        letter-spacing: 0.05em;
    }

    .so-filter-label-icon {
        font-size: 14px;
    }

    /* ═══════════════════════════════════════════════════════════════ */
    /*  INPUTS                                                        */
    /* ═══════════════════════════════════════════════════════════════ */
    .so-input {
        height: 36px;
        padding: 0 12px;
        background: var(--so-surface);
        border: 1px solid var(--so-border);
        border-radius: var(--so-radius-sm);
        font-size: 13px;
        color: var(--so-text-primary);
        outline: none;
        transition: var(--so-transition);
        box-sizing: border-box;
    }

    .so-input:focus {
        border-color: var(--so-primary);
        box-shadow: 0 0 0 3px var(--so-primary-100);
    }

    .so-input::placeholder {
        color: var(--so-text-muted);
    }

    .so-select {
        appearance: none;
        background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3e%3cpath fill='none' stroke='%236b7280' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='m2 5 6 6 6-6'/%3e%3c/svg%3e");
        background-repeat: no-repeat;
        background-position: right 10px center;
        background-size: 14px;
        padding-right: 32px;
        min-width: 140px;
    }

    .so-search-wrapper {
        position: relative;
    }

    .so-search-icon {
        position: absolute;
        left: 10px;
        top: 50%;
        transform: translateY(-50%);
        font-size: 16px;
        color: var(--so-text-muted);
        pointer-events: none;
    }

    .so-input--search {
        padding-left: 34px;
        padding-right: 34px;
        width: 300px;
        max-width: 100%;
        min-width: 220px;
        flex-shrink: 0;
    }

    .so-search-clear {
        position: absolute;
        right: 6px;
        top: 50%;
        transform: translateY(-50%);
        width: 24px;
        height: 24px;
        border-radius: 50%;
        border: none;
        background: var(--so-border-light);
        color: var(--so-text-muted);
        display: flex;
        align-items: center;
        justify-content: center;
        cursor: pointer;
        transition: var(--so-transition);
    }

    .so-search-clear:hover {
        background: var(--so-border);
        color: var(--so-text-primary);
    }

    .so-search-clear .material-symbols-outlined {
        font-size: 14px;
    }

    /* ═══════════════════════════════════════════════════════════════ */
    /*  GRID WRAPPER                                                  */
    /* ═══════════════════════════════════════════════════════════════ */
    .so-grid-wrapper {
        background: var(--so-surface);
        border: 1px solid var(--so-border);
        border-radius: var(--so-radius-lg);
        box-shadow: var(--so-shadow-md);
        display: flex;
        flex-direction: column;
        overflow: hidden;
        flex: 1;
        min-height: 0;
        margin-bottom: 2px;
    }

    /* ═══════════════════════════════════════════════════════════════ */
    /*  SCROLL CONTAINER                                              */
    /* ═══════════════════════════════════════════════════════════════ */
    .so-scroll-container {
        overflow-y: auto;
        overflow-x: auto;
        flex: 1;
        min-height: 200px;
        scroll-behavior: smooth;
        padding-bottom: 16px;
    }

    /* Custom scrollbar */
    .so-scroll-container::-webkit-scrollbar {
        width: 6px;
    }

    .so-scroll-container::-webkit-scrollbar-track {
        background: transparent;
    }

    .so-scroll-container::-webkit-scrollbar-thumb {
        background: var(--so-border);
        border-radius: 10px;
    }

    .so-scroll-container::-webkit-scrollbar-thumb:hover {
        background: var(--so-text-muted);
    }

    /* ═══════════════════════════════════════════════════════════════ */
    /*  STICKY HORIZONTAL SCROLLBAR                                  */
    /* ═══════════════════════════════════════════════════════════════ */
    .so-horizontal-bar {
        height: 14px;
        overflow-x: auto;
        overflow-y: hidden;
        flex-shrink: 0;
        border-top: 1px solid var(--so-border-light);
        background: var(--so-surface);
        position: sticky;
        bottom: 0;
        z-index: 10;
        margin-bottom: 4px;
    }

    .so-horizontal-bar::-webkit-scrollbar {
        height: 10px;
    }

    .so-horizontal-bar::-webkit-scrollbar-track {
        background: var(--so-border-light);
    }

    .so-horizontal-bar::-webkit-scrollbar-thumb {
        background: var(--so-border);
        border-radius: 10px;
    }

    .so-horizontal-bar::-webkit-scrollbar-thumb:hover {
        background: var(--so-text-muted);
    }

    .so-horizontal-track {
        height: 100%;
        min-width: 900px;
        pointer-events: none;
    }

    /* ═══════════════════════════════════════════════════════════════ */
    /*  SUMMARY BAR                                                   */
    /* ═══════════════════════════════════════════════════════════════ */
    .so-grid-summary {
        display: flex;
        align-items: center;
        justify-content: space-between;
        flex-wrap: wrap;
        gap: 8px;
        padding: 10px 20px;
        border-bottom: 1px solid var(--so-border);
        background: var(--so-surface-hover);
        flex-shrink: 0;
    }

    .so-grid-summary-left {
        display: flex;
        align-items: center;
        gap: 6px;
    }

    .so-grid-summary-icon {
        font-size: 16px;
        color: var(--so-text-muted);
    }

    .so-grid-summary-text {
        font-size: 12px;
        color: var(--so-text-secondary);
    }

    .so-grid-summary-text strong {
        color: var(--so-text-primary);
        font-weight: 700;
    }

    .so-grid-summary-right {
        display: flex;
        align-items: center;
        gap: 6px;
        flex-wrap: wrap;
    }

    /* ═══════════════════════════════════════════════════════════════ */
    /*  BADGES                                                        */
    /* ═══════════════════════════════════════════════════════════════ */
    .so-badge {
        display: inline-flex;
        align-items: center;
        gap: 4px;
        padding: 2px 8px;
        border-radius: 20px;
        font-size: 11px;
        font-weight: 600;
        letter-spacing: 0.02em;
    }

    .so-badge-filter {
        background: var(--so-primary-50);
        color: var(--so-primary);
        border: 1px solid var(--so-primary-light);
    }

    .so-badge-close {
        width: 14px;
        height: 14px;
        border-radius: 50%;
        border: none;
        background: transparent;
        color: inherit;
        display: flex;
        align-items: center;
        justify-content: center;
        cursor: pointer;
        padding: 0;
        transition: var(--so-transition);
    }

    .so-badge-close:hover {
        background: var(--so-primary-100);
    }

    .so-badge-close .material-symbols-outlined {
        font-size: 12px;
    }

    /* ═══════════════════════════════════════════════════════════════ */
    /*  LOADING STATE                                                 */
    /* ═══════════════════════════════════════════════════════════════ */
    .so-loading-state {
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        padding: 64px 20px;
        gap: 16px;
    }

    .so-loading-spinner {
        width: 40px;
        height: 40px;
        border: 3px solid var(--so-border);
        border-top-color: var(--so-primary);
        border-radius: 50%;
        animation: so-spin 0.8s linear infinite;
    }

    @keyframes so-spin {
        to { transform: rotate(360deg); }
    }

    .so-loading-text {
        font-size: 13px;
        color: var(--so-text-muted);
        font-weight: 500;
    }

    /* ═══════════════════════════════════════════════════════════════ */
    /*  DESKTOP TABLE                                                 */
    /* ═══════════════════════════════════════════════════════════════ */
    .desktop-table-wrapper {
        display: block;
        min-width: 900px;
    }

    .so-table {
        width: 100%;
        border-collapse: separate;
        border-spacing: 0;
        table-layout: fixed;
        min-width: 900px;
    }

    /* ═══ Column Resize Handles ═══ */
    .so-col-resizable {
        position: relative;
    }

    .so-col-fixed {
        /* actions column — no resize */
    }

    .so-resize-handle {
        position: absolute;
        top: 0;
        right: 0;
        width: 6px;
        height: 100%;
        cursor: col-resize;
        background: transparent;
        z-index: 2;
        transition: background 0.15s ease;
    }

    .so-resize-handle::after {
        content: '';
        position: absolute;
        right: 0;
        top: 25%;
        height: 50%;
        width: 2px;
        background: transparent;
        border-radius: 2px;
        transition: background 0.15s ease;
    }

    .so-resize-handle:hover {
        background: rgba(124, 58, 237, 0.08);
    }

    .so-resize-handle:hover::after {
        background: var(--so-primary-light);
    }

    .so-resize-handle.so-resizing {
        background: rgba(124, 58, 237, 0.15);
    }

    .so-resize-handle.so-resizing::after {
        background: var(--so-primary);
    }

    @media (max-width: 768px) {
        .so-resize-handle--mobile {
            display: none;
        }
    }

    /* Table Head */
    .so-table-head {
        position: sticky;
        top: 0;
        z-index: 10;
    }

    .so-table-head tr {
        background: var(--so-surface);
    }

    .so-table-head::after {
        content: '';
        position: absolute;
        bottom: 0;
        left: 0;
        right: 0;
        height: 1px;
        background: var(--so-border);
        z-index: 1;
    }

    .so-th {
        padding: 12px 16px;
        font-size: 11px;
        font-weight: 700;
        text-transform: uppercase;
        letter-spacing: 0.06em;
        color: var(--so-text-muted);
        border-bottom: 2px solid var(--so-border);
        cursor: pointer;
        user-select: none;
        transition: var(--so-transition);
        white-space: nowrap;
        background: var(--so-surface);
        position: relative;
    }

    .so-th:hover {
        color: var(--so-primary);
        background: var(--so-primary-50);
    }

    .so-th-inner {
        display: flex;
        align-items: center;
        gap: 4px;
    }

    .so-th-inner--end {
        justify-content: flex-end;
    }

    .so-th-right .so-th-inner {
        justify-content: flex-end;
    }

    .so-th-actions {
        text-align: right;
        cursor: default;
    }

    .so-th-actions:hover {
        background: transparent;
    }

    /* ═══ Sticky Right Column (Actions) ═══ */
    .so-th-sticky-right {
        position: sticky;
        right: 0;
        z-index: 12;
        text-align: right;
        cursor: default;
        background: var(--so-surface);
        border-left: 2px solid var(--so-border);
        padding: 12px 14px;
        font-size: 11px;
        font-weight: 700;
        text-transform: uppercase;
        letter-spacing: 0.06em;
        color: var(--so-text-muted);
        white-space: nowrap;
    }

    .so-th-sticky-right::before {
        content: '';
        position: absolute;
        left: -8px;
        top: 0;
        width: 8px;
        height: 100%;
        background: linear-gradient(90deg, transparent, rgba(0,0,0,0.03));
        pointer-events: none;
    }

    .dark .so-th-sticky-right::before {
        background: linear-gradient(90deg, transparent, rgba(0,0,0,0.15));
    }

    .so-th-sticky-right:hover {
        background: var(--so-surface);
    }

    .so-td-sticky-right {
        position: sticky;
        right: 0;
        z-index: 5;
        text-align: right;
        white-space: nowrap;
        background: var(--so-surface);
        border-left: 1px solid var(--so-border-light);
        padding: 12px 14px;
    }

    .so-td-sticky-right::before {
        content: '';
        position: absolute;
        left: -8px;
        top: 0;
        width: 8px;
        height: 100%;
        background: linear-gradient(90deg, transparent, rgba(0,0,0,0.03));
        pointer-events: none;
    }

    .dark .so-td-sticky-right::before {
        background: linear-gradient(90deg, transparent, rgba(0,0,0,0.15));
    }

    .so-tr:hover .so-td-sticky-right {
        background: var(--so-primary-50);
    }

    .so-tr-selected .so-td-sticky-right {
        background: var(--so-surface-selected);
    }

    /* Sort Icon */
    .so-sort-icon {
        font-size: 14px;
        opacity: 0.3;
        transition: var(--so-transition);
    }

    .so-th:hover .so-sort-icon {
        opacity: 0.6;
    }

    .sort-active {
        color: var(--so-primary) !important;
        font-weight: 800;
    }

    .sort-active .so-sort-icon {
        opacity: 1 !important;
    }

    /* Table Body */
    .so-table-body {
        /* no direct style, rows handle it */
    }

    .so-tr {
        cursor: pointer;
        transition: var(--so-transition);
        border-bottom: 1px solid var(--so-border-light);
    }

    .so-tr:hover {
        background: var(--so-primary-50);
    }

    .so-tr-selected {
        background: var(--so-surface-selected) !important;
        box-shadow: inset 3px 0 0 var(--so-primary);
    }

    .so-td {
        padding: 12px 16px;
        font-size: 13px;
        color: var(--so-text-primary);
        vertical-align: middle;
    }

    .so-td-date {
        white-space: nowrap;
        color: var(--so-text-secondary);
    }

    .so-td-date .so-td-icon {
        font-size: 14px;
        color: var(--so-text-muted);
        margin-right: 4px;
    }

    .so-td-money {
        white-space: nowrap;
        text-align: right;
        font-family: 'JetBrains Mono', 'Fira Code', 'Consolas', monospace;
        font-size: 12.5px;
        color: var(--so-text-secondary);
    }

    .so-td-total {
        white-space: nowrap;
        text-align: right;
        font-family: 'JetBrains Mono', 'Fira Code', 'Consolas', monospace;
        font-size: 13px;
        font-weight: 700;
        color: #059669;
    }

    .dark .so-td-total {
        color: #34d399;
    }

    .so-td-memo {
        color: var(--so-text-muted);
        max-width: 200px;
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap;
    }

    .so-td-actions {
        text-align: right;
        white-space: nowrap;
    }

    .so-td-customer {
        max-width: 220px;
    }

    .so-td-right {
        text-align: right;
        font-variant-numeric: tabular-nums;
    }

    .so-td-center {
        text-align: center;
    }

    /* ═══════════════════════════════════════════════════════════════ */
    /*  STATUS BADGES (Table)                                         */
    /* ═══════════════════════════════════════════════════════════════ */
    .so-status {
        display: inline-flex;
        align-items: center;
        gap: 5px;
        padding: 3px 10px;
        border-radius: 20px;
        font-size: 11px;
        font-weight: 700;
        text-transform: uppercase;
        letter-spacing: 0.04em;
        white-space: nowrap;
    }

    .so-status-dot {
        width: 6px;
        height: 6px;
        border-radius: 50%;
        flex-shrink: 0;
    }

    .so-status--approved {
        background: #ecfdf5;
        color: #047857;
    }

    .so-status--approved .so-status-dot {
        background: #059669;
        box-shadow: 0 0 0 2px rgba(5, 150, 105, 0.2);
    }

    .so-status--void {
        background: #fef2f2;
        color: #b91c1c;
    }

    .so-status--void .so-status-dot {
        background: #dc2626;
        box-shadow: 0 0 0 2px rgba(220, 38, 38, 0.2);
    }

    .so-status--draft {
        background: #f9fafb;
        color: #6b7280;
    }

    .so-status--draft .so-status-dot {
        background: #9ca3af;
        box-shadow: 0 0 0 2px rgba(156, 163, 175, 0.2);
    }

    .so-status--sm {
        padding: 2px 7px;
        font-size: 9px;
    }

    .so-status--sm .so-status-dot {
        width: 5px;
        height: 5px;
    }

    .dark .so-status--approved {
        background: rgba(5, 150, 105, 0.15);
        color: #34d399;
    }

    .dark .so-status--approved .so-status-dot {
        background: #34d399;
    }

    .dark .so-status--void {
        background: rgba(220, 38, 38, 0.15);
        color: #fca5a5;
    }

    .dark .so-status--void .so-status-dot {
        background: #f87171;
    }

    .dark .so-status--draft {
        background: rgba(156, 163, 175, 0.15);
        color: #9ca3af;
    }

    .dark .so-status--draft .so-status-dot {
        background: #71717a;
    }

    /* ═══════════════════════════════════════════════════════════════ */
    /*  CODE / REF LINKS                                              */
    /* ═══════════════════════════════════════════════════════════════ */
    .so-code-link {
        font-weight: 700;
        font-size: 13px;
        color: var(--so-primary);
        transition: var(--so-transition);
    }

    .so-tr:hover .so-code-link {
        text-decoration: underline;
        text-underline-offset: 2px;
    }

    .so-ref-code {
        font-size: 12px;
        color: var(--so-text-secondary);
        background: var(--so-surface-hover);
        padding: 2px 8px;
        border-radius: 4px;
        font-family: 'JetBrains Mono', 'Fira Code', 'Consolas', monospace;
        font-size: 11px;
    }

    /* ═══════════════════════════════════════════════════════════════ */
    /*  CUSTOMER AVATAR CELL                                          */
    /* ═══════════════════════════════════════════════════════════════ */
    .so-customer-cell {
        display: flex;
        align-items: center;
        gap: 10px;
        min-width: 0;
    }

    .so-customer-avatar {
        width: 30px;
        height: 30px;
        border-radius: 8px;
        background: linear-gradient(135deg, var(--so-primary-100), var(--so-primary-50));
        color: var(--so-primary);
        display: flex;
        align-items: center;
        justify-content: center;
        font-size: 11px;
        font-weight: 800;
        flex-shrink: 0;
        letter-spacing: 0.03em;
    }

    .so-customer-avatar--sm {
        width: 22px;
        height: 22px;
        font-size: 9px;
        border-radius: 6px;
    }

    .so-customer-name {
        font-size: 13px;
        font-weight: 500;
        color: var(--so-text-primary);
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap;
    }

    /* ═══════════════════════════════════════════════════════════════ */
    /*  ACTION BUTTONS                                                */
    /* ═══════════════════════════════════════════════════════════════ */
    .so-action-group {
        display: inline-flex;
        align-items: center;
        gap: 4px;
        justify-content: flex-end;
    }

    .so-action-btn {
        width: 32px;
        height: 32px;
        border-radius: var(--so-radius-sm);
        border: none;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        cursor: pointer;
        transition: var(--so-transition);
    }

    .so-action-btn .material-symbols-outlined {
        font-size: 17px;
    }

    .so-action-btn--edit {
        background: transparent;
        color: var(--so-text-muted);
    }

    .so-action-btn--edit:hover {
        background: var(--so-primary-50);
        color: var(--so-primary);
        box-shadow: 0 2px 8px var(--so-primary-100);
    }

    .so-action-btn--approve {
        background: transparent;
        color: var(--so-text-muted);
    }

    .so-action-btn--approve:hover {
        background: #ecfdf5;
        color: #059669;
        box-shadow: 0 2px 8px rgba(5, 150, 105, 0.15);
    }

    .dark .so-action-btn--approve:hover {
        background: rgba(5, 150, 105, 0.15);
        color: #34d399;
    }

    .so-action-btn--sm {
        width: 28px;
        height: 28px;
    }

    .so-action-btn--sm .material-symbols-outlined {
        font-size: 15px;
    }

    /* ═══════════════════════════════════════════════════════════════ */
    /*  MOBILE SORT BAR                                               */
    /* ═══════════════════════════════════════════════════════════════ */
    .so-mobile-sort-bar {
        display: none;
        border-bottom: 1px solid var(--so-border);
    }

    .so-mobile-sort-inner {
        display: flex;
        align-items: center;
        justify-content: space-between;
        padding: 10px 16px;
    }

    .so-mobile-sort-label {
        display: flex;
        align-items: center;
        gap: 4px;
        font-size: 12px;
        font-weight: 600;
        color: var(--so-text-muted);
    }

    .so-mobile-sort-label .material-symbols-outlined {
        font-size: 16px;
    }

    .so-mobile-sort-select {
        padding: 5px 28px 5px 10px;
        font-size: 12px;
        border: 1px solid var(--so-border);
        border-radius: var(--so-radius-sm);
        background: var(--so-surface);
        color: var(--so-text-primary);
        outline: none;
        appearance: none;
        background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3e%3cpath fill='none' stroke='%236b7280' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='m2 5 6 6 6-6'/%3e%3c/svg%3e");
        background-repeat: no-repeat;
        background-position: right 8px center;
        background-size: 12px;
    }

    /* ═══════════════════════════════════════════════════════════════ */
    /*  MOBILE CARD GRID                                              */
    /* ═══════════════════════════════════════════════════════════════ */
    .card-grid {
        display: none;
    }

    .so-card {
        background: var(--so-surface);
        border: 1px solid var(--so-border);
        border-radius: var(--so-radius-md);
        margin: 8px;
        padding: 0;
        cursor: pointer;
        transition: var(--so-transition);
        overflow: hidden;
        box-shadow: var(--so-shadow-sm);
    }

    .so-card:hover {
        border-color: var(--so-primary-light);
        box-shadow: var(--so-shadow-md), 0 0 0 1px var(--so-primary-100);
        transform: translateY(-1px);
    }

    .so-card--selected {
        border-color: var(--so-primary);
        background: var(--so-surface-selected);
        box-shadow: var(--so-shadow-md), inset 0 0 0 1px var(--so-primary-light);
    }

    .so-card-header {
        display: flex;
        align-items: center;
        justify-content: space-between;
        padding: 10px 12px 8px;
        border-bottom: 1px solid var(--so-border-light);
    }

    .so-card-header-left {
        display: flex;
        align-items: center;
        gap: 8px;
    }

    .so-card-header-right {
        display: flex;
        align-items: center;
        gap: 2px;
    }

    .so-card-checkbox {
        width: 16px;
        height: 16px;
        border-radius: 4px;
        border: 2px solid var(--so-border);
        accent-color: var(--so-primary);
        cursor: pointer;
    }

    .so-card-body {
        padding: 10px 12px 6px;
    }

    .so-card-code {
        font-size: 14px;
        font-weight: 700;
        color: var(--so-primary);
        margin-bottom: 4px;
        position: relative;
        padding-right: 20px;
    }

    .so-card-customer {
        font-size: 12px;
        color: var(--so-text-secondary);
        display: flex;
        align-items: center;
        gap: 6px;
        position: relative;
        padding-right: 20px;
    }

    .so-card-sort-arrow {
        font-size: 12px;
        opacity: 0.3;
        position: absolute;
        right: 0;
        top: 50%;
        transform: translateY(-50%);
        transition: var(--so-transition);
    }

    .so-card-code:hover .so-card-sort-arrow,
    .so-card-customer:hover .so-card-sort-arrow {
        opacity: 0.7;
    }

    .so-card-footer {
        display: flex;
        align-items: center;
        justify-content: space-between;
        padding: 8px 12px 10px;
        border-top: 1px solid var(--so-border-light);
    }

    .so-card-meta {
        display: flex;
        align-items: center;
        gap: 8px;
        flex-wrap: wrap;
    }

    .so-card-meta-item {
        display: inline-flex;
        align-items: center;
        gap: 3px;
        font-size: 10px;
        color: var(--so-text-muted);
    }

    .so-card-meta-item .material-symbols-outlined {
        font-size: 12px;
    }

    .so-card-total {
        font-family: 'JetBrains Mono', 'Fira Code', 'Consolas', monospace;
        font-size: 14px;
        font-weight: 700;
        color: #059669;
    }

    .dark .so-card-total {
        color: #34d399;
    }

    /* ═══════════════════════════════════════════════════════════════ */
    /*  EMPTY STATE                                                   */
    /* ═══════════════════════════════════════════════════════════════ */
    .so-empty-state {
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        padding: 64px 20px;
        text-align: center;
    }

    .so-empty-icon-wrapper {
        width: 80px;
        height: 80px;
        border-radius: 50%;
        background: var(--so-surface-hover);
        display: flex;
        align-items: center;
        justify-content: center;
        margin-bottom: 16px;
        border: 2px dashed var(--so-border);
    }

    .so-empty-icon {
        font-size: 36px;
        color: var(--so-text-muted);
    }

    .so-empty-title {
        font-size: 16px;
        font-weight: 700;
        color: var(--so-text-primary);
        margin: 0 0 6px 0;
    }

    .so-empty-desc {
        font-size: 13px;
        color: var(--so-text-muted);
        margin: 0 0 20px 0;
    }

    /* ═══════════════════════════════════════════════════════════════ */
    /*  INFINITE SCROLL TRIGGER                                       */
    /* ═══════════════════════════════════════════════════════════════ */
    .so-scroll-trigger {
        display: flex;
        flex-direction: column;
        align-items: center;
        padding: 16px 20px;
        gap: 8px;
    }

    .so-loading-bar {
        width: 120px;
        height: 3px;
        background: var(--so-border);
        border-radius: 999px;
        overflow: hidden;
    }

    .so-loading-bar-inner {
        width: 40%;
        height: 100%;
        background: linear-gradient(90deg, var(--so-primary), var(--so-primary-light));
        border-radius: 999px;
        animation: so-loading-slide 1.2s ease-in-out infinite;
    }

    @keyframes so-loading-slide {
        0% { transform: translateX(-100%); }
        100% { transform: translateX(350%); }
    }

    .so-scroll-loading-text {
        font-size: 12px;
        color: var(--so-text-muted);
        font-weight: 500;
    }

    .so-scroll-hint {
        display: flex;
        align-items: center;
        gap: 6px;
        font-size: 12px;
        color: var(--so-text-muted);
        animation: so-bounce-down 1.5s ease-in-out infinite;
    }

    .so-scroll-hint-icon {
        font-size: 16px;
    }

    @keyframes so-bounce-down {
        0%, 100% { transform: translateY(0); }
        50% { transform: translateY(4px); }
    }

    .so-scroll-end {
        display: flex;
        align-items: center;
        gap: 12px;
        padding: 16px 20px;
    }

    .so-scroll-end-line {
        flex: 1;
        height: 1px;
        background: var(--so-border);
    }

    .so-scroll-end-text {
        display: flex;
        align-items: center;
        gap: 6px;
        font-size: 12px;
        color: var(--so-text-muted);
        white-space: nowrap;
    }

    .so-scroll-end-text .material-symbols-outlined {
        font-size: 16px;
        color: #059669;
    }

    .dark .so-scroll-end-text .material-symbols-outlined {
        color: #34d399;
    }

    /* ═══════════════════════════════════════════════════════════════ */
    /*  RESPONSIVE                                                    */
    /* ═══════════════════════════════════════════════════════════════ */
    @media (max-width: 768px) {
        .desktop-table-wrapper {
            display: none;
        }

        .so-mobile-sort-bar {
            display: none;
        }

        .card-grid {
            display: grid;
            grid-template-columns: 1fr;
            gap: 0;
            padding: 0;
        }

        .so-header-inner {
            flex-direction: column;
            align-items: flex-start;
        }

        .so-filter-row {
            flex-direction: column;
            gap: 10px;
        }

        .so-filter-group {
            width: 100%;
        }

        .so-filter-group--grow {
            min-width: auto;
        }

        .so-input {
            width: 100%;
        }

        .so-btn {
            width: 100%;
            justify-content: center;
        }

        .so-header-title {
            font-size: 18px;
        }
    }

    @media (min-width: 769px) and (max-width: 1024px) {
        .so-hide-mobile {
            display: table-cell !important;
        }
    }

    @media (max-width: 768px) {
        .so-hide-mobile {
            display: none !important;
        }
    }

    /* ═══════════════════════════════════════════════════════════════ */
    /*  ROW ANIMATION                                                 */
    /* ═══════════════════════════════════════════════════════════════ */
    .so-tr {
        animation: so-fadeIn 0.3s ease-out;
    }

    @keyframes so-fadeIn {
        from {
            opacity: 0;
            transform: translateY(4px);
        }
        to {
            opacity: 1;
            transform: translateY(0);
        }
    }

    /* ═══════════════════════════════════════════════════════════════ */
    /*  DESKTOP-ONLY / MOBILE-ONLY UTILITY                            */
    /* ═══════════════════════════════════════════════════════════════ */
    .so-desktop-only {
        display: flex;
    }

    .so-mobile-menu-btn {
        display: none;
    }

    .so-mobile-sort-inline {
        display: none;
    }

    @media (max-width: 768px) {
        .so-desktop-only {
            display: none !important;
        }

        .so-mobile-menu-btn {
            display: inline-flex;
            align-items: center;
            justify-content: center;
            width: 32px;
            height: 32px;
            border-radius: 8px;
            border: 1px solid var(--so-border);
            background: var(--so-surface);
            color: var(--so-text-primary);
            cursor: pointer;
            transition: var(--so-transition);
            box-shadow: var(--so-shadow-sm);
            flex-shrink: 0;
            margin-left: auto;
        }

        .so-mobile-menu-btn:hover {
            background: var(--so-surface-hover);
            border-color: var(--so-primary-light);
            color: var(--so-primary);
            box-shadow: var(--so-shadow-md);
        }

        .so-mobile-menu-btn:active {
            transform: scale(0.95);
        }

        .so-mobile-menu-btn .material-symbols-outlined {
            font-size: 20px;
        }

        .so-mobile-sort-inline {
            display: inline-flex;
            align-items: center;
            height: 30px;
            padding: 0 8px;
            border-radius: 8px;
            border: 1px solid var(--so-border);
            background: var(--so-surface);
            color: var(--so-text-secondary);
            font-size: 12px;
            cursor: pointer;
            flex-shrink: 0;
            transition: var(--so-transition);
        }

        .so-mobile-sort-inline:focus {
            outline: none;
            border-color: var(--so-primary);
        }

        .so-grid-summary {
            padding: 8px 12px;
            flex-wrap: nowrap;
            overflow-x: auto;
            gap: 6px;
        }

        .so-grid-summary-left {
            flex-shrink: 0;
            min-width: 0;
        }

        .so-grid-summary-right {
            flex-shrink: 0;
        }
    }

    /* ═══════════════════════════════════════════════════════════════ */
    /*  MOBILE BOTTOM SHEET                                           */
    /* ═══════════════════════════════════════════════════════════════ */
    .so-bottom-sheet-overlay {
        display: none;
    }

    .so-bottom-sheet {
        display: none;
    }

    @media (max-width: 768px) {
        .so-bottom-sheet-overlay {
            display: block;
            position: fixed;
            inset: 0;
            background: rgba(0, 0, 0, 0.4);
            z-index: 999;
            animation: so-overlay-in 0.2s ease-out;
            backdrop-filter: blur(2px);
            -webkit-backdrop-filter: blur(2px);
        }

        @keyframes so-overlay-in {
            from { opacity: 0; }
            to { opacity: 1; }
        }

        .so-bottom-sheet {
            display: flex;
            flex-direction: column;
            position: fixed;
            bottom: 0;
            left: 0;
            right: 0;
            z-index: 1000;
            background: var(--so-surface);
            border-radius: 20px 20px 0 0;
            box-shadow: 0 -4px 24px rgba(0, 0, 0, 0.12);
            max-height: 85vh;
            overflow-y: auto;
            animation: so-sheet-up 0.3s cubic-bezier(0.4, 0, 0.2, 1);
            -webkit-overflow-scrolling: touch;
        }

        @keyframes so-sheet-up {
            from { transform: translateY(100%); }
            to { transform: translateY(0); }
        }

        .so-bottom-sheet-handle {
            width: 40px;
            height: 4px;
            border-radius: 999px;
            background: var(--so-border);
            margin: 10px auto 0;
            flex-shrink: 0;
        }

        .so-bottom-sheet-header {
            display: flex;
            align-items: center;
            justify-content: space-between;
            padding: 14px 20px 10px;
            border-bottom: 1px solid var(--so-border-light);
            flex-shrink: 0;
        }

        .so-bottom-sheet-title {
            font-size: 16px;
            font-weight: 700;
            color: var(--so-text-primary);
            margin: 0;
        }

        .so-bottom-sheet-close {
            width: 32px;
            height: 32px;
            border-radius: 8px;
            border: none;
            background: var(--so-surface-hover);
            color: var(--so-text-muted);
            display: flex;
            align-items: center;
            justify-content: center;
            cursor: pointer;
            transition: var(--so-transition);
        }

        .so-bottom-sheet-close:hover {
            background: var(--so-border);
            color: var(--so-text-primary);
        }

        .so-bottom-sheet-close .material-symbols-outlined {
            font-size: 20px;
        }

        .so-bottom-sheet-content {
            padding: 16px 20px 24px;
            overflow-y: auto;
        }

        .so-bottom-sheet-section {
            display: flex;
            flex-direction: column;
            gap: 12px;
        }

        .so-bottom-sheet-section-title {
            display: flex;
            align-items: center;
            gap: 6px;
            font-size: 12px;
            font-weight: 700;
            color: var(--so-text-muted);
            text-transform: uppercase;
            letter-spacing: 0.05em;
            padding-bottom: 4px;
            border-bottom: 1px solid var(--so-border-light);
        }

        .so-bottom-sheet-filter {
            display: flex;
            flex-direction: column;
            gap: 5px;
        }

        .so-bottom-sheet-filter .so-input {
            width: 100%;
            box-sizing: border-box;
        }
    }