.feed-scroll { height: 100dvh; overflow-y: auto; scroll-snap-type: y mandatory; scrollbar-width: none; overscroll-behavior-y: contain; outline: none; background: var(--bg); }
.feed-scroll::-webkit-scrollbar { display: none; }
.feed-slide { height: 100dvh; min-height: 100dvh; scroll-snap-align: start; scroll-snap-stop: always; box-sizing: border-box; display: flex; flex-direction: column; align-items: center; justify-content: center; padding: calc(42px + var(--safe-t)) 44px calc(var(--tabbar-h) + 44px + var(--safe-b)); text-align: center; }
.feed-slide > * { opacity: 0; transform: translateY(14px); transition: opacity .42s var(--ease), transform .42s var(--ease); }
.feed-slide.is-visible > * { opacity: 1; transform: none; }
.feed-slide.is-visible .feed-reference, .feed-slide.is-visible .feed-story { transition-delay: .1s; }
.feed-verse p { max-width: 22ch; margin: 0; color: var(--ink); font: 400 calc(var(--verse-size) * var(--text-scale))/1.32 var(--serif); text-wrap: balance; }
.feed-reference { margin-top: 26px; color: var(--muted); font: 500 11px/1 var(--sans); letter-spacing: .2em; text-transform: uppercase; }
.feed-book { color: var(--muted); font: 500 11px/1 var(--sans); letter-spacing: .28em; text-transform: uppercase; }
.feed-number { margin-top: 14px; color: var(--ink); font: 400 clamp(88px, 29vw, 154px)/.9 var(--serif); letter-spacing: -.04em; }
.feed-story { margin-top: 34px; color: var(--muted); font: italic 400 18px/1.2 var(--serif); min-height: 22px; }
/* top bar: save on the left, book picker on the right; the middle stays empty */
.feed-top, .feed-save { position: fixed; z-index: 4; top: max(10px, var(--safe-t)); height: 40px; display: flex; align-items: center; color: var(--ink); background: none; border: 0; cursor: pointer; -webkit-tap-highlight-color: transparent; filter: drop-shadow(0 1px 2px rgba(0,0,0,.35)); transition: transform 150ms var(--ease-out), opacity .2s var(--ease); }
.feed-top { right: max(10px, calc((100vw - var(--app-w)) / 2 + 10px)); gap: 4px; padding: 0 8px 0 12px; border-radius: 999px; font: 600 12px/1 var(--sans); letter-spacing: .08em; text-transform: uppercase; }
.feed-top .icon { width: 16px; height: 16px; stroke-width: 2; }
.feed-save { left: max(6px, calc((100vw - var(--app-w)) / 2 + 6px)); width: 44px; justify-content: center; padding: 0; }
.feed-save .icon { width: 25px; height: 25px; stroke-width: 1.6; }
.feed-top:active, .feed-save:active { transform: scale(.96); }
@media (hover: hover) and (pointer: fine) { .feed-top:hover { background: var(--surface-2); } }
.feed-save.feed-actions-hidden { opacity: 0; pointer-events: none; }
/* go-to sheet */
.feed-pick-seg { margin-bottom: 10px; }
.feed-pick-list { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; max-height: 58vh; overflow-y: auto; }
.feed-pick-book { display: flex; justify-content: space-between; align-items: center; min-height: 44px; padding: 0 12px; color: var(--ink); background: var(--surface-2); border: 1px solid transparent; border-radius: var(--r-sm); font: 14px var(--sans); text-align: left; cursor: pointer; }
.feed-pick-book small { color: var(--muted); font-size: 11px; }
.feed-pick-book.is-current { border-color: var(--ink); }
@media (hover: hover) and (pointer: fine) { .feed-pick-book:hover { background: var(--line); } }
/* verse ticks: one per verse in the chapter; read ones lit, the current one longer. 28px wide so a thumb can hit it */
.feed-rail { position: fixed; z-index: 3; top: 22vh; bottom: calc(22vh + var(--tabbar-h) / 2); left: max(4px, calc((100vw - var(--app-w)) / 2 + 4px)); width: 28px; display: flex; flex-direction: column; justify-content: center; gap: 3px; touch-action: none; cursor: pointer; -webkit-tap-highlight-color: transparent; }
.feed-rail i { flex: 1; min-height: 0; max-height: 26px; width: 3px; margin-left: 10px; border-radius: 2px; background: var(--line); transition: width 150ms var(--ease-out), background-color 150ms var(--ease-out); }
.feed-rail.is-dense { gap: 1px; } .feed-rail.is-dense i { width: 2px; border-radius: 0; }
.feed-rail i.is-read { background: var(--muted); }
.feed-rail i.is-current { width: 12px; background: var(--ink); }
.feed-rail.is-scrubbing i { width: 6px; } .feed-rail.is-scrubbing i.is-current { width: 16px; }
@media (hover: hover) and (pointer: fine) { .feed-rail:hover i:not(.is-current) { width: 6px; } }
.feed-verse { -webkit-touch-callout: none; }
.feed-buddy { display: block; width: 50px; height: 50px; margin: -2px; }
.feed-actions { position: fixed; z-index: 4; right: max(14px, calc((100vw - var(--app-w)) / 2 + 14px)); bottom: calc(var(--tabbar-h) + 22px + var(--safe-b)); display: flex; flex-direction: column; gap: 12px; transition: opacity .2s var(--ease), transform .2s var(--ease); }
.feed-actions-hidden { opacity: 0; pointer-events: none; transform: translateY(8px); }
.feed-actions { gap: 6px; }
/* Instagram-style rail: bare icons, no boxes or labels; aria-label carries the name */
.feed-action { width: 46px; height: 46px; padding: 0; display: grid; place-items: center; border: 0; background: none; color: var(--ink); cursor: pointer; -webkit-tap-highlight-color: transparent; transition: transform 150ms var(--ease-out); }
.feed-action:active { transform: scale(.95); }
.feed-action:focus-visible { outline: 2px solid var(--muted); outline-offset: 2px; border-radius: 50%; }
.feed-action .icon { width: 27px; height: 27px; stroke-width: 1.6; filter: drop-shadow(0 1px 2px rgba(0,0,0,.35)); }
.feed-action[data-action="like"].is-active { color: var(--like); }
.feed-pop .icon { animation: feed-pop 320ms var(--ease-out); }
@keyframes feed-pop { 0% { transform: scale(.7); } 55% { transform: scale(1.18); } 100% { transform: scale(1); } }
.feed-note-quote { margin: 0 0 18px; padding: 0 0 18px; border-bottom: 1px solid var(--line); color: var(--ink-2); font: italic 18px/1.4 var(--serif); }
.feed-note-quote cite { display: block; margin-top: 9px; color: var(--muted); font: 500 10px/1 var(--sans); letter-spacing: .12em; text-transform: uppercase; font-style: normal; }
.feed-note-input { width: 100%; min-height: 130px; resize: vertical; box-sizing: border-box; padding: 12px; border: 1px solid var(--line); border-radius: var(--r-sm); background: var(--surface-2); color: var(--ink); font: 400 16px/1.45 var(--sans); }
.feed-note-input:focus-visible { outline: 2px solid var(--muted); outline-offset: 2px; }
.feed-note-actions { display: flex; justify-content: space-between; gap: 10px; margin-top: 14px; }
.feed-note-actions button { min-height: 44px; padding: 0 15px; border: 1px solid var(--line); border-radius: var(--r-sm); background: transparent; color: var(--ink); font: 500 13px var(--sans); cursor: pointer; }
.feed-note-actions .feed-note-save { border-color: var(--ink); background: var(--ink); color: var(--on-accent); }
.feed-note-delete { color: var(--danger) !important; }
@media (min-width: 521px) { .feed-scroll { max-width: var(--app-w); margin: 0 auto; } }
@media (prefers-reduced-motion: reduce) { .feed-slide > *, .feed-actions, .feed-rail i { transition: none; } .feed-pop .icon { animation: none; } }

/* right column: like + share big (people look for buttons), the companion in the bottom-right corner */
.feed-ask-label { display: none; }
#screen-read .feed-actions { gap: 4px; bottom: calc(var(--tabbar-h) + var(--safe-b) + 6px); transition: opacity .2s var(--ease); transform: none; }
.feed-action { width: 52px; height: 52px; }
.feed-action .icon { width: 32px; height: 32px; }
.feed-action[data-action="ask"] { position: relative; width: 64px; height: 64px; margin-right: -6px; }
.feed-buddy { width: 72px; height: 72px; margin: -4px; transition: filter .3s var(--ease), opacity .3s var(--ease); }
[data-buddy="silent"] .feed-buddy { filter: grayscale(1); opacity: .45; }
/* top left: save + note */
.feed-note-top { display: flex; position: fixed; z-index: 4; top: max(10px, var(--safe-t)); left: max(48px, calc((100vw - var(--app-w)) / 2 + 48px)); width: 44px; height: 40px; align-items: center; justify-content: center; padding: 0; color: var(--ink); background: none; border: 0; cursor: pointer; filter: drop-shadow(0 1px 2px rgba(0,0,0,.35)); transition: transform 150ms var(--ease-out), opacity .2s var(--ease); }
.feed-note-top .icon { width: 23px; height: 23px; stroke-width: 1.6; }
.feed-note-top:active { transform: scale(.96); }
.feed-note-top.feed-actions-hidden { opacity: 0; pointer-events: none; }
/* the companion's speech bubble */
.feed-bubble { position: absolute; left: -2px; top: -4px; width: 22px; height: 22px; display: grid; place-items: center; color: var(--on-accent); background: var(--accent); border-radius: 50%; font: 700 13px/1 var(--sans); pointer-events: none; opacity: 0; transform: scale(.6); transition: opacity 200ms var(--ease-out), transform 200ms var(--ease-out); }
.feed-bubble.is-on { opacity: 1; transform: none; transition-duration: 280ms; }
@media (prefers-reduced-motion: reduce) { .feed-bubble { transition: opacity .2s; transform: none; } }
.feed-fly-heart { position: fixed; z-index: 30; color: var(--like); pointer-events: none; filter: drop-shadow(0 4px 12px rgba(0,0,0,.35)); }
.feed-fly-heart > div, .feed-fly-heart .icon { width: 100%; height: 100%; }
.feed-rail i.is-saved { background: var(--saved); }   /* saved verses: a quiet gold tick */
.feed-menu { display: grid; gap: 2px; }
.feed-menu button { display: flex; align-items: center; gap: 14px; min-height: 52px; padding: 0 6px; border: 0; border-top: 1px solid var(--line); background: none; color: var(--ink); font: 500 15px var(--sans); text-align: left; cursor: pointer; }
.feed-menu button:first-child { border-top: 0; }
.feed-menu .icon { width: 20px; height: 20px; color: var(--muted); }
.feed-compare section { padding: 14px 0; border-top: 1px solid var(--line); }
.feed-compare section:first-child { border-top: 0; padding-top: 4px; }
.feed-compare h3 { margin: 0 0 6px; color: var(--muted); font: 600 11px var(--sans); letter-spacing: .08em; text-transform: uppercase; }
.feed-compare p { margin: 0; font: 400 19px/1.45 var(--serif); color: var(--ink); }
.feed-compare-wait { color: var(--muted); font: 14px var(--sans); }
.feed-chapter p { margin: 0; font: 400 20px/1.6 var(--serif); color: var(--ink); text-wrap: pretty; }
.feed-chapter sup { margin: 0 3px 0 2px; color: var(--muted); font: 600 10px var(--sans); vertical-align: 6px; }
.feed-chapter span { cursor: pointer; }
.feed-chapter-next { display: flex; align-items: center; justify-content: center; gap: 6px; width: 100%; min-height: 48px; margin: 22px 0 6px; border: 1px solid var(--line); border-radius: var(--r-sm); background: none; color: var(--ink); font: 500 14px var(--sans); }
.feed-chapter-next .icon { width: 15px; height: 15px; }
/* Reading mode: Chapter (class on the Read screen). Same slides, but they flow like a page: no snapping, small verse numbers, left-aligned */
.is-chapter .feed-scroll { scroll-snap-type: none; scroll-padding-top: calc(80px + var(--safe-t)); padding: calc(64px + var(--safe-t)) 0 calc(var(--tabbar-h) + 140px + var(--safe-b)); --fade: linear-gradient(transparent calc(40px + var(--safe-t)), #000 calc(90px + var(--safe-t)), #000 calc(100% - var(--tabbar-h) - 170px - var(--safe-b)), transparent calc(100% - var(--tabbar-h) - 70px - var(--safe-b))); -webkit-mask-image: var(--fade); mask-image: var(--fade); }
.is-chapter .feed-rail { display: none; }
.is-chapter .feed-slide { height: auto; min-height: 0; scroll-snap-align: none; display: block; padding: 0 64px 0 40px; text-align: left; }
.is-chapter .feed-slide > * { transform: none; }
.is-chapter .feed-title { padding: 56px 40px 28px; text-align: center; }
.is-chapter .feed-number { font-size: 72px; margin-top: 10px; }
.is-chapter .feed-story { margin-top: 18px; }
.is-chapter .feed-verse { position: relative; padding-top: 3px; padding-bottom: 3px; }
.is-chapter .feed-verse::before { content: attr(data-v); position: absolute; left: 14px; top: 11px; color: var(--muted); font: 600 10px/1 var(--sans); font-variant-numeric: tabular-nums; }
.is-chapter .feed-verse p { max-width: 34em; font-size: calc(19px * var(--text-scale)); line-height: 1.6; text-wrap: pretty; }
.is-chapter .feed-reference { display: none; }
