/* How the page looks: colors, type, and spacing.
   To change the words, edit index.html — not this file. */

:root {
  color-scheme: light;
  --bg: #f7f5f0;
  --surface: #fffcf8;
  --text: #1a1916;
  --muted: #4f4a43;
  --line: #e3ddd2;
  --accent: #0d4f4c;
  --on-accent: #f7f5f0;
  --ink: #1a1916;
  --on-ink: #f7f5f0;
  --tag: #efece4;
  --serif: "Iowan Old Style", "Palatino Linotype", Palatino, "Book Antiqua", Georgia, "Times New Roman", serif;
  --sans: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  --space: 4.5rem;
}

@media (prefers-color-scheme: dark) {
  :root {
    color-scheme: dark;
    --bg: #141311;
    --surface: #1d1c19;
    --text: #f3f0e8;
    --muted: #c4beb3;
    --line: #322f2a;
    --accent: #9ed9d2;
    --on-accent: #10211f;
    --ink: #f3f0e8;
    --on-ink: #141311;
    --tag: #2a2723;
  }
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: 4.25rem;
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--sans);
  font-size: 1.0625rem;
  line-height: 1.65;
}

.wrap {
  width: min(40rem, calc(100% - 2.5rem));
  margin-inline: auto;
}

.skip {
  position: absolute;
  left: 0.75rem;
  top: 0.75rem;
  transform: translateY(-160%);
  background: var(--ink);
  color: var(--on-ink);
  padding: 0.5rem 0.8rem;
  border-radius: 0.4rem;
  z-index: 10;
}

.skip:focus {
  transform: none;
}

a {
  color: var(--accent);
  text-underline-offset: 0.18em;
}

a:hover {
  text-decoration-thickness: 2px;
}

:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
}

.nav {
  position: sticky;
  top: 0;
  z-index: 5;
  background: var(--bg);
  border-bottom: 1px solid var(--line);
}

.nav .wrap {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem 1.15rem;
  padding-top: 0.75rem;
  padding-bottom: 0.75rem;
}

.nav a {
  color: var(--muted);
  text-decoration: none;
  font-size: 0.92rem;
  padding: 0.35rem 0;
}

.nav a:hover {
  color: var(--accent);
  text-decoration: underline;
}

.hero {
  padding: 2.75rem 0 0.5rem;
}

.avatar {
  width: 5.25rem;
  height: 5.25rem;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: var(--ink);
  color: var(--on-ink);
  font-family: var(--serif);
  font-weight: 600;
  font-size: 1.3rem;
  letter-spacing: 0.04em;
}

h1,
h2,
h3 {
  font-family: var(--serif);
  font-weight: 600;
  line-height: 1.2;
  text-wrap: balance;
}

h1 {
  margin: 1rem 0 0.45rem;
  font-size: clamp(2rem, 4vw + 1rem, 2.75rem);
  letter-spacing: -0.02em;
}

.headline {
  margin: 0;
  color: var(--accent);
  font-size: 1.125rem;
  font-weight: 600;
  line-height: 1.4;
}

.now {
  margin: 0.85rem 0 0;
  max-width: 38rem;
  text-wrap: pretty;
}

.tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  margin: 1.35rem 0 0;
  padding: 0;
  list-style: none;
}

.tags li {
  background: var(--tag);
  color: var(--text);
  border-radius: 999px;
  padding: 0.28rem 0.7rem;
  font-size: 0.84rem;
  line-height: 1.4;
}

main {
  padding-bottom: 1rem;
}

section {
  padding-top: var(--space);
}

h2 {
  margin: 0 0 1rem;
  font-size: 1.6rem;
}

section p {
  margin: 0 0 0.9rem;
}

.cards {
  display: grid;
  gap: 0.85rem;
}

.card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 0.75rem;
  padding: 1.05rem 1.15rem 0.95rem;
}

.card-top {
  display: flex;
  flex-wrap: nowrap;
  justify-content: space-between;
  align-items: baseline;
  gap: 0.75rem;
  margin-bottom: 0.4rem;
}

.card h3 {
  margin: 0;
  flex: 1 1 auto;
  min-width: 0;
  font-size: 1.15rem;
  text-wrap: pretty;
}

.nowrap {
  white-space: nowrap;
}

.year {
  margin: 0;
  flex: 0 0 auto;
  color: var(--muted);
  font-size: 0.9rem;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

.card p:last-child {
  margin-bottom: 0;
}

.status {
  display: inline-block;
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 0.15rem 0.55rem;
  font-size: 0.78rem;
  line-height: 1.4;
  color: var(--text);
  background: var(--tag);
}

.status-live {
  background: var(--accent);
  border-color: var(--accent);
  color: var(--on-accent);
}

.site-footer {
  margin-top: var(--space);
  padding: 0 0 2.5rem;
  /* Lets the last sections scroll up under the nav, and stops
     there so the Contact heading cannot slide underneath it. */
  min-height: calc(100svh - 4.25rem);
}

.contact {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem 1.25rem;
  margin: 0;
  padding: 0;
  list-style: none;
}

.contact a {
  display: inline-block;
  padding: 0.4rem 0;
  font-weight: 600;
}

.copyright {
  margin: 0.85rem 0 0;
  color: var(--muted);
  font-size: 0.9rem;
}

@media (max-width: 480px) {
  :root {
    --space: 3.25rem;
  }

  .hero {
    padding-top: 2.1rem;
  }

  h2 {
    font-size: 1.45rem;
  }
}
