/* Montserrat stands in for Proxima Nova, Bitter for Adelle.
   Both are variable fonts, self-hosted so the site makes no external requests. */

@font-face {
  font-family: "Montserrat";
  src: url("fonts/montserrat.woff2") format("woff2");
  font-weight: 100 900;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "Bitter";
  src: url("fonts/bitter.woff2") format("woff2");
  font-weight: 100 900;
  font-style: normal;
  font-display: swap;
}

:root {
  --bg: #fafaf7;
  --ink: #1c1c1a;
  --muted: #7c7973;
  --hair: #e6e4de;
  --serif: "Bitter", "Iowan Old Style", Georgia, serif;
  --sans: "Montserrat", "Helvetica Neue", Helvetica, Arial, sans-serif;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #151514;
    --ink: #e9e7e2;
    --muted: #96938c;
    --hair: #2b2a28;
  }
}

* { box-sizing: border-box; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 1rem;
  font-weight: 450;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}

/* Layout: fixed sidebar left, content column right */

.layout {
  display: grid;
  grid-template-columns: 13rem minmax(0, 1fr);
  gap: 5rem;
  max-width: 85rem;
  margin: 0 auto;
  padding: 3.2rem 2.5rem 0;
}

aside.side {
  position: sticky;
  top: 3.2rem;
  align-self: start;
}

.wordmark {
  display: block;
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--ink);
  text-decoration: none;
  margin: 0 0 2.6rem;
}

nav.side {
  display: flex;
  flex-direction: column;
  gap: 0.7rem;
}

nav.side a {
  font-size: 0.85rem;
  font-weight: 550;
  color: var(--muted);
  text-decoration: none;
  width: max-content;
}

nav.side a:hover,
nav.side a[aria-current="page"] { color: var(--ink); }

nav.side.secondary { margin-top: 2rem; }

@media (max-width: 820px) {
  .layout {
    display: block;
    padding: 2.2rem 1.5rem 0;
  }
  aside.side { position: static; margin-bottom: 3rem; }
  .wordmark { margin-bottom: 1.2rem; }
  nav.side { flex-direction: row; flex-wrap: wrap; gap: 0.6rem 1.5rem; }
}

/* Section headings */

h1.section,
h2.sub {
  font-size: 0.95rem;
  font-weight: 650;
  text-align: center;
  margin: 1rem 0 3rem;
}

.private-section { margin-top: 6rem; }

/* Images */

figure { margin: 0; }

figure img {
  display: block;
  width: 100%;
  height: auto;
}

figcaption {
  margin-top: 0.7rem;
  font-size: 0.8rem;
  font-weight: 500;
  color: var(--muted);
}

/* Cover photo on the front page */

.cover a { display: block; }
.cover a:hover img { opacity: 0.94; }

/* Tile grid: uniform three across, centered captions */

.tiles {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 3rem 2rem;
}

.tiles a {
  display: block;
  text-decoration: none;
  color: inherit;
}

.tiles img {
  width: 100%;
  display: block;
}

.tiles a:hover img { opacity: 0.88; }

.tiles figcaption { text-align: center; }

/* One photo: show it big and centered. Two: side by side. Three+: the grid. */

.tiles.tiles-1 {
  display: block;
  max-width: 46rem;
  margin: 0 auto;
}

.tiles.tiles-2 {
  grid-template-columns: 1fr 1fr;
  max-width: 58rem;
  margin: 0 auto;
}

@media (max-width: 560px) {
  .tiles { grid-template-columns: 1fr; gap: 2.8rem; }
}

@media (min-width: 561px) and (max-width: 820px) {
  .tiles { grid-template-columns: 1fr 1fr; }
}

/* Fullscreen photo viewer: left half = previous, right half = next */

.viewer {
  position: fixed;
  inset: 0;
  background: #0f0f0e;
}

.viewer img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: contain;
  padding: 2.75rem;
}

.viewer .prev,
.viewer .next {
  position: absolute;
  top: 0;
  bottom: 0;
  width: 50%;
  display: flex;
  align-items: center;
  color: rgba(255, 255, 255, 0.4);
  font-size: 2.4rem;
  font-weight: 300;
  text-decoration: none;
}

.viewer .prev { left: 0; justify-content: flex-start; padding-left: 1.1rem; }
.viewer .next { right: 0; justify-content: flex-end; padding-right: 1.1rem; }
.viewer .prev::after { content: "\2039"; }
.viewer .next::after { content: "\203A"; }
.viewer .prev:hover,
.viewer .next:hover { color: rgba(255, 255, 255, 0.85); }

.viewer .play {
  position: absolute;
  top: 1rem;
  right: 3.8rem;
  z-index: 2;
  color: rgba(255, 255, 255, 0.6);
  font-size: 1.15rem;
  line-height: 1.5;
  letter-spacing: -0.12em;
  text-decoration: none;
}

.viewer .play:hover { color: rgba(255, 255, 255, 0.95); }

.playlink {
  text-align: center;
  margin: -1.6rem 0 2.6rem;
  font-size: 0.8rem;
  font-weight: 500;
}

.playlink a {
  color: var(--muted);
  text-decoration: none;
  border-bottom: 1px solid var(--hair);
  padding-bottom: 0.15rem;
}

.playlink a:hover { color: var(--ink); }

.viewer .close {
  position: absolute;
  top: 0.9rem;
  right: 1.3rem;
  z-index: 2;
  color: rgba(255, 255, 255, 0.6);
  font-size: 1.8rem;
  line-height: 1;
  text-decoration: none;
}

.viewer .close:hover { color: rgba(255, 255, 255, 0.95); }

.viewer .cap {
  position: absolute;
  left: 1.3rem;
  bottom: 0.9rem;
  margin: 0;
  color: rgba(255, 255, 255, 0.65);
  font-size: 0.8rem;
  font-weight: 500;
}

/* Videos: embedded players, one calm column */

.videos {
  max-width: 52rem;
  margin: 0 auto;
  display: grid;
  gap: 3rem;
}

.tiles + .videos,
.text-page + .videos { margin-top: 4rem; }

.videos iframe {
  width: 100%;
  aspect-ratio: 16 / 9;
  border: 0;
  display: block;
  background: #000;
}

.videos figcaption { text-align: center; }

/* Texts and poems */

ul.textlist {
  list-style: none;
  margin: 0;
  padding: 0;
}

ul.textlist li { border-top: 1px solid var(--hair); }
ul.textlist li:last-child { border-bottom: 1px solid var(--hair); }

ul.textlist a {
  display: block;
  padding: 1.4rem 0;
  text-decoration: none;
  color: var(--ink);
}

ul.textlist .title {
  font-family: var(--serif);
  font-size: 1.3rem;
}

ul.textlist a:hover .title { color: var(--muted); }

.text-page {
  max-width: 34rem;
  margin: 0 auto;
  padding: 1rem 0 2rem;
}

.text-page h1 {
  font-family: var(--serif);
  font-weight: 500;
  font-size: 1.7rem;
  margin: 0 0 2.2rem;
}

.poem {
  font-family: var(--serif);
  font-size: 1.15rem;
  font-weight: 400;
  line-height: 1.95;
  white-space: pre-line;
}

/* About */

.about {
  display: grid;
  grid-template-columns: 5fr 7fr;
  gap: 3.5rem;
  align-items: start;
}

@media (max-width: 700px) {
  .about { grid-template-columns: 1fr; }
}

/* About without a portrait: just a calm text column */

.about.solo {
  display: block;
  max-width: 38rem;
  margin: 0 auto;
}

.about .bio p {
  font-family: var(--serif);
  font-size: 1.1rem;
  font-weight: 400;
  line-height: 1.85;
  margin: 0 0 1.4rem;
}

.about .contact {
  font-size: 0.85rem;
  font-weight: 550;
  color: var(--muted);
  margin-top: 2.5rem;
}

.about .contact a {
  color: var(--ink);
  text-decoration: none;
  border-bottom: 1px solid var(--hair);
  padding-bottom: 0.15rem;
}

/* Private gate note */

.gate-note {
  display: block;
  width: max-content;
  max-width: 100%;
  margin: 0 auto 4rem;
  font-size: 0.8rem;
  font-weight: 500;
  color: var(--muted);
  border: 1px solid var(--hair);
  padding: 0.5rem 0.95rem;
}

/* Footer */

footer.site {
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 0.75rem 2rem;
  border-top: 1px solid var(--hair);
  margin-top: 6rem;
  padding: 2rem 0 3.2rem;
  font-size: 0.78rem;
  font-weight: 450;
  color: var(--muted);
}

footer.site a { color: var(--muted); text-decoration: none; }
footer.site a:hover { color: var(--ink); }

/* 404 */

.lost {
  max-width: 34rem;
  margin: 5rem auto;
  text-align: center;
  font-family: var(--serif);
  font-size: 1.2rem;
}

.lost a { color: inherit; }

/* Crossfade slideshow: all slides stacked, opacity animated. No scripts. */

.fader { position: relative; overflow: hidden; }
.fader img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; opacity: 0; }
.cover .fader { aspect-ratio: 3 / 2; }
.viewer .fader { position: absolute; inset: 0; }
.viewer .fader img { padding: 2.75rem; }

.fader img:nth-child(1) { animation-delay: 0.0s; }
.fader img:nth-child(2) { animation-delay: 6.0s; }
.fader img:nth-child(3) { animation-delay: 12.0s; }
.fader img:nth-child(4) { animation-delay: 18.0s; }
.fader img:nth-child(5) { animation-delay: 24.0s; }
.fader img:nth-child(6) { animation-delay: 30.0s; }
.fader img:nth-child(7) { animation-delay: 36.0s; }
.fader img:nth-child(8) { animation-delay: 42.0s; }
.fader img:nth-child(9) { animation-delay: 48.0s; }
.fader img:nth-child(10) { animation-delay: 54.0s; }

.fader.n2 img { animation: fade2 12.0s ease-in-out infinite; }
@keyframes fade2 { 0% { opacity: 0; } 15.0% { opacity: 1; } 50.0% { opacity: 1; } 65.0% { opacity: 0; } 100% { opacity: 0; } }
.fader.n3 img { animation: fade3 18.0s ease-in-out infinite; }
@keyframes fade3 { 0% { opacity: 0; } 10.0% { opacity: 1; } 33.333% { opacity: 1; } 43.333% { opacity: 0; } 100% { opacity: 0; } }
.fader.n4 img { animation: fade4 24.0s ease-in-out infinite; }
@keyframes fade4 { 0% { opacity: 0; } 7.5% { opacity: 1; } 25.0% { opacity: 1; } 32.5% { opacity: 0; } 100% { opacity: 0; } }
.fader.n5 img { animation: fade5 30.0s ease-in-out infinite; }
@keyframes fade5 { 0% { opacity: 0; } 6.0% { opacity: 1; } 20.0% { opacity: 1; } 26.0% { opacity: 0; } 100% { opacity: 0; } }
.fader.n6 img { animation: fade6 36.0s ease-in-out infinite; }
@keyframes fade6 { 0% { opacity: 0; } 5.0% { opacity: 1; } 16.667% { opacity: 1; } 21.667% { opacity: 0; } 100% { opacity: 0; } }
.fader.n7 img { animation: fade7 42.0s ease-in-out infinite; }
@keyframes fade7 { 0% { opacity: 0; } 4.286% { opacity: 1; } 14.286% { opacity: 1; } 18.571% { opacity: 0; } 100% { opacity: 0; } }
.fader.n8 img { animation: fade8 48.0s ease-in-out infinite; }
@keyframes fade8 { 0% { opacity: 0; } 3.75% { opacity: 1; } 12.5% { opacity: 1; } 16.25% { opacity: 0; } 100% { opacity: 0; } }
.fader.n9 img { animation: fade9 54.0s ease-in-out infinite; }
@keyframes fade9 { 0% { opacity: 0; } 3.333% { opacity: 1; } 11.111% { opacity: 1; } 14.444% { opacity: 0; } 100% { opacity: 0; } }
.fader.n10 img { animation: fade10 60.0s ease-in-out infinite; }
@keyframes fade10 { 0% { opacity: 0; } 3.0% { opacity: 1; } 10.0% { opacity: 1; } 13.0% { opacity: 0; } 100% { opacity: 0; } }
