/* ===== CTA Box - Professional Design ===== */

.ctabox {
    display: flex;
    align-items: center;
    gap: 18px;
    background: #f6f8fb;
    border: 1px solid #e3e8ef;
    border-radius: 14px;
    padding: 14px 18px;
    margin: 28px 0;
    box-shadow: 0 4px 14px rgba(20, 40, 80, 0.05);
    font-family: "YekanBakh", Sans-serif;
    transition: box-shadow 0.25s ease, transform 0.25s ease;
    direction: rtl;
}

.ctabox:hover {
    box-shadow: 0 8px 22px rgba(20, 40, 80, 0.10);
    transform: translateY(-2px);
}

/* --- تصویر --- */
.ctabox-image {
    flex: 0 0 auto;
}

.ctabox-image img {
    width: 120px;
    aspect-ratio: 1000 / 562;
    object-fit: cover;
    border-radius: 10px;
    display: block;
}


/* --- محتوا (وسط) --- */
.ctabox-content {
    flex: 1 1 auto;
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.ctabox-label {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 13px;
    font-weight: 600;
    color: #5b6b85;
}

.ctabox-title {
    font-size: 17px;
    font-weight: 700;
    line-height: 1.5;
    color: #000;
    text-decoration: none;
    transition: color 0.2s ease;

    /* جلوگیری از بلند شدن بیش از حد عنوان */
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.ctabox-title:hover {
    color: #2563eb;
}

/* --- دکمه (سمت چپ) --- */
.ctabox-action {
    flex: 0 0 auto;
}

.ctabox-button {
    display: inline-block;
    background: #1c2a44;
    color: #ffffff !important;
    font-size: 14px;
    font-weight: 600;
    text-decoration: none;
    padding: 9px 18px;
    border-radius: 9px;
    white-space: nowrap;
    transition: background 0.2s ease, transform 0.15s ease;
}

.ctabox-button:hover {
    background: #2563eb;
    transform: translateY(-1px);
}

/* --- آیکون لامپ متحرک --- */
.ctabox-lamp {
    fill: #f5c518;
    filter: drop-shadow(0 0 2px rgba(245, 197, 24, 0.55));
    animation: ctaLampGlow 1.6s ease-in-out infinite;
    width: 23px;
    height: 23px;
}

@keyframes ctaLampGlow {
    0%, 100% { opacity: 0.45; }
    50%      { opacity: 1; }
}

/* احترام به تنظیم کاهش حرکت کاربر */
@media (prefers-reduced-motion: reduce) {
    .ctabox-lamp {
        animation: none;
        opacity: 1;
    }
}

/* ===== نسخه موبایل ===== */
@media (max-width: 600px) {
    .ctabox {
        gap: 12px;
        padding: 12px;
        border-radius: 12px;
        margin: 20px 0;

        /* چیدمان شبکه‌ای: تصویر کنار متن، دکمه تمام‌عرض زیر آن */
        display: grid;
        grid-template-columns: auto 1fr;
        align-items: center;
    }


  .ctabox-image img {
    width: 90px;
    border-radius: 9px;
}



    .ctabox-content {
        gap: 4px;
    }

    .ctabox-label {
        font-size: 12px;
    }

    .ctabox-title {
        font-size: 14px;
        -webkit-line-clamp: 2;
    }

    /* دکمه به ردیف بعد می‌رود و تمام عرض را می‌گیرد */
    .ctabox-action {
        grid-column: 1 / -1;
    }

    .ctabox-button {
        display: block;
        text-align: center;
        width: 100%;
        font-size: 13px;
        padding: 10px;
    }
}
