:root {
    --primary: #15803d;
    --primary-dark: #064e3b;
    --primary-darker: #052e26;
    --primary-soft: #dcfce7;
    --primary-border: #bbf7d0;

    --cream: #f0fdf4;
    --cream-soft: #f7fee7;

    --muted: #6b7280;
    --text: #111827;
    --text-soft: #374151;
    --border: #e5e7eb;

    --danger: #dc2626;
    --warning: #b45309;
    --white: #ffffff;

    --shadow-sm: 0 6px 18px rgba(6, 78, 59, .07);
    --shadow-md: 0 10px 28px rgba(6, 78, 59, .10);
    --shadow-lg: 0 18px 45px rgba(6, 78, 59, .14);

    --radius-sm: 10px;
    --radius-md: 14px;
    --radius-lg: 18px;
    --radius-xl: 22px;

    --brown: var(--primary);
    --brown-dark: var(--primary-dark);
    --brown-darker: var(--primary-darker);
    --green-soft: var(--primary-soft);
    --green-border: var(--primary-border);
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    background: var(--cream);
    color: var(--text);
    font-family: Arial, Helvetica, sans-serif;
    font-size: 14px;
}

a {
    text-decoration: none;
}

img {
    max-width: 100%;
}

/* =========================================================
   NAVBAR & APP LAYOUT
========================================================= */

.navbar,
.app-navbar {
    background: linear-gradient(135deg, var(--primary-darker), var(--primary-dark)) !important;
    min-height: 58px;
    box-shadow: 0 6px 20px rgba(5, 46, 38, .16);
}

.navbar-brand,
.app-brand {
    font-weight: 900;
    letter-spacing: -.3px;
}

.app-container {
    width: 100%;
}

.app-shell {
    align-items: stretch;
}

.app-main {
    padding: 24px;
    min-width: 0;
}

.app-mobile-top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
}

.app-desktop-userbar {
    margin-left: auto;
    display: flex;
    align-items: center;
    gap: 12px;
}

.app-usertext {
    white-space: nowrap;
}

.app-menu-toggle,
.app-mobile-userbox,
.app-drawer-overlay {
    display: none;
}

/* =========================================================
   SIDEBAR
========================================================= */

.sidebar,
.app-sidebar {
    min-height: calc(100vh - 56px);
    background: linear-gradient(180deg, var(--primary-darker), var(--primary-dark));
    color: white;
    padding: 18px 14px;
    box-shadow: 8px 0 24px rgba(5, 46, 38, .12);
}

.app-menu-scroll {
    width: 100%;
}

.sidebar a,
.app-sidebar a {
    color: #d1fae5;
    display: flex;
    align-items: center;
    min-height: 42px;
    padding: 10px 14px;
    text-decoration: none;
    border-radius: 13px;
    margin-bottom: 7px;
    font-size: 14px;
    font-weight: 800;
    transition: .15s ease;
}

.sidebar a:hover,
.sidebar a.active,
.app-sidebar a:hover,
.app-sidebar a.active {
    background: rgba(255, 255, 255, .14);
    color: white;
    transform: translateX(2px);
}

/* =========================================================
   GLOBAL COMPONENTS
========================================================= */

.card {
    border: 0;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-md);
    background: var(--white);
}

.card.p-3 {
    padding: 18px !important;
}

.btn {
    border-radius: 11px;
    font-weight: 800;
}

.btn-sm {
    border-radius: 9px;
    font-size: 12px;
}

.btn-lg {
    border-radius: 13px;
    font-weight: 900;
}

.btn-brown,
.btn-green,
.btn-primary {
    background: var(--primary) !important;
    color: #ffffff !important;
    border: 1px solid var(--primary) !important;
}

.btn-brown:hover,
.btn-green:hover,
.btn-primary:hover {
    background: var(--primary-dark) !important;
    border-color: var(--primary-dark) !important;
    color: #ffffff !important;
}

.btn-outline-secondary {
    border-color: #d1d5db;
    color: var(--text-soft);
}

.btn-outline-secondary:hover {
    background: var(--primary);
    border-color: var(--primary);
    color: #ffffff;
}

.btn-outline-danger {
    border-radius: 11px;
}

.form-control,
.form-select {
    border-radius: 12px;
    border-color: #d1d5db;
    min-height: 40px;
    font-size: 14px;
}

.form-control:focus,
.form-select:focus {
    border-color: #22c55e;
    box-shadow: 0 0 0 .22rem rgba(34, 197, 94, .15);
}

.form-label {
    font-size: 13px;
    font-weight: 800;
    color: var(--text-soft);
    margin-bottom: 6px;
}

.table {
    margin-bottom: 0;
}

.table th {
    color: var(--muted);
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: .04em;
    font-weight: 900;
    border-bottom-color: #e5e7eb;
}

.table td {
    vertical-align: middle;
    color: var(--text-soft);
}

.badge {
    border-radius: 999px;
    padding: 6px 9px;
    font-size: 11px;
}

.badge-green-soft {
    background: var(--primary-soft);
    color: #166534;
}

.text-success {
    color: #047857 !important;
}

.bg-success {
    background-color: #047857 !important;
}

.alert {
    border: 0;
    border-radius: 14px;
    box-shadow: var(--shadow-sm);
}

.alert-success {
    background: #dcfce7;
    color: #166534;
}

.alert-danger {
    background: #fee2e2;
    color: #991b1b;
}

.alert-warning {
    background: #fef3c7;
    color: #92400e;
}

.modal-content {
    border: 0;
    border-radius: 20px;
    box-shadow: 0 22px 60px rgba(6, 78, 59, .22);
}

.modal-header {
    border-bottom: 1px solid #eef2f7;
    padding: 18px 20px;
}

.modal-title {
    font-weight: 900;
}

.modal-body {
    padding: 20px;
}

.modal-footer {
    border-top: 1px solid #eef2f7;
    padding: 14px 20px;
}

.empty-state {
    text-align: center;
    padding: 34px 20px;
    color: #6b7280;
}

.empty-state strong {
    display: block;
    color: #111827;
    font-size: 16px;
    margin-bottom: 4px;
}

.simple-footer {
    width: 100%;
    padding: 14px 16px 20px;
    margin-top: 20px;
    border-top: 1px solid rgba(6, 78, 59, .12);
    color: var(--muted);
    font-size: 12px;
    line-height: 1.5;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 7px;
    flex-wrap: wrap;
    text-align: center;
}

.footer-separator {
    color: #9ca3af;
}

/* =========================================================
   SCROLLBAR
========================================================= */

::-webkit-scrollbar {
    width: 9px;
    height: 9px;
}

::-webkit-scrollbar-track {
    background: #ecfdf5;
}

::-webkit-scrollbar-thumb {
    background: #86efac;
    border-radius: 999px;
}

::-webkit-scrollbar-thumb:hover {
    background: #22c55e;
}

/* =========================================================
   OWNER DASHBOARD
========================================================= */

.owner-page {
    width: 100%;
}

.owner-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 16px;
    margin-bottom: 18px;
}

.owner-header h3 {
    margin: 0;
    font-size: 26px;
    font-weight: 900;
    color: var(--text);
}

.owner-header p {
    margin: 5px 0 0;
    color: var(--muted);
    font-size: 14px;
}

.owner-header-btn {
    min-width: 120px;
}

.owner-summary {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 14px;
    margin-bottom: 16px;
}

.owner-stat-card,
.stat-card {
    border-radius: var(--radius-lg);
    background: linear-gradient(135deg, #ffffff, #f7fee7);
}

.owner-stat-card small,
.stat-card small {
    display: block;
    font-size: 12px;
    font-weight: 800;
    margin-bottom: 6px;
}

.owner-stat-card h3,
.stat-card h3 {
    margin: 0;
    font-size: 24px;
    line-height: 1.2;
    word-break: break-word;
    font-weight: 900;
    color: var(--text);
}

.owner-grid {
    display: grid;
    grid-template-columns: minmax(0, 1.4fr) minmax(0, .9fr);
    gap: 14px;
}

.owner-card {
    min-width: 0;
}

.owner-card-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    margin-bottom: 10px;
}

.owner-card-header h5 {
    margin: 0;
    font-size: 17px;
    font-weight: 900;
    color: var(--text);
}

.owner-recent-card {
    margin-top: 14px;
}

.owner-table-responsive {
    border-radius: 14px;
}

.owner-table th,
.owner-table td {
    white-space: nowrap;
}

/* =========================================================
   POS CASHIER
========================================================= */

.pos-page {
    width: 100%;
}

.pos-header {
    margin-bottom: 14px;
}

.pos-header h3 {
    font-size: 24px;
    font-weight: 900;
    margin: 0;
    color: #111827;
}

.pos-header p {
    margin: 4px 0 0;
    color: #6b7280;
    font-size: 14px;
}

.pos-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 340px;
    gap: 16px;
    align-items: start;
}

.pos-left,
.pos-right {
    min-width: 0;
}

.pos-card {
    background: #ffffff;
    border-radius: 18px;
    padding: 14px;
    box-shadow: 0 8px 22px rgba(6, 78, 59, .08);
}

.pos-toolbar {
    display: grid;
    gap: 10px;
    margin-bottom: 10px;
}

.search-box,
.product-search,
.category-search,
.stock-search {
    position: relative;
}

.search-box span,
.product-search span,
.category-search span,
.stock-search span {
    position: absolute;
    left: 13px;
    top: 50%;
    transform: translateY(-50%);
    color: #6b7280;
    font-size: 16px;
}

.search-box input,
.product-search input,
.category-search input,
.stock-search input {
    width: 100%;
    height: 42px;
    border: 1px solid #d1d5db;
    border-radius: 12px;
    padding: 0 14px 0 38px;
    outline: none;
    font-size: 14px;
}

.search-box input:focus,
.product-search input:focus,
.category-search input:focus,
.stock-search input:focus {
    border-color: #059669;
    box-shadow: 0 0 0 3px rgba(5, 150, 105, .10);
}

.category-wrap {
    display: flex;
    gap: 7px;
    overflow-x: auto;
    padding: 1px 1px 8px;
    scrollbar-width: thin;
}

.category-filter {
    border: 1px solid #bbf7d0;
    background: #f7fee7;
    color: #166534;
    border-radius: 999px;
    padding: 6px 10px;
    font-weight: 800;
    font-size: 12px;
    white-space: nowrap;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    line-height: 1;
}

.category-filter .count {
    background: #ffffff;
    color: #047857;
    border-radius: 999px;
    min-width: 18px;
    height: 18px;
    padding: 0 5px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 10px;
}

.category-filter.active {
    background: #047857;
    color: #ffffff;
    border-color: #047857;
}

.category-filter.active .count {
    background: #dcfce7;
    color: #047857;
}

.product-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 10px;
}

.product-item {
    min-width: 0;
}

.product-card-pos {
    border: 1px solid rgba(6, 78, 59, .08);
    background: #ffffff;
    border-radius: 16px;
    overflow: hidden;
    cursor: pointer;
    height: 100%;
    box-shadow: 0 5px 14px rgba(6, 78, 59, .06);
    transition: .14s ease;
}

.product-card-pos:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 24px rgba(6, 78, 59, .11);
}

.product-card-pos img {
    width: calc(100% - 12px);
    height: 92px;
    object-fit: cover;
    border-radius: 12px;
    margin: 6px 6px 0;
    background: #dcfce7;
}

.product-body {
    padding: 8px 9px 10px;
}

.product-category {
    color: #6b7280;
    font-size: 10px;
    line-height: 1.2;
}

.product-title {
    min-height: 32px;
    margin: 3px 0 6px;
    font-weight: 900;
    font-size: 13px;
    line-height: 1.2;
    color: #111827;
}

.product-meta {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 6px;
    margin-bottom: 8px;
}

.product-price {
    color: #047857;
    font-weight: 900;
    font-size: 14px;
}

.product-stock {
    color: #4b5563;
    font-size: 11px;
}

.product-stock.low {
    color: #dc2626;
    font-weight: 900;
}

.qty-control {
    display: grid;
    grid-template-columns: 30px 1fr 30px;
    border: 1px solid #e5e7eb;
    background: #f9fafb;
    border-radius: 10px;
    overflow: hidden;
}

.qty-control button {
    border: 0;
    background: #ffffff;
    color: #047857;
    font-weight: 900;
    font-size: 15px;
    height: 30px;
}

.qty-control input {
    width: 100%;
    border: 0;
    height: 30px;
    text-align: center;
    background: #f9fafb;
    font-weight: 900;
    font-size: 13px;
}

.cart-panel {
    position: sticky;
    top: 74px;
}

.cart-title {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
}

.cart-title h5 {
    font-size: 18px;
    margin: 0;
    font-weight: 900;
}

.cart-title .btn {
    padding: 4px 9px;
    font-size: 12px;
}

.cart-list {
    min-height: 58px;
    max-height: 205px;
    overflow-y: auto;
    padding: 9px;
    border: 1px solid #d9f99d;
    background: #f7fee7;
    border-radius: 14px;
    color: #6b7280;
    font-size: 12px;
}

.cart-line {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 96px;
    gap: 8px;
    padding: 8px 0;
    border-bottom: 1px dashed #bbf7d0;
    color: #111827;
}

.cart-line:last-child {
    border-bottom: 0;
}

.cart-info strong {
    display: block;
    font-size: 12px;
    line-height: 1.25;
}

.cart-info span {
    display: block;
    font-size: 10px;
    color: #6b7280;
    margin-top: 2px;
}

.cart-subtotal {
    font-size: 11px;
    font-weight: 900;
    color: #047857;
    margin-top: 3px;
}

.cart-qty-wrap {
    display: grid;
    grid-template-columns: 24px 1fr 24px;
    align-items: center;
    height: 30px;
    border: 1px solid #bbf7d0;
    border-radius: 9px;
    overflow: hidden;
    background: #ffffff;
}

.cart-qty-wrap button {
    height: 30px;
    border: 0;
    background: #ffffff;
    color: #047857;
    font-weight: 900;
    font-size: 13px;
}

.cart-qty-wrap input {
    height: 30px;
    border: 0;
    text-align: center;
    font-weight: 900;
    background: #f7fee7;
    width: 100%;
    font-size: 12px;
}

.total-box,
.pos-total-box {
    background: linear-gradient(135deg, #052e26, #047857);
    color: #ffffff;
    border-radius: 16px;
    padding: 13px;
    margin: 10px 0;
}

.total-box small,
.pos-total-box small {
    color: #d1fae5;
    font-size: 11px;
}

.total-box h5,
.pos-total-box h5 {
    margin: 2px 0 9px;
    font-size: 15px;
}

.total-box h2,
.pos-total-box h2 {
    margin: 2px 0 0;
    font-size: 26px;
    font-weight: 900;
}

.discount-row {
    display: grid;
    grid-template-columns: 44px 52px 52px 1fr;
    gap: 6px;
}

.soft-btn,
.quick-pay,
.payment-btn {
    border: 1px solid #bbf7d0;
    background: #f7fee7;
    color: #166534;
    border-radius: 10px;
    padding: 7px 8px;
    font-weight: 900;
    font-size: 12px;
}

.soft-btn:hover,
.quick-pay:hover {
    background: #dcfce7;
}

.payment-tabs {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 5px;
    padding: 5px;
    background: #ecfdf5;
    border: 1px solid #bbf7d0;
    border-radius: 12px;
}

.payment-btn {
    border: 0;
    background: transparent;
}

.payment-btn.active {
    background: #047857;
    color: #ffffff;
}

.quick-pay-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 6px;
}

#paid {
    font-size: 16px;
    font-weight: 900;
    height: 38px;
}

.change-box {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border: 1px solid #bbf7d0;
    background: #f7fee7;
    border-radius: 13px;
    padding: 10px 12px;
    margin-top: 10px;
    font-size: 13px;
}

.change-box strong {
    color: #047857;
    font-size: 16px;
}

/* =========================================================
   CATEGORIES / PRODUCTS / STOCK SHARED
========================================================= */

.category-page,
.product-page,
.stock-page {
    width: 100%;
}

.category-header,
.product-header,
.stock-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 16px;
    margin-bottom: 16px;
}

.category-header h3,
.product-header h3,
.stock-header h3 {
    margin: 0;
    font-size: 26px;
    font-weight: 900;
    color: #111827;
}

.category-header p,
.product-header p,
.stock-header p {
    margin: 5px 0 0;
    color: #6b7280;
    font-size: 14px;
}

.category-card,
.product-card,
.stock-card {
    background: #ffffff;
    border-radius: 18px;
    padding: 16px;
    box-shadow: 0 8px 22px rgba(6, 78, 59, .08);
}

.category-toolbar,
.product-toolbar,
.stock-toolbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 14px;
    margin-bottom: 14px;
}

.category-search,
.product-search {
    max-width: 360px;
    width: 100%;
}

.stock-search {
    max-width: 420px;
    width: 100%;
}

.category-table,
.product-table,
.stock-table {
    width: 100%;
    margin: 0;
    border-collapse: separate;
    border-spacing: 0 8px;
}

.category-table thead th,
.product-table thead th,
.stock-table thead th {
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: .04em;
    color: #6b7280;
    font-weight: 900;
    padding: 8px 12px;
    border: 0;
    white-space: nowrap;
}

.category-table tbody tr,
.product-table tbody tr,
.stock-table tbody tr {
    background: #f9fafb;
    border-radius: 14px;
}

.category-table tbody td,
.product-table tbody td,
.stock-table tbody td {
    padding: 12px;
    vertical-align: middle;
    border-top: 1px solid #eef2f7;
    border-bottom: 1px solid #eef2f7;
    font-size: 13px;
}

.category-table tbody td:first-child,
.product-table tbody td:first-child,
.stock-table tbody td:first-child {
    border-left: 1px solid #eef2f7;
    border-top-left-radius: 14px;
    border-bottom-left-radius: 14px;
}

.category-table tbody td:last-child,
.product-table tbody td:last-child,
.stock-table tbody td:last-child {
    border-right: 1px solid #eef2f7;
    border-top-right-radius: 14px;
    border-bottom-right-radius: 14px;
}

.category-table tbody tr.is-restock {
    background: #fff7f7;
}

.category-table tbody tr.is-restock td {
    border-top-color: #fecaca;
    border-bottom-color: #fecaca;
}

.category-name,
.product-name,
.stock-product {
    font-weight: 900;
    color: #111827;
}

.category-desc,
.product-category,
.stock-category,
.stock-note {
    color: #6b7280;
}

.category-desc {
    max-width: 420px;
}

.category-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 34px;
    height: 26px;
    padding: 0 9px;
    border-radius: 999px;
    background: #dcfce7;
    color: #047857;
    font-size: 12px;
    font-weight: 900;
    white-space: nowrap;
}

.category-badge-muted {
    background: #e5e7eb;
    color: #374151;
}

.category-badge-warning {
    background: #fef3c7;
    color: #92400e;
}

.category-badge-danger {
    background: #fee2e2;
    color: #b91c1c;
}

.category-badge-empty {
    background: #f3f4f6;
    color: #6b7280;
}

.category-date,
.stock-date {
    color: #6b7280;
    font-size: 12px;
    white-space: nowrap;
}

.product-image {
    width: 54px;
    height: 54px;
    border-radius: 12px;
    object-fit: cover;
    background: #dcfce7;
}

.product-image-placeholder {
    width: 54px;
    height: 54px;
    border-radius: 12px;
    background: #dcfce7;
    color: #047857;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 22px;
}

.status-badge,
.badge-type {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 72px;
    height: 26px;
    padding: 0 9px;
    border-radius: 999px;
    font-size: 11px;
    font-weight: 900;
}

.status-active,
.badge-in {
    background: #dcfce7;
    color: #047857;
}

.status-inactive {
    background: #e5e7eb;
    color: #374151;
}

.badge-out {
    background: #fee2e2;
    color: #b91c1c;
}

.badge-adjustment {
    background: #dbeafe;
    color: #1d4ed8;
}

.btn-edit {
    border: 1px solid #fde68a;
    background: #fffbeb;
    color: #92400e;
    border-radius: 10px;
    padding: 6px 10px;
    font-size: 12px;
    font-weight: 900;
}

.btn-edit:hover {
    background: #fef3c7;
    color: #92400e;
}

.image-preview {
    width: 74px;
    height: 74px;
    border-radius: 14px;
    object-fit: cover;
    background: #dcfce7;
    border: 1px solid #bbf7d0;
}

.stock-summary {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 12px;
    margin-bottom: 16px;
}

.summary-card {
    background: #ffffff;
    border-radius: 16px;
    padding: 14px;
    box-shadow: 0 8px 22px rgba(6, 78, 59, .08);
}

.summary-card span {
    display: block;
    color: #6b7280;
    font-size: 12px;
    font-weight: 800;
    margin-bottom: 4px;
}

.summary-card strong {
    display: block;
    color: #111827;
    font-size: 24px;
    font-weight: 900;
    line-height: 1.2;
}

.summary-card.danger strong {
    color: #dc2626;
}

.summary-card.warning strong {
    color: #b45309;
}

.stock-number {
    font-weight: 900;
    color: #111827;
}

.stock-before {
    color: #6b7280;
}

.stock-after {
    color: #047857;
}

.stock-help {
    color: #6b7280;
    font-size: 12px;
    margin-top: 5px;
}

.product-stock-info {
    margin-top: 8px;
    padding: 10px 12px;
    border-radius: 12px;
    background: #f0fdf4;
    border: 1px solid #bbf7d0;
    color: #047857;
    font-size: 13px;
    font-weight: 800;
    display: none;
}

/* =========================================================
   SALES REPORT PAGE
========================================================= */

.report-page {
    width: 100%;
}

.report-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 16px;
    margin-bottom: 18px;
}

.report-header h3 {
    margin: 0;
    font-size: 28px;
    font-weight: 900;
    color: var(--text);
}

.report-header p {
    margin: 5px 0 0;
    color: var(--muted);
    font-size: 14px;
}

.report-print-btn {
    min-width: 110px;
}

.report-filter-card {
    margin-bottom: 14px;
}

.report-filter-form {
    display: grid;
    grid-template-columns: 220px 220px 140px;
    gap: 12px;
    align-items: end;
}

.report-filter-group,
.report-filter-action {
    min-width: 0;
}

.report-summary {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 14px;
    margin-bottom: 14px;
}

.report-summary-card {
    border: 1px solid #dbe5df !important;
    border-radius: 0 !important;
    box-shadow: none !important;
    background: #ffffff !important;
}

.report-summary-card small {
    display: block;
    font-size: 12px;
    font-weight: 900;
    margin-bottom: 6px;
    color: #374151;
}

.report-summary-card h3 {
    font-size: 24px;
    line-height: 1.2;
    margin-bottom: 0;
    word-break: break-word;
    color: #111827;
}

.report-table-card {
    border: 1px solid #dbe5df !important;
    border-radius: 0 !important;
    box-shadow: none !important;
    background: #ffffff !important;
}

.report-card-header {
    display: grid;
    gap: 2px;
    margin-bottom: 10px;
}

.report-card-header h5 {
    margin: 0;
    font-size: 17px;
    font-weight: 900;
    color: var(--text);
}

.report-card-header small {
    font-size: 12px;
    color: var(--muted);
}

.report-table {
    margin-bottom: 0;
}

.report-table th,
.report-table td {
    white-space: nowrap;
    border: 1px solid #dbe5df;
    font-size: 12px;
    vertical-align: middle;
}

.report-table th {
    background: #f8fafc;
    color: #111827;
    font-weight: 900;
}

.report-table td strong {
    color: #111827;
}

.report-items-sold {
    display: block;
    max-width: 260px;
    white-space: normal;
    line-height: 1.35;
    color: var(--text-soft);
    font-size: 12px;
}

/* =========================================================
   GLOBAL PAGINATION GREEN
========================================================= */

.pagination {
    --bs-pagination-color: #064e3b !important;
    --bs-pagination-bg: #f7fee7 !important;
    --bs-pagination-border-color: #bbf7d0 !important;
    --bs-pagination-hover-color: #052e26 !important;
    --bs-pagination-hover-bg: #dcfce7 !important;
    --bs-pagination-hover-border-color: #15803d !important;
    --bs-pagination-focus-color: #052e26 !important;
    --bs-pagination-focus-bg: #dcfce7 !important;
    --bs-pagination-active-color: #ffffff !important;
    --bs-pagination-active-bg: #15803d !important;
    --bs-pagination-active-border-color: #15803d !important;
    --bs-pagination-disabled-color: #9ca3af !important;
    --bs-pagination-disabled-bg: #f3f4f6 !important;
    --bs-pagination-disabled-border-color: #e5e7eb !important;
}

.app-pagination {
    width: 100% !important;
    margin-top: 18px !important;
    display: flex !important;
    justify-content: center !important;
}

.app-pagination .pagination {
    display: flex !important;
    flex-wrap: wrap !important;
    justify-content: center !important;
    align-items: center !important;
    gap: 7px !important;
    margin: 0 !important;
    padding: 0 !important;
}

.app-pagination .page-link,
.pagination .page-link {
    min-width: 40px !important;
    min-height: 38px !important;
    padding: 8px 13px !important;
    border-radius: 12px !important;
    background-color: #f7fee7 !important;
    border-color: #bbf7d0 !important;
    color: #064e3b !important;
    font-size: 13px !important;
    font-weight: 900 !important;
    line-height: 1.2 !important;
    text-align: center !important;
    text-decoration: none !important;
    box-shadow: none !important;
}

.app-pagination .page-link:hover,
.pagination .page-link:hover {
    background-color: #dcfce7 !important;
    border-color: #15803d !important;
    color: #052e26 !important;
}

.app-pagination .page-item.active .page-link,
.pagination .page-item.active .page-link,
.page-item.active .page-link {
    background: linear-gradient(135deg, #064e3b, #15803d) !important;
    background-color: #15803d !important;
    border-color: #15803d !important;
    color: #ffffff !important;
    box-shadow: 0 8px 18px rgba(6, 78, 59, .18) !important;
}

.app-pagination .page-item.disabled .page-link,
.pagination .page-item.disabled .page-link,
.page-item.disabled .page-link {
    background-color: #f3f4f6 !important;
    border-color: #e5e7eb !important;
    color: #9ca3af !important;
    box-shadow: none !important;
    pointer-events: none !important;
}

/* =========================================================
   RESPONSIVE TABLET
========================================================= */

@media screen and (max-width: 1400px) {
    .product-grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }

    .pos-layout {
        grid-template-columns: minmax(0, 1fr) 330px;
    }
}

@media screen and (max-width: 1100px) {
    .pos-layout {
        grid-template-columns: 1fr;
    }

    .cart-panel {
        position: static;
    }

    .product-grid {
        grid-template-columns: repeat(4, minmax(0, 1fr));
    }
}

@media screen and (max-width: 992px) {
    .sidebar {
        min-height: auto;
        padding: 12px;
    }

    .sidebar a {
        min-height: 40px;
        font-size: 13px;
    }

    .card.p-3 {
        padding: 14px !important;
    }

    .owner-summary,
    .stock-summary {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .owner-grid {
        grid-template-columns: 1fr;
    }

    .report-filter-form {
        grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    }

    .report-filter-action {
        grid-column: span 2 !important;
    }
}

@media screen and (max-width: 900px) {
    .product-grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
}
/* =========================================================
   RESPONSIVE MOBILE FINAL
   Desktop dan tablet tidak diubah
========================================================= */

@media screen and (max-width: 768px) {
    html,
    body {
        width: 100%;
        max-width: 100%;
        overflow-x: hidden;
    }

    body {
        font-size: 13px;
        background: var(--cream);
    }

    .card {
        border-radius: 16px;
    }

    .card.p-3 {
        padding: 14px !important;
    }

    .btn,
    .form-control,
    .form-select {
        font-size: 13px;
    }

    .table-responsive {
        border-radius: 14px;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }

    .table {
        min-width: 680px;
    }

    .table th,
    .table td {
        white-space: nowrap;
        font-size: 12px;
        padding: 10px;
    }
}

/* =========================================================
   MOBILE DRAWER + SAFE GUTTER
========================================================= */

@media screen and (min-width: 577px) {
    .app-mobile-userbox,
    .app-drawer-overlay {
        display: none !important;
    }
}

@media screen and (max-width: 576px) {
    html,
    body {
        width: 100% !important;
        max-width: 100% !important;
        overflow-x: hidden !important;
        background: var(--cream) !important;
        font-size: 13px !important;
    }

    body.drawer-open {
        overflow: hidden !important;
    }

    .app-container,
    .container,
    .container-fluid {
        width: 100% !important;
        max-width: 100% !important;
        padding-left: 12px !important;
        padding-right: 12px !important;
        margin-left: auto !important;
        margin-right: auto !important;
        overflow-x: hidden !important;
    }

    .app-shell,
    .row {
        width: 100% !important;
        max-width: 100% !important;
        margin-left: 0 !important;
        margin-right: 0 !important;
        display: block !important;
    }

    .app-shell > *,
    .row > * {
        width: 100% !important;
        max-width: 100% !important;
        padding-left: 0 !important;
        padding-right: 0 !important;
    }

    .app-main,
    main,
    .main-content,
    .content {
        width: 100% !important;
        max-width: 100% !important;
        padding: 14px 0 24px !important;
        margin: 0 !important;
        overflow-x: hidden !important;
    }

    .navbar,
    .app-navbar {
        position: sticky !important;
        top: 0 !important;
        z-index: 1040 !important;
        min-height: auto !important;
        padding: 13px 12px !important;
        background: linear-gradient(135deg, #052e26, #064e3b) !important;
        box-shadow: 0 6px 18px rgba(5, 46, 38, .16) !important;
    }

    .navbar .container-fluid,
    .app-navbar-inner {
        width: 100% !important;
        max-width: 100% !important;
        padding-left: 0 !important;
        padding-right: 0 !important;
        margin: 0 !important;
    }

    .app-mobile-top {
        display: flex !important;
        align-items: center !important;
        justify-content: space-between !important;
        width: 100% !important;
        gap: 12px !important;
    }

    .navbar-brand,
    .app-brand {
        margin: 0 !important;
        padding: 0 !important;
        max-width: calc(100% - 56px) !important;
        font-size: 16px !important;
        font-weight: 900 !important;
        color: #ffffff !important;
        line-height: 1.2 !important;
        white-space: nowrap !important;
        overflow: hidden !important;
        text-overflow: ellipsis !important;
    }

    .app-desktop-userbar {
        display: none !important;
    }

    .app-menu-toggle {
        display: inline-flex !important;
        align-items: center !important;
        justify-content: center !important;
        width: 42px !important;
        height: 38px !important;
        min-width: 42px !important;
        padding: 0 !important;
        border-radius: 12px !important;
        border: 1px solid rgba(255, 255, 255, .28) !important;
        background: rgba(255, 255, 255, .10) !important;
        color: #ffffff !important;
        font-size: 18px !important;
        font-weight: 900 !important;
        line-height: 1 !important;
        z-index: 1061 !important;
    }

    .app-drawer-overlay {
        display: block !important;
        position: fixed !important;
        inset: 0 !important;
        background: rgba(15, 23, 42, .48) !important;
        opacity: 0 !important;
        visibility: hidden !important;
        pointer-events: none !important;
        transition: .22s ease !important;
        z-index: 1050 !important;
    }

    .app-drawer-overlay.is-open {
        opacity: 1 !important;
        visibility: visible !important;
        pointer-events: auto !important;
    }

    .sidebar,
    .app-sidebar {
        position: fixed !important;
        top: 0 !important;
        right: 0 !important;
        left: auto !important;
        width: 82% !important;
        max-width: 320px !important;
        height: 100vh !important;
        min-height: 100vh !important;
        padding: 18px 14px !important;
        overflow-y: auto !important;
        overflow-x: hidden !important;
        background: linear-gradient(180deg, #052e26, #065f46) !important;
        box-shadow: -18px 0 40px rgba(0, 0, 0, .25) !important;
        transform: translateX(105%) !important;
        transition: transform .24s ease !important;
        z-index: 1060 !important;
    }

    .sidebar.is-open,
    .app-sidebar.is-open {
        transform: translateX(0) !important;
    }

    .app-mobile-userbox {
        display: grid !important;
        gap: 10px !important;
        margin: 44px 0 14px !important;
        padding: 14px !important;
        border-radius: 16px !important;
        border: 1px solid rgba(255, 255, 255, .14) !important;
        background: rgba(255, 255, 255, .08) !important;
    }

    .app-mobile-usertext {
        color: #d1fae5 !important;
        font-size: 13px !important;
        font-weight: 900 !important;
        line-height: 1.35 !important;
        overflow-wrap: anywhere !important;
    }

    .app-mobile-logout {
        display: inline-flex !important;
        align-items: center !important;
        justify-content: center !important;
        min-height: 38px !important;
        width: 100% !important;
        border-radius: 12px !important;
        border: 1px solid rgba(255, 255, 255, .32) !important;
        background: rgba(255, 255, 255, .08) !important;
        color: #ffffff !important;
        font-size: 12px !important;
        font-weight: 900 !important;
        text-decoration: none !important;
    }

    .app-menu-scroll {
        display: grid !important;
        gap: 8px !important;
        width: 100% !important;
    }

    .sidebar a,
    .app-sidebar a {
        width: 100% !important;
        min-height: 44px !important;
        margin: 0 !important;
        padding: 12px 14px !important;
        border-radius: 13px !important;
        background: rgba(255, 255, 255, .08) !important;
        color: #ecfdf5 !important;
        font-size: 13px !important;
        font-weight: 900 !important;
        line-height: 1.2 !important;
        transform: none !important;
    }

    .sidebar a.active,
    .app-sidebar a.active {
        background: #ffffff !important;
        color: #047857 !important;
    }

    .owner-header,
    .pos-header,
    .category-header,
    .product-header,
    .stock-header,
    .report-header {
        display: grid !important;
        grid-template-columns: 1fr !important;
        gap: 10px !important;
        margin-bottom: 14px !important;
    }

    .owner-header h3,
    .pos-header h3,
    .category-header h3,
    .product-header h3,
    .stock-header h3,
    .report-header h3 {
        font-size: 21px !important;
        line-height: 1.25 !important;
        margin: 0 !important;
    }

    .owner-header p,
    .pos-header p,
    .category-header p,
    .product-header p,
    .stock-header p,
    .report-header p {
        font-size: 13px !important;
        line-height: 1.45 !important;
        margin-top: 4px !important;
    }

    .btn-green,
    .btn-brown,
    .report-print-btn,
    .owner-header-btn,
    .category-header .btn-green,
    .product-header .btn-green,
    .stock-header .btn-green {
        width: 100% !important;
        min-height: 42px !important;
        display: inline-flex !important;
        align-items: center !important;
        justify-content: center !important;
        font-size: 13px !important;
        border-radius: 12px !important;
    }

    .card,
    .pos-card,
    .category-card,
    .product-card,
    .stock-card,
    .report-table-card,
    .report-filter-card,
    .owner-card {
        width: 100% !important;
        max-width: 100% !important;
        padding: 12px !important;
        border-radius: 16px !important;
        overflow: hidden !important;
        box-shadow: 0 6px 18px rgba(6, 78, 59, .07) !important;
    }

    .owner-summary,
    .stock-summary,
    .report-summary {
        display: grid !important;
        grid-template-columns: 1fr !important;
        gap: 10px !important;
        margin-bottom: 12px !important;
    }

    .owner-stat-card,
    .summary-card,
    .report-summary-card {
        padding: 14px !important;
        border-radius: 16px !important;
    }

    .owner-stat-card h3,
    .summary-card strong,
    .report-summary-card h3 {
        font-size: 22px !important;
        line-height: 1.2 !important;
    }

    .pos-layout {
        display: grid !important;
        grid-template-columns: 1fr !important;
        gap: 12px !important;
        width: 100% !important;
    }

    .pos-left,
    .pos-right {
        width: 100% !important;
        min-width: 0 !important;
    }

    .pos-toolbar {
        gap: 9px !important;
    }

    .search-box input,
    .product-search input,
    .category-search input,
    .stock-search input {
        height: 40px !important;
        font-size: 13px !important;
        border-radius: 12px !important;
    }

    .category-wrap {
        display: flex !important;
        gap: 7px !important;
        overflow-x: auto !important;
        overflow-y: hidden !important;
        white-space: nowrap !important;
        padding-bottom: 7px !important;
        scrollbar-width: none !important;
    }

    .category-wrap::-webkit-scrollbar {
        display: none !important;
    }

    .category-filter {
        flex: 0 0 auto !important;
        min-height: 32px !important;
        padding: 7px 10px !important;
        font-size: 11px !important;
    }

    .product-grid {
        display: grid !important;
        grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
        gap: 9px !important;
    }

    .product-card-pos {
        border-radius: 15px !important;
    }

    .product-card-pos img {
        width: calc(100% - 10px) !important;
        height: 76px !important;
        margin: 5px 5px 0 !important;
        border-radius: 11px !important;
    }

    .product-body {
        padding: 7px 8px 9px !important;
    }

    .product-title {
        min-height: 30px !important;
        font-size: 12px !important;
        line-height: 1.25 !important;
    }

    .product-meta {
        display: grid !important;
        grid-template-columns: 1fr !important;
        gap: 2px !important;
    }

    .product-price {
        font-size: 13px !important;
    }

    .product-stock {
        font-size: 10px !important;
    }

    .qty-control {
        grid-template-columns: 28px 1fr 28px !important;
    }

    .qty-control button,
    .qty-control input {
        height: 29px !important;
        font-size: 12px !important;
    }

    .cart-panel {
        position: static !important;
        top: auto !important;
    }

    .cart-list {
        max-height: 210px !important;
        min-height: 58px !important;
        font-size: 12px !important;
    }

    .cart-line {
        display: grid !important;
        grid-template-columns: 1fr !important;
        gap: 8px !important;
    }

    .cart-qty-wrap {
        width: 112px !important;
    }

    .total-box,
    .pos-total-box {
        padding: 12px !important;
        border-radius: 15px !important;
    }

    .total-box h2,
    .pos-total-box h2 {
        font-size: 24px !important;
    }

    .discount-row {
        display: grid !important;
        grid-template-columns: repeat(3, 1fr) !important;
        gap: 6px !important;
    }

    .discount-row input {
        grid-column: span 3 !important;
    }

    .quick-pay-grid {
        grid-template-columns: repeat(3, 1fr) !important;
        gap: 6px !important;
    }

    .category-toolbar,
    .product-toolbar,
    .stock-toolbar {
        display: grid !important;
        grid-template-columns: 1fr !important;
        gap: 10px !important;
    }

    .category-search,
    .product-search,
    .stock-search {
        max-width: 100% !important;
    }

    .category-card .table-responsive,
    .product-card .table-responsive,
    .stock-card .table-responsive,
    .report-table-card .table-responsive {
        overflow: visible !important;
        border-radius: 0 !important;
    }

    .category-table,
    .product-table,
    .stock-table,
    .report-table {
        width: 100% !important;
        min-width: 0 !important;
        border-spacing: 0 !important;
    }

    .category-table thead,
    .product-table thead,
    .stock-table thead,
    .report-table thead {
        display: none !important;
    }

    .category-table,
    .category-table tbody,
    .category-table tr,
    .category-table td,
    .product-table,
    .product-table tbody,
    .product-table tr,
    .product-table td,
    .stock-table,
    .stock-table tbody,
    .stock-table tr,
    .stock-table td,
    .report-table,
    .report-table tbody,
    .report-table tr,
    .report-table td {
        display: block !important;
        width: 100% !important;
    }

    .category-table tbody tr,
    .product-table tbody tr,
    .stock-table tbody tr,
    .report-table tbody tr {
        margin-bottom: 12px !important;
        padding: 12px !important;
        border: 1px solid #e5e7eb !important;
        border-radius: 16px !important;
        background: #ffffff !important;
        box-shadow: 0 6px 18px rgba(6, 78, 59, .07) !important;
    }

    .category-table tbody td,
    .product-table tbody td,
    .stock-table tbody td,
    .report-table tbody td {
        border: 0 !important;
        padding: 7px 0 !important;
        font-size: 13px !important;
        display: grid !important;
        grid-template-columns: 92px minmax(0, 1fr) !important;
        gap: 10px !important;
        align-items: start !important;
        white-space: normal !important;
        word-break: break-word !important;
        overflow-wrap: anywhere !important;
    }

    .category-table tbody td::before,
    .product-table tbody td::before,
    .stock-table tbody td::before,
    .report-table tbody td::before {
        content: attr(data-label);
        display: block !important;
        font-size: 10px !important;
        font-weight: 900 !important;
        color: #6b7280 !important;
        text-transform: uppercase !important;
        letter-spacing: .04em !important;
    }

    .category-table tbody td[colspan]::before,
    .product-table tbody td[colspan]::before,
    .stock-table tbody td[colspan]::before,
    .report-table tbody td[colspan]::before {
        display: none !important;
        content: none !important;
    }

    .report-items-sold {
        max-width: 100% !important;
        font-size: 12px !important;
    }

    .btn-edit {
        width: 100% !important;
        margin-top: 4px !important;
    }

    .app-pagination {
        margin-top: 14px !important;
    }

    .app-pagination .pagination {
        gap: 5px !important;
    }

    .app-pagination .page-link,
    .pagination .page-link {
        min-width: 34px !important;
        min-height: 34px !important;
        padding: 7px 9px !important;
        border-radius: 10px !important;
        font-size: 12px !important;
    }
}

@media screen and (max-width: 390px) {
    .product-grid {
        grid-template-columns: 1fr !important;
    }

    .product-card-pos img {
        height: 92px !important;
    }

    .quick-pay-grid {
        grid-template-columns: repeat(2, 1fr) !important;
    }
}

/* =========================================================
   PRINT REPORT FINAL
========================================================= */



/* =========================================================
   EMPTY STATE TABLE MOBILE FIX
   Fix tampilan kosong di laporan / stock table mobile
========================================================= */

.empty-state {
    width: 100%;
    min-width: 100%;
    padding: 32px 18px;
    text-align: center;
    color: var(--muted);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 8px;
    line-height: 1.45;
    white-space: normal;
    word-break: normal;
    overflow-wrap: normal;
}

.empty-state strong {
    display: block;
    width: 100%;
    max-width: 320px;
    font-size: 16px;
    font-weight: 900;
    color: var(--text);
    line-height: 1.35;
    white-space: normal;
    word-break: normal;
    overflow-wrap: normal;
}

.empty-state span,
.empty-state p,
.empty-state div {
    max-width: 320px;
    white-space: normal;
    word-break: normal;
    overflow-wrap: normal;
}

/* Fix khusus td kosong di mode mobile table */
.stock-table td[colspan],
.report-table td[colspan] {
    width: 100% !important;
    display: table-cell !important;
    padding: 0 !important;
    white-space: normal !important;
}

.stock-table td[colspan]::before,
.report-table td[colspan]::before {
    display: none !important;
    content: none !important;
}

/* Mobile: kosong tetap full card, bukan pecah per kolom */
@media screen and (max-width: 576px) {
    .stock-table tbody tr:has(td[colspan]),
    .report-table tbody tr:has(td[colspan]) {
        display: block !important;
        width: 100% !important;
        padding: 0 !important;
        border: 1px solid #e5e7eb !important;
        border-radius: 16px !important;
        background: #ffffff !important;
        box-shadow: 0 8px 22px rgba(6, 78, 59, .06) !important;
        overflow: hidden !important;
    }

    .stock-table tbody td[colspan],
    .report-table tbody td[colspan] {
        display: block !important;
        width: 100% !important;
        max-width: 100% !important;
        padding: 0 !important;
        border: 0 !important;
    }

    .stock-table tbody td[colspan] .empty-state,
    .report-table tbody td[colspan] .empty-state {
        width: 100% !important;
        min-width: 100% !important;
        max-width: 100% !important;
        padding: 34px 20px !important;
        text-align: center !important;
        white-space: normal !important;
        word-break: normal !important;
        overflow-wrap: normal !important;
    }

    .stock-table tbody td[colspan] .empty-state strong,
    .report-table tbody td[colspan] .empty-state strong {
        width: 100% !important;
        max-width: 280px !important;
        margin: 0 auto !important;
        font-size: 16px !important;
        line-height: 1.35 !important;
        white-space: normal !important;
        word-break: normal !important;
        overflow-wrap: normal !important;
    }
}
/* =========================================================
   PRINT / EXPORT PDF FINAL - DESKTOP FRIENDLY
   Fokus: Laporan Penjualan, Produk Terjual, Stock
   Letakkan paling bawah app.css
========================================================= */

@media print {
    @page {
        size: A4 landscape;
        margin: 8mm;
    }

    html,
    body {
        width: 100% !important;
        max-width: 100% !important;
        margin: 0 !important;
        padding: 0 !important;
        background: #ffffff !important;
        color: #000000 !important;
        font-family: Arial, Helvetica, sans-serif !important;
        font-size: 10px !important;
        line-height: 1.25 !important;
        overflow: visible !important;
        -webkit-print-color-adjust: exact !important;
        print-color-adjust: exact !important;
    }

    * {
        box-shadow: none !important;
        text-shadow: none !important;
    }

    .no-print,
    .navbar,
    .app-navbar,
    .sidebar,
    .app-sidebar,
    .app-drawer-overlay,
    .simple-footer,
    .report-filter-card,
    .report-print-btn,
    .app-pagination,
    .pagination,
    .modal,
    .modal-backdrop,
    button,
    .btn,
    form,
    input,
    select,
    textarea {
        display: none !important;
        visibility: hidden !important;
    }

    .container,
    .container-fluid,
    .app-container,
    .app-shell,
    .app-main,
    main,
    .row,
    .col,
    .col-12,
    .report-page,
    .owner-page,
    .category-page,
    .product-page,
    .stock-page {
        display: block !important;
        width: 100% !important;
        max-width: 100% !important;
        min-width: 0 !important;
        margin: 0 !important;
        padding: 0 !important;
        overflow: visible !important;
        background: #ffffff !important;
    }

    .card,
    .report-table-card,
    .report-summary-card,
    .owner-card,
    .stock-card,
    .category-card,
    .product-card {
        width: 100% !important;
        max-width: 100% !important;
        margin: 0 0 10px !important;
        padding: 0 !important;
        border: 0 !important;
        border-radius: 0 !important;
        background: #ffffff !important;
        box-shadow: none !important;
        overflow: visible !important;
    }

    .report-header,
    .owner-header,
    .category-header,
    .product-header,
    .stock-header {
        display: block !important;
        margin: 0 0 12px !important;
        padding: 0 0 8px !important;
        border-bottom: 2px solid #111827 !important;
        background: #ffffff !important;
        color: #000000 !important;
    }

    .report-header h3,
    .owner-header h3,
    .category-header h3,
    .product-header h3,
    .stock-header h3 {
        margin: 0 0 4px !important;
        padding: 0 !important;
        font-size: 20px !important;
        line-height: 1.2 !important;
        font-weight: 900 !important;
        color: #000000 !important;
    }

    .report-header p,
    .owner-header p,
    .category-header p,
    .product-header p,
    .stock-header p,
    p,
    small,
    span,
    strong {
        color: #000000 !important;
    }

    .report-summary,
    .owner-summary,
    .stock-summary {
        display: grid !important;
        grid-template-columns: repeat(3, 1fr) !important;
        gap: 0 !important;
        width: 100% !important;
        margin: 0 0 12px !important;
        padding: 0 !important;
        border-top: 1px solid #cbd5e1 !important;
        border-left: 1px solid #cbd5e1 !important;
        background: #ffffff !important;
        page-break-inside: avoid !important;
        break-inside: avoid !important;
    }

    .report-summary-card,
    .owner-stat-card,
    .summary-card {
        display: block !important;
        width: auto !important;
        max-width: none !important;
        margin: 0 !important;
        padding: 0 !important;
        border: 0 !important;
        border-right: 1px solid #cbd5e1 !important;
        border-bottom: 1px solid #cbd5e1 !important;
        border-radius: 0 !important;
        background: #ffffff !important;
        box-shadow: none !important;
    }

    .report-summary-card small,
    .owner-stat-card small,
    .summary-card span {
        display: block !important;
        margin: 0 !important;
        padding: 6px 8px !important;
        border-bottom: 1px solid #cbd5e1 !important;
        background: #f8fafc !important;
        color: #000000 !important;
        font-size: 8px !important;
        line-height: 1.2 !important;
        font-weight: 900 !important;
    }

    .report-summary-card h3,
    .owner-stat-card h3,
    .summary-card strong {
        display: block !important;
        margin: 0 !important;
        padding: 8px 8px !important;
        color: #000000 !important;
        font-size: 14px !important;
        line-height: 1.2 !important;
        font-weight: 900 !important;
    }

    .report-card-header {
        display: block !important;
        margin: 0 0 8px !important;
        padding: 0 !important;
    }

    .report-card-header h5 {
        margin: 0 0 3px !important;
        padding: 0 !important;
        color: #000000 !important;
        font-size: 15px !important;
        line-height: 1.2 !important;
        font-weight: 900 !important;
    }

    .report-card-header small {
        color: #000000 !important;
        font-size: 9px !important;
        line-height: 1.3 !important;
    }

    .table-responsive,
    .report-table-responsive,
    .owner-table-responsive {
        display: block !important;
        width: 100% !important;
        max-width: 100% !important;
        margin: 0 !important;
        padding: 0 !important;
        overflow: visible !important;
        border: 0 !important;
        border-radius: 0 !important;
        background: #ffffff !important;
    }

    table,
    .table,
    .category-table,
    .product-table,
    .stock-table,
    .report-table,
    .owner-table {
        display: table !important;
        width: 100% !important;
        min-width: 0 !important;
        max-width: 100% !important;
        margin: 0 !important;
        padding: 0 !important;
        table-layout: fixed !important;
        border-collapse: collapse !important;
        border-spacing: 0 !important;
        border: 1px solid #cbd5e1 !important;
        background: #ffffff !important;
        color: #000000 !important;
    }

    thead {
        display: table-header-group !important;
    }

    tbody {
        display: table-row-group !important;
    }

    tfoot {
        display: table-footer-group !important;
    }

    tr,
    table tr,
    .table tr,
    .category-table tr,
    .product-table tr,
    .stock-table tr,
    .report-table tr,
    .owner-table tr {
        display: table-row !important;
        width: auto !important;
        max-width: none !important;
        margin: 0 !important;
        padding: 0 !important;
        border: 0 !important;
        border-radius: 0 !important;
        background: #ffffff !important;
        box-shadow: none !important;
        page-break-inside: avoid !important;
        break-inside: avoid !important;
    }

    th,
    td,
    table th,
    table td,
    .table th,
    .table td,
    .category-table th,
    .category-table td,
    .product-table th,
    .product-table td,
    .stock-table th,
    .stock-table td,
    .report-table th,
    .report-table td,
    .owner-table th,
    .owner-table td {
        display: table-cell !important;
        width: auto !important;
        max-width: none !important;
        margin: 0 !important;
        border: 1px solid #cbd5e1 !important;
        padding: 4px 5px !important;
        background: #ffffff !important;
        color: #000000 !important;
        font-size: 7px !important;
        line-height: 1.2 !important;
        vertical-align: top !important;
        white-space: normal !important;
        word-break: break-word !important;
        overflow-wrap: anywhere !important;
        text-align: left !important;
    }

    th,
    table th,
    .table th,
    .category-table th,
    .product-table th,
    .stock-table th,
    .report-table th,
    .owner-table th {
        background: #f8fafc !important;
        color: #000000 !important;
        font-size: 6.5px !important;
        font-weight: 900 !important;
        text-transform: uppercase !important;
        letter-spacing: 0 !important;
    }

    td::before,
    th::before,
    tr::before,
    tr::after,
    .table td::before,
    .table th::before,
    .category-table td::before,
    .product-table td::before,
    .stock-table td::before,
    .report-table td::before,
    .owner-table td::before {
        display: none !important;
        content: none !important;
    }

    .report-items-sold {
        display: block !important;
        max-width: none !important;
        white-space: normal !important;
        color: #000000 !important;
        font-size: 7px !important;
        line-height: 1.2 !important;
    }

    .badge,
    .status-badge,
    .stock-badge,
    .badge-type {
        display: inline-block !important;
        min-width: 0 !important;
        height: auto !important;
        padding: 0 !important;
        border: 0 !important;
        background: transparent !important;
        color: #000000 !important;
        font-size: inherit !important;
        font-weight: 700 !important;
    }

    /* Kolom khusus laporan penjualan 9 kolom */
    .report-table th:nth-child(1),
    .report-table td:nth-child(1) {
        width: 15% !important;
    }

    .report-table th:nth-child(2),
    .report-table td:nth-child(2) {
        width: 13% !important;
    }

    .report-table th:nth-child(3),
    .report-table td:nth-child(3) {
        width: 10% !important;
    }

    .report-table th:nth-child(4),
    .report-table td:nth-child(4) {
        width: 22% !important;
    }

    .report-table th:nth-child(5),
    .report-table td:nth-child(5) {
        width: 5% !important;
        text-align: center !important;
    }

    .report-table th:nth-child(6),
    .report-table td:nth-child(6) {
        width: 8% !important;
        text-align: right !important;
    }

    .report-table th:nth-child(7),
    .report-table td:nth-child(7) {
        width: 8% !important;
        text-align: right !important;
    }

    .report-table th:nth-child(8),
    .report-table td:nth-child(8) {
        width: 8% !important;
        text-align: right !important;
    }

    .report-table th:nth-child(9),
    .report-table td:nth-child(9) {
        width: 11% !important;
        text-align: left !important;
    }

    a {
        color: #000000 !important;
        text-decoration: none !important;
    }
}