/* 兼容性修复CSS */

/* 修复text-size-adjust兼容性 */
body {
    -webkit-text-size-adjust: 100%;
    -ms-text-size-adjust: 100%;
    text-size-adjust: 100%;
}

/* 修复backdrop-filter兼容性 */
.contact-info,
.benefit,
.copy-btn,
.share-btn {
    -webkit-backdrop-filter: blur(15px);
    backdrop-filter: blur(15px);
}

/* 修复image-rendering兼容性 */
.program-image img,
.gallery-item img {
    -webkit-image-rendering: -webkit-optimize-contrast;
    -moz-image-rendering: crisp-edges;
    -ms-image-rendering: pixelated;
    image-rendering: -webkit-optimize-contrast;
    image-rendering: crisp-edges;
    image-rendering: pixelated;
}

/* 移动端康养环境显示修复 - 确保立即可见 */
@media (max-width: 768px) {
    /* 确保康养环境部分在移动端立即可见 */
    .photo-gallery-section {
        opacity: 1 !important;
        visibility: visible !important;
        transform: none !important;
        animation: none !important;
    }
    
    .photo-gallery-section.fade-in-section {
        opacity: 1 !important;
        transform: translateY(0) !important;
        transition: none !important;
    }
    
    /* 所有重要内容区域在移动端都直接显示 */
    .fade-in-section {
        opacity: 1 !important;
        transform: translateY(0) !important;
        transition: none !important;
        animation: none !important;
    }
    
    /* 移动端图片渲染优化 */
    .program-image img,
    .gallery-item img {
        -webkit-image-rendering: -webkit-optimize-contrast;
        image-rendering: -webkit-optimize-contrast;
        image-rendering: crisp-edges;
    }
    
    /* 移动端字体优化 */
    body {
        -webkit-text-size-adjust: 100%;
        -ms-text-size-adjust: 100%;
        text-size-adjust: 100%;
    }
    
    /* 移动端触摸优化 */
    .cta-button,
    .signup-btn,
    .share-btn,
    .copy-btn,
    .copy-modal-btn {
        min-height: 44px;
        min-width: 44px;
        touch-action: manipulation;
        -webkit-tap-highlight-color: transparent;
    }
    
    /* 优化点击区域 */
    .gallery-item,
    .healing-item,
    .family-item,
    .detail-card,
    .pricing-card {
        touch-action: manipulation;
        -webkit-tap-highlight-color: transparent;
    }
    
    /* 防止双击缩放 */
    .hero-content,
    .section-title,
    .contact-info {
        touch-action: manipulation;
    }
}

/* 性能优化 */
.fade-in-section {
    will-change: transform, opacity;
}

/* 减少动画在低性能设备上的影响 */
@media (prefers-reduced-motion: reduce) {
    .fade-in-section,
    .healing-item,
    .gallery-item,
    .family-item,
    .cta-button,
    .signup-btn {
        animation: none !important;
        transition: none !important;
    }
}

/* 修复Safari兼容性 */
@supports (-webkit-backdrop-filter: blur(10px)) {
    .contact-info,
    .benefit {
        -webkit-backdrop-filter: blur(15px);
    }
}

/* 修复Edge兼容性 */
@supports (image-rendering: -webkit-optimize-contrast) {
    .program-image img,
    .gallery-item img {
        image-rendering: -webkit-optimize-contrast;
    }
}

/* 缓存控制优化 */
img {
    cache-control: public, max-age=31536000;
}

/* 安全性增强 */
* {
    -webkit-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
    user-select: none;
}

/* 允许文本选择 */
p, h1, h2, h3, h4, h5, h6, span, div.text-content {
    -webkit-user-select: text;
    -moz-user-select: text;
    -ms-user-select: text;
    user-select: text;
}