/* ==========================================================================
   拓盟传媒 · 全站分享卡片 + 资料领取弹窗（由 /js/share.js 驱动）
   设计原则：不打断阅读，桌面左下 / 移动底部悬浮；轻量、低侵入。
   ========================================================================== */

/* ---------- 浮动分享按钮（FAB） ---------- */
.tm-share-fab {
  position: fixed;
  left: 18px;
  bottom: 96px;
  z-index: 70;
  width: 52px;
  height: 52px;
  border: none;
  border-radius: 50%;
  background: var(--navy, #0B1F3A);
  color: #fff;
  box-shadow: 0 8px 22px rgba(11, 31, 58, .28);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform .18s ease, box-shadow .18s ease;
}
.tm-share-fab:hover { transform: translateY(-2px); box-shadow: 0 12px 26px rgba(11, 31, 58, .34); }
.tm-share-fab svg { width: 24px; height: 24px; display: block; }

/* ---------- 分享面板 ---------- */
.tm-share-panel {
  position: fixed;
  left: 18px;
  bottom: 158px;
  z-index: 71;
  width: 210px;
  background: #fff;
  border-radius: 16px;
  padding: 12px;
  box-shadow: 0 14px 36px rgba(11, 31, 58, .22);
  border: 1px solid var(--line, #DCE4EE);
}
.tm-share-panel[hidden] { display: none; }
.tm-share-head {
  font-size: 12px;
  color: var(--text-2, #5B6B7F);
  padding: 2px 6px 10px;
  border-bottom: 1px solid var(--line, #DCE4EE);
  margin-bottom: 8px;
}
.tm-share-opt {
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
  text-align: left;
  background: var(--bg, #F4F7FB);
  border: 1px solid transparent;
  border-radius: 11px;
  padding: 11px 12px;
  margin-bottom: 7px;
  font-size: 14px;
  color: var(--ink, #1F2733);
  cursor: pointer;
  transition: background .15s ease, border-color .15s ease;
}
.tm-share-opt:hover { background: #eef3fa; border-color: var(--blue, #2A6FDB); }
.tm-share-opt .ic { font-size: 18px; line-height: 1; }
.tm-share-close {
  width: 100%;
  background: none;
  border: none;
  color: var(--text-2, #5B6B7F);
  font-size: 13px;
  padding: 6px;
  cursor: pointer;
}
.tm-share-mask { position: fixed; inset: 0; z-index: 69; background: transparent; }
.tm-share-mask[hidden] { display: none; }

/* ---------- 微信内分享引导遮罩 ---------- */
.tm-wx-guide {
  position: fixed; inset: 0; z-index: 90;
  background: rgba(0, 0, 0, .72);
  display: flex; justify-content: flex-end;
}
.tm-wx-guide[hidden] { display: none; }
.tm-wx-guide-inner {
  margin: 14px 16px; max-width: 260px; text-align: right; color: #fff;
  font-size: 15px; line-height: 1.7;
}
.tm-wx-guide-inner .tm-wx-arrow { font-size: 40px; line-height: 1; margin-bottom: 4px; }
.tm-wx-guide-inner b { color: #FFD24A; }
.tm-wx-guide-inner button {
  margin-top: 14px; background: #fff; color: #0B1F3A; border: none;
  border-radius: 20px; padding: 8px 18px; font-size: 14px; cursor: pointer;
}

/* ---------- 资料领取弹窗（微信门槛） ---------- */
.tm-gate { position: fixed; inset: 0; z-index: 85; display: flex; align-items: center; justify-content: center; }
.tm-gate[hidden] { display: none; }
.tm-gate-mask { position: absolute; inset: 0; background: rgba(11, 31, 58, .55); }
.tm-gate-box {
  position: relative; z-index: 1;
  width: min(380px, 92vw);
  background: #fff; border-radius: 18px;
  padding: 22px 22px 18px; text-align: center;
  box-shadow: 0 20px 60px rgba(0, 0, 0, .3);
  max-height: 92vh; overflow: auto;
}
.tm-gate-close {
  position: absolute; top: 10px; right: 12px;
  background: none; border: none; font-size: 24px; line-height: 1;
  color: var(--text-2, #5B6B7F); cursor: pointer;
}
.tm-gate-title { font-size: 18px; font-weight: 700; color: var(--navy, #0B1F3A); margin-bottom: 12px; }
.tm-gate-qr { width: 168px; height: 168px; margin: 0 auto 10px; border: 1px solid var(--line, #DCE4EE); border-radius: 12px; overflow: hidden; }
.tm-gate-qr img { width: 100%; height: 100%; object-fit: cover; }
.tm-gate-wx { font-size: 14px; color: var(--ink, #1F2733); margin-bottom: 12px; }
.tm-gate-wx b { color: var(--blue, #2A6FDB); }
.tm-gate-steps { text-align: left; font-size: 13px; color: var(--text-2, #5B6B7F); padding-left: 20px; margin: 0 0 14px; line-height: 1.7; }
.tm-gate-steps b { color: var(--navy, #0B1F3A); }
.tm-gate-creds {
  display: flex; flex-direction: column; gap: 4px; text-align: left;
  background: var(--bg, #F4F7FB); border: 1px solid var(--line, #DCE4EE);
  border-radius: 10px; padding: 10px 12px; margin: 0 0 12px;
  font-size: 13px; color: var(--text-2, #5B6B7F);
}
.tm-gate-creds b { color: var(--navy, #0B1F3A); font-family: ui-monospace, Menlo, Consolas, monospace; letter-spacing: .3px; }
.tm-gate-input { display: flex; gap: 8px; margin-bottom: 8px; }
.tm-gate-input input {
  flex: 1; padding: 11px 12px; border: 1px solid var(--line, #DCE4EE);
  border-radius: 10px; font-size: 14px; outline: none;
}
.tm-gate-input input:focus { border-color: var(--blue, #2A6FDB); }
.tm-gate-input button {
  background: var(--blue, #2A6FDB); color: #fff; border: none;
  border-radius: 10px; padding: 0 16px; font-size: 14px; font-weight: 600; cursor: pointer;
}
.tm-gate-msg { font-size: 12.5px; min-height: 18px; margin-bottom: 6px; }
.tm-gate-msg.err { color: #E63946; }
.tm-gate-msg.ok { color: #1B9E5A; }
.tm-gate-down {
  display: block; margin: 6px auto 10px; background: var(--navy, #0B1F3A); color: #fff;
  text-decoration: none; border-radius: 10px; padding: 12px; font-weight: 700; font-size: 14px;
}
.tm-gate-tip { font-size: 11px; color: var(--text-2, #5B6B7F); margin: 0; line-height: 1.5; }

/* ---------- 轻提示 toast ---------- */
.tm-toast {
  position: fixed; left: 50%; bottom: 90px; transform: translateX(-50%);
  z-index: 95; background: rgba(11, 31, 58, .92); color: #fff;
  padding: 10px 18px; border-radius: 22px; font-size: 13px;
  opacity: 0; pointer-events: none; transition: opacity .25s ease, transform .25s ease;
}
.tm-toast.show { opacity: 1; transform: translateX(-50%) translateY(-4px); }

/* ---------- 移动端避让底部 dock ---------- */
@media (max-width: 768px) {
  .tm-share-fab { bottom: 78px; width: 48px; height: 48px; }
  .tm-share-panel { left: 12px; bottom: 134px; width: 196px; }
  .tm-toast { bottom: 76px; }
}
