/* Arch Street Press — one-ink design: the logo's blue on white paper. */

@font-face {
  font-family: "Literata";
  src: url("/fonts/literata-latin-wght-normal.woff2") format("woff2");
  font-weight: 200 900;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Literata";
  src: url("/fonts/literata-latin-wght-italic.woff2") format("woff2");
  font-weight: 200 900;
  font-style: italic;
  font-display: swap;
}
@font-face {
  font-family: "Barlow Condensed";
  src: url("/fonts/barlow-condensed-latin-500-normal.woff2") format("woff2");
  font-weight: 500;
  font-display: swap;
}
@font-face {
  font-family: "Barlow Condensed";
  src: url("/fonts/barlow-condensed-latin-600-normal.woff2") format("woff2");
  font-weight: 600;
  font-display: swap;
}

:root {
  --blue: #2975b1;       /* logo ink */
  --blue-deep: #17476f;  /* hover, pressed */
  --ink: #1c2633;        /* body text */
  --ink-soft: #4a5868;   /* secondary text */
  --tint: #eaf2f9;       /* 10% screen of the ink */
  --rule: #c5d8ea;
  --paper: #ffffff;

  --serif: "Literata", Georgia, "Times New Roman", serif;
  --cond: "Barlow Condensed", "Arial Narrow", "Helvetica Neue", Arial, sans-serif;

  --measure: 36rem;
  --wide: 72rem;
  --gutter: clamp(1.25rem, 4vw, 2.5rem);
  --shelf-h: clamp(150px, 13vw, 205px);
}

*, *::before, *::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--serif);
  font-size: 1.1875rem;
  line-height: 1.65;
  font-optical-sizing: auto;
  text-rendering: optimizeLegibility;
}

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

a { color: var(--blue); text-decoration-thickness: 1px; text-underline-offset: 0.18em; }
a:hover { color: var(--blue-deep); text-decoration-thickness: 2px; }
:focus-visible { outline: 3px solid var(--blue); outline-offset: 3px; border-radius: 2px; }

h1, h2, h3, h4 { font-family: var(--serif); color: var(--ink); line-height: 1.15; margin: 0 0 0.6em; }
h1 { font-size: clamp(2.3rem, 5vw, 3.4rem); font-weight: 600; letter-spacing: -0.015em; }
h2 { font-size: clamp(1.6rem, 3vw, 2.1rem); font-weight: 600; letter-spacing: -0.01em; }
h3 { font-size: 1.3rem; font-weight: 600; }
p { margin: 0 0 1em; }

.wrap { max-width: var(--wide); margin: 0 auto; padding: 0 var(--gutter); }

.skip {
  position: absolute; left: -999px; top: 0.5rem;
  background: var(--blue); color: #fff; padding: 0.5rem 1rem; font-family: var(--cond); z-index: 10;
}
.skip:focus { left: 0.5rem; }

/* ---------- header ---------- */
.site-header { border-bottom: 1px solid var(--rule); }
.header-inner {
  display: flex; align-items: center; justify-content: space-between; gap: 1rem 2rem;
  flex-wrap: wrap; padding-top: 1.1rem; padding-bottom: 1.1rem;
}
.brand img { height: 40px; width: auto; }
.site-header ul { display: flex; flex-wrap: wrap; gap: 0.25rem 1.6rem; margin: 0; padding: 0; list-style: none; }
.site-header nav a {
  font-family: var(--cond); font-weight: 500; font-size: 1.2rem; letter-spacing: 0.02em;
  color: var(--ink); text-decoration: none; padding: 0.25rem 0; border-bottom: 2px solid transparent;
}
.site-header nav a:hover { color: var(--blue); }
.site-header nav a[aria-current="page"] { color: var(--blue); border-bottom-color: var(--blue); }

/* ---------- buttons ---------- */
.button {
  display: inline-block; font-family: var(--cond); font-weight: 600; font-size: 1.15rem; letter-spacing: 0.02em;
  line-height: 1.2; text-decoration: none; padding: 0.7rem 1.3rem;
  background: var(--blue); color: #fff; border: 2px solid var(--blue); border-radius: 2px;
}
.button:hover { background: var(--blue-deep); border-color: var(--blue-deep); color: #fff; }
.button-quiet { background: transparent; color: var(--blue); }
.button-quiet:hover { background: var(--tint); color: var(--blue-deep); border-color: var(--blue-deep); }
.actions { display: flex; flex-wrap: wrap; gap: 0.75rem; margin: 1.75rem 0; }

/* ---------- home: hero ---------- */
.hero { padding-top: clamp(3rem, 8vw, 6.5rem); }
.hero-quote { margin: 0; max-width: 54rem; }
.hero-quote p {
  font-size: clamp(2rem, 5.2vw, 4rem); line-height: 1.12; font-weight: 400; letter-spacing: -0.02em;
  margin: 0; text-indent: -0.42em;
}
.hero-quote footer {
  font-family: var(--cond); font-weight: 500; font-size: 1.15rem; color: var(--ink-soft); margin-top: 1rem;
}
.hero-answer {
  font-size: clamp(1.4rem, 2.6vw, 1.9rem); line-height: 1.3; font-weight: 600; color: var(--blue);
  margin: clamp(2rem, 5vw, 3.25rem) 0 0; max-width: 34rem;
}

/* The shelf: covers standing on one blue rule */
.shelf {
  margin-top: clamp(3rem, 7vw, 5rem);
  overflow-x: auto; scrollbar-width: thin;
}
.shelf-row {
  display: flex; align-items: flex-end; gap: clamp(0.75rem, 1.6vw, 1.5rem);
  list-style: none; margin: 0 auto; padding: 0 var(--gutter);
  width: max-content; min-width: 100%; max-width: none; justify-content: center;
  border-bottom: 10px solid var(--blue);
}
.shelf-row li { flex: none; }
.shelf-row img {
  height: var(--shelf-h); width: auto;
  box-shadow: 0 1px 0 rgba(23, 71, 111, 0.25);
  transition: transform 160ms ease-out;
}
.shelf-row a:hover img, .shelf-row a:focus-visible img { transform: translateY(-8px); }

@media (prefers-reduced-motion: no-preference) {
  .home .shelf-row li { animation: rise 600ms cubic-bezier(.2,.7,.2,1) both; }
  .home .shelf-row li:nth-child(2) { animation-delay: 60ms; }
  .home .shelf-row li:nth-child(3) { animation-delay: 120ms; }
  .home .shelf-row li:nth-child(4) { animation-delay: 180ms; }
  .home .shelf-row li:nth-child(5) { animation-delay: 240ms; }
  .home .shelf-row li:nth-child(6) { animation-delay: 300ms; }
  .home .shelf-row li:nth-child(7) { animation-delay: 360ms; }
  .home .shelf-row li:nth-child(8) { animation-delay: 420ms; }
  @keyframes rise { from { opacity: 0; transform: translateY(24px); } to { opacity: 1; transform: none; } }
}
@media (prefers-reduced-motion: reduce) {
  .shelf-row img { transition: none; }
}

/* ---------- sections ---------- */
.section { padding: clamp(3.5rem, 8vw, 6rem) 0; }
.section-tint { background: var(--tint); }
.section-rule { border-top: 1px solid var(--rule); }
.prose { max-width: var(--measure); }
.wrap.prose { max-width: var(--wide); }
.wrap.prose > * { max-width: var(--measure); }
.wrap.prose > h1 { max-width: none; }
.prose > :last-child { margin-bottom: 0; }

.two-col { display: grid; gap: clamp(2rem, 5vw, 4.5rem); grid-template-columns: minmax(0, 1fr); }
@media (min-width: 900px) {
  .two-col { grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr); align-items: start; }
}
.pull-quote { margin: 0; padding-left: 1.5rem; border-left: 3px solid var(--blue); }
.pull-quote p { font-style: italic; font-size: 1.3rem; line-height: 1.5; }
.pull-quote footer { font-family: var(--cond); font-weight: 500; font-size: 1.15rem; color: var(--ink-soft); }

.prize-amount {
  font-size: clamp(3rem, 8vw, 5rem); line-height: 1; font-weight: 300; color: var(--blue);
  letter-spacing: -0.03em; margin: 0 0 1.25rem; font-variant-numeric: oldstyle-nums;
}

.process {
  list-style: none; margin: 2rem 0 0; padding: 0; counter-reset: step;
  display: grid; gap: 2.25rem 3rem; grid-template-columns: minmax(0, 1fr);
}
@media (min-width: 640px) { .process { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (min-width: 1080px) { .process { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 2rem 2.25rem; } }
.process li { counter-increment: step; }
.process li::before {
  content: counter(step); display: block; font-size: 2.6rem; line-height: 1; font-weight: 300;
  color: var(--blue); margin-bottom: 0.6rem; font-variant-numeric: oldstyle-nums;
}
.process h3 { margin-bottom: 0.4em; }
.process p { font-size: 1.05rem; color: var(--ink-soft); margin: 0; }

/* ---------- generic page ---------- */
.page { padding-top: clamp(2.5rem, 6vw, 4.5rem); padding-bottom: clamp(3.5rem, 8vw, 6rem); }
.lede { font-size: clamp(1.25rem, 2.2vw, 1.45rem); line-height: 1.45; color: var(--ink-soft); max-width: 40rem; }
.crumb { font-family: var(--cond); font-weight: 500; font-size: 1.1rem; margin-bottom: 1.5rem; }
.crumb a { text-decoration: none; }
.crumb a::before { content: "‹ "; }

/* ---------- titles: a bookcase ---------- */
.bookcase {
  list-style: none; margin: 3rem 0 0; padding: 0;
  display: grid; gap: 3rem 2rem; grid-template-columns: repeat(auto-fill, minmax(11rem, 1fr));
}
.title-card a { display: block; text-decoration: none; color: var(--ink); }
.title-cover {
  display: flex; align-items: flex-end; height: 17rem; padding-bottom: 0;
  border-bottom: 6px solid var(--blue);
}
.title-cover img { max-height: 100%; width: auto; max-width: 100%; transition: transform 160ms ease-out; }
.title-card a:hover img, .title-card a:focus-visible img { transform: translateY(-6px); }
.title-name { display: block; font-weight: 600; font-size: 1.1rem; line-height: 1.3; margin-top: 0.9rem; }
.title-card a:hover .title-name { color: var(--blue); }
.title-author { display: block; font-family: var(--cond); font-weight: 500; font-size: 1.05rem; color: var(--ink-soft); margin-top: 0.25rem; }
@media (max-width: 520px) {
  .bookcase { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 2.25rem 1.25rem; }
  .title-cover { height: 13rem; }
}

/* ---------- book page ---------- */
.book-grid { display: grid; gap: 2.5rem 4rem; grid-template-columns: minmax(0, 1fr); }
@media (min-width: 820px) {
  .book-grid { grid-template-columns: minmax(14rem, 22rem) minmax(0, 1fr); align-items: start; }
  .book-cover { position: sticky; top: 2rem; }
}
.book-cover img { width: 100%; max-width: 22rem; box-shadow: 0 18px 40px -24px rgba(23, 71, 111, 0.6); }
.book h1 { margin-bottom: 0.25em; }
.book-subtitle { font-size: 1.35rem; line-height: 1.35; font-style: italic; color: var(--ink-soft); margin-bottom: 0.75rem; }
.book-byline { font-family: var(--cond); font-weight: 600; font-size: 1.3rem; color: var(--blue); }
.book-about { margin-top: 3rem; padding-top: 2rem; border-top: 1px solid var(--rule); }
.people { display: flex; flex-wrap: wrap; gap: 1.5rem; margin: 0 0 1.5rem; }
.person { margin: 0; width: 9rem; }
.person img { width: 9rem; height: 9rem; object-fit: cover; object-position: center 25%; }
.person figcaption { font-family: var(--cond); font-weight: 500; font-size: 1rem; color: var(--ink-soft); margin-top: 0.4rem; line-height: 1.25; }

/* ---------- blog ---------- */
.jump { display: flex; gap: 1.5rem; font-family: var(--cond); font-weight: 600; font-size: 1.15rem; margin: 1.5rem 0 0; }
.blog-section { margin-top: clamp(3rem, 7vw, 4.5rem); scroll-margin-top: 1.5rem; }
.blog-section > h2 { padding-bottom: 0.6rem; border-bottom: 3px solid var(--blue); }
.winner-group { margin-top: 2.5rem; }
.winner-group h3 { font-family: var(--cond); font-weight: 600; font-size: 1.35rem; color: var(--blue); letter-spacing: 0.01em; }
.entries {
  list-style: none; margin: 1.25rem 0 0; padding: 0;
  display: grid; gap: 2.25rem 2.5rem; grid-template-columns: repeat(auto-fill, minmax(19rem, 1fr));
}
.entry > a { display: block; text-decoration: none; color: var(--ink); }
.entry-thumb { display: block; aspect-ratio: 3 / 2; overflow: hidden; background: var(--tint); margin-bottom: 0.9rem; }
.entry-thumb img { width: 100%; height: 100%; object-fit: cover; }
.entry-title { display: block; font-size: 1.3rem; font-weight: 600; line-height: 1.25; }
.entry > a:hover .entry-title { color: var(--blue); text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 0.18em; }
.entry-author { font-family: var(--cond); font-weight: 500; font-size: 1.1rem; color: var(--blue); margin: 0.3rem 0 0; }
.entry-excerpt { font-size: 1rem; line-height: 1.55; color: var(--ink-soft); margin: 0.5rem 0 0; }

.post { max-width: 48rem; }
.post h1 { margin-bottom: 0.3em; }
.post-author { font-family: var(--cond); font-weight: 600; font-size: 1.35rem; color: var(--blue); margin-bottom: 0; }
.post-hero { margin: 2rem 0 2.5rem; }
.post-hero img { width: 100%; max-height: 32rem; object-fit: cover; }
.post-body { max-width: var(--measure); }
.post-body img { margin: 2rem 0; }
.post-body h2 { font-size: 1.5rem; margin-top: 2em; }
.post-body h2.bio-heading {
  font-family: var(--cond); font-weight: 600; font-size: 1.3rem; color: var(--blue);
  margin-top: 3rem; padding-top: 1.5rem; border-top: 1px solid var(--rule);
}
.post-body h2.bio-heading ~ p { font-size: 1.02rem; color: var(--ink-soft); }
.post-body blockquote { margin: 1.5em 0; padding-left: 1.25rem; border-left: 3px solid var(--rule); font-style: italic; }
.post-body .center { text-align: center; }

/* ---------- contact ---------- */


.contact-email { font-size: clamp(1.3rem, 3vw, 1.7rem); font-weight: 600; overflow-wrap: anywhere; }


/* ---------- footer ---------- */
.site-footer { background: var(--blue); color: #fff; margin-top: 0; }
.footer-inner {
  display: grid; gap: 1.5rem 4rem; padding-top: 3rem; padding-bottom: 3rem;
  grid-template-columns: minmax(0, 1fr);
  font-size: 0.98rem; line-height: 1.6;
}
@media (min-width: 820px) { .footer-inner { grid-template-columns: minmax(0, 2fr) minmax(0, 1fr); } }
.site-footer a { color: #fff; }
.site-footer a:hover { color: #fff; text-decoration-thickness: 2px; }
.site-footer :focus-visible { outline-color: #fff; }
.footer-about { max-width: 40rem; margin: 0; }
.footer-contact p { margin: 0 0 0.75rem; }
.footer-copy { font-family: var(--cond); font-weight: 500; font-size: 1.05rem; margin: 0; opacity: 0.85; }

@media (max-width: 640px) {
  body { font-size: 1.125rem; }
  .brand img { height: 34px; }
  .site-header ul { gap: 0.25rem 1.1rem; }
}
