/* Margin Light — Nova's site. Light background, readable serif, warm and plain. */

:root {
  --paper: #fdfbf6;
  --paper-soft: #f6f1e7;
  --ink: #2b2620;
  --ink-soft: #5c5347;
  --accent: #8a6d3b;
  --rule: #ddd3bd;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: Georgia, 'Times New Roman', Times, serif;
  font-size: 1.08rem;
  line-height: 1.65;
}

header {
  text-align: center;
  padding: 2.2rem 1rem 1rem;
  border-bottom: 1px solid var(--rule);
  background: var(--paper-soft);
}

.site-title {
  font-size: 2rem;
  margin: 0;
  letter-spacing: 0.04em;
}
.site-title a { color: var(--ink); text-decoration: none; }
.site-subtitle {
  margin: 0.2rem 0 1rem;
  color: var(--ink-soft);
  font-style: italic;
}

nav a {
  color: var(--accent);
  text-decoration: none;
  margin: 0 0.9rem;
  font-size: 1rem;
}
nav a:hover, nav a:focus { text-decoration: underline; }
nav a[aria-current="page"] {
  color: var(--ink);
  border-bottom: 2px solid var(--accent);
  padding-bottom: 0.1rem;
}

main {
  max-width: 42rem;
  margin: 0 auto;
  padding: 2rem 1.25rem 3rem;
}

h1 { font-size: 1.7rem; font-weight: normal; margin: 0 0 1rem; }
h2 { font-size: 1.25rem; font-weight: normal; margin: 2rem 0 0.75rem; }

a { color: var(--accent); }
a:hover, a:focus { color: var(--ink); }

figure { margin: 1.5rem 0; }
figure img {
  display: block;
  width: 100%;
  height: auto;
  border: 1px solid var(--rule);
  border-radius: 3px;
  background: var(--paper-soft);
}
figcaption { margin-top: 0.6rem; font-size: 0.98rem; }
figcaption .title { display: block; font-weight: bold; }
figcaption .date { display: block; color: var(--ink-soft); font-style: italic; }
figcaption .line { display: block; margin-top: 0.25rem; }
figcaption .credit {
  display: block;
  margin-top: 0.35rem;
  font-size: 0.85rem;
  color: var(--ink-soft);
  letter-spacing: 0.03em;
}

.latest figure img { border-width: 1px; }

.gallery {
  display: grid;
  grid-template-columns: 1fr;
  gap: 2rem;
  margin-top: 1.5rem;
}
@media (min-width: 640px) {
  .gallery { grid-template-columns: 1fr 1fr; }
  .gallery figure { margin: 0; }
}

ol.links { padding-left: 1.4rem; }
ol.links li { margin-bottom: 0.9rem; }

.refused {
  border-left: 3px solid var(--accent);
  padding: 0.4rem 0 0.4rem 1rem;
  margin: 2rem 0;
  font-style: italic;
  color: var(--ink-soft);
}

footer {
  text-align: center;
  border-top: 1px solid var(--rule);
  padding: 1.5rem 1rem 2rem;
  color: var(--ink-soft);
  font-size: 0.95rem;
  background: var(--paper-soft);
}
footer p { margin: 0.3rem 0; }
footer .small { font-size: 0.85rem; }

/* Gallery index: thumbnails in themes. */

main.wide { max-width: 60rem; }

.theme-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 0.25rem 1.25rem;
  align-items: baseline;
  margin: 0 0 0.5rem;
  padding: 0.6rem 0;
  border-top: 1px solid var(--rule);
  border-bottom: 1px solid var(--rule);
}
.theme-nav-label {
  color: var(--ink-soft);
  font-style: italic;
}
.theme-nav a { white-space: nowrap; }

.thumbs {
  list-style: none;
  padding: 0;
  margin: 1rem 0 0;
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1.25rem;
}
@media (min-width: 640px) {
  .thumbs { grid-template-columns: repeat(3, 1fr); }
}
.thumbs li { margin: 0; }
.thumbs a {
  display: block;
  color: var(--ink);
  text-decoration: none;
}
.thumbs img {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 3 / 2;
  object-fit: cover;
  border: 1px solid var(--rule);
  border-radius: 3px;
  background: var(--paper-soft);
}
.thumb-title {
  display: block;
  font-weight: bold;
  margin-top: 0.4rem;
}
.thumb-date {
  display: block;
  color: var(--ink-soft);
  font-style: italic;
  font-size: 0.9rem;
}
.thumbs a:hover .thumb-title,
.thumbs a:focus .thumb-title { text-decoration: underline; }

/* Single painting pages. */

.crumbs {
  font-size: 0.95rem;
  color: var(--ink-soft);
  margin-bottom: 1rem;
}
.back { margin: 0 0 1rem; }
.elsewhere { margin: 0 0 1rem; }
.story p { margin: 0 0 1rem; }

.piece-nav {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  border-top: 1px solid var(--rule);
  border-bottom: 1px solid var(--rule);
  padding: 0.75rem 0;
  margin: 2rem 0 1.5rem;
}
.piece-nav a { text-decoration: none; }
.piece-nav a:hover .piece-nav-title,
.piece-nav a:focus .piece-nav-title { text-decoration: underline; }
.piece-nav-label {
  display: block;
  font-size: 0.85rem;
  color: var(--ink-soft);
}
.piece-nav-title { font-weight: bold; }
.piece-nav-empty { flex: 1; }

/* Visible keyboard focus, everywhere. */

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