:root {
  color-scheme: light;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI",
    sans-serif;
  font-synthesis: none;
  background: #f2efe6;
  color: #111719;
  --canvas: #f2efe6;
  --surface: #e5e6df;
  --surface-raised: #dce3e1;
  --text: #111719;
  --muted: #4d5c60;
  --rule: #899598;
  --accent: #006b7d;
  --signal: #63dce9;
  --mono: "SFMono-Regular", Consolas, "Liberation Mono", ui-monospace, monospace;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

::selection {
  background: var(--signal);
  color: var(--text);
}

html {
  background: var(--canvas);
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-width: 0;
  min-height: 100vh;
  overflow-x: hidden;
  border-top: 0.35rem solid var(--signal);
  background: var(--canvas);
  color: var(--text);
  font-size: 1rem;
  line-height: 1.6;
  text-rendering: optimizeLegibility;
}

a {
  color: inherit;
  text-decoration-color: var(--rule);
  text-decoration-thickness: 1px;
  text-underline-offset: 0.2em;
}

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

a:focus-visible {
  border-radius: 0;
  outline: 2px solid var(--accent);
  outline-offset: 4px;
}

img {
  display: block;
  max-width: 100%;
}

.shell {
  width: min(100% - 3rem, 86rem);
  margin-inline: auto;
}

.skip-link {
  position: fixed;
  z-index: 10;
  top: 0.9rem;
  left: 0.9rem;
  padding: 0.65rem 0.9rem;
  translate: 0 -190%;
  background: var(--text);
  color: var(--canvas);
  font-weight: 800;
}

.skip-link:focus {
  translate: 0;
}

.site-header {
  border-bottom: 1px solid var(--rule);
}

.header-frame {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  gap: 1rem;
  min-height: 6.75rem;
  align-items: center;
}

.brand-mark {
  display: block;
  width: 4.75rem;
  color: var(--text);
}

.brand-mark svg {
  display: block;
  width: 100%;
  height: auto;
  overflow: visible;
}

.packet-line,
.packet-shell {
  fill: none;
  stroke: currentcolor;
  stroke-width: 1.5;
  vector-effect: non-scaling-stroke;
}

.packet-line--cipher {
  stroke: var(--accent);
  stroke-dasharray: 2 2;
}

.packet-shell {
  fill: var(--canvas);
  stroke: var(--accent);
  stroke-width: 2;
}

.packet-bit {
  fill: var(--text);
}

.packet-bit--signal {
  fill: var(--signal);
}

.site-name {
  margin: 0;
  font-size: clamp(1.35rem, 2vw, 1.65rem);
  font-weight: 780;
  letter-spacing: -0.045em;
  line-height: 1;
}

.site-name a,
a.site-name {
  display: inline-flex;
  min-height: 2.75rem;
  align-items: center;
  text-decoration: none;
}

.header-register,
.section-register,
.page-register {
  margin: 0;
  color: var(--muted);
  font-family: var(--mono);
  font-size: 0.64rem;
  font-variant-numeric: tabular-nums;
  font-weight: 700;
  letter-spacing: 0.12em;
  line-height: 1.5;
  text-transform: uppercase;
}

.header-register {
  display: grid;
  justify-items: end;
}

.header-register span:first-child {
  color: var(--accent);
}

.work {
  margin-block: clamp(3.25rem, 6vw, 6rem) 6rem;
}

.section-header {
  display: grid;
  grid-template-columns: minmax(7rem, 1fr) minmax(0, 10fr);
  align-items: end;
  border-top: 1px solid var(--rule);
  padding-top: 1rem;
}

.section-register {
  display: grid;
  gap: 0.15rem;
  align-self: stretch;
  align-content: space-between;
  border-right: 1px solid var(--rule);
  padding: 0.35rem 1.25rem 1.2rem 0;
}

.section-register span:last-child {
  color: var(--accent);
}

.section-title {
  margin: 0;
  padding: 0.2rem 0 0.8rem;
  color: var(--text);
  font-size: clamp(5rem, 10vw, 9rem);
  font-weight: 820;
  letter-spacing: -0.085em;
  line-height: 0.84;
  text-transform: uppercase;
}

.section-title::first-letter {
  color: var(--accent);
}

.section-title--compact {
  font-size: clamp(4.5rem, 8vw, 7.25rem);
}

.work-list {
  position: relative;
  z-index: 1;
  border-bottom: 1px solid var(--rule);
}

.work-row {
  position: relative;
  border-top: 1px solid var(--rule);
}

.work-row:nth-child(even) {
  background: var(--surface);
}

.work-link {
  position: relative;
  display: grid;
  grid-template-columns: minmax(7rem, 1fr) minmax(0, 6fr) minmax(15rem, 4fr);
  gap: clamp(1.5rem, 3.5vw, 4rem);
  min-height: 18rem;
  align-items: center;
  padding: clamp(2rem, 4vw, 3.5rem) clamp(1rem, 2.25vw, 2rem) clamp(2rem, 4vw, 3.5rem) 0;
  color: var(--text);
  text-decoration: none;
  transition:
    background-color 160ms ease,
    color 160ms ease;
}

.work-link::after {
  position: absolute;
  top: 0;
  right: 0;
  width: 1.15rem;
  height: 1.15rem;
  border-top: 1px solid var(--accent);
  border-right: 1px solid var(--accent);
  content: "";
}

.work-link:hover {
  background: var(--text);
  color: var(--canvas);
}

.work-link:focus-visible {
  z-index: 2;
  outline: 3px solid var(--accent);
  outline-offset: -3px;
}

.work-link:hover .work-summary,
.work-link:hover .work-kind,
.work-link:hover .work-route,
.work-link:hover .packet-id {
  color: var(--canvas);
}

.work-link:hover .packet-id {
  border-color: var(--signal);
  background: var(--signal);
  color: var(--text);
}

.work-link:hover .work-route i {
  border-color: var(--signal);
  background: var(--signal);
}

.work-link:hover .external-mark {
  color: var(--signal);
}

.work-meta {
  display: grid;
  align-self: stretch;
  align-content: space-between;
  justify-items: start;
  margin: 0;
  border-right: 1px solid var(--rule);
  padding-right: 1rem;
  font-family: var(--mono);
  text-transform: uppercase;
}

.packet-id {
  display: inline-block;
  border: 1px solid var(--signal);
  padding: 0.4rem 0.5rem;
  background: var(--signal);
  color: var(--text);
  font-size: 0.7rem;
  font-variant-numeric: tabular-nums;
  font-weight: 800;
  letter-spacing: 0.06em;
  line-height: 1;
}

.work-kind,
.work-route {
  color: var(--muted);
  font-size: 0.64rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  line-height: 1.3;
}

.work-route {
  display: flex;
  align-items: center;
  gap: 0.45rem;
}

.work-route i {
  width: 0.45rem;
  height: 0.45rem;
  border: 1px solid var(--accent);
  background: var(--signal);
}

.work-copy {
  min-width: 0;
}

.work-row:not(.work-row--media) .work-copy {
  grid-column: 2 / 4;
  max-width: 68rem;
}

.work-title {
  margin: 0;
  font-size: clamp(2.65rem, 6vw, 5.6rem);
  font-weight: 760;
  letter-spacing: -0.065em;
  line-height: 0.88;
  overflow-wrap: anywhere;
}

.external-mark {
  display: inline-block;
  margin-left: 0.16em;
  color: var(--accent);
  font-family: var(--mono);
  font-size: 0.42em;
  font-weight: 500;
  translate: 0 -0.72em;
}

.work-summary {
  max-width: 52ch;
  margin-top: 1.5rem;
  color: var(--muted);
  font-size: clamp(0.96rem, 1.35vw, 1.08rem);
}

.work-summary > :first-child {
  margin-top: 0;
}

.work-summary > :last-child {
  margin-bottom: 0;
}

.work-media {
  position: relative;
  margin: 0;
  border: 1px solid var(--rule);
  background: var(--surface-raised);
}

.work-media::after {
  position: absolute;
  inset: 0.65rem;
  border: 1px solid rgb(0 107 125 / 32%);
  pointer-events: none;
  content: "";
}

.work-media img {
  width: 100%;
  height: auto;
}

.home-notes {
  margin-block: clamp(6rem, 10vw, 9rem);
}

.home-notes-body {
  display: grid;
  grid-template-columns: minmax(7rem, 1fr) minmax(0, 10fr);
  border-block: 1px solid var(--rule);
}

.home-notes-intro {
  display: grid;
  grid-column: 2;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 2rem;
  align-items: center;
  padding: clamp(1.75rem, 4vw, 3rem) 0;
}

.home-section-summary {
  max-width: 48rem;
  color: var(--muted);
  font-size: clamp(1.05rem, 1.8vw, 1.3rem);
}

.home-section-summary > :first-child {
  margin-top: 0;
}

.home-section-summary > :last-child {
  margin-bottom: 0;
}

.signal-link {
  display: inline-flex;
  min-height: 2.75rem;
  align-items: center;
  gap: 0.8rem;
  color: var(--accent);
  font-family: var(--mono);
  font-size: 0.7rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-decoration: none;
  text-transform: uppercase;
}

.signal-link span {
  display: grid;
  width: 1.65rem;
  height: 1.65rem;
  place-items: center;
  border: 1px solid var(--accent);
  background: var(--signal);
  color: var(--text);
}

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

.home-notes-body > .note-list {
  grid-column: 2;
  border-top: 1px solid var(--rule);
}

.note-list li + li {
  border-top: 1px solid var(--rule);
}

.note-row {
  display: grid;
  grid-template-columns: minmax(8rem, 1.5fr) minmax(0, 6fr) auto;
  gap: clamp(1.25rem, 3vw, 3rem);
  min-height: 7.5rem;
  align-items: center;
  padding: 1.35rem 0;
  color: var(--text);
  text-decoration: none;
  transition:
    background-color 160ms ease,
    color 160ms ease;
}

.note-row:hover {
  background: var(--text);
  color: var(--canvas);
}

.note-row time,
.note-row-copy > span {
  color: var(--muted);
}

.note-row:hover time,
.note-row:hover .note-row-copy > span {
  color: var(--canvas);
}

.note-row time {
  font-family: var(--mono);
  font-size: 0.66rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.note-row-copy {
  display: grid;
  gap: 0.3rem;
}

.note-row-copy strong {
  font-size: clamp(1.25rem, 2.2vw, 1.8rem);
  letter-spacing: -0.035em;
  line-height: 1.1;
}

.note-row-copy > span {
  font-size: 0.92rem;
}

.note-row-arrow {
  color: var(--accent);
  font-family: var(--mono);
  font-size: 1.35rem;
}

.note-row:hover .note-row-arrow {
  color: var(--signal);
}

.home-about {
  margin-block: clamp(7rem, 12vw, 11rem) 2rem;
}

.home-about-link {
  display: grid;
  grid-template-columns: minmax(7rem, 1fr) minmax(0, 10fr);
  min-height: 27rem;
  border: 1px solid var(--text);
  background: var(--text);
  color: var(--canvas);
  text-decoration: none;
  transition: background-color 160ms ease;
}

.home-about-link:hover {
  background: #172326;
  color: var(--canvas);
}

.home-about-link:focus-visible {
  outline-color: var(--accent);
  outline-offset: 4px;
}

.home-about-register {
  display: grid;
  align-content: space-between;
  margin: 0;
  border-right: 1px solid var(--muted);
  padding: 2rem 1rem 2rem 1.5rem;
  color: var(--signal);
  font-family: var(--mono);
  font-size: 0.64rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.home-about-copy {
  display: grid;
  align-content: center;
  justify-items: start;
  padding: clamp(2.5rem, 6vw, 6rem);
}

.home-about-copy h2 {
  margin: 0 0 2rem;
  font-size: clamp(4.5rem, 9vw, 8rem);
  font-weight: 820;
  letter-spacing: -0.08em;
  line-height: 0.84;
  text-transform: uppercase;
}

.home-about-copy h2::first-letter {
  color: var(--signal);
}

.home-about-copy .home-section-summary {
  max-width: 42rem;
  color: var(--canvas);
}

.home-about-cta {
  display: inline-flex;
  min-height: 2.75rem;
  align-items: center;
  gap: 0.8rem;
  margin-top: 2.25rem;
  color: var(--signal);
  font-family: var(--mono);
  font-size: 0.7rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.home-about-cta i {
  font-size: 1.15rem;
  font-style: normal;
}

.page-layout {
  display: grid;
  grid-template-columns: minmax(7rem, 1fr) minmax(0, 10fr);
  margin-block: clamp(3.5rem, 8vw, 7rem) 6rem;
}

.page-register {
  display: grid;
  gap: 0.2rem;
  align-self: stretch;
  align-content: start;
  border-right: 1px solid var(--rule);
  padding: 0.35rem 1.25rem 0 0;
}

.page-register span:first-child,
.page-register span:nth-child(2) {
  color: var(--accent);
}

.page-content {
  width: min(100%, 68rem);
  padding-left: clamp(2rem, 6vw, 6rem);
}

.page-heading {
  border-top: 1px solid var(--rule);
}

.page-heading h1 {
  margin: 0;
  padding: clamp(1.1rem, 2.5vw, 2rem) 0 clamp(2.5rem, 5vw, 4rem);
  font-size: clamp(3rem, 8vw, 6.5rem);
  font-weight: 780;
  letter-spacing: -0.07em;
  line-height: 0.9;
}

.page-heading h1::first-letter {
  color: var(--accent);
}

.page-media {
  position: relative;
  width: min(100%, 58rem);
  margin: 0 0 clamp(3.5rem, 7vw, 5rem);
  border: 1px solid var(--rule);
  padding: 0.55rem;
  background: var(--text);
}

.page-media::after {
  position: absolute;
  inset: 1.1rem;
  border: 1px solid rgb(99 220 233 / 42%);
  pointer-events: none;
  content: "";
}

.page-media img {
  width: 100%;
  height: auto;
}

.page-body {
  counter-reset: page-section;
}

.page-body > p {
  width: min(100%, 50rem);
  margin: 0 0 1.35rem;
  color: #344347;
}

.page-body > p:first-child {
  width: min(100%, 58rem);
  margin-bottom: clamp(4rem, 8vw, 6.5rem);
  border-left: 0.45rem solid var(--signal);
  padding: 0.2rem 0 0.2rem clamp(1.25rem, 3vw, 2.25rem);
  color: var(--text);
  font-size: clamp(1.2rem, 2vw, 1.5rem);
  line-height: 1.48;
}

.page-body h2 {
  display: grid;
  grid-template-columns: 3.25rem minmax(0, 1fr);
  width: min(100%, 58rem);
  margin: clamp(4rem, 8vw, 6rem) 0 1.65rem;
  border-top: 1px solid var(--rule);
  padding-top: 0.8rem;
  font-family: var(--mono);
  font-size: clamp(1rem, 1.8vw, 1.25rem);
  letter-spacing: 0.08em;
  line-height: 1.3;
  text-transform: uppercase;
  counter-increment: page-section;
}

.page-body h2::before {
  color: var(--accent);
  content: "0" counter(page-section);
  font-variant-numeric: tabular-nums;
}

.page-content li {
  color: #344347;
}

.page-content a {
  color: var(--accent);
}

.page-content .note-row {
  color: var(--text);
}

.page-content .note-row:hover {
  color: var(--canvas);
}

.page-footer {
  display: flex;
  width: min(100%, 58rem);
  min-height: 4rem;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  margin-top: clamp(5rem, 10vw, 8rem);
  border-block: 1px solid var(--rule);
  color: var(--muted);
  font-family: var(--mono);
  font-size: 0.64rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.page-footer a {
  display: inline-flex;
  min-height: 2.75rem;
  align-items: center;
  gap: 0.55rem;
  text-decoration: none;
}

.notes-index-intro {
  width: min(100%, 58rem);
  margin-bottom: clamp(4rem, 8vw, 6.5rem);
  border-left: 0.45rem solid var(--signal);
  padding-left: clamp(1.25rem, 3vw, 2.25rem);
  color: var(--text);
  font-size: clamp(1.2rem, 2vw, 1.5rem);
  line-height: 1.48;
}

.notes-index-intro > :first-child {
  margin-top: 0;
}

.notes-index-intro > :last-child {
  margin-bottom: 0;
}

.note-list--archive {
  width: min(100%, 58rem);
  border-block: 1px solid var(--rule);
}

.note-heading time {
  display: block;
  padding-top: 1rem;
  color: var(--accent);
  font-family: var(--mono);
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.note-heading h1 {
  padding-top: 0.75rem;
}

@media (max-width: 720px) {
  body {
    border-top-width: 0.25rem;
  }

  .shell {
    width: min(100% - 2rem, 86rem);
  }

  .header-frame {
    grid-template-columns: auto minmax(0, 1fr);
    min-height: 5.5rem;
  }

  .brand-mark {
    width: 4rem;
  }

  .header-register {
    display: none;
  }

  .site-name {
    font-size: 1.3rem;
  }

  .work {
    margin-top: 3.25rem;
  }

  .section-header {
    grid-template-columns: 4.25rem minmax(0, 1fr);
  }

  .section-register {
    padding-right: 0.65rem;
    font-size: 0.55rem;
  }

  .section-title {
    padding: 0.35rem 0 0.65rem;
    font-size: clamp(3.8rem, 18vw, 5rem);
  }

  .section-title--compact {
    font-size: clamp(3.3rem, 16vw, 4.5rem);
  }

  .work-link {
    grid-template-columns: minmax(0, 1fr);
    gap: 1.6rem;
    min-height: 0;
    padding: 1.65rem 0 2rem;
  }

  .work-meta {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    gap: 0.8rem;
    border-right: 0;
    padding-right: 1.25rem;
  }

  .work-route {
    margin-left: auto;
  }

  .work-row:not(.work-row--media) .work-copy {
    grid-column: auto;
  }

  .work-title {
    font-size: clamp(2.55rem, 13vw, 3.7rem);
  }

  .work-summary {
    margin-top: 1.15rem;
  }

  .work-media {
    width: 100%;
  }

  .home-notes {
    margin-block: 6rem;
  }

  .home-notes-body {
    grid-template-columns: minmax(0, 1fr);
  }

  .home-notes-intro,
  .home-notes-body > .note-list {
    grid-column: auto;
  }

  .home-notes-intro {
    grid-template-columns: minmax(0, 1fr);
    gap: 1.25rem;
    padding-block: 1.5rem 1.75rem;
  }

  .signal-link {
    justify-self: start;
  }

  .note-row {
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 0.8rem 1rem;
    padding-block: 1.2rem;
  }

  .note-row time {
    grid-column: 1 / 3;
  }

  .note-row-arrow {
    grid-column: 2;
    grid-row: 2;
  }

  .home-about {
    margin-top: 7rem;
  }

  .home-about-link {
    grid-template-columns: minmax(0, 1fr);
    min-height: 0;
  }

  .home-about-register {
    display: flex;
    justify-content: space-between;
    gap: 1rem;
    border-right: 0;
    border-bottom: 1px solid var(--muted);
    padding: 1rem;
  }

  .home-about-copy {
    padding: 2.25rem 1rem 2.75rem;
  }

  .home-about-copy h2 {
    font-size: clamp(3.8rem, 18vw, 5rem);
  }

  .page-layout {
    grid-template-columns: minmax(0, 1fr);
    gap: 1.5rem;
  }

  .page-register {
    display: flex;
    flex-wrap: wrap;
    gap: 0.35rem 0.8rem;
    border-right: 0;
    border-bottom: 1px solid var(--rule);
    padding: 0 0 0.75rem;
  }

  .page-content {
    padding-left: 0;
  }

  .page-heading {
    border-top: 0;
  }

  .page-heading h1 {
    padding-top: 0;
  }

  .page-media {
    padding: 0.35rem;
  }

  .page-media::after {
    inset: 0.75rem;
  }

  .page-body > p:first-child {
    border-left-width: 0.35rem;
    padding-left: 1rem;
  }

  .page-body h2 {
    grid-template-columns: 2.4rem minmax(0, 1fr);
  }

  .notes-index-intro {
    border-left-width: 0.35rem;
    padding-left: 1rem;
  }
}

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

  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    transition-duration: 0.01ms !important;
  }
}
