/* Native disclosure: opening the picker does not depend on JavaScript. */
.pnc-theme-picker {
  position: relative;
  display: inline-block;
  flex-shrink: 0;
}

.pnc-theme-picker > summary.pnc-theme-toggle {
  display: flex;
  align-items: center;
  justify-content: center;
  box-sizing: border-box;
  width: 42px;
  height: 42px;
  padding: 0;
  border: 1px solid var(--line, #cbd5e1);
  border-radius: 50%;
  background: var(--surface, #fff);
  color: var(--ink, #1e293b);
  list-style: none;
  cursor: pointer;
}

.pnc-theme-picker > summary::-webkit-details-marker {
  display: none;
}

.pnc-theme-picker > summary::marker {
  content: "";
}

.pnc-theme-picker > summary:focus-visible,
.pnc-theme-picker .pnc-theme-option:focus-visible {
  outline: 3px solid var(--amber, #0752bd);
  outline-offset: 3px;
}

.pnc-theme-picker > .pnc-theme-menu {
  position: absolute;
  z-index: 100;
  top: calc(100% + 8px);
  right: 0;
  left: auto;
  box-sizing: border-box;
  width: 150px;
  padding: 8px;
  border: 1px solid var(--line, #cbd5e1);
  border-radius: 12px;
  background: var(--surface, #fff);
  box-shadow: 0 10px 30px rgb(0 0 0 / .18);
}

.pnc-theme-picker:not([open]) > .pnc-theme-menu {
  display: none;
}

.pnc-theme-picker .pnc-theme-option {
  display: block;
  width: 100%;
  min-height: 44px;
  padding: 11px 12px;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: var(--ink, #1e293b);
  font: inherit;
  font-size: 14px;
  text-align: left;
  cursor: pointer;
}

.pnc-theme-picker .pnc-theme-option:hover,
.pnc-theme-picker .pnc-theme-option[aria-pressed="true"] {
  background: var(--paper-dim, #dbeafe);
  color: var(--ink, #0752bd);
}

.pnc-theme-picker--mobile {
  display: none;
}

@media (max-width: 640px) {
  .pnc-theme-picker--mobile {
    display: inline-block;
    margin-left: auto;
  }

  .pnc-theme-picker--mobile > summary.pnc-theme-toggle {
    width: 36px;
    height: 36px;
  }
}

.pnc-theme-status {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
  border: 0;
}
