@import url('https://fonts.googleapis.com/css2?family=Noto+Sans+SC:wght@400;500;700&display=swap');

body {
    font-family: 'Noto Sans SC', sans-serif;
    background-color: #f8fafc;
    color: #334155;
    scroll-behavior: smooth;
}

.navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: 80px;
    background-color: white;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 5%;
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
    transition: all 0.3s ease;
    z-index: 1000;
}

.navbar.scrolled {
    height: 40px;
    background-color: rgba(255,255,255,0.8);
    backdrop-filter: blur(10px);
}

.logo {
    width: 80px;
    height: 80px;
    transition: all 0.3s ease;
}

.logo.scrolled {
    width: 40px;
    height: 40px;
}

.site-name {
    font-size: 40px;
    font-weight: 600;
    transition: all 0.3s ease;
}

.site-name.scrolled {
    font-size: 16px;
}

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

.nav-link {
    color: #334155;
    font-weight: 500;
    transition: color 0.2s;
}

.nav-link:hover {
    color: #3b82f6;
}


.hero-bg {
    background: linear-gradient(135deg, rgba(16, 185, 129, 0.1) 0%, rgba(236, 253, 245, 0.8) 100%);
}

.product-card {
    transition: all 0.3s ease;
    border: 1px solid #e2e8f0;
}

.product-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1);
}

.product-image {
    transition: transform 0.3s ease;
}

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

.testimonial-card {
    transition: all 0.3s ease;
    border: 2px solid #059669;
}

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

.floating-btn {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    z-index: 50;
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.2);
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0% { transform: scale(1); }
    50% { transform: scale(1.05); }
    100% { transform: scale(1); }
}

.testimonial-slider {
    scroll-snap-type: x mandatory;
}

.testimonial-slide {
    scroll-snap-align: start;
}

.ingredient-icon {
    width: 60px;
    height: 60px;
    background-color: rgba(16, 185, 129, 0.1);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto;
}

.countdown-item {
    background-color: #ffffff;
    border-radius: 8px;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
}

.before-after {
    position: relative;
    overflow: hidden;
}

.before-after .before {
    position: absolute;
    top: 0;
    left: 0;
    width: 50%;
    height: 100%;
    overflow: hidden;
}

.mobile-menu {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease-out;
}

.mobile-menu.active {
    max-height: 500px;
}
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(0, 0, 0, 0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.modal-overlay.active {
    opacity: 1;
    visibility: visible;
}

.modal-content {
    background-color: white;
    border-radius: 12px;
    padding: 30px;
    position: relative;
    max-width: 90%;
    width: 400px;
    transform: translateY(20px);
    transition: all 0.3s ease;
}

.modal-overlay.active .modal-content {
    transform: translateY(0);
}

.close-modal {
    position: absolute;
    top: 15px;
    right: 15px;
    font-size: 24px;
    cursor: pointer;
    color: #718096;
}

.consult-btn {
    background-color: #2ECC71;
    color: white;
    border-radius: 8px;
    padding: 12px 24px;
    transition: all 0.3s ease;
}

.consult-btn:hover {
    background-color: #27AE60;
    transform: scale(1.05);
}

/* 滚动条修复样式 */
body.modal-open {
    position: fixed;
    width: 100%;
    overflow-y: scroll;
}

@media (max-width: 768px) {
    .modal-content {
        width: 85%;
    }
    
    .qr-code {
        width: 160px;
        height: 160px;
    }
    
    .cta-buttons {
        flex-direction: column;
    }
}

details {
    border: 1px solid #E0E0E0;
    border-radius: 8px;
    margin-bottom: 10px;
    overflow: hidden;
    transition: all 0.3s ease;
}

summary {
    padding: 15px 20px 15px 60px;
    font-size: 16px;
    font-weight: bold;
    color: #333;
    cursor: pointer;
    list-style: none;
    position: relative;
    transition: all 0.3s ease;
}

summary::-webkit-details-marker {
    display: none;
}

summary:after {
    content: '+';
    position: absolute;
    right: 20px;
    font-size: 18px;
    transition: all 0.3s ease;
}

details[open] summary:after {
    content: '-';
}

summary:before {
    content: '';
    position: absolute;
    left: 20px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 16px;
    font-weight: bold;
}

details[open] summary:before {
    content: '';
}

.faq-content {
    padding: 15px 20px 15px 40px;
    font-size: 16px;
    border-top: 1px solid #f0f0f0;
    position: relative;
}

.faq-content:before {
    content: 'A:';
    position: absolute;
    left: 20px;
    top: 15px;
    font-size: 14px;
    font-weight: bold;
}

/* 为每个FAQ项添加编号 */
details:nth-child(2) summary:before { content: 'Q1:'; }
details:nth-child(3) summary:before { content: 'Q2:'; }
details:nth-child(4) summary:before { content: 'Q3:'; }
details:nth-child(5) summary:before { content: 'Q4:'; }
details:nth-child(6) summary:before { content: 'Q5:'; }
details:nth-child(7) summary:before { content: 'Q6:'; }
details:nth-child(8) summary:before { content: 'Q7:'; }
details:nth-child(9) summary:before { content: 'Q8:'; }
details:nth-child(10) summary:before { content: 'Q9:'; }
details:nth-child(11) summary:before { content: 'Q10:'; }

@media (max-width: 640px) {
    summary {
        padding: 10px 15px 10px 35px;
    }
    
    .faq-content {
        padding: 10px 15px 10px 35px;
    }
    
    summary:before {
        left: 15px;
    }
    
    .faq-content:before {
        left: 15px;
    }
}

.ratingvalue {
    font-size: 0.875rem;
    font-weight: bold;
    padding: 0 10px 0 0;
}
i.fas {
    line-height: unset !important;
}

.back-to-top {
    position: fixed;
    right: 30px;
    bottom: 30px;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background-color: #2ECC71;
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    transition: all 0.3s ease;
    opacity: 0;
    visibility: hidden;
}
.back-to-top.show {
    opacity: 1;
    visibility: visible;
}

/* 首页文章列表 */
.category-tab {
    cursor: pointer;
    transition: all 0.3s ease;
}
.category-tab.active {
    background-color: #059669;
    color: white;
}
.article-container {
    display: none;
    opacity: 0;
    transition: opacity 0.5s ease;
}
.article-container.active {
    display: grid;
    opacity: 1;
}
.line-clamp-2 {
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}
.category-scroll::-webkit-scrollbar {
    display: none;
}
.category-scroll {
    -ms-overflow-style: none;
    scrollbar-width: none;
}
.article-card {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}
.article-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.1);
}
/* TAG标签样式 - 单个容器优化版 */
.tags-group {
    /* 关键：消除inline元素默认间距 */
    font-size: 0; 
    line-height: 0;
}
.article-tag {
    text-decoration: none;
    transition: all 0.2s ease;
    padding: 0.1rem 0.35rem;
    line-height: 1.2; /* 恢复行高 */
    margin-right: 0.1rem; /* 仅设置右侧微小间距 */
    display: inline-block;
}
.article-tag:last-child {
    margin-right: 0; /* 最后一个标签去除右侧间距 */
}
.article-tag:hover {
    background-color: #059669;
    color: white !important;
}
/* 标签容器样式 */
.tags-wrapper {
    display: flex;
    flex: 1;
    justify-content: flex-end; /* 靠右对齐 */
    align-items: center;
}