@import url('https://fonts.googleapis.com/css2?family=Cinzel:wght@500;600&family=Cormorant+Garamond:ital,wght@0,500;0,600;1,500&display=swap');

/* Piper Apologetics — shared public layout standard.
 * Keeps each section's own visual identity while aligning the site frame,
 * masthead geometry, navigation treatment, opening-card radius, and spacing.
 */

:root {
  --pa-shell-max: 1180px;
  --pa-shell-pad: 22px;
  --pa-opening-radius: 24px;
  --pa-opening-gap: 24px;
  --pa-masthead-height: 84px;
}

@media (min-width: 721px) {
  /* The application routes and About now use the same full-width masthead
     with a centered 1180px working frame. The editorial homepage keeps its
     intentionally wider, dark presentation. */
  body:not(.piper-editorial-home) > .site-shell {
    width: 100%;
    max-width: none;
    margin: 0;
    padding-right: 0;
    padding-left: 0;
  }

  body:not(.piper-editorial-home) > .site-shell > .site-header {
    width: 100% !important;
    margin-right: 0 !important;
    margin-left: 0 !important;
  }

  body:not(.piper-editorial-home) > .site-shell > .site-header > .header-inner {
    width: 100%;
    max-width: var(--pa-shell-max);
    min-height: var(--pa-masthead-height);
    margin-right: auto;
    margin-left: auto;
    padding: 15px var(--pa-shell-pad) !important;
  }

  .cw-brand-header,
  .about-static-header,
  .piper-public-header {
    width: 100% !important;
    margin-right: 0 !important;
    margin-left: 0 !important;
    background: rgba(13, 13, 12, .975) !important;
  }

  body:not(.piper-editorial-home) > .site-shell > main {
    width: 100%;
    max-width: var(--pa-shell-max);
    margin-right: auto;
    margin-left: auto;
    padding-right: var(--pa-shell-pad);
    padding-left: var(--pa-shell-pad);
  }

  /* One masthead scale across the app, Writers, About, Papers, and policies. */
  .site-header .brand-wrap {
    grid-template-columns: 54px minmax(190px, 1fr) !important;
    column-gap: 13px !important;
  }

  .site-header .brand-wrap::before {
    width: 54px !important;
    height: 54px !important;
  }

  .site-header .brand,
  .cw-brand-copy strong,
  .about-static-brand-copy strong,
  .piper-public-brand-copy strong {
    font-family: 'Cinzel', Georgia, serif !important;
    font-size: 1.05rem !important;
    font-weight: 600 !important;
    letter-spacing: .13em !important;
    line-height: 1.06 !important;
    text-transform: uppercase;
  }

  .site-header .tagline,
  .cw-brand-copy em,
  .about-static-tagline,
  .piper-public-tagline {
    font-family: 'Cormorant Garamond', Georgia, serif !important;
    font-size: .72rem !important;
    font-style: italic;
    line-height: 1.16 !important;
  }

  .site-header .brand-foundations,
  .cw-brand-copy small,
  .about-static-kicker,
  .piper-public-foundations {
    display: block !important;
    margin-top: 3px;
    font-family: 'Cinzel', Georgia, serif !important;
    font-size: .65rem !important;
    color: #d8ccba !important;
    opacity: 1 !important;
    letter-spacing: .105em !important;
    line-height: 1.15 !important;
    text-transform: uppercase;
  }

  .cw-brand-inner {
    width: 100%;
    max-width: var(--pa-shell-max) !important;
    min-height: var(--pa-masthead-height);
    margin-right: auto;
    margin-left: auto;
    padding: 15px var(--pa-shell-pad) !important;
  }

  .cw-brand-home {
    grid-template-columns: 54px minmax(220px, 1fr) !important;
    gap: 13px !important;
  }

  .cw-brand-home img {
    width: 54px !important;
    height: 54px !important;
  }

  .about-static-mark,
  .piper-public-brand > img {
    width: 54px !important;
    height: 54px !important;
    flex-basis: 54px !important;
  }

  .piper-public-header {
    min-height: var(--pa-masthead-height);
    padding: 15px max(var(--pa-shell-pad), calc((100vw - 1136px) / 2));
  }

  /* One ivory pill navigation language across every public masthead. */
  .site-header .desktop-primary-nav,
  .cw-brand-nav,
  .about-static-nav,
  .piper-public-nav {
    display: flex !important;
    align-items: center !important;
    justify-content: flex-end !important;
    gap: 3px !important;
    padding: 4px !important;
    border: 1px solid rgba(184, 153, 99, .28) !important;
    border-radius: 999px !important;
    background: #f5f0e5 !important;
    box-shadow: 0 5px 20px rgba(0, 0, 0, .22) !important;
  }

  .site-header .desktop-primary-nav > .nav-button,
  .site-header .desktop-primary-nav > a,
  .site-header .desktop-primary-nav .primary-nav-explore-toggle,
  .cw-brand-nav > a,
  .cw-brand-more > summary,
  .about-static-nav > a,
  .about-more > summary,
  .piper-public-nav > a,
  .piper-public-nav > .pa-shared-more > summary {
    position: relative;
    display: inline-flex !important;
    align-items: center;
    justify-content: center;
    min-height: 44px;
    padding: 8px 12px !important;
    border: 1px solid transparent !important;
    border-radius: 999px !important;
    background: transparent !important;
    color: #171612 !important;
    box-shadow: none !important;
    font-family: 'Cinzel', Georgia, serif !important;
    font-size: .9rem !important;
    font-weight: 600 !important;
    letter-spacing: .035em !important;
    line-height: 1.1 !important;
    text-decoration: none !important;
    text-transform: none !important;
    white-space: nowrap;
  }

  .cw-brand-nav > a::after,
  .cw-brand-more > summary::after {
    content: none !important;
  }

  .site-header .desktop-primary-nav > .nav-button:hover,
  .site-header .desktop-primary-nav > a:hover,
  .site-header .desktop-primary-nav .primary-nav-explore-toggle:hover,
  .cw-brand-nav > a:hover,
  .cw-brand-more > summary:hover,
  .about-static-nav > a:hover,
  .about-more > summary:hover,
  .piper-public-nav > a:hover,
  .piper-public-nav > .pa-shared-more > summary:hover {
    border-color: rgba(184, 153, 99, .32) !important;
    background: #fffaf0 !important;
    color: #171612 !important;
  }

  .site-header .desktop-primary-nav > .active,
  .site-header .desktop-primary-nav .primary-nav-explore-toggle.active,
  .cw-brand-nav > a[aria-current='page'],
  .cw-brand-more.current > summary,
  .cw-brand-more[open] > summary,
  .about-static-nav > a[aria-current='page'],
  .about-more.active > summary,
  .about-more[open] > summary,
  .piper-public-nav > a[aria-current='page'],
  .piper-public-nav > a.active,
  .piper-public-nav > .pa-shared-more.active > summary,
  .piper-public-nav > .pa-shared-more[open] > summary {
    border-color: #9a805a !important;
    background: #9a805a !important;
    color: #fffaf0 !important;
    box-shadow: 0 3px 12px rgba(60, 48, 32, .2) !important;
  }

  /* Matching page width, opening gap, and opening-card silhouette. */
  #questions.screen.active,
  #apologetics.screen.active,
  .about-page.screen.active {
    padding-top: var(--pa-opening-gap) !important;
  }

  .church-writers-page .shell {
    width: 100%;
    max-width: var(--pa-shell-max) !important;
    margin-right: auto;
    margin-left: auto;
    padding: 0 var(--pa-shell-pad) 56px !important;
  }

  .church-writers-page #libraryHero.hero {
    margin-top: var(--pa-opening-gap) !important;
  }

  .questions-v2-hero,
  .church-writers-page #libraryHero.hero,
  .about-static-hero {
    overflow: hidden;
    border-radius: var(--pa-opening-radius) !important;
  }

  #apologetics .apologetics-workspace-nav {
    overflow: visible;
    border-radius: var(--pa-opening-radius) var(--pa-opening-radius) 0 0 !important;
  }

  #apologetics .apologetics-hub-hero {
    overflow: hidden;
    border-radius: 0 0 var(--pa-opening-radius) var(--pa-opening-radius) !important;
  }
}

@media (min-width: 721px) and (max-width: 900px) {
  body:not(.piper-editorial-home) > .site-shell > .site-header > .header-inner,
  .cw-brand-inner {
    align-items: flex-start !important;
    flex-direction: column !important;
    gap: 10px !important;
  }

  .site-header .desktop-primary-nav,
  .cw-brand-nav,
  .about-static-nav,
  .piper-public-nav {
    width: 100% !important;
    max-width: 100%;
    justify-content: flex-start !important;
    overflow: visible;
    scrollbar-width: none;
  }
}

@media (max-width: 720px) {
  :root {
    --pa-shell-pad: 14px;
    --pa-opening-radius: 18px;
    --pa-opening-gap: 12px;
  }

  .questions-v2-hero,
  .church-writers-page #libraryHero.hero,
  .about-static-hero {
    overflow: hidden;
    border-radius: var(--pa-opening-radius) !important;
  }

  #apologetics .apologetics-workspace-nav {
    border-radius: var(--pa-opening-radius) var(--pa-opening-radius) 0 0 !important;
  }

  #apologetics .apologetics-hub-hero {
    overflow: hidden;
    border-radius: 0 0 var(--pa-opening-radius) var(--pa-opening-radius) !important;
  }
}

/* Four primary study paths. Supporting pages remain in the More menu. */
@media(min-width:721px){
  nav[aria-label="Main navigation"] .about-more-menu{
    max-height:min(70vh,620px);overflow-y:auto;overscroll-behavior:contain;
  }
  .ocia-site-nav{display:flex;align-items:center;flex-wrap:nowrap;gap:4px}
  .ocia-site-nav>.about-more>summary{cursor:pointer}
}



/* Studies is the visual reference for the four primary research areas.
   Shared tokens and scoped components live in this canonical layout owner.
   Higher route-root specificity keeps late feature styles from restyling them. */
:root{
  --pa-reading-paper:#f5f1ea;
  --pa-reading-card:#fffaf1;
  --pa-reading-ink:#201b16;
  --pa-reading-muted:#665d51;
  --pa-reading-line:#d4c6b3;
  --pa-reading-gold:#9a805a;
  --pa-reading-radius:18px;
  --pa-reading-title:clamp(2.4rem,5vw,4.1rem);
  --pa-reading-heading:clamp(1.65rem,3vw,2.3rem);
}
/* Place the three brand lines in the same column, so the foundation line
   cannot wrap into the medallion column and stretch the app masthead. */
@media(min-width:721px){
  body:not(.piper-editorial-home) .site-header .brand-wrap{grid-template-rows:auto auto auto!important;row-gap:2px!important}
  body:not(.piper-editorial-home) .site-header .brand-wrap::before{grid-column:1!important;grid-row:1 / 4!important}
  body:not(.piper-editorial-home) .site-header .brand{grid-column:2!important;grid-row:1!important}
  body:not(.piper-editorial-home) .site-header .tagline{grid-column:2!important;grid-row:2!important}
  body:not(.piper-editorial-home) .site-header .brand-foundations{grid-column:2!important;grid-row:3!important}
}
body.church-writers-page,
body:has(#dialogue.screen.active),
body:has(#heresy.screen.active){background:var(--pa-reading-paper)!important}
#dialogue.screen,#heresy.screen,.church-writers-page .shell{
  --surface:#fffaf1;--surface-2:#f1e8da;--text:#201b16;--muted:#665d51;
  --border:#d4c6b3;--accent:#9a805a;--accent-dark:#70512f;--accent-soft:#eee4d5;
  color:var(--pa-reading-ink);
}
#dialogue.screen.active,#heresy.screen.active{padding-top:24px!important;padding-bottom:64px!important}
#dialogue #dialogue-app .if-clean,#dialogue #dialogue-app .dialogue-shell,
#heresy #heresy-app .heresy-shell{width:100%;max-width:1136px!important;margin-inline:auto!important}
.church-writers-page .shell{max-width:1180px!important;padding:0 22px 64px!important}

/* One illustrated opening; a continuous paper page follows it. */
.church-writers-page #libraryHero.hero,
#dialogue #dialogue-app .if-clean-hero,
#heresy #heresy-app .heresy-hero{
  padding:44px!important;min-height:320px;
  border:1px solid #3b342b!important;border-radius:var(--pa-reading-radius)!important;
  box-shadow:0 18px 44px rgba(43,33,22,.12)!important;
}
.church-writers-page #libraryHero.hero{margin-top:24px!important}
.church-writers-page #libraryHero h1,
#dialogue #dialogue-app .if-clean-hero h1,
#heresy #heresy-app .heresy-hero h1{
  max-width:800px!important;margin:10px 0 14px!important;
  color:#fffdf8!important;font:700 var(--pa-reading-title)/1.03 Georgia,'Times New Roman',serif!important;
  letter-spacing:-.035em!important;
}
.church-writers-page #libraryHero>p,
#dialogue #dialogue-app .if-clean-hero>p,
#heresy #heresy-app .heresy-hero>div>p{
  max-width:780px!important;color:#e2d9ca!important;
  font:400 1rem/1.65 Georgia,'Times New Roman',serif!important;
}
.church-writers-page #libraryHero .eye,
#dialogue #dialogue-app .if-clean-hero .eyebrow,
#heresy #heresy-app .heresy-hero .eyebrow{
  color:#d0aa68!important;font:700 .7rem/1.4 Arial,sans-serif!important;letter-spacing:.15em!important;
}
.church-writers-page #libraryHero .notice{font-size:.84rem!important;line-height:1.6!important;padding:14px 16px!important;margin-top:20px!important}
.church-writers-page #libraryHero .metrics span{font-size:.72rem!important;line-height:1.4}
#dialogue #dialogue-app .if-clean-hero:after{content:none!important}
#dialogue #dialogue-app .if-clean-step{padding:12px 14px!important;border-radius:9px!important}
#dialogue #dialogue-app .if-clean-step strong{font-size:.86rem!important}
#dialogue #dialogue-app .if-clean-step span{font-size:.78rem!important;line-height:1.5!important;color:#ded5c7!important}
#heresy #heresy-app .heresy-rule{padding:18px!important;align-self:center!important}
#heresy #heresy-app .heresy-rule p{font-size:.86rem!important;line-height:1.6!important}

/* Search, topic selection, and evidence controls share one vocabulary. */
.church-writers-page .search input,
#dialogue #dialogue-app .if-clean-search input{
  min-height:46px!important;padding:12px 14px!important;border:1px solid var(--pa-reading-line)!important;
  border-radius:10px!important;background:#fffdf9!important;color:var(--pa-reading-ink)!important;
  font:400 .95rem/1.4 Georgia,'Times New Roman',serif!important;
}
#dialogue #dialogue-app .if-clean-search{font-size:.75rem!important;gap:7px!important}
#dialogue #dialogue-app .if-clean-toolbar{margin:32px 0 18px!important}
#dialogue #dialogue-app .if-clean-toolbar h2{
  font:700 var(--pa-reading-heading)/1.1 Georgia,'Times New Roman',serif!important;letter-spacing:-.025em;
}
.church-writers-page .browse-modes button,.church-writers-page .filter,
#dialogue #dialogue-app .if-clean-filter{
  min-height:40px!important;font-size:.8rem!important;line-height:1.3!important;padding:9px 13px!important;
}
.church-writers-page .browse-modes{margin:24px 0 16px!important;background:#eee5d7!important;border-color:var(--pa-reading-line)!important}
.church-writers-page .filter.active,#dialogue #dialogue-app .if-clean-filter.is-active{
  background:#9a805a!important;color:#fffaf0!important;border-color:#9a805a!important;
}
.church-writers-page .back-btn,.church-writers-page .copy-btn,.church-writers-page .search button,
#dialogue #dialogue-app .dialogue-back,#dialogue #dialogue-app .dialogue-action,
#heresy #heresy-app .heresy-back,#heresy #heresy-app .heresy-action{
  min-height:42px!important;padding:10px 14px!important;border:1px solid var(--pa-reading-line)!important;
  border-radius:9px!important;background:#fffaf1!important;color:#70512f!important;
  font:700 .83rem/1.35 Georgia,'Times New Roman',serif!important;text-decoration:none;
}
.church-writers-page .detail-actions,#dialogue #dialogue-app .flow-nav{gap:8px!important;margin:18px 0!important}

/* Topic cards remain restrained, readable, and visibly interactive. */
.church-writers-page .topic-card,.church-writers-page .council-card,
#dialogue #dialogue-app .if-clean-card,#heresy #heresy-app .heresy-card{
  border-color:var(--pa-reading-line)!important;border-radius:14px!important;background:#fffaf1!important;
  box-shadow:0 7px 20px rgba(43,33,22,.04)!important;
}
.church-writers-page .topic-card{padding:20px!important}
.church-writers-page .topic-card h3,.church-writers-page .council-card h3,
#dialogue #dialogue-app .if-clean-card h3,#heresy #heresy-app .heresy-card h2{
  font:700 1.25rem/1.2 Georgia,'Times New Roman',serif!important;color:var(--pa-reading-ink)!important;
}
.church-writers-page .topic-card p,.church-writers-page .council-card p,
#dialogue #dialogue-app .if-clean-card p,#heresy #heresy-app .heresy-card p{
  font:400 .88rem/1.6 Georgia,'Times New Roman',serif!important;color:var(--pa-reading-muted)!important;
}
#dialogue #dialogue-app .if-clean-card strong{font-size:.9rem!important;line-height:1.45!important}
#dialogue #dialogue-app .if-clean-card .eyebrow,#heresy #heresy-app .heresy-card .eyebrow{font-size:.68rem!important}
#dialogue #dialogue-app .if-clean-grid,#heresy #heresy-app .heresy-grid,.church-writers-page .topic-grid{gap:14px!important}
.church-writers-page .topic-stats span,#heresy #heresy-app .heresy-card-foot span{font-size:.72rem!important;line-height:1.45}
#heresy #heresy-app .heresy-card-foot strong{font-size:.8rem!important}

/* Reading pages: clear hierarchy and source text instead of tiny nested boxes. */
.church-writers-page .section,.church-writers-page .quote-card,
#heresy #heresy-app .heresy-argument-panel{
  border-color:var(--pa-reading-line)!important;border-radius:14px!important;
  box-shadow:0 7px 20px rgba(43,33,22,.035)!important;
}
.church-writers-page .section-head,.church-writers-page .quote-head{padding:18px!important}
.church-writers-page .section-title h2{font:700 1.25rem/1.25 Georgia,serif!important}
.church-writers-page .section-meta,.church-writers-page .work{font-size:.78rem!important;line-height:1.5!important}
.church-writers-page .quote{font-size:.95rem!important;line-height:1.7!important;background:#f1e8da!important}
.church-writers-page .context-box,.church-writers-page .history-note,.church-writers-page .excerpt-caution{font-size:.82rem!important;line-height:1.6!important}
#dialogue #dialogue-app .flow-topic h1{font:700 clamp(2rem,4.5vw,3.25rem)/1.08 Georgia,serif!important}
#dialogue #dialogue-app .flow-position>header{background:#eee5d7!important;border-left-color:#9a805a!important}
#dialogue #dialogue-app .flow-position h2{font:700 1.6rem/1.2 Georgia,serif!important}
#dialogue #dialogue-app .flow-step{padding:24px 22px!important}
#dialogue #dialogue-app .flow-step>p,#dialogue #dialogue-app .flow-step>ul,#dialogue #dialogue-app .flow-step>details{max-width:880px}
#dialogue #dialogue-app .flow-step h3{font:700 1.15rem/1.35 Georgia,serif!important}
#dialogue #dialogue-app .flow-step p,#dialogue #dialogue-app .flow-step li{font-size:.95rem!important;line-height:1.7!important}
#dialogue #dialogue-app .flow-nav a{border-radius:9px!important;background:#fffaf1!important;padding:10px 16px!important;font-size:.9rem!important}
#heresy #heresy-app .heresy-detail-head{border-radius:18px!important;padding:32px!important}
#heresy #heresy-app .heresy-detail-head h1{font:700 clamp(2rem,4.5vw,3.25rem)/1.08 Georgia,serif!important}
#heresy #heresy-app .heresy-detail-head>p{font-size:.95rem!important;line-height:1.65!important}
#heresy #heresy-app .heresy-panel p,#heresy #heresy-app .heresy-analysis-row p,
#heresy #heresy-app .heresy-scripture p{font-size:.95rem!important;line-height:1.7!important}
#heresy #heresy-app .heresy-trinity-case{border-width:1px!important;padding:24px!important;background:#f1e8da!important}
#heresy #heresy-app .heresy-trinity-case>p{font-size:.88rem!important;line-height:1.6!important}
#heresy #heresy-app .heresy-trinity-card strong{font-size:.9rem!important;line-height:1.3}
#heresy #heresy-app .heresy-trinity-card span{font-size:.8rem!important;line-height:1.55!important}

/* Keyboard focus stays visible; long references never widen the page. */
.church-writers-page .shell :focus-visible,
#dialogue #dialogue-app :focus-visible,#heresy #heresy-app :focus-visible{
  outline:2px solid #9a805a!important;outline-offset:3px!important;
}
.church-writers-page .quote-body a,#dialogue #dialogue-app .flow-source a,
#heresy #heresy-app .heresy-sources a{overflow-wrap:anywhere}
@media(max-width:760px){
  .church-writers-page .shell{padding:0 14px 48px!important}
  .church-writers-page #libraryHero.hero{margin-top:12px!important}
  #dialogue.screen.active,#heresy.screen.active{padding-top:12px!important}
  .church-writers-page #libraryHero.hero,#dialogue #dialogue-app .if-clean-hero,#heresy #heresy-app .heresy-hero{
    padding:28px 22px!important;min-height:0!important;border-radius:14px!important;
  }
  .church-writers-page #libraryHero h1,#dialogue #dialogue-app .if-clean-hero h1,#heresy #heresy-app .heresy-hero h1{
    font-size:clamp(2rem,8vw,2.75rem)!important;line-height:1.07!important;
  }
  .church-writers-page #libraryHero>p,#dialogue #dialogue-app .if-clean-hero>p,#heresy #heresy-app .heresy-hero>div>p{font-size:.95rem!important}
  #dialogue #dialogue-app .if-clean-card{grid-template-columns:110px minmax(0,1fr)!important;gap:13px!important}
  #dialogue #dialogue-app .if-clean-copy{padding:16px 14px 16px 0!important}
  #dialogue #dialogue-app .if-clean-arrow{display:none!important}
  #dialogue #dialogue-app .flow-step{padding:20px 14px!important}
  #heresy #heresy-app .heresy-detail-head{padding:26px 22px!important}
  #heresy #heresy-app .heresy-trinity-grid{grid-template-columns:1fr!important}
}
@media(prefers-reduced-motion:reduce){
  .church-writers-page .shell *,#dialogue #dialogue-app *,#heresy #heresy-app *{scroll-behavior:auto!important;transition:none!important}
}


/* Steps 4–6: one entrance, a clear return path, supporting evidence on demand. */
#dialogue #dialogue-app .research-disclosure,
#heresy #heresy-app .research-disclosure,
.church-writers-page .research-disclosure {
  margin:18px 0;border:1px solid var(--pa-reading-line);border-radius:12px;
  background:var(--pa-reading-card);color:var(--pa-reading-ink);overflow:hidden;
}
#dialogue #dialogue-app .research-disclosure > summary,
#heresy #heresy-app .research-disclosure > summary,
.church-writers-page .research-disclosure > summary {
  display:flex;align-items:center;justify-content:space-between;gap:16px;
  padding:15px 18px;min-height:48px;font:.88rem/1.5 Georgia,serif;font-weight:700;
  cursor:pointer;list-style:none;color:var(--pa-reading-ink);
}
.research-disclosure > summary::-webkit-details-marker{display:none}
.research-disclosure > summary::after{content:'+';font:700 1.25rem/1 Georgia,serif;color:#9a805a;flex:none}
.research-disclosure[open] > summary::after{content:'−'}
#dialogue #dialogue-app .research-disclosure > :not(summary),
#heresy #heresy-app .research-disclosure > :not(summary),
.church-writers-page .research-disclosure > :not(summary){margin:0;padding:0 18px 18px}
.research-disclosure > summary:focus-visible{outline:2px solid #9a805a;outline-offset:-4px}
.church-writers-page #libraryHero .hero-disclosure{background:rgba(22,18,13,.6);border-color:rgba(222,192,142,.35);margin-bottom:0}
.church-writers-page #libraryHero .hero-disclosure > summary{color:#f5ead5;font-size:.85rem;padding:12px 16px}
.church-writers-page #libraryHero .hero-disclosure .notice{background:transparent;border:0;color:#ded4c5;font-size:.85rem}
.church-writers-page #libraryHero .hero-disclosure .metrics{color:#ded4c5}
#dialogue #dialogue-app .research-path{margin-top:20px;font-size:.88rem;color:#d7bc90}
.research-result-count{color:#665d51;font-size:.82rem;margin:0 0 12px}
.research-browse-toolbar{display:flex;align-items:end;justify-content:space-between;gap:24px;margin:30px 0 14px}
.research-browse-toolbar h2{margin:5px 0 0;font:700 clamp(1.65rem,3vw,2.3rem)/1.15 Georgia,serif}
.research-browse-toolbar label{display:grid;gap:6px;width:min(360px,100%);font-size:.82rem;color:#665d51}
.research-browse-toolbar input{width:100%;min-height:46px;padding:11px 14px;border:1px solid #d4c6b3;border-radius:10px;background:#fffaf1;color:#201b16;font:inherit}
.research-copy-status{font-size:.82rem;margin-left:12px;color:#665d51}
#heresy #heresy-app [hidden],.church-writers-page [hidden]{display:none!important}
#heresy #heresy-app .research-disclosure .heresy-trinity-case{border:0;box-shadow:none;background:transparent}
#heresy #heresy-app .research-disclosure .heresy-method{margin:0;border:0;background:transparent}
#dialogue #dialogue-app .research-disclosure .dialogue-scripture{grid-template-columns:1fr}
@media(max-width:760px){.research-browse-toolbar{display:block}.research-browse-toolbar label{margin-top:14px;width:100%}.research-disclosure > summary{padding:14px!important}.research-disclosure > :not(summary){padding-left:14px!important;padding-right:14px!important}}


/* Studies uses a research canvas rather than the narrow article shell. */
.launch-main:has(> #studies){width:min(calc(100% - 48px),1280px);padding-top:32px}
@media(max-width:720px){.launch-main:has(> #studies){width:calc(100% - 20px)!important;padding-top:14px!important}}


@media(min-width:721px){
  :is(.cw-brand-inner,.piper-public-header,.site-header .header-inner){display:flex;align-items:center;flex-wrap:wrap;gap:16px}
  :is(.cw-brand-home,.piper-public-brand){flex:0 1 auto;min-width:0}
  :is(.cw-brand-copy,.piper-public-brand-copy) strong{display:flex!important;flex-wrap:wrap;gap:0 .3em}
  :is(.cw-brand-copy,.piper-public-brand-copy) strong :is(.brand-piper,.brand-apologetics){font-size:1.05rem!important;line-height:1.2!important}
  :is(.piper-public-nav,.desktop-primary-nav){margin-left:auto;max-width:100%;flex-wrap:wrap!important}
}

/* Canonical header geometry: the same single row at desktop widths. */
@media(min-width:1100px){
  body .site-header .header-inner,body .cw-brand-inner,body .piper-public-header,body .about-static-header{
    box-sizing:border-box!important;display:flex!important;flex-direction:row!important;flex-wrap:nowrap!important;align-items:center!important;justify-content:space-between!important;gap:16px!important;min-height:84px!important;height:84px!important;padding:15px 22px!important;margin-inline:auto!important;width:100%!important;max-width:1280px!important;
  }
  body .site-header .brand-wrap,body .cw-brand-home,body .piper-public-brand{flex:0 0 285px!important;min-width:0!important;grid-template-columns:54px minmax(0,1fr)!important;gap:0 12px!important;}
  body .site-header .brand-wrap::before,body .cw-brand-home img,body .piper-public-brand>img{width:54px!important;height:54px!important;}
  body .site-header .brand-wrap::before{grid-column:1!important;grid-row:1 / 4!important;}
  body .site-header .brand{grid-column:2!important;grid-row:1!important;}
  body .site-header .tagline{grid-column:2!important;grid-row:2!important;}
  body .site-header .brand-foundations{grid-column:2!important;grid-row:3!important;}
  body .cw-brand-copy strong,body .piper-public-brand-copy strong{flex-direction:row!important;flex-wrap:nowrap!important;white-space:nowrap!important;gap:.3em!important;}
  body .site-header .brand,body .site-header .brand-name,body .site-header .brand-piper,body .site-header .brand-apologetics{font-size:1.05rem!important;letter-spacing:.06em!important;white-space:nowrap!important;}
  body .site-header .desktop-primary-nav,body .cw-brand-nav,body .piper-public-nav,body .about-static-nav{flex:0 0 auto!important;flex-wrap:nowrap!important;width:max-content!important;margin-left:auto!important;gap:3px!important;}
  body .site-header .desktop-primary-nav>a,body .site-header .primary-nav-explore-toggle,body .cw-brand-nav>a,body .cw-brand-more>summary,body .piper-public-nav>a,body .piper-public-nav>details>summary,body .about-static-nav>a,body .about-more>summary{font-size:.85rem!important;letter-spacing:0!important;padding:8px 10px!important;min-height:44px!important;white-space:nowrap!important;}
}
body :is(.desktop-primary-nav,.cw-brand-nav,.piper-public-nav,.about-static-nav,.ocia-site-nav)>:is(a,button).active,
body :is(.desktop-primary-nav,.cw-brand-nav,.piper-public-nav,.about-static-nav,.ocia-site-nav)>a[aria-current="page"],
body .site-header .desktop-primary-nav .primary-nav-explore-toggle.active,
body :is(.cw-brand-more,.about-more,.pa-shared-more,.piper-public-more):is(.active,.current,[open])>summary{
  color:#1a1612!important;background:#fff8e9!important;border-color:#9a805a!important;box-shadow:inset 0 -2px 0 #9a805a!important;
}
input[type="search"]::-webkit-search-cancel-button{appearance:none;-webkit-appearance:none;width:16px;height:16px;cursor:pointer;background:linear-gradient(45deg,transparent 44%,#79613e 45% 55%,transparent 56%),linear-gradient(-45deg,transparent 44%,#79613e 45% 55%,transparent 56%);}
body .pa-unified-footer{display:block!important;box-sizing:border-box;margin:0!important;padding:38px 22px 24px!important;background:#171511!important;color:#e9dfd0!important;border-top:1px solid #544735!important;font:400 .88rem/1.6 Georgia,serif!important;width:100%!important;}
.pa-footer-inner{max-width:1236px;margin:auto;display:grid;grid-template-columns:1.5fr 1fr 1fr;gap:24px;}
.pa-unified-footer strong{color:#fff6e5;font-weight:600;}.pa-unified-footer p{margin:8px 0;}.pa-unified-footer small{color:#c6b79f;}
.pa-unified-footer nav{display:grid;align-content:start;gap:8px;}.pa-unified-footer a{color:#eee4d5!important;text-decoration:none;font:inherit!important;}.pa-unified-footer a:hover{text-decoration:underline;}.pa-footer-bottom{grid-column:1/-1;border-top:1px solid #544735;padding-top:18px;font-size:.8rem;}.pa-footer-bottom strong{margin-left:12px;}
@media(max-width:720px){.pa-footer-inner{grid-template-columns:1fr 1fr;}.pa-footer-inner>div{grid-column:1/-1;}.pa-footer-bottom strong{display:block;margin:8px 0 0;}}
/* Empty study containers should never leave a dark slab below the reading. */
body:has(#studies) .launch-main,body:has(#studies) #bible-study-detail{background:#f5f1ea!important;}
#studies #bible-study-detail[hidden],#studies #bible-study-browse[hidden]{display:none!important;}
#studies .study-master-view,#studies .study-master-article{background:transparent!important;}
#studies .study-master-article:after{content:none!important;}

@media(min-width:1100px){body .site-header .brand-name{display:flex!important;flex-wrap:nowrap!important;gap:.3em!important;}body .site-header .brand-name>span{display:inline!important;}body .site-header .brand-wrap{grid-template-rows:auto auto auto!important;}}

/* Oct 10 follow-up: one desktop brand block on every page (index shell, Studies, Writers, About).
   Header grows with its content (no fixed 84px clip); wordmark, tagline and foundations each stay on one line. */
@media(min-width:1000px){
  html body .site-header .header-inner,html body .cw-brand-inner,html body .piper-public-header,html body .about-static-header{
    box-sizing:border-box!important;display:flex!important;flex-direction:row!important;flex-wrap:nowrap!important;align-items:center!important;justify-content:space-between!important;gap:18px!important;height:auto!important;min-height:92px!important;padding:14px 22px!important;margin-inline:auto!important;width:100%!important;max-width:1280px!important;
  }
  /* Studies' header is its own row and carries the 1px rule inside its box; match the 92px row + 1px rule of the other headers. */
  html body header.piper-public-header,html body header.about-static-header{min-height:93px!important;}
  html body .site-header .brand-wrap,html body .cw-brand-home,html body .piper-public-brand{
    flex:0 0 auto!important;min-width:0!important;display:grid!important;grid-template-columns:54px max-content!important;grid-template-rows:auto auto auto!important;gap:2px 12px!important;align-items:center!important;align-content:center!important;height:auto!important;overflow:visible!important;
  }
  html body .site-header .brand-wrap::before,html body .cw-brand-home>img,html body .piper-public-brand>img{grid-column:1!important;grid-row:1 / 4!important;width:54px!important;height:54px!important;align-self:center!important;margin:0!important;}
  html body .cw-brand-copy,html body .piper-public-brand-copy{grid-column:2!important;grid-row:1 / 4!important;display:flex!important;flex-direction:column!important;gap:2px!important;min-width:0!important;}
  html body .site-header .brand{grid-column:2!important;grid-row:1!important;}
  html body .site-header .tagline{grid-column:2!important;grid-row:2!important;}
  html body .site-header .brand-foundations{grid-column:2!important;grid-row:3!important;}
  html body .site-header .brand,html body .site-header .brand-name,html body .cw-brand-copy strong,html body .piper-public-brand-copy strong{display:flex!important;flex-direction:row!important;flex-wrap:nowrap!important;gap:.3em!important;white-space:nowrap!important;margin:0!important;padding:0!important;height:auto!important;line-height:1.2!important;}
  html body .site-header .brand-name>span,html body :is(.site-header,.cw-brand-copy,.piper-public-brand-copy) :is(.brand-piper,.brand-apologetics){display:inline!important;font-family:'Cinzel',Georgia,serif!important;font-size:1.05rem!important;font-weight:600!important;letter-spacing:.06em!important;line-height:1.2!important;white-space:nowrap!important;margin:0!important;transform:none!important;position:static!important;}
  html body .site-header .tagline,html body .cw-brand-copy em,html body .piper-public-tagline{display:block!important;font-size:.72rem!important;line-height:1.2!important;white-space:nowrap!important;margin:0!important;}
  html body .site-header .brand-foundations,html body .cw-brand-copy small,html body .piper-public-foundations{display:block!important;font-size:.56rem!important;letter-spacing:.08em!important;line-height:1.2!important;white-space:nowrap!important;margin:1px 0 0!important;}
  html body .site-header .brand-foundations[hidden]{display:block!important;}
  html body .site-header .desktop-primary-nav,html body .cw-brand-nav,html body .piper-public-nav,html body .about-static-nav{flex:0 0 auto!important;flex-wrap:nowrap!important;width:max-content!important;margin-left:auto!important;gap:3px!important;}
  html body .site-header .desktop-primary-nav>a.nav-button,html body .site-header .desktop-primary-nav>button.nav-button,html body .site-header .desktop-primary-nav>[data-screen].nav-button,html body .site-header .desktop-primary-nav .primary-nav-explore-toggle.nav-button,html body .site-header .desktop-primary-nav>a,html body .site-header .primary-nav-explore-toggle,html body .cw-brand-nav>a,html body .cw-brand-more>summary,html body .piper-public-nav>a,html body .piper-public-nav>details>summary,html body .about-static-nav>a,html body .about-more>summary{font-size:.85rem!important;letter-spacing:0!important;padding:8px 10px!important;min-height:44px!important;white-space:nowrap!important;}
}
@media(min-width:1000px) and (max-width:1099px){
  html body .site-header .desktop-primary-nav>a.nav-button,html body .site-header .desktop-primary-nav>button.nav-button,html body .site-header .desktop-primary-nav>[data-screen].nav-button,html body .site-header .desktop-primary-nav .primary-nav-explore-toggle.nav-button,html body .site-header .desktop-primary-nav>a,html body .site-header .primary-nav-explore-toggle,html body .cw-brand-nav>a,html body .cw-brand-more>summary,html body .piper-public-nav>a,html body .piper-public-nav>details>summary,html body .about-static-nav>a,html body .about-more>summary{padding:8px 7px!important;}
}
/* Active tab: same cream pill + charcoal everywhere (Refuting Heresy previously used a tan variant). */
html body :is(.desktop-primary-nav,.cw-brand-nav,.piper-public-nav,.about-static-nav)>:is(a,button):is(.active,[aria-current="page"]),
html body .site-header .desktop-primary-nav>a.nav-button.active,html body .site-header .desktop-primary-nav>button.nav-button.active,html body .site-header .desktop-primary-nav>[data-screen].active,
html body.piper-editorial-home .site-header .desktop-primary-nav>a.nav-button.active,
html body .site-header .desktop-primary-nav .primary-nav-explore-toggle.active{color:#1a1612!important;background:#fff8e9!important;border-color:#9a805a!important;box-shadow:inset 0 -2px 0 #9a805a!important;}
/* Scripture & data credits inside the unified footer (license attribution). */
.pa-footer-credits{grid-column:1/-1;border-top:1px solid #544735;padding-top:16px;color:#c6b79f;font-size:.74rem;line-height:1.55;}
.pa-footer-credits p{margin:0 0 6px!important;max-width:1100px;}
body .pa-unified-footer .pa-footer-credits a{text-decoration:underline!important;text-underline-offset:2px;}
