@font-face {
  font-family: "Remnant UI";
  font-style: normal;
  font-weight: 200 800;
  font-display: swap;
  src: url("/assets/fonts/oxanium.woff2") format("woff2");
}

@font-face {
  font-family: "Remnant Mono";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("/assets/fonts/share-tech-mono.woff2") format("woff2");
}

:root {
  color-scheme: dark;

  --starsector-font-ui: "Remnant UI", system-ui, -apple-system, "Segoe UI", sans-serif;
  --starsector-font-mono: "Remnant Mono", ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", monospace;
  --starsector-page: #04080d;
  --starsector-surface: rgb(6 10 16 / 64%);
  --starsector-surface-raised: #0f2430;
  --starsector-edge: rgb(0 104 128 / 62%);
  --starsector-edge-strong: rgb(68 152 176 / 86%);
  --starsector-edge-inset: rgb(0 0 0 / 86%);
  --starsector-text: #d7e8f7;
  --starsector-muted: #9fb4ca;
  --starsector-weak: #8da3ba;
  --starsector-hot: #9fd7ea;
  --starsector-title-edge: #d98937;
  --starsector-glow: 0 0 18px rgb(28 152 252 / 16%);
  --starsector-inset: 0 0 0 1px var(--starsector-edge-inset) inset;

  --starsector-control-bg: rgb(4 12 18 / 82%);
  --starsector-control-raised: rgb(8 24 34 / 96%);
  --starsector-control-edge: rgb(68 152 176 / 36%);
  --starsector-control-edge-strong: rgb(122 215 238 / 72%);
  --starsector-control-range: rgb(5 18 26 / 94%);
  --starsector-control-check: rgb(5 14 20 / 94%);
  --starsector-control-check-active: rgb(8 26 36 / 96%);
  --starsector-control-shadow: 0 0 0 1px rgb(0 0 0 / 42%) inset, 0 12px 24px rgb(0 0 0 / 22%);
  --starsector-select-arrow: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='6' viewBox='0 0 10 6'%3E%3Cpath fill='%239fd7ea' d='M1 1h8L5 5z'/%3E%3C/svg%3E");

  /* Compact names are the contract consumed by the art projects. */
  --page: var(--starsector-page);
  --surface: var(--starsector-surface);
  --raised: var(--starsector-surface-raised);
  --edge: var(--starsector-edge);
  --edge-strong: var(--starsector-edge-strong);
  --text: var(--starsector-text);
  --muted: var(--starsector-muted);
  --hot: var(--starsector-hot);
}

html,
body {
  background: var(--starsector-page);
  font-family: var(--starsector-font-ui);
}

body {
  color: var(--starsector-text);
}

a {
  color: var(--starsector-hot);
}

code,
kbd,
output,
pre,
samp,
tt,
.starsector-mono {
  font-family: var(--starsector-font-mono);
}

.starsector-surface {
  border: 1px solid var(--starsector-edge);
  border-radius: 0;
  background: var(--starsector-surface);
  box-shadow: var(--starsector-inset);
}

.starsector-surface-elevated {
  border: 1px solid var(--starsector-edge-strong);
  border-radius: 0;
  background: var(--starsector-surface-raised);
  box-shadow: var(--starsector-inset), var(--starsector-glow);
}

* {
  scrollbar-width: thin;
  scrollbar-color: rgb(44 114 136 / 94%) rgb(3 10 15 / 75%);
}

*::-webkit-scrollbar {
  width: 10px;
  height: 10px;
}

*::-webkit-scrollbar-track {
  background: rgb(3 10 15 / 75%);
}

*::-webkit-scrollbar-thumb {
  border: 1px solid rgb(0 0 0 / 65%);
  background: linear-gradient(180deg, rgb(68 152 176 / 90%), rgb(22 82 106 / 95%));
}

button,
input,
select,
textarea {
  color: inherit;
  font: inherit;
}

:where(button, input[type="button"], input[type="submit"], input[type="reset"], select, input[type="number"], input[type="search"], input[type="text"], input[type="email"], input[type="password"], textarea) {
  min-height: 1.9rem;
  border: 1px solid var(--starsector-control-edge);
  border-radius: 0;
  background: var(--starsector-control-bg);
  box-shadow: var(--starsector-control-shadow);
}

:where(select, input[type="number"], input[type="search"], input[type="text"], input[type="email"], input[type="password"], textarea) {
  width: 100%;
  padding: 0.24rem 0.5rem;
}

select {
  appearance: none;
  padding-right: 1.85rem;
  background-image: var(--starsector-select-arrow);
  background-position: calc(100% - 0.62rem) 50%;
  background-size: 0.58rem 0.34rem;
  background-repeat: no-repeat;
}

:where(button, input[type="button"], input[type="submit"], input[type="reset"]) {
  padding: 0.24rem 0.62rem;
  color: var(--starsector-hot);
  background: var(--starsector-control-raised);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  cursor: pointer;
}

:where(button, input[type="button"], input[type="submit"], input[type="reset"]):hover {
  border-color: var(--starsector-control-edge-strong);
}

:where(button, input[type="button"], input[type="submit"], input[type="reset"]):active {
  color: var(--starsector-page);
  background: var(--starsector-hot);
}

:where(button, input, select, textarea):focus-visible {
  border-color: var(--starsector-control-edge-strong);
  outline: 1px solid var(--starsector-control-edge-strong);
  outline-offset: 1px;
}

:where(button, input[type="button"], input[type="submit"], input[type="reset"]):disabled {
  color: var(--starsector-muted);
  cursor: not-allowed;
}

input[type="color"] {
  width: 100%;
  min-height: 31px;
  padding: 2px;
  border: 1px solid var(--starsector-control-edge);
  border-radius: 0;
  background: var(--starsector-control-bg);
  cursor: pointer;
}

input[type="range"] {
  appearance: none;
  width: 100%;
  height: 0.56rem;
  padding: 0;
  border: 1px solid var(--starsector-control-edge);
  background: var(--starsector-control-range);
  cursor: ew-resize;
  touch-action: none;
}

input[type="range"]::-webkit-slider-thumb {
  appearance: none;
  width: 0.58rem;
  height: 0.95rem;
  border: 1px solid #0b1a25;
  background: var(--starsector-hot);
  box-shadow: 0 0 0 1px rgb(0 0 0 / 45%) inset;
  cursor: ew-resize;
}

input[type="range"]::-moz-range-thumb {
  width: 0.58rem;
  height: 0.95rem;
  border: 1px solid #0b1a25;
  border-radius: 0;
  background: var(--starsector-hot);
  cursor: ew-resize;
}

input[type="range"]::-moz-range-track {
  height: 0.56rem;
  border: 1px solid var(--starsector-control-edge);
  border-radius: 0;
  background: var(--starsector-control-range);
}

input[type="checkbox"] {
  appearance: none;
  display: grid;
  width: 1.03rem;
  height: 1.03rem;
  margin: 0;
  border: 1px solid var(--starsector-control-edge);
  background: var(--starsector-control-check);
  place-content: center;
}

input[type="checkbox"]::before {
  width: 0.58rem;
  height: 0.58rem;
  transform: scale(0);
  background: var(--starsector-hot);
  clip-path: polygon(14% 53%, 28% 67%, 74% 21%, 84% 31%, 28% 87%, 4% 63%);
  content: "";
  transition: transform 120ms ease-out;
}

input[type="checkbox"]:checked {
  border-color: var(--starsector-edge-strong);
  background: var(--starsector-control-check-active);
}

input[type="checkbox"]:checked::before {
  transform: scale(1);
}
