/* ===================
  This is the shared look for the site's pages — the paper-white background,
  green ink, Comico headings, pill buttons, and click-to-enlarge lightbox — so
  every page matches the Illustrations page.
  =================== */

/* --------------------------------------------------------------------------- */
/* Fonts */
/* --------------------------------------------------------------------------- */

@font-face {
  font-family: 'Comico';
  src: url('fonts/comico-regular.woff2') format('woff2'),
       url('fonts/comico-regular.woff') format('woff');
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

/* --------------------------------------------------------------------------- */
/* Base and page layout */
/* --------------------------------------------------------------------------- */

* { box-sizing: border-box; }
html, body { height: 100%; margin: 0; }
body {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 2.5rem 1.5rem 2rem;
  background: #ffffff;
  color: #28381b;
  font-family: "Iowan Old Style", "Palatino Linotype", Palatino, Georgia, "Times New Roman", serif;
  text-align: center;
  overflow-x: hidden;
}

/* --------------------------------------------------------------------------- */
/* Headings and captions */
/* --------------------------------------------------------------------------- */

h1 {
  margin: 0;
  font-family: 'Comico', "Iowan Old Style", "Palatino Linotype", Palatino, Georgia, "Times New Roman", serif;
  font-weight: 400;
  font-size: clamp(2rem, 6vw, 3.5rem);
  letter-spacing: 0.02em;
}
.subtitle {
  margin: 0.5rem 0 0;
  font-size: clamp(0.8rem, 2.4vw, 1rem);
  letter-spacing: 0.28em;
  text-transform: uppercase;
  opacity: 0.75;
}
.hint {
  margin: 2.5rem 0 0;
  font-size: 0.72rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  opacity: 0.45;
}
@media (prefers-reduced-motion: reduce) {
  .hint { display: none; }
}

/* --------------------------------------------------------------------------- */
/* Back-to-home pill */
/* --------------------------------------------------------------------------- */

a.back {
  display: inline-block;
  margin-top: 1.75rem;
  padding: 0.55rem 1.4rem;
  color: #fbfaf3;
  background: #28381b;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  font-size: 0.8rem;
  font-weight: 700;
  text-decoration: none;
  border-radius: 999px;
  transition: background 0.2s ease;
}
a.back:hover { background: #35471f; }

/* --------------------------------------------------------------------------- */
/* Click-to-enlarge lightbox */
/* --------------------------------------------------------------------------- */

.lightbox {
  position: fixed;
  inset: 0;
  z-index: 9999;
  display: grid;
  place-items: center;
  padding: 5vh 5vw;
  background: rgba(8, 12, 6, 0.88);
  -webkit-backdrop-filter: blur(3px);
  backdrop-filter: blur(3px);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.28s ease;
}
.lightbox.open { opacity: 1; pointer-events: auto; }
.lightbox figure {
  margin: 0;
  text-align: center;
  transform: scale(0.9);
  transition: transform 0.28s ease;
}
.lightbox.open figure { transform: scale(1); }
.lightbox img {
  display: block;
  max-width: 88vw;
  max-height: 78vh;
  width: auto;
  height: auto;
  object-fit: contain;
  border: 8px solid #fbfaf3;
  border-radius: 4px;
  background: #28381b;
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.6);
}
.lb-close {
  position: fixed;
  top: 1.2rem;
  right: 1.4rem;
  width: 2.6rem;
  height: 2.6rem;
  border-radius: 50%;
  border: 1px solid rgba(251, 250, 243, 0.5);
  background: rgba(0, 0, 0, 0.3);
  color: #fbfaf3;
  font-size: 1.5rem;
  line-height: 1;
  cursor: pointer;
  display: grid;
  place-items: center;
  transition: background 0.2s ease;
}
.lb-close:hover { background: rgba(0, 0, 0, 0.55); }
.lb-nav {
  position: fixed;
  top: 50%;
  transform: translateY(-50%);
  width: 3rem;
  height: 3rem;
  border-radius: 50%;
  border: 1px solid rgba(251, 250, 243, 0.5);
  background: rgba(0, 0, 0, 0.3);
  color: #fbfaf3;
  font-size: 1.7rem;
  line-height: 1;
  cursor: pointer;
  display: grid;
  place-items: center;
  z-index: 10000;
  transition: background 0.2s ease;
}
.lb-nav:hover { background: rgba(0, 0, 0, 0.55); }
.lb-prev { left: 1.2rem; }
.lb-next { right: 1.2rem; }

/* --------------------------------------------------------------------------- */
/* Footer */
/* --------------------------------------------------------------------------- */

.site-footer { margin-top: auto; width: 100%; display: flex; justify-content: flex-end; padding-top: 22px; }
.site-copyright { margin: 0; font-size: 0.78rem; letter-spacing: 0.04em; opacity: 0.65; }
