/* 弹窗容器 - 全屏居中布局 */
.dialog-container {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* 遮罩层 */
.dialog-mask {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    transition: opacity 0.3s ease;
}

/* 非模态框遮罩层 - 不拦截点击 */
.dialog-mask.non-modal {
    pointer-events: none;
    background: rgba(0, 0, 0, 0.2);
}

/* 弹窗主体 */
.dialog-box {
    width: 800px;
    height: 600px;
    background: var(--bg);
    border-radius: 8px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
    position: relative;
    z-index: 1;
    overflow: hidden;
    min-width: 300px;
    min-height: 200px;
    transition: transform 0.3s ease;
}

/* 可调整大小的弹窗 */
.dialog-box.resizable {
    resize: both;
    overflow: auto;
}

/* 弹窗标题栏 */
.dialog-title-bar {
    height: 48px;
    line-height: 48px;
    padding: 0 20px;
    background: var(--title);
    border-bottom: 1px solid var(--border);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

/* 弹窗标题文本 */
.dialog-title-text {
    font-weight: 500;
    color: var(--title-text);
    font-size: 16px;
}

/* 关闭按钮 */
.dialog-close-btn {
    background: transparent;
    border: none;
    font-size: 20px;
    cursor: pointer;
    color: #666;
    padding: 0 8px;
    line-height: 1;
    transition: color 0.2s ease;
}

.dialog-close-btn:hover {
    color: var(--primary);
}

.dialog-close-btn:focus {
    outline: none;
}

/* iframe 容器 */
.dialog-iframe {
    width: 100%;
    height: calc(100% - 48px);
    border: none;
    display: block;
}

/* 禁止背景滚动（弹窗打开时添加到 body） */
body.dialog-open {
    overflow: hidden;
}