:root {
  --face: #bfbfbf;
  --hi: #dbdbdb;
  --shade: #808080;
  --title: linear-gradient(90deg, #00007b, #1085d2);
  --raised: inset -1px -1px #000, inset 1px 1px #fff, inset -2px -2px var(--shade), inset 2px 2px var(--hi);
  --window: inset -1px -1px #000, inset 1px 1px var(--hi), inset -2px -2px var(--shade), inset 2px 2px #fff;
  --sunken: inset -1px -1px #fff, inset 1px 1px var(--shade), inset -2px -2px var(--hi), inset 2px 2px #000;
  --pressed: inset -1px -1px #fff, inset 1px 1px #000, inset -2px -2px var(--hi), inset 2px 2px var(--shade);
  --thin: inset -1px -1px #fff, inset 1px 1px var(--shade);

  --ground: #008080;
  --surface: var(--face);
  --surface-2: var(--face);
  --surface-3: var(--hi);
  --ink: #000;
  --ink-2: #1a1a1a;
  --ink-3: #404040;
  --line: var(--shade);
  --line-2: var(--shade);
  --accent: #000080;
  --accent-soft: #fff;
  --ok: #006000;
  --ok-soft: #fff;
  --warn: #7a5200;
  --warn-soft: #ffffe1;
  --warn-bar: #000080;
  --fail: #a00000;
  --fail-soft: #fff;
  --field: #fff;
  --on-solid: #fff;
  --ok-line: var(--shade);
  --fail-line: var(--shade);
  --sans: Tahoma, "MS Sans Serif", "Microsoft Sans Serif", Geneva, Verdana, sans-serif;
  --display: var(--sans);
  --mono: "Courier New", Courier, monospace;
  --r: 0;
  --shadow: none;
  --shadow-lift: 2px 2px 0 rgba(0, 0, 0, 0.45);
}

*,
*::before,
*::after {
  border-radius: 0 !important;
}

body {
  font-size: 13px;
  line-height: 1.4;
}
h1,
.stat-n {
  font-weight: 700;
  letter-spacing: 0;
}
h2 {
  letter-spacing: 0;
  text-transform: none;
  font-size: 13px;
  color: var(--ink);
}
:focus-visible {
  outline: 1px dotted #000;
  outline-offset: -4px;
}
.control:focus-visible,
.price:focus-within,
.override input:focus-visible {
  outline: none;
}
::selection {
  background: var(--accent);
  color: #fff;
}

.page {
  color: #fff;
}
.page a:not([class]) {
  color: #fff;
}

.card,
.filters,
.stat,
.empty,
.notice,
.run,
.auth-card,
.scan-list,
.bulk-result,
.record,
.guide-step,
.tour-card,
.menu-panel,
.combo-list,
.scan-dialog-in,
.kv,
.guide-progress {
  color: var(--ink);
  background: var(--face);
  border: none;
  box-shadow: var(--window);
}
.card a:not([class]),
.empty a:not([class]),
.notice a:not([class]),
.run a:not([class]),
.auth-card a:not([class]) {
  color: var(--accent);
}
.bulk-result {
  border-left: none;
}
.record {
  padding: 3px;
}
.page-link.current {
  color: #000;
}
.stat:hover,
.record:hover {
  transform: none;
  box-shadow: var(--window);
}
.stat:active,
.record:active {
  box-shadow: var(--pressed);
}

.masthead {
  background: var(--title);
  border-bottom: none;
  box-shadow: inset 0 -1px #000080;
}
.masthead-in {
  padding: 10px 14px;
}
.masthead .logo {
  height: 30px;
}
.masthead-title {
  color: #fff;
  font-weight: 700;
  font-size: 16px;
  letter-spacing: 0;
  border-left-color: rgba(255, 255, 255, 0.35);
}
.masthead-link,
.menu[open] > summary {
  color: #000;
  background: var(--face);
  border: none;
  box-shadow: var(--raised);
}
.masthead-link:hover,
.masthead-link[aria-current="page"] {
  color: #000;
  background: var(--face);
}
.menu[open] > summary {
  box-shadow: var(--pressed);
}
.masthead-link.icon-only {
  width: 38px;
  height: 32px;
}
.masthead-link.icon-only svg {
  width: 22px;
  height: 22px;
}
.menu-panel {
  min-width: 250px;
}
.menu-item {
  font-size: 14px;
}

.menu-panel {
  top: calc(100% + 4px);
  padding: 3px;
  box-shadow: var(--window), var(--shadow-lift);
  animation: none;
}
.menu-head {
  border-bottom: 1px solid var(--shade);
  box-shadow: 0 1px #fff;
  color: var(--ink);
}
.menu-head b {
  font-weight: 700;
}
.menu-item {
  padding: 5px 22px;
}
.menu-item .i,
.menu-item:hover .i {
  color: inherit;
}
.menu-item:hover,
.menu-item[aria-current="page"],
.menu-item.danger:hover,
.menu-item.danger:hover .i,
a.menu-head:hover {
  background: var(--accent);
  color: #fff;
  font-weight: 400;
}
.menu-sep {
  height: 2px;
  background: var(--shade);
  box-shadow: 0 1px #fff;
}

.btn,
.ibtn,
.seg-btn,
.vt,
.page-link,
.to-top,
.dialog-close,
.tour-x,
.listen-icon {
  color: #000;
  background: var(--face);
  border: none;
  box-shadow: var(--raised);
  font-weight: 400;
  transition: none;
}
.btn {
  min-height: 26px;
  padding: 4px 14px;
}
.btn:hover,
.ibtn:hover,
.seg-btn:hover,
.vt:hover,
.page-link:hover,
.to-top:hover,
.dialog-close:hover,
.tour-x:hover {
  background: var(--face);
  border: none;
}
.btn:active,
.ibtn:active,
.seg-btn:active,
.vt:active,
.page-link:active,
.to-top:active,
.dialog-close:active,
.tour-x:active,
.seg-btn[aria-pressed="true"],
.seg-btn[aria-current],
.seg-btn.on,
.vt[aria-pressed="true"],
.vt.on,
.page-link.current {
  box-shadow: var(--pressed);
  background: var(--face);
}
.btn.primary {
  color: #000;
  background: var(--face);
  box-shadow: 0 0 0 1px #000, var(--raised);
}
.btn.primary:hover {
  filter: none;
}
.btn.tone {
  background: var(--face);
}
.btn:disabled,
.ibtn:disabled {
  opacity: 1;
  color: var(--shade);
  text-shadow: 1px 1px #fff;
}
.listen-icon {
  box-shadow: none;
  background: none;
}
.listen-icon:active {
  box-shadow: var(--pressed);
}

.control,
.override input,
.price {
  background-color: var(--field);
  border: none;
  box-shadow: var(--sunken);
}
.control:hover,
.price:hover {
  border: none;
}
.chip {
  border: none;
  background: none;
  color: var(--ink);
}
.filters select.control.active,
.chip:has(input:checked),
.price:has(input:not(:placeholder-shown)) {
  background-color: var(--field);
  color: var(--ink);
}
select.control {
  padding-right: 26px;
  background-image:
    linear-gradient(45deg, transparent 50%, #000 50%),
    linear-gradient(135deg, #000 50%, transparent 50%),
    linear-gradient(var(--face), var(--face));
  background-position:
    calc(100% - 13px) 50%,
    calc(100% - 9px) 50%,
    calc(100% - 2px) 50%;
  background-size:
    4px 4px,
    4px 4px,
    18px calc(100% - 4px);
  box-shadow: var(--sunken), inset -19px 0 0 -17px var(--hi);
}
input[type="checkbox"],
input[type="radio"] {
  accent-color: var(--accent);
}
.reset,
.sel-clear {
  color: #fff;
}
.filters .reset {
  color: var(--accent);
}

.table-wrap {
  color: var(--ink);
  background: var(--field);
  border: none;
  box-shadow: var(--sunken);
  padding: 2px;
}
.albums th {
  color: #000;
  background: var(--face);
  box-shadow: var(--raised);
  font-size: 12px;
  font-weight: 400;
  letter-spacing: 0;
  text-transform: none;
  padding: 4px 10px;
  border-bottom: none;
}
@media (min-width: 761px) {
  .albums td {
    border-bottom: 1px solid #e6e6e6;
  }
}
.row:has(.sel:checked) td {
  background: var(--accent);
  color: #fff;
}
.row:has(.sel:checked) td a,
.row:has(.sel:checked) td .meta {
  color: #fff;
}

.pill {
  background: var(--face) !important;
  border: none !important;
  box-shadow: inset 1px 1px var(--shade), inset -1px -1px #fff, inset 2px 2px var(--hi);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0;
  padding: 3px 8px;
}
.pill.wanted {
  color: var(--ok);
}
.pill.approved {
  color: var(--accent);
}

.bar {
  height: 18px;
  background: var(--field);
  box-shadow: var(--sunken);
  padding: 3px;
}
.bar span {
  background: repeating-linear-gradient(90deg, var(--accent) 0 8px, transparent 8px 10px);
}

.tour-hole {
  box-shadow: 0 0 0 9999px rgba(0, 0, 0, 0.45), 0 0 0 2px #fff;
}

@media (max-width: 760px) {
  .filters {
    top: 61px;
  }
  .filters::before {
    left: -16px;
    right: -16px;
    top: -9px;
  }
}

@media (max-width: 760px) {
  .page.dash {
    justify-content: flex-start;
    padding-top: 16px;
    padding-bottom: 16px;
  }
  .page.dash #status {
    flex: 1;
    display: flex;
    flex-direction: column;
  }
  .page.dash .stats {
    flex: 1;
    grid-template-columns: minmax(0, 1fr);
    grid-auto-rows: 1fr;
    gap: 8px;
  }
  .page.dash .stat {
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
    padding: 12px 16px;
  }
  .page.dash .stat:nth-child(4) {
    margin-top: 10px;
  }
  .page.dash .stat-label {
    order: -1;
    font-size: clamp(14px, 2.2vh, 18px);
  }
  .page.dash .stat-n {
    font-size: clamp(26px, 6vh, 48px);
    line-height: 1;
  }
}

body {
  padding-bottom: 40px;
}
.taskbar {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 60;
  display: flex;
  align-items: center;
  gap: 4px;
  height: 40px;
  padding: 4px;
  color: #000;
  background: var(--face);
  box-shadow: inset 0 1px var(--hi), inset 0 2px #fff;
}
.start {
  position: relative;
  height: 100%;
}
.start > summary {
  list-style: none;
}
.start > summary::-webkit-details-marker {
  display: none;
}
.start-btn {
  display: flex;
  align-items: center;
  height: 100%;
  padding: 0 12px;
  cursor: pointer;
  background: var(--face);
  box-shadow: var(--raised);
}
.start[open] > .start-btn {
  box-shadow: var(--pressed);
}
.start-logo {
  display: block;
  height: 15px;
  width: auto;
  filter: invert(1);
}
.start-menu.menu-panel {
  position: absolute;
  top: auto;
  right: auto;
  left: -2px;
  bottom: calc(100% + 4px);
  flex-direction: row;
  min-width: 260px;
  padding: 3px;
}
.start-stripe {
  display: flex;
  align-items: center;
  gap: 4px;
  width: 30px;
  padding: 10px 0;
  writing-mode: vertical-rl;
  transform: rotate(180deg);
  color: #fff;
  background: linear-gradient(0deg, #00007b, #1085d2);
  font-size: 20px;
  line-height: 30px;
  letter-spacing: 0.02em;
}
.start-stripe b {
  font-weight: 700;
}
.start-body {
  flex: 1;
  display: flex;
  flex-direction: column;
  padding: 2px 0 2px 2px;
}
.start-body .menu-item {
  gap: 12px;
  padding: 8px 16px 8px 10px;
  font-size: 14px;
}
.start-body .menu-item .i {
  width: 22px;
  height: 22px;
}
.task {
  display: flex;
  align-items: center;
  height: 100%;
  min-width: 0;
  max-width: 200px;
  flex: 0 1 200px;
  padding: 0 10px;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
  font-weight: 700;
  background: repeating-conic-gradient(var(--face) 0 25%, #fff 0 50%) 0 0 / 2px 2px;
  box-shadow: var(--pressed);
}
.tray {
  display: flex;
  align-items: center;
  height: 100%;
  margin-left: auto;
  padding: 0 10px;
  font-size: 12px;
  box-shadow: var(--thin);
}
.results-foot {
  bottom: 40px;
}
.to-top {
  bottom: 60px;
}
:root:has(.results-foot) .to-top {
  bottom: 124px;
}
@media (max-width: 760px) {
  .to-top,
  :root:has(.results-foot) .to-top {
    bottom: 56px;
  }
}

.confirm {
  width: min(380px, calc(100% - 32px));
  padding: 3px;
  border: none;
  color: var(--ink);
  background: var(--face);
  box-shadow: var(--window), var(--shadow-lift);
}
.confirm::backdrop {
  background: rgba(0, 0, 0, 0.25);
}
.confirm-title {
  padding: 3px 6px;
  color: #fff;
  font-weight: 700;
  background: var(--title);
}
.confirm-text {
  margin: 0;
  padding: 18px 16px;
}
.confirm-actions {
  display: flex;
  justify-content: center;
  gap: 8px;
  padding: 0 16px 14px;
}
.confirm-actions .btn {
  min-width: 80px;
  justify-content: center;
}
.confirm .btn:focus-visible {
  outline: none;
}

.working {
  display: flex;
  width: 100%;
  height: auto;
  gap: 12px;
  padding: 6px 10px;
  color: var(--ink);
  background: var(--face);
  box-shadow: var(--window);
}
.spinner {
  position: relative;
  display: inline-block;
  flex: 1;
  min-width: 80px;
  height: 18px;
  overflow: hidden;
  border: none;
  vertical-align: middle;
  background: var(--field);
  box-shadow: var(--thin);
  animation: none;
}
.spinner::before {
  content: "";
  position: absolute;
  top: 3px;
  bottom: 3px;
  left: 0;
  width: 50px;
  background: repeating-linear-gradient(90deg, var(--accent) 0 8px, transparent 8px 10px);
  animation: win98-march 5s linear infinite;
  animation-delay: var(--march, 0s);
}
.spinner.inline {
  flex: none;
  width: 80px;
  height: 14px;
  margin-right: 6px;
}
@keyframes win98-march {
  from {
    left: -50px;
  }
  to {
    left: 100%;
  }
}

.combo {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
  margin-left: auto;
  padding: 5px 10px;
  color: #000;
  font-size: 13px;
  text-decoration: none;
  background: #ffffe1;
  box-shadow: var(--raised);
}
.combo:active {
  box-shadow: var(--pressed);
}
.combo .i {
  flex: none;
  width: 18px;
  height: 18px;
  fill: currentColor;
}
.combo-name {
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}
.combo b {
  flex: none;
}
@media (max-width: 760px) {
  .combo-name {
    display: none;
  }
}
