/* ============================================================
   砀山梨 · 「梨金翠」主题（唯一主题 · 靓丽环保版 v33）
   ------------------------------------------------------------
   设计意象：秋日砀山梨园
     · 鲜梨绿   → 主色，明亮有生机（环保·生态）
     · 嫩芽亮绿 → 点缀，清爽提亮
     · 酥梨金   → 砀山梨的果实色，导航顶边/序号/重点条
     · 梨花纸白 → 背景，温润不刺眼
   本文件覆盖 base.css 的全部配色变量，并补齐组件级细节。
   ============================================================ */

/* ---------- 1. 配色变量 ---------- */
:root {
  /* 主色阶：鲜梨绿 */
  --primary: #35a046;
  --primary-dark: #1d7a33;
  --primary-light: #e6f8e3;

  /* 点缀色阶：嫩芽亮绿 */
  --accent: #8fce3c;
  --accent-soft: #f0fadf;

  /* 辅助绿 */
  --green: #47a84f;
  --green-dark: #1d7a33;

  /* 酥梨金（砀山梨果实色：顶边、序号、重点标记） */
  --pear-gold: #ffb300;
  --pear-gold-soft: #fff5d9;

  /* 底色 */
  --bg: #f9fcf3;
  --card-bg: #ffffff;
  --text: #24331d;
  --text-light: #6e7f63;
  --border: #dcebcf;

  /* 状态色 */
  --danger: #b0392e;
  --warn: #f59e0b;

  /* 圆角与阴影 */
  --radius: 14px;
  --radius-sm: 8px;
  --shadow: 0 2px 8px rgba(29, 122, 51, .07);
  --shadow-lg: 0 16px 40px rgba(29, 122, 51, .15);
  --paper-line: #cfe5bc;

  /* 主题渐变 */
  --grad-primary: linear-gradient(135deg, #54c35b 0%, #21943a 100%);
  --grad-topbar: linear-gradient(90deg, #1d7a33 0%, #35a046 55%, #5cbf4e 100%);
  --grad-gold: linear-gradient(90deg, #ffc93d 0%, #ff9800 100%);
}

/* ---------- 2. 全局细节 ---------- */
html { -webkit-text-size-adjust: 100%; }
body {
  background: var(--bg);
  color: var(--text);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}
::selection { background: #d4f0ae; color: #175c26; }

/* 滚动条 */
::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-track { background: #eff7e4; }
::-webkit-scrollbar-thumb {
  background: #a4d67e;
  border-radius: 6px;
  border: 2px solid #eff7e4;
}
::-webkit-scrollbar-thumb:hover { background: var(--accent); }

/* 链接与焦点 */
a { transition: color .18s; }
a:focus-visible,
button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

/* ---------- 3. 顶栏 ---------- */
.topbar {
  background: var(--grad-topbar);
  color: rgba(255, 255, 255, .88);
  letter-spacing: .5px;
}
.topbar a { color: rgba(255, 255, 255, .9); }
.topbar a:hover { color: #fff8e1; }
.topbar .tb-motto { color: rgba(255, 255, 255, .78); }

/* ---------- 4. 头部 / Logo / 搜索 ---------- */
.header { background: #ffffff; }
.logo-icon {
  background: var(--grad-primary) !important;
  color: #fbfff7 !important;
  box-shadow:
    inset 0 0 0 2px rgba(251, 255, 247, .45),
    0 4px 12px rgba(29, 122, 51, .32) !important;
  border-radius: 9px !important;
}
.logo-text { color: var(--primary-dark); }
.logo-text small { color: var(--text-light); letter-spacing: .5px; }

.header-search input,
.search-bar input {
  border-color: var(--border);
  background: #fbfdf7;
  transition: border-color .2s, box-shadow .2s, background .2s;
}
.header-search input:focus,
.search-bar input:focus {
  border-color: var(--accent);
  background: #ffffff;
  box-shadow: 0 0 0 3px rgba(143, 206, 60, .22);
}
.header-search button,
.search-bar button { background: var(--grad-primary); color: #fff; }
.header-search button:hover,
.search-bar button:hover { background: var(--primary-dark); }

.head-tel {
  color: var(--primary-dark);
  font-weight: 700;
  transition: color .18s;
}
.head-tel:hover { color: var(--pear-gold); }

/* ---------- 5. 主导航（亮绿 + 酥梨金顶边） ---------- */
.mainnav {
  background: linear-gradient(90deg, #21943a 0%, #3aa648 100%);
  border-top: 3px solid var(--pear-gold);
  box-shadow: 0 2px 12px rgba(29, 122, 51, .22);
}
.mainnav a { color: rgba(255, 255, 255, .94); }
.mainnav .nav-item > a:hover,
.mainnav a.active {
  color: #fff8e1;
  border-bottom-color: var(--pear-gold);
}
.mainnav a.active { font-weight: 700; }

/* 下拉菜单 */
.dropdown {
  border-top: 3px solid var(--pear-gold);
  box-shadow: 0 12px 32px rgba(29, 122, 51, .18);
  border-radius: 0 0 var(--radius-sm) var(--radius-sm);
}
.dropdown a { color: var(--text); }
.dropdown a:hover {
  background: var(--accent-soft);
  color: var(--primary-dark);
}
.dd-label { color: var(--primary); }
.dd-tag {
  background: var(--accent-soft);
  color: var(--primary-dark);
  border-radius: 20px;
  padding: 1px 8px;
}

/* 导航右侧 CTA 按钮：酥梨金 */
.nav-cta {
  background: var(--grad-gold) !important;
  color: #5a3a00 !important;
  font-weight: 700 !important;
  border-radius: var(--radius-sm);
  box-shadow: 0 2px 8px rgba(255, 179, 0, .4);
}
.nav-cta:hover { filter: brightness(1.06) !important; }

/* ---------- 6. 按钮 ---------- */
.btn {
  background: var(--grad-primary);
  color: #fbfff7;
  border: 0;
  border-radius: var(--radius-sm);
  font-weight: 700;
  letter-spacing: .5px;
  box-shadow: 0 3px 10px rgba(29, 122, 51, .25);
  transition: transform .18s, box-shadow .2s, filter .2s;
}
.btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(29, 122, 51, .3);
  filter: brightness(1.06);
}
.btn:active { transform: translateY(0); }

.btn-primary {
  background: var(--primary-dark);
  color: #fbfff7;
  border-color: var(--primary-dark);
}
.btn-primary:hover { background: #17652a; }

.btn-ghost,
.btn-outline {
  background: transparent;
  color: var(--primary-dark);
  border: 1.5px solid var(--primary);
  box-shadow: none;
}
.btn-ghost:hover,
.btn-outline:hover {
  background: var(--accent-soft);
  color: var(--primary-dark);
  border-color: var(--primary-dark);
}

/* 幻灯片内按钮：酥梨金底 + 深棕字，最醒目 */
.front-hero .slide-inner .btn,
.hero .slide-inner .btn {
  background: var(--grad-gold);
  color: #4a3000;
  font-weight: 700;
  box-shadow: 0 4px 14px rgba(0, 0, 0, .28);
}
.front-hero .slide-inner .btn:hover,
.hero .slide-inner .btn:hover { filter: brightness(1.07); }

/* ---------- 7. 卡片 ---------- */
.card {
  background: var(--card-bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  transition: transform .25s ease, box-shadow .25s ease, border-color .25s ease;
}
.card:hover {
  transform: translateY(-4px);
  border-color: #c4e69a;
  box-shadow: 0 14px 34px rgba(29, 122, 51, .15);
}
.card h3,
.card h3 a { color: var(--text); }
.card h3 a:hover { color: var(--primary); }

/* 通用列表项 hover */
.list-item {
  transition: border-color .2s, box-shadow .2s, background .2s;
}
.list-item:hover {
  border-color: #c4e69a;
  box-shadow: 0 6px 18px rgba(29, 122, 51, .1);
}

/* ---------- 8. 英雄区 / 页头横幅 ---------- */
.page-banner,
.page-hero {
  background-color: var(--primary-dark);
  background-image: linear-gradient(135deg,
    rgba(23, 101, 42, .9) 0%,
    rgba(53, 160, 70, .68) 100%);
  color: #fbfff7;
}
.page-banner h1,
.page-hero h1 { color: #fbfff7; letter-spacing: 2px; }

/* 轮播指示条 */
.dots span { background: rgba(255, 255, 255, .45); }
.dots span.active { background: var(--pear-gold); }

/* ---------- 9. 侧栏 / 列表序号（酥梨金序号） ---------- */
.fs-head h2 { color: var(--primary-dark); }
.fs-head a { color: var(--primary); }
.fs-head a:hover { color: var(--pear-gold); }
.fs-item { border-bottom-color: var(--border); }
.fs-item .no {
  color: var(--pear-gold);
  font-weight: 800;
}
.fs-item a { color: var(--text); }
.fs-item a:hover { color: var(--primary); }
.fs-date { color: var(--text-light); }

/* ---------- 10. 标签 / 提示 ---------- */
.tag,
.label,
.badge {
  background: var(--accent-soft);
  color: var(--primary-dark);
  border-radius: 20px;
  padding: 2px 10px;
  font-weight: 600;
}
.tag-done,
.tag-pass,
.alert-success,
.alert-ok,
.alert-info {
  background: var(--accent-soft);
  color: var(--primary-dark);
  border-color: #bfe39a;
}
.tag-hot,
.tag-warn {
  background: var(--pear-gold-soft);
  color: #9a6a00;
  border-radius: 20px;
}

/* ---------- 11. 表单 ---------- */
input[type="text"],
input[type="tel"],
input[type="email"],
input[type="password"],
textarea,
select {
  border-color: var(--border);
  border-radius: var(--radius-sm);
  background: #fbfdf7;
  transition: border-color .2s, box-shadow .2s, background .2s;
}
input:focus,
textarea:focus,
select:focus {
  border-color: var(--accent);
  background: #ffffff;
  box-shadow: 0 0 0 3px rgba(143, 206, 60, .22);
  outline: none;
}
.query-form input:focus,
.search-bar input:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(143, 206, 60, .25);
}

/* ---------- 12. 区块标题金条 / 页脚 ---------- */
.section-title .bar {
  background: var(--grad-gold) !important;
}

/* 页脚：主题原用 .footer 类，但模板输出的是 <footer> 元素（类名不存在，规则一直未生效），
   这里改为元素选择器；深绿底色沿用站点既有基色，只统一链接与标题的强调色。 */
footer { color: rgba(255, 255, 255, .82); }
footer a { color: rgba(255, 255, 255, .8); }
footer a:hover { color: #ffe08a; }
footer h4,
footer strong { color: #ffffff; }

/* 联系横幅：亮绿渐变 */
.contact-banner {
  background: var(--grad-primary) !important;
  color: #fbfff7;
}

/* ---------- 13. 清除 base.css 里硬编码的旧色 ---------- */
.intro-block p,
.ds-lead p,
.cele-card p,
.heri-card p {
  color: #3c4a34;
}

/* 页头/幻灯片暖白文字（与深色遮罩对比良好） */
.front-hero .slide-inner,
.hero .slide-inner { color: #fbfff7; }

/* ---------- 14. 梨园四时图卡 ---------- */
.season-card { overflow: hidden; }
.season-card .thumb img {
  transition: transform .5s ease;
}
.season-card:hover .thumb img { transform: scale(1.05); }
.season-card .season-tag {
  position: absolute;
  left: 12px;
  top: 12px;
  background: rgba(255, 255, 255, .92);
  color: var(--primary-dark);
  font-size: 12.5px;
  font-weight: 700;
  padding: 3px 12px;
  border-radius: 20px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, .18);
}
.season-card .thumb { position: relative; }

/* ---------- 15. 微信浮动入口 ---------- */
.wx-float {
  position: fixed;
  right: 18px;
  bottom: 92px;
  z-index: 900;
}
.wx-btn {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
  border: none;
  cursor: pointer;
  background: linear-gradient(135deg, var(--accent), var(--primary));
  color: #fff;
  padding: 10px 12px;
  border-radius: 14px;
  box-shadow: 0 6px 18px rgba(47, 107, 58, .35);
  font-family: inherit;
}
.wx-btn:hover { transform: translateY(-2px); box-shadow: 0 10px 24px rgba(47, 107, 58, .45); }
.wx-ico { font-size: 22px; line-height: 1; }
.wx-txt {
  font-size: 11.5px;
  font-weight: 700;
  letter-spacing: .5px;
  writing-mode: horizontal-tb;
}
.wx-pop {
  position: absolute;
  right: 0;
  bottom: calc(100% + 10px);
  display: none;
  width: 210px;
  background: #fff;
  border-radius: var(--radius);
  box-shadow: 0 12px 36px rgba(0, 0, 0, .22);
  padding: 14px;
  text-align: center;
}
.wx-pop.open { display: block; }
.wx-pop img { width: 180px; height: 180px; border-radius: 8px; display: block; margin: 0 auto; }
.wx-pop p { margin: 10px 0 0; font-size: 13.5px; font-weight: 700; color: var(--primary-dark); line-height: 1.6; }
.wx-pop p small { font-weight: 400; color: #7a8a7a; }

@media (max-width: 768px) {
  .wx-float { right: 12px; bottom: 78px; }
  .wx-txt { display: none; }
  .wx-btn { padding: 11px; border-radius: 50%; }
  .wx-pop { right: -20px; }
}

/* ---------- 16. 电话优先下单表单 ---------- */
.field label em { color: #e53935; font-style: normal; }
.wx-hint {
  margin-top: 10px;
  font-size: 13px;
  color: #5a7a5a;
  background: rgba(124, 179, 66, .1);
  border-radius: 8px;
  padding: 8px 12px;
}
.wx-row {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-top: 16px;
  padding: 14px;
  background: rgba(124, 179, 66, .08);
  border: 1px dashed rgba(47, 107, 58, .3);
  border-radius: var(--radius);
}
.wx-row .wx-qr { width: 92px; height: 92px; border-radius: 8px; flex-shrink: 0; }
.wx-row div { font-size: 13.5px; line-height: 1.7; color: #4a5a4a; }
.wx-row div strong { color: var(--primary-dark); font-size: 14.5px; }

/* 手机底部条加微信按钮 */
.mobar .mb-wx { position: relative; }

/* ============================================================
   17. 界面优化层（v35）
   ------------------------------------------------------------
   目标：不改动站点栏目、文案与事实，只解决窄屏可读性、
   配色一致性与触控/无障碍三类问题。
     17.1 顶栏窄屏单行化        17.2 首屏轮播窄屏字号
     17.3 底部操作条配色与触控   17.4 浮动入口间距
     17.5 侧栏要闻列表窄屏      17.6 移动端抽屉搜索入口
     17.7 旧橙残留收口          17.8 动效与无障碍
   ============================================================ */

/* ---------- 17.1 顶栏：窄屏单行显示，杜绝中文断裂 ---------- */
@media (max-width: 768px) {
  .topbar { letter-spacing: 0; }
  .topbar .container { flex-wrap: nowrap; gap: 10px; min-height: 32px; }
  .topbar .tb-motto {
    flex: 1 1 auto;
    min-width: 0;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    font-size: 11.5px;
    letter-spacing: .5px;
  }
  .topbar .container > div { display: flex; flex: none; align-items: center; }
  .topbar a {
    flex: none;
    white-space: nowrap;
    margin-left: 0;
    margin-right: 12px;
    font-size: 12px;
  }
  .topbar a:last-child { margin-right: 0; }
}
@media (max-width: 430px) {
  .topbar .container { justify-content: center; }
  .topbar .tb-motto { display: none; }
  .topbar .container > div { width: 100%; justify-content: center; }
  .topbar a { margin: 0 6px; font-size: 11.5px; }
}

/* ---------- 17.2 首屏轮播：窄屏收敛字号，标题不再孤字折行 ---------- */
@media (max-width: 768px) {
  .front-hero { min-height: 300px; }
  .front-hero .slide-inner { padding: 22px 20px; }
  .front-hero .slide-inner h1,
  .front-hero .slide-inner h2,
  .hero .slide-inner h1,
  .hero .slide-inner h2 {
    font-size: 23px;
    letter-spacing: 1.2px;
    line-height: 1.34;
    text-wrap: balance;
  }
  .front-hero .slide-inner p,
  .hero .slide-inner p {
    font-size: 13.5px;
    line-height: 1.7;
    margin: 8px 0 14px;
    max-width: none;
  }
  .front-hero .slide-inner .btn,
  .hero .slide-inner .btn { padding: 8px 18px; font-size: 13.5px; }
  .front-hero .dots { bottom: 12px; right: 14px; }
  .front-hero .dots span { width: 18px; height: 4px; }
  .front-hero .dots span.active { width: 28px; }
}
@media (max-width: 480px) {
  .front-hero { min-height: 252px; }
  .front-hero .slide-inner h1,
  .front-hero .slide-inner h2,
  .hero .slide-inner h1,
  .hero .slide-inner h2 { font-size: 20px; letter-spacing: .6px; }
  .front-hero .slide-inner p,
  .hero .slide-inner p { font-size: 12.5px; }
}

/* ---------- 17.3 移动端底部操作条：统一强调色、触控区 ≥56px ---------- */
.mobar a.mb-tel { background: var(--accent); color: #40230a; font-weight: 700; }
.mobar .mb-ai {
  background: var(--grad-gold) !important;
  color: #5a3a00 !important;
}
@media (max-width: 768px) {
  body { padding-bottom: calc(56px + env(safe-area-inset-bottom, 0px)); }
  .mobar {
    border-top: 2px solid var(--pear-gold) !important;
    padding-bottom: env(safe-area-inset-bottom, 0px);
  }
  .mobar a {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 56px;
    padding: 0 4px;
    font-size: 13.5px;
    letter-spacing: .5px;
    white-space: nowrap;
  }
}

/* ---------- 17.4 右下浮动入口：与底部条留出间距，避免遮挡正文 ---------- */
@media (max-width: 768px) {
  .wx-float { right: 12px; bottom: calc(72px + env(safe-area-inset-bottom, 0px)); }
  .wx-btn {
    width: 50px;
    height: 50px;
    padding: 0;
    justify-content: center;
    border-radius: 50%;
  }
  .wx-ico { font-size: 21px; }
  .wx-pop { right: -4px; width: 198px; }
}

/* ---------- 17.5 侧栏「要闻」列表：窄屏日期与标题不再互相挤压 ---------- */
@media (max-width: 480px) {
  .fs-item { gap: 8px; padding: 10px 0; }
  .fs-item .no { width: 18px; font-size: 15px; }
  .fs-item a { font-size: 13.5px; line-height: 1.55; }
  .fs-item .fs-date { font-size: 10.5px; }
}

/* ---------- 17.6 移动端抽屉：补齐站内搜索入口 ---------- */
.mm-search { display: flex; gap: 8px; margin: 14px 0 2px; }
.mm-search input {
  flex: 1 1 auto;
  min-width: 0;
  height: 40px;
  padding: 0 12px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: #fbfdf7;
  font-size: 14px;
  color: var(--text);
}
.mm-search input:focus {
  border-color: var(--accent);
  background: #ffffff;
  box-shadow: 0 0 0 3px rgba(143, 206, 60, .22);
}
.mm-search button {
  flex: none;
  height: 40px;
  padding: 0 16px;
  border: 0;
  cursor: pointer;
  border-radius: var(--radius-sm);
  background: var(--grad-primary);
  color: #ffffff;
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 1px;
}
.mm-close {
  display: flex;
  align-items: center;
  justify-content: center;
  min-width: 44px;
  min-height: 44px;
  margin: -8px -8px -8px 0;
  border-radius: 8px;
  transition: background .18s, color .18s;
}
.mm-close:hover { background: var(--accent-soft); color: var(--primary-dark); }

/* ---------- 17.7 旧橙残留收口：AI 浮动入口 / 页脚 AI 按钮 / 提示线 ---------- */
.ai-btn {
  background: var(--grad-gold) !important;
  color: #4a3000 !important;
  border-color: rgba(255, 255, 255, .9) !important;
  box-shadow: 0 6px 18px rgba(154, 106, 0, .32) !important;
}
.ai-btn:hover { color: #4a3000 !important; filter: brightness(1.05); }
.ft-ai-btn {
  background: linear-gradient(135deg, rgba(255, 179, 0, .26), rgba(255, 179, 0, .08));
  border-color: rgba(255, 179, 0, .6);
  color: #ffe9a8 !important;
}
.ft-ai-btn:hover { background: rgba(255, 179, 0, .38); color: #ffffff !important; }
.ft-note { border-left-color: var(--pear-gold); }

/* ---------- 17.8 无障碍与动效 ---------- */
a, button, .v-chip, .mm-group a { -webkit-tap-highlight-color: rgba(53, 160, 70, .18); }
.mobar a:focus-visible,
.mm-search button:focus-visible { outline: 2px solid var(--pear-gold); outline-offset: 2px; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: .001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .001ms !important;
  }
}
