/* Enhanced Dine-In Modal Styles */
.dine-in-modal {
    --primary-blue: #007bff;
    --secondary-blue: #0056b3;
    --light-blue: #e3f2fd;
    --success-green: #28a745;
    --warning-orange: #ffc107;
    --danger-red: #dc3545;
    --gray-light: #f8f9fa;
    --gray-medium: #6c757d;
    --border-radius: 8px;
    --shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

/* Modal Container */
.dine-in-modal .modal-dialog {
    max-width: 1200px;
    width: 95%;
}

.dine-in-modal .modal-content {
    border: none;
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
}

.dine-in-modal .modal-header {
    background: linear-gradient(135deg, var(--primary-blue), var(--secondary-blue));
    color: white;
    border-bottom: none;
    border-radius: var(--border-radius) var(--border-radius) 0 0;
    padding: 1.5rem;
}

.dine-in-modal .modal-title {
    font-size: 1.5rem;
    font-weight: 600;
    margin: 0;
}

.dine-in-modal .modal-body {
    padding: 2rem;
    background: var(--gray-light);
    position: relative;
}

/* Floor Navigation */
.floor-nav {
    display: flex;
    gap: 0.5rem;
    margin-bottom: 2rem;
    flex-wrap: wrap;
}

.floor-tab {
    padding: 0.75rem 1.5rem;
    background: white;
    border: 2px solid #e9ecef;
    border-radius: var(--border-radius);
    color: var(--gray-medium);
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    text-decoration: none;
}

.floor-tab:hover {
    border-color: var(--primary-blue);
    color: var(--primary-blue);
    transform: translateY(-2px);
}

.floor-tab.active {
    background: var(--primary-blue);
    border-color: var(--primary-blue);
    color: white;
}

/* Table Grid */
.table-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 1rem;
    margin-bottom: 2rem;
}

.table-card {
    background: white;
    border-radius: var(--border-radius);
    padding: 1.5rem;
    box-shadow: var(--shadow);
    transition: all 0.3s ease;
    cursor: pointer;
    border: 3px solid transparent;
    position: relative;
    overflow: hidden;
    user-select: none;
}

.table-card::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 123, 255, 0.05);
    opacity: 0;
    transition: opacity 0.2s ease;
    pointer-events: none;
}

.table-card:hover::after {
    opacity: 1;
}

.table-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
}

.table-card.available {
    border-color: var(--success-green);
}

.table-card.occupied {
    border-color: var(--danger-red);
}

.table-card.reserved {
    border-color: var(--warning-orange);
}

/* Table Status Indicators */
.table-status {
    position: absolute;
    top: 0.5rem;
    right: 0.5rem;
    width: 12px;
    height: 12px;
    border-radius: 50%;
    border: 2px solid white;
}

.table-status.available {
    background: var(--success-green);
}

.table-status.occupied {
    background: var(--danger-red);
}

.table-status.reserved {
    background: var(--warning-orange);
}

/* Table Information */
.table-name {
    font-size: 1.25rem;
    font-weight: 600;
    color: #2c3e50;
    margin-bottom: 0.5rem;
}

.table-seats {
    color: var(--gray-medium);
    font-size: 0.9rem;
    margin-bottom: 0.5rem;
}

.table-orders {
    font-size: 0.85rem;
    color: var(--gray-medium);
    margin-bottom: 1rem;
}

.table-amount {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--primary-blue);
}

/* Table Card Hover Effects */
.table-card.available:hover {
    border-color: var(--secondary-blue);
}

.table-card.occupied:hover {
    border-color: #c82333;
}

/* Transfer Modal */
.transfer-modal .modal-dialog {
    max-width: 800px;
}

.transfer-options {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1rem;
    margin: 1.5rem 0;
}

.transfer-option {
    background: white;
    border: 2px solid #e9ecef;
    border-radius: var(--border-radius);
    padding: 1.5rem;
    cursor: pointer;
    transition: all 0.3s ease;
}

.transfer-option:hover {
    border-color: var(--primary-blue);
    transform: translateY(-2px);
}

.transfer-option.selected {
    border-color: var(--primary-blue);
    background: var(--light-blue);
}

/* Order Details */
.order-details {
    background: white;
    border-radius: var(--border-radius);
    padding: 1.5rem;
    margin-top: 1rem;
    box-shadow: var(--shadow);
}

.order-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.75rem 0;
    border-bottom: 1px solid #e9ecef;
}

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

.order-item-name {
    font-weight: 500;
    color: #2c3e50;
}

.order-item-qty {
    color: var(--gray-medium);
    font-size: 0.9rem;
}

.order-item-price {
    font-weight: 600;
    color: var(--primary-blue);
}

/* Statistics Panel */
.stats-panel {
    background: white;
    border-radius: var(--border-radius);
    padding: 1rem;
    margin-bottom: 1.5rem;
    box-shadow: var(--shadow);
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 0.75rem;
}

.stat-item {
    text-align: center;
    padding: 0.75rem 0.5rem;
    background: var(--gray-light);
    border-radius: var(--border-radius);
}

.stat-number {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--primary-blue);
    margin-bottom: 0.2rem;
}

.stat-label {
    font-size: 0.75rem;
    color: var(--gray-medium);
    text-transform: uppercase;
    letter-spacing: 0.3px;
}

/* Responsive Design */
@media (max-width: 768px) {
    .dine-in-modal .modal-dialog {
        width: 95%;
        margin: 1rem auto;
    }
    
    .dine-in-modal .modal-body {
        padding: 1rem;
    }
    
    .table-grid {
        grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
        gap: 0.75rem;
    }
    
    .table-card {
        padding: 1rem;
    }
    
    .table-name {
        font-size: 1.1rem;
    }
    
    .floor-nav {
        gap: 0.25rem;
    }
    
    .floor-tab {
        padding: 0.5rem 1rem;
        font-size: 0.9rem;
    }
    
    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 0.5rem;
    }
    
    .stat-item {
        padding: 0.5rem 0.25rem;
    }
    
    .stat-number {
        font-size: 1.25rem;
    }
    
    .stat-label {
        font-size: 0.7rem;
    }
}

@media (max-width: 480px) {
    .table-grid {
        grid-template-columns: 1fr;
    }
    
    .table-actions {
        flex-direction: column;
    }
    
    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 0.4rem;
    }
    
    .stat-item {
        padding: 0.4rem 0.2rem;
    }
    
    .stat-number {
        font-size: 1.1rem;
    }
    
    .stat-label {
        font-size: 0.65rem;
    }
}

/* Loading States */
.loading-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(255, 255, 255, 0.8);
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: var(--border-radius);
    z-index: 10;
}

.spinner {
    width: 40px;
    height: 40px;
    border: 4px solid #e9ecef;
    border-top: 4px solid var(--primary-blue);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Animations */
.fade-in {
    animation: fadeIn 0.3s ease-in;
}

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

.slide-in {
    animation: slideIn 0.3s ease-out;
}

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

/* Dark Mode Support */
[data-layout-mode="dark_mode"] .dine-in-modal .modal-body {
    background: #2a2e39;
}

[data-layout-mode="dark_mode"] .table-card {
    background: #3a3f4b;
    color: #ffffff;
}

[data-layout-mode="dark_mode"] .table-name {
    color: #ffffff;
}

[data-layout-mode="dark_mode"] .transfer-option {
    background: #3a3f4b;
    border-color: #4a4f5b;
    color: #ffffff;
}

[data-layout-mode="dark_mode"] .order-details {
    background: #3a3f4b;
    color: #ffffff;
}

[data-layout-mode="dark_mode"] .stats-panel {
    background: #3a3f4b;
    color: #ffffff;
}

[data-layout-mode="dark_mode"] .stat-item {
    background: #4a4f5b;
    color: #ffffff;
}

/* Context Menu Styles */
.context-menu {
    position: absolute;
    background: white;
    border-radius: var(--border-radius);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
    min-width: 200px;
    z-index: 1060;
    opacity: 0;
    visibility: hidden;
    transform: scale(0.95) translateY(-10px);
    transition: all 0.2s ease;
    border: 1px solid #e9ecef;
    top: 0;
    left: 0;
}

/* Make modal content relative for context menu positioning */
.dine-in-modal .modal-content {
    position: relative;
}

.context-menu.show {
    opacity: 1;
    visibility: visible;
    transform: scale(1) translateY(0);
}

.context-menu-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.75rem 1rem;
    background: var(--primary-blue);
    color: white;
    border-radius: var(--border-radius) var(--border-radius) 0 0;
    font-weight: 600;
    font-size: 0.9rem;
}

.context-menu-close {
    background: none;
    border: none;
    color: white;
    cursor: pointer;
    padding: 0.25rem;
    border-radius: 4px;
    transition: background-color 0.2s ease;
}

.context-menu-close:hover {
    background: rgba(255, 255, 255, 0.2);
}

.context-menu-actions {
    padding: 0.5rem 0;
}

.context-menu-action {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    width: 100%;
    padding: 0.75rem 1rem;
    background: none;
    border: none;
    color: #2c3e50;
    font-size: 0.9rem;
    cursor: pointer;
    transition: all 0.2s ease;
    text-align: left;
}

.context-menu-action:hover {
    background: var(--light-blue);
    color: var(--primary-blue);
}

.context-menu-action i {
    width: 16px;
    text-align: center;
    color: var(--gray-medium);
}

.context-menu-action:hover i {
    color: var(--primary-blue);
}

.context-menu-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.1);
    z-index: 1040;
    opacity: 0;
    visibility: hidden;
    transition: all 0.2s ease;
    border-radius: var(--border-radius);
}

.context-menu-overlay.show {
    opacity: 1;
    visibility: visible;
}

/* Dark mode support for context menu */
[data-layout-mode="dark_mode"] .context-menu {
    background: #3a3f4b;
    border-color: #4a4f5b;
}

[data-layout-mode="dark_mode"] .context-menu-action {
    color: #ffffff;
}

[data-layout-mode="dark_mode"] .context-menu-action:hover {
    background: #4a4f5b;
    color: #ffffff;
}

[data-layout-mode="dark_mode"] .context-menu-action i {
    color: #a0a0a0;
}

[data-layout-mode="dark_mode"] .context-menu-action:hover i {
    color: #ffffff;
}

/* Enhanced Transfer Modal Styles */
.transfer-modal .modal-dialog {
    max-width: 1000px;
}

.transfer-modal .modal-body {
    padding: 1.5rem;
    max-height: 70vh;
    overflow-y: auto;
}

/* Transfer Summary Flow */
.transfer-summary {
    background: linear-gradient(135deg, #f8f9fa, #e9ecef);
    border-radius: var(--border-radius);
    padding: 1.5rem;
    border: 1px solid #dee2e6;
}

.transfer-flow {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 2rem;
}

.transfer-step {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
}

.step-icon {
    width: 50px;
    height: 50px;
    background: var(--primary-blue);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.2rem;
}

.step-label {
    font-weight: 600;
    color: var(--gray-medium);
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.step-table {
    background: white;
    padding: 0.5rem 1rem;
    border-radius: var(--border-radius);
    border: 2px solid #e9ecef;
    font-weight: 600;
    color: var(--primary-blue);
    min-width: 120px;
    text-align: center;
}

.transfer-arrow {
    font-size: 1.5rem;
    color: var(--primary-blue);
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.5; }
}

/* Transfer Sections */
.transfer-section {
    background: white;
    border-radius: var(--border-radius);
    border: 1px solid #e9ecef;
    height: 100%;
    display: flex;
    flex-direction: column;
}

.section-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1rem 1.5rem;
    background: #f8f9fa;
    border-bottom: 1px solid #e9ecef;
    border-radius: var(--border-radius) var(--border-radius) 0 0;
}

.section-header h6 {
    margin: 0;
    color: #2c3e50;
    font-weight: 600;
}

.section-actions {
    display: flex;
    gap: 0.5rem;
}

/* Source Table Info */
.source-table-info {
    padding: 1rem 1.5rem;
    border-bottom: 1px solid #e9ecef;
}

.table-info-card {
    background: #f8f9fa;
    border-radius: var(--border-radius);
    padding: 1rem;
}

.table-info-header {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 1rem;
}

.table-info-header i {
    color: var(--primary-blue);
    font-size: 1.2rem;
}

.table-info-header .table-name {
    font-weight: 600;
    color: #2c3e50;
    font-size: 1.1rem;
}

.table-info-details {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.info-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.info-label {
    color: var(--gray-medium);
    font-size: 0.9rem;
}

.info-value {
    font-weight: 600;
    color: #2c3e50;
}

.info-value.occupied {
    color: var(--danger-red);
}

.info-value.amount {
    color: var(--primary-blue);
}

/* Order Summary */
.order-summary {
    padding: 1rem 1.5rem;
    flex: 1;
    overflow-y: auto;
}

.order-summary-card {
    background: #f8f9fa;
    border-radius: var(--border-radius);
    padding: 1rem;
    margin-bottom: 1rem;
}

.summary-header {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 1rem;
    color: #2c3e50;
    font-weight: 600;
}

.summary-content {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.summary-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.summary-label {
    color: var(--gray-medium);
    font-size: 0.9rem;
}

.summary-value {
    font-weight: 600;
    color: #2c3e50;
}

.summary-value.amount {
    color: var(--primary-blue);
}

/* Items List */
.items-list {
    margin-top: 1rem;
}

.items-header {
    font-weight: 600;
    color: #2c3e50;
    margin-bottom: 0.75rem;
    padding-bottom: 0.5rem;
    border-bottom: 1px solid #e9ecef;
}

.items-container {
    max-height: 200px;
    overflow-y: auto;
}

.item-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.5rem 0;
    border-bottom: 1px solid #f1f3f4;
}

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

.item-name {
    flex: 1;
    font-weight: 500;
    color: #2c3e50;
}

.item-qty {
    color: var(--gray-medium);
    font-size: 0.9rem;
    margin: 0 1rem;
}

.item-price {
    font-weight: 600;
    color: var(--primary-blue);
    min-width: 80px;
    text-align: right;
}

/* Target Tables Container */
.target-tables-container {
    padding: 1rem 1.5rem;
    flex: 1;
    overflow-y: auto;
}

.no-tables-message {
    text-align: center;
    padding: 2rem;
    color: var(--gray-medium);
}

.no-tables-message i {
    font-size: 2rem;
    margin-bottom: 1rem;
    color: var(--warning-orange);
}

.target-tables-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 1rem;
}

.target-table-card {
    background: white;
    border: 2px solid #e9ecef;
    border-radius: var(--border-radius);
    transition: all 0.3s ease;
    cursor: pointer;
}

.target-table-card:hover {
    border-color: var(--primary-blue);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 123, 255, 0.15);
}

.target-table-card.selected {
    border-color: var(--success-green);
    background: #f8fff9;
}

.table-card-header {
    padding: 1rem;
    border-bottom: 1px solid #e9ecef;
    position: relative;
}

.table-status {
    position: absolute;
    top: 0.75rem;
    right: 0.75rem;
    width: 12px;
    height: 12px;
    border-radius: 50%;
    border: 2px solid white;
}

.table-status.available {
    background: var(--success-green);
}

.table-card-header .table-name {
    font-weight: 600;
    color: #2c3e50;
    font-size: 1.1rem;
}

.table-card-body {
    padding: 1rem;
}

.table-info {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.info-row {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--gray-medium);
    font-size: 0.9rem;
}

.info-row i {
    width: 16px;
    text-align: center;
    color: var(--primary-blue);
}

.table-card-footer {
    padding: 1rem;
    border-top: 1px solid #e9ecef;
    text-align: center;
}

.select-table-btn {
    width: 100%;
    transition: all 0.3s ease;
}

.target-table-card.selected .select-table-btn {
    background: var(--success-green);
    border-color: var(--success-green);
    color: white;
}

/* Modal Footer */
.transfer-modal .modal-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 1.5rem;
    border-top: 1px solid #e9ecef;
    background: #f8f9fa;
}

.transfer-status {
    flex: 1;
}

.status-message {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.9rem;
    font-weight: 500;
}

.status-message.success {
    color: var(--success-green);
}

.status-message.info {
    color: var(--primary-blue);
}

.modal-actions {
    display: flex;
    gap: 0.75rem;
}

/* Responsive Design for Transfer Modal */
@media (max-width: 768px) {
    .transfer-modal .modal-dialog {
        margin: 1rem;
        max-width: calc(100% - 2rem);
    }
    
    .transfer-modal .modal-body {
        padding: 1rem;
        max-height: 60vh;
    }
    
    .transfer-flow {
        flex-direction: column;
        gap: 1rem;
    }
    
    .transfer-arrow {
        transform: rotate(90deg);
    }
    
    .target-tables-grid {
        grid-template-columns: 1fr;
    }
    
    .transfer-modal .modal-footer {
        flex-direction: column;
        gap: 1rem;
        align-items: stretch;
    }
    
    .modal-actions {
        justify-content: center;
    }
}

@media (max-width: 480px) {
    .transfer-summary {
        padding: 1rem;
    }
    
    .step-icon {
        width: 40px;
        height: 40px;
        font-size: 1rem;
    }
    
    .step-table {
        min-width: 100px;
        font-size: 0.9rem;
    }
    
    .section-header {
        padding: 0.75rem 1rem;
        flex-direction: column;
        gap: 0.5rem;
        align-items: stretch;
    }
    
    .section-actions {
        justify-content: center;
    }
}

/* Dark Mode Support for Transfer Modal */
[data-layout-mode="dark_mode"] .transfer-summary {
    background: linear-gradient(135deg, #2a2e39, #3a3f4b);
    border-color: #4a4f5b;
}

[data-layout-mode="dark_mode"] .transfer-section {
    background: #3a3f4b;
    border-color: #4a4f5b;
}

[data-layout-mode="dark_mode"] .section-header {
    background: #4a4f5b;
    border-color: #5a5f6b;
}

[data-layout-mode="dark_mode"] .table-info-card,
[data-layout-mode="dark_mode"] .order-summary-card {
    background: #4a4f5b;
}

[data-layout-mode="dark_mode"] .target-table-card {
    background: #3a3f4b;
    border-color: #4a4f5b;
}

[data-layout-mode="dark_mode"] .target-table-card.selected {
    background: #2a4a2a;
    border-color: var(--success-green);
}

[data-layout-mode="dark_mode"] .transfer-modal .modal-footer {
    background: #4a4f5b;
    border-color: #5a5f6b;
}

/* Table Details Modal Styles */
.table-actions-card {
    background: white;
    border-radius: var(--border-radius);
    padding: 1.5rem;
    box-shadow: var(--shadow);
    height: fit-content;
}

.table-actions-card h6 {
    color: #2c3e50;
    font-weight: 600;
    margin-bottom: 1rem;
    padding-bottom: 0.5rem;
    border-bottom: 1px solid #e9ecef;
}

.orders-section {
    background: white;
    border-radius: var(--border-radius);
    padding: 1.5rem;
    box-shadow: var(--shadow);
}

.orders-section h6 {
    color: #2c3e50;
    font-weight: 600;
    margin-bottom: 1rem;
    padding-bottom: 0.5rem;
    border-bottom: 1px solid #e9ecef;
}

.order-details-card {
    background: #f8f9fa;
    border-radius: var(--border-radius);
    padding: 1.5rem;
    border: 1px solid #e9ecef;
    transition: all 0.3s ease;
    height: 100%;
}

.order-details-card:hover {
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    transform: translateY(-2px);
}

.order-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 1rem;
    padding-bottom: 0.75rem;
    border-bottom: 1px solid #e9ecef;
}

.order-info {
    flex: 1;
}

.order-reference {
    font-weight: 600;
    color: var(--primary-blue);
    margin: 0 0 0.25rem 0;
    font-size: 1rem;
}

.order-customer {
    color: var(--gray-medium);
    font-size: 0.9rem;
}

.order-actions {
    display: flex;
    gap: 0.5rem;
}

.order-summary {
    margin-bottom: 1rem;
}

.summary-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.25rem 0;
    font-size: 0.9rem;
}

.summary-row span:first-child {
    color: var(--gray-medium);
}

.summary-row .amount {
    font-weight: 600;
    color: var(--primary-blue);
}

.order-items {
    margin-bottom: 1rem;
}

.order-items h6 {
    color: #2c3e50;
    font-weight: 600;
    margin-bottom: 0.75rem;
    font-size: 0.9rem;
}

.items-list {
    max-height: 150px;
    overflow-y: auto;
    background: white;
    border-radius: 4px;
    padding: 0.5rem;
    border: 1px solid #e9ecef;
}

.item-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.25rem 0;
    border-bottom: 1px solid #f1f3f4;
    font-size: 0.85rem;
}

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

.item-name {
    flex: 1;
    color: #2c3e50;
    font-weight: 500;
}

.item-qty {
    color: var(--gray-medium);
    margin: 0 0.5rem;
    min-width: 40px;
    text-align: center;
}

.item-price {
    font-weight: 600;
    color: var(--primary-blue);
    min-width: 80px;
    text-align: right;
}

.order-actions-footer {
    display: flex;
    gap: 0.5rem;
    padding-top: 0.75rem;
    border-top: 1px solid #e9ecef;
}

.order-actions-footer .btn {
    flex: 1;
    font-size: 0.8rem;
    padding: 0.375rem 0.75rem;
}

/* Dark Mode Support for Table Details */
[data-layout-mode="dark_mode"] .table-actions-card,
[data-layout-mode="dark_mode"] .orders-section {
    background: #3a3f4b;
    color: #ffffff;
}

[data-layout-mode="dark_mode"] .table-actions-card h6,
[data-layout-mode="dark_mode"] .orders-section h6 {
    color: #ffffff;
    border-color: #5a5f6b;
}

[data-layout-mode="dark_mode"] .order-details-card {
    background: #4a4f5b;
    border-color: #5a5f6b;
    color: #ffffff;
}

[data-layout-mode="dark_mode"] .order-header {
    border-color: #5a5f6b;
}

[data-layout-mode="dark_mode"] .order-reference {
    color: #64b5f6;
}

[data-layout-mode="dark_mode"] .order-customer {
    color: #a0a0a0;
}

[data-layout-mode="dark_mode"] .summary-row span:first-child {
    color: #a0a0a0;
}

[data-layout-mode="dark_mode"] .summary-row .amount {
    color: #64b5f6;
}

[data-layout-mode="dark_mode"] .order-items h6 {
    color: #ffffff;
}

[data-layout-mode="dark_mode"] .items-list {
    background: #3a3f4b;
    border-color: #5a5f6b;
}

[data-layout-mode="dark_mode"] .item-row {
    border-color: #5a5f6b;
}

[data-layout-mode="dark_mode"] .item-name {
    color: #ffffff;
}

[data-layout-mode="dark_mode"] .item-qty {
    color: #a0a0a0;
}

[data-layout-mode="dark_mode"] .item-price {
    color: #64b5f6;
}

[data-layout-mode="dark_mode"] .order-actions-footer {
    border-color: #5a5f6b;
}

/* Take Away Orders Grid */
.takeaway-orders-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 16px;
  padding: 8px 0;
}

/* Take Away Order Cards */
.takeaway-order-card {
  background: var(--card-bg);
  border: 1px solid var(--border-color);
  border-radius: 8px;
  padding: 16px;
  cursor: pointer;
  transition: all 0.2s ease;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.takeaway-order-card:hover {
  background: var(--hover-bg);
  border-color: var(--primary-color);
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.takeaway-order-card .order-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 4px;
}

.takeaway-order-card .order-reference {
  font-weight: 600;
  color: var(--text-primary);
  font-size: 1.1em;
}

.takeaway-order-card .order-customer {
  font-size: 0.9em;
  color: var(--text-secondary);
  margin-bottom: 4px;
}

.takeaway-order-card .order-amount {
  font-weight: 600;
  color: var(--primary-color);
  font-size: 1.1em;
  margin-bottom: 4px;
}

.takeaway-order-card .order-time {
  font-size: 0.8em;
  color: var(--text-secondary);
}

.takeaway-order-card .order-status {
  display: flex;
  align-items: center;
}

/* Dark mode styles for take-away order cards */
[data-bs-theme="dark"] .takeaway-order-card {
  background: var(--dark-card-bg);
  border-color: var(--dark-border-color);
}

[data-bs-theme="dark"] .takeaway-order-card:hover {
  background: var(--dark-hover-bg);
  border-color: var(--primary-color);
}

/* Modal Header Button Styles */
.modal-header .btn-outline-light {
  color: #ffffff !important;
  border-color: rgba(255, 255, 255, 0.5) !important;
  background-color: rgba(255, 255, 255, 0.1) !important;
}

.modal-header .btn-outline-light:hover {
  color: #000000 !important;
  background-color: #ffffff !important;
  border-color: #ffffff !important;
}

.modal-header .btn-outline-light i {
  color: inherit !important;
}

/* ========================================
   DELIVERY MODAL STYLES
   ======================================== */

/* Delivery Orders Grid */
.delivery-orders-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 1rem;
  margin-top: 1rem;
}

/* Delivery Order Card */
.delivery-order-card {
  background: #ffffff;
  border: 1px solid #e0e0e0;
  border-radius: 8px;
  padding: 1rem;
  cursor: pointer;
  transition: all 0.3s ease;
  position: relative;
}

.delivery-order-card:hover {
  border-color: #007bff;
  box-shadow: 0 4px 12px rgba(0, 123, 255, 0.15);
  transform: translateY(-2px);
}

.delivery-order-card .order-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 0.5rem;
}

.delivery-order-card .order-reference {
  font-weight: 600;
  color: #007bff;
  font-size: 0.9rem;
}

.delivery-order-card .order-status .badge {
  font-size: 0.7rem;
  padding: 0.25rem 0.5rem;
}

.delivery-order-card .order-customer {
  font-weight: 500;
  color: #333;
  margin-bottom: 0.25rem;
}

.delivery-order-card .order-amount {
  font-weight: 600;
  color: #28a745;
  font-size: 1.1rem;
  margin-bottom: 0.25rem;
}

.delivery-order-card .order-time {
  font-size: 0.8rem;
  color: #666;
}

/* Dark mode support for delivery modal */
[data-bs-theme="dark"] .delivery-order-card {
  background: #2d3748;
  border-color: #4a5568;
  color: #e2e8f0;
}

[data-bs-theme="dark"] .delivery-order-card:hover {
  border-color: #63b3ed;
  box-shadow: 0 4px 12px rgba(99, 179, 237, 0.15);
}

[data-bs-theme="dark"] .delivery-order-card .order-reference {
  color: #63b3ed;
}

[data-bs-theme="dark"] .delivery-order-card .order-customer {
  color: #e2e8f0;
}

[data-bs-theme="dark"] .delivery-order-card .order-time {
  color: #a0aec0;
}

/* Delivery context menu styles (reuse existing context menu styles) */
#delivery-context-menu {
  z-index: 1060; /* Ensure it appears above modals */
}

/* Delivery order details modal styles */
.delivery-order-details .order-items {
  max-height: 300px;
  overflow-y: auto;
}

.delivery-order-details .item-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.5rem 0;
  border-bottom: 1px solid #e0e0e0;
}

.delivery-order-details .item-row:last-child {
  border-bottom: none;
}

.delivery-order-details .item-name {
  flex: 1;
  font-weight: 500;
}

.delivery-order-details .item-qty {
  width: 60px;
  text-align: center;
  font-weight: 600;
  color: #007bff;
}

.delivery-order-details .item-price {
  width: 80px;
  text-align: right;
  font-weight: 600;
  color: #28a745;
}

.delivery-order-details .item-remarks {
  width: 100%;
  margin-top: 0.25rem;
  padding-left: 1rem;
}

/* Dark mode support for delivery order details */
[data-bs-theme="dark"] .delivery-order-details .item-row {
  border-bottom-color: #4a5568;
}

[data-bs-theme="dark"] .delivery-order-details .item-name {
  color: #e2e8f0;
}

[data-bs-theme="dark"] .delivery-order-details .item-qty {
  color: #63b3ed;
}

[data-bs-theme="dark"] .delivery-order-details .item-price {
  color: #68d391;
}