/* ================================================
   Orders & Invoice Detail Styles
   ================================================ */

/* ---- Container ---- */
.ord-container {
    max-width: 100%;
}

/* ---- Section Tabs ---- */
.ord-tabs {
    display: flex;
    gap: 4px;
    margin-bottom: 20px;
    border-bottom: 2px solid #e2e8f0;
    padding-bottom: 0;
}

.ord-tab {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 10px 20px;
    font-size: 13px;
    font-weight: 600;
    color: var(--gp-gray-500);
    background: transparent;
    border: none;
    border-bottom: 3px solid transparent;
    margin-bottom: -2px;
    cursor: pointer;
    transition: all 0.2s;
    white-space: nowrap;
}

.ord-tab:hover {
    color: var(--gp-blue);
    background: var(--gp-gray-100);
    border-radius: 6px 6px 0 0;
}

.ord-tab-active {
    color: var(--gp-blue);
    border-bottom-color: var(--gp-blue-light);
}

.ord-tab-icon {
    width: 18px;
    height: 18px;
}

/* ---- Filter Bar ---- */
.ord-filter-bar {
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 10px;
    padding: 14px 16px;
    margin-bottom: 16px;
}

.ord-filter-row {
    display: flex;
    gap: 12px;
    align-items: flex-end;
    flex-wrap: wrap;
}

.ord-filter-field {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.ord-filter-search {
    flex: 1;
    min-width: 180px;
}

.ord-filter-label {
    font-size: 11px;
    font-weight: 600;
    color: #64748b;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.ord-input {
    height: 36px;
    padding: 0 10px;
    font-size: 13px;
    border: 1px solid #cbd5e1;
    border-radius: 6px;
    background: #fff;
    color: #1e293b;
    outline: none;
    transition: border-color 0.15s;
}

.ord-input:focus {
    border-color: #2563eb;
    box-shadow: 0 0 0 2px rgba(37, 99, 235, 0.15);
}

.ord-filter-actions {
    display: flex;
    align-items: flex-end;
    gap: 8px;
}

.ord-search-btn {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    height: 36px;
    padding: 0 18px;
    font-size: 13px;
    font-weight: 700;
    color: #fff;
    background: linear-gradient(135deg, #2563eb, #1d4ed8);
    border: none;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.15s;
    white-space: nowrap;
}

.ord-search-btn:hover {
    background: linear-gradient(135deg, #1d4ed8, #1e3a8a);
    box-shadow: 0 2px 6px rgba(30, 58, 138, 0.3);
}

.ord-search-btn:active {
    transform: scale(0.97);
}

.ord-clear-btn {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    height: 36px;
    padding: 0 14px;
    font-size: 12px;
    font-weight: 600;
    color: #64748b;
    background: #fff;
    border: 1px solid #cbd5e1;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.15s;
}

.ord-clear-btn:hover {
    color: #dc2626;
    border-color: #fca5a5;
    background: #fef2f2;
}

.ord-clear-btn:disabled {
    opacity: 0.4;
    cursor: default;
}

.ord-clear-btn:disabled:hover {
    color: #64748b;
    border-color: #cbd5e1;
    background: #fff;
}

/* ---- YMM Select ---- */
.ord-select {
    min-width: 160px;
    cursor: pointer;
}

.ord-select:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    background: #f1f5f9;
}

/* ---- Active Filter Indicator ---- */
.ord-filter-active {
    display: flex;
    align-items: center;
    gap: 6px;
    margin-top: 10px;
    padding: 8px 12px;
    background: #eff6ff;
    border: 1px solid #bfdbfe;
    border-radius: 6px;
    font-size: 12px;
    color: #1e40af;
}

.ord-filter-active strong {
    font-weight: 700;
}

/* ---- Toggle / Expand Row ---- */
.ord-toggle-cell {
    padding: 6px 8px !important;
    width: 40px;
}

.ord-toggle-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 26px;
    height: 26px;
    border: 1px solid #cbd5e1;
    border-radius: 6px;
    background: #fff;
    color: #64748b;
    cursor: pointer;
    transition: all 0.15s;
}

.ord-toggle-btn:hover {
    background: #2563eb;
    color: #fff;
    border-color: #2563eb;
}

.ord-row-expanded {
    background: #eff6ff !important;
    border-bottom-color: transparent !important;
}

.ord-row-expanded .ord-toggle-btn {
    background: #2563eb;
    color: #fff;
    border-color: #2563eb;
}

/* ---- Expanded Detail Row ---- */
.ord-detail-row {
    background: #f8fafc !important;
}

.ord-detail-row:hover {
    background: #f8fafc !important;
}

.ord-detail-cell {
    padding: 0 !important;
    border-top: none !important;
}

.ord-detail-container {
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    margin: 0 14px 14px 14px;
    overflow: hidden;
    background: #fff;
    box-shadow: 0 1px 4px rgba(0,0,0,0.06);
}

/* ---- Detail Header ---- */
.ord-detail-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 16px;
    background: linear-gradient(135deg, #1e3a8a, #1e40af);
    color: #fff;
}

.ord-detail-title {
    font-size: 14px;
    font-weight: 700;
}

.ord-detail-po {
    margin-left: 12px;
    font-size: 12px;
    font-weight: 500;
    color: #bfdbfe;
}

.ord-detail-pdf-link {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 5px 12px;
    font-size: 12px;
    font-weight: 600;
    color: #fff;
    background: rgba(255,255,255,0.15);
    border-radius: 6px;
    text-decoration: none;
    transition: background 0.15s;
}

.ord-detail-pdf-link:hover {
    background: rgba(255,255,255,0.25);
    color: #fff;
}

/* ---- Detail Items Table ---- */
.ord-detail-items-wrap {
    overflow-x: auto;
}

.ord-detail-items {
    width: 100%;
    border-collapse: collapse;
    font-size: 12px;
}

.ord-detail-items thead tr {
    background: #f1f5f9;
}

.ord-detail-items thead th {
    padding: 8px 12px;
    font-size: 10px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: #475569;
    white-space: nowrap;
    border-bottom: 1px solid #e2e8f0;
    text-align: left;
}

.ord-detail-items tbody tr {
    border-bottom: 1px solid #f1f5f9;
}

.ord-detail-items tbody tr:last-child {
    border-bottom: none;
}

.ord-detail-items tbody tr:hover {
    background: #f8fafc;
}

.ord-detail-items td {
    padding: 8px 12px;
    color: #334155;
    vertical-align: top;
}

.ord-detail-item-id {
    font-size: 11px;
    color: #94a3b8;
    white-space: nowrap;
}

.ord-detail-item-product {
    min-width: 180px;
}

.ord-detail-product-link {
    font-weight: 600;
    color: #1e293b;
    text-decoration: none;
    font-size: 12px;
    transition: color 0.15s;
}

.ord-detail-product-link:hover {
    color: #2563eb;
}

.ord-detail-item-info {
    font-size: 11px;
    color: #64748b;
    margin-top: 2px;
    line-height: 1.4;
}

.ord-detail-item-eta {
    font-size: 11px;
    color: #92400e;
    margin-top: 2px;
}

.ord-detail-item-tracking {
    display: flex;
    align-items: center;
    gap: 6px;
    flex-wrap: wrap;
    margin-top: 3px;
}

.ord-detail-item-note {
    font-size: 11px;
    color: #94a3b8;
    font-style: italic;
    margin-top: 2px;
}

.ord-detail-part-num {
    font-family: monospace;
    font-size: 11px;
    color: #64748b;
}

/* ---- Detail Totals ---- */
.ord-detail-totals-wrap {
    display: flex;
    justify-content: flex-end;
    padding: 12px 16px;
    border-top: 1px solid #e2e8f0;
}

.ord-detail-totals {
    width: 280px;
    max-width: 100%;
}

.ord-detail-total-row {
    display: flex;
    justify-content: space-between;
    padding: 4px 0;
    font-size: 12px;
    color: #475569;
}

.ord-detail-total-row span:last-child {
    font-weight: 600;
    color: #1e293b;
}

.ord-detail-discount-row {
    color: #2563eb;
}

.ord-detail-discount-row span:last-child {
    color: #2563eb !important;
}

.ord-detail-grand-total {
    border-top: 2px solid #e2e8f0;
    margin-top: 6px;
    padding-top: 8px !important;
    font-size: 14px !important;
    font-weight: 700;
}

.ord-detail-grand-total span:last-child {
    color: #1e3a8a !important;
    font-size: 15px;
    font-weight: 800;
}

/* ---- Detail Bottom Panels ---- */
.ord-detail-panels {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0;
    border-top: 1px solid #e2e8f0;
}

.ord-detail-panel {
    border-right: 1px solid #e2e8f0;
}

.ord-detail-panel:last-child {
    border-right: none;
}

.ord-detail-panel-header {
    padding: 8px 14px;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: #475569;
    background: #f1f5f9;
    border-bottom: 1px solid #e2e8f0;
}

.ord-detail-panel-body {
    padding: 12px 14px;
    font-size: 12px;
    line-height: 1.6;
    color: #334155;
}

.ord-detail-info-row {
    margin-bottom: 4px;
}

.ord-detail-info-row strong {
    color: #1e293b;
}

/* ---- Section Headers ---- */
.ord-section-header {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 12px 16px;
    background: linear-gradient(135deg, #2563eb, #1d4ed8);
    color: #fff;
    font-size: 14px;
    font-weight: 600;
    border-radius: 10px 10px 0 0;
    margin-bottom: 0;
}

.ord-section-header-amber {
    background: linear-gradient(135deg, #f59e0b, #d97706);
}

.ord-section-icon {
    width: 18px;
    height: 18px;
}

/* ---- Table Styles ---- */
.ord-table-wrap {
    overflow-x: auto;
    border: 1px solid #e2e8f0;
    border-radius: 10px;
}

.ord-section-header + .ord-table-wrap {
    border-top: none;
    border-radius: 0 0 10px 10px;
}

.ord-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 13px;
}

.ord-table thead tr {
    background: linear-gradient(135deg, var(--gp-blue), var(--gp-blue-dark));
}

.ord-table thead th {
    padding: 10px 14px;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: #fff;
    white-space: nowrap;
    border-bottom: 2px solid var(--gp-blue);
}

.ord-table tbody tr {
    border-bottom: 1px solid #f1f5f9;
    transition: background 0.1s;
}

.ord-table tbody tr:hover {
    background: #f8fafc;
}

.ord-table tbody tr:last-child {
    border-bottom: none;
}

.ord-table td {
    padding: 10px 14px;
    color: #334155;
    vertical-align: middle;
}

.ord-right {
    text-align: right !important;
}

.ord-center {
    text-align: center !important;
}

.ord-total {
    font-weight: 700;
    color: #1e293b !important;
}

.ord-row-canceled {
    background: #fef2f2 !important;
    opacity: 0.85;
}

.ord-row-canceled:hover {
    background: #fee2e2 !important;
}

/* ---- Invoice Link ---- */
.ord-invoice-link {
    font-weight: 600;
    color: #2563eb;
    text-decoration: none;
    transition: color 0.15s;
}

.ord-invoice-link:hover {
    color: #1d4ed8;
    text-decoration: underline;
}

/* ---- Location ---- */
.ord-location {
    display: block;
    font-weight: 500;
    color: #1e293b;
}

.ord-location-detail {
    color: #94a3b8;
    font-size: 11px;
}

/* ---- Status Badges ---- */
.ord-status {
    display: inline-block;
    padding: 3px 10px;
    border-radius: 12px;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.3px;
    white-space: nowrap;
}

.ord-status-paid {
    background: #dcfce7;
    color: #166534;
    border: 1px solid #bbf7d0;
}

.ord-status-due {
    background: #fef3c7;
    color: #92400e;
    border: 1px solid #fde68a;
}

.ord-status-canceled {
    background: #fee2e2;
    color: #991b1b;
    border: 1px solid #fecaca;
}

/* ---- View Button ---- */
.ord-view-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    color: #2563eb;
    background: #eff6ff;
    border-radius: 6px;
    text-decoration: none;
    transition: all 0.15s;
}

.ord-view-btn:hover {
    background: #2563eb;
    color: #fff;
}

/* ---- Product Name ---- */
.ord-product-name {
    max-width: 300px;
    color: #1e293b;
}

/* ---- Carrier Badge ---- */
.ord-carrier-badge {
    display: inline-block;
    padding: 2px 8px;
    background: #e0e7ff;
    color: #3730a3;
    border-radius: 4px;
    font-size: 11px;
    font-weight: 600;
}

/* ---- Tracking Link ---- */
.ord-tracking-link {
    color: #2563eb;
    text-decoration: none;
    font-size: 12px;
    font-weight: 500;
}

.ord-tracking-link:hover {
    color: #1d4ed8;
    text-decoration: underline;
}

/* ---- Empty State ---- */
.ord-empty {
    text-align: center;
    color: #94a3b8;
    padding: 32px 16px !important;
    font-size: 14px;
    font-style: italic;
}

/* ---- Pagination ---- */
.ord-pagination {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 16px;
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-top: none;
    border-radius: 0 0 10px 10px;
}

.ord-pagination-info {
    font-size: 12px;
    color: #64748b;
}

.ord-pagination-controls {
    display: flex;
    align-items: center;
    gap: 4px;
}

.ord-per-page {
    height: 30px;
    padding: 0 6px;
    font-size: 12px;
    border: 1px solid #cbd5e1;
    border-radius: 4px;
    background: #fff;
    color: #334155;
    margin-right: 4px;
}

.ord-per-page-label {
    font-size: 11px;
    color: #94a3b8;
    margin-right: 8px;
}

.ord-page-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 30px;
    height: 30px;
    padding: 0 6px;
    font-size: 12px;
    font-weight: 600;
    color: #334155;
    background: #fff;
    border: 1px solid #cbd5e1;
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.15s;
}

.ord-page-btn:hover {
    background: #2563eb;
    color: #fff;
    border-color: #2563eb;
}

.ord-page-btn-active {
    background: #1e3a8a;
    color: #fff;
    border-color: #1e3a8a;
}

.ord-page-btn-disabled {
    cursor: default;
    opacity: 0.4;
}

.ord-page-btn-disabled:hover {
    background: #fff;
    color: #334155;
    border-color: #cbd5e1;
}

/* ================================================
   Invoice Detail Page Styles
   ================================================ */

.inv-container {
    max-width: 100%;
}

/* ---- Not Found ---- */
.inv-not-found {
    text-align: center;
    padding: 60px 20px;
}

.inv-not-found h3 {
    font-size: 20px;
    font-weight: 700;
    color: #1e293b;
    margin-bottom: 8px;
}

.inv-not-found p {
    font-size: 14px;
    color: #64748b;
    margin-bottom: 20px;
}

/* ---- Back Bar ---- */
.inv-back-bar {
    margin-bottom: 16px;
}

.inv-back-link {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 13px;
    font-weight: 500;
    color: #2563eb;
    text-decoration: none;
    padding: 6px 12px;
    border-radius: 6px;
    transition: all 0.15s;
}

.inv-back-link:hover {
    background: #eff6ff;
    color: #1d4ed8;
}

.inv-back-icon {
    width: 16px;
    height: 16px;
}

/* ---- Invoice Header ---- */
.inv-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    padding: 20px 24px;
    background: linear-gradient(135deg, #1e3a8a 0%, #1e40af 100%);
    color: #fff;
    border-radius: 12px;
    margin-bottom: 20px;
}

.inv-number {
    font-size: 22px;
    font-weight: 800;
    margin: 0 0 8px 0;
    color: #fff;
}

.inv-header-meta {
    display: flex;
    gap: 20px;
    flex-wrap: wrap;
}

.inv-meta-item {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    font-size: 13px;
    color: #bfdbfe;
}

.inv-meta-item strong {
    color: #dbeafe;
}

.inv-meta-icon {
    width: 16px;
    height: 16px;
    color: #93c5fd;
}

.inv-header-right {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 6px;
}

.inv-header-right .ord-status {
    font-size: 12px;
    padding: 5px 14px;
}

.inv-due-amount {
    font-size: 18px;
    font-weight: 800;
    color: #fbbf24;
}

/* ---- Info Grid ---- */
.inv-info-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
    margin-bottom: 20px;
}

@media (max-width: 768px) {
    .inv-info-grid {
        grid-template-columns: 1fr;
    }
    .inv-header {
        flex-direction: column;
        gap: 12px;
    }
    .inv-header-right {
        align-items: flex-start;
    }
}

.inv-info-card {
    border: 1px solid #e2e8f0;
    border-radius: 10px;
    overflow: hidden;
}

.inv-info-card-header {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 16px;
    background: linear-gradient(135deg, #2563eb, #1d4ed8);
    color: #fff;
    font-size: 13px;
    font-weight: 700;
}

.inv-info-icon {
    width: 16px;
    height: 16px;
}

.inv-info-card-body {
    padding: 14px 16px;
    font-size: 13px;
    line-height: 1.6;
    color: #334155;
}

.inv-info-company {
    font-weight: 700;
    color: #1e293b;
    font-size: 14px;
}

.inv-info-light {
    color: #94a3b8;
    font-size: 12px;
}

/* ---- Line Items Section ---- */
.inv-section {
    margin-bottom: 20px;
}

.inv-section-header {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 12px 16px;
    background: linear-gradient(135deg, #1e3a8a, #1e40af);
    color: #fff;
    font-size: 14px;
    font-weight: 700;
    border-radius: 10px 10px 0 0;
}

.inv-section-icon {
    width: 18px;
    height: 18px;
}

.inv-item-count {
    margin-left: auto;
    background: rgba(255,255,255,0.2);
    padding: 2px 10px;
    border-radius: 12px;
    font-size: 11px;
    font-weight: 600;
}

/* ---- Invoice Table ---- */
.inv-table-wrap {
    overflow-x: auto;
    border: 1px solid #e2e8f0;
    border-top: none;
    border-radius: 0 0 10px 10px;
}

.inv-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 13px;
}

.inv-table thead tr {
    background: #f1f5f9;
}

.inv-table thead th {
    padding: 10px 14px;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: #475569;
    white-space: nowrap;
    border-bottom: 1px solid #e2e8f0;
    text-align: left;
}

.inv-th-product {
    min-width: 200px;
}

.inv-table tbody tr {
    border-bottom: 1px solid #f1f5f9;
    transition: background 0.1s;
}

.inv-table tbody tr:hover {
    background: #f8fafc;
}

.inv-table tbody tr:last-child {
    border-bottom: none;
}

.inv-table td {
    padding: 10px 14px;
    color: #334155;
    vertical-align: top;
}

.inv-right {
    text-align: right !important;
}

.inv-center {
    text-align: center !important;
}

/* ---- Product Link ---- */
.inv-product-link {
    font-weight: 600;
    color: #1e293b;
    text-decoration: none;
    transition: color 0.15s;
}

.inv-product-link:hover {
    color: #2563eb;
}

.inv-item-note {
    font-size: 11px;
    color: #94a3b8;
    margin-top: 3px;
    font-style: italic;
}

.inv-part-number {
    font-family: monospace;
    font-size: 12px;
    color: #64748b;
}

/* ---- Price Display ---- */
.inv-price {
    font-weight: 600;
    color: #1e293b;
}

.inv-list-price {
    display: block;
    font-size: 11px;
    color: #94a3b8;
    text-decoration: line-through;
}

.inv-line-total {
    font-weight: 700;
    color: #1e293b !important;
}

/* ---- Tracking in Table ---- */
.inv-tracking-info {
    display: flex;
    flex-direction: column;
    gap: 3px;
}

.inv-carrier-badge {
    display: inline-block;
    padding: 2px 8px;
    background: #e0e7ff;
    color: #3730a3;
    border-radius: 4px;
    font-size: 11px;
    font-weight: 600;
    width: fit-content;
}

.inv-tracking-link {
    color: #2563eb;
    text-decoration: none;
    font-size: 12px;
    font-weight: 500;
}

.inv-tracking-link:hover {
    color: #1d4ed8;
    text-decoration: underline;
}

.inv-tracking-text {
    font-size: 12px;
    color: #475569;
}

.inv-tracking-date {
    font-size: 10px;
    color: #94a3b8;
}

.inv-not-shipped {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 2px 8px;
    background: #fef3c7;
    color: #92400e;
    border-radius: 4px;
    font-size: 11px;
    font-weight: 600;
}

.inv-eta-info {
    font-size: 11px;
    color: #64748b;
    margin-top: 2px;
}

/* ---- Totals Section ---- */
.inv-totals-section {
    display: flex;
    justify-content: flex-end;
    margin-bottom: 20px;
}

.inv-totals-card {
    width: 380px;
    max-width: 100%;
    border: 1px solid #e2e8f0;
    border-radius: 10px;
    overflow: hidden;
}

.inv-totals-header {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 16px;
    background: linear-gradient(135deg, #10b981, #059669);
    color: #fff;
    font-size: 13px;
    font-weight: 700;
}

.inv-totals-icon {
    width: 16px;
    height: 16px;
}

.inv-totals-body {
    padding: 4px 0;
}

.inv-total-row {
    display: flex;
    justify-content: space-between;
    padding: 8px 20px;
    font-size: 13px;
    color: #475569;
}

.inv-total-row span:last-child {
    font-weight: 600;
    color: #1e293b;
}

.inv-savings-row {
    color: #059669;
}

.inv-savings-row span:last-child {
    color: #059669 !important;
}

.inv-discount-row {
    color: #2563eb;
}

.inv-discount-row span:last-child {
    color: #2563eb !important;
}

.inv-grand-total {
    border-top: 2px solid #e2e8f0;
    margin-top: 4px;
    padding-top: 12px;
    padding-bottom: 12px;
    font-size: 16px;
    font-weight: 800;
}

.inv-grand-total span:last-child {
    color: #1e3a8a !important;
    font-size: 18px;
}

.inv-total-due {
    background: #fef3c7;
    border-top: 1px solid #fde68a;
    padding: 10px 20px;
    font-weight: 700;
    color: #92400e;
}

.inv-total-due span:last-child {
    color: #92400e !important;
    font-size: 16px;
}

/* ---- Notes Section ---- */
.inv-notes-section {
    border: 1px solid #e2e8f0;
    border-radius: 10px;
    overflow: hidden;
    margin-bottom: 20px;
}

.inv-notes-header {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 16px;
    background: #f1f5f9;
    font-size: 13px;
    font-weight: 700;
    color: #475569;
    border-bottom: 1px solid #e2e8f0;
}

.inv-notes-body {
    padding: 14px 16px;
    font-size: 13px;
    color: #334155;
    line-height: 1.6;
    white-space: pre-wrap;
}

/* ---- Responsive ---- */
@media (max-width: 640px) {
    .ord-tabs {
        overflow-x: auto;
    }

    .ord-tab {
        padding: 8px 14px;
        font-size: 12px;
    }

    .ord-filter-row {
        flex-direction: column;
    }

    .ord-select {
        min-width: 100%;
    }

    .inv-totals-card {
        width: 100%;
    }

    .inv-table td,
    .inv-table th {
        padding: 8px 10px;
    }

    .ord-detail-container {
        margin: 0 6px 10px 6px;
    }

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

    .ord-detail-panel {
        border-right: none;
        border-bottom: 1px solid #e2e8f0;
    }

    .ord-detail-panel:last-child {
        border-bottom: none;
    }

    .ord-detail-totals-wrap {
        justify-content: stretch;
    }

    .ord-detail-totals {
        width: 100%;
    }

    .ord-detail-header {
        flex-direction: column;
        gap: 8px;
        align-items: flex-start;
    }
}
