/* ==========================================
   IMPORT FONTS
========================================== */
@import url('https://fonts.googleapis.com/css2?family=Nunito:wght@400;600;700;800;900&family=Plus+Jakarta+Sans:wght@400;500;600;700&display=swap');

/* ==========================================
   CSS VARIABLES
========================================== */
:root {
    --primary: #FF6B35;
    --primary-light: #FFF0EB;
    --primary-dark: #E0521C;
    --bg: #F7F8FA;
    --surface: #FFFFFF;
    --text: #1A1A2E;
    --text-muted: #8E8EA0;
    --border: #EBEBF0;
    --success: #22C55E;
    --danger: #EF4444;
    --warning: #F59E0B;
    --info: #3B82F6;
    --radius-sm: 8px;
    --radius-md: 12px;
    --radius-lg: 18px;
    --radius-xl: 24px;
    --shadow-sm: 0 1px 4px rgba(0, 0, 0, 0.06);
    --shadow-md: 0 4px 16px rgba(0, 0, 0, 0.08);
    --shadow-lg: 0 8px 32px rgba(0, 0, 0, 0.12);
}

/* ==========================================
   BASE
========================================== */
* {
    box-sizing: border-box;
    -webkit-tap-highlight-color: transparent;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
}

@media (prefers-reduced-motion: reduce) {
    html {
        scroll-behavior: auto;
    }
}

body {
    font-family: 'Plus Jakarta Sans', sans-serif;
    background: var(--bg);
    color: var(--text);
    min-height: 100vh;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
}

/* Vertikal va gorizontal ichki scroll — silliq */
.cat-tabs-scroll,
.search-modal-results,
#menu-categories.menu-categories-inner,
#cart-modal .cart-scroll-body {
    scroll-behavior: smooth;
}

@media (prefers-reduced-motion: reduce) {
    .cat-tabs-scroll,
    .search-modal-results,
    #menu-categories.menu-categories-inner,
    #cart-modal .cart-scroll-body {
        scroll-behavior: auto;
    }
}

.hidden {
    display: none !important;
}

/* ==========================================
   CLIENT: HEADER
========================================== */
.glass-header {
    position: sticky;
    top: 0;
    z-index: 100;
    background: rgba(255, 255, 255, 0.92);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--border);
    padding-bottom: 0;
}

.client-sticky-row-1 {
    top: 0;
    z-index: 110;
}

.client-sticky-categories {
    top: var(--client-row1-h, 52px);
    z-index: 105;
    padding-bottom: 0;
    display: flex;
    flex-direction: column;
    border-bottom: 1px solid var(--border);
}

.cat-tab-indicator-track {
    position: relative;
    height: 3px;
    margin: 0 14px 4px;
    flex-shrink: 0;
    pointer-events: none;
}

.cat-tab-indicator {
    position: absolute;
    top: 0;
    left: 0;
    height: 3px;
    width: 2rem;
    background: #111;
    border-radius: 2px;
    opacity: 0;
    transform: translateX(0);
    transition:
        transform 0.32s cubic-bezier(0.22, 1, 0.36, 1),
        width 0.32s cubic-bezier(0.22, 1, 0.36, 1),
        opacity 0.2s ease;
    will-change: transform, width;
}

@media (prefers-reduced-motion: reduce) {
    .cat-tab-indicator {
        transition: opacity 0.15s ease;
    }
}

.header-liked-btn {
    flex-shrink: 0;
    width: 44px;
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 1.5px solid var(--border);
    border-radius: 50%;
    background: var(--surface);
    color: var(--primary);
    cursor: pointer;
    -webkit-tap-highlight-color: transparent;
    transition: transform 0.15s ease, background 0.2s;
}

.header-liked-btn:active {
    transform: scale(0.94);
    background: var(--primary-light);
}

.work-hours-badge .wh-label {
    font-weight: 800;
    color: var(--text-muted);
    margin-right: 4px;
}

.work-hours-badge .wh-time {
    font-weight: 700;
}

.cat-tabs-scroll {
    padding-top: 6px;
    padding-bottom: 2px;
}

.catalog-body {
    padding: 10px 14px calc(110px + env(safe-area-inset-bottom));
}

.catalog-section {
    margin-bottom: 36px;
    padding: 16px 14px 18px;
    background: var(--surface);
    border-radius: var(--radius-lg);
    border: 1px solid var(--border);
    box-shadow: var(--shadow-sm);
    scroll-margin-top: calc(var(--client-sticky-total, 140px) + 8px);
}

.catalog-section:last-child {
    margin-bottom: 8px;
}

.catalog-section-heading {
    font-size: clamp(19px, 4.5vw, 22px);
    font-weight: 800;
    margin: 0 0 16px;
    padding-bottom: 4px;
    color: var(--text);
    letter-spacing: -0.02em;
    line-height: 1.2;
}

.category-product-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 14px;
}

.search-flat-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 14px;
}

.cat-tab-pill {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 8px 4px;
    margin-right: 14px;
    margin-bottom: 0;
    background: none;
    border: none;
    font-size: 14px;
    font-weight: 600;
    color: var(--text-muted);
    cursor: pointer;
    font-family: 'Plus Jakarta Sans', sans-serif;
    white-space: nowrap;
    -webkit-tap-highlight-color: transparent;
    transition: color 0.2s, opacity 0.2s;
}

.cat-tab-pill:not(.is-active) {
    color: var(--text-muted);
    opacity: 0.88;
}

.cat-tab-pill.is-active {
    color: #111;
    font-weight: 800;
    opacity: 1;
}

.cat-tab-icon {
    width: 28px;
    height: 28px;
    border-radius: 8px;
    object-fit: cover;
    background: #f3f4f6;
    flex-shrink: 0;
}

.card-stepper-overlay {
    position: absolute;
    right: 8px;
    bottom: 8px;
    z-index: 3;
    display: flex;
    align-items: flex-end;
    justify-content: flex-end;
}

.card-stepper-overlay .card-add-circle {
    position: relative;
    right: auto;
    bottom: auto;
}

.card-stepper-overlay .card-qty-strip {
    position: relative;
    right: auto;
    bottom: auto;
}

.card-stepper-overlay .card-qty-compact-only {
    position: relative;
    right: auto;
    bottom: auto;
}

/* 1-qator: ish vaqti (chap) + qidiruv (o'ng) */
.header-top {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 14px 6px;
}

.work-hours-badge {
    display: flex;
    align-items: center;
    gap: 5px;
    font-size: 11px;
    font-weight: 700;
    color: var(--text-muted);
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 20px;
    padding: 6px 10px;
    white-space: nowrap;
    line-height: 1.4;
    flex-shrink: 0;
}

.work-hours-badge.open {
    color: #22a55b;
    border-color: rgba(34, 165, 91, 0.3);
    background: rgba(34, 165, 91, 0.08);
}

.work-hours-badge.closed {
    color: #e53e3e;
    border-color: rgba(229, 62, 62, 0.3);
    background: rgba(229, 62, 62, 0.08);
}

/* Compact qidiruv — header ichida, ish vaqti yonida */
.search-fake-compact {
    flex: 1;
    min-width: 0;
    padding: 7px 12px;
    font-size: 13px;
}

.menu-burger-btn {
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 5px;
    width: 44px;
    height: 44px;
    padding: 10px 8px;
    background: transparent;
    border: none;
    cursor: pointer;
    border-radius: 12px;
    flex-shrink: 0;
    -webkit-tap-highlight-color: transparent;
}

.menu-burger-btn:active {
    background: var(--primary-light);
}

.burger-line {
    display: block;
    height: 2.5px;
    width: 100%;
    background: var(--text);
    border-radius: 2px;
}

.store-title {
    font-family: 'Nunito', sans-serif;
    font-size: 22px;
    font-weight: 900;
    color: var(--text);
    letter-spacing: -0.5px;
    flex: 1;
    min-width: 0;
    text-align: left;
    line-height: 1.15;
}

.store-title span {
    color: var(--primary);
}

/* Header orders button */
.header-orders-btn {
    background: var(--primary-light);
    border: 1.5px solid var(--primary);
    border-radius: 50px;
    padding: 7px 12px;
    font-size: 11px;
    font-weight: 700;
    color: var(--primary);
    cursor: pointer;
    font-family: 'Plus Jakarta Sans', sans-serif;
    transition: all 0.2s;
    white-space: nowrap;
    flex-shrink: 0;
    max-width: 42%;
}

.menu-cat-btn {
    width: 100%;
    text-align: left;
    padding: 12px 14px;
    border: 1px solid var(--border);
    background: var(--surface);
    border-radius: 12px;
    font-size: 15px;
    font-weight: 600;
    color: var(--text);
    cursor: pointer;
    font-family: 'Plus Jakarta Sans', sans-serif;
    transition: background 0.15s, border-color 0.15s;
}

.menu-cat-btn:active {
    background: var(--primary-light);
    border-color: var(--primary);
}

.menu-cat-btn.menu-cat--selected,
.menu-cat-row-toggle.menu-cat--selected {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    border-color: var(--primary);
    color: #fff;
    box-shadow: 0 4px 14px rgba(255, 107, 53, 0.3);
}

.menu-cat-row-toggle.menu-cat--selected .menu-cat-chevron,
.menu-cat-row-toggle.menu-cat--selected .menu-cat-has-children-badge {
    color: #fff;
    opacity: 0.95;
}

.menu-cat-branch {
    margin-bottom: 6px;
}

.menu-cat-leaf {
    margin-bottom: 6px;
}

.menu-cat-row-toggle {
    width: 100%;
    display: flex;
    align-items: center;
    gap: 8px;
    text-align: left;
    padding: 12px 14px;
    border: 1px solid var(--border);
    background: var(--surface);
    border-radius: 12px;
    font-size: 15px;
    font-weight: 600;
    color: var(--text);
    cursor: pointer;
    font-family: 'Plus Jakarta Sans', sans-serif;
    transition: background 0.15s, border-color 0.15s;
    -webkit-tap-highlight-color: transparent;
}

.menu-cat-row-toggle:active {
    background: var(--primary-light);
    border-color: var(--primary);
}

.menu-cat-chevron {
    display: inline-block;
    flex-shrink: 0;
    width: 1.15em;
    text-align: center;
    font-size: 12px;
    color: var(--text-muted);
    transition: transform 0.2s ease;
}

.menu-cat-chevron.is-open {
    transform: rotate(90deg);
    color: var(--primary);
}

.menu-cat-toggle-label {
    flex: 1;
    min-width: 0;
}

.menu-cat-has-children-badge {
    font-size: 15px;
    line-height: 1;
    opacity: 0.75;
    flex-shrink: 0;
}

.menu-cat-children {
    margin-top: 6px;
    margin-left: 10px;
    padding-left: 10px;
    border-left: 2px solid var(--border);
}

.menu-cat-children[hidden] {
    display: none !important;
}

.header-orders-btn:active {
    background: var(--primary);
    color: white;
    transform: scale(0.96);
}

/* ==========================================
   CLIENT: CATEGORY TABS
========================================== */

.category-wrapper {
    overflow-x: auto;
    white-space: nowrap;
    padding: 8px 14px 4px;
    scrollbar-width: none;
}

.category-wrapper::-webkit-scrollbar {
    display: none;
}

.tab {
    display: inline-block;
    padding: 7px 16px;
    margin-right: 6px;
    background: var(--surface);
    border: 1.5px solid var(--border);
    border-radius: 50px;
    font-size: 13px;
    font-weight: 600;
    color: var(--text-muted);
    cursor: pointer;
    transition: all 0.2s;
    font-family: 'Plus Jakarta Sans', sans-serif;
}

.tab.active {
    background: var(--primary);
    border-color: var(--primary);
    color: white;
    box-shadow: 0 4px 12px rgba(255, 107, 53, 0.3);
}

.tab.back-btn {
    background: #f3f4f6;
    border-color: #d1d5db;
    color: #374151;
    font-weight: 600;
}

.tab.back-btn:hover {
    background: #e5e7eb;
    border-color: #9ca3af;
}

/* Joriy bo'lim (Orqaga yonida) — mijoz qayerdaligini ko'rsatish */
.tab.tab-current-location {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    border-color: var(--primary);
    color: #fff;
    cursor: default;
    pointer-events: none;
    box-shadow: 0 4px 14px rgba(255, 107, 53, 0.35);
    font-weight: 800;
}

.tab.tab-current-location.active {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    color: #fff;
}

/* ==========================================
   BOTTOM NAVIGATION (floating pill)
========================================== */
.bottom-nav {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    display: flex;
    justify-content: space-between;
    align-items: stretch;
    gap: 4px;
    margin: 10px 14px;
    margin-bottom: calc(10px + env(safe-area-inset-bottom));
    padding: 8px 10px;
    background: rgba(255, 255, 255, 0.94);
    border: 1px solid rgba(0, 0, 0, 0.06);
    border-radius: 26px;
    z-index: 100;
    box-shadow: 0 8px 32px rgba(26, 26, 46, 0.12);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
}

.nav-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 3px;
    padding: 6px 4px;
    background: none;
    border: none;
    cursor: pointer;
    transition: color 0.2s ease, transform 0.15s ease;
    position: relative;
    min-width: 0;
    flex: 1;
    color: #9ca3af;
    font-family: inherit;
}

.nav-icon-wrap {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s ease, color 0.2s ease, transform 0.2s ease;
}

.nav-svg {
    flex-shrink: 0;
}

.nav-label {
    font-size: 10px;
    font-weight: 700;
    color: inherit;
    letter-spacing: -0.2px;
    white-space: nowrap;
    max-width: 100%;
    overflow: hidden;
    text-overflow: ellipsis;
}

.nav-item--active {
    color: #2563eb;
}

.nav-item--active .nav-icon-wrap {
    background: #e8f0fe;
    color: #2563eb;
}

.nav-item:active {
    transform: scale(0.96);
}

.nav-badge {
    position: absolute;
    top: 4px;
    right: 8px;
    background: var(--primary);
    color: white;
    font-size: 10px;
    font-weight: 700;
    padding: 2px 6px;
    border-radius: 10px;
    min-width: 18px;
    text-align: center;
    display: none;
}

.nav-badge.show {
    display: block;
}

/* ==========================================
   CLIENT: PRODUCT GRID
========================================== */
.grid-container {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
    padding: 14px 14px calc(110px + env(safe-area-inset-bottom));
}

/* Skeleton (mijoz mahsulotlar yuklanmaguncha) */
.product-skeleton-card {
    pointer-events: none;
    cursor: default;
}

.product-skeleton-card .skeleton-pad {
    padding: 10px 12px 14px;
}

.skeleton-shimmer {
    background: linear-gradient(90deg, #ececec 0%, #f5f5f5 45%, #ececec 90%);
    background-size: 200% 100%;
    animation: skeleton-shimmer 1.1s ease-in-out infinite;
}

@keyframes skeleton-shimmer {
    0% { background-position: 100% 0; }
    100% { background-position: -100% 0; }
}

.product-card--stock-out {
    opacity: 0.72;
    filter: grayscale(0.35);
}

.product-card--stock-out .card-img-wrap img {
    filter: grayscale(0.45);
}

.product-card--stock-out .p-price-block,
.product-card--stock-out h4 {
    color: #888;
}

.card-stock-out-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 34px;
    padding: 0 12px;
    border-radius: 50px;
    font-size: 11px;
    font-weight: 800;
    color: #6b7280;
    background: rgba(255, 255, 255, 0.95);
    border: 1.5px solid rgba(0, 0, 0, 0.12);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
    letter-spacing: 0.02em;
    user-select: none;
    pointer-events: none;
}

.product-card {
    background: white;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.08);
    border: 1px solid rgba(0, 0, 0, 0.05);
    transition: transform 0.2s, box-shadow 0.2s;
    cursor: pointer;
    display: flex;
    flex-direction: column;
}

.product-card:active {
    transform: scale(0.97);
}

.product-card:hover {
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.12);
}

.card-img-wrap {
    position: relative;
    overflow: hidden;
    aspect-ratio: 1;
}

.product-card img,
.card-img-wrap img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    background: #f5f5f5;
    transition: transform 0.3s;
}

/* ==========================================
   CLIENT: PAYMENT UI
   ========================================== */
.payment-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
    margin-bottom: 20px;
}

.payment-option-card {
    background: var(--surface);
    border: 2px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 14px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 8px;
    cursor: pointer;
    transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
    min-height: 85px;
}

.payment-option-card.active {
    border-color: var(--primary);
    background: linear-gradient(135deg, var(--primary) 0%, #ff8c61 100%);
    color: white;
    box-shadow: 0 4px 15px rgba(255, 107, 53, 0.25);
    transform: scale(1.02);
}

.payment-option-card.active * {
    color: white;
}

.payment-option-card.active .pay-label {
    color: var(--primary);
}

.payment-option-card .pay-icon {
    font-size: 24px;
}

.payment-option-card .pay-label {
    font-size: 13px;
    font-weight: 700;
    color: var(--text-muted);
    transition: color 0.2s;
}

.payment-option-card .pay-logo {
    height: 22px;
    width: auto;
    object-fit: contain;
}

/* App Link Button Customization */
#app-payment-section {
    margin-top: 14px !important;
    margin-bottom: 18px !important;
}

#receipt-upload-section {
    margin-top: 14px !important;
    margin-bottom: 16px !important;
}

#cart-modal #checkout-btn {
    margin-top: 18px;
}

#app-payment-section .tg-button {
    background: var(--surface) !important;
    color: var(--primary) !important;
    border: 2px solid var(--primary) !important;
    box-shadow: 0 4px 12px rgba(255, 107, 53, 0.1) !important;
}

#app-payment-section .tg-button:active {
    background: var(--primary-light) !important;
    transform: scale(0.97);
}
.img-count-badge {
    position: absolute;
    bottom: 6px;
    right: 6px;
    background: rgba(0, 0, 0, 0.65);
    color: white;
    font-size: 11px;
    font-weight: 700;
    padding: 3px 8px;
    border-radius: 50px;
    backdrop-filter: blur(4px);
}

.p-info {
    padding: 10px 12px 12px;
    flex: 1;
    display: flex;
    flex-direction: column;
}

/* Nom va narx — yuqori qism, flex:1 bilan pastga siqiladi */
.p-info-top {
    flex: 1;
}

.price-stock-row {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 4px;
    margin-bottom: 6px;
    flex-wrap: wrap;
}

.stock-badge {
    font-size: 10px;
    background: #f0f7ff;
    color: #007aff;
    padding: 2px 6px;
    border-radius: 6px;
    font-weight: 600;
    border: 1px solid #d0e7ff;
    flex-shrink: 0;
}

.product-card h4 {
    font-size: 13px;
    font-weight: 700;
    line-height: 1.35;
    display: -webkit-box;
    -webkit-line-clamp: 1;
    line-clamp: 1;
    -webkit-box-orient: vertical;
    overflow: hidden;
    color: #1a1a1a;
    margin: 0 0 4px;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    min-height: 0;
}

.p-info--catalog {
    padding: 10px 12px 12px;
    display: flex;
    flex-direction: column;
    gap: 2px;
    flex: 1;
}

.p-price-stack {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 2px;
    margin-bottom: 6px;
}

.p-price-stack .old-price-sm {
    font-size: 11px;
    opacity: 0.85;
}

.p-price-stack .price-current {
    font-size: 15px;
    font-weight: 800;
    color: #ff6b35;
    line-height: 1.2;
}

.p-price-stack .discount-timer-hms {
    font-size: 11px;
    font-weight: 700;
    color: #f97316;
    font-variant-numeric: tabular-nums;
    letter-spacing: 0.02em;
}

.p-stock-line {
    font-size: 11px;
    color: var(--text-muted);
    font-weight: 600;
}

.price {
    color: #ff6b35;
    font-weight: 800;
    font-size: 14px;
    margin-bottom: 0;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

.old-price-strike {
    position: relative;
    display: inline-block;
    color: #333;
    font-weight: 600;
    margin-right: 4px;
}

.old-price-strike::after {
    content: "";
    position: absolute;
    top: 50%;
    left: -10%;
    width: 120%;
    height: 2.5px;
    background-color: #EF4444;
    transform: rotate(-12deg);
    transform-origin: center;
    border-radius: 4px;
}


/* ── Savat stepper (karta ichida, o'ng tomonda) ── */
.card-stepper-wrap {
    display: flex;
    justify-content: flex-end;
    align-items: center;
    margin-top: auto;
    padding-top: 8px;
    min-height: 36px;
}

.icon-search-black {
    color: #111;
    display: block;
    flex-shrink: 0;
}

.search-modal-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    color: #111;
}

/* + doira tugma (savat bo'sh) — oq fon, qora + */
.card-add-circle {
    width: 34px;
    height: 34px;
    border-radius: 50%;
    background: #fff;
    border: 1.5px solid rgba(0, 0, 0, 0.14);
    color: #111;
    font-size: 22px;
    line-height: 1;
    font-weight: 400;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    transition: transform 0.15s, box-shadow 0.15s;
    flex-shrink: 0;
}
.card-add-circle:active { transform: scale(0.88); }

/* - qty + strip — oq fon, qora − son + */
.card-qty-strip {
    display: flex;
    align-items: center;
    gap: 0;
    background: #fff;
    border: 1.5px solid rgba(0, 0, 0, 0.14);
    border-radius: 50px;
    overflow: hidden;
    transform-origin: right center;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
    will-change: transform;
}
.card-qty-strip--animate {
    animation: stripExpandLeft 0.62s cubic-bezier(0.22, 1, 0.36, 1) both;
}
@keyframes stripExpandLeft {
    from {
        opacity: 0.72;
        transform: scaleX(0.16);
    }
    to {
        opacity: 1;
        transform: scaleX(1);
    }
}
.card-qty-strip button {
    width: 34px;
    height: 32px;
    background: none;
    border: none;
    color: #111;
    font-size: 18px;
    font-weight: 700;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    line-height: 1;
    transition: background 0.1s;
    flex-shrink: 0;
}
.card-qty-strip button:active { background: rgba(0, 0, 0, 0.06); }
.card-qty-num {
    min-width: 28px;
    text-align: center;
    font-size: 14px;
    font-weight: 800;
    color: #111;
    user-select: none;
    padding: 0 6px;
}

/* Kompakt miqdor — oq, qora raqam */
.card-qty-compact-only {
    min-width: 34px;
    height: 34px;
    padding: 0 10px;
    border-radius: 50px;
    border: 1.5px solid rgba(0, 0, 0, 0.14);
    background: #fff;
    color: #111;
    font-size: 14px;
    font-weight: 800;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    transition: transform 0.15s, background 0.1s;
    box-sizing: border-box;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
}
.card-qty-compact-only:active {
    transform: scale(0.92);
    background: rgba(0, 0, 0, 0.04);
}

/* Avto-yig'ilgach kompakt pill yumshoq paydo bo'ladi */
.card-qty-compact-only--enter {
    animation: compactQtyEnter 0.58s cubic-bezier(0.22, 1, 0.36, 1) both;
}

@keyframes compactQtyEnter {
    from {
        opacity: 0.55;
        transform: scale(0.9);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

/* ── Floating cart button (pastki o'ng burchak) ── */
.cart-total-bar {
    position: fixed;
    bottom: calc(88px + env(safe-area-inset-bottom));
    right: 16px;
    z-index: 110;
    display: none;
    filter: drop-shadow(0 6px 18px rgba(255,107,53,0.45));
}
.cart-total-bar.visible { display: block; }

.cart-total-bar-btn {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px 18px 12px 14px;
    background: linear-gradient(135deg, #ff6b35, #ff4500);
    border: none;
    border-radius: 50px;
    cursor: pointer;
    transition: transform 0.15s, filter 0.15s;
    white-space: nowrap;
}
.cart-total-bar-btn:active {
    transform: scale(0.93);
}

.ctb-cart-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    color: #fff;
}
.ctb-cart-icon svg {
    display: block;
}
.ctb-label {
    display: none; /* yashirilgan — faqat icon va summa */
}
.ctb-amount {
    color: white;
    font-size: 15px;
    font-weight: 800;
    letter-spacing: -0.3px;
}

/* ==========================================
   CLIENT: FLOATING CART
========================================== */
.floating-cart {
    position: fixed;
    bottom: 18px;
    left: 14px;
    right: 14px;
    background: var(--text);
    color: white;
    padding: 13px 14px 13px 18px;
    border-radius: 50px;
    display: none;
    justify-content: space-between;
    align-items: center;
    box-shadow: 0 12px 32px rgba(26, 26, 46, 0.3);
    z-index: 200;
    cursor: pointer;
}

.cart-info {
    font-size: 14px;
    font-weight: 600;
}

.cart-info b {
    color: var(--primary);
}

.view-cart-btn {
    background: var(--primary);
    color: white;
    border: none;
    padding: 8px 18px;
    border-radius: 50px;
    font-weight: 700;
    font-size: 13px;
    cursor: pointer;
    font-family: 'Plus Jakarta Sans', sans-serif;
}

/* ==========================================
   CLIENT: PRODUCT DETAIL MODAL
========================================== */
.product-detail-content {
    padding: 0 !important;
    border-radius: var(--radius-xl) var(--radius-xl) 0 0;
    overflow: hidden;
    min-height: 50vh;
}

.product-detail-content .modal-handle {
    position: absolute;
    top: 10px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 10;
    background: rgba(255,255,255,0.65);
}

.detail-back-fab {
    position: absolute;
    top: 14px;
    left: 14px;
    z-index: 14;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    border: none;
    background: #fff;
    color: #1a1a1a;
    box-shadow: 0 4px 18px rgba(0,0,0,0.12);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: transform 0.15s ease, box-shadow 0.2s ease;
}

.detail-back-fab:active {
    transform: scale(0.94);
}

.detail-top-actions {
    position: absolute;
    top: 14px;
    right: 14px;
    z-index: 14;
}

.detail-action-pill {
    display: flex;
    align-items: center;
    background: #fff;
    border-radius: 999px;
    box-shadow: 0 4px 18px rgba(0,0,0,0.12);
    padding: 4px 6px;
    gap: 2px;
}

.detail-icon-btn {
    width: 40px;
    height: 36px;
    border: none;
    background: transparent;
    border-radius: 999px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #1a1a1a;
    padding: 0;
    transition: background 0.15s ease;
}

.detail-icon-btn:active {
    background: rgba(0,0,0,0.06);
}

.detail-pill-divider {
    width: 1px;
    height: 20px;
    background: rgba(0,0,0,0.1);
    border-radius: 1px;
}

.detail-like-btn .detail-like-svg {
    fill: none;
}

.detail-like-btn.is-liked .detail-like-svg {
    fill: #ef4444;
    stroke: #ef4444;
}

.detail-close {
    display: none;
}

.detail-carousel-wrap {
    position: relative;
    width: 100%;
}

/* Carousel */
.detail-carousel {
    position: relative;
    width: 100%;
    overflow: hidden;
    background: #ececec;
}

.carousel-track {
    display: flex;
    width: 100%;
    height: 100%;
    transition: transform 0.35s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    will-change: transform;
    gap: 0;
}

.carousel-slide {
    flex: 0 0 100%;
    width: 100%;
    height: 260px;
    position: relative;
    background: #ececec;
    overflow: hidden;
}

.carousel-slide img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.carousel-dots {
    display: flex;
    justify-content: center;
    gap: 6px;
    padding: 10px 0;
    position: absolute;
    bottom: 10px;
    left: 0; right: 0;
}

.carousel-dot {
    width: 6px; height: 6px;
    border-radius: 50%;
    background: rgba(0,0,0,0.18);
    cursor: pointer;
    transition: all 0.2s;
    border: none;
}

.carousel-dot.active {
    background: #374151;
    width: 22px;
    border-radius: 4px;
    box-shadow: none;
}

.carousel-arrow {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(255,255,255,0.9);
    color: #1f2937;
    border: none;
    width: 36px; height: 36px;
    border-radius: 50%;
    font-size: 22px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 10px rgba(0,0,0,0.12);
    transition: background 0.2s;
    z-index: 5;
}

.carousel-arrow:hover { background: #fff; }
.carousel-prev { left: 10px; }
.carousel-next { right: 10px; }

/* Detail body */
.detail-body {
    margin-top: -18px;
    position: relative;
    z-index: 3;
    padding: 22px 18px 32px;
    background: var(--surface);
    border-radius: 22px 22px 0 0;
    box-shadow: 0 -8px 28px rgba(0,0,0,0.06);
}

.detail-title {
    font-family: 'Nunito', sans-serif;
    font-size: 22px;
    font-weight: 900;
    color: var(--text);
    margin-bottom: 6px;
    line-height: 1.3;
}

.detail-price {
    font-family: 'Nunito', sans-serif;
    font-size: 20px;
    font-weight: 800;
    color: var(--primary);
    margin-bottom: 14px;
}

.detail-desc {
    font-size: 14px;
    line-height: 1.7;
    color: var(--text-muted);
    margin-bottom: 20px;
    white-space: pre-wrap;
}

.detail-add-btn {
    margin-top: 8px;
    font-size: 16px;
}

/* ==========================================
   CLIENT: MY ORDERS
========================================== */
.my-orders-list-scroll {
    max-height: min(320px, 52vh);
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    padding-right: 2px;
    padding-bottom: 20px;
}

.my-order-card {
    background: var(--surface);
    border-radius: var(--radius-md);
    padding: 14px;
    margin-bottom: 10px;
    border: 1px solid var(--border);
    box-shadow: var(--shadow-sm);
    transition: box-shadow 0.15s;
}

.my-order-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
}

.order-date {
    font-size: 12px;
    color: var(--text-muted);
    font-weight: 500;
}

.order-items-text {
    font-size: 13px;
    color: #555;
    line-height: 1.5;
    margin-bottom: 10px;
}

.my-order-footer {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    gap: 10px;
    padding-top: 10px;
    border-top: 1px solid var(--border);
}

.my-order-footer-top {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 8px;
}

.my-order-footer-actions {
    display: flex;
    justify-content: flex-end;
    flex-wrap: wrap;
    gap: 8px;
}

.my-order-detail-open-btn {
    background: rgba(255, 107, 53, 0.12);
    color: var(--primary);
    border: 1px solid rgba(255, 107, 53, 0.28);
}

.my-order-detail-open-btn:active {
    opacity: 0.9;
}

.my-order-detail-content {
    max-height: 90vh;
    display: flex;
    flex-direction: column;
}

.my-order-detail-body {
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    padding: 0 16px 24px;
    flex: 1;
    min-height: 0;
}

.my-order-detail-meta {
    margin-bottom: 14px;
}

.my-order-detail-meta .mod-row-line {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    flex-wrap: wrap;
    margin-bottom: 6px;
}

.my-order-detail-meta .mod-date {
    margin: 0;
    font-size: 13px;
    color: var(--text-muted);
    font-weight: 600;
}

.my-order-detail-block {
    margin-bottom: 14px;
}

.my-order-detail-block .mod-k {
    display: block;
    font-size: 11px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    color: var(--text-muted);
    margin-bottom: 6px;
}

.my-order-detail-block .mod-v {
    margin: 0;
    font-size: 15px;
    font-weight: 600;
    color: var(--text);
    line-height: 1.45;
}

.my-order-detail-block.mod-grid2 {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
}

@media (max-width: 360px) {
    .my-order-detail-block.mod-grid2 {
        grid-template-columns: 1fr;
    }
}

.my-order-detail-lines {
    border: 1px solid var(--border);
    border-radius: 14px;
    overflow: hidden;
    background: var(--surface);
}

.my-order-detail-line {
    padding: 12px 14px;
    border-bottom: 1px solid var(--border);
}

.my-order-detail-line:last-child {
    border-bottom: none;
}

.my-order-detail-line .mod-line-name {
    font-weight: 700;
    font-size: 14px;
    color: var(--text);
    margin-bottom: 4px;
}

.my-order-detail-line .mod-line-meta {
    font-size: 13px;
    color: var(--text-muted);
}

.my-order-detail-pre {
    margin: 0;
    padding: 12px 14px;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 14px;
    font-size: 13px;
    line-height: 1.55;
    white-space: pre-wrap;
    color: var(--text);
    font-family: inherit;
}

.order-detail-muted {
    margin: 0;
    font-size: 14px;
    color: var(--text-muted);
}

.order-detail-error {
    color: #b91c1c;
    font-size: 14px;
    font-weight: 600;
    padding: 8px 0;
}

.my-order-detail-total {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 8px;
    padding: 16px 14px;
    border-radius: 14px;
    background: linear-gradient(135deg, var(--primary-light), #fff);
    border: 1px solid rgba(255, 107, 53, 0.2);
    font-weight: 800;
    font-size: 16px;
    color: var(--text);
}

.my-order-detail-total strong {
    color: var(--primary);
    font-size: 18px;
}

.my-order-receipt-btn {
    width: 100%;
    margin: 0;
}

.order-total-text {
    font-size: 16px;
    font-weight: 800;
    color: var(--primary);
    font-family: 'Nunito', sans-serif;
}

.status-cancelled {
    background: #FEE2E2;
    color: #991B1B;
}

/* ==========================================
   CLIENT: CART MODAL
========================================== */
.modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    display: none;
    align-items: flex-end;
    justify-content: center;
    z-index: 300;
    animation: fadeIn 0.3s ease;
}

/* Apple-style sheet: mahsulot detail va savat — silliq ochilish / yopilish */
#product-detail-modal.modal,
/* Cart + Product detail — Apple sheet animatsiyasi */
#cart-modal.modal,
#product-detail-modal.modal {
    animation: none;
    opacity: 0;
    transition: opacity 0.45s cubic-bezier(0.2, 0.8, 0.2, 1);
}

#product-detail-modal.modal.modal--sheet-open,
#cart-modal.modal.modal--sheet-open {
    opacity: 1;
}

#product-detail-modal .modal-content,
#cart-modal .modal-content {
    animation: none;
    transform: translate3d(0, 60px, 0) scale(0.94);
    opacity: 0;
    transition:
        transform 0.55s cubic-bezier(0.34, 1.56, 0.64, 1),
        opacity 0.4s cubic-bezier(0.2, 0.8, 0.2, 1);
    will-change: transform, opacity;
}

#product-detail-modal.modal.modal--sheet-open .modal-content,
#cart-modal.modal.modal--sheet-open .modal-content {
    transform: translate3d(0, 0, 0) scale(1);
    opacity: 1;
}

/* Cart modal ichida checkout tugma — doim pastda */
#cart-modal .modal-content {
    display: flex;
    flex-direction: column;
    max-height: 88vh;
    padding: 0;
}
#cart-modal .cart-scroll-body {
    flex: 1;
    overflow-y: auto;
    padding: 0 20px 8px;
}
#cart-modal .cart-sticky-footer {
    flex-shrink: 0;
    padding: 12px 20px calc(12px + env(safe-area-inset-bottom));
    border-top: 1px solid var(--border);
    background: var(--surface);
}

@media (prefers-reduced-motion: reduce) {
    #product-detail-modal.modal,
    #cart-modal.modal,
    #product-detail-modal .modal-content,
    #cart-modal .modal-content {
        transition-duration: 0.01ms !important;
    }
}

/* E'lonlar oynasini markazga olish */
#ann-detail-modal {
    align-items: center;
}

#ann-detail-modal .modal-content {
    width: 90%;
    border-radius: var(--radius-xl); /* Har tomonlama yumaloq */
    margin-bottom: 0;
}

.modal-content {
    background: var(--surface);
    width: 100%;
    max-height: 92vh;
    border-radius: 28px 28px 0 0;
    padding: 20px 20px 32px;
    overflow-y: auto;
    position: relative;
    box-shadow: 0 -10px 40px rgba(0, 0, 0, 0.15);
    animation: slideUp 0.35s cubic-bezier(0.32, 0.72, 0, 1);
}

.modal-content--profile {
    background: #f3f4f6;
    padding-left: 14px;
    padding-right: 14px;
}

.profile-modal-body {
    padding: 0 0 20px;
}

.profile-screen {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.profile-hero-card {
    background: #fff;
    border-radius: 18px;
    padding: 18px 16px;
    border: 1px solid rgba(0, 0, 0, 0.05);
    box-shadow: 0 2px 14px rgba(26, 26, 46, 0.06);
    display: flex;
    align-items: center;
    gap: 14px;
}

.profile-avatar-wrap--hero {
    flex-shrink: 0;
}

.profile-hero-text {
    flex: 1;
    min-width: 0;
}

.profile-hero-name {
    font-size: 18px;
    font-weight: 800;
    color: var(--text);
    line-height: 1.25;
}

.profile-trust-badge {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    margin-top: 8px;
    background: #e8f0fe;
    color: #1d4ed8;
    border: 1px solid #bfdbfe;
    border-radius: 20px;
    padding: 4px 12px;
    font-size: 11px;
    font-weight: 700;
}

.profile-info-card--modern {
    margin: 0;
    border-radius: 18px;
    border: 1px solid rgba(0, 0, 0, 0.05);
    box-shadow: 0 2px 14px rgba(26, 26, 46, 0.06);
}

.profile-settings-card {
    background: #fff;
    border-radius: 18px;
    border: 1px solid rgba(0, 0, 0, 0.05);
    box-shadow: 0 2px 14px rgba(26, 26, 46, 0.06);
    overflow: hidden;
}

.profile-settings-row {
    display: flex;
    align-items: center;
    width: 100%;
    padding: 16px 14px;
    border: none;
    background: #fff;
    font-size: 15px;
    font-weight: 600;
    color: var(--text);
    cursor: pointer;
    text-align: left;
    font-family: inherit;
    gap: 12px;
    min-height: 54px;
}

.profile-settings-card > *:not(:first-child) {
    border-top: 1px solid #f0f1f3;
}

label.profile-settings-row--lang {
    cursor: default;
    margin: 0;
}

.profile-settings-row:active {
    background: #f9fafb;
}

.psi-icon {
    width: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    color: #6b7280;
}

.psi-svg {
    display: block;
}

.psi-label {
    flex: 1;
    min-width: 0;
}

.psi-chevron {
    color: #d1d5db;
    font-size: 20px;
    font-weight: 300;
    line-height: 1;
    flex-shrink: 0;
}

.profile-lang-select {
    border: none;
    background: transparent;
    color: #9ca3af;
    font-weight: 600;
    font-size: 14px;
    font-family: inherit;
    max-width: 42%;
    text-align: right;
    cursor: pointer;
    margin-right: 2px;
    padding: 4px 0;
}

.profile-lang-select:focus {
    outline: none;
    color: var(--text);
}

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

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

.modal-handle {
    width: 48px;
    height: 5px;
    background: rgba(0, 0, 0, 0.15);
    border-radius: 3px;
    margin: 0 auto 16px;
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    padding-bottom: 12px;
    border-bottom: 1px solid var(--border);
}

.modal-header h3 {
    font-family: 'Nunito', sans-serif;
    font-size: 22px;
    font-weight: 900;
    color: var(--text-main);
    letter-spacing: -0.5px;
}

#cart-modal .modal-header h3 {
    flex: 1;
    min-width: 0;
    margin-right: 10px;
}

.modal-close {
    width: 36px;
    height: 36px;
    background: rgba(0, 0, 0, 0.06);
    border: none;
    border-radius: 12px;
    font-size: 20px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-main);
    transition: all 0.2s ease;
}

.modal-close:hover {
    background: rgba(0, 0, 0, 0.1);
    transform: scale(1.05);
}

.modal-close:active {
    transform: scale(0.95);
}

/* Cart items */
.summary-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 14px 4px;
    border-bottom: 1px solid var(--border);
    margin-bottom: 4px;
}

.summary-info {
    flex: 1;
}

.summary-info .item-name {
    font-size: 15px;
    font-weight: 700;
    margin-bottom: 4px;
    color: var(--text-main);
}

.summary-info .item-price {
    font-size: 14px;
    color: var(--primary);
    font-weight: 800;
}

.qty-controls {
    display: flex;
    align-items: center;
    background: var(--bg);
    border-radius: 10px;
    padding: 4px;
    gap: 10px;
    border: 1px solid var(--border);
}

.qty-btn {
    width: 32px;
    height: 32px;
    background: var(--surface);
    border: none;
    border-radius: var(--radius-sm);
    font-size: 17px;
    font-weight: 700;
    color: var(--primary);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: var(--shadow-sm);
}

.qty-num {
    font-weight: 800;
    min-width: 20px;
    text-align: center;
    font-size: 15px;
}

/* Payment info & Slider */
.card-slider-wrapper {
    position: relative;
    margin: 16px 0;
    overflow: hidden;
}
.card-slider-track {
    display: flex;
    transition: transform 0.4s cubic-bezier(0.2, 0.8, 0.2, 1);
    gap: 0;
    padding-bottom: 5px;
}
.payment-card-box {
    flex: 0 0 100%;
    background: var(--primary-light);
    border: 1.5px dashed var(--primary);
    border-radius: var(--radius-md);
    padding: 14px 16px;
    margin: 0;
    box-sizing: border-box;
    width: 100%;
}

.payment-card-box p.card-label {
    font-size: 13px;
    color: var(--text-muted);
    margin-bottom: 6px;
}

.payment-card-box h4 {
    font-size: 16px;
    font-weight: 800;
    color: var(--primary);
    letter-spacing: 1px;
    word-break: break-all;
}

.copy-area {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 8px;
}

.copy-btn {
    background: white;
    border: 1.2px solid var(--primary);
    color: var(--primary);
    padding: 5px 12px;
    border-radius: 8px;
    font-size: 11px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.2s;
    display: flex;
    align-items: center;
    gap: 4px;
}

.copy-btn:active {
    background: var(--primary);
    color: white;
    transform: scale(0.95);
}

.card-dots {
    display: flex;
    justify-content: center;
    gap: 6px;
    margin-top: 4px;
    margin-bottom: 12px;
}
.card-dot {
    width: 6px;
    height: 6px;
    border-radius: 3px;
    background: var(--border);
    transition: all 0.3s;
}
.card-dot.active {
    background: var(--primary);
    width: 14px;
}

.order-total {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 4px;
    font-size: 16px;
    font-weight: 700;
    background: rgba(255, 107, 53, 0.04);
    border-radius: 12px;
    padding: 14px 16px;
}

.order-total b {
    color: var(--primary);
    font-family: 'Nunito', sans-serif;
    font-size: 22px;
    font-weight: 900;
}

/* File upload */
.file-label {
    display: block;
    text-align: center;
    padding: 18px;
    background: var(--bg);
    border: 2px dashed var(--border);
    border-radius: 14px;
    color: var(--text-muted);
    font-weight: 700;
    font-size: 15px;
    margin-bottom: 16px;
    cursor: pointer;
    transition: all 0.25s ease;
}

.file-label:hover {
    border-color: var(--primary);
    color: var(--primary);
    background: var(--primary-light);
    transform: translateY(-1px);
}

.file-label:active {
    transform: translateY(0);
}



/* ==========================================
   SHARED: BUTTONS
========================================== */
.tg-button {
    width: 100%;
    padding: 16px;
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    color: white;
    border: none;
    border-radius: 14px;
    font-size: 17px;
    font-weight: 800;
    cursor: pointer;
    font-family: 'Plus Jakarta Sans', sans-serif;
    transition: all 0.25s ease;
    box-shadow: 0 4px 12px rgba(255, 107, 53, 0.3);
    letter-spacing: -0.3px;
}

.tg-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(255, 107, 53, 0.4);
}

.tg-button:active {
    transform: translateY(0) scale(0.98);
    box-shadow: 0 2px 8px rgba(255, 107, 53, 0.3);
}

.tg-button:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

/* ==========================================
   SHARED: LOADER
========================================== */
.loader-container {
    height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 14px;
    color: var(--text-muted);
    font-size: 14px;
}

.spinner {
    width: 40px;
    height: 40px;
    border: 3px solid var(--border);
    border-top-color: var(--primary);
    border-radius: 50%;
    animation: spin 0.75s linear infinite;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

/* ==========================================
   MISC
========================================== */
.loading-text {
    text-align: center;
    color: var(--text-muted);
    padding: 30px;
    font-size: 14px;
}

.empty {
    text-align: center;
    padding: 40px 20px;
    color: var(--text-muted);
    font-size: 14px;
}

.empty-icon {
    font-size: 40px;
    margin-bottom: 10px;
}

.divider {
    height: 1px;
    background: var(--border);
    margin: 14px 0;
}

/* ==========================================
   CLIENT: ORDER FORM
========================================== */
.order-textarea {
    width: 100%;
    padding: 14px 16px;
    border: 1.5px solid var(--border);
    border-radius: 14px;
    font-size: 15px;
    font-family: 'Plus Jakarta Sans', sans-serif;
    color: var(--text);
    background: var(--bg);
    resize: none;
    outline: none;
    transition: all 0.25s ease;
    margin-bottom: 16px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04);
}

.order-textarea:focus {
    border-color: var(--primary);
    background: white;
    box-shadow: 0 0 0 3px rgba(255, 107, 53, 0.1);
}

.section-label {
    font-size: 12px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: var(--text-muted);
    margin-bottom: 12px;
    margin-top: 6px;
    display: block;
}

/* Delivery toggle */
.delivery-toggle {
    display: flex;
    gap: 10px;
    margin-bottom: 6px;
}

.delivery-btn {
    flex: 1;
    padding: 12px 10px;
    border: 1.5px solid var(--border);
    border-radius: 12px;
    background: var(--bg);
    color: var(--text-muted);
    font-size: 14px;
    font-weight: 700;
    cursor: pointer;
    font-family: 'Plus Jakarta Sans', sans-serif;
    transition: all 0.25s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
}

.delivery-btn:hover {
    border-color: var(--primary);
    background: rgba(255, 107, 53, 0.05);
}

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

.delivery-btn.active {
    background: var(--primary-light);
    border-color: var(--primary);
    color: var(--primary);
    box-shadow: 0 2px 8px rgba(255, 107, 53, 0.15);
}

/* Order status badges */
.order-status {
    display: inline-block;
    padding: 4px 10px;
    border-radius: 50px;
    font-size: 12px;
    font-weight: 700;
}

.status-pending {
    background: #FEF9C3;
    color: #854D0E;
}

.status-accepted {
    background: #DCFCE7;
    color: #166534;
}

/* Danger button */
.btn-sm {
    padding: 6px 12px;
    font-size: 12px;
    border-radius: var(--radius-sm);
    border: none;
    cursor: pointer;
    font-weight: 700;
    font-family: 'Plus Jakarta Sans', sans-serif;
}

.btn-danger {
    background: #FEE2E2;
    color: #991B1B;
}

.btn-danger:active {
    background: #EF4444;
    color: white;
}

/* ==========================================
   LIGHTBOX
========================================== */
#lightbox {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.94);
    z-index: 9999;
    display: none;
    align-items: center;
    justify-content: center;
    flex-direction: column;
}

#lightbox-img {
    max-width: 95vw;
    max-height: 88vh;
    object-fit: contain;
    border-radius: 8px;
    box-shadow: 0 0 60px rgba(0, 0, 0, 0.5);
}

/*#lightbox::after {
    content: 'Kichraytirish uchun bir marta bosing';
    position: absolute;
    bottom: 20px;
    color: rgba(255, 255, 255, 0.7);
    font-size: 14px;
}*/

/* ==========================================
   STATUS + PAY BADGES
========================================== */
.status-done {
    background: #D1FAE5;
    color: #065F46;
}

.pay-badge {
    display: inline-block;
    font-size: 11px;
    font-weight: 700;
    padding: 2px 8px;
    border-radius: 50px;
}

.pay-card {
    background: #EFF6FF;
    color: #1D4ED8;
}

.pay-cash {
    background: #F0FDF4;
    color: #166534;
}

/* ==========================================
   ANIMATIONS (for Admin Settings)
   ========================================== */
.animate-in {
    animation-duration: 0.3s;
    animation-fill-mode: both;
}
.fade-in {
    animation-name: fadeIn;
}
.slide-in-from-top-2 {
    animation-name: slideInTop;
}

/* TO'LOV BUTTONLARI */
.payment-selection-wrapper {
    margin-bottom: 4px;
}

/* old column layout kept for compatibility but not used */
.payment-buttons-container {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.payment-option-btn {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 16px 20px;
    background: var(--surface);
    border: 2px solid var(--border);
    border-radius: 18px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 15px;
    font-weight: 600;
    color: var(--text-main);
    text-align: left;
}

.payment-option-btn.active {
    border-color: var(--primary);
    background: var(--primary-light);
}

/* ---- CHIP / PILL payment row ---- */
.payment-chips-row {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.pay-chip {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 8px 14px;
    background: var(--surface);
    border: 2px solid var(--border);
    border-radius: 50px;
    cursor: pointer;
    font-size: 13px;
    font-weight: 700;
    color: var(--text-main);
    font-family: 'Plus Jakarta Sans', sans-serif;
    transition: all 0.2s ease;
    white-space: nowrap;
    -webkit-tap-highlight-color: transparent;
}

.pay-chip:active {
    transform: scale(0.95);
}

.pay-chip.active {
    border-color: var(--primary);
    background: var(--primary-light);
    color: var(--primary);
    box-shadow: 0 2px 10px rgba(255, 107, 53, 0.18);
}

.pay-chip-icon {
    font-size: 16px;
    line-height: 1;
}

.pay-chip-label {
    line-height: 1;
}

/* ---- SEARCH FAKE INPUT ---- */
.search-fake-input {
    width: 100%;
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 11px 16px;
    background: var(--bg);
    border: 1.5px solid var(--border);
    border-radius: 12px;
    cursor: pointer;
    font-family: 'Plus Jakarta Sans', sans-serif;
    font-size: 14px;
    color: var(--text-muted);
    text-align: left;
    -webkit-tap-highlight-color: transparent;
    transition: border-color 0.2s;
}

.search-fake-input:active {
    border-color: var(--primary);
}

.search-icon-lbl {
    font-size: 15px;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #111;
}

.search-placeholder-lbl {
    flex: 1;
    overflow: hidden;
    white-space: nowrap;
    text-overflow: ellipsis;
}

/* ---- SEARCH MODAL ---- */
.search-modal-box {
    background: var(--bg);
    border-radius: 0 0 20px 20px;
    padding: 12px 14px 16px;
    box-shadow: 0 8px 32px rgba(0,0,0,0.18);
    display: flex;
    flex-direction: column;
    gap: 0;
    max-height: 92vh;
}

.search-modal-input-row {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 12px;
    background: var(--surface);
    border: 1.5px solid var(--border);
    border-radius: 12px;
    margin-bottom: 12px;
}

.search-modal-input {
    flex: 1;
    border: none;
    background: transparent;
    outline: none;
    font-size: 16px;
    font-family: 'Plus Jakarta Sans', sans-serif;
    color: var(--text);
    padding: 4px 0;
}

.search-modal-cancel {
    background: none;
    border: none;
    cursor: pointer;
    font-size: 13px;
    font-weight: 700;
    color: var(--primary);
    font-family: 'Plus Jakarta Sans', sans-serif;
    padding: 4px 2px;
    flex-shrink: 0;
}

.search-modal-results {
    overflow-y: auto;
    max-height: 72vh;
    padding-bottom: 8px;
}

/* ==========================================
   VARIANT STYLES
========================================== */
.detail-variants-container {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.variant-btn {
    flex: 1;
    min-width: calc(50% - 5px);
    padding: 12px 16px;
    background: var(--bg);
    border: 2px solid var(--border);
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.25s ease;
    font-size: 14px;
    font-weight: 600;
    color: var(--text-main);
    text-align: center;
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.variant-btn .variant-name {
    font-size: 14px;
    font-weight: 600;
}

.variant-btn .variant-price {
    font-size: 12px;
    font-weight: 500;
}

.variant-btn:hover {
    border-color: var(--primary);
    background: rgba(255, 107, 53, 0.05);
}

.variant-btn.active {
    border-color: var(--primary);
    background: var(--primary-light);
    color: var(--primary);
    box-shadow: 0 2px 8px rgba(255, 107, 53, 0.15);
}

.variant-modal-variants {
    display: flex;
    flex-direction: column;
    gap: 10px;
    padding: 10px 0;
}

.variant-modal-btn {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 20px;
    background: var(--bg);
    border: 2px solid var(--border);
    border-radius: 14px;
    cursor: pointer;
    transition: all 0.25s ease;
    font-size: 15px;
    font-weight: 600;
    color: var(--text-main);
}

.variant-modal-btn:hover {
    border-color: var(--primary);
    background: rgba(255, 107, 53, 0.05);
    transform: translateY(-1px);
}

.variant-modal-btn.active {
    border-color: var(--primary);
    background: var(--primary-light);
    color: var(--primary);
    box-shadow: 0 4px 12px rgba(255, 107, 53, 0.15);
}

.variant-modal-btn .variant-name {
    font-weight: 700;
}

.variant-modal-btn .variant-price {
    font-weight: 800;
    color: var(--primary);
}

/* Variant satr: nom + narx | − miqdor + */
.variant-modal-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    padding: 12px 14px;
    background: var(--surface);
    border: 2px solid var(--border);
    border-radius: 14px;
}

.variant-modal-row-info {
    display: flex;
    flex-direction: column;
    gap: 4px;
    min-width: 0;
    flex: 1;
}

.variant-modal-row-info .variant-name {
    font-weight: 700;
    font-size: 15px;
}

.variant-modal-row-info .variant-price {
    font-weight: 700;
    font-size: 13px;
    color: var(--primary);
}

.variant-modal-qty-strip {
    display: flex;
    align-items: center;
    gap: 0;
    background: #fff3ee;
    border: 1.5px solid #ff6b35;
    border-radius: 50px;
    overflow: hidden;
    flex-shrink: 0;
}

.variant-modal-qty-strip button {
    width: 32px;
    height: 32px;
    background: none;
    border: none;
    color: #ff6b35;
    font-size: 18px;
    font-weight: 700;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
}

.variant-modal-qty-strip button:active {
    background: #ffe4d5;
}

.variant-modal-qty-num {
    min-width: 26px;
    text-align: center;
    font-size: 15px;
    font-weight: 800;
    color: #ff6b35;
}

.card-qty-num--tap {
    cursor: pointer;
    border: none;
    background: transparent;
    font: inherit;
    padding: 0 4px;
}

/* TO'LOV DROPDOWN - APPLE STYLE */
.payment-dropdown {
    position: relative;
    width: 100%;
    z-index: 100;
}

.payment-dropdown-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px 20px;
    background: #fff;
    border: 1px solid rgba(0,0,0,0.08);
    border-radius: 18px;
    cursor: pointer;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 2px 10px rgba(0,0,0,0.02);
}

.payment-dropdown-header:active {
    transform: scale(0.97);
    background: #f9f9f9;
}

.selected-payment-info {
    display: flex;
    align-items: center;
    gap: 14px;
}

.selected-payment-info .pay-icon {
    font-size: 1.5rem;
    filter: drop-shadow(0 2px 4px rgba(0,0,0,0.1));
}

.selected-payment-info .pay-label {
    font-weight: 700;
    color: var(--text-main);
    font-size: 15px;
    letter-spacing: -0.3px;
}

.dropdown-arrow {
    font-size: 12px;
    color: #A0A0B0;
    transition: transform 0.5s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.payment-dropdown.open .dropdown-arrow {
    transform: rotate(180deg);
}

.payment-dropdown.open .payment-dropdown-header {
    border-color: var(--primary);
    box-shadow: 0 10px 25px rgba(0,0,0,0.06);
}

.payment-options-menu {
    position: absolute;
    top: calc(100% + 10px);
    left: 0;
    right: 0;
    background: rgba(255, 255, 255, 0.98);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-radius: 22px;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.15);
    border: 1px solid rgba(0,0,0,0.05);
    overflow: hidden;
    transform-origin: top center;
    transition: all 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
    z-index: 1000;
    opacity: 1;
    transform: translateY(0) scale(1);
}

/* Yopilgandagi holat - Animatsiya ishlashi uchun */
.payment-options-menu.menu-closed {
    opacity: 0;
    transform: translateY(-10px) scale(0.95);
    pointer-events: none;
    visibility: hidden;
}

.payment-option-item {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 16px 20px;
    cursor: pointer;
    transition: all 0.2s ease;
    border-bottom: 1px solid rgba(0,0,0,0.03);
}

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

.payment-option-item:hover {
    background: rgba(0, 0, 0, 0.02);
}

.payment-option-item:active {
    background: rgba(0, 0, 0, 0.05);
    transform: scale(0.98);
}

.payment-option-item .pay-icon {
    font-size: 1.3rem;
}

.payment-option-item .pay-label {
    font-weight: 600;
    color: var(--text-main);
    font-size: 15px;
}

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

@keyframes slideInTop {
    from { transform: translateY(-0.5rem); }
    to { transform: translateY(0); }
}

/* ---- PROFIL MENU ROW ---- */
.profile-menu-row {
    width: 100%;
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 16px;
    background: var(--surface);
    border: none;
    font-size: 15px;
    font-weight: 600;
    color: var(--text);
    cursor: pointer;
    font-family: 'Plus Jakarta Sans', sans-serif;
    -webkit-tap-highlight-color: transparent;
    transition: background 0.15s;
}

.profile-menu-row:active {
    background: var(--primary-light);
}

.profile-menu-row + .profile-menu-row {
    border-top: 1px solid var(--border);
}

.pmr-arrow {
    margin-left: auto;
    font-size: 18px;
    color: var(--text-muted);
}

/* ---- SEARCH RESULT ITEMS ---- */
.search-result-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    padding: 13px 4px;
    border-bottom: 1px solid var(--border);
    cursor: pointer;
    -webkit-tap-highlight-color: transparent;
    transition: background 0.15s;
}

.search-result-item:active {
    background: var(--primary-light);
    border-radius: 8px;
}

.sri-name {
    font-size: 14px;
    font-weight: 600;
    color: var(--text);
    flex: 1;
    min-width: 0;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.sri-price {
    font-size: 13px;
    font-weight: 700;
    color: var(--primary);
    white-space: nowrap;
    flex-shrink: 0;
}

/* ==========================================
   MENU MODAL — 70vh, katalog panjarasi
========================================== */
.menu-modal-content-sheet {
    max-height: 70vh !important;
    height: 70vh;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    min-height: 0;
}

.menu-modal-content-sheet > .modal-handle {
    flex-shrink: 0;
}

.menu-cat-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 16px 12px;
    padding: 10px 0 20px;
}

.menu-cat-tile {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    margin: 0;
    padding: 0;
    border: none;
    background: none;
    cursor: pointer;
    -webkit-tap-highlight-color: transparent;
    text-align: center;
}

.menu-cat-tile:active {
    opacity: 0.85;
}

.menu-cat-tile-img-wrap {
    width: 100%;
    aspect-ratio: 1;
    max-width: 88px;
    margin: 0 auto;
    border-radius: 50%;
    overflow: hidden;
    background: #f0f0f0;
    border: 1px solid var(--border);
    flex-shrink: 0;
}

.menu-cat-tile-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.menu-cat-tile-label {
    font-size: 12px;
    font-weight: 700;
    color: var(--text);
    line-height: 1.2;
    max-width: 100%;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    padding: 0 2px;
}

/* ==========================================
   MENU MODAL — header (sevimlilar + yopish)
========================================== */
.menu-modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 10px;
    flex-shrink: 0;
}

.menu-modal-header-left {
    display: flex;
    align-items: center;
    gap: 6px;
    min-width: 0;
    flex: 1;
}

.menu-modal-header-left h3 {
    margin: 0;
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.menu-modal-back-btn {
    flex-shrink: 0;
    width: 36px;
    height: 36px;
    border: none;
    border-radius: 10px;
    background: var(--primary-light);
    color: var(--primary);
    font-size: 18px;
    font-weight: 800;
    cursor: pointer;
    display: none;
    align-items: center;
    justify-content: center;
    line-height: 1;
}

.menu-modal-header-actions {
    display: flex;
    align-items: center;
    gap: 6px;
    flex-shrink: 0;
}

.menu-favorites-btn {
    position: relative;
    width: 36px;
    height: 36px;
    border: none;
    border-radius: 12px;
    background: rgba(0, 0, 0, 0.06);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s, color 0.2s;
}

.menu-favorites-btn.has-likes {
    background: rgba(239, 68, 68, 0.12);
    color: #ef4444;
}

.menu-favorites-icon {
    font-size: 18px;
    line-height: 1;
    color: var(--text-muted);
    transition: color 0.2s;
}

.menu-favorites-btn.has-likes .menu-favorites-icon {
    color: #ef4444;
}

.menu-fav-count {
    position: absolute;
    top: -4px;
    right: -4px;
    min-width: 16px;
    height: 16px;
    padding: 0 4px;
    border-radius: 8px;
    background: #ef4444;
    color: #fff;
    font-size: 9px;
    font-weight: 800;
    display: flex;
    align-items: center;
    justify-content: center;
}

.menu-categories-outer {
    flex: 1;
    min-height: 0;
    display: flex;
    flex-direction: column;
    position: relative;
    padding: 0 14px 0;
}

.menu-categories-outer::after {
    content: '';
    position: absolute;
    left: 14px;
    right: 14px;
    bottom: 22px;
    height: 36px;
    pointer-events: none;
    opacity: 0;
    transition: opacity 0.2s ease;
    background: linear-gradient(to bottom, transparent, rgba(255, 255, 255, 0.96));
    border-radius: 0 0 10px 10px;
}

.menu-categories-outer.menu-cat-scroll--more::after {
    opacity: 1;
}

#menu-categories.menu-categories-inner {
    flex: 1;
    min-height: 0;
    overflow-y: auto;
    padding-bottom: 8px;
    -webkit-overflow-scrolling: touch;
}

#menu-categories.menu-categories-inner:not(.menu-categories-inner--grid) {
    display: flex;
    flex-direction: column;
    gap: 6px;
    max-height: min(270px, 46vh);
}

/* Sevimlilar: scroll alohida qatlamda (flex + touch muvofiqligi) */
#menu-categories.menu-categories-inner.menu-categories-inner--favorites:not(.menu-categories-inner--grid) {
    gap: 0;
    overflow: hidden;
    max-height: none;
}

.menu-fav-list-scroll {
    flex: 1 1 auto;
    min-height: 0;
    width: 100%;
    max-height: min(calc(5 * 72px + 4 * 6px), 52vh);
    overflow-y: auto;
    overflow-x: hidden;
    -webkit-overflow-scrolling: touch;
    overscroll-behavior-y: contain;
    touch-action: pan-y;
    display: flex;
    flex-direction: column;
    gap: 6px;
    padding-bottom: 6px;
}

/* Flex qatorlarni siqmasin — aks holda barcha mahsulotlar bir panelga "tiqilib" ketadi */
.menu-fav-list-scroll > .menu-fav-row {
    flex-shrink: 0;
}
#menu-categories.menu-categories-inner--grid {
    display: block;
    max-height: none;
}

.menu-categories-scroll-hint {
    flex-shrink: 0;
    text-align: center;
    font-size: 11px;
    font-weight: 700;
    color: var(--text-muted);
    padding: 2px 8px 10px;
    letter-spacing: 0.02em;
}

.business-link-icon-wrap {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.business-brand-icon {
    display: block;
}

.business-call-btn {
    width: 100%;
    border: none;
    border-top: 1px solid var(--border);
    background: var(--surface);
    padding: 14px 16px;
    font-weight: 800;
    font-size: 15px;
    color: var(--primary);
    cursor: pointer;
    font-family: inherit;
    text-align: center;
    -webkit-tap-highlight-color: transparent;
}

.business-call-btn:active {
    background: var(--primary-light);
}

.profile-sister-apps-title {
    padding: 12px 16px 6px;
    font-size: 12px;
    font-weight: 800;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.06em;
}

.profile-sister-app-row {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px 16px;
    border-top: 1px solid var(--border);
}

.profile-sister-app-name {
    flex: 1;
    min-width: 0;
    font-weight: 700;
    font-size: 15px;
    color: var(--text);
}

.profile-sister-app-open {
    flex-shrink: 0;
    padding: 8px 14px;
    border-radius: 10px;
    border: none;
    background: var(--primary);
    color: #fff;
    font-weight: 800;
    font-size: 13px;
    cursor: pointer;
    font-family: inherit;
    -webkit-tap-highlight-color: transparent;
}

.profile-sister-app-open:active {
    opacity: 0.9;
}

/* Sevimlilar ro'yxati (menyu ichida) */
.menu-fav-row {
    display: flex;
    align-items: stretch;
    gap: 0;
    width: 100%;
    padding: 0;
    border: 1px solid var(--border);
    border-radius: 14px;
    background: var(--surface);
    overflow: hidden;
    transition: border-color 0.15s;
}

.menu-fav-row:active {
    border-color: var(--primary);
}

.menu-fav-row-main {
    flex: 1;
    min-width: 0;
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 12px;
    border: none;
    background: transparent;
    cursor: pointer;
    text-align: left;
    font-family: inherit;
}

.menu-fav-pending-heart {
    flex-shrink: 0;
    width: 48px;
    min-height: 100%;
    align-self: stretch;
    border: none;
    border-left: 1px solid var(--border);
    background: rgba(0, 0, 0, 0.02);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    transition: background 0.15s;
}

.menu-fav-pending-heart:active {
    background: var(--primary-light);
}

.menu-fav-pending-heart .mfph-icon {
    color: #ef4444;
    line-height: 1;
    transition: color 0.2s, transform 0.2s;
}

.menu-fav-pending-heart.is-pending-unlike .mfph-icon {
    color: rgba(180, 180, 190, 0.95);
}

.cart-header-actions {
    display: flex;
    align-items: center;
    gap: 8px;
}

.cart-clear-btn {
    padding: 6px 10px;
    font-size: 12px;
    font-weight: 700;
    border: 1px solid var(--border);
    border-radius: 10px;
    background: var(--surface);
    color: var(--text-muted);
    cursor: pointer;
    font-family: inherit;
    white-space: nowrap;
}

.cart-clear-btn:active {
    background: #fee2e2;
    border-color: #fecaca;
    color: #b91c1c;
}

.menu-fav-row-img {
    width: 52px;
    height: 52px;
    border-radius: 10px;
    object-fit: cover;
    flex-shrink: 0;
    background: var(--border);
}

.menu-fav-row-info {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.menu-fav-row-name {
    font-size: 14px;
    font-weight: 700;
    color: var(--text);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.menu-fav-row-price {
    font-size: 13px;
    font-weight: 800;
    color: var(--primary);
}

.menu-fav-row-chev {
    font-size: 20px;
    color: var(--text-muted);
    font-weight: 300;
    flex-shrink: 0;
}

.detail-like-icon {
    font-size: 18px;
    line-height: 1;
    transition: color 0.2s, transform 0.2s;
}

.detail-body .detail-title {
    margin: 0 0 8px;
}

/* ==========================================
   PROFILE — avatar + qalam
========================================== */
.profile-avatar-wrap {
    position: relative;
    width: 72px;
    height: 72px;
}

.profile-avatar-circle {
    width: 72px;
    height: 72px;
    border-radius: 50%;
    background: var(--primary-light);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 36px;
    border: 2px solid var(--primary);
}

.profile-edit-pencil {
    position: absolute;
    bottom: -2px;
    right: -2px;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    border: 2px solid var(--surface);
    background: var(--primary);
    color: #fff;
    font-size: 13px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: var(--shadow-sm);
    padding: 0;
    line-height: 1;
}

/* ==========================================
   PROFILE MODAL — info card & edit form
========================================== */
.profile-info-card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 14px;
    overflow: hidden;
    margin: 8px 0 12px;
}

.profile-info-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 13px 16px;
    border-bottom: 1px solid var(--border);
}

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

.pir-label {
    font-size: 13px;
    color: var(--text-muted);
    font-weight: 600;
}

.pir-value {
    font-size: 14px;
    font-weight: 700;
    color: var(--text);
    text-align: right;
}

.pir-value--address {
    max-width: 58%;
    white-space: normal;
    line-height: 1.35;
}

.profile-field-label {
    display: block;
    font-size: 12px;
    font-weight: 700;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 6px;
}

.profile-field-input {
    width: 100%;
    padding: 12px 14px;
    border: 1.5px solid var(--border);
    border-radius: 10px;
    font-size: 15px;
    font-family: inherit;
    color: var(--text);
    background: var(--surface);
    margin-bottom: 14px;
    outline: none;
    transition: border-color 0.2s;
}

.profile-field-input:focus {
    border-color: var(--primary);
}

.profile-field-textarea {
    resize: vertical;
    min-height: 78px;
}

.profile-language-card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 14px;
    padding: 14px;
    margin-bottom: 12px;
}

.profile-language-card .profile-field-input {
    margin-bottom: 0;
}

.profile-back-btn {
    border: none;
    background: var(--primary-light);
    color: var(--primary);
    border-radius: 999px;
    padding: 9px 14px;
    font-weight: 800;
    font-family: inherit;
    margin-bottom: 12px;
}

.business-info-card {
    padding: 4px 0;
}

.business-info-hero {
    background: linear-gradient(135deg, var(--primary-light), #fff);
    border: 1px solid var(--border);
    border-radius: 18px;
    padding: 18px;
    text-align: center;
    margin-bottom: 12px;
}

.business-info-icon {
    width: 52px;
    height: 52px;
    border-radius: 18px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: white;
    box-shadow: var(--shadow-sm);
    font-size: 26px;
    margin-bottom: 10px;
}

.business-info-hero h4 {
    margin: 0 0 8px;
    font-size: 18px;
    font-weight: 900;
    color: var(--text);
}

.business-info-hero p {
    margin: 0;
    color: var(--text-muted);
    line-height: 1.5;
    font-size: 14px;
}

.business-info-list {
    border: 1px solid var(--border);
    border-radius: 14px;
    overflow: hidden;
    margin-bottom: 12px;
}

.business-info-row {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    padding: 13px 14px;
    background: var(--surface);
    border-bottom: 1px solid var(--border);
}

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

.business-info-row span {
    color: var(--text-muted);
    font-weight: 700;
}

.business-info-row b {
    text-align: right;
    color: var(--text);
}

.business-link-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
}

.business-link-btn {
    border: 1px solid var(--border);
    border-radius: 14px;
    background: var(--surface);
    color: var(--text);
    padding: 13px 10px;
    font-weight: 800;
    font-family: inherit;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.business-info-empty {
    text-align: center;
    color: var(--text-muted);
    font-size: 13px;
    margin: 12px 0 0;
}

.gender-btn {
    flex: 1;
    padding: 12px;
    border: 1.5px solid var(--border);
    border-radius: 10px;
    background: var(--surface);
    color: var(--text-muted);
    font-size: 14px;
    font-weight: 700;
    font-family: inherit;
    cursor: pointer;
    transition: all 0.2s;
}

.gender-btn--active {
    border-color: var(--primary);
    background: var(--primary-light);
    color: var(--primary);
}

/* ==========================================
   MENU CATEGORIES — sub-category indicator
========================================== */
.menu-cat-sub-indicator {
    display: inline-block;
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--primary);
    opacity: 0.55;
    flex-shrink: 0;
    margin-left: auto;
}