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

body {
    font-family: Arial, sans-serif;
    background-color: #f5f7fa;
    color: #333;
}

/* 头部样式 */
.header {
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 100%;
    margin-bottom: 10px;
    background-image: url(/images/header-bg.png);
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    padding: 20px 0;
    position: relative;
}

.header::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(255, 255, 255, 0.5);
    z-index: 1;
}

.header h1 {
    width: 100%;
    text-align: center;
    font-size: 2.2rem;
    color: #ffffff;
    position: relative;
    z-index: 2;
    margin-top: auto;
    margin-bottom: auto;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 15px;
}

.header h1 span {
    text-shadow: 0 2px 4px rgba(0,0,0,0.3);
}

.site-logo {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    object-fit: cover;
    border: 3px solid rgba(255,255,255,0.8);
    box-shadow: 0 2px 8px rgba(0,0,0,0.2);
}

/* 搜索框样式 */
.search-container {
    max-width: 1050px;
    margin: 40px auto;
    text-align: center;
}

.search-box {
    display: inline-block;
    position: relative;
}

.search-box form {
    display: flex;
}

.search-box input {
    width: 500px;
    height: 40px;
    padding: 0 15px;
    font-size: 16px;
    border: 2px solid #1E90FF;
    border-radius: 20px 0 0 20px;
    outline: none;
}

.search-box button {
    height: 40px;
    padding: 0 20px;
    font-size: 16px;
    background-color: #1E90FF;
    color: white;
    border: none;
    border-radius: 0 20px 20px 0;
    cursor: pointer;
    transition: background-color 0.3s;
}

.search-box button:hover {
    background-color: #187bcd;
}

/* 快捷链接样式 */
.quick-links {
    max-width: 1050px;
    margin: 30px auto;
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 15px;
    justify-content: center;
}

.quick-link {
    background-color: white;
    padding: 25px 30px;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    text-decoration: none;
    color: #333;
    font-size: 18px;
    font-weight: 500;
    transition: transform 0.3s, box-shadow 0.3s;
    display: flex;
    align-items: center;
    justify-content: center;
}

.quick-link:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0,0,0,0.15);
    background-color: #e8f4ff;
}

.quick-link:hover a {
    color: #1E90FF;
}

.quick-link a {
    text-decoration: none;
    color: #333;
}

/* 分类导航样式 */
.category-container {
    max-width: 1050px;
    margin: 40px auto;
    background-color: white;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    padding: 20px;
}

.category-tabs {
    display: flex;
    border-bottom: 2px solid #1E90FF;
    margin-bottom: 20px;
}

.category-tab {
    padding: 10px 20px;
    font-size: 16px;
    color: #666;
    cursor: pointer;
    border-bottom: 3px solid transparent;
    transition: all 0.3s;
}

.category-tab:hover {
    color: #1E90FF;
    background-color: #e8f4ff;
}

.category-tab.active {
    color: #1E90FF;
    border-bottom-color: #1E90FF;
}

.category-content {
    min-height: 200px;
}

.category-section {
    display: grid;
    grid-template-columns: repeat(6, 1fr);
    gap: 15px;
}

.category-link {
    background-color: #f8f9fa;
    padding: 10px 15px;
    border-radius: 6px;
    text-decoration: none;
    color: #333;
    font-size: 0.95rem;
    text-align: center;
    transition: background-color 0.3s;
}

.category-link:hover {
    background-color: #e8f4ff;
    color: #1E90FF;
}

/* 底部样式 */
.footer {
    max-width: 1050px;
    margin: 40px auto 20px;
    text-align: center;
    font-size: 14px;
    color: #666;
    padding-top: 20px;
    border-top: 1px solid #e0e0e0;
}

.footer-links {
    margin-bottom: 10px;
}

.footer-links a {
    color: #666;
    text-decoration: none;
    margin: 0 10px;
    font-size: 20px;
    padding: 8px;
    border-radius: 50%;
    transition: all 0.3s;
}

.footer-links a:hover {
    color: #1E90FF;
    background-color: #e8f4ff;
}

.footer-links svg {
    vertical-align: middle;
}

/* 联系方式弹窗样式 */
.contact-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    z-index: 1000;
    justify-content: center;
    align-items: center;
}

.contact-modal-content {
    background-color: white;
    padding: 30px;
    border-radius: 8px;
    max-width: 320px;
    width: 90%;
    position: relative;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
}

.contact-modal-close {
    position: absolute;
    top: 10px;
    right: 15px;
    font-size: 24px;
    color: #999;
    cursor: pointer;
    line-height: 1;
}

.contact-modal-close:hover {
    color: #333;
}

/* 响应式设计 */
@media (max-width: 768px) {
    .header {
        height: auto;
        min-height: 120px;
        padding: 15px;
    }
    
    .header h1 {
        font-size: 22px;
        flex-direction: column;
        gap: 10px;
    }
    
    .site-logo {
        width: 50px;
        height: 50px;
    }
    
    .search-container {
        margin: 15px auto;
        padding: 0 15px;
    }
    
    .search-box {
        width: 100%;
        display: flex;
    }
    
    .search-box form {
        width: 100%;
    }
    
    .search-box input {
        width: 100%;
        height: 42px;
        font-size: 15px;
        border-radius: 21px 0 0 21px;
        padding: 0 15px;
    }
    
    .search-box button {
        height: 42px;
        padding: 0 18px;
        font-size: 15px;
        border-radius: 0 21px 21px 0;
        min-width: 90px;
        white-space: nowrap;
    }
    
    .quick-links {
        max-width: 100%;
        margin: 15px auto;
        padding: 0 15px;
        gap: 12px;
        grid-template-columns: repeat(3, 1fr);
    }
    
    .quick-link {
        padding: 15px 10px;
        font-size: 15px;
        text-align: center;
    }
    
    .category-container {
        max-width: 100%;
        margin: 15px auto;
        padding: 15px;
    }
    
    .category-tabs {
        overflow-x: auto;
        white-space: nowrap;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: none;
        padding-bottom: 5px;
        gap: 5px;
    }
    
    .category-tabs::-webkit-scrollbar {
        display: none;
    }
    
    .category-tab {
        padding: 10px 16px;
        font-size: 14px;
        flex-shrink: 0;
        border-radius: 20px;
        background-color: #f5f5f5;
    }
    
    .category-tab.active {
        background-color: #e8f4ff;
    }
    
    .category-section {
        grid-template-columns: repeat(3, 1fr);
        gap: 10px;
    }
    
    .category-link {
        padding: 12px 8px;
        font-size: 13px;
        border-radius: 8px;
    }
    
    .footer {
        max-width: 100%;
        margin: 20px auto 15px;
        padding: 15px;
    }
    
    .footer-links {
        margin-bottom: 15px;
    }
    
    .footer-links a {
        margin: 0 8px;
        font-size: 18px;
        padding: 10px;
    }
    
    .contact-modal-content {
        width: 90%;
        margin: 20% auto;
        padding: 20px;
    }
}

@media (max-width: 480px) {
    .header {
        min-height: 100px;
        padding: 12px;
    }
    
    .header h1 {
        font-size: 18px;
        gap: 8px;
    }
    
    .site-logo {
        width: 40px;
        height: 40px;
    }
    
    .search-box input {
        height: 38px;
        font-size: 14px;
        border-radius: 19px 0 0 19px;
    }
    
    .search-box button {
        height: 38px;
        padding: 0 15px;
        font-size: 14px;
        border-radius: 0 19px 19px 0;
        min-width: 80px;
        white-space: nowrap;
    }
    
    .quick-links {
        grid-template-columns: repeat(2, 1fr);
        gap: 10px;
        padding: 0 10px;
    }
    
    .quick-link {
        padding: 12px 8px;
        font-size: 14px;
    }
    
    .category-container {
        padding: 12px;
    }
    
    .category-tab {
        padding: 8px 14px;
        font-size: 13px;
    }
    
    .category-section {
        grid-template-columns: repeat(2, 1fr);
        gap: 8px;
    }
    
    .category-link {
        padding: 10px 6px;
        font-size: 12px;
    }
    
    .footer-links a {
        margin: 0 5px;
        font-size: 16px;
        padding: 8px;
    }
    
    .contact-modal-content {
        width: 95%;
        margin: 30% auto;
        padding: 15px;
    }
}
