/* ============================================
   乡村振兴主题网页 - 样式表
   ============================================ */

/* 基础重置和变量定义 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --primary-color: #91CBDA;
    --secondary-color: #5BA9C4;
    --accent-color: #E8F4F8;
    --text-color: #2c3e50;
    --light-text: #666;
    --border-color: #d4e9f0;
    --shadow: 0 4px 12px rgba(145, 203, 218, 0.15);
    --shadow-hover: 0 8px 24px rgba(91, 169, 196, 0.25);
    --transition: all 0.3s ease-in-out;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    color: var(--text-color);
    background-color: #fafaf8;
    line-height: 1.6;
}

.container {
    max-width: 1400px;
    margin: 0 auto;
    background-color: #ffffff;
}

/* ============================================
   头部和导航栏
   ============================================ */

header.header {
    background: linear-gradient(135deg, #91CBDA 0%, #5BA9C4 50%, #3A8BA8 100%);
    color: white;
    padding: 30px 0;
    box-shadow: var(--shadow);
    position: sticky;
    top: 0;
    z-index: 100;
}

.header-content {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 30px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 40px;
}

.logo {
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.logo h1 {
    font-size: 32px;
    font-weight: 700;
    margin-bottom: 8px;
    letter-spacing: 2px;
}

.logo .tagline {
    font-size: 14px;
    opacity: 0.95;
    font-weight: 300;
}

/* 导航栏样式 */
.navbar {
    flex-grow: 1;
}

.nav-list {
    display: flex;
    list-style: none;
    gap: 30px;
    flex-wrap: wrap;
}

.nav-link {
    color: white;
    text-decoration: none;
    font-size: 16px;
    font-weight: 500;
    position: relative;
    padding: 8px 0;
    transition: var(--transition);
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background-color: #E8F4F8;
    transition: width 0.3s ease-in-out;
}

.nav-link:hover {
    opacity: 0.8;
    transform: translateY(-2px);
}

.nav-link:hover::after,
.nav-link.active::after {
    width: 100%;
}

/* ============================================
   主横幅区域
   ============================================ */

.banner {
    background: linear-gradient(135deg, rgba(145, 203, 218, 0.85) 0%, rgba(91, 169, 196, 0.8) 50%, rgba(58, 139, 168, 0.85) 100%),
                url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 1200 400"><path fill="rgba(255,255,255,0.1)" d="M0,200 Q300,150 600,200 T1200,200 L1200,400 L0,400 Z"/></svg>');
    background-size: cover, 100%;
    background-position: center, center;
    background-attachment: fixed;
    min-height: 400px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.banner::before {
    content: '';
    position: absolute;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle at 20% 50%, rgba(255, 255, 255, 0.1) 0%, transparent 50%);
    animation: float 20s ease-in-out infinite;
    pointer-events: none;
}

.banner-content {
    position: relative;
    z-index: 1;
    padding: 60px 40px;
    animation: slideDown 0.8s ease-in-out;
}

.banner h2 {
    font-size: 48px;
    font-weight: 700;
    margin-bottom: 20px;
    letter-spacing: 2px;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.2);
}

.banner p {
    font-size: 20px;
    opacity: 0.95;
    font-weight: 300;
    text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.2);
}

/* ============================================
   主内容区域
   ============================================ */

.main-content {
    padding: 60px 30px;
}

.content-wrapper {
    max-width: 1400px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 1fr 350px;
    gap: 40px;
}

/* 段落标题 */
.section-title {
    font-size: 32px;
    font-weight: 700;
    color: #3A8BA8;
    margin-bottom: 40px;
    padding-bottom: 15px;
    border-bottom: 3px solid #91CBDA;
    position: relative;
}

.section-title::before {
    content: '';
    position: absolute;
    left: 0;
    bottom: -3px;
    width: 60px;
    height: 3px;
    background-color: #5BA9C4;
}

/* ============================================
   新闻中心板块
   ============================================ */

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

.news-card {
    background-color: #ffffff;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: var(--shadow);
    transition: var(--transition);
    display: flex;
    flex-direction: column;
    animation: fadeInUp 0.6s ease-in-out;
}

.news-card:hover {
    box-shadow: var(--shadow-hover);
    transform: translateY(-8px);
}

.news-image {
    width: 100%;
    height: 220px;
    overflow: hidden;
    position: relative;
    background: linear-gradient(135deg, #91CBDA, #5BA9C4);
}

.news-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: var(--transition);
}

.news-card:hover .news-image img {
    transform: scale(1.08);
    filter: brightness(1.1);
}

.news-content {
    padding: 25px;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}

.news-title {
    font-size: 20px;
    font-weight: 600;
    color: #3A8BA8;
    margin-bottom: 12px;
    line-height: 1.4;
    transition: color 0.3s ease-in-out;
}

.news-card:hover .news-title {
    color: #91CBDA;
}

.news-intro {
    font-size: 14px;
    color: var(--light-text);
    margin-bottom: 15px;
    line-height: 1.6;
    flex-grow: 1;
}

.news-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: 15px;
    border-top: 1px solid var(--border-color);
    font-size: 12px;
}

.news-date {
    color: #999;
}

.news-category {
    background-color: #E8F4F8;
    color: #3A8BA8;
    padding: 4px 12px;
    border-radius: 20px;
    font-weight: 600;
    transition: var(--transition);
}

.news-card:hover .news-category {
    background-color: #91CBDA;
    color: white;
}

/* ============================================
   侧边栏
   ============================================ */

.sidebar {
    display: flex;
    flex-direction: column;
    gap: 30px;
}

.section-subtitle {
    font-size: 20px;
    font-weight: 700;
    color: #3A8BA8;
    margin-bottom: 15px;
    padding-bottom: 10px;
    border-bottom: 2px solid #91CBDA;
}

/* 新闻快讯 */
.news-brief {
    background-color: #ffffff;
    padding: 25px;
    border-radius: 12px;
    box-shadow: var(--shadow);
}

.brief-list {
    list-style: none;
}

.brief-item {
    display: flex;
    gap: 15px;
    padding: 12px 0;
    border-bottom: 1px solid var(--border-color);
    transition: var(--transition);
}

.brief-item:last-child {
    border-bottom: none;
}

.brief-item:hover {
    background-color: #E8F4F8;
    padding-left: 10px;
}

.brief-time {
    background-color: #91CBDA;
    color: white;
    padding: 4px 10px;
    border-radius: 4px;
    font-size: 12px;
    font-weight: 600;
    white-space: nowrap;
    min-width: 50px;
    text-align: center;
}

.brief-link {
    color: var(--text-color);
    text-decoration: none;
    transition: color 0.3s ease-in-out;
    font-size: 14px;
    line-height: 1.5;
}

.brief-link:hover {
    color: var(--primary-color);
    text-decoration: underline;
}

/* 关于我们侧边框 */
.about-box {
    background: linear-gradient(135deg, #E8F4F8 0%, rgba(145, 203, 218, 0.08) 100%);
    padding: 25px;
    border-radius: 12px;
    border-left: 4px solid #91CBDA;
    box-shadow: var(--shadow);
}

.about-content {
    font-size: 14px;
    color: var(--text-color);
    line-height: 1.8;
}

.about-content p {
    margin-bottom: 15px;
}

.about-list {
    list-style: none;
    padding-left: 0;
}

.about-list li {
    padding-left: 25px;
    margin-bottom: 10px;
    position: relative;
    color: var(--light-text);
}

.about-list li::before {
    content: '✓';
    position: absolute;
    left: 0;
    color: #91CBDA;
    font-weight: bold;
    font-size: 16px;
}

/* 建设成果统计 */
.stats-box {
    background-color: #ffffff;
    padding: 25px;
    border-radius: 12px;
    box-shadow: var(--shadow);
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 15px;
}

.stat-item {
    background: linear-gradient(135deg, #91CBDA 0%, #5BA9C4 100%);
    color: white;
    padding: 20px 15px;
    border-radius: 8px;
    text-align: center;
    transition: var(--transition);
    box-shadow: 0 2px 8px rgba(145, 203, 218, 0.25);
}

.stat-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 6px 16px rgba(145, 203, 218, 0.35);
}

.stat-number {
    display: block;
    font-size: 24px;
    font-weight: 700;
    margin-bottom: 5px;
}

.stat-label {
    display: block;
    font-size: 13px;
    font-weight: 500;
    opacity: 0.9;
}

/* ============================================
   页脚区域
   ============================================ */

footer.footer {
    background: linear-gradient(135deg, #91CBDA 0%, #5BA9C4 50%, #3A8BA8 100%);
    color: white;
    padding: 50px 30px 20px;
    margin-top: 60px;
}

.footer-content {
    max-width: 1400px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 40px;
    padding-bottom: 30px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.2);
}

.footer-section h4 {
    font-size: 18px;
    font-weight: 600;
    margin-bottom: 15px;
    color: #E8F4F8;
}

.footer-section p {
    font-size: 14px;
    margin-bottom: 10px;
    opacity: 0.9;
    line-height: 1.8;
}

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

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

.footer-section a {
    color: white;
    text-decoration: none;
    transition: var(--transition);
    font-size: 14px;
}

.footer-section a:hover {
    color: #E8F4F8;
    padding-left: 8px;
}

.footer-bottom {
    max-width: 1400px;
    margin: 0 auto;
    padding: 30px 0;
    text-align: center;
    font-size: 13px;
    opacity: 0.85;
}

/* ============================================
   动画效果
   ============================================ */

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

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes float {
    0%, 100% {
        transform: translate(0, 0);
    }
    25% {
        transform: translate(10px, -10px);
    }
    50% {
        transform: translate(-10px, 10px);
    }
    75% {
        transform: translate(-10px, -10px);
    }
}

/* ============================================
   响应式设计
   ============================================ */

@media (max-width: 1024px) {
    .content-wrapper {
        grid-template-columns: 1fr;
    }

    .header-content {
        flex-direction: column;
        gap: 20px;
    }

    .logo h1 {
        font-size: 28px;
    }

    .banner h2 {
        font-size: 36px;
    }

    .banner p {
        font-size: 16px;
    }
}

@media (max-width: 768px) {
    .header-content {
        padding: 0 15px;
    }

    .logo h1 {
        font-size: 24px;
    }

    .nav-list {
        gap: 15px;
    }

    .nav-link {
        font-size: 14px;
    }

    .banner {
        min-height: 300px;
    }

    .banner h2 {
        font-size: 28px;
    }

    .banner p {
        font-size: 14px;
    }

    .main-content {
        padding: 40px 15px;
    }

    .section-title {
        font-size: 24px;
    }

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

    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .footer-content {
        grid-template-columns: 1fr;
        gap: 20px;
    }
}

@media (max-width: 480px) {
    header.header {
        padding: 20px 0;
    }

    .logo h1 {
        font-size: 20px;
    }

    .logo .tagline {
        font-size: 12px;
    }

    .nav-list {
        gap: 10px;
    }

    .nav-link {
        font-size: 12px;
        padding: 4px 0;
    }

    .banner {
        min-height: 250px;
    }

    .banner h2 {
        font-size: 20px;
    }

    .banner p {
        font-size: 12px;
    }

    .main-content {
        padding: 30px 10px;
    }

    .section-title {
        font-size: 20px;
        margin-bottom: 20px;
    }

    .news-card {
        margin-bottom: 20px;
    }

    .news-image {
        height: 180px;
    }

    .news-title {
        font-size: 16px;
    }

    .news-intro {
        font-size: 13px;
    }

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

    .footer-section h4 {
        font-size: 16px;
    }
}
