/* =========================================================
   THE BIGGEST LIBRARY YET
   Main stylesheet

   Edit the content in index.html.
   Most visual changes can be made by changing the variables below.
   ========================================================= */

:root {
  --paper: #f3f0e8;
  --paper-deep: #e8e2d6;
  --ink: #25231f;
  --muted: #6d675d;
  --rule: #8d867a;
  --accent: #7b211d;
  --max-width: 1340px;
  --serif: Georgia, "Times New Roman", serif;
  --sans: Arial, Helvetica, sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background:
    radial-gradient(circle at top, #faf8f2 0%, var(--paper) 48%, var(--paper-deep) 100%);
  color: var(--ink);
  font-family: var(--serif);
  line-height: 1.45;
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.site-header,
main,
.site-footer {
  width: min(calc(100% - 40px), var(--max-width));
  margin: 0 auto;
}

.site-header {
  padding: 0 0 42px;
}

.logo-image {
  display: block;
  width: 100%;
  height: auto;
  max-height: 385px;
  object-fit: cover;
  object-position: center top;
  box-shadow: 0 12px 30px rgba(50, 35, 20, 0.18);
}

.tagline {
  display: grid;
  grid-template-columns: minmax(80px, 1fr) minmax(320px, 760px) minmax(80px, 1fr);
  align-items: center;
  gap: 34px;
  margin: 18px 65px 0;
}

.tagline span {
  height: 1px;
  background: var(--rule);
}

.tagline p {
  margin: 0;
  text-align: center;
  font-size: clamp(1.1rem, 2vw, 1.45rem);
  letter-spacing: 0.02em;
}

section {
  border-bottom: 1px solid var(--rule);
}

.about {
  display: grid;
  grid-template-columns: 32% 68%;
  padding: 30px 0 28px;
}

.section-label {
  padding: 0 36px 0 25px;
}

.section-label h2,
.projects-heading h2 {
  margin: 0;
  font-family: var(--serif);
  font-size: 1.05rem;
  text-transform: uppercase;
  letter-spacing: 0.28em;
}

.about-copy {
  max-width: 700px;
  padding-right: 50px;
}

.about-copy p {
  margin: 0 0 15px;
  font-size: 1.06rem;
}

.about-copy .cessation {
  margin-top: 18px;
  font-style: italic;
}

.projects {
  padding: 25px 0 28px;
}

.projects-heading {
  margin: 0 0 8px 32%;
  padding-left: 25px;
}

.project-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  margin-left: 32%;
}

.project {
  min-height: 345px;
  padding: 0 30px 0 30px;
  border-left: 1px solid #c4beb2;
  display: flex;
  flex-direction: column;
}

.project-number {
  margin: 0 0 13px;
  color: var(--accent);
  font-size: 2.4rem;
  line-height: 1;
}

.project-number::after {
  content: "";
  display: block;
  width: 28px;
  height: 1px;
  background: #b9b2a5;
  margin-top: 10px;
}

.project h3 {
  margin: 0 0 16px;
  font-size: 1.12rem;
  line-height: 1.05;
  text-transform: uppercase;
  letter-spacing: 0.19em;
}

.project p:not(.project-number) {
  margin: 0 0 13px;
  font-size: 0.99rem;
}

.project-link {
  margin-top: auto;
  padding-top: 10px;
  color: var(--accent);
  font-family: var(--serif);
  font-size: 0.85rem;
  font-weight: bold;
  text-decoration: none;
  text-transform: uppercase;
  letter-spacing: 0.03em;
}

.project-link:hover,
.project-link:focus-visible {
  text-decoration: underline;
  text-underline-offset: 4px;
}

.elsewhere {
  display: grid;
  grid-template-columns: 18% 82%;
  padding: 18px 0 22px;
}

.elsewhere-copy {
  border-left: 1px solid #c4beb2;
  padding: 0 40px;
}

.elsewhere-copy h3 {
  margin: 0 0 6px;
  font-size: 0.88rem;
  text-transform: uppercase;
  letter-spacing: 0.25em;
}

.elsewhere-copy p {
  max-width: 760px;
  margin: 0 0 8px;
}

.collection-progress {
  font-style: italic;
}

.site-footer {
  padding: 18px 25px 40px;
  color: var(--muted);
  font-size: 0.85rem;
}

.site-footer p {
  margin: 0;
}

/* ---------------------------------------------------------
   Mobile / tablet
   --------------------------------------------------------- */

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

  .section-label,
  .about-copy,
  .elsewhere-copy {
    padding-left: 0;
    padding-right: 0;
  }

  .section-label {
    margin-bottom: 20px;
  }

  .projects-heading {
    margin-left: 0;
    padding-left: 0;
  }

  .project-grid {
    margin-left: 0;
  }

  .tagline {
    margin-left: 0;
    margin-right: 0;
  }

  .elsewhere-copy {
    border-left: 0;
  }
}

@media (max-width: 680px) {
  .site-header,
  main,
  .site-footer {
    width: min(calc(100% - 28px), var(--max-width));
  }

  .site-header {
    padding-bottom: 28px;
  }

  .logo-image {
    min-height: 170px;
    object-fit: cover;
  }

  .tagline {
    grid-template-columns: 1fr;
    gap: 10px;
  }

  .tagline span {
    display: none;
  }

  .project-grid {
    grid-template-columns: 1fr;
  }

  .project {
    min-height: auto;
    padding: 25px 0;
    border-left: 0;
    border-top: 1px solid #c4beb2;
  }

  .project:first-child {
    border-top: 0;
  }

  .project-link {
    margin-top: 10px;
  }

  .about-copy p {
    font-size: 1rem;
  }
}
