
/*  全局样式  */
html, body {
    margin: 0;
    padding: 0;
    font-family: 'Roboto', sans-serif;
    color: #ffffff;
    background-color: #0d1b2a; /* 深蓝色背景 */
    overflow-x: hidden; /* 防止水平滚动条 */
    scroll-behavior: smooth; /* 平滑滚动 */
}

body {
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

/*  字体  */
@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@400;700&family=Roboto:wght@400;700&display=swap');

h1, h2, h3, h4, h5, h6 {
    font-family: 'Poppins', sans-serif;
    font-weight: 700;
    margin-top: 1.5em;
    margin-bottom: 0.5em;
    line-height: 1.2;
    color: #ffc857; /* 金色标题 */
}

p {
    font-family: 'Roboto', sans-serif;
    font-size: 1rem;
    line-height: 1.7;
    margin-bottom: 1em;
    color: #f0f0f0; /* 浅灰色正文 */
}

a {
    color: #5bc0de; /* 链接颜色 */
    text-decoration: none;
    transition: color 0.3s ease;
}

a:hover {
    color: #ffffff; /* 链接hover颜色 */
}

/*  通用容器样式  */
.container {
    width: 90%;
    max-width: 1200px;
    margin-left: auto;
    margin-right: auto;
    padding: 20px;
}

.section {
    padding: 80px 0;
    background-repeat: no-repeat;
    background-size: cover;
    background-position: center;
    position: relative;
    overflow: hidden; /* 确保背景渐变不溢出 */
}

.section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5); /* 叠加半透明黑色背景，增强文字可读性 */
    z-index: 0; /* 确保在内容下方 */
}

.section-content {
    position: relative;
    z-index: 1; /* 确保内容在叠加层之上 */
}

/*  首页头部样式  */
.header {
    background: linear-gradient(to bottom, #0d1b2a, #1e293b); /* 头部渐变背景 */
    padding: 100px 0;
    text-align: center;
}

.header h1 {
    font-size: 3.5rem;
    margin-bottom: 20px;
    text-shadow: 2px 2px 3px rgba(0, 0, 0, 0.3); /* 标题阴影 */
}

.header p {
    font-size: 1.2rem;
    color: #d0d0d0;
    max-width: 700px;
    margin: 0 auto;
}

/*  导航栏样式  */
.navigation {
    background-color: rgba(255, 255, 255, 0.05); /* 半透明导航栏背景 */
    padding: 20px 0;
    position: sticky;
    top: 0;
    z-index: 100; /* 确保导航栏在最上层 */
}

.navigation ul {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    justify-content: center;
    align-items: center;
}

.navigation li {
    margin: 0 20px;
}

.navigation a {
    display: block;
    padding: 10px 15px;
    border-radius: 5px;
    transition: background-color 0.3s ease, color 0.3s ease;
}

.navigation a:hover {
    background-color: #ffc857; /* 导航链接hover背景 */
    color: #0d1b2a; /* 导航链接hover文字颜色 */
}

/*  功能模块样式  */
.feature-section {
    background: linear-gradient(to right, #1e293b, #0d1b2a); /* 功能模块渐变背景 */
}

.feature-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
    margin-top: 40px;
}

.feature-item {
    background-color: rgba(255, 255, 255, 0.08); /* 功能项背景 */
    padding: 30px;
    border-radius: 10px;
    text-align: center;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.feature-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.2); /* hover阴影 */
}

.feature-item img {
    width: 80px;
    height: 80px;
    margin-bottom: 20px;
    border-radius: 50%;
    object-fit: cover;
}

.feature-item h3 {
    font-size: 1.8rem;
    margin-bottom: 15px;
}

.feature-item p {
    font-size: 1rem;
    color: #d0d0d0;
}

/*  案例展示模块样式  */
.case-section {
    background: linear-gradient(to bottom, #243b55, #14284a); /* 案例模块渐变背景 */
}

.case-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
    gap: 30px;
    margin-top: 40px;
}

.case-item {
    background-color: rgba(255, 255, 255, 0.08); /* 案例项背景 */
    border-radius: 10px;
    overflow: hidden;
    transition: box-shadow 0.3s ease;
}

.case-item:hover {
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.2); /* hover阴影 */
}

.case-item img {
    width: 100%;
    height: 250px;
    object-fit: cover;
    display: block;
}

.case-item-content {
    padding: 25px;
}

.case-item h4 {
    font-size: 1.5rem;
    margin-bottom: 10px;
}

.case-item p {
    font-size: 1rem;
    color: #d0d0d0;
}

/*  代码示例样式  */
pre {
    background-color: #282c34; /* 代码块背景色 */
    color: #abb2bf; /* 代码颜色 */
    padding: 15px;
    border-radius: 8px;
    overflow-x: auto; /* 水平滚动条，在小屏幕下显示 */
    tab-size: 4; /* Tab 尺寸 */
    font-family: 'Courier New', monospace; /* 等宽字体 */
    line-height: 1.5;
    margin-bottom: 1em;
}

code {
    font-family: 'Courier New', monospace;
    font-size: 0.9rem;
}

/*  示例文章展示样式  */
.article-section {
    background: linear-gradient(to bottom, #14284a, #0d1b2a); /* 文章模块渐变背景 */
    padding: 60px 0;
}

.article-section h2 {
    font-size: 2.5rem;
    margin-bottom: 20px;
    text-align: center;
}

.article-section h3 {
    font-size: 2rem;
    margin-top: 2em;
    margin-bottom: 1em;
}

.article-section h4 {
    font-size: 1.8rem;
    margin-top: 1.5em;
    margin-bottom: 0.8em;
}

.article-section p {
    font-size: 1.1rem;
    line-height: 1.8;
    margin-bottom: 1.2em;
}

.article-section ul {
    list-style-type: square;
    padding-left: 25px;
    margin-bottom: 1.2em;
}

.article-section li {
    font-size: 1.1rem;
    line-height: 1.8;
    color: #d0d0d0;
}

.article-section blockquote {
    border-left: 5px solid #ffc857; /* 引用块左边线 */
    padding-left: 15px;
    margin: 1.5em 0;
    font-style: italic;
    color: #d0d0d0;
}

/*  页脚样式  */
.footer {
    background-color: #1e293b; /* 页脚背景色 */
    padding: 30px 0;
    text-align: center;
    font-size: 0.9rem;
    color: #a0a0a0;
    margin-top: auto; /* 页脚推到底部 */
}

/*  响应式设计  */
@media (max-width: 1024px) {
    .header h1 {
        font-size: 3rem;
    }

    .header p {
        font-size: 1.1rem;
    }

    .navigation li {
        margin: 0 15px;
    }

    .navigation a {
        padding: 8px 12px;
    }

    .feature-grid {
        grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    }

    .case-grid {
        grid-template-columns: 1fr; /* 平板及以下设备案例项单列显示 */
    }
}

@media (max-width: 768px) {
    .header {
        padding: 80px 0;
    }

    .header h1 {
        font-size: 2.5rem;
    }

    .header p {
        font-size: 1rem;
    }

    .navigation ul {
        flex-direction: column;
    }

    .navigation li {
        margin: 10px 0;
    }

    .feature-item {
        padding: 20px;
    }

    .feature-item h3 {
        font-size: 1.6rem;
    }

    .case-item-content {
        padding: 20px;
    }

    .case-item h4 {
        font-size: 1.3rem;
    }

    .article-section h2 {
        font-size: 2rem;
    }

    .article-section h3 {
        font-size: 1.7rem;
    }

    .article-section p, .article-section li {
        font-size: 1rem;
    }
}

@media (max-width: 480px) {
    .header {
        padding: 60px 0;
    }

    .header h1 {
        font-size: 2rem;
    }

    .container {
        padding: 15px;
    }

    .feature-item {
        padding: 15px;
    }

    .feature-item h3 {
        font-size: 1.4rem;
    }

    .case-item-content {
        padding: 15px;
    }

    .case-item h4 {
        font-size: 1.2rem;
    }

    .article-section h2 {
        font-size: 1.8rem;
    }

    .article-section h3 {
        font-size: 1.5rem;
    }
}

/*  额外的视觉修饰  */
.highlight {
    color: #ffc857; /* 高亮文本颜色 */
    font-weight: bold;
}

.decorative-line {
    height: 2px;
    background: linear-gradient(to right, rgba(255,200,87,0.1), #ffc857, rgba(255,200,87,0.1)); /* 装饰线条渐变 */
    margin: 40px 0;
    width: 80%;
    margin-left: auto;
    margin-right: auto;
}

.blockchain-node {
    background: linear-gradient(135deg, #1E293B, #475569); /* 区块链节点渐变背景 */
    padding: 15px;
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 80px;
    height: 80px;
    color: #ffffff;
    font-weight: bold;
}

.button {
    display: inline-block;
    padding: 12px 30px;
    background-color: #ffc857;
    color: #0d1b2a;
    border-radius: 5px;
    font-weight: bold;
    text-decoration: none;
    transition: background-color 0.3s ease, color 0.3s ease;
}

.button:hover {
    background-color: #0d1b2a;
    color: #ffc857;
    border: 1px solid #ffc857;
}

.code-block-caption {
    font-size: 0.9rem;
    color: #999;
    margin-top: -0.8em;
    margin-bottom: 0.5em;
    text-align: left;
}

/*  辅助类，用于更灵活的布局控制  */
.text-center {
    text-align: center;
}

.mt-4 {
    margin-top: 2rem;
}

.mb-4 {
    margin-bottom: 2rem;
}

.pt-4 {
    padding-top: 2rem;
}

.pb-4 {
    padding-bottom: 2rem;
}

.section-title {
    text-align: center;
    margin-bottom: 60px;
}

.section-title h2 {
    font-size: 2.8rem;
    position: relative;
    padding-bottom: 20px;
    display: inline-block;
}

.section-title h2::after {
    content: '';
    position: absolute;
    left: 50%;
    bottom: 0;
    transform: translateX(-50%);
    width: 60px;
    height: 3px;
    background-color: #ffc857; /* 标题下划线 */
}

.overlay-text {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-size: 2rem;
    color: rgba(255, 255, 255, 0.2); /* 半透明叠加文字 */
    pointer-events: none; /* 穿透点击事件 */
    z-index: 0;
    white-space: nowrap;
    opacity: 0.8;
    font-weight: bold;
    letter-spacing: 0.3em;
    text-shadow: 3px 3px 5px rgba(0, 0, 0, 0.5);
}

