/* Both editions share a reader; this server-selected attribute changes its palette.
   No hostname guessing, global theme storage, or cross-origin requests are used. */
@layer base {
  :root[data-edition="buzz"]{--paper:#eff4f8;--surface:#f9fbfe;--ink:#182838;--muted:#52677a;--subtle:#718598;--line:#cedbe7;--strong-line:#8fa8bf;--accent:#245c98;--accent-soft:#dceafa;--security:#845033;--security-soft:#f0e4d9;--link:#195d9e;--shadow:0 12px 40px #152f4920}
  :root[data-edition="buzz"][data-theme="dark"]{--paper:#111c29;--surface:#182839;--ink:#edf3fa;--muted:#adbed0;--subtle:#8c9fb3;--line:#30465c;--strong-line:#57758f;--accent:#96c7ff;--accent-soft:#213b56;--security:#edba94;--security-soft:#463729;--link:#abd2ff;--shadow:0 12px 40px #0006}
  @media(prefers-color-scheme:dark){:root[data-edition="buzz"]:not([data-theme="light"]):not([data-theme="dark"]){--paper:#111c29;--surface:#182839;--ink:#edf3fa;--muted:#adbed0;--subtle:#8c9fb3;--line:#30465c;--strong-line:#57758f;--accent:#96c7ff;--accent-soft:#213b56;--security:#edba94;--security-soft:#463729;--link:#abd2ff;--shadow:0 12px 40px #0006}}
}
@layer components {
  .edition-switch{display:flex;flex-direction:column;align-items:flex-start;justify-content:center;gap:4px;min-height:52px;max-width:270px;padding:9px 13px;border:1px solid var(--strong-line);border-radius:8px;background:var(--surface);color:var(--ink);text-decoration:none;line-height:1.35;transition:background-color .15s,border-color .15s}
  .edition-switch-current{font-size:11px;font-weight:650;overflow-wrap:anywhere}
  .edition-switch-destination{display:flex;align-items:center;gap:8px;font-size:10px;color:var(--accent);font-weight:550}
  .edition-switch-destination>span{font-size:16px;line-height:1}
  .edition-switch:hover{border-color:var(--accent);background:var(--accent-soft)}
  .edition-switch:focus-visible{outline:3px solid var(--accent);outline-offset:4px}
  :root[data-edition="buzz"] .wordmark-icon{transform:rotate(0);gap:2px}
  :root[data-edition="buzz"] .wordmark-icon i{border-radius:50%}
  :root[data-edition="buzz"] .category-label{color:var(--accent)}
  :root[data-edition="buzz"] .design-topics,:root[data-edition="buzz"] .library-tab{display:none!important}
}
@layer responsive {
  /* On phones the edition control gets a deliberate full row. It never disappears. */
  @media(max-width:700px){
    .masthead-inner,.reader-page .masthead-inner{display:flex;flex-wrap:wrap;gap:8px 12px;padding-top:12px;padding-bottom:12px}
    .masthead .wordmark{order:0}
    .masthead .masthead-actions,.reader-page .masthead-actions{order:1;flex-basis:auto;margin-left:auto;justify-content:flex-end;gap:0}
    .masthead .edition-switch{order:2;flex-basis:100%;max-width:none;min-width:0;min-height:48px;flex-direction:row;align-items:center;justify-content:space-between;gap:12px;padding:10px 12px}
    .edition-switch-current{font-size:11px;min-width:0}
    .edition-switch-destination{font-size:10px;flex-shrink:0;gap:5px}
    .masthead .settings-back{order:1;margin-left:auto;font-size:11px}
  }
  @media(max-width:360px){
    .masthead .wordmark{font-size:34px}
    .masthead .wordmark-icon{margin-right:7px}
    .masthead .masthead-actions,.reader-page .masthead-actions{gap:0;flex-basis:auto}
    .masthead-actions>.icon-button{padding:7px 5px}
    .masthead .edition-switch{gap:8px;padding:9px 10px}
    .edition-switch-current{font-size:10px}
    .edition-switch-destination{font-size:9px;max-width:45%;flex-wrap:wrap}
  }
  @media print{.edition-switch{display:none!important}:root[data-edition="buzz"]{--paper:white;--surface:white;--ink:black;--muted:#444;--accent:#245c98}}
}
