/* Modal Overlay & Base Dialog Styles */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(15, 23, 42, 0.65);
    backdrop-filter: blur(6px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    padding: 16px;
    animation: fadeIn 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}

.modal-content {
    background: #ffffff;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    width: 100%;
    max-width: 520px;
    box-shadow: var(--shadow-lg);
    display: flex;
    flex-direction: column;
    overflow: hidden;
    max-height: 90vh;
    animation: slideUp 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

.modal-content.wide {
    max-width: 780px;
}

.modal-content.extra-wide {
    max-width: 920px;
}

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

.modal-header h3 {
    font-size: 17px;
    font-weight: 800;
    color: var(--brand-navy);
}

.modal-close-btn {
    background: #f1f5f9;
    border: none;
    color: var(--text-muted);
    width: 32px;
    height: 32px;
    border-radius: 50%;
    cursor: pointer;
    font-size: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s;
}

.modal-close-btn:hover {
    background: #fee2e2;
    color: var(--brand-red);
}

.modal-body {
    padding: 20px;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    gap: 16px;
    background: #ffffff;
}

.modal-footer {
    padding: 14px 20px;
    border-top: 1px solid var(--border-color);
    display: flex;
    justify-content: flex-end;
    gap: 10px;
    background: #f8fafc;
}

/* Modifiers / Add-ons List */
.modifiers-list {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
}

.mod-checkbox-card {
    background: #f8fafc;
    border: 1.5px solid var(--border-color);
    border-radius: var(--radius-sm);
    padding: 10px 12px;
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: all 0.2s;
}

.mod-checkbox-card:hover {
    border-color: var(--brand-navy);
    background: #f1f5f9;
}

.mod-checkbox-card.selected {
    background: rgba(254, 15, 12, 0.05);
    border-color: var(--brand-red);
}

.mod-checkbox-card.selected .mod-info-name {
    color: var(--brand-red);
    font-weight: 700;
}

.mod-info-name {
    font-size: 13px;
    font-weight: 600;
    color: var(--brand-navy);
}

.mod-info-price {
    font-size: 12px;
    font-family: 'JetBrains Mono', monospace;
    font-weight: 700;
    color: var(--text-muted);
}

/* ==========================================
   MODERN CHECKOUT & SETTLE PAYMENT MODAL
   ========================================== */
.payment-grid {
    display: grid;
    grid-template-columns: 1.15fr 0.85fr;
    gap: 20px;
}

.payment-methods-tabs {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 8px;
    margin-bottom: 16px;
}

.pay-method-btn {
    background: #ffffff;
    border: 1.5px solid var(--border-color);
    padding: 12px 6px;
    border-radius: var(--radius-sm);
    cursor: pointer;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 6px;
    font-size: 12px;
    font-weight: 700;
    color: var(--brand-navy);
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}

.pay-method-btn span:first-child {
    font-size: 22px;
}

.pay-method-btn:hover {
    border-color: var(--brand-navy);
    background: #f8fafc;
    transform: translateY(-1px);
}

.pay-method-btn.active {
    background: var(--brand-navy);
    border-color: var(--brand-navy);
    color: #ffffff;
    box-shadow: 0 4px 14px rgba(36, 38, 93, 0.25);
}

/* Tendered Amount Input Group */
.tendered-input-wrapper {
    display: flex;
    align-items: center;
    background: #ffffff;
    border: 2px solid var(--border-color);
    border-radius: 10px;
    overflow: hidden;
    margin-bottom: 14px;
    transition: all 0.2s;
    box-shadow: var(--shadow-sm);
}

.tendered-input-wrapper:focus-within {
    border-color: var(--brand-navy);
    box-shadow: 0 0 0 3px rgba(36, 38, 93, 0.12);
}

.tendered-curr-badge {
    background: #f1f5f9;
    color: var(--brand-navy);
    font-size: 15px;
    font-weight: 800;
    padding: 12px 16px;
    border-right: 1.5px solid var(--border-color);
    font-family: 'JetBrains Mono', monospace;
}

.tendered-input-field {
    flex: 1;
    border: none;
    outline: none;
    padding: 10px 14px;
    font-size: 22px;
    font-weight: 800;
    color: var(--brand-navy);
    font-family: 'JetBrains Mono', monospace;
    background: transparent;
}

.btn-tendered-clear {
    background: #fee2e2;
    border: none;
    color: var(--brand-red);
    padding: 8px 14px;
    font-size: 12px;
    font-weight: 800;
    cursor: pointer;
    margin-right: 8px;
    border-radius: 6px;
    transition: all 0.15s;
}
.btn-tendered-clear:hover {
    background: var(--brand-red);
    color: #ffffff;
}

/* Sri Lankan Quick Cash Banknotes Grid */
.quick-cash-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 7px;
    margin-bottom: 14px;
}

.quick-cash-btn {
    background: #ffffff;
    border: 1.5px solid #e2e8f0;
    padding: 9px 4px;
    border-radius: 8px;
    font-size: 12px;
    font-weight: 800;
    color: var(--brand-navy);
    cursor: pointer;
    transition: all 0.15s cubic-bezier(0.4, 0, 0.2, 1);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 2px;
}

.quick-cash-btn.exact-btn {
    background: #ecfdf5;
    border-color: #a7f3d0;
    color: #047857;
    grid-column: span 2;
}
.quick-cash-btn.exact-btn:hover {
    background: #10b981;
    color: #ffffff;
    border-color: #10b981;
}

.quick-cash-btn:hover {
    background: var(--brand-navy);
    color: #ffffff;
    border-color: var(--brand-navy);
    transform: translateY(-1px);
    box-shadow: 0 4px 10px rgba(36, 38, 93, 0.15);
}

/* Touch POS Fast Numeric Keypad */
.pos-numpad-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 6px;
}

.numpad-key {
    background: #f8fafc;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 10px;
    font-size: 15px;
    font-weight: 800;
    color: var(--brand-navy);
    cursor: pointer;
    text-align: center;
    transition: all 0.1s;
    user-select: none;
}

.numpad-key:hover {
    background: #e2e8f0;
    border-color: #cbd5e1;
    transform: scale(1.02);
}

.numpad-key:active {
    background: var(--brand-navy);
    color: #ffffff;
    transform: scale(0.98);
}

.numpad-key.key-backspace {
    background: #fee2e2;
    color: var(--brand-red);
    border-color: #fecaca;
}
.numpad-key.key-backspace:hover {
    background: var(--brand-red);
    color: #ffffff;
}

/* Right Column Summary Box */
.payment-summary-box {
    background: #ffffff;
    border: 1.5px solid var(--border-color);
    border-radius: 12px;
    padding: 16px;
    display: flex;
    flex-direction: column;
    gap: 8px;
    box-shadow: var(--shadow-sm);
}

.pay-summary-line {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 12.5px;
    color: var(--text-muted);
}

.pay-summary-line.grand-total-row {
    font-size: 16px;
    font-weight: 800;
    color: var(--brand-navy);
    border-top: 1.5px dashed var(--border-color);
    border-bottom: 1.5px dashed var(--border-color);
    padding: 10px 0;
    margin: 4px 0;
}

.pay-summary-line.grand-total-row span:last-child {
    color: var(--brand-red);
    font-size: 22px;
    font-family: 'JetBrains Mono', monospace;
}

.change-due-banner {
    border-radius: 10px;
    padding: 14px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 10px;
    transition: all 0.2s;
}

.change-due-banner.green {
    background: #ecfdf5;
    border: 1.5px solid #a7f3d0;
}
.change-due-banner.green .cd-label { color: #065f46; font-weight: 700; font-size: 13px; }
.change-due-banner.green .cd-val { color: #047857; font-weight: 800; font-size: 22px; font-family: 'JetBrains Mono', monospace; }

.change-due-banner.red {
    background: #fef2f2;
    border: 1.5px solid #fecaca;
}
.change-due-banner.red .cd-label { color: #991b1b; font-weight: 700; font-size: 13px; }
.change-due-banner.red .cd-val { color: #dc2626; font-weight: 800; font-size: 22px; font-family: 'JetBrains Mono', monospace; }

.btn-complete-pay {
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
    color: #ffffff;
    border: none;
    border-radius: 10px;
    padding: 14px;
    font-size: 15px;
    font-weight: 800;
    cursor: pointer;
    margin-top: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    box-shadow: 0 4px 14px rgba(16, 185, 129, 0.35);
    transition: all 0.2s;
}

.btn-complete-pay:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(16, 185, 129, 0.45);
}

/* ==========================================
   TABLE TRANSFER / SPLIT / MERGE BILL STYLES
   ========================================== */
.split-tabs-bar {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
    background: #f1f5f9;
    padding: 4px;
    border-radius: var(--radius-sm);
    border: 1px solid var(--border-color);
    margin-bottom: 12px;
}

.split-tab-btn {
    background: transparent;
    border: none;
    color: var(--brand-navy);
    padding: 8px;
    border-radius: 6px;
    font-size: 13px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.2s;
}

.split-tab-btn.active {
    background: var(--brand-navy);
    color: #fff;
    box-shadow: var(--shadow-sm);
}

/* Equal Split Grid */
.equal-split-parts {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 12px;
    margin-top: 12px;
}

.equal-part-card {
    background: #f8fafc;
    border: 1.5px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 14px;
    display: flex;
    flex-direction: column;
    gap: 8px;
    text-align: center;
}

.equal-part-card.paid {
    background: #ecfdf5;
    border-color: #10b981;
}

.equal-part-title {
    font-size: 13px;
    font-weight: 800;
    color: var(--brand-navy);
}

.equal-part-amount {
    font-size: 20px;
    font-weight: 800;
    color: var(--brand-red);
    font-family: 'JetBrains Mono', monospace;
}

/* Item-by-Item Split 2-Column Board */
.item-split-board {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
    margin-top: 10px;
}

.item-split-col {
    background: #f8fafc;
    border: 1.5px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 12px;
    display: flex;
    flex-direction: column;
    gap: 8px;
    min-height: 260px;
}

.item-split-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1.5px solid var(--border-color);
    padding-bottom: 8px;
    font-size: 13px;
    font-weight: 800;
    color: var(--brand-navy);
}

.item-split-list {
    display: flex;
    flex-direction: column;
    gap: 6px;
    flex: 1;
    overflow-y: auto;
}

.item-split-row {
    background: #ffffff;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    padding: 8px 10px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 12px;
}

.btn-move-item {
    background: var(--brand-navy);
    color: #fff;
    border: none;
    border-radius: 4px;
    padding: 4px 8px;
    font-size: 11px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.2s;
}

.btn-move-item:hover {
    background: var(--brand-red);
}

/* Animations */
@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes slideUp {
    from { transform: translateY(16px); opacity: 0; }
    to { transform: translateY(0); opacity: 1; }
}

/* ==========================================
   TABLE SELECTOR HIGH-DENSITY RESPONSIVE STYLES
   ========================================== */
.table-selector-content {
    max-width: 1040px;
    width: 95vw;
    max-height: 88vh;
    border-radius: 14px;
}

.table-selector-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 14px 20px;
    background: #ffffff;
    border-bottom: 1px solid var(--border-color);
}

.table-selector-tabs {
    display: flex;
    gap: 6px;
    background: #f1f5f9;
    padding: 4px;
    border-radius: var(--radius-sm);
    border: 1px solid var(--border-color);
    overflow-x: auto;
}

.table-selector-tab {
    background: transparent;
    border: none;
    color: var(--brand-navy);
    font-size: 12px;
    font-weight: 700;
    padding: 6px 12px;
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.2s;
    white-space: nowrap;
}

.table-selector-tab:hover {
    background: rgba(255, 255, 255, 0.8);
}

.table-selector-tab.active {
    background: var(--brand-navy);
    color: #ffffff;
    box-shadow: var(--shadow-sm);
}

.table-selector-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(152px, 1fr));
    gap: 10px;
    padding: 2px;
    max-height: 60vh;
    overflow-y: auto;
}

.table-selector-card {
    background: #ffffff;
    border: 1.5px solid var(--border-color);
    border-radius: 10px;
    padding: 10px 12px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    min-height: 88px;
    box-sizing: border-box;
    overflow: hidden;
    transition: all 0.15s ease-in-out;
    position: relative;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04);
}

.table-selector-card.available {
    border-color: #a7f3d0;
    background: linear-gradient(180deg, #ffffff 0%, #ecfdf5 100%);
    cursor: pointer;
}

.table-selector-card.available:hover {
    transform: translateY(-2px);
    border-color: #10b981;
    box-shadow: 0 6px 16px rgba(16, 185, 129, 0.2);
}

.table-selector-card.occupied {
    background: linear-gradient(180deg, #ffffff 0%, #fef2f2 100%);
    border-color: #fca5a5;
    cursor: not-allowed;
    opacity: 0.94;
}

.table-selector-card.holding {
    background: linear-gradient(180deg, #ffffff 0%, #fffbeb 100%);
    border: 1.5px dashed #f59e0b;
    cursor: pointer;
}

.table-selector-card.holding:hover {
    transform: translateY(-2px);
    border-color: #d97706;
    box-shadow: 0 6px 16px rgba(217, 119, 6, 0.2);
}

.table-selector-card.selected {
    border: 2px solid var(--brand-red);
    background: #fff5f5;
    box-shadow: 0 2px 8px var(--primary-glow);
}

.tsc-top {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 6px;
}

.tsc-title {
    font-size: 14px;
    font-weight: 800;
    color: var(--brand-navy);
    line-height: 1.1;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.tsc-status-pill {
    font-size: 10px;
    font-weight: 800;
    padding: 2px 6px;
    border-radius: 4px;
    white-space: nowrap;
    flex-shrink: 0;
    line-height: 1;
}

.tsc-status-pill.available {
    background: #d1fae5;
    color: #065f46;
    border: 1px solid #a7f3d0;
}

.tsc-status-pill.occupied {
    background: #fee2e2;
    color: #991b1b;
    border: 1px solid #fecaca;
}

.tsc-status-pill.draft {
    background: #fef3c7;
    color: #92400e;
    border: 1px solid #fde68a;
}

.tsc-area {
    font-size: 10.5px;
    color: var(--text-muted);
    font-weight: 600;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    margin-top: 2px;
}

.tsc-bottom {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 6px;
    padding-top: 6px;
    border-top: 1px dashed rgba(0, 0, 0, 0.08);
}

.tsc-btn-select {
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
    color: #ffffff;
    border: none;
    padding: 4px 10px;
    border-radius: 4px;
    font-size: 11px;
    font-weight: 800;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 3px;
    box-shadow: 0 1px 4px rgba(16, 185, 129, 0.25);
    transition: all 0.15s;
    width: 100%;
    justify-content: center;
}

.tsc-btn-select:hover {
    transform: translateY(-1px);
    box-shadow: 0 3px 8px rgba(16, 185, 129, 0.35);
}

.tsc-occupied-row {
    font-size: 10.5px;
    color: #991b1b;
    font-weight: 700;
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
    font-family: 'JetBrains Mono', monospace;
}

.tsc-draft-btn {
    background: #f59e0b;
    color: #ffffff;
    border: none;
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 11px;
    font-weight: 800;
    cursor: pointer;
    width: 100%;
    text-align: center;
    box-shadow: 0 1px 4px rgba(245, 158, 11, 0.25);
}

/* Responsive adjustments */
@media (max-width: 1200px) {
    .table-selector-grid {
        grid-template-columns: repeat(auto-fill, minmax(145px, 1fr));
        gap: 8px;
    }
}

@media (max-width: 768px) {
    .table-selector-grid {
        grid-template-columns: repeat(auto-fill, minmax(130px, 1fr));
        gap: 6px;
    }
    .table-selector-card {
        padding: 8px;
        min-height: 80px;
    }
}

/* ==========================================
   PREMIUM MODAL FORM CONTROLS & ITEM EDIT STYLES
   ========================================== */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(15, 23, 42, 0.7);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
    padding: 20px;
    animation: fadeIn 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}

.modal-content {
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 18px;
    width: 100%;
    max-width: 540px;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25), 0 0 0 1px rgba(0, 0, 0, 0.05);
    display: flex;
    flex-direction: column;
    overflow: hidden;
    max-height: 90vh;
    animation: slideUp 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

.modal-content.wide {
    max-width: 720px;
}

.modal-content.extra-wide {
    max-width: 940px;
}

.modal-header {
    padding: 18px 24px;
    border-bottom: 1px solid #f1f5f9;
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: #ffffff;
}

.modal-header h3 {
    font-size: 18px;
    font-weight: 800;
    color: #0f172a;
    display: flex;
    align-items: center;
    gap: 8px;
}

.modal-header-desc {
    font-size: 12.5px;
    color: #64748b;
    margin-top: 3px;
    font-weight: 500;
}

.modal-close-btn {
    background: #f1f5f9;
    border: 1px solid #e2e8f0;
    color: #64748b;
    width: 34px;
    height: 34px;
    border-radius: 10px;
    cursor: pointer;
    font-size: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s;
}

.modal-close-btn:hover {
    background: #fee2e2;
    border-color: #fca5a5;
    color: #e11d48;
    transform: scale(1.05);
}

.modal-body {
    padding: 24px;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    gap: 18px;
    background: #ffffff;
}

.modal-footer {
    padding: 16px 24px;
    border-top: 1px solid #f1f5f9;
    display: flex;
    justify-content: flex-end;
    align-items: center;
    gap: 12px;
    background: #f8fafc;
}

/* Form Inputs & Fields */
.input-field, input[type="text"].input-field, input[type="number"].input-field, select.input-field {
    width: 100%;
    min-height: 42px;
    padding: 0 14px;
    border: 1.5px solid #e2e8f0;
    border-radius: 10px;
    background: #f8fafc;
    font-family: 'Outfit', sans-serif;
    font-size: 13.5px;
    font-weight: 600;
    color: #0f172a;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    outline: none;
    box-sizing: border-box;
    user-select: text !important;
    -webkit-user-select: text !important;
}

.input-field:hover {
    border-color: #cbd5e1;
    background: #ffffff;
}

.input-field:focus {
    border-color: #6366f1;
    background: #ffffff;
    box-shadow: 0 0 0 4px rgba(99, 102, 241, 0.12);
}

select.input-field {
    appearance: none;
    -webkit-appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 24 24' stroke='%2364748b' stroke-width='2'%3E%3Cpath stroke-linecap='round' stroke-linejoin='round' d='M19 9l-7 7-7-7'%3E%3C/path%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 14px center;
    background-size: 16px;
    padding-right: 38px;
    cursor: pointer;
}

textarea.input-field {
    height: auto !important;
    min-height: 72px;
    padding: 10px 14px;
    line-height: 1.5;
    resize: vertical;
}

.form-label {
    font-size: 12px;
    font-weight: 700;
    color: #334155;
    display: block;
    margin-bottom: 6px;
    letter-spacing: 0.2px;
}
.form-label .req {
    color: #e11d48;
    margin-left: 2px;
}

.item-form-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
}

/* Modern Image Upload Section */
.item-image-upload-wrap {
    display: flex;
    gap: 16px;
    align-items: center;
    background: #f8fafc;
    border: 1.5px dashed #cbd5e1;
    padding: 16px;
    border-radius: 14px;
    transition: all 0.2s;
}

.item-image-upload-wrap:hover {
    border-color: #6366f1;
    background: #fdfefe;
}

.item-img-preview {
    width: 84px;
    height: 84px;
    border-radius: 12px;
    object-fit: cover;
    background: #e2e8f0;
    border: 2px solid #ffffff;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
    flex-shrink: 0;
    transition: transform 0.2s;
}

.item-img-preview:hover {
    transform: scale(1.05);
}

.upload-file-btn {
    background: #ffffff;
    border: 1.5px solid #cbd5e1;
    color: #475569;
    border-radius: 8px;
    padding: 6px 12px;
    font-size: 12px;
    font-weight: 700;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    transition: all 0.2s;
}

.upload-file-btn:hover {
    background: #f1f5f9;
    border-color: #94a3b8;
    color: #0f172a;
}

/* Modern Modifiers Checkbox Grid */
.mod-selection-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: 10px;
    max-height: 160px;
    overflow-y: auto;
    background: #f8fafc;
    padding: 12px;
    border-radius: 12px;
    border: 1px solid #e2e8f0;
}

.mod-checkbox-label {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 9px 12px;
    background: #ffffff;
    border: 1.5px solid #e2e8f0;
    border-radius: 10px;
    font-size: 12.5px;
    font-weight: 600;
    color: #334155;
    cursor: pointer;
    transition: all 0.2s;
    user-select: none;
}

.mod-checkbox-label:hover {
    border-color: #6366f1;
    background: #fdfefe;
    transform: translateY(-1px);
}

.mod-checkbox-label.selected, .mod-checkbox-label:has(input:checked) {
    background: #eef2ff;
    border-color: #6366f1;
    color: #4338ca;
    font-weight: 700;
}

.mod-price-pill {
    font-family: 'JetBrains Mono', monospace;
    font-size: 11px;
    font-weight: 700;
    background: #f1f5f9;
    color: #64748b;
    padding: 2px 7px;
    border-radius: 6px;
}

.mod-checkbox-label:has(input:checked) .mod-price-pill {
    background: #c7d2fe;
    color: #3730a3;
}

/* Category & Modifier Manager Table Lists */
.manager-table-wrap {
    max-height: 300px;
    overflow-y: auto;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    background: #ffffff;
    margin-top: 14px;
}

.manager-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 16px;
    border-bottom: 1px solid #f1f5f9;
    transition: background 0.15s;
}
.manager-row:last-child { border-bottom: none; }
.manager-row:hover { background: #f8fafc; }

.manager-row-title {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 14px;
    font-weight: 700;
    color: #0f172a;
}

.manager-add-bar {
    display: flex;
    gap: 10px;
    background: #f8fafc;
    border: 1.5px solid #e2e8f0;
    padding: 14px;
    border-radius: 12px;
    align-items: center;
}

/* Buttons in Modals */
.btn-modal-cancel {
    background: #f1f5f9;
    border: 1px solid #e2e8f0;
    color: #475569;
    padding: 10px 20px;
    border-radius: 10px;
    font-size: 13.5px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.2s;
}

.btn-modal-cancel:hover {
    background: #e2e8f0;
    color: #0f172a;
}

.btn-modal-submit {
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
    border: none;
    color: #ffffff;
    padding: 10px 26px;
    border-radius: 10px;
    font-size: 13.5px;
    font-weight: 800;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 8px;
    box-shadow: 0 4px 14px rgba(16, 185, 129, 0.35);
    transition: all 0.2s;
}

/* ==========================================
   FOOD ICON PALETTE & CATEGORY MANAGER STYLES
   ========================================== */
.cat-icon-trigger-box {
    width: 64px;
    height: 44px;
    background: #ffffff;
    border: 1.5px solid #cbd5e1;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 4px;
    cursor: pointer;
    font-size: 22px;
    transition: all 0.2s;
    user-select: none;
    position: relative;
    flex-shrink: 0;
}

.cat-icon-trigger-box:hover {
    border-color: #6366f1;
    background: #fdfefe;
    transform: scale(1.03);
}

.food-icon-picker-panel {
    background: #ffffff;
    border: 1.5px solid #e2e8f0;
    border-radius: 14px;
    padding: 14px;
    box-shadow: 0 12px 30px -4px rgba(0, 0, 0, 0.15);
    margin-top: 10px;
    animation: fadeIn 0.15s ease-out;
}

.food-icon-palette-grid {
    display: grid;
    grid-template-columns: repeat(10, 1fr);
    gap: 6px;
    max-height: 180px;
    overflow-y: auto;
    padding: 4px;
}

.food-icon-option-btn {
    width: 38px;
    height: 38px;
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    cursor: pointer;
    transition: all 0.15s;
}

.food-icon-option-btn:hover {
    background: #eef2ff;
    border-color: #6366f1;
    transform: scale(1.15);
}

.food-icon-option-btn.selected {
    background: #c7d2fe;
    border-color: #4f46e5;
}

/* Category Manager Items Container (Matching Reference Screenshot) */
.category-manager-container {
    background: #f8fafc;
    border: 1.5px solid #e2e8f0;
    border-radius: 14px;
    padding: 14px;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.category-add-header-row {
    display: flex;
    align-items: center;
    gap: 10px;
}

.category-items-card-list {
    background: #ffffff;
    border: 1.5px solid #e2e8f0;
    border-radius: 12px;
    overflow: hidden;
    max-height: 340px;
    overflow-y: auto;
}

.category-item-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 18px;
    border-bottom: 1px solid #f1f5f9;
    transition: background 0.15s;
}

.category-item-row:last-child {
    border-bottom: none;
}

.category-item-row:hover {
    background: #f8fafc;
}

.category-item-info {
    display: flex;
    align-items: center;
    gap: 12px;
}

.category-item-icon {
    font-size: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.category-item-name {
    font-size: 14.5px;
    font-weight: 800;
    color: #0f172a;
}

.category-dish-count-badge {
    font-size: 11.5px;
    font-weight: 700;
    color: #64748b;
    background: #f1f5f9;
    padding: 3px 9px;
    border-radius: 12px;
    border: 1px solid #e2e8f0;
}

.btn-category-delete {
    background: #fff5f5;
    border: 1px solid #fecaca;
    color: #dc2626;
    border-radius: 8px;
    padding: 6px 14px;
    font-size: 12px;
    font-weight: 700;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 6px;
    transition: all 0.2s;
}

.btn-category-delete:hover {
    background: #fee2e2;
    border-color: #f87171;
    color: #b91c1c;
    transform: translateY(-1px);
}

/* Sales Slide-Out Sidebar Drawer Styles */
.sales-drawer-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(15, 23, 42, 0.5);
    backdrop-filter: blur(4px);
    z-index: 1050;
    display: flex;
    justify-content: flex-end;
    animation: fadeIn 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}

.sales-drawer-panel {
    width: 100%;
    max-width: 520px;
    height: 100vh;
    background: #ffffff;
    box-shadow: -4px 0 25px rgba(0, 0, 0, 0.15);
    display: flex;
    flex-direction: column;
    animation: slideInRight 0.25s cubic-bezier(0.16, 1, 0.3, 1);
    z-index: 1051;
}

@keyframes slideInRight {
    from { transform: translateX(100%); }
    to { transform: translateX(0); }
}

.sales-drawer-header {
    padding: 16px 20px;
    background: #f8fafc;
    border-bottom: 1.5px solid #e2e8f0;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-shrink: 0;
}

.sales-drawer-header-left {
    display: flex;
    align-items: center;
    gap: 10px;
}

.sales-drawer-title {
    font-size: 18px;
    font-weight: 900;
    color: #0f172a;
    font-family: 'JetBrains Mono', monospace;
    letter-spacing: -0.3px;
}

.sales-drawer-body {
    flex: 1;
    overflow-y: auto;
    padding: 20px;
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.sales-drawer-footer {
    padding: 14px 20px;
    background: #ffffff;
    border-top: 1.5px solid #e2e8f0;
    display: flex;
    gap: 10px;
    flex-shrink: 0;
    box-shadow: 0 -4px 12px rgba(0, 0, 0, 0.04);
}

.sales-drawer-action-btn {
    flex: 1;
    height: 42px;
    border-radius: 9px;
    font-size: 13px;
    font-weight: 800;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 7px;
    transition: all 0.15s ease;
    border: none;
}

.sales-drawer-action-btn.view-inv {
    background: #0f172a;
    color: #ffffff;
}

.sales-drawer-action-btn.view-inv:hover {
    background: #1e293b;
    transform: translateY(-1px);
}

.sales-drawer-action-btn.edit-sale {
    background: #eef2ff;
    color: #4f46e5;
    border: 1.5px solid #c7d2fe;
}

.sales-drawer-action-btn.edit-sale:hover {
    background: #e0e7ff;
    border-color: #818cf8;
}

.sales-drawer-action-btn.delete-sale {
    background: #fef2f2;
    color: #dc2626;
    border: 1.5px solid #fecaca;
    max-width: 110px;
}

.sales-drawer-action-btn.delete-sale:hover {
    background: #fee2e2;
    border-color: #f87171;
}

.sale-meta-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 10px;
    padding: 14px;
}

.sale-meta-item {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.sale-meta-label {
    font-size: 11px;
    font-weight: 700;
    color: #64748b;
    text-transform: uppercase;
    letter-spacing: 0.3px;
}

.sale-meta-val {
    font-size: 13px;
    font-weight: 800;
    color: #0f172a;
}

.sales-row-clickable {
    cursor: pointer;
    transition: background 0.15s ease;
}

.sales-row-clickable:hover {
    background: #f1f5f9 !important;
}

.sales-row-clickable.selected-row {
    background: #eef2ff !important;
    border-left: 3px solid #4f46e5;
}

/* ===================================================
   PREMIUM CUSTOM CONFIRM & ALERT MODAL SYSTEM (UI/UX)
   =================================================== */
.pos-dialog-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(15, 23, 42, 0.72);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 99999;
    padding: 16px;
    animation: dialogFadeIn 0.18s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

.pos-dialog-card {
    background: #ffffff;
    border-radius: 20px;
    width: 100%;
    max-width: 440px;
    box-shadow: 0 25px 60px -12px rgba(15, 23, 42, 0.35), 0 0 0 1px rgba(226, 232, 240, 0.8);
    overflow: hidden;
    display: flex;
    flex-direction: column;
    text-align: center;
    padding: 28px 24px 22px 24px;
    transform: scale(0.94) translateY(8px);
    animation: dialogPopIn 0.22s cubic-bezier(0.175, 0.885, 0.32, 1.275) forwards;
}

@keyframes dialogFadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes dialogPopIn {
    to {
        opacity: 1;
        transform: scale(1) translateY(0);
    }
}

.pos-dialog-icon-wrapper {
    width: 68px;
    height: 68px;
    border-radius: 22px;
    margin: 0 auto 16px auto;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 32px;
    box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.1);
    position: relative;
}

.pos-dialog-icon-wrapper.type-danger {
    background: linear-gradient(135deg, #fef2f2 0%, #fee2e2 100%);
    border: 2px solid #fecaca;
    color: #ef4444;
}

.pos-dialog-icon-wrapper.type-warning {
    background: linear-gradient(135deg, #fffbeb 0%, #fef3c7 100%);
    border: 2px solid #fde68a;
    color: #f59e0b;
}

.pos-dialog-icon-wrapper.type-primary {
    background: linear-gradient(135deg, #eef2ff 0%, #e0e7ff 100%);
    border: 2px solid #c7d2fe;
    color: #4f46e5;
}

.pos-dialog-icon-wrapper.type-success {
    background: linear-gradient(135deg, #ecfdf5 0%, #d1fae5 100%);
    border: 2px solid #a7f3d0;
    color: #10b981;
}

.pos-dialog-title {
    font-size: 19px;
    font-weight: 800;
    color: #0f172a;
    margin: 0 0 8px 0;
    letter-spacing: -0.3px;
    font-family: 'Outfit', sans-serif;
}

.pos-dialog-message {
    font-size: 13.5px;
    color: #64748b;
    line-height: 1.55;
    margin: 0 0 24px 0;
    font-weight: 500;
}

.pos-dialog-actions {
    display: flex;
    gap: 10px;
    width: 100%;
}

.pos-dialog-btn {
    flex: 1;
    padding: 12px 18px;
    border-radius: 12px;
    font-size: 13.5px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.15s ease;
    border: none;
    outline: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    font-family: 'Outfit', sans-serif;
}

.pos-dialog-btn:active {
    transform: scale(0.97);
}

.pos-dialog-btn-cancel {
    background: #f1f5f9;
    color: #475569;
    border: 1.5px solid #e2e8f0;
}

.pos-dialog-btn-cancel:hover {
    background: #e2e8f0;
    color: #0f172a;
}

.pos-dialog-btn-danger {
    background: linear-gradient(135deg, #ef4444 0%, #dc2626 100%);
    color: #ffffff;
    box-shadow: 0 6px 18px -3px rgba(239, 68, 68, 0.45);
}

.pos-dialog-btn-danger:hover {
    background: linear-gradient(135deg, #dc2626 0%, #b91c1c 100%);
    box-shadow: 0 8px 22px -3px rgba(220, 38, 38, 0.55);
}

.pos-dialog-btn-primary {
    background: linear-gradient(135deg, #4f46e5 0%, #4338ca 100%);
    color: #ffffff;
    box-shadow: 0 6px 18px -3px rgba(79, 70, 229, 0.45);
}

.pos-dialog-btn-primary:hover {
    background: linear-gradient(135deg, #4338ca 0%, #3730a3 100%);
    box-shadow: 0 8px 22px -3px rgba(67, 56, 202, 0.55);
}

.pos-dialog-btn-warning {
    background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
    color: #ffffff;
    box-shadow: 0 6px 18px -3px rgba(245, 158, 11, 0.45);
}

.pos-dialog-btn-warning:hover {
    background: linear-gradient(135deg, #d97706 0%, #b45309 100%);
}

.pos-dialog-btn-success {
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
    color: #ffffff;
    box-shadow: 0 6px 18px -3px rgba(16, 185, 129, 0.45);
}

.pos-dialog-btn-success:hover {
    background: linear-gradient(135deg, #059669 0%, #047857 100%);
}

