/* 全局变量 */
:root {
    --primary-blue: #E8F4F8;
    --accent-gold: #D4B996;
    --text-dark: #2C3E50;
    --text-medium: #5D6D7E;
    --text-light: #95A5A6;
    --bg-white: #FFFFFF;
    --bg-light-gray: #F8FAFC;
    --shadow-light: rgba(0, 0, 0, 0.08);
    --shadow-hover: rgba(0, 0, 0, 0.15);
}

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

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Inter', sans-serif;
    line-height: 1.6;
    color: var(--text-dark);
    background-color: var(--bg-light-gray);
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* 导航栏 */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    background-color: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    z-index: 1000;
    box-shadow: 0 2px 10px var(--shadow-light);
}

.navbar .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 20px;
}

.nav-brand h1 {
    font-size: 24px;
    font-weight: 700;
    color: var(--text-dark);
    letter-spacing: 2px;
}

.nav-links {
    display: flex;
    gap: 30px;
}

.nav-links a {
    text-decoration: none;
    color: var(--text-medium);
    font-size: 14px;
    font-weight: 500;
    transition: color 0.3s ease;
    position: relative;
}

.nav-links a:hover,
.nav-links a.active {
    color: var(--text-dark);
}

.nav-links a.active::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 100%;
    height: 2px;
    background-color: var(--accent-gold);
}

/* 语言切换 */
.language-dropdown {
    position: relative;
    margin-left: 20px;
}

.lang-dropdown-btn {
    display: flex;
    align-items: center;
    gap: 5px;
    padding: 8px 14px;
    background-color: transparent;
    border: 1px solid var(--text-light);
    border-radius: 25px;
    cursor: pointer;
    font-size: 13px;
    color: var(--text-medium);
    transition: all 0.3s ease;
}

.lang-dropdown-btn:hover {
    border-color: var(--accent-gold);
    color: var(--accent-gold);
}

.lang-dropdown-content {
    position: absolute;
    top: 100%;
    right: 0;
    margin-top: 10px;
    background-color: white;
    border-radius: 10px;
    box-shadow: 0 5px 20px var(--shadow-light);
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: all 0.3s ease;
    z-index: 100;
}

.language-dropdown:hover .lang-dropdown-content {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.lang-option {
    display: block;
    padding: 10px 25px;
    text-decoration: none;
    color: var(--text-medium);
    font-size: 13px;
    transition: background-color 0.3s ease;
}

.lang-option:hover,
.lang-option.active {
    background-color: var(--primary-blue);
    color: var(--text-dark);
}

/* 移动端菜单 */
.mobile-menu-btn {
    display: none;
    font-size: 20px;
    color: var(--text-dark);
    cursor: pointer;
}

.mobile-menu {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    width: 100%;
    background-color: white;
    padding: 20px;
    box-shadow: 0 5px 20px var(--shadow-light);
}

.mobile-menu a {
    display: block;
    padding: 12px 0;
    text-decoration: none;
    color: var(--text-medium);
    font-size: 14px;
    border-bottom: 1px solid var(--primary-blue);
}

.mobile-menu a:last-of-type {
    border-bottom: none;
}

.mobile-lang {
    display: flex;
    gap: 10px;
    margin-top: 15px;
}

.mobile-lang .lang-btn {
    padding: 8px 16px;
    border: 1px solid var(--text-light);
    border-radius: 20px;
    background-color: transparent;
    color: var(--text-medium);
    font-size: 13px;
    cursor: pointer;
}

.mobile-lang .lang-btn.active {
    background-color: var(--accent-gold);
    border-color: var(--accent-gold);
    color: white;
}

/* 页面标题 */
.page-header {
    padding: 150px 0 80px;
    text-align: center;
    position: relative;
    overflow: hidden;
    min-height: 350px;
    display: flex;
    align-items: center;
}

.header-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
}

.header-bg img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.header-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, rgba(44, 62, 80, 0.7) 0%, rgba(212, 185, 150, 0.4) 100%);
}

.back-btn {
    position: absolute;
    left: -50px;
    top: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 45px;
    height: 45px;
    background-color: rgba(255, 255, 255, 0.2);
    border-radius: 50%;
    text-decoration: none;
    color: white;
    font-size: 18px;
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.3);
}

.back-btn:hover {
    background-color: rgba(255, 255, 255, 0.3);
    transform: scale(1.1);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.2);
}

.page-header .container {
    position: relative;
    z-index: 1;
}

.page-header h1 {
    font-size: 42px;
    font-weight: 600;
    color: white;
    margin-bottom: 15px;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
}

.page-header p {
    font-size: 18px;
    color: rgba(255, 255, 255, 0.9);
    text-shadow: 0 1px 5px rgba(0, 0, 0, 0.2);
}

/* 筛选区域 */
.filters {
    padding: 30px 0;
    background-color: white;
    border-bottom: 1px solid var(--primary-blue);
}

.filter-row {
    display: flex;
    gap: 40px;
    margin-bottom: 20px;
}

.filter-group {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.filter-group label {
    font-size: 13px;
    font-weight: 500;
    color: var(--text-dark);
}

.filter-select {
    padding: 10px 40px 10px 15px;
    border: 1px solid var(--text-light);
    border-radius: 8px;
    font-size: 14px;
    color: var(--text-dark);
    background-color: white;
    cursor: pointer;
    min-width: 180px;
    appearance: none;
    -webkit-appearance: none;
    -moz-appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%23D4B996' d='M6 8L2 4h8z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 15px center;
    transition: all 0.3s ease;
}

.filter-select:hover {
    border-color: var(--accent-gold);
}

.filter-select:focus {
    outline: none;
    border-color: var(--accent-gold);
    box-shadow: 0 0 0 3px rgba(212, 185, 150, 0.2);
}

.tags-filter {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}

.tags-filter span {
    font-size: 14px;
    color: var(--text-medium);
}

.tag-btn {
    padding: 6px 14px;
    border: 1px solid var(--text-light);
    border-radius: 20px;
    background-color: white;
    color: var(--text-medium);
    font-size: 13px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.tag-btn:hover {
    border-color: var(--accent-gold);
    color: var(--accent-gold);
}

.tag-btn.active {
    background-color: var(--accent-gold);
    border-color: var(--accent-gold);
    color: white;
}

/* 产品网格 */
.products-grid {
    padding: 50px 0;
}

.products-wrapper {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
    margin-bottom: 40px;
}

.product-card {
    position: relative;
    background-color: white;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 15px var(--shadow-light);
    transition: all 0.3s ease;
}

.product-card:hover {
    box-shadow: 0 10px 30px var(--shadow-hover);
    transform: translateY(-5px);
}

.product-badge {
    position: absolute;
    top: 15px;
    right: 15px;
    padding: 5px 12px;
    background-color: #FF6B6B;
    color: white;
    font-size: 11px;
    font-weight: 600;
    border-radius: 20px;
    z-index: 1;
}

.product-badge.badge-new {
    background-color: var(--accent-gold);
}

.product-badge.badge-organic {
    background-color: #27AE60;
}

.product-image {
    width: 100%;
    padding-bottom: 100%;
    position: relative;
    overflow: hidden;
}

.product-image img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.product-card:hover .product-image img {
    transform: scale(1.05);
}

.product-link {
    text-decoration: none;
    color: inherit;
    display: block;
}

.product-info {
    padding: 20px;
}

.product-info h3 {
    font-size: 17px;
    font-weight: 600;
    color: var(--text-dark);
    margin-bottom: 8px;
}

.product-info p {
    font-size: 13px;
    color: var(--text-medium);
    line-height: 1.5;
    margin-bottom: 12px;
}

.rating {
    display: flex;
    align-items: center;
    gap: 3px;
    margin-bottom: 10px;
}

.rating i {
    color: var(--accent-gold);
    font-size: 12px;
}

.rating span {
    font-size: 12px;
    color: var(--text-light);
    margin-left: 5px;
}

.price {
    font-size: 18px;
    font-weight: 600;
    color: var(--text-dark);
    margin-bottom: 15px;
}

.add-btn {
    width: 100%;
    padding: 12px;
    background-color: var(--accent-gold);
    color: white;
    border: none;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
}

.add-btn:hover {
    background-color: var(--text-dark);
    transform: scale(1.02);
}

/* 分页 */
.pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 10px;
}

.page-btn {
    width: 40px;
    height: 40px;
    border: 1px solid var(--text-light);
    border-radius: 8px;
    background-color: white;
    color: var(--text-medium);
    font-size: 14px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.page-btn:hover:not(:disabled) {
    border-color: var(--accent-gold);
    color: var(--accent-gold);
}

.page-btn.active {
    background-color: var(--accent-gold);
    border-color: var(--accent-gold);
    color: white;
}

.page-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.page-btn.prev,
.page-btn.next {
    width: auto;
    padding: 0 15px;
}

/* 页脚 */
.footer {
    background-color: var(--text-dark);
    color: white;
    padding: 60px 0;
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 40px;
    margin-bottom: 40px;
}

.footer-brand h2 {
    font-size: 24px;
    font-weight: 700;
    margin-bottom: 10px;
    letter-spacing: 2px;
}

.footer-brand p {
    color: rgba(255, 255, 255, 0.7);
    font-size: 14px;
}

.footer-links h3,
.footer-contact h3 {
    font-size: 16px;
    font-weight: 600;
    margin-bottom: 20px;
}

.footer-links ul {
    list-style: none;
}

.footer-links li {
    margin-bottom: 10px;
}

.footer-links a {
    color: rgba(255, 255, 255, 0.7);
    text-decoration: none;
    font-size: 14px;
    transition: color 0.3s ease;
}

.footer-links a:hover {
    color: var(--accent-gold);
}

.footer-contact p {
    display: flex;
    align-items: center;
    gap: 10px;
    color: rgba(255, 255, 255, 0.7);
    font-size: 14px;
    margin-bottom: 10px;
}

.footer-bottom {
    padding-top: 30px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    text-align: center;
}

.footer-bottom p {
    color: rgba(255, 255, 255, 0.6);
    font-size: 13px;
    margin-bottom: 8px;
}

/* 页面标题区域返回按钮 */
.page-header .back-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 20px;
    padding: 10px 20px;
    background: rgba(255, 255, 255, 0.15);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 30px;
    font-size: 14px;
    font-weight: 500;
    color: white;
    text-decoration: none;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
}

.page-header .back-btn:hover {
    background: rgba(255, 255, 255, 0.25);
    border-color: rgba(255, 255, 255, 0.4);
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
}

.page-header .back-btn i {
    font-size: 16px;
    transition: transform 0.3s ease;
}

.page-header .back-btn:hover i {
    transform: translateX(-3px);
}

.footer-bottom p:last-child {
    margin-bottom: 0;
}

/* 响应式设计 */
@media (max-width: 768px) {
    .nav-links {
        display: none;
    }

    .language-dropdown {
        display: none;
    }

    .mobile-menu-btn {
        display: block;
    }

    .mobile-menu.active {
        display: block;
    }

    .filter-row {
        flex-direction: column;
        gap: 20px;
    }

    .page-header h1 {
        font-size: 28px;
    }

    .products-wrapper {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 480px) {
    .navbar .container {
        padding: 12px 15px;
    }

    .page-header {
        padding: 130px 0 40px;
    }

    .page-header h1 {
        font-size: 24px;
    }

    .products-wrapper {
        grid-template-columns: 1fr;
    }

    .footer-content {
        gap: 30px;
    }
}