/* جستجوی هوشمند آسمان - استایل جستجوی زنده */

.ass-live-results {
    position: absolute;
    z-index: 99999;
    width: 100%;
    max-height: 420px;
    overflow-y: auto;
    background: #ffffff;
    border: 1px solid #dddddd;
    border-radius: 8px;
    box-shadow: 0 6px 24px rgba(0, 0, 0, 0.12);
    direction: rtl;
    animation: ass-fade-in 0.15s ease-out;
}

/* انیمیشن نمایش نتایج */
@keyframes ass-fade-in {
    from {
        opacity: 0;
        transform: translateY(-4px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* فهرست نتایج */
.ass-results-list {
    list-style: none;
    margin: 0;
    padding: 0;
}

/* هر نتیجه */
.ass-result-item {
    margin: 0;
    padding: 0;
}

.ass-result-item a {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 14px;
    color: #222222;
    text-decoration: none;
    border-bottom: 1px solid #f0f0f0;
    transition: background-color 0.15s ease;
}

/* حذف خط جداکننده از آخرین نتیجه */
.ass-result-item:last-child a {
    border-bottom: none;
}

/* حالت هاور و فوکوس */
.ass-result-item a:hover,
.ass-result-item a:focus {
    color: #222222;
    background: #f7f9fc;
    text-decoration: none;
    outline: none;
}

/* تصویر محصول */
.ass-result-item img {
    width: 48px;
    height: 48px;
    flex: 0 0 48px;
    object-fit: contain;
    border-radius: 6px;
    background: #ffffff;
}

/* بخش اطلاعات محصول */
.ass-result-item a > span,
.ass-result-item a > div {
    min-width: 0;
}

/* عنوان محصول */
.ass-result-title {
    display: block;
    overflow: hidden;
    color: #222222;
    font-size: 14px;
    font-weight: 600;
    line-height: 1.6;
    text-overflow: ellipsis;
    white-space: nowrap;
}

/* قیمت محصول */
.ass-result-price {
    display: block;
    margin-top: 2px;
    color: #777777;
    font-size: 12px;
    line-height: 1.6;
}

/* پیام نبودن نتیجه */
.ass-no-results {
    margin: 0;
    padding: 14px;
    color: #666666;
    font-size: 13px;
    line-height: 1.8;
    text-align: center;
}

/* پیشنهاد هوش مصنوعی آسمان */
.ass-matis-suggestion {
    padding: 12px 14px;
    color: #23415f;
    background: #f2f8ff;
    border-top: 1px solid #dceaff;
    font-size: 13px;
    line-height: 1.9;
}

/* عنوان پیشنهاد هوش مصنوعی */
.ass-matis-suggestion strong {
    color: #1a5fb4;
    font-weight: 700;
}

/* اعلان نبودن نتیجه در صفحه */
.ass-no-results-notice {
    margin: 16px 0;
    padding: 16px;
    color: #666666;
    background: #fbfbfb;
    border: 1px solid #dddddd;
    border-radius: 8px;
    font-size: 14px;
    line-height: 1.8;
}

/* نوار اسکرول */
.ass-live-results::-webkit-scrollbar {
    width: 7px;
}

.ass-live-results::-webkit-scrollbar-track {
    background: #f5f5f5;
    border-radius: 8px;
}

.ass-live-results::-webkit-scrollbar-thumb {
    background: #c8c8c8;
    border-radius: 8px;
}

.ass-live-results::-webkit-scrollbar-thumb:hover {
    background: #aaaaaa;
}

/* نمایش مناسب در موبایل */
@media (max-width: 600px) {
    .ass-live-results {
        width: 100%;
        max-height: 60vh;
        border-radius: 6px;
    }

    .ass-result-item a {
        padding: 9px 10px;
        gap: 8px;
    }

    .ass-result-item img {
        width: 40px;
        height: 40px;
        flex-basis: 40px;
    }

    .ass-result-title {
        font-size: 13px;
    }

    .ass-result-price {
        font-size: 11px;
    }

    .ass-matis-suggestion {
        padding: 10px;
        font-size: 12px;
    }
}

/* کاهش انیمیشن برای کاربرانی که آن را غیرفعال کرده‌اند */
@media (prefers-reduced-motion: reduce) {
    .ass-live-results {
        animation: none;
    }

    .ass-result-item a {
        transition: none;
    }
}
