/* ===== 公众号落地页样式 · 与 m 站共用设计变量 ===== */
:root {
  /* 品牌色（渐变蓝，与 site.css 一致） */
  --brand: #0B6BA8;
  --brand-grad: linear-gradient(135deg, #1C8AD2 0%, #06599E 100%);

  /* 文本 / 面 */
  --ink: #143243;
  --muted: #476478;
  --line: #D3E2EC;
  --surface: #FFFFFF;
  --chat-bg: #F1F5F8;

  /* 统一字号：全站仅 4 档 */
  --fs-sm: 0.85rem;
  --fs-base: 1rem;
  --fs-lg: 1.1rem;
  --fs-xl: 1.35rem;

  --radius-btn: 12px;
  --bar-h: 3.1rem; /* 与顶部/底部主导航同高 */
}

/* ===== 重置（与 site.css 对齐） ===== */
* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
html { font-size: 16px; -webkit-text-size-adjust: 100%; }
body {
  background: var(--chat-bg);
  color: var(--ink);
  font-family: -apple-system, BlinkMacSystemFont, "PingFang SC", "Microsoft YaHei", "Helvetica Neue", Arial, sans-serif;
  font-size: var(--fs-base);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  max-width: 640px;
  margin: 0 auto;
  padding: var(--bar-h) 0 4rem; /* 顶部/底部固定栏留白 */
}
a { text-decoration: none; color: inherit; outline: none; }
img { border: 0; max-width: 100%; height: auto; display: block; }
p { margin: 0; }
button { border: none; font-family: inherit; cursor: pointer; }
.sr-only {
  position: absolute; width: 1px; height: 1px;
  padding: 0; margin: -1px; overflow: hidden;
  clip: rect(0, 0, 0, 0); border: 0;
}

/* 隐藏商务通自带浮层 */
#LRdiv1, #LXB_CONTAINER_SHOW, #LXB_CONTAINER { display: none !important; }

/* ===== 顶部栏（与主导航同款渐变蓝） ===== */
.ly-header {
  position: fixed; top: 0; left: 50%; transform: translateX(-50%);
  z-index: 100; width: 100%; max-width: 640px;
  box-shadow: 0 2px 10px rgba(11, 107, 168, 0.25);
}
.ly-header nav {
  position: relative; height: var(--bar-h);
  display: flex; align-items: center;
  background: var(--brand-grad);
}
.ly-header nav h2 {
  flex: 1; color: #fff; font-size: var(--fs-base); font-weight: 600;
  letter-spacing: 0.02em; text-align: center; padding: 0 7.4rem 0 3.1rem;
}
/* 左侧返回主页图标 */
.ly-header .ico-back {
  position: absolute; left: 0; top: 0; width: var(--bar-h); height: var(--bar-h);
  display: flex; align-items: center; justify-content: center; color: #fff;
}
.ly-header .ico-back svg { width: 1.3rem; height: 1.3rem; }
/* 右侧“一键通话”按钮（绿底白字，背景与标题栏一致，CSS 脉冲动效） */
.ly-header .ico-tel {
  position: absolute; right: 0.7rem; top: 50%; transform: translateY(-50%);
  display: flex; align-items: center; gap: 4px;
  height: 2rem; padding: 0 0.7rem;
  background: #45c01a; color: #fff;
  font-size: var(--fs-sm); font-weight: 600; white-space: nowrap;
  border-radius: 6px;
  animation: ly-tel-pulse 1.6s ease-in-out infinite;
}
.ly-header .ico-tel svg { width: 1rem; height: 1rem; }
@keyframes ly-tel-pulse {
  0%, 100% { transform: translateY(-50%) scale(1);    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.18); }
  50%      { transform: translateY(-50%) scale(1.05); box-shadow: 0 2px 12px rgba(69, 192, 26, 0.55); }
}

/* ===== 会话区 ===== */
.ly-section1 { width: 100%; }
.ly-section1 .info-card {
  display: flex; gap: 12px; align-items: flex-start;
  width: 100%; margin: 16px 0 0;
  background: var(--surface); border: 1px solid var(--line);
  border-radius: var(--radius-btn); padding: 14px;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.05);
}
.ly-section1 .info-card .cover { width: 35%; flex-shrink: 0; overflow: hidden; border-radius: 8px; }
.ly-section1 .info-card .cover img { width: 100%; }
.wxdoctxt { flex: 1; min-width: 0; }
.wxdoctxt p { margin-top: 6px; font-size: var(--fs-sm); color: var(--muted); line-height: 1.7; }
.wxdoctxt p:first-child { margin-top: 0; }
.wxdoctxt b { color: var(--ink); font-weight: 600; }
.wxdoctxt .tag { color: var(--brand); }

.ly-section1 .env { width: 100%; margin: 16px 0 0; }
.ly-section1 .env .env-title { font-weight: 600; color: var(--ink); margin-bottom: 8px; }
.ly-section1 .env img { width: 100%; border-radius: 8px; }

/* ===== 对话气泡 ===== */
.ly-section1 .line { margin: 14px 0 0; }
.ly-section1 .left { display: flex; align-items: flex-start; gap: 8px; max-width: 82%; }
.ly-section1 .left .avatar { width: 40px; height: 40px; flex-shrink: 0; border-radius: 6px; }
.ly-section1 .left .bubble {
  position: relative; padding: 10px 12px;
  background: var(--surface); color: var(--ink);
  border: 1px solid var(--line); border-radius: 8px;
  font-size: var(--fs-base); line-height: 1.6;
}
.ly-section1 .left .bubble img { display: inline-block; vertical-align: middle; margin-left: 4px; }
.ly-clear { clear: both; }
.ly-hide { display: none; }

/* ===== 底部输入栏 ===== */
.ly-footer {
  position: fixed; bottom: 0; left: 50%; transform: translateX(-50%);
  z-index: 100; width: 100%; max-width: 640px;
  display: flex; align-items: center; gap: 8px;
  height: 4rem; padding: 0 10px;
  background: var(--surface); border-top: 1px solid var(--line);
}
.ly-footer .call {
  width: 2.4rem; height: 2.4rem; flex-shrink: 0;
  display: flex; align-items: center; justify-content: center;
  color: #7a7a7a;
}
.ly-footer .call svg { width: 1.6rem; height: 1.6rem; }
.ly-footer .input-box { flex: 1; min-width: 0; }
.ly-footer textarea {
  width: 100%; height: 2.6rem; padding: 0.4rem 0.7rem;
  color: var(--ink); font-size: var(--fs-base); line-height: 1.4;
  background: var(--chat-bg); border: 1px solid var(--line);
  border-radius: var(--radius-btn); outline: none; resize: none; overflow-y: auto;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}
.ly-footer textarea:focus {
  border-color: var(--brand); box-shadow: 0 0 0 3px rgba(11, 107, 168, 0.14);
}
.ly-footer .send {
  flex-shrink: 0; height: 2.6rem; padding: 0 1rem;
  display: flex; align-items: center; justify-content: center;
  background: var(--brand-grad); color: #fff;
  font-size: var(--fs-sm); font-weight: 600;
  border-radius: var(--radius-btn);
  box-shadow: 0 4px 12px rgba(11, 107, 168, 0.22);
  transition: filter 0.2s ease;
}
.ly-footer .send:hover { filter: brightness(0.97); }
.ly-footer .send:active { filter: brightness(0.92); }

/* ===== 铃铛动画 ===== */
.ly-animation-bell { display: inline-block; transition: 0.5s; }
.ly-animation-bell.on { animation: ly-animation-bell 0.5s; }
@keyframes ly-animation-bell {
  0%   { transform: rotate(-5deg); }
  20%  { transform: rotate(10deg); }
  40%  { transform: rotate(-15deg); }
  60%  { transform: rotate(20deg); }
  80%  { transform: rotate(-15deg); }
  100% { transform: rotate(10deg); }
}
