/* Bozo's Theme v3.9.0: dual-color lightbulb switch.
   Scoped to the existing theme toggle; compatible with the v3.8.1
   wordmark/mobile drawer and separate Bozo's Header Fix plugin. */
.cm-v150 .cm-theme-toggle.cm-bulb-toggle {
  --cm-bulb-ink: #9cd8ff;
  --cm-bulb-light: rgba(105, 171, 211, .16);
  --cm-bulb-base: #b6dcef;
  --cm-bulb-halo: rgba(66, 166, 221, .13);
  --cm-bulb-border: rgba(113, 180, 232, .48);
  display: inline-flex;
  gap: 8px;
  align-items: center;
  justify-content: center;
  border-color: var(--cm-bulb-border);
  background: linear-gradient(145deg, #23445d, #10263d);
  color: #ebf6ff;
  box-shadow: inset 0 1px 0 rgba(229,246,255,.12), 0 2px 8px rgba(0,0,0,.16);
  transition: border-color .18s ease, background-color .18s ease, box-shadow .18s ease;
  cursor: pointer;
}
.cm-v150 .cm-bulb-toggle.cm-bulb-palette-amber-teal {
  --cm-bulb-ink: #69e0c5;
  --cm-bulb-base: #baf0e2;
  --cm-bulb-light: rgba(43, 182, 158, .14);
  --cm-bulb-halo: rgba(43, 182, 158, .17);
  --cm-bulb-border: rgba(75,198,174,.43);
}
.cm-v150 .cm-bulb-toggle.cm-bulb-palette-amber-silver {
  --cm-bulb-ink: #e1e9f4;
  --cm-bulb-base: #c9d5e3;
  --cm-bulb-light: rgba(218, 232, 244, .12);
  --cm-bulb-halo: rgba(173, 205, 227, .16);
  --cm-bulb-border: rgba(196, 215, 236, .46);
}
.cm-v150 .cm-bulb-toggle .cm-toggle-glyph {
  display: inline-flex;
  flex: none;
  align-items: center;
  justify-content: center;
  width: 29px;
  height: 29px;
  line-height: 1;
  color: var(--cm-bulb-ink);
}
.cm-v150 .cm-bulb-toggle .cm-bulb-icon {
  display: block;
  width: 28px;
  height: 28px;
  overflow: visible;
  color: var(--cm-bulb-ink);
  transition: color .18s ease, filter .18s ease;
}
.cm-v150 .cm-bulb-toggle .cm-bulb-glass {
  stroke: currentColor;
  stroke-width: 2;
  fill: var(--cm-bulb-light);
}
.cm-v150 .cm-bulb-toggle .cm-bulb-filament {
  stroke: var(--cm-bulb-base);
  opacity: .92;
}
.cm-v150 .cm-bulb-toggle .cm-bulb-base { stroke: var(--cm-bulb-base); }
.cm-v150 .cm-bulb-toggle .cm-bulb-rays { opacity: .34; }
.cm-v150 .cm-bulb-toggle:hover {
  border-color: var(--cm-bulb-ink);
  box-shadow: inset 0 1px 0 rgba(229,246,255,.18), 0 0 0 3px var(--cm-bulb-halo);
}
/* Light mode: bulb is turned off, retaining an accessible tap target. */
html[data-cm-theme="light"] .cm-v150 .cm-theme-toggle.cm-bulb-toggle {
  --cm-bulb-ink: #915500;
  --cm-bulb-base: #825311;
  --cm-bulb-light: #ffd168;
  --cm-bulb-halo: rgba(250, 177, 42, .23);
  --cm-bulb-border: #b77829;
  background: linear-gradient(145deg,#fff9e9,#f8d590);
  border-color: var(--cm-bulb-border);
  color: #37240e;
  box-shadow: inset 0 1px 0 #fff, 0 2px 10px rgba(130, 87, 24, .15);
}
html[data-cm-theme="light"] .cm-v150 .cm-bulb-toggle .cm-bulb-rays { opacity: 1; }
html[data-cm-theme="light"] .cm-v150 .cm-bulb-toggle.cm-bulb-glow-enabled .cm-bulb-icon {
  filter: drop-shadow(0 0 4px rgba(255,174,23,.63));
}
html[data-cm-theme="light"] .cm-v150 .cm-theme-toggle.cm-bulb-toggle:hover {
  background: linear-gradient(145deg,#fffaf0,#ffc65b);
  box-shadow: inset 0 1px 0 #fff, 0 0 0 3px rgba(232,158,27,.25);
}
.cm-v150 .cm-theme-toggle.cm-bulb-toggle:focus-visible {
  outline: 3px solid #52c9dd;
  outline-offset: 3px;
}
html[data-cm-theme="light"] .cm-v150 .cm-theme-toggle.cm-bulb-toggle:focus-visible {
  outline-color: #9a5907;
}
/* In the mobile drawer, keep the lightbulb beside the text; do not alter
   the 3.8.1 header layout or hamburger menu's focus management. */
@media(max-width:1080px) {
  .cm-v150 .bsh-mobile-appearance .cm-theme-toggle.cm-bulb-toggle {
    width: 100%;
    justify-content: flex-start;
  }
}
@media(prefers-reduced-motion: reduce) {
  .cm-v150 .cm-bulb-toggle,
  .cm-v150 .cm-bulb-toggle .cm-bulb-icon { transition: none !important; }
}

/* v4.0: real emoji 💡 lights up when dark mode is ON. */
.cm-v150 .cm-theme-toggle.cm-bulb-emoji {
  min-width: 46px; min-height: 46px; border-radius: 13px;
  background: linear-gradient(145deg, #284965, #0c2137);
  border: 1px solid rgba(255,194,84,.66);
  box-shadow: inset 0 1px 0 rgba(255,255,255,.14), 0 0 10px rgba(255,181,62,.15);
}
.cm-v150 .cm-bulb-emoji .cm-toggle-glyph,
.cm-v150 .cm-bulb-emoji .cm-emoji-bulb {
  display:inline-flex; width:32px; height:32px; align-items:center; justify-content:center;
  font-family: 'Apple Color Emoji','Segoe UI Emoji','Noto Color Emoji',sans-serif;
  font-size: 27px; line-height:1; color:initial;
}
html[data-cm-theme="dark"] .cm-v150 .cm-bulb-emoji .cm-emoji-bulb {
  opacity:1; filter:saturate(1.24);
}
html[data-cm-theme="dark"] .cm-v150 .cm-bulb-emoji.cm-bulb-glow-enabled .cm-emoji-bulb {
  filter:drop-shadow(0 0 6px rgba(255,207,72,.84)) saturate(1.24);
}
html[data-cm-theme="light"] .cm-v150 .cm-theme-toggle.cm-bulb-emoji {
  background:linear-gradient(145deg,#f5f7fa,#dce3e9);
  border-color:#8192a5; box-shadow:inset 0 1px 0 #fff;
}
html[data-cm-theme="light"] .cm-v150 .cm-bulb-emoji .cm-emoji-bulb {
  opacity:.66; filter:grayscale(1) saturate(0) brightness(.85);
}
.cm-v150 .cm-theme-toggle.cm-bulb-emoji:focus-visible { outline:3px solid #f9bb43; outline-offset:3px; }
@media (prefers-reduced-motion:reduce) {
 .cm-v150 .cm-bulb-emoji .cm-emoji-bulb { transition:none!important; }
}
