/* ===== 基础变量 ===== */
:root {
    --primary: #E85D4E;
    --primary-light: #F5A623;
    --primary-dark: #C43E2F;
    --secondary: #4A90A4;
    --accent-green: #7CB342;
    --accent-purple: #9C27B0;
    --accent-orange: #FF9800;
    --accent-teal: #009688;
    --accent-blue: #2196F3;
    --accent-red: #F44336;
    --bg-warm: #FFF8F0;
    --bg-cream: #FDF6E9;
    --bg-white: #FFFFFF;
    --text-primary: #2C2C2C;
    --text-secondary: #666666;
    --text-light: #999999;
    --border-light: #E8E0D5;
    --shadow-soft: 0 4px 20px rgba(0,0,0,0.06);
    --shadow-medium: 0 8px 32px rgba(0,0,0,0.1);
    --radius: 16px;
    --radius-sm: 8px;
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Noto Sans SC', -apple-system, BlinkMacSystemFont, sans-serif;
    background: var(--bg-warm);
    color: var(--text-primary);
    line-height: 1.6;
    overflow-x: hidden;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 24px;
}

/* ===== 导航栏 ===== */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 40px;
    height: 72px;
    background: rgba(255, 248, 240, 0.92);
    backdrop-filter: blur(20px);
    border-bottom: 1px solid rgba(232, 224, 213, 0.5);
    transition: var(--transition);
}

.nav-brand {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 22px;
    font-weight: 700;
    color: var(--primary);
}

.logo-icon {
    font-size: 28px;
    color: var(--primary);
    animation: pulse 3s ease-in-out infinite;
}

@keyframes pulse {
    0%, 100% { opacity: 1; transform: scale(1); }
    50% { opacity: 0.7; transform: scale(1.1); }
}

.nav-links {
    display: flex;
    gap: 32px;
}

.nav-links a {
    text-decoration: none;
    color: var(--text-secondary);
    font-size: 15px;
    font-weight: 500;
    position: relative;
    transition: var(--transition);
}

.nav-links a:hover,
.nav-links a.active {
    color: var(--primary);
}

.nav-links a::after {
    content: '';
    position: absolute;
    bottom: -6px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--primary);
    border-radius: 2px;
    transition: var(--transition);
}

.nav-links a:hover::after,
.nav-links a.active::after {
    width: 100%;
}

.nav-toggle {
    display: none;
    font-size: 24px;
    cursor: pointer;
    color: var(--text-primary);
}

/* ===== Hero 首屏 ===== */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    padding: 120px 40px 80px;
    overflow: hidden;
}

.hero-bg {
    position: absolute;
    inset: 0;
    background: 
        radial-gradient(ellipse at 20% 50%, rgba(232, 93, 78, 0.08) 0%, transparent 50%),
        radial-gradient(ellipse at 80% 30%, rgba(245, 166, 35, 0.06) 0%, transparent 50%),
        radial-gradient(ellipse at 50% 80%, rgba(74, 144, 164, 0.05) 0%, transparent 50%),
        linear-gradient(180deg, var(--bg-warm) 0%, var(--bg-cream) 100%);
    z-index: 0;
}

.hero-bg::before {
    content: '';
    position: absolute;
    top: 15%;
    left: 50%;
    transform: translateX(-50%);
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, rgba(232, 93, 78, 0.03) 0%, transparent 70%);
    border-radius: 50%;
    animation: breathe 6s ease-in-out infinite;
}

@keyframes breathe {
    0%, 100% { transform: translateX(-50%) scale(1); opacity: 0.5; }
    50% { transform: translateX(-50%) scale(1.1); opacity: 0.8; }
}

.hero-content {
    position: relative;
    z-index: 2;
    text-align: center;
    max-width: 800px;
}

.hero-title {
    font-size: clamp(36px, 6vw, 64px);
    font-weight: 700;
    line-height: 1.2;
    margin-bottom: 24px;
}

.title-line {
    display: block;
    background: linear-gradient(135deg, var(--text-primary) 0%, var(--text-secondary) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.title-line.highlight {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-light) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    position: relative;
}

.title-line.highlight::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 50%;
    transform: translateX(-50%);
    width: 120px;
    height: 4px;
    background: linear-gradient(90deg, var(--primary), var(--primary-light));
    border-radius: 2px;
}

.hero-subtitle {
    font-size: 18px;
    color: var(--text-secondary);
    max-width: 560px;
    margin: 0 auto 40px;
    line-height: 1.8;
}

.hero-cta {
    display: flex;
    gap: 16px;
    justify-content: center;
    flex-wrap: wrap;
}

.btn-primary {
    padding: 14px 36px;
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    color: white;
    border: none;
    border-radius: 50px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
    box-shadow: 0 4px 16px rgba(232, 93, 78, 0.3);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(232, 93, 78, 0.4);
}

.btn-secondary {
    padding: 14px 36px;
    background: transparent;
    color: var(--primary);
    border: 2px solid var(--primary);
    border-radius: 50px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
}

.btn-secondary:hover {
    background: var(--primary);
    color: white;
}

/* 粒子效果 */
.hero-particles {
    position: absolute;
    inset: 0;
    z-index: 1;
    pointer-events: none;
}

.particle {
    position: absolute;
    width: 4px;
    height: 4px;
    background: var(--primary-light);
    border-radius: 50%;
    opacity: 0.4;
    animation: float 8s ease-in-out infinite;
}

@keyframes float {
    0%, 100% { transform: translateY(0) translateX(0); opacity: 0.4; }
    25% { transform: translateY(-20px) translateX(10px); opacity: 0.7; }
    50% { transform: translateY(-40px) translateX(-10px); opacity: 0.3; }
    75% { transform: translateY(-20px) translateX(5px); opacity: 0.6; }
}

/* ===== 关于我们 / 时间轴 ===== */
.about-section {
    padding: 100px 0;
    background: var(--bg-white);
}

.about-header {
    text-align: center;
    margin-bottom: 60px;
}

.about-header h2 {
    font-size: 36px;
    font-weight: 700;
    margin-bottom: 12px;
    color: var(--text-primary);
}

.about-tagline {
    font-size: 20px;
    color: var(--primary);
    font-weight: 500;
    letter-spacing: 2px;
}

.timeline {
    position: relative;
    max-width: 900px;
    margin: 0 auto;
    padding: 20px 0;
}

.timeline::before {
    content: '';
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    width: 2px;
    height: 100%;
    background: linear-gradient(180deg, var(--primary), var(--primary-light), var(--accent-green), var(--secondary));
    border-radius: 1px;
}

.timeline-item {
    position: relative;
    padding: 24px 0;
    display: flex;
    align-items: center;
}

.timeline-item:nth-child(odd) {
    flex-direction: row;
}

.timeline-item:nth-child(even) {
    flex-direction: row-reverse;
}

.timeline-dot {
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    width: 16px;
    height: 16px;
    border-radius: 50%;
    border: 3px solid white;
    box-shadow: 0 0 0 3px currentColor;
    z-index: 2;
}

.timeline-content {
    width: 42%;
    padding: 24px;
    background: var(--bg-warm);
    border-radius: var(--radius);
    box-shadow: var(--shadow-soft);
    transition: var(--transition);
}

.timeline-content:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-medium);
}

.timeline-year {
    font-size: 14px;
    font-weight: 700;
    margin-bottom: 8px;
    letter-spacing: 1px;
}

.timeline-title {
    font-size: 18px;
    font-weight: 600;
    margin-bottom: 8px;
    color: var(--text-primary);
}

.timeline-desc {
    font-size: 14px;
    color: var(--text-secondary);
    line-height: 1.6;
}

/* ===== AI 对话区 ===== */
.chat-section {
    padding: 100px 0;
    background: linear-gradient(180deg, var(--bg-cream) 0%, var(--bg-warm) 100%);
}

.chat-header {
    text-align: center;
    margin-bottom: 48px;
}

.chat-header h2 {
    font-size: 36px;
    font-weight: 700;
    margin-bottom: 12px;
}

.chat-desc {
    color: var(--text-secondary);
    font-size: 16px;
}

.chat-container {
    max-width: 800px;
    margin: 0 auto;
    background: var(--bg-white);
    border-radius: var(--radius);
    box-shadow: var(--shadow-medium);
    overflow: hidden;
    border: 1px solid var(--border-light);
}

.chat-messages {
    height: 480px;
    overflow-y: auto;
    padding: 24px;
    background: linear-gradient(180deg, #FAFAFA 0%, var(--bg-white) 100%);
}

.message {
    display: flex;
    gap: 12px;
    margin-bottom: 20px;
    animation: messageSlide 0.3s ease-out;
}

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

.message-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    font-weight: 700;
    flex-shrink: 0;
}

.ai-message .message-avatar {
    background: linear-gradient(135deg, var(--primary), var(--primary-light));
    color: white;
}

.user-message {
    flex-direction: row-reverse;
}

.user-message .message-avatar {
    background: linear-gradient(135deg, var(--secondary), #6BB3C7);
    color: white;
}

.message-content {
    max-width: 70%;
    padding: 14px 18px;
    border-radius: 18px;
    font-size: 15px;
    line-height: 1.7;
}

.ai-message .message-content {
    background: var(--bg-warm);
    color: var(--text-primary);
    border-bottom-left-radius: 4px;
}

.user-message .message-content {
    background: linear-gradient(135deg, var(--primary), var(--primary-dark));
    color: white;
    border-bottom-right-radius: 4px;
}

.message-content p {
    margin-bottom: 8px;
}

.message-content p:last-child {
    margin-bottom: 0;
}

/* 输入区 */
.chat-input-area {
    padding: 20px 24px;
    background: var(--bg-white);
    border-top: 1px solid var(--border-light);
}

.input-wrapper {
    display: flex;
    gap: 12px;
    align-items: flex-end;
    background: var(--bg-warm);
    border-radius: 24px;
    padding: 8px 8px 8px 20px;
    border: 1px solid var(--border-light);
    transition: var(--transition);
}

.input-wrapper:focus-within {
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(232, 93, 78, 0.1);
}

.input-wrapper textarea {
    flex: 1;
    border: none;
    background: transparent;
    resize: none;
    font-size: 15px;
    font-family: inherit;
    color: var(--text-primary);
    outline: none;
    max-height: 120px;
    padding: 8px 0;
}

.input-wrapper textarea::placeholder {
    color: var(--text-light);
}

.send-btn {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--primary), var(--primary-dark));
    color: white;
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition);
    flex-shrink: 0;
}

.send-btn:hover {
    transform: scale(1.05);
    box-shadow: 0 4px 12px rgba(232, 93, 78, 0.3);
}

.send-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    transform: none;
}

.chat-hint {
    text-align: center;
    font-size: 12px;
    color: var(--text-light);
    margin-top: 10px;
}

/* 打字动画 */
.typing-indicator {
    display: flex;
    gap: 4px;
    padding: 12px 16px;
}

.typing-indicator span {
    width: 8px;
    height: 8px;
    background: var(--primary-light);
    border-radius: 50%;
    animation: typingBounce 1.4s ease-in-out infinite;
}

.typing-indicator span:nth-child(2) { animation-delay: 0.2s; }
.typing-indicator span:nth-child(3) { animation-delay: 0.4s; }

@keyframes typingBounce {
    0%, 60%, 100% { transform: translateY(0); }
    30% { transform: translateY(-10px); }
}

/* ===== 服务项目 ===== */
.services-section {
    padding: 100px 0;
    background: var(--bg-white);
}

.services-section h2 {
    text-align: center;
    font-size: 36px;
    font-weight: 700;
    margin-bottom: 60px;
}

.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 24px;
}

.service-card {
    background: var(--bg-warm);
    border-radius: var(--radius);
    padding: 36px 28px;
    transition: var(--transition);
    border: 1px solid var(--border-light);
    position: relative;
    overflow: hidden;
}

.service-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 4px;
    background: linear-gradient(90deg, var(--primary), var(--primary-light));
    transform: scaleX(0);
    transition: var(--transition);
}

.service-card:hover::before {
    transform: scaleX(1);
}

.service-card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-medium);
}

.service-icon {
    font-size: 40px;
    margin-bottom: 20px;
}

.service-card h3 {
    font-size: 20px;
    font-weight: 600;
    margin-bottom: 12px;
    color: var(--text-primary);
}

.service-card p {
    font-size: 14px;
    color: var(--text-secondary);
    line-height: 1.7;
    margin-bottom: 16px;
}

.service-tag {
    display: inline-block;
    padding: 4px 12px;
    background: rgba(232, 93, 78, 0.1);
    color: var(--primary);
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
}

/* ===== 咨询表单 ===== */
.inquiry-section {
    padding: 100px 0;
    background: linear-gradient(135deg, var(--bg-cream) 0%, var(--bg-warm) 100%);
}

.inquiry-card {
    max-width: 700px;
    margin: 0 auto;
    background: var(--bg-white);
    border-radius: var(--radius);
    padding: 48px;
    box-shadow: var(--shadow-medium);
    border: 1px solid var(--border-light);
}

.inquiry-card h3 {
    font-size: 28px;
    font-weight: 700;
    margin-bottom: 8px;
    text-align: center;
}

.inquiry-card > p {
    text-align: center;
    color: var(--text-secondary);
    margin-bottom: 36px;
}

.inquiry-form {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.form-group.full-width {
    grid-column: 1 / -1;
}

.form-group label {
    font-size: 14px;
    font-weight: 600;
    color: var(--text-primary);
}

.form-group input,
.form-group select,
.form-group textarea {
    padding: 12px 16px;
    border: 1px solid var(--border-light);
    border-radius: var(--radius-sm);
    font-size: 15px;
    font-family: inherit;
    background: var(--bg-warm);
    color: var(--text-primary);
    transition: var(--transition);
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(232, 93, 78, 0.1);
}

.form-group textarea {
    resize: vertical;
    min-height: 80px;
}

/* ===== 页脚 ===== */
.footer {
    background: var(--text-primary);
    color: white;
    padding: 60px 0 24px;
}

.footer-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 40px;
    flex-wrap: wrap;
    gap: 24px;
}

.footer-brand {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 20px;
    font-weight: 700;
}

.footer-brand .logo-icon {
    color: var(--primary-light);
}

.footer-brand p {
    font-size: 14px;
    color: rgba(255,255,255,0.6);
    font-weight: 400;
    margin-left: 8px;
}

.footer-links {
    display: flex;
    gap: 32px;
}

.footer-links a {
    color: rgba(255,255,255,0.7);
    text-decoration: none;
    font-size: 14px;
    transition: var(--transition);
}

.footer-links a:hover {
    color: white;
}

.footer-bottom {
    text-align: center;
    padding-top: 24px;
    border-top: 1px solid rgba(255,255,255,0.1);
    font-size: 13px;
    color: rgba(255,255,255,0.5);
}

/* ===== 悬浮客服 ===== */
.float-contact {
    position: fixed;
    bottom: 32px;
    right: 32px;
    z-index: 999;
}

.float-btn {
    width: 56px;
    height: 56px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--primary), var(--primary-dark));
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    box-shadow: 0 4px 16px rgba(232, 93, 78, 0.4);
    transition: var(--transition);
    animation: floatPulse 2s ease-in-out infinite;
}

@keyframes floatPulse {
    0%, 100% { box-shadow: 0 4px 16px rgba(232, 93, 78, 0.4); }
    50% { box-shadow: 0 4px 24px rgba(232, 93, 78, 0.6); }
}

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

.contact-panel {
    position: absolute;
    bottom: 70px;
    right: 0;
    width: 280px;
    background: var(--bg-white);
    border-radius: var(--radius);
    box-shadow: var(--shadow-medium);
    border: 1px solid var(--border-light);
    opacity: 0;
    visibility: hidden;
    transform: translateY(10px);
    transition: var(--transition);
}

.contact-panel.active {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.contact-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 20px;
    border-bottom: 1px solid var(--border-light);
}

.contact-header h4 {
    font-size: 16px;
    font-weight: 600;
}

.contact-header span {
    cursor: pointer;
    font-size: 20px;
    color: var(--text-light);
}

.contact-options {
    padding: 12px;
}

.contact-option {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px;
    border-radius: var(--radius-sm);
    text-decoration: none;
    color: inherit;
    transition: var(--transition);
    cursor: pointer;
}

.contact-option:hover {
    background: var(--bg-warm);
}

.option-icon {
    font-size: 24px;
}

.contact-option div {
    display: flex;
    flex-direction: column;
}

.contact-option strong {
    font-size: 14px;
    font-weight: 600;
}

.contact-option span {
    font-size: 12px;
    color: var(--text-light);
}

/* ===== 弹窗 ===== */
.modal {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 2000;
    opacity: 0;
    visibility: hidden;
    transition: var(--transition);
}

.modal.active {
    opacity: 1;
    visibility: visible;
}

.modal-content {
    background: var(--bg-white);
    border-radius: var(--radius);
    padding: 40px;
    max-width: 400px;
    width: 90%;
    text-align: center;
    position: relative;
    transform: scale(0.9);
    transition: var(--transition);
}

.modal.active .modal-content {
    transform: scale(1);
}

.modal-close {
    position: absolute;
    top: 16px;
    right: 20px;
    font-size: 24px;
    cursor: pointer;
    color: var(--text-light);
}

.qr-placeholder {
    width: 200px;
    height: 200px;
    margin: 20px auto;
    background: var(--bg-warm);
    border-radius: var(--radius-sm);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    border: 2px dashed var(--border-light);
}

.qr-placeholder p {
    font-size: 13px;
    color: var(--text-light);
    padding: 0 20px;
}

.qr-placeholder code {
    background: var(--bg-cream);
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 12px;
    margin-top: 8px;
}

/* ===== 响应式 ===== */
@media (max-width: 768px) {
    .navbar {
        padding: 0 20px;
    }

    .nav-links {
        display: none;
        position: absolute;
        top: 72px;
        left: 0;
        right: 0;
        background: var(--bg-warm);
        flex-direction: column;
        padding: 20px;
        gap: 16px;
        border-bottom: 1px solid var(--border-light);
    }

    .nav-links.active {
        display: flex;
    }

    .nav-toggle {
        display: block;
    }

    .hero {
        padding: 100px 20px 60px;
    }

    .form-row {
        grid-template-columns: 1fr;
    }

    .timeline::before {
        left: 20px;
    }

    .timeline-item,
    .timeline-item:nth-child(odd),
    .timeline-item:nth-child(even) {
        flex-direction: row;
        padding-left: 48px;
    }

    .timeline-dot {
        left: 20px;
        transform: none;
    }

    .timeline-content {
        width: 100%;
    }

    .inquiry-card {
        padding: 28px;
    }

    .footer-content {
        flex-direction: column;
        text-align: center;
    }
}

/* ===== 滚动条美化 ===== */
::-webkit-scrollbar {
    width: 6px;
}

::-webkit-scrollbar-track {
    background: transparent;
}

::-webkit-scrollbar-thumb {
    background: var(--border-light);
    border-radius: 3px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--text-light);
}
