/* ==========================================================================
   SERVEBEES UNIFIED MESSAGE & CONFIRMATION MODAL SYSTEM
   ========================================================================== */

.sb-modal-overlay {
    position: fixed;
    inset: 0;
    z-index: 100200 !important;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    background: rgba(7, 21, 37, 0.65);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition: opacity 220ms cubic-bezier(0.16, 1, 0.3, 1),
                visibility 220ms cubic-bezier(0.16, 1, 0.3, 1);
}

.sb-modal-overlay.is-active {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
}

.sb-modal-card {
    position: relative;
    width: 100%;
    max-width: 440px;
    background: #ffffff;
    border-radius: 20px;
    border: 1px solid rgba(226, 232, 240, 0.85);
    box-shadow:
        0 24px 48px -12px rgba(15, 23, 42, 0.22),
        0 8px 16px -6px rgba(15, 23, 42, 0.08),
        inset 0 1px 0 rgba(255, 255, 255, 1);
    padding: 28px 24px 24px;
    text-align: center;
    transform: scale(0.92) translateY(12px);
    transition: transform 260ms cubic-bezier(0.16, 1, 0.3, 1),
                opacity 200ms ease;
    font-family: 'Plus Jakarta Sans', 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    color: #0f172a;
    box-sizing: border-box;
}

.sb-modal-overlay.is-active .sb-modal-card {
    transform: scale(1) translateY(0);
}

/* Close Button */
.sb-modal-close-btn {
    position: absolute;
    top: 14px;
    right: 14px;
    width: 32px;
    height: 32px;
    border: none;
    background: #f1f5f9;
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
    color: #64748b;
    cursor: pointer;
    transition: all 160ms ease;
}

.sb-modal-close-btn:hover {
    background: #e2e8f0;
    color: #0f172a;
    transform: scale(1.05);
}

/* Icon Container */
.sb-modal-icon-badge {
    width: 64px;
    height: 64px;
    margin: 0 auto 18px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 28px;
    position: relative;
    box-shadow: 0 8px 20px -4px rgba(0, 0, 0, 0.08);
}

/* Icon Variants */
.sb-modal-card[data-type="success"] .sb-modal-icon-badge {
    background: #ecfdf5;
    color: #059669;
    border: 2px solid #a7f3d0;
    box-shadow: 0 10px 24px -4px rgba(16, 185, 129, 0.25);
}

.sb-modal-card[data-type="error"] .sb-modal-icon-badge {
    background: #fef2f2;
    color: #dc2626;
    border: 2px solid #fecaca;
    box-shadow: 0 10px 24px -4px rgba(239, 68, 68, 0.25);
}

.sb-modal-card[data-type="warning"] .sb-modal-icon-badge {
    background: #fffbeb;
    color: #d97706;
    border: 2px solid #fde68a;
    box-shadow: 0 10px 24px -4px rgba(245, 158, 11, 0.25);
}

.sb-modal-card[data-type="info"] .sb-modal-icon-badge {
    background: #eff6ff;
    color: #2563eb;
    border: 2px solid #bfdbfe;
    box-shadow: 0 10px 24px -4px rgba(59, 130, 246, 0.25);
}

/* Title & Content */
.sb-modal-title {
    margin: 0 0 10px;
    font-size: 19px;
    font-weight: 700;
    line-height: 1.35;
    color: #0f172a;
    letter-spacing: -0.015em;
}

.sb-modal-message {
    margin: 0 0 24px;
    font-size: 14.5px;
    font-weight: 450;
    line-height: 1.55;
    color: #475569;
    white-space: pre-line;
    max-height: 50vh;
    overflow-y: auto;
    padding: 0 4px;
    word-break: break-word;
}

/* Custom Scrollbar */
.sb-modal-message::-webkit-scrollbar {
    width: 4px;
}
.sb-modal-message::-webkit-scrollbar-thumb {
    background: #cbd5e1;
    border-radius: 4px;
}

/* Action Buttons */
.sb-modal-actions {
    display: flex;
    gap: 10px;
    justify-content: center;
    align-items: center;
}

.sb-modal-btn {
    appearance: none;
    border: none;
    border-radius: 12px;
    padding: 12px 22px;
    font-size: 14px;
    font-weight: 600;
    font-family: inherit;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    transition: all 180ms cubic-bezier(0.16, 1, 0.3, 1);
    min-width: 110px;
    line-height: 1.4;
}

.sb-modal-btn:focus-visible {
    outline: 2px solid #0284c7;
    outline-offset: 2px;
}

/* Confirm / Primary Button Variants */
.sb-modal-btn-primary {
    background: #0284c7;
    color: #ffffff;
    box-shadow: 0 4px 14px rgba(2, 132, 199, 0.32);
}

.sb-modal-btn-primary:hover {
    background: #0369a1;
    transform: translateY(-1px);
    box-shadow: 0 6px 18px rgba(2, 132, 199, 0.4);
}

.sb-modal-card[data-type="success"] .sb-modal-btn-primary {
    background: #059669;
    box-shadow: 0 4px 14px rgba(5, 150, 105, 0.32);
}
.sb-modal-card[data-type="success"] .sb-modal-btn-primary:hover {
    background: #047857;
    box-shadow: 0 6px 18px rgba(5, 150, 105, 0.4);
}

.sb-modal-card[data-type="error"] .sb-modal-btn-primary,
.sb-modal-btn-danger {
    background: #dc2626 !important;
    color: #ffffff !important;
    box-shadow: 0 4px 14px rgba(220, 38, 38, 0.32) !important;
}
.sb-modal-card[data-type="error"] .sb-modal-btn-primary:hover,
.sb-modal-btn-danger:hover {
    background: #b91c1c !important;
    box-shadow: 0 6px 18px rgba(220, 38, 38, 0.4) !important;
}

.sb-modal-card[data-type="warning"] .sb-modal-btn-primary {
    background: #d97706;
    box-shadow: 0 4px 14px rgba(217, 119, 6, 0.32);
}
.sb-modal-card[data-type="warning"] .sb-modal-btn-primary:hover {
    background: #b45309;
    box-shadow: 0 6px 18px rgba(217, 119, 6, 0.4);
}

/* Cancel Button */
.sb-modal-btn-cancel {
    background: #f1f5f9;
    color: #475569;
    border: 1px solid #e2e8f0;
}

.sb-modal-btn-cancel:hover {
    background: #e2e8f0;
    color: #0f172a;
}

/* Mobile Responsiveness */
@media (max-width: 480px) {
    .sb-modal-card {
        padding: 24px 18px 20px;
        border-radius: 16px;
    }

    .sb-modal-icon-badge {
        width: 56px;
        height: 56px;
        font-size: 24px;
        margin-bottom: 14px;
    }

    .sb-modal-title {
        font-size: 17px;
    }

    .sb-modal-message {
        font-size: 13.5px;
        margin-bottom: 20px;
    }

    .sb-modal-actions {
        flex-direction: column-reverse;
        width: 100%;
    }

    .sb-modal-btn {
        width: 100%;
        padding: 12px;
    }
}
