/* ===================================
   字体导入 - Google Fonts
   引入中文思源黑体（Noto Sans SC）
=================================== */
@import url('https://fonts.googleapis.com/css2?family=Noto+Sans+SC:wght@300;400;500;700&display=swap');

/* ===================================
   全局重置与滚动优化
   - scroll-behavior: smooth → 平滑滚动锚点
   - backface-visibility / perspective → 修复滚动时文字抖动
=================================== */
html {
    scroll-behavior: smooth;
}

* {
    backface-visibility: hidden;
    perspective: 1000px;
}

/* ===================================
   全局 CSS 变量（主题色）
   - primary-color: 主色（深蓝）
   - secondary-color: 辅助色（亮蓝）
   - accent-color: 强调色（橙色，用于 hover 和下划线）
   - dark-color: 文字深色
   - light-color: 浅灰背景
=================================== */
:root {
    --primary-color: #0B3D91;
    --secondary-color: #007AFF;
    --accent-color: #FF6B00;
    --dark-color: #333333;
    --light-color: #F5F5F5;
}

/* ===================================
   全局 Body 样式
   - 字体：思源黑体
   - 文字颜色：深灰
   - 隐藏横向溢出
=================================== */
body {
    font-family: 'Noto Sans SC', sans-serif;
    color: var(--dark-color);
    overflow-x: hidden;
}

/* ===================================
   文字渐变效果（用于特殊标题）
   用法：<span class="text-gradient">文字</span>
=================================== */
.text-gradient {
    background: linear-gradient(90deg, var(--primary-color), var(--secondary-color));
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

/* 渐变背景（用于按钮、头部等） */
.bg-gradient {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
}

/* ===================================
   导航栏链接样式
   - 下划线动画：hover/active 时从左边滑出
=================================== */
.nav-link {
    position: relative;
    transition: all 0.3s ease;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 0;
    height: 2px;
    background-color: var(--accent-color);
    transition: width 0.3s ease;
}

.nav-link:hover::after,
.nav-link.active::after {
    width: 100%;
}

/* ===================================
   首屏 Hero 区域
   - 高度：全屏（100vh）
   - 背景：蓝色渐变 + 背景图片
=================================== */
.hero-section {
    height: 100vh;
    background:  url('/img/home.webp') no-repeat center center;
    background-size: cover;
}

/* ===================================
   区域标题样式
   - 相对定位，底部有一个橙色下划线
   用法：<h2 class="section-title">标题</h2>
=================================== */
.section-title {
    position: relative;
    display: inline-block;
    margin-bottom: 2rem;
}

.section-title::after {
    content: '';
    position: absolute;
    bottom: -10px;
    left: 0;
    width: 60px;
    height: 3px;
    background-color: var(--accent-color);
}

/* ===================================
   卡片通用样式
   - hover 时向上浮动 + 阴影加深
=================================== */
.card {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.card:hover {
    transform: translateY(-10px);
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
}

/* ===================================
   团队成员卡片
   - 图片 hover 时放大
=================================== */
.team-card img {
    transition: transform 0.5s ease;
}

.team-card:hover img {
    transform: scale(1.05);
}

/* 社交图标 hover 效果 */
.social-icon {
    transition: transform 0.3s ease, color 0.3s ease;
}

.social-icon:hover {
    transform: translateY(-5px);
    color: var(--accent-color);
}

/* ===================================
   时间轴（发展历程）
   - 左侧竖线 + 圆点
=================================== */
.timeline-item {
    position: relative;
    padding-left: 30px;
    margin-bottom: 30px;
}

/* 圆点 */
.timeline-item::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background-color: var(--accent-color);
}

/* 竖线（连接圆点） */
.timeline-item::after {
    content: '';
    position: absolute;
    left: 5px;
    top: 12px;
    width: 2px;
    height: calc(100% + 18px);
    background-color: #e5e7eb;
}

/* 最后一项不显示竖线 */
.timeline-item:last-child::after {
    display: none;
}



/* ===================================
   服务卡片图标
   - hover 时放大 + 变色
=================================== */
.service-icon {
    transition: all 0.3s ease;
}

.service-card:hover .service-icon {
    transform: scale(1.1);
    color: var(--accent-color);
}

/* ===================================
   智能客服聊天机器人
=================================== */

/* 右下角浮动容器 */
.chatbot-container {
    position: fixed;
    bottom: 30px;
    right: 30px;
    z-index: 1000;
}

/* 聊天按钮（圆形） */
.chatbot-button {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    display: flex;
    justify-content: center;
    align-items: center;
    cursor: pointer;
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
    transition: all 0.3s ease;
}

.chatbot-button:hover {
    transform: scale(1.1);
}

/* 聊天面板（默认隐藏） */
.chatbot-panel {
    position: absolute;
    bottom: 80px;
    right: 0;
    width: 350px;
    height: 450px;
    background-color: white;
    border-radius: 10px;
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
    display: none;
    flex-direction: column;
    overflow: hidden;
}

/* 聊天头部（渐变背景） */
.chatbot-header {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    color: white;
    padding: 15px;
    font-weight: 500;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

/* 消息区域（可滚动） */
.chatbot-messages {
    flex: 1;
    padding: 15px;
    overflow-y: auto;
}

/* 单条消息通用样式 */
.message {
    margin-bottom: 15px;
    max-width: 80%;
    padding: 10px 15px;
    border-radius: 18px;
}

/* 机器人消息（灰色，左对齐） */
.bot-message {
    background-color: #f0f0f0;
    border-bottom-left-radius: 5px;
    align-self: flex-start;
}

/* 用户消息（渐变蓝，右对齐） */
.user-message {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    color: white;
    border-bottom-right-radius: 5px;
    align-self: flex-end;
    margin-left: auto;
}

/* 聊天输入栏 */
.chatbot-input {
    display: flex;
    padding: 10px;
    border-top: 1px solid #e5e7eb;
}

.chatbot-input input {
    flex: 1;
    padding: 10px;
    border: 1px solid #e5e7eb;
    border-radius: 20px;
    margin-right: 10px;
}

.chatbot-input button {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    color: white;
    border: none;
    border-radius: 20px;
    padding: 10px 15px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.chatbot-input button:hover {
    opacity: 0.9;
}

/* 快捷问题按钮区域 */
.quick-questions {
    display: flex;
    flex-wrap: wrap;
    gap: 5px;
    margin-top: 10px;
}

.quick-question {
    background-color: #f0f0f0;
    padding: 5px 10px;
    border-radius: 15px;
    font-size: 0.8rem;
    cursor: pointer;
    transition: all 0.3s ease;
}

.quick-question:hover {
    background-color: #e5e7eb;
}

/* ===================================
   响应式设计（手机/平板适配）
=================================== */

/* 平板及以下 */
@media (max-width: 768px) {
    .hero-content h1 {
        font-size: 2.5rem;
    }
    
    .chatbot-panel {
        width: 300px;
        height: 400px;
        right: -10px;
    }
}

/* 手机及以下 */
@media (max-width: 640px) {
    .hero-content h1 {
        font-size: 2rem;
    }
    
    .chatbot-panel {
        width: 280px;
        height: 350px;
    }
}
/* 导航栏标题金色渐变 */
nav .flex .items-center span.text-xl.font-bold {
    background: linear-gradient(135deg, #FFD700, #FFA500);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    font-weight: bold;
}

/* 科技感黑色导航栏 */
nav {
    background: rgba(10, 10, 15, 0.80) !important;
    position: relative;
    overflow: hidden;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.25);
    border-bottom: 1px solid rgba(255, 215, 0, 0.3);
}

/* 顶部微光扫过动画 */
nav::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 2px;
    background: linear-gradient(90deg, transparent, #FFD700, transparent);
    animation: scan 3s infinite;
}

@keyframes scan {
    0% { left: -100%; }
    100% { left: 100%; }
}