/* ========================================
   迪思六线数字科技有限公司 - 全局样式
   家装设计风 | 浅灰 + 原木色 + 米白
   ======================================== */

/* CSS Reset & 基础设置 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    font-size: 16px;
}

body {
    font-family: "PingFang SC", "Microsoft YaHei", "Helvetica Neue", Arial, sans-serif;
    background-color: #f5f3f0;
    color: #4a4a4a;
    line-height: 1.8;
    overflow-x: hidden;
}

a {
    text-decoration: none;
    color: inherit;
    transition: all 0.3s ease;
}

ul, ol {
    list-style: none;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

/* ========================================
   颜色变量
   ======================================== */
:root {
    --primary-wood: #c9a87c;
    --secondary-wood: #b8956a;
    --light-beige: #f5f3f0;
    --medium-beige: #e8e4df;
    --dark-gray: #4a4a4a;
    --light-gray: #8c8c8c;
    --white: #ffffff;
    --text-dark: #333333;
    --text-light: #666666;
    --border-color: #dcd9d4;
    --shadow-light: rgba(0, 0, 0, 0.05);
    --shadow-medium: rgba(0, 0, 0, 0.1);
}

/* ========================================
   顶部导航栏
   ======================================== */
.header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    background: transparent;
    transition: all 0.4s ease;
    padding: 20px 0;
}

.header.scrolled {
    background: rgba(245, 243, 240, 0.98);
    box-shadow: 0 2px 20px var(--shadow-light);
    padding: 15px 0;
}

.header-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 40px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    display: flex;
    align-items: center;
    gap: 15px;
}

.logo img {
    height: 50px;
    width: auto;
}

.logo-text {
    font-size: 1.5rem;
    font-weight: 600;
    color: var(--text-dark);
    letter-spacing: 2px;
}

.nav-menu {
    display: flex;
    gap: 40px;
}

.nav-menu li a {
    font-size: 1rem;
    color: var(--text-dark);
    font-weight: 500;
    position: relative;
    padding: 8px 0;
}

.nav-menu li a::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--primary-wood);
    transition: width 0.3s ease;
}

.nav-menu li a:hover::after,
.nav-menu li a.active::after {
    width: 100%;
}

.nav-menu li a:hover,
.nav-menu li a.active {
    color: var(--primary-wood);
}

.hamburger {
    display: none;
    flex-direction: column;
    cursor: pointer;
    gap: 5px;
}

.hamburger span {
    width: 28px;
    height: 3px;
    background: var(--text-dark);
    transition: all 0.3s ease;
}

.hamburger.active span:nth-child(1) {
    transform: rotate(45deg) translate(6px, 6px);
}

.hamburger.active span:nth-child(2) {
    opacity: 0;
}

.hamburger.active span:nth-child(3) {
    transform: rotate(-45deg) translate(6px, -6px);
}

/* ========================================
   页脚
   ======================================== */
.footer {
    background: var(--text-dark);
    color: var(--light-beige);
    padding: 80px 0 40px;
}

.footer-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 40px;
}

.footer-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 60px;
    margin-bottom: 60px;
}

.footer-section h4 {
    font-size: 1.2rem;
    margin-bottom: 25px;
    color: var(--primary-wood);
    font-weight: 600;
}

.footer-section p {
    color: #b0b0b0;
    line-height: 2;
    font-size: 0.95rem;
}

.footer-section ul li {
    margin-bottom: 12px;
}

.footer-section ul li a {
    color: #b0b0b0;
    transition: color 0.3s ease;
}

.footer-section ul li a:hover {
    color: var(--primary-wood);
}

.contact-info li {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 15px;
    color: #b0b0b0;
}

.footer-bottom {
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    padding-top: 30px;
    text-align: center;
    color: #888;
    font-size: 0.9rem;
}

/* ========================================
   通用组件
   ======================================== */
.container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 40px;
}

.section {
    padding: 120px 0;
}

.section-title {
    text-align: center;
    margin-bottom: 60px;
}

.section-title h2 {
    font-size: 2.5rem;
    color: var(--text-dark);
    margin-bottom: 15px;
    font-weight: 600;
}

.section-title p {
    color: var(--text-light);
    font-size: 1.1rem;
    max-width: 600px;
    margin: 0 auto;
}

.btn {
    display: inline-block;
    padding: 15px 40px;
    background: var(--primary-wood);
    color: var(--white);
    border: none;
    border-radius: 0;
    font-size: 1rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    letter-spacing: 1px;
}

.btn:hover {
    background: var(--secondary-wood);
    transform: translateY(-2px);
    box-shadow: 0 10px 30px var(--shadow-medium);
}

.btn-outline {
    background: transparent;
    border: 2px solid var(--primary-wood);
    color: var(--primary-wood);
}

.btn-outline:hover {
    background: var(--primary-wood);
    color: var(--white);
}

/* ========================================
   动画效果
   ======================================== */
.fade-in {
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.8s ease;
}

.fade-in.visible {
    opacity: 1;
    transform: translateY(0);
}

/* ========================================
   响应式设计
   ======================================== */
@media (max-width: 1024px) {
    .header-container {
        padding: 0 25px;
    }

    .nav-menu {
        gap: 25px;
    }

    .footer-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 40px;
    }

    .section {
        padding: 80px 0;
    }
}

@media (max-width: 768px) {
    .hamburger {
        display: flex;
    }

    .nav-menu {
        position: fixed;
        top: 80px;
        left: -100%;
        width: 100%;
        height: calc(100vh - 80px);
        background: var(--light-beige);
        flex-direction: column;
        align-items: center;
        justify-content: center;
        gap: 30px;
        transition: left 0.4s ease;
    }

    .nav-menu.active {
        left: 0;
    }

    .container {
        padding: 0 25px;
    }

    .section-title h2 {
        font-size: 2rem;
    }

    .footer-grid {
        grid-template-columns: 1fr;
        gap: 40px;
    }

    .logo-text {
        font-size: 1.2rem;
    }
}

@media (max-width: 480px) {
    html {
        font-size: 14px;
    }

    .header-container {
        padding: 0 20px;
    }

    .container {
        padding: 0 20px;
    }

    .btn {
        padding: 12px 30px;
        font-size: 0.9rem;
    }
}
