/* 全局样式重置 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    line-height: 1.6;
    color: #333;
    background-color: #f5f5f5;
}

/* 容器布局 */
.container {
    max-width: 800px;
    margin: 0 auto;
    padding: 20px;
    background-color: #fff;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

/* 头部样式 */
header {
    text-align: center;
    padding: 40px 0;
    border-bottom: 1px solid #eee;
    margin-bottom: 40px;
}

.website-name {
    font-size: 3rem;
    font-weight: 700;
    color: #2c3e50;
    margin-bottom: 10px;
    letter-spacing: 2px;
}

/* 主要内容区域 */
main {
    flex: 1;
    text-align: center;
}

.introduction {
    margin-bottom: 40px;
    padding: 30px;
    background-color: #fafafa;
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    border-left: 4px solid #3498db;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.introduction:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.12);
}

.introduction h2 {
    font-size: 1.8rem;
    color: #2c3e50;
    margin-bottom: 20px;
    font-weight: 600;
}

.introduction p {
    font-size: 1.1rem;
    color: #555;
    line-height: 1.8;
    max-width: 600px;
    margin: 0 auto;
    text-align: left;
}

/* 瀑布流图片画廊 */
/* 设置图片最大宽度，用于动态计算列数 */
:root {
    --gallery-item-max-width: 200px;
    --gallery-gap: 20px;
}

.gallery-container {
    /* 使用CSS Grid实现基于容器宽度的动态列数 */
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(min(var(--gallery-item-max-width), 100%), 1fr));
    grid-gap: var(--gallery-gap);
    margin-top: 30px;
    max-width: 100%;
    justify-items: center;
}

.gallery-item {
    width: 100%;
    overflow: hidden;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    display: flex;
    flex-direction: column;
    background-color: #fff;
}

.gallery-item:hover {
    transform: translateY(-4px);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.15);
}

.gallery-item img {
    width: 100%;
    height: auto;
    display: block;
    transition: transform 0.3s ease;
    object-fit: cover;
}

.gallery-item:hover img {
    transform: scale(1.05);
}

/* 页脚样式 */
footer {
    margin-top: auto;
    padding: 20px 0;
    border-top: 1px solid #eee;
    text-align: center;
    color: #999;
    font-size: 0.9rem;
}

.icp-info p {
    margin: 0;
}

/* 响应式设计 */
@media (max-width: 768px) {
    .container {
        padding: 15px;
    }
    
    .website-name {
        font-size: 2.5rem;
    }
    
    .introduction h2 {
        font-size: 1.5rem;
    }
    
    .introduction p {
        font-size: 1rem;
    }
}

@media (max-width: 480px) {
    .website-name {
        font-size: 2rem;
    }
    
    header {
        padding: 30px 0;
        margin-bottom: 30px;
    }
}