/* WHY SO MANY CHURCHES? (churches/churches.js, churches/data.js) */
.dn { --dn-r1: #A6773A; --dn-r2: #46596B; --dn-r3: #7E8A6A; position: fixed; inset: 0; z-index: 58; display: flex; align-items: center; justify-content: center; padding: 16px; background: rgba(20, 16, 12, 0.5); opacity: 0; transition: opacity 0.25s ease; }
body.site-dark .dn { --dn-r1: #E0B96B; --dn-r2: #9FB3C6; --dn-r3: #B3BE9A; }
.dn.open { opacity: 1; }
.dn[hidden] { display: none; }
html.dn-open, html.dn-open body { overflow: hidden; }
.dn-box { position: relative; display: flex; flex-direction: column; width: min(760px, 100%); height: min(900px, 100%); overflow: hidden; border-radius: 24px; background: var(--bg); border: 1px solid var(--rule); box-shadow: 0 40px 80px -30px rgba(20, 16, 12, 0.6); transform: translateY(20px); transition: transform 0.35s cubic-bezier(0.22, 1, 0.36, 1); }
.dn.open .dn-box { transform: none; }
@media (max-width: 700px) { .dn { padding: 0; } .dn-box { width: 100%; height: 100%; border-radius: 0; border: none; } }

.dn-head { flex: none; display: flex; align-items: center; gap: 12px; padding: 12px 16px 10px; padding-top: max(12px, env(safe-area-inset-top)); background: var(--bg-raised); }
.dn-titles { flex: 1; min-width: 0; }
.dn-kicker { font-family: var(--sans); font-size: 10.5px; font-weight: 800; letter-spacing: 0.16em; text-transform: uppercase; color: var(--gold); }
.dn-title { font-family: var(--serif); font-style: italic; font-size: 22px; line-height: 1.15; color: var(--ink); }
.dn-tabs { flex: none; display: flex; gap: 4px; padding: 0 12px 10px; background: var(--bg-raised); border-bottom: 1px solid var(--rule); }
.dn-tabs button { flex: 1; padding: 9px 6px; border: 1px solid var(--rule); border-radius: 999px; background: var(--bg); color: var(--muted); font-family: var(--sans); font-size: 13.5px; font-weight: 700; cursor: pointer; -webkit-tap-highlight-color: transparent; }
.dn-tabs button.is-on { background: var(--ink); border-color: var(--ink); color: var(--bg); }
.dn-body { flex: 1; min-height: 0; overflow-y: auto; overscroll-behavior: contain; padding: 16px 16px calc(28px + env(safe-area-inset-bottom)); -webkit-overflow-scrolling: touch; }
.dn-body > * { max-width: 640px; margin-left: auto; margin-right: auto; }
.dn-lede { margin: 0 auto 16px; font-family: var(--sans); font-size: 15px; line-height: 1.6; color: var(--muted); }
.dn-sub { margin: 22px 0 8px; font-family: var(--sans); font-size: 10.5px; font-weight: 800; letter-spacing: 0.14em; text-transform: uppercase; color: var(--muted); }
.dn-note { margin: 10px 0; font-family: var(--sans); font-size: 14px; line-height: 1.55; color: var(--muted); }
.dn-sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }

/* chips: a tradition, in its color */
.dn-chips { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 8px; }
.dn-chip { display: inline-flex; align-items: center; gap: 6px; padding: 5px 11px 5px 8px; border: 1.5px solid color-mix(in srgb, var(--c) 50%, var(--rule)); border-radius: 999px; background: color-mix(in srgb, var(--c) 10%, var(--bg-raised)); color: var(--ink); font-family: var(--sans); font-size: 13px; font-weight: 700; cursor: pointer; -webkit-tap-highlight-color: transparent; }
.dn-chip i { width: 9px; height: 9px; border-radius: 50%; background: var(--c); }
@media (hover: hover) { .dn-chip:hover { background: color-mix(in srgb, var(--c) 20%, var(--bg-raised)); } }
.dn-ref { display: inline; padding: 0; border: none; background: none; color: var(--gold); font: inherit; font-weight: 700; cursor: pointer; text-decoration: underline; text-decoration-color: color-mix(in srgb, var(--gold) 35%, transparent); text-underline-offset: 3px; }

/* the river */
.dn-river { --lanes: 128px; position: relative; padding-bottom: 8px; }
@media (min-width: 600px) { .dn-river { --lanes: 210px; } }
.dn-lanes { position: absolute; left: 0; top: 0; width: var(--lanes); overflow: visible; }
.dn-lane { fill: none; stroke-width: 4; stroke-linecap: round; opacity: 0.85; }
.dn-hit { fill: none; stroke: transparent; stroke-width: 14; cursor: pointer; pointer-events: stroke; }
.dn-dot { cursor: pointer; stroke: var(--bg); stroke-width: 2; }
/* (the rows let taps through to the branches beside them; their own text and chips still take taps) */
.dn-row { pointer-events: none; }
.dn-row > * { pointer-events: auto; }
.dn-lanes { z-index: 1; }
.dn-row { position: relative; min-height: 64px; padding: 0 0 22px calc(var(--lanes) + 12px); }
.dn-yr { font-family: var(--sans); font-size: 11px; font-weight: 800; letter-spacing: 0.1em; text-transform: uppercase; color: var(--gold); }
.dn-rt { margin: 2px 0 4px; font-family: var(--serif); font-size: 18px; line-height: 1.25; color: var(--ink); }
.dn-rx { margin: 0; font-family: var(--sans); font-size: 14px; line-height: 1.55; color: var(--muted); }
.dn-row.is-end { padding-bottom: 36px; }

/* the rings */
.dn-rings { max-width: 340px !important; margin-bottom: 8px; }
.dn-rings svg { display: block; width: 100%; height: auto; }
.dn-ring { fill: color-mix(in srgb, var(--r) 10%, var(--bg)); stroke: color-mix(in srgb, var(--r) 45%, var(--rule)); stroke-width: 1.5; cursor: pointer; transition: fill 0.2s; outline: none; }
.dn-ring.is-on { fill: color-mix(in srgb, var(--r) 30%, var(--bg)); stroke: var(--r); stroke-width: 2.5; }
.dn-ring:focus-visible { stroke-width: 4; }
.dn-ring-t { font-family: var(--sans); font-size: 12px; font-weight: 800; letter-spacing: 0.06em; text-transform: uppercase; fill: var(--muted); pointer-events: none; }
.dn-ring-t.is-on { fill: var(--ink); }
.dn-ring-mid { font-size: 34px; fill: var(--gold); pointer-events: none; }
.dn-ring-h { margin-bottom: 6px; padding: 12px 14px; border-left: 4px solid var(--r); border-radius: 0 14px 14px 0; background: color-mix(in srgb, var(--r) 9%, transparent); font-family: var(--sans); }
.dn-ring-h span { font-size: 10.5px; font-weight: 800; letter-spacing: 0.14em; text-transform: uppercase; color: var(--r); }
.dn-ring-h b { display: block; font-family: var(--serif); font-weight: 400; font-size: 20px; color: var(--ink); }
.dn-ring-h p { margin: 4px 0 0; font-size: 14px; line-height: 1.5; color: var(--muted); }
.dn-core-i { display: flex; gap: 10px; align-items: flex-start; padding: 8px 0; border-bottom: 1px solid var(--rule); font-family: var(--sans); }
.dn-core-i b { display: block; font-size: 15px; color: var(--ink); }
.dn-core-i small { font-size: 13px; color: var(--muted); }
.dn-tick { flex: none; display: grid; place-items: center; width: 22px; height: 22px; border-radius: 50%; background: var(--good-soft); color: var(--good); font-size: 13px; font-weight: 800; }

/* a question, with who stands where */
.dn-q { position: relative; display: block; width: 100%; margin: 8px 0; padding: 14px 40px 14px 14px; border: 1px solid var(--rule); border-radius: 16px; background: var(--bg-raised); color: var(--ink); text-align: left; font-family: var(--sans); cursor: pointer; -webkit-tap-highlight-color: transparent; }
@media (hover: hover) { .dn-q:hover { border-color: var(--coral); } }
.dn-q-t { display: block; margin-bottom: 8px; font-family: var(--serif); font-size: 17.5px; line-height: 1.3; }
.dn-q-g { display: flex; flex-direction: column; gap: 5px; }
.dn-q-p { display: flex; align-items: center; gap: 8px; font-size: 13px; line-height: 1.35; color: var(--muted); }
.dn-dots { flex: none; display: inline-flex; flex-wrap: wrap; gap: 3px; width: 72px; justify-content: flex-end; }
.dn-dots i { width: 10px; height: 10px; border-radius: 50%; }
.dn-q-go { position: absolute; right: 14px; top: 14px; color: var(--muted); }
.dn-out-list { display: flex; flex-direction: column; gap: 6px; }
.dn-out-b { display: grid; grid-template-columns: 1fr auto; align-items: center; padding: 12px 14px; border: 1px dashed var(--rule); border-radius: 14px; background: none; color: var(--ink); text-align: left; font-family: var(--sans); cursor: pointer; }
.dn-out-b b { font-size: 15px; }
.dn-out-b small { grid-column: 1; font-size: 12.5px; color: var(--muted); }
.dn-out-b span { grid-row: 1 / 3; grid-column: 2; color: var(--muted); }

/* compare */
.dn-picks { display: flex; align-items: center; gap: 8px; }
.dn-pick { position: relative; flex: 1; min-width: 0; display: flex; align-items: center; border: 2px solid var(--c); border-radius: 14px; background: color-mix(in srgb, var(--c) 10%, var(--bg-raised)); }
.dn-pick i { position: absolute; left: 12px; width: 10px; height: 10px; border-radius: 50%; background: var(--c); pointer-events: none; }
.dn-pick select { width: 100%; padding: 12px 10px 12px 30px; border: none; background: none; color: var(--ink); font-family: var(--sans); font-size: 14.5px; font-weight: 700; -webkit-appearance: none; appearance: none; cursor: pointer; text-overflow: ellipsis; }
.dn-swap { flex: none; width: 36px; height: 36px; border: 1px solid var(--rule); border-radius: 50%; background: var(--bg-raised); color: var(--ink); font-size: 16px; cursor: pointer; }
.dn-sum { margin: 14px auto 6px; font-family: var(--sans); font-size: 14px; line-height: 1.55; color: var(--muted); }
.dn-sum b { color: var(--ink); }
.dn-only { display: flex; align-items: center; gap: 8px; margin-bottom: 4px; font-family: var(--sans); font-size: 13.5px; color: var(--muted); cursor: pointer; }
.dn-cmp-ring { margin: 20px auto 8px; font-family: var(--sans); font-size: 13px; font-weight: 700; color: var(--ink); }
.dn-cmp-ring span { margin-right: 6px; padding: 2px 8px; border-radius: 999px; background: color-mix(in srgb, var(--r) 16%, transparent); color: var(--r); font-size: 10.5px; font-weight: 800; letter-spacing: 0.12em; text-transform: uppercase; }
.dn-row2 { display: block; width: 100%; margin: 6px 0; padding: 12px; border: 1px solid var(--rule); border-left: 4px solid var(--coral); border-radius: 6px 14px 14px 6px; background: var(--bg-raised); color: var(--ink); text-align: left; font-family: var(--sans); cursor: pointer; -webkit-tap-highlight-color: transparent; }
.dn-row2.is-same { border-left-color: var(--rule); background: transparent; opacity: 0.7; }
.dn-row2-q { display: flex; justify-content: space-between; gap: 8px; margin-bottom: 8px; font-family: var(--serif); font-size: 16px; line-height: 1.3; }
.dn-row2-q em { flex: none; align-self: flex-start; padding: 2px 8px; border-radius: 999px; background: var(--good-soft); color: var(--good); font-family: var(--sans); font-style: normal; font-size: 11px; font-weight: 800; }
.dn-row2-c { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.dn-c { padding: 8px 10px; border-top: 3px solid var(--c); border-radius: 4px 4px 10px 10px; background: color-mix(in srgb, var(--c) 8%, transparent); }
.dn-c b { display: block; font-size: 13.5px; line-height: 1.35; }
.dn-c small { display: block; margin-top: 4px; font-size: 12px; line-height: 1.4; color: var(--muted); }
.dn-row2.is-same .dn-c small { display: none; }
.dn-cards2 { display: flex; flex-direction: column; gap: 6px; margin-top: 18px !important; }
.dn-go { display: block; width: 100%; margin-top: 18px; padding: 12px 14px; border: 1.5px solid var(--c, var(--coral)); border-radius: 14px; background: color-mix(in srgb, var(--c, var(--coral)) 10%, var(--bg-raised)); color: var(--ink); text-align: left; font-family: var(--sans); font-size: 14.5px; font-weight: 700; cursor: pointer; }
.dn-cards2 .dn-go { margin-top: 0; }

/* the sheet: a tradition, a question, or a group outside the circle */
.dn-sheet { position: absolute; inset: 0; z-index: 5; display: flex; align-items: flex-end; justify-content: center; background: rgba(20, 16, 12, 0.4); opacity: 0; transition: opacity 0.2s ease; }
.dn-sheet.open { opacity: 1; }
.dn-sheet[hidden] { display: none; }
.dn-sheet-box { position: relative; width: 100%; max-width: 680px; max-height: calc(100% - 36px); overflow-y: auto; overscroll-behavior: contain; border-radius: 22px 22px 0 0; background: var(--bg); box-shadow: 0 -20px 40px -20px rgba(0, 0, 0, 0.4); transform: translateY(24px); transition: transform 0.3s cubic-bezier(0.22, 1, 0.36, 1); }
.dn-sheet.open .dn-sheet-box { transform: none; }
/* (the card's own top row: Share, the star, notes, and flag the site puts beside a Close, and Close, together at its right,
   held at the top as the card is read. They had floated loose, the star at the card's left edge. From the owner: "I noticed
   the favorite star on different apps is not aligned properly") */
.dn-sheet-head { position: sticky; top: 0; z-index: 2; display: flex; align-items: center; justify-content: flex-end; gap: 10px; padding: 10px 12px; background: var(--bg); border-radius: 22px 22px 0 0; }
.dn-sheet-in { padding: 0 0 calc(24px + env(safe-area-inset-bottom)); }
.dn-card-band { padding: 22px 18px 16px; background: linear-gradient(135deg, var(--c), color-mix(in srgb, var(--c) 70%, #000)); color: #fff; font-family: var(--sans); }
.dn-card-band span { font-size: 11px; font-weight: 800; letter-spacing: 0.12em; text-transform: uppercase; opacity: 0.85; }
.dn-card-band h2 { margin: 4px 0 2px; font-family: var(--serif); font-weight: 400; font-size: 28px; line-height: 1.1; }
.dn-card-band small { font-size: 13.5px; opacity: 0.9; }
.dn-card > :not(.dn-card-band), .dn-qd { padding-left: 18px; padding-right: 18px; }
.dn-card-s { margin: 16px 0 10px; font-family: var(--serif); font-size: 18px; line-height: 1.45; color: var(--ink); }
.dn-meta { display: flex; flex-wrap: wrap; gap: 6px 14px; font-family: var(--sans); font-size: 13px; color: var(--muted); }
.dn-meta b { color: var(--ink); }
.dn-list { margin: 0; padding-left: 20px !important; font-family: var(--sans); font-size: 14.5px; line-height: 1.55; color: var(--ink); }
.dn-list li { margin: 4px 0; }
.dn-list li::marker { color: var(--c); }
.dn-docs small { color: var(--muted); }
.dn-stand { display: flex; flex-direction: column; }
.dn-st { display: grid; grid-template-columns: 1fr; gap: 1px; padding: 9px 0; border: none; border-bottom: 1px solid var(--rule); background: none; color: var(--ink); text-align: left; font-family: var(--sans); cursor: pointer; }
.dn-st span { font-size: 12.5px; color: var(--muted); }
.dn-st b { font-size: 14.5px; }
.dn-st small { font-size: 12.5px; color: var(--muted); }
.dn-bodies { display: flex; flex-wrap: wrap; gap: 6px; }
.dn-bodies span { padding: 5px 10px; border: 1px solid var(--rule); border-radius: 999px; font-family: var(--sans); font-size: 12.5px; color: var(--ink); }
.dn-card .dn-go { width: calc(100% - 36px); margin-left: 18px; }
.dn-truth > div { display: flex; justify-content: space-between; gap: 10px; padding: 9px 0; border-bottom: 1px solid var(--rule); font-family: var(--sans); font-size: 14.5px; color: var(--ink); }
.dn-truth .dn-ref { flex: none; }

.dn-qd { padding-top: 6px; }
.dn-qd h2 { margin: 6px 0 4px; font-family: var(--serif); font-weight: 400; font-size: 26px; line-height: 1.15; color: var(--ink); }
.dn-why { margin: 0 0 8px; font-family: var(--sans); font-size: 14px; color: var(--muted); }
.dn-pos { margin: 12px 0; padding: 14px; border: 1px solid var(--rule); border-radius: 16px; background: var(--bg-raised); font-family: var(--sans); }
.dn-pos h3 { margin: 0 0 4px; font-family: var(--serif); font-weight: 400; font-size: 18.5px; line-height: 1.25; color: var(--ink); }
.dn-pos > p { margin: 0; font-size: 14.5px; line-height: 1.55; color: var(--ink); }
.dn-pos .dn-pn { margin-top: 8px; font-size: 13px; color: var(--muted); }
.dn-refs { display: flex; flex-wrap: wrap; gap: 4px 12px; margin-top: 10px; font-size: 13.5px; }
.dn-refs span { width: 100%; font-size: 10.5px; font-weight: 800; letter-spacing: 0.12em; text-transform: uppercase; color: var(--muted); }
.dn-ours { margin: 16px 0 4px; padding: 14px; border-left: 3px solid var(--coral); border-radius: 4px 14px 14px 4px; background: var(--coral-soft); font-family: var(--sans); }
.dn-ours-h { font-size: 10.5px; font-weight: 800; letter-spacing: 0.14em; text-transform: uppercase; color: var(--gold); }
.dn-ours p { margin: 4px 0 0; font-size: 14.5px; line-height: 1.6; color: var(--ink); }

.dn-src { margin-top: 28px !important; padding-top: 12px; border-top: 1px solid var(--rule); font-family: var(--sans); font-size: 13px; color: var(--muted); }
.dn-src summary { cursor: pointer; font-weight: 700; }
.dn-src p { line-height: 1.55; }
@media (prefers-reduced-motion: reduce) { .dn, .dn-box, .dn-sheet, .dn-sheet-box { transition: none; } }

/* the home page card */
.churches-banner { background: linear-gradient(135deg, #3B3148 0%, #5E4A6E 100%); color: #F7F3EA; box-shadow: 0 10px 28px rgba(50, 40, 64, 0.28); }
.churches-banner .wit-banner-eyebrow { color: #E9D29C; opacity: 1; }
@media (hover: hover) { .churches-banner:hover { box-shadow: 0 14px 32px rgba(50, 40, 64, 0.36); } }
.dn-mini { display: inline-flex; align-items: flex-end; gap: 4px; height: 22px; }
.dn-mini i { width: 6px; border-radius: 3px 3px 0 0; opacity: 0.95; box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.25); }
.dn-mini i:nth-child(odd) { height: 22px; } .dn-mini i:nth-child(even) { height: 15px; }

/* documents: the creeds open in the site's pop-up; confessions open their public copy */
.dn-docs a { color: var(--gold); font: inherit; font-weight: 700; text-decoration: underline; text-decoration-color: color-mix(in srgb, var(--gold) 35%, transparent); text-underline-offset: 3px; }
.dn-ext { font-size: 0.85em; }
.dn-jump { display: inline-block; margin: 2px 0 4px; padding: 6px 12px; border: 1px solid var(--coral); border-radius: 999px; background: var(--coral-soft); color: var(--ink); font: 700 13px var(--sans); cursor: pointer; }
.dn-ours { scroll-margin-top: 56px; }

/* pressing and sliding across the branches: the one under the finger rises */
.dn-lanes { -webkit-user-select: none; user-select: none; -webkit-touch-callout: none; }
.dn-lanes .dn-lane, .dn-lanes .dn-dot { transition: opacity 0.18s ease, stroke-width 0.18s ease, transform 0.18s ease; }
.dn-lanes.is-scrub .dn-lane, .dn-lanes.is-scrub .dn-dot { opacity: 0.22; }
.dn-lanes.is-scrub .dn-lane.is-up { opacity: 1; stroke-width: 9; filter: drop-shadow(0 4px 6px rgba(0, 0, 0, 0.35)); }
.dn-lanes.is-scrub .dn-dot.is-up { opacity: 1; transform-box: fill-box; transform-origin: center; transform: scale(1.7); }
.dn-scrub { position: absolute; left: calc(var(--lanes) + 6px); right: 0; z-index: 3; padding: 10px 12px; border: 1.5px solid var(--c); border-radius: 14px; background: var(--bg-raised); box-shadow: 0 14px 30px -14px rgba(0, 0, 0, 0.45); pointer-events: none; font-family: var(--sans); transition: top 0.12s ease-out; animation: bv-in 0.15s ease; }
.dn-scrub b { display: flex; align-items: center; gap: 7px; font-size: 15px; color: var(--ink); }
.dn-scrub b i { width: 10px; height: 10px; border-radius: 50%; background: var(--c); }
.dn-scrub small { display: block; margin: 2px 0 4px; font-size: 12px; color: var(--muted); }
.dn-scrub p { margin: 0; font-size: 13px; line-height: 1.45; color: var(--ink); display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.dn-scrub span { display: block; margin-top: 6px; font-size: 11px; font-weight: 700; color: var(--c); }
@media (prefers-reduced-motion: reduce) { .dn-scrub { transition: none; } }
/* (a question's councils: where it was decided, The Councils) */
.dn-councils { align-items: center; margin: 4px 0 10px; }
.dn-councils small { flex-basis: 100%; font: 800 10.5px var(--sans); letter-spacing: 0.13em; text-transform: uppercase; color: var(--muted); }
.dn-councils .dn-chip { --c: var(--gold); }
