:root {
    --primary-color: #4A6CF7;
    --secondary-color: #1E293B;
    --text-color: #333647;
    --light-text: #64748B;
    --white: #FFFFFF;
    --light-bg: #F8FAFC;
    --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.05);
    --radius-md: 12px;
    --transition: all 0.4s ease;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: "Microsoft Yahei", "PingFang SC", "Helvetica Neue", Arial, sans-serif;
}

body {
    background-color: var(--light-bg);
    color: var(--text-color);
    line-height: 1.6;
    overflow-x: hidden;
}

/* 基础布局容器 */
.main-wrapper {
    width: 100%;
    position: relative;
}

.content-container {
    max-width: 1440px;
    margin: 0 auto;
    padding: 0 16px;
    width: 100%;
}

/* 通用区块样式 */
section {
    width: 100%;
    position: relative;
    margin-bottom: 40px;
    clear: both;
}

.banner-section {
    height: 600px;
    margin-bottom: 40px;
    overflow: hidden;
}

.ads-section {
    margin: 20px 0;
}

.ads-section:empty {
    display: none;
}

.recommend-section, .solutions-section, .news-section {
    margin-bottom: 40px;
}

/* 区块标题样式 */
.section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 24px;
    flex-wrap: wrap;
    gap: 10px;
}

.section-title {
    font-size: 32px;
    font-weight: 700;
    color: var(--secondary-color);
    position: relative;
    padding-bottom: 10px;
    margin: 0;
}

.section-title::after {
    content: '';
    position: absolute;
    left: 0;
    bottom: 0;
    width: 60px;
    height: 4px;
    background-color: var(--primary-color);
    border-radius: 2px;
}

.section-desc {
    font-size: 16px;
    color: var(--light-text);
    margin-top: 8px;
    max-width: 600px;
    line-height: 1.6;
}

.view-more {
    display: inline-flex;
    align-items: center;
    color: var(--primary-color);
    font-size: 16px;
    font-weight: 500;
    text-decoration: none;
    padding: 8px 16px;
    border: 1px solid var(--primary-color);
    border-radius: 8px;
    transition: var(--transition);
}

.view-more:hover {
    background-color: var(--primary-color);
    color: var(--white);
    transform: translateY(-2px);
    box-shadow: var(--shadow-sm);
}

/* 轮播图样式 */
.banner-slider {
    width: 100%;
    height: 100%;
    overflow: hidden;
    position: relative;
}

.maintit {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    z-index: 10;
    color: var(--white);
    text-shadow: 0 2px 8px rgba(0,0,0,0.5);
    text-align: center;
    width: 100%;
    max-width: 800px;
    padding: 0 16px;
}

.maintit1 {
    font-size: 42px;
    font-weight: 700;
    margin-bottom: 16px;
    line-height: 1.2;
}

.maintit2 {
    font-size: 20px;
    opacity: 0.95;
    line-height: 1.5;
}

.slider-wrapper {
    display: flex;
    width: 100%;
    height: 100%;
    transition: transform 0.8s ease;
}

.slider-item {
    min-width: 100%;
    height: 100%;
    position: relative;
}

.slider-dots {
    position: absolute;
    bottom: 40px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 16px;
    z-index: 10;
}

.slider-dot {
    width: 14px;
    height: 14px;
    border-radius: 50%;
    background-color: rgba(255,255,255,0.6);
    cursor: pointer;
    transition: var(--transition);
    border: 2px solid transparent;
}

.slider-dot.active {
    background-color: var(--white);
    border-color: var(--primary-color);
    width: 36px;
    border-radius: 8px;
}

/* 推荐卡片网格布局 */
.recommend-grid {
    width: 100%;
    margin: 0;
    padding: 0;
    display: flex;
    flex-wrap: wrap;
    gap: 0;
    justify-content: space-between;
    position: relative;
}

/* 修复最后一行布局伪元素 */
.recommend-grid::after {
    content: '';
    flex: auto;
    width: 24.5%;
    height: 0;
    visibility: hidden;
}

/* 推荐卡片基础样式 */
.recommend-grid .isotope-item {
    width: 24.5%;
    margin: 0 0 20px 0;
    padding: 0;
    position: relative;
    height: auto;
    min-height: 360px;
    float: none;
    flex-shrink: 0;
    box-sizing: border-box;
}

.recommend-card {
    background-color: var(--white);
    border-radius: var(--radius-md);
    overflow: hidden;
    box-shadow: var(--shadow-sm);
    transition: var(--transition);
    height: 100%;
    display: flex;
    flex-direction: column;
    margin: 0 8px 20px 8px;
}

.recommend-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.08);
}

.card-img {
    position: relative;
    width: 100%;
    height: 200px;
    overflow: hidden;
    flex: none;
}

.card-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s ease;
}

.recommend-card:hover .card-img img {
    transform: scale(1.08);
}

.overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0,0,0,0.1);
}

.meta-info {
    position: absolute;
    top: 12px;
    left: 12px;
    display: flex;
    align-items: center;
    gap: 6px;
    background-color: rgba(0,0,0,0.6);
    padding: 6px 12px;
    border-radius: 16px;
    color: var(--white);
    font-size: 13px;
}

.hit-tag {
    color: #FFD700;
    font-weight: 600;
}

/* 卡片内容区 */
.card-content {
    padding: 16px;
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    gap: 8px;
    box-sizing: border-box;
}

.card-title {
    font-size: 16px;
    font-weight: 600;
    color: var(--secondary-color);
    margin-bottom: 8px;
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    order: 0;
}

/* 作者信息 */
.author-info {
    display: flex;
    align-items: center;
    order: 1;
    width: 100%;
    margin-top: 5px !important;
}

.author-avatar {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid var(--light-bg);
}

.author-name {
    font-size: 13px;
    color: var(--light-text);
    margin-left: 8px;
}

/* Tag样式（合并重复代码，统一管理） */
.recommend-card .card-content .project-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    padding-top: 10px;
    border-top: 1px solid var(--light-bg);
    margin-top: -2px !important;
    order: 2;
    width: 100%;
    max-height: 60px;
    overflow: hidden;
    box-sizing: border-box;
}

.recommend-card .card-content .tag-item {
    padding: 4px 10px;
    background-color: rgba(74, 108, 247, 0.1);
    color: var(--primary-color);
    border-radius: 16px;
    font-size: 12px;
    font-weight: 500;
}

.recommend-card .card-content .tag-empty {
    color: var(--light-text);
    font-size: 12px;
    font-style: italic;
}

/* 广告样式 */
.ad-banner {
    width: 100%;
    height: 280px;
    background-position: center;
    background-size: cover;
    background-repeat: no-repeat;
    position: relative;
    border-radius: var(--radius-md);
    overflow: hidden;
    margin-bottom: 20px;
}

.ad-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, rgba(0,0,0,0.7) 0%, rgba(0,0,0,0.3) 100%);
}

.ad-content {
    height: 100%;
    display: flex;
    align-items: center;
}

.ad-link {
    text-decoration: none;
}

.ad-title {
    font-size: 32px;
    font-weight: 700;
    color: var(--white);
    text-shadow: 0 2px 8px rgba(0, 0, 0, 0.4);
    max-width: 600px;
    transition: var(--transition);
    padding: 0 20px;
}

.ad-title:hover {
    color: var(--primary-color);
    transform: translateX(6px);
}

/* 行业解决方案样式 */
.solutions-slider {
    width: 100%;
    overflow: hidden;
    clear: both;
    margin-top: 8px;
}

.slide-slick {
    display: flex;
    gap: 20px;
    width: 100%;
    flex-wrap: wrap;
}

.solution-card {
    flex: 1;
    min-width: 280px;
    max-width: calc(33.333% - 14px);
    height: 300px;
    border-radius: var(--radius-md);
    overflow: hidden;
    position: relative;
    box-shadow: var(--shadow-sm);
    transition: var(--transition);
    z-index: 1;
    margin-bottom: 16px;
}

.solution-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.08);
}

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

.card-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(to bottom, rgba(0,0,0,0.1), rgba(0,0,0,0.7));
}

.card-link {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    padding: 20px;
    color: var(--white);
    text-decoration: none;
}

.card-cat {
    font-size: 18px;
    font-weight: 600;
    display: block;
    margin-bottom: 6px;
}

.card-text {
    font-size: 14px;
    opacity: 0.9;
    line-height: 1.4;
}

/* 新闻资讯样式 */
.news-container {
    display: grid;
    grid-template-columns: 2fr 3fr;
    gap: 20px;
    width: 100%;
    clear: both;
}

.main-ad {
    height: 100%;
    border-radius: var(--radius-md);
    overflow: hidden;
    box-shadow: var(--shadow-sm);
    position: relative;
}

.main-ad-link {
    display: block;
    width: 100%;
    height: 100%;
}

.main-ad img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s ease;
}

.main-ad:hover img {
    transform: scale(1.02);
}

/* 右侧小图广告区域 */
.sub-ads {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    grid-template-rows: repeat(2, 1fr);
    gap: 12px;
    height: 100%;
}

.sub-ad-item {
    position: relative;
    border-radius: var(--radius-md);
    overflow: hidden;
    box-shadow: var(--shadow-sm);
    transition: var(--transition);
    height: 100%;
}

.sub-ad-link {
    display: block;
    width: 100%;
    height: 100%;
    position: relative;
    text-decoration: none;
}

.sub-ad-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s ease;
}

.sub-ad-item:hover img {
    transform: scale(1.05);
}

/* 响应式适配（按屏幕尺寸从大到小排序） */
@media (max-width: 1200px) {
    .recommend-grid .isotope-item {
        width: 32.5%;
        min-height: 340px;
    }
    
    .recommend-grid::after {
        width: 32.5%;
    }
    
    .solution-card {
        max-width: calc(50% - 10px);
    }
    
    .news-container {
        grid-template-columns: 1fr 1fr;
    }
    
    .sub-ads {
        grid-template-columns: repeat(2, 1fr);
        grid-template-rows: repeat(3, 1fr);
    }
}

@media (max-width: 992px) {
    .recommend-grid .isotope-item {
        width: 49%;
        min-height: 340px;
    }
    
    .recommend-grid::after {
        width: 49%;
    }
    
    .recommend-card {
        margin: 0 6px 20px 6px;
    }
    
    .news-container {
        grid-template-columns: 1fr 1fr;
        gap: 16px;
    }
    
    .sub-ads {
        grid-template-columns: repeat(2, 1fr);
        grid-template-rows: repeat(2, 1fr);
    }
    
    .solution-card {
        max-width: calc(50% - 8px);
        height: 280px;
    }
}

@media (max-width: 768px) {
    /* 全局调整 */
    .banner-section {
        height: 400px;
    }
    
    .maintit1 {
        font-size: 28px;
        margin-bottom: 12px;
    }
    
    .maintit2 {
        font-size: 16px;
    }
    
    .section-title {
        font-size: 24px;
        padding-bottom: 8px;
    }
    
    .ad-banner {
        height: 200px;
        margin-bottom: 16px;
    }
    
    .ad-title {
        font-size: 24px;
    }
    
    /* 行业解决方案 */
    .solution-card {
        max-width: 100%;
        min-width: 100%;
        margin-bottom: 12px;
        height: 240px;
    }
    
    /* 新闻资讯 */
    .news-container {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    
    .main-ad {
        height: 240px;
    }
    
    .sub-ads {
        grid-template-columns: repeat(2, 1fr);
        grid-template-rows: repeat(2, 1fr);
        height: auto;
        min-height: auto;
        gap: 12px;
    }
    
    .sub-ad-item {
        min-height: 120px;
        height: auto;
    }
    
    /* 推荐卡片 */
    .recommend-grid .isotope-item {
        width: 49%;
        min-height: 320px;
        margin-bottom: 16px;
    }
    
    .recommend-grid::after {
        width: 49%;
    }
    
    .recommend-card {
        margin: 0 4px 16px 4px;
    }
    
    .card-img {
        height: 180px;
    }
    
    /* Tag样式调整 */
    .recommend-card .card-content .project-tags {
        margin-top: 8px;
        padding-top: 8px;
        gap: 5px;
    }
    
    .recommend-card .card-content .tag-item {
        padding: 3px 9px;
        font-size: 11px;
    }
}

@media (max-width: 576px) {
    /* 全局调整 */
    section {
        margin-bottom: 32px;
    }
    
    .banner-section, .recommend-section, .solutions-section, .news-section {
        margin-bottom: 32px;
    }
    
    .ads-section {
        margin: 16px 0;
    }
    
    .content-container {
        padding: 0 12px;
    }
    
    .slider-dots {
        bottom: 30px;
    }
    
    /* 推荐卡片 */
    .recommend-grid .isotope-item {
        width: 49%;
        min-height: 280px;
        margin-bottom: 12px;
    }
    
    .recommend-grid::after {
        width: 49%;
    }
    
    .recommend-card {
        margin: 0 2px 12px 2px;
    }
    
    .card-img {
        height: 150px;
    }
    
    .card-content {
        padding: 12px;
        gap: 6px;
    }
    
    .card-title {
        font-size: 14px;
        margin-bottom: 6px;
    }
    
    .author-avatar {
        width: 24px;
        height: 24px;
    }
    
    .author-name {
        font-size: 12px;
        margin-left: 6px;
    }
    
    .meta-info {
        top: 8px;
        left: 8px;
        padding: 4px 8px;
        font-size: 11px;
    }
    
    /* 区块标题 */
    .section-header {
        flex-direction: column;
        align-items: flex-start;
        margin-bottom: 20px;
    }
    
    .section-title {
        font-size: 20px;
        margin-bottom: 8px;
    }
    
    .section-desc {
        font-size: 14px;
        margin-bottom: 12px;
    }
    
    .view-more {
        align-self: flex-start;
        margin-top: 8px;
        padding: 6px 14px;
        font-size: 14px;
    }
    
    /* 广告 */
    .ad-banner {
        height: 160px;
        margin-bottom: 12px;
    }
    
    .ad-title {
        font-size: 20px;
    }
    
    .news-container {
        gap: 16px;
    }
    
    .main-ad {
        height: 180px;
    }
    
    .sub-ads {
        display: flex;
        flex-direction: column;
        gap: 10px;
        height: auto;
    }
    
    .sub-ad-item {
        min-height: 80px;
        height: 80px;
        margin: 0;
    }
    
    /* 行业解决方案 */
    .solution-card {
        height: 200px;
        margin-bottom: 12px;
    }
    
    .card-link {
        padding: 16px;
    }
    
    .card-cat {
        font-size: 16px;
    }
    
    .card-text {
        font-size: 13px;
    }
    
    /* Tag样式调整 */
    .recommend-card .card-content .project-tags {
        padding-top: 6px;
        margin-top: 6px;
        gap: 4px;
    }
    
    .recommend-card .card-content .tag-item {
        padding: 3px 8px;
        font-size: 11px;
    }
}

@media (max-width: 480px) {
    /* 推荐卡片 */
    .recommend-grid .isotope-item {
        width: 49%;
        min-height: 260px;
        margin-bottom: 10px;
    }
    
    .recommend-grid::after {
        width: 49%;
    }
    
    .recommend-card {
        margin: 0 2px 10px 2px;
    }
    
    .card-img {
        height: 130px;
    }
    
    .card-content {
        padding: 10px;
        gap: 4px;
    }
    
    .card-title {
        font-size: 13px;
        margin-bottom: 4px;
    }
    
    .author-avatar {
        width: 22px;
        height: 22px;
    }
    
    .author-name {
        font-size: 11px;
    }
    
    .meta-info {
        padding: 3px 6px;
        font-size: 10px;
    }
    
    /* 新闻资讯 */
    .news-container {
        gap: 12px;
    }
    
    .main-ad {
        height: 150px;
    }
    
    .sub-ads {
        gap: 8px;
    }
    
    .sub-ad-item {
        min-height: 70px;
        height: 70px;
    }
    
    /* 行业解决方案 */
    .solution-card {
        height: 180px;
    }
    
    .section-title {
        font-size: 18px;
    }
    
    .section-desc {
        font-size: 13px;
    }
    
    /* Tag样式调整 */
    .recommend-card .card-content .project-tags {
        padding-top: 4px;
        margin-top: 4px;
        gap: 3px;
    }
    
    .recommend-card .card-content .tag-item {
        padding: 2px 6px;
        font-size: 10px;
    }
}

@media (max-width: 360px) {
    /* 推荐卡片 */
    .recommend-grid .isotope-item {
        width: 49%;
        min-height: 240px;
        margin-bottom: 8px;
    }
    
    .recommend-grid::after {
        width: 49%;
    }
    
    .recommend-card {
        margin: 0 1px 8px 1px;
    }
    
    .card-img {
        height: 110px;
    }
    
    .card-content {
        padding: 8px;
    }
    
    .card-title {
        font-size: 12px;
        margin-bottom: 4px;
        -webkit-line-clamp: 2;
    }
    
    .author-avatar {
        width: 20px;
        height: 20px;
    }
    
    .author-name {
        font-size: 10px;
    }
    
    .meta-info {
        top: 6px;
        left: 6px;
        padding: 2px 5px;
        font-size: 9px;
    }
    
    /* 新闻资讯 */
    .news-container {
        gap: 10px;
    }
    
    .main-ad {
        height: 130px;
    }
    
    .sub-ads {
        gap: 6px;
    }
    
    .sub-ad-item {
        min-height: 60px;
        height: 60px;
    }
    
    /* 行业解决方案 */
    .solution-card {
        height: 160px;
    }
    
    .card-link {
        padding: 12px;
    }
    
    .card-cat {
        font-size: 14px;
    }
    
    .card-text {
        font-size: 11px;
    }
    
    .section-title {
        font-size: 17px;
    }
    
    .section-desc {
        font-size: 12px;
    }
    
    .view-more {
        padding: 5px 10px;
        font-size: 13px;
    }
}

@media (max-width: 280px) {
    /* 推荐卡片 */
    .recommend-grid .isotope-item {
        width: 100%;
        min-height: 250px;
        margin-bottom: 10px;
    }
    
    .recommend-grid::after {
        width: 100%;
    }
    
    .recommend-card {
        margin: 0 0 10px 0;
    }
    
    .card-img {
        height: 140px;
    }
    
    .card-content {
        padding: 12px;
        gap: 8px;
    }
    
    .card-title {
        font-size: 14px;
        margin-bottom: 8px;
    }
    
    .author-avatar {
        width: 24px;
        height: 24px;
    }
    
    .author-name {
        font-size: 12px;
    }
    
    .meta-info {
        top: 8px;
        left: 8px;
        padding: 4px 8px;
        font-size: 11px;
    }
    
    .content-container {
        padding: 0 8px;
    }
    
    /* Tag样式调整 */
    .recommend-card .card-content .project-tags {
        margin-top: 8px;
        padding-top: 8px;
    }
}