@import url('https://fonts.googleapis.com/css2?family=Vazirmatn:wght@400;500;600;700&display=swap');

#rahbord-bale-overlay {
    position: fixed;
    inset: 0;
    z-index: 999999;
    display: flex;
    align-items: flex-end;
    justify-content: flex-end;
    padding: 24px;
    pointer-events: none;
    opacity: 0;
    transition: opacity .35s ease;
    font-family: 'Vazirmatn', Tahoma, sans-serif;
}

#rahbord-bale-overlay.rbp-show {
    opacity: 1;
    pointer-events: auto;
}

#rahbord-bale-overlay.rbp-hide {
    opacity: 0;
    pointer-events: none;
}

#rahbord-bale-popup {
    background: #ffffff;
    border-radius: 20px;
    box-shadow: 0 28px 64px rgba(0,0,0,.22), 0 4px 16px rgba(0,0,0,.1);
    width: 340px;
    max-width: calc(100vw - 32px);
    direction: rtl;
    overflow: hidden;
    transform: translateY(24px) scale(.97);
    transition: transform .4s cubic-bezier(.22,.97,.39,1);
    border: 1px solid #e8e8e8;
}

#rahbord-bale-overlay.rbp-show #rahbord-bale-popup {
    transform: translateY(0) scale(1);
}

.rbp-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 18px 18px 16px;
    background: #111111;
    position: relative;
}

.rbp-brand {
    display: flex;
    align-items: center;
    gap: 14px;
    flex: 1;
    min-width: 0;
}

.rbp-logo {
    height: 22px;
    flex-shrink: 0;
}

.rbp-logo img {
    height: 22px;
    width: auto;
    display: block;
}

.rbp-title-wrap {
    min-width: 0;
}

.rbp-badge {
    display: inline-block;
    background: rgba(0, 184, 148, .15);
    color: #00B894;
    font-size: 10px;
    font-weight: 700;
    padding: 2px 8px;
    border-radius: 20px;
    margin-bottom: 5px;
    border: 1px solid rgba(0, 184, 148, .25);
}

.rbp-title {
    color: #ffffff;
    font-size: 12.5px;
    font-weight: 700;
    margin: 0;
    line-height: 1.4;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

#rahbord-close-btn {
    background: rgba(255,255,255,.08);
    border: 1px solid rgba(255,255,255,.12);
    cursor: pointer;
    width: 30px;
    height: 30px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #aaaaaa;
    flex-shrink: 0;
    transition: background .2s, color .2s, transform .25s;
    padding: 0;
}

#rahbord-close-btn:hover {
    background: rgba(255,255,255,.16);
    color: #ffffff;
    transform: rotate(90deg);
}

#rahbord-close-btn svg {
    width: 13px;
    height: 13px;
}

.rbp-divider {
    height: 3px;
    background: linear-gradient(90deg, #00B894, #00d4a8, #00B894);
    background-size: 200% 100%;
}

.rbp-body {
    padding: 16px 18px 12px;
    background: #fff;
}

.rbp-subtitle {
    font-size: 12px;
    font-weight: 700;
    color: #111111;
    margin: 0 0 7px;
    line-height: 1.6;
}

.rbp-desc {
    font-size: 12px;
    color: #666;
    line-height: 1.9;
    margin: 0;
}

.rbp-footer {
    padding: 4px 18px 18px;
    background: #fff;
}

.rbp-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    width: 100%;
    padding: 13px 20px;
    background: #00B894;
    color: #ffffff;
    text-decoration: none;
    border-radius: 12px;
    font-size: 13px;
    font-weight: 700;
    font-family: 'Vazirmatn', Tahoma, sans-serif;
    transition: transform .2s, box-shadow .2s, background .2s;
    box-shadow: 0 6px 20px rgba(0, 184, 148, .32);
}

.rbp-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 28px rgba(0, 184, 148, .45);
    background: #00c9a0;
    color: #fff;
    text-decoration: none;
}

.rbp-btn:active {
    transform: translateY(0);
}

.rbp-btn-icon {
    height: 16px;
    width: auto;
    flex-shrink: 0;
    filter: brightness(0) invert(1);
}

@media (max-width: 600px) {
    #rahbord-bale-overlay {
        align-items: flex-end;
        justify-content: center;
        padding: 12px;
        padding-bottom: 20px;
    }
    #rahbord-bale-popup {
        width: 100%;
        max-width: 100%;
        border-radius: 18px 18px 14px 14px;
    }
}
