/* 高端长裤展示网站 - 全局样式 */
/* 设计风格：现代简约，中性色调，突出产品质感 */

/* 基础样式重置 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Helvetica Neue', Arial, 'PingFang SC', 'Microsoft YaHei', sans-serif;
    line-height: 1.6;
    color: #333;
    background-color: #f8f8f8;
}

/* 容器布局 */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* 导航栏样式 */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    z-index: 1000;
    padding: 1rem 0;
    border-bottom: 1px solid #eaeaea;
}

.nav-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

.logo {
    font-size: 1.5rem;
    font-weight: 300;
    letter-spacing: 2px;
    color: #2c2c2c;
    text-decoration: none;
}

.nav-menu {
    display: flex;
    list-style: none;
    gap: 2rem;
}

.nav-menu a {
    text-decoration: none;
    color: #666;
    font-weight: 300;
    transition: color 0.3s ease;
    position: relative;
}

.nav-menu a:hover {
    color: #2c2c2c;
}

.nav-menu a::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 0;
    height: 1px;
    background: #2c2c2c;
    transition: width 0.3s ease;
}

.nav-menu a:hover::after {
    width: 100%;
}

/* 页脚样式 */
.footer {
    background: #2c2c2c;
    color: #fff;
    text-align: center;
    padding: 2rem 0;
    margin-top: 4rem;
}

/* 按钮样式 */
.btn {
    display: inline-block;
    padding: 0.8rem 2rem;
    border: 1px solid #2c2c2c;
    color: #2c2c2c;
    text-decoration: none;
    font-weight: 300;
    transition: all 0.3s ease;
    background: transparent;
    cursor: pointer;
}

.btn:hover {
    background: #2c2c2c;
    color: #fff;
}

.btn-secondary {
    border: none;
    text-decoration: underline;
    padding: 0.5rem 0;
}

.btn-secondary:hover {
    background: transparent;
    color: #666;
}

/* 轮播图样式 */
.carousel {
    position: relative;
    width: 100%;
    height: 100vh;
    overflow: hidden;
}

.carousel-slide {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    transition: opacity 1s ease;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
}

.carousel-slide.active {
    opacity: 1;
}

.carousel-content {
    position: absolute;
    bottom: 20%;
    left: 10%;
    color: #fff;
    text-shadow: 0 2px 4px rgba(0,0,0,0.3);
}

.carousel-content h1 {
    font-size: 3rem;
    font-weight: 300;
    margin-bottom: 1rem;
}

/* 网格布局 */
.grid {
    display: grid;
    gap: 2rem;
    padding: 4rem 0;
}

.grid-2 {
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
}

.grid-3 {
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
}

.grid-4 {
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
}

/* 卡片样式 */
.card {
    background: #fff;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 15px rgba(0, 0, 0, 0.15);
}

.card-img {
    width: 100%;
    height: 300px;
    object-fit: cover;
}

.card-content {
    padding: 1.5rem;
}

.card-title {
    font-size: 1.2rem;
    font-weight: 400;
    margin-bottom: 0.5rem;
    color: #2c2c2c;
}

.card-desc {
    color: #666;
    font-size: 0.9rem;
    line-height: 1.5;
}

/* 筛选标签 */
.filter-tabs {
    display: flex;
    justify-content: center;
    gap: 1rem;
    margin-bottom: 3rem;
    flex-wrap: wrap;
}

.filter-tab {
    padding: 0.5rem 1.5rem;
    border: 1px solid #eaeaea;
    background: #fff;
    color: #666;
    cursor: pointer;
    transition: all 0.3s ease;
    border-radius: 25px;
}

.filter-tab.active,
.filter-tab:hover {
    background: #2c2c2c;
    color: #fff;
    border-color: #2c2c2c;
}

/* 模态框样式 */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    z-index: 2000;
    align-items: center;
    justify-content: center;
}

.modal.active {
    display: flex;
}

.modal-content {
    max-width: 90%;
    max-height: 90%;
    position: relative;
}

.modal-img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
}

.modal-close {
    position: absolute;
    top: -40px;
    right: 0;
    background: none;
    border: none;
    color: #fff;
    font-size: 2rem;
    cursor: pointer;
}

.modal-desc {
    position: absolute;
    bottom: 20px;
    left: 20px;
    color: #fff;
    text-shadow: 0 2px 4px rgba(0,0,0,0.5);
}

/* 工艺页面样式 */
.craft-section {
    padding: 4rem 0;
}

.craft-item {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
    gap: 3rem;
    align-items: center;
    margin-bottom: 4rem;
}

.craft-item:nth-child(even) .craft-img {
    order: 2;
}

.craft-item:nth-child(even) .craft-text {
    order: 1;
}

.craft-img {
    width: 100%;
    height: 400px;
    object-fit: cover;
    border-radius: 8px;
}

.craft-text h3 {
    font-size: 1.8rem;
    font-weight: 300;
    margin-bottom: 1rem;
    color: #2c2c2c;
}

.craft-text p {
    color: #666;
    line-height: 1.8;
}

/* 响应式设计 */
@media (max-width: 768px) {
    .nav-menu {
        gap: 1rem;
    }
    
    .carousel-content h1 {
        font-size: 2rem;
    }
    
    .craft-item {
        grid-template-columns: 1fr;
    }
    
    .craft-item:nth-child(even) .craft-img,
    .craft-item:nth-child(even) .craft-text {
        order: unset;
    }
    
    .filter-tabs {
        gap: 0.5rem;
    }
    
    .filter-tab {
        padding: 0.4rem 1rem;
        font-size: 0.9rem;
    }
}

@media (max-width: 480px) {
    .nav-content {
        flex-direction: column;
        gap: 1rem;
    }
    
    .nav-menu {
        gap: 0.5rem;
    }
    
    .carousel-content {
        left: 5%;
        bottom: 15%;
    }
    
    .carousel-content h1 {
        font-size: 1.5rem;
    }
    
    .grid-2,
    .grid-3,
    .grid-4 {
        grid-template-columns: 1fr;
    }
}

/* 工具类 */
.text-center {
    text-align: center;
}

.mt-4 {
    margin-top: 4rem;
}

.mb-4 {
    margin-bottom: 4rem;
}

.px-4 {
    padding-left: 4rem;
    padding-right: 4rem;
}

.hidden {
    display: none;
}

.fade-in {
    animation: fadeIn 0.8s ease;
}

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