/* 全局样式重置 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* 定义全局变量 */
:root {
    --primary-color: #4a90e2;
    --hover-color: #357abd;
    --text-color: #2c3e50;
    --light-gray: #f5f6fa;
    --border-color: #dcdde1;
    --shadow-color: rgba(0, 0, 0, 0.1);
    --transition: all 0.3s ease;
}

/* 页面基本样式 */
body {
    /* 设置字体族，优先使用系统默认字体 */
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, 'Open Sans', 'Helvetica Neue', sans-serif;
    min-height: 100vh;
    /* 使用弹性布局，使页脚始终在底部 */
    display: flex;
    flex-direction: column;
    background: linear-gradient(135deg, var(--light-gray) 0%, #ffffff 100%);
    color: var(--text-color);
}

/* 主容器样式 */
.container {
    max-width: 1000px;
    margin: 0 auto;
    padding: 30px;
    flex: 1;
}

/* 顶部文字按钮区域样式 */
.text-buttons {
    /* 垂直排列文字按钮 */
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 25px;
    margin-bottom: 40px;
    padding: 20px;
    background: rgba(255, 255, 255, 0.9);
    border-radius: 15px;
    box-shadow: 0 10px 20px var(--shadow-color);
}

/* 文字按钮链接样式 */
.text-btn {
    color: var(--text-color);
    text-decoration: none;
    font-size: 18px;
    font-weight: 500;
    cursor: pointer;
    transition: var(--transition);
    padding: 12px 25px;
    position: relative;
    border-radius: 8px;
    background: white;
    box-shadow: 0 2px 5px var(--shadow-color);
    width: 80%;
    text-align: center;
    border: none;
    outline: none;
}

/* 文字按钮悬停效果 */
.text-btn:hover {
    color: var(--primary-color);
    transform: translateY(-2px);
    box-shadow: 0 5px 15px var(--shadow-color);
}

/* 文字按钮悬停效果的下划线 */
.text-btn::after {
    content: '';
    position: absolute;
    width: 0;
    height: 2px;
    bottom: 0;
    left: 50%;
    background-color: #ff6b6b;
    transition: all 0.3s ease;
    transform: translateX(-50%);
}

/* 文字按钮悬停时的颜色变化 */
.text-btn:hover {
    color: #ff6b6b;
}

/* 文字按钮悬停时下划线展开 */
.text-btn:hover::after {
    width: 100%;
}

/* 当前激活的文字按钮样式 */
.text-btn.active {
    color: #ff6b6b;
}

.text-btn.active::after {
    width: 100%;
}

/* 图片容器样式 */
.image-container {
    padding: 30px;
    text-align: center;
    background: white;
    border-radius: 20px;
    box-shadow: 0 15px 30px var(--shadow-color);
    margin: 20px 0;
}

/* 图片框架样式 */
.image-frame {
    border-radius: 12px;
    overflow: hidden;
    margin-bottom: 0;
    position: relative;
    transition: var(--transition);
}

/* 图片样式 */
#displayImage {
    width: 100%;
    height: auto;
    display: block;
    transition: var(--transition);
}

/* 图片悬停效果 */
.image-frame:hover #displayImage {
    transform: scale(1.02);
}

/* 页脚样式 */
.footer {
    text-align: center;
    padding: 25px;
    background: white;
    box-shadow: 0 -5px 15px var(--shadow-color);
}

/* ICP备案信息样式 */
.icp {
    font-size: 14px;
    color: #666;
}

/* ICP备案链接样式 */
.icp a {
    color: var(--text-color);
    text-decoration: none;
    transition: var(--transition);
}

/* ICP备案链接悬停效果 */
.icp a:hover {
    color: var(--primary-color);
}

/* 添加页面加载动画 */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

.container > * {
    animation: fadeIn 0.8s ease-out forwards;
}

/* 移动端响应式设计 */
@media (max-width: 767px) {
    /* 移动端容器内边距调整 */
    .container {
        padding: 15px;
    }
    
    /* 移动端文字按钮字体大小调整 */
    .text-btn {
        font-size: 16px;
        width: 90%;
        padding: 10px 20px;
    }
    
    /* 移动端页脚内边距调整 */
    .footer {
        padding: 20px;
    }
}

/* 预览区域样式 */
.preview-section {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    display: none;
    justify-content: center;
    align-items: center;
    z-index: 1000;
}

.preview-section.active {
    display: flex;
}

.preview-container {
    background: white;
    padding: 20px;
    border-radius: 10px;
    max-width: 90vw;
    max-height: 90vh;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    gap: 20px;
}

#previewImage {
    max-width: 100%;
    height: auto;
    border-radius: 8px;
}

.preview-text {
    background: var(--light-gray);
    padding: 20px;
    border-radius: 8px;
    margin-top: 10px;
}

#previewDescription {
    color: var(--text-color);
    font-size: 16px;
    line-height: 1.6;
    white-space: pre-line;
    text-align: left;
}

/* 移动端响应式设计 */
@media (max-width: 767px) {
    .preview-container {
        padding: 15px;
    }

    .preview-text {
        padding: 15px;
    }

    #previewDescription {
        font-size: 14px;
    }
} 