/* 全局基础重置 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Arial', sans-serif;
}

/* 全局变量：后续改颜色/尺寸直接改这里就行 */
:root {
    --primary-color: #2284E5; /* 主色调
    --secondary-color: #2b2b2b;
    --light-gray: #f5f5f5;
    --white: #ffffff;
    --max-width: 1200px; /* 页面最大宽度 */
}

body {
    line-height: 1.6;
    color: var(--secondary-color);
}

/* 通用容器：控制页面内容宽度，居中对齐 */
.container {
    max-width: var(--max-width);
    margin: 0 auto;
    padding: 0 20px;
    width: 100%;
}

/* ====================== 核心：导航菜单样式 ====================== */
.navbar {
    background-color: var(--white);
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    position: sticky;
    top: 0;
    z-index: 999;
}

.nav-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 80px;
}

/* 网站logo */
.logo a {
    font-size: 24px;
    font-weight: bold;
    color: var(--primary-color);
    text-decoration: none;
}

/* 桌面端菜单 */
.nav-menu {
    display: flex;
    list-style: none;
    gap: 30px;
}

.nav-item a {
    text-decoration: none;
    color: var(--secondary-color);
    font-weight: 500;
    font-size: 16px;
    transition: color 0.3s ease;
}

/* 菜单hover效果，当前页面高亮 */
.nav-item a:hover,
.nav-item a.active {
    color: var(--primary-color);
}

/* 移动端汉堡菜单按钮 */
.hamburger {
    display: none;
    flex-direction: column;
    cursor: pointer;
}

.hamburger span {
    width: 25px;
    height: 3px;
    background-color: var(--secondary-color);
    margin: 4px 0;
    transition: 0.3s;
}

/* ====================== 通用按钮样式 ====================== */
.btn {
    display: inline-block;
    padding: 12px 24px;
    background-color: var(--primary-color);
    color: var(--white);
    text-decoration: none;
    border-radius: 6px;
    font-weight: 500;
    border: none;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

.btn:hover {
    background-color: #b82020;
}

.btn-outline {
    background-color: transparent;
    border: 2px solid var(--primary-color);
    color: var(--primary-color);
}

.btn-outline:hover {
    background-color: var(--primary-color);
    color: var(--white);
}

/* ====================== 首页搜索区样式 ====================== */
.hero-section {
    background-color: var(--light-gray);
    padding: 80px 0;
    text-align: center;
}

.hero-title {
    font-size: 40px;
    margin-bottom: 20px;
    color: var(--secondary-color);
}

.hero-desc {
    font-size: 18px;
    margin-bottom: 40px;
    color: #666;
    max-width: 700px;
    margin-left: auto;
    margin-right: auto;
}

.search-box {
    max-width: 800px;
    margin: 0 auto;
    display: flex;
    gap: 10px;
    background-color: var(--white);
    padding: 10px;
    border-radius: 8px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.08);
}

.search-input {
    flex: 1;
    padding: 15px 20px;
    border: 1px solid #eee;
    border-radius: 6px;
    font-size: 16px;
    outline: none;
}

.search-input:focus {
    border-color: var(--primary-color);
}

/* ====================== 服务卡片区通用样式 ====================== */
.section {
    padding: 60px 0;
}

.section-title {
    font-size: 32px;
    text-align: center;
    margin-bottom: 50px;
    color: var(--secondary-color);
}

.cards-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 30px;
}

.card {
    background-color: var(--white);
    border-radius: 8px;
    padding: 30px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.05);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.1);
}

.card-icon {
    font-size: 40px;
    color: var(--primary-color);
    margin-bottom: 20px;
}

.card-title {
    font-size: 22px;
    margin-bottom: 15px;
    color: var(--secondary-color);
}

.card-desc {
    color: #666;
    margin-bottom: 20px;
}

/* ====================== 页脚样式 ====================== */
.footer {
    background-color: var(--secondary-color);
    color: var(--white);
    padding: 60px 0 20px;
    margin-top: 60px;
}

.footer-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 40px;
    margin-bottom: 40px;
}

.footer-col h3 {
    font-size: 18px;
    margin-bottom: 20px;
    color: var(--white);
}

.footer-col ul {
    list-style: none;
}

.footer-col ul li {
    margin-bottom: 10px;
}

.footer-col ul li a {
    color: #ccc;
    text-decoration: none;
    transition: color 0.3s ease;
}

.footer-col ul li a:hover {
    color: var(--white);
}

.footer-bottom {
    text-align: center;
    padding-top: 20px;
    border-top: 1px solid #444;
    color: #999;
}

/* ====================== 响应式适配：移动端 ====================== */
@media screen and (max-width: 768px) {
    /* 移动端菜单 */
    .hamburger {
        display: flex;
    }

    .nav-menu {
        position: fixed;
        left: -100%;
        top: 80px;
        flex-direction: column;
        background-color: var(--white);
        width: 100%;
        text-align: center;
        transition: 0.3s;
        box-shadow: 0 10px 15px rgba(0,0,0,0.1);
        padding: 30px 0;
        gap: 20px;
    }

    .nav-menu.active {
        left: 0;
    }

    /* 移动端搜索框 */
    .search-box {
        flex-direction: column;
    }

    .hero-title {
        font-size: 28px;
    }

    .section-title {
        font-size: 24px;
    }
}