/* 本地字体定义 - Space Grotesk (可变字体，包含所有字重) */
@font-face {
  font-family: 'Space Grotesk';
  font-style: normal;
  font-weight: 300 700;
  font-display: swap;
  src: url('../fonts/SpaceGrotesk-400.woff2') format('woff2'),
       url('../fonts/SpaceGrotesk-400.ttf') format('truetype');
}

:root {
    --primary-color: #000;
    --secondary-color: #fff;
    --accent-color: #ff3e00;
    --text-color: #333;
    --light-gray: #f5f5f5;
    --dark-gray: #222;
}

html {
    scroll-behavior: smooth;
    overflow-x: hidden;
    max-width: 100%;
    width: 100%;
}

* {
    box-sizing: border-box;
}

/* 图片懒加载样式 */
.lazy-image {
    background-color: #f0f0f0;
    background-image: linear-gradient(90deg, #f0f0f0 0%, #e0e0e0 50%, #f0f0f0 100%);
    background-size: 200% 100%;
    animation: loading 1.5s ease-in-out infinite;
}

.image-loading {
    opacity: 0.7;
    filter: blur(5px);
    transition: opacity 0.3s, filter 0.3s;
}

.image-loaded {
    opacity: 1;
    filter: blur(0);
    transition: opacity 0.3s, filter 0.3s;
}

.image-error {
    opacity: 0.5;
}

@keyframes loading {
    0% {
        background-position: 200% 0;
    }
    100% {
        background-position: -200% 0;
    }
}

/* 图片优化：防止布局偏移和提升加载性能 */
img {
    /* 使用 GPU 加速 */
    transform: translateZ(0);
    will-change: transform;
    /* 优化图片渲染 */
    image-rendering: -webkit-optimize-contrast;
    image-rendering: crisp-edges;
    /* 防止图片闪烁 */
    backface-visibility: hidden;
    -webkit-backface-visibility: hidden;
    max-width: 100%;
    height: auto;
    display: block;
}

/* 图片容器优化 */
.article-image,
.hero-image,
.magazine-small-card-item img,
.magazine-large-card-item img {
    will-change: transform;
    backface-visibility: hidden;
    transform: translateZ(0);
}

body {
    font-family: 'Space Grotesk', sans-serif;
    color: var(--text-color);
    background-color: var(--secondary-color);
    overflow-x: hidden;
    max-width: 100%;
    width: 100%;
    position: relative;
}

.hero-section {
    height: 100vh;
    position: relative;
    overflow: hidden;
}

/* 首页的hero-section正常显示轮播图 */
.home-page .hero-section {
    background-color: transparent;
}

/* 非首页的hero-section使用淡灰色背景（如果存在） */
.hero-section:not(.home-page .hero-section) {
    background-color: #e5e5e5 !important;
    height: auto !important;
    min-height: auto !important;
    padding-top: 120px !important;
    padding-bottom: 40px !important;
}

.hero-carousel-container {
    width: 100%;
    height: 100%;
}

.hero-carousel-wrapper {
    position: relative;
    width: 100%;
    height: 100%;
}

.hero-slide {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    transition: opacity 0.3s ease-in-out;
    z-index: 1;
}

.hero-slide.active {
    opacity: 1;
    z-index: 2;
}

/* 粒子 Canvas 样式 */
.particle-canvas {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 10;
    pointer-events: none;
    image-rendering: pixelated;
}

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

.hero-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(to bottom, rgba(0,0,0,0.2), rgba(0,0,0,0.7));
    z-index: 2;
}

/* 首页的hero内容使用白色文字 */
.home-page .hero-content-fixed {
    z-index: 10;
    color: white !important;
}

/* 非首页的hero内容使用深色文字 */
.hero-content-fixed {
    z-index: 10;
    color: #333 !important;
}

.hero-content {
    position: absolute;
    bottom: 10%;
    left: 5%;
    color: #333 !important; /* 深色文字以适应淡灰色背景 */
    z-index: 10;
}

.hero-carousel-controls {
    z-index: 10;
}

.hero-carousel-indicators {
    z-index: 10;
}

.carousel-btn {
    cursor: pointer;
    border: none;
    outline: none;
}

.indicator {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background-color: rgba(0, 0, 0, 0.3);
    cursor: pointer;
    transition: background-color 0.3s ease;
}

.indicator.active {
    background-color: rgba(0, 0, 0, 0.7);
}

.hero-title {
    font-size: clamp(2rem, 6vw, 4.5rem);
    font-weight: 400;
    line-height: 1.1;
    margin-bottom: 0.75rem;
    letter-spacing: -1px;
}

.hero-subtitle {
    font-size: clamp(0.95rem, 2.5vw, 1.25rem);
    font-weight: 300;
    margin-bottom: 0;
    max-width: 600px;
    line-height: 1.6;
}

/* Page Header Section (独立于Hero区域) */
.page-header-section {
    position: relative;
    z-index: 1;
    transition: background-color 0.3s ease, border-color 0.3s ease;
}

.page-title {
    font-size: clamp(2.5rem, 6vw, 5rem);
    font-weight: 300;
    line-height: 1.1;
    letter-spacing: -2px;
    color: #111827; /* gray-900 */
}

.page-description {
    font-size: clamp(1rem, 2.5vw, 1.375rem);
    font-weight: 300;
    line-height: 1.7;
    color: #4b5563; /* gray-600 */
    max-width: 700px;
}

/* Navigation bar main container */
.nav-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 100;
    transition: background-color 0.3s ease, box-shadow 0.3s ease;
    background-color: transparent;
    max-width: 100%;
}

/* 移动端导航栏：默认隐藏，向上滑动时显示 */
@media (max-width: 767px) {
    .nav-container {
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        z-index: 100;
        background-color: #000000; /* 黑色背景 */
        transform: translateY(-100%); /* 默认隐藏 */
        transition: transform 0.3s ease, background-color 0.3s ease;
    }
    
    /* 显示导航栏 */
    .nav-container.nav-visible {
        transform: translateY(0);
    }
    
    /* 移动端导航链接和按钮白色 */
    .nav-container .nav-link,
    .nav-container .mobile-menu-btn {
        color: #ffffff; /* 白色字体 */
    }
    
    /* 首页移动端：确保hero-section全屏显示 */
    .home-page .hero-section {
        height: 100vh;
        height: 100dvh; /* 动态视口高度，适配移动端浏览器 */
    }
    
    /* 移动端导航栏滚动后也保持黑色背景 */
    .nav-container.nav-scrolled {
        background-color: #000000 !important; /* 强制黑色背景 */
    }
}

.nav-container.py-4 {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
    max-width: 100%;
}

/* Ensure desktop navigation shows on medium and larger screens */
.hidden.md\:flex {
    display: none;
    gap: 2rem;
    align-items: center;
}

/* Only show on medium and larger screens */
@media (min-width: 768px) {
    .hidden.md\:flex {
        display: flex;
    }
}

/* Mobile menu button */
button.md\:hidden {
    display: block;
}
.nav-scrolled {
    background-color: rgba(255, 255, 255, 0.95);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.nav-scrolled .nav-link {
    color: var(--primary-color);
}

.nav-link {
    position: relative;
    color: var(--secondary-color);
    transition: color 0.3s ease;
    font-weight: 400;
    letter-spacing: 1px;
    text-transform: uppercase;
    font-size: 0.9rem;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 0;
    height: 1px;
    background-color: var(--accent-color);
    transition: width 0.3s ease;
}

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

.mobile-menu-btn {
    color: var(--secondary-color);
    transition: all 0.3s ease;
    background: none;
    border: none;
    cursor: pointer;
    padding: 10px;
    z-index: 100;
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 44px;
    min-height: 44px;
}

.mobile-menu-btn:hover {
    transform: scale(1.1);
}

.nav-scrolled .mobile-menu-btn {
    color: var(--primary-color);
    background-color: rgba(255, 255, 255, 0.9);
    border-radius: 4px;
}

/* 移动端导航栏滚动后保持黑色背景和白色字体 */
@media (max-width: 767px) {
    .nav-container.nav-scrolled {
        background-color: #000000 !important; /* 强制黑色背景 */
    }
    
    .nav-container.nav-scrolled .nav-link,
    .nav-container.nav-scrolled .mobile-menu-btn {
        color: #ffffff !important; /* 强制白色字体 */
    }
    
    .nav-container.nav-scrolled .mobile-menu-btn {
        background-color: transparent; /* 移除白色背景 */
    }
}


.section-title {
    font-size: clamp(2rem, 5vw, 3.5rem);
    font-weight: 300;
    margin-bottom: 3rem;
    letter-spacing: -1px;
    position: relative;
}

.section-title::after {
    content: '';
    position: absolute;
    bottom: -10px;
    left: 0;
    width: 50px;
    height: 2px;
    background-color: var(--accent-color);
}



.article-image {
    width: 100%;
    height: 100%;
    min-height: 280px;
    object-fit: cover;
    transition: transform 0.5s ease;
    display: block;
}

/* Article Card Styles - 统一所有文章类型的样式 */
.article-card {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    width: 100%; /* 默认使用屏幕宽度 */
    max-width: 100%; /* 最大宽度限制 */
    margin-bottom: 30px;
    display: flex;
    flex-direction: column;
    position: relative;
    overflow: hidden;
    height: auto;
    min-height: 600px; /* 设置最小高度确保卡片统一 */
}

/* 统一卡片封面图容器高度 */
.article-card > div:first-child,
.article-card-image {
    height: 280px !important;
    min-height: 280px !important;
    max-height: 280px !important;
    overflow: hidden;
    position: relative;
    flex-shrink: 0;
}

/* 移动端：覆盖固定高度，使用16:9比例 */
@media (max-width: 767px) {
    .article-card > div:first-child,
    .article-card-image {
        height: auto !important;
        min-height: auto !important;
        max-height: none !important;
        aspect-ratio: 16 / 9 !important;
    }
}

/* 卡片内容区域 - 使用flex布局固定元素位置 */
.article-card-content {
    display: flex;
    flex-direction: column;
    flex-grow: 1;
    min-height: 320px; /* 固定内容区域最小高度 */
    padding: 2rem;
}

/* 标题固定高度 - 最多2行（完整行，不显示半行） */
.article-card-title {
    font-size: 1.5rem; /* 24px - text-2xl */
    line-height: 1.4; /* 精确行高，避免半行显示 */
    height: 67.2px; /* 精确计算：24px * 1.4 * 2 = 67.2px */
    min-height: 67.2px;
    max-height: 67.2px;
    overflow: hidden;
    display: -webkit-box;
    -webkit-line-clamp: 2; /* 严格限制2行 */
    -webkit-box-orient: vertical;
    text-overflow: ellipsis;
    margin-bottom: 0.75rem;
    word-break: break-word;
    padding: 0;
    box-sizing: border-box;
}

/* 日期固定位置 */
.article-card-date {
    height: 20px;
    min-height: 20px;
    margin-bottom: 1rem;
    flex-shrink: 0;
}

/* 简介固定高度 - 3行（完整行，不显示半行） */
.article-card-excerpt {
    font-size: 1rem; /* 16px - text-base */
    line-height: 1.5; /* 精确行高，避免半行显示 */
    min-height: 72px; /* 精确计算：16px * 1.5 * 3 = 72px */
    max-height: 72px;
    height: 72px;
    overflow: hidden;
    display: -webkit-box;
    -webkit-line-clamp: 3; /* 严格限制3行 */
    -webkit-box-orient: vertical;
    text-overflow: ellipsis;
    margin-bottom: 1.5rem;
    flex-grow: 1;
    word-break: break-word;
    padding: 0;
    box-sizing: border-box;
}

/* Read more按钮固定在底部 */
.article-card-readmore {
    margin-top: auto;
    padding-top: 1rem;
    flex-shrink: 0;
    height: 32px;
    min-height: 32px;
}

/* 旧的样式已移除，使用新的固定位置样式 */

.article-card {
    cursor: pointer;
    transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1),
                box-shadow 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.article-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
}

/* 点击特效 */
.article-card:active {
    transform: translateY(-2px) scale(0.98);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.15);
}

/* Magazine卡牌点击特效 */
.magazine-small-card-item,
.magazine-large-card-item {
    cursor: pointer;
    transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1),
                box-shadow 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.magazine-small-card-item:active,
.magazine-large-card-item:active {
    transform: translateY(-2px) scale(0.98);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.15);
}

.article-excerpt {
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}



/* 统一容器样式 - 确保所有模块在指定范围内显示 */
#magazine-features-container,
#market-articles-container,
#artant-articles-container,
#events-articles-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
    width: 100%;
    max-width: 100%; /* 适应父容器宽度 */
    margin: 0 auto;
    padding: 0 20px;
}

/* 大屏幕上的布局 */
@media (min-width: 768px) {
    #magazine-features-container,
    #market-articles-container,
    #artant-articles-container,
    #events-articles-container {
        padding: 0 40px;
    }
}

/* 更大屏幕上显示5列 */
@media (min-width: 1200px) {
    #magazine-features-container,
    #market-articles-container,
    #artant-articles-container,
    #events-articles-container {
        grid-template-columns: repeat(5, 1fr);
    }
}

/* 移动端响应式设计 - 确保卡片适应屏幕宽度 */
@media (max-width: 767px) {
    .article-card {
        width: 100% !important; /* 强制使用屏幕宽度 */
        max-width: 100% !important; /* 移除最大宽度限制 */
        margin-left: 0.25rem !important;
        margin-right: 0.25rem !important;
        margin-bottom: 1.5rem !important; /* 增加底部间距 */
        border-radius: 16px !important; /* 更大的圆角 */
        box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08), 
                    0 2px 4px rgba(0, 0, 0, 0.04) !important; /* 更柔和的阴影 */
        background-color: #ffffff !important;
        overflow: hidden;
        transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1),
                    box-shadow 0.3s cubic-bezier(0.4, 0, 0.2, 1) !important;
    }
    
    /* 移动端卡牌悬停效果 */
    .article-card:active {
        transform: scale(0.98) !important;
        box-shadow: 0 2px 8px rgba(0, 0, 0, 0.12),
                    0 1px 2px rgba(0, 0, 0, 0.06) !important;
    }
    
    /* 调整网格容器在移动端的间距 */
    #magazine-features-container,
    #market-articles-container,
    #artant-articles-container,
    #events-articles-container {
        padding: 0 1rem; /* 增加两侧内边距，避免卡牌贴边 */
        gap: 1.5rem !important; /* 增加卡片间距 */
        grid-template-columns: 1fr; /* 单列布局 */
    }
    
    /* 调整文章图片高度适应移动端 - 16:9比例 */
    .article-card-image,
    .article-card > div:first-child {
        height: auto !important;
        min-height: auto !important;
        max-height: none !important;
        aspect-ratio: 16 / 9 !important; /* 16:9比例 */
        border-radius: 16px 16px 0 0 !important; /* 顶部圆角 */
        overflow: hidden;
        position: relative;
    }
    
    /* 覆盖内联样式 */
    .article-card-image[style*="height"],
    .article-card > div:first-child[style*="height"] {
        height: auto !important;
        min-height: auto !important;
    }
    
    /* 图片添加渐变遮罩效果 */
    .article-card-image::after {
        content: '';
        position: absolute;
        bottom: 0;
        left: 0;
        right: 0;
        height: 60px;
        background: linear-gradient(to top, rgba(0, 0, 0, 0.1), transparent);
        pointer-events: none;
    }
    
    /* 图片过渡效果 */
    .article-card-image img {
        transition: transform 0.5s cubic-bezier(0.4, 0, 0.2, 1) !important;
        height: 100% !important;
        width: 100% !important;
        object-fit: cover !important;
    }
    
    .article-card:active .article-card-image img {
        transform: scale(1.05) !important;
    }
    
    /* 确保article-card > div:first-child也应用16:9 */
    .article-card > div:first-child {
        height: auto !important;
        min-height: auto !important;
        max-height: none !important;
        aspect-ratio: 16 / 9 !important;
    }
    
    /* 分类标签美化 */
    .article-card-image .absolute {
        background: rgba(255, 255, 255, 0.95) !important;
        backdrop-filter: blur(10px);
        -webkit-backdrop-filter: blur(10px);
        border-radius: 20px !important;
        padding: 0.5rem 1rem !important;
        box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
        font-weight: 600 !important;
        letter-spacing: 0.5px;
    }
    
    /* 调整卡片内容内边距 - 增加左右内边距避免文字贴边 */
    .article-card-content {
        padding: 1.5rem 1.25rem !important; /* 增加左右内边距 */
        min-height: auto !important; /* 移除固定最小高度，让内容自然流动 */
        background: linear-gradient(to bottom, #ffffff, #fafafa);
    }
    
    /* 覆盖Tailwind的p-8类在移动端的表现 */
    .article-card-content.p-8 {
        padding: 1.5rem 1.25rem !important;
    }
    
    /* 移动端通用grid容器间距 - 适用于category.html等页面 */
    .grid.grid-cols-1 {
        padding-left: 0.5rem !important;
        padding-right: 0.5rem !important;
    }
    
    /* category.html 等页面的容器也需要间距 - 确保左右对称 */
    .category-section {
        padding-left: 0.5rem !important;
        padding-right: 0.5rem !important;
    }
    
    /* 覆盖Tailwind的px-6类在移动端 */
    .category-section.px-6 {
        padding-left: 0.5rem !important;
        padding-right: 0.5rem !important;
    }
    
    .category-section .grid,
    [id$="-container"].grid {
        padding-left: 0 !important; /* 移除grid的padding，由category-section统一控制 */
        padding-right: 0 !important;
    }
    
    /* article-detail.html 相关文章卡片移动端间距 */
    .related-articles-grid {
        padding-left: 0.5rem !important;
        padding-right: 0.5rem !important;
    }
    
    .related-article-card {
        margin-left: 0.5rem !important;
        margin-right: 0.5rem !important;
    }
    
    /* 移动端标题高度 - 2行完整显示 */
    .article-card-title {
        font-size: 1.25rem !important; /* 20px */
        line-height: 1.4 !important;
        height: 56px !important; /* 20px * 1.4 * 2 = 56px */
        min-height: 56px !important;
        max-height: 56px !important;
        -webkit-line-clamp: 2 !important;
        font-weight: 700 !important; /* 更粗的字体 */
        color: #1a1a1a !important; /* 更深的颜色 */
        letter-spacing: -0.3px; /* 稍微收紧字距 */
        margin-bottom: 0.75rem !important;
    }
    
    /* 移动端日期样式优化 */
    .article-card-date {
        font-size: 0.8125rem !important; /* 13px */
        color: #6b7280 !important;
        font-weight: 500 !important;
        letter-spacing: 0.2px;
        margin-bottom: 1rem !important;
    }
    
    /* 移动端卡牌内容区域高度调整 */
    .article-card-content {
        min-height: auto !important; /* 移除固定高度，让内容自然流动 */
        max-height: none !important;
        height: auto !important;
    }
    
    /* 移动端简介高度 - 3行完整显示 */
    .article-card-excerpt {
        font-size: 0.9375rem !important; /* 15px */
        line-height: 1.6 !important; /* 增加行高提升可读性 */
        min-height: 72px !important; /* 15px * 1.6 * 3 = 72px */
        max-height: 72px !important;
        height: 72px !important;
        -webkit-line-clamp: 3 !important;
        color: #4b5563 !important; /* 稍微深一点的灰色 */
        /* 保持Tailwind的mb-6，不覆盖 */
    }
    
    /* Read more按钮美化 - 保持Tailwind的mt-auto */
    .article-card-readmore {
        /* 保持Tailwind的mt-auto，不覆盖 */
        padding-top: 0 !important; /* 移除上边距 */
    }
    
    .article-card-readmore a {
        display: inline-flex !important;
        align-items: center !important;
        font-weight: 600 !important;
        font-size: 0.9375rem !important; /* 15px */
        padding: 0.625rem 1rem !important;
        border-radius: 8px !important;
        transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1) !important;
        background-color: rgba(0, 0, 0, 0.03) !important;
    }
    
    .article-card-readmore a:hover,
    .article-card-readmore a:active {
        background-color: rgba(0, 0, 0, 0.08) !important;
        transform: translateX(4px) !important;
    }
    
    .article-card-readmore a svg {
        transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1) !important;
    }
    
    .article-card-readmore a:hover svg,
    .article-card-readmore a:active svg {
        transform: translateX(4px) !important;
    }
    
    /* 调整文章摘要显示行数 */
    .article-card .card-body .article-excerpt {
        height: 72px; /* 调整高度适应3行 */
        -webkit-line-clamp: 3;
    }
    
    /* Magazine小卡牌移动端美化 - 与article-card保持一致 */
    .magazine-small-card-item {
        border-radius: 16px !important;
        box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08), 
                    0 2px 4px rgba(0, 0, 0, 0.04) !important;
        margin-left: 0.25rem !important;
        margin-right: 0.25rem !important;
        margin-bottom: 1.5rem !important;
        overflow: hidden;
        transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1),
                    box-shadow 0.3s cubic-bezier(0.4, 0, 0.2, 1) !important;
    }
    
    .magazine-small-card-item:active {
        transform: scale(0.98) !important;
        box-shadow: 0 2px 8px rgba(0, 0, 0, 0.12),
                    0 1px 2px rgba(0, 0, 0, 0.06) !important;
    }
    
    /* Magazine小卡牌图片容器 */
    .magazine-small-card-item > div:first-child,
    .magazine-small-card-item .relative.overflow-hidden {
        height: auto !important;
        min-height: auto !important;
        aspect-ratio: 16 / 9 !important; /* 16:9比例 */
    }
    
    .magazine-small-card-item img {
        border-radius: 16px 16px 0 0 !important;
        transition: transform 0.5s cubic-bezier(0.4, 0, 0.2, 1) !important;
        height: 100% !important;
        width: 100% !important;
        object-fit: cover !important;
    }
    
    /* 覆盖内联样式 */
    .magazine-small-card-item > div:first-child[style*="height"],
    .magazine-small-card-item .relative.overflow-hidden[style*="height"] {
        height: auto !important;
        min-height: auto !important;
    }
    
    .magazine-small-card-item:active img {
        transform: scale(1.05) !important;
    }
    
    /* Magazine大卡牌移动端美化 */
    .magazine-large-card-item {
        border-radius: 16px !important;
        box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08), 
                    0 2px 4px rgba(0, 0, 0, 0.04) !important;
        margin-left: 0.25rem !important;
        margin-right: 0.25rem !important;
        margin-bottom: 1.5rem !important;
        overflow: visible !important; /* 改为visible，确保内容不被裁剪 */
        transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1),
                    box-shadow 0.3s cubic-bezier(0.4, 0, 0.2, 1) !important;
    }
    
    .magazine-large-card-item:active {
        transform: scale(0.98) !important;
        box-shadow: 0 2px 8px rgba(0, 0, 0, 0.12),
                    0 1px 2px rgba(0, 0, 0, 0.06) !important;
    }
    
    /* Magazine大卡牌移动端grid布局优化 */
    .magazine-large-card-item .grid {
        display: flex !important;
        flex-direction: column !important; /* 移动端垂直排列 */
    }
    
    /* Magazine大卡牌图片容器 */
    .magazine-large-card-item > .grid > div:first-child,
    .magazine-large-card-item .relative.overflow-hidden {
        height: auto !important;
        min-height: auto !important;
        max-height: none !important;
        aspect-ratio: 16 / 9 !important; /* 16:9比例 */
        overflow: hidden; /* 图片容器保持hidden */
    }
    
    /* Magazine大卡牌内容区域移动端优化 */
    .magazine-large-card-item .p-8 {
        padding: 1.5rem 1.25rem !important; /* 减少移动端padding */
        min-height: auto !important;
        max-height: none !important;
        justify-content: flex-start !important; /* 改为顶部对齐，不要居中 */
    }
    
    /* Magazine大卡牌标题移动端优化 */
    .magazine-large-card-item h3 {
        font-size: 1.25rem !important; /* 移动端标题大小 */
        line-height: 1.4 !important;
        margin-bottom: 0.75rem !important;
        display: -webkit-box;
        -webkit-line-clamp: 3; /* 最多3行 */
        -webkit-box-orient: vertical;
        overflow: hidden;
        text-overflow: ellipsis;
    }
    
    /* Magazine大卡牌日期移动端优化 */
    .magazine-large-card-item .text-sm {
        font-size: 0.8125rem !important;
        margin-bottom: 0.75rem !important;
    }
    
    /* Magazine大卡牌简介移动端优化 */
    .magazine-large-card-item .line-clamp-4 {
        font-size: 0.9375rem !important;
        line-height: 1.6 !important;
        margin-bottom: 0 !important; /* 移除底部margin */
        -webkit-line-clamp: 3 !important; /* 移动端显示3行 */
    }
    
    .magazine-large-card-item img {
        border-radius: 16px 16px 0 0 !important;
        transition: transform 0.5s cubic-bezier(0.4, 0, 0.2, 1) !important;
        height: 100% !important;
        width: 100% !important;
        object-fit: cover !important;
    }
    
    /* 覆盖内联样式 */
    .magazine-large-card-item > div:first-child[style*="height"],
    .magazine-large-card-item .relative.overflow-hidden[style*="height"],
    .magazine-large-card-item > div:first-child[style*="min-height"],
    .magazine-large-card-item .relative.overflow-hidden[style*="min-height"] {
        height: auto !important;
        min-height: auto !important;
    }
    
    .magazine-large-card-item:active img {
        transform: scale(1.05) !important;
    }
    
    /* 相关文章卡牌移动端美化 */
    .related-article-card {
        border-radius: 16px !important;
        box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08), 
                    0 2px 4px rgba(0, 0, 0, 0.04) !important;
        margin-left: 0.5rem !important;
        margin-right: 0.5rem !important;
        margin-bottom: 1.5rem !important;
        overflow: hidden;
        background-color: #ffffff !important;
        transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1),
                    box-shadow 0.3s cubic-bezier(0.4, 0, 0.2, 1) !important;
    }
    
    .related-article-card:active {
        transform: scale(0.98) !important;
        box-shadow: 0 2px 8px rgba(0, 0, 0, 0.12),
                    0 1px 2px rgba(0, 0, 0, 0.06) !important;
    }
    
    .related-article-image {
        border-radius: 16px 16px 0 0 !important;
        transition: transform 0.5s cubic-bezier(0.4, 0, 0.2, 1) !important;
        height: auto !important;
        aspect-ratio: 16 / 9 !important; /* 16:9比例 */
    }
    
    .related-article-card:active .related-article-image {
        transform: scale(1.05) !important;
    }
    
    .related-article-title {
        font-weight: 700 !important;
        color: #1a1a1a !important;
        letter-spacing: -0.3px;
        font-size: 1.125rem !important;
        line-height: 1.4 !important;
    }
    
    .related-article-date {
        font-size: 0.8125rem !important;
        color: #6b7280 !important;
        font-weight: 500 !important;
        letter-spacing: 0.2px;
    }
}



.exhibition-card {
    position: relative;
    overflow: hidden;
    cursor: pointer;
}

.exhibition-image {
    width: 100%;
    height: 400px;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.exhibition-card:hover .exhibition-image {
    transform: scale(1.02);
}

.exhibition-info {
    padding: 1.5rem;
}

.exhibition-date {
    font-size: 0.9rem;
    color: var(--accent-color);
    margin-bottom: 0.5rem;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.exhibition-title {
    font-size: 1.5rem;
    font-weight: 500;
    margin-bottom: 0.5rem;
}

.exhibition-location {
    font-size: 1rem;
    font-weight: 300;
    color: var(--text-color);
}

.artist-card {
    position: relative;
    overflow: hidden;
    cursor: pointer;
}

.artist-image {
    width: 100%;
    height: 300px;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.artist-card:hover .artist-image {
    transform: scale(1.02);
}

.artist-info {
    padding: 1.5rem;
}

.artist-name {
    font-size: 1.5rem;
    font-weight: 500;
    margin-bottom: 0.5rem;
}

.artist-nationality {
    font-size: 1rem;
    font-weight: 300;
    color: var(--text-color);
}


/* Animation classes */
.fade-in {
    opacity: 0;
    animation: fadeIn 1s ease forwards;
}

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


/* Custom scrollbar */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: var(--light-gray);
}

::-webkit-scrollbar-thumb {
    background: var(--dark-gray);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--primary-color);
}

/* Responsive design */
@media (max-width: 768px) {
    .nav-links {
        display: none;
    }
    
    .mobile-menu-btn {
        display: block;
    }
    
    .artwork-grid {
        grid-template-columns: 1fr;
    }
    
    .exhibitions-grid {
        grid-template-columns: 1fr;
    }
    
    .artists-grid {
        grid-template-columns: 1fr;
    }
    
    .hero-content {
        bottom: 20%;
        left: 10%;
        right: 10%; /* 添加右边距防止内容贴边 */
    }
    
    /* 优化hero区域按钮在小屏幕下的显示 */
    .hero-content .flex {
        gap: 1rem; /* 确保按钮之间有足够间距 */
    }
    
    .hero-content a {
        min-width: 140px; /* 设置最小宽度确保按钮可读性 */
        font-size: 0.75rem; /* 稍微减小字体大小 */
    }
}

/* 针对超小屏幕的额外优化 */
@media (max-width: 480px) {
    .hero-content {
        bottom: 15%;
        left: 5%;
        right: 5%;
    }
    
    .hero-content .flex {
        gap: 0.75rem;
    }
    
    .hero-content a {
        min-width: 120px;
        padding: 0.75rem 1rem; /* 调整内边距 */
        font-size: 0.7rem;
    }
}

/* Magazine Section - New Design Styles (Full Width) */
#magazine {
    width: 100%;
    max-width: 100%;
}

.magazine-small-card {
    position: relative;
    min-height: 520px;
    width: 100%;
}

.magazine-small-card-item {
    height: 100%;
    min-height: 520px;
    display: flex;
    flex-direction: column;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    border: 1px solid #e5e7eb;
    position: relative;
    background: white;
    width: 100%;
}

.magazine-small-card-item:hover {
    transform: translateY(-4px);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
}

.magazine-small-card-item img {
    width: 100%;
    height: 360px;
    min-height: 360px;
    object-fit: cover;
    display: block;
}

.magazine-large-card {
    position: relative;
    width: 100%;
}

.magazine-large-card-item {
    border: 1px solid #e5e7eb;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    position: relative;
    width: 100%;
    background: white;
}

.magazine-large-card-item:hover {
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.15);
}

/* Ensure full width on all screen sizes */
#magazine-top-row,
#magazine-bottom-row {
    width: 100%;
    max-width: 100%;
}

/* Line clamp utilities */
.line-clamp-2 {
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.line-clamp-3 {
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.line-clamp-4 {
    display: -webkit-box;
    -webkit-line-clamp: 4;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* Responsive adjustments for Magazine section */
@media (max-width: 768px) {
    #magazine .section-title {
        font-size: 1.5rem;
    }
    
    .magazine-large-card-item .grid {
        grid-template-columns: 1fr !important;
    }
    
    .magazine-large-card-item .p-8 {
        padding: 1.5rem;
    }
    
    .magazine-large-card-item h3 {
        font-size: 1.5rem;
    }
    
    #magazine {
        padding-left: 0.5rem !important;
        padding-right: 0.5rem !important;
    }
    
    /* 移动端首页magazine容器减少padding */
    #magazine-top-row,
    #magazine-bottom-row {
        padding-left: 0.5rem !important;
        padding-right: 0.5rem !important;
    }
    
    /* 覆盖Tailwind的px-6类在移动端 */
    #magazine-top-row.px-6,
    #magazine-bottom-row.px-6 {
        padding-left: 0.5rem !important;
        padding-right: 0.5rem !important;
    }
    
    /* 移动端magazine卡片减少左右间距 */
    .magazine-small-card-item,
    .magazine-large-card-item {
        margin-left: 0.25rem !important;
        margin-right: 0.25rem !important;
    }
    
    /* 移动端magazine卡片内容区域增加内边距 */
    .magazine-small-card-item .p-6,
    .magazine-large-card-item .p-8 {
        padding-left: 1.25rem !important;
        padding-right: 1.25rem !important;
    }
}

/* Footer移动端样式优化 */
@media (max-width: 767px) {
    /* Footer整体padding优化 */
    footer.bg-gray-900,
    footer.bg-black {
        padding-top: 3rem !important;
        padding-bottom: 2rem !important;
        padding-left: 1rem !important;
        padding-right: 1rem !important;
    }
    
    /* Footer容器padding优化 */
    footer .container {
        padding-left: 0.5rem !important;
        padding-right: 0.5rem !important;
    }
    
    /* Footer grid间距优化 */
    footer .grid {
        gap: 2.5rem !important;
    }
    
    /* Footer标题字体大小优化 */
    footer h3 {
        font-size: 1.125rem !important; /* 18px */
        margin-bottom: 1rem !important;
        font-weight: 600 !important;
    }
    
    /* Footer段落和链接字体大小优化 */
    footer p,
    footer li,
    footer a {
        font-size: 0.9375rem !important; /* 15px */
        line-height: 1.6 !important;
    }
    
    /* Footer链接列表横向排列 - 移动端 */
    footer ul.space-y-2 {
        display: flex !important;
        flex-wrap: wrap !important;
        gap: 0.75rem 1rem !important; /* 行间距0.75rem，列间距1rem */
        margin: 0 !important;
        padding: 0 !important;
    }
    
    footer ul.space-y-2 li {
        margin: 0 !important;
        padding: 0 !important;
        list-style: none !important;
        white-space: nowrap; /* 防止链接文字换行 */
    }
    
    /* Footer链接可点击区域优化 */
    footer ul li a,
    footer .space-y-2 a {
        display: inline-flex;
        align-items: center;
        padding: 0.5rem 0.75rem !important;
        min-height: 44px; /* 确保可点击区域足够大 */
        white-space: nowrap; /* 防止链接文字换行 */
    }
    
    /* Footer社交媒体图标优化 */
    footer .flex.space-x-4 {
        gap: 1rem !important;
        margin-top: 1rem !important;
    }
    
    footer .flex.space-x-4 a {
        min-width: 44px;
        min-height: 44px;
        display: flex;
        align-items: center;
        justify-content: center;
        padding: 0.5rem !important;
    }
    
    footer .flex.space-x-4 i {
        font-size: 1.25rem !important; /* 20px */
    }
    
    /* Footer联系信息优化 */
    footer .space-y-2 p {
        margin-bottom: 0.5rem !important;
        line-height: 1.5 !important;
    }
    
    /* Footer底部版权信息优化 */
    footer .border-t {
        margin-top: 2rem !important;
        padding-top: 1.5rem !important;
        padding-bottom: 0 !important;
    }
    
    footer .border-t p {
        font-size: 0.875rem !important; /* 14px */
        line-height: 1.5 !important;
    }
    
    /* Footer "Follow Us"标题优化 */
    footer h4 {
        font-size: 1rem !important; /* 16px */
        margin-bottom: 0.75rem !important;
        margin-top: 1.5rem !important;
    }
}

/* Large screens - maximize visual impact */
@media (min-width: 1920px) {
    #magazine-top-row,
    #magazine-bottom-row {
        padding-left: 5rem;
        padding-right: 5rem;
    }
}