/* css/style.css */
:root {
    --primary-orange: #f39c12;
    --primary-orange-dark: #e67e22;
    --primary-orange-light: #f5b041;
    --secondary-orange: #fd7e14;
    --soft-orange: #fff3e0;
    --danger: #e74c3c;
    --success: #27ae60;
    --warning: #f1c40f;
    --info: #3498db;
    --gray-light: #ecf0f1;
    --gray: #bdc3c7;
    --dark: #2c3e50;
    --shadow: 0 2px 10px rgba(0,0,0,0.1);
    --border-radius: 12px;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    background: dark;
    color: var(--dark);
    line-height: 1.6;
}

.app-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
    padding-bottom: 100px;
}

/* Header */
.header {
    background: linear-gradient(135deg, var(--primary-orange), var(--primary-orange-dark));
    color: white;
    padding: 20px;
    border-radius: var(--border-radius);
    margin-bottom: 20px;
    box-shadow: var(--shadow);
}

.header-content {
    display: flex;
    align-items: center;
    gap: 15px;
    flex-wrap: wrap;
}

.flag-icon {
    width: 40px;
    height: 40px;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.2);
}

.header h1 {
    font-size: 1.5rem;
    margin: 0;
    flex: 1;
}

/* Menu Groups */
.menu-groups {
    display: flex;
    gap: 10px;
    overflow-x: auto;
    padding: 10px 0;
    margin-bottom: 20px;
    scrollbar-width: thin;
}

.group-btn {
    padding: 12px 24px;
    background: white;
    border: 2px solid var(--primary-orange);
    border-radius: 50px;
    color: var(--primary-orange-dark);
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
    white-space: nowrap;
    font-size: 0.9rem;
}

.group-btn.active,
.group-btn:hover {
    background: var(--primary-orange);
    color: white;
    transform: translateY(-2px);
}

/* Menu Items */
.menu-container {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.menu-item {
    background: white;
    border-radius: var(--border-radius);
    padding: 15px;
    box-shadow: var(--shadow);
    transition: transform 0.2s;
}

.menu-item:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 20px rgba(0,0,0,0.15);
}

.item-info {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 12px;
    padding-bottom: 12px;
    border-bottom: 2px solid var(--soft-orange);
}

.item-info h3 {
    font-size: 1.1rem;
    color: var(--dark);
}

.price {
    font-weight: bold;
    color: var(--primary-orange-dark);
    font-size: 1.2rem;
}

.item-options {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.option-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 10px;
    padding: 8px;
    background: var(--soft-orange);
    border-radius: 8px;
}

.option-row span:first-child {
    font-weight: 500;
    min-width: 60px;
}

.quantity-control {
    display: flex;
    align-items: center;
    gap: 12px;
    background: white;
    padding: 4px 8px;
    border-radius: 30px;
}

.quantity-control button {
    width: 32px;
    height: 32px;
    border: none;
    background: var(--primary-orange);
    color: white;
    border-radius: 50%;
    font-size: 1.2rem;
    cursor: pointer;
    transition: all 0.2s;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.quantity-control button:hover {
    background: var(--primary-orange-dark);
    transform: scale(1.1);
}

.quantity-control button:active {
    transform: scale(0.95);
}

.qty-value {
    font-weight: bold;
    min-width: 30px;
    text-align: center;
    font-size: 1.1rem;
}

.item-subtotal {
    font-weight: bold;
    color: var(--primary-orange-dark);
    min-width: 70px;
    text-align: right;
}

/* Bottom Bar */
.bottom-bar {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: white;
    padding: 15px 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    box-shadow: 0 -2px 20px rgba(0,0,0,0.1);
    z-index: 1000;
    max-width: 1200px;
    margin: 0 auto;
}

.total-section {
    font-size: 1.3rem;
    font-weight: bold;
}

.total-label {
    color: var(--dark);
}

.total-amount {
    color: var(--primary-orange-dark);
    font-size: 1.5rem;
}

.review-btn,
.track-btn {
    padding: 12px 20px;
    border: none;
    border-radius: 30px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.review-btn {
    background: var(--primary-orange);
    color: white;
}

.track-btn {
    background: var(--gray-light);
    color: var(--dark);
}

.review-btn:hover,
.track-btn:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow);
}

/* Modals */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0,0,0,0.5);
    z-index: 2000;
    overflow-y: auto;
    padding: 20px;
}

.modal-content {
    background: white;
    max-width: 600px;
    margin: 50px auto;
    border-radius: var(--border-radius);
    overflow: hidden;
    animation: slideIn 0.3s;
}

.modal-content.large {
    max-width: 800px;
}

@keyframes slideIn {
    from {
        transform: translateY(-50px);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

.modal-header {
    background: var(--primary-orange);
    color: white;
    padding: 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.modal-header h2 {
    font-size: 1.3rem;
    margin: 0;
}

.close-modal {
    background: none;
    border: none;
    color: white;
    font-size: 1.8rem;
    cursor: pointer;
    line-height: 1;
}

.modal-body {
    padding: 20px;
    max-height: 60vh;
    overflow-y: auto;
}

.modal-footer {
    padding: 20px;
    display: flex;
    gap: 10px;
    justify-content: flex-end;
    border-top: 1px solid var(--gray-light);
}

/* Forms */
.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 500;
    color: var(--dark);
}

.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 10px;
    border: 2px solid var(--gray-light);
    border-radius: 8px;
    font-size: 1rem;
    transition: border-color 0.3s;
    font-family: inherit;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--primary-orange);
}

.phone-input {
    display: flex;
    align-items: center;
    gap: 10px;
}

.phone-prefix {
    background: var(--gray-light);
    padding: 10px;
    border-radius: 8px;
    font-weight: bold;
}

.phone-input input {
    flex: 1;
}

.checkbox-group {
    display: flex;
    gap: 15px;
    flex-wrap: wrap;
    margin: 15px 0;
}

.checkbox-group label {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    cursor: pointer;
}

/* Buttons */
.btn-primary,
.btn-secondary {
    padding: 12px 24px;
    border: none;
    border-radius: 30px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
}

.btn-primary {
    background: var(--primary-orange);
    color: white;
}

.btn-secondary {
    background: var(--gray-light);
    color: var(--dark);
}

.btn-primary:hover,
.btn-secondary:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow);
}

/* Dashboard Styles */
.dashboard-container,
.kitchen-container,
.admin-container {
    min-height: 100vh;
    background: #f8f9fa;
}

.dashboard-header,
.kitchen-header,
.admin-header {
    background: white;
    box-shadow: var(--shadow);
    position: sticky;
    top: 0;
    z-index: 100;
}

.dashboard-header .header-content,
.kitchen-header .header-content,
.admin-header .header-content {
    max-width: 1400px;
    margin: 0 auto;
    padding: 15px 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 15px;
}

.dashboard-nav {
    background: var(--dark);
    padding: 0 20px;
    overflow-x: auto;
    display: flex;
    gap: 5px;
}

.dashboard-nav a {
    padding: 12px 20px;
    color: white;
    text-decoration: none;
    font-weight: 500;
    transition: all 0.3s;
    white-space: nowrap;
}

.dashboard-nav a:hover,
.dashboard-nav a.active {
    background: var(--primary-orange);
}

.dashboard-main,
.kitchen-main,
.admin-main {
    max-width: 1400px;
    margin: 20px auto;
    padding: 0 20px;
}

/* Stats Cards */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}

.stat-card {
    background: white;
    padding: 20px;
    border-radius: var(--border-radius);
    display: flex;
    align-items: center;
    gap: 15px;
    box-shadow: var(--shadow);
    transition: transform 0.2s;
}

.stat-card:hover {
    transform: translateY(-5px);
}

.stat-card i {
    font-size: 2.5rem;
    color: var(--primary-orange);
}

.stat-info h3 {
    font-size: 0.85rem;
    color: var(--gray);
    margin-bottom: 5px;
}

.stat-number {
    font-size: 1.8rem;
    font-weight: bold;
    color: var(--dark);
}

.stat-card.pending i { color: var(--warning); }
.stat-card.processing i { color: var(--info); }
.stat-card.delivered i { color: var(--success); }
.stat-card.cancelled i { color: var(--danger); }
.stat-card.delivery i { color: #3498db; }
.stat-card.pickup i { color: #9b59b6; }
.stat-card.dinein i { color: #e67e22; }
.stat-card.revenue i { color: #27ae60; }

/* Orders Table */
.orders-section {
    background: white;
    border-radius: var(--border-radius);
    padding: 20px;
    box-shadow: var(--shadow);
    overflow-x: auto;
}

.orders-table {
    width: 100%;
    border-collapse: collapse;
}

.orders-table th,
.orders-table td {
    padding: 12px;
    text-align: left;
    border-bottom: 1px solid var(--gray-light);
}

.orders-table th {
    background: var(--soft-orange);
    font-weight: 600;
    color: var(--dark);
}

.order-type-badge {
    display: inline-block;
    padding: 4px 8px;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 500;
}

.order-type-badge.delivery { background: #e3f2fd; color: #1976d2; }
.order-type-badge.pickup { background: #f3e5f5; color: #7b1fa2; }
.order-type-badge.dinein { background: #fff3e0; color: #f57c00; }

.actions {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.actions button {
    padding: 6px 10px;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.2s;
}

.btn-view { background: var(--info); color: white; }
.btn-process { background: var(--warning); color: white; }
.btn-complete { background: var(--success); color: white; }
.btn-cancel { background: var(--danger); color: white; }

/* Kitchen Styles */
.kitchen-orders {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 20px;
}

.kitchen-card {
    background: white;
    border-radius: var(--border-radius);
    overflow: hidden;
    box-shadow: var(--shadow);
    transition: transform 0.2s;
}

.kitchen-card:hover {
    transform: translateY(-5px);
}

.kitchen-card.pending {
    border-left: 4px solid var(--warning);
}

.kitchen-card.processing {
    border-left: 4px solid var(--info);
}

.kitchen-card-header {
    background: var(--soft-orange);
    padding: 15px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 10px;
}

.kitchen-card-header h3 {
    font-size: 1.1rem;
    color: var(--dark);
}

.kitchen-card-body {
    padding: 15px;
}

.elapsed-time {
    margin: 10px 0;
    padding: 8px;
    border-radius: 6px;
    font-weight: bold;
}

.time-green { background: #d5f4e6; color: #27ae60; }
.time-yellow { background: #fff3cd; color: #f39c12; }
.time-red { background: #f8d7da; color: #e74c3c; }

.items-list ul {
    margin-top: 8px;
    padding-left: 20px;
}

.items-list li {
    margin: 5px 0;
    font-size: 0.9rem;
}

.kitchen-card-footer {
    padding: 15px;
    display: flex;
    gap: 10px;
    border-top: 1px solid var(--gray-light);
}

.kitchen-card-footer button {
    flex: 1;
    padding: 8px;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    font-weight: 500;
    transition: all 0.2s;
}

.no-orders {
    text-align: center;
    padding: 60px 20px;
    background: white;
    border-radius: var(--border-radius);
}

.no-orders i {
    font-size: 4rem;
    color: var(--primary-orange);
    margin-bottom: 20px;
}

/* Admin Styles */
.config-section {
    background: white;
    border-radius: var(--border-radius);
    padding: 20px;
    margin-bottom: 30px;
    box-shadow: var(--shadow);
}

.config-section h2 {
    margin-bottom: 20px;
    color: var(--dark);
    border-bottom: 2px solid var(--primary-orange);
    padding-bottom: 10px;
}

.sub-section {
    margin-top: 30px;
    padding-top: 20px;
    border-top: 1px solid var(--gray-light);
}

.sub-section h3 {
    margin-bottom: 15px;
    color: var(--primary-orange-dark);
}

.form-row {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    margin-bottom: 20px;
}

.hours-table {
    margin-bottom: 20px;
}

.hour-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px;
    border-bottom: 1px solid var(--gray-light);
    flex-wrap: wrap;
    gap: 10px;
}

.day-name {
    font-weight: 600;
    min-width: 100px;
}

.hour-controls {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}

.hour-controls input[type="time"] {
    padding: 6px;
    border: 1px solid var(--gray);
    border-radius: 6px;
}

.menu-items-list {
    margin-top: 20px;
}

.menu-group {
    margin-bottom: 30px;
}

.menu-group h4 {
    background: var(--soft-orange);
    padding: 10px;
    border-radius: 8px;
    margin-bottom: 15px;
}

.items-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 15px;
}

.menu-item-card {
    border: 1px solid var(--gray-light);
    border-radius: 8px;
    padding: 12px;
    transition: all 0.2s;
}

.menu-item-card:hover {
    box-shadow: var(--shadow);
}

.item-header {
    display: flex;
    justify-content: space-between;
    margin-bottom: 8px;
}

.item-options-badge {
    font-size: 0.8rem;
    color: var(--gray);
    margin: 8px 0;
}

.item-status {
    font-size: 0.8rem;
    padding: 4px 8px;
    border-radius: 20px;
    display: inline-block;
    margin: 8px 0;
}

.item-status.available {
    background: #d5f4e6;
    color: #27ae60;
}

.item-status.unavailable {
    background: #f8d7da;
    color: #e74c3c;
}

.item-actions {
    display: flex;
    gap: 8px;
    justify-content: flex-end;
}

.item-actions button {
    padding: 6px 10px;
    border: none;
    border-radius: 6px;
    cursor: pointer;
}

.btn-edit {
    background: var(--info);
    color: white;
}

.btn-delete {
    background: var(--danger);
    color: white;
}

/* Alert */
.alert {
    padding: 15px;
    border-radius: 8px;
    margin-bottom: 20px;
    animation: slideIn 0.3s;
}

.alert.success {
    background: #d5f4e6;
    color: #27ae60;
    border-left: 4px solid #27ae60;
}

/* Responsive */
@media (max-width: 768px) {
    .app-container {
        padding: 10px;
        padding-bottom: 90px;
    }
    
    .header h1 {
        font-size: 1.2rem;
    }
    
    .bottom-bar {
        flex-direction: column;
        gap: 10px;
    }
    
    .review-btn,
    .track-btn {
        width: 100%;
        justify-content: center;
    }
    
    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .kitchen-orders {
        grid-template-columns: 1fr;
    }
    
    .form-row {
        grid-template-columns: 1fr;
    }
    
    .modal-content {
        margin: 20px auto;
        width: 95%;
    }
    
    .orders-table {
        font-size: 0.85rem;
    }
    
    .actions {
        flex-direction: column;
    }
    
    .hour-row {
        flex-direction: column;
        align-items: flex-start;
    }
}

@media (max-width: 480px) {
    .stats-grid {
        grid-template-columns: 1fr;
    }
    
    .option-row {
        flex-direction: column;
        align-items: stretch;
    }
    
    .quantity-control {
        justify-content: center;
    }
    
    .item-subtotal {
        text-align: center;
    }
}

/* Print Styles */
@media print {
    .bottom-bar,
    .actions,
    .kitchen-card-footer,
    .dashboard-nav {
        display: none;
    }
    
    .modal {
        display: block;
        position: relative;
        background: white;
    }
}

/* Additional styles for JS components */

/* Alerts */
.alerts-container {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 10000;
    max-width: 350px;
}

.alert {
    background: white;
    border-radius: 8px;
    padding: 12px 16px;
    margin-bottom: 10px;
    display: flex;
    align-items: center;
    gap: 12px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
    animation: slideInRight 0.3s ease;
}

.alert-success {
    border-left: 4px solid var(--success);
    color: var(--success);
}

.alert-error {
    border-left: 4px solid var(--danger);
    color: var(--danger);
}

.alert-warning {
    border-left: 4px solid var(--warning);
    color: var(--warning);
}

.alert-info {
    border-left: 4px solid var(--info);
    color: var(--info);
}

.alert-close {
    margin-left: auto;
    background: none;
    border: none;
    font-size: 1.2rem;
    cursor: pointer;
    color: var(--gray);
}

/* Toast notifications */
.toast-container {
    position: fixed;
    bottom: 20px;
    right: 20px;
    z-index: 10000;
}

.toast {
    background: white;
    border-radius: 8px;
    padding: 12px 20px;
    display: flex;
    align-items: center;
    gap: 12px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
    animation: slideInUp 0.3s ease;
}

.toast-success {
    border-left: 4px solid var(--success);
}

.toast-error {
    border-left: 4px solid var(--danger);
}

.toast-warning {
    border-left: 4px solid var(--warning);
}

.toast-info {
    border-left: 4px solid var(--info);
}

/* Loading overlay */
.loading-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0,0,0,0.5);
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
}

.spinner {
    width: 50px;
    height: 50px;
    border: 4px solid rgba(255,255,255,0.3);
    border-top-color: var(--primary-orange);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

@keyframes slideInRight {
    from {
        transform: translateX(100%);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

@keyframes slideInUp {
    from {
        transform: translateY(100%);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

/* Modal open state */
body.modal-open {
    overflow: hidden;
}

/* Custom select */
.custom-select {
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%23666' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'%3E%3C/polyline%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 12px center;
    padding-right: 36px;
}

/* Status badges */
.status-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 500;
}

.status-pending {
    background: #fff3cd;
    color: #856404;
}

.status-processing {
    background: #cce5ff;
    color: #004085;
}

.status-delivered {
    background: #d4edda;
    color: #155724;
}

.status-cancelled {
    background: #f8d7da;
    color: #721c24;
}

/* Order type badges */
.order-type-badge {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 4px 10px;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 500;
}

.order-type-badge.delivery {
    background: #e3f2fd;
    color: #1976d2;
}

.order-type-badge.pickup {
    background: #f3e5f5;
    color: #7b1fa2;
}

.order-type-badge.dinein {
    background: #fff3e0;
    color: #f57c00;
}

/* Order info grid */
.order-info-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 16px;
    margin-bottom: 24px;
}

.info-group {
    background: var(--gray-light);
    padding: 12px;
    border-radius: 8px;
}

.info-group.full-width {
    grid-column: 1 / -1;
}

.info-group label {
    display: block;
    font-size: 0.8rem;
    color: var(--gray);
    margin-bottom: 4px;
}

.info-group p {
    font-weight: 500;
    margin: 0;
}

/* Items table */
.items-table {
    width: 100%;
    border-collapse: collapse;
    margin: 16px 0;
}

.items-table th,
.items-table td {
    padding: 10px;
    border-bottom: 1px solid var(--gray-light);
}

.items-table th {
    background: var(--soft-orange);
    font-weight: 600;
}

.items-table .text-center {
    text-align: center;
}

.items-table .text-right {
    text-align: right;
}

.items-table tfoot td {
    border-top: 2px solid var(--gray);
    font-weight: 500;
}

.items-table .total-row {
    background: var(--soft-orange);
    font-size: 1.1rem;
}

/* Modal actions */
.modal-actions {
    display: flex;
    gap: 12px;
    justify-content: flex-end;
    margin-top: 24px;
    padding-top: 16px;
    border-top: 1px solid var(--gray-light);
}

/* No data state */
.no-data {
    text-align: center;
    padding: 40px;
    color: var(--gray);
}

.no-data i {
    font-size: 3rem;
    margin-bottom: 12px;
}

/* Success icon */
.success-icon {
    text-align: center;
    font-size: 4rem;
    color: var(--success);
    margin-bottom: 20px;
}

/* Confirmation order */
.confirmation-order .order-summary {
    background: var(--gray-light);
    border-radius: 12px;
    padding: 20px;
    margin: 20px 0;
}

.summary-row {
    display: flex;
    justify-content: space-between;
    padding: 8px 0;
    border-bottom: 1px solid rgba(0,0,0,0.1);
}

.summary-row:last-child {
    border-bottom: none;
}

.order-number {
    font-family: monospace;
    font-size: 1.1rem;
    font-weight: bold;
    color: var(--primary-orange);
}

.total-row {
    display: flex;
    justify-content: space-between;
    padding: 12px 0;
    margin-top: 12px;
    border-top: 2px solid var(--primary-orange);
    font-size: 1.2rem;
}

.total-amount {
    color: var(--primary-orange-dark);
    font-size: 1.3rem;
}

.confirmation-actions {
    display: flex;
    gap: 12px;
    justify-content: center;
    margin-top: 20px;
}

/* Track result */
.track-result-card {
    background: var(--gray-light);
    border-radius: 12px;
    padding: 20px;
    margin-top: 20px;
}

.track-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 16px;
    padding-bottom: 12px;
    border-bottom: 2px solid var(--primary-orange);
}

.track-details .detail-row {
    display: flex;
    justify-content: space-between;
    padding: 8px 0;
    border-bottom: 1px dashed rgba(0,0,0,0.1);
}

.track-details .detail-row:last-child {
    border-bottom: none;
}

.elapsed-time {
    font-weight: bold;
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .order-info-grid {
        grid-template-columns: 1fr;
    }
    
    .modal-actions {
        flex-direction: column;
    }
    
    .modal-actions button {
        width: 100%;
    }
    
    .items-table {
        font-size: 0.85rem;
    }
    
    .items-table th,
    .items-table td {
        padding: 6px;
    }
}

@media print {
    .dashboard-nav,
    .modal-actions,
    .close-modal,
    .actions,
    .btn-primary,
    .btn-secondary {
        display: none !important;
    }
    
    .modal {
        position: relative;
        display: block;
        background: white;
    }
    
    .modal-content {
        box-shadow: none;
        margin: 0;
        padding: 0;
    }
}

/* Products Table Styles */
.products-table-container {
    background: white;
    border-radius: var(--border-radius);
    overflow-x: auto;
    box-shadow: var(--shadow);
}

.products-table {
    width: 100%;
    border-collapse: collapse;
}

.products-table th,
.products-table td {
    padding: 14px 12px;
    text-align: left;
    border-bottom: 1px solid var(--gray-light);
}

.products-table th {
    background: var(--soft-orange);
    font-weight: 600;
    color: var(--dark);
}

.products-table th.text-center,
.products-table td.text-center {
    text-align: center;
}

.rank-cell {
    width: 60px;
    font-size: 1.3rem;
    font-weight: bold;
    text-align: center;
}

.rank-1, .rank-2, .rank-3 {
    font-size: 1.5rem;
}

.rank-other {
    display: inline-block;
    width: 28px;
    height: 28px;
    background: var(--gray-light);
    border-radius: 50%;
    line-height: 28px;
    font-size: 0.85rem;
    font-weight: bold;
    color: var(--dark);
}

.product-name {
    font-weight: 500;
}

.quantity-cell {
    font-weight: 600;
    color: var(--primary-orange-dark);
}

.percentage-cell {
    min-width: 150px;
}

.percentage-bar-container {
    position: relative;
    background: var(--gray-light);
    border-radius: 20px;
    height: 28px;
    overflow: hidden;
    display: inline-block;
    width: 100%;
    max-width: 200px;
}

.percentage-bar {
    position: absolute;
    left: 0;
    top: 0;
    height: 100%;
    background: linear-gradient(90deg, var(--primary-orange), var(--primary-orange-dark));
    border-radius: 20px;
    transition: width 0.5s ease;
}

.percentage-text {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    height: 100%;
    font-size: 0.75rem;
    font-weight: bold;
    color: var(--dark);
    z-index: 1;
}

/* Filter section improvements */
.filter-card {
    background: white;
    border-radius: var(--border-radius);
    padding: 20px;
    margin-bottom: 30px;
    box-shadow: var(--shadow);
}

.filter-card h3 {
    margin-bottom: 16px;
    color: var(--dark);
    font-size: 1.1rem;
}

.filter-form .form-row {
    display: flex;
    gap: 15px;
    align-items: flex-end;
    flex-wrap: wrap;
}

.filter-form .form-group {
    margin-bottom: 0;
    flex: 1;
}

.filter-form .form-group label {
    display: block;
    margin-bottom: 5px;
    font-size: 0.85rem;
}

.filter-form input[type="date"] {
    width: 100%;
    padding: 10px;
    border: 2px solid var(--gray-light);
    border-radius: 8px;
    font-size: 0.9rem;
}

.filter-form button {
    margin-left: 0;
    white-space: nowrap;
}

/* Section header */
.section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    flex-wrap: wrap;
    gap: 10px;
}

.section-header h2 {
    font-size: 1.3rem;
    color: var(--dark);
}

.section-subtitle {
    font-size: 0.8rem;
    color: var(--gray);
}

.btn-small {
    padding: 6px 12px;
    background: var(--gray-light);
    border: none;
    border-radius: 20px;
    cursor: pointer;
    font-size: 0.8rem;
    transition: all 0.2s;
}

.btn-small:hover {
    background: var(--primary-orange);
    color: white;
}

/* Responsive */
@media (max-width: 768px) {
    .filter-form .form-row {
        flex-direction: column;
    }
    
    .filter-form button {
        width: 100%;
    }
    
    .products-table {
        font-size: 0.85rem;
    }
    
    .products-table th,
    .products-table td {
        padding: 10px 8px;
    }
    
    .rank-cell {
        width: 45px;
    }
    
    .percentage-bar-container {
        max-width: 120px;
    }
    
    .section-header {
        flex-direction: column;
        align-items: flex-start;
    }
}

/* Period Title */
.period-title {
    background: linear-gradient(135deg, var(--primary-orange), var(--primary-orange-dark));
    color: white;
    padding: 12px 20px;
    border-radius: var(--border-radius);
    margin-bottom: 25px;
    text-align: center;
}

.period-title h2 {
    font-size: 1.1rem;
    margin: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
}

.period-title i {
    font-size: 1.2rem;
}

/* Percentage badges on stat cards */
.percentage-badge {
    margin-top: 8px;
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    font-size: 0.7rem;
}

.percentage-count {
    background: rgba(243, 156, 18, 0.15);
    padding: 3px 8px;
    border-radius: 20px;
    color: var(--primary-orange-dark);
    font-weight: 500;
}

.percentage-amount {
    background: rgba(46, 204, 113, 0.15);
    padding: 3px 8px;
    border-radius: 20px;
    color: #27ae60;
    font-weight: 500;
}

.percentage-badge.cancelled .percentage-count {
    background: rgba(231, 76, 60, 0.15);
    color: var(--danger);
}

/* Cancelled card specific styles */
.stat-card.cancelled-card {
    border-left: 4px solid var(--danger);
}

.stat-card.cancelled-card i {
    color: var(--danger);
}

.stat-card.cancelled-card .stat-number {
    color: var(--danger);
}

/* Stat card hover effect */
.stat-card {
    transition: transform 0.2s, box-shadow 0.2s;
}

.stat-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.15);
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .period-title h2 {
        font-size: 0.9rem;
        flex-wrap: wrap;
    }
    
    .percentage-badge {
        flex-direction: column;
        gap: 4px;
    }
    
    .percentage-count,
    .percentage-amount {
        display: inline-block;
        text-align: center;
        font-size: 0.65rem;
    }
    
    .stat-card .stat-info small {
        font-size: 0.7rem;
    }
}

/* Customer info inline styles */
.customer-info-cell .customer-line {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}

.customer-name {
    font-weight: 500;
    color: var(--dark);
}

.customer-separator,
.datetime-separator {
    color: var(--gray);
    font-weight: normal;
}

.customer-phone {
    color: var(--primary-orange-dark);
    font-family: monospace;
}

/* Datetime inline styles */
.datetime-cell .datetime-line {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}

.order-date {
    font-weight: 500;
}

.order-time {
    color: var(--primary-orange-dark);
    font-family: monospace;
}

/* Detail info grid - inline rows */
.detail-info-grid {
    background: var(--gray-light);
    border-radius: var(--border-radius);
    padding: 16px;
    margin-bottom: 20px;
}

.info-row {
    display: flex;
    align-items: baseline;
    padding: 8px 0;
    border-bottom: 1px solid rgba(0,0,0,0.05);
}

.info-row:last-child {
    border-bottom: none;
}

.info-row.full-width {
    flex-direction: column;
    gap: 5px;
}

.info-label {
    min-width: 100px;
    font-weight: 600;
    color: var(--dark);
    font-size: 0.85rem;
}

.info-label i {
    width: 20px;
    color: var(--primary-orange);
    margin-right: 8px;
}

.info-value {
    flex: 1;
    color: var(--on-surface);
}

/* Table responsive */
.table-responsive {
    overflow-x: auto;
    margin: 16px 0;
}

/* Filter select styling */
.filter-form select {
    width: 100%;
    padding: 10px;
    border: 2px solid var(--gray-light);
    border-radius: 8px;
    font-size: 0.9rem;
    background-color: white;
    cursor: pointer;
}

.filter-form select:focus {
    outline: none;
    border-color: var(--primary-orange);
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .info-row {
        flex-direction: column;
        gap: 5px;
    }
    
    .info-label {
        min-width: auto;
    }
    
    .customer-info-cell .customer-line,
    .datetime-cell .datetime-line {
        flex-direction: column;
        align-items: flex-start;
        gap: 4px;
    }
    
    .customer-separator,
    .datetime-separator {
        display: none;
    }
    
    .orders-table th,
    .orders-table td {
        padding: 10px 8px;
    }
    
    .btn-view, .btn-complete, .btn-cancel {
        padding: 4px 8px;
        font-size: 0.7rem;
    }
}

/* Order type filter in orders section */
.order-actions {
    display: flex;
    align-items: center;
    gap: 15px;
    flex-wrap: wrap;
}

.order-type-filter {
    display: flex;
    align-items: center;
    gap: 10px;
    background: var(--gray-light);
    padding: 5px 12px;
    border-radius: 30px;
}

.order-type-filter label {
    font-size: 0.8rem;
    font-weight: 500;
    color: var(--dark);
    display: flex;
    align-items: center;
    gap: 5px;
}

.order-type-filter select {
    padding: 6px 12px;
    border: 1px solid var(--outline-variant);
    border-radius: 20px;
    background: white;
    font-size: 0.85rem;
    cursor: pointer;
    outline: none;
}

.order-type-filter select:focus {
    border-color: var(--primary-orange);
}

/* Loading and error states */
.loading-details {
    text-align: center;
    padding: 40px;
    color: var(--gray);
}

.loading-details i {
    font-size: 2rem;
    margin-bottom: 10px;
    display: inline-block;
}

.error-details {
    text-align: center;
    padding: 40px;
    color: var(--danger);
}

.error-details i {
    font-size: 3rem;
    margin-bottom: 15px;
    display: inline-block;
}

.error-details .small {
    font-size: 0.8rem;
    margin-top: 10px;
    color: var(--gray);
}

/* Detail info grid improvements */
.detail-info-grid {
    background: var(--gray-light);
    border-radius: var(--border-radius);
    padding: 16px;
    margin-bottom: 20px;
}

.info-row {
    display: flex;
    align-items: baseline;
    padding: 8px 0;
    border-bottom: 1px solid rgba(0,0,0,0.05);
}

.info-row:last-child {
    border-bottom: none;
}

.info-row.full-width {
    flex-direction: column;
    gap: 5px;
}

.info-label {
    min-width: 100px;
    font-weight: 600;
    color: var(--dark);
    font-size: 0.85rem;
}

.info-label i {
    width: 20px;
    color: var(--primary-orange);
    margin-right: 8px;
}

.info-value {
    flex: 1;
    color: var(--on-surface);
    word-break: break-word;
}

/* Responsive */
@media (max-width: 768px) {
    .order-actions {
        flex-direction: column;
        align-items: stretch;
    }
    
    .order-type-filter {
        justify-content: space-between;
    }
    
    .order-type-filter select {
        flex: 1;
    }
    
    .info-row {
        flex-direction: column;
        gap: 5px;
    }
    
    .info-label {
        min-width: auto;
    }
}

/* ============================================
   ESTILOS PARA MÓVIL - MAÍZ Y ARROZ EN MISMA FILA
   ============================================ */

/* Desktop - vertical */
.item-options {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

/* Mobile - grid de 2 columnas */
@media (max-width: 768px) {
    .item-options {
        display: grid !important;
        grid-template-columns: repeat(2, 1fr) !important;
        gap: 10px !important;
    }
    
    /* Si solo hay una opción, que ocupe toda la fila */
    .item-options:has(.option-row:only-child),
    .item-options.options-single {
        grid-template-columns: 1fr !important;
    }
    
    .option-row {
        display: flex !important;
        flex-direction: column !important;
        align-items: stretch !important;
        text-align: center !important;
        padding: 12px 8px !important;
        margin: 0 !important;
        background: var(--soft-orange);
        border-radius: 8px;
    }
    
    .option-row span:first-child {
        margin-bottom: 8px !important;
        font-weight: 600;
        font-size: 0.85rem;
    }
    
    .quantity-control {
        display: flex !important;
        justify-content: center !important;
        margin: 8px 0 !important;
    }
    
    .quantity-control button {
        width: 36px !important;
        height: 36px !important;
        font-size: 1.2rem !important;
    }
    
    .qty-value {
        font-size: 1rem !important;
        min-width: 35px !important;
    }
    
    .item-subtotal {
        text-align: center !important;
        margin-top: 5px !important;
        font-size: 0.8rem !important;
        font-weight: bold;
    }
}

/* Para pantallas muy pequeñas */
@media (max-width: 480px) {
    .item-options {
        gap: 8px !important;
    }
    
    .option-row {
        padding: 8px 6px !important;
    }
    
    .quantity-control button {
        width: 30px !important;
        height: 30px !important;
    }
    
    .qty-value {
        min-width: 28px !important;
    }
}