/* Pulse shared colour-theme control (docs/DESIGN.md D41): the header button, the same on every page and on the hub's own
   pages. Canonical copy: pages/_shared/pulse-theme.css; copied verbatim next to pulse-theme.js (load it after the page's own
   stylesheet). Uses the page's tokens where it has them (--border or --line, --surface, --muted, --ink, --accent), with
   the house values as fallback. The icon follows <html data-theme> (set before the first paint by pulse-theme.js):
   automatic = half-filled circle, light = sun, dark = moon. Drawn as a mask in the text colour: no markup, no script. */
:root[data-theme="light"]{color-scheme:light}
:root[data-theme="dark"]{color-scheme:dark}
button.pt-theme{-webkit-appearance:none;appearance:none;box-sizing:border-box;flex:none;display:inline-flex;align-items:center;justify-content:center;
  width:32px;height:32px;min-width:32px;margin:0;padding:0;border-radius:999px;cursor:pointer;font:inherit;font-size:0;line-height:0;
  border:1px solid var(--border,var(--line,#dce2ea));background:var(--surface,#fff);color:var(--muted,#5f6a79);
  transition:color .12s,border-color .12s}
button.pt-theme:hover{color:var(--ink,#191d26);border-color:var(--accent,#2f5d8a)}
button.pt-theme:focus-visible{outline:2px solid var(--accent,#2f5d8a);outline-offset:2px}
button.pt-theme::before{content:"";display:block;width:16px;height:16px;background-color:currentColor;
  -webkit-mask:var(--pt-ic) center/16px 16px no-repeat;mask:var(--pt-ic) center/16px 16px no-repeat;
  --pt-ic:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='12' cy='12' r='8.5'/%3E%3Cpath d='M12 3.5a8.5 8.5 0 0 1 0 17z' fill='%23000'/%3E%3C/svg%3E")}
:root[data-theme="light"] button.pt-theme::before{
  --pt-ic:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='12' cy='12' r='4'/%3E%3Cpath d='M12 2v2M12 20v2M4.93 4.93l1.41 1.41M17.66 17.66l1.41 1.41M2 12h2M20 12h2M6.34 17.66l-1.41 1.41M19.07 4.93l-1.41 1.41'/%3E%3C/svg%3E")}
:root[data-theme="dark"] button.pt-theme::before{
  --pt-ic:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M12 3a6 6 0 0 0 9 9 9 9 0 1 1-9-9z'/%3E%3C/svg%3E")}
@media print{button.pt-theme{display:none}}
@media (forced-colors:active){button.pt-theme::before{background-color:ButtonText}}
