/* ===== 文档中心 doc.css ===== */

/* 复用 about.html 的 banner 样式 */
.a-banner {
    height: 540px;
    background: url(../images/banner_about.jpg) no-repeat center center;
    background-size: cover;
    position: relative;
}

.banner-box {
    width: 1200px;
    height: 100%;
    position: absolute;
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%);
    z-index: 2;
}

.about-text {
    width: 600px;
    position: absolute;
    top: 50%;
    left: 0;
    transform: translate(0, -50%);
}

.about-text h1 {
    font-size: 45px;
    font-weight: bold;
    color: #19293A;
    padding: 20px;
    display: block;
}

.about-text span {
    font-size: 18px;
    padding: 15px;
    color: #303133;
    display: block;
}

.about_psd {
    width: 540px;
    height: 450px;
    background: url(../images/about_psd.png) no-repeat center center;
    background-size: cover;
    position: absolute;
    bottom: 0;
    right: 0;
}

/* 文档主体 */
.doc-section {
    background: #f5f7fa;
    padding: 48px 0 80px;
    min-height: 50vh;
}

/* 确保 footer 正常显示 */
body.page-doc .footer {
    display: block !important;
    visibility: visible !important;
    background: #19293A !important;  /* 深色背景，确保可见 */
    margin-top: 0;
}

.doc-wrapper {
    display: flex;
    gap: 32px;
    align-items: stretch;   /* 让侧边栏和内容区一样高 */
    min-height: 70vh;   /* 确保内容区足够高，footer 不会跑到中间 */
}

/* 左侧导航 */
.doc-sidebar {
    width: 240px;
    flex-shrink: 0;
    position: sticky;
    top: 20px;
    background: #fff;
    border-radius: 8px;
    box-shadow: 0 2px 12px rgba(0,0,0,0.06);
    overflow: hidden;
}

.doc-sidebar-title {
    padding: 20px 24px;
    font-size: 16px;
    font-weight: bold;
    color: #fff;
    background: linear-gradient(135deg, #0067ED 0%, #3d8bff 100%);
}

.doc-nav {
    list-style: none;
    padding: 8px 0;
}

.doc-nav li {
    padding: 14px 24px;
    font-size: 15px;
    color: #303133;
    cursor: pointer;
    border-left: 3px solid transparent;
    transition: all 0.2s;
    display: flex;
    align-items: center;
    gap: 8px;
}

.doc-nav li:hover {
    background: #f0f9eb;
    color: #0067ED;
}

.doc-nav li.active {
    background: #f0f9eb;
    color: #0067ED;
    border-left-color: #0067ED;
    font-weight: bold;
}

.doc-nav li .doc-nav-icon {
    width: 20px;
    height: 20px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
}

/* 右侧内容 */
.doc-content {
    flex: 1;
    min-width: 0;
    min-height: 80vh;   /* 确保内容区足够高，footer 不会跑到中间 */
}

.doc-panel {
    display: none;
    background: #fff;
    border-radius: 8px;
    box-shadow: 0 2px 12px rgba(0,0,0,0.06);
    overflow: hidden;
}

.doc-panel.active {
    display: block;
    min-height: 100vh;   /* 确保活动面板足够高，footer 会被推到页面底部 */
}

/* 面板头部 */
.doc-panel-header {
    padding: 32px 40px;
    background: linear-gradient(135deg, #f0f9eb 0%, #ffffff 100%);
    border-bottom: 1px solid #ebeef5;
}

.doc-panel-header h2 {
    font-size: 28px;
    color: #0067ED;
    margin-bottom: 8px;
}

.doc-panel-header p {
    font-size: 14px;
    color: #606266;
    line-height: 1.8;
}

/* 内容区块 */
.doc-block {
    padding: 32px 40px;
    border-bottom: 1px solid #f0f2f5;
}

.doc-block:last-child {
    border-bottom: none;
}

.doc-block-title {
    font-size: 20px;
    font-weight: bold;
    color: #303133;
    margin-bottom: 20px;
    padding-left: 12px;
    border-left: 4px solid #0067ED;
    line-height: 1.2;
}

/* 平台简介 */
.doc-intro-text {
    font-size: 15px;
    color: #606266;
    line-height: 2;
}

/* 功能卡片 */
.doc-features {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
}

.doc-feature-card {
    padding: 20px;
    background: #f9fbfc;
    border-radius: 6px;
    border: 1px solid #ebeef5;
    transition: all 0.2s;
}

.doc-feature-card:hover {
    border-color: #0067ED;
    box-shadow: 0 4px 12px rgba(0, 103, 237,0.1);
}

.doc-feature-card .feature-icon {
    width: 40px;
    height: 40px;
    border-radius: 8px;
    background: linear-gradient(135deg, #0067ED 0%, #3d8bff 100%);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    margin-bottom: 12px;
}

.doc-feature-card .feature-name {
    font-size: 16px;
    font-weight: bold;
    color: #303133;
    margin-bottom: 6px;
}

.doc-feature-card .feature-desc {
    font-size: 13px;
    color: #909399;
    line-height: 1.6;
}

/* 使用步骤 */
.doc-steps {
    counter-reset: step;
}

.doc-step {
    display: flex;
    gap: 20px;
    margin-bottom: 24px;
    position: relative;
}

.doc-step:last-child {
    margin-bottom: 0;
}

.doc-step-num {
    width: 36px;
    height: 36px;
    flex-shrink: 0;
    border-radius: 50%;
    background: linear-gradient(135deg, #0067ED 0%, #3d8bff 100%);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
    font-weight: bold;
    counter-increment: step;
}

.doc-step-num::before {
    content: counter(step);
}

.doc-step-body {
    flex: 1;
    padding-top: 4px;
}

.doc-step-title {
    font-size: 16px;
    font-weight: bold;
    color: #303133;
    margin-bottom: 6px;
}

.doc-step-desc {
    font-size: 14px;
    color: #606266;
    line-height: 1.8;
}

.doc-step-desc .doc-tag {
    display: inline-block;
    padding: 2px 8px;
    background: #f0f9eb;
    color: #0067ED;
    border-radius: 4px;
    font-size: 12px;
    margin: 0 2px;
}

/* 常见问题 */
.doc-faq-item {
    border: 1px solid #ebeef5;
    border-radius: 6px;
    margin-bottom: 12px;
    overflow: hidden;
}

.doc-faq-item:last-child {
    margin-bottom: 0;
}

.doc-faq-q {
    padding: 16px 20px;
    font-size: 15px;
    font-weight: bold;
    color: #303133;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: space-between;
    background: #fafafa;
    transition: background 0.2s;
}

.doc-faq-q:hover {
    background: #f0f9eb;
}

.doc-faq-q .faq-icon {
    color: #0067ED;
    font-size: 18px;
    transition: transform 0.2s;
}

.doc-faq-item.open .faq-icon {
    transform: rotate(45deg);
}

.doc-faq-a {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease;
}

.doc-faq-item.open .doc-faq-a {
    max-height: 200px;
}

.doc-faq-a-inner {
    padding: 16px 20px;
    font-size: 14px;
    color: #606266;
    line-height: 1.8;
    border-top: 1px solid #ebeef5;
}

/* 参数信息表 */
.doc-param-table {
    width: 100%;
    border-collapse: collapse;
}

.doc-param-table th {
    background: #f0f9eb;
    color: #0067ED;
    font-size: 14px;
    padding: 12px 16px;
    text-align: left;
    border: 1px solid #e0e0e0;
}

.doc-param-table td {
    padding: 12px 16px;
    font-size: 14px;
    color: #606266;
    border: 1px solid #ebeef5;
}

.doc-param-table td:first-child {
    width: 30%;
    color: #303133;
    font-weight: bold;
    background: #fafafa;
}

/* ===== 响应式 ===== */
@media screen and (max-width: 1260px) {
    /* 移除 .doc-banner h1 样式 */
}

@media screen and (max-width: 992px) {
    .doc-wrapper {
        flex-direction: column;
    }

    .doc-sidebar {
        width: 100%;
        position: static;
    }

    .doc-nav {
        display: flex;
        overflow-x: auto;
        padding: 0;
    }

    .doc-nav li {
        padding: 14px 20px;
        white-space: nowrap;
        border-left: none;
        border-bottom: 3px solid transparent;
    }

    .doc-nav li.active {
        border-left: none;
        border-bottom-color: #0067ED;
    }

    .doc-features {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media screen and (max-width: 768px) {
    /* a-banner 响应式样式，参照 about.html */
    .a-banner {
        height: 350px;
        background: url(../images/mobile/m_about.jpg) no-repeat center center;
        background-size: cover;
    }

    .banner-box {
        width: 100%;
    }

    .about-text {
        width: 50%;
    }

    .about-text h1 {
        font-size: 24px;
        color: #303133;
    }

    .about-text span {
        font-size: 16px;
        display: none;
    }

    .about_psd {
        display: none;
    }

    .doc-section {
        padding: 24px 0 40px;
    }

    .doc-panel-header,
    .doc-block {
        padding: 20px;
    }

    .doc-panel-header h2 {
        font-size: 22px;
    }

    .doc-block-title {
        font-size: 17px;
    }

    .doc-features {
        grid-template-columns: 1fr;
    }

    .doc-step {
        gap: 12px;
    }

    .doc-step-num {
        width: 28px;
        height: 28px;
        font-size: 13px;
    }
}
