/* YesOnline global system message box */
#sys-msg-box-root {
    position: fixed;
    inset: 0;
    z-index: 12000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1rem;
    font-family: "Inter", "Segoe UI", system-ui, -apple-system, sans-serif;
}

#sys-msg-box-root[hidden] {
    display: none !important;
}

#sys-msg-box-root .sys-msg-box-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(15, 23, 42, 0.48);
    backdrop-filter: blur(3px);
}

#sys-msg-box-root .sys-msg-box-dialog {
    position: relative;
    z-index: 1;
    width: min(100%, 24rem);
    background: #fff;
    border-radius: 16px;
    box-shadow: 0 24px 60px rgba(15, 23, 42, 0.28);
    padding: 1.35rem 1.35rem 1.1rem;
    display: flex;
    flex-direction: column;
    gap: 1rem;
    animation: sys-msg-box-in 0.18s ease-out;
}

@keyframes sys-msg-box-in {
    from { opacity: 0; transform: scale(0.96) translateY(8px); }
    to { opacity: 1; transform: none; }
}

#sys-msg-box-root .sys-msg-box-header {
    display: flex;
    align-items: flex-start;
    gap: 0.85rem;
}

#sys-msg-box-root .sys-msg-box-icon {
    width: 2.5rem;
    height: 2.5rem;
    min-width: 2.5rem;
    min-height: 2.5rem;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    overflow: hidden;
}

#sys-msg-box-root .sys-msg-box-icon svg {
    display: block;
    width: 1.25rem;
    height: 1.25rem;
    max-width: 1.25rem;
    max-height: 1.25rem;
    flex-shrink: 0;
}

#sys-msg-box-root .sys-msg-box-icon.is-info { background: #eef2ff; color: #4f46e5; }
#sys-msg-box-root .sys-msg-box-icon.is-ok { background: #ecfdf5; color: #059669; }
#sys-msg-box-root .sys-msg-box-icon.is-error { background: #fef2f2; color: #dc2626; }
#sys-msg-box-root .sys-msg-box-icon.is-warning { background: #fffbeb; color: #d97706; }
#sys-msg-box-root .sys-msg-box-icon.is-question { background: #f0f9ff; color: #0284c7; }

#sys-msg-box-root .sys-msg-box-body {
    flex: 1;
    min-width: 0;
    padding-top: 0.15rem;
}

#sys-msg-box-root .sys-msg-box-title {
    margin: 0 0 0.4rem;
    font-size: 1.02rem;
    font-weight: 700;
    color: #0f172a;
    line-height: 1.35;
}

#sys-msg-box-root .sys-msg-box-title[hidden] {
    display: none !important;
}

#sys-msg-box-root .sys-msg-box-message {
    margin: 0;
    font-size: 0.875rem;
    color: #475569;
    line-height: 1.5;
}

#sys-msg-box-root .sys-msg-box-actions {
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-end;
    align-items: center;
    gap: 0.5rem;
    padding-top: 0.15rem;
    border-top: 1px solid #f1f5f9;
}

#sys-msg-box-root .sys-msg-box-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 2.15rem;
    padding: 0.48rem 1.1rem;
    border-radius: 999px;
    border: 1px solid #e2e8f0;
    background: #fff;
    color: #334155;
    font-family: inherit;
    font-size: 0.8125rem;
    font-weight: 600;
    line-height: 1.2;
    letter-spacing: 0;
    text-transform: none;
    cursor: pointer;
    appearance: none;
    -webkit-appearance: none;
    box-shadow: none;
    transition: background 0.12s, border-color 0.12s, box-shadow 0.12s, transform 0.1s;
}

#sys-msg-box-root .sys-msg-box-btn:hover {
    background: #f8fafc;
    border-color: #cbd5e1;
}

#sys-msg-box-root .sys-msg-box-btn:focus-visible {
    outline: 2px solid #6366f1;
    outline-offset: 2px;
}

#sys-msg-box-root .sys-msg-box-btn.is-primary {
    border-color: transparent;
    background: linear-gradient(135deg, #4f46e5, #6366f1);
    color: #fff;
}

#sys-msg-box-root .sys-msg-box-btn.is-primary:hover {
    box-shadow: 0 4px 14px rgba(79, 70, 229, 0.38);
    transform: translateY(-1px);
}

#sys-msg-box-root .sys-msg-box-btn.is-danger {
    border-color: transparent;
    background: #ef4444;
    color: #fff;
}

#sys-msg-box-root .sys-msg-box-btn.is-danger:hover {
    background: #dc2626;
    box-shadow: 0 4px 14px rgba(239, 68, 68, 0.35);
}
