:root {
  --ink: #172018;
  --soft-ink: #3c473b;
  --paper: #e4ebdd;
  --paper-light: #f5f8ef;
  --panel: #edf3e7;
  --line: #202820;
  --muted-line: #7f8c78;
  --red: #c63e35;
  --blue: #486984;
  --green: #8aa26f;
  --yellow: #d9b653;
  --white: #fbfcf5;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family:
    ui-monospace, SFMono-Regular, Menlo, Consolas, "Liberation Mono",
    "Noto Sans Mono CJK KR", "Noto Sans KR", monospace;
  line-height: 1.55;
  letter-spacing: 0;
}

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

a {
  color: inherit;
  text-decoration: none;
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  min-height: 58px;
  padding: 10px 28px;
  background: rgba(228, 235, 221, 0.94);
  border-bottom: 2px solid var(--line);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-width: 140px;
  font-size: 18px;
  font-weight: 800;
}

.brand img {
  width: 32px;
  height: 32px;
  image-rendering: pixelated;
}

.topbar nav {
  display: flex;
  gap: 8px;
}

.topbar nav a,
.hero-actions a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 34px;
  padding: 0 12px;
  background: rgba(245, 248, 239, 0.82);
  border: 2px solid var(--line);
  font-size: 14px;
  font-weight: 800;
}

.topbar nav a:hover,
.topbar nav a:focus-visible,
.hero-actions a:hover,
.hero-actions a:focus-visible {
  background: var(--yellow);
  outline: none;
}

.hero {
  min-height: 76vh;
  display: flex;
  align-items: flex-start;
  padding: 78px 32px 96px;
  border-bottom: 2px solid var(--line);
  background: url("assets/library-hero.png") center bottom / cover no-repeat;
  image-rendering: pixelated;
}

.hero-copy {
  width: min(670px, 100%);
  margin-left: max(0px, calc((100vw - 1180px) / 2));
}

.eyebrow,
.section-label {
  margin: 0 0 10px;
  color: var(--soft-ink);
  font-size: 13px;
  font-weight: 900;
  text-transform: uppercase;
}

.hero h1 {
  margin: 0;
  color: var(--ink);
  font-size: 84px;
  line-height: 0.9;
  letter-spacing: 0;
}

.tagline {
  max-width: 560px;
  margin: 18px 0 0;
  color: var(--red);
  font-size: 24px;
  font-weight: 900;
  line-height: 1.25;
}

.lead {
  max-width: 620px;
  margin: 18px 0 0;
  color: var(--soft-ink);
  font-size: 17px;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 24px;
}

.snapshot,
.screens,
.archive-layout,
.not-list,
.build {
  width: min(1180px, calc(100% - 56px));
  margin: 0 auto;
}

.snapshot,
.screens,
.band,
.archive,
.not-list,
.build {
  padding-top: 72px;
  padding-bottom: 72px;
}

.snapshot {
  display: grid;
  grid-template-columns: minmax(0, 1.08fr) minmax(330px, 0.92fr);
  gap: 48px;
}

h2 {
  margin: 0;
  color: var(--ink);
  font-size: 38px;
  line-height: 1.16;
  letter-spacing: 0;
}

.snapshot-copy p:last-child,
.build-copy p {
  margin: 18px 0 0;
  color: var(--soft-ink);
  font-size: 16px;
}

.facts {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin: 0;
}

.facts div,
.loop-grid article,
.feature-list article {
  min-height: 104px;
  padding: 18px;
  background: var(--panel);
  border: 2px solid var(--line);
}

.facts dt {
  color: var(--soft-ink);
  font-size: 13px;
  font-weight: 900;
}

.facts dd {
  margin: 8px 0 0;
  color: var(--ink);
  font-size: 18px;
  font-weight: 900;
}

.screens {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(320px, 0.8fr);
  gap: 18px;
  padding-top: 0;
}

figure {
  margin: 0;
  background: var(--panel);
  border: 2px solid var(--line);
}

.screens img,
.side-shot img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center top;
  image-rendering: pixelated;
}

.main-shot img {
  min-height: 410px;
}

figcaption {
  padding: 12px 14px;
  color: var(--soft-ink);
  border-top: 2px solid var(--line);
  font-size: 13px;
}

.band {
  width: 100%;
  background: #d8e2d4;
  border-top: 2px solid var(--line);
  border-bottom: 2px solid var(--line);
}

.section-heading {
  width: min(1180px, calc(100% - 56px));
  margin: 0 auto 24px;
}

.loop-grid {
  width: min(1180px, calc(100% - 56px));
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 10px;
  margin: 0 auto;
}

.loop-grid span {
  display: block;
  color: var(--blue);
  font-size: 13px;
  font-weight: 900;
}

.loop-grid h3,
.feature-list h3 {
  margin: 10px 0 0;
  font-size: 20px;
  line-height: 1.2;
}

.loop-grid p,
.feature-list p {
  margin: 10px 0 0;
  color: var(--soft-ink);
  font-size: 14px;
}

.archive {
  background: var(--paper);
}

.archive-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(330px, 430px);
  gap: 18px;
}

.feature-list {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.side-shot {
  min-height: 430px;
}

.not-list {
  display: grid;
  grid-template-columns: minmax(0, 0.85fr) minmax(360px, 1fr);
  gap: 42px;
  align-items: start;
  border-top: 2px solid var(--line);
  border-bottom: 2px solid var(--line);
}

.not-list ul {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.not-list li {
  padding: 12px 14px;
  background: var(--paper-light);
  border-left: 6px solid var(--red);
  border-top: 2px solid var(--line);
  border-right: 2px solid var(--line);
  border-bottom: 2px solid var(--line);
  font-size: 14px;
  font-weight: 800;
}

.build {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(360px, 520px);
  gap: 42px;
  align-items: center;
}

.commands {
  display: grid;
  gap: 8px;
}

.commands code {
  display: block;
  overflow-x: auto;
  padding: 14px 16px;
  color: var(--white);
  background: var(--ink);
  border-left: 8px solid var(--blue);
  font-family: inherit;
  font-size: 14px;
  white-space: nowrap;
}

@media (max-width: 900px) {
  .topbar {
    position: static;
    align-items: flex-start;
    flex-direction: column;
    gap: 10px;
    padding: 10px 20px;
  }

  .topbar nav {
    width: 100%;
    overflow-x: auto;
    padding-bottom: 2px;
  }

  .hero {
    min-height: 70vh;
    padding: 58px 22px 76px;
    background-color: var(--paper);
    background-position: center bottom;
    background-size: auto 58%;
  }

  .hero h1 {
    font-size: 56px;
  }

  .tagline {
    font-size: 21px;
  }

  .snapshot,
  .screens,
  .archive-layout,
  .not-list,
  .build {
    width: min(100% - 40px, 680px);
    grid-template-columns: 1fr;
  }

  .section-heading,
  .loop-grid {
    width: min(100% - 40px, 680px);
  }

  .loop-grid,
  .feature-list {
    grid-template-columns: 1fr;
  }

  .facts,
  .not-list ul {
    grid-template-columns: 1fr 1fr;
  }

  .snapshot,
  .screens,
  .band,
  .archive,
  .not-list,
  .build {
    padding-top: 56px;
    padding-bottom: 56px;
  }

  .screens {
    padding-top: 0;
  }

  h2 {
    font-size: 30px;
  }

  .main-shot img,
  .side-shot {
    min-height: 0;
  }
}

@media (max-width: 560px) {
  .hero {
    min-height: 74vh;
    background-size: auto 34%;
  }

  .hero h1 {
    font-size: 46px;
  }

  .tagline {
    font-size: 18px;
  }

  .lead {
    font-size: 15px;
  }

  .hero-actions {
    flex-direction: column;
  }

  .hero-actions a {
    width: 100%;
  }

  .facts,
  .not-list ul {
    grid-template-columns: 1fr;
  }

  h2 {
    font-size: 26px;
  }
}
