/* Base Container */
.rpb-box {
    background-color: var(--rpb-bg, #ffffff);
    border-radius: 12px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05);
    border: 1px solid #e0e0e0; /* کمی تیره‌تر برای دیده شدن بهتر مرز */
    position: relative;
    margin: 35px auto; /* فاصله از بالا بیشتر شد تا برچسب جا بشود */
    padding: 20px;
    font-family: inherit;
    box-sizing: border-box;
    display: flex;
    direction: rtl;
    line-height: normal;
    max-width: 600px;
    width: 100%;
}

/* Label (Top Right) - تنظیمات کلی برای همه استایل‌ها */
.rpb-label {
    position: absolute;
    top: -15px; /* این عدد باعث می‌شود برچسب روی لبه قرار بگیرد */
    right: 20px;
    background-color: #2e7d32;
    color: #fff;
    padding: 5px 15px;
    border-radius: 8px;
    font-size: 13px;
    font-weight: bold;
    z-index: 10;
    line-height: 1.5;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

/* Title */
.rpb-title {
    color: var(--rpb-text, #000);
    margin: 0 !important;
    font-size: 19px !important;
    font-weight: 800 !important;
    line-height: 1.5 !important;
}

/* Divider */
.rpb-divider {
    height: 1px;
    border-bottom: 2px dotted #90caf9;
    width: 100%;
    margin-top: 15px;
    margin-bottom: 15px;
}

/* --- STYLE 1 (Vertical) --- */
.rpb-box.style_1 {
    flex-direction: column;
    align-items: center;
    text-align: center;
    padding: 40px 30px 30px 30px;
}

/* نکته اصلاحی: حذف دستور top مثبت برای استایل ۱ */
.rpb-box.style_1 .rpb-label {
    /* قبلا اینجا top: 15px بود که حذف شد تا از تنظیمات کلی پیروی کند */
    right: 30px; /* کمی فاصله افقی متناسب با سایز بزرگ */
}

.rpb-box.style_1 .rpb-title {
    margin-top: 10px !important;
    font-size: 22px !important;
}

.rpb-box.style_1 .rpb-divider {
    width: 90%;
    margin: 20px auto;
}

.rpb-btn-horizontal {
    background-color: var(--rpb-btn, #4CAF50);
    color: #fff !important;
    text-decoration: none !important;
    padding: 10px 50px;
    border-radius: 8px;
    font-size: 18px;
    font-weight: bold;
    display: inline-block;
    transition: transform 0.2s, opacity 0.2s;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.rpb-btn-horizontal:hover {
    transform: translateY(-2px);
    opacity: 0.9;
}

/* --- STYLE 2 (Horizontal No Image) --- */
.rpb-box.style_2 {
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
    padding: 30px 25px 25px 25px;
}

.rpb-box.style_2 .rpb-content {
    flex-grow: 1;
    padding-left: 20px;
}

/* --- STYLE 3 (Horizontal With Image) --- */
.rpb-box.style_3 {
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
    padding: 25px;
}

.rpb-box.style_3 .rpb-thumb {
    width: 80px;
    height: 80px;
    flex-shrink: 0;
    margin-left: 15px;
}

.rpb-box.style_3 .rpb-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 10px;
    margin: 0;
    display: block;
}

.rpb-box.style_3 .rpb-content {
    flex-grow: 1;
    padding: 0 10px;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

/* Vertical Button (Style 2 & 3) */
.rpb-btn-vertical {
    background-color: var(--rpb-btn, #4CAF50);
    color: #fff !important;
    text-decoration: none !important;
    padding: 8px 12px;
    border-radius: 8px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    font-size: 15px;
    line-height: 1.3;
    text-align: center;
    min-width: 60px;
    transition: opacity 0.2s;
}

.rpb-btn-vertical span {
    display: block;
}

.rpb-btn-vertical:hover {
    opacity: 0.9;
}

/* Mobile Responsive */
@media (max-width: 600px) {
    .rpb-box {
        margin: 30px 10px; /* فاصله از کناره‌ها در موبایل */
        width: auto;
    }

    .rpb-box.style_2,
    .rpb-box.style_3 {
        flex-direction: column;
        text-align: center;
    }

    .rpb-box.style_2 .rpb-divider {
        margin: 10px auto;
        width: 60%;
    }

    .rpb-box.style_2 .rpb-content,
    .rpb-box.style_3 .rpb-content {
        padding: 0;
        width: 100%;
    }

    .rpb-btn-vertical {
        flex-direction: row;
        width: 100%;
        margin: 15px 0 0 0;
        padding: 10px;
    }

    .rpb-btn-vertical span {
        display: inline;
        margin: 0 3px;
    }

    .rpb-box.style_3 .rpb-thumb {
        margin: 0 0 15px 0;
    }
}