:root {
  color-scheme: dark;
  --bg: #191919;
  --text: #edf1f6;
  --muted: #b5becc;
  --soft: #8792a1;
  --line: rgba(215, 223, 234, 0.16);
  --line-strong: rgba(215, 223, 234, 0.3);
  --link: #f7f9fc;
  --layout-width: 75rem;
  --content-width: 42rem;
  --sidebar-width: 12rem;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  background: var(--bg);
  color: var(--text);
  font-family: "Noto Sans Mono", ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 15px;
  line-height: 1.82;
  font-weight: 500;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
}

::selection {
  background: rgba(237, 241, 246, 0.14);
  color: var(--text);
}

a {
  color: var(--link);
  text-decoration-color: rgba(247, 249, 252, 0.3);
  text-underline-offset: 0.2rem;
}

a:hover {
  color: var(--text);
  text-decoration-color: currentColor;
}

.site-shell {
  width: min(calc(100% - 2rem), var(--layout-width));
  margin: 0 auto;
  padding: 2.25rem 0 4rem;
  display: grid;
  grid-template-columns: minmax(10rem, var(--sidebar-width)) minmax(0, 1fr);
  gap: 3.5rem;
}

.sidebar {
  padding-top: 4.8rem;
}

.sidebar__inner {
  position: sticky;
  top: 2rem;
}

.sidebar__label {
  margin: 0 0 1rem;
  color: var(--soft);
  font-size: 0.78rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.sidebar__top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1rem;
}

.sidebar__top .sidebar__label {
  margin: 0;
}

.sidebar__nav {
  display: grid;
  gap: 0.45rem;
}

.sidebar__nav a {
  color: var(--muted);
  text-decoration: none;
  font-size: 0.9rem;
  padding-left: 0.75rem;
  border-left: 1px solid transparent;
}

.sidebar__nav a.nav-subitem {
  margin-left: 1rem;
  font-size: 0.84rem;
}

.sidebar__nav a:hover,
.sidebar__nav a.is-active {
  color: var(--text);
  border-left-color: var(--line-strong);
}

.main {
  width: 100%;
}

.content {
  max-width: var(--content-width);
  margin: 0 auto;
}

.status-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  margin-bottom: 2.4rem;
  color: var(--soft);
  font-size: 0.8rem;
}

.status-bar__slot {
  display: inline-flex;
  align-items: center;
  min-height: 1.2rem;
}

.status-bar__slot--right {
  justify-content: flex-end;
}

.lang-switch {
  display: inline-flex;
  align-items: center;
  gap: 0.2rem;
  color: var(--soft);
  font-size: 0.78rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.lang-switch button {
  appearance: none;
  background: none;
  border: 0;
  padding: 0.1rem 0.2rem;
  margin: 0;
  color: inherit;
  font: inherit;
  text-transform: inherit;
  letter-spacing: inherit;
  cursor: pointer;
}

.lang-switch button.is-active {
  color: var(--text);
}

.lang-switch__sep {
  color: var(--line-strong);
}

.lang-switch__group {
  display: inline-flex;
  align-items: center;
  gap: 0.2rem;
}

.troll-switch {
  display: inline-flex;
  align-items: center;
  gap: 0.2rem;
}

.troll-switch__label {
  color: var(--soft);
}

.troll-switch button {
  appearance: none;
  background: none;
  border: 0;
  padding: 0.1rem 0.2rem;
  margin: 0;
  color: inherit;
  font: inherit;
  text-transform: inherit;
  letter-spacing: inherit;
  cursor: pointer;
}

.troll-switch button.is-active {
  color: var(--text);
}

#troll-cursor {
  position: fixed;
  z-index: 10000;
  left: 0;
  top: 0;
  width: 64px;
  height: 64px;
  pointer-events: none;
  background: url('./public/cursor/cursor.png') no-repeat center / contain;
  transform: translate(-8px, -8px);
  will-change: transform, background-image;
  image-rendering: -webkit-optimize-contrast;
  image-rendering: crisp-edges;
  display: none;
}

html.troll-mode-on,
html.troll-mode-on body,
html.troll-mode-on a,
html.troll-mode-on button,
html.troll-mode-on input,
html.troll-mode-on textarea,
html.troll-mode-on select {
  cursor: none !important;
}

html.troll-mode-on #troll-cursor {
  display: block;
}

html.troll-mode-on.is-pointer #troll-cursor {
  background-image: url('./public/cursor/pointer.png');
}

.lang-switch--mobile {
  display: none;
}

.hero {
  margin-bottom: 2.4rem;
  text-align: center;
  display: grid;
  gap: 0.55rem;
}

.avatar {
  position: relative;
  width: 6.5rem;
  height: 6.5rem;
  margin: 0 auto 0.8rem;
  border-radius: 50%;
  overflow: hidden;
  border: 1px solid var(--line);
}

.avatar img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.avatar__model-crop {
  position: relative;
  width: 100%;
  height: 100%;
  overflow: hidden;
  pointer-events: none;
}

.avatar model-viewer {
  display: block;
  width: 396%;
  height: 484%;
  --poster-color: transparent;
  transform: translate(-34%, -52%);
  pointer-events: none;
}

.eyebrow {
  margin: 0;
  color: var(--soft);
  font-size: 0.8rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

h1,
h2,
h3 {
  margin: 0;
  font-weight: 650;
}

h1 {
  font-size: clamp(2rem, 4.4vw, 2.6rem);
  line-height: 1.28;
}

h2 {
  font-size: 1.02rem;
}

h3 {
  font-size: 0.95rem;
}

p,
li,
dd,
dt,
td,
th {
  margin: 0;
}

.subtitle {
  color: var(--soft);
}

.subtitle:empty,
.lede:empty {
  display: none;
}

.lede,
.body-copy,
.note,
.footer {
  display: grid;
  gap: 0.85rem;
}

.section {
  margin-top: 1.55rem;
  padding-top: 1.25rem;
  display: grid;
  gap: 0.9rem;
}

.section-head {
  display: grid;
  grid-template-columns: 3rem minmax(0, 1fr);
  gap: 0.75rem;
  align-items: baseline;
}

.section-id {
  color: var(--soft);
}

.link-list,
.text-list,
.record-list {
  display: grid;
  gap: 0.55rem;
}

.link-list {
  margin-top: 0.15rem;
}

.link-row {
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 0.75rem;
  align-items: baseline;
  text-decoration: none;
}

.link-row:hover .link-row__meta {
  color: var(--text);
}

.link-row__dots {
  border-bottom: 1px dotted var(--line-strong);
  transform: translateY(-0.14rem);
}

.link-row__meta {
  color: var(--soft);
  white-space: nowrap;
}

.info-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1rem 1.5rem;
}

.fact dt {
  color: var(--soft);
  margin-bottom: 0.2rem;
}

.fact dd {
  color: var(--text);
}

.record {
  padding-top: 1rem;
  border-top: 1px dotted var(--line);
  display: grid;
  gap: 0.55rem;
}

.featured-links {
  display: grid;
  gap: 1rem;
}

.easter-egg__trigger {
  background: none;
  border: 0;
  padding: 0;
  margin: 0;
  color: var(--link);
  font: inherit;
  text-align: left;
  width: 100%;
  cursor: pointer;
}

.easter-egg__trigger:hover {
  color: var(--text);
}

.featured-link {
  display: grid;
  gap: 0.55rem;
  padding-top: 1rem;
  border-top: 1px dotted var(--line);
}

.featured-link:first-child {
  padding-top: 0;
  border-top: 0;
}

.featured-link__text {
  color: var(--muted);
}

.featured-link__note {
  color: var(--soft);
  font-size: 0.92rem;
}

.record:first-child {
  padding-top: 0;
  border-top: 0;
}

.record__head {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  align-items: baseline;
}

.record__tag {
  color: var(--soft);
  font-size: 0.88rem;
  white-space: nowrap;
}

.record__meta {
  color: var(--muted);
  display: grid;
  gap: 0.2rem;
  font-size: 0.92rem;
}

.record__meta strong {
  color: var(--text);
  font-weight: 650;
}

.text-list {
  list-style: none;
  padding: 0;
  margin: 0;
}

.text-list li {
  padding-left: 1rem;
  position: relative;
}

.text-list li::before {
  content: "-";
  position: absolute;
  left: 0;
  color: var(--soft);
}

.table-wrap {
  overflow-x: auto;
}

table {
  width: 100%;
  min-width: 34rem;
  border-collapse: collapse;
}

th,
td {
  padding: 0.75rem 0.75rem 0.75rem 0;
  text-align: left;
  vertical-align: top;
}

th {
  color: var(--soft);
  font-weight: 500;
  border-bottom: 1px dotted var(--line);
}

tbody tr + tr td {
  border-top: 1px dotted var(--line);
}

.note {
  color: var(--muted);
  padding-left: 1rem;
  border-left: 2px solid var(--line);
}

.embed-frame {
  position: relative;
  width: 100%;
  padding-bottom: 56.25%;
  margin-top: 0.85rem;
  margin-bottom: 0.55rem;
}

.embed-frame iframe {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
}

.checklist {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  gap: 0.65rem;
}

.checklist li {
  position: relative;
  padding-left: 1.25rem;
  color: var(--muted);
}

.checklist li::before {
  content: "+";
  position: absolute;
  left: 0;
  color: var(--text);
}

.pricing-block {
  display: grid;
  gap: 1rem;
  text-align: center;
  justify-items: center;
}

.pricing-block__old {
  color: var(--soft);
  text-decoration: line-through;
}

.pricing-block__current {
  font-size: clamp(1.8rem, 5vw, 2.6rem);
  line-height: 1.1;
  font-weight: 700;
}

.cta-stack {
  width: 100%;
  max-width: 26rem;
  display: grid;
  gap: 0.55rem;
}

.cta-button {
  display: inline-block;
  width: 100%;
  padding: 0.9rem 1rem;
  border: 1px solid var(--line-strong);
  color: var(--text);
  text-decoration: none;
  text-align: center;
}

.cta-button:hover {
  background: rgba(237, 241, 246, 0.04);
}

.cta-caption {
  color: var(--soft);
  font-size: 0.86rem;
}

.footer {
  margin-top: 2.5rem;
  padding-top: 1rem;
  border-top: 1px solid var(--line);
  color: var(--soft);
  font-size: 0.8rem;
  text-align: center;
  justify-items: center;
  gap: 0.45rem;
}

@media (max-width: 900px) {
  .site-shell {
    width: min(calc(100% - 1.25rem), var(--layout-width));
    grid-template-columns: 1fr;
    gap: 1.5rem;
    padding: 1rem 0 3rem;
  }

  .sidebar {
    padding-top: 0;
    padding-bottom: 1rem;
    border-bottom: 1px dotted var(--line);
  }

  .sidebar__inner {
    position: static;
  }

  .sidebar__nav {
    padding-top: 0.4rem;
    border-top: 1px dotted var(--line);
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.45rem 1rem;
  }

  .info-grid {
    grid-template-columns: 1fr;
  }

  table {
    min-width: 31rem;
  }

}

@media (max-width: 640px) {
  body {
    font-size: 14px;
    line-height: 1.76;
  }

  a {
    font-weight: 600;
    text-decoration-color: rgba(237, 241, 246, 0.55);
    text-decoration-thickness: 1px;
  }

  .sidebar__nav {
    grid-template-columns: 1fr;
  }

  .status-bar {
    display: flex;
    justify-content: space-between;
    text-align: left;
  }

  .status-bar .lang-switch--desktop {
    display: none;
  }

  .lang-switch--mobile {
    display: inline-flex;
  }

  .section-head {
    grid-template-columns: 1fr;
    gap: 0.2rem;
  }

  .hero {
    text-align: center;
  }

  .avatar {
    margin-left: auto;
    margin-right: auto;
  }

  .link-row {
    color: var(--text);
  }

  .link-row span:first-child,
  .featured-link .link-row span:first-child,
  .record a,
  .body-copy a,
  .footer a {
    font-weight: 650;
    text-decoration: underline;
    text-decoration-color: rgba(237, 241, 246, 0.45);
    text-underline-offset: 0.18rem;
  }

  .link-row__meta {
    color: rgba(237, 241, 246, 0.78);
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
}
