/* ========================================
   麦克斯洗衣工厂官网 - 主样式文件
   ======================================== */

/* CSS变量定义 */
:root {
    --color-primary: #1E88E5;
    --color-primary-dark: #1565C0;
    --color-secondary: #4CAF50;
    --color-accent: #FF9800;
    --color-bg-white: #FFFFFF;
    --color-bg-gray: #F5F5F5;
    --color-bg-dark: #1a1a2e;
    --color-text-dark: #333333;
    --color-text-gray: #666666;
    --color-text-light: #999999;
    --color-border: #E0E0E0;
    --shadow-sm: 0 2px 8px rgba(0,0,0,0.08);
    --shadow-md: 0 4px 16px rgba(0,0,0,0.12);
    --shadow-lg: 0 8px 32px rgba(0,0,0,0.15);
    --transition: all 0.3s ease;
    --radius-sm: 8px;
    --radius-md: 12px;
    --radius-lg: 16px;
}

/* 重置样式 */
*, *::before, *::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Microsoft YaHei', 'Noto Sans SC', -apple-system, BlinkMacSystemFont, sans-serif;
    font-size: 16px;
    line-height: 1.6;
    color: var(--color-text-dark);
    background: var(--color-bg-white);
}

a {
    text-decoration: none;
    color: inherit;
    transition: var(--transition);
}

ul, ol {
    list-style: none;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

button {
    cursor: pointer;
    border: none;
    outline: none;
    font-family: inherit;
}

/* 容器 */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* 通用标题 */
.section-title {
    text-align: center;
    margin-bottom: 50px;
}

.section-title h2 {
    font-size: 32px;
    font-weight: 700;
    color: var(--color-text-dark);
    margin-bottom: 12px;
}

.section-title p {
    font-size: 16px;
    color: var(--color-text-gray);
}

/* 按钮样式 */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 12px 28px;
    font-size: 16px;
    font-weight: 500;
    border-radius: var(--radius-sm);
    transition: var(--transition);
}

.btn-primary {
    background: var(--color-primary);
    color: white;
}

.btn-primary:hover {
    background: var(--color-primary-dark);
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

.btn-accent {
    background: var(--color-accent);
    color: white;
}

.btn-accent:hover {
    background: #F57C00;
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

.btn-outline {
    border: 2px solid var(--color-primary);
    color: var(--color-primary);
    background: transparent;
}

.btn-outline:hover {
    background: var(--color-primary);
    color: white;
}

/* ========== 导航栏 ========== */
.header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    background: white;
    box-shadow: var(--shadow-sm);
    transition: var(--transition);
}

.header.scrolled {
    background: rgba(255, 255, 255, 0.98);
}

.nav {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 70px;
}

.logo {
    display: flex;
    align-items: center;
    gap: 10px;
}

.logo-icon {
    width: 46px;
    height: 46px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    flex-shrink: 0;
}

.logo-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.logo-text {
    font-size: 22px;
    font-weight: 700;
    color: var(--color-primary);
}

.nav-menu {
    display: flex;
    align-items: center;
    gap: 8px;
}

.nav-item {
    position: relative;
}

.nav-link {
    display: flex;
    align-items: center;
    padding: 10px 16px;
    font-size: 15px;
    color: var(--color-text-dark);
    border-radius: var(--radius-sm);
}

.nav-link:hover, .nav-link.active {
    color: var(--color-primary);
    background: rgba(30, 136, 229, 0.08);
}

.nav-link i {
    margin-left: 5px;
    font-size: 12px;
    transition: var(--transition);
}

/* 下拉菜单 */
.dropdown {
    position: absolute;
    top: 100%;
    left: 0;
    min-width: 180px;
    background: white;
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-lg);
    opacity: 0;
    visibility: hidden;
    transform: translateY(10px);
    transition: var(--transition);
    padding: 8px 0;
}

.nav-item:hover .dropdown {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.dropdown-item {
    display: block;
    padding: 10px 20px;
    font-size: 14px;
    color: var(--color-text-dark);
}

.dropdown-item:hover {
    background: var(--color-bg-gray);
    color: var(--color-primary);
}

.nav-btn {
    margin-left: 20px;
}

/* ========== Banner轮播 ========== */
.banner {
    position: relative;
    height: 600px;
    margin-top: 70px;
    overflow: hidden;
}

.banner-slide {
    position: absolute;
    width: 100%;
    height: 100%;
    opacity: 0;
    transition: opacity 0.8s ease;
}

.banner-slide.active {
    opacity: 1;
}

.banner-bg {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.banner-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, rgba(30, 136, 229, 0.85), rgba(76, 175, 80, 0.7));
    display: flex;
    align-items: center;
    justify-content: center;
}

.banner-content {
    text-align: center;
    color: white;
    max-width: 800px;
    padding: 0 20px;
}

.banner-content h1 {
    font-size: 48px;
    font-weight: 700;
    margin-bottom: 20px;
    text-shadow: 0 2px 10px rgba(0,0,0,0.2);
}

.banner-content p {
    font-size: 20px;
    margin-bottom: 30px;
    opacity: 0.95;
}

.banner-dots {
    position: absolute;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 12px;
}

.banner-dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: rgba(255,255,255,0.5);
    cursor: pointer;
    transition: var(--transition);
}

.banner-dot.active {
    background: white;
    transform: scale(1.2);
}

.banner-arrow {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 56px;
    height: 56px;
    background: transparent;
    border: 2px solid rgba(255, 255, 255, 0.4);
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: 10;
    backdrop-filter: blur(4px);
}

.banner-arrow:hover {
    background: rgba(255, 255, 255, 0.15);
    border-color: rgba(255, 255, 255, 0.8);
    transform: translateY(-50%) scale(1.08);
}

.banner-arrow .arrow-line {
    position: relative;
    width: 12px;
    height: 12px;
    border-right: 2px solid rgba(255, 255, 255, 0.8);
    border-bottom: 2px solid rgba(255, 255, 255, 0.8);
    transition: all 0.3s ease;
}

.banner-arrow-prev .arrow-line {
    transform: rotate(135deg);
    margin-left: 4px;
}

.banner-arrow-next .arrow-line {
    transform: rotate(-45deg);
    margin-right: 4px;
}

.banner-arrow:hover .arrow-line {
    border-color: #fff;
}

.banner-arrow-prev:hover .arrow-line {
    animation: arrowLeft 0.6s ease infinite;
}

.banner-arrow-next:hover .arrow-line {
    animation: arrowRight 0.6s ease infinite;
}

@keyframes arrowLeft {
    0%, 100% { transform: rotate(135deg) translateX(0); }
    50% { transform: rotate(135deg) translateX(3px); }
}

@keyframes arrowRight {
    0%, 100% { transform: rotate(-45deg) translateX(0); }
    50% { transform: rotate(-45deg) translateX(3px); }
}

.banner-arrow-prev {
    left: 40px;
}

.banner-arrow-next {
    right: 40px;
}

/* ========== 数字展示区 ========== */
.stats {
    padding: 60px 0;
    background: var(--color-bg-gray);
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 30px;
}

.stat-item {
    text-align: center;
    padding: 30px 20px;
    background: white;
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-sm);
    transition: var(--transition);
}

.stat-item:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-md);
}

.stat-number {
    font-size: 42px;
    font-weight: 700;
    color: var(--color-primary);
    margin-bottom: 8px;
}

.stat-label {
    font-size: 15px;
    color: var(--color-text-gray);
}

/* ========== 服务卡片 ========== */
.services {
    padding: 80px 0;
}

.services-header {
    text-align: center;
    margin-bottom: 50px;
}

.services-header .tag {
    display: inline-block;
    padding: 6px 16px;
    background: linear-gradient(135deg, var(--color-primary), var(--color-secondary));
    color: white;
    border-radius: 20px;
    font-size: 14px;
    margin-bottom: 15px;
}

.services-header h2 {
    font-size: 32px;
    color: var(--color-text-dark);
}

.services-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 24px;
    margin-bottom: 50px;
}

.service-card {
    background: white;
    border-radius: var(--radius-md);
    padding: 30px 24px;
    text-align: center;
    border: 1px solid var(--color-border);
    transition: var(--transition);
    cursor: pointer;
}

.service-card:hover {
    border-color: var(--color-primary);
    transform: translateY(-8px);
    box-shadow: var(--shadow-lg);
}

.service-icon {
    width: 70px;
    height: 70px;
    margin: 0 auto 20px;
    background: linear-gradient(135deg, rgba(30,136,229,0.1), rgba(76,175,80,0.1));
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 32px;
}

.service-card h3 {
    font-size: 18px;
    color: var(--color-text-dark);
    margin-bottom: 10px;
}

.service-card p {
    font-size: 14px;
    color: var(--color-text-gray);
}

/* 优势展示 */
.advantages {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 30px;
    padding: 40px;
    background: var(--color-bg-gray);
    border-radius: var(--radius-lg);
}

.advantage-item {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 15px;
    color: var(--color-text-dark);
}

.advantage-item i {
    font-size: 20px;
    color: var(--color-primary);
}

/* ========== 流程展示 ========== */
.process {
    padding: 80px 0;
    background: var(--color-bg-gray);
}

.process-timeline {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    position: relative;
    padding: 40px 0;
}

.process-timeline::before {
    content: '';
    position: absolute;
    top: 65px;
    left: 50px;
    right: 50px;
    height: 4px;
    background: var(--color-border);
    z-index: 1;
}

.process-step {
    flex: 1;
    text-align: center;
    position: relative;
    z-index: 2;
}

.step-icon {
    width: 60px;
    height: 60px;
    margin: 0 auto 20px;
    background: white;
    border: 3px solid var(--color-primary);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    color: var(--color-primary);
    transition: var(--transition);
}

.process-step:hover .step-icon {
    background: var(--color-primary);
    color: white;
    transform: scale(1.1);
}

.step-title {
    font-size: 16px;
    font-weight: 600;
    color: var(--color-text-dark);
}

/* ========== 客户评价 ========== */
.testimonials {
    padding: 80px 0;
}

.testimonial-slider {
    max-width: 800px;
    margin: 0 auto;
    text-align: center;
}

.testimonial-item {
    padding: 40px;
    background: var(--color-bg-gray);
    border-radius: var(--radius-lg);
}

.testimonial-content {
    font-size: 18px;
    color: var(--color-text-dark);
    line-height: 1.8;
    margin-bottom: 25px;
    font-style: italic;
}

.testimonial-author {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 15px;
}

.author-avatar {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background: var(--color-primary);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
}

.author-info h4 {
    font-size: 16px;
    color: var(--color-text-dark);
}

.author-info .rating {
    color: #FFC107;
}

/* ========== Footer ========== */
.footer {
    background: var(--color-bg-dark);
    color: white;
    padding: 60px 0 30px;
}

.footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr;
    gap: 40px;
    margin-bottom: 40px;
}

.footer-brand .logo-text {
    color: white;
    margin-bottom: 15px;
}

.footer-brand p {
    color: rgba(255,255,255,0.7);
    font-size: 14px;
    line-height: 1.8;
}

.footer-col h4 {
    font-size: 16px;
    margin-bottom: 20px;
    color: white;
}

.footer-links a {
    display: block;
    color: rgba(255,255,255,0.7);
    font-size: 14px;
    padding: 6px 0;
}

.footer-links a:hover {
    color: white;
}

.footer-contact p {
    display: flex;
    align-items: center;
    gap: 10px;
    color: rgba(255,255,255,0.7);
    font-size: 14px;
    margin-bottom: 12px;
}

.footer-bottom {
    text-align: center;
    padding-top: 30px;
    border-top: 1px solid rgba(255,255,255,0.1);
}

.footer-bottom p {
    color: rgba(255,255,255,0.5);
    font-size: 14px;
}

.footer-bottom a {
    color: rgba(255,255,255,0.95);
    text-decoration: underline;
    text-underline-offset: 2px;
}

.footer-bottom a:hover {
    color: #FFFFFF;
}

/* ========== 悬浮按钮 ========== */
.float-btns {
    position: fixed;
    right: 30px;
    bottom: 100px;
    z-index: 999;
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.float-btn {
    width: 50px;
    height: 50px;
    background: var(--color-primary);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    box-shadow: var(--shadow-md);
    transition: var(--transition);
}

.float-btn:hover {
    transform: scale(1.1);
    background: var(--color-primary-dark);
}

.float-btn.accent {
    background: var(--color-accent);
}

.float-btn.accent:hover {
    background: #F57C00;
}

#backTop {
    opacity: 0;
    visibility: hidden;
}

#backTop.show {
    opacity: 1;
    visibility: visible;
}

/* ========== 页面Banner ========== */
.page-banner {
    height: 300px;
    margin-top: 70px;
    background: linear-gradient(135deg, var(--color-primary), var(--color-secondary));
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    color: white;
}

.page-banner h1 {
    font-size: 36px;
    margin-bottom: 12px;
}

.page-banner p {
    font-size: 18px;
    opacity: 0.9;
}

.breadcrumb {
    margin-top: 20px;
    font-size: 14px;
    opacity: 0.8;
}

.breadcrumb a:hover {
    text-decoration: underline;
}

/* ========== Tab切换 ========== */
.tabs {
    display: flex;
    justify-content: center;
    gap: 20px;
    margin-bottom: 40px;
}

.tab-btn {
    padding: 15px 30px;
    background: white;
    border: 2px solid var(--color-border);
    border-radius: var(--radius-sm);
    font-size: 16px;
    color: var(--color-text-dark);
    transition: var(--transition);
}

.tab-btn.active, .tab-btn:hover {
    background: var(--color-primary);
    border-color: var(--color-primary);
    color: white;
}

.tab-content {
    display: none;
}

.tab-content.active {
    display: block;
}

/* ========== 表格样式 ========== */
.price-table {
    width: 100%;
    background: white;
    border-radius: var(--radius-md);
    overflow: hidden;
    box-shadow: var(--shadow-sm);
}

.price-table th, .price-table td {
    padding: 16px 20px;
    text-align: left;
    border-bottom: 1px solid var(--color-border);
}

.price-table th {
    background: var(--color-primary);
    color: white;
    font-weight: 600;
}

.price-table tr:hover td {
    background: var(--color-bg-gray);
}

.price-table .price {
    color: var(--color-accent);
    font-weight: 600;
}

/* ========== 表单样式 ========== */
.form-group {
    margin-bottom: 24px;
}

.form-group label {
    display: block;
    font-size: 14px;
    color: var(--color-text-dark);
    margin-bottom: 8px;
    font-weight: 500;
}

.form-control {
    width: 100%;
    padding: 14px 16px;
    font-size: 15px;
    border: 1px solid var(--color-border);
    border-radius: var(--radius-sm);
    transition: var(--transition);
}

.form-control:focus {
    outline: none;
    border-color: var(--color-primary);
    box-shadow: 0 0 0 3px rgba(30, 136, 229, 0.1);
}

textarea.form-control {
    resize: vertical;
    min-height: 120px;
}

/* ========== FAQ折叠 ========== */
.faq-item {
    background: white;
    border-radius: var(--radius-md);
    margin-bottom: 16px;
    box-shadow: var(--shadow-sm);
    overflow: hidden;
}

.faq-question {
    padding: 20px 24px;
    font-size: 16px;
    font-weight: 500;
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: var(--transition);
}

.faq-question:hover {
    background: var(--color-bg-gray);
}

.faq-question i {
    transition: var(--transition);
}

.faq-item.active .faq-question i {
    transform: rotate(180deg);
}

.faq-answer {
    padding: 0 24px;
    max-height: 0;
    overflow: hidden;
    transition: all 0.3s ease;
}

.faq-item.active .faq-answer {
    padding: 0 24px 20px;
    max-height: 500px;
}

/* ========== 响应式 ========== */
@media (max-width: 1024px) {
    .services-grid, .stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .footer-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .banner {
        height: 500px;
    }
    
    .banner-content h1 {
        font-size: 32px;
    }
    
    .services-grid, .stats-grid {
        grid-template-columns: 1fr;
    }
    
    .process-timeline {
        flex-direction: column;
        gap: 30px;
    }
    
    .process-timeline::before {
        display: none;
    }
    
    .footer-grid {
        grid-template-columns: 1fr;
    }
    
    .nav-menu {
        display: none;
    }
}
