/* Design switcher for the preview build only (never deployed): a small bar at the bottom left
   of every preview page with previous/next design, the design list and a hide toggle.
   CSS only (the site's CSP allows no JavaScript). The id selectors and "all: revert" keep the
   designs' own styles from leaking into the bar. */

#gse-sw, #gse-sw *, #gse-sw *::before, #gse-sw *::after { all: revert; box-sizing: border-box; }

#gse-sw {
  position: fixed;
  left: 12px;
  bottom: 12px;
  z-index: 2147483000;
  font: 500 13px/1 system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  color: #ffffff;
  -webkit-font-smoothing: antialiased;
}
#gse-noswitch { display: none !important; }
#gse-noswitch:target ~ #gse-sw { display: none !important; }

#gse-sw .gse-sw__toggle {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: 0;
  opacity: 0;
  pointer-events: none;
}

#gse-sw .gse-sw__bar {
  display: flex;
  align-items: center;
  gap: 2px;
  padding: 4px;
  border-radius: 999px;
  background: rgba(20, 21, 26, 0.9);
  box-shadow: 0 4px 18px rgba(0, 0, 0, 0.28), 0 0 0 1px rgba(255, 255, 255, 0.08);
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
}
#gse-sw a, #gse-sw label, #gse-sw summary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: 30px;
  min-width: 30px;
  padding: 0 8px;
  border-radius: 999px;
  color: #ffffff;
  font: inherit;
  text-decoration: none;
  cursor: pointer;
  white-space: nowrap;
  list-style: none;
}
#gse-sw summary::-webkit-details-marker { display: none; }
#gse-sw a:hover, #gse-sw label:hover, #gse-sw summary:hover { background: rgba(255, 255, 255, 0.16); }
#gse-sw a:focus-visible, #gse-sw summary:focus-visible,
#gse-sw .gse-sw__toggle:focus-visible ~ .gse-sw__bar .gse-sw__hide,
#gse-sw .gse-sw__toggle:focus-visible ~ .gse-sw__mini { outline: 2px solid #ffc94d; outline-offset: 1px; }
#gse-sw .gse-sw__arrow { font-size: 18px; padding-bottom: 2px; }

#gse-sw .gse-sw__name { max-width: 46vw; padding: 0 10px; overflow: hidden; text-overflow: ellipsis; }
#gse-sw .gse-sw__nr { margin-right: 6px; opacity: 0.6; font-variant-numeric: tabular-nums; }
#gse-sw .gse-sw__tag {
  margin-left: 7px;
  padding: 3px 6px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.14);
  font-size: 11px;
  opacity: 0.85;
}

/* Jump list: opens upwards. */
#gse-sw .gse-sw__bar { position: relative; }
#gse-sw .gse-sw__jump[open] > summary { background: rgba(255, 255, 255, 0.16); }
#gse-sw .gse-sw__list {
  position: absolute;
  left: 0;
  bottom: calc(100% + 8px);
  width: min(300px, calc(100vw - 24px));
  max-height: min(70vh, 560px);
  margin: 0;
  padding: 6px;
  overflow-y: auto;
  overscroll-behavior: contain;
  border-radius: 14px;
  background: rgba(20, 21, 26, 0.96);
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.35), 0 0 0 1px rgba(255, 255, 255, 0.08);
  list-style: none;
}
#gse-sw .gse-sw__group {
  display: block;
  padding: 10px 10px 6px;
  color: rgba(255, 255, 255, 0.55);
  font-size: 11px;
}
#gse-sw .gse-sw__list a {
  display: flex;
  justify-content: flex-start;
  width: 100%;
  height: auto;
  padding: 7px 10px;
  border-radius: 8px;
}
#gse-sw .gse-sw__list a[aria-current] { background: #ffffff; color: #14151a; }
#gse-sw .gse-sw__list .gse-sw__nr { min-width: 2.2em; }

/* Hidden state: only a small round button remains. */
#gse-sw .gse-sw__mini {
  display: none;
  width: 34px;
  height: 34px;
  padding: 0;
  background: rgba(20, 21, 26, 0.9);
  box-shadow: 0 4px 18px rgba(0, 0, 0, 0.28), 0 0 0 1px rgba(255, 255, 255, 0.08);
  font-size: 15px;
}
#gse-sw .gse-sw__toggle:checked ~ .gse-sw__bar { display: none; }
#gse-sw .gse-sw__toggle:checked ~ .gse-sw__mini { display: inline-flex; }

@media (max-width: 30em) {
  #gse-sw .gse-sw__tag { display: none; }
  #gse-sw .gse-sw__name { max-width: 38vw; }
}
@media print { #gse-sw { display: none !important; } }
