/* =========================================================
   华中农业大学幼儿园 - 主样式
   主题色：校徽红 #9d2933 / 深红 #7c1f26 / 米白 #faf6f0
   ========================================================= */
:root {
  --red: #8d1f10;        /* 主色：导航/header 底色 */
  --red-dark: #6e150a;   /* 菜单栏：比主色低几个色度 */
  --red-deep: #571106;
  --gold: #d9a441;
  --cream: #faf6f0;
  --bg-gray: #f5f5f5;
  --text: #333;
  --text-light: #777;
  --radius: 8px;
  --shadow: 0 4px 16px rgba(0, 0, 0, .08);
  --transition: all .3s ease;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  font-family: "Microsoft YaHei", "PingFang SC", "Helvetica Neue", Arial, sans-serif;
  font-size: 15px;
  color: var(--text);
  background: var(--bg-gray);
  line-height: 1.7;
  overflow-x: hidden; /* 防止意外横向滚动撑破布局 */
}

img { max-width: 100%; height: auto; display: block; }

/* 防栅格被内容撑破：
   栅格子项默认 min-width:auto，图片/长文本的固有宽度（如 SVG 的 800px）
   会把轨道撑得比屏幕还宽，手机端表现为"列表撑开、显示不全"。
   统一允许子项收缩到容器宽度内 */
.news-grid > *, .duo-grid > *, .notice-grid > *, .team-grid > *,
.gallery-grid > *, .gallery-list-grid > *, .page-layout > *, .focus-slider, .hero-slider {
  min-width: 0;
}

a { color: inherit; text-decoration: none; transition: var(--transition); }
ul { list-style: none; }
time { color: var(--text-light); font-style: normal; }

.container {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 16px;
}

/* ================= Header（深红底 + 白色 logo） ================= */
.site-header {
  background: var(--red);
  position: relative;
  z-index: 100;
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding-top: 12px;
  padding-bottom: 12px;
}

.brand { display: flex; align-items: center; gap: 12px; flex-shrink: 0; }

.brand-logo { height: 46px; width: auto; }

/* 深底上的搜索框：边框与图标统一为白色 */
.search-box {
  display: flex;
  align-items: center;
  border: 1px solid rgba(255, 255, 255, .85);
  border-radius: 20px;
  overflow: hidden;
  background: rgba(255, 255, 255, .12);
}
.search-box input {
  border: none;
  outline: none;
  padding: 7px 14px;
  font-size: 13px;
  width: 180px;
  background: transparent;
  color: #fff;
}
.search-box input::placeholder { color: rgba(255, 255, 255, .65); }

/* 清空按钮（输入后出现的 X）：浏览器原生控件，换成白色 X 与整体配色统一 */
.search-box input[type="search"]::-webkit-search-cancel-button {
  -webkit-appearance: none;
  appearance: none;
  width: 13px;
  height: 13px;
  cursor: pointer;
  /* 白色圆圈 X 图标 */
  background-image: url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23ffffff' stroke-width='2.4' stroke-linecap='round'%3E%3Ccircle cx='12' cy='12' r='10' fill='none' stroke='%23ffffff' stroke-opacity='.55'/%3E%3Cline x1='8' y1='8' x2='16' y2='16'/%3E%3Cline x1='16' y1='8' x2='8' y2='16'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-size: contain;
}
.search-box .search-btn {
  border: none;
  background: transparent;
  cursor: pointer;
  padding: 6px 11px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff; /* 白色放大镜，与边框同色 */
}

.search-toggle {
  display: none;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border: 1px solid rgba(255, 255, 255, .85);
  border-radius: 50%;
  background: transparent;
  cursor: pointer;
  color: #fff; /* 白色放大镜，与边框同色 */
  flex-shrink: 0;
}

/* 深底上的汉堡按钮 */
.nav-toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 40px;
  height: 40px;
  background: transparent;
  border: 1px solid rgba(255, 255, 255, .45);
  border-radius: 6px;
  cursor: pointer;
  padding: 8px;
}
.nav-toggle span {
  display: block;
  height: 2px;
  background: #fff;
  border-radius: 2px;
  transition: var(--transition);
}
.nav-toggle.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-toggle.open span:nth-child(2) { opacity: 0; }
.nav-toggle.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ================= 导航 ================= */
.site-nav { background: var(--red); position: sticky; top: 0; z-index: 99; box-shadow: var(--shadow); }

.nav-list { display: flex; justify-content: space-between; flex-wrap: wrap; }

.nav-list a {
  display: block;
  color: #fff;
  font-size: 16px;
  padding: 14px 18px;
  letter-spacing: 1px;
  position: relative;
}
.nav-list a:hover,
.nav-list a.active { background: var(--red-deep); }
.nav-list a.active::after {
  content: "";
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  bottom: 6px;
  width: 24px;
  height: 3px;
  border-radius: 2px;
  background: var(--gold);
}

/* ---- 二级菜单（桌面端 hover 展开） ---- */
.nav-list li { position: relative; }

/* 下箭头用纯 CSS 边框三角形绘制（不用特殊字符，避免站群平台转码后变成问号） */
.has-sub > a::after {
  content: "";
  display: inline-block;
  width: 0;
  height: 0;
  margin-left: 5px;
  vertical-align: 2px;
  border-left: 4px solid transparent;
  border-right: 4px solid transparent;
  border-top: 5px solid currentColor;
  opacity: .85;
}

.sub-list {
  position: absolute;
  top: 100%;
  left: 0;
  min-width: 100%;
  background: #fff;
  border-top: 3px solid var(--gold);
  box-shadow: 0 8px 20px rgba(0, 0, 0, .15);
  border-radius: 0 0 6px 6px;
  overflow: hidden;
  opacity: 0;
  visibility: hidden;
  transform: translateY(10px);
  transition: all .25s ease;
  z-index: 110;
}

.nav-list li:hover > .sub-list {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.sub-list a {
  color: var(--text);
  font-size: 14px;
  padding: 11px 18px;
  border-bottom: 1px solid #f2f2f2;
  white-space: nowrap;
  text-align: center;
}
.sub-list li:last-child a { border-bottom: none; }
.sub-list a:hover {
  background: var(--cream);
  color: var(--red);
}

/* ================= Hero Banner 轮播 ================= */
.hero { background: var(--cream); }

.hero-slider { position: relative; overflow: hidden; }

.hero-slide { display: none; position: relative; }
.hero-slide.active { display: block; animation: heroFade .6s ease; }
@keyframes heroFade { from { opacity: .3; } to { opacity: 1; } }

.hero-slide img { width: 100%; height: auto; }

.hero-caption {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 46px;
}
.hero-caption p {
  display: inline-block;
  background: rgba(87, 17, 6, .82);
  color: #fff;
  font-size: 15px;
  letter-spacing: 1px;
  padding: 8px 22px;
  border-radius: 4px;
}

/* 左右切换箭头 */
.hero-arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 46px;
  height: 46px;
  border: none;
  border-radius: 50%;
  background: rgba(0, 0, 0, .28);
  color: #fff;
  font-size: 28px;
  line-height: 1;
  cursor: pointer;
  opacity: 0;
  transition: var(--transition);
  z-index: 5;
}
.hero-slider:hover .hero-arrow { opacity: 1; }
.hero-arrow.prev { left: 18px; }
.hero-arrow.next { right: 18px; }
.hero-arrow:hover { background: var(--red); }

/* 圆点指示器 */
.hero-dots {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 14px;
  display: flex;
  justify-content: center;
  gap: 8px;
  z-index: 5;
}
.hero-dots .dot { background: rgba(255, 255, 255, .6); }
.hero-dots .dot.active { background: #fff; }

/* ================= 通用 Section ================= */
.section { padding: 48px 0 56px; }

/* 园所动态：底图 m1 只铺区块下部（贴底、全宽等比），上部白色 */
.section-news {
  background-color: #fff;
  background-image: url("../img/m1_bg.png");
  background-repeat: no-repeat;
  background-position: bottom center;
  background-size: 100% auto;
}

/* 精彩时刻/队伍建设：白色底 */
.section-duo {
  background: #fff;
}

.section-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 2px solid var(--red);
  margin-bottom: 26px;
  padding-bottom: 0;
}
.section-head h2 {
  font-size: 26px;
  color: var(--red);
  letter-spacing: 2px;
  position: relative;
  padding-bottom: 10px;
}
.section-head h2::before {
  content: "";
  display: inline-block;
  width: 6px;
  height: 22px;
  background: var(--red);
  border-radius: 3px;
  margin-right: 10px;
  vertical-align: -2px;
}
.section-head h2::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -2px;
  width: 120px;
  height: 4px;
  background: var(--red);
  border-radius: 2px;
}

.more { font-size: 13px; color: var(--text-light); padding-bottom: 12px; }
.more:hover { color: var(--red); }

.section-head.light { border-bottom-color: rgba(255, 255, 255, .5); }
.section-head.light h2 { color: #fff; }
.section-head.light h2::before { background: var(--gold); }
.section-head.light h2::after { background: var(--gold); }
.section-head.light .more {
  color: rgba(255, 255, 255, .85);
  border: 1px solid rgba(255, 255, 255, .55);
  border-radius: 3px;
  padding: 4px 14px;
  margin-bottom: 12px;
}
.section-head.light .more:hover { background: rgba(255, 255, 255, .15); color: #fff; }

/* ================= 园所动态 ================= */
.news-grid {
  display: grid;
  grid-template-columns: 46% 1fr;
  gap: 34px;
  align-items: start;
}
.news-grid > * { min-width: 0; } /* 防止内容把栅格撑破 */

.focus-item .focus-pic { position: relative; border-radius: var(--radius); overflow: hidden; }

/* HTML 静态轮播：只显示带 active 的当前张 */
.focus-slider .focus-item { display: none; }
.focus-slider .focus-item.active { display: block; }
.focus-item .focus-pic img { width: 100%; aspect-ratio: 16 / 9; object-fit: cover; transition: transform .4s; }
.focus-item:hover .focus-pic img { transform: scale(1.04); }

.date-badge {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  background: var(--red);
  color: #fff;
  width: 62px;
  height: 62px;
  border-radius: 6px;
  line-height: 1.15;
  box-shadow: var(--shadow);
}
.date-badge b { font-size: 24px; }
.date-badge i { font-style: normal; font-size: 11px; opacity: .9; }

.focus-pic .date-badge { position: absolute; left: 14px; bottom: 14px; }

.focus-item h3 { font-size: 18px; margin-top: 16px; line-height: 1.5; }
.focus-item h3 a:hover { color: var(--red); }
.focus-item p { margin-top: 8px; color: var(--text-light); font-size: 14px; }

.slider-dots { display: flex; gap: 8px; margin-top: 14px; }
.dot {
  width: 10px; height: 10px;
  border-radius: 50%;
  background: #ddd;
  cursor: pointer;
  transition: var(--transition);
}
.dot.active { background: var(--red); width: 24px; border-radius: 5px; }

/* 右侧列表 */
.news-list li {
  display: flex;
  gap: 16px;
  align-items: flex-start;
  padding: 13px 0;
  border-bottom: 1px dashed #e5e5e5;
}
.news-list li:last-child { border-bottom: none; }

/* 园所动态（深色底图区块）：右列表高度跟随左轮播卡（JS 精确同步），新闻每条白卡片 */
.section-news .news-grid { align-items: stretch; }
.section-news .news-list { overflow: hidden; }

.section-news .news-focus {
  background: #fff;
  border-radius: var(--radius);
  padding: 14px 14px 12px;
  box-shadow: 0 2px 10px rgba(0, 0, 0, .12);
  display: flex;
  flex-direction: column;
}
.section-news .news-focus .slider-dots {
  margin-top: auto; /* 圆点压到卡片底部 */
  padding-top: 12px;
  justify-content: center;
}
.section-news .focus-item p { margin-bottom: 4px; }

.section-news .news-list li {
  background: #fff;
  border-bottom: none;
  border-radius: var(--radius);
  padding: 13px 16px;
  margin-bottom: 12px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, .08);
  transition: var(--transition);
}
.section-news .news-list li:last-child { margin-bottom: 0; }
.section-news .news-list li:hover {
  transform: translateY(-3px);
  box-shadow: 0 6px 16px rgba(0, 0, 0, .14);
}
.section-news .news-list li:hover .list-date {
  background: var(--cream);
  border-color: var(--red);
}
.section-news .news-list li:hover .list-date b { color: var(--red); }
.section-news .news-list li:hover .list-date i { color: var(--text-light); }

.list-date {
  flex-shrink: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  width: 58px;
  height: 58px;
  border: 1px solid #eee;
  border-radius: 6px;
  background: var(--cream);
  line-height: 1.15;
  transition: var(--transition);
}
.list-date b { font-size: 22px; color: var(--red); }
.list-date i { font-style: normal; font-size: 11px; color: var(--text-light); }

.news-list li:hover .list-date { background: var(--red); border-color: var(--red); }
.news-list li:hover .list-date b,
.news-list li:hover .list-date i { color: #fff; }

.list-txt { flex: 1; min-width: 0; }
.list-txt a {
  display: block;
  font-size: 15px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.list-txt a:hover { color: var(--red); }
.list-txt time { font-size: 12px; }

/* ================= 通知公告（红底区块，卡片内嵌） ================= */
.section-notice {
  background: url("../img/m2_bg.png") center / cover no-repeat;
  padding-bottom: 60px;
}

.notice-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 22px;
}

/* ---- 通知公告卡片 ---- */
.notice-card {
  background: #fff;
  border-radius: var(--radius);
  padding: 20px 18px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  min-height: 140px;
  box-shadow: 0 4px 14px rgba(0, 0, 0, .12);
  transition: var(--transition);
}
.notice-card:hover { transform: translateY(-6px); box-shadow: 0 12px 26px rgba(0, 0, 0, .25); }
.notice-card time {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  color: var(--text-light);
  font-size: 13px;
}
.notice-card time::before {
  content: "";
  width: 12px;
  height: 12px;
  border: 2px solid var(--red);
  border-radius: 3px;
  flex-shrink: 0;
}
.notice-card h3 {
  font-size: 15px;
  font-weight: normal;
  color: var(--text);
  line-height: 1.65;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* ================= 数字园史馆 ================= */
.section-gallery {
  background: url("../img/m3_bg.jpg") center / cover no-repeat;
}

.gallery-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

.gallery-card {
  background: #fff;
  border-radius: var(--radius);
  overflow: hidden;
  min-width: 0;
  box-shadow: 0 2px 10px rgba(0, 0, 0, .07);
  transition: var(--transition);
}
.gallery-card:hover { transform: translateY(-6px); box-shadow: var(--shadow); }
.gallery-card img { width: 100%; aspect-ratio: 16 / 9; object-fit: cover; }

.gallery-info { padding: 14px 16px 16px; }
.gallery-info time { font-size: 12px; color: var(--red); }
.gallery-info p {
  margin-top: 6px;
  font-size: 14px;
  line-height: 1.6;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* ================= 双栏区块 ================= */
.duo-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 40px;
  align-items: start;
}
.duo-grid > * { min-width: 0; }

/* ---- 队伍建设：2×2 卡片 ---- */
.team-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 20px;
}

.team-card {
  background: #fff;
  border-radius: var(--radius);
  padding: 28px 22px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  min-height: 180px; /* 整体加高约50%，轮播列经 syncDuoHeight 自动跟随 */
  box-shadow: 0 2px 10px rgba(0, 0, 0, .07);
  position: relative;
  overflow: hidden;
  transition: var(--transition);
}
.team-card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 3px;
  background: var(--red);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform .3s;
}
.team-card:hover { transform: translateY(-5px); box-shadow: var(--shadow); }
.team-card:hover::before { transform: scaleX(1); }
.team-card time {
  color: var(--red);
  font-size: 13px;
  font-weight: bold;
}
.team-card h3 {
  font-size: 15px;
  font-weight: normal;
  line-height: 1.6;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* ================= 入园指南 / 家园共育（m4 底图区） ================= */
.section-last {
  background: url("../img/m4_bg.jpg") center / cover no-repeat;
}

/* 入园指南：白色卡片模块 */
.section-last .thumb-list li {
  background: #fff;
  border-radius: var(--radius);
  border-bottom: none;
  padding: 14px 16px;
  margin-bottom: 14px;
  box-shadow: 0 2px 10px rgba(0, 0, 0, .07);
  transition: var(--transition);
}
.section-last .thumb-list li:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow);
}
.section-last .thumb-list li:last-child { margin-bottom: 0; }

/* 家园共育：轮播整体套白色卡片 */
.section-last .focus-item {
  background: #fff;
  border-radius: var(--radius);
  padding: 14px 14px 6px;
  box-shadow: 0 2px 10px rgba(0, 0, 0, .07);
}
.section-last .focus-item p { margin-bottom: 8px; }

/* 精彩时刻 / 家园共育：轮播高度由 JS 锁定（与相邻列对齐），图片自适应填满剩余空间 */
.section-duo .focus-slider { overflow: hidden; }
/* 非当前张隐藏（写在全局规则后，需带 .focus-slider 提高优先级覆盖 .section-duo .focus-item） */
.section-duo .focus-slider .focus-item { display: none; }
/* 当前张：flex 纵向布局，图片填满锁定高度 */
.section-duo .focus-slider .focus-item.active {
  height: 100%;
  display: flex;
  flex-direction: column;
}
.section-duo .focus-item .focus-pic { flex: 1; min-height: 0; }
.section-duo .focus-item .focus-pic img {
  height: 100%;
  aspect-ratio: auto; /* 覆盖固定 16:9，按锁定高度填充 */
  object-fit: cover;
}
.section-duo .focus-item h3 { margin-top: 12px; }

/* 带缩略图列表 */
.thumb-list li {
  display: flex;
  gap: 16px;
  align-items: center;
  padding: 14px 0;
  border-bottom: 1px dashed #e0e0e0;
}
.thumb-list li:last-child { border-bottom: none; }
.thumb-list img {
  flex-shrink: 0;
  width: clamp(84px, 26vw, 128px); /* 随屏幕宽度收缩，防止窄屏撑破 */
  aspect-ratio: 16 / 10;
  object-fit: cover;
  border-radius: 6px;
}
.thumb-list .list-txt a { white-space: normal; }

/* ================= 页脚 ================= */
.site-footer {
  background: var(--red-deep);
  color: rgba(255, 255, 255, .85);
  text-align: center;
  padding: 26px 0;
  font-size: 13px;
  line-height: 2;
}

/* ================= 返回顶部 ================= */
.back-top {
  position: fixed;
  right: 24px;
  bottom: 40px;
  width: 44px;
  height: 44px;
  border: none;
  border-radius: 50%;
  background: var(--red);
  color: #fff;
  font-size: 20px;
  cursor: pointer;
  opacity: 0;
  visibility: hidden;
  transition: var(--transition);
  box-shadow: var(--shadow);
  z-index: 90;
}
.back-top.show { opacity: 1; visibility: visible; }
.back-top:hover { background: var(--red-dark); transform: translateY(-4px); }

/* =========================================================
   响应式
   ========================================================= */
@media (max-width: 992px) {
  .search-box input { width: 130px; }

  .nav-list { justify-content: flex-start; }
  .nav-list a { padding: 12px 13px; font-size: 14px; }

  .news-grid { grid-template-columns: 1fr; gap: 24px; }
  .notice-grid { grid-template-columns: repeat(2, 1fr); }
  .gallery-grid { grid-template-columns: repeat(3, 1fr); gap: 16px; }
  .duo-grid { grid-template-columns: 1fr; gap: 36px; }
}

@media (max-width: 768px) {
  .section { padding: 32px 0 40px; }
  .section-head h2 { font-size: 20px; }
  .section-head h2::before { height: 18px; }
  .section-head h2::after { width: 90px; }

  /* 移动端导航折叠 */
  .nav-toggle { display: flex; }
  .site-nav {
    position: static;
    max-height: 0;
    overflow: hidden;
    transition: max-height .35s ease;
  }
  .site-nav.open { max-height: 1200px; }
  .nav-list { flex-direction: column; padding-top: 6px; padding-bottom: 10px; }
  .nav-list a { padding: 12px 16px; border-bottom: 1px solid rgba(255,255,255,.08); }
  .nav-list a.active::after { display: none; }

  /* 移动端二级菜单：点击展开 */
  .has-sub > a::after {
    position: absolute;
    right: 16px;
    transition: transform .25s;
  }
  .has-sub.sub-open > a::after { transform: rotate(180deg); }

  .sub-list {
    position: static;
    opacity: 1;
    visibility: visible;
    transform: none;
    box-shadow: none;
    border-top: none;
    border-radius: 0;
    max-height: 0;
    overflow: hidden;
    transition: max-height .3s ease;
    background: var(--red-deep);
  }
  .has-sub.sub-open > .sub-list { max-height: 400px; }
  .sub-list a {
    color: rgba(255, 255, 255, .85);
    text-align: left;
    padding: 10px 16px 10px 32px;
    border-bottom: 1px solid rgba(255,255,255,.06);
  }
  .sub-list a:hover { background: rgba(255, 255, 255, .08); color: #fff; }
  .sub-list a::before {
    content: "·";
    margin-right: 8px;
    color: var(--gold);
  }

  .header-inner { flex-wrap: wrap; }
  .header-tools { margin-left: auto; }

  /* 移动端搜索：弹出式（图标与汉堡并排） */
  .header-tools { display: flex; flex-wrap: nowrap; align-items: center; gap: 10px; }
  .search-toggle { display: inline-flex; }
  .search-box {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: #fff;
    border: 1px solid var(--red);
    border-radius: 0;
    box-shadow: 0 12px 20px rgba(0, 0, 0, .1);
    padding: 12px 16px;
    z-index: 98;
  }
  .search-box.open { display: flex; }
  .search-box input { flex: 1; width: auto; color: var(--text); }
  .search-box input::placeholder { color: #999; }
  .search-box .search-btn { color: var(--red); } /* 白底弹窗内图标用主题红 */
  /* 白底弹窗内清空 X 也用主题红 */
  .search-box input[type="search"]::-webkit-search-cancel-button {
    background-image: url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%238d1f10' stroke-width='2.4' stroke-linecap='round'%3E%3Ccircle cx='12' cy='12' r='10' fill='none' stroke='%238d1f10' stroke-opacity='.4'/%3E%3Cline x1='8' y1='8' x2='16' y2='16'/%3E%3Cline x1='16' y1='8' x2='8' y2='16'/%3E%3C/svg%3E");
  }

  .hero-caption { bottom: 44px; }
  .hero-caption p { font-size: 12px; padding: 6px 12px; }
  .hero-arrow { width: 34px; height: 34px; font-size: 20px; opacity: 1; }
  .hero-arrow.prev { left: 8px; }
  .hero-arrow.next { right: 8px; }

  .gallery-grid { grid-template-columns: 1fr; }
}

@media (max-width: 480px) {
  body { font-size: 14px; }

  .brand-logo { height: 34px; }

  .search-toggle { width: 32px; height: 32px; font-size: 13px; }
  .nav-toggle { width: 36px; height: 36px; }

  .notice-grid { grid-template-columns: 1fr; }
  .notice-card { min-height: auto; }

  .team-grid { grid-template-columns: 1fr; gap: 14px; }
  .team-card { min-height: 0; padding: 20px 16px; } /* 手机端单列不需要加高 */

  .focus-item h3 { font-size: 16px; }
  .list-txt a { font-size: 14px; }

  .back-top { right: 14px; bottom: 24px; }
}

/* =========================================================
   子页面通用
   ========================================================= */
.page-head {
  background: linear-gradient(135deg, var(--red) 0%, var(--red-dark) 100%);
  color: #fff;
  padding: 36px 0 32px;
}
.page-head h1 {
  font-size: 26px;
  letter-spacing: 2px;
  display: flex;
  align-items: center;
  gap: 10px;
}
.page-head h1::before {
  content: "";
  width: 6px;
  height: 22px;
  background: var(--gold);
  border-radius: 3px;
  flex-shrink: 0;
}
.breadcrumb { margin-top: 10px; font-size: 13px; color: rgba(255, 255, 255, .75); }
.breadcrumb a { color: rgba(255, 255, 255, .75); }
.breadcrumb a:hover { color: #fff; }

/* 右侧内容区内的面包屑（两栏页面用） */
.crumb-bar {
  font-size: 13px;
  color: var(--text-light);
  padding-bottom: 12px;
  margin-bottom: 18px;
  border-bottom: 1px solid #f0f0f0;
}
.crumb-bar a { color: var(--text-light); }
.crumb-bar a:hover { color: var(--red); }

.page-body { padding: 40px 0 60px; }

.page-card {
  background: #fff;
  border-radius: var(--radius);
  box-shadow: 0 2px 10px rgba(0, 0, 0, .06);
  padding: 30px 34px;
}

/* ---- 二级页面两栏布局：左侧菜单 + 右侧内容 ---- */
.page-layout {
  display: grid;
  grid-template-columns: 250px 1fr;
  gap: 30px;
  align-items: start;
}

.side-menu {
  background: #fff;
  border-radius: var(--radius);
  box-shadow: 0 2px 10px rgba(0, 0, 0, .06);
  overflow: hidden;
}

.side-menu-title {
  background: linear-gradient(135deg, var(--red) 0%, var(--red-dark) 100%);
  color: #fff;
  font-size: 18px;
  letter-spacing: 2px;
  text-align: center;
  padding: 14px 10px;
}

.side-menu-list li { border-bottom: 1px solid #f2f2f2; }
.side-menu-list li:last-child { border-bottom: none; }

.side-menu-list a {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 13px 18px;
  font-size: 15px;
  color: var(--text);
  transition: var(--transition);
}

.side-menu-list a::after {
  content: "›";
  color: #c9c9c9;
  font-size: 16px;
  transition: var(--transition);
}

.side-menu-list a:hover { color: var(--red); background: var(--cream); padding-left: 24px; }
.side-menu-list a:hover::after { color: var(--red); }

.side-menu-list a.active {
  background: var(--red);
  color: #fff;
  padding-left: 24px;
}
.side-menu-list a.active::after { color: var(--gold); }

/* ---- 新闻列表页 ---- */
.news-page-list li {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 16px 8px;
  border-bottom: 1px dashed #e5e5e5;
  border-radius: 4px;
  transition: var(--transition);
}
.news-page-list li:hover { background: var(--cream); }
.news-page-list li::before {
  content: "";
  width: 6px;
  height: 6px;
  background: var(--red);
  border-radius: 50%;
  flex-shrink: 0;
}
.news-page-list .t {
  flex: 1;
  min-width: 0;
  font-size: 15px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.news-page-list .t:hover { color: var(--red); }
.news-page-list time { font-size: 13px; color: var(--text-light); flex-shrink: 0; }

/* ---- 分页 ---- */
.pagination {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 36px;
}
.pagination a,
.pagination span {
  min-width: 36px;
  height: 36px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 12px;
  border: 1px solid #ddd;
  border-radius: 4px;
  font-size: 14px;
  color: var(--text);
  background: #fff;
}
.pagination a:hover { border-color: var(--red); color: var(--red); }
.pagination .current { background: var(--red); border-color: var(--red); color: #fff; }

/* ---- 图文列表页 ---- */
.gallery-list-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 24px;
}
.gallery-list-grid .gallery-card { box-shadow: 0 2px 10px rgba(0,0,0,.07); }
.gallery-list-grid .gallery-info p {
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* ---- 内容页 ---- */
.article-card h1 { font-size: 22px; line-height: 1.5; color: var(--text); text-align: center; }
.article-meta {
  display: flex;
  flex-wrap: wrap;
  justify-content: center; /* 与居中标题对齐 */
  gap: 8px 22px;
  font-size: 13px;
  color: var(--text-light);
  padding: 14px 0;
  border-bottom: 1px solid #eee;
  margin-bottom: 24px;
}
.article-content p {
  margin: 0 0 18px;
  text-indent: 2em;
  font-size: 15px;
  line-height: 2.15;
}
.article-content h2 {
  font-size: 18px;
  color: var(--red);
  margin: 26px 0 12px;
}
.article-content img {
  width: 100%;
  max-width: 640px;
  border-radius: var(--radius);
  margin: 6px auto 20px;
}

/* =========================================================
   正文排版强制覆盖（站群平台会注入默认 class / 内联样式 / 表格）
   用 !important 硬压平台样式，正文区域行距/字号/字体以本规则为准
   ========================================================= */
.article-content p,
.article-content div,
.article-content span,
.article-content td,
.article-content li,
.about-block p,
.about-block span {
  line-height: 2.15 !important;
  font-size: 15px !important;
  font-family: inherit !important;
  color: #333 !important;
}
.article-content p,
.about-block p {
  margin: 0 0 18px !important;
}
/* 平台注入的 table 布局拆掉边框影响 */
.article-content table {
  width: 100% !important;
  border-collapse: collapse;
}
.article-content table td {
  border: none !important;
  padding: 0 !important;
  display: block; /* 单元格转块级，恢复纵向文章流 */
}
/* 正文图片防撑破、防平台固定尺寸 */
.article-content img,
.about-block img {
  max-width: 100% !important;
  height: auto !important;
}
/* 强调/加粗跟随主题色 */
.article-content b,
.article-content strong {
  color: inherit;
}
.article-nav {
  margin-top: 32px;
  padding-top: 20px;
  border-top: 1px solid #eee;
  display: flex;
  flex-direction: column;
  gap: 8px;
  font-size: 14px;
}
.article-nav span { color: var(--text-light); flex-shrink: 0; }
.article-nav a { color: var(--text); }
.article-nav a:hover { color: var(--red); }
.article-nav div { display: flex; gap: 10px; min-width: 0; }
.article-nav a { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

/* ---- 单页（园所概况） ---- */
.about-img {
  width: 100%;
  max-width: 760px;
  border-radius: var(--radius);
  margin: 0 auto 26px;
}
/* 单页正文：一整片连续排版（同内容页 article 风格，无分块装饰） */
.about-block h2 {
  font-size: 18px;
  color: var(--red);
  margin: 22px 0 10px;
  padding-left: 0;
  border-left: none;
}
.about-block:first-of-type h2 { margin-top: 0; }
.about-block p {
  margin: 0 0 18px;
  text-indent: 2em;
  font-size: 15px;
  line-height: 2.15;
}
/* 联系我们：并入正文流，不再单独成盒 */
.contact-box {
  background: none;
  border: none;
  border-radius: 0;
  padding: 0;
  margin-top: 22px;
  padding-top: 14px;
  border-top: 1px solid #eee;
  font-size: 14px;
  line-height: 2.1;
}
.contact-box strong { color: var(--red); font-size: 16px; }

/* 子页面响应式 */
@media (max-width: 992px) {
  .page-layout { grid-template-columns: 210px 1fr; gap: 22px; }
}

@media (max-width: 768px) {
  .page-layout { grid-template-columns: 1fr; gap: 18px; }
  .side-menu-list {
    display: flex;
    flex-wrap: wrap;
    padding: 8px;
    gap: 6px;
  }
  .side-menu-list li { border-bottom: none; }
  .side-menu-list a {
    padding: 8px 14px;
    border: 1px solid #eee;
    border-radius: 18px;
    font-size: 13px;
  }
  .side-menu-list a::after { display: none; }
  .side-menu-list a:hover { padding-left: 14px; }
  .side-menu-list a.active { padding-left: 14px; }
  .page-head { padding: 26px 0 24px; }
  .page-head h1 { font-size: 21px; }
  .page-card { padding: 20px 16px; }
  .gallery-list-grid { grid-template-columns: 1fr; gap: 16px; }
  .article-card h1 { font-size: 18px; }
}
