:where(:root) {
  --at-ink: #141412;
  --at-paper: #ece9e2;
  --at-chartreuse: #d4f34a;
  --at-font-mono: "JetBrains Mono", ui-monospace, "Cascadia Mono", monospace;
  --at-dur-fast: 0.18s;
  --at-ease-out: cubic-bezier(0.2, 0.7, 0.2, 1);
}

.atlas-thread {
  position: fixed;
  inset: auto auto 16px 16px;
  z-index: 2147483000;
  display: inline-flex;
  align-items: center;
  gap: 0.7em;
  max-width: calc(100vw - 32px);
  padding: 9px 13px;
  border: 1px solid rgb(236 233 226 / 0.16);
  border-radius: 2px;
  color: var(--at-paper);
  background: var(--at-ink);
  font-family: var(--at-font-mono);
  font-size: 11px;
  font-weight: 400;
  letter-spacing: 0.18em;
  line-height: 1;
  text-decoration: none;
  text-transform: uppercase;
  white-space: nowrap;
  box-shadow: 0 10px 28px rgb(0 0 0 / 0.22);
  transition:
    border-color var(--at-dur-fast) var(--at-ease-out),
    transform var(--at-dur-fast) var(--at-ease-out);
}

.atlas-thread[data-position="right"] {
  inset: auto 16px 16px auto;
}

.atlas-thread__mark {
  width: 8px;
  height: 8px;
  flex: none;
  background: var(--at-chartreuse);
}

.atlas-thread__sep {
  color: rgb(236 233 226 / 0.35);
}

.atlas-thread__name,
.atlas-thread__arrow {
  color: rgb(236 233 226 / 0.65);
  transition: color var(--at-dur-fast) var(--at-ease-out);
}

.atlas-thread:hover {
  border-color: rgb(212 243 74 / 0.55);
  transform: translateY(-1px);
}

.atlas-thread:hover .atlas-thread__name,
.atlas-thread:hover .atlas-thread__arrow {
  color: var(--at-chartreuse);
}

.atlas-thread:focus-visible {
  outline: 2px solid var(--at-chartreuse);
  outline-offset: 2px;
}

@media (max-width: 420px) {
  .atlas-thread[data-position="right"] {
    inset: auto 12px 12px auto;
  }

  .atlas-thread {
    padding-inline: 11px;
    letter-spacing: 0.13em;
  }
}

@media (prefers-reduced-motion: reduce) {
  .atlas-thread,
  .atlas-thread__name,
  .atlas-thread__arrow {
    transition: none;
  }

  .atlas-thread:hover {
    transform: none;
  }
}

@media print {
  .atlas-thread {
    display: none;
  }
}
