:root {
  color-scheme: dark;
  --wall: #0d0f13;
  --dot-a: #2b1d22;
  --dot-b: #231a1e;
  --page: #13161c;
  --panel: #1e222a;
  --line: #2c313b;
  --text: #dad4c6;
  --muted: #bdb6a6;
  --faint: #9a9384;
  --strong: #f2ede1;
  --gold: #c9a962;
  --gold-hover: #e2c98c;
  --serif-display: "Cormorant Garamond", Georgia, serif;
  --serif-body: "EB Garamond", Georgia, serif;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  background-color: var(--wall);
  background-image:
    radial-gradient(circle at 14px 14px, var(--dot-a) 2.5px, transparent 3.5px),
    radial-gradient(circle at 42px 42px, var(--dot-b) 5px, transparent 6px);
  background-size: 56px 56px;
  color: var(--text);
  font-family: var(--serif-body);
  font-size: 21px;
  line-height: 1.6;
}

a { color: var(--gold); text-decoration: none; }
a:hover { color: var(--gold-hover); }
b { color: var(--strong); }

main {
  max-width: 880px;
  min-height: 100vh;
  margin: 0 auto;
  padding: 96px 80px 160px;
  background: var(--page);
  display: flex;
  flex-direction: column;
  gap: 56px;
}

header { display: flex; flex-direction: column; gap: 14px; }

h1, h2 { font-family: var(--serif-display); font-weight: 600; margin: 0; }
h1 { font-size: 76px; line-height: 1; color: var(--strong); }

.tagline { margin: 0; font-size: 24px; font-style: italic; color: var(--muted); }

/* Home */
.portrait { display: flex; align-items: center; gap: 32px; }
.portrait svg { flex-shrink: 0; }
.photo {
  flex-grow: 1;
  height: 400px;
  border-radius: 18px;
  background: var(--panel);
  border: 1px solid var(--line);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 17px;
  color: var(--faint);
  object-fit: cover;
}

.about { display: flex; flex-direction: column; gap: 22px; }
.about h2 { font-size: 40px; color: var(--gold); margin-bottom: 4px; }
.about p { margin: 0; }

/* Pro */
.entries { display: flex; flex-direction: column; }
.entry {
  display: grid;
  grid-template-columns: 120px minmax(0, 1fr);
  gap: 32px;
  padding: 32px 0;
  border-top: 1px solid var(--line);
}
.entry:last-child { border-bottom: 1px solid var(--line); }
.entry .date { font-size: 17px; font-style: italic; color: var(--faint); }
.entry .body { display: flex; flex-direction: column; gap: 10px; }
.entry h2 { font-size: 34px; color: var(--gold); }
.entry p { margin: 0; font-size: 20px; }
.entry .subtitle { font-style: italic; color: var(--strong); }
.entry .more { font-size: 18px; font-style: italic; }
.entry .body { gap: 16px; }
.entry .label { font-size: 14px; letter-spacing: 0.12em; text-transform: uppercase; color: var(--faint); }
.entry h2 { line-height: 1.15; text-wrap: balance; }
.entry ul { margin: 0; padding-left: 22px; font-size: 20px; display: flex; flex-direction: column; gap: 8px; }
.entry .links { display: flex; flex-wrap: wrap; gap: 24px; }
.figure {
  display: block;
  width: 100%;
  max-width: 100%;
  height: auto;
  box-sizing: border-box;
  padding: 12px;
  background: #fbfaf6;
  border-radius: 12px;
}
.figure.placeholder {
  height: 220px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--panel);
  border: 1px solid var(--line);
  font-size: 16px;
  color: var(--faint);
}

.figure.cover { padding: 0; background: none; }

/* Project list */
.projects { display: flex; flex-direction: column; gap: 64px; }
.card-pro { display: flex; flex-direction: column; gap: 14px; }
.card-pro h2 { font-size: 34px; line-height: 1.15; text-wrap: balance; }
.card-pro h2 a { color: var(--gold); }
.card-pro h2 a:hover { color: var(--gold-hover); }
.card-pro a:hover .figure { opacity: 0.9; }
.meta { display: flex; justify-content: space-between; align-items: baseline; }
.meta .label { font-size: 14px; letter-spacing: 0.12em; text-transform: uppercase; color: var(--faint); }
.meta .date { font-size: 17px; font-style: italic; color: var(--faint); }

/* Project page */
.back { font-size: 18px; font-style: italic; }
.project { display: flex; flex-direction: column; gap: 20px; }
.project h1 { font-size: 52px; line-height: 1.08; text-wrap: balance; }
.project p { margin: 0; }
.project .subtitle { font-style: italic; color: var(--strong); }
.project ul { margin: 0; padding-left: 22px; display: flex; flex-direction: column; gap: 8px; }
.project .links { display: flex; flex-wrap: wrap; gap: 24px; font-size: 19px; font-style: italic; }

.note { margin: 0; font-size: 20px; font-style: italic; color: var(--muted); }
.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

/* Hobby */
.cards { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 28px; }
.card { display: flex; flex-direction: column; gap: 12px; }
.card .image {
  height: 200px;
  border-radius: 14px;
  background: var(--panel);
  border: 1px solid var(--line);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
  color: var(--faint);
}
.card h2 { font-size: 30px; color: var(--gold); }
.card p { margin: 0; font-size: 19px; line-height: 1.55; }

/* Floating menu */
.dock {
  position: fixed;
  left: 50%;
  bottom: 28px;
  transform: translateX(-50%);
  display: flex;
  gap: 6px;
  padding: 8px;
  background: #1a1d24;
  border: 1px solid #2f3440;
  border-radius: 22px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
}
.dock a {
  width: 52px;
  height: 52px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 16px;
  color: var(--text);
}
.dock a:hover { background: #242832; color: var(--strong); }
.dock a[aria-current="page"] { background: #2a2f39; color: var(--strong); }
.dock .in { font-family: Arial, sans-serif; font-weight: 700; font-size: 22px; }

@media (max-width: 720px) {
  body { font-size: 19px; }
  main { padding: 56px 20px 140px; gap: 40px; }
  h1 { font-size: 52px; }
  .project h1 { font-size: 36px; }
  .card-pro h2 { font-size: 28px; }
  .portrait svg { display: none; }
  .photo { height: 300px; }
  .entry { grid-template-columns: 1fr; gap: 8px; }
  .cards { grid-template-columns: 1fr; }
}

/* Contact form */
.contact { display: flex; flex-direction: column; gap: 22px; scroll-margin-top: 32px; }
.contact h2 { font-size: 40px; color: var(--gold); }
.contact form { display: flex; flex-direction: column; gap: 18px; }
.field { display: flex; flex-direction: column; gap: 6px; }
.field label { font-size: 16px; letter-spacing: 0.08em; text-transform: uppercase; color: var(--faint); }
.field input,
.field textarea {
  font: inherit;
  font-size: 19px;
  color: var(--strong);
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 12px 14px;
}
.field textarea { resize: vertical; }
.field input:focus,
.field textarea:focus { outline: 2px solid var(--gold); outline-offset: 1px; border-color: transparent; }
.contact button {
  align-self: flex-start;
  font: inherit;
  font-size: 19px;
  padding: 12px 28px;
  color: #13161c;
  background: var(--gold);
  border: 0;
  border-radius: 999px;
  cursor: pointer;
}
.contact button:hover { background: var(--gold-hover); }
.contact button:disabled { opacity: 0.6; cursor: default; }
.form-status { margin: 0; min-height: 1.6em; font-style: italic; color: var(--muted); }

/* Three photos side by side */
.triptych { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.triptych img {
  display: block;
  width: 100%;
  max-width: 100%;
  aspect-ratio: 3 / 4;
  object-fit: cover;
  border-radius: 10px;
}
.card-pro a:hover .triptych img { opacity: 0.9; }

/* One wide photo with the same height as a row of three */
.triptych.single { position: relative; }
.triptych.single .spacer { aspect-ratio: 3 / 4; }
.triptych.single img {
  position: absolute;
  inset: 0;
  height: 100%;
  aspect-ratio: auto;
  object-fit: cover;
}

/* A wide photo taking two of the three slots */
.triptych img.span2 { grid-column: span 2; height: 0; min-height: 100%; aspect-ratio: auto; }

/* Portrait photo: two thirds of the column, ornaments on each side */
.portrait { justify-content: center; }
img.photo { flex-grow: 0; width: 46.666%; height: auto; display: block; padding: 0; }
@media (max-width: 720px) { img.photo { width: 70%; height: auto; } }

/* Figures shown at 70% width, centred */
.figure.smaller { width: 70%; margin-inline: auto; }
