/* ============================================
   DQSS 新手引导(遮罩分步)
   配色与 dqssAi.css 保持一致
   ============================================ */

/* 遮罩 - 4 块拼起来,中央高亮区 */
.ob-mask {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(15, 23, 42, 0.65);
    z-index: 9998;
    pointer-events: auto;
    transition: opacity 0.25s ease;
    opacity: 0;
    visibility: hidden;
}
.ob-mask.show { opacity: 1; visibility: visible; }

/* 高亮区 - 用 box-shadow 在元素周围画一圈"光" */
.ob-highlight {
    position: fixed;
    border-radius: 10px;
    box-shadow:
        0 0 0 4px #fff,
        0 0 0 8px #377db5,
        0 0 0 16px rgba(55, 125, 181, 0.25),
        0 0 40px rgba(55, 125, 181, 0.5);
    z-index: 9999;
    pointer-events: none;
    transition: all 0.35s cubic-bezier(0.4, 0, 0.2, 1);
    opacity: 0;
    visibility: hidden;
}
.ob-highlight.show { opacity: 1; visibility: visible; }

/* 提示卡 */
.ob-card {
    position: fixed;
    z-index: 10000;
    background: #fff;
    border-radius: 14px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.35);
    padding: 24px 26px;
    width: 380px;
    max-width: calc(100vw - 32px);
    opacity: 0;
    transform: translateY(8px);
    transition: opacity 0.3s ease, transform 0.3s ease;
    /* 关键:默认不接收事件,只有 .show 时才接收 */
    pointer-events: none;
    visibility: hidden;
}
.ob-card.show {
    opacity: 1;
    transform: translateY(0);
    pointer-events: auto;
    visibility: visible;
}

/* 卡片内部 */
.ob-card-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 14px;
}
.ob-card-title {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 17px;
    font-weight: 600;
    color: #2a6090;
}
.ob-card-title i {
    color: #377db5;
    font-size: 20px;
}
.ob-card-step {
    font-size: 12px;
    color: #64748b;
    background: #f1f5f9;
    padding: 4px 10px;
    border-radius: 12px;
    font-weight: 500;
}
.ob-card-body {
    font-size: 14px;
    line-height: 1.7;
    color: #334155;
    margin-bottom: 18px;
}
.ob-card-body .ob-tip {
    display: block;
    margin-top: 10px;
    padding: 8px 12px;
    background: rgba(55, 125, 181, 0.08);
    border-left: 3px solid #377db5;
    border-radius: 4px;
    color: #2a6090;
    font-size: 13px;
}
.ob-card-body .ob-tip code {
    background: #fff;
    padding: 2px 6px;
    border-radius: 3px;
    color: #2a6090;
    font-family: 'Consolas', 'Monaco', monospace;
    font-size: 12px;
    border: 1px solid #e2e8f0;
}
.ob-card-body b {
    color: #2a6090;
    font-weight: 600;
}

/* 进度点 */
.ob-dots {
    display: flex;
    justify-content: center;
    gap: 6px;
    margin-bottom: 16px;
}
.ob-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #e2e8f0;
    transition: all 0.25s ease;
}
.ob-dot.active {
    background: #377db5;
    width: 24px;
    border-radius: 4px;
}
.ob-dot.done {
    background: #5a9dd3;
}

/* 按钮区 */
.ob-card-actions {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 10px;
}
.ob-btn {
    border: none;
    background: #f1f5f9;
    color: #64748b;
    padding: 9px 18px;
    border-radius: 8px;
    font-size: 14px;
    cursor: pointer;
    transition: all 0.2s ease;
    font-family: inherit;
}
.ob-btn:hover {
    background: #e2e8f0;
    color: #334155;
}
.ob-btn-primary {
    background: #377db5;
    color: #fff;
    margin-left: auto;
}
.ob-btn-primary:hover {
    background: #2a6090;
}
.ob-btn-skip {
    background: transparent;
    color: #94a3b8;
    font-size: 13px;
    padding: 9px 12px;
}
.ob-btn-skip:hover {
    background: transparent;
    color: #64748b;
}

/* 引导"开始/完成"全屏卡(无高亮那种) */
.ob-welcome {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) scale(0.95);
    z-index: 10000;
    background: #fff;
    border-radius: 18px;
    box-shadow: 0 25px 70px rgba(0, 0, 0, 0.4);
    padding: 36px 40px;
    width: 440px;
    max-width: calc(100vw - 32px);
    text-align: center;
    opacity: 0;
    transition: opacity 0.35s ease, transform 0.35s ease;
    /* 关键:默认不接收事件,只有 .show 时才接收 - 修 ob-welcome 挡住下一步按钮的 bug */
    pointer-events: none;
    visibility: hidden;
}
.ob-welcome.show {
    opacity: 1;
    transform: translate(-50%, -50%) scale(1);
    pointer-events: auto;
    visibility: visible;
}
.ob-welcome-icon {
    width: 72px;
    height: 72px;
    margin: 0 auto 18px;
    background: linear-gradient(135deg, #377db5 0%, #5a9dd3 100%);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-size: 32px;
    box-shadow: 0 8px 24px rgba(55, 125, 181, 0.4);
}
.ob-welcome-title {
    font-size: 22px;
    font-weight: 700;
    color: #2a6090;
    margin-bottom: 12px;
}
.ob-welcome-subtitle {
    font-size: 14px;
    color: #64748b;
    line-height: 1.7;
    margin-bottom: 24px;
}
.ob-welcome-subtitle b {
    color: #2a6090;
}
.ob-welcome-features {
    text-align: left;
    background: #f8fafc;
    border-radius: 10px;
    padding: 14px 18px;
    margin-bottom: 24px;
    font-size: 13px;
    color: #475569;
    line-height: 2;
}
.ob-welcome-features i {
    color: #377db5;
    width: 18px;
    margin-right: 6px;
}

/* 引导箭头(指向高亮区) */
.ob-arrow {
    position: fixed;
    z-index: 10000;
    color: #fff;
    font-size: 28px;
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.3));
    opacity: 0;
    transition: opacity 0.3s ease;
    pointer-events: none;
    visibility: hidden;
}
.ob-arrow.show { opacity: 1; visibility: visible; }

/* 移动端适配 */
@media (max-width: 768px) {
    .ob-card {
        width: calc(100vw - 24px);
        padding: 20px;
        left: 12px !important;
        right: 12px !important;
        bottom: 12px !important;
        top: auto !important;
        transform: none;
    }
    .ob-card.show {
        transform: none;
    }
    .ob-welcome {
        width: calc(100vw - 24px);
        padding: 28px 24px;
    }
}

/* 防止引导时页面滚动 */
body.ob-active {
    overflow: hidden;
}
