/* On-Screen PM Toast Container */
#pm_toast_container {
    position: fixed;
    bottom: 24px;
    right: 24px;
    z-index: 999999;
    display: flex;
    flex-direction: column-reverse;
    gap: 10px;
    max-width: 360px;
    width: calc(100% - 32px);
    pointer-events: none;
}

@media (max-width: 768px) {
    #pm_toast_container {
        top: 16px;
        bottom: auto;
        right: 50%;
        transform: translateX(50%);
        max-width: 92%;
    }
}

/* Individual Toast Card (Pro Glassmorphism) */
.pm_toast_card {
    pointer-events: auto;
    background: linear-gradient(135deg, rgba(30, 30, 38, 0.94) 0%, rgba(18, 18, 22, 0.97) 100%);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid rgba(255, 255, 255, 0.18);
    border-radius: 16px;
    padding: 12px 14px;
    display: flex;
    align-items: center;
    gap: 12px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.6), 0 0 15px rgba(0, 198, 255, 0.25);
    cursor: pointer;
    position: relative;
    overflow: hidden;
    animation: pmToastSlideIn 0.35s cubic-bezier(0.175, 0.885, 0.32, 1.275) forwards;
    transition: transform 0.2s ease, box-shadow 0.2s ease, opacity 0.3s ease;
}

.pm_toast_card:hover {
    transform: translateY(-3px) scale(1.02);
    box-shadow: 0 14px 35px rgba(0, 0, 0, 0.7), 0 0 22px rgba(0, 198, 255, 0.4);
    border-color: rgba(255, 255, 255, 0.35);
}

.pm_toast_card.hiding {
    animation: pmToastSlideOut 0.3s ease forwards;
}

/* Toast Avatar Container */
.pm_toast_avatar_wrap {
    position: relative;
    flex-shrink: 0;
}

.pm_toast_avatar {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid #00c6ff;
    box-shadow: 0 0 10px rgba(0, 198, 255, 0.4);
}

.pm_toast_badge {
    position: absolute;
    bottom: -2px;
    right: -2px;
    background: #00c6ff;
    color: #ffffff;
    font-size: 9px;
    width: 17px;
    height: 17px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 2px solid #141418;
}

/* Toast Body Data */
.pm_toast_body {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
}

.pm_toast_header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 2px;
}

.pm_toast_name {
    font-weight: 800;
    font-size: 13.5px;
    color: #ffffff;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    text-shadow: 0 1px 3px rgba(0,0,0,0.5);
}

.pm_toast_tag {
    font-size: 9.5px;
    font-weight: 800;
    text-transform: uppercase;
    background: linear-gradient(90deg, #ff007f 0%, #7f00ff 100%);
    color: #ffffff;
    padding: 2px 7px;
    border-radius: 8px;
    letter-spacing: 0.5px;
}

.pm_toast_msg {
    font-size: 12px;
    color: #d0d0dc;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    line-height: 1.3;
}

/* Toast Controls (Settings Gear & Close) */
.pm_toast_controls {
    display: flex;
    align-items: center;
    gap: 6px;
    flex-shrink: 0;
}

.pm_toast_settings_btn {
    color: rgba(255, 255, 255, 0.45);
    font-size: 13px;
    padding: 3px;
    cursor: pointer;
    transition: color 0.2s ease, transform 0.2s ease;
}

.pm_toast_settings_btn:hover {
    color: #00c6ff;
    transform: rotate(45deg);
}

/* Toast Close Button */
.pm_toast_close {
    color: rgba(255, 255, 255, 0.45);
    font-size: 14px;
    padding: 3px;
    cursor: pointer;
    transition: color 0.2s ease;
    flex-shrink: 0;
}

.pm_toast_close:hover {
    color: #ff4757;
}

/* Bottom Progress Bar Timer */
.pm_toast_progress {
    position: absolute;
    bottom: 0;
    left: 0;
    height: 3px;
    background: linear-gradient(90deg, #00c6ff 0%, #0072ff 100%);
    width: 100%;
    animation: pmToastProgress 10s linear forwards;
}

@keyframes pmToastSlideIn {
    0% {
        opacity: 0;
        transform: translateY(30px) scale(0.9);
    }
    100% {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

@keyframes pmToastSlideOut {
    0% {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
    100% {
        opacity: 0;
        transform: translateY(-20px) scale(0.9);
    }
}

@keyframes pmToastProgress {
    0% {
        width: 100%;
    }
    100% {
        width: 0%;
    }
}

/* Block Banner in PM Chat Window (Exact Mockup Match!) */
.pm_block_banner {
    background: #d0e8ff !important;
    color: #1b4f72 !important;
    font-weight: 700 !important;
    font-size: 13.5px !important;
    text-align: center !important;
    padding: 10px 22px !important;
    border-radius: 20px !important;
    margin: 12px auto 16px auto !important;
    width: fit-content !important;
    max-width: 90% !important;
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.25) !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 12px !important;
    z-index: 100 !important;
    position: relative !important;
}

.pm_block_unblock_btn {
    background: #1b4f72 !important;
    color: #ffffff !important;
    border: none !important;
    border-radius: 14px !important;
    padding: 4px 14px !important;
    font-size: 12px !important;
    font-weight: 800 !important;
    cursor: pointer !important;
    transition: background 0.2s ease, transform 0.2s ease !important;
}

.pm_block_unblock_btn:hover {
    background: #003366 !important;
    transform: scale(1.05) !important;
}

/* PM Disabled Inputs when Blocked */
.pm_blocked_disabled {
    pointer-events: none !important;
    opacity: 0.45 !important;
}

/* Mobile Touch & Hardware Acceleration for Swipe Right to Reply */
.privlog, .chat_log, .inpriv, .outpriv,
.private_logs, .chat_message, .target_private, .hunter_private, .privcont {
    touch-action: pan-y !important;
}

/* User List Bottom Padding Fix for Mobile Drawer (prevents bottom cut-off) */
#chat_right_data {
    padding-bottom: 120px !important;
}

@media (max-width: 800px) {
    #chat_right_data {
        padding-bottom: 140px !important;
    }
}
