/* ===== Banner/Hero 区域专属美化 ===== */

/* 通用 Hero 背景增强 */
.hero-bg,
.product-hero-bg {
    position: absolute;
    inset: 0;
    overflow: hidden;
    background: linear-gradient(180deg, #f0f9ff 0%, #e0f2fe 25%, #eef2ff 50%, #faf5ff 75%, #fff1f2 100%);
}

.hero-gradient {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 25%, #f093fb 50%, #f6d365 75%, #fda085 100%);
    background-size: 400% 400%;
    animation: gradient-flow 15s ease infinite;
    opacity: 0.12;
    filter: blur(80px);
}

@keyframes gradient-flow {
    0%, 100% { background-position: 0% 50%; }
    25% { background-position: 50% 100%; }
    50% { background-position: 100% 50%; }
    75% { background-position: 50% 0%; }
}

/* 添加浮动装饰圆圈 */
.hero-bg::before,
.product-hero-bg::before {
    content: '';
    position: absolute;
    top: -10%;
    right: -5%;
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, rgba(102, 126, 234, 0.15) 0%, transparent 70%);
    border-radius: 50%;
    animation: float-slow 20s ease-in-out infinite;
    pointer-events: none;
}

.hero-bg::after,
.product-hero-bg::after {
    content: '';
    position: absolute;
    bottom: -10%;
    left: -5%;
    width: 500px;
    height: 500px;
    background: radial-gradient(circle, rgba(240, 147, 251, 0.12) 0%, transparent 70%);
    border-radius: 50%;
    animation: float-slow 18s ease-in-out infinite reverse;
    pointer-events: none;
}

@keyframes float-slow {
    0%, 100% { transform: translate(0, 0) scale(1); }
    33% { transform: translate(20px, -20px) scale(1.05); }
    66% { transform: translate(-20px, 20px) scale(0.95); }
}

/* Hero 网格增强 */
.hero-grid {
    position: absolute;
    inset: 0;
    background-image: 
        linear-gradient(rgba(37, 99, 235, 0.04) 1px, transparent 1px),
        linear-gradient(90deg, rgba(37, 99, 235, 0.04) 1px, transparent 1px);
    background-size: 80px 80px;
    mask-image: radial-gradient(ellipse at 50% 50%, black 40%, transparent 80%);
    -webkit-mask-image: radial-gradient(ellipse at 50% 50%, black 40%, transparent 80%);
    animation: grid-pulse 8s ease-in-out infinite;
}

@keyframes grid-pulse {
    0%, 100% { opacity: 0.4; }
    50% { opacity: 0.7; }
}

/* Hero 内容区域增强 */
.hero-content,
.product-hero-content {
    position: relative;
    z-index: 2;
}

/* Hero 标题增强 */
.hero-title,
.product-hero-title {
    text-shadow: 0 2px 20px rgba(0, 0, 0, 0.05);
}

.hero-title .highlight,
.product-hero-title .highlight {
    /* 删除渐变效果 */
}

/* Hero 描述增强 */
.hero-desc,
.product-hero-desc {
    position: relative;
    padding-left: 1.5rem;
}

.hero-desc::before,
.product-hero-desc::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0.5rem;
    width: 4px;
    height: calc(100% - 1rem);
    background: var(--primary-gradient);
    border-radius: 2px;
}

/* Hero 卡片增强 */
.hero-card,
.product-hero-card {
    position: relative;
    background: rgba(255, 255, 255, 0.95) !important;
    backdrop-filter: blur(20px) saturate(180%) !important;
    -webkit-backdrop-filter: blur(20px) saturate(180%) !important;
    border: 1px solid rgba(255, 255, 255, 0.6) !important;
    box-shadow: 
        0 20px 60px rgba(0, 0, 0, 0.1),
        0 0 80px rgba(37, 99, 235, 0.15),
        inset 0 1px 0 rgba(255, 255, 255, 0.8) !important;
    animation: float-enhanced 8s ease-in-out infinite !important;
}

@keyframes float-enhanced {
    0%, 100% { 
        transform: translateY(0) rotate(0deg);
        box-shadow: 
            0 20px 60px rgba(0, 0, 0, 0.1),
            0 0 80px rgba(37, 99, 235, 0.15),
            inset 0 1px 0 rgba(255, 255, 255, 0.8);
    }
    25% { 
        transform: translateY(-15px) rotate(1deg);
        box-shadow: 
            0 30px 80px rgba(0, 0, 0, 0.12),
            0 0 100px rgba(37, 99, 235, 0.2),
            inset 0 1px 0 rgba(255, 255, 255, 0.8);
    }
    50% { 
        transform: translateY(-25px) rotate(0deg);
        box-shadow: 
            0 40px 100px rgba(0, 0, 0, 0.15),
            0 0 120px rgba(37, 99, 235, 0.25),
            inset 0 1px 0 rgba(255, 255, 255, 0.8);
    }
    75% { 
        transform: translateY(-15px) rotate(-1deg);
        box-shadow: 
            0 30px 80px rgba(0, 0, 0, 0.12),
            0 0 100px rgba(37, 99, 235, 0.2),
            inset 0 1px 0 rgba(255, 255, 255, 0.8);
    }
}

/* Hero 卡片光晕效果 */
.hero-card::before,
.product-hero-card::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(37, 99, 235, 0.08) 0%, transparent 60%);
    animation: halo-rotate 20s linear infinite;
    pointer-events: none;
}

@keyframes halo-rotate {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* 聊天消息增强 */
.chat-demo .message.customer .bubble {
    background: linear-gradient(135deg, #f3f4f6 0%, #e5e7eb 100%);
    border: 1px solid rgba(0, 0, 0, 0.05);
    position: relative;
    overflow: hidden;
}

.chat-demo .message.customer .bubble::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, transparent 0%, rgba(37, 99, 235, 0.03) 100%);
    pointer-events: none;
}

.chat-demo .message.agent .bubble {
    background: linear-gradient(135deg, #2563eb 0%, #7c3aed 100%);
    box-shadow: 0 4px 20px rgba(37, 99, 235, 0.3);
    position: relative;
}

.chat-demo .message.agent .bubble::before {
    content: '';
    position: absolute;
    top: -2px;
    left: -2px;
    right: -2px;
    bottom: -2px;
    background: linear-gradient(135deg, #2563eb, #7c3aed, #db2777);
    border-radius: inherit;
    z-index: -1;
    filter: blur(8px);
    opacity: 0.5;
}

/* Stats Banner 美化 */
.stats-banner {
    position: relative;
    background: linear-gradient(135deg, rgba(37, 99, 235, 0.02) 0%, rgba(124, 58, 237, 0.02) 100%);
    border-top: 1px solid rgba(37, 99, 235, 0.1);
    border-bottom: 1px solid rgba(37, 99, 235, 0.1);
}

.stats-banner-grid {
    gap: 2rem !important;
}

.stat-banner-item {
    background: white;
    padding: 2rem 1.5rem;
    border-radius: var(--radius-2xl);
    box-shadow: var(--shadow-md);
    transition: all var(--transition-base);
    border: 1px solid var(--gray-100);
    position: relative;
    overflow: hidden;
}

.stat-banner-item::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: var(--primary-gradient);
    transform: scaleX(0);
    transition: transform var(--transition-slow);
}

.stat-banner-item:hover::before {
    transform: scaleX(1);
}

.stat-banner-item:hover {
    transform: translateY(-8px) scale(1.02);
    box-shadow: var(--shadow-xl), 0 0 60px rgba(37, 99, 235, 0.15);
    border-color: rgba(37, 99, 235, 0.2);
}

.stat-banner-value {
    background: var(--primary-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    font-size: 3rem !important;
    font-weight: 800;
    text-shadow: 0 4px 20px rgba(37, 99, 235, 0.2);
}

/* 内页 Banner 美化 */
.page-hero {
    position: relative;
    overflow: hidden;
}

.page-hero::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -20%;
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, rgba(37, 99, 235, 0.1) 0%, transparent 70%);
    border-radius: 50%;
    animation: float-slow 20s ease-in-out infinite;
}

.page-hero::after {
    content: '';
    position: absolute;
    bottom: -50%;
    left: -20%;
    width: 500px;
    height: 500px;
    background: radial-gradient(circle, rgba(124, 58, 237, 0.1) 0%, transparent 70%);
    border-radius: 50%;
    animation: float-slow 18s ease-in-out infinite reverse;
}

/* Banner 按钮增强 */
.hero-cta .btn,
.product-hero-cta .btn {
    position: relative;
    overflow: hidden;
    z-index: 1;
}

.hero-cta .btn::after,
.product-hero-cta .btn::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, rgba(255,255,255,0.2) 0%, transparent 100%);
    opacity: 0;
    transition: opacity var(--transition-base);
}

.hero-cta .btn:hover::after,
.product-hero-cta .btn:hover::after {
    opacity: 1;
}

/* 移动端优化 */
@media (max-width: 768px) {
    .hero-bg::before,
    .hero-bg::after,
    .product-hero-bg::before,
    .product-hero-bg::after {
        width: 300px;
        height: 300px;
    }
    
    .hero-grid {
        background-size: 40px 40px;
    }
    
    .hero-card,
    .product-hero-card {
        animation: float-enhanced-mobile 6s ease-in-out infinite !important;
    }
    
    @keyframes float-enhanced-mobile {
        0%, 100% { transform: translateY(0); }
        50% { transform: translateY(-10px); }
    }
    
    .stat-banner-item:hover {
        transform: translateY(-4px) scale(1.01);
    }
}

/* 可访问性 - 减少动画 */
@media (prefers-reduced-motion: reduce) {
    .hero-gradient,
    .hero-bg::before,
    .hero-bg::after,
    .hero-grid,
    .hero-card,
    .product-hero-card {
        animation: none;
    }
}
