/* --- تنظیمات نوار در حالت دسکتاپ (گوشه سمت راست) --- */
.ios-bottom-bar {
    position: fixed !important;
    bottom: 30px !important;
    right: 30px !important; /* انتقال به سمت راست در دسکتاپ */
    left: auto !important;
    transform: none !important;
    width: 80px !important; /* عرض کم برای حالت عمودی در دسکتاپ */
    height: auto !important;
    min-height: 200px !important;
    background: rgba(255, 255, 255, 0.4) !important;
    backdrop-filter: blur(25px) saturate(180%) !important;
    -webkit-backdrop-filter: blur(25px) saturate(180%) !important;
    border: 1px solid rgba(255, 255, 255, 0.3) !important;
    border-radius: 25px !important;
    display: flex !important;
    flex-direction: column !important; /* چیدمان عمودی در دسکتاپ */
    justify-content: center !important;
    align-items: center !important;
    gap: 20px !important;
    padding: 20px 0 !important;
    z-index: 99999 !important;
    /* سایه تار و عمیق که خواسته بودی */
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.15), 
                0 5px 15px rgba(0, 0, 0, 0.05) !important;
}

.ios-icon {
    width: 28px !important;
    height: 28px !important;
    object-fit: contain !important;
    transition: transform 0.2s ease;
}

.bar-item:hover .ios-icon {
    transform: scale(1.15);
}

/* --- تنظیمات مخصوص موبایل (ریسپانسیو) --- */
@media (max-width: 768px) {
    .ios-bottom-bar {
        right: 50% !important;
        bottom: 20px !important;
        left: auto !important;
        transform: translateX(50%) !important;
        width: 90% !important;
        max-width: 350px !important;
        height: 65px !important;
        min-height: auto !important;
        flex-direction: row !important; /* چیدمان افقی در موبایل */
        padding: 0 15px !important;
        border-radius: 35px !important;
    }

    /* !!! مهم: مخفی کردن نوار وقتی داخل صفحه چت هستیم !!! */
    body.show-chat .ios-bottom-bar {
        display: none !important;
    }
}

/* استایل شمارنده پیام */
.msg-badge {
    position: absolute !important;
    top: -5px !important;
    right: -5px !important;
    background: #ff3b30 !important;
    color: #fff !important;
    font-size: 11px !important;
    width: 20px !important;
    height: 20px !important;
    border-radius: 50% !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    border: 2px solid rgba(255,255,255,0.8) !important;
    box-shadow: 0 2px 5px rgba(0,0,0,0.2) !important;
}

.bar-item {
    position: relative !important;
    text-decoration: none !important;
}
.icon{
  width: 40px;
}
/* ========================================= */
/* === استایل آیتم سهمیه در نوار پایینی === */
/* ========================================= */



.quota-icon {
    position: relative;
    display: inline-block; /* برای قرارگیری صحیح بج */
}

.quota-badge {
    position: absolute;
    top: -5px;  /* کمی بالاتر از آیکون */
    right: -10px; /* کمی راست‌تر از آیکون */
    background-color: #e74c3c; /* قرمز */
    color: white;
    font-size: 11px;
    font-weight: bold;
    border-radius: 50%;
    padding: 3px 6px;
    min-width: 20px; /* برای حفظ شکل دایره‌ای */
    text-align: center;
    border: 2px solid white;
    box-shadow: 0 1px 3px rgba(0,0,0,0.2);
}

/* اگر تعداد پیام‌ها زیاد بود، بج را کمی بزرگتر کن */
.quota-badge:empty {
    display: none; /* اگر عددی نبود، نمایش نده */
}
.add-menu {
    display: none; /* در ابتدا مخفی */
    position: fixed;
    bottom: 65px; /* تنظیم ارتفاع برای قرارگیری بالای نوار */
    left: 50%;
    transform: translateX(-50%);
    background: white;
    border-radius: 10px;
    box-shadow: 0 -2px 10px rgba(0,0,0,0.1);
    z-index: 1000; /* مطمئن شوید که روی بقیه المان‌ها قرار می‌گیرد */
    width: 200px;
    border: 1px solid #eee;
}
.add-menu-item {
    padding: 15px;
    text-align: center;
    cursor: pointer;
    font-size: 14px;
}
.add-menu-item:hover {
    background-color: #f1f1f1;
}
.add-menu-item:first-child {
    border-bottom: 1px solid #f1f1f1;
}