:root {
  --primary-color: #c93a2c;
  /* 朱砂红 */
  --secondary-color: #3d524c;
  /* 墨绿 */
  --accent-color: #e6b33d;
  /* 金 */
  --paper-bg: #f3eee8;
  /* 宣纸色 */
  --ink-color: #33322e;
  /* 墨色 */
}

.left {
  /* font-family: '微软雅黑', sans-serif; */
  max-width: 100px;
  margin: 0 20px;
  padding: 20px 0;
  /* background-color: #f5f5f5; */
  font-family: '华文楷体', '微软雅黑', sans-serif;
  /* overflow-y: auto; */
  /* 允许滚动 */
  position: fixed;
  left: 15px;
  top: 0;
  bottom: 0;
  /* width: 380px; 固定宽度 */
  z-index: 1000;
}

/* 修改后的时间轴样式 */
.timeline {
  position: fixed;
  left: -10px;
  top: 50%;
  transform: translateY(-50%);
  height: 80vh;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 40px 0;
  z-index: 100;
}

/* 时间轴线 */
.timeline::before {
  content: '';
  position: absolute;
  left: 45%;
  top: 5%;
  bottom: 5%;
  width: 3px;
  transform: translateX(-50%);
  background: linear-gradient(to bottom,
      transparent 20%,
      var(--secondary-color) 50%,
      transparent 80%);
}

/* 时间节点 */
.timeline-node {
  position: relative;
  width: 30px;
  height: 30px;
  margin: 15px 0;
  order: 1;
}

/* 节点标题 */
.node-title {
  writing-mode: vertical-lr;
  /* 从左向右的垂直排列 */
  text-orientation: upright;
  /* 保持文字正立 */
  letter-spacing: 2px;
  /* 增加字间距 */
  left: 25px;
  /* 调整位置 */
  white-space: nowrap;
  padding: 1px 1px;
  /* 调整内边距 */
  font-size: 15px;
  /* 适当增大字号 */
  line-height: 1;
  border-radius: 8px;
  background: rgba(243, 238, 232, 0.95);
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.1);
}

/* 激活状态 */
.timeline-node.active .node-title {
  color: var(--primary-color);
  font-weight: bold;
  transform: translateY(-50%) scale(1.1);
}



/* 新增标题换行样式 */
.detail-card h3 .title-wrap {
  display: inline-block;
  vertical-align: middle;
}

.detail-card h3 .ratio {
  display: block;
  font-size: 0.9em;
  margin-top: 4px;
  color: #888;
}


/* 内容区域 */
.content {
  display: none;
  padding: 1px;
  /* background: white; */
  border-radius: 10px;
  /* box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1); */
  margin: 5px 0;
  /* background: linear-gradient(145deg, #fffdfa 0%, #f8f4ed 100%); */
  border: 1px solid #e0d7cc;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
  position: fixed;
  width: 300px;

}

@keyframes pulse {

  0%,
  100% {
    transform: scale(1.1);
  }

  50% {
    transform: scale(1.15);
  }
}

.content.active {
  display: block;
  animation: fadeIn 0.5s ease;
  transform: translateY(-3%) scale(1);
}

@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(20px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.content h2 {
  color: var(--secondary-color);
  font-family: '华文行楷';
  position: relative;
  padding-bottom: 1px;
}

.content h2::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 120px;
  height: 3px;
  background: linear-gradient(90deg,
      transparent 0%,
      var(--primary-color) 50%,
      transparent 100%);
}

/* 新增样式 */
.yin-yang-img {
  max-width: 300px;
  margin: 20px auto;
  display: block;
}

.slider-container {
  position: relative;
  /* width: 80%; */
  /* margin: 30px auto; */
  /* height: 50px; */

  margin: 15px auto !important;
  /* 上下边距从30px→15px */
  height: 40px;
  width: 90%;
  /* 略微加宽 */
}

.slider-background {
  position: absolute;
  width: 100%;
  /* height: 8px; */
  /* background: linear-gradient(to right, #000, #fff); */
  top: 50%;
  transform: translateY(-50%);
  border-radius: 4px;
  background: linear-gradient(to right,
      var(--secondary-color),
      var(--primary-color),
      var(--secondary-color));
  height: 6px;
}

.slider-marks {
  position: absolute;
  width: 100%;
  height: 100%;
  display: flex;
  justify-content: space-between;
}

.mark {
  width: 2px;
  height: 20px;
  background: #666;
  margin-top: 15px;
}

.slider-handle {
  position: absolute;
  width: 24px;
  height: 24px;
  /* background: #e74c3c; */
  border-radius: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  cursor: pointer;
  transition: transform 0.2s;

  background: var(--primary-color);
  border: 2px solid #fff;
  box-shadow: 0 2px 8px rgba(201, 58, 44, 0.3);

}

.slider-value {
  text-align: center;
  margin-top: 1px;
  font-weight: bold;
  color: #333;
}

/* 新增动态内容样式 */
.dynamic-content {
  padding: 2rem;
  /* background: linear-gradient(145deg, #fffdfa 0%, #f8f4ed 100%); */
  border-radius: 12px;
  border: 1px solid #e0d7cc;
  margin: 2rem auto;
  box-shadow: 0 8px 32px rgba(61, 82, 76, 0.08);
}

.balance-display {
  display: grid;
  grid-template-columns: 1fr 1.5fr;
  gap: 2rem;
  align-items: center;
}

#taijiImage.taiji-img {
  /* 增加ID选择器提升优先级 */
  width: auto !important;
  /* 覆盖width:100% */
  max-width: 150px !important;
  /* margin: 12px auto; */
  transition: transform 0.6s ease;
  margin-left: 30px;
}

.taiji-img:hover {
  transform: rotate(360deg);
}


.yin-yang-ratio {
  /* margin-top: 1.5rem; */
  background: #fff;
  /* padding: 1rem; */
  border-radius: 8px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);

  margin-top: 0.8rem !important;
  /* 从1.5rem→0.8rem */
  padding: 0.2rem !important;
  /* 内边距缩小 */
}

.ratio-progress {
  height: 8px;
  background: var(--primary-color);
  border-radius: 4px;
  transition: width 0.8s ease;
}

.ratio-label {
  display: flex;
  justify-content: space-between;
  margin-top: 0.1rem;
  font-size: 0.9em;
}

.constitution-detail {
  display: grid;
  gap: 0.1rem;
}

.detail-card {
  background: #fff;
  padding: 0.1rem;
  border-radius: 8px;
  border-left: 4px solid var(--secondary-color);
  box-shadow: 0 3px 12px rgba(61, 82, 76, 0.06);
}

.symptom-list {
  columns: 1;
  list-style: none;
  padding: 0;
}

.symptom-list li {
  padding: 0.2rem 0;
  position: relative;
  padding-left: 1.2em;
}

.symptom-list li::before {
  content: "•";
  color: var(--primary-color);
  position: absolute;
  left: 0;
}

.advice-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1.5rem;
  margin-top: 1rem;
}

.advice-item {
  text-align: center;
  padding: 1rem;
  background: rgba(201, 58, 44, 0.05);
  border-radius: 6px;
}

.pill-icon,
.acupoint-icon {
  font-size: 2.5em;
  color: var(--secondary-color);
  margin-bottom: 0.5rem;
}

.detail-card {
  padding: 0.8rem !important;
}

/* 响应式优化 */
@media (max-width: 768px) {
  #taijiImage.taiji-img {
    max-width: 80px !important;
    margin: 5px auto !important;
  }

  .slider-container {
    margin: 10px auto !important;
    height: 35px;
  }

  .yin-yang-ratio {
    margin-top: 0.5rem !important;
    padding: 0.6rem !important;
  }
}



/* 新增功法节点样式 */
/* 核心容器 */
.gongfa-container {
  width: 260px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 4px;
  background: #fffaf4;
  padding: 12px 10px;
  border: 1px solid #e0d7cc;
  box-shadow: 0 3px 15px rgba(94, 73, 52, 0.1);
  position: relative;
  font-family: '华文楷体', cursive;
}

/* 导航栏系统 */
/* 新增功法节点样式 */
.gongfa-nav {
  display: flex;
  justify-content: center;
  gap: 30px;
  margin: 30px 0;
  background: linear-gradient(90deg, #f8f4ed 0%, #fffdfa 100%);
  padding: 15px;
  border-radius: 50px;
  margin-top: -30px;
}

.nav-item {
  padding: 12px 25px;
  border-radius: 25px;
  /* background: #f0f0f0; */
  cursor: pointer;
  /* transition: all 0.3s ease; */
  position: relative;
  font-weight: 500;

  background: none;
  border: 2px solid var(--secondary-color);
  color: var(--secondary-color);
  font-family: '华文楷体';
  transition: all 0.3s ease;
}

.nav-item.active {
  /* background: #e74c3c; */
  /* color: white; */
  transform: scale(1.1);
  box-shadow: 0 4px 15px rgba(231, 76, 60, 0.3);

  background: var(--primary-color);
  border-color: var(--primary-color);
  color: #fff;
}

/* 视频修炼区 */
.video-section {
  width: 100%;
  height: 150px;
  border: 1.5px solid #d4b99e;
  border-radius: 6px;
  overflow: visible;
  background: #000;
  margin: -8px 0 4px;
  position: relative;

}

.main-video {
  width: 100%;
  height: auto;
  object-fit: contain;
  opacity: 0.9;
}

/* 功法要诀区 */
.data-sidebar {
  width: 143%;
  padding: 12px;
  background: #fcf8f2;
  border: 1px solid #e0d7cc;
  border-radius: 6px;
  margin-top: -35px;
}

.key-points h3 {
  color: #8c5c4a;
  font-size: 14px;
  margin: 0 0 8px;
  padding-left: 8px;
  border-left: 3px solid #a95238;
  line-height: 1.3;
}

.key-points ul {
  padding: 0;
  margin: 0;
}

.key-points li {
  padding: 8px;
  margin: 4px 0;
  background: #fff;
  border: 1px solid #e0d7cc;
  border-radius: 3px;
  font-size: 12px;
  line-height: 1;
  color: #665147;
  list-style: "· " inside;
}

/* 响应式适配 */
@media (max-width: 480px) {
  .gongfa-container {
    width: 100%;
    padding: 8px;
    border-radius: 0;
  }

  .gongfa-nav {
    flex-wrap: wrap;
    border-radius: 15px;
    gap: 4px;
  }

  .nav-item {
    flex: 1 0 45%;
    padding: 6px 12px;
    font-size: 12px;
  }

  .video-section {
    width: 100%;
    height: auto;
    aspect-ratio: 16/9;
  }
}













/* 视频播放 */
/* 添加视频面板样式 */
.video-panel {
  position: fixed;
  left: 25px;
  top: 256px;
  width: 240px;
  z-index: 1000;
  background: rgba(248, 244, 232, 0.9);
  border-radius: 12px;
  padding: 15px;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
  border: 1px solid #d0b9a1;
  height: 140px;
}

.medical-video {
  width: 100%;
  height: 153px;
  border-radius: 8px;
  overflow: hidden;
  background: #000;
  margin-top: -5px;
}

/* 调整原有内容的位置 */
.left {
  margin-left: 360px;
  /* 为视频留出空间 */
}

.timeline {
  left: 340px;
  /* 时间轴右移 */
}

/* 保证视频始终在最上层 */
.video-panel {
  z-index: 1001;
}

.navbar {
  z-index: 1002;
  /* 导航栏保持在最顶层 */
}

@media (max-width: 1200px) {
  .video-panel {
    position: relative;
    left: auto;
    top: auto;
    width: 100%;
    margin: 20px 0;
  }

  .left {
    margin-left: 0;
  }

  .timeline {
    left: -10px;
  }
}



/* 在原有.timeline-node样式后添加 */
a.timeline-node {
  position: fixed;
  left: 20px;
  top: 50%;
  transform: translateY(-50%);
  z-index: 1001;
  text-decoration: none;
  transition: all 0.3s ease;
}

.xuewei {
  /* writing-mode: vertical-rl; 竖向排列文字 */
  /* padding: 15px 8px; */
  background: rgba(248, 244, 232, 0.9);
  border-radius: 8px;
  box-shadow: 0 4px 12px rgba(83, 71, 65, 0.1);
  border: 1px solid var(--浅绛);
  color: var(--胭脂红);
  font-size: 1.2em;
  /* letter-spacing: 2px; */
  transition: all 0.3s ease;
  margin-left: -14px;
}

a.timeline-node:hover .xuewei {
  transform: translateX(5px);
  background: var(--胭脂红);
  color: var(--宣纸白);
  box-shadow: 0 6px 16px rgba(197, 61, 52, 0.3);
}




@font-face {
  font-family: '汉仪飞檐隶';
  src: url('../material/汉仪飞檐隶.ttf') format('truetype');
  font-weight: normal;
  font-style: normal;
}

body {
  background: 
    linear-gradient(rgba(251, 242, 221, 0.9), rgba(251, 242, 221, 0.9)),
    url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" width="100" height="100" viewBox="0 0 100 100"><filter id="noise"><feTurbulence type="fractalNoise" baseFrequency="0.04" numOctaves="5" stitchTiles="stitch"/><feColorMatrix type="matrix" values="1 0 0 0 0 0 1 0 0 0 0 0 1 0 0 0 0 0 0.1 -0.05"/></filter><rect width="100" height="100" filter="url(%23noise)" fill="%23f3eee8" opacity="0.3"/></svg>');
}

.navbar {
  position: absolute;
  top: 1%;
  right: 2.5%;
  display: flex;
  flex-direction: row;
  justify-content: flex-end;
  padding: 10px;
  z-index: 3;
}

.navbar a:hover {
  transform: scale(1.1);
  color: #FFD700;
}

.navbar a {
  color: #264758;
  text-decoration: none;
  font-size: 25px;
  margin-right: 35px;
  font-family: '汉仪飞檐隶', sans-serif;
}

.navbar a:last-child {
  margin-right: 7px;
}

:root {
  --宣纸白: #F8F4E8;
  --浅绛: #D6B7A5;
  --茶色: #75665B;
  /* 加深茶色 */
  --淡竹青: #B7C4A0;
  --胭脂红: #C53D34;
  --浅陶: #D3C0AB;
  --墨韵: #534741;
  /* 新增深褐色 */
}

/* 浮动容器样式 */
.wuyinliaofa {
  position: fixed;
  right: 15px;
  top: 85px;
  z-index: 1000;
  /* background: rgba(248, 244, 232, 0.95); */
  backdrop-filter: blur(5px);
  border-radius: 16px;
  /* box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1); */
  padding: 15px;
}



.player-container {
  background: linear-gradient(to right, var(--浅陶), var(--宣纸白));
  width: 320px;
  padding: 1px;
  border-radius: 16px;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
  position: relative;
  border: 1px solid var(--浅绛);
  margin-bottom: 30px;
  height: 380px;
}


.yin-yang {
  width: 80px;
  height: 80px;
  position: absolute;
  top: -40px;
  left: 50%;
  transform: translateX(-50%);
  background: url('../material/0\ \(9\).png') no-repeat center/contain;
  filter: drop-shadow(0 2px 5px rgba(0, 0, 0, 0.1));
}

h2 {
  color: var(--胭脂红) !important;
  text-align: center;
  margin-bottom: 1px;
  margin-top: 50px;
  font-size: 1.4em;
  text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.1);
}

select {
  background: rgba(248, 244, 232, 0.9);
  border: 1px solid var(--浅绛);
  padding: 8px 15px;
  width: 100%;
  margin: 15px 0;
  border-radius: 20px;
  font-family: 'Ma Shan Zheng', cursive;
  color: var(--墨韵);
  /* 加深选项文字 */
  background-image: url('dropdown-arrow-light.png');
  background-repeat: no-repeat;
  background-position: right 12px center;
  background-size: 12px;
  cursor: pointer;
  transition: all 0.3s;
}

select:hover {
  background: rgba(183, 196, 160, 0.1);
  border-color: var(--茶色);
}

.song-info {
  color: var(--墨韵);
  text-align: center;
  margin: 20px 0;
  padding: 15px;
  background: rgba(248, 244, 232, 0.7);
  /* 提高背景不透明度 */
  border-radius: 8px;
  border: 1px solid var(--浅绛);
  backdrop-filter: blur(2px);
}

.controls {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  margin: 25px 0;
}

button {
  background: rgba(248, 244, 232, 0.9);
  border: 1px solid var(--浅绛);
  padding: 15px;
  border-radius: 50%;
  cursor: pointer;
  transition: all 0.3s;
  font-size: 16px;
  color: var(--墨韵);
  /* 按钮文字颜色 */
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

button:hover {
  background: var(--淡竹青);
  transform: scale(1.1);
  color: var(--宣纸白);
  border-color: var(--墨韵);
}

.progress-container {
  height: 4px;
  background: rgba(248, 244, 232, 0.5);
  border-radius: 2px;
  margin: 20px 0;
  position: relative;
}

.progress-bar {
  height: 100%;
  background: var(--胭脂红);
  width: 0;
  transition: width 0.1s linear;
}

.medical-effect {
  font-size: 13px;
  color: var(--茶色);
  margin-top: 8px;
  line-height: 1.6;
  letter-spacing: 0.5px;
}

#currentSong {
  font-size: 1.2em;
  color: var(--胭脂红);
  /* 当前歌曲名称颜色 */
  margin-bottom: 5px;
}

/* 添加在原有样式中 */
.theory-container {
  background: linear-gradient(to bottom, var(--宣纸白), var(--浅陶));
  width: 320px;
  padding: 0.1px;
  border-radius: 16px;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
  border: 1px solid var(--浅绛);
  height: 160px;
  /* 设置固定高度与五行图一致 */
  display: flex;
  gap: 15px;
  position: relative;
  margin-top: -10px;
}

.theory-graphic {
  flex: 1;
  min-width: 160px;
}


.theory-container h3 {
  color: var(--胭脂红);
  text-align: center;
  margin: 0 0 15px;
  font-size: 1.3em;
}


.theory-desc {
  flex: 1;
  background: rgba(248, 244, 232, 0.8);
  padding: 15px;
  border-radius: 8px;
  font-size: 13px;
  line-height: 1.5;
  height: 82%;
  overflow-y: auto;
  /* 为滚动条留出空间 */
}

/* 自定义滚动条 */
.theory-desc::-webkit-scrollbar {
  width: 4px;
  background-color: rgba(83, 71, 65, 0.1);
}

.theory-desc::-webkit-scrollbar-thumb {
  background-color: var(--墨韵);
  border-radius: 2px;
}

.theory-desc li {
  margin: 8px 0;
}

.element text {
  font-family: 'Ma Shan Zheng', cursive;
}

.element circle {
  cursor: pointer;
  transition: transform 0.3s;
}

.element:hover circle {
  transform: scale(1.5);
  filter: drop-shadow(0 0 3px rgba(0, 0, 0, 0.3));
}

@media (max-width: 480px) {

  .player-container,
  .theory-container {
    width: 90%;
    padding: 20px;
  }

  .wu-xing {
    width: 200px;
    height: 200px;
  }
}

/* 新增理论描述样式 */
.theory-desc h4 {
  color: var(--墨韵);
  margin: 12px 0 6px;
  font-size: 14px;
}

.theory-features {
  padding-left: 15px;
}

.theory-features li {
  list-style-type: "❖ ";
  color: var(--茶色);
}

#container {
  transition: opacity 0.2s ease;
  height: 100%;
}

#container.hidden {
  opacity: 0;
  pointer-events: none;
}


/* 左侧left的样式 */

:root {
  --primary-color: #c93a2c;
  /* 朱砂红 */
  --secondary-color: #3d524c;
  /* 墨绿 */
  --accent-color: #e6b33d;
  /* 金 */
  --paper-bg: #f3eee8;
  /* 宣纸色 */
  --ink-color: #33322e;
  /* 墨色 */
}

.left {
  /* font-family: '微软雅黑', sans-serif; */
  max-width: 400px;
  margin: 0 20px;
  padding: 20px 0;
  /* background-color: #f5f5f5; */
  font-family: '华文楷体', '微软雅黑', sans-serif;
  background: var(--paper-bg) url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100" opacity="0.08"><text x="50%" y="50%" font-size="40" font-family="隶书">醫</text></svg>');
  color: var(--ink-color);
}

/* 修改后的时间轴样式 */
.timeline {
  position: fixed;
  left: -10px;
  top: 50%;
  transform: translateY(-50%);
  height: 80vh;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 40px 0;
  z-index: 100;
}

/* 时间轴线 */
.timeline::before {
  content: '';
  position: absolute;
  left: 45%;
  top: 5%;
  bottom: 5%;
  width: 3px;
  transform: translateX(-50%);
  background: linear-gradient(to bottom,
      transparent 20%,
      var(--secondary-color) 50%,
      transparent 80%);
}

/* 时间节点 */
.timeline-node {
  position: relative;
  width: 30px;
  height: 30px;
  margin: 15px 0;
  order: 1;
}

/* 节点标题 */
.node-title {
  position: absolute;
  left: 20px;
  top: 50%;
  transform: translateY(-50%);
  white-space: nowrap;
  font-size: 15px;
  transition: all 0.3s ease;
  background: rgba(243, 238, 232, 0.9);
  padding: 5px 15px;
  border-radius: 20px;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.1);
}

/* 激活状态 */
.timeline-node.active .node-title {
  color: var(--primary-color);
  font-weight: bold;
  transform: translateY(-50%) scale(1.1);
}





/* 内容区域 */
.content {
  display: none;
  padding: 10px;
  /* background: white; */
  border-radius: 10px;
  /* box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1); */
  margin: 5px 0;
  background: linear-gradient(145deg, #fffdfa 0%, #f8f4ed 100%);
  border: 1px solid #e0d7cc;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
  position: relative;
}

@keyframes pulse {

  0%,
  100% {
    transform: scale(1.1);
  }

  50% {
    transform: scale(1.15);
  }
}

.content.active {
  display: block;
  animation: fadeIn 0.5s ease;
}

@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(20px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.content h2 {
  color: var(--secondary-color);
  font-family: '华文行楷';
  position: relative;
  padding-bottom: 15px;
}

.content h2::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 120px;
  height: 3px;
  background: linear-gradient(90deg,
      transparent 0%,
      var(--primary-color) 50%,
      transparent 100%);
}

/* 新增样式 */
.yin-yang-img {
  max-width: 300px;
  margin: 20px auto;
  display: block;
}

.slider-container {
  position: relative;
  width: 80%;
  margin: 30px auto;
  height: 50px;
}

.slider-background {
  position: absolute;
  width: 100%;
  /* height: 8px; */
  /* background: linear-gradient(to right, #000, #fff); */
  top: 50%;
  transform: translateY(-50%);
  border-radius: 4px;
  background: linear-gradient(to right,
      var(--secondary-color),
      var(--primary-color),
      var(--secondary-color));
  height: 6px;
}

.slider-marks {
  position: absolute;
  width: 100%;
  height: 100%;
  display: flex;
  justify-content: space-between;
}

.mark {
  width: 2px;
  height: 20px;
  background: #666;
  margin-top: 15px;
}

.slider-handle {
  position: absolute;
  width: 24px;
  height: 24px;
  /* background: #e74c3c; */
  border-radius: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  cursor: pointer;
  transition: transform 0.2s;

  background: var(--primary-color);
  border: 2px solid #fff;
  box-shadow: 0 2px 8px rgba(201, 58, 44, 0.3);

}

.slider-value {
  text-align: center;
  margin-top: 10px;
  font-weight: bold;
  color: #333;
}

/* 新增动态内容样式 */
.dynamic-content {
  padding: 2rem;
  background: linear-gradient(145deg, #fffdfa 0%, #f8f4ed 100%);
  border-radius: 12px;
  border: 1px solid #e0d7cc;
  margin: 2rem auto;
  box-shadow: 0 8px 32px rgba(61, 82, 76, 0.08);
}

.balance-display {
  display: grid;
  grid-template-columns: 1fr 1.5fr;
  gap: 2rem;
  align-items: center;
}

.taiji-img {
  width: 100%;
  max-width: 320px;
  transition: transform 0.8s ease;
  filter: drop-shadow(0 4px 12px rgba(61, 82, 76, 0.1));
}

.taiji-img:hover {
  transform: rotate(360deg);
}


.yin-yang-ratio {
  margin-top: 1.5rem;
  background: #fff;
  padding: 1rem;
  border-radius: 8px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
}

.ratio-progress {
  height: 8px;
  background: var(--primary-color);
  border-radius: 4px;
  transition: width 0.8s ease;
}

.ratio-label {
  display: flex;
  justify-content: space-between;
  margin-top: 0.5rem;
  font-size: 0.9em;
}

.constitution-detail {
  display: grid;
  gap: 1.5rem;
}

.detail-card {
  background: #fff;
  padding: 1.5rem;
  border-radius: 8px;
  border-left: 4px solid var(--secondary-color);
  box-shadow: 0 3px 12px rgba(61, 82, 76, 0.06);
}

.symptom-list {
  columns: 2;
  list-style: none;
  padding: 0;
}

.symptom-list li {
  padding: 0.5rem 0;
  position: relative;
  padding-left: 1.2em;
}

.symptom-list li::before {
  content: "•";
  color: var(--primary-color);
  position: absolute;
  left: 0;
}

.advice-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1.5rem;
  margin-top: 1rem;
}

.advice-item {
  text-align: center;
  padding: 1rem;
  background: rgba(201, 58, 44, 0.05);
  border-radius: 6px;
}

.pill-icon,
.acupoint-icon {
  font-size: 2.5em;
  color: var(--secondary-color);
  margin-bottom: 0.5rem;
}

@media (max-width: 768px) {
  .balance-display {
    grid-template-columns: 1fr;
  }

  .taiji-svg {
    max-width: 200px;
    margin: 0 auto;
  }

  .symptom-list {
    columns: 1;
  }

  .advice-grid {
    grid-template-columns: 1fr;
  }
}

/* 矩阵容器样式 */
.matrix-container {
  display: grid;
  grid-template-columns: 40px 1fr;
  gap: 10px;
  max-width: 800px;
  margin: 30px auto;
}

/* 矩阵网格 */
.matrix-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 2px;
  background: #eee;
  padding: 2px;
  border-radius: 4px;
}

/* 矩阵色块 */
.matrix-cell {
  aspect-ratio: 1;
  background: #fff;
  cursor: pointer;
  transition: all 0.3s ease;
  position: relative;
}

.matrix-cell {
  border: 2px solid rgba(61, 82, 76, 0.2);
  transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.matrix-cell:hover {
  transform: scale(1.15);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.enhanced-matrix {
  margin: 2rem auto;
  max-width: 800px;
  padding: 1.5rem;
  background: rgba(255, 255, 255, 0.95);
  border-radius: 12px;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
}

/* 调整矩阵网格 */
.matrix-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 4px;
  background: rgba(61, 82, 76, 0.08);
  padding: 4px;
  border-radius: 8px;
}

/* 优化色块样式 */
.matrix-cell {
  aspect-ratio: 1;
  cursor: pointer;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  position: relative;
  border: 1px solid rgba(61, 82, 76, 0.15);
  /* 默认背景色 */
  background:
    linear-gradient(135deg,
      rgba(255, 255, 255, 0.15) 0%,
      rgba(0, 0, 0, 0.05) 100%),
    #fff;
  /* 渐变叠加层 */
}

/* 五行渐变色 */
.matrix-cell[data-element="木"] {
  background:
    linear-gradient(135deg,
      rgba(139, 195, 74, 1) 0%,
      rgba(106, 155, 55, 1) 100%),
    #8BC34A;
}

.matrix-cell[data-element="火"] {
  background:
    linear-gradient(135deg,
      rgba(255, 87, 34, 1) 0%,
      rgba(214, 69, 24, 1) 100%),
    #FF5722;
}

.matrix-cell[data-element="土"] {
  background:
    linear-gradient(135deg,
      rgba(255, 193, 7, 1) 0%,
      rgba(214, 160, 0, 1) 100%),
    #FFC107;
}

.matrix-cell[data-element="金"] {
  background:
    linear-gradient(135deg,
      rgba(96, 125, 139, 1) 0%,
      rgba(74, 98, 110, 1) 100%),
    #607D8B;
}

.matrix-cell[data-element="水"] {
  background:
    linear-gradient(135deg,
      rgba(33, 150, 243, 1) 0%,
      rgba(25, 118, 210, 1) 100%),
    #2196F3;
}

/* 悬停效果 */
.matrix-cell:hover {
  transform: scale(1.15);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
  z-index: 2;
}

/* 坐标轴样式 */
.matrix-axis {
  display: flex;
  justify-content: space-around;
  font-weight: bold;
  color: #666;
}

.y-axis {
  flex-direction: column;
  height: 700px;
  justify-content: space-between;
  margin-top: 10px;
  margin-left: 10px;
}

.x-axis {
  grid-column: 2;
}

/* 添加音律标记 */
.matrix-cell::after {
  content: attr(data-tone);
  position: absolute;
  bottom: 6px;
  right: 6px;
  font-size: 0.9em;
  color: white;
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.3);
}

/* 详情框样式 */
.detail-box {
  padding: 20px;
  margin: 30px auto;
  max-width: 600px;
  /* background: #fff; */
  border-radius: 8px;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
  min-height: 120px;

  background: #fff;
  border: 2px solid var(--secondary-color);
  position: relative;
}

.detail-box::before {
  content: '';
  position: absolute;
  top: -2px;
  left: -2px;
  right: -2px;
  bottom: -2px;
  border: 2px solid var(--primary-color);
  mix-blend-mode: multiply;
}

.detail-box h3 {
  color: #e74c3c;
  margin-bottom: 10px;
}

.detail-box p {
  line-height: 1.6;
  color: #555;
}

/* 新增功法节点样式 */
.gongfa-nav {
  display: flex;
  justify-content: center;
  gap: 30px;
  margin: 30px 0;
  background: linear-gradient(90deg, #f8f4ed 0%, #fffdfa 100%);
  padding: 15px;
  border-radius: 50px;
}

.nav-item {
  padding: 12px 25px;
  border-radius: 25px;
  /* background: #f0f0f0; */
  cursor: pointer;
  /* transition: all 0.3s ease; */
  position: relative;
  font-weight: 500;

  background: none;
  border: 2px solid var(--secondary-color);
  color: var(--secondary-color);
  font-family: '华文楷体';
  transition: all 0.3s ease;
}

.nav-item.active {
  /* background: #e74c3c; */
  /* color: white; */
  transform: scale(1.1);
  box-shadow: 0 4px 15px rgba(231, 76, 60, 0.3);

  background: var(--primary-color);
  border-color: var(--primary-color);
  color: #fff;
}

.gongfa-container {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 30px;
  max-width: 1200px;
  margin: 0 auto;
}

.video-section {
  position: relative;
  background: #000;
  border-radius: 12px;
  overflow: hidden;
  border: 3px solid var(--secondary-color);
  box-shadow: 0 8px 20px rgba(61, 82, 76, 0.1);
}

.video-section::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(45deg,
      transparent 65%,
      rgba(201, 58, 44, 0.1) 100%);
}

.main-video {
  width: 100%;
  height: 500px;
  object-fit: cover;
}

.meridian-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  opacity: 0.7;
}

.data-sidebar {
  background: #fff;
  padding: 20px;
  border-radius: 12px;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
}

.effect-chart {
  margin-bottom: 30px;
  background: #fff;
  border: 1px solid #e0d7cc;
}

.time-label {
  font-size: 0.9em;
  color: #666;
}

.key-points li {
  padding: 12px;
  margin: 8px 0;
  background: #f8f8f8;
  border-left: 4px solid #e74c3c;
  border-radius: 4px;
}

.timeline-compare {
  display: flex;
  justify-content: center;
  gap: 50px;
  margin: 40px 0;
}

.time-node {
  width: 60px;
  height: 60px;
  border-radius: 50%;
  background: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
  transition: all 0.3s ease;
}

.time-node.active {
  background: #e74c3c;
  color: white;
  transform: scale(1.2);
}

/* 响应式优化 */
@media (max-width: 768px) {
  .gongfa-nav {
    flex-direction: column;
    border-radius: 25px;
  }

  .nav-item {
    width: 100%;
    text-align: center;
  }

  .matrix-container {
    grid-template-columns: 1fr;
  }

  .y-axis {
    display: none;
  }
}

/* 新增五行样式 */
.wuxing-overview {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 1.5rem;
  margin: 2rem 0;
}

.element-card {
  background: rgba(255, 255, 255, 0.9);
  padding: 1.5rem;
  border-radius: 12px;
  text-align: center;
  box-shadow: 0 4px 12px rgba(61, 82, 76, 0.08);
  transition: transform 0.3s ease;
}

.element-card:hover {
  transform: translateY(-5px);
}

.element-icon {
  font-size: 2.5rem;
  margin-bottom: 0.5rem;
}

.element-properties p {
  margin: 0.4rem 0;
  color: var(--secondary-color);
  font-size: 0.95em;
}

.sheng {
  background: #8BC34A;
}

.ke {
  background: #c93a2c;
}

.phase-wood {
  background: #8BC34A;
  top: 20%;
  left: 20%;
}

.phase-fire {
  background: #FF5722;
  top: 20%;
  right: 20%;
}

.phase-earth {
  background: #FFC107;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
}

.phase-metal {
  background: #607D8B;
  bottom: 20%;
  left: 20%;
}

.phase-water {
  background: #2196F3;
  bottom: 20%;
  right: 20%;
}

.enhanced-detail {
  background: linear-gradient(145deg, #fffdfa 0%, #f8f4ed 100%);
  border-radius: 12px;
  padding: 2rem;
  margin: 2rem auto;
  border-left: 4px solid var(--secondary-color);
}

.detail-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1.5rem;
}

.element-tag {
  padding: 0.5rem 1rem;
  border-radius: 20px;
  font-size: 0.9em;
  color: white;
}

.theory-section {
  margin-bottom: 2rem;
}

.application-section ul {
  columns: 2;
  list-style: none;
  padding: 0;
}

.application-section li {
  padding: 0.8rem;
  margin: 0.5rem 0;
  background: rgba(201, 58, 44, 0.05);
  border-radius: 6px;
}

@media (max-width: 768px) {
  .wuxing-overview {
    grid-template-columns: 1fr;
  }

  .application-section ul {
    columns: 1;
  }

  .relation-diagram {
    height: 250px;
  }
}