:root {
  color-scheme: light dark;
  --bg: #ffffff;
  --fg: #18181b;
  --muted: #52525b;
  --muted-2: #a1a1aa;
  --line: #f4f4f5;
  --line-dark: #27272a;
  --bg-dark: #09090b;
  --fg-dark: #fafafa;
  --muted-dark: #a1a1aa;
  --muted-2-dark: #52525b;
  --max: 42rem;
}

* {
  box-sizing: border-box;
}

html {
  font-size: 16px;
}

body {
  margin: 0;
  min-height: 100vh;
  background: var(--bg);
  color: var(--fg);
  font-family: "Courier New", Courier, monospace;
}

@media (prefers-color-scheme: dark) {
  body {
    background: var(--bg-dark);
    color: var(--fg-dark);
  }
}

main {
  display: block;
}

a {
  color: inherit;
}

.site-shell {
  width: min(100% - 3rem, var(--max));
  margin: 0 auto;
  padding: 2.5rem 1.5rem 3.5rem;
}

.site-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
  margin-bottom: 3.5rem;
}

.brand-mark {
  display: inline-grid;
  place-items: center;
  width: 2.4rem;
  height: 2.4rem;
  color: var(--fg);
}

@media (prefers-color-scheme: dark) {
  .brand-mark {
    color: var(--fg-dark);
  }
}

.synthetic-beacon {
  display: inline-grid;
  place-items: center;
  width: 100%;
  height: 100%;
}

.beacon-svg {
  width: 100%;
  height: 100%;
  overflow: visible;
}

.beacon-svg .micro-square,
.beacon-svg .mid-square,
.beacon-svg .ring,
.beacon-svg .core {
  transform-box: fill-box;
  transform-origin: center;
}

.beacon-svg .micro-square {
  fill: #a1a1aa;
}

.beacon-svg .mid-square {
  fill: #52525b;
}

.beacon-svg .ring {
  fill: none;
  stroke: #a1a1aa;
  stroke-width: 2.5;
  opacity: 0.8;
}

.beacon-svg .core {
  fill: #18181b;
}

@media (prefers-color-scheme: dark) {
  .beacon-svg .micro-square {
    fill: #71717a;
  }

  .beacon-svg .mid-square {
    fill: #d4d4d8;
  }

  .beacon-svg .ring {
    stroke: #71717a;
  }

  .beacon-svg .core {
    fill: #fafafa;
  }
}

.site-nav {
  display: flex;
  align-items: center;
  gap: 1.5rem;
  flex-wrap: wrap;
  font-size: 0.875rem;
}

.page-stack {
  display: grid;
  gap: 3.5rem;
}

.page-header {
  display: grid;
  gap: 1.25rem;
}

.page-title {
  margin: 0;
  font-size: 1.125rem;
  font-weight: 500;
  line-height: 1.4;
}

.body-copy {
  color: var(--muted);
  line-height: 1.7;
}

.body-copy p,
.body-copy ul,
.body-copy li {
  margin: 0;
}

.body-copy.stack-4 {
  gap: 1rem;
}

.stack-4 {
  display: grid;
  gap: 1rem;
}

.stack-2 {
  display: grid;
  gap: 0.5rem;
}

.stack-4-list,
.stack-6-list {
  list-style: none;
  padding: 0;
  margin: 0;
}

.stack-4-list {
  display: grid;
  gap: 1rem;
}

.stack-6-list {
  display: grid;
  gap: 1.5rem;
}

.section-title {
  margin: 0 0 0.75rem;
  font-size: 0.875rem;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  text-decoration: underline;
  text-underline-offset: 4px;
}

.terminal-link {
  display: inline-block;
  color: inherit;
  text-decoration: none;
}

.terminal-link:hover,
.terminal-link:focus-visible {
  background: #18181b;
  color: #ffffff;
  transform: translateX(1px);
  outline: none;
}

@media (prefers-color-scheme: dark) {
  .body-copy {
    color: var(--muted-dark);
  }

  .terminal-link:hover,
  .terminal-link:focus-visible {
    background: #fafafa;
    color: #09090b;
  }
}

.terminal-link--underlined {
  text-decoration: underline;
  text-decoration-color: #a1a1aa;
  text-underline-offset: 2px;
}

@media (prefers-color-scheme: dark) {
  .terminal-link--underlined {
    text-decoration-color: #52525b;
  }
}

.nav-link {
  padding: 0 0.25rem;
  color: #52525b;
}

.nav-link[aria-current="page"] {
  color: var(--fg);
  text-decoration: underline;
  text-underline-offset: 4px;
}

@media (prefers-color-scheme: dark) {
  .nav-link {
    color: #a1a1aa;
  }

  .nav-link[aria-current="page"] {
    color: var(--fg-dark);
  }
}

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

.meta-left {
  display: flex;
  align-items: baseline;
  gap: 0.5rem;
  min-width: 0;
}

.year,
.period {
  flex-shrink: 0;
  font-size: 0.875rem;
  color: var(--muted-2);
}

.item-copy {
  margin-top: 0.125rem;
  font-size: 0.875rem;
  line-height: 1.7;
  color: var(--muted);
}

.item-title,
.role {
  font-weight: 500;
}

.company {
  color: var(--muted);
}

.badge {
  font-size: 0.75rem;
  color: #16a34a;
}

.site-footer {
  margin-top: 4rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--line);
  font-size: 0.875rem;
  color: var(--muted-2);
}

@media (prefers-color-scheme: dark) {
  .year,
  .period,
  .site-footer {
    color: var(--muted-2-dark);
  }

  .item-copy,
  .company {
    color: var(--muted-dark);
  }

  .site-footer {
    border-top-color: var(--line-dark);
  }
}

@media (max-width: 640px) {
  .site-shell {
    width: min(100% - 1.5rem, var(--max));
    padding: 1.5rem 0.75rem 2.5rem;
  }

  .site-header,
  .meta-row {
    align-items: flex-start;
    flex-direction: column;
  }
}
