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

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

/* 社区横幅样式 */
.community-banner {
    margin-top: 70px;
}

.community-banner img {
    width: 100%;
    height: auto;
    max-height: 300px;
    object-fit: cover;
}

/* 专家咨询横幅样式 */
.expert-banner {
    margin-top: 70px;
}

.expert-banner img {
    width: 100%;
    height: auto;
    max-height: 300px;
    object-fit: cover;
}

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

/* 导航栏样式 */
.navbar {
    background-color: #fff;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    position: fixed;
    top: 0;
    width: 100%;
    z-index: 1000;
}

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

.nav-logo a {
    font-size: 24px;
    font-weight: bold;
    color: #ff6b6b;
    text-decoration: none;
}

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

.nav-item {
    margin-left: 30px;
}

.nav-link {
    text-decoration: none;
    color: #333;
    font-weight: 500;
    transition: color 0.3s;
}

.nav-link:hover {
    color: #ff6b6b;
}

.nav-toggle {
    display: none;
    flex-direction: column;
    cursor: pointer;
}

.bar {
    width: 25px;
    height: 3px;
    background-color: #333;
    margin: 3px 0;
    transition: 0.3s;
}

/* 横幅样式 */
.hero {
    background: linear-gradient(135deg, #ff9a9e 0%, #fad0c4 100%);
    height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding-top: 70px;
}

.hero-container {
    max-width: 800px;
}

.hero h1 {
    font-size: 3rem;
    margin-bottom: 20px;
    color: #fff;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3);
}

.hero p {
    font-size: 1.2rem;
    margin-bottom: 30px;
    color: #fff;
    text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.3);
}

/* 轮播图样式 */
.slider-container {
    position: relative;
    width: 100%;
    height: 500px;
    overflow: hidden;
    margin-top: 70px;
}

.slider {
    display: flex;
    width: 100%;
    height: 100%;
    transition: transform 0.5s ease-in-out;
}

.slide {
    min-width: 100%;
    height: 100%;
    position: relative;
}

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

.slide-content {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    text-align: center;
    color: white;
    width: 80%;
    max-width: 800px;
    background: rgba(0, 0, 0, 0.5);
    padding: 30px;
    border-radius: 10px;
}

.slide-content h2 {
    font-size: 2.5rem;
    margin-bottom: 20px;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
}

.slide-content p {
    font-size: 1.2rem;
    margin-bottom: 30px;
    text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.5);
}

.slider-nav {
    position: absolute;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 10px;
}

.slider-dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background-color: rgba(255, 255, 255, 0.5);
    cursor: pointer;
    transition: background-color 0.3s;
}

.slider-dot.active {
    background-color: white;
}

.slider-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background-color: rgba(0, 0, 0, 0.5);
    color: white;
    border: none;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    font-size: 1.5rem;
    cursor: pointer;
    transition: background-color 0.3s;
}

.slider-btn:hover {
    background-color: rgba(0, 0, 0, 0.8);
}

.slider-btn.prev {
    left: 20px;
}

.slider-btn.next {
    right: 20px;
}

.btn {
    display: inline-block;
    background-color: #ff6b6b;
    color: #fff;
    padding: 12px 30px;
    border-radius: 30px;
    text-decoration: none;
    font-weight: bold;
    transition: background-color 0.3s;
    border: none;
    cursor: pointer;
    font-size: 1rem;
}

.btn:hover {
    background-color: #ff5252;
}

/* 特色服务样式 */
.features {
    padding: 80px 0;
    background-color: #fff;
}

.section-title {
    text-align: center;
    font-size: 2rem;
    margin-bottom: 50px;
    color: #333;
}

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

.feature-card {
    text-align: center;
    padding: 30px;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s;
}

.feature-card:hover {
    transform: translateY(-10px);
}

.feature-icon {
    font-size: 3rem;
    color: #ff6b6b;
    margin-bottom: 20px;
}

.feature-card h3 {
    font-size: 1.5rem;
    margin-bottom: 15px;
}

/* 性健康页面样式 */
.page-content {
    padding: 100px 0 50px;
}

.page-title {
    text-align: center;
    font-size: 2.5rem;
    margin-bottom: 40px;
    color: #ff6b6b;
}

.health-intro {
    text-align: center;
    max-width: 800px;
    margin: 0 auto 40px;
    font-size: 1.2rem;
    color: #666;
    line-height: 1.8;
}

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

.health-category {
    background-color: #fff;
    border-radius: 10px;
    padding: 25px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
    transition: transform 0.3s, box-shadow 0.3s;
}

.health-category:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.1);
}

.health-category h2 {
    color: #ff6b6b;
    margin-bottom: 20px;
    padding-bottom: 10px;
    border-bottom: 2px solid #ff6b6b;
    display: flex;
    align-items: center;
}

.health-category h2 i {
    margin-right: 10px;
}

.article-list {
    list-style: none;
}

.article-list li {
    margin-bottom: 15px;
    padding-bottom: 15px;
    border-bottom: 1px solid #eee;
}

.article-list li:last-child {
    margin-bottom: 0;
    padding-bottom: 0;
    border-bottom: none;
}

.article-list a {
    text-decoration: none;
    color: #333;
    font-size: 1.1rem;
    transition: color 0.3s;
    display: block;
}

.article-list a:hover {
    color: #ff6b6b;
}

.article-list a::before {
    content: "→";
    margin-right: 10px;
    color: #ff6b6b;
}

/* 情趣指南页面样式 */
.guide-intro {
    text-align: center;
    max-width: 800px;
    margin: 0 auto 40px;
    font-size: 1.2rem;
    color: #666;
    line-height: 1.8;
}

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

.guide-category {
    background-color: #fff;
    border-radius: 10px;
    padding: 25px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
    transition: transform 0.3s, box-shadow 0.3s;
}

.guide-category:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.1);
}

.guide-category h2 {
    color: #ff6b6b;
    margin-bottom: 20px;
    padding-bottom: 10px;
    border-bottom: 2px solid #ff6b6b;
    display: flex;
    align-items: center;
}

.guide-category h2 i {
    margin-right: 10px;
}

/* 热门文章样式 */
.articles {
    padding: 80px 0;
    background-color: #f8f9fa;
}

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

.article-card {
    background-color: #fff;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s;
}

.article-card:hover {
    transform: translateY(-10px);
}

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

.article-content {
    padding: 20px;
}

.article-content h3 {
    font-size: 1.3rem;
    margin-bottom: 10px;
}

.read-more {
    color: #ff6b6b;
    text-decoration: none;
    font-weight: bold;
    display: inline-block;
    margin-top: 10px;
}

.read-more:hover {
    text-decoration: underline;
}

/* 产品推荐页面样式 */
.page-content {
    padding: 100px 0 50px;
}

.page-title {
    text-align: center;
    font-size: 2.5rem;
    margin-bottom: 40px;
    color: #ff6b6b;
}

.products-intro {
    text-align: center;
    max-width: 800px;
    margin: 0 auto 40px;
    font-size: 1.2rem;
    color: #666;
    line-height: 1.8;
}

.product-categories {
    margin-bottom: 60px;
}

.category-filter {
    background-color: #fff;
    border-radius: 10px;
    padding: 25px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
    margin-bottom: 30px;
}

.category-filter h2 {
    color: #ff6b6b;
    margin-bottom: 20px;
}

.category-filter ul {
    display: flex;
    flex-wrap: wrap;
    list-style: none;
    gap: 15px;
}

.category-filter li a {
    display: block;
    padding: 8px 20px;
    background-color: #f8f9fa;
    color: #333;
    text-decoration: none;
    border-radius: 20px;
    transition: all 0.3s;
}

.category-filter li a:hover,
.category-filter li a.active {
    background-color: #ff6b6b;
    color: #fff;
}

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

.product-card {
    background-color: #fff;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
    transition: transform 0.3s, box-shadow 0.3s;
}

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

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

.product-info {
    padding: 20px;
    text-align: center;
}

.product-info h3 {
    font-size: 1.3rem;
    margin-bottom: 10px;
    color: #333;
}

.description {
    color: #666;
    margin-bottom: 15px;
    font-size: 0.95rem;
    line-height: 1.5;
}

.price {
    font-size: 1.4rem;
    color: #ff6b6b;
    font-weight: bold;
    margin: 15px 0;
}

.btn-small {
    background-color: #ff6b6b;
    color: #fff;
    border: none;
    padding: 10px 25px;
    border-radius: 25px;
    cursor: pointer;
    transition: background-color 0.3s;
    font-weight: bold;
}

.btn-small:hover {
    background-color: #ff5252;
}

.product-reviews {
    margin-top: 60px;
}

.product-reviews h2 {
    text-align: center;
    font-size: 2rem;
    margin-bottom: 40px;
    color: #333;
}

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

.review-card {
    background-color: #fff;
    border-radius: 10px;
    padding: 25px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
}

.review-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
    padding-bottom: 15px;
    border-bottom: 1px solid #eee;
}

.reviewer {
    font-weight: bold;
    color: #333;
}

.rating {
    color: #ffc107;
}

.review-content {
    color: #666;
    line-height: 1.6;
    margin-bottom: 15px;
}

.review-product {
    text-align: right;
    color: #ff6b6b;
    font-weight: 500;
}

/* 页脚样式 */
.footer {
    background-color: #333;
    color: #fff;
    padding: 50px 0 20px;
}

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

.footer-section h3,
.footer-section h4 {
    margin-bottom: 20px;
}

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

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

.footer-section a {
    color: #ccc;
    text-decoration: none;
    transition: color 0.3s;
}

.footer-section a:hover {
    color: #ff6b6b;
}

.footer-section i {
    margin-right: 10px;
    width: 20px;
}

.footer-bottom {
    text-align: center;
    padding-top: 20px;
    border-top: 1px solid #555;
}

/* 社区页面样式 */
.community-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background-color: #fff;
    padding: 25px;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
    margin-bottom: 30px;
}

.community-header p {
    font-size: 1.1rem;
    color: #666;
    max-width: 70%;
}

/* 社区搜索栏样式 */
.community-search {
    margin-bottom: 30px;
}

.search-container {
    position: relative;
    max-width: 500px;
    margin: 0 auto;
}

.search-input {
    width: 100%;
    padding: 15px 20px;
    border-radius: 30px;
    border: 2px solid #ddd;
    font-size: 1rem;
    outline: none;
    transition: border-color 0.3s;
}

.search-input:focus {
    border-color: #ff6b6b;
}

.search-btn {
    position: absolute;
    right: 5px;
    top: 5px;
    background-color: #ff6b6b;
    color: #fff;
    border: none;
    border-radius: 50%;
    width: 40px;
    height: 40px;
    cursor: pointer;
    transition: background-color 0.3s;
}

.search-btn:hover {
    background-color: #ff5252;
}

.community-content {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 30px;
}

.forum-categories h2,
.recent-posts h2 {
    margin-bottom: 20px;
    color: #ff6b6b;
    font-size: 1.8rem;
}

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

.category-card {
    background-color: #fff;
    border-radius: 10px;
    padding: 25px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
    transition: transform 0.3s, box-shadow 0.3s;
    cursor: pointer;
}

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

.category-card h3 {
    color: #ff6b6b;
    margin-bottom: 15px;
    display: flex;
    align-items: center;
}

.category-card h3 i {
    margin-right: 10px;
    font-size: 1.5rem;
}

.category-card p {
    color: #666;
    margin-bottom: 20px;
    line-height: 1.6;
}

.category-stats {
    display: flex;
    justify-content: space-between;
    color: #999;
    font-size: 0.9rem;
}

.category-stats i {
    margin-right: 5px;
}

.posts-list {
    display: flex;
    flex-direction: column;
    gap: 25px;
}

.post-card {
    background-color: #fff;
    border-radius: 10px;
    padding: 25px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
    transition: transform 0.3s, box-shadow 0.3s;
}

.post-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.1);
}

.post-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
    padding-bottom: 15px;
    border-bottom: 1px solid #eee;
}

.post-author {
    display: flex;
    align-items: center;
    gap: 15px;
}

.post-author img {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    object-fit: cover;
}

.author-name {
    font-weight: bold;
    color: #333;
}

.post-time {
    font-size: 0.9rem;
    color: #999;
}

.post-category {
    background-color: #ff6b6b;
    color: #fff;
    padding: 5px 12px;
    border-radius: 20px;
    font-size: 0.9rem;
}

.post-title {
    font-size: 1.4rem;
    margin-bottom: 15px;
    color: #333;
}

.post-excerpt {
    color: #666;
    line-height: 1.6;
    margin-bottom: 20px;
}

.post-meta {
    display: flex;
    gap: 20px;
    color: #999;
    font-size: 0.9rem;
}

.post-meta i {
    margin-right: 5px;
}

.community-sidebar {
    display: flex;
    flex-direction: column;
    gap: 30px;
}

.sidebar-card {
    background-color: #fff;
    border-radius: 10px;
    padding: 25px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
}

.sidebar-card h3 {
    color: #ff6b6b;
    margin-bottom: 20px;
    padding-bottom: 15px;
    border-bottom: 2px solid #ff6b6b;
}

.topic-list {
    list-style: none;
}

.topic-list li {
    margin-bottom: 15px;
    padding-bottom: 15px;
    border-bottom: 1px solid #eee;
}

.topic-list li:last-child {
    margin-bottom: 0;
    padding-bottom: 0;
    border-bottom: none;
}

.topic-list a {
    text-decoration: none;
    color: #333;
    transition: color 0.3s;
    display: block;
}

.topic-list a:hover {
    color: #ff6b6b;
}

.topic-list a::before {
    content: "→";
    margin-right: 10px;
    color: #ff6b6b;
}

.rules-list {
    list-style: none;
}

.rules-list li {
    margin-bottom: 15px;
    padding-left: 20px;
    position: relative;
    color: #666;
}

.rules-list li::before {
    content: "•";
    color: #ff6b6b;
    position: absolute;
    left: 0;
    top: 0;
}

/* 专家咨询页面样式 */
.expert-intro {
    text-align: center;
    max-width: 800px;
    margin: 0 auto 40px;
    background-color: #fff;
    padding: 40px;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
}

.expert-intro p {
    font-size: 1.2rem;
    color: #666;
    margin-bottom: 30px;
    line-height: 1.8;
}

.expert-content {
    display: flex;
    flex-direction: column;
    gap: 50px;
}

.expert-categories h2,
.expert-team h2,
.consultation-process h2,
.faq-section h2 {
    text-align: center;
    font-size: 2rem;
    margin-bottom: 30px;
    color: #ff6b6b;
}

.expert-categories .categories-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 30px;
}

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

.expert-card {
    background-color: #fff;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
    transition: transform 0.3s, box-shadow 0.3s;
}

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

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

.expert-info {
    padding: 20px;
    text-align: center;
}

.expert-info h3 {
    font-size: 1.4rem;
    margin-bottom: 10px;
    color: #333;
}

.expert-title {
    color: #ff6b6b;
    font-weight: bold;
    margin-bottom: 10px;
}

.expert-desc {
    color: #666;
    margin-bottom: 20px;
    font-size: 0.95rem;
    line-height: 1.5;
}

.process-steps {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 30px;
    margin-bottom: 30px;
}

.step {
    flex: 1;
    min-width: 200px;
    max-width: 250px;
    text-align: center;
    background-color: #fff;
    padding: 30px 20px;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
}

.step-number {
    width: 50px;
    height: 50px;
    background-color: #ff6b6b;
    color: #fff;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    font-weight: bold;
    margin: 0 auto 20px;
}

.step h3 {
    margin-bottom: 15px;
    color: #333;
}

.step p {
    color: #666;
    line-height: 1.6;
}

.faq-list {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.faq-item {
    background-color: #fff;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
    overflow: hidden;
}

.faq-question {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px;
    cursor: pointer;
    background-color: #f8f9fa;
}

.faq-question h3 {
    margin: 0;
    color: #333;
}

.faq-answer {
    padding: 0 20px;
    display: none;
    animation: fadeIn 0.3s ease;
}

.faq-answer p {
    padding: 20px 0;
    color: #666;
    line-height: 1.6;
    border-top: 1px solid #eee;
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

/* 响应式设计 */
@media screen and (max-width: 992px) {
    .community-content {
        grid-template-columns: 1fr;
    }
    
    .community-sidebar {
        display: grid;
        grid-template-columns: 1fr 1fr;
        gap: 20px;
    }
    
    .sidebar-card {
        margin-bottom: 0;
    }
}

@media screen and (max-width: 768px) {
    .nav-menu {
        position: fixed;
        left: -100%;
        top: 70px;
        flex-direction: column;
        background-color: #fff;
        width: 100%;
        text-align: center;
        transition: 0.3s;
        box-shadow: 0 10px 27px rgba(0, 0, 0, 0.05);
        padding: 20px 0;
    }

    .nav-menu.active {
        left: 0;
    }

    .nav-item {
        margin: 10px 0;
    }

    .nav-toggle {
        display: flex;
    }

    .nav-toggle.active .bar:nth-child(2) {
        opacity: 0;
    }

    .nav-toggle.active .bar:nth-child(1) {
        transform: translateY(8px) rotate(45deg);
    }

    .nav-toggle.active .bar:nth-child(3) {
        transform: translateY(-8px) rotate(-45deg);
    }

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

    .hero p {
        font-size: 1rem;
    }
    
    .page-title {
        font-size: 2rem;
    }
    
    .health-grid {
        grid-template-columns: 1fr;
    }
    
    .community-header {
        flex-direction: column;
        gap: 20px;
        text-align: center;
    }
    
    .community-header p {
        max-width: 100%;
    }
    
    .categories-grid {
        grid-template-columns: 1fr;
    }
    
    .community-sidebar {
        grid-template-columns: 1fr;
    }
    
    .post-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 15px;
    }
}