/* 全局样式 */
:root {
    --primary-color: #2c3e50;
    --secondary-color: #3498db;
    --accent-color: #e74c3c;
    --text-color: #333;
    --light-gray: #f5f6fa;
    --white: #ffffff;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Microsoft YaHei', sans-serif;
    line-height: 1.6;
    color: var(--text-color);
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* 头部样式 */
.header {
    background-color: var(--white);
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
    position: fixed;
    width: 100%;
    top: 0;
    z-index: 1000;
}

.header .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 20px;
}

.logo {
    display: flex;
    align-items: center;
}

.logo img {
    height: 50px;
    margin-right: 10px;
}

.logo h1 {
    font-size: 1.5rem;
    color: var(--primary-color);
}

.nav ul {
    display: flex;
    list-style: none;
}

.nav ul li {
    margin-left: 30px;
}

.nav ul li a {
    text-decoration: none;
    color: var(--text-color);
    font-weight: 500;
    transition: color 0.3s ease;
}

.nav ul li a:hover,
.nav ul li a.active {
    color: var(--secondary-color);
}

/* 轮播图样式 */
.slider {
    margin-top: 80px;
    position: relative;
    height: 500px;
    overflow: hidden;
}

.slider-container {
    height: 100%;
}

.slide {
    position: absolute;
    width: 100%;
    height: 100%;
    opacity: 0;
    transition: opacity 0.5s ease;
}

.slide.active {
    opacity: 1;
}

.slide img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.slide-content {
    position: absolute;
    bottom: 50px;
    left: 50px;
    color: var(--white);
    text-shadow: 2px 2px 4px rgba(0,0,0,0.5);
}

.slide-content h2 {
    font-size: 2.5rem;
    margin-bottom: 10px;
}

.slider-controls button {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(255,255,255,0.5);
    border: none;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    cursor: pointer;
    transition: background 0.3s ease;
}

.slider-controls button:hover {
    background: rgba(255,255,255,0.8);
}

.slider-controls .prev {
    left: 20px;
}

.slider-controls .next {
    right: 20px;
}

/* 特色服务样式 */
.features {
    padding: 80px 0;
    background-color: var(--light-gray);
}

.section-title {
    text-align: center;
    margin-bottom: 50px;
    color: var(--primary-color);
    font-size: 2rem;
}

.feature-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 30px;
}

.feature-item {
    background: var(--white);
    padding: 30px;
    border-radius: 10px;
    text-align: center;
    transition: transform 0.3s ease;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
}

.feature-item:hover {
    transform: translateY(-10px);
}

.feature-item i {
    font-size: 2.5rem;
    color: var(--secondary-color);
    margin-bottom: 20px;
}

.feature-item h3 {
    margin-bottom: 15px;
    color: var(--primary-color);
}

/* 新闻动态样式 */
.news {
    padding: 80px 0;
}

.news-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
}

/* 页脚样式 */
.footer {
    background-color: var(--primary-color);
    color: var(--white);
    padding: 60px 0 20px;
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 40px;
    margin-bottom: 40px;
}

.footer-section h3 {
    margin-bottom: 20px;
    font-size: 1.2rem;
}

.footer-section ul {
    list-style: none;
}

.footer-section ul li {
    margin-bottom: 10px;
}

.footer-section ul li a {
    color: var(--white);
    text-decoration: none;
    transition: color 0.3s ease;
}

.footer-section ul li a:hover {
    color: var(--secondary-color);
}

.social-links {
    display: flex;
    gap: 15px;
}

.social-links a {
    color: var(--white);
    font-size: 1.5rem;
    transition: color 0.3s ease;
}

.social-links a:hover {
    color: var(--secondary-color);
}

.footer-bottom {
    text-align: center;
    padding-top: 20px;
    border-top: 1px solid rgba(255,255,255,0.1);
}

/* 用户操作区域 */
.user-actions {
    display: flex;
    align-items: center;
    margin-left: 20px;
}

.login-btn {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 16px;
    background: var(--primary-color);
    color: var(--white);
    border-radius: 20px;
    text-decoration: none;
    transition: all 0.3s ease;
}

.login-btn:hover {
    background: var(--secondary-color);
    transform: translateY(-2px);
}

.user-info {
    position: relative;
    display: flex;
    align-items: center;
    gap: 10px;
    cursor: pointer;
    padding: 5px 10px;
    border-radius: 20px;
    transition: all 0.3s ease;
}

.user-info:hover {
    background: rgba(255, 255, 255, 0.1);
}

.avatar {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid var(--white);
}

.username {
    color: var(--white);
    font-weight: 500;
}

.dropdown-menu {
    position: absolute;
    top: 100%;
    right: 0;
    background: var(--white);
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
    padding: 10px 0;
    min-width: 150px;
    display: none;
    z-index: 1000;
}

.user-info:hover .dropdown-menu {
    display: block;
    animation: fadeInDown 0.3s ease;
}

.dropdown-menu a {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 15px;
    color: var(--text-color);
    text-decoration: none;
    transition: all 0.3s ease;
}

.dropdown-menu a:hover {
    background: var(--light-gray);
    color: var(--primary-color);
}

.dropdown-menu a.logout {
    color: var(--error-color);
    border-top: 1px solid var(--light-gray);
    margin-top: 5px;
}

.dropdown-menu a.logout:hover {
    background: var(--error-color);
    color: var(--white);
}

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

/* 响应式设计 */
@media (max-width: 768px) {
    .header .container {
        flex-direction: column;
    }

    .nav ul {
        margin-top: 20px;
        flex-wrap: wrap;
        justify-content: center;
    }

    .nav ul li {
        margin: 5px 10px;
    }

    .slider {
        height: 300px;
    }

    .slide-content {
        left: 20px;
        bottom: 20px;
    }

    .slide-content h2 {
        font-size: 1.8rem;
    }

    .user-actions {
        margin-left: 10px;
    }
    
    .login-btn span {
        display: none;
    }
    
    .username {
        display: none;
    }
    
    .dropdown-menu {
        right: -10px;
    }
}

@media (max-width: 480px) {
    .feature-grid {
        grid-template-columns: 1fr;
    }

    .news-grid {
        grid-template-columns: 1fr;
    }
} 