/* ========================================================================== 
   بخش تصاویر
   ========================================================================== */
   .screenshots-section {
    padding: 60px 0;
    background-color: var(--background);
    text-align: center;
    position: relative;
    overflow: hidden;
}

.screenshots-section .section-heading {
    margin-bottom: 40px;
    font-size: 28px;
    font-weight: bold;
    color: var(--primary);
    position: relative;
    z-index: 1;
}

.screenshots-section .screenshots-container {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 20px;
    position: relative;
    z-index: 1;
}

.screenshots-section .screenshot-item {
    flex: 1 1 300px;
    max-width: 300px;
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.1);
    border-radius: 12px;
    overflow: hidden;
    background: var(--text-light);
    padding: 15px;
    text-align: center;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    position: relative;
    z-index: 2; /* اطمینان از اینکه باکس‌ها بالاتر از انیمیشن‌ها هستند */
}

.screenshots-section .screenshot-item:hover {
    transform: translateY(-10px);
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.2);
}

.screenshots-section .screenshot-item img {
    width: 100%;
    height: auto;
    object-fit: cover;
    border-radius: 8px;
    margin-bottom: 8px;
    transition: transform 0.3s ease;
}

.screenshots-section .screenshot-item:hover img {
    transform: scale(1.05);
}

/* استایل عنوان‌ها */
.screenshots-section .screenshot-item h4 {
    font-size: 18px;
    color: var(--text-dark);
    font-weight: bold;
    margin-top: 10px;
    text-align: center;
    transition: color 0.3s ease;
}

.screenshots-section .screenshot-item:hover h4 {
    color: var(--primary);
}

/* افکت‌های پس‌زمینه */
.screenshots-section::before {
    content: "";
    position: absolute;
    top: -100px;
    left: -100px;
    width: 300px;
    height: 300px;
    background: rgba(255, 193, 7, 0.2);
    border-radius: 50%;
    z-index: 0; /* قرار دادن در لایه پایین‌تر */
    animation: float 6s ease-in-out infinite;
    pointer-events: none; /* جلوگیری از مسدود کردن کلیک */
}

.screenshots-section::after {
    content: "";
    position: absolute;
    bottom: -100px;
    right: -100px;
    width: 400px;
    height: 400px;
    background: rgba(0, 123, 255, 0.2);
    border-radius: 50%;
    z-index: 0; /* قرار دادن در لایه پایین‌تر */
    animation: float-reverse 8s ease-in-out infinite;
    pointer-events: none; /* جلوگیری از مسدود کردن کلیک */
}

/* انیمیشن‌های شناور */
@keyframes float {
    0%, 100% {
        transform: translateY(0);
    }
    50% {
        transform: translateY(-20px);
    }
}

@keyframes float-reverse {
    0%, 100% {
        transform: translateY(0);
    }
    50% {
        transform: translateY(20px);
    }
}

/* برای دستگاه‌های کوچک‌تر از 768px */
@media (max-width: 768px) {
    .screenshots-section .screenshot-item {
        display: flex;
        flex-direction: column; /* ترتیب نمایش: اول عنوان، سپس تصویر */
        align-items: center;
    }

    .screenshots-section .screenshot-item h4 {
        font-size: 16px; /* کاهش اندازه فونت برای دستگاه‌های کوچک‌تر */
        margin-bottom: 8px; /* فاصله از تصویر */
        margin-top: 0; /* حذف فاصله اضافی بالا */
    }

    .screenshots-section .screenshot-item img {
        width: 100%;
        height: auto; /* ارتفاع خودکار برای تناسب بهتر */
        object-fit: contain; /* نمایش کامل تصویر بدون برش */
        margin-bottom: 0; /* حذف فاصله اضافی پایین */
    }
}

/* برای دستگاه‌های کوچک‌تر از 480px */
@media (max-width: 480px) {
    .screenshots-section .screenshot-item h4 {
        font-size: 14px; /* کاهش بیشتر اندازه فونت برای دستگاه‌های بسیار کوچک */
        margin-bottom: 6px;
    }

    .screenshots-section .screenshot-item img {
        width: 100%; /* عرض تصویر را به اندازه باکس تنظیم می‌کند */
        height: auto; /* ارتفاع خودکار برای نمایش کامل */
        object-fit: contain; /* نمایش کامل تصویر بدون برش */
    }
}