﻿:root {
    --bg-light: #F6F7F9;
    --card-bg: #FFFFFF;
    --text-primary: #111827;
    --text-secondary: #6B7280;
    --primary-color: #0d6efd; /* لون افتراضي ويمكن تغييره */
    --teal-color: #008080;
    --border-color: #E5E7EB;
    --chip-bg: #F9FAFB;
    --chip-selected-bg: #008080; /* Teal */
    --chip-text: #111827;
    --chip-selected-text: #FFFFFF;
}


body {
    background-color: var(--bg-light);
    font-family: 'Cairo', sans-serif;
    margin: 0;
    direction: rtl; /* دعم اللغة العربية */
}

/* Container */
.menu-page-container {
    max-width: 60%; /* لتقييد العرض وكأنه موبايل على شاشات الديسكتوب */
    margin: 0 auto;
    background-color: var(--bg-light);
    min-height: 100vh;
    padding-bottom: 20px;
}

/* Sticky Header */
.sticky-header {
    z-index: 1000;
    background-color: #023c3c;
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
    padding: 12px;
}

.header-content {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

/* Search Box */
.search-box {
    position: relative;
    border: 1px solid var(--border-color);
    border-radius: 14px;
    background-color: #F9FAFB;
    padding: 8px 12px;
    display: flex;
    align-items: center;
    gap: 8px;
}

    .search-box input {
        border: none;
        background: transparent;
        width: 100%;
        outline: none;
        font-family: 'Cairo';
        color: var(--text-primary);
    }

.search-icon {
    color: var(--text-secondary);
}

/* Sort Chips */
.sort-chips-container {
    display: flex;
    gap: 8px;
    overflow-x: auto;
    white-space: nowrap;
    scrollbar-width: none; /* Hide scrollbar Firefox */
}

    .sort-chips-container::-webkit-scrollbar {
        display: none;
    }

.chip-btn {
    border: 1px solid var(--border-color);
    border-radius: 999px;
    background-color: var(--chip-bg);
    padding: 6px 14px;
    font-family: 'Cairo';
    font-size: 12px;
    font-weight: bold;
    color: var(--chip-text);
    cursor: pointer;
    transition: all 0.2s;
}

    .chip-btn.active {
        background-color: var(--chip-selected-bg);
        color: var(--chip-selected-text);
        border-color: var(--chip-selected-bg);
    }

/* Category Chips */
.category-scroll-container {
    display: flex;
    gap: 10px;
    overflow-x: auto;
    white-space: nowrap;
    padding-bottom: 5px;
    scrollbar-width: none;
}

    .category-scroll-container::-webkit-scrollbar {
        display: none;
    }

.cat-chip {
    border: 1px solid var(--border-color);
    border-radius: 999px;
    background-color: var(--chip-bg);
    padding: 6px 14px;
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    font-family: 'Cairo';
    font-weight: bold;
    font-size: 12px;
    color: var(--chip-text);
}

    .cat-chip .badge {
        background-color: #E0F2FE;
        color: #0369A1;
        border-radius: 999px;
        padding: 2px 6px;
        font-size: 10px;
    }

    .cat-chip.active {
        background-color: var(--chip-selected-bg);
        color: white;
        border-color: var(--chip-selected-bg);
    }

        .cat-chip.active .badge {
            background-color: white;
            color: var(--chip-selected-bg);
        }

/* Indicator */
.status-indicator {
    font-size: 12px;
    color: var(--text-secondary);
}

/* Hero Section */
.hero-section {
    background-color: #008080;
    height: 35px;
    border-radius: 5px;
    margin: 10px 10px 0 10px;
    display: flex;
    align-items: flex-end;
    padding: 5px;
    position: relative;
    overflow: hidden;
}

.menu-title {
    color: white;
    font-size: 18px;
    font-weight: bold;
    margin: 0;
}

/* Business Info Card */
.business-card {
    background-color: white;
    border-radius: 18px;
    margin: 14px;
    padding: 14px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    box-shadow: 0 1px 3px rgba(0,0,0,0.05);
}

.business-name {
    font-size: 14px;
    font-weight: bold;
    margin: 0 0 4px 0;
    color: var(--text-primary);
}

.business-address {
    font-size: 12px;
    color: var(--text-secondary);
    margin: 0;
    max-width: 200px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.actions-side {
    display: flex;
    gap: 8px;
}

.action-btn {
    width: 40px;
    height: 40px;
    border-radius: 12px;
    display: flex;
    justify-content: center;
    align-items: center;
    text-decoration: none;
    font-size: 16px;
    transition: transform 0.1s;
}

    .action-btn:active {
        transform: scale(0.95);
    }

.call-btn {
    background-color: #E0F2FE;
    color: #0369A1;
}

.wa-btn {
    background-color: #ECFDF5;
    color: #047857;
}

.map-btn {
    background-color: #FFF7ED;
    color: #C2410C;
}

/* Item List Styles */
.items-list {
    padding: 0 14px 20px 14px;
}

/* Category Header Row */
.category-header-row {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-top: 20px;
    margin-bottom: 10px;
}

.cat-icon-box {
    width: 38px;
    height: 38px;
    background-color: #E0F2FE;
    color: #0369A1;
    border-radius: 12px;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 14px;
}

.cat-title {
    font-size: 14px;
    font-weight: bold;
    margin: 0;
    color: var(--text-primary);
}

/* Item Card */
.menu-item-card {
    background-color: white;
    border-radius: 18px;
    padding: 12px;
    margin-bottom: 10px;
    cursor: pointer;
    transition: background-color 0.2s;
}

    .menu-item-card:hover {
        background-color: #f8f9fa;
    }

.item-layout {
    display: flex;
    gap: 12px;
    align-items: center;
}

.item-img-container {
    width: 110px;
    height: 90px;
    flex-shrink: 0;
}

    .item-img-container img {
        width: 100%;
        height: 100%;
        object-fit: cover;
        border-radius: 16px;
        background-color: #F3F4F6;
    }

.item-content {
    flex-grow: 1;
    overflow: hidden;
}

.item-name {
    font-size: 14px;
    font-weight: bold;
    margin: 0 0 4px 0;
    color: var(--text-primary);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.item-price-row {
    display: flex;
    gap: 8px;
    margin-bottom: 4px;
}

.current-price {
    font-size: 12px;
    font-weight: bold;
    color: var(--text-primary);
}

.old-price {
    font-size: 12px;
    color: var(--text-secondary);
    text-decoration: line-through;
}

.item-desc {
    font-size: 11px;
    color: var(--text-secondary);
    margin: 0;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* Badge */
.item-badge-container {
    align-self: flex-start;
}

.item-badge {
    padding: 4px 8px;
    border-radius: 999px;
    font-size: 10px;
    font-weight: bold;
}

.badge-sale {
    background-color: #FFF7ED;
    color: #C2410C;
}

.badge-new {
    background-color: #ECFDF5;
    color: #047857;
}

/* Compact Mode Styles */
body.compact-mode .item-img-container {
    display: none;
}

body.compact-mode .item-desc {
    display: none;
}

body.compact-mode .menu-item-card {
    padding: 8px;
    border-radius: 8px;
    border: 1px solid #eee;
}


@media (max-width: 768px) {
    .menu-page-container {
        max-width: 90%;
        margin: 0 auto;
    }

    .sticky-header {
        top: 50px;
        background-color: #dfdfdf;
    }
}