@import url('https://fonts.googleapis.com/css2?family=Noto+Sans+Arabic:wght@300;400;500;600;700;800&family=Inter:wght@300;400;500;600;700&family=IBM+Plex+Sans+Arabic:wght@300;400;500;600;700&display=swap');

/* Food Menu Specific Styles */

h1, h2, h3 {
    font-family: 'Poppins', 'IBM Plex Sans Arabic', sans-serif;
    font-weight: 600;
    letter-spacing: -0.3px;
}

.food-categories {
    display: flex;
    gap: 15px;
    margin: 30px 0;
    flex-wrap: wrap;
    justify-content: center;
}

.category-btn {
    font-family: 'Inter', 'Noto Sans Arabic', sans-serif;
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    color: var(--text-primary);
    padding: 14px 28px;
    border-radius: 12px;
    font-size: 1em;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
    backdrop-filter: blur(10px);
    text-transform: uppercase;
    letter-spacing: 1px;
}

.category-btn:hover {
    background: rgba(212, 114, 34, 0.12);
    border-color: rgba(212, 114, 34, 0.6);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(212, 114, 34, 0.15);
}

.category-btn.active {
    background: linear-gradient(135deg, rgba(212, 114, 34, 0.2) 0%, rgba(212, 114, 34, 0.1) 100%);
    border-color: rgba(212, 114, 34, 0.8);
    box-shadow: 0 4px 16px rgba(212, 114, 34, 0.2);
}

.food-items-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 25px;
    margin-bottom: 40px;
}

.food-item {
    background: var(--card-bg);
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 8px 24px var(--shadow);
    transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
    border: 1px solid var(--border-color);
    position: relative;
    backdrop-filter: blur(10px);
}

.food-item:hover {
    transform: translateY(-3px);
    box-shadow: 0 12px 32px rgba(212, 114, 34, 0.15);
    border-color: rgba(212, 114, 34, 0.3);
}

.food-item-image {
    width: 100%;
    height: 200px;
    object-fit: cover;
    background: #1a1a1a;
}

.food-item-content {
    padding: 20px;
}

.food-item-name {
    font-family: 'IBM Plex Sans Arabic', 'Noto Sans Arabic', sans-serif;
    font-size: 1.3em;
    font-weight: 600;
    color: var(--accent-primary);
    margin-bottom: 10px;
    letter-spacing: -0.01em;
    line-height: 1.2;
}

.food-item-description {
    font-family: 'Inter', 'Noto Sans Arabic', sans-serif;
    color: var(--text-secondary);
    font-size: 0.95em;
    margin-bottom: 16px;
    line-height: 1.5;
}

.food-item-price {
    font-family: 'Inter', 'Noto Sans Arabic', sans-serif;
    font-size: 1.2em;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 16px;
    letter-spacing: 0.01em;
}

.quantity-selection {
    margin-bottom: 15px;
}

.quantity-selection label {
    display: block;
    color: var(--accent-primary);
    font-size: 1em;
    font-weight: 600;
    margin-bottom: 8px;
}

.quantity-selection select {
    width: 100%;
    padding: 10px;
    border: 2px solid var(--border-color);
    border-radius: 8px;
    background: var(--input-bg);
    color: var(--text-primary);
    font-size: 1em;
    font-family: 'IBM Plex Sans Arabic', 'Noto Sans Arabic', sans-serif;
    transition: all 0.3s ease;
}

.quantity-selection select:focus {
    outline: none;
    border-color: #d47222;
    box-shadow: 0 0 8px rgba(212, 114, 34, 0.3);
}

.quantity-selection select option {
    background: #1a1a1a;
    color: #fff;
}

.meat-selection {
    margin-bottom: 15px;
}

.meat-selection label {
    display: block;
    color: var(--accent-primary);
    font-size: 1em;
    font-weight: 600;
    margin-bottom: 8px;
}

.meat-options {
    display: flex;
    gap: 10px;
    margin-bottom: 10px;
}

.meat-btn {
    font-family: 'Inter', 'Noto Sans Arabic', sans-serif;
    flex: 1;
    padding: 12px 16px;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    background: var(--card-bg);
    color: var(--text-primary);
    font-size: 0.95em;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
    backdrop-filter: blur(10px);
}

.meat-btn:hover {
    background: rgba(212, 114, 34, 0.12);
    border-color: rgba(212, 114, 34, 0.6);
}

.meat-btn.active {
    background: linear-gradient(135deg, rgba(212, 114, 34, 0.2) 0%, rgba(212, 114, 34, 0.1) 100%);
    border-color: rgba(212, 114, 34, 0.8);
    color: #d47222;
}

.food-item-actions {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 15px;
}

.quantity-controls {
    display: flex;
    align-items: center;
    gap: 10px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 25px;
    padding: 5px;
}

.quantity-btn {
    background: rgba(212, 114, 34, 0.3);
    border: none;
    color: #fff;
    width: 35px;
    height: 35px;
    border-radius: 50%;
    font-size: 1.2em;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.quantity-btn:hover {
    background: rgba(212, 114, 34, 0.6);
    transform: scale(1.1);
}

.quantity-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    transform: none;
}

.quantity-display {
    color: #fff;
    font-weight: 600;
    font-size: 1.1em;
    min-width: 30px;
    text-align: center;
}

.add-to-cart-btn {
    background: linear-gradient(135deg, #d47222 0%, #e88230 100%);
    color: #fff;
    border: none;
    padding: 12px 25px;
    border-radius: 25px;
    font-size: 1em;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    text-transform: uppercase;
    letter-spacing: 1px;
    flex: 1;
}

.add-to-cart-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(212, 114, 34, 0.4);
}

.add-to-cart-btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
}

/* Cart Section */
.cart-section {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(135deg, #1a1a1a 0%, #2d2d2d 100%);
    border-top: 2px solid rgba(212, 114, 34, 0.3);
    padding: 20px;
    box-shadow: 0 -5px 30px rgba(0, 0, 0, 0.5);
    z-index: 100;
    transform: translateY(100%);
    transition: transform 0.3s ease;
    max-height: 70vh;
    overflow-y: auto;
}

.cart-section.visible {
    transform: translateY(0);
}

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

.cart-header h3 {
    color: #d47222;
    font-size: 1.5em;
    margin: 0;
}

.cart-count {
    background: #d47222;
    color: #fff;
    padding: 5px 12px;
    border-radius: 20px;
    font-weight: 600;
    font-size: 0.9em;
}

.cart-items {
    max-height: 200px;
    overflow-y: auto;
    margin-bottom: 15px;
}

.cart-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

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

.cart-item-info {
    flex: 1;
}

.cart-item-name {
    color: #fff;
    font-weight: 600;
    margin-bottom: 5px;
}

.cart-item-details {
    color: #ccc;
    font-size: 0.9em;
}

.cart-item-controls {
    display: flex;
    align-items: center;
    gap: 10px;
}

.cart-item-price {
    color: #d47222;
    font-weight: 700;
    font-size: 1.1em;
}

.remove-item-btn {
    background: rgba(255, 0, 0, 0.2);
    border: 1px solid rgba(255, 0, 0, 0.3);
    color: #ff6b6b;
    width: 30px;
    height: 30px;
    border-radius: 50%;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.remove-item-btn:hover {
    background: rgba(255, 0, 0, 0.4);
    transform: scale(1.1);
}

.empty-cart {
    text-align: center;
    color: #ccc;
    font-style: italic;
    padding: 20px;
}

.cart-total {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 15px;
}

.total-amount {
    color: #fff;
    font-size: 1.3em;
    font-weight: 700;
}

.checkout-btn {
    background: linear-gradient(135deg, #d47222 0%, #e88230 100%);
    color: #fff;
    border: none;
    padding: 15px 30px;
    border-radius: 25px;
    font-size: 1.1em;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s ease;
    text-transform: uppercase;
    letter-spacing: 1px;
    flex: 1;
    max-width: 200px;
}

.checkout-btn:hover:not(:disabled) {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(212, 114, 34, 0.4);
}

.checkout-btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
}

/* Customer Form Styles */
.customer-form {
    padding: 30px;
}

.customer-form .form-group {
    margin-bottom: 25px;
}

.customer-form .form-group label {
    display: block;
    color: #fff;
    font-size: 1.2em;
    font-weight: 600;
    margin-bottom: 8px;
    text-align: right;
}

.customer-form .form-group input,
.customer-form .form-group textarea {
    width: 100%;
    padding: 15px;
    border: 2px solid rgba(212, 114, 34, 0.3);
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.05);
    color: #fff;
    font-size: 1.1em;
    font-family: 'Tajawal', Arial, sans-serif;
    transition: all 0.3s ease;
}

.customer-form .form-group input:focus,
.customer-form .form-group textarea:focus {
    outline: none;
    border-color: #d47222;
    box-shadow: 0 0 10px rgba(212, 114, 34, 0.3);
}

.customer-form .form-group input::placeholder,
.customer-form .form-group textarea::placeholder {
    color: #ccc;
}

.customer-form .phone-input {
    display: flex;
    align-items: center;
    background: rgba(255, 255, 255, 0.1);
    border: 2px solid rgba(212, 114, 34, 0.5);
    border-radius: 10px;
    overflow: hidden;
}

.customer-form .phone-prefix {
    background: rgba(212, 114, 34, 0.4);
    color: #d47222;
    padding: 15px;
    font-weight: 600;
    border-right: 1px solid rgba(212, 114, 34, 0.5);
}

.customer-form .phone-input input {
    border: none;
    background: transparent;
    flex: 1;
    padding: 15px;
    color: #f4f1eb;
    font-size: 1em;
}

.customer-form .phone-input input:focus {
    outline: none;
    background: rgba(255, 255, 255, 0.05);
}

.customer-form .phone-input:focus-within {
    border-color: #d47222;
    box-shadow: 0 0 10px rgba(212, 114, 34, 0.3);
}

.customer-form .form-actions {
    display: flex;
    gap: 15px;
    justify-content: center;
    margin-top: 30px;
}

.customer-form .cancel-btn,
.customer-form .submit-btn {
    padding: 15px 30px;
    border: none;
    border-radius: 50px;
    font-size: 1.2em;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    min-width: 120px;
}

.customer-form .cancel-btn {
    background: rgba(255, 255, 255, 0.1);
    color: #fff;
    border: 2px solid rgba(255, 255, 255, 0.3);
}

.customer-form .cancel-btn:hover {
    background: rgba(255, 255, 255, 0.2);
    border-color: rgba(255, 255, 255, 0.5);
}

.customer-form .submit-btn {
    background: linear-gradient(135deg, #d47222 0%, #e88230 100%);
    color: #fff;
    box-shadow: 0 5px 20px rgba(212, 114, 34, 0.4);
}

.customer-form .submit-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(212, 114, 34, 0.6);
}

.customer-form .submit-btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
}

/* Order Confirmation Modal Styles */
.confirmation-modal {
    max-width: 500px;
    text-align: center;
    background: linear-gradient(135deg, #2c1810 0%, #1a0f08 100%);
    border: 2px solid #d47222;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.5);
}

/* ===== Mobile Checkout Bar (always visible on mobile) ===== */
@media (max-width: 768px) {
  .mobile-checkout-bar {
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 15px;
    padding: 16px 20px;
    padding-bottom: max(16px, env(safe-area-inset-bottom));
    background: linear-gradient(180deg, rgba(26, 15, 8, 0.98) 0%, rgba(20, 12, 6, 1) 100%);
    border-top: 3px solid rgba(212, 114, 34, 0.7);
    backdrop-filter: saturate(150%) blur(12px);
    box-shadow: 0 -8px 32px rgba(0, 0, 0, 0.6), 0 -2px 8px rgba(212, 114, 34, 0.3);
    z-index: 99999;
    min-height: 75px;
  }
  .mobile-total {
    color: #fff;
    font-weight: 800;
    font-size: 1.2em;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 2px;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.5);
  }
  .mobile-total span:first-child {
    font-size: 0.75em;
    color: rgba(255, 255, 255, 0.7);
    font-weight: 600;
  }
  .mobile-checkout-btn {
    background: linear-gradient(135deg, #d47222 0%, #ff8c3a 100%);
    color: #fff;
    border: 2px solid rgba(255, 255, 255, 0.2);
    padding: 16px 28px;
    border-radius: 999px;
    font-size: 1.15em;
    font-weight: 900;
    letter-spacing: 0.5px;
    min-width: 160px;
    min-height: 52px;
    flex-shrink: 0;
    cursor: pointer;
    box-shadow: 0 8px 24px rgba(212, 114, 34, 0.6), 0 4px 12px rgba(255, 140, 58, 0.4);
    text-transform: uppercase;
    transition: all 0.2s ease;
    touch-action: manipulation;
    -webkit-tap-highlight-color: transparent;
  }
  .mobile-checkout-btn:active:not(:disabled) {
    transform: scale(0.97);
    box-shadow: 0 4px 12px rgba(212, 114, 34, 0.5);
  }
  .mobile-checkout-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    box-shadow: none;
    background: linear-gradient(135deg, #666 0%, #888 100%);
  }
  /* Provide bottom spacing to avoid content being hidden behind the fixed bar */
  body {
    padding-bottom: max(90px, calc(90px + env(safe-area-inset-bottom)));
  }
  .container {
    padding-bottom: 20px;
  }
}

.confirmation-header {
    padding: 30px 20px 20px;
    border-bottom: 1px solid rgba(212, 114, 34, 0.3);
}

.success-icon {
    width: 80px;
    height: 80px;
    background: linear-gradient(135deg, #4CAF50, #45a049);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 20px;
    font-size: 40px;
    color: white;
    font-weight: bold;
    box-shadow: 0 10px 20px rgba(76, 175, 80, 0.3);
    animation: successPulse 2s ease-in-out infinite;
}

@keyframes successPulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.05); }
}

.confirmation-header h2 {
    color: #d47222;
    font-size: 2.2em;
    margin: 0 0 15px;
    font-weight: 700;
}

.confirmation-message {
    color: #f4f1eb;
    font-size: 1.1em;
    margin: 0;
    line-height: 1.6;
}

.delivery-info {
    padding: 30px 20px;
    display: flex;
    align-items: center;
    gap: 20px;
    background: rgba(212, 114, 34, 0.1);
    margin: 20px 0;
    border-radius: 15px;
}

.delivery-icon {
    flex-shrink: 0;
    width: 60px;
    height: 60px;
    background: linear-gradient(135deg, #d47222, #b85d1e);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 5px 15px rgba(212, 114, 34, 0.3);
}

.delivery-icon img {
    width: 40px;
    height: 40px;
    filter: brightness(0) invert(1);
}

.delivery-icon:not(:has(img))::before {
    content: "🚚";
    font-size: 30px;
    display: block;
}

.delivery-text {
    text-align: right;
    flex: 1;
}

.delivery-text h3 {
    color: #d47222;
    font-size: 1.3em;
    margin: 0 0 8px;
    font-weight: 600;
}

.delivery-text p {
    color: #f4f1eb;
    font-size: 1em;
    margin: 0;
    line-height: 1.5;
}

.confirmation-actions {
    padding: 20px;
    display: flex;
    gap: 15px;
    justify-content: center;
}

.continue-btn, .close-btn {
    padding: 15px 30px;
    border: none;
    border-radius: 25px;
    font-size: 1.1em;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    min-width: 140px;
}

.continue-btn {
    background: linear-gradient(135deg, #d47222, #b85d1e);
    color: white;
    box-shadow: 0 5px 15px rgba(212, 114, 34, 0.3);
}

.continue-btn:hover {
    background: linear-gradient(135deg, #b85d1e, #a04f1a);
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(212, 114, 34, 0.4);
}

.close-btn {
    background: transparent;
    color: #d47222;
    border: 2px solid #d47222;
}

.close-btn:hover {
    background: #d47222;
    color: white;
    transform: translateY(-2px);
}

/* Floating Cart Button (Mobile) */
.floating-cart-btn {
    position: fixed;
    bottom: 20px;
    right: 20px;
    background: linear-gradient(135deg, #d47222 0%, #e88230 100%);
    color: #fff;
    border: none;
    border-radius: 50px;
    padding: 15px 25px;
    font-size: 1.1em;
    font-weight: 700;
    cursor: pointer;
    box-shadow: 0 8px 25px rgba(212, 114, 34, 0.5);
    z-index: 99;
    display: none;
    align-items: center;
    gap: 10px;
    transition: all 0.3s ease;
    animation: bounceIn 0.5s ease;
}

.floating-cart-btn.visible {
    display: flex;
}

.floating-cart-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 30px rgba(212, 114, 34, 0.6);
}

.floating-cart-btn .cart-badge {
    background: #fff;
    color: #d47222;
    border-radius: 50%;
    width: 28px;
    height: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 800;
    font-size: 0.9em;
    animation: pulse 2s ease infinite;
}

@keyframes bounceIn {
    0% { transform: scale(0); opacity: 0; }
    50% { transform: scale(1.1); }
    100% { transform: scale(1); opacity: 1; }
}

@keyframes pulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.1); }
}

/* Cart Toggle for Mobile */
.cart-toggle-header {
    display: none;
    justify-content: space-between;
    align-items: center;
    padding: 15px;
    background: rgba(212, 114, 34, 0.2);
    border-radius: 15px 15px 0 0;
    cursor: pointer;
    user-select: none;
}

.cart-toggle-header:active {
    background: rgba(212, 114, 34, 0.3);
}

.cart-toggle-icon {
    font-size: 1.5em;
    transition: transform 0.3s ease;
}

.cart-section.minimized .cart-toggle-icon {
    transform: rotate(180deg);
}

.cart-section.minimized .cart-items,
.cart-section.minimized .cart-total {
    display: none;
}

/* Responsive Design */
@media (max-width: 768px) {
    .food-items-grid {
        grid-template-columns: 1fr;
        gap: 20px;
        padding-bottom: 100px;
    }
    
    .food-categories {
        gap: 10px;
    }
    
    .category-btn {
        padding: 10px 20px;
        font-size: 1em;
    }
    
    .cart-section {
        padding: 0;
        border-radius: 20px 20px 0 0;
        max-height: 80vh;
    }
    
    .cart-toggle-header {
        display: flex;
    }
    
    .cart-header {
        padding: 15px;
        padding-top: 0;
    }
    
    .cart-items {
        padding: 0 15px;
        max-height: 250px;
    }
    
    .cart-total {
        padding: 15px;
        flex-direction: row;
        gap: 15px;
        background: rgba(212, 114, 34, 0.1);
        position: sticky;
        bottom: 0;
    }
    
    .checkout-btn {
        max-width: none;
        flex: 1;
        padding: 18px 30px;
        font-size: 1.2em;
        min-height: 56px;
        font-weight: 800;
        box-shadow: 0 6px 20px rgba(212, 114, 34, 0.5);
        touch-action: manipulation;
        -webkit-tap-highlight-color: transparent;
    }
    
    .checkout-btn:active:not(:disabled) {
        transform: scale(0.98);
    }
    
    .floating-cart-btn.visible {
        display: flex;
    }
    
    .food-item-actions {
        flex-direction: row;
        gap: 10px;
    }
    
    .quantity-controls {
        order: 1;
        flex: 0 0 auto;
    }
    
    .add-to-cart-btn {
        order: 2;
        flex: 1;
        padding: 12px 20px;
    }

    .meat-options {
        flex-direction: row;
        gap: 8px;
    }

    .meat-btn {
        padding: 12px 15px;
        font-size: 0.9em;
    }

    .confirmation-modal {
        max-width: 90%;
        margin: 10px;
    }

    .confirmation-header {
        padding: 20px 15px 15px;
    }

    .success-icon {
        width: 60px;
        height: 60px;
        font-size: 30px;
        margin-bottom: 15px;
    }

    .confirmation-header h2 {
        font-size: 1.8em;
        margin-bottom: 10px;
    }

    .confirmation-message {
        font-size: 1em;
    }

    .delivery-info {
        padding: 20px 15px;
        flex-direction: column;
        text-align: center;
        gap: 15px;
    }

    .delivery-text {
        text-align: center;
    }

    .confirmation-actions {
        flex-direction: column;
        gap: 10px;
    }

    .continue-btn, .close-btn {
        width: 100%;
        padding: 12px 20px;
        font-size: 1em;
    }
    
    /* Better mobile form */
    .customer-form {
        padding: 20px 15px;
    }
    
    .customer-form .form-group {
        margin-bottom: 20px;
    }
    
    .customer-form .form-group label {
        font-size: 1.1em;
    }
    
    .customer-form .form-group input,
    .customer-form .form-group textarea {
        padding: 14px;
        font-size: 1em;
    }
    
    .customer-form .form-actions {
        gap: 10px;
        margin-top: 25px;
    }
    
    .customer-form .cancel-btn,
    .customer-form .submit-btn {
        padding: 18px 30px;
        font-size: 1.2em;
        flex: 1;
        min-height: 56px;
        font-weight: 700;
        touch-action: manipulation;
        -webkit-tap-highlight-color: transparent;
    }
    
    .customer-form .submit-btn {
        box-shadow: 0 8px 24px rgba(212, 114, 34, 0.5);
    }
    
    .customer-form .submit-btn:active {
        transform: scale(0.98);
    }
}
