/* 弹窗组件样式 */
.native-dialog-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    display: -webkit-box;
    display: -ms-flexbox;
    display: flex;
    -webkit-box-align: center;
    -ms-flex-align: center;
    align-items: center;
    -webkit-box-pack: center;
    -ms-flex-pack: center;
    justify-content: center;
    z-index: 9999;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.2s ease, visibility 0.2s ease;
}

.native-dialog-overlay.active {
    opacity: 1;
    visibility: visible;
}

.native-dialog {
    background: #fff;
    border-radius: 8px;
    width: 90%;
    max-width: 500px;
    box-shadow: 0 5px 25px rgba(0, 0, 0, 0.2);
    -webkit-transform: translateY(-20px) scale(0.95);
    transform: translateY(-20px) scale(0.95);
    transition: -webkit-transform 0.2s ease;
    transition: transform 0.2s ease;
    transition: transform 0.2s ease, -webkit-transform 0.2s ease;
    overflow: hidden;
}

.native-dialog-overlay.active .native-dialog {
    -webkit-transform: translateY(0) scale(1);
    transform: translateY(0) scale(1);
}

.native-dialog-header {
    padding: 18px 24px;
    border-bottom: 1px solid #eee;
    display: -webkit-box;
    display: -ms-flexbox;
    display: flex;
    -webkit-box-pack: justify;
    -ms-flex-pack: justify;
    justify-content: space-between;
    -webkit-box-align: center;
    -ms-flex-align: center;
    align-items: center;
}

.native-dialog-title {
    margin: 0;
    font-size: 18px;
    font-weight: 600;
    color: #2c3e50;
    display: -webkit-box;
    display: -ms-flexbox;
    display: flex;
    -webkit-box-align: center;
    -ms-flex-align: center;
    align-items: center;
    gap: 10px;
}

.native-dialog-icon {
    font-size: 20px;
}

.native-dialog-close {
    background: none;
    border: none;
    font-size: 22px;
    cursor: pointer;
    color: #999;
    transition: color 0.2s ease;
    padding: 4px;
    line-height: 1;
}

.native-dialog-close:hover {
    color: #e74c3c;
}

.native-dialog-content {
    padding: 24px;
    font-size: 16px;
    color: #34495e;
    line-height: 1.6;
    text-align: center;
}

.native-dialog-footer {
    padding: 15px 24px;
    /*border-top: 1px solid #eee;*/
    display: -webkit-box;
    display: -ms-flexbox;
    display: flex;
    gap: 10px;
}

/* 默认大屏幕按钮右对齐 */
.native-dialog-footer {
    -webkit-box-pack: end;
    -ms-flex-pack: end;
    justify-content: flex-end;
}

/* 小屏幕设备按钮居中对齐 */
@media (max-width: 480px) {
    .native-dialog-footer {
        -webkit-box-pack: center;
        -ms-flex-pack: center;
        justify-content: center;
        -webkit-box-orient: horizontal;
        -webkit-box-direction: normal;
        -ms-flex-direction: row;
        flex-direction: row;
        flex-wrap: wrap;
    }

    .native-dialog-btn {
        /*-webkit-box-flex: 1;*/
        /*-ms-flex: 1;*/
        /*flex: 1;*/
        min-width: 120px;
        justify-content: center;
    }
}

.native-dialog-btn {
    padding: 8px 18px;
    border-radius: 20px;
    border: none;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
    display: -webkit-box;
    display: -ms-flexbox;
    display: flex;
    -webkit-box-align: center;
    -ms-flex-align: center;
    align-items: center;
    gap: 6px;
}

.native-dialog-btn-default {
    background: #ecf0f1;
    color: #3498db;
}

.native-dialog-btn-default:hover {
    background: #dcdde1;
}

.native-dialog-btn-primary {
    background: #509DFF;
    color: white;
}

.native-dialog-btn-primary:hover {
    background: #4392f5;
}

.native-dialog-btn-success {
    background: #2ecc71;
    color: white;
}

.native-dialog-btn-success:hover {
    background: #27ae60;
}

.native-dialog-btn-danger {
    background: #e74c3c;
    color: white;
}

.native-dialog-btn-danger:hover {
    background: #c0392b;
}