/* style.css */

/* 基础重置与全局字体 */
* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-padding-top: 80px;
}

body {
    font-family: 'Helvetica Neue', Arial, sans-serif;
    color: #333;
    background-color: #fff;
    line-height: 1.6;
}

/* 页眉样式 */
.header {
    position: fixed;
    top: 0;
    width: 100%;
    background-color: #fff;
    padding: 1rem 2rem;
    z-index: 1000;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

/* Logo区域样式 */
.logo-area {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
}

.header .logo {
    font-size: 1.8rem;
    font-weight: bold;
    color: #2c3e50;
    line-height: 1.2;
}

.header .subtitle {
    font-size: 0.9rem;
    color: #666;
    margin-top: 0.2rem;
    font-weight: 500;
}

/* 语言切换器样式 */
.lang-switcher {
    border: 1px solid #ddd;
    padding: 0.5rem 1rem;
    border-radius: 4px;
    font-size: 0.9rem;
    color: #555;
    cursor: pointer;
    transition: all 0.3s ease;
}

.lang-switcher:hover {
    border-color: #3498db;
    color: #3498db;
}

/* 导航菜单样式 */
.header nav ul {
    list-style: none;
    display: flex;
    gap: 2rem;
}

.header nav ul li a {
    color: #555;
    text-decoration: none;
    padding: 0.5rem 1rem;
    transition: color 0.3s ease;
    font-weight: 500;
}

.header nav ul li a:hover {
    color: #3498db;
}

.header nav ul li a.active {
    color: #3498db; /* 使用与hover状态相同的颜色以保持一致性 */
    font-weight: 700; /* 加粗字体以示突出 */
}

/* 页脚样式 */
.footer {
    position: fixed;
    bottom: 0;
    width: 100%;
    background-color: #2c3e50;
    padding: 1rem 2rem;
    font-size: 0.9rem;
    text-align: center;
    color: #ecf0f1;
}

/* 主体内容样式 */
main {
    padding-top: 80px;
    padding-bottom: 80px;
}



/* 主页介绍区域样式 */
#intro-section {
    display: grid;
    grid-template-columns: 1fr 1fr; /* 等宽两列 */
    gap: 3rem; /* 列间距 */
    padding: 4rem 2rem; /* 内边距 */
    max-width: 1200px;
    margin: 0 auto;
    align-items: center; /* 垂直居中对齐 */
}

.intro-left h2 {
    font-size: 2.2rem;
    color: #2c3e50;
    margin-bottom: 2rem;
    font-weight: 400;
}

.intro-left ul {
    list-style: none;
    margin-bottom: 2.5rem;
}

.intro-left li {
    padding: 0.8rem 0;
    border-bottom: 1px solid #eee;
    color: #666;
    line-height: 1.6;
    position: relative;
    padding-left: 1.5rem;
}

.intro-left li:before {
    content: "▸";
    position: absolute;
    left: 0;
    color: #3498db;
    font-weight: bold;
}

.intro-left li:last-child {
    border-bottom: none;
}

.cta-button {
    display: inline-block;
    background-color: #3498db;
    color: white;
    padding: 1rem 2rem;
    text-decoration: none;
    border-radius: 6px;
    font-weight: 600;
    transition: all 0.3s ease;
    box-shadow: 0 4px 6px rgba(52, 152, 219, 0.2);
}

.cta-button:hover {
    background-color: #2980b9;
    transform: translateY(-2px);
    box-shadow: 0 6px 12px rgba(52, 152, 219, 0.3);
}

.intro-right video {
    width: 100%;
    border-radius: 8px;
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.15);
}

/* 动态区域样式 */
#news {
    padding: 4rem 2rem;
    max-width: 1200px;
    margin: 0 auto;
}

#news h2 {
    text-align: center;
    font-size: 2.5rem;
    margin-bottom: 3rem;
    color: #2c3e50;
    font-weight: 300;
}

/* 新闻网格 */
.news-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
}

/* 新闻卡片 */
.news-card {
    background: #fff;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    padding: 1.5rem;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.news-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 15px rgba(0, 0, 0, 0.15);
}

.news-card h3 {
    font-size: 1.4rem;
    margin-bottom: 1rem;
    color: #2c3e50;
}

.news-card p {
    color: #666;
    line-height: 1.6;
}

.news-card .date {
    font-size: 0.9rem;
    color: #999;
    margin-top: 1rem;
}

/* 项目页样式 */
.project-gallery {
    padding: 2rem;
    max-width: 1200px;
    margin: 0 auto;
    column-count: 2;
    column-gap: 30px;
}

.project-item {
    display: inline-block;
    width: 100%;
    margin-bottom: 30px;
    break-inside: avoid;
    background: #fff;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.project-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 15px rgba(0, 0, 0, 0.15);
}

.project-item img {
    width: 100%;
    height: auto;
    display: block;
}

.project-item .content {
    padding: 1.5rem;
}

.project-item h3 {
    font-size: 1.3rem;
    margin-bottom: 0.5rem;
    color: #2c3e50;
}

.project-item p {
    color: #666;
    line-height: 1.5;
    font-size: 0.95rem;
}

.project-item .tech-tags {
    margin-top: 1rem;
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.project-item .tech-tag {
    background: #3498db;
    color: white;
    padding: 0.2rem 0.5rem;
    border-radius: 4px;
    font-size: 0.8rem;
}

/* 占位页面样式 */
.placeholder-content {
    padding: 4rem 2rem;
    max-width: 800px;
    margin: 0 auto;
    text-align: center;
}

.placeholder-content h1 {
    font-size: 2.5rem;
    margin-bottom: 2rem;
    color: #2c3e50;
    font-weight: 300;
}

.placeholder-content p {
    font-size: 1.2rem;
    color: #666;
    line-height: 1.6;
}

/* 响应式设计 */
@media (max-width: 768px) {
    .header {
        padding: 1rem;
        flex-direction: column;
        gap: 1rem;
    }
    
    .header nav ul {
        gap: 1rem;
        flex-wrap: wrap;
        justify-content: center;
    }
    
    .lang-switcher {
        margin-top: 0.5rem;
    }
    
    #intro-section {
        grid-template-columns: 1fr;
        gap: 2rem;
        padding: 2rem 1rem;
    }
    
    .intro-left h2 {
        font-size: 1.8rem;
    }
    
    .intro-left li {
        padding: 0.6rem 0;
        font-size: 0.95rem;
    }
    
    .project-gallery {
        column-count: 1;
        padding: 1rem;
    }
    
    #news {
        padding: 2rem 1rem;
    }
    
    .news-grid {
        grid-template-columns: 1fr;
    }
} 