/* استایل بنرهای هوشمند - نسخه مدرن و موبایل‌فرندلی */

.pcm-smart-banner-wrapper {
    margin: 30px 0;
    padding: 0;
    direction: rtl;
    text-align: right;
}

.pcm-smart-banner {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 10px 40px rgba(102, 126, 234, 0.3);
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    display: flex;
    flex-direction: column;
    max-width: 800px;
    margin: 0 auto;
}

.pcm-smart-banner:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 50px rgba(102, 126, 234, 0.4);
}

/* تصویر بنر */
.pcm-banner-image {
    position: relative;
    width: 100%;
    height: 450px;
    overflow: hidden;
}

.pcm-banner-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.pcm-smart-banner:hover .pcm-banner-image img {
    transform: scale(1.08);
}

.pcm-banner-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(to bottom, transparent 0%, rgba(0,0,0,0.3) 100%);
}

/* محتوای بنر */
.pcm-banner-content {
    padding: 24px 28px 28px;
    background: white;
    position: relative;
}

.pcm-banner-title {
    font-size: 22px;
    font-weight: 700;
    color: #1a202c;
    margin: 0 0 12px 0;
    line-height: 1.4;
}

.pcm-banner-description {
    font-size: 15px;
    color: #4a5568;
    line-height: 1.7;
    margin: 0 0 20px 0;
}

/* دکمه CTA */
.pcm-banner-cta {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 12px 28px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    text-decoration: none;
    border-radius: 8px;
    font-weight: 600;
    font-size: 15px;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.4);
}

.pcm-banner-cta:hover {
    background: linear-gradient(135deg, #764ba2 0%, #667eea 100%);
    transform: translateX(-3px);
    box-shadow: 0 6px 20px rgba(102, 126, 234, 0.5);
    color: white;
    text-decoration: none;
}

.pcm-banner-cta svg {
    transition: transform 0.3s ease;
}

.pcm-banner-cta:hover svg {
    transform: translateX(-4px);
}

/* حالت بدون تصویر */
.pcm-smart-banner:not(:has(.pcm-banner-image)) {
    background: white;
    border: 2px solid #e2e8f0;
}

.pcm-smart-banner:not(:has(.pcm-banner-image)) .pcm-banner-content {
    padding: 32px 28px;
}

.pcm-smart-banner:not(:has(.pcm-banner-image)) .pcm-banner-title {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* موبایل فرندلی */
@media (max-width: 768px) {
    .pcm-smart-banner-wrapper {
        margin: 20px 0;
    }
    
    .pcm-smart-banner {
        border-radius: 12px;
    }
    
    .pcm-banner-image {
        height: 350px;
    }
    
    /* تغییر object-fit برای نمایش کامل تصویر در موبایل */
    .pcm-banner-image img {
        object-fit: contain;
        background: #f8f9fa;
    }
    
    .pcm-banner-content {
        padding: 20px;
    }
    
    .pcm-banner-title {
        font-size: 19px;
    }
    
    .pcm-banner-description {
        font-size: 14px;
    }
    
    .pcm-banner-cta {
        width: 100%;
        justify-content: center;
        padding: 14px 24px;
    }
}

@media (max-width: 480px) {
    .pcm-banner-image {
        height: 300px;
    }
    
    /* تغییر object-fit برای نمایش کامل تصویر در موبایل کوچک */
    .pcm-banner-image img {
        object-fit: contain;
        background: #f8f9fa;
    }
    
    .pcm-banner-title {
        font-size: 17px;
    }
    
    .pcm-banner-description {
        font-size: 13px;
        margin-bottom: 16px;
    }
}

/* انیمیشن ورود */
@keyframes bannerFadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.pcm-smart-banner-wrapper {
    animation: bannerFadeIn 0.6s ease-out;
}

/* تاریک مود (اختیاری) */
@media (prefers-color-scheme: dark) {
    .pcm-smart-banner:not(:has(.pcm-banner-image)) {
        background: #1a202c;
        border-color: #2d3748;
    }
    
    .pcm-smart-banner:not(:has(.pcm-banner-image)) .pcm-banner-content {
        background: #1a202c;
    }
    
    .pcm-smart-banner .pcm-banner-content {
        background: #1a202c;
    }
    
    .pcm-banner-title {
        color: #f7fafc;
    }
    
    .pcm-banner-description {
        color: #a0aec0;
    }
}