:root {
    --ink: #271d20;
    --ink-soft: #38282e;
    --wine: #672d45;
    --wine-deep: #4d2234;
    --peach: #f3c5aa;
    --paper: #f8f5ef;
    --white: #fffdfa;
    --muted: #695a5d;
    --line: #ded2c6;
    --terracotta: #a15c47;
    --night: #251820;
    --radius: 0.4rem;
    --shadow: 0 0.55rem 1.8rem #39202b0d;
}

.container { width: min(100% - clamp(2rem, 9vw, 10rem), 80rem); }
h1, h2 { letter-spacing: -0.05em; }
.overline { color: #875143; letter-spacing: 0.14em; }
.button, .outline-link { min-height: 2.85rem; border-radius: 0.32rem; padding-inline: 1rem; }
.text-link { text-decoration-thickness: 1px; }
.site-header { background: #fff; box-shadow: 0 2px 18px #37212b0b; }
.site-header .brand-wordmark {
    width: clamp(8rem, 13vw, 11rem);
    height: auto;
    padding: 0;
    border-radius: 0;
}
.site-header .brand-mark { display: none; }
.masthead { min-height: 5rem; gap: clamp(1rem, 2.5vw, 2.5rem); }
.main-nav { gap: clamp(0.75rem, 2vw, 1.85rem); }
.main-nav a { border-bottom-width: 1px; }
.main-nav a[aria-current] { color: var(--wine); }
.main-nav .mobile-community-link { display: none; }
.menu-toggle { display: none; }
.menu-toggle:focus-visible { outline: 2px solid var(--wine); outline-offset: -2px; }
.search-link { border-radius: 0.32rem; }
.search-link:hover, .search-link[aria-current] { background: var(--paper); }

.opening {
    border-bottom: 1px solid #dfcec0;
    color: var(--wine-deep);
    background: radial-gradient(ellipse at 88% 76%, #e4cbb9 0, transparent 54%), linear-gradient(118deg, #fcf9f3 26%, #f1e5d8 100%);
}
.opening-grid { grid-template-columns: minmax(0, 1.12fr) minmax(0, 0.88fr); gap: clamp(2.4rem, 7vw, 7rem); padding-block: clamp(2.5rem, 6vw, 5.8rem); }
.opening .overline { color: #824a3c; }
.opening .overline::before { background: var(--terracotta); }
.opening h1 { margin-top: 1.1rem; font-size: clamp(3.05rem, 6.35vw, 6.5rem); line-height: 0.98; letter-spacing: -0.06em; }
.opening h1 em { color: #9b513d; }
.opening-deck { color: var(--muted); max-width: 45ch; }
.opening .search-box { padding: 0.35rem; border-color: #d6c4b7; border-radius: 0.45rem; background: #fffdfa; box-shadow: 0 0.7rem 2rem #4d223412; }
.opening-links { gap: 0.1rem 1.1rem; margin-top: 0.95rem; }
.opening-links a { padding: 0; border: 0; border-radius: 0; color: var(--wine-deep); text-decoration: underline; text-decoration-thickness: 1px; }
.opening-links a:hover { color: var(--terracotta); }
.opening-highlights { width: min(100%, 31rem); margin-inline: auto; }
.opening-art {
    aspect-ratio: 0.98;
    border: 1px solid #745344;
    border-radius: 50% 50% 0.25rem 0.25rem / 39% 39% 0.25rem 0.25rem;
    outline: 1px solid #ab7d65;
    outline-offset: 0.5rem;
    box-shadow: 0 1.6rem 2.75rem #5233212e;
}
.opening-art img { object-position: center 73%; }
.opening-art figcaption { inset: auto 0.8rem 0.8rem; display: flex; justify-content: center; transform: none; white-space: normal; }
.opening-art figcaption a { border-radius: 0.25rem; background: #2a1822f0; }
.opening-scripture::before {
    content: "";
    position: absolute;
    z-index: 1;
    inset: 0;
    background: linear-gradient(180deg, #21151080 0%, #211510c9 30%, #21151080 55%, transparent 77%);
    pointer-events: none;
}
.opening-verse {
    position: absolute;
    z-index: 2;
    inset: 19% 10% auto;
    margin: 0;
    color: #fff9ee;
    text-align: center;
}
.opening-verse p {
    font: 500 clamp(.88rem, 1.3vw, 1.12rem)/1.5 var(--serif);
    text-wrap: pretty;
    text-shadow: 0 1px 5px #160b09;
}
.opening-scripture figcaption { z-index: 2; }
.highlight-controls { margin-top: 1.2rem; gap: 0.8rem; color: var(--wine-deep); }
.highlight-controls button { width: 2.75rem; height: 2.75rem; border-color: #a9816e; color: var(--wine-deep); }
.highlight-controls button:hover { color: #fff; background: var(--wine-deep); border-color: var(--wine-deep); }

.question-band { background: var(--night); border-bottom-color: #3c2731; color: var(--white); }
.question-links, .question-links a { border-color: #fbefdf40; }
.question-links a { color: #fff4e9; padding-inline: 0.65rem; }
.question-links a span { color: var(--peach); }
.question-links a:hover, .question-links a:focus-visible { background: #ffffff13; }
.question-intro p { color: #e3d2cd; }
.question-intro .button { color: var(--night); background: var(--peach); border-color: var(--peach); }
.question-intro .button:hover { background: var(--white); border-color: var(--white); }
.homepage-answers { padding-block: clamp(2.75rem, 6vw, 5rem) 0; }
.answer-start-links { gap: 0; border-block: 1px solid var(--line); }
.answer-start-links a { padding: clamp(1rem, 2.5vw, 1.8rem); border: 0; border-inline-start: 2px solid var(--terracotta); }
.answer-start-links a strong { font-size: clamp(1.25rem, 2.35vw, 1.95rem); }
.answer-start-links a:hover { background: #efe5da; }
.topic-item:hover, .topic-item:focus-visible { background: #eee4d9; }
.featured-reading { border-radius: 0.35rem; }
.feature-band { background: #eee5da; }
.join-band { background: #4d2234; }
.verse-band { background: var(--night); }
.verse-layout figure { background: transparent; border: 0; border-inline-start: 2px solid #ce9e81; border-radius: 0; }

.page-banner {
    background: radial-gradient(ellipse at 95% 0%, #efe2d4, transparent 70%), #f3ede4;
    color: var(--wine-deep);
    border-bottom: 1px solid var(--line);
}
.page-banner .overline { color: #875143; }
.banner-content { padding-block: clamp(2.6rem, 6vw, 5.5rem); }
.banner-content h1 { max-width: 23ch; font-size: clamp(2.55rem, 6.1vw, 5.8rem); text-wrap: balance; }
.banner-content p:not(.overline) { color: var(--muted); }
.banner-content .breadcrumb, .project-breadcrumb, .news-breadcrumb, .reader-saved-link { color: var(--wine); }
.banner-content .button-peach { background: var(--wine-deep); border-color: var(--wine-deep); color: #fffdfa; }
.banner-content .button-peach:hover { background: var(--wine); border-color: var(--wine); }
.reader-actions [aria-pressed="true"] { background: #fffdfa; border-color: #8d665f; color: var(--wine-deep); }
.banner-library {
    background: linear-gradient(90deg, #291922 26%, #291922e5 48%, #2919225e 100%), url("reading-room.webp") right center / min(72rem, 82%) auto no-repeat, #291922;
}
.banner-library h1, .banner-library .overline { color: #fff3e8; }
.banner-library .banner-content p:not(.overline) { color: #f3e4db; }
.banner-library .banner-content .button-peach { background: var(--peach); border-color: var(--peach); color: var(--night); }
.banner-library .banner-content .button-peach:hover { background: var(--white); border-color: var(--white); }
.answers-banner .answers-search { max-width: 40rem; box-shadow: var(--shadow); }
.news-masthead { border-bottom: 2px solid #a86550; }
.news-story-header .banner-content, .article-banner .banner-content { max-width: 72rem; }
.news-story-header .banner-content h1, .article-banner .banner-content h1 { text-wrap: pretty; }
.project-banner::after { content: none; }
:is(.showcase-banner, .discussion-banner, .project-banner) .banner-content {
    display: grid;
    grid-template-columns: minmax(0, 1.05fr) minmax(0, 0.95fr);
    align-items: center;
    gap: clamp(1.3rem, 5vw, 5.5rem);
}
.banner-copy .button { margin-top: 1rem; }
.banner-copy .project-actions .button { margin-top: 0; }
.project-secondary { color: var(--wine); }
.page-banner img.banner-photo {
    position: static;
    width: 100%;
    height: auto;
    aspect-ratio: 1.65;
    object-fit: cover;
    z-index: auto;
    border: 1px solid #a77a61;
    border-radius: 0.35rem;
    box-shadow: var(--shadow);
}
.showcase-banner .banner-photo { border-radius: 48% 48% 0.35rem 0.35rem / 32% 32% 0.35rem 0.35rem; }
.discussion-banner { background: radial-gradient(ellipse at 90% 10%, #ead6cb, transparent 65%), #f3ebe3; }
.project-banner .banner-content h1 { font-size: clamp(2.15rem, 4.6vw, 4.35rem); }

.project-list { gap: clamp(1.15rem, 3vw, 2.1rem) clamp(0.85rem, 2vw, 1.45rem); }
.project-list li { min-width: 0; }
.project-list a { gap: 0.65rem; padding: 0 0 1rem; border-bottom: 1px solid #b99a8a; }
.project-list img { border-radius: 0.25rem 0.25rem 0 0; object-position: center; }
.project-list h3 { font-size: clamp(1.12rem, 2vw, 1.75rem); }
.project-list a > span { align-self: start; display: grid; place-items: center; width: 1.85rem; height: 1.85rem; border: 1px solid var(--line); border-radius: 50%; }
.project-list a:hover > span { color: var(--white); background: var(--wine-deep); border-color: var(--wine-deep); }
.library-feature, .news-feature { border-radius: 0.35rem; }
.library-feature img { object-position: center; }
.library-catalog .rail-nav:last-child { grid-column: 1 / -1; }
.shelf-art { background: radial-gradient(ellipse at 42% 30%, #fff8, transparent 75%), var(--shelf-tint); }
.shelf .entry-card { box-shadow: none; }
.shelf .entry-card:hover { box-shadow: var(--shadow); }
.news-card { border-radius: 0.35rem; }
.news-card > img { border-radius: 0.3rem 0.3rem 0 0; }
.news-filters a { padding-inline: 0.35rem; }
.page-guide, .related-band { background: #efe7dc; }

.reading-body p + p, .news-story-copy p + p { margin-top: 0.85em; }
.reading-body { max-width: 49rem; }
.reading-body section + section { padding-top: 1.4rem; }
.reading-note { background: #efe4d8; }
.reader-panel, .rail-nav, .thread-card, .reply { box-shadow: none; }
.reader-panel h2, .rail-nav h2 { color: var(--wine-deep); }
.forum-topics a[aria-current], .answers-rail a[aria-current] { border-inline-start: 2px solid var(--wine); }
.forum-feed .thread-card { border-inline-start: 2px solid #a1715e; }
.forum-views { background: var(--white); padding-inline: 0.65rem; }
.guidance { background: #efe4d8; box-shadow: none; }
.message-form { border-top: 2px solid var(--terracotta); }
.message-form :is(input:not([type="hidden"]), select, textarea) { border-radius: 0.28rem; background: #fcfaf6; }
.article-actions { padding-block: 0.8rem; border-block-start: 1px solid var(--line); }

.home-paths { background: #eee5da; border-block: 1px solid var(--line); }
.home-path-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 15rem), 1fr)); gap: 1rem; }
.home-path-grid a { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: start; gap: 0.65rem; padding: 0.8rem; border: 1px solid var(--line); border-radius: var(--radius); background: var(--white); color: var(--wine-deep); text-decoration: none; }
.home-path-grid img { grid-column: 1 / -1; width: 100%; height: auto; aspect-ratio: 2; object-fit: cover; }
.home-path-grid h3 { font: 400 clamp(1.25rem, 2vw, 1.75rem)/1.17 var(--serif); }
.home-path-grid a:hover h3 { text-decoration: underline; }
.path-progress { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 0.8rem; margin-top: 1rem; border-inline-start: 3px solid var(--terracotta); }
.path-progress h2, .path-progress p { margin: 0; }
.path-progress progress { display: block; width: min(100%, 16rem); height: 0.75rem; margin-top: 0.45rem; accent-color: var(--wine); }
.study-steps li { scroll-margin-block-start: 1rem; }
.site-results { max-width: 64rem; }
.site-results .entry-card h2 a::after { position: absolute; inset: 0; content: ""; }
.site-results .topic-tabs { margin-top: 1rem; }
.project-filters { margin-top: 0; }
.recovery-layout { max-width: 38rem; }
.admin-inbox { max-width: 63rem; }
.admin-dashboard, .admin-work-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 16rem), 1fr)); gap: 1rem; margin-top: 1rem; align-items: start; }
.admin-dashboard a { display: grid; gap: .3rem; color: var(--wine-deep); text-decoration: none; border-top: 2px solid var(--terracotta); }
.admin-dashboard a:hover { background: #efe4d8; }
.admin-dashboard strong { font: 2.4rem/1 var(--serif); }
.admin-filter-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 10rem), 1fr)); align-items: end; gap: .7rem; margin-top: 1rem; }
.admin-filter-grid label, .admin-decision label { min-width: 0; color: var(--wine-deep); font-size: .9rem; }
.admin-filter-grid :is(input:not([type="hidden"]), select), .admin-decision textarea { display: block; width: 100%; min-width: 0; min-height: 2.6rem; margin-top: .3rem; padding: .4rem; border: 1px solid var(--line); border-radius: var(--radius); background: var(--white); color: var(--ink); }
.admin-decision { padding-top: .75rem; border-top: 1px solid var(--line); }
.admin-work-grid .message-form .admin-check input, .message-form .admin-check input { display: inline-block; width: auto; margin: 0 .35rem 0 0; }
.admin-work-grid .message-form { min-width: 0; }
.admin-work-grid input[type="file"] { max-width: 100%; }
.admin-audit p { flex-basis: 100%; white-space: pre-wrap; }
.admin-system { display: grid; grid-template-columns: minmax(0, .4fr) minmax(0, 1fr); gap: .7rem 1rem; overflow-wrap: anywhere; }
.admin-system dt { font-weight: 700; }
.admin-system dd { margin: 0; }
.admin-message, .admin-history { margin-top: 1rem; }
.admin-message details { padding: 0.7rem; background: var(--paper); }
.admin-message summary { cursor: pointer; font-weight: 650; }
.admin-history h2 { font-size: 1.65rem; }
.member-activity { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 20rem), 1fr)); align-items: start; gap: 1.25rem; }
.member-activity .notice { grid-column: 1 / -1; }
.member-activity li { padding-block: 0.5rem; overflow-wrap: anywhere; }
.member-activity .text-link { margin-top: 0.75rem; }
.post-report summary { color: var(--muted); cursor: pointer; font-size: 0.86rem; }
.post-report form { display: grid; gap: 0.6rem; margin-top: 0.65rem; }
.post-report textarea { display: block; width: 100%; margin-top: 0.25rem; padding: 0.45rem; border: 1px solid var(--line); border-radius: var(--radius); resize: vertical; }
.reply:target { outline: 2px solid var(--wine); }
.episode-player audio { display: block; width: 100%; margin-block: 0.8rem; }
.episode-player details { margin-top: 1rem; }
.episode-player summary { cursor: pointer; font-weight: 650; }
.episode-player details p { margin-top: 0.7rem; }
.news-story-aside nav [aria-current="location"] { font-weight: 700; text-decoration-thickness: 2px; }

.site-footer { background: var(--night); border-top: 3px solid #99614e; }
.footer-grid {
    display: grid;
    grid-template-columns: minmax(0, 1.3fr) repeat(2, minmax(0, 0.7fr)) minmax(0, 0.55fr);
    align-items: start;
    gap: 1.5rem clamp(1rem, 5vw, 4rem);
    padding-block: clamp(2.25rem, 5vw, 4rem);
}
.footer-brand .brand span { font: 1.4rem/1.1 var(--serif); }
.footer-grid nav { display: grid; justify-items: start; gap: 0.35rem; }
.footer-grid nav h2 { margin-bottom: 0.25rem; color: var(--peach); font: 650 0.92rem var(--sans); letter-spacing: 0; }
.footer-grid nav a { color: #f0e6e0; text-decoration: none; }
.footer-grid nav a:hover { text-decoration: underline; }
.footer-reference { justify-self: end; }
.footer-legal {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: .3rem clamp(.85rem, 2.6vw, 2rem);
    padding-block: .8rem 1.1rem;
    border-top: 1px solid #ffffff2e;
}
.footer-legal a { display: inline-flex; align-items: center; min-height: 2rem; color: #e4d6d3; font-size: .82rem; text-underline-offset: .24em; }
.footer-legal a[aria-current="page"], .footer-legal a:hover { color: var(--peach); }
.form-policy { color: var(--muted); font-size: .86rem; }
.form-policy a { color: var(--wine); text-underline-offset: .17em; }

@media (max-width: 62rem) {
    .masthead { min-height: auto; gap: 0.35rem 0.7rem; }
    .main-nav { justify-content: space-between; gap: 0.2rem 0.65rem; }
    .menu-ready .masthead { padding-block: .7rem; }
    .menu-ready .head-actions { gap: .5rem; }
    .menu-ready .head-actions > .button { display: none; }
    .menu-ready .menu-toggle {
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        gap: 5px;
        width: 2.75rem;
        height: 2.75rem;
        padding: .5rem;
        border: 1px solid var(--line);
        border-radius: .32rem;
        color: var(--wine-deep);
        background: #fff;
        cursor: pointer;
    }
    .menu-toggle span { display: block; width: 19px; height: 2px; background: currentColor; }
    .menu-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
    .menu-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
    .menu-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }
    .menu-ready .main-nav { display: none; }
    .menu-ready:has(.menu-toggle[aria-expanded="true"]) .main-nav {
        display: grid;
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: .2rem .7rem;
        padding-top: .7rem;
        margin-top: .35rem;
        border-top: 1px solid var(--line);
    }
    .menu-ready .main-nav a { min-height: 2.75rem; padding: .45rem .65rem; font-size: .92rem; border: 0; border-radius: .3rem; }
    .menu-ready .main-nav a:hover, .menu-ready .main-nav a[aria-current] { background: #f4e8e5; }
    .menu-ready .main-nav .mobile-community-link { display: flex; grid-column: 1 / -1; align-items: center; justify-content: space-between; margin-top: .25rem; color: var(--white); background: var(--wine-deep); }
}
@media (max-width: 49rem) {
    .opening-grid { grid-template-columns: minmax(0, 1fr); gap: 2rem; }
    .opening h1 { font-size: clamp(2.85rem, 10.5vw, 5.1rem); }
    .opening-highlights { width: min(100% - 1.2rem, 29rem); }
    .opening-art { aspect-ratio: 1.23; }
    .opening-scripture { aspect-ratio: .85; }
    .footer-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .footer-brand, .footer-reference { grid-column: 1 / -1; justify-self: start; }
}
@media (max-width: 39rem) {
    :is(.showcase-banner, .discussion-banner, .project-banner) .banner-content { grid-template-columns: minmax(0, 1fr); }
    .banner-library { background: #291922; }
    .banner-content h1 { font-size: clamp(2.3rem, 10.4vw, 4rem); }
    .project-banner .banner-content h1 { font-size: clamp(2.15rem, 9.5vw, 3.6rem); }
    .opening-art { outline-offset: 0.35rem; }
}
@media (max-width: 28rem) {
    .site-header .brand-wordmark { width: 7.25rem; }
    .head-actions .button { padding-inline: 0.6rem; }
    .main-nav a { min-height: 2.75rem; }
    .opening-links { column-gap: 0.8rem; }
    .opening-links a { font-size: 0.8rem; }
    .page-projects .project-list { grid-template-columns: minmax(0, 1fr); }
    .page-projects .project-list h3 { font-size: 1.4rem; }
}
@media (max-width: 22rem) {
    .site-header .brand-wordmark { display: none; }
    .site-header .brand-mark { display: block; }
}
@media (prefers-reduced-motion: no-preference) {
    :is(.button, .outline-link, .search-link, .circle-arrow, .project-list a > span, .news-card, .topic-item) {
        transition: color 160ms ease, background-color 160ms ease, border-color 160ms ease, box-shadow 160ms ease;
    }
}
