:root {
  --pink: #f7c8d7;
  --blue: #1d3fd8;
  --unit: 8px;
  --measure: 560px;
  --font: "Helvetica Neue", Helvetica, Arial, sans-serif;
  --small: 13px;
  --body: 17px;
  --title: 40px;
}

* { box-sizing: border-box; margin: 0; padding: 0; }

body {
  background: var(--pink);
  color: var(--blue);
  font: var(--body)/1.45 var(--font);
  -webkit-font-smoothing: antialiased;
}

main {
  max-width: var(--measure);
  margin: 0 auto;
  padding: calc(var(--unit) * 4) calc(var(--unit) * 2) calc(var(--unit) * 8);
  display: grid;
  gap: calc(var(--unit) * 4);
}

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

header {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  border-bottom: 2px solid var(--blue);
  padding-bottom: var(--unit);
}
h1 { font-size: var(--body); font-weight: 700; }
nav { display: flex; gap: calc(var(--unit) * 2); font-size: var(--body); font-variant-numeric: tabular-nums; }
nav a[hidden] { visibility: hidden; display: inline; }


figure { aspect-ratio: 4 / 5; background: var(--blue); }
figure[hidden] { display: none; }
figure img { display: block; width: 100%; height: 100%; object-fit: cover; }

h2 {
  font-size: var(--title);
  line-height: 1;
  font-weight: 700;
  letter-spacing: -0.02em;
  overflow-wrap: anywhere;
  margin-bottom: calc(var(--unit) * 3);
}
#post p { margin-bottom: calc(var(--unit) * 2); white-space: pre-line; }
#post p:last-child { margin-bottom: 0; }
footer { font-size: var(--small); }

@media (max-width: 420px) {
  :root { --title: 32px; }
}
