/* Hallmark · macrostructure: Index-First · tone: Swiss minimalist · anchor hue: red
 * Genre: editorial · theme: Manifesto · nav: N9 · footer: Ft2 · enrichment: none
 * Audience: hhc.today visitors · use: browse frontend resources
 * Pre-emit critique: P5 H5 E4 S4 R5 V4
 */

* {
  box-sizing: border-box;
}

html,
body {
  overflow-x: clip;
}

body {
  min-height: 100vh;
  min-height: 100svh;
  margin: 0;
  display: flex;
  flex-direction: column;
  background: var(--color-paper);
  color: var(--color-ink);
  font-family: var(--font-body);
  font-size: var(--text-body);
  line-height: 1.55;
}

h1,
h2,
p {
  margin: 0;
}

a {
  color: inherit;
}

a:focus-visible {
  outline: 2px solid var(--color-accent);
  outline-offset: var(--space-1);
  color: var(--color-accent);
}

.frame {
  width: min(calc(100% - 2 * var(--gutter)), 78rem);
  margin-inline: auto;
}

.site-header,
.site-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-3);
}

.site-header {
  min-height: clamp(4.5rem, 8vw, 6.25rem);
  border-bottom: var(--rule-thin) solid var(--color-ink);
}

.wordmark,
.section-link {
  display: inline-flex;
  min-height: 44px;
  align-items: center;
  gap: var(--space-2);
  text-decoration: none;
  white-space: nowrap;
}

.wordmark {
  font: 700 var(--text-body) / 1 var(--font-display);
  letter-spacing: -0.02em;
}

.wordmark span {
  width: var(--space-2);
  height: var(--space-2);
  background: var(--color-accent);
}

.section-link {
  font-size: var(--text-small);
}

.section-link span,
.title-dot {
  color: var(--color-accent);
}

.masthead {
  display: grid;
  gap: var(--space-4);
  padding-block: clamp(3rem, 5vw, 4.5rem) clamp(4rem, 6.6vw, 6rem);
}

.masthead h1 {
  min-width: 0;
  font: 700 var(--text-title) / 1 var(--font-display);
  letter-spacing: -0.065em;
  overflow-wrap: anywhere;
}

.masthead-label {
  display: grid;
  align-content: end;
  gap: var(--space-1);
  font-size: var(--text-small);
}

.small-label {
  color: var(--color-muted);
  font: 600 var(--text-label) / 1.45 var(--font-display);
  letter-spacing: 0.11em;
  text-transform: uppercase;
}

.index-section {
  display: grid;
  gap: var(--space-6);
  padding-block: var(--space-8);
  border-block: var(--rule-thin) solid var(--color-ink);
  scroll-margin-block: var(--space-6);
}

.index-heading {
  display: grid;
  gap: var(--space-2);
}

.index-heading h2 {
  min-width: 0;
  margin-bottom: var(--space-2);
  font-size: var(--text-heading);
  line-height: 1.2;
  font-weight: 700;
  letter-spacing: -0.035em;
  overflow-wrap: anywhere;
}

.section-number {
  color: var(--color-accent);
  font-variant-numeric: tabular-nums;
}

.entries {
  min-width: 0;
  padding: 0;
  margin: 0;
  list-style: none;
  border-top: var(--rule-thin) solid var(--color-rule);
}

.entry-link {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-3);
  min-height: 52px;
  font-size: var(--text-entry);
  font-weight: 700;
  text-decoration: none;
  white-space: nowrap;
}

.entry-arrow {
  width: 44px;
  height: 44px;
  padding: var(--space-3);
  flex: none;
  background: var(--color-accent);
  color: var(--color-paper);
}

.entry-description,
.site-footer {
  color: var(--color-muted);
}

.site-footer {
  margin-top: auto;
  padding-block: var(--space-8) var(--space-4);
  font-size: var(--text-small);
}

.site-footer a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  white-space: nowrap;
  text-underline-offset: 0.25em;
}

a:active {
  color: var(--color-accent);
}

@media (hover: hover) {
  a:hover {
    color: var(--color-accent);
  }
}

@media (min-width: 48rem) {
  .index-section {
    grid-template-columns: minmax(0, 5fr) minmax(0, 7fr);
    gap: var(--column-gap);
    padding-block: var(--space-12);
  }

  .entries {
    border: 0;
    align-self: center;
  }

  .entry-link {
    min-height: 44px;
  }
}
