/* ============================================================
   Cheaply: CSS Reset and Base
   ============================================================ */

*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  font-size: 16px;
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
  tab-size: 4;
  height: 100%;
}

body {
  font-family: var(--font-sans);
  font-size: var(--text-base);
  line-height: var(--leading-normal);
  color: var(--color-text);
  background-color: var(--color-bg);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  min-height: 100%;
}

img,
svg,
video,
canvas,
audio,
iframe,
embed,
object {
  display: block;
  max-width: 100%;
}

img {
  height: auto;
}

input,
button,
textarea,
select {
  font: inherit;
  color: inherit;
}

button {
  cursor: pointer;
}

p,
h1,
h2,
h3,
h4,
h5,
h6 {
  overflow-wrap: break-word;
}

h1,
h2,
h3,
h4,
h5,
h6 {
  font-weight: var(--weight-semibold);
  line-height: var(--leading-tight);
  letter-spacing: var(--tracking-tight);
  color: var(--color-text);
}

a {
  color: inherit;
  text-decoration: none;
}

ul,
ol {
  list-style: none;
}

table {
  border-collapse: collapse;
}

:focus-visible {
  outline: 2px solid var(--color-border-focus);
  outline-offset: 2px;
}

/* Override browser blue focus ring on all interactive elements */
:focus {
  outline: none;
}

select {
  -webkit-appearance: none;
  -moz-appearance: none;
  appearance: none;
}

select:focus {
  outline: 2px solid var(--gray-900);
  outline-offset: 0;
}

::selection {
  background: var(--gray-900);
  color: var(--white);
}

/* Monochrome browser controls: checkbox, radio, range, progress */
:root {
  accent-color: #1a1a1a;
  color-scheme: light;
}

/* Caret cursor color in inputs */
input,
textarea {
  caret-color: #1a1a1a;
}

/* Custom checkbox and radio: remove blue, use black */
input[type="checkbox"],
input[type="radio"] {
  accent-color: #1a1a1a;
  cursor: pointer;
}

/* Range slider */
input[type="range"] {
  accent-color: #1a1a1a;
}

/* Progress element */
progress {
  accent-color: #1a1a1a;
  color: #1a1a1a;
}

/* Minimal scrollbar */
::-webkit-scrollbar {
  width: 4px;
  height: 4px;
}

::-webkit-scrollbar-track {
  background: transparent;
}

::-webkit-scrollbar-thumb {
  background: var(--gray-300);
  border-radius: 999px;
}

::-webkit-scrollbar-thumb:hover {
  background: var(--gray-400);
}

.scrollbar-none::-webkit-scrollbar {
  display: none;
}

.scrollbar-none {
  scrollbar-width: none;
}

svg {
  flex-shrink: 0;
}