/* ==========================================================================
   Maureen Wallner — shared site styles
   Fonts, colors, spacing and image sizes are matched directly against
   computed styles read from the live maureenwallner.com (Squarespace).
   ========================================================================== */

@import url("https://fonts.googleapis.com/css2?family=Young+Serif&family=Bitter:ital,wght@0,400;0,600;1,400&display=swap");

:root {
  --cream: #e5dcce;         /* page background, everywhere */
  --ink: #714b4b;           /* the one text/heading/button color used site-wide */
  --button-text: #f3ede5;
  --max-width: 1296px;      /* 1440 viewport minus 72px margins each side */
  --side: 72px;             /* fixed side margin at desktop, matches live */
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--cream);
  color: var(--ink);
  font-family: "Bitter", Georgia, "Times New Roman", serif;
  font-size: 1rem;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

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

a {
  color: inherit;
  text-decoration: none;
}

h1, h2, h3, h4 {
  font-family: "Young Serif", Georgia, serif;
  font-weight: 400;
  letter-spacing: -0.02em;
  color: var(--ink);
  margin: 0;
}

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

/* -------------------------------------------------- layout helpers */

.wrap {
  max-width: var(--max-width);
  margin: 0 auto;
  padding-left: var(--side);
  padding-right: var(--side);
}

/* -------------------------------------------------- decorative paper overlay
   Single composite image (real asset from the live site) with a flat cream
   fill and torn-paper/photo scraps baked into its corners. Stretched to
   exactly fill whatever section it's applied to, same technique as the
   original. */

.paper-deco {
  position: relative;
}

.paper-deco::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image: url("/assets/img/bg-paper.jpg");
  background-size: 100% 100%;
  background-repeat: no-repeat;
  z-index: 0;
  pointer-events: none;
}

/* -------------------------------------------------- header / nav */

.site-header {
  background: var(--cream);
  position: relative;
  z-index: 20;
}

.site-header__inner {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 30px var(--side);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
}

.brand {
  font-family: "Young Serif", Georgia, serif;
  font-weight: 400;
  font-size: 1.65rem;
  letter-spacing: -0.02em;
  color: var(--ink);
  white-space: nowrap;
}

.nav-toggle {
  display: none;
  background: none;
  border: none;
  color: var(--ink);
  font-size: 1.6rem;
  cursor: pointer;
  padding: 0.25rem;
}

.main-nav {
  display: flex;
  align-items: center;
  gap: 2.1rem;
  flex-wrap: wrap;
}

.main-nav__links {
  display: flex;
  gap: 2.1rem;
  list-style: none;
  margin: 0;
  padding: 0;
}

.main-nav__links a {
  font-family: "Bitter", serif;
  font-size: 1rem;
  color: var(--ink);
  padding-bottom: 0.2rem;
  border-bottom: 1px solid transparent;
  transition: border-color 0.2s ease;
}

.main-nav__links a:hover,
.main-nav__links a:focus-visible,
.main-nav__links a[aria-current="page"] {
  border-bottom-color: var(--ink);
}

.main-nav__social {
  display: flex;
  gap: 1.1rem;
  align-items: center;
}

.main-nav__social a {
  color: var(--ink);
  display: inline-flex;
  transition: transform 0.2s ease, opacity 0.2s ease;
}

.main-nav__social a:hover,
.main-nav__social a:focus-visible {
  transform: translateY(-2px);
  opacity: 0.75;
}

.main-nav__social svg {
  width: 20px;
  height: 20px;
}

a:focus-visible,
button:focus-visible {
  outline: 2px solid var(--ink);
  outline-offset: 3px;
}

/* -------------------------------------------------- hero texture (home only) */

.hero-texture {
  position: relative;
  background-image: url("/assets/img/bg-hero.jpg");
  background-size: cover;
  background-position: center;
}

.wave-divider {
  display: block;
  width: 100%;
  height: auto;
  position: relative;
  z-index: 2;
}

.wave-divider path {
  fill: var(--cream);
}

.wave-divider .wave-line {
  fill: none;
  stroke: var(--ink);
  stroke-width: 2.5;
}

/* -------------------------------------------------- buttons */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  background: var(--ink);
  color: var(--button-text);
  font-family: "Bitter", serif;
  font-size: 1rem;
  text-align: center;
  padding: 1rem 1.8rem;
  border-radius: 45px 0;
  border: none;
  cursor: pointer;
  line-height: 1.4;
  transition: transform 0.18s cubic-bezier(0.2, 0.9, 0.3, 1.2), opacity 0.2s ease;
}

.btn:hover {
  opacity: 0.88;
  transform: translateY(-2px);
}

.btn:active {
  transform: translateY(0);
}

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

.text-link {
  border-bottom: 1px solid var(--ink);
  padding-bottom: 1px;
  transition: opacity 0.2s ease;
}

.text-link:hover {
  opacity: 0.7;
}

/* -------------------------------------------------- footer */

.site-footer {
  padding: 2.5rem var(--side) 3.5rem;
  position: relative;
  z-index: 2;
}

.site-footer__inner {
  max-width: var(--max-width);
  margin: 0 auto;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
}

.site-footer__name {
  font-family: "Young Serif", serif;
  font-weight: 400;
  font-size: 1.65rem;
  letter-spacing: -0.02em;
  color: var(--ink);
}

.site-footer__social {
  display: flex;
  gap: 1.4rem;
}

.site-footer__social a {
  color: var(--ink);
  transition: transform 0.2s ease, opacity 0.2s ease;
}

.site-footer__social a:hover {
  transform: translateY(-2px);
  opacity: 0.75;
}

.site-footer__social svg {
  width: 20px;
  height: 20px;
}

.site-footer__email {
  font-family: "Young Serif", serif;
  font-weight: 400;
  font-size: 1.65rem;
  letter-spacing: -0.02em;
  color: var(--ink);
}

/* -------------------------------------------------- hero: latest book (home) */

.hero {
  padding: 3.5rem var(--side) 4.5rem;
  position: relative;
}

.hero__inner {
  max-width: var(--max-width);
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2rem;
  align-items: center;
  position: relative;
  z-index: 2;
}

.hero__title {
  font-size: 4.8rem;
  line-height: 1;
  margin-bottom: 1.2rem;
}

.hero__tagline {
  font-family: "Young Serif", serif;
  font-weight: 400;
  font-size: 1.5rem;
  letter-spacing: -0.02em;
  color: var(--ink);
}

.hero__art {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1.75rem;
}

.hero__cover {
  width: 235px;
  max-width: 100%;
  box-shadow: 0 20px 40px -16px rgba(50, 30, 25, 0.4);
}

/* -------------------------------------------------- home: about teaser */

.about-teaser {
  max-width: var(--max-width);
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr 1.3fr;
  gap: 3rem;
  align-items: center;
  padding: 4rem var(--side) 5rem;
  position: relative;
  z-index: 2;
}

.about-teaser__photo {
  width: 100%;
  max-width: 316px;
  margin: 0 auto;
  box-shadow: 0 20px 40px -16px rgba(50, 30, 25, 0.4);
}

.about-teaser__eyebrow {
  font-family: "Bitter", serif;
  font-size: 1.43rem;
  line-height: 1.5;
  margin-bottom: 0.5rem;
}

.about-teaser__quote {
  font-family: "Young Serif", serif;
  font-weight: 400;
  letter-spacing: -0.02em;
  font-size: 2.3rem;
  line-height: 1.14;
  color: var(--ink);
}

/* -------------------------------------------------- book / project grids */

.page-head {
  padding: 3.5rem var(--side) 1rem;
}

.page-head .wrap {
  max-width: var(--max-width);
}

.grid-section {
  padding: 2.5rem var(--side) 5rem;
  position: relative;
}

.book-grid,
.project-grid {
  max-width: var(--max-width);
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(4, 291px);
  gap: 2.1rem 44px;
  position: relative;
  z-index: 2;
}

.book-grid {
  grid-template-columns: repeat(auto-fit, 291px);
}

.card {
  display: block;
  text-align: left;
}

.card__cover {
  aspect-ratio: 291 / 437;
  width: 100%;
  object-fit: cover;
  box-shadow: 0 16px 32px -16px rgba(50, 30, 25, 0.4);
  margin-bottom: 1rem;
  transition: transform 0.25s cubic-bezier(0.2, 0.9, 0.3, 1.1), box-shadow 0.25s ease;
}

.card:hover .card__cover,
.card:focus-visible .card__cover {
  transform: translateY(-6px);
  box-shadow: 0 24px 40px -16px rgba(50, 30, 25, 0.5);
}

.card__title {
  font-family: "Young Serif", serif;
  font-weight: 400;
  letter-spacing: -0.02em;
  font-size: 1.65rem;
  color: var(--ink);
}

/* -------------------------------------------------- book / project detail */

.detail {
  padding: 3rem var(--side) 4rem;
  position: relative;
}

.detail__inner {
  max-width: var(--max-width);
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr 0.55fr;
  gap: 3rem;
  align-items: start;
  position: relative;
  z-index: 2;
}

.detail__title {
  font-size: 2.3rem;
  margin-bottom: 1.4rem;
}

.detail__body {
  font-size: 1.43rem;
  line-height: 1.5;
  max-width: 45ch;
}

.detail__body p + p {
  margin-top: 1.2rem;
}

.detail__side {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1.3rem;
}

.detail__cover {
  width: 207px;
  max-width: 100%;
  box-shadow: 0 20px 40px -16px rgba(50, 30, 25, 0.4);
}

.gallery {
  max-width: var(--max-width);
  margin: 3rem auto 0;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.4rem;
  position: relative;
  z-index: 2;
}

.gallery img {
  width: 100%;
  aspect-ratio: 5 / 4.8;
  object-fit: cover;
  box-shadow: 0 4px 0 #fff, 0 8px 18px rgba(50, 30, 25, 0.25);
  border: 6px solid #fff;
}

.detail-nav {
  max-width: var(--max-width);
  margin: 3.5rem auto 0;
  display: flex;
  justify-content: space-between;
  position: relative;
  z-index: 2;
  font-family: "Young Serif", serif;
  font-weight: 400;
  letter-spacing: -0.02em;
  font-size: 1.65rem;
}

.detail-nav a {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  color: var(--ink);
  transition: opacity 0.2s ease;
}

.detail-nav a:hover {
  opacity: 0.7;
}

/* -------------------------------------------------- long-form quote hero (projects) */

.quote-hero {
  padding: 4.5rem var(--side) 2.5rem;
  position: relative;
}

.quote-hero p {
  max-width: 20ch;
  margin: 0 auto;
  text-align: center;
  font-family: "Young Serif", serif;
  font-weight: 400;
  letter-spacing: -0.02em;
  font-size: clamp(1.6rem, 3.4vw, 2.3rem);
  line-height: 1.25;
  color: var(--ink);
  position: relative;
  z-index: 2;
}

.quote-hero--wide p {
  max-width: 34ch;
}

.article-scan {
  max-width: 900px;
  margin: 0 auto;
  position: relative;
  z-index: 2;
}

.article-scan img {
  width: 100%;
  box-shadow: 0 20px 40px -16px rgba(50, 30, 25, 0.35);
}

/* -------------------------------------------------- blog list */

.blog-list {
  max-width: var(--max-width);
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 3rem;
  position: relative;
  z-index: 2;
}

.blog-post-row {
  display: grid;
  grid-template-columns: 518px 1fr;
  gap: 78px;
  align-items: center;
}

.blog-post-row__image img {
  width: 100%;
  aspect-ratio: 518 / 293;
  object-fit: cover;
}

.blog-post-row__date {
  font-family: "Bitter", serif;
  font-size: 1rem;
  color: var(--ink);
  margin-bottom: 0.6rem;
}

.blog-post-row__title {
  font-size: 2.94rem;
  line-height: 1.2;
  letter-spacing: -0.02em;
  margin-bottom: 1rem;
}

.blog-post-row__excerpt {
  font-family: "Bitter", serif;
  margin-bottom: 1.2rem;
}

/* -------------------------------------------------- blog post detail */

.post {
  max-width: 820px;
  margin: 0 auto;
  padding: 3.5rem var(--side) 2rem;
}

.post__meta {
  font-family: "Bitter", serif;
  color: var(--ink);
  margin-bottom: 1rem;
}

.post__title {
  font-size: clamp(2.4rem, 5vw, 3.4rem);
  margin-bottom: 2rem;
}

.post__body {
  font-size: 1.43rem;
  line-height: 1.5;
}

.post__body p + p {
  margin-top: 1.2rem;
}

.post__cta {
  margin: 2.2rem 0;
  display: block;
  text-align: center;
  padding: 1.1rem 2rem;
  border-radius: 45px 0;
}

.comments {
  max-width: 820px;
  margin: 2rem auto 0;
  padding: 0 var(--side) 4rem;
}

.comments__head {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  margin-bottom: 1.2rem;
}

.comments__head h2 {
  font-size: 1.7rem;
}

.comments__sort {
  font-family: "Bitter", serif;
  font-size: 0.95rem;
  color: var(--ink);
}

.comments__box {
  background: #fff;
  min-height: 160px;
  border-radius: 4px;
}

/* -------------------------------------------------- about page */

.about-hero {
  padding: 4rem var(--side) 3rem;
  position: relative;
  overflow: hidden;
}

.about-hero__inner {
  max-width: var(--max-width);
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3rem;
  align-items: center;
  position: relative;
  z-index: 2;
}

.about-hero__eyebrow {
  font-family: "Bitter", serif;
  font-size: 1.43rem;
  margin-bottom: 1rem;
}

.about-hero__title {
  font-size: 4.24rem;
  line-height: 1.06;
  margin-bottom: 1.3rem;
}

.about-hero__text {
  font-family: "Bitter", serif;
  font-size: 1.43rem;
  line-height: 1.5;
  max-width: 32ch;
}

.about-hero__photo img {
  width: 100%;
  max-width: 298px;
  margin: 0 auto;
  box-shadow: 0 20px 40px -16px rgba(50, 30, 25, 0.4);
}

/* -------------------------------------------------- responsive */

@media (max-width: 900px) {
  .hero__inner,
  .detail__inner,
  .about-hero__inner,
  .about-teaser,
  .blog-post-row {
    grid-template-columns: 1fr;
  }

  .hero__art {
    order: -1;
  }

  .book-grid,
  .project-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .book-grid {
    grid-template-columns: repeat(auto-fit, minmax(180px, 260px));
  }

  .gallery {
    grid-template-columns: repeat(2, 1fr);
  }

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

@media (max-width: 640px) {
  :root {
    --side: 6vw;
  }

  .hero__title {
    font-size: 3.2rem;
  }

  .about-hero__title {
    font-size: 3rem;
  }

  .main-nav {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--cream);
    flex-direction: column;
    align-items: flex-start;
    padding: 0 6vw 1.5rem;
    display: none;
    gap: 1.2rem;
    box-shadow: 0 12px 20px -12px rgba(0, 0, 0, 0.2);
  }

  .main-nav.is-open {
    display: flex;
  }

  .main-nav__links {
    flex-direction: column;
    gap: 1rem;
  }

  .nav-toggle {
    display: inline-flex;
  }

  .book-grid,
  .project-grid {
    grid-template-columns: 1fr 1fr;
    gap: 1.8rem;
  }

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

  .site-footer__inner {
    flex-direction: column;
    text-align: center;
  }

  .detail-nav {
    font-size: 1.1rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  * {
    transition: none !important;
    scroll-behavior: auto !important;
  }
}
