/* Modeled on alexlubben.com: single long page, minimal, editorial. */

:root {
  --text: #1a1a1a;
  --muted: #666;
  --link: #1a1a1a;
  --rule: #e5e5e5;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  padding: 0;
  color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Helvetica, Arial, sans-serif;
  font-size: 17px;
  line-height: 1.6;
  background: #fff;
}

main {
  max-width: 1120px;
  margin: 0 auto;
  padding: 3rem 1.25rem 4rem;
}

/* Narrow container for the intro (header/about/contact) and the footer area.
   The two-column layout below starts only after "Get in touch". */
.narrow {
  max-width: 720px;
  margin: 0 auto;
}

/* Two-column area: Selected work (left) + Latest articles (right), 50/50.
   On phones it becomes one column: 5 latest, a Read more button, the
   Selected stories (tap to reveal), then the rest of the latest. */
.columns {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  grid-template-areas:
    "selected latest-top"
    "selected latest-rest";
  gap: 0 3rem;
  align-items: start;
}

.columns h2 {
  margin-top: 2.75rem;
}

#selected { grid-area: selected; }
#latest-top { grid-area: latest-top; }
#latest-rest { grid-area: latest-rest; }

/* Phone-only: reveals Selected work between the two latest groups */
#read-more { display: none; }

/* Phone-only heading above the remaining latest articles */
.continued-heading { display: none; }

h1 {
  font-family: Georgia, "Times New Roman", serif;
  font-size: 2rem;
  font-weight: 700;
  margin: 0 0 2.5rem;
  line-height: 1.25;
}

/* Site header: photo left, name/title/location right, vertically aligned */
.site-header {
  display: flex;
  align-items: center;
  gap: 1.5rem;
}

.site-header img {
  width: 128px;
  height: 128px;
  object-fit: cover;
  object-position: 60% 35%;
  border-radius: 50%;
  flex: 0 0 128px;
}

.site-title h1 {
  margin: 0 0 0.35rem;
  font-size: 2.2rem;
}

.site-title p {
  margin: 0;
  color: var(--muted);
  font-size: 1.1rem;
  line-height: 1.45;
}

hr {
  border: none;
  border-top: 1px solid var(--rule);
  margin: 2.25rem 0;
}

/* The <hr> above About me / Get in touch is the separator, so those h2s need no top border */
#about h2,
#contact h2 {
  border-top: none;
  padding-top: 0;
  margin-top: 0;
}

/* Full-width photo opening the More work section */
.section-photo {
  width: 100%;
  height: auto;
  display: block;
  border-radius: 8px;
  margin: 0 0 1.75rem;
}

h2 {
  font-family: Georgia, "Times New Roman", serif;
  font-size: 1.4rem;
  margin: 2.75rem 0 1rem;
  padding-top: 2rem;
  border-top: 1px solid var(--rule);
}

h3 {
  font-size: 1.05rem;
  margin: 1.75rem 0 0.5rem;
}

a { color: var(--link); }
a:hover { color: #000; }

section p { margin: 0.75rem 0; }

.section-note {
  color: var(--muted);
  font-size: 0.95rem;
  margin-top: -0.5rem;
}

/* Featured story cards — kept compact so one card is roughly the height
   of two Latest-articles items in the right column. */
.feature {
  margin: 0 0 1.75rem;
}

.feature img {
  width: 100%;
  height: 170px;
  object-fit: cover;
  display: block;
  margin-bottom: 0.7rem;
}

.feature h3 {
  font-family: Georgia, "Times New Roman", serif;
  font-size: 1.2rem;
  font-style: italic;
  margin: 0 0 0.25rem;
  font-weight: 700;
}

.feature h3 a { text-decoration: none; }
.feature h3 a:hover { text-decoration: underline; }

.feature .outlet {
  color: var(--muted);
  font-size: 0.95rem;
  margin: 0 0 0.5rem;
}

.feature p.desc { margin: 0.5rem 0; }

.feature.placeholder {
  border: 1px dashed #ccc;
  padding: 1.25rem;
  color: var(--muted);
}

/* Latest articles list: uniform rows — fixed-size thumbnail + headline.
   Every thumbnail is cropped to identical dimensions so rows align. */
.latest-list article {
  display: flex;
  gap: 0.9rem;
  align-items: flex-start;
  margin-bottom: 1.75rem;
}

.latest-list .thumb {
  flex: 0 0 110px;
  width: 110px;
  margin: 0;
}

.latest-list .thumb img {
  width: 100%;
  height: 74px;
  object-fit: cover;
  display: block;
}

.latest-list h3 {
  font-family: Georgia, "Times New Roman", serif;
  font-size: 1.05rem;
  line-height: 1.35;
  margin: 0;
  font-weight: 700;
}

.latest-list h3 a { text-decoration: none; }
.latest-list h3 a:hover { text-decoration: underline; }

/* Link lists */
#more ul {
  list-style: none;
  padding: 0;
  margin: 0.5rem 0 0;
}

#more li { margin: 0.4rem 0; }

footer {
  margin-top: 3rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--rule);
  color: var(--muted);
  font-size: 0.9rem;
}

/* The two columns stay side-by-side at every screen size (no stacking). */
@media (max-width: 900px) {
  .columns {
    gap: 0 1.25rem;
  }
}

@media (max-width: 560px) {
  h1 { font-size: 1.6rem; }
  .site-header { gap: 1rem; }
  .site-header img {
    width: 96px;
    height: 96px;
    flex-basis: 96px;
  }
  .site-title h1 { font-size: 1.7rem; }
  .site-title p { font-size: 1rem; }
  .latest-list .thumb {
    flex-basis: 64px;
    width: 64px;
  }
  .latest-list .thumb img { height: 44px; }
  .latest-list h3 { font-size: 0.95rem; }
  .latest-list article { gap: 0.6rem; }

  /* Single-column phone layout: 5 latest, Read more button,
     Selected work (tap to reveal), then the rest of the latest. */
  .columns {
    grid-template-columns: minmax(0, 1fr);
    grid-template-areas:
      "latest-top"
      "read-more"
      "selected"
      "latest-rest";
    gap: 0;
  }
  #read-more {
    display: block;
    grid-area: read-more;
    justify-self: center;
    margin: 1.75rem 0;
    padding: 0.7rem 2.25rem;
    font-family: inherit;
    font-size: 1rem;
    background: #fff;
    color: var(--text);
    border: 1px solid #bbb;
    border-radius: 999px;
    cursor: pointer;
  }
  #read-more:hover { border-color: #888; }
  #selected { display: none; }
  #selected h2 { margin-top: 1rem; }
  .columns.expanded #selected { display: block; }
  .continued-heading { display: block; }
}
