/* =========================================
   1. CSS 变量与基础设置 (Variables & Base)
   ========================================= */
:root {
    --primary: #6750A4;
    --on-primary: #FFFFFF;
    --primary-container: #EADDFF;
    --on-primary-container: #21005D;
    --secondary: #BF4638;
    --bg: #FFFBFE;
    --surface: #FFFFFF;
    --text-main: #1C1B1F;
    --text-sub: #49454F;
    --radius-lg: 16px;
    --radius-full: 100px;
    --shadow-sm: 0px 1px 3px 1px rgba(0, 0, 0, 0.15);
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
    -webkit-tap-highlight-color: transparent;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Outfit', sans-serif;
    background-color: var(--bg);
    color: var(--text-main);
    line-height: 1.6;
    overflow-x: hidden;
}

a {
    text-decoration: none;
    color: inherit;
    transition: opacity 0.2s;
}

ul {
    list-style: none;
}

img {
    width: 100%;
    height: auto;
    display: block;
}

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

/* =========================================
   2. 头部导航栏 (Header & Nav)
   ========================================= */
header {
    position: fixed;
    top: 0;
    width: 100%;
    z-index: 1000;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    height: 72px;
    border-bottom: 1px solid #f0f0f0;
    display: flex;
    align-items: center;
}

nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
}

.logo {
    font-size: 1.4rem;
    font-weight: 800;
    color: #FEDD00;
    display: flex;
    align-items: center;
    gap: 6px;
    letter-spacing: -0.5px;
}

.nav-right {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-left: auto;
}

.lang-switch-item {
    display: flex;
    align-items: center;
}

.lang-dropdown {
    position: relative;
}

.lang-toggle {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    font-weight: 600;
    font-size: 0.9rem;
    color: var(--text-sub);
    padding: 6px 12px;
    border-radius: 8px;
    transition: background-color 0.2s, color 0.2s;
    background: none;
    border: none;
    cursor: pointer;
    font-family: inherit;
    text-decoration: none;
}

.lang-toggle:hover {
    background-color: var(--primary-container);
    color: var(--on-primary-container);
}

.lang-toggle .material-symbols-rounded {
    font-size: 18px;
}

.lang-toggle .lang-arrow {
    font-size: 16px;
    transition: transform 0.2s;
}

.lang-dropdown.open .lang-arrow {
    transform: rotate(180deg);
}

.lang-menu {
    position: absolute;
    top: calc(100% + 6px);
    right: 0;
    background: #fff;
    border: 1px solid #eee;
    border-radius: 12px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12);
    padding: 6px;
    min-width: 140px;
    list-style: none;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-6px);
    transition: opacity 0.2s, transform 0.2s, visibility 0.2s;
    z-index: 1001;
}

.lang-dropdown.open .lang-menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.lang-option {
    display: block;
    padding: 8px 12px;
    border-radius: 8px;
    font-size: 0.9rem;
    font-weight: 500;
    color: var(--text-sub);
    transition: background-color 0.15s, color 0.15s;
    white-space: nowrap;
}

.lang-option:hover {
    background-color: var(--primary-container);
    color: var(--on-primary-container);
}

.lang-option.active {
    color: var(--primary);
    font-weight: 700;
}

.nav-links {
    display: flex;
    gap: 32px;
    align-items: center;
}

.nav-links a:not(.btn-nav-amazon) {
    font-weight: 500;
    color: var(--text-sub);
}

/* 导航栏里的亚马逊按钮特殊样式 */
.btn-nav-amazon {
    background-color: #FFD814;
    color: #0F1111 !important;
    padding: 8px 20px;
    border-radius: 24px;
    font-weight: 600 !important;
    font-size: 0.9rem;
    border: 1px solid #FCD200;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
    transition: all 0.2s ease;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    white-space: nowrap;
}

.btn-nav-amazon:hover {
    background-color: #F7CA00;
    border-color: #F2C200;
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.15);
}

.menu-btn {
    display: none;
    /* 桌面端默认隐藏 */
    background: none;
    border: none;
    color: var(--text-main);
    cursor: pointer;
    font-size: 0;
}

.nav-close-btn {
    position: absolute;
    top: 20px;
    right: 20px;
    font-size: 2rem;
    padding: 10px;
    cursor: pointer;
    display: none;
    background: none;
    border: none;
    color: var(--text-main);
}

/* =========================================
   3. 通用按钮 (Buttons)
   ========================================= */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    height: 50px;
    padding: 0 28px;
    border-radius: var(--radius-full);
    font-weight: 700;
    font-size: 1rem;
    border: none;
    cursor: pointer;
    gap: 8px;
    transition: transform 0.2s;
    box-sizing: border-box;
}

.btn:active {
    transform: scale(0.98);
}

.btn-amazon {
    background: var(--secondary);
    color: #fff;
    box-shadow: 0 4px 12px rgba(191, 70, 56, 0.3);
}

.btn-tonal {
    background: var(--primary-container);
    color: var(--on-primary-container);
}

.btn-white {
    background: #FFFFFF;
    color: var(--primary);
    font-weight: 700;
    border: 1px solid #eee;
}

.btn-white:hover {
    background: #f9f9f9;
}

.btn-container {
    padding: 0 20px;
    width: 100%;
    box-sizing: border-box;
}

/* =========================================
   4. 首页 Hero 区域 (Hero Section)
   ========================================= */
.hero {
    padding: 120px 0 80px;
}

.hero-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    align-items: center;
}

.hero-content h1 {
    font-size: 3.5rem;
    line-height: 1.1;
    margin-bottom: 24px;
    color: var(--text-main);
}

.hero-content p {
    color: var(--text-sub);
    font-size: 1.15rem;
    margin-bottom: 32px;
    max-width: 480px;
}

.hero-img picture {
    display: block;
    width: 100%;
}

.hero-img img {
    border-radius: 24px;
    box-shadow: var(--shadow-sm);
    width: 100%;
    height: auto;
    display: block;
}

/* =========================================
   5. 产品展示区域 (Products)
   ========================================= */
.section {
    padding: 80px 0;
}

.section-header {
    text-align: center;
    margin-bottom: 50px;
}

.section-header h2 {
    font-size: 2.2rem;
    margin-bottom: 12px;
}

.section-header p {
    color: var(--text-sub);
    max-width: 600px;
    margin: 0 auto;
}

.grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 32px;
}

.product-card {
    background: var(--surface);
    border-radius: var(--radius-lg);
    padding: 16px;
    border: 1px solid #eee;
    transition: transform 0.3s;
    display: flex;
    flex-direction: column;
}

.product-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.05);
}

.card-img {
    height: 240px;
    border-radius: 12px;
    overflow: hidden;
    margin-bottom: 16px;
    background: #f5f5f5;
}

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

.tag {
    display: inline-block;
    padding: 4px 10px;
    border-radius: 6px;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    margin-bottom: 8px;
    background: var(--primary-container);
    color: var(--on-primary-container);
}

/* =========================================
   6. 博客区域 (Blog / Journal)
   ========================================= */
.blog-section {
    background: var(--primary-container);
    padding: 80px 0;
    border-radius: 32px;
    margin-bottom: 60px;
}

.blog-section h2 {
    text-align: center;
    color: var(--on-primary-container);
    margin-bottom: 40px;
    font-size: 2rem;
}

.blog-card {
    background: #fff;
    border-radius: 16px;
    overflow: hidden;
    cursor: pointer;
    transition: transform 0.2s;
    display: flex;
    flex-direction: column;
    height: 100%;
}

.blog-card:hover {
    transform: scale(1.02);
}

.blog-content {
    padding: 20px;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}

.blog-content h3 {
    font-size: 1.25rem;
    margin-bottom: 8px;
    line-height: 1.3;
}

.blog-content p {
    font-size: 0.9rem;
    color: var(--text-sub);
    margin-bottom: 12px;
    flex-grow: 1;
}

.read-link,
.read-more {
    color: #FEDD00;
    font-weight: 700;
    font-size: 0.9rem;
    display: flex;
    align-items: center;
    gap: 4px;
    margin-top: auto;
}


/* =========================================
   7. 页脚 (Footer) 
   ========================================= */
footer {
    background: #F4F4F4;
    padding: 60px 0 30px;
    margin-top: 80px;
    border-top: 1px solid #EAEAEA;
}

/* 布局网格 (对应 footer-grid) */
.footer-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 40px;
    margin-bottom: 40px;
}

/* 每一列的标题 */
.footer-col h4 {
    color: var(--primary);
    margin-bottom: 20px;
    text-transform: uppercase;
    font-size: 0.9rem;
    letter-spacing: 1px;
    font-weight: 700;
}

/* 列表样式 */
.footer-col ul {
    list-style: none;
    /* 确保去除默认圆点 */
    padding: 0;
}

.footer-col ul li {
    margin-bottom: 12px;
}

/* 链接通用样式 */
.footer-col a {
    color: var(--text-sub);
    text-decoration: none;
    /* 去除下划线 */
    transition: color 0.2s;
}

.footer-col a:hover {
    color: var(--primary);
}

/* 品牌列 LOGO (对应 footer-logo) */
.footer-logo {
    font-size: 1.4rem;
    font-weight: 800;
    color: var(--primary);
    display: flex;
    align-items: center;
    gap: 6px;
    margin-bottom: 16px;
}

/* 品牌列描述文字 */
.brand-col p {
    color: var(--text-sub);
    font-size: 0.95rem;
    line-height: 1.6;
}

/* 特殊高亮链接 (对应 highlight-link) */
.highlight-link {
    color: var(--secondary) !important;
    font-weight: 600;
}

/* 底部版权栏 (对应 footer-copyright) */
.footer-copyright {
    text-align: center;
    padding-top: 30px;
    border-top: 1px solid #DDDDDD;
    color: #888;
    font-size: 0.85rem;
}

.footer-copyright a {
    color: #888;
    text-decoration: none;
}

/* =========================================
   8. 移动端适配 (Media Queries)
   ========================================= */
@media (max-width: 768px) {
    .menu-btn {
        display: block;
    }

    .nav-links {
        position: fixed;
        top: 0;
        right: 0;
        width: 100%;
        height: 100vh;
        background: #fff;
        flex-direction: column;
        justify-content: flex-start;
        align-items: center;
        transform: translateY(-100%);
        transition: 0.3s;
        z-index: 999;
        padding: 80px 24px 40px;
        gap: 0;
        overflow-y: auto;
    }

    .nav-links.active {
        transform: translateY(0);
    }

    .nav-links.active .nav-close-btn {
        display: flex;
        align-items: center;
        justify-content: center;
        width: auto;
    }

    .nav-links > li {
        width: 100%;
    }

    .nav-links > li > a:not(.btn-nav-amazon):not(.lang-option) {
        display: block;
        padding: 14px 0;
        font-size: 1.25rem;
        border-bottom: 1px solid #f0f0f0;
        text-align: center;
    }

    .lang-switch-item {
        width: 100%;
        margin-top: 8px;
        border-bottom: 1px solid #f0f0f0;
    }

    .lang-dropdown {
        width: 100%;
    }

    .lang-toggle {
        width: 100%;
        justify-content: center;
        gap: 8px;
        padding: 14px 0;
        font-size: 1.25rem;
        border-radius: 0;
    }

    .lang-menu {
        position: static;
        opacity: 1;
        visibility: visible;
        transform: none;
        box-shadow: none;
        border: none;
        border-radius: 0;
        padding: 0;
        min-width: 0;
        max-height: 0;
        overflow: hidden;
        transition: max-height 0.3s ease;
    }

    .lang-dropdown.open .lang-menu {
        max-height: 200px;
    }

    .lang-option {
        display: block;
        padding: 12px 0;
        font-size: 1.1rem;
        border-radius: 0;
        border-top: 1px solid #f5f5f5;
        text-align: center;
    }

    .lang-option.active {
        background-color: #f8f5ff;
    }

    .btn-nav-amazon {
        margin-top: 16px;
        padding: 12px 32px;
        font-size: 1.1rem;
        width: auto;
        justify-content: center;
    }

    .hero {
        padding-top: 100px;
        text-align: center;
    }

    .hero-grid {
        grid-template-columns: 1fr;
        gap: 30px;
    }

    .hero h1 {
        font-size: 2.5rem;
    }

    .hero-content {
        order: 2;
    }

    .hero-img {
        order: 1;
    }

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

    .btn {
        width: 100%;
    }
}

/* =========================================
   9. 博客页面专用样式 (Blog Page Specifics)
   ========================================= */

/* Blog Hero (精选文章) */
.blog-hero {
    padding-top: 100px;
    padding-bottom: 60px;
}

.featured-card {
    display: grid;
    grid-template-columns: 1.2fr 1fr;
    gap: 40px;
    align-items: center;
    background: var(--primary-container);
    border-radius: 32px;
    overflow: hidden;
    transition: transform 0.3s;
    cursor: pointer;
}

.featured-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 10px 30px rgba(103, 80, 164, 0.2);
}

.featured-img {
    height: 100%;
    min-height: 400px;
    position: relative;
}

.featured-img picture {
    display: block;
    height: 100%;
    width: 100%;
}

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

.featured-content {
    padding: 40px;
    padding-left: 0;
}

.badge {
    display: inline-block;
    background: var(--primary);
    color: #fff;
    padding: 6px 12px;
    border-radius: 8px;
    font-size: 0.8rem;
    font-weight: 700;
    margin-bottom: 16px;
    text-transform: uppercase;
}

.featured-content h2 {
    font-size: 2.5rem;
    line-height: 1.1;
    margin-bottom: 16px;
    color: var(--on-primary-container);
}

.featured-content p {
    font-size: 1.1rem;
    color: var(--text-sub);
    margin-bottom: 24px;
    max-width: 90%;
}

/* 筛选按钮 */
.blog-filters {
    display: flex;
    gap: 12px;
    margin-bottom: 40px;
    overflow-x: auto;
    padding-bottom: 10px;
    -webkit-overflow-scrolling: touch;
}

.filter-btn {
    padding: 8px 20px;
    border-radius: 100px;
    border: 1px solid #ddd;
    background: transparent;
    font-weight: 600;
    cursor: pointer;
    white-space: nowrap;
    color: var(--text-sub);
    transition: all 0.3s ease;
    font-family: inherit;
}

.filter-btn:hover {
    border-color: var(--primary);
    color: var(--primary);
}

.filter-btn.active {
    background: var(--text-main);
    color: #fff;
    border-color: var(--text-main);
}

/* 博客列表网格 */
.blog-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 32px;
    padding-bottom: 60px;
    min-height: 300px;
}

/* 博客卡片增强样式 */
.blog-card {
    background: var(--surface);
    border-radius: var(--radius-lg);
    overflow: hidden;
    border: 1px solid #eee;
    transition: transform 0.3s ease;
    display: flex;
    flex-direction: column;
    animation: fadeIn 0.5s ease-in-out;
    height: 100%;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.blog-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.05);
}

.blog-img {
    height: 220px;
    background: #f5f5f5;
}

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

.blog-content {
    padding: 24px;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}

.blog-meta {
    font-size: 0.85rem;
    color: var(--secondary);
    font-weight: 600;
    margin-bottom: 8px;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.blog-card h3 {
    font-size: 1.35rem;
    margin-bottom: 12px;
    line-height: 1.3;
    font-weight: 700;
    color: var(--text-main);
}

.blog-card p {
    color: var(--text-sub);
    font-size: 0.95rem;
    margin-bottom: 24px;
    line-height: 1.6;
    flex-grow: 1;
}



/* 翻页加载按钮 */
.pagination {
    text-align: center;
    margin-bottom: 80px;
}

.load-more {
    background: transparent;
    border: 1px solid var(--text-main);
    padding: 12px 32px;
    border-radius: 100px;
    font-weight: 600;
    cursor: pointer;
    transition: 0.2s;
    font-family: inherit;
    font-size: 1rem;
}

.load-more:hover {
    background: var(--text-main);
    color: #fff;
}

.load-more:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

/* 博客页面响应式调整 */
@media (max-width: 768px) {
    .featured-card {
        grid-template-columns: 1fr;
    }

    .featured-img {
        min-height: 250px;
    }

    .featured-content {
        padding: 24px;
    }

    .featured-content h2 {
        font-size: 1.8rem;
    }

    .blog-grid {
        grid-template-columns: 1fr;
    }
}

/* =========================================
   10. 联系我们页面样式 (Contact Page)
   ========================================= */

.page-section {
    padding-top: 120px;
    padding-bottom: 80px;
    min-height: calc(100vh - 400px);
}

.page-header {
    text-align: center;
    margin-bottom: 60px;
}

.page-header h1 {
    font-size: 3rem;
    font-weight: 800;
    margin-bottom: 16px;
    color: var(--text-main);
}

.page-header p {
    font-size: 1.2rem;
    color: var(--text-sub);
    max-width: 600px;
    margin: 0 auto;
}

.contact-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 32px;
    margin-bottom: 60px;
}

.contact-card {
    background: var(--surface);
    border-radius: var(--radius-lg);
    padding: 40px;
    text-align: center;
    border: 1px solid #eee;
    transition: all 0.3s ease;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.contact-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 10px 30px rgba(103, 80, 164, 0.15);
    border-color: var(--primary);
}

.contact-icon {
    width: 80px;
    height: 80px;
    background: var(--primary-container);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 24px;
    color: var(--primary);
}

.contact-card h3 {
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: 12px;
    color: var(--text-main);
}

.contact-card p {
    color: var(--text-sub);
    font-size: 1rem;
    margin-bottom: 24px;
    line-height: 1.6;
}

.contact-info {
    background: var(--primary-container);
    border-radius: var(--radius-lg);
    padding: 40px;
    text-align: center;
}

.contact-info h2 {
    font-size: 2rem;
    font-weight: 700;
    margin-bottom: 16px;
    color: var(--on-primary-container);
}

.contact-info p {
    color: var(--text-sub);
    font-size: 1.1rem;
    margin-bottom: 24px;
}

.contact-info ul {
    display: inline-block;
    text-align: left;
    list-style: none;
}

.contact-info li {
    padding: 12px 0;
    font-size: 1.1rem;
    color: var(--text-main);
    border-bottom: 1px solid rgba(0, 0, 0, 0.1);
}

.contact-info li:last-child {
    border-bottom: none;
}

.contact-info strong {
    color: var(--primary);
    font-weight: 700;
}

@media (max-width: 768px) {
    .page-header h1 {
        font-size: 2rem;
    }

    .page-header p {
        font-size: 1rem;
    }

    .contact-grid {
        grid-template-columns: 1fr;
    }

    .contact-card {
        padding: 32px 24px;
    }

    .contact-info {
        padding: 32px 24px;
    }

    .contact-info h2 {
        font-size: 1.5rem;
    }

    .contact-info li {
        font-size: 1rem;
    }
}