#tool-body {
  --wx-card: #fff;
  --wx-text: #333;
  --wx-muted: #888;
  --wx-border: #e5e5e5;
  --wx-hover: #f5f5f5;
  --wx-primary: #07c160;
  --wx-primary-weak: #e8f8ee;
  --wx-danger: #ff5722;
}
.theme-dark-mode #tool-body {
  --wx-card: #2d2d2d;
  --wx-text: #ddd;
  --wx-muted: #999;
  --wx-border: #3d3d3f;
  --wx-hover: #3a3a3c;
  --wx-primary: #07c160;
  --wx-primary-weak: #1d3327;
}
#tool-body .wx-layout { display: flex; gap: 16px; align-items: flex-start; }
#tool-body .wx-col-editor { flex: 1 1 420px; min-width: 0; }
#tool-body .wx-col-preview { flex: 0 0 375px; }
@media (max-width: 768px) {
  #tool-body .wx-layout { flex-direction: column; align-items: stretch; }
  #tool-body .wx-col-preview { flex: 1 1 auto; width: 100%; order: -1; }
}
#tool-body .wx-card {
  background: var(--wx-card);
  border-radius: 10px;
  padding: 14px 16px;
  margin-bottom: 12px;
  box-shadow: 0 1px 4px rgba(0,0,0,.05);
}
#tool-body .wx-card > h3 {
  font-size: 15px;
  font-weight: 600;
  margin: 0 0 12px;
  color: var(--wx-text);
  display: flex;
  align-items: center;
  gap: 6px;
}
#tool-body .wx-field { display: flex; align-items: center; gap: 8px; margin-bottom: 8px; flex-wrap: wrap; }
#tool-body .wx-field > label { flex: 0 0 auto; min-width: 70px; white-space: nowrap; font-size: 13px; color: var(--wx-muted); }
#tool-body .wx-in {
  border: 1px solid var(--wx-border);
  border-radius: 6px;
  padding: 0 8px;
  background: var(--wx-card);
  color: var(--wx-text);
  font-size: 13px;
  flex: 1 1 120px;
  min-width: 0;
  outline: none;
}
#tool-body .wx-in:focus { border-color: var(--wx-primary); }
#tool-body textarea.wx-in { height: auto; min-height: 64px; padding: 6px 8px; line-height: 1.6; resize: vertical; }
#tool-body #wx-import-text { width: 100%; display: block; box-sizing: border-box; }
#tool-body .wx-field .layui-input-wrap { flex: 1 1 120px; min-width: 0; }
#tool-body .layui-input-wrap .wx-in { width: 100%; flex: none; box-sizing: border-box; }
#tool-body #wx-f-text-wrap { display: block; }
#tool-body #wx-f-text-wrap > label { display: block; margin-bottom: 6px; }
#tool-body .wx-sel { flex: 1 1 50px; min-width: 0; }
#tool-body .wx-hint { font-size: 12px; color: var(--wx-muted); line-height: 1.7; margin: 6px 0 0; }
#tool-body .wx-btn-row { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 10px; }
#tool-body .wx-modal { position: fixed; left: 0; top: 0; right: 0; bottom: 0; z-index: 19891014; display: flex; overflow: auto; padding: 16px; }
#tool-body .wx-modal-mask { position: fixed; left: 0; top: 0; right: 0; bottom: 0; background: rgba(0,0,0,.5); }
#tool-body .wx-modal-box { position: relative; margin: auto; width: 460px; max-width: 100%; display: flex; flex-direction: column; background: var(--wx-card); border-radius: 10px; box-shadow: 0 10px 40px rgba(0,0,0,.28); }
#tool-body .wx-modal-head { display: flex; align-items: center; justify-content: space-between; padding: 14px 18px; font-weight: 600; font-size: 15px; color: var(--wx-text); border-bottom: 1px solid var(--wx-border); }
#tool-body .wx-modal-x { border: 0; background: transparent; font-size: 24px; line-height: 1; color: var(--wx-muted); cursor: pointer; padding: 0 4px; }
#tool-body .wx-modal-x:hover { color: var(--wx-text); }
#tool-body .wx-modal-body { padding: 16px 18px 4px; }
#tool-body .wx-modal-foot { display: flex; align-items: center; gap: 8px; padding: 12px 18px 16px; justify-content: flex-end; }
#tool-body .wx-btn-ghost {
  height: 32px; line-height: 30px; padding: 0 12px;
  border: 1px solid var(--wx-border); border-radius: 6px;
  background: transparent; color: var(--wx-text);
  font-size: 13px; cursor: pointer;
}
#tool-body .wx-btn-ghost:hover { border-color: var(--wx-primary); color: var(--wx-primary); }
#tool-body .wx-item {
  border: 1px solid var(--wx-border);
  border-radius: 8px;
  padding: 8px 10px;
  margin-bottom: 6px;
  display: flex;
  align-items: center;
  gap: 8px;
}
#tool-body .wx-item.wx-item-editing { border-color: var(--wx-primary); background: var(--wx-primary-weak); }
#tool-body .wx-item .wx-it-avatar { width: 34px; height: 34px; border-radius: 6px; object-fit: cover; flex: 0 0 auto; background: #f1f1f1; }
#tool-body .wx-item .wx-it-main { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 4px; }
#tool-body .wx-item .wx-it-main .wx-in { flex: 0 0 auto; }
#tool-body .wx-item .wx-it-name { font-size: 13px; color: var(--wx-text); }
#tool-body .wx-item .wx-it-ops { display: flex; gap: 4px; flex: 0 0 auto; flex-wrap: wrap; justify-content: flex-end; }
#tool-body .wx-mini-btn {
  height: 26px; line-height: 24px; padding: 0 8px;
  border: 1px solid var(--wx-border); border-radius: 5px;
  background: transparent; color: var(--wx-muted);
  font-size: 12px; cursor: pointer; white-space: nowrap;
}
#tool-body .wx-mini-btn:hover { color: var(--wx-primary); border-color: var(--wx-primary); }
#tool-body .wx-mini-btn.wx-mini-danger:hover { color: var(--wx-danger); border-color: var(--wx-danger); }
#tool-body .wx-badge {
  display: inline-block; padding: 1px 7px; border-radius: 4px;
  font-size: 11px; color: #fff; background: var(--wx-primary); flex: 0 0 auto;
}
#tool-body .wx-badge.wx-badge-time { background: #999; }
#tool-body .wx-badge.wx-badge-media { background: #f79c46; }
#tool-body .wx-sum { flex: 1; min-width: 0; font-size: 13px; color: var(--wx-text); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
#tool-body .wx-disclaimer { font-size: 12px; color: var(--wx-muted); text-align: center; padding: 4px 0 12px; }
#tool-body .wx-preview-sticky { position: sticky; top: 12px; }

/* ============ 手機預覽（1125×2436 原生渲染，縮放至 375×812 顯示） ============ */
#tool-body .wc-preview-box { position: relative; }
#tool-body .wc-phone-scale-wrap { position: absolute; left: 50%; top: 0; width: 375px; height: 812px; transform: translateX(-50%); transform-origin: top center; }
#tool-body .wc-phone-wrap {
  width: 375px; height: 812px; overflow: hidden; border-radius: 44px;
  box-shadow: 0 0 0 2px #2c2c2e, 0 0 0 5px #1a1a1c, 0 0 0 6px #3a3a3c, 0 20px 60px rgba(0,0,0,.25), 0 8px 24px rgba(0,0,0,.12);
  background: #1a1a1c;
}
#tool-body .wc-phone-content { transform: scale(0.33333333); transform-origin: 0 0; }
#tool-body .wc-phone {
  width: 1125px; height: 2436px; background: #ededed; position: relative; font-size: 36px; overflow: hidden;
  scrollbar-width: none; -ms-overflow-style: none;
}
#tool-body .wc-phone::-webkit-scrollbar { width: 0; display: none; }
#tool-body .wc-phone-top { position: relative; z-index: 99; background: #ededed; }
#tool-body .wc-phone-top::after { content: ''; position: absolute; width: 100%; height: 1px; background: #d5d5d5; left: 0; bottom: 2px; }

#tool-body .wc-status-bar { height: 132px; display: flex; align-items: center; padding: 0 43px 0 95px; }
#tool-body .wc-time { font-size: 45px; flex: 1; font-weight: 600; letter-spacing: 1px; color: #000; }
#tool-body .wc-status-icons { display: flex; align-items: flex-end; gap: 18px; height: 36px; }
#tool-body .wc-signal-group { display: flex; align-items: flex-end; gap: 18px; height: 36px; }
#tool-body .wc-official-signal, #tool-body .wc-official-wifi { display: block; flex: 0 0 auto; position: relative; overflow: hidden; }
#tool-body .wc-official-signal-single { width: 60px; height: 36px; }
#tool-body .wc-official-signal-dual { width: 48px; height: 36px; }
#tool-body .wc-official-signal img { position: absolute; width: 148px; height: 60px; max-width: none; filter: brightness(0); }
#tool-body .wc-official-signal-single img { left: -44px; top: -10px; }
#tool-body .wc-official-signal-dual img { width: 118.4px; height: 48px; left: -33.6px; top: -5.6px; }
#tool-body .wc-official-signal-base { opacity: 0.25; }
#tool-body .wc-official-signal-active { position: absolute; left: 0; top: 0; height: 100%; overflow: hidden; }
#tool-body .wc-official-signal-primary { top: 0; height: 100%; }
#tool-body .wc-official-signal-dual .wc-official-signal-primary { clip-path: inset(0 0 13px 0); }
#tool-body .wc-official-signal-dual .wc-official-signal-secondary { clip-path: inset(23px 0 0 0); }
#tool-body .wc-official-wifi { width: 49px; height: 36px; }
#tool-body .wc-official-wifi img { position: absolute; width: 90px; height: 36.5px; max-width: none; left: -20px; top: 0; filter: brightness(0); }
#tool-body .wc-battery-wrap {
  box-sizing: border-box; width: 75px; height: 36px; padding: 7px 16px 7px 7px;
  position: relative; background-repeat: no-repeat; background-position: center; background-size: 75px 36px; flex: 0 0 auto;
}
#tool-body .wc-battery-level { display: block; width: 100%; height: 22px; }
#tool-body .wc-battery-level i { display: block; height: 22px; max-width: 100%; border-radius: 4px; background: #000; }
#tool-body .wc-battery-low .wc-battery-level i { background: #e5484d; }
#tool-body .wc-android-signal-group { display: flex; align-items: flex-end; gap: 5px; height: 39px; }
#tool-body .wc-android-signal, #tool-body .wc-android-wifi { display: block; fill: #000; flex: 0 0 auto; }
#tool-body .wc-android-signal { width: 39px; height: 39px; }
#tool-body .wc-android-wifi { width: 54px; height: 39px; }
#tool-body .wc-android-battery {
  box-sizing: border-box; width: 72px; height: 39px; border: 3px solid rgba(0,0,0,.72); border-radius: 9px;
  position: relative; display: flex; align-items: center; justify-content: center; overflow: visible; flex: 0 0 auto;
}
#tool-body .wc-android-batt-num {
  position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; z-index: 1;
  color: #111;
  font-family: Arial, 'Helvetica Neue', sans-serif; font-size: 26px; line-height: 1; font-weight: 700; letter-spacing: -1px;
}
#tool-body .wc-android-batt-hi {
  color: #fff;
}
#tool-body .wc-android-battery > i { position: absolute; right: -7px; top: 10px; width: 5px; height: 13px; border-radius: 0 3px 3px 0; background: rgba(0,0,0,.72); }
#tool-body .wc-android-battery-fill { position: absolute; left: 0; top: 0; bottom: 0; max-width: 100%; border-radius: 5px; background: #111; }
#tool-body .wc-android-battery-low .wc-android-battery-fill, #tool-body .wc-android-battery-low > i { background: #e5484d; }
#tool-body .wc-android-battery-low { border-color: #e5484d; }
#tool-body .wc-phone-android .wc-status-icons { gap: 14px; }
#tool-body .wc-phone-android .wc-time { font-size: 42px; font-weight: 500; }

#tool-body .wc-nav { height: 132px; display: flex; align-items: center; padding: 0 50px; color: #000; }
#tool-body .wc-nav-left { width: 150px; display: flex; align-items: center; position: relative; }
#tool-body .wc-nav-center { flex: 1; display: flex; justify-content: center; overflow: hidden; }
#tool-body .wc-nav-center span { font-size: 51px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
#tool-body .wc-nav-right { width: 150px; display: flex; justify-content: flex-end; }
#tool-body .wc-nav-dots { display: flex; gap: 12px; align-items: center; }
#tool-body .wc-nav-dots i { width: 12px; height: 12px; background: #000; border-radius: 50%; display: block; }

#tool-body .wc-chat-body {
  position: absolute; top: 264px; bottom: 269px; left: 0; right: 0;
  overflow-y: scroll; -webkit-overflow-scrolling: touch; background-color: #ededed;
  background-position: center; background-repeat: no-repeat; background-size: cover;
  scrollbar-width: none; -ms-overflow-style: none;
}
#tool-body .wc-chat-body::-webkit-scrollbar { width: 0; display: none; }
#tool-body .wc-chat-body-image .wc-nick { color: rgba(255,255,255,.96); text-shadow: 0 1px 4px rgba(0,0,0,.7); }
#tool-body .wc-chat-body-image .wc-notice-bg { padding: 8px 18px; border-radius: 8px; background: rgba(0,0,0,.22); color: #fff; text-shadow: 0 1px 3px rgba(0,0,0,.35); }
#tool-body .wc-chat-content { padding: 36px; }
#tool-body .wc-dialog { margin-bottom: 50px; position: relative; display: flex; }
#tool-body .wc-dialog-right { justify-content: flex-end; }
#tool-body .wc-face { width: 123px; height: 123px; background: #f1f1f1; border-radius: 15px; overflow: hidden; position: absolute; top: 0; }
#tool-body .wc-face img { width: 100%; height: 100%; object-fit: cover; }
#tool-body .wc-dialog-right .wc-face { right: 0; }
#tool-body .wc-body { display: flex; flex-direction: column; margin-left: 160px; margin-right: 140px; max-width: calc(100% - 340px); }
#tool-body .wc-dialog-right .wc-body { margin-left: 140px; margin-right: 160px; align-items: flex-end; }
#tool-body .wc-nick { font-size: 33px; color: #888; margin-bottom: 15px; line-height: 1; padding-left: 6px; transform: translateY(calc(var(--wx-bshift, 0px) * 0.6875)); }
#tool-body .wc-dialog-right .wc-nick { text-align: right; padding-right: 6px; padding-left: 0; }

#tool-body .wc-bubble {
  background: #fff; padding: 28px 38px; font-size: 48px; border-radius: 15px;
  word-break: break-all; display: inline-block; position: relative; line-height: 1.4; min-height: 80px; color: #111;
}
#tool-body .wc-arrow {
  background: #fff; width: 24px; height: 24px; border-bottom-left-radius: 4px;
  top: 50px; left: -12px; position: absolute; transform: rotate(45deg); display: block;
}
#tool-body .wc-dialog-right .wc-arrow { left: auto; right: -10px; border-bottom-left-radius: 0; border-top-right-radius: 4px; }
#tool-body .wc-bubble-txt { display: inline-block; transform: translateY(var(--wx-bshift, 0px)); }

#tool-body .wc-bubble-image { border: 1px #d5d5d5 solid; padding: 0; background: none !important; overflow: hidden; }
#tool-body .wc-bubble-image .wc-arrow { display: none; }
#tool-body .wc-bubble-image img { max-width: 420px; max-height: 420px; display: block; }
#tool-body .wc-img-placeholder {
  width: 300px; height: 240px; display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: 16px; background: #f5f5f5; border-radius: 8px; cursor: pointer;
}
#tool-body .wc-img-placeholder span { font-size: 32px; color: #999; }

#tool-body .wc-voice-stack { display: flex; flex-direction: column; align-items: flex-start; max-width: 700px; }
#tool-body .wc-dialog-right .wc-voice-stack { align-items: flex-end; }
#tool-body .wc-bubble-voice { display: flex; align-items: center; justify-content: flex-start; gap: 16px; padding-top: 25px; padding-bottom: 25px; }
#tool-body .wc-dialog-right .wc-bubble-voice { justify-content: flex-end; }
#tool-body .wc-voice-wave { width: 34px; height: 49px; flex: 0 0 auto; object-fit: contain; }
#tool-body .wc-voice-dur { font-size: 42px; white-space: nowrap; transform: translateY(calc(var(--wx-bshift, 0px) * 0.5)); }
#tool-body .wc-voice-unread { position: absolute; right: -50px; top: 50%; margin-top: -13px; width: 28px; height: 28px; border-radius: 50%; background: #e75e58; }
#tool-body .wc-voice-transcript {
  display: inline-block; width: fit-content; max-width: 700px; margin-top: 8px; padding: 22px 30px;
  border-radius: 14px; background: #fff; color: #111; font-size: 48px; line-height: 1.5; text-align: left; white-space: pre-wrap; word-break: break-word;
  transform: translateY(var(--wx-bshift, 0px));
}

#tool-body .wc-bubble-redpacket, #tool-body .wc-bubble-transfer {
  background: #f79c46 !important; width: 700px; padding: 0 !important; min-height: auto !important; border-radius: 15px; overflow: visible;
}
#tool-body .wc-rp-content { display: flex; height: 192px; align-items: center; position: relative; padding: 0 30px; }
/* #tool-body .wc-rp-content::after { content: ''; background: #f0b36f; position: absolute; width: 100%; height: 1px; bottom: 0; left: 0; } */
#tool-body .wc-rp-icon { width: 120px; height: 120px; display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
#tool-body .wc-rp-icon img { width: 120px; height: 120px; display: block; object-fit: contain; }
#tool-body .wc-rp-icon-redpacket { width: 111px; padding-left: 9px; }
#tool-body .wc-rp-info { flex: 1; display: flex; flex-direction: column; margin-left: 30px; overflow: hidden; }
#tool-body .wc-rp-info span { font-size: 48px; color: #fff; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; transform: translateY(var(--wx-bshift, 0px)); }
#tool-body .wc-rp-info small { font-size: 36px; color: #fff; opacity: 0.85; transform: translateY(calc(var(--wx-bshift, 0px) * 0.75)); }
#tool-body .wc-rp-bottom { height: 71px; display: flex; align-items: center; padding: 0 30px 5px; margin-top: -15px; }
#tool-body .wc-rp-bottom span { font-size: 36px; color: #faecda; }

#tool-body .wc-notice { font-size: 36px; color: #b0b0b0; display: flex; justify-content: center; flex: 1; margin-bottom: 50px; }
#tool-body .wc-notice-bg { background: none; color: #b0b0b0; padding: 10px 17px; text-align: center; transform: translateY(calc(var(--wx-bshift, 0px) * 0.75)); }

#tool-body .wc-bottom { background: #f6f6f6; position: absolute; bottom: 0; width: 100%; }
#tool-body .wc-bottom-chat { height: 170px; border-top: 1px solid #e0e0e0; }
#tool-body .wc-bottom-inner { display: flex; align-items: center; height: 100%; padding: 0 24px; gap: 18px; }
#tool-body .wc-bottom-icon { width: 78px; height: 78px; display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
#tool-body .wc-bottom-icon img { width: 72px; height: 72px; object-fit: contain; }
#tool-body .wc-input-box {
  height: 108px; background: #fff; border-radius: 16px; flex: 1; position: relative;
  display: flex; align-items: center; justify-content: flex-end; padding-right: 10px;
}
#tool-body .wc-input-mic { width: 74px; height: 74px; display: block; }
#tool-body .wc-home-indicator { height: 102px; display: flex; align-items: center; justify-content: center; }
#tool-body .wc-home-indicator i { display: block; width: 402px; height: 15px; background: #000; border-radius: 10px; margin-top: 63px; }
#tool-body .wc-phone-android .wc-home-indicator i { width: 375px; height: 9px; background: rgba(0, 0, 0, 0.35); border-radius: 5px; }