/* 修复模态框样式，确保只能通过X关闭 */
.modal {
    display: none; /* 默认隐藏所有模态框 */
    position: fixed;
    z-index: 9999;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.7);
    /* 确保点击事件有效 */
    pointer-events: auto;
}

.modal-content {
    position: relative;
    background-color: #fff;
    margin: 10% auto;
    padding: 30px;
    border-radius: 8px;
    width: 90%;
    max-width: 500px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
    /* 允许在内容区域点击 */
    pointer-events: auto;
}

.close {
    position: absolute;
    top: 15px;
    right: 20px;
    font-size: 24px;
    cursor: pointer;
    color: #aaa;
    transition: all 0.3s ease;
    /* 确保关闭按钮可点击 */
    pointer-events: auto;
    z-index: 1200;
}

.close:hover {
    color: #333;
}

/* 手机屏幕上的模态框样式调整 */
@media (max-width: 768px) {
    .modal-content, .vip-content-modal .modal-content, .vip-channel-modal-content {
        width: 80%; /* 减少到原来宽度的五分之四（80%） */
        padding: 25px 20px;
        margin: 15% auto;
        max-width: 85%; /* 确保在小屏幕上不会太宽 */
    }
    
    .close, .vip-channel-modal-close {
        top: 10px;
        right: 12px; /* 调整关闭按钮位置，使其更容易点击 */
        font-size: 28px; /* 增大字体使按钮更易点击 */
        padding: 6px 10px; /* 增加点击区域 */
        background-color: rgba(255, 255, 255, 0.2); /* 添加轻微背景色增强可见度 */
        border-radius: 50%; /* 圆形按钮更容易触摸 */
    }
    
    .vip-channel-modal-content {
        max-height: 80vh; /* 在手机上限制高度 */
    }
}

/* =============== 全新导航条样式 =============== */
.navbar {
    background: linear-gradient(90deg, #1e0f4d 0%, #3c1080 50%, #531eb6 100%) !important;
    padding: 18px 0 !important;
    box-shadow: 0 5px 25px rgba(83, 30, 182, 0.5) !important;
    position: sticky;
    top: 0;
    z-index: 1000;
    border-bottom: 2px solid rgba(255, 255, 255, 0.1);
    animation: navbarGlow 4s infinite alternate;
}

@keyframes navbarGlow {
    0% { box-shadow: 0 5px 25px rgba(83, 30, 182, 0.5); }
    100% { box-shadow: 0 5px 35px rgba(127, 53, 250, 0.8); }
}

.nav-container {
    max-width: 1400px !important;
    padding: 0 30px !important;
}

.logo {
    font-size: 32px !important;
    font-weight: 900 !important;
    background: linear-gradient(90deg, #ffcc00, #ff6b6b, #fc85ae) !important;
    -webkit-background-clip: text !important;
    -webkit-text-fill-color: transparent !important;
    text-shadow: 0 0 15px rgba(255, 200, 0, 0.4) !important;
    animation: logoGlow 3s infinite alternate !important;
    letter-spacing: 1px;
    position: relative;
}

.logo::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 100%;
    height: 3px;
    background: linear-gradient(90deg, #ffcc00, #ff6b6b, #fc85ae);
    border-radius: 3px;
    animation: borderAnim 2s infinite alternate;
}

@keyframes borderAnim {
    0% { width: 0; opacity: 0.5; left: 0; }
    100% { width: 100%; opacity: 1; left: 0; }
}

@keyframes logoGlow {
    0% { text-shadow: 0 0 15px rgba(255, 200, 0, 0.2); }
    100% { text-shadow: 0 0 25px rgba(255, 200, 0, 0.5); }
}

.nav-buttons {
    gap: 20px !important;
}

.login-btn, .register-btn {
    padding: 12px 30px !important;
    border-radius: 50px !important;
    font-size: 17px !important;
    font-weight: 700 !important;
    letter-spacing: 0.5px;
    position: relative;
    overflow: hidden;
    z-index: 1;
    transition: all 0.4s cubic-bezier(0.2, 0.8, 0.2, 1.2) !important;
}

.login-btn {
    background: transparent !important;
    border: 2px solid #c896ff !important;
    color: #fff !important;
    box-shadow: 0 0 20px rgba(200, 150, 255, 0.3) !important;
}

.login-btn:hover {
    background: rgba(200, 150, 255, 0.15) !important;
    border-color: #e2c6ff !important;
    transform: translateY(-3px) scale(1.03) !important;
    box-shadow: 0 8px 25px rgba(200, 150, 255, 0.4) !important;
}

.register-btn {
    background: linear-gradient(45deg, #ff6b6b, #ff9e9e, #ff6b6b) !important;
    background-size: 200% 200% !important;
    color: #fff !important;
    border: none !important;
    box-shadow: 0 5px 20px rgba(255, 107, 107, 0.4) !important;
    animation: gradientBg 3s ease infinite !important;
}

.register-btn:hover {
    transform: translateY(-3px) scale(1.05) !important;
    box-shadow: 0 10px 30px rgba(255, 107, 107, 0.5) !important;
}

@keyframes gradientBg {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

.login-btn::before, .register-btn::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(255,255,255,0.3) 0%, rgba(255,255,255,0) 60%);
    transform: rotate(45deg);
    transition: all 0.5s ease;
    z-index: -1;
}

.login-btn:hover::before, .register-btn:hover::before {
    transform: rotate(45deg) translate(10%, 10%);
}

.user-info {
    background: rgba(200, 150, 255, 0.15) !important;
    border: 1px solid rgba(200, 150, 255, 0.3) !important;
    padding: 10px 25px !important;
    border-radius: 50px !important;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.2) !important;
    backdrop-filter: blur(10px) !important;
}

.username {
    font-size: 16px !important;
    font-weight: 700 !important;
    background: linear-gradient(90deg, #ffcc00, #ff6b6b) !important;
    -webkit-background-clip: text !important;
    -webkit-text-fill-color: transparent !important;
    margin-right: 15px !important;
}

.logout-btn {
    background: linear-gradient(45deg, #ff6b6b, #ff9e9e) !important;
    padding: 8px 22px !important;
    border-radius: 50px !important;
    font-size: 15px !important;
    font-weight: 700 !important;
    box-shadow: 0 4px 12px rgba(255, 107, 107, 0.3) !important;
}

.logout-btn:hover {
    transform: translateY(-2px) !important;
    box-shadow: 0 6px 18px rgba(255, 107, 107, 0.4) !important;
}

/* =============== VIP广告区样式增强 =============== */
.vip-section {
    padding: 60px 0 !important;
    background: linear-gradient(135deg, #1a1c2c, #2d3250) !important;
    text-align: center;
    position: relative;
    overflow: hidden;
    display: flex;
    justify-content: center;
    align-items: center;
}

.vip-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: 
        radial-gradient(circle at 20% 30%, rgba(150, 60, 255, 0.15) 0%, transparent 50%),
        radial-gradient(circle at 80% 70%, rgba(255, 107, 107, 0.1) 0%, transparent 50%);
    pointer-events: none;
}

.vip-container {
    max-width: 1300px;
    position: relative;
    z-index: 2;
    width: 100%;
    margin: 0 auto;
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 0 20px;
}

.vip-header {
    margin-bottom: 50px;
    text-align: center;
    width: 100%;
}

.vip-header h2 {
    font-size: 42px !important;
    font-weight: 900 !important;
    color: #fff !important;
    margin-bottom: 15px !important;
    text-shadow: 0 0 30px rgba(255, 200, 0, 0.4) !important;
    position: relative;
    display: inline-block;
}

.vip-header h2::after {
    content: '';
    position: absolute;
    bottom: -10px;
    left: 50%;
    transform: translateX(-50%);
    width: 100px;
    height: 4px;
    background: linear-gradient(90deg, #ffcc00, #ff6b6b);
    border-radius: 4px;
}

.vip-tagline {
    font-size: 22px !important;
    color: #c8c8ee !important;
    margin-top: 20px !important;
}

.vip-cards {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 60px;
    perspective: 1000px;
    margin: 0 auto;
    text-align: center;
    width: 100%;
    flex-wrap: nowrap;
    max-width: none;
}

.vip-card {
    background: rgba(255, 255, 255, 0.05) !important;
    backdrop-filter: blur(5px) !important;
    border-radius: 20px !important;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3) !important;
    padding: 40px 30px !important;
    width: 350px !important;
    transition: all 0.5s cubic-bezier(0.2, 0.8, 0.2, 1) !important;
    border: 1px solid rgba(255, 255, 255, 0.1) !important;
    transform-style: preserve-3d;
    position: relative;
    margin: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    flex-shrink: 0;
}

.vip-card.basic {
    background: linear-gradient(135deg, rgba(255, 167, 38, 0.1), rgba(245, 124, 0, 0.05)) !important;
    border: 1px solid rgba(255, 167, 38, 0.2) !important;
    width: 262.5px !important;
}

.vip-card.premium {
    background: linear-gradient(135deg, rgba(255, 215, 0, 0.1), rgba(255, 140, 0, 0.05)) !important;
    border: 1px solid rgba(255, 215, 0, 0.2) !important;
    transform: scale(1.05);
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.4) !important;
    width: 262.5px !important;
}

.vip-card::before {
    content: '';
    position: absolute;
    top: -10px;
    left: -10px;
    right: -10px;
    bottom: -10px;
    background: linear-gradient(135deg, transparent 50%, rgba(255, 255, 255, 0.05) 100%);
    border-radius: 25px;
    z-index: -1;
    opacity: 0;
    transition: opacity 0.5s ease;
}

.vip-card:hover {
    transform: translateY(-15px) rotateX(5deg) rotateY(-5deg) !important;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.4) !important;
}

.vip-card.premium:hover {
    transform: translateY(-15px) rotateX(5deg) rotateY(-5deg) scale(1.05) !important;
}

.vip-card:hover::before {
    opacity: 1;
}

/* 确保卡片内的所有内容居中 */
.vip-card .card-header {
    margin-bottom: 30px !important;
    padding-bottom: 20px !important;
    padding-top: 15px !important;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1) !important;
    text-align: center;
    width: 100%;
}

.vip-card h3 {
    font-size: 28px !important;
    font-weight: 800 !important;
    margin-bottom: 15px !important;
}

.vip-card.basic h3 {
    color: #FFA726 !important;
    text-shadow: 0 0 10px rgba(255, 167, 38, 0.4) !important;
}

.vip-card.premium h3 {
    color: #FFD700 !important;
    text-shadow: 0 0 15px rgba(255, 215, 0, 0.5) !important;
}

.vip-card .price {
    font-size: 48px !important;
    font-weight: 900 !important;
    position: relative;
    display: inline-block;
}

.vip-card.basic .price {
    color: #FFA726 !important;
}

.vip-card.premium .price {
    color: #FFD700 !important;
    animation: priceGlow 3s infinite alternate;
}

@keyframes priceGlow {
    0% { text-shadow: 0 0 10px rgba(255, 215, 0, 0.3); }
    100% { text-shadow: 0 0 20px rgba(255, 215, 0, 0.5); }
}

.vip-card .price::before {
    content: '¥';
    font-size: 30px;
    vertical-align: super;
}

.vip-card .features {
    text-align: center;
    margin-bottom: 0;
    min-height: 170px;
    padding-left: 0;
    width: 100%;
}

.vip-card .features li {
    margin-bottom: 15px !important;
    color: #e0e0ff !important;
    font-size: 16px !important;
    list-style: none;
    position: relative;
    padding-left: 30px;
    text-align: left;
    display: inline-block;
}

.vip-card .features li::before {
    content: '•';
    position: absolute;
    left: 0;
    top: 0;
    font-size: 18px;
    font-weight: bold;
    color: #4CAF50;
}

.vip-card .features li.disabled {
    color: rgba(224, 224, 255, 0.5) !important;
}

.vip-card .features li.disabled::before {
    content: '×';
    color: #ff4757;
}

.vip-card .vip-btn {
    padding: 15px 30px !important;
    font-size: 18px !important;
    font-weight: 800 !important;
    text-transform: uppercase;
    letter-spacing: 1px;
    border-radius: 50px !important;
    position: relative;
    overflow: hidden;
    transition: all 0.5s cubic-bezier(0.2, 0.8, 0.2, 1) !important;
    width: auto !important;
    min-width: 180px !important;
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.4) !important;
    margin-top: -25px !important;
    margin-bottom: 12px !important;
    transform: scale(1);
    border: 3px solid rgba(255, 255, 255, 0.5) !important;
    text-shadow: 0 1px 3px rgba(0, 0, 0, 0.3) !important;
    animation: buttonPulse 2s infinite alternate;
}

@keyframes buttonPulse {
    0% { transform: scale(1); box-shadow: 0 8px 20px rgba(0, 0, 0, 0.4); }
    100% { transform: scale(1.05); box-shadow: 0 12px 30px rgba(0, 0, 0, 0.6); }
}

.vip-card .vip-btn.basic-btn {
    background: linear-gradient(45deg, #FFA726, #F57C00) !important;
    color: white !important;
    border: 3px solid rgba(255, 167, 38, 0.7) !important;
}

.vip-card .vip-btn.premium-btn {
    background: linear-gradient(45deg, #FFD700, #FF8C00) !important;
    color: white !important;
    border: 3px solid rgba(255, 215, 0, 0.7) !important;
    animation: premiumBtnGlow 3s infinite alternate;
}

@keyframes premiumBtnGlow {
    0% { box-shadow: 0 8px 20px rgba(0, 0, 0, 0.3), 0 0 5px rgba(255, 215, 0, 0.5); }
    100% { box-shadow: 0 12px 30px rgba(0, 0, 0, 0.4), 0 0 20px rgba(255, 215, 0, 0.8); }
}

.vip-card .vip-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.5), transparent);
    transition: 0.6s;
}

.vip-card .vip-btn:hover {
    transform: translateY(-5px) scale(1.08) !important;
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.5) !important;
    border-color: rgba(255, 255, 255, 0.8) !important;
}

.vip-card .vip-btn.basic-btn:hover {
    border-color: rgba(255, 167, 38, 0.9) !important;
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.5), 0 0 15px rgba(255, 167, 38, 0.5) !important;
}

.vip-card .vip-btn.premium-btn:hover {
    border-color: rgba(255, 215, 0, 0.9) !important;
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.5), 0 0 25px rgba(255, 215, 0, 0.7) !important;
}

.vip-card .vip-btn:hover::before {
    left: 100%;
}

/* 添加按钮内的闪光效果 */
.vip-card .vip-btn::after {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(255,255,255,0.3) 0%, rgba(255,255,255,0) 60%);
    transform: scale(0);
    transition: transform 0.8s ease-out;
    z-index: -1;
    opacity: 0;
}

.vip-card .vip-btn:hover::after {
    transform: scale(1);
    opacity: 0.3;
}

.vip-card.premium::after {
    content: '推荐';
    position: absolute;
    top: -12px;
    right: 30px;
    background: linear-gradient(45deg, #FFD700, #FF8C00);
    color: white;
    padding: 5px 15px;
    font-size: 14px;
    font-weight: bold;
    border-radius: 20px;
    box-shadow: 0 5px 15px rgba(255, 215, 0, 0.3);
}

/* VIP标识样式 */
.vip-badge {
    display: inline-block;
    padding: 3px 8px;
    margin-right: 5px;
    border-radius: 10px;
    font-size: 12px;
    font-weight: bold;
    color: white;
    vertical-align: middle;
}

.vip-badge.basic {
    background: linear-gradient(135deg, #FFA726, #F57C00);
    border: 1px solid #FFA726;
    box-shadow: 0 0 5px rgba(255, 167, 38, 0.5);
}

.vip-badge.premium {
    background: linear-gradient(135deg, #FFD700, #FF8C00);
    border: 1px solid #FFD700;
    box-shadow: 0 0 8px rgba(255, 215, 0, 0.7);
    animation: golden-pulse 2s infinite;
}

/* 在用户信息区域显示时的特殊样式 */
.user-info .vip-badge {
    transform: scale(1.1);
    vertical-align: middle;
    margin-right: 8px;
    box-shadow: 0 0 10px rgba(255, 215, 0, 0.5);
    position: relative;
    /* 增加3D效果 */
    text-shadow: 0 1px 0 rgba(0, 0, 0, 0.2);
    border: 1px solid rgba(255, 255, 255, 0.3);
}

.user-info .vip-badge.basic {
    background: linear-gradient(135deg, #FFA726, #F57C00);
    animation: badge-glow-basic 3s infinite alternate;
}

.user-info .vip-badge.premium {
    background: linear-gradient(135deg, #FFD700, #FF8C00);
    animation: badge-glow-premium 3s infinite alternate;
}

@keyframes badge-glow-basic {
    0% { box-shadow: 0 0 5px rgba(255, 167, 38, 0.5); }
    100% { box-shadow: 0 0 12px rgba(255, 167, 38, 0.8); }
}

@keyframes badge-glow-premium {
    0% { box-shadow: 0 0 8px rgba(255, 215, 0, 0.7); }
    50% { box-shadow: 0 0 15px rgba(255, 215, 0, 0.9); }
    100% { box-shadow: 0 0 8px rgba(255, 215, 0, 0.7); }
}

@keyframes golden-pulse {
    0% { box-shadow: 0 0 5px rgba(255, 215, 0, 0.7); }
    50% { box-shadow: 0 0 15px rgba(255, 215, 0, 0.9); }
    100% { box-shadow: 0 0 5px rgba(255, 215, 0, 0.7); }
}


.vip-single-image:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.4);
}

.vip-single-image img {
    max-width: 100%;
    height: auto;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
    margin-bottom: 15px;
    display: block;
    margin-left: auto;
    margin-right: auto;
}

.vip-image-caption {
    padding: 15px 10px;
    text-align: center;
}

.vip-image-caption h3 {
    color: #fff;
    font-size: 24px;
    margin-bottom: 10px;
    text-shadow: 0 0 10px rgba(255, 215, 0, 0.4);
}

.vip-image-caption p {
    color: #e0e0ff;
    font-size: 16px;
    line-height: 1.6;
}

/* 调整模态框样式，确保内容显示居中 */
.vip-content-container {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 50vh;
    padding: 20px 0;
}

.vip-content-modal .modal-content {
    max-width: 900px;
    width: 90%;
    background: rgba(30, 30, 50, 0.95);
    backdrop-filter: blur(10px);
    padding: 30px;
    border-radius: 20px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.5);
}

/* 支持管理员添加多种内容的样式 */
.vip-content-container a {
    color: #ffcc00;
    text-decoration: none;
    transition: all 0.3s ease;
}

.vip-content-container a:hover {
    color: #ff9900;
    text-decoration: underline;
}

.vip-content-container h2, 
.vip-content-container h3, 
.vip-content-container h4 {
    color: #fff;
    margin: 20px 0 10px;
    text-shadow: 0 0 10px rgba(255, 255, 255, 0.2);
}

.vip-content-container p {
    color: #e0e0ff;
    margin-bottom: 15px;
    line-height: 1.6;
}

.vip-content-container ul, 
.vip-content-container ol {
    color: #e0e0ff;
    margin-left: 20px;
    margin-bottom: 20px;
}

.vip-content-container li {
    margin-bottom: 8px;
}

/* 支持多图片展示 */
.vip-content-container .gallery {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    justify-content: center;
    margin: 20px 0;
}

.vip-content-container .gallery-item {
    flex: 0 0 calc(33.333% - 15px);
    transition: all 0.3s ease;
}

.vip-channel-modal-content {
    max-height: 80vh;
}

.vip-channel-modal-close {
    position: absolute;
    top: 15px;
    right: 20px;
    font-size: 24px;
    cursor: pointer;
    color: #aaa;
    transition: all 0.3s ease;
    /* 确保关闭按钮可点击 */
    pointer-events: auto;
    z-index: 1200;
}

.vip-channel-modal-close:hover {
    color: #333;
}

/* =============== 123张展示图的尺寸调整 =============== */
@media screen and (min-width: 769px) {
    /* 确保容器居中对齐 */
    .gallery-container {
        overflow-x: hidden !important;
        width: 100% !important;
        max-width: 100vw !important;
        box-sizing: border-box !important;
        padding: 0 !important; /* 移除容器内边距 */
        display: flex !important;
        flex-direction: column !important; /* 改为纵向排列 */
        justify-content: center !important;
        align-items: center !important;
    }
    
    /* 确保网格居中对齐 */
    #gallery-grid, 
    .gallery-items-wrapper {
        display: grid !important;
        grid-template-columns: repeat(5, 1fr) !important;
        gap: 35px !important; /* 网格间距 */
        row-gap: 35px !important; /* 行间距 */
        width: 96% !important; /* 减少宽度确保左右有空间 */
        max-width: 1300px !important;
        margin: 0 auto !important; /* 居中对齐 */
        padding: 20px !important;
        box-sizing: border-box !important;
        justify-content: center !important;
    }
    
    /* 电脑端所有展示图样式调整 */
    .gallery-item {
        width: 100% !important; /* 恢复正常宽度 */
        margin: 0 auto !important; /* 居中对齐 */
        padding: 0 15px !important; /* 添加左右内边距 */
        box-sizing: border-box !important;
        overflow: hidden !important;
        position: relative !important;
        border-radius: 8px !important;
        transform: none !important;
        transition: transform 0.4s cubic-bezier(0.2, 0.8, 0.2, 1) !important; /* 添加平滑过渡效果 */
    }
    
    .gallery-item:hover {
        transform: translateY(-10px) scale(1.03) !important; /* 上移10px并放大3% */
        z-index: 50 !important; /* 确保悬停的图片在上层 */
    }
    
    .gallery-item .img-container {
        overflow: hidden !important;
        width: 100% !important; /* 确保图片容器撑满项目宽度 */
        border-radius: 8px !important;
        box-shadow: 0 5px 15px rgba(0, 0, 0, 0.08) !important; /* 添加初始阴影 */
        transition: box-shadow 0.4s cubic-bezier(0.2, 0.8, 0.2, 1) !important; /* 阴影过渡 */
    }
    
    .gallery-item:hover .img-container {
        box-shadow: 0 15px 30px rgba(0, 0, 0, 0.15) !important; /* 悬停时加深阴影 */
    }
    
    .gallery-item img {
        width: 100% !important; /* 图片宽度适应容器 */
        object-fit: cover !important;
        transition: transform 0.5s cubic-bezier(0.2, 0.8, 0.2, 1) !important; /* 添加放大过渡效果 */
    }
    
    .gallery-item:hover img {
        transform: scale(1.07) !important; /* 图片内部放大7% */
    }
    
    /* 电脑端展示图高度调整 - 所有图片减少1/6高度 */
    .gallery-item .img-container {
        height: calc(100% * 5 / 6) !important; /* 减少原来高度的1/6 */
        padding-top: calc(133% * 5 / 6) !important; /* 保持宽高比但降低高度 */
    }
    
    .gallery-item img {
        height: 100% !important; /* 图片填充容器高度 */
        position: absolute !important;
        top: 0 !important;
        left: 0 !important;
    }
    
    /* 展示图底部文本框样式 */
    .gallery-item .text-box {
        display: block !important;
        visibility: visible !important;
        opacity: 1 !important;
        height: auto !important;
        width: 100% !important;
        padding: 10px !important;
        margin: 0 !important;
        overflow: hidden !important;
        position: relative !important; /* 改为相对定位确保在图片底部 */
        z-index: 5 !important;
        background-color: #ffffff !important;
        color: #333333 !important;
        font-size: 14px !important;
        text-align: center !important;
        font-weight: 500 !important;
        border-top: 1px solid #f0f0f0 !important;
        box-shadow: 0 2px 5px rgba(0,0,0,0.05) !important;
        box-sizing: border-box !important;
        transform: none !important;
    }

    .gallery-item .text-box .dot {
        display: inline-block !important;
        width: 8px !important;
        height: 8px !important;
        background-color: #FF8C00 !important; /* 深橙色 */
        border-radius: 50% !important;
        margin-right: 5px !important;
        vertical-align: middle !important;
    }
}

/* 确保移动端展示图有适当间隙 */
@media screen and (max-width: 768px) {
    /* 确保网格居中对齐 */
    #gallery-grid, 
    .gallery-items-wrapper {
        display: grid !important;
        grid-template-columns: repeat(2, 1fr) !important;
        gap: 20px !important; /* 网格间距 */
        row-gap: 25px !important; /* 行间距 */
        width: 94% !important; /* 减少宽度确保左右有空间 */
        margin: 0 auto !important; /* 居中对齐 */
        padding: 10px !important;
        box-sizing: border-box !important;
        justify-content: center !important;
    }
    
    .gallery-item {
        width: 100% !important; /* 恢复正常宽度 */
        margin: 0 auto !important; /* 居中对齐 */
        padding: 0 10px !important; /* 添加左右内边距 */
        box-sizing: border-box !important;
        transform: none !important;
        display: flex !important; /* 使用flex布局 */
        flex-direction: column !important; /* 竖向排列 */
    }
    
    .gallery-item .img-container {
        width: 100% !important;
        overflow: hidden !important;
        order: 1 !important; /* 图片在前 */
        padding-top: calc(133% * 11 / 8) !important; /* 增加原高度的八分之一 */
        height: auto !important;
        position: relative !important;
    }
    
    .gallery-item img {
        width: 100% !important;
        object-fit: cover !important;
        position: absolute !important;
        top: 0 !important;
        left: 0 !important;
        height: 100% !important;
    }
    
    /* 移动端文本框样式 */
    .gallery-item .text-box {
        padding: 8px !important;
        font-size: 12px !important;
        position: relative !important; /* 确保在图片底部 */
        background-color: #ffffff !important;
        border-top: 1px solid #f0f0f0 !important;
        order: 2 !important; /* 文本框在后 */
        width: 100% !important;
        margin: 0 !important;
        bottom: auto !important; /* 移除底部定位 */
        top: auto !important; /* 移除顶部定位 */
        left: auto !important; /* 移除左侧定位 */
        right: auto !important; /* 移除右侧定位 */
    }
    
    .gallery-item .text-box .dot {
        width: 6px !important;
        height: 6px !important;
    }
} 

/* 新增：统一展示图点击样式 */
.gallery-item {
    cursor: pointer !important;
    position: relative !important;
    z-index: 1 !important;
    overflow: hidden !important;
    transition: transform 0.3s ease !important;
}

.gallery-item:hover {
    transform: translateY(-5px) !important;
}

.gallery-item img {
    cursor: pointer !important;
    width: 100% !important;
    object-fit: cover !important;
    transition: transform 0.3s ease !important;
}

.gallery-item img:hover {
    transform: scale(1.05) !important;
}

.gallery-item .text-box {
    display: flex !important;
    align-items: center !important;
    padding: 8px !important;
    font-size: 12px !important;
    background-color: #ffffff !important;
    border-top: 1px solid #f0f0f0 !important;
} 
