.app-modal-mask {
    position: fixed;
    inset: 0;
    z-index: 9999;
    display: none;
    align-items: center;
    justify-content: center;
    background: rgba(16, 24, 40, 0.45);
}

.app-modal-mask.show {
    display: flex;
}

.app-modal {
    width: min(420px, calc(100vw - 40px));
    background: #fcfdfe;
    border: 1px solid #e0e6ed;
    border-radius: 8px;
    box-shadow: 0 18px 45px rgba(0, 0, 0, 0.22);
    overflow: hidden;
    animation: appModalIn 0.18s ease-out;
}

.app-modal-title {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 13px 16px;
    color: #fff;
    font-size: 15px;
    font-weight: 600;
    background: linear-gradient(45deg, #2c3e50, #34495e);
}

.app-modal-body {
    padding: 20px 18px 16px;
    color: #2d3748;
    font-size: 14px;
    line-height: 1.7;
    word-break: break-word;
}

.app-modal-input {
    width: 100%;
    height: 36px;
    margin-top: 12px;
    padding: 0 10px;
    border: 1px solid #dcdfe6;
    border-radius: 4px;
    outline: none;
    font-size: 14px;
}

.app-modal-input:focus {
    border-color: #3498db;
    box-shadow: 0 0 0 3px rgba(52, 152, 219, 0.12);
}

.app-modal-actions {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
    padding: 12px 16px;
    background: #f8fafc;
    border-top: 1px solid #e2e8f0;
}

.app-modal-btn {
    min-width: 76px;
    padding: 7px 14px;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 13px;
    transition: all 0.2s ease;
}

.app-modal-btn.primary {
    color: #fff;
    background: #3498db;
}

.app-modal-btn.primary:hover {
    background: #2980b9;
}

.app-modal-btn.danger {
    color: #fff;
    background: #f56c6c;
}

.app-modal-btn.danger:hover {
    background: #f78989;
}

.app-modal-btn.cancel {
    color: #606266;
    background: #fff;
    border: 1px solid #dcdfe6;
}

.app-modal-btn.cancel:hover {
    color: #3498db;
    border-color: #3498db;
}

@keyframes appModalIn {
    from {
        opacity: 0;
        transform: translateY(8px) scale(0.98);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}
