/* 文化子页面样式 */
body {
    background-color: #f5f0e6; /* 调整背景色为更柔和的米色 */
    color: #333;
    line-height: 1.6;
    font-family: 'Microsoft YaHei', sans-serif;
}

.culture-container {
    display: flex;
    gap: 2rem;
    margin: 2rem 0;
    position: relative;
}

/* 全新设计的导航栏样式 */
.culture-sidebar {
    position: fixed;
    left: -90px; /* 初始隐藏更多以容纳阴影 */
    top: 50%;
    transform: translateY(-50%);
    transition: left 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    background: rgba(232, 224, 213, 0.98);
    padding: 1.5rem 0;
    border-radius: 0 12px 12px 0;
    box-shadow: 4px 0 15px rgba(0, 0, 0, 0.2);
    z-index: 100;
    width: 110px; /* 加宽容器 */
    backdrop-filter: blur(4px);
    border-left: 2px solid #D4AF37;
}

.culture-sidebar:hover {
    left: 0;
    box-shadow: 6px 0 20px rgba(0, 0, 0, 0.25);
}

.sidebar-nav ul {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.sidebar-item {
    position: relative;
    display: flex;
    justify-content: center;
}

.sidebar-item a {
    writing-mode: vertical-rl;
    text-orientation: upright;
    font-family: 'STXingkai', cursive;
    font-size: 1.4rem;
    color: #634b36;
    padding: 0.8rem 0.6rem; /* 减少文字与容器的距离 */
    text-decoration: none;
    border-radius: 6px;
    box-shadow: 
        inset 0 0 8px rgba(212,175,55,0.1),
        2px 2px 6px rgba(0,0,0,0.1);
    transition: all 0.3s ease;
    width: 70px;
    height: 140px;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow: hidden;
}

/* 文字绝对居中 */
.sidebar-item a span {
    position: relative;
    z-index: 2;
    transform: translateX(3px); /* 视觉居中补偿 */
}

/* 装饰性边框 */
.sidebar-item a::before {
    content: "";
    position: absolute;
    top: 5px;
    left: 5px;
    right: 5px;
    bottom: 5px;
    border: 1px solid rgba(212,175,55,0.3);
    border-radius: 4px;
}

/* 悬停效果 */
.sidebar-item a:hover {
    background: linear-gradient(to bottom, 
        rgba(212,175,55,0.9) 0%,
        rgba(180,140,40,0.9) 100%);
    color: #fff;
    transform: translateX(8px);
    box-shadow: 
        3px 3px 10px rgba(0,0,0,0.2),
        inset 0 0 12px rgba(255,255,255,0.2);
}

/* 激活状态 */
.sidebar-item.active a {
    background: linear-gradient(to bottom, 
        #8b0000 0%,
        #6a0000 100%);
    color: #D4AF37;
}

/* 为"皮影艺术"添加不同的背景色 */
.sidebar-item:nth-child(2) a {
    background: linear-gradient(to bottom, 
        rgba(212,175,55,0.9) 0%,
        rgba(180,140,40,0.9) 100%);
    color: #fff;
}

/* 移动端适配 */
@media (max-width: 768px) {
    .culture-sidebar {
        position: static;
        width: 100%;
        border-radius: 0;
        box-shadow: 0 2px 10px rgba(0,0,0,0.1);
        margin-bottom: 2rem;
    }

    .sidebar-nav ul {
        flex-direction: row;
        justify-content: center;
        padding: 1rem 0;
    }

    .sidebar-item a {
        writing-mode: horizontal-tb;
        width: auto;
        height: auto;
        padding: 0.8rem 1.5rem;
        transform: none !important;
    }

    .sidebar-item a span {
        transform: none;
    }
}
/* 移动端适配 */
@media (max-width: 768px) {
    .culture-sidebar {
        position: static;
        width: 100%;
        border-radius: 0;
        box-shadow: 0 2px 10px rgba(0,0,0,0.1);
        margin-bottom: 2rem;
    }

    .sidebar-nav ul {
        flex-direction: row;
        justify-content: center;
        padding: 1rem 0;
    }

    .sidebar-item a {
        writing-mode: horizontal-tb;
        width: auto;
        height: auto;
        padding: 1rem 1.5rem;
        transform: none !important;
    }

    .sidebar-item a span {
        transform: none;
    }
}

/* 右侧内容区 */
.culture-content {
    flex: 1;
    background-color: white;
    padding: 2.5rem;
    border-radius: 8px;
    box-shadow: 0 2px 15px rgba(0,0,0,0.1);
    overflow-y: auto; /* 添加垂直滚动条 */
    height: calc(100vh - 4rem); /* 高度为视口高度减去页脚高度 */
    margin-left: 30px; /* 与左侧导航栏宽度一致 */
}

.culture-section {
    margin-bottom: 3rem;
}

.culture-section h2 {
    color: #B22222; /* 调整标题颜色为更柔和的红色 */
    margin-bottom: 1.2rem;
    font-family: 'STXingkai', cursive;
    font-size: 1.8rem;
    border-bottom: 2px solid #D4AF37; /* 添加金色下划线 */
    padding-bottom: 0.5rem;
    background-color: #fff; /* 添加背景色 */
    display: inline-block; /* 使标题宽度适应内容 */
    padding: 0 10px; /* 添加内边距 */
}

.section-tag {
    color: #D4AF37;
    font-style: italic;
    margin-bottom: 1.5rem;
}

.novel-item {
    margin-bottom: 2.5rem;
    padding-bottom: 1.5rem;
    border-bottom: 1px dashed #eee;
}

.novel-item:last-child {
    border-bottom: none;
}

/* 书籍容器 */
.novel-container {
    display: flex;
    gap: 2rem;
    margin-bottom: 2rem;
}

.novel-image {
    flex: 0 0 200px;
}

.novel-image img {
    width: 100%;
    height: auto;
    border-radius: 8px;
    box-shadow: 0 4px 8px rgba(0,0,0,0.1);
    transition: transform 0.3s;
}

.novel-image img:hover {
    transform: scale(1.05);
}

.novel-info {
    flex: 1;
}

.novel-tag {
    font-style: italic;
    color: #666;
    margin: 0.5rem 0;
}

.novel-meta {
    color: #888;
    font-size: 0.9rem;
    margin: 0.5rem 0;
}
/* 添加首行缩进和段落间距 */
.novel-intro p {
    text-indent: 2em;
    margin-bottom: 6em; /* 相当于两行空行 */
}

.novel-desc {
    text-indent: 2em;
    margin-bottom: 1.5em;
}

/* 结语部分也需要首行缩进 */
.conclusion p {
    text-indent: 2em;
}

.timeline,
.culture-background,
.craftsmanship,
.performance-art,
.conclusion {
    margin-bottom: 2.5rem;
}

.timeline-item,
.performance-item,
.craft-item {
    margin-bottom: 1.5rem;
}

ul {
    padding-left: 1.8rem;
    margin-bottom: 1.2rem;
}

li {
    margin-bottom: 0.8rem;
}

/* 在culture.css中添加以下样式 */

/* 时间轴容器 */
.timeline {
    position: relative;
    padding-left: 40px;
    margin: 2rem 0;
}

/* 时间线（垂直线） */
.timeline::before {
    content: '';
    position: absolute;
    left: 15px;
    top: 15px;
    width: 3px;
    height: calc(100% - 30px);
    background: linear-gradient(to bottom, 
        #D4AF37 0%, 
        rgba(212,175,55,0.6) 80%, 
        rgba(212,175,55,0.2) 100%);
}

/* 时间轴项目 */
.timeline-item {
    position: relative;
    margin-bottom: 3rem;
    padding: 1.5rem;
    background: #fff;
    border-radius: 8px;
    box-shadow: 0 3px 10px rgba(0,0,0,0.1);
    transition: transform 0.3s ease;
}

/* 时间节点（圆形标记） */
.timeline-item::before {
    content: '';
    position: absolute;
    left: -38px;
    top: 20px;
    width: 24px;
    height: 24px;
    background: #B22222;
    border: 4px solid #D4AF37;
    border-radius: 50%;
    z-index: 1;
}

/* 时间标签 */
.timeline-item::after {
    content: attr(data-date);
    position: absolute;
    left: -160px;
    top: 15px;
    width: 120px;
    padding: 0.5rem;
    text-align: right;
    color: #634b36;
    font-family: 'STXingkai', cursive;
    font-size: 1.1rem;
}

/* 悬停效果 */
.timeline-item:hover {
    transform: translateX(10px);
}

.timeline-item:hover::before {
    background: #D4AF37;
    border-color: #B22222;
}

/* 响应式设计 */
@media (max-width: 768px) {
    .timeline {
        padding-left: 30px;
    }

    .timeline::before {
        left: 8px;
    }

    .timeline-item::before {
        left: -28px;
        width: 20px;
        height: 20px;
    }

    .timeline-item::after {
        left: auto;
        right: 100%;
        top: -10px;
        width: 100px;
        text-align: left;
        font-size: 0.9rem;
    }
}

/* 响应式设计 */
@media (max-width: 768px) {
    .culture-container {
        flex-direction: column;
    }
    
    .culture-sidebar {
        position: static;
        height: auto;
        flex-direction: row;
        overflow-y: visible;
    }
    
    .sidebar-nav ul {
        writing-mode: horizontal-tb; /* 恢复水平排列 */
    }
    
    .culture-content {
        height: auto;
        margin-left: 0;
    }
    
    .novel-container {
        flex-direction: column;
    }
    
    .novel-image {
        margin-bottom: 1rem;
    }
}