/* 基础样式 */
:root {
    --primary-color: #000000;
    --secondary-color: #333333;
    --accent-color: #ff4d4d;
    --text-color: #333333;
    --light-gray: #f5f5f5;
    --dark-gray: #666666;
    --white: #ffffff;
    --transition: all 0.3s ease;
    --shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
    --container-width: 1200px;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Poppins', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    line-height: 1.6;
    color: var(--text-color);
}

.container {
    max-width: var(--container-width);
    margin: 0 auto;
    padding: 0 20px;
}

/* 导航栏样式 */
.header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    background: var(--white);
    box-shadow: var(--shadow);
    z-index: 1000;
}

.nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 80px;
    padding: 0 30px;
}

.nav__logo a {
    font-size: 24px;
    font-weight: 700;
    text-decoration: none;
    color: var(--primary-color);
}

.nav__logo span {
    color: var(--accent-color);
}

.nav__menu ul {
    display: flex;
    list-style: none;
    gap: 30px;
}

.nav__menu a {
    text-decoration: none;
    color: var(--text-color);
    font-weight: 500;
    transition: var(--transition);
}

.nav__menu a:hover {
    color: var(--accent-color);
}

.nav__actions {
    display: flex;
    gap: 20px;
}

.nav__action {
    color: var(--text-color);
    text-decoration: none;
    position: relative;
}

.cart-count {
    position: absolute;
    top: -8px;
    right: -8px;
    background: var(--accent-color);
    color: var(--white);
    font-size: 12px;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.nav__toggle {
    display: none;
}

/* Hero区域样式 */
.hero {
    margin-top: 80px;
    height: calc(100vh - 80px);
    position: relative;
    overflow: hidden;
}

.hero__slider {
    height: 100%;
    position: relative;
}

.hero__slide {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    transition: opacity 0.5s ease;
    display: flex;
    align-items: center;
}

.hero__slide.active {
    opacity: 1;
}

.hero__content {
    width: 50%;
    padding: 0 50px;
    z-index: 1;
}

.hero__content h1 {
    font-size: 4rem;
    margin-bottom: 20px;
    line-height: 1.2;
}

.hero__content p {
    font-size: 1.2rem;
    margin-bottom: 30px;
}

.hero__image {
    position: absolute;
    top: 0;
    right: 0;
    width: 60%;
    height: 100%;
    background-size: cover;
    background-position: center;
}

.hero__dots {
    position: absolute;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 10px;
}

.hero__dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.5);
    cursor: pointer;
    transition: var(--transition);
}

.hero__dot.active {
    background: var(--white);
}

/* 分类区域样式 */
.categories {
    padding: 80px 0;
    background: var(--light-gray);
}

.section-title {
    text-align: center;
    font-size: 2.5rem;
    margin-bottom: 50px;
}

.categories__grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
}

.category-card {
    position: relative;
    height: 400px;
    overflow: hidden;
    border-radius: 10px;
    text-decoration: none;
}

.category-card__image {
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    transition: var(--transition);
}

.category-card:hover .category-card__image {
    transform: scale(1.1);
}

.category-card h3 {
    position: absolute;
    bottom: 30px;
    left: 30px;
    color: var(--white);
    font-size: 2rem;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}

/* 商品区域样式 */
.products {
    padding: 80px 0;
}

.products__grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 30px;
    margin-bottom: 50px;
}

.product-card {
    background: var(--white);
    border-radius: 10px;
    overflow: hidden;
    box-shadow: var(--shadow);
    transition: var(--transition);
}

.product-card:hover {
    transform: translateY(-10px);
}

.product-card__image {
    position: relative;
    height: 300px;
    overflow: hidden;
}

.product-card__image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: var(--transition);
}

.product-card:hover .product-card__image img {
    transform: scale(1.1);
}

.product-card__actions {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    display: flex;
    gap: 10px;
    opacity: 0;
    transition: var(--transition);
}

.product-card:hover .product-card__actions {
    opacity: 1;
}

.btn-icon {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: var(--white);
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition);
}

.btn-icon:hover {
    background: var(--accent-color);
    color: var(--white);
}

.product-card__content {
    padding: 20px;
}

.product-card__content h3 {
    font-size: 1.2rem;
    margin-bottom: 10px;
}

.product-card__price {
    display: flex;
    gap: 10px;
    align-items: center;
    margin-bottom: 15px;
}

.price {
    font-size: 1.2rem;
    font-weight: 600;
    color: var(--accent-color);
}

.original-price {
    color: var(--dark-gray);
    text-decoration: line-through;
}

.product-card__colors {
    display: flex;
    gap: 5px;
}

.color {
    width: 20px;
    height: 20px;
    border-radius: 50%;
    border: 2px solid var(--white);
    box-shadow: 0 0 0 1px var(--dark-gray);
    cursor: pointer;
    transition: var(--transition);
}

.color:hover {
    transform: scale(1.2);
}

/* 特性区域样式 */
.features {
    padding: 60px 0;
    background: var(--light-gray);
}

.features__grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 30px;
}

.feature {
    text-align: center;
}

.feature i {
    font-size: 2.5rem;
    color: var(--accent-color);
    margin-bottom: 20px;
}

.feature h3 {
    font-size: 1.2rem;
    margin-bottom: 10px;
}

/* 订阅区域样式 */
.newsletter {
    padding: 80px 0;
    background: var(--primary-color);
    color: var(--white);
}

.newsletter__content {
    text-align: center;
    max-width: 600px;
    margin: 0 auto;
}

.newsletter__content h2 {
    font-size: 2.5rem;
    margin-bottom: 20px;
}

.newsletter__form {
    display: flex;
    gap: 10px;
    margin-top: 30px;
}

.newsletter__form input {
    flex: 1;
    padding: 15px;
    border: none;
    border-radius: 5px;
    font-size: 1rem;
}

/* 按钮样式 */
.btn {
    display: inline-block;
    padding: 15px 30px;
    border-radius: 5px;
    text-decoration: none;
    font-weight: 500;
    transition: var(--transition);
}

.btn--primary {
    background: var(--accent-color);
    color: var(--white);
}

.btn--primary:hover {
    background: darken(var(--accent-color), 10%);
    transform: translateY(-2px);
}

.btn--outline {
    border: 2px solid var(--primary-color);
    color: var(--primary-color);
}

.btn--outline:hover {
    background: var(--primary-color);
    color: var(--white);
}

.text-center {
    text-align: center;
}

/* 页脚样式 */
.footer {
    background: var(--primary-color);
    color: var(--white);
    padding: 80px 0 30px;
}

.footer__grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 40px;
    margin-bottom: 50px;
}

.footer__col h3 {
    font-size: 1.2rem;
    margin-bottom: 20px;
}

.footer__col ul {
    list-style: none;
}

.footer__col ul li {
    margin-bottom: 10px;
}

.footer__col a {
    color: var(--white);
    text-decoration: none;
    transition: var(--transition);
}

.footer__col a:hover {
    color: var(--accent-color);
}

.social-links {
    display: flex;
    gap: 15px;
    margin-top: 20px;
}

.social-links a {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.1);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition);
}

.social-links a:hover {
    background: var(--accent-color);
}

.contact-info li {
    display: flex;
    align-items: center;
    gap: 10px;
}

.footer__bottom {
    text-align: center;
    padding-top: 30px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

/* 响应式设计 */
@media (max-width: 1024px) {
    .products__grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (max-width: 768px) {
    .nav__menu {
        display: none;
    }

    .nav__toggle {
        display: block;
        background: none;
        border: none;
        cursor: pointer;
    }

    .nav__toggle span {
        display: block;
        width: 25px;
        height: 2px;
        background: var(--text-color);
        margin: 5px 0;
        transition: var(--transition);
    }

    .hero__content {
        width: 100%;
        text-align: center;
        padding: 0 20px;
    }

    .hero__image {
        opacity: 0.3;
        width: 100%;
    }

    .categories__grid {
        grid-template-columns: 1fr;
    }

    .products__grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .features__grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .newsletter__form {
        flex-direction: column;
    }

    .footer__grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 480px) {
    .products__grid {
        grid-template-columns: 1fr;
    }

    .features__grid {
        grid-template-columns: 1fr;
    }

    .footer__grid {
        grid-template-columns: 1fr;
    }
} 