/* ==========================================================================
   中南林业科技大学野生动植物保护协会站（挂于木的地 PLDE / PLCO 下）
   视觉体系对齐 PLDE 主站（/plca）：
     ① PLDE 主题框   linear-gradient(45deg,#4CAF50,#81C784) + 白字
     ② 协会主题框    白底细条 + 会徽 + 协会各页导航
     底色   #f5f7fa  ｜  正文 slate-700  ｜  标题 #2E7D32
     卡片   #fff + 12px 圆角 + ring(#e2e8f0) + shadow-sm
     页脚   #37474F 深灰蓝  ｜  字体 'Microsoft YaHei','PingFang SC'
   ========================================================================== */

*,
*::before,
*::after { box-sizing: border-box; }

:root {
  /* PLDE 主站取色 */
  --plde-green: #4CAF50;
  --plde-green-light: #81C784;
  --plde-title: #2E7D32;
  --plde-footer: #37474F;
  --plde-bg: #f5f7fa;
  --plde-line: #e2e8f0;
  --plde-text: #334155;
  --plde-text-strong: #1e293b;
  --plde-dim: #64748b;
  --plde-hover: #E8F5E8;

  /* 协会语义色（仅在 PLDE 绿系内做深浅区分） */
  --assoc-deep: #1B5E20;
  --assoc-soft: #EDF7ED;

  --radius: 12px;
  --shadow-sm: 0 1px 3px 0 rgb(0 0 0 / .1), 0 1px 2px -1px rgb(0 0 0 / .1);
  --shadow-md: 0 4px 6px -1px rgb(0 0 0 / .1), 0 2px 4px -2px rgb(0 0 0 / .1);
  --wrap: 1120px;
}

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--plde-bg);
  color: var(--plde-text-strong);
  font-family: 'Microsoft YaHei', 'PingFang SC', 'Hiragino Sans GB', sans-serif;
  font-size: 15px;
  line-height: 1.75;
  -webkit-font-smoothing: antialiased;
}

a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }

.wrap {
  width: 100%;
  max-width: var(--wrap);
  margin: 0 auto;
  padding: 0 20px;
}

/* --------------------- ① 木的地计划 PLDE 主题框（置顶） ---------------------
   与 /plca 的 SiteHeader 逐项对齐：
     header            px-6 py-4 gap-3 flex-wrap  →  padding 16px 24px / gap 12px，通栏不套 .wrap
     品牌名            text-2xl font-semibold tracking-wide
     品牌副标题        mt-0.5 text-xs text-white/85
     导航项            text-sm font-medium px-2.5 py-1.5 rounded-md
     悬浮 / 选中       hover:bg-white/10 ｜ active:bg-white/25
     账号区            ml-1 pl-3 border-l border-white/30
   ------------------------------------------------------------------------- */

.site-header {
  background: linear-gradient(45deg, var(--plde-green), var(--plde-green-light));
  color: #fff;
  box-shadow: var(--shadow-md);
  position: relative;
  z-index: 20;
}

.header-inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 16px 24px;
}

.brand { display: flex; flex-direction: column; }

.brand-name {
  font-size: 24px;
  line-height: 32px;
  font-weight: 600;
  letter-spacing: .025em;
}
.brand-sub {
  margin: 2px 0 0;
  font-size: 12px;
  line-height: 16px;
  color: rgba(255, 255, 255, .85);
}

/* PLDE 板块导航（首页 + 四个子计划 + 账号区） */
.nav-plan {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
}
.nav-plan ul {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin: 0;
  padding: 0;
  list-style: none;
  font-size: 14px;
  line-height: 20px;
  font-weight: 500;
}
.nav-plan li { display: block; }
.nav-plan a {
  display: inline-block;
  padding: 6px 10px;
  border-radius: 6px;
  white-space: nowrap;
  color: rgba(255, 255, 255, .85);
  transition: background .18s, color .18s;
}
.nav-plan a:hover { background: rgba(255, 255, 255, .1); color: #fff; }
.nav-plan a.is-active { background: rgba(255, 255, 255, .25); color: #fff; }

/* 账号区（由 assets/main.js 按会话填充；未登录 → 登录 / 注册） */
.nav-account {
  margin-left: 4px;
  padding-left: 12px;
  border-left: 1px solid rgba(255, 255, 255, .3);
  font-size: 14px;
  line-height: 20px;
}
.nav-account-dim { color: rgba(255, 255, 255, .6); }
.nav-account-anon { display: inline-flex; align-items: center; gap: 8px; }
.nav-account-anon a { transition: color .18s; }
.nav-account-anon a:hover { color: rgba(255, 255, 255, .7); }
.nav-account-anon .nav-register {
  border-radius: 4px;
  background: rgba(255, 255, 255, .2);
  padding: 4px 10px;
  font-size: 12px;
  line-height: 16px;
}
.nav-account-anon .nav-register:hover { background: rgba(255, 255, 255, .3); color: #fff; }
.nav-account-user {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 8px;
  border-radius: 6px;
  transition: background .18s;
}
.nav-account-user:hover { background: rgba(255, 255, 255, .15); }
.nav-account-avatar {
  display: grid;
  place-items: center;
  width: 24px;
  height: 24px;
  border-radius: 999px;
  background: rgba(255, 255, 255, .25);
  font-size: 12px;
  font-weight: 700;
}
.nav-account-role {
  border-radius: 4px;
  background: rgba(255, 255, 255, .2);
  padding: 2px 6px;
  font-size: 10px;
  line-height: 14px;
}

/* --------------------- ② 中南林野保协会主题框 --------------------- */

.assoc-bar {
  position: sticky;
  top: 0;
  z-index: 30;
  background: #fff;
  border-bottom: 1px solid var(--plde-line);
  box-shadow: 0 1px 2px rgba(15, 23, 42, .05);
}

.assoc-inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 8px 16px;
  padding-top: 9px;
  padding-bottom: 9px;
}

.assoc-brand { display: flex; align-items: center; gap: 10px; min-width: 0; }
.assoc-brand img {
  width: 34px;
  height: 34px;
  flex: 0 0 34px;
  border-radius: 50%;
  object-fit: cover;
  background: #fff;
  box-shadow: 0 0 0 1px var(--plde-line);
}
.assoc-txt b {
  display: block;
  font-size: 14.5px;
  font-weight: 600;
  color: var(--plde-text-strong);
  line-height: 1.3;
  white-space: nowrap;
}
.assoc-txt em {
  display: block;
  font-style: normal;
  font-size: 10.5px;
  letter-spacing: .06em;
  color: var(--plde-dim);
}

.nav-assoc {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 2px;
  font-size: 14px;
  font-weight: 500;
}
.nav-assoc > a {
  padding: 6px 12px;
  border-radius: 7px;
  color: var(--plde-text);
  white-space: nowrap;
  transition: background .18s, color .18s;
}
.nav-assoc > a:hover { background: var(--assoc-soft); color: var(--plde-title); }
.nav-assoc > a.is-active {
  background: var(--assoc-soft);
  color: var(--plde-title);
  font-weight: 600;
  box-shadow: inset 0 -2px 0 var(--plde-green);
}
.nav-assoc > a.nav-cta {
  margin-left: 8px;
  background: var(--plde-green);
  color: #fff;
}
.nav-assoc > a.nav-cta:hover { background: #43A047; color: #fff; }
.nav-assoc > a.nav-cta.is-active { box-shadow: inset 0 -2px 0 rgba(255, 255, 255, .9); }

.nav-toggle {
  display: none;
  width: 38px;
  height: 34px;
  border: 1px solid var(--plde-line);
  border-radius: 8px;
  background: #fff;
  cursor: pointer;
  position: relative;
}
.nav-toggle::before,
.nav-toggle::after,
.nav-toggle span {
  content: '';
  position: absolute;
  left: 9px;
  right: 9px;
  height: 2px;
  background: var(--plde-text-strong);
  border-radius: 2px;
}
.nav-toggle::before { top: 10px; }
.nav-toggle span { top: 16px; }
.nav-toggle::after { top: 22px; }

/* ------------------------------ 通用排版 ------------------------------ */

main { display: block; padding-bottom: 24px; }

.page-head {
  padding: 34px 0 8px;
}
.page-head h1 {
  margin: 0 0 6px;
  font-size: 25px;
  font-weight: 600;
  color: var(--plde-title);
  letter-spacing: .01em;
}
.page-head p {
  margin: 0;
  font-size: 13.5px;
  color: var(--plde-dim);
}

.section { margin: 26px 0; }

.card {
  background: #fff;
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--plde-line);
  padding: 24px;
}

.card + .card { margin-top: 16px; }

.card h2 {
  margin: 0 0 10px;
  font-size: 16.5px;
  font-weight: 600;
  color: var(--plde-text-strong);
  display: flex;
  align-items: center;
  gap: 8px;
}
.card h2 .bar {
  width: 4px;
  height: 15px;
  border-radius: 2px;
  background: var(--plde-green);
  flex: 0 0 4px;
}
.card h3 {
  margin: 16px 0 6px;
  font-size: 15px;
  font-weight: 600;
  color: var(--plde-title);
}
.card p { margin: 0 0 10px; font-size: 14px; line-height: 1.8; color: var(--plde-text); }
.card p:last-child { margin-bottom: 0; }
.card ul { margin: 8px 0 10px; padding-left: 20px; font-size: 14px; color: var(--plde-text); }
.card li { margin: 5px 0; line-height: 1.75; }
.card b, .card strong { color: var(--plde-text-strong); }

.dim { color: var(--plde-dim); font-size: 13px; }
.mono { font-family: Consolas, Monaco, monospace; font-size: 13px; }

.grid { display: grid; gap: 14px; }
.grid-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.grid-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.grid-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }

.tag {
  display: inline-block;
  padding: 2px 9px;
  border-radius: 999px;
  background: var(--assoc-soft);
  color: var(--plde-title);
  font-size: 12px;
  font-weight: 500;
}

.link { color: var(--plde-title); }
.link:hover { text-decoration: underline; }

.btn {
  display: inline-block;
  padding: 9px 18px;
  border-radius: 9px;
  font-size: 14px;
  font-weight: 500;
  transition: all .18s;
}
.btn-primary {
  background: var(--plde-green);
  color: #fff;
  box-shadow: var(--shadow-sm);
}
.btn-primary:hover { background: #43A047; }
.btn-ghost {
  background: #fff;
  color: var(--plde-title);
  border: 1px solid var(--plde-line);
}
.btn-ghost:hover { border-color: var(--plde-green-light); background: var(--assoc-soft); }

/* ------------------------------ 首页 Hero ------------------------------ */

.hero {
  background: #fff;
  border-bottom: 1px solid var(--plde-line);
  padding: 44px 0 34px;
}
.hero-grid {
  display: grid;
  grid-template-columns: 1.45fr 1fr;
  gap: 34px;
  align-items: center;
}
.hero .eyebrow {
  display: inline-block;
  font-size: 12px;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--plde-green);
  font-weight: 600;
  margin-bottom: 10px;
}
.hero h1 {
  margin: 0 0 10px;
  font-size: 32px;
  line-height: 1.35;
  font-weight: 600;
  color: var(--plde-title);
}
.hero .slogan {
  margin: 0 0 14px;
  font-size: 16px;
  color: var(--plde-green);
  font-weight: 500;
  letter-spacing: .04em;
}
.hero .lede {
  margin: 0 0 20px;
  font-size: 14.5px;
  line-height: 1.85;
  color: var(--plde-text);
}
.hero-actions { display: flex; flex-wrap: wrap; gap: 10px; }

.hero-emblem {
  display: grid;
  place-items: center;
}
.hero-emblem img {
  width: 100%;
  max-width: 290px;
  height: auto;
  border-radius: 50%;
  box-shadow: var(--shadow-md);
  background: #fff;
}

.stats {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
  margin-top: 30px;
}
.stat {
  background: var(--plde-bg);
  border: 1px solid var(--plde-line);
  border-radius: var(--radius);
  padding: 15px 16px;
  text-align: center;
}
.stat b {
  display: block;
  font-size: 24px;
  font-weight: 600;
  color: var(--plde-title);
  line-height: 1.2;
}
.stat span { font-size: 12.5px; color: var(--plde-dim); }

/* ------------------------------ 图文 ------------------------------ */

.figure {
  margin: 0;
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid var(--plde-line);
  background: #fff;
  box-shadow: var(--shadow-sm);
}
.figure img { width: 100%; height: auto; display: block; }
.figure figcaption {
  padding: 9px 13px;
  font-size: 12.5px;
  color: var(--plde-dim);
  border-top: 1px solid var(--plde-line);
  background: #fbfcfd;
}

/* 图集：统一 4:3 显示，整齐排布 */
.gallery { display: grid; gap: 12px; align-items: start; }
.gallery-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.gallery-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.gallery-2 .figure img,
.gallery-3 .figure img { aspect-ratio: 4 / 3; object-fit: cover; }
/* 竖版图（海报、长图）单独处理，保持完整不裁切 */
.figure.tall img,
.gallery .figure img.tall { aspect-ratio: auto; max-height: 430px; object-fit: contain; background: #f8fafc; }

/* 图文并排 */
.media-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 18px;
  align-items: center;
}
.media-row.rev .media-body { order: 2; }

/* ------------------------------ 时间线 ------------------------------ */

.timeline { position: relative; padding-left: 26px; }
.timeline::before {
  content: '';
  position: absolute;
  left: 6px;
  top: 6px;
  bottom: 6px;
  width: 2px;
  background: linear-gradient(var(--plde-green-light), var(--assoc-soft));
  border-radius: 2px;
}
.tl-item { position: relative; margin-bottom: 16px; }
.tl-item::before {
  content: '';
  position: absolute;
  left: -24px;
  top: 6px;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: #fff;
  border: 2.5px solid var(--plde-green);
}
.tl-month { font-size: 12.5px; font-weight: 600; color: var(--plde-green); letter-spacing: .04em; }
.tl-title { font-size: 14.5px; font-weight: 600; color: var(--plde-text-strong); margin: 1px 0 3px; }
.tl-desc { font-size: 13.5px; color: var(--plde-text); line-height: 1.75; }

/* ------------------------------ 列表条目 ------------------------------ */

.item {
  display: flex;
  gap: 13px;
  padding: 14px 0;
  border-bottom: 1px dashed var(--plde-line);
}
.item:last-child { border-bottom: 0; padding-bottom: 0; }
.item:first-child { padding-top: 4px; }
.item-idx {
  flex: 0 0 30px;
  height: 30px;
  border-radius: 8px;
  background: var(--assoc-soft);
  color: var(--plde-title);
  display: grid;
  place-items: center;
  font-size: 13px;
  font-weight: 600;
}
.item-body h4 { margin: 0 0 3px; font-size: 14.5px; font-weight: 600; color: var(--plde-text-strong); }
.item-body p { margin: 0; font-size: 13.5px; line-height: 1.75; color: var(--plde-text); }

/* ------------------------------ 组织架构图 ------------------------------ */

.org { text-align: center; }
.org-top {
  display: inline-block;
  padding: 8px 18px;
  border-radius: 9px;
  background: var(--assoc-deep);
  color: #fff;
  font-size: 13.5px;
  font-weight: 600;
  margin-bottom: 4px;
}
.org-conn {
  width: 2px;
  height: 16px;
  background: var(--plde-line);
  margin: 0 auto;
}
.org-row { display: flex; justify-content: center; gap: 10px; flex-wrap: wrap; margin-bottom: 4px; }
.org-node {
  padding: 7px 15px;
  border-radius: 9px;
  background: #fff;
  border: 1px solid var(--plde-line);
  font-size: 13.5px;
  color: var(--plde-text-strong);
  box-shadow: var(--shadow-sm);
}
.org-node.acc { border-color: var(--plde-green-light); background: var(--assoc-soft); color: var(--plde-title); font-weight: 600; }
.org-label {
  font-size: 12px;
  color: var(--plde-dim);
  margin: 12px 0 7px;
  letter-spacing: .06em;
}

/* ------------------------------ 联系矩阵 ------------------------------ */

.contact-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 12px;
}
.contact {
  background: var(--plde-bg);
  border: 1px solid var(--plde-line);
  border-radius: 10px;
  padding: 13px 15px;
}
.contact .k { font-size: 12px; color: var(--plde-dim); margin-bottom: 2px; }
.contact .v { font-size: 14px; font-weight: 600; color: var(--plde-text-strong); word-break: break-all; }

/* ------------------------------ 页脚 ------------------------------ */

.site-footer {
  background: var(--plde-footer);
  color: rgba(255, 255, 255, .8);
  padding: 26px 0;
  margin-top: 34px;
  font-size: 13px;
  text-align: center;
  line-height: 1.9;
}
.site-footer a { color: rgba(255, 255, 255, .92); }
.site-footer a:hover { text-decoration: underline; }
.site-footer .foot-dim { color: rgba(255, 255, 255, .5); font-size: 12px; }
.site-footer .foot-links { margin-bottom: 8px; display: flex; justify-content: center; flex-wrap: wrap; gap: 6px 14px; }

/* ------------------------------ 响应式 ------------------------------ */

@media (max-width: 900px) {
  .hero-grid { grid-template-columns: 1fr; }
  .hero-emblem { display: none; }
  .grid-4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .grid-3 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .gallery-3 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .media-row { grid-template-columns: 1fr; }
  .media-row.rev .media-body { order: 0; }
  .nav-plan { width: 100%; }
  .nav-plan ul { gap: 4px; font-size: 13px; }
}

@media (max-width: 680px) {
  .nav-toggle { display: block; }
  .nav-assoc {
    display: none;
    width: 100%;
    flex-direction: column;
    align-items: stretch;
    gap: 2px;
    padding: 6px 0 2px;
  }
  .nav-assoc.open { display: flex; }
  .nav-assoc > a { padding: 9px 12px; }
  .nav-assoc > a.nav-cta { margin-left: 0; text-align: center; }
  .assoc-txt b { white-space: normal; font-size: 13.5px; }
  .assoc-brand img { width: 30px; height: 30px; flex: 0 0 30px; }
  .hero h1 { font-size: 24px; }
  .stats { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .grid-2, .grid-3, .grid-4, .gallery-2, .gallery-3 { grid-template-columns: 1fr; }
  .wrap { padding: 0 16px; }
}
