/* =========================================================================
   Museum of Arcadia — Editorial pages
   Figma: Manifesto 57:2524, Art at MOA 57:2620, Life at MOA 57:2685,
   legal pages, 404.

   Desktop: 870px content column, 285px viewport margins (x=285 @ 1440).
   ========================================================================= */


/* ----- Page shell (margins live on .page, not inside .editorial) ----- */

body.page-template-page-editorial .page,
body.page-editorial:not(.page-legal) .page,
body.error404 .page {
  padding-left: var(--pad-page-x-wide, 285px);
  padding-right: var(--pad-page-x-wide, 285px);
  box-sizing: border-box;
}

body.page-newsletter .page {
  padding-left: 0;
  padding-right: 0;
}

body.page-legal .page,
body.page-template-page-legal .page {
  padding: 40px var(--pad-page-x, 136px) var(--s-10);
  box-sizing: border-box;
}


/* =========================================================================
   LEGAL HUB — two-column layout (Figma 57:4856+)
   ========================================================================= */

.legal-layout {
  display: grid;
  grid-template-columns: 220px minmax(0, 1fr);
  gap: 80px;
  align-items: start;
  max-width: var(--container-max);
  margin: 0 auto;
}

.legal-nav {
  position: sticky;
  top: var(--s-5);
}

.legal-nav__title {
  font-family: var(--font-sans);
  text-transform: uppercase;
  letter-spacing: var(--ls-caps);
  font-weight: 500;
  font-size: 0.9375rem;
  line-height: 1.4;
  color: var(--moa-black);
  margin: 0 0 var(--s-5);
}

.legal-nav__list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 0;
}

.legal-nav__item {
  margin: 0;
  padding: 0;
}

.legal-nav__link {
  display: block;
  font-family: var(--font-sans);
  text-transform: uppercase;
  letter-spacing: var(--ls-caps);
  font-size: 0.8125rem;
  line-height: 1.4;
  color: var(--moa-muted);
  padding: var(--s-3) 0;
  border-bottom: 1px solid var(--moa-rule);
  text-decoration: none;
  transition: color var(--t-fast) var(--ease-standard);
}

.legal-nav__link:hover {
  color: var(--moa-black);
}

.legal-nav__link.is-active {
  color: var(--moa-black);
  font-weight: 500;
}

.legal-nav__link.is-active::after {
  content: '';
  display: block;
  height: 3px;
  background: var(--moa-nav-active);
  margin-top: 4px;
  width: 100%;
}

.legal-main {
  min-width: 0;
  max-width: 870px;
}

.legal-main__header {
  text-align: left;
  margin-bottom: 46px;
}

.legal-main__title {
  display: inline-block;
  width: auto;
  max-width: 100%;
  margin: 0;
  font-family: var(--font-sans);
  font-size: 1.4375rem;
  font-weight: 500;
  line-height: 23px;
  letter-spacing: 0.01em;
  text-transform: uppercase;
  text-align: left;
}

.legal-main__title img,
.legal-main__title svg {
  display: none !important;
}

.legal-main__body {
  font-family: var(--font-serif);
  color: var(--moa-black);
}


/* =========================================================================
   PAGE WRAPPER + TITLE (manifesto / art / life editorial)
   ========================================================================= */

.editorial {
  max-width: 841px;
  width: 100%;
  margin: 0 auto;
  padding: 46px 0 var(--s-10);
  box-sizing: border-box;
}

.editorial__header {
  text-align: center;
  margin-bottom: 46px;
}

.editorial__title {
  display: inline-block;
  width: auto;
  max-width: 100%;
  margin: 0;
  font-family: var(--font-sans);
  font-size: 1.4375rem;   /* 23px — Figma */
  font-weight: 500;
  line-height: 23px;
  letter-spacing: 0.01em;
  text-transform: uppercase;
  text-align: center;
}

/* WP.com / block editor decorations must not appear in titles */
.editorial__title img,
.editorial__title svg,
.editorial__title .wp-block-post-title,
.editorial__title .jetpack-ai-assistant,
.editorial__title [class*="emoji"] {
  display: none !important;
}


/* =========================================================================
   BODY — prose, verse, legal (inside .editorial__body or legacy .prose)
   ========================================================================= */

.editorial__body,
.editorial .prose {
  font-family: var(--font-serif);
  color: var(--moa-black);
}

.editorial__body > p,
.editorial .prose p,
.editorial__body .prose p {
  font-size: 1.3375rem;   /* 21.4px — Figma */
  line-height: 30px;
  margin-bottom: var(--s-5);
  text-align: left;
}

.editorial__body > p:last-child,
.editorial .prose p:last-child {
  margin-bottom: 0;
}

body.page-template-page-editorial.page-editorial:not(.page-legal) .editorial {
  max-width: 845px;
}

body.page-template-page-editorial.page-editorial:not(.page-legal) .editorial__body > p,
body.page-template-page-editorial.page-editorial:not(.page-legal) .editorial .prose p,
body.page-template-page-editorial.page-editorial:not(.page-legal) .editorial__body .prose p {
  font-family: var(--font-serif);
  font-size: 21.4px;
  font-weight: 400;
  line-height: 30px;
  letter-spacing: 0.005em;
  margin: 0 0 30px;
}

body.page-template-page-editorial.page-editorial:not(.page-legal) .editorial__body > p:last-child,
body.page-template-page-editorial.page-editorial:not(.page-legal) .editorial .prose p:last-child {
  margin-bottom: 0;
}

body.page-life-at-moa.page-template-page-editorial.page-editorial:not(.page-legal) .editorial {
  max-width: 860px;
  padding-top: 36px;
  padding-bottom: 21px;
}

body.page-life-at-moa.page-template-page-editorial.page-editorial:not(.page-legal) .editorial__header {
  margin-bottom: 28px;
}

body.page-life-at-moa.page-template-page-editorial.page-editorial:not(.page-legal) .page {
  min-height: 0;
}

body.page-life-at-moa .page-title--animated::after {
  display: none;
}

body.page-life-at-moa .site-footer .newsletter {
  padding-top: 90px;
  padding-bottom: 53px;
}

body.page-life-at-moa .site-footer .newsletter::before {
  margin-bottom: 0;
}

body.page-manifesto .page-title--animated::after {
  display: none;
}

body.page-template-page-editorial.page-editorial.page-manifesto:not(.page-legal) .page {
  padding-left: 285px;
  padding-right: 285px;
}

body.page-manifesto .editorial {
  max-width: 870px;
}

body.page-template-page-editorial.page-manifesto .editorial {
  max-width: 870px;
}

body.page-template-page-editorial.page-editorial.page-manifesto:not(.page-legal) .editorial {
  max-width: 870px;
}

body.page-manifesto .editorial__header {
  margin-bottom: 62px;
}

body.page-manifesto .editorial__body > .prose {
  margin: 0 0 30px;
}

body.page-template-page-editorial.page-editorial.page-manifesto:not(.page-legal) .editorial__body > .prose p,
body.page-template-page-editorial.page-editorial.page-manifesto:not(.page-legal) .editorial .prose p,
body.page-template-page-editorial.page-editorial.page-manifesto:not(.page-legal) .editorial__body .prose p {
  margin-bottom: 0;
}

body.page-template-page-editorial.page-editorial.page-manifesto:not(.page-legal) .editorial__body .prose--manifesto-breathing p:nth-child(1),
body.page-template-page-editorial.page-editorial.page-manifesto:not(.page-legal) .editorial__body .prose--manifesto-breathing p:nth-child(2) {
  margin-bottom: 30px;
}

body.page-manifesto .editorial__body > .prose:last-child {
  margin-bottom: 0;
}

body.page-manifesto .editorial__body > .verse {
  margin: 0 0 30px;
  text-align: center;
  font-style: italic;
}

body.page-manifesto .editorial__body > .verse:first-child {
  text-align: center;
  margin-bottom: 52px;
}

body.page-manifesto .editorial__body > .verse--callout {
  text-align: left;
}

body.page-manifesto .editorial__body > .verse--exhaust {
  margin-bottom: 0;
}

body.page-manifesto .editorial__body > .verse p,
body.page-manifesto .editorial .verse p {
  font-family: var(--font-serif);
  font-size: 21.4px;
  font-weight: 400;
  font-style: italic;
  line-height: 30px;
  letter-spacing: 0.005em;
  margin: 0;
  text-align: inherit;
}

body.page-manifesto .editorial__body > .verse--spaced p:not(:last-child) {
  margin-bottom: 30px;
}

.editorial__body em,
.editorial__body i,
.editorial .prose em,
.editorial .prose i {
  font-style: italic;
}

.editorial__body .standalone,
.editorial .prose .standalone {
  text-align: center;
  font-style: italic;
  margin: var(--s-5) 0;
  font-size: 1.1rem;
}


/* =========================================================================
   VERSE BLOCK — centered italic stanza (Manifesto)
   ========================================================================= */

.verse {
  text-align: center;
  font-style: italic;
  margin: var(--s-7) 0;
  color: var(--moa-black);
}

.editorial .verse p,
.editorial__body .verse p {
  font-size: 1.875rem;    /* 30px — Figma */
  line-height: 1.5;
  margin-bottom: var(--s-3);
  text-align: center;
}

.verse p:last-child {
  margin-bottom: 0;
}

.verse + .verse {
  margin-top: var(--s-5);
}

.manifesto-mobile-line {
  display: block;
}

/* Editorial footer matches the Figma Link/Footer block. */
body.page-template-page-editorial.page-editorial:not(.page-legal) .site-footer .footer-main {
  padding-top: 51px;
  padding-bottom: 43px;
}

body.page-template-page-editorial.page-editorial:not(.page-legal) .site-footer .footer-cols {
  column-gap: 75px;
  row-gap: 75px;
  max-width: 523px;
  align-items: flex-start;
}

body.page-template-page-editorial.page-editorial:not(.page-legal) .site-footer .footer-col--follow {
  margin-top: 0;
}

body.page-template-page-editorial.page-editorial:not(.page-legal) .site-footer .footer-col__title {
  margin-bottom: 30px;
}

body.page-template-page-editorial.page-editorial:not(.page-legal) .site-footer .footer-col--follow::after {
  content: '';
  display: block;
  width: min(1302.17px, calc(100vw - 32px));
  height: 0;
  margin: 18px auto 0;
  border-top: 0.75px solid var(--moa-border-header);
  position: relative;
  left: 50%;
  transform: translateX(-50%);
  pointer-events: none;
}


/* =========================================================================
   LEGAL ACCORDIONS
   ========================================================================= */

.legal-intro {
  font-family: var(--font-serif);
  font-size: 1.0625rem;
  line-height: 1.7;
  color: var(--moa-black);
  margin-bottom: var(--s-7);
}

.legal-intro p {
  margin-bottom: var(--s-4);
}

.legal-intro p:last-child {
  margin-bottom: 0;
}

.legal-accordion,
.accordion {
  border-top: 1px solid var(--moa-black);
}

.legal__section,
.accordion__item,
details.legal__section,
details.accordion__item {
  border-bottom: 1px solid var(--moa-black);
}

.legal__head,
.accordion__title,
summary.legal__head,
summary.accordion__title {
  font-family: var(--font-sans);
  text-transform: uppercase;
  letter-spacing: var(--ls-caps);
  font-weight: 500;
  font-size: 0.9375rem;
  line-height: 1.4;
  padding: var(--s-5) 0;
  cursor: pointer;
  list-style: none;
  position: relative;
  padding-right: var(--s-7);
  color: var(--moa-black);
  user-select: none;
  display: block;
}

.legal__head::-webkit-details-marker,
.accordion__title::-webkit-details-marker { display: none; }
.legal__head::marker,
.accordion__title::marker { content: ''; }

.legal__head::after,
.accordion__title::after {
  content: '+';
  position: absolute;
  right: 0;
  top: 50%;
  transform: translateY(-50%);
  font-size: 1.25rem;
  font-weight: 400;
  line-height: 1;
  transition: transform 0.25s ease;
}

.legal__section[open] > .legal__head::after,
.accordion__item[open] > .accordion__title::after,
details.legal__section[open] > summary::after,
details.accordion__item[open] > summary::after {
  content: '−';
}

.legal__head:focus-visible,
.accordion__title:focus-visible {
  outline: 2px solid var(--moa-black);
  outline-offset: 2px;
}

.legal__body,
.accordion__body {
  font-family: var(--font-serif);
  font-size: 1.0625rem;
  line-height: 1.7;
  color: var(--moa-black);
  padding: 0 0 var(--s-6);
}

.legal__body p,
.accordion__body p {
  margin-bottom: var(--s-4);
}

.legal__body p:last-child,
.accordion__body p:last-child {
  margin-bottom: 0;
}

.legal__body[data-collapsing],
.legal__body[data-expanding],
.accordion__body[data-collapsing],
.accordion__body[data-expanding] {
  overflow: hidden;
  transition: height 0.3s ease;
}


/* =========================================================================
   404 PAGE
   ========================================================================= */

.error-404 {
  max-width: 720px;
  margin: 0 auto;
  padding: 80px 0 var(--s-10);
  text-align: center;
}

.error-404__title {
  font-family: var(--font-sans);
  text-transform: uppercase;
  letter-spacing: var(--ls-caps);
  font-weight: 500;
  font-size: var(--fs-page-title);
  line-height: var(--lh-tight);
  margin-bottom: var(--s-5);
}

.error-404__body {
  font-family: var(--font-serif);
  font-style: italic;
  font-size: 1.0625rem;
  line-height: var(--lh-body);
  margin-bottom: var(--s-7);
  color: var(--moa-black);
}


/* =========================================================================
   RESPONSIVE
   ========================================================================= */

@media (max-width: 1200px) {
  body.page-template-page-editorial .page,
  body.page-editorial:not(.page-legal) .page,
  body.error404 .page {
    padding-left: var(--container-pad-d);
    padding-right: var(--container-pad-d);
  }

  body.page-template-page-editorial.page-editorial.page-manifesto:not(.page-legal) .page {
    padding-left: var(--container-pad-d);
    padding-right: var(--container-pad-d);
  }

  body.page-legal .page,
  body.page-template-page-legal .page {
    padding-left: var(--container-pad-d);
    padding-right: var(--container-pad-d);
  }

  .legal-layout {
    gap: 48px;
    grid-template-columns: 200px minmax(0, 1fr);
  }
}

@media (max-width: 768px) {
  body.page-template-page-editorial .page,
  body.page-editorial:not(.page-legal) .page,
  body.error404 .page {
    padding-left: var(--container-pad-m);
    padding-right: var(--container-pad-m);
  }

  body.page-template-page-editorial.page-editorial.page-manifesto:not(.page-legal) .page {
    padding-left: 12px;
    padding-right: 12px;
  }

  body.page-legal .page,
  body.page-template-page-legal .page {
    padding: var(--s-6) var(--container-pad-m) var(--s-8);
  }

  .legal-layout {
    grid-template-columns: 1fr;
    gap: var(--s-6);
  }

  .legal-nav {
    position: static;
    border-bottom: 1px solid var(--moa-rule);
    padding-bottom: var(--s-5);
  }

  .legal-nav__list {
    flex-direction: column;
  }

  .legal-main__header {
    margin-bottom: var(--s-6);
  }

  .legal-main {
    max-width: none;
  }

  .editorial {
    padding: var(--s-7) 0 var(--s-8);
  }

  .editorial__header {
    margin-bottom: var(--s-7);
  }

  .editorial__title {
    font-size: var(--fs-page-title);
    line-height: var(--lh-tight);
  }

  body.page-manifesto .editorial__header {
    margin-bottom: 46px;
  }

  body.page-manifesto .editorial {
    max-width: none;
    padding-top: 28px;
  }

  body.page-manifesto .editorial__title {
    font-size: 18px;
    line-height: 22px;
    letter-spacing: 0.01em;
  }

  body.page-manifesto .editorial__body > .prose {
    margin-bottom: 30px;
  }

  body.page-manifesto .editorial__body > .verse:first-child {
    margin-bottom: 22px;
  }

  body.page-manifesto .editorial__body > .verse {
    text-align: center;
  }

  body.page-manifesto .editorial__body > .verse--callout {
    text-align: left;
  }

  body.page-manifesto .editorial__body > .verse--exhaust {
    margin-bottom: 0;
  }

  .editorial__body > p,
  .editorial .prose p,
  .editorial__body .prose p {
    font-size: 1.125rem;
    line-height: 1.6;
  }

  .editorial .verse p,
  .editorial__body .verse p {
    font-size: 1.25rem;
  }

  body.page-manifesto .editorial__body > .verse p,
  body.page-manifesto .editorial .verse p {
    font-size: 17.45px;
    line-height: 24px;
    letter-spacing: 0.005em;
  }

  body.page-manifesto .manifesto-mobile-line {
    display: block;
  }

  body.page-template-page-editorial.page-editorial.page-manifesto:not(.page-legal) .editorial__body > p,
  body.page-template-page-editorial.page-editorial.page-manifesto:not(.page-legal) .editorial .prose p,
  body.page-template-page-editorial.page-editorial.page-manifesto:not(.page-legal) .editorial__body .prose p {
    font-size: 17.45px;
    line-height: 24px;
    letter-spacing: 0.005em;
  }

  body.page-life-at-moa.page-template-page-editorial.page-editorial:not(.page-legal) .page {
    padding-left: 12px;
    padding-right: 12px;
  }

  body.page-life-at-moa.page-template-page-editorial.page-editorial:not(.page-legal) .editorial {
    max-width: none;
    padding-top: 36px;
    padding-bottom: 21px;
  }

  body.page-life-at-moa.page-template-page-editorial.page-editorial:not(.page-legal) .editorial__header {
    margin-bottom: 28px;
  }

  body.page-life-at-moa.page-template-page-editorial.page-editorial:not(.page-legal) .editorial__body > p,
  body.page-life-at-moa.page-template-page-editorial.page-editorial:not(.page-legal) .editorial .prose p,
  body.page-life-at-moa.page-template-page-editorial.page-editorial:not(.page-legal) .editorial__body .prose p {
    font-size: 17.45px;
    line-height: 24px;
    letter-spacing: 0.005em;
    margin-bottom: 24px;
    padding: 10px;
  }

  body.page-template-page-editorial.page-editorial:not(.page-legal) .site-footer .footer-cols {
    gap: 0;
    row-gap: 0;
    column-gap: 0;
    max-width: none;
    align-items: stretch;
  }

  body.page-template-page-editorial.page-editorial:not(.page-legal) .site-footer .footer-main {
    padding: 34px var(--container-pad-m) 49px;
  }

  body.page-template-page-editorial.page-editorial:not(.page-legal) .site-footer .footer-col__title {
    margin: 0;
  }

  body.page-template-page-editorial.page-editorial:not(.page-legal) .site-footer .footer-col--follow {
    margin-top: 30px;
  }

  body.page-template-page-editorial.page-editorial:not(.page-legal) .site-footer .footer-col--follow::after {
    display: none;
  }

  .error-404 {
    padding: var(--s-7) 0 var(--s-8);
  }

  .legal__head {
    font-size: 0.875rem;
    padding: var(--s-4) var(--s-6) var(--s-4) 0;
  }

  .legal__body {
    font-size: 1rem;
    padding-bottom: var(--s-5);
  }

  .legal-intro {
    font-size: 1rem;
    margin-bottom: var(--s-6);
  }
}

body.page-newsletter.page-editorial:not(.page-legal) .page {
  padding-left: 0;
  padding-right: 0;
}
