/* ==================== 基础样式 ==================== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", "Helvetica Neue", Helvetica, Arial, sans-serif;
    background: #f5f7fa;
    color: #333;
    line-height: 1.6;
    font-size: 14px;
}

a {
    text-decoration: none;
    color: inherit;
    transition: color 0.3s ease;
}

a:hover {
    color: #6a9c47;
}

.clearfix::after {
    content: "";
    display: table;
    clear: both;
}
#topbar {
    background-color: #6a9c47;
}
#topbar .links>li, #topbar .links>li>a {
    color: #f1f1f1;
}
#topbar .left-name {
    color: #f1f1f1;
}

/* ==================== 头部样式 ==================== */
#header {
    background: #fff;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.08);
    height: auto !important;
    margin-bottom: 20px;
}

/* 顶部工具栏 */
.header-top {
    background: linear-gradient(90deg, #6a9c47 0%, #7cb342 100%);
    min-height: 40px;
    line-height: 40px;
    padding: 0;
}

.top-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.top-left .welcome-text {
    color: rgba(255, 255, 255, 0.9);
    font-size: 13px;
}

.top-right {
    display: flex;
    gap: 20px;
}

.top-link {
    color: rgba(255, 255, 255, 0.9);
    font-size: 13px;
    padding: 0 8px;
}

.top-link:hover {
    color: #fff;
}

/* 主头部区域 */
.header-main {
    padding: 20px 0;
}

.header-content {
    display: flex;
    align-items: center;
    gap: 30px;
    flex-wrap: wrap;
}

/* Logo */
.logo a {
    display: flex;
    align-items: center;
    gap: 12px;
    flex-shrink: 0;
}

.logo img {
    height: 50px;
    width: auto;
}

.logo-text {
    font-size: 24px;
    font-weight: 600;
    color: #6a9c47;
    white-space: nowrap;
}

/* 搜索框 */
.search-box {
    flex: 1;
    min-width: 280px;
    max-width: 500px;
}

.search-wrapper {
    display: flex;
    background: #f5f7fa;
    border-radius: 50px;
    border: 2px solid #e8ecef;
    overflow: hidden;
    transition: all 0.3s ease;
}

.search-wrapper:focus-within {
    border-color: #6a9c47;
    box-shadow: 0 0 0 3px rgba(106, 156, 71, 0.1);
}

.search-input {
    flex: 1;
    border: none;
    background: transparent;
    padding: 12px 20px;
    font-size: 14px;
    outline: none;
    min-width: 0;
}

.search-btn {
    display: flex;
    align-items: center;
    gap: 6px;
    background: linear-gradient(90deg, #6a9c47 0%, #7cb342 100%);
    border: none;
    padding: 12px 24px;
    color: #fff;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: opacity 0.3s ease;
    flex-shrink: 0;
}

.search-btn:hover {
    opacity: 0.9;
}

.search-icon {
    font-size: 16px;
}

/* 发布按钮 */
.header-action .btn-publish {
    display: flex;
    align-items: center;
    gap: 8px;
    background: linear-gradient(135deg, #ff9500 0%, #ff6b35 100%);
    color: #fff;
    padding: 12px 24px;
    border-radius: 50px;
    font-weight: 500;
    font-size: 14px;
    box-shadow: 0 4px 15px rgba(255, 149, 0, 0.3);
    transition: all 0.3s ease;
    flex-shrink: 0;
    white-space: nowrap;
}

.header-action .btn-publish:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(255, 149, 0, 0.4);
    color: #fff;
}

.publish-icon {
    font-size: 16px;
}

/* 导航栏 */
.header-nav {
    background: #fff;
    border-top: 1px solid #f0f0f0;
    height: auto !important;
}

.navbar {
    padding: 0;
    height: auto !important;
}

.nav-wrapper {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
}

.nav-wrapper a {
    display: inline-block;
    padding: 15px 18px;
    color: #555;
    font-size: 15px;
    font-weight: 500;
    position: relative;
    transition: all 0.3s ease;
    white-space: nowrap;
}

.nav-wrapper a:hover,
.nav-wrapper a.active {
    color: #6a9c47;
}

.nav-wrapper a.active::after {
    content: "";
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 80%;
    height: 3px;
    background: linear-gradient(90deg, #6a9c47 0%, #7cb342 100%);
    border-radius: 3px 3px 0 0;
}

/* ==================== 广告位样式 ==================== */
.top-ads {
    background: #fff;
    padding: 15px 0;
    margin-bottom: 20px;
}

.ads-link {
    display: block;
    width: 100%;
}

.ads-image {
    width: 100%;
    height: auto;
    border-radius: 8px;
    transition: opacity 0.3s ease;
    max-width: 100%;
}

.ads-link:hover .ads-image {
    opacity: 0.9;
}

/* ==================== 分类导航样式 ==================== */
.category-section {
    background: #fff;
    padding: 40px 0;
    margin-bottom: 30px;
}

.section-header {
    text-align: center;
    margin-bottom: 35px;
}

.section-title {
    font-size: 28px;
    color: #333;
    margin-bottom: 8px;
    font-weight: 600;
}

.section-subtitle {
    color: #999;
    font-size: 14px;
}

.category-grid {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 20px;
}

.category-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 25px 15px;
    background: #f8f9fa;
    border-radius: 12px;
    transition: all 0.3s ease;
    border: 2px solid transparent;
    min-width: 0;
}

.category-card:hover {
    background: #fff;
    border-color: #6a9c47;
    box-shadow: 0 8px 25px rgba(106, 156, 71, 0.15);
    transform: translateY(-5px);
}

.category-icon {
    font-size: 36px;
    margin-bottom: 12px;
    line-height: 1;
}

.category-name {
    font-size: 16px;
    color: #333;
    font-weight: 500;
    margin-bottom: 4px;
    text-align: center;
    white-space: nowrap;
}

.category-count {
    font-size: 12px;
    color: #999;
    text-align: center;
    white-space: nowrap;
}

/* ==================== 信息列表样式 ==================== */
.info-section {
    background: #fff;
    padding: 30px 0;
    margin-bottom: 20px;
}

.info-section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-bottom: 20px;
    border-bottom: 2px solid #f0f0f0;
    margin-bottom: 25px;
}

.info-section-title {
    display: flex;
    align-items: center;
    gap: 12px;
}

.title-icon {
    font-size: 24px;
    line-height: 1;
}

.title-text {
    font-size: 20px;
    color: #333;
    font-weight: 600;
    white-space: nowrap;
}

.view-more {
    color: #6a9c47;
    font-size: 14px;
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 4px;
    padding: 8px 16px;
    background: rgba(106, 156, 71, 0.08);
    border-radius: 20px;
    transition: all 0.3s ease;
    flex-shrink: 0;
    white-space: nowrap;
}

.view-more:hover {
    background: rgba(106, 156, 71, 0.15);
    color: #6a9c47;
}

.view-more .arrow {
    font-size: 18px;
    line-height: 1;
}

.info-list-content {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 15px;
}

.info-list {
    background: #fff;
    border: 1px solid #e8ecef;
    border-radius: 8px;
    overflow: hidden;
    transition: all 0.3s ease;
    min-width: 0;
}

.info-list:hover {
    border-color: #6a9c47;
    box-shadow: 0 4px 15px rgba(106, 156, 71, 0.1);
    transform: translateY(-2px);
}

.list-content {
    padding: 15px;
    width: 100%;
    min-width: 0;
}

.list-name {
    display: block;
    font-size: 14px;
    color: #333;
    margin-bottom: 12px;
    line-height: 1.5;
    overflow: hidden;
    text-overflow: ellipsis;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    min-height: 42px;
    transition: color 0.3s ease;
    word-break: break-all;
}

.list-name:hover {
    color: #6a9c47;
}

.list-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    padding-top: 12px;
    border-top: 1px solid #f0f0f0;
}

.meta-column,
.meta-area,
.meta-time {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    font-size: 12px;
    color: #999;
    max-width: 100%;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.meta-icon {
    font-size: 12px;
    line-height: 1;
}

.meta-column {
    color: #6a9c47;
    background: rgba(106, 156, 71, 0.08);
    padding: 2px 6px;
    border-radius: 4px;
}
.info-content {
    width: 1200px !important;
}

/* ==================== 页脚样式 ==================== */
#footer {
    background: #2c3e50;
    color: #ecf0f1;
    margin-top: 40px;
}

/* 页脚链接区 */
.footer-links {
    padding: 50px 0;
}

.footer-link-row {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 40px;
}

.footer-col {
    padding: 0 10px;
    min-width: 0;
}

.footer-title {
    font-size: 16px;
    color: #fff;
    margin-bottom: 20px;
    font-weight: 600;
    position: relative;
    padding-bottom: 10px;
}

.footer-title::after {
    content: "";
    position: absolute;
    bottom: 0;
    left: 0;
    width: 40px;
    height: 2px;
    background: linear-gradient(90deg, #6a9c47 0%, #7cb342 100%);
}

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

.footer-list li {
    margin-bottom: 12px;
}

.footer-list a {
    color: #bdc3c7;
    font-size: 14px;
    transition: all 0.3s ease;
    display: inline-block;
    word-break: break-all;
}

.footer-list a:hover {
    color: #6a9c47;
    transform: translateX(5px);
}

.footer-contact .contact-list li {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    color: #bdc3c7;
    font-size: 14px;
    word-break: break-all;
}

.contact-icon {
    font-size: 16px;
    line-height: 1;
    flex-shrink: 0;
}

/* 版权信息区 */
.footer-copyright {
    background: #1a252f;
    padding: 25px 0;
}

.copyright-content {
    text-align: center;
}

.copyright-info,
.beian-info {
    color: #7f8c8d;
    font-size: 14px;
    margin-bottom: 8px;
}

.beian-info a {
    color: #6a9c47;
    transition: color 0.3s ease;
}

.beian-info a:hover {
    color: #7cb342;
}

.wall {
    min-height: 100vh;
    padding-top: 50px;
}
.login, .register, .forget {
    margin-top: 0;
}

/* ==================== 响应式设计 ==================== */
@media (max-width: 1100px) {
    .category-grid {
        grid-template-columns: repeat(5, 1fr);
    }
    
    .info-list-content {
        grid-template-columns: repeat(4, 1fr);
    }
}

@media (max-width: 992px) {
    .category-grid {
        grid-template-columns: repeat(3, 1fr);
    }
    
    .info-list-content {
        grid-template-columns: repeat(3, 1fr);
    }
    
    .footer-link-row {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .header-content {
        justify-content: center;
    }
    
    .search-box {
        order: 3;
        max-width: 100%;
        width: 100%;
    }
    
    .header-action {
        order: 4;
    }
}

@media (max-width: 768px) {
    .category-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .info-list-content {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .top-bar {
        flex-direction: column;
        gap: 10px;
        text-align: center;
    }
    
    .top-right {
        justify-content: center;
    }
    
    .mobile-hide {
        display: none;
    }
    
    .header-action {
        display: none;
    }
    
    .section-title {
        font-size: 22px;
    }
    
    .title-text {
        font-size: 18px;
    }
}

@media (max-width: 576px) {
    .category-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 10px;
    }
    
    .category-card {
        padding: 15px 10px;
    }
    
    .category-icon {
        font-size: 28px;
    }
    
    .category-name {
        font-size: 14px;
    }
    
    .category-count {
        font-size: 11px;
    }
    
    .info-list-content {
        grid-template-columns: 1fr;
    }
    
    .footer-link-row {
        grid-template-columns: 1fr;
        gap: 30px;
    }
    
    .section-title {
        font-size: 20px;
    }
    
    .header-main {
        padding: 15px 0;
    }
    
    .logo-text {
        font-size: 18px;
    }
    
    .search-input {
        padding: 10px 15px;
        font-size: 13px;
    }
    
    .search-btn {
        padding: 10px 15px;
    }
    
    .search-text {
        display: none;
    }
}

/* ==================== 页面包装器 ==================== */
.page-wrapper {
    min-height: calc(100vh - 500px);
}

/* ==================== 工具类 ==================== */
.mt-md {
    margin-top: 20px;
}

.mb-md {
    margin-bottom: 20px;
}

.mt-sm {
    margin-top: 10px;
}

.mb-sm {
    margin-bottom: 10px;
}
