/* Match the main header controls, including its 0.8 desktop display scale. */
body { --appearance-size: 35.2px; --appearance-icon: 19.2px; }
.shared-appearance { display: flex; align-items: center; gap: calc(8px / var(--page-ui-scale, 1)); flex: none; }
body .shared-appearance :is(#theme-toggle,#mascot-toggle) {
  position: static; display: grid; place-items: center; flex: none;
  width: var(--appearance-size); height: var(--appearance-size);
  min-width: 0; min-height: 0; padding: 0; border-radius: 50%;
  border: 1px solid rgba(207,220,235,.27);
  background: linear-gradient(165deg,rgba(37,47,61,.60),rgba(12,22,35,.70));
  color: #f1f6ff; cursor: pointer;
  box-shadow: inset 0 1px rgba(235,243,255,.14),0 3px 8px rgba(0,8,27,.14);
}
.shared-appearance svg { width: var(--appearance-icon); height: var(--appearance-icon); }
.shared-appearance #mascot-toggle[aria-pressed="false"] svg { opacity: .6; }
.shared-appearance #mascot-toggle[aria-pressed="true"] { border-color: rgba(201,220,243,.65); }
.shared-appearance :is(button):focus-visible { outline: 2px solid #8ebdf5; outline-offset: 4px; }
.shared-appearance .theme-icon-moon, .light-mode .shared-appearance .theme-icon-sun { display: none; }
.light-mode .shared-appearance .theme-icon-moon { display: inline; }
.light-mode:not([data-page="report"]) .shared-appearance button { background: #edf4fc; color: #24456a; border-color: #91accb; }
#simple_header .shared-appearance { margin-left: auto; }
#head > .shared-appearance { position: absolute; top: 1.5rem; right: 1.5rem; }
body .portal-actions .pwa-install-btn { min-height: 0; height: var(--appearance-size); padding: 0 calc(9px / var(--page-ui-scale, 1)); font-size: calc(10px / var(--page-ui-scale, 1)); border-width: calc(1px / var(--page-ui-scale, 1)); line-height: 1; border-radius: 999px; }
.portal-actions { gap: calc(8px / var(--page-ui-scale, 1)); }
.header-inner { flex-wrap: wrap; }
.corner-watermark { position: fixed; bottom: 0; right: 0; width: 480px; height: auto; opacity: .35; pointer-events: none; z-index: 50; }
body.mascot-hidden .corner-watermark { display: none !important; }
@media (max-width: 768px) { body { --appearance-size: 28.8px; --appearance-icon: 16px; } }
@media (max-width: 480px) {
  body { --appearance-size: 24px; --appearance-icon: 13.6px; }
  .shared-appearance { gap: 6px; }
  body .portal-actions .pwa-install-btn { font-size: 9px; padding-inline: 7px; }
}
@media (max-width: 1700px), (max-height: 700px) { body .corner-watermark { display: none !important; } }
@media (min-width: 1701px) and (min-height: 701px) { body:not(.mascot-hidden) .corner-watermark { display: block; } }
