/* ============================================================
   howtoUse.css — 使用指南页面样式
   ============================================================ */

.howto-container {
    max-width: 800px;
    margin: 0 auto;
    padding: 2rem 1.5rem 4rem;
}

/* ---- Hero ---- */
.howto-hero {
    text-align: center;
    padding: 3rem 0 2.5rem;
}

.howto-hero-title {
    font-size: 2.5rem;
    font-weight: 700;
    background: linear-gradient(135deg, #b3b9ff, #9f7aea);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 0.5rem;
}

.howto-hero-sub {
    color: #7a8499;
    font-size: 1.05rem;
}

/* ---- 步骤卡片 ---- */
.howto-step {
    background: rgba(15, 18, 28, 0.7);
    border: 1px solid #2d3540;
    border-radius: 20px;
    padding: 1.75rem 2rem;
    margin-bottom: 1.5rem;
    position: relative;
    overflow: hidden;
}

.howto-step::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 2px;
    background: linear-gradient(90deg, #9f7aea, #5dade2);
    opacity: 0.6;
}

.step-header {
    display: flex;
    align-items: center;
    gap: 1.25rem;
    margin-bottom: 1.25rem;
}

.step-num {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 48px;
    height: 48px;
    background: linear-gradient(135deg, #9f7aea, #7c3aed);
    border-radius: 50%;
    font-size: 1.3rem;
    font-weight: 700;
    color: white;
    flex-shrink: 0;
    box-shadow: 0 4px 16px rgba(159, 122, 234, 0.3);
}

.step-meta {
    flex: 1;
}

.step-title {
    font-size: 1.2rem;
    font-weight: 600;
    color: #e1e8f0;
    margin-bottom: 0.2rem;
}

.step-subtitle {
    font-size: 0.82rem;
    color: #9f7aea;
    font-family: 'Courier New', monospace;
}

.step-content {
    padding-left: calc(48px + 1.25rem);
}

.step-desc {
    color: #8a94a8;
    line-height: 1.75;
    font-size: 0.9rem;
    margin-bottom: 1.25rem;
}

.step-desc code {
    background: rgba(159, 122, 234, 0.12);
    border: 1px solid rgba(159, 122, 234, 0.2);
    border-radius: 6px;
    padding: 0.1rem 0.45rem;
    font-family: 'Courier New', monospace;
    font-size: 0.82rem;
    color: #b3b9ff;
}

/* ---- 截图区域 ---- */
.step-screenshot {
    margin-bottom: 1rem;
}

.screenshot-placeholder {
    width: 100%;
    background: rgba(10, 12, 16, 0.6);
    border: 1px dashed rgba(159, 122, 234, 0.3);
    border-radius: 14px;
    aspect-ratio: 16 / 9;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    overflow: hidden;
    position: relative;
}

.screenshot-placeholder img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 14px;
    cursor: zoom-in;
}

.screenshot-placeholder .shot-placeholder-icon {
    font-size: 3rem;
    opacity: 0.4;
}

.screenshot-placeholder .shot-placeholder-text {
    font-size: 0.8rem;
    color: #5a6270;
    font-family: 'Courier New', monospace;
}

.screenshot-caption {
    text-align: center;
    font-size: 0.78rem;
    color: #5a6270;
    margin-top: 0.5rem;
    font-style: italic;
}

/* ---- 图片全屏预览 ---- */
#imgLightbox {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.94);
    z-index: 10000;
    display: none;
    align-items: center;
    justify-content: center;
}

#lightboxImg {
    max-width: 95vw;
    max-height: 95vh;
    object-fit: contain;
    border: none;
    border-radius: 8px;
    cursor: zoom-out;
}

#lightboxCloseBtn {
    position: fixed;
    top: 1rem;
    right: 1rem;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.15);
    color: #fff;
    font-size: 1.5rem;
    line-height: 1;
    width: 2.2rem;
    height: 2.2rem;
    border-radius: 50%;
    cursor: pointer;
    z-index: 10001;
    transition: background 0.15s;
}
#lightboxCloseBtn:hover { background: rgba(255, 255, 255, 0.25); }

/* ---- 命令行块 ---- */
.step-commands {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    margin-bottom: 1rem;
}

.step-cmd-item {
    background: #0a0c10;
    border: 1px solid #2d3540;
    border-radius: 10px;
    overflow: hidden;
}

.step-cmd-label {
    background: rgba(159, 122, 234, 0.08);
    border-bottom: 1px solid #2d3540;
    padding: 0.4rem 1rem;
    font-size: 0.75rem;
    color: #9f7aea;
    font-family: 'Courier New', monospace;
}

.step-cmd-code {
    padding: 0.7rem 1rem;
    font-family: 'Courier New', Consolas, monospace;
    font-size: 0.85rem;
    color: #c3e88d;
    white-space: pre;
}

/* ---- 提示框 ---- */
.step-note {
    display: flex;
    gap: 0.6rem;
    background: rgba(14, 165, 233, 0.07);
    border: 1px solid rgba(14, 165, 233, 0.18);
    border-radius: 10px;
    padding: 0.7rem 1rem;
    font-size: 0.83rem;
    color: #7ab8d4;
    line-height: 1.55;
    align-items: flex-start;
}

.note-icon {
    font-size: 1rem;
    flex-shrink: 0;
}

.step-note code {
    background: rgba(14, 165, 233, 0.1);
    border-radius: 4px;
    padding: 0.05rem 0.35rem;
    font-family: 'Courier New', monospace;
    font-size: 0.8rem;
}

/* ---- 连接方式选项 ---- */
.step-choices {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.choice-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    background: rgba(10, 12, 16, 0.5);
    border: 1px solid #2d3540;
    border-radius: 10px;
    padding: 0.8rem 1.1rem;
}

.choice-tag {
    background: rgba(159, 122, 234, 0.15);
    border: 1px solid rgba(159, 122, 234, 0.3);
    border-radius: 20px;
    padding: 0.2rem 0.75rem;
    font-size: 0.78rem;
    font-weight: 600;
    color: #b3b9ff;
    white-space: nowrap;
    flex-shrink: 0;
}

.choice-desc {
    color: #8a94a8;
    font-size: 0.82rem;
    line-height: 1.5;
}

/* ---- 完成区域 ---- */
.howto-complete {
    text-align: center;
    padding: 3rem 2rem;
    background: linear-gradient(135deg, rgba(159, 122, 234, 0.08), rgba(93, 173, 226, 0.04));
    border: 1px solid rgba(159, 122, 234, 0.2);
    border-radius: 20px;
    margin-top: 1rem;
}

.complete-icon {
    font-size: 3.5rem;
    margin-bottom: 1rem;
}

.howto-complete h2 {
    font-size: 1.4rem;
    color: #e1e8f0;
    margin-bottom: 0.5rem;
}

.howto-complete p {
    color: #7a8499;
    font-size: 0.9rem;
    margin-bottom: 1.5rem;
}

.howto-btn {
    display: inline-block;
    background: linear-gradient(135deg, #9f7aea, #7c3aed);
    color: white;
    text-decoration: none;
    padding: 0.7rem 2rem;
    border-radius: 40px;
    font-weight: 600;
    font-size: 0.9rem;
    transition: all 0.2s;
    box-shadow: 0 4px 16px rgba(159, 122, 234, 0.25);
}

.howto-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(159, 122, 234, 0.35);
}

/* ---- 响应式 ---- */
@media (max-width: 600px) {
    .step-content {
        padding-left: 0;
        margin-top: 0.75rem;
    }

    .howto-hero-title {
        font-size: 1.8rem;
    }

    .howto-step {
        padding: 1.25rem 1.25rem;
    }

    .step-cmd-code {
        font-size: 0.75rem;
    }

    .choice-item {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.4rem;
    }
}
