/* 基础样式 */
:root {
    --primary-color: #8B5A2B;
    --secondary-color: #A68B65;
    --light-color: #F8F9FA;
    --dark-color: #343A40;
    --text-color: #495057;
    --white: #fff;
    --gray: #e9ecef;
    --border-radius: 4px;
    --box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    background-color: var(--light-color);
}

a {
    text-decoration: none;
    color: var(--primary-color);
    transition: all 0.3s ease;
}

a:hover {
    color: var(--secondary-color);
}

img {
    max-width: 100%;
    height: auto;
}

ul {
    list-style: none;
}

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

.text-center {
    text-align: center;
}

/* 按钮样式 */
.read-more {
    display: inline-block;
    padding: 8px 20px;
    background-color: var(--primary-color);
    color: var(--white);
    border-radius: var(--border-radius);
    font-size: 14px;
    margin-top: 20px;
}

.read-more:hover {
    background-color: var(--secondary-color);
    color: var(--white);
}

/*顶部*/
.top{width: 100%;height: 36px;background: #f8f8f8;}
.top_con{width: 1200px;margin: 0 auto;}
.bityiche{float: left;color: #565656;font-size: 12px;line-height: 36px;}
.ignore{float: right;color: #565656;font-size: 12px;line-height: 36px;}
.ignore a{color: #565656;}

/* 头部样式 */
.header {
    background-color: var(--white);
    box-shadow: var(--box-shadow);
    position: sticky;
    top: 0;
    z-index: 1000;
    padding: 15px 0;
}

.header .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo a {
    display: flex;
    align-items: center;
    color: var(--primary-color);
}

.logo img {
    height: 50px;
    margin-right: 10px;
}

.logo h1 {
    font-size: 24px;
    font-weight: normal;
}

.main-nav ul {
    display: flex;
}

.main-nav li {
    margin-left: 30px;
}

.main-nav a {
    color: var(--dark-color);
    font-size: 16px;
    position: relative;
}

.main-nav a.active,
.main-nav a:hover {
    color: var(--primary-color);
}

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

.mobile-menu-btn {
    display: none;
    flex-direction: column;
    justify-content: space-between;
    width: 30px;
    height: 21px;
    cursor: pointer;
}

.mobile-menu-btn span {
    display: block;
    height: 3px;
    width: 100%;
    background-color: var(--primary-color);
    border-radius: 3px;
}

/* 幻灯片样式 */
.slider {
    position: relative;
    height: 500px;
    overflow: hidden;
}

.slide {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    transition: opacity 1s ease;
}

.slide.active {
    opacity: 1;
}

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

.slide-content {
    position: absolute;
    bottom: 50px;
    left: 50px;
    background-color: rgba(0, 0, 0, 0.6);
    color: var(--white);
    padding: 20px;
    max-width: 500px;
    border-radius: var(--border-radius);
}

.slide-content h2 {
    font-size: 28px;
    margin-bottom: 10px;
}

.slide-content p {
    font-size: 16px;
}

.slider-controls {
    position: absolute;
    top: 50%;
    width: 100%;
    display: flex;
    justify-content: space-between;
    transform: translateY(-50%);
    padding: 0 20px;
}

.slider-controls button {
    background-color: rgba(0, 0, 0, 0.5);
    color: var(--white);
    border: none;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    font-size: 20px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
}

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

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

.slider-dots .dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background-color: rgba(255, 255, 255, 0.5);
    margin: 0 5px;
    cursor: pointer;
}

.slider-dots .dot.active {
    background-color: var(--white);
}

/* 内容区块样式 */
.section {
    padding: 50px 0;
}

.section-title {
    text-align: center;
    margin-bottom: 40px;
    position: relative;
}

.section-title span {
    display: inline-block;
    padding: 0 20px;
    background-color: var(--light-color);
    position: relative;
    z-index: 1;
    font-size: 28px;
    color: var(--primary-color);
}

.section-title:after {
    content: '';
    position: absolute;
    top: 50%;
    left: 0;
    width: 100%;
    height: 1px;
    background-color: var(--primary-color);
    z-index: 0;
}

/* 寺庙简介样式 */
.temple-intro .intro-content {
    display: flex;
    align-items: center;
    gap: 30px;
}

.intro-image {
    flex: 1;
    border-radius: var(--border-radius);
    overflow: hidden;
    box-shadow: var(--box-shadow);
}

.intro-text {
    flex: 1;
}

.intro-text p {
    margin-bottom: 15px;
}

/* 师父简介新样式 */
.master-single {
    max-width: 600px;
    margin: 0 auto;
    background-color: var(--white);
    border-radius: var(--border-radius);
    overflow: hidden;
    box-shadow: var(--box-shadow);
}

.master-single .master-image {
    width: 100%;
    /*height: 300px;*/
}

.master-single .master-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.master-single .master-info {
    padding: 25px;
}

.master-single h3 {
    color: var(--primary-color);
    font-size: 22px;
    margin-bottom: 5px;
}

.master-single .title {
    color: var(--secondary-color);
    font-style: italic;
    margin-bottom: 15px;
}

.master-single p {
    margin-bottom: 15px;
}

/* 近期资讯样式 */
.news-list-text {
    max-width: 800px;
    margin: 0 auto;
}

.news-item-text {
    background-color: var(--white);
    padding: 20px;
    margin-bottom: 15px;
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow);
    transition: all 0.3s ease;
}

.news-item-text:hover {
    transform: translateY(-3px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

.news-item-text h3 {
    margin-bottom: 10px;
}

.news-item-text h3 a {
    color: var(--dark-color);
}

.news-item-text h3 a:hover {
    color: var(--primary-color);
}

.news-item-text .meta {
    color: #6C757D;
    font-size: 14px;
    margin-bottom: 10px;
}

.news-item-text p {
    color: var(--text-color);
}

/* 面包屑导航 */
.breadcrumb {
    padding: 15px 0;
    background-color: var(--gray);
    font-size: 14px;
}

.breadcrumb a {
    color: var(--text-color);
}

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

.breadcrumb span {
    color: var(--primary-color);
}


/* 列表页样式 */
.list-item-text {
    background-color: var(--white);
    padding: 20px;
    margin-bottom: 15px;
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow);
    transition: all 0.3s ease;
}

.list-item-text:hover {
    transform: translateY(-3px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

.list-item-text h3 {
    margin-bottom: 10px;
}

.list-item-text h3 a {
    color: var(--dark-color);
}

.list-item-text h3 a:hover {
    color: var(--primary-color);
}

.list-item-text .meta {
    color: #6C757D;
    font-size: 14px;
    margin-bottom: 10px;
}

.list-item-text p {
    color: var(--text-color);
    margin-bottom: 15px;
}

/* 分页导航 */
.pagination {
    margin-top: 30px;
}

.pagination ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.pagination li {
    display: inline;
}

.pagination a,
.pagination span {
    float: left;
    padding: 5px 14px;
    margin: 0px 5px 3px 0;
    border: 1px solid #ddd;
    border-radius: 8px;
    font-size: 12px;
    color: #666;
    background-color: #FFF;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.03);
    transition: var(--transition);
}

.pagination a:hover {
    color: #ffffff;
    background-color: var(--primary-color, rgb(54, 144, 207));
    border-color: var(--primary-color, #3690cf);
}

.pagination .active span {
    color: #ffffff;
    background-color: var(--primary-color, rgb(54, 144, 207));
    border-color: var(--primary-color, #3690cf);
}

/* 内容页样式 */
.article-detail {
    background-color: var(--white);
    padding: 30px;
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow);
}

.article-detail h1 {
    font-size: 28px;
    color: var(--primary-color);
    margin-bottom: 15px;
}

.article-meta {
    font-size: 14px;
    color: #999;
    margin-bottom: 30px;
    display: flex;
    gap: 20px;
}

.featured-image {
    width: 100%;
    height: auto;
    margin-bottom: 30px;
    border-radius: var(--border-radius);
}

.article-content h2 {
    font-size: 22px;
    color: var(--primary-color);
    margin: 25px 0 15px;
}

.article-content p {
    margin-bottom: 15px;
    line-height: 1.8;
}

.image-gallery {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 15px;
    margin: 20px 0;
}

.image-gallery img {
    border-radius: var(--border-radius);
}

blockquote {
    border-left: 4px solid var(--primary-color);
    padding-left: 20px;
    margin: 20px 0;
    font-style: italic;
    color: #666;
}
.article-navigation {
    margin-top: 40px;
    display: flex;
    justify-content: space-between;
}

.article-navigation a {
    color: var(--text-color);
}

.article-navigation a:hover {
    color: var(--primary-color);
}

/* 微信二维码弹出样式 */

.social-links {
    display: flex;
    gap: 15px;
}

/* 微信图标容器 */

.social-links {
    display: flex;
    gap: 15px;
}
.social-links a {
    display: inline-block;
    width: 40px;
    height: 40px;
    background-color: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    color: var(--white);
    text-align: center;
    line-height: 40px;
    transition: transform 0.3s ease, background-color 0.3s ease; /* 添加过渡效果 */
    transform: translateY(0); /* 初始位置 */
}

.social-links a:hover {
    background-color: var(--primary-color);
    transform: translateY(-3px);
}

.wechat-popup-trigger {
    position: relative;
    display: inline-block;
}

.wechat-popup {
    position: absolute;
    bottom: 100%;
    left: 50%;
    transform: translateX(-50%);
    width: 180px;
    padding: 15px;
    background: #fff;
    border-radius: 8px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
    text-align: center;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    z-index: 1000;
    margin-bottom: 15px;
}

.wechat-popup::after {
    content: '';
    position: absolute;
    top: 100%;
    left: 50%;
    margin-left: -10px;
    border-width: 10px;
    border-style: solid;
    border-color: #fff transparent transparent transparent;
}

.wechat-popup img {
    width: 100%;
    height: auto;
    border-radius: 4px;
    margin-bottom: 10px;
}

.wechat-popup p {
    font-size: 14px;
    color: #666;
    margin: 0;
}

.wechat-popup-trigger:hover .wechat-popup,
.wechat-popup-trigger:focus-within .wechat-popup {
    opacity: 1;
    visibility: visible;
}


/* 底部样式 */
.footer {
    background-color: var(--dark-color);
    color: var(--white);
    padding: 50px 0 0;
}

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

.footer a{
    color: #bbb;
}

.widget h3 {
    color: var(--white);
    font-size: 18px;
    margin-bottom: 20px;
    position: relative;
    padding-bottom: 10px;
}

.widget h3:after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 50px;
    height: 2px;
    background-color: var(--primary-color);
}

.widget p {
    margin-bottom: 15px;
    color: #bbb;
}

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

.widget ul a {
    color: #bbb;
}

.widget ul a:hover {
    color: var(--white);
    padding-left: 5px;
}

.footer-bottom {
    text-align: center;
    padding: 20px 0;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    color: #bbb;
    font-size: 14px;
}/* 移动端专属滚动修复 */
@media (max-width: 768px) {
    html, body {
        height: 100%;
        overflow-x: hidden;
        position: relative;
    }
    
    body {
        -webkit-overflow-scrolling: touch;
        overflow-anchor: none;
    }
    
    /* 防止移动端自动滚动 */
    main, article, .article-detail {
        overflow-anchor: none;
    }
    
    /* 修复移动端焦点滚动 */
    input, textarea, video {
        -webkit-overflow-scrolling: touch;
    }
    
    /* 确保页面初始在顶部 */
    body::after {
        content: '';
        display: block;
        height: 0;
        clear: both;
    }
}