/* ===== 变量与重置 ===== */
:root {
    --primary: #10b981;
    --primary-dark: #059669;
    --primary-light: #d1fae5;
    --secondary: #0f172a;
    --text: #334155;
    --text-light: #64748b;
    --bg: #f8fafc;
    --white: #ffffff;
    --border: #e2e8f0;
    --shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 20px 25px -5px rgba(0, 0, 0, 0.1);
    --radius: 12px;
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

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

html {
    scroll-behavior: smooth;
    scroll-padding-top: 80px;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'PingFang SC', 'Hiragino Sans GB', 'Microsoft YaHei', sans-serif;
    line-height: 1.7;
    color: var(--text);
    background: var(--white);
    -webkit-font-smoothing: antialiased;
}

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

a {
    text-decoration: none;
    color: inherit;
}

/* ===== 按钮 ===== */
.btn-primary {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: var(--primary);
    color: var(--white);
    padding: 12px 28px;
    border-radius: 8px;
    font-weight: 600;
    font-size: 15px;
    border: none;
    cursor: pointer;
    transition: var(--transition);
}

.btn-primary:hover {
    background: var(--primary-dark);
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

.btn-secondary {
    display: inline-flex;
    align-items: center;
    background: transparent;
    color: var(--white);
    padding: 12px 28px;
    border-radius: 8px;
    font-weight: 600;
    font-size: 15px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    cursor: pointer;
    transition: var(--transition);
}

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

.btn-block {
    width: 100%;
    justify-content: center;
}

/* ===== 导航栏 ===== */
.header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    box-shadow: var(--shadow);
    z-index: 1000;
    padding: 16px 0;
}

.header .container {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.logo h1 {
    font-size: 24px;
    font-weight: 700;
    color: var(--primary);
    letter-spacing: -0.5px;
}

.nav ul {
    display: flex;
    list-style: none;
    gap: 32px;
}

.nav a {
    color: var(--text);
    font-weight: 500;
    font-size: 15px;
    padding: 8px 0;
    position: relative;
    transition: var(--transition);
}

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

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

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

.mobile-toggle {
    display: none;
    flex-direction: column;
    gap: 5px;
    cursor: pointer;
    padding: 5px;
}

.mobile-toggle span {
    width: 24px;
    height: 2px;
    background: var(--text);
    transition: var(--transition);
}

/* ===== Hero 区域 ===== */
/* ===== 轮播图 ===== */
.hero-slider {
    position: relative;
    width: 100%;
    height: 70vh;
    min-height: 500px;
    max-height: 700px;
    overflow: hidden;
}

.hero-slide {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    visibility: hidden;
    transition: all 0.8s ease;
}

.hero-slide.active {
    opacity: 1;
    visibility: visible;
}

.hero-slide img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
}

.hero-slide .hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, rgba(15, 23, 42, 0.75) 0%, rgba(30, 58, 95, 0.65) 100%);
}

.hero-slide .hero-content {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    z-index: 2;
    width: 100%;
    max-width: 800px;
    text-align: center;
    margin: 0 auto;
    padding: 0 24px;
}

.hero-slide .hero-content .hero-tag {
    display: inline-block;
    background: var(--primary-light);
    color: var(--primary-dark);
    padding: 8px 16px;
    border-radius: 20px;
    font-size: 14px;
    font-weight: 600;
    margin-bottom: 24px;
}

.hero-slide .hero-content h1 {
    font-size: clamp(32px, 5vw, 56px);
    font-weight: 800;
    color: var(--white);
    line-height: 1.1;
    margin-bottom: 24px;
    letter-spacing: -1px;
}

.hero-slide .hero-content p {
    font-size: 18px;
    color: rgba(255, 255, 255, 0.9);
    margin-bottom: 40px;
}

/* 轮播指示器 */
.hero-dots {
    position: absolute;
    bottom: 40px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 12px;
    z-index: 10;
}

.hero-dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.4);
    cursor: pointer;
    transition: all 0.3s ease;
}

.hero-dot.active {
    background: var(--primary);
    transform: scale(1.3);
}

.hero-dot:hover {
    background: rgba(255, 255, 255, 0.7);
}

.hero h1 {
    font-size: clamp(32px, 5vw, 56px);
    font-weight: 800;
    color: var(--white);
    line-height: 1.1;
    margin-bottom: 24px;
    letter-spacing: -1px;
}

.hero p {
    font-size: 18px;
    color: rgba(255, 255, 255, 0.8);
    margin-bottom: 40px;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

.hero-buttons {
    display: flex;
    gap: 16px;
    justify-content: center;
    flex-wrap: wrap;
    margin-bottom: 60px;
}

.hero-stats {
    display: flex;
    gap: 48px;
    justify-content: center;
    padding-top: 40px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.hero-stat {
    text-align: center;
}

.hero-stat strong {
    display: block;
    font-size: 32px;
    color: var(--white);
    font-weight: 700;
}

.hero-stat span {
    font-size: 14px;
    color: rgba(255, 255, 255, 0.6);
}

/* ===== 通用 Section ===== */
section {
    padding: 100px 0;
}

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

.section-header h2 {
    font-size: 36px;
    font-weight: 700;
    color: var(--secondary);
    margin-bottom: 12px;
    letter-spacing: -0.5px;
}

.section-header p {
    font-size: 16px;
    color: var(--text-light);
}

.section-tag {
    display: inline-block;
    background: var(--primary-light);
    color: var(--primary-dark);
    padding: 6px 14px;
    border-radius: 20px;
    font-size: 13px;
    font-weight: 600;
    margin-bottom: 16px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* ===== 服务 Tab ===== */
.service-tabs {
    display: flex;
    gap: 12px;
    justify-content: center;
    margin-bottom: 48px;
}

.tab-btn {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 14px 32px;
    background: var(--bg);
    border: 2px solid var(--border);
    border-radius: 10px;
    font-size: 15px;
    font-weight: 600;
    color: var(--text);
    cursor: pointer;
    transition: var(--transition);
}

.tab-btn i {
    font-size: 18px;
}

.tab-btn:hover {
    border-color: var(--primary);
    color: var(--primary);
}

.tab-btn.active {
    background: var(--primary);
    border-color: var(--primary);
    color: var(--white);
}

.tab-content {
    display: none;
}

.tab-content.active {
    display: grid;
    animation: fadeIn 0.4s ease;
}

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

/* ===== 服务卡片 ===== */
.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 24px;
}

.service-card {
    background: var(--white);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 32px;
    text-align: center;
    transition: var(--transition);
}

.service-card:hover {
    border-color: var(--primary);
    box-shadow: var(--shadow-lg);
    transform: translateY(-4px);
}

.service-icon {
    width: 64px;
    height: 64px;
    background: var(--primary-light);
    border-radius: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 20px;
    font-size: 28px;
    color: var(--primary);
}

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

.service-card p {
    font-size: 14px;
    color: var(--text-light);
    line-height: 1.6;
}

/* ===== 关于我们 ===== */
.about {
    background: var(--bg);
}

.company-motto {
    text-align: center;
    background: var(--white);
    border-radius: var(--radius);
    padding: 40px;
    margin-bottom: 60px;
    box-shadow: var(--shadow);
}

.company-motto h3 {
    font-size: 24px;
    font-weight: 700;
    color: var(--primary);
    margin-bottom: 16px;
}

.company-motto p {
    font-size: 20px;
    color: var(--text);
    font-weight: 500;
    letter-spacing: 2px;
}

.about-grid {
    display: grid;
    grid-template-columns: 1.2fr 1fr;
    gap: 80px;
    align-items: center;
}

.about-content h2 {
    font-size: 36px;
    font-weight: 700;
    color: var(--secondary);
    margin-bottom: 24px;
    letter-spacing: -0.5px;
}

.about-content p {
    color: var(--text);
    margin-bottom: 16px;
    line-height: 1.8;
}

.about-features {
    list-style: none;
    margin-top: 32px;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
}

.about-features li {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 15px;
    color: var(--text);
}

.about-features i {
    color: var(--primary);
    font-size: 18px;
}

.about-stats {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
}

.stat-card {
    background: var(--white);
    border-radius: var(--radius);
    padding: 40px 32px;
    text-align: center;
    box-shadow: var(--shadow);
    transition: var(--transition);
}

.stat-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-lg);
}

.stat-number {
    font-size: 48px;
    font-weight: 800;
    color: var(--primary);
    line-height: 1;
    margin-bottom: 8px;
}

.stat-label {
    font-size: 15px;
    color: var(--text-light);
    font-weight: 500;
}

/* ===== 工程案例 ===== */
.projects-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(340px, 1fr));
    gap: 32px;
}

.project-card {
    background: var(--white);
    border-radius: var(--radius);
    overflow: hidden;
    box-shadow: var(--shadow);
    transition: var(--transition);
}

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

.project-img {
    height: 220px;
    overflow: hidden;
}

.project-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.project-card:hover .project-img img {
    transform: scale(1.08);
}

.project-info {
    padding: 28px;
}

.project-tag {
    display: inline-block;
    background: var(--primary-light);
    color: var(--primary-dark);
    padding: 4px 12px;
    border-radius: 6px;
    font-size: 12px;
    font-weight: 600;
    margin-bottom: 12px;
}

.project-info h3 {
    font-size: 18px;
    font-weight: 600;
    color: var(--secondary);
    margin-bottom: 8px;
}

.project-info p {
    font-size: 14px;
    color: var(--text-light);
}

/* ===== 联系我们 ===== */
.contact {
    background: var(--bg);
}

.contact-wrapper {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    align-items: start;
}

.contact-info h2 {
    font-size: 36px;
    font-weight: 700;
    color: var(--secondary);
    margin-bottom: 16px;
    line-height: 1.2;
}

.contact-info > p {
    font-size: 16px;
    color: var(--text-light);
    margin-bottom: 40px;
}

.contact-items {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

.contact-item {
    display: flex;
    gap: 16px;
    align-items: flex-start;
}

.contact-icon {
    width: 48px;
    height: 48px;
    background: var(--primary);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--white);
    font-size: 18px;
    flex-shrink: 0;
}

.contact-item h4 {
    font-size: 14px;
    font-weight: 600;
    color: var(--text);
    margin-bottom: 4px;
}

.contact-item a,
.contact-item p {
    font-size: 15px;
    color: var(--text-light);
}

.contact-item a:hover {
    color: var(--primary);
}

/* 在线联系按钮 */
.btn-online {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    width: 100%;
    margin-top: 32px;
    padding: 16px 32px;
    font-size: 16px;
}

.btn-online i {
    font-size: 18px;
}

/* 微信二维码 */
.contact-wechat {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    background: var(--white);
    border-radius: var(--radius);
    padding: 32px;
    box-shadow: var(--shadow);
}

.wechat-qr {
    width: 180px;
    height: 180px;
    border-radius: 12px;
    overflow: hidden;
    margin-bottom: 16px;
}

.wechat-qr img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.contact-wechat p {
    font-size: 15px;
    color: var(--text);
    font-weight: 500;
}

/* 联系表单 */
.contact-form {
    background: var(--white);
    border-radius: var(--radius);
    padding: 40px;
    box-shadow: var(--shadow);
}

.form-group {
    margin-bottom: 20px;
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 14px 18px;
    border: 2px solid var(--border);
    border-radius: 10px;
    font-size: 15px;
    font-family: inherit;
    color: var(--text);
    transition: var(--transition);
    background: var(--white);
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--primary);
}

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

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

.footer-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-bottom: 40px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    margin-bottom: 30px;
}

.footer-brand h3 {
    font-size: 24px;
    font-weight: 700;
    color: var(--primary);
    margin-bottom: 8px;
}

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

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

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

.footer-links a:hover {
    color: var(--primary);
}

.footer-bottom {
    text-align: center;
}

.footer-bottom p {
    font-size: 13px;
    color: rgba(255, 255, 255, 0.5);
}

/* ===== 返回顶部 ===== */
.back-to-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 50px;
    height: 50px;
    background: var(--primary);
    color: var(--white);
    border: none;
    border-radius: 50%;
    font-size: 18px;
    cursor: pointer;
    opacity: 0;
    visibility: hidden;
    transition: var(--transition);
    z-index: 999;
    box-shadow: var(--shadow-lg);
}

.back-to-top.show {
    opacity: 1;
    visibility: visible;
}

.back-to-top:hover {
    background: var(--primary-dark);
    transform: translateY(-4px);
}

/* ===== 响应式 ===== */
@media (max-width: 992px) {
    .nav {
        display: none;
    }
    
    .header .btn-primary {
        display: none;
    }
    
    .mobile-toggle {
        display: flex;
    }
    
    .nav.active {
        display: block;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background: var(--white);
        padding: 24px;
        box-shadow: var(--shadow-lg);
    }
    
    .nav.active ul {
        flex-direction: column;
        gap: 16px;
    }
    
    .about-grid,
    .contact-wrapper {
        grid-template-columns: 1fr;
        gap: 48px;
    }
    
    .hero-stats {
        gap: 32px;
    }
}

@media (max-width: 768px) {
    section {
        padding: 60px 0;
    }
    
    .hero {
        padding: 100px 0 60px;
    }
    
    .hero-buttons {
        flex-direction: column;
        align-items: center;
    }
    
    .hero-buttons .btn-primary,
    .hero-buttons .btn-secondary {
        width: 100%;
        max-width: 280px;
        justify-content: center;
    }
    
    .hero-stats {
        flex-direction: column;
        gap: 24px;
    }
    
    .service-tabs {
        flex-direction: column;
        align-items: center;
    }
    
    .tab-btn {
        width: 100%;
        max-width: 300px;
        justify-content: center;
    }
    
    .services-grid,
    .projects-grid {
        grid-template-columns: 1fr;
    }
    
    .about-stats {
        grid-template-columns: 1fr 1fr;
    }
    
    .about-features {
        grid-template-columns: 1fr;
    }
    
    .footer-content {
        flex-direction: column;
        gap: 24px;
        text-align: center;
    }
    
    .footer-links {
        flex-wrap: wrap;
        justify-content: center;
    }
    
    .contact-form {
        padding: 24px;
    }
}

@media (max-width: 480px) {
    .container {
        padding: 0 16px;
    }
    
    .hero h1 {
        font-size: 28px;
    }
    
    .section-header h2,
    .about-content h2,
    .contact-info h2 {
        font-size: 28px;
    }
    
    .stat-number {
        font-size: 36px;
    }
    
    .about-stats {
        grid-template-columns: 1fr;
    }
}
