
/* 
整体页面的样式设计
采用现代Web技术，包括Flexbox和Grid布局，实现响应式设计
色彩搭配遵循黄金比例，主色70%，辅色25%，点缀色5%
页面背景使用科技感强的深色调，搭配亮色装饰元素
*/

/* 全局样式 */
body {
    margin: 0;
    font-family: 'Roboto', sans-serif;
    background: linear-gradient(135deg, #1e3c72, #2a5298);
    color: #ffffff;
    line-height: 1.6;
    scroll-behavior: smooth;
}

/* 导航栏样式 */
nav {
    position: fixed;
    top: 0;
    width: 100%;
    background: rgba(30, 60, 114, 0.9);
    padding: 20px 0;
    z-index: 1000;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

nav .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    max-width: 1200px;
    margin: auto;
    padding: 0 20px;
}

nav a {
    color: #ffffff;
    text-decoration: none;
    margin: 0 15px;
    font-weight: bold;
    transition: color 0.3s ease;
}

nav a:hover {
    color: #feb47b;
}

/* 主页引导区 */
.hero {
    position: relative;
    width: 100%;
    height: 100vh;
    background: linear-gradient(135deg, #1e3c72, #2a5298);
    display: flex;
    justify-content: center;
    align-items: center;
    text-align: center;
    color: #ffffff;
    overflow: hidden;
}

.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 200%;
    height: 200%;
    background: url('https://images.gptkong.com/demo/sample1.png') repeat;
    animation: moveBackground 20s linear infinite;
    opacity: 0.2;
}

@keyframes moveBackground {
    from { transform: translate(0, 0); }
    to { transform: translate(-50%, -50%); }
}

.hero-content {
    position: relative;
    z-index: 1;
}

.hero h1 {
    font-size: 3em;
    margin-bottom: 20px;
    animation: fadeInDown 2s ease forwards;
}

.hero p {
    font-size: 1.2em;
    margin-bottom: 30px;
    animation: fadeInUp 2s ease forwards;
}

@keyframes fadeInDown {
    from { opacity: 0; transform: translateY(-50px); }
    to { opacity: 1; transform: translateY(0); }
}

@keyframes fadeInUp {
    from { opacity: 0; transform: translateY(50px); }
    to { opacity: 1; transform: translateY(0); }
}

.cta-button {
    background: linear-gradient(45deg, #ff7e5f, #feb47b);
    border: none;
    border-radius: 50px;
    color: #fff;
    padding: 15px 30px;
    font-size: 1.2em;
    cursor: pointer;
    transition: transform 0.3s ease, background 0.3s ease;
}

.cta-button:hover {
    transform: scale(1.05);
    background: linear-gradient(45deg, #ff6a00, #ee0979);
}

/* 内容模块 */
.section {
    padding: 80px 20px;
    background: #ffffff;
    color: #333333;
}

.section:nth-child(even) {
    background: #f5f5f5;
}

.container {
    max-width: 1200px;
    margin: auto;
    display: flex;
    flex-wrap: wrap;
    gap: 40px;
}

.section h2 {
    text-align: center;
    margin-bottom: 40px;
    color: #1e3c72;
}

.card-container {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
    justify-content: center;
}

.card {
    background: #ffffff;
    border-radius: 10px;
    box-shadow: 0 4px 6px rgba(0,0,0,0.1);
    padding: 20px;
    flex: 1 1 calc(33.333% - 40px);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    position: relative;
}

.card img {
    width: 100%;
    border-radius: 10px;
    box-shadow: 0 4px 6px rgba(0,0,0,0.1);
    transition: transform 0.3s ease;
}

.card img:hover {
    transform: scale(1.05);
}

.card h3 {
    margin-top: 15px;
    color: #2a5298;
}

.card p {
    font-size: 1em;
    margin-top: 10px;
}

.card:hover {
    transform: translateY(-10px);
    box-shadow: 0 10px 15px rgba(0,0,0,0.2);
}

@media (max-width: 768px) {
    .card {
        flex: 1 1 calc(50% - 40px);
    }
}

@media (max-width: 480px) {
    .card {
        flex: 1 1 100%;
    }
}

/* 数据可视化区域 */
.chart {
    position: relative;
    width: 100%;
    height: 400px;
    background: #f5f5f5;
    border-radius: 10px;
    overflow: hidden;
}

.bar {
    position: absolute;
    bottom: 0;
    width: 30px;
    background: #2a5298;
    animation: grow 1s ease forwards;
}

@keyframes grow {
    from { height: 0; }
    to { height: var(--bar-height); }
}

/* 代码块样式 */
code, pre {
    background: #2a5298;
    color: #ffffff;
    padding: 10px;
    border-radius: 5px;
    overflow-x: auto;
    font-family: 'Courier New', Courier, monospace;
}

/* 用户评价轮播 */
.carousel {
    position: relative;
    overflow: hidden;
    width: 100%;
    height: 300px;
    border-radius: 10px;
}

.carousel-track {
    display: flex;
    transition: transform 0.5s ease-in-out;
}

.carousel-item {
    min-width: 100%;
    box-sizing: border-box;
    padding: 20px;
    background: #ffffff;
    color: #333333;
}

@keyframes slide {
    0% { transform: translateX(0); }
    20% { transform: translateX(0); }
    25% { transform: translateX(-100%); }
    45% { transform: translateX(-100%); }
    50% { transform: translateX(-200%); }
    70% { transform: translateX(-200%); }
    75% { transform: translateX(-300%); }
    95% { transform: translateX(-300%); }
    100% { transform: translateX(0); }
}

.carousel-track {
    animation: slide 20s infinite;
}

/* 投资收益计算器 */
.calculator {
    background: #f9f9f9;
    padding: 30px;
    border-radius: 10px;
    box-shadow: 0 4px 6px rgba(0,0,0,0.1);
}

.calculator input {
    width: 100%;
    padding: 10px;
    margin-bottom: 15px;
    border: 2px solid #ccc;
    border-radius: 5px;
    transition: border-color 0.3s ease;
}

.calculator input:focus {
    border-color: #2a5298;
    outline: none;
}

.calculator button {
    width: 100%;
    padding: 12px;
    background: #2a5298;
    color: #fff;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    transition: background 0.3s ease;
}

.calculator button:hover {
    background: #1e3c72;
}

.result {
    margin-top: 20px;
    font-size: 1.2em;
    color: #2a5298;
}

/* 回顶部按钮 */
.back-to-top {
    position: fixed;
    bottom: 40px;
    right: 40px;
    background: #2a5298;
    color: #ffffff;
    padding: 10px 15px;
    border-radius: 50px;
    cursor: pointer;
    display: none;
    transition: background 0.3s ease;
}

.back-to-top:hover {
    background: #1e3c72;
}

/* 加载动画 */
.loader {
    border: 8px solid #f3f3f3;
    border-top: 8px solid #2a5298;
    border-radius: 50%;
    width: 60px;
    height: 60px;
    animation: spin 1s linear infinite;
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
}

@keyframes spin {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

/* 折叠内容 */
.collapsible {
    background-color: #2a5298;
    color: white;
    cursor: pointer;
    padding: 18px;
    width: 100%;
    border: none;
    text-align: left;
    outline: none;
    font-size: 1.2em;
    transition: background-color 0.3s ease;
}

.active, .collapsible:hover {
    background-color: #1e3c72;
}

.content {
    padding: 0 18px;
    display: none;
    background-color: #f1f1f1;
    color: #333333;
    overflow: hidden;
}

