/* The share bar (share.mjs, share.js) on the hub's tokens (hub.css), so it reads right on the light /learn/ pages and the dark
   hub pages alike. Round marks in each place's colour up front; More and the WeChat card are bordered panels under the row, no
   shadow. Without the script More stays open (every link reachable) and the WeChat card opens as the link's #target. */
.sh { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 8px; margin-top: var(--lt-y, 40px); padding-top: 20px; border-top: 1px solid var(--hb-line); }
.sh [hidden] { display: none !important; }
.sh svg { display: block; flex-shrink: 0; }
.sh-h { display: flex; align-items: center; gap: 8px; margin: 0 auto 0 0; font-size: 14px; font-weight: 500; color: var(--hb-mut); }
.sh-row { display: flex; flex-wrap: wrap; gap: 8px; }
.sh-b {
  box-sizing: border-box; display: inline-flex; align-items: center; justify-content: center; width: 36px; height: 36px; padding: 0;
  border: 1px solid var(--hb-line); border-radius: 50%; background: var(--sh-bg); color: var(--sh-fg); cursor: pointer; text-decoration: none;
  transition: transform .15s ease, opacity .15s ease;
}
.sh-b:hover { transform: scale(1.06); opacity: .92; }
.sh-ghost { background: var(--hb-card); color: var(--hb-fg); }
.sh-more-btn { display: none; }
.hb-js .sh-more-btn { display: inline-flex; }
.sh-b:focus-visible, .sh-chip:focus-visible, .sh-x:focus-visible, .sh-manual:focus-visible { outline: 2px solid var(--hb-vi); outline-offset: 2px; }
.sh-panel { flex-basis: 100%; box-sizing: border-box; padding: 12px; border: 1px solid var(--hb-line); border-radius: 16px; background: var(--hb-card); }
.hb-js .sh-more:not(.sh-open) { display: none; }
.sh-panel-h { display: flex; align-items: center; gap: 8px; margin: 0 0 10px; font-size: 14px; font-weight: 600; color: var(--hb-fg); }
.sh-chips { display: flex; flex-wrap: wrap; gap: 8px; }
.sh-chip {
  box-sizing: border-box; display: inline-flex; align-items: center; gap: 8px; height: 36px; padding: 0 12px 0 4px; border: 1px solid var(--hb-line);
  border-radius: 999px; background: transparent; color: var(--hb-fg); font: inherit; font-size: 14px; font-weight: 500; text-decoration: none; cursor: pointer;
}
.sh-chip:hover { background: var(--lt-fill, rgba(127, 127, 127, .1)); }
.sh-chip-plain { padding: 0 14px; }
.sh-dot { display: inline-flex; align-items: center; justify-content: center; width: 28px; height: 28px; border-radius: 50%; background: var(--sh-bg); color: var(--sh-fg); }
.sh-dot-ink { --sh-bg: #0b0712; --sh-fg: #fff; }
.sh-wechat { display: none; position: relative; align-items: center; gap: 18px; }
.sh-wechat:target, .sh-wechat.sh-open { display: flex; }
.sh-qr { width: 160px; height: 160px; border: 1px solid var(--hb-line); border-radius: 12px; background: #fff; }
.sh-wechat-tx { min-width: 0; padding-right: 32px; }
.sh-note { margin: 0 0 12px; font-size: 14px; line-height: 1.5; color: var(--hb-mut); }
.sh-x {
  position: absolute; top: 8px; right: 8px; display: inline-flex; align-items: center; justify-content: center; width: 32px; height: 32px;
  padding: 0; border: 0; border-radius: 50%; background: transparent; color: var(--hb-mut); cursor: pointer;
}
.sh-x:hover { background: var(--lt-fill, rgba(127, 127, 127, .1)); color: var(--hb-fg); }
.sh-status { flex-basis: 100%; margin: 0; font-size: 13px; color: var(--hb-mut); }
.sh-status:empty { display: none; }
.sh-manual {
  flex-basis: 100%; box-sizing: border-box; height: 36px; padding: 0 12px; border: 1px solid var(--hb-line); border-radius: 10px;
  background: var(--lt-field, transparent); color: var(--hb-fg); font: inherit; font-size: 14px;
}
@media (max-width: 560px) {
  .sh-h { flex-basis: 100%; }
  .sh-wechat:target, .sh-wechat.sh-open { flex-direction: column; text-align: center; }
  .sh-wechat-tx { padding: 0 24px; }
  .sh-wechat .sh-panel-h { justify-content: center; }
}
/* On the hub's dark pages (templates, compare) the bar is a section of its own: its border and the section's padding space it. */
.hb-share-sec .sh { margin-top: 0; }
