/* TOKOKU01 POS Design Tokens & Styles */

:root {
    --bg-dark: #0f111a;
    --bg-card: rgba(22, 28, 45, 0.7);
    --bg-sidebar: #0b0d14;
    --bg-input: #1a2035;
    
    --text-main: #f8fafc;
    --text-muted: #94a3b8;
    --text-accent: #0284c7; /* Sky blue */
    
    --primary: #38bdf8;
    --primary-hover: #0ea5e9;
    --success: #10b981;
    --warning: #f59e0b;
    --danger: #ef4444;
    
    --glass-border: rgba(255, 255, 255, 0.08);
    --glass-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.37);
    
    --font-sans: 'Outfit', sans-serif;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: var(--font-sans);
}

body.dark-theme {
    background-color: var(--bg-dark);
    color: var(--text-main);
    overflow: hidden;
    height: 100vh;
}

/* Container Layout */
.pos-container {
    display: grid;
    grid-template-columns: 200px 1fr 36%;
    height: 100vh;
    width: 100vw;
}

/* 1. Sidebar Navigation */
.pos-sidebar {
    background-color: var(--bg-sidebar);
    border-right: 1px solid var(--glass-border);
    display: flex;
    flex-direction: column;
    padding: 24px 16px;
    justify-content: space-between;
}

.brand-logo {
    display: flex;
    align-items: center;
    gap: 12px;
    padding-bottom: 24px;
    border-bottom: 1px solid var(--glass-border);
}

.logo-icon {
    font-size: 24px;
    color: var(--primary);
}

.logo-text {
    font-size: 20px;
    font-weight: 700;
    letter-spacing: 0.5px;
}

.text-accent {
    color: var(--primary);
}

.sidebar-nav {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-top: 24px;
    flex-grow: 1;
}

.nav-item {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 12px 16px;
    color: var(--text-muted);
    text-decoration: none;
    font-size: 15px;
    font-weight: 500;
    border-radius: 8px;
    transition: all 0.2s ease;
}

.nav-item:hover {
    color: var(--text-main);
    background-color: rgba(255, 255, 255, 0.03);
}

.nav-item.active {
    color: var(--text-main);
    background: linear-gradient(135deg, rgba(56, 189, 248, 0.15) 0%, rgba(2, 132, 199, 0.15) 100%);
    border-left: 3px solid var(--primary);
}

.cashier-info {
    display: flex;
    align-items: center;
    gap: 12px;
    padding-top: 16px;
    border-top: 1px solid var(--glass-border);
}

.cashier-avatar {
    width: 40px;
    height: 40px;
    background-color: var(--primary);
    color: var(--bg-dark);
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    font-size: 18px;
}

.cashier-details {
    flex-grow: 1;
    overflow: hidden;
}

.cashier-name {
    font-size: 14px;
    font-weight: 600;
    white-space: nowrap;
    text-overflow: ellipsis;
    overflow: hidden;
}

.cashier-role {
    font-size: 11px;
    color: var(--text-muted);
}

.logout-btn {
    background: transparent;
    border: none;
    color: var(--danger);
    font-size: 18px;
    cursor: pointer;
    opacity: 0.7;
    transition: opacity 0.2s;
}

.logout-btn:hover {
    opacity: 1;
}

/* 2. Main POS Area */
.pos-main {
    display: flex;
    flex-direction: column;
    padding: 24px;
    background: radial-gradient(circle at top left, #131722, #0d0f17);
    overflow: hidden;
}

.pos-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    gap: 16px;
    flex-wrap: wrap;
}

.search-wrapper {
    display: flex;
    align-items: stretch;
    gap: 10px;
    flex-grow: 1;
    max-width: 640px;
}

.search-box {
    position: relative;
    flex: 1;
    min-width: 0;
}

.search-icon {
    position: absolute;
    left: 16px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-muted);
    font-size: 18px;
}

#barcode-search {
    width: 100%;
    background-color: var(--bg-input);
    border: 1px solid var(--glass-border);
    color: var(--text-main);
    padding: 14px 16px 14px 48px;
    border-radius: 12px;
    font-size: 15px;
    outline: none;
    transition: border-color 0.2s;
}

#barcode-search:focus {
    border-color: var(--primary);
}

.focus-badge {
    position: absolute;
    right: 16px;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(255, 255, 255, 0.08);
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 11px;
    color: var(--text-muted);
    pointer-events: none;
}

.branch-selector-wrapper {
    display: flex;
    align-items: center;
    gap: 8px;
    background-color: rgba(255, 255, 255, 0.04);
    padding: 10px 16px;
    border-radius: 8px;
    border: 1px solid var(--glass-border);
    font-size: 14px;
    font-weight: 500;
}

.branch-icon {
    color: var(--primary);
}

/* Category Filter Bar */
.categories-bar {
    margin-bottom: 20px;
}

.categories-scroll {
    display: flex;
    gap: 10px;
    overflow-x: auto;
    padding-bottom: 8px;
}

.categories-scroll::-webkit-scrollbar {
    height: 4px;
}

.categories-scroll::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 2px;
}

.category-badge {
    background-color: var(--bg-card);
    border: 1px solid var(--glass-border);
    color: var(--text-muted);
    padding: 8px 16px;
    border-radius: 20px;
    font-size: 13px;
    cursor: pointer;
    white-space: nowrap;
    transition: all 0.2s ease;
}

.category-badge:hover {
    color: var(--text-main);
    border-color: var(--primary);
}

.category-badge.active {
    background-color: var(--primary);
    color: var(--bg-dark);
    font-weight: 600;
    border-color: var(--primary);
}

/* Product Container & Grid */
.products-container {
    flex-grow: 1;
    overflow-y: auto;
    padding-right: 4px;
}

.products-container::-webkit-scrollbar {
    width: 6px;
}

.products-container::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 3px;
}

.products-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: 16px;
}

/* Product Card */
.product-card {
    background: var(--bg-card);
    border: 1px solid var(--glass-border);
    border-radius: 12px;
    padding: 12px;
    cursor: pointer;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    transition: transform 0.2s, border-color 0.2s, box-shadow 0.2s;
}

.product-card:hover {
    transform: translateY(-2px);
    border-color: var(--primary);
    box-shadow: 0 4px 12px rgba(56, 189, 248, 0.15);
}

.product-card.out-of-stock {
    opacity: 0.5;
    pointer-events: none;
}

.product-info-top {
    margin-bottom: 12px;
}

.product-card-title {
    font-size: 14px;
    font-weight: 600;
    margin-bottom: 4px;
    color: var(--text-main);
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.product-card-sku {
    font-size: 11px;
    color: var(--text-muted);
    margin-bottom: 8px;
    display: block;
}

.stock-badge {
    display: inline-block;
    padding: 2px 6px;
    border-radius: 4px;
    font-size: 11px;
    font-weight: 500;
}

.stock-badge.in-stock {
    background-color: rgba(16, 185, 129, 0.15);
    color: var(--success);
}

.stock-badge.low-stock {
    background-color: rgba(245, 158, 11, 0.15);
    color: var(--warning);
}

.stock-badge.out-of-stock {
    background-color: rgba(239, 68, 110, 0.15);
    color: var(--danger);
}

.product-info-bottom {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-top: 1px solid var(--glass-border);
    padding-top: 8px;
}

.product-card-price {
    font-weight: 700;
    font-size: 15px;
    color: var(--primary);
}

.product-add-icon {
    font-size: 14px;
    color: var(--text-muted);
    background-color: rgba(255, 255, 255, 0.05);
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
}

/* 3. Right Cart Panel */
.pos-cart-panel {
    background-color: var(--bg-sidebar);
    border-left: 1px solid var(--glass-border);
    padding: 16px 18px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    overflow: hidden;
}

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

.cart-header h3 {
    font-size: 18px;
    font-weight: 600;
}

.items-count {
    background-color: rgba(56, 189, 248, 0.15);
    color: var(--primary);
    font-size: 12px;
    font-weight: 600;
    padding: 4px 10px;
    border-radius: 20px;
}

.customer-select-box {
    position: relative;
    margin-bottom: 10px;
}

.select-icon {
    position: absolute;
    left: 12px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-muted);
}

#customer-select {
    width: 100%;
    background-color: var(--bg-input);
    border: 1px solid var(--glass-border);
    color: var(--text-main);
    padding: 10px 12px 10px 36px;
    border-radius: 8px;
    outline: none;
    font-size: 13px;
    cursor: pointer;
}

/* Cart Items Scroll List */
.cart-items-wrapper {
    flex-grow: 1;
    overflow-y: auto;
    margin-bottom: 8px;
}

.cart-items-wrapper::-webkit-scrollbar {
    width: 4px;
}

.cart-items-wrapper::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 2px;
}

.cart-items-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.empty-cart-state {
    text-align: center;
    padding: 60px 20px;
    color: var(--text-muted);
}

.empty-icon {
    font-size: 40px;
    color: rgba(255, 255, 255, 0.05);
    margin-bottom: 12px;
}

.empty-cart-state p {
    font-size: 13px;
    line-height: 1.5;
}

/* Cart Item Card */
.cart-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid var(--glass-border);
    border-radius: 8px;
    padding: 10px;
    transition: background .3s ease, border-color .3s ease;
}

/* Barang yang BARU discan/ditambah -> warna beda (hijau) + kilat sekejap, biar kasir tahu mana yang barusan masuk. */
.cart-item-added {
    background: rgba(16, 185, 129, 0.16) !important;
    border-color: #10b981 !important;
    box-shadow: inset 3px 0 0 #10b981;
    animation: cartAddedFlash .6s ease;
}
@keyframes cartAddedFlash {
    0% { background: rgba(16, 185, 129, 0.45); }
    100% { background: rgba(16, 185, 129, 0.16); }
}

.cart-item-details {
    flex-grow: 1;
    margin-right: 12px;
    min-width: 0;
}

.cart-item-name {
    font-size: 13px;
    font-weight: 500;
    margin-bottom: 2px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.cart-item-price {
    font-size: 12px;
    color: var(--primary);
    font-weight: 600;
}

.cart-item-qty-control {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-shrink: 0;
    background-color: var(--bg-input);
    border: 1px solid var(--glass-border);
    border-radius: 6px;
    padding: 2px;
}

.qty-btn {
    background: transparent;
    border: none;
    color: var(--text-main);
    width: 24px;
    height: 24px;
    font-size: 12px;
    cursor: pointer;
    border-radius: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.qty-btn:hover {
    background-color: rgba(255, 255, 255, 0.05);
}

.qty-val {
    font-size: 13px;
    font-weight: 600;
    min-width: 20px;
    text-align: center;
}

.btn-delete-item {
    background: transparent;
    border: none;
    color: var(--danger);
    cursor: pointer;
    margin-left: 10px;
    padding: 6px;
    border-radius: 4px;
}

.btn-delete-item:hover {
    background-color: rgba(239, 68, 68, 0.1);
}

/* Pricing Summary Box */
.price-summary-box {
    border-top: 1px solid var(--glass-border);
    padding: 10px 0;
    display: flex;
    flex-direction: column;
    gap: 6px;
    /* Bayangan ke atas -> ringkasan+tombol terlihat "mengambang" di atas daftar barang yg scroll. */
    box-shadow: 0 -12px 18px -12px rgba(0, 0, 0, 0.55);
}

.summary-row {
    display: flex;
    justify-content: space-between;
    font-size: 13px;
    color: var(--text-muted);
}

.summary-row.grand-total-row {
    color: var(--text-main);
    font-size: 15px;
    font-weight: 600;
}

.grand-total-val {
    color: var(--success);
    font-size: 22px;
    font-weight: 700;
}

.summary-divider {
    border-top: 1px dashed var(--glass-border);
    margin: 4px 0;
}

/* Payment Section */
.payment-action-box {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.pay-row {
    display: flex;
    gap: 10px;
    align-items: stretch;
}

.pay-method-box {
    flex-shrink: 0;
    width: 132px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 5px;
}

.pay-method-label {
    font-size: 11px;
    color: var(--text-muted);
}

.pay-method-dropdown {
    width: 100%;
    background-color: var(--bg-input);
    border: 1px solid var(--glass-border);
    color: var(--text-main);
    padding: 11px 8px;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    outline: none;
}

.pay-method-dropdown:focus { border-color: var(--primary); }

.pay-row .cash-calc-wrapper { flex: 1; margin: 0; }

.payment-method-selector {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 6px;
}

.method-btn {
    border: 1px solid var(--glass-border);
    background-color: rgba(255, 255, 255, 0.02);
    color: var(--text-muted);
    text-align: center;
    padding: 7px 3px;
    border-radius: 8px;
    cursor: pointer;
    font-size: 11px;
    font-weight: 500;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    transition: all 0.2s;
}

.method-btn:hover {
    color: var(--text-main);
    border-color: var(--primary);
}

.method-btn.active {
    border-color: var(--primary);
    background-color: rgba(56, 189, 248, 0.1);
    color: var(--primary);
}

.cash-calc-wrapper {
    background-color: rgba(255, 255, 255, 0.02);
    border: 1px solid var(--glass-border);
    border-radius: 8px;
    padding: 12px;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.cash-calc-wrapper .input-group {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.cash-calc-wrapper label {
    font-size: 12px;
    color: var(--text-muted);
}

.cash-calc-wrapper input {
    background-color: var(--bg-input);
    border: 1px solid var(--glass-border);
    color: var(--text-main);
    padding: 6px 10px;
    border-radius: 4px;
    width: 140px;
    text-align: right;
    font-size: 14px;
    font-weight: 600;
    outline: none;
}

.change-group {
    display: flex;
    justify-content: space-between;
    font-size: 12px;
    color: var(--text-muted);
}

.change-value {
    color: var(--primary);
    font-weight: 700;
    font-size: 15px;
}

.btn-checkout {
    background-color: var(--success);
    color: var(--bg-dark);
    border: none;
    border-radius: 12px;
    padding: 16px;
    font-size: 16px;
    font-weight: 700;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    transition: opacity 0.2s, background-color 0.2s;
}

.btn-checkout:hover {
    background-color: #059669;
}

.btn-checkout:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

/* 4. MODALS */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background-color: rgba(0, 0, 0, 0.75);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 99990 !important;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.2s;
}

.modal-overlay.active {
    opacity: 1;
    pointer-events: auto;
}

.modal-card {
    background-color: #121829;
    border: 1px solid var(--glass-border);
    border-radius: 16px;
    width: 100%;
    max-width: 480px;
    max-height: 90vh;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    box-shadow: var(--glass-shadow);
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 20px;
    border-bottom: 1px solid var(--glass-border);
    flex-shrink: 0;
}

.modal-header.header-warning {
    background-color: rgba(239, 68, 68, 0.1);
    color: var(--danger);
}

.close-modal {
    background: transparent;
    border: none;
    color: var(--text-muted);
    font-size: 24px;
    cursor: pointer;
}

.modal-body {
    padding: 20px;
    overflow-y: auto;
    flex: 1;
}

.modal-footer {
    padding: 14px 20px;
    border-top: 1px solid var(--glass-border);
    display: flex;
    justify-content: flex-end;
    gap: 10px;
    flex-shrink: 0;
}

.warning-text {
    font-size: 13px;
    color: var(--text-muted);
    margin-bottom: 16px;
}

.action-details-card {
    background-color: rgba(255, 255, 255, 0.02);
    border: 1px solid var(--glass-border);
    border-radius: 8px;
    padding: 12px;
    font-size: 13px;
    margin-bottom: 20px;
}

.action-details-card p {
    margin-bottom: 6px;
}

.action-details-card p:last-child {
    margin-bottom: 0;
}

.override-input-section {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.override-input-section label {
    font-size: 12px;
    color: var(--text-muted);
}

#override-barcode {
    width: 100%;
    background-color: var(--bg-input);
    border: 1px solid var(--glass-border);
    color: var(--text-main);
    padding: 12px;
    border-radius: 8px;
    outline: none;
    font-size: 14px;
}

.divider-text {
    text-align: center;
    font-size: 10px;
    color: var(--text-muted);
    margin: 8px 0;
    font-weight: 600;
}

.form-group input {
    width: 100%;
    background-color: var(--bg-input);
    border: 1px solid var(--glass-border);
    color: var(--text-main);
    padding: 10px;
    border-radius: 6px;
    outline: none;
}

.modal-footer {
    display: flex;
    justify-content: flex-end;
    gap: 12px;
    padding: 16px 20px;
    border-top: 1px solid var(--glass-border);
}

.btn-secondary {
    background-color: rgba(255, 255, 255, 0.05);
    color: var(--text-main);
    border: 1px solid var(--glass-border);
    padding: 10px 18px;
    border-radius: 8px;
    cursor: pointer;
    font-weight: 500;
}

.btn-primary {
    background-color: var(--primary);
    color: var(--bg-dark);
    border: none;
    padding: 10px 18px;
    border-radius: 8px;
    cursor: pointer;
    font-weight: 600;
}

/* History Modal Size */
.modal-card.history-card {
    max-width: 800px;
}

/* Daftar transaksi bisa di-scroll bila panjang; judul kolom tetap menempel di atas. */
.history-card .modal-body {
    max-height: 72vh;
    overflow-y: auto;
}

.history-card thead th {
    position: sticky;
    top: 0;
    background-color: #121829;
    z-index: 1;
}

/* Thermal Receipt Styling */
.modal-card.receipt-card {
    max-width: 400px;
}

.receipt-paper {
    background-color: #fff;
    color: #000;
    padding: 24px 16px;
    font-family: 'Courier New', Courier, monospace;
    font-size: 12px;
    border-radius: 4px;
    box-shadow: inset 0 0 10px rgba(0,0,0,0.15);
}

.receipt-paper * {
    font-family: 'Courier New', Courier, monospace !important;
}

/* Table styling in history */
.table-responsive {
    overflow-x: auto;
}

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

.data-table th, .data-table td {
    padding: 12px;
    text-align: left;
    border-bottom: 1px solid var(--glass-border);
}

.data-table th {
    color: var(--text-muted);
    font-weight: 500;
}

.data-table tbody tr:hover {
    background-color: rgba(255, 255, 255, 0.02);
}

.btn-table-action {
    background-color: rgba(56, 189, 248, 0.1);
    color: var(--primary);
    border: none;
    padding: 6px 10px;
    border-radius: 4px;
    cursor: pointer;
}

.btn-table-action:hover {
    background-color: var(--primary);
    color: var(--bg-dark);
}

/* ==========================================
   MOBILE RESPONSIVE & TOUCH-OPTIMIZED STYLES (< 768px)
   ========================================== */
/* ==========================================
   MOBILE NATIVE POS STYLES (< 768px)
   ========================================== */
@media (max-width: 768px) {
    button, input, select {
        min-height: 46px;
    }

    body {
        padding-bottom: 74px !important;
    }

    body.dark-theme {
        height: auto !important;
        overflow-y: auto !important;
    }

    .pos-container {
        display: block !important;
        grid-template-columns: none !important;
        width: 100% !important;
        max-width: 100vw !important;
        height: auto !important;
        min-height: 100vh !important;
        padding: 8px 8px 85px 8px !important;
        overflow-x: hidden !important;
    }

    .pos-sidebar {
        display: none !important;
    }

    .pos-main {
        width: 100% !important;
        max-width: 100% !important;
        flex: 1 1 100% !important;
        display: flex !important;
        flex-direction: column !important;
    }

    .pos-header {
        width: 100% !important;
        flex-direction: column !important;
        gap: 8px !important;
        padding: 8px 10px !important;
    }

    .search-wrapper {
        width: 100% !important;
        display: flex !important;
        gap: 8px !important;
    }

    .search-box {
        flex: 1 !important;
        width: 100% !important;
    }

    .branch-selector-wrapper {
        width: 100% !important;
        justify-content: space-between !important;
    }

    .categories-bar {
        width: 100% !important;
        padding: 4px 0 !important;
        overflow-x: auto !important;
        white-space: nowrap !important;
    }

    .categories-scroll {
        display: flex !important;
        gap: 8px !important;
        overflow-x: auto !important;
    }

    .category-badge {
        padding: 8px 16px !important;
        font-size: 13px !important;
        border-radius: 20px !important;
        flex-shrink: 0 !important;
    }

    .products-container {
        width: 100% !important;
        max-width: 100% !important;
        flex: 1 !important;
    }

    /* Product Grid: 2 Columns matching User Image Reference */
    .products-grid {
        width: 100% !important;
        grid-template-columns: repeat(2, 1fr) !important;
        gap: 10px !important;
        padding: 2px !important;
    }

    .product-card {
        padding: 10px !important;
        border-radius: 14px !important;
        background: rgba(15, 23, 42, 0.75) !important;
        border: 1px solid rgba(255, 255, 255, 0.08) !important;
        display: flex !important;
        flex-direction: column !important;
        justify-content: space-between !important;
    }

    .product-card img {
        height: 110px !important;
        border-radius: 10px !important;
        object-fit: cover !important;
    }

    .product-name {
        font-size: 13px !important;
        font-weight: 600 !important;
        color: #fff !important;
        margin: 6px 0 2px 0 !important;
    }

    .product-price {
        font-size: 14px !important;
        font-weight: 700 !important;
        color: #10b981 !important;
    }

    /* Floating Bottom Navigation Bar (Dark Navy #0b1220 matching Desktop) */
    .mobile-bottom-nav {
        display: flex !important;
        position: fixed !important;
        bottom: 0 !important;
        left: 0 !important;
        right: 0 !important;
        height: 64px !important;
        background: rgba(11, 18, 32, 0.95) !important;
        backdrop-filter: blur(12px) !important;
        border-top: 1px solid rgba(255, 255, 255, 0.1) !important;
        z-index: 9000 !important;
        justify-content: space-around !important;
        align-items: center !important;
        padding: 0 6px !important;
    }

    .mobile-bottom-nav .nav-btn {
        display: flex !important;
        flex-direction: column !important;
        align-items: center !important;
        justify-content: center !important;
        background: none !important;
        border: none !important;
        color: #94a3b8 !important;
        font-size: 10px !important;
        gap: 3px !important;
        cursor: pointer !important;
        flex: 1 !important;
        min-height: unset !important;
    }

    .mobile-bottom-nav .nav-btn i {
        font-size: 18px !important;
    }

    .mobile-bottom-nav .nav-btn.active {
        color: #10b981 !important;
    }

    /* Center Floating Cart Button with Badge (Matching User Reference Image) */
    .mobile-cart-badge-wrapper {
        position: relative !important;
        top: -18px !important;
        width: 58px !important;
        height: 58px !important;
        display: flex !important;
        align-items: center !important;
        justify-content: center !important;
    }

    .mobile-cart-btn {
        width: 54px !important;
        height: 54px !important;
        border-radius: 50% !important;
        background: linear-gradient(135deg, #10b981 0%, #059669 100%) !important;
        border: 3px solid #0b1220 !important;
        color: #fff !important;
        display: flex !important;
        align-items: center !important;
        justify-content: center !important;
        box-shadow: 0 8px 20px rgba(16, 185, 129, 0.4) !important;
        cursor: pointer !important;
        position: relative !important;
        min-height: unset !important;
    }

    .mobile-cart-btn i {
        font-size: 22px !important;
    }

    .mobile-cart-count {
        position: absolute !important;
        top: -4px !important;
        right: -2px !important;
        background: #ef4444 !important;
        color: #fff !important;
        font-size: 11px !important;
        font-weight: 800 !important;
        min-width: 20px !important;
        height: 20px !important;
        border-radius: 10px !important;
        display: flex !important;
        align-items: center !important;
        justify-content: center !important;
        border: 2px solid #0b1220 !important;
    }

    /* Right Cart Panel on Mobile: Fullscreen Slide-Up Modal Drawer */
    .pos-cart-panel {
        position: fixed !important;
        inset: 0 !important;
        z-index: 8500 !important;
        background: #0b1220 !important;
        display: none !important;
        flex-direction: column !important;
        padding: 14px 14px 80px 14px !important;
        overflow-y: auto !important;
        border: none !important;
    }

    .pos-cart-panel.mobile-active {
        display: flex !important;
    }

    #btn-close-mobile-cart {
        display: block !important;
    }

    .table-responsive {
        width: 100% !important;
        overflow-x: auto !important;
        -webkit-overflow-scrolling: touch !important;
    }

    .modal-card {
        width: 95% !important;
        max-width: 100% !important;
        max-height: 88vh !important;
        overflow-y: auto !important;
        margin: 10px auto !important;
        border-radius: 16px !important;
        padding: 16px !important;
    }
}

@media (min-width: 769px) {
    .mobile-bottom-nav {
        display: none !important;
    }
}

/* Thermal Receipt Print Media Query — Prints ONLY #receipt-paper & Eliminates Blank Pages */
@media print {
    html, body {
        background: #ffffff !important;
        color: #000000 !important;
        margin: 0 !important;
        padding: 0 !important;
        width: 100% !important;
        height: auto !important;
        min-height: 0 !important;
        overflow: visible !important;
    }

    body > *:not(#receipt-modal) {
        display: none !important;
    }

    .pos-container,
    .mobile-bottom-nav,
    .sidebar,
    .header,
    .top-bar,
    .modal-overlay:not(#receipt-modal) {
        display: none !important;
    }

    #receipt-modal {
        position: static !important;
        inset: auto !important;
        width: 100% !important;
        max-width: 80mm !important;
        height: auto !important;
        margin: 0 auto !important;
        padding: 0 !important;
        background: #ffffff !important;
        box-shadow: none !important;
        border: none !important;
        z-index: 999999 !important;
        opacity: 1 !important;
        display: block !important;
        visibility: visible !important;
        pointer-events: auto !important;
    }

    #receipt-modal * {
        visibility: visible !important;
    }

    #receipt-modal .modal-header,
    #receipt-modal .modal-footer,
    #receipt-modal .close-modal {
        display: none !important;
    }

    #receipt-modal .modal-card,
    #receipt-modal .receipt-card {
        box-shadow: none !important;
        border: none !important;
        background: #ffffff !important;
        color: #000000 !important;
        width: 100% !important;
        max-width: 100% !important;
        margin: 0 !important;
        padding: 0 !important;
        max-height: none !important;
        overflow: visible !important;
    }

    #receipt-modal .modal-body {
        padding: 0 !important;
        margin: 0 !important;
        max-height: none !important;
        overflow: visible !important;
    }

    #receipt-paper {
        color: #000000 !important;
        background: #ffffff !important;
        padding: 6px !important;
        margin: 0 !important;
        font-family: 'Courier New', Courier, monospace !important;
        font-size: 12px !important;
        line-height: 1.3 !important;
        width: 100% !important;
        box-shadow: none !important;
        border: none !important;
    }
}

/* In-Cart Product Selection & Badge Styles */
.product-card {
    position: relative;
}
.product-card.in-cart {
    border-color: var(--primary) !important;
    box-shadow: 0 0 10px rgba(56, 189, 248, 0.25) !important;
}
.product-add-icon.has-items {
    background-color: var(--primary) !important;
    color: var(--bg-dark) !important;
    font-size: 11px !important;
    font-weight: 700 !important;
    width: auto !important;
    min-width: 24px !important;
    height: 24px !important;
    padding: 0 6px !important;
    border-radius: 12px !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
}

/* Modal Stacking Layer Fix */
#receipt-modal {
    z-index: 99995 !important;
}
#override-modal {
    z-index: 100000 !important;
}

