/* ================= 南岭国家公园科普平台 前台样式 ================= */
* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
    font-family: 'Microsoft YaHei', 'PingFang SC', Arial, sans-serif;
    background: #f7faf7;
    color: #333;
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}
a { color: inherit; text-decoration: none; }
img { max-width: 100%; }
.container { max-width: 1200px; margin: 0 auto; padding: 0 16px; }

/* ============ 顶部导航 ============ */
.site-header {
    position: sticky;
    top: 0;
    z-index: 100;
    background: rgba(16, 82, 50, 0.97);
    backdrop-filter: blur(6px);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.15);
}
.nav-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 64px;
}
.logo { display: flex; align-items: center; gap: 10px; color: #fff; }
.logo-icon {
    width: 38px; height: 38px;
    background: linear-gradient(135deg, #6fbf73, #2e8b57);
    border-radius: 10px;
    display: flex; align-items: center; justify-content: center;
    font-size: 20px;
}
.logo-text { font-size: 18px; font-weight: 700; letter-spacing: 1px; }
.logo-text small { display: block; font-size: 11px; font-weight: 400; color: #cfe8d6; letter-spacing: 0; }
.nav-menu { display: flex; gap: 4px; }
.nav-menu a {
    display: block;
    padding: 8px 16px;
    color: #e6f4e9;
    border-radius: 20px;
    font-size: 15px;
    transition: all 0.2s ease;
}
.nav-menu a:hover, .nav-menu a.active { background: rgba(255, 255, 255, 0.18); color: #fff; }
.nav-toggle {
    display: none;
    background: none;
    border: 1px solid rgba(255, 255, 255, 0.4);
    color: #fff;
    border-radius: 6px;
    width: 40px; height: 40px;
    font-size: 20px;
    cursor: pointer;
}

/* ============ 首页轮播 ============ */
.hero { position: relative; overflow: hidden; background: #eaf4ec; }
.hero-track { display: flex; transition: transform 0.5s ease; }
.hero-slide { position: relative; min-width: 100%; }
.hero-slide img { width: 100%; height: 420px; object-fit: cover; display: block; }
.hero-slide .hero-mask {
    position: absolute; inset: 0;
    background: linear-gradient(180deg, rgba(0,0,0,0.1) 0%, rgba(0,0,0,0.55) 100%);
}
.hero-caption {
    position: absolute;
    left: 0; right: 0; bottom: 40px;
    text-align: center;
    color: #fff;
    text-shadow: 0 1px 6px rgba(0,0,0,0.5);
}
.hero-caption h2 { font-size: 30px; margin: 0 0 8px; }
.hero-caption p { font-size: 15px; margin: 0; opacity: 0.92; }
.hero-dots {
    position: absolute; left: 0; right: 0; bottom: 14px;
    display: flex; justify-content: center; gap: 8px;
}
.hero-dots span {
    width: 10px; height: 10px; border-radius: 50%;
    background: rgba(255,255,255,0.5);
    cursor: pointer;
    transition: all 0.2s ease;
}
.hero-dots span.active { background: #fff; width: 26px; border-radius: 6px; }

/* ============ 通用区块 ============ */
.section { padding: 46px 0; }
.section-head { display: flex; align-items: baseline; justify-content: space-between; margin-bottom: 22px; }
.section-title {
    font-size: 24px;
    color: #14532d;
    position: relative;
    padding-left: 14px;
}
.section-title::before {
    content: '';
    position: absolute; left: 0; top: 6px; bottom: 6px;
    width: 4px; border-radius: 3px;
    background: linear-gradient(180deg, #16a34a, #4ade80);
}
.section-more { color: #15803d; font-size: 14px; }
.section-more:hover { text-decoration: underline; }

/* ============ 公告栏 ============ */
.notice-bar {
    background: #fffdf0;
    border: 1px solid #f3e6b8;
    border-radius: 10px;
    padding: 12px 18px;
    display: flex;
    align-items: center;
    gap: 14px;
}
.notice-bar .notice-label {
    flex-shrink: 0;
    background: #f59e0b;
    color: #fff;
    font-size: 13px;
    padding: 2px 10px;
    border-radius: 14px;
}
.notice-list { flex: 1; overflow: hidden; height: 26px; position: relative; }
.notice-list p { margin: 0; line-height: 26px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.notice-list p a:hover { color: #d97706; }

/* ============ 卡片网格 ============ */
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.grid-4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; }
.card {
    background: #fff;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 16px rgba(20, 83, 45, 0.08);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.card:hover { transform: translateY(-4px); box-shadow: 0 12px 28px rgba(20, 83, 45, 0.14); }
.card-img { display: block; width: 100%; height: 180px; object-fit: cover; background: #e5e5e5; }
.card-body { padding: 14px 16px; }
.card-title { font-size: 16px; font-weight: 600; color: #1f2937; margin: 0 0 8px; }
.card-title a:hover { color: #15803d; }
.card-summary { font-size: 13px; color: #6b7280; margin: 0 0 10px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.card-meta { display: flex; justify-content: space-between; font-size: 12px; color: #9ca3af; }
.card-meta .tag { color: #15803d; }

/* 活动卡片 */
.activity-card .status-ribbon {
    position: absolute;
    top: 12px; right: 12px;
    font-size: 12px;
    color: #fff;
    padding: 3px 10px;
    border-radius: 14px;
    z-index: 2;
}
.status-ribbon.recruiting { background: #16a34a; }
.status-ribbon.full { background: #ef4444; }
.status-ribbon.closed { background: #f59e0b; }
.status-ribbon.ended { background: #6b7280; }
.status-ribbon.draft { background: #9ca3af; }
.activity-card .card-img { position: relative; }

/* 视频卡片 */
.video-card .card-img-wrap { position: relative; }
.video-card .card-img { height: 200px; }
.video-card .play-badge {
    position: absolute; inset: 0;
    display: flex; align-items: center; justify-content: center;
}
.video-card .play-badge::before {
    content: '';
    width: 52px; height: 52px;
    background: rgba(255, 255, 255, 0.85);
    border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    box-shadow: 0 4px 16px rgba(0,0,0,0.25);
}
.video-card .play-badge::after {
    content: '';
    position: absolute;
    width: 0; height: 0;
    margin-left: 4px;
    border-style: solid;
    border-width: 9px 0 9px 15px;
    border-color: transparent transparent transparent #16a34a;
}
.video-duration {
    position: absolute; right: 8px; bottom: 8px;
    background: rgba(0,0,0,0.65);
    color: #fff;
    font-size: 12px;
    padding: 1px 8px;
    border-radius: 10px;
}

/* ============ 列表页 ============ */
.page-hero {
    background: linear-gradient(135deg, #166534 0%, #22c55e 100%);
    color: #fff;
    padding: 44px 0;
    text-align: center;
}
.page-hero h1 { margin: 0 0 6px; font-size: 28px; letter-spacing: 2px; }
.page-hero p { margin: 0; opacity: 0.85; font-size: 14px; }
.filter-bar {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 10px;
    margin: 22px 0;
    background: #fff;
    padding: 12px 16px;
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(20, 83, 45, 0.06);
}
.filter-bar .filter-item { color: #6b7280; font-size: 14px; padding: 4px 12px; border-radius: 16px; }
.filter-bar .filter-item:hover { color: #15803d; }
.filter-bar .filter-item.active { background: #dcfce7; color: #15803d; }
.filter-bar .filter-search { margin-left: auto; display: flex; gap: 6px; }
.filter-search input {
    border: 1px solid #d1d5db;
    border-radius: 20px;
    padding: 6px 14px;
    font-size: 14px;
    outline: none;
    width: 200px;
}
.filter-search input:focus { border-color: #16a34a; }
.filter-search button {
    border: none;
    background: #16a34a;
    color: #fff;
    border-radius: 20px;
    padding: 6px 18px;
    cursor: pointer;
    font-size: 14px;
}

/* ============ 详情页 ============ */
.detail-wrap { max-width: 860px; margin: 0 auto; }
.detail-head {
    text-align: center;
    background: #fff;
    padding: 34px 24px 22px;
    border-radius: 12px;
    box-shadow: 0 4px 16px rgba(20, 83, 45, 0.06);
    margin: 26px 0;
}
.detail-head h1 { font-size: 26px; margin: 0 0 12px; color: #14532d; }
.detail-meta { color: #9ca3af; font-size: 13px; display: flex; justify-content: center; gap: 18px; flex-wrap: wrap; }
.detail-cover { margin: 0 0 22px; }
.detail-cover img { width: 100%; border-radius: 12px; max-height: 460px; object-fit: cover; }
.detail-content {
    background: #fff;
    padding: 28px;
    border-radius: 12px;
    box-shadow: 0 4px 16px rgba(20, 83, 45, 0.06);
    font-size: 16px;
    line-height: 1.9;
    color: #333;
}
.detail-content h2 { color: #14532d; margin: 20px 0 10px; }
.detail-content img { max-width: 100%; border-radius: 8px; }
.detail-content a { color: #15803d; }
.detail-content blockquote {
    border-left: 4px solid #16a34a;
    margin: 14px 0;
    padding: 6px 16px;
    color: #4b5563;
    background: #f3faf5;
}
.detail-content table { border-collapse: collapse; margin: 14px 0; }
.detail-content td { border: 1px solid #d1d5db; padding: 6px 12px; }

/* 相关推荐 */
.related { margin: 26px 0 10px; }
.related h3 { color: #14532d; margin: 0 0 14px; }

/* 分页 */
.pagination {
    display: flex;
    justify-content: center;
    gap: 8px;
    margin: 30px 0;
}
.pagination a, .pagination span {
    display: inline-block;
    min-width: 36px;
    height: 36px;
    line-height: 34px;
    text-align: center;
    background: #fff;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    color: #4b5563;
    font-size: 14px;
    padding: 0 6px;
}
.pagination .current { background: #16a34a; border-color: #16a34a; color: #fff; }
.pagination a:hover { border-color: #16a34a; color: #16a34a; }

/* ============ 活动详情 ============ */
.activity-info {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 14px;
    margin: 20px 0;
}
.info-item {
    background: #f3faf5;
    border: 1px solid #d6ecdd;
    border-radius: 10px;
    padding: 14px;
    text-align: center;
}
.info-item .info-label { font-size: 13px; color: #6b7280; }
.info-item .info-value { font-size: 16px; font-weight: 600; color: #14532d; margin-top: 4px; }
.register-box {
    background: #fff;
    border: 1px solid #d6ecdd;
    border-radius: 12px;
    padding: 22px;
    margin: 22px 0;
    box-shadow: 0 4px 16px rgba(20, 83, 45, 0.06);
}
.register-box h3 { margin: 0 0 16px; color: #14532d; }
.form-group { margin-bottom: 14px; }
.form-group label { display: block; margin-bottom: 6px; color: #374151; font-size: 14px; }
.form-group .required { color: #dc2626; }
.form-control {
    width: 100%;
    border: 1px solid #d1d5db;
    border-radius: 8px;
    padding: 9px 12px;
    font-size: 14px;
    font-family: inherit;
    outline: none;
    background: #fff;
}
.form-control:focus { border-color: #16a34a; box-shadow: 0 0 0 3px rgba(22, 163, 74, 0.12); }
textarea.form-control { resize: vertical; min-height: 70px; }
.form-row-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.btn-green {
    display: inline-block;
    background: linear-gradient(135deg, #16a34a, #15803d);
    color: #fff;
    border: none;
    border-radius: 8px;
    padding: 11px 28px;
    font-size: 16px;
    cursor: pointer;
    transition: opacity 0.2s ease;
    font-family: inherit;
}
.btn-green:hover { opacity: 0.92; }
.btn-green:disabled { opacity: 0.6; cursor: not-allowed; }
.btn-outline {
    display: inline-block;
    background: #fff;
    color: #15803d;
    border: 1px solid #16a34a;
    border-radius: 8px;
    padding: 10px 28px;
    font-size: 16px;
    cursor: pointer;
}
.btn-outline:hover { background: #f0fdf4; }
.form-tip { font-size: 13px; color: #6b7280; margin-top: 8px; }
.register-success { text-align: center; padding: 30px 0; }
.register-success .ok-icon {
    width: 64px; height: 64px;
    border-radius: 50%;
    background: #dcfce7;
    color: #16a34a;
    font-size: 32px;
    line-height: 64px;
    margin: 0 auto 14px;
}

/* ============ 视频播放 ============ */
.video-player {
    background: #000;
    border-radius: 12px;
    overflow: hidden;
    margin: 0 0 20px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.3);
}
.video-player video { display: block; width: 100%; max-height: 560px; background: #000; }
.video-title { font-size: 20px; font-weight: 600; margin: 0 0 8px; color: #14532d; }
.video-desc { color: #6b7280; font-size: 14px; }

/* ============ 关于我们 ============ */
.about-intro { background: #fff; border-radius: 12px; padding: 30px; box-shadow: 0 4px 16px rgba(20,83,45,0.06); }
.about-intro h2 { color: #14532d; margin: 22px 0 10px; }
.about-intro p { color: #374151; text-indent: 2em; }
.about-points { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; margin: 26px 0; }
.about-point {
    background: #fff;
    border-radius: 12px;
    padding: 24px 20px;
    text-align: center;
    box-shadow: 0 4px 16px rgba(20, 83, 45, 0.06);
}
.about-point .point-icon { font-size: 34px; }
.about-point h3 { margin: 10px 0 6px; color: #14532d; font-size: 17px; }
.about-point p { color: #6b7280; font-size: 13px; margin: 0; }

/* ============ 页脚 ============ */
.site-footer {
    background: #0f3d24;
    color: #c8dccf;
    margin-top: 50px;
    padding: 34px 0 20px;
}
.footer-top { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 24px; padding-bottom: 22px; }
.footer-about { max-width: 460px; }
.footer-about h4 { color: #fff; margin: 0 0 10px; font-size: 16px; }
.footer-about p { font-size: 13px; margin: 0; }
.footer-links h4 { color: #fff; margin: 0 0 10px; font-size: 16px; }
.footer-links a { display: block; font-size: 13px; color: #c8dccf; padding: 3px 0; }
.footer-links a:hover { color: #fff; }
.footer-bottom {
    border-top: 1px solid rgba(255, 255, 255, 0.12);
    padding-top: 16px;
    text-align: center;
    font-size: 12px;
    color: #8aa396;
}

/* ============ 公告列表 ============ */
.panel-list { display: flex; flex-direction: column; gap: 14px; margin: 22px 0; }
.notice-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    background: #fff;
    border-radius: 12px;
    padding: 18px 22px;
    box-shadow: 0 4px 16px rgba(20, 83, 45, 0.06);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.notice-item:hover { transform: translateY(-2px); box-shadow: 0 10px 24px rgba(20, 83, 45, 0.12); }
.notice-item-main h3 { margin: 0 0 6px; font-size: 17px; color: #1f2937; }
.notice-item:hover .notice-item-main h3 { color: #15803d; }
.notice-item-main p { margin: 0; color: #6b7280; font-size: 13px; }
.notice-item-date {
    display: inline-block;
    background: #f0fdf4;
    color: #15803d;
    font-size: 13px;
    padding: 2px 10px;
    border-radius: 12px;
    margin-bottom: 6px;
}
.notice-item-arrow { color: #16a34a; font-size: 20px; flex-shrink: 0; }

/* ============ 空状态 & 响应式 ============ */
.empty-state { text-align: center; color: #9ca3af; padding: 50px 0; font-size: 15px; }
@media (max-width: 900px) {
    .grid-4 { grid-template-columns: repeat(2, 1fr); }
    .about-points { grid-template-columns: repeat(2, 1fr); }
    .activity-info { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 640px) {
    .nav-toggle { display: block; }
    .nav-menu {
        position: absolute;
        top: 64px; left: 0; right: 0;
        background: #14532d;
        flex-direction: column;
        gap: 0;
        padding: 10px 16px;
        display: none;
    }
    .nav-menu.open { display: flex; }
    .nav-menu a { padding: 12px 10px; border-bottom: 1px solid rgba(255,255,255,0.1); border-radius: 0; }
    .logo-text { font-size: 16px; }
    .hero-slide img { height: 240px; }
    .hero-caption h2 { font-size: 20px; }
    .section { padding: 32px 0; }
    .grid-3, .grid-4 { grid-template-columns: 1fr; }
    .about-points { grid-template-columns: 1fr; }
    .activity-info { grid-template-columns: 1fr 1fr; }
    .form-row-2 { grid-template-columns: 1fr; }
    .filter-search input { width: 140px; }
}
