/* One Human One Bag.
   His two files set everything here: a black ground, a field of halftone dots, one flat white bag,
   and a geometric sans. Two colours, no third. Every surface is a hairline, never a filled card:
   his picture has no boxes in it, so neither does this page. */

@font-face {
  font-family: "Outfit";
  src: url("/fonts/Outfit-latin.woff2") format("woff2");
  font-weight: 100 900;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "DM Mono";
  src: url("/fonts/DMMono-400.woff2") format("woff2");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "DM Mono";
  src: url("/fonts/DMMono-500.woff2") format("woff2");
  font-weight: 500;
  font-style: normal;
  font-display: swap;
}

:root {
  /* his palette, picked off reference-banner-mono.jpg: the page is 89% black, 3% white, the rest
     is the dot field between them */
  --ground: #000000;
  --ink: #ffffff;
  --ash: rgba(255, 255, 255, 0.56);
  --dim: rgba(255, 255, 255, 0.36);
  --faint: rgba(255, 255, 255, 0.18);
  --line: rgba(255, 255, 255, 0.14);
  --line-soft: rgba(255, 255, 255, 0.07);

  /* the dense scale (order of 2026-10-19): one display element, labels at 11 */
  --t-label: 11px;
  --t-meta: 12px;
  --t-body: 14px;
  --t-lead: 15px;
  --t-head: 17px;
  --t-word: clamp(21px, 2.7vh, 30px);
  --t-display: clamp(50px, 8.6vh, 104px);

  --col: 1120px;
  --gutter: clamp(16px, 3vw, 40px);
  --mark: clamp(42px, 6.6vh, 72px);
  --pad: clamp(12px, 1.7vh, 18px);
  --track: 0.17em;
}

* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  background: var(--ground);
}

body {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  color: var(--ink);
  font-family: "Outfit", system-ui, sans-serif;
  font-size: var(--t-body);
  font-weight: 400;
  font-synthesis: none;
  line-height: 1.45;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

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

a {
  color: inherit;
}

b {
  font-weight: 600;
}

/* ============================ the ground ============================ */
/* His halftone, drawn as a real dot grid instead of a picture, so it stays a dot on any screen.
   The glow sits where the week's number does. */

.ground {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  overflow: hidden;
}

.ground__dots {
  position: absolute;
  inset: -8% -8% -8% -8%;
  background-image: radial-gradient(circle at center, rgba(255, 255, 255, 0.5) 1.1px, transparent 1.2px);
  background-size: 7px 7px;
  -webkit-mask-image: radial-gradient(96% 76% at 50% 26%, #000 0%, rgba(0, 0, 0, 0.5) 44%, transparent 86%);
  mask-image: radial-gradient(96% 76% at 50% 26%, #000 0%, rgba(0, 0, 0, 0.5) 44%, transparent 86%);
  opacity: 0.44;
  animation: drift 64s linear infinite;
  will-change: transform;
}

@keyframes drift {
  from {
    transform: translate3d(0, 0, 0);
  }
  to {
    transform: translate3d(-42px, -28px, 0);
  }
}

/* the same bag again, drawn only in dots, bleeding off the left edge: the device his banner uses */
.ground__ghost {
  position: absolute;
  left: -9vmin;
  top: 44%;
  width: min(46vh, 26vw);
  height: auto;
  transform: translateY(-50%);
  opacity: 0.14;
}


/* The hairlines between the bands. Drawn as a line of their own: a border would make every band a
   box, and text in a box owes it 16 px of side padding it does not need here. */
.nav,
.week,
.hero,
.crowd,
.figures,
.coin,
.step,
.list li,
.table__row,
.slot {
  position: relative;
}

.nav::before,
.week::before,
.hero::before,
.crowd::before,
.figures::before,
.coin::before,
.step::before,
.list li::before,
.table__row::before,
.slot::before {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  top: 0;
  height: 1px;
  background: var(--line);
}

.list li::before,
.table__row::before,
.slot::before {
  background: var(--line-soft);
}

/* ============================ the sheet ============================ */

.sheet {
  position: relative;
  z-index: 1;
  flex: 1;
  width: min(var(--col), 100%);
  margin: 0 auto;
  padding: 0 var(--gutter);
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.label {
  display: block;
  margin: 0;
  font-size: var(--t-label);
  font-weight: 500;
  letter-spacing: var(--track);
  text-transform: uppercase;
  color: var(--ash);
}

.mono {
  font-family: "DM Mono", ui-monospace, monospace;
  font-size: var(--t-meta);
  letter-spacing: 0.01em;
}

/* --- his banner, made into the letterhead --- */

.head {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: clamp(20px, 4vh, 42px) 0 clamp(14px, 2.4vh, 26px);
}

.head__mark {
  width: var(--mark);
  height: auto;
  margin-bottom: clamp(8px, 1.4vh, 16px);
}

.head__word {
  margin: 0;
  font-size: var(--t-word);
  font-weight: 600;
  letter-spacing: -0.005em;
  line-height: 1.1;
}

.head__claim {
  margin: clamp(6px, 1vh, 12px) 0 0;
  font-size: var(--t-label);
  font-weight: 500;
  letter-spacing: var(--track);
  text-transform: uppercase;
  color: var(--ash);
}


/* --- the sections, as a centred row of labels --- */

.nav {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: clamp(14px, 2.4vw, 34px);
  padding: 4px 0;
}

.nav__link {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 36px;
  padding: 6px 2px;
  color: var(--ash);
  font-size: var(--t-label);
  font-weight: 500;
  letter-spacing: var(--track);
  text-decoration: none;
  text-transform: uppercase;
  transition: color 0.16s ease;
}

.nav__link::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 1px;
  background: var(--ink);
  transform: scaleX(0);
  transform-origin: center;
  transition: transform 0.18s ease;
}

.nav__link:hover,
.nav__link:focus-visible,
.nav__link.is-open {
  color: var(--ink);
}

.nav__link:hover::after,
.nav__link:focus-visible::after,
.nav__link.is-open::after {
  transform: scaleX(1);
}

.nav__dot {
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--ink);
}

/* --- the week --- */

.week {
  display: grid;
  grid-template-columns: repeat(5, auto);
  justify-content: space-between;
  gap: 10px clamp(14px, 2vw, 30px);
  padding: var(--pad) 0;
}

.week__cell {
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.week__cell .value {
  display: flex;
  align-items: center;
  gap: 9px;
  font-size: var(--t-meta);
  font-weight: 500;
  font-family: "DM Mono", ui-monospace, monospace;
  letter-spacing: 0.01em;
}

.checks__said {
  color: var(--ash);
}

.week__cell--me .me__name {
  font-family: "Outfit", sans-serif;
  font-size: var(--t-meta);
  font-weight: 600;
}

.me__bar {
  display: flex;
  gap: 3px;
}

.me__bar i {
  width: 11px;
  height: 3px;
  background: var(--faint);
}

.me__bar i.is-on {
  background: var(--ink);
}

.me__bar i.is-off {
  background: var(--dim);
}

.me__sub {
  font-size: var(--t-label);
  color: var(--dim);
  letter-spacing: 0.03em;
}

.checks {
  display: flex;
  gap: 12px;
}

.check {
  display: flex;
  align-items: center;
  gap: 5px;
  font-size: var(--t-label);
  color: var(--dim);
  font-family: "DM Mono", ui-monospace, monospace;
}

.check i {
  width: 8px;
  height: 8px;
  border: 1px solid var(--dim);
  border-radius: 50%;
}

.check.is-lit {
  color: var(--ink);
}

.check.is-lit i {
  background: var(--ink);
  border-color: var(--ink);
}

/* --- the one display element --- */

.hero {
  padding: clamp(16px, 3.2vh, 40px) 0 clamp(14px, 2.4vh, 30px);
  text-align: center;
}

.hero__eyebrow {
  margin: 0;
  font-size: var(--t-label);
  font-weight: 500;
  letter-spacing: var(--track);
  text-transform: uppercase;
  color: var(--ash);
}

.hero__figure {
  margin: clamp(4px, 0.8vh, 10px) 0 0;
  font-size: var(--t-display);
  font-weight: 600;
  line-height: 1;
  letter-spacing: -0.025em;
  font-variant-numeric: tabular-nums;
}

.hero__unit {
  margin-left: 0.22em;
  font-size: 0.3em;
  font-weight: 500;
  letter-spacing: 0.12em;
  vertical-align: 0.42em;
}

.hero__stats {
  margin: clamp(12px, 2vh, 24px) 0 0;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 10px;
}

.stat {
  display: flex;
  flex-direction: column;
  gap: 3px;
}

.stat dt {
  font-size: var(--t-label);
  letter-spacing: var(--track);
  text-transform: uppercase;
  color: var(--ash);
}

.stat dd {
  margin: 0;
  font-size: var(--t-meta);
  font-family: "DM Mono", ui-monospace, monospace;
}

/* --- the crowd: one bag per human, every bag the same size --- */

.crowd {
  padding: var(--pad) 0;
}

.crowd__field {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: clamp(5px, 0.7vh, 9px);
  justify-content: space-between;
}

.crowd__field li {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
}

.crowd__field img {
  width: 100%;
  height: auto;
  opacity: 0.13;
}

.crowd__field li.is-filled img {
  opacity: 1;
  animation: breathe 9s ease-in-out infinite;
}

.crowd__field li.is-whale::after {
  content: "";
  position: absolute;
  left: 50%;
  top: 50%;
  width: 26px;
  height: 26px;
  margin: -13px 0 0 -13px;
  border: 1px solid var(--ink);
  border-radius: 50%;
}

@keyframes breathe {
  0%,
  100% {
    opacity: 1;
  }
  50% {
    opacity: 0.62;
  }
}

/* Two lines, whatever it says: the caption grows when a week fills the field, and a line that
   appears later must not push the rest of the sheet off the screen. */
.crowd__said {
  margin: 12px 0 0;
  min-height: 2.9em;
  font-size: var(--t-meta);
  line-height: 1.45;
  color: var(--ash);
  max-width: 78ch;
}

/* --- the whale tax and the weeks behind us --- */

.figures {
  display: grid;
  grid-template-columns: 1fr 1fr 1.25fr;
  gap: clamp(18px, 2.4vw, 34px);
  padding: var(--pad) 0;
}

.figure {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.figure__value {
  margin: 0;
  font-size: clamp(20px, 2.6vh, 26px);
  font-weight: 600;
  line-height: 1.1;
  font-variant-numeric: tabular-nums;
}

.figure__note {
  margin: 0;
  font-size: var(--t-label);
  line-height: 1.5;
  color: var(--dim);
}

.rows {
  margin: 0;
  display: grid;
  gap: 4px;
}

.row {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  font-size: var(--t-label);
}

.row dt {
  color: var(--ash);
}

.row dd {
  margin: 0;
  font-family: "DM Mono", ui-monospace, monospace;
}

.slots {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(8, 1fr);
  gap: 5px;
}

.slot {
  display: flex;
  flex-direction: column;
  gap: 3px;
  padding: 9px 2px 0;
  text-align: center;
  font-family: "DM Mono", ui-monospace, monospace;
}

.slot__week {
  font-size: 10px;
  color: var(--dim);
  letter-spacing: 0.02em;
}

.slot__value {
  font-size: var(--t-label);
}

.slot.is-empty {
  color: var(--dim);
}

/* --- the coin --- */

.coin {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px clamp(16px, 2vw, 28px);
  padding: var(--pad) 0 clamp(14px, 2vh, 22px);
}

.coin__mint,
.coin__links {
  margin: 0;
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.coin__mint .label {
  display: inline-block;
}

.key {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  min-height: 38px;
  padding: 0 16px;
  border: 1px solid var(--line);
  background: transparent;
  color: var(--ink);
  font-family: inherit;
  font-size: var(--t-label);
  font-weight: 500;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  text-decoration: none;
  cursor: pointer;
  transition: border-color 0.16s ease, color 0.16s ease;
}

.key:hover:not([disabled]):not([aria-disabled="true"]),
.key:focus-visible {
  border-color: var(--ink);
}

.key[disabled],
.key[aria-disabled="true"] {
  color: var(--dim);
  border-color: var(--line-soft);
  cursor: default;
}

.key__mark {
  width: 13px;
  height: 13px;
  filter: grayscale(1) brightness(2.6);
}

.said {
  font-size: var(--t-label);
  color: var(--ash);
}

.said.is-bad {
  color: var(--ink);
  text-decoration: underline;
}

/* ============================ the sections ============================ */

.panel {
  position: fixed;
  inset: 0;
  z-index: 5;
  background: var(--ground);
  overflow-y: auto;
  overscroll-behavior: contain;
}

.panel[hidden] {
  display: none;
}

.panel__head {
  position: sticky;
  top: 0;
  z-index: 1;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 14px max(var(--gutter), calc((100vw - var(--col)) / 2));
  background: var(--ground);
  border-bottom: 1px solid var(--line);
}

.panel__title {
  margin: 0;
  font-size: var(--t-head);
  font-weight: 600;
  letter-spacing: 0.01em;
}

.panel__body {
  padding: clamp(18px, 3vh, 30px) max(var(--gutter), calc((100vw - var(--col)) / 2)) 64px;
  display: grid;
  gap: 20px;
}

.lede {
  margin: 0;
  font-size: var(--t-lead);
  line-height: 1.6;
  max-width: 78ch;
  color: var(--ink);
}

.note {
  margin: 0;
  font-size: var(--t-meta);
  line-height: 1.55;
  color: var(--ash);
  max-width: 78ch;
}

.risk {
  margin: 0;
  padding: 16px 18px;
  border: 1px solid var(--line);
  font-size: var(--t-meta);
  line-height: 1.55;
  color: var(--ash);
}

.card__title {
  margin: 2px 0 0;
  font-size: var(--t-head);
  font-weight: 600;
}

.split > div {
  display: grid;
  gap: 14px;
  align-content: start;
}

.split {
  display: grid;
  grid-template-columns: 1.15fr 1fr;
  gap: clamp(20px, 3vw, 44px);
  align-items: start;
}

.fields {
  display: grid;
  gap: 16px;
  align-content: start;
}

.field {
  display: grid;
  gap: 7px;
}

.field > span:first-child {
  font-size: var(--t-label);
  letter-spacing: var(--track);
  text-transform: uppercase;
  color: var(--ash);
}

.actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
}

.input,
.textarea {
  width: 100%;
  padding: 11px 16px;
  border: 1px solid var(--line);
  background: transparent;
  color: var(--ink);
  font-family: "DM Mono", ui-monospace, monospace;
  font-size: var(--t-meta);
}

.textarea {
  min-height: 96px;
  resize: vertical;
  font-family: inherit;
  font-size: var(--t-body);
}

.input:focus,
.textarea:focus {
  outline: none;
  border-color: var(--ink);
}

.readout {
  padding: 14px 16px;
  border: 1px solid var(--line-soft);
  font-family: "DM Mono", ui-monospace, monospace;
  font-size: var(--t-meta);
  line-height: 1.55;
  white-space: pre-wrap;
  color: var(--ash);
}

.code {
  font-size: var(--t-head);
  color: var(--ink);
  letter-spacing: 0.06em;
}

.checkline {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: var(--t-meta);
  color: var(--ash);
}

.aside {
  display: grid;
  gap: 14px;
  align-content: start;
  padding: 18px 20px;
  border: 1px solid var(--line);
}

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

.list li {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 14px;
  padding: 10px 0;
  font-size: var(--t-meta);
}

.list li > span:first-child {
  color: var(--ink);
}

.list li > span + span {
  color: var(--ash);
  font-family: "DM Mono", ui-monospace, monospace;
  font-size: var(--t-label);
}

.list--wide li {
  grid-template-columns: 220px 1fr;
}

.list--wide li > span + span {
  font-family: inherit;
  font-size: var(--t-meta);
  line-height: 1.55;
}

.table {
  display: grid;
  font-size: var(--t-meta);
}

.table__head,
.table__row {
  display: grid;
  grid-template-columns: 1.1fr 0.7fr 0.9fr 0.9fr 1fr;
  gap: 12px;
  padding: 9px 0;
}

.table__head::before {
  display: none;
}

.table__head {
  font-size: var(--t-label);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--ash);
}

.table__row {
  font-family: "DM Mono", ui-monospace, monospace;
  font-size: var(--t-label);
}

.steps {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: clamp(16px, 2vw, 28px);
}

.step {
  display: grid;
  gap: 7px;
  align-content: start;
  padding-top: 14px;
}

.step__n {
  font-size: var(--t-label);
  letter-spacing: var(--track);
  color: var(--ash);
}

.step__t {
  margin: 0;
  font-size: var(--t-head);
  font-weight: 600;
}

.step p {
  margin: 0;
  font-size: var(--t-meta);
  line-height: 1.55;
  color: var(--ash);
}

/* ============================ states ============================ */

body.is-open .ground__dots {
  opacity: 0.22;
}

:focus-visible {
  outline: 1px solid var(--ink);
  outline-offset: 2px;
}

@media (prefers-reduced-motion: reduce) {
  .ground__dots,
  .crowd__field li.is-filled img {
    animation: none;
  }
}

/* ============================ widths ============================ */
/* Every query lives here, after the rules it changes, and the short-height one comes last so a
   laptop at 1366x768 is not overruled by a width query. */

@media (max-width: 980px) {
  .figures {
    grid-template-columns: 1fr 1fr;
  }

  .figure--weeks {
    grid-column: 1 / -1;
  }

  .split,
  .steps {
    grid-template-columns: 1fr;
  }

  .list--wide li {
    grid-template-columns: 1fr;
    gap: 4px;
  }
}

@media (max-width: 860px) {
  .nav {
    justify-content: space-between;
    gap: 6px;
  }

  .week {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    justify-content: stretch;
  }

  .week__cell--checks,
  .week__cell--me {
    grid-column: 1 / -1;
  }

  .week__cell--checks .value {
    flex-wrap: wrap;
  }

  .hero__stats {
    grid-template-columns: repeat(2, 1fr);
  }

  .table__head {
    display: none;
  }

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

@media (max-width: 560px) {
  :root {
    --t-display: clamp(42px, 13vw, 58px);
    --t-word: 20px;
  }

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

  .slots {
    grid-template-columns: repeat(4, 1fr);
  }

  .list li {
    grid-template-columns: 1fr;
    gap: 3px;
  }

  .coin {
    flex-direction: column;
    align-items: flex-start;
  }

  .coin__mint .mono {
    word-break: break-all;
  }
}

@media (max-width: 380px) {
  .nav__link {
    font-size: var(--t-label);
    letter-spacing: 0.04em;
  }
}

/* A short desktop window: the letterhead gives its room back to the figure and the crowd.
   These two come last in the file, so a width query can never overrule them. */
@media (min-width: 861px) and (max-height: 1060px) {
  :root {
    --pad: 13px;
  }

  .head {
    padding: 20px 0 14px;
  }

  .nav {
    padding: 3px 0;
  }

  .hero {
    padding: 22px 0 16px;
  }

  .hero__stats {
    margin-top: 14px;
  }

  .crowd__said {
    margin-top: 10px;
  }
}

@media (min-width: 861px) and (max-height: 840px) {
  :root {
    --pad: 8px;
  }

  .head {
    padding: 12px 0 8px;
  }

  .nav {
    padding: 1px 0;
  }

  .hero {
    padding: 14px 0 10px;
  }

  .hero__stats {
    margin-top: 11px;
  }

  .crowd__said {
    margin-top: 6px;
    font-size: var(--t-label);
  }

  .coin {
    padding-bottom: 6px;
  }
}
