/* heininger.xyz — the default landing page, built on the Industry system.
   A technical drawing: a hairline-framed sheet on graph paper, condensed
   uppercase headings, one blue accent. Every value comes from industry.css
   tokens. */

body { margin: 0; background: var(--color-bg); }

/* Links in body copy sit a step darker than the accent so they hold their
   contrast against the light ground. */
a { color: var(--color-accent-700); }
a:hover { color: var(--color-accent); }

/* Those two would repaint a primary button's label as it is hovered — a:hover
   outranks .btn-primary — so pin the label to the sheet colour and darken the
   fill instead. */
a.btn-primary,
a.btn-primary:hover { color: var(--color-bg); }
a.btn-primary:hover {
  background: var(--color-accent-700);
  border-color: var(--color-accent-700);
}

/* — the sheet — */

.sheet {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  gap: 22px;
  padding: 26px 30px 30px;
  position: relative;
  color: var(--color-text);
  font-family: var(--font-body);
  /* graph paper */
  background-color: var(--color-bg);
  background-image:
    linear-gradient(var(--color-neutral-200) 1px, transparent 1px),
    linear-gradient(90deg, var(--color-neutral-200) 1px, transparent 1px);
  background-size: 34px 34px;
}

/* — top bar — */

.topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  position: relative;
  z-index: 1;
}

.brand {
  font-family: var(--font-heading);
  font-weight: 600;
  font-size: 20px;
  letter-spacing: 0.02em;
  font-style: italic;
}

/* The dot in heininger.xyz, drawn as a stoplight: three discs stacked on the
   same slant as the italic. Decorative, so the real dot is kept for screen
   readers alongside it. */
.brand-dots {
  display: inline-flex;
  flex-direction: column;
  gap: 2px;
  height: 19px;
  margin: 0 3px 0 6px;
  vertical-align: middle;
  /* nudged up a pixel to sit on the wordmark's optical centre */
  transform: skewX(-12deg) translateY(-1px);
}

.brand-dots span {
  width: 5px;
  height: 5px;
  flex: none;
  border-radius: 50%;
}

.brand-dots span:nth-child(1) { background: #e01b1b; }
.brand-dots span:nth-child(2) { background: #1db821; }
.brand-dots span:nth-child(3) { background: #1636e0; }

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
  border: 0;
}

/* — era switch — */

.era-switch {
  display: flex;
  align-items: center;
  font-size: 11px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.era {
  padding: 6px 14px;
  border: 1px solid var(--color-divider);
  color: var(--color-neutral-700);
  text-decoration: none;
}

/* The current era is the filled one; it butts against its neighbour, so it
   drops the shared border. */
.era--current {
  border-color: var(--color-accent);
  border-right: 0;
  background: var(--color-accent);
  color: var(--color-bg);
}

a.era:hover {
  background: var(--color-accent-100);
  color: var(--color-accent-800);
}

/* — the framed sheet — */

.blueprint {
  flex: 1;
  display: flex;
  flex-direction: column;
  background: var(--color-bg);
  position: relative;
  z-index: 1;
}

/* — masthead — */

.masthead {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 20px 28px;
  padding: 26px 28px 22px;
  border-bottom: 1px solid var(--color-divider);
}

/* Wraps the plate onto its own line once the title needs more than 380px. */
.masthead-title {
  display: flex;
  flex-direction: column;
  gap: 8px;
  flex: 1 1 380px;
  min-width: 0;
}

.kicker {
  font-size: 11px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--color-neutral-600);
}

.masthead h1 {
  margin: 0;
  font-family: var(--font-heading);
  font-weight: 600;
  font-size: clamp(38px, 5.4vw, 68px);
  line-height: 0.92;
  letter-spacing: 0.005em;
  text-transform: uppercase;
}

.tagline {
  margin: 4px 0 0;
  font-size: 17px;
  color: var(--color-neutral-700);
}

/* The spec block, read as a drawing's title block. */
.spec {
  display: grid;
  grid-template-columns: max-content 1fr;
  flex: 0 1 auto;
  min-width: 240px;
  margin: 0;
  border: 1px solid var(--color-divider);
  font-size: 11px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.spec dt {
  padding: 6px 10px;
  border-right: 1px solid var(--color-divider);
  color: var(--color-neutral-600);
}

.spec dd {
  margin: 0;
  padding: 6px 14px;
}

/* every row but the last carries a rule */
.spec > *:nth-child(-n + 4) { border-bottom: 1px solid var(--color-divider); }

/* — panes — */

.body {
  flex: 1;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr);
}

.pane-about {
  display: flex;
  flex-direction: column;
  gap: 18px;
  padding: 22px 28px 24px;
}

.pane-projects {
  display: flex;
  flex-direction: column;
  padding: 22px 28px 24px;
  border-left: 1px solid var(--color-divider);
}

.pane-heading {
  font-size: 11px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--color-neutral-600);
  border-bottom: 1px solid var(--color-divider);
  padding-bottom: 8px;
}

.pane-heading h2 {
  margin: 0;
  font: inherit;
  letter-spacing: inherit;
}

/* — about — */

.bio {
  display: flex;
  flex-direction: column;
  gap: 12px;
  font-size: 14.5px;
  line-height: 1.6;
}

.bio p {
  margin: 0;
  color: var(--color-neutral-700);
}

.bio-lead { color: var(--color-text); }

.stats {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  border: 1px solid var(--color-divider);
  margin-top: auto; /* pins the stats and the button to the foot of the pane */
}

.stat {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 12px 14px;
  border-right: 1px solid var(--color-divider);
}

.stat:last-child { border-right: 0; }

.stat-value {
  font-family: var(--font-heading);
  font-weight: 600;
  font-size: 30px;
  line-height: 1;
}

/* "since" runs quieter than the year it qualifies. */
.stat-qualifier {
  font-size: 17px;
  font-weight: 400;
  color: var(--color-neutral-500);
}

.stat-label {
  font-size: 10px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--color-neutral-600);
}

.pane-about .btn { align-self: flex-start; }

/* — projects — */

.project {
  display: grid;
  grid-template-columns: 42px minmax(0, 1fr) max-content;
  align-items: start;
  column-gap: 16px;
  row-gap: 5px;
  padding: 18px 0;
  border-bottom: 1px solid var(--color-divider);
}

.project:last-child { border-bottom: 0; }

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

a.project:hover { background: var(--color-accent-100); }

.project-index {
  grid-row: 1 / span 3;
  font-family: var(--font-heading);
  font-weight: 600;
  font-size: 22px;
  color: var(--color-neutral-500);
}

.project h3 {
  margin: 0;
  font-family: var(--font-heading);
  font-weight: 600;
  font-size: 30px;
  line-height: 1;
  text-transform: uppercase;
  color: var(--color-neutral-800);
}

.project-status {
  align-self: center;
  text-transform: uppercase;
  white-space: nowrap;
}

.project-status--live {
  background: var(--color-accent);
  color: var(--color-bg);
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.14em;
  padding: 4px 12px;
}

.project-status--beta {
  font-size: 10px;
  letter-spacing: 0.12em;
}

/* The shipped one is the only one drawn at full strength. */
.project--live .project-index { color: var(--color-accent-700); }
.project--live h3 { color: var(--color-text); }

.project-summary {
  grid-column: 2 / span 2;
  margin: 0;
  font-size: 14px;
}

.project-note {
  grid-column: 2 / span 2;
  margin: 0;
  font-size: 13px;
  line-height: 1.5;
  color: var(--color-neutral-600);
}

/* — colophon — */

.colophon {
  display: grid;
  grid-template-columns: max-content minmax(0, 1fr) max-content;
  align-items: center;
  border-top: 1px solid var(--color-divider);
  font-size: 11px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--color-neutral-600);
}

.colophon a {
  padding: 10px 16px;
  border-right: 1px solid var(--color-divider);
  text-decoration: none;
  color: inherit;
}

.colophon a:hover { color: var(--color-accent); }

.colophon span { padding: 10px 16px; }

.colophon span:last-child { border-left: 1px solid var(--color-divider); }

/* — narrow — */

@media (max-width: 900px) {
  .body { grid-template-columns: minmax(0, 1fr); }

  .pane-projects {
    border-left: 0;
    border-top: 1px solid var(--color-divider);
  }
}

/* Small screens: the sheet takes the full width, the plate spans it. The
   frame drops its side borders and its registration marks — a drawing
   cropped to the page rather than a shrunken one. */
@media (max-width: 640px) {
  .sheet {
    padding: 14px 0 0;
    gap: 14px;
  }

  .topbar { padding: 0 16px; }

  .blueprint {
    border-left: 0;
    border-right: 0;
  }

  .blueprint > .corner { display: none; }

  .masthead { padding: 20px 16px 18px; }

  .spec {
    width: 100%;
    min-width: 0;
  }

  .pane-about,
  .pane-projects { padding: 18px 16px 20px; }

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

  .colophon > a,
  .colophon > span,
  .colophon > span:last-child {
    border: 0;
    border-top: 1px solid var(--color-divider);
    padding: 9px 16px;
  }

  .colophon > :first-child { border-top: 0; }
}
