/* ═════════════════════════════════════════════════════════════════════
   THE SCROLL (/scroll, /timeline) — page layer on top of brethren-v2.css
   Covenant HUD v2. Mobile first: base rules are the phone layout, the
   desktop rail layout switches on at 900px, the side column at 1100px.

   Uses the shared tokens (--v2-*) and classes (.v2-*) from
   /css/brethren-v2.css. Page-only classes are prefixed .tl- or keep the
   historic names the inline JS queries (post-entry, card, composer…).
   ═════════════════════════════════════════════════════════════════════ */

/* ── Compatibility aliases: inline styles in the page's JS templates still
      reference these legacy names. They map onto the v2 palette. ── */
:root {
    --text-muted: var(--v2-ink-3);
    --text-primary: var(--v2-ink);
    --text-secondary: var(--v2-ink-2);
    --accent-gold: var(--v2-gold);
    --danger: var(--v2-alert);
    --green: var(--v2-live);
    --bg-input: var(--v2-bg);
    --bg-card: var(--v2-bg-2);
    --border: var(--v2-edge);
    --divider: var(--v2-edge);
    --font: var(--v2-font-body);
    --t-testimony: var(--v2-gold);
    --t-revelation: var(--v2-gold-hi);
    --t-prayer: #6ea8ff;
    --t-confession: var(--v2-ink-2);
    --t-live: var(--v2-gold-hi);
}
.tl-body, .tl-body *, .tl-body *::before, .tl-body *::after { box-sizing: border-box; }
html.v2 .tl-body { margin: 0; overflow-x: hidden; }
.tl-body button, .tl-body input, .tl-body select, .tl-body textarea { font-family: inherit; }
html.v2 body.m-sheet-open,
html.v2 body.v3-mode-map,
html.v2 body.sv-lock { overflow: hidden; }

/* ── Unclipped chamfer: same look as .v2-chamfer, drawn by pseudo
      elements so dropdowns, menus and the mini-player are never clipped. ── */
.tl-cham {
    --c: var(--v2-cut);
    --fill: var(--v2-bg-2);
    --line: var(--v2-edge);
    position: relative;
    isolation: isolate;
}
.tl-cham::before,
.tl-cham::after {
    content: '';
    position: absolute;
    z-index: -1;
    pointer-events: none;
    clip-path: polygon(0 0, calc(100% - var(--c)) 0, 100% var(--c), 100% 100%, var(--c) 100%, 0 calc(100% - var(--c)));
}
.tl-cham::before { inset: 0; background: var(--line); }
.tl-cham::after { inset: 1px; background: var(--fill); }
.tl-cham.tl-tick::after {
    background:
        linear-gradient(to bottom left, transparent calc(50% - 2px), var(--v2-gold) calc(50% - 2px), var(--v2-gold) calc(50% + 1px), transparent calc(50% + 1px)) right top / calc(var(--c) - 1px) calc(var(--c) - 1px) no-repeat,
        var(--fill);
}
.tl-cham.tl-gold { --line: var(--v2-edge-gold); }

/* ── Page frame ── */
.tl-page { padding: 14px var(--v2-gutter) 40px; max-width: 1240px; margin: 0 auto; }
@media (min-width: 900px) { .tl-page { padding: 28px var(--v2-gutter) 64px; } }

/* Admin hero banner (only when configured) */
.tl-hero { display: none; margin-bottom: 18px; }
.tl-hero.has-banner { display: block; }
.tl-hero .tl-hero-content { display: none; }
.tl-hero .hero-banner-wrap { display: block; overflow: hidden; border: 1px solid var(--v2-edge); }
.tl-hero .hero-banner-wrap img, .tl-hero .hero-banner-wrap video { display: block; width: 100%; height: auto; }

/* ── Greeting ── */
.tl-greet { margin: 2px 0 16px; }
.tl-greet .v2-display { font-size: clamp(27px, 7.4vw, 46px); margin: 6px 0 0; }
.tl-greet p { margin: 8px 0 0; color: var(--v2-ink-3); font-size: 14px; }
@media (min-width: 900px) { .tl-greet { margin: 4px 0 22px; } }

/* ── The Outer Court (stories rail) ── */
.m-stories { gap: 6px; margin-bottom: 22px; padding-top: 4px; padding-bottom: 4px; }
.m-story {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    width: 76px;
    padding: 2px 0;
    border: 0;
    background: none;
    color: var(--v2-ink-2);
    font-family: var(--v2-font-body);
    font-size: 12px;
    font-weight: 700;
    line-height: 1.25;
    text-align: center;
    text-decoration: none;
    cursor: pointer;
    position: relative;
}
.m-story .m-ring {
    position: relative;
    width: 58px;
    height: 58px;
    display: grid;
    place-items: center;
    flex-shrink: 0;
    isolation: isolate;
    transition: transform 0.2s var(--v2-ease);
}
.m-story:hover .m-ring { transform: translateY(-2px); }
/* shortcut items: octagon icons */
.m-story-static .m-ring { background: var(--v2-edge-gold); clip-path: var(--v2-octagon); }
.m-story-static .m-ring::before {
    content: '';
    position: absolute;
    inset: 1.5px;
    z-index: -1;
    background: linear-gradient(160deg, var(--v2-bg-4), var(--v2-bg-2));
    clip-path: var(--v2-octagon);
}
.m-story-static .m-core { color: var(--v2-gold); font-size: 19px; }
.m-story-add .m-ring { background: linear-gradient(180deg, var(--v2-gold-hi), var(--v2-gold)); }
.m-story-add .m-ring::before { display: none; }
.m-story-add .m-core { color: var(--v2-bg); }
/* real people's stories and live gatherings: circular rings */
.m-story-dyn .m-ring { border-radius: 50%; padding: 2.5px; background: linear-gradient(160deg, var(--v2-gold-hi), var(--v2-gold-lo)); }
.m-story-dyn.live .m-ring, .m-story-dyn.red .m-ring { background: var(--v2-alert); }
.m-story-dyn .m-core {
    width: 100%;
    height: 100%;
    border-radius: 50%;
    border: 2px solid var(--v2-bg);
    display: grid;
    place-items: center;
    background: var(--v2-bg-3) center / cover no-repeat;
    color: var(--v2-gold);
    font-size: 17px;
    overflow: hidden;
    object-fit: cover;
}
.m-story-dyn video.m-core { display: block; }
.m-story-tag {
    position: absolute;
    top: 48px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 1;
    padding: 2px 6px;
    background: var(--v2-alert);
    color: #fff;
    font-family: var(--v2-font-display);
    font-size: 9.5px;
    font-weight: 800;
    letter-spacing: 0.1em;
}
.m-story .m-sl { max-width: 78px; overflow: hidden; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow-wrap: anywhere; }
@media (min-width: 900px) { .m-stories { gap: 10px; } }
.tl-stories-ph { height: 104px; margin-bottom: 22px; }

/* ── The Pulse (globe panel) ── */
.tl-pulse { --line: var(--v2-edge-gold); margin-bottom: 26px; }
.pulse-head { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 14px; padding: 16px 16px 10px; }
.pulse-title { display: flex; align-items: center; gap: 12px; min-width: 0; flex: 1 1 200px; }
.pulse-title > i {
    width: 38px;
    height: 38px;
    display: grid;
    place-items: center;
    flex-shrink: 0;
    background: var(--v2-gold);
    color: var(--v2-bg);
    font-size: 16px;
    clip-path: var(--v2-octagon);
}
.pulse-title h2 { font-family: var(--v2-font-display); font-size: 15px; font-weight: 800; letter-spacing: 0.14em; text-transform: uppercase; margin: 0; }
.pulse-title p { font-size: 13px; color: var(--v2-ink-3); margin: 2px 0 0; }
.pulse-meta { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.tl-tag-line { background: none; box-shadow: inset 0 0 0 1px var(--v2-edge); color: var(--v2-ink-2); min-height: 26px; }
.pulse-map {
    position: relative;
    height: 270px;
    margin: 0 1px;
    overflow: hidden;
    background: radial-gradient(ellipse 70% 80% at 50% 50%, rgba(22, 39, 122, 0.55), transparent 75%);
    touch-action: pan-y;
}
.pulse-map svg { position: absolute; inset: 0; width: 100%; height: 100%; display: block; }
.p-load { position: absolute; inset: 0; display: grid; place-items: center; font-family: var(--v2-font-display); font-size: 13px; letter-spacing: 0.08em; color: var(--v2-ink-3); pointer-events: none; }
#mapCanvas .graticule { fill: none; stroke: rgba(122, 142, 192, 0.12); stroke-width: 0.5; }
#mapCanvas .sanct-label { font-family: var(--v2-font-display); font-size: 10px; font-weight: 700; letter-spacing: 0.12em; }
.map-controls-row { position: absolute; right: 10px; top: 10px; z-index: 3; display: none; flex-direction: column; gap: 6px; }
.map-ctrl-btn {
    width: 44px;
    height: 44px;
    display: grid;
    place-items: center;
    border: 1px solid var(--v2-edge);
    background: rgba(10, 20, 66, 0.9);
    color: var(--v2-ink-2);
    font-size: 15px;
    cursor: pointer;
}
.map-ctrl-btn:hover, .map-ctrl-btn.active { color: var(--v2-gold); border-color: var(--v2-edge-gold); }
.tl-map-close { background: var(--v2-gold); color: var(--v2-bg); border-color: var(--v2-gold); }
.tl-map-close:hover { color: var(--v2-bg); filter: brightness(1.08); }
.pulse-legend {
    position: absolute;
    left: 12px;
    bottom: 12px;
    z-index: 3;
    display: none;
    flex-wrap: wrap;
    gap: 6px 14px;
    max-width: calc(100% - 24px);
    padding: 10px 14px;
    background: rgba(10, 20, 66, 0.92);
    border: 1px solid var(--v2-edge);
    font-size: 12px;
    font-weight: 600;
    color: var(--v2-ink-2);
}
.pulse-legend span { display: inline-flex; align-items: center; gap: 7px; }
.pulse-legend i { width: 9px; height: 9px; border-radius: 50%; display: inline-block; }
.pulse-legend .tl-map-title { width: 100%; font-family: var(--v2-font-display); font-size: 13px; font-weight: 800; color: var(--v2-ink); }
.tl-partner { position: absolute; left: 12px; bottom: 12px; z-index: 2; pointer-events: none; }
.tl-partner img { max-height: 40px; max-width: 130px; object-fit: contain; opacity: 0.85; }
.pulse-stats { margin: 0 1px 1px; padding: 1px 0 0; }
/* full-bleed strips at the foot of an unclipped chamfer keep its cut corner */
.pulse-stats, .sanct-counters {
    clip-path: polygon(0 0, 100% 0, 100% 100%, calc(var(--v2-cut) - 1px) 100%, 0 calc(100% - var(--v2-cut) + 1px));
}
.pulse-stats .v2-stat { padding: 13px 14px; }
.pulse-stats .v2-stat-num { font-size: 22px; }
@media (min-width: 600px) { .pulse-map { height: 320px; } }
@media (min-width: 900px) {
    .pulse-head { padding: 22px 26px 14px; }
    .pulse-map { height: 380px; }
    .pulse-stats .v2-stat { padding: 18px 26px; }
    .pulse-stats .v2-stat-num { font-size: 28px; }
}
/* Full-screen map ("Pulse" mode): between the phone bars, beside the rail */
body.v3-mode-map .tl-pulse { z-index: 1150; } /* lift the panel's stacking context above the feed */
body.v3-mode-map .pulse-map {
    position: fixed;
    z-index: 1150;
    inset: calc(var(--v2-top-h) + var(--v2-safe-top)) 0 calc(var(--v2-dock-h) + var(--v2-safe-bottom)) 0;
    height: auto;
    margin: 0;
    background: radial-gradient(ellipse 70% 70% at 50% 50%, rgba(22, 39, 122, 0.6), transparent 75%), var(--v2-bg);
    touch-action: none;
}
@media (min-width: 900px) { body.v3-mode-map .pulse-map { inset: 0 0 0 var(--v2-rail-w); } }
body.v3-mode-map .map-controls-row, body.v3-mode-map .pulse-legend { display: flex; }
body.v3-mode-map .tl-partner { display: none; }

/* ── Main + side layout ── */
.tl-layout { display: grid; grid-template-columns: minmax(0, 1fr); gap: 32px; align-items: start; }
.tl-side { display: none; }
@media (min-width: 1100px) {
    .tl-layout { grid-template-columns: minmax(0, 1fr) 330px; }
    .tl-side { display: flex; flex-direction: column; gap: 18px; position: sticky; top: 24px; }
}
.feed { min-width: 0; }

/* ── Composer entry ── */
.composer { margin-bottom: 20px; }
.composer-top { display: flex; align-items: center; gap: 10px; padding: 14px 14px 0; }
.composer-avatar { --s: 44px; }
.composer-input {
    flex: 1;
    min-width: 0;
    min-height: 48px;
    padding: 0 14px;
    border: 1px solid var(--v2-edge);
    background: var(--v2-bg-3);
    color: var(--v2-ink-3);
    font-family: var(--v2-font-body);
    font-size: 14px;
    text-align: left;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    cursor: pointer;
    transition: border-color 0.15s ease, color 0.15s ease;
}
.composer-input:hover { border-color: var(--v2-edge-gold); color: var(--v2-ink-2); }
.composer-plus { --n: 8px; width: 48px; min-height: 48px; padding: 0; font-size: 16px; flex-shrink: 0; }
.composer-actions { gap: 8px; padding: 12px 14px 14px; margin: 0; }
.composer-actions .v2-chip { flex-shrink: 0; }
@media (min-width: 600px) {
    .composer-top { padding: 16px 18px 0; }
    .composer-plus { display: none; }
    .composer-actions { padding: 12px 18px 16px 72px; flex-wrap: wrap; overflow: visible; }
}
@media (min-width: 900px) { .composer-actions.v2-scroller { margin: 0; } }
.composer-expand { display: none; }
.auth-banner { padding: 22px 20px; margin-bottom: 22px; }
.auth-banner h3 { font-size: 18px; margin: 0 0 6px; }
.auth-banner p { color: var(--v2-ink-2); margin: 0 0 14px; font-size: 14px; }

/* ── Composer sheet (the real composer, hoisted to <body>) ── */
.m-composer-backdrop {
    position: fixed;
    inset: 0;
    z-index: 1290;
    background: rgba(6, 12, 46, 0.82);
    -webkit-backdrop-filter: blur(6px);
    backdrop-filter: blur(6px);
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.2s ease;
}
body.m-sheet-open .m-composer-backdrop { opacity: 1; pointer-events: auto; }
body.m-sheet-open > #composer {
    --c: 0px;
    --line: var(--v2-edge-gold);
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 1300;
    margin: 0;
    max-height: 92vh;
    max-height: 92dvh;
    overflow-y: auto;
    overscroll-behavior: contain;
    animation: v2-rise 0.3s var(--v2-ease);
}
body.m-sheet-open > #composer .composer-top,
body.m-sheet-open > #composer .composer-actions { display: none !important; }
@media (min-width: 700px) {
    body.m-sheet-open > #composer {
        --c: var(--v2-cut);
        left: 50%;
        right: auto;
        top: 50%;
        bottom: auto;
        width: min(680px, calc(100vw - 48px));
        max-height: calc(100vh - 48px);
        transform: translate(-50%, -50%);
        animation: none;
    }
}
@media (min-width: 900px) { body.m-sheet-open > #composer { margin-left: calc(var(--v2-rail-w) / 2); } }
.composer-expand.active { display: block; padding: 18px 16px calc(18px + var(--v2-safe-bottom)); }
@media (min-width: 700px) { .composer-expand.active { padding: 24px 26px 24px; } }
.m-sheet-header { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; margin-bottom: 14px; }
.m-sheet-header h2 { font-family: var(--v2-font-display); font-size: 22px; font-weight: 800; letter-spacing: -0.01em; margin: 4px 0 0; }
.m-sheet-header .v2-icon-btn { margin: -6px -10px 0 0; }
/* Mode switch (Post / Story / Room / Go live): gold underline tabs */
.composer-mode-row { display: grid; grid-template-columns: repeat(4, 1fr); margin: 0 0 16px; border-bottom: 1px solid var(--v2-edge); }
.composer-mode-tab.v2-chip {
    position: relative;
    justify-content: center;
    gap: 6px;
    min-height: 46px;
    padding: 0 2px;
    border: 0;
    background: none;
    color: var(--v2-ink-3);
    font-family: var(--v2-font-display);
    font-size: 11.5px;
    letter-spacing: 0.06em;
    text-transform: uppercase;
}
.composer-mode-tab.v2-chip:hover { color: var(--v2-ink); }
.composer-mode-tab.v2-chip.active { color: var(--v2-ink); background: none; }
.composer-mode-tab.v2-chip.active i { color: var(--v2-gold); }
.composer-mode-tab.v2-chip.active::after { content: ''; position: absolute; left: 6px; right: 6px; bottom: -1px; height: 3px; background: var(--v2-gold); box-shadow: 0 0 12px rgba(245, 166, 35, 0.7); }
.composer-mode-panel { display: none; }
.composer-mode-panel.active { display: block; }
.composer-type-selector { gap: 6px; margin-bottom: 12px; }
.composer-type-pill.active { color: var(--v2-bg-2); background: var(--v2-gold); border-color: var(--v2-gold); }
.composer-type-pill.active i { color: var(--v2-bg-2); }
.composer-title-input { margin-bottom: 10px; }
.composer-textarea { min-height: 120px; line-height: 1.6; display: block; }
.composer-privacy-row { margin-top: 10px; font-size: 14px; color: var(--v2-ink-2); }
.composer-privacy-row label { display: inline-flex; align-items: center; gap: 10px; min-height: 44px; cursor: pointer; }
.composer-privacy-row input {
    -webkit-appearance: none;
    appearance: none;
    width: 20px;
    height: 20px;
    margin: 0;
    border: 1.5px solid var(--v2-ink-3);
    background: var(--v2-bg);
    cursor: pointer;
    display: grid;
    place-items: center;
}
.composer-privacy-row input:checked { border-color: var(--v2-gold); background: var(--v2-gold); box-shadow: inset 0 0 0 3px var(--v2-bg-2); }
.composer-media-preview { position: relative; margin-top: 12px; }
.composer-media-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(84px, 1fr)); gap: 6px; padding-right: 0; }
.composer-media-thumb, .composer-add-more { position: relative; aspect-ratio: 1; background: var(--v2-bg-3); overflow: hidden; }
.composer-media-thumb img, .composer-media-thumb video { width: 100%; height: 100%; object-fit: cover; display: block; }
.composer-add-more { display: grid; place-items: center; color: var(--v2-gold); border: 1px dashed var(--v2-edge-gold); cursor: pointer; font-size: 18px; }
.remove-thumb, .remove-media {
    position: absolute;
    top: 4px;
    right: 4px;
    z-index: 2;
    width: 30px;
    height: 30px;
    display: grid;
    place-items: center;
    border: 0;
    background: rgba(6, 12, 46, 0.85);
    color: var(--v2-ink);
    font-size: 12px;
    cursor: pointer;
}
.composer-media-preview .composer-media-grid { padding-right: 46px; }
.remove-media { top: 0; right: 0; width: 40px; height: 40px; background: var(--v2-bg-3); border: 1px solid var(--v2-edge); }
.composer-progress { display: none; height: 4px; margin-top: 10px; background: var(--v2-bg-4); }
.composer-progress-bar { height: 100%; width: 0; background: linear-gradient(90deg, var(--v2-gold-lo), var(--v2-gold-hi)); transition: width 0.2s ease; }
.composer-toolbar {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-top: 16px;
    padding-top: 14px;
    border-top: 1px solid var(--v2-edge);
    position: relative;
}
.composer-tools { display: flex; gap: 2px; margin-left: -10px; }
.composer-tool i { color: var(--v2-gold); }
.composer-btns { display: flex; gap: 8px; margin-left: auto; }
#composerLinkPreview { position: relative; margin-top: 12px; }
#composerLinkPreview .tl-lp-x {
    position: absolute;
    top: 6px;
    right: 6px;
    z-index: 2;
    width: 32px;
    height: 32px;
    display: grid;
    place-items: center;
    border: 0;
    background: rgba(6, 12, 46, 0.85);
    color: var(--v2-ink);
    cursor: pointer;
}
.story-hint { font-size: 12.5px; color: var(--v2-ink-3); }
.story-hint i { color: var(--v2-gold); margin-right: 6px; }

/* Verse chips the mobile sheet adds for attached [grv:…] verses */
.m-verse-chips { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 10px; }
.m-verse-chips:empty { display: none; }
.m-verse-chip { display: inline-flex; align-items: center; gap: 8px; min-height: 36px; padding: 0 4px 0 12px; background: var(--v2-bg-3); border: 1px solid var(--v2-edge-gold); font-size: 13px; font-weight: 700; color: var(--v2-ink); }
.m-verse-chip > i { color: var(--v2-gold); }
.m-vc-x { width: 32px; height: 32px; border: 0; background: none; color: var(--v2-ink-3); cursor: pointer; }

/* Inline room / broadcast forms */
.inline-form .form-group, .modal .form-group { display: flex; flex-direction: column; gap: 7px; margin-bottom: 14px; }
.form-row { display: grid; grid-template-columns: 1fr; gap: 0 12px; }
@media (min-width: 520px) { .form-row { grid-template-columns: 1fr 1fr; } }
.form-group > label, .settings-form-group > label, .toggle-row > label:first-child {
    font-family: var(--v2-font-display);
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: var(--v2-ink-2);
}
.form-group > label span { color: var(--v2-alert); }
.form-group input[type='text'], .form-group input[type='password'], .form-group input[type='number'],
.form-group input[type='datetime-local'], .form-group select, .form-group textarea {
    width: 100%;
    min-height: 46px;
    padding: 11px 14px;
    border: 1px solid var(--v2-edge);
    border-radius: 0;
    background: var(--v2-bg);
    color: var(--v2-ink);
    font-family: var(--v2-font-body);
    font-size: 16px;
    outline: none;
    -webkit-appearance: none;
    appearance: none;
}
.form-group textarea { min-height: 90px; resize: vertical; }
.form-group select {
    padding-right: 38px;
    background-image: linear-gradient(45deg, transparent 50%, var(--v2-gold) 50%), linear-gradient(135deg, var(--v2-gold) 50%, transparent 50%);
    background-position: calc(100% - 20px) 50%, calc(100% - 14px) 50%;
    background-size: 6px 6px;
    background-repeat: no-repeat;
}
.form-group select option, #newEventRecurring option { background: var(--v2-bg-2); color: var(--v2-ink); }
.form-group input:focus, .form-group select:focus, .form-group textarea:focus { border-color: var(--v2-gold); box-shadow: 0 0 0 3px rgba(245, 166, 35, 0.18); }
.form-group input::placeholder, .form-group textarea::placeholder { color: var(--v2-ink-3); }
.form-group input[type='datetime-local'] { color-scheme: dark; }
.form-section { margin-bottom: 14px; }
.form-section-title { font-family: var(--v2-font-display); font-size: 11px; font-weight: 700; letter-spacing: 0.14em; text-transform: uppercase; color: var(--v2-gold); margin-bottom: 6px; }
.form-hint { display: block; margin-top: -6px; font-size: 12px; color: var(--v2-ink-3); }
.toggle-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 52px; border-bottom: 1px solid var(--v2-edge); }
.toggle-row select { min-height: 40px; padding: 0 12px; border: 1px solid var(--v2-edge); background: var(--v2-bg); color: var(--v2-ink); font: inherit; font-size: 16px; }
.toggle-switch { position: relative; width: 46px; height: 26px; flex-shrink: 0; }
.toggle-switch input { position: absolute; inset: 0; opacity: 0; margin: 0; cursor: pointer; z-index: 1; }
.toggle-switch .slider { position: absolute; inset: 0; background: var(--v2-bg-4); border: 1px solid var(--v2-edge); transition: background 0.2s ease; }
.toggle-switch .slider::after { content: ''; position: absolute; top: 3px; left: 3px; width: 18px; height: 18px; background: var(--v2-ink-2); transition: transform 0.2s var(--v2-ease); }
.toggle-switch input:checked + .slider { background: var(--v2-gold); border-color: var(--v2-gold); }
.toggle-switch input:checked + .slider::after { transform: translateX(20px); background: var(--v2-bg-2); }
.type-cards { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.type-card {
    --c: 10px;
    --fill: var(--v2-bg-3);
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 3px;
    min-height: 68px;
    padding: 12px;
    border: 0;
    background: none;
    color: var(--v2-ink);
    text-align: left;
    font-family: var(--v2-font-body);
    cursor: pointer;
    position: relative;
    isolation: isolate;
}
.type-card::before, .type-card::after {
    content: '';
    position: absolute;
    z-index: -1;
    clip-path: polygon(0 0, calc(100% - var(--c)) 0, 100% var(--c), 100% 100%, var(--c) 100%, 0 calc(100% - var(--c)));
}
.type-card::before { inset: 0; background: var(--v2-edge); }
.type-card::after { inset: 1px; background: var(--fill); }
.type-card i { color: var(--v2-gold); font-size: 15px; }
.type-card strong { font-family: var(--v2-font-display); font-size: 14px; }
.type-card small { font-size: 12px; color: var(--v2-ink-3); line-height: 1.35; }
.type-card.selected::before { background: var(--v2-gold); }
.type-card.selected { --fill: var(--v2-gold-wash-fill); }
.room-image-upload { display: flex; flex-direction: column; gap: 8px; }
.upload-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 9px;
    min-height: 46px;
    padding: 0 16px;
    border: 1px dashed var(--v2-edge-gold);
    color: var(--v2-ink-2);
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    text-transform: none !important;
    letter-spacing: 0 !important;
}
.upload-btn i { color: var(--v2-gold); }
.upload-btn:hover { color: var(--v2-ink); background: var(--v2-bg-3); }
.room-image-preview { display: block; width: 100%; max-height: 180px; object-fit: cover; border: 1px solid var(--v2-edge); }
input[type='color'] { width: 52px; height: 40px; padding: 2px; border: 1px solid var(--v2-edge); background: var(--v2-bg); cursor: pointer; }

/* ── Story composer ── */
.story-kind-row { display: grid; grid-template-columns: repeat(4, 1fr); gap: 6px; margin-bottom: 12px; }
.story-kind { justify-content: center; padding: 0 4px; font-size: 12px; }
.story-stage { margin-bottom: 4px; }
.story-drop {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 6px;
    min-height: 190px;
    padding: 20px;
    border: 1px dashed var(--v2-edge-gold);
    background: var(--v2-bg);
    text-align: center;
    cursor: pointer;
}
.story-drop i { font-size: 28px; color: var(--v2-gold); }
.story-drop-t { font-family: var(--v2-font-display); font-weight: 700; }
.story-drop-s { font-size: 13px; color: var(--v2-ink-3); }
.story-preview, .story-audio-preview { position: relative; background: var(--v2-bg); border: 1px solid var(--v2-edge); }
.story-preview-inner img, .story-preview-inner video { display: block; width: 100%; max-height: 360px; object-fit: contain; }
.story-remove {
    position: absolute;
    top: 8px;
    right: 8px;
    z-index: 2;
    width: 36px;
    height: 36px;
    display: grid;
    place-items: center;
    border: 0;
    background: rgba(6, 12, 46, 0.85);
    color: var(--v2-ink);
    cursor: pointer;
}
.story-textcanvas { min-height: 220px; display: grid; place-items: center; padding: 24px; }
.story-textcanvas textarea {
    width: 100%;
    min-height: 140px;
    border: 0;
    background: none;
    color: #fff;
    font-family: var(--v2-font-display);
    font-size: 22px;
    font-weight: 700;
    line-height: 1.35;
    text-align: center;
    resize: none;
    outline: none;
}
.story-textcanvas textarea::placeholder { color: rgba(240, 242, 255, 0.55); }
.story-bg-row { display: flex; gap: 8px; margin-top: 10px; flex-wrap: wrap; }
.story-bg { width: 40px; height: 40px; border: 2px solid transparent; border-radius: 50%; cursor: pointer; }
.story-bg.active { border-color: var(--v2-gold); box-shadow: 0 0 0 2px var(--v2-bg-2); }
.story-audio-panel { display: flex; flex-direction: column; align-items: center; gap: 10px; padding: 24px; background: var(--v2-bg); border: 1px dashed var(--v2-edge-gold); }
.story-rec {
    width: 84px;
    height: 84px;
    display: grid;
    place-items: center;
    align-content: center;
    gap: 4px;
    border: 0;
    border-radius: 50%;
    background: linear-gradient(180deg, var(--v2-gold-hi), var(--v2-gold));
    color: var(--v2-bg);
    font-family: var(--v2-font-display);
    font-size: 12px;
    font-weight: 800;
    cursor: pointer;
}
.story-rec i { font-size: 22px; }
.story-rec.recording { background: var(--v2-alert); color: #fff; }
.story-audio-or { font-size: 12px; color: var(--v2-ink-3); text-transform: uppercase; letter-spacing: 0.12em; }
.story-audio-up { min-height: 44px; padding: 0 16px; border: 1px solid var(--v2-edge); background: var(--v2-bg-3); color: var(--v2-ink); font: inherit; font-weight: 600; cursor: pointer; }
.story-audio-up i { color: var(--v2-gold); margin-right: 6px; }
.story-audio-preview { display: flex; align-items: center; gap: 12px; padding: 14px 52px 14px 14px; }
.story-audio-art { width: 48px; height: 48px; display: grid; place-items: center; flex-shrink: 0; background: var(--v2-bg-4); color: var(--v2-gold); clip-path: var(--v2-octagon); }
.story-audio-preview audio { flex: 1; min-width: 0; }

/* ── Verse of the day ("decree") ── */
.tl-verse { --fill: linear-gradient(160deg, var(--v2-bg-4) 0%, var(--v2-bg-2) 70%); --line: var(--v2-edge-gold); padding: 22px 20px 20px; margin: 0 0 24px; }
.tl-verse-mark { display: block; height: 24px; margin-top: 12px; font-family: var(--v2-font-display); font-size: 60px; font-weight: 800; line-height: 0.6; color: var(--v2-gold); }
.tl-verse .votd-text { margin: 0; font-size: 17px; font-weight: 500; font-style: italic; line-height: 1.55; color: var(--v2-ink); }
.tl-verse .votd-ref { display: block; margin-top: 14px; font-style: normal; }
.tl-verse-foot { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 16px; }
@media (min-width: 900px) { .tl-verse { padding: 28px 32px 24px; } .tl-verse .votd-text { font-size: 20px; } }

/* ── Now live (featured gathering) ── */
.sanct-nowlive, .sanct-rivers { margin-bottom: 24px; }
.tl-live-card { --line: var(--v2-edge-gold); padding: 18px 16px; }
.tl-live-card .tl-live-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 10px; }
.tl-live-card h3 { font-family: var(--v2-font-display); font-size: 19px; font-weight: 700; line-height: 1.28; margin: 0 0 6px; overflow-wrap: anywhere; }
.tl-live-card .tl-live-meta { display: flex; flex-wrap: wrap; gap: 4px 14px; font-size: 13px; color: var(--v2-ink-3); }
.tl-live-card .tl-live-meta i { color: var(--v2-gold); margin-right: 6px; }
.tl-live-card .tl-live-meta b { color: var(--v2-ink); }
.tl-live-card .v2-btn { margin-top: 14px; }
.sanct-nl-wave { display: flex; align-items: flex-end; gap: 3px; height: 28px; margin-top: 12px; }
.sanct-nl-wave span { width: 4px; height: var(--swh, 14px); background: var(--v2-gold); opacity: 0.75; animation: tl-wave 1.2s ease-in-out infinite alternate; }
@keyframes tl-wave { from { transform: scaleY(0.35); } to { transform: scaleY(1); } }
@media (min-width: 900px) { .tl-live-card { padding: 22px 26px; } .tl-live-card .v2-btn { width: auto; } }

/* ── Rivers of prayer (activity ticker + counters) ── */
.sanct-riverbox { overflow: hidden; }
.sanct-river { display: flex; align-items: center; gap: 10px; padding: 12px 16px; background: var(--v2-bg-3); overflow: hidden; white-space: nowrap; font-size: 13px; color: var(--v2-ink-2); margin: 1px 1px 0; }
.sanct-river:has(.sanct-river-track:empty) { display: none; }
.sanct-river-track { display: inline-flex; gap: 28px; animation: tl-tick 40s linear infinite; }
.sanct-river:hover .sanct-river-track { animation-play-state: paused; }
@keyframes tl-tick { to { transform: translateX(-50%); } }
.sanct-drop { display: inline-flex; align-items: center; gap: 8px; }
.sanct-drop i { font-size: 12px; }
.sanct-drop b { color: var(--v2-ink); }
.sanct-where { color: var(--v2-ink-3); }
.sanct-counters { display: grid; grid-template-columns: repeat(auto-fit, minmax(90px, 1fr)); gap: 1px; padding: 1px; background: var(--v2-edge); margin: 0 1px 1px; }
.sanct-counter { background: var(--v2-bg-2); padding: 12px 14px; }
.sanct-counter .n { font-family: var(--v2-font-display); font-size: 22px; font-weight: 800; line-height: 1; font-variant-numeric: tabular-nums; color: var(--v2-ink); }
.sanct-counter:first-child .n { color: var(--v2-gold); }
.sanct-counter .l { margin-top: 6px; font-family: var(--v2-font-display); font-size: 10px; font-weight: 700; letter-spacing: 0.12em; text-transform: uppercase; color: var(--v2-ink-3); }
.tl-rivers-head { display: flex; align-items: center; gap: 10px; padding: 14px 16px 10px; }

/* ── Feed filters (sticky under the phone top bar) ── */
.filter-section {
    position: sticky;
    top: calc(var(--v2-top-h) + var(--v2-safe-top));
    z-index: 40;
    margin: 0 calc(var(--v2-gutter) * -1) 18px;
    padding: 8px 0;
    background: rgba(6, 12, 46, 0.94);
    -webkit-backdrop-filter: blur(12px);
    backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--v2-edge);
}
.filter-tabs.v2-scroller { gap: 6px; margin: 0; padding: 0 var(--v2-gutter); scroll-padding: 0 var(--v2-gutter); }
.filter-tab i { font-size: 11px; }
@media (min-width: 900px) {
    .filter-section { top: 0; margin: 0 0 22px; padding: 10px 0; }
    .filter-tabs.v2-scroller { margin: 0; padding: 0; }
}

/* ── Timeline rail grouped by day ── */
.chronicle-container { position: relative; }
#postsContainer { position: relative; padding-left: 24px; }
#postsContainer::before {
    content: '';
    position: absolute;
    left: 6px;
    top: 8px;
    bottom: 0;
    width: 2px;
    background: linear-gradient(180deg, var(--v2-gold) 0%, var(--v2-gold) 55%, rgba(245, 166, 35, 0.15) 100%);
}
#postsContainer > .loading, #postsContainer > .empty-state { margin-left: -24px; }
.tl-day { position: relative; display: flex; align-items: baseline; gap: 10px; margin: 0 0 14px; padding-left: 0; }
.tl-day::before {
    content: '';
    position: absolute;
    left: -24px;
    top: 6px;
    width: 14px;
    height: 14px;
    border-radius: 50%;
    background: var(--v2-gold);
    box-shadow: 0 0 0 4px var(--v2-bg), 0 0 18px var(--v2-gold);
}
.tl-day h3 { font-family: var(--v2-font-display); font-size: 20px; font-weight: 800; color: var(--v2-gold); margin: 0; }
.tl-day span { font-size: 11px; font-weight: 700; letter-spacing: 0.12em; text-transform: uppercase; color: var(--v2-ink-3); }
.post-entry ~ .tl-day { margin-top: 26px; }
@media (min-width: 900px) {
    #postsContainer { padding-left: 40px; }
    #postsContainer::before { left: 7px; }
    #postsContainer > .loading, #postsContainer > .empty-state { margin-left: -40px; }
    .tl-day::before { left: -40px; width: 16px; height: 16px; top: 5px; box-shadow: 0 0 0 5px var(--v2-bg), 0 0 18px var(--v2-gold); }
}
.post-entry { margin-bottom: 16px; }
.post-entry.m-story-flash > .card { --line: var(--v2-gold); }
@media (prefers-reduced-motion: no-preference) {
    .post-entry:not(.revealed) { opacity: 0.001; }
    .post-entry.revealed { animation: v2-rise 0.4s var(--v2-ease); }
}
#tlLoadMoreSentinel { min-height: 1px; color: var(--v2-ink-3); font-size: 13px; }

/* ── Post card ── */
.post-entry > .card { --pp: 16px; padding: var(--pp) var(--pp) 0; margin: 0; }
.post-entry > .card:has(.post-dropdown.show),
.post-entry > .card:has(.comment-dropdown.show),
.post-entry > .card:has(.mention-dropdown.active),
.post-entry > .card:has(.emoji-picker),
.composer:has(.emoji-picker) { z-index: 5; }
.post-entry > .card.post-testimony, .post-entry > .card.post-revelation, .post-entry > .card.pc-live { --line: var(--v2-edge); }
.post-entry > .card.post-prayer { --line: var(--v2-edge-gold); }
@media (min-width: 900px) { .post-entry > .card { --pp: 24px; } }
.post-header { display: flex; align-items: center; gap: 12px; margin-bottom: 12px; min-width: 0; }
.post-avatar { --s: 44px; display: block; }
.post-avatar > img, .post-avatar > .v2-av-initials { border-color: var(--v2-bg-2); }
.pc-who { flex: 1; min-width: 0; }
.pc-nm { font-size: 13px; color: var(--v2-ink-3); line-height: 1.35; overflow-wrap: anywhere; }
.pc-nm .post-author { font-family: var(--v2-font-display); font-size: 14px; font-weight: 700; color: var(--v2-ink); text-decoration: none; }
.pc-nm a.post-author:hover { color: var(--v2-gold); }
.pc-verb { color: var(--v2-ink-3); font-weight: 400; }
.pc-flag { font-size: 13px; }
.post-meta { font-size: 12px; color: var(--v2-ink-3); margin-top: 2px; }
.post-meta i { font-size: 10px; margin-left: 2px; }
.edited-tag { cursor: help; text-decoration: underline dotted; }
.post-type-badge {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    flex-shrink: 0;
    font-family: var(--v2-font-display);
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: var(--v2-gold);
    white-space: nowrap;
}
.post-type-badge i { font-size: 12px; }
.post-type-badge.prayer { color: #9cc3ff; }
.post-type-badge.confession, .post-type-badge.neutral { color: var(--v2-ink-3); }
.post-menu-wrap { position: relative; flex-shrink: 0; margin-right: -10px; }
.post-menu { width: 44px; height: 44px; display: grid; place-items: center; border: 0; background: none; color: var(--v2-ink-3); cursor: pointer; flex-shrink: 0; }
.post-menu:hover { color: var(--v2-gold); }
div.post-menu { display: none; }
.post-dropdown, .comment-dropdown {
    position: absolute;
    right: 0;
    top: 100%;
    z-index: 30;
    min-width: 180px;
    display: none;
    flex-direction: column;
    padding: 4px 0;
    background: var(--v2-bg-2);
    border: 1px solid var(--v2-edge-gold);
    box-shadow: 0 18px 50px rgba(2, 6, 30, 0.7);
}
.post-dropdown.show, .comment-dropdown.show { display: flex; }
.post-dropdown-item, .comment-dropdown-item {
    display: flex;
    align-items: center;
    gap: 12px;
    min-height: 46px;
    padding: 0 16px;
    font-size: 14px;
    font-weight: 600;
    color: var(--v2-ink-2);
    cursor: pointer;
}
.post-dropdown-item i, .comment-dropdown-item i { width: 16px; color: var(--v2-gold); }
.post-dropdown-item:hover, .comment-dropdown-item:hover { background: var(--v2-bg-3); color: var(--v2-ink); }
.post-dropdown-item.danger, .post-dropdown-item.danger i, .comment-dropdown-item.danger, .comment-dropdown-item.danger i { color: var(--v2-alert); }
.post-title { font-family: var(--v2-font-display); font-size: 19px; font-weight: 700; line-height: 1.28; margin: 0 0 8px; color: var(--v2-ink); overflow-wrap: anywhere; }
.post-title a { color: inherit; text-decoration: none; }
.post-title a:hover { text-decoration: underline; text-decoration-color: var(--v2-gold); }
.post-body { color: var(--v2-ink-2); font-size: 15px; line-height: 1.7; overflow-wrap: anywhere; white-space: pre-wrap; margin-bottom: 4px; }
.post-body a.post-link, .post-body .hashtag-link, .post-body .mention-link, .comment-text a, .lightbox-caption a { color: var(--v2-gold); text-decoration: none; font-weight: 600; }
.post-body a:hover, .comment-text a:hover { text-decoration: underline; }
.see-more-link { color: var(--v2-gold); font-weight: 700; cursor: pointer; white-space: nowrap; }
.post-scripture .post-body { white-space: normal; }
.post-confession .post-body, .post-prayer .post-body { font-size: 15.5px; }
@media (min-width: 900px) { .post-title { font-size: 21px; } }
/* edit mode */
.post-editing { white-space: normal; }
.tl-edit-ta { width: 100%; min-height: 110px; }
.tl-edit-btns { display: flex; justify-content: flex-end; gap: 8px; margin-top: 10px; }
/* type extras */
.pc-praying { display: flex; align-items: center; gap: 8px; margin: 10px 0 2px; font-size: 13px; color: var(--v2-ink-3); }
.pc-praying b { color: var(--v2-ink); }
.pc-pd { width: 8px; height: 8px; border-radius: 50%; background: var(--v2-live); animation: v2-pulse 2s infinite; flex-shrink: 0; }
.pc-confnote { display: flex; align-items: center; gap: 8px; margin: 10px 0 2px; font-size: 12.5px; color: var(--v2-ink-3); }
.pc-confnote i { color: var(--v2-gold); }
.pc-ref { color: var(--v2-gold); font-weight: 700; text-decoration: none; }
.pc-openref { display: inline-flex; align-items: center; gap: 8px; min-height: 40px; margin-top: 8px; font-size: 13px; font-weight: 700; color: var(--v2-gold); text-decoration: none; }
/* media */
.post-image { display: block; width: calc(100% + var(--pp) * 2); max-width: none; margin: 14px calc(var(--pp) * -1) 0; max-height: 70vh; object-fit: cover; background: var(--v2-bg-3); cursor: zoom-in; }
.post-image-gallery { display: grid; gap: 3px; margin: 14px calc(var(--pp) * -1) 0; }
.post-image-gallery.gallery-2 { grid-template-columns: 1fr 1fr; aspect-ratio: 16 / 9; }
.post-image-gallery.gallery-3 { grid-template-columns: 2fr 1fr; grid-template-rows: 1fr 1fr; aspect-ratio: 16 / 10; }
.post-image-gallery.gallery-3 .gallery-item:first-child { grid-row: 1 / 3; }
.post-image-gallery.gallery-4 { grid-template-columns: 1fr 1fr; grid-template-rows: 1fr 1fr; aspect-ratio: 1; }
.post-image-gallery.gallery-5 { grid-template-columns: repeat(6, 1fr); grid-template-rows: 1fr 1fr; aspect-ratio: 16 / 10; }
.post-image-gallery.gallery-5 .gallery-item:nth-child(-n + 2) { grid-column: span 3; }
.post-image-gallery.gallery-5 .gallery-item:nth-child(n + 3) { grid-column: span 2; }
.gallery-item { position: relative; overflow: hidden; background: var(--v2-bg-3); cursor: zoom-in; min-height: 0; }
.gallery-item img { width: 100%; height: 100%; object-fit: cover; display: block; }
.gallery-more-overlay { position: absolute; inset: 0; display: grid; place-items: center; background: rgba(6, 12, 46, 0.62); font-family: var(--v2-font-display); font-size: 22px; font-weight: 800; color: var(--v2-ink); }
.video-embed-container { position: relative; margin: 14px calc(var(--pp, 16px) * -1) 0 !important; background: var(--v2-bg); overflow: hidden; }
.video-embed-container > img { display: block; width: 100%; aspect-ratio: 16 / 9; object-fit: cover; }
.video-embed-container video, .video-embed-container iframe { display: block; width: 100%; aspect-ratio: 16 / 9; border: 0; background: var(--v2-bg); object-fit: contain; }
.video-embed-play-overlay { position: absolute; inset: 0; display: grid; place-items: center; cursor: pointer; background: linear-gradient(0deg, rgba(6, 12, 46, 0.55), transparent 55%); }
.play-btn, .media-play-btn { width: 56px; height: 56px; display: grid; place-items: center; background: rgba(245, 166, 35, 0.94); color: var(--v2-bg); font-size: 18px; clip-path: var(--v2-octagon); }
.video-embed-info { padding: 10px 14px 12px; background: var(--v2-bg-3); }
.video-title { font-family: var(--v2-font-display); font-size: 14px; font-weight: 700; color: var(--v2-ink); }
.video-channel { font-size: 12px; color: var(--v2-ink-3); margin-top: 2px; }
.video-channel i { color: var(--v2-alert) !important; }
/* shared media (Media Center) */
.tl-media-link { display: block; text-decoration: none; color: inherit; }
.media-embed-card { margin: 14px calc(var(--pp) * -1) 0; background: var(--v2-bg-3); }
.media-thumbnail { position: relative; aspect-ratio: 16 / 9; overflow: hidden; background: var(--v2-bg); }
.media-thumbnail img { width: 100%; height: 100%; object-fit: cover; display: block; }
.media-thumbnail::after { content: ''; position: absolute; inset: 0; background: linear-gradient(0deg, rgba(6, 12, 46, 0.65), transparent 50%); pointer-events: none; }
.media-badge { position: absolute; left: 12px; top: 12px; z-index: 1; display: inline-flex; align-items: center; gap: 6px; padding: 4px 9px; background: var(--v2-gold); color: var(--v2-bg); font-family: var(--v2-font-display); font-size: 10px; font-weight: 800; letter-spacing: 0.1em; text-transform: uppercase; }
.media-duration { position: absolute; right: 12px; bottom: 12px; z-index: 1; padding: 4px 9px; background: var(--v2-bg-4); font-family: var(--v2-font-display); font-size: 10px; font-weight: 800; letter-spacing: 0.08em; }
.media-play-overlay { position: absolute; inset: 0; z-index: 1; display: grid; place-items: center; }
.media-info { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 12px 16px; }
.media-details { min-width: 0; }
.media-title { font-family: var(--v2-font-display); font-size: 15px; font-weight: 700; margin: 0; color: var(--v2-ink); }
.media-meta { font-size: 12px; color: var(--v2-ink-3); margin-top: 3px; }
.media-meta i { color: var(--v2-gold); margin-right: 4px; }
.media-action-btn { flex-shrink: 0; display: inline-flex; align-items: center; gap: 8px; min-height: 40px; padding: 0 14px; border: 0; background: linear-gradient(180deg, var(--v2-gold-hi), var(--v2-gold)); color: var(--v2-bg-2); font-family: var(--v2-font-display); font-size: 12px; font-weight: 700; cursor: pointer; clip-path: polygon(0 0, 100% 0, 100% calc(100% - 8px), calc(100% - 8px) 100%, 0 100%); }
@media (max-width: 420px) { .media-action-btn { display: none; } }
/* link previews */
.link-preview {
    display: flex;
    flex-direction: column;
    margin: 14px 0 0 !important;
    background: var(--v2-bg-3);
    border: 1px solid var(--v2-edge);
    text-decoration: none;
    color: inherit;
    overflow: hidden;
}
.link-preview > img { display: block; width: 100%; max-height: 220px; object-fit: cover; }
.link-preview-body { padding: 12px 14px; min-width: 0; }
.link-preview-domain { display: flex; align-items: center; gap: 6px; font-size: 11.5px; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; color: var(--v2-ink-3); }
.link-preview-domain img { width: 14px; height: 14px; }
.link-preview-title { margin-top: 4px; font-family: var(--v2-font-display); font-size: 15px; font-weight: 700; color: var(--v2-ink); overflow-wrap: anywhere; }
.link-preview-desc { margin-top: 4px; font-size: 13px; color: var(--v2-ink-3); line-height: 1.5; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.link-preview:hover { border-color: var(--v2-edge-gold); }
.link-preview-placeholder { display: flex; align-items: center; gap: 8px; margin: 14px 0 0; padding: 12px 14px; background: var(--v2-bg-3); border: 1px solid var(--v2-edge); font-size: 13px; color: var(--v2-ink-3); }
/* inline room link card */
.room-inline { display: flex; align-items: center; gap: 12px; margin-top: 14px; padding: 12px; background: var(--v2-bg-3); border: 1px solid var(--v2-edge); cursor: pointer; }
.ri-icon { position: relative; width: 44px; height: 44px; display: grid; place-items: center; flex-shrink: 0; background: var(--v2-bg-4) !important; color: var(--v2-gold); clip-path: var(--v2-octagon); }
.ri-pulse { display: none; }
.ri-info { flex: 1; min-width: 0; }
.ri-title { font-family: var(--v2-font-display); font-size: 14px; font-weight: 700; }
.ri-sub { display: flex; align-items: center; gap: 6px; font-size: 12px; color: var(--v2-ink-3); }
.ri-sub .dot { width: 7px; height: 7px; border-radius: 50%; }
.ri-btn { min-height: 40px; padding: 0 16px; border: 0; background: linear-gradient(180deg, var(--v2-gold-hi), var(--v2-gold)); color: var(--v2-bg-2); font-family: var(--v2-font-display); font-weight: 700; cursor: pointer; }

/* ── Entity cards: rooms, broadcasts, events ── */
.ec-livebadge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    flex-shrink: 0;
    padding: 4px 9px;
    background: var(--v2-alert);
    color: #fff;
    font-family: var(--v2-font-display);
    font-size: 10px;
    font-weight: 800;
    letter-spacing: 0.1em;
}
.ec-bd { width: 6px; height: 6px; border-radius: 50%; background: #fff; animation: v2-pulse 2s infinite; }
.ec-statebadge { flex-shrink: 0; padding: 4px 9px; background: var(--v2-bg-4); color: var(--v2-ink); font-family: var(--v2-font-display); font-size: 10px; font-weight: 800; letter-spacing: 0.1em; text-transform: uppercase; }
.ec-statebadge.muted { background: none; box-shadow: inset 0 0 0 1px var(--v2-edge); color: var(--v2-ink-3); }
.ec-statebadge.event { background: var(--v2-gold); color: var(--v2-bg); }
.ec-roomvis {
    display: flex;
    align-items: center;
    gap: 14px;
    margin-top: 4px;
    padding: 14px;
    background: var(--v2-bg-3);
    border-left: 3px solid var(--v2-edge);
    cursor: pointer;
}
.ec-roomvis.live, .ec-roomvis.bcast { border-left-color: var(--v2-alert); }
.ec-roomvis.scheduled { border-left-color: var(--v2-gold); cursor: default; }
.ec-rt { min-width: 0; font-size: 13px; color: var(--v2-ink-3); line-height: 1.5; overflow-wrap: anywhere; }
.ec-rt b { font-family: var(--v2-font-display); font-size: 15px; font-weight: 700; color: var(--v2-ink); }
.ec-when { color: var(--v2-gold); font-weight: 700; }
.ec-wave { display: flex; align-items: center; gap: 3px; height: 34px; flex-shrink: 0; }
.ec-wave span { width: 4px; height: 100%; background: var(--v2-alert); animation: tl-wave 0.9s ease-in-out infinite alternate; }
.ec-wave span:nth-child(2) { animation-delay: 0.15s; height: 70%; }
.ec-wave span:nth-child(3) { animation-delay: 0.3s; height: 90%; }
.ec-wave span:nth-child(4) { animation-delay: 0.45s; height: 60%; }
.ec-wave span:nth-child(5) { animation-delay: 0.6s; height: 80%; }
.ec-icontile { width: 44px; height: 44px; display: grid; place-items: center; flex-shrink: 0; background: var(--v2-bg-4); color: var(--v2-gold); clip-path: var(--v2-octagon); }
.ec-cf { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 14px; margin-top: 12px; }
.ec-joinbtn, .ec-replaybtn, .ec-remindbtn, .ec-actbtn, .ec-rsvp {
    --n: 8px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    min-height: 44px;
    padding: 0 16px;
    border: 0;
    font-family: var(--v2-font-display);
    font-size: 12.5px;
    font-weight: 700;
    cursor: pointer;
    clip-path: polygon(0 0, 100% 0, 100% calc(100% - var(--n)), calc(100% - var(--n)) 100%, 0 100%);
}
.ec-joinbtn, .ec-rsvp { background: linear-gradient(180deg, var(--v2-gold-hi), var(--v2-gold)); color: var(--v2-bg-2); }
.ec-joinbtn.bcast { background: var(--v2-alert); color: #fff; }
.ec-replaybtn, .ec-remindbtn, .ec-actbtn { background: var(--v2-bg-3); color: var(--v2-ink); box-shadow: inset 0 0 0 1px var(--v2-edge-gold); }
.ec-replaybtn i, .ec-remindbtn i, .ec-actbtn i { color: var(--v2-gold); }
.ec-remindbtn.subscribed, .ec-rsvp.subscribed { background: var(--v2-bg-4); color: var(--v2-gold); box-shadow: inset 0 0 0 1px var(--v2-gold); }
.ec-spread { display: inline-flex; align-items: center; gap: 7px; font-size: 13px; color: var(--v2-ink-3); }
.ec-livedot { width: 8px; height: 8px; border-radius: 50%; background: var(--v2-alert); }
.ec-livedot.green { background: var(--v2-live); }
.ec-eventbody { --c: 12px; display: flex; gap: 14px; margin-top: 4px; padding: 14px; background: var(--v2-bg-3); cursor: pointer; clip-path: polygon(0 0, calc(100% - var(--c)) 0, 100% var(--c), 100% 100%, 0 100%); }
.ec-datechip { width: 62px; flex-shrink: 0; align-self: flex-start; padding: 8px 0 10px; text-align: center; background: linear-gradient(180deg, var(--v2-gold-hi), var(--v2-gold)); color: var(--v2-bg); font-family: var(--v2-font-display); font-weight: 800; clip-path: polygon(0 0, calc(100% - 10px) 0, 100% 10px, 100% 100%, 0 100%); }
.ec-mo, .ec-dow { font-size: 10.5px; letter-spacing: 0.14em; }
.ec-dy { font-size: 28px; line-height: 1.05; }
.ec-eventinfo { min-width: 0; }
.ec-et { font-family: var(--v2-font-display); font-size: 16px; font-weight: 700; line-height: 1.3; overflow-wrap: anywhere; }
.ec-em { display: flex; flex-direction: column; gap: 2px; margin-top: 6px; font-size: 13px; color: var(--v2-ink-3); }
.ec-em i { width: 16px; color: var(--v2-gold); }
/* system posts (photo updates, new connections) */
.post-entry > .card.pc-system { padding: 0; }
.post-entry > .card.pc-system .post-header,
.post-entry > .card.pc-system .post-title,
.post-entry > .card.pc-system .post-body,
.post-entry > .card.pc-system .post-image,
.post-entry > .card.pc-system .post-image-gallery,
.post-entry > .card.pc-system .post-reactions-bar,
.post-entry > .card.pc-system .post-action-bar,
.post-entry > .card.pc-system .comments-section { display: none !important; }
.ec-sysrow { display: flex; align-items: center; gap: 14px; padding: 14px 16px; }
.ec-sysicon { width: 40px; height: 40px; display: grid; place-items: center; flex-shrink: 0; background: var(--v2-bg-4); color: var(--v2-gold); clip-path: var(--v2-octagon); }
.ec-systext { flex: 1; min-width: 0; font-size: 13.5px; color: var(--v2-ink-2); line-height: 1.45; }
.ec-sysname { font-family: var(--v2-font-display); font-weight: 700; color: var(--v2-ink); text-decoration: none; }
a.ec-sysname:hover { color: var(--v2-gold); }
.ec-tm { font-size: 12px; color: var(--v2-ink-3); margin-top: 2px; }
.ec-sysavatarprev { width: 48px; height: 48px; flex-shrink: 0; border-radius: 50%; background: var(--v2-bg-3) center / cover; border: 2px solid var(--v2-gold); }
.ec-sysavatarprev.cover { width: 72px; height: 44px; border-radius: 0; border-width: 1px; border-color: var(--v2-edge-gold); }
.ec-connectfaces { display: flex; align-items: center; flex-shrink: 0; }
.ec-cface { width: 36px; height: 36px; border-radius: 50%; overflow: hidden; display: grid; place-items: center; background: var(--v2-bg-4); border: 2px solid var(--v2-bg-2); color: var(--v2-gold-hi); font-family: var(--v2-font-display); font-size: 12px; font-weight: 800; }
.ec-cface img { width: 100%; height: 100%; object-fit: cover; }
.ec-clink { width: 22px; height: 22px; margin: 0 -4px; z-index: 1; display: grid; place-items: center; background: var(--v2-gold); color: var(--v2-bg); font-size: 10px; clip-path: var(--v2-octagon); }
@media (max-width: 420px) { .ec-connectfaces { display: none; } }

/* ── Reactions ── */
.post-stat { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 4px 12px; margin-top: 14px; font-size: 13px; color: var(--v2-ink-3); }
.post-stat i { color: var(--v2-gold); margin-right: 6px; }
.post-stat strong { color: var(--v2-ink); }
.post-action-bar { margin: 12px calc(var(--pp) * -1) 0; padding: 0 6px; }
.post-action-bar .v2-reacts { gap: 2px; }
.post-action { min-width: 44px; justify-content: center; }
.post-action.liked { color: var(--v2-gold); }
.post-action.liked i { animation: v2-pop 0.35s var(--v2-ease); }
.post-action[aria-expanded='true'] { color: var(--v2-ink); }
@media (min-width: 900px) { .post-action-bar { padding: 0 14px; } }

/* ── Comments ── */
.comments-section { display: none; margin: 0 calc(var(--pp) * -1); padding: 16px var(--pp) 6px; border-top: 1px solid var(--v2-edge); background: rgba(6, 12, 46, 0.35); }
.comments-section.open { display: block; }
.comment { display: flex; gap: 10px; margin-bottom: 12px; }
.comment-replies { margin: -2px 0 12px 44px; }
.comment-avatar, .mention-item-avatar {
    width: 34px;
    height: 34px;
    flex-shrink: 0;
    display: grid;
    place-items: center;
    overflow: hidden;
    border-radius: 50%;
    background: var(--v2-bg-4);
    color: var(--v2-gold-hi);
    font-family: var(--v2-font-display);
    font-size: 12px;
    font-weight: 800;
}
.comment-avatar img, .mention-item-avatar img { width: 100%; height: 100%; object-fit: cover; display: block; }
.comment > div:last-child { flex: 1; min-width: 0; }
.comment-bubble { --c: var(--v2-cut-sm); padding: 9px 14px 10px; background: var(--v2-bg-3); clip-path: polygon(0 0, calc(100% - var(--c)) 0, 100% var(--c), 100% 100%, var(--c) 100%, 0 calc(100% - var(--c))); }
.comment-author { display: block; font-family: var(--v2-font-display); font-size: 13px; font-weight: 700; color: var(--v2-ink); }
.comment-text { font-size: 14px; line-height: 1.6; color: var(--v2-ink-2); margin-top: 2px; overflow-wrap: anywhere; white-space: pre-wrap; }
.comment-actions { display: flex; align-items: center; gap: 4px; margin-top: 2px; font-size: 12px; color: var(--v2-ink-3); }
.comment-time { padding-right: 6px; }
.comment-reply-btn, .comment-menu-btn { min-height: 40px; min-width: 40px; padding: 0 8px; border: 0; background: none; color: var(--v2-ink-3); font: inherit; font-weight: 700; cursor: pointer; }
.comment-reply-btn:hover, .comment-menu-btn:hover { color: var(--v2-gold); }
.comment-menu-wrap { position: relative; }
.comment-menu-wrap .comment-dropdown { left: auto; right: 0; }
.comment-edit-input { width: 100%; min-height: 42px; margin-top: 6px; padding: 8px 12px; border: 1px solid var(--v2-gold); background: var(--v2-bg); color: var(--v2-ink); font: inherit; font-size: 16px; outline: none; }
.comment-edit-actions { display: flex; gap: 8px; margin-top: 8px; }
.comment-edit-actions button { min-height: 36px; padding: 0 14px; border: 0; font-family: var(--v2-font-display); font-size: 12px; font-weight: 700; cursor: pointer; }
.comment-edit-actions .save-btn { background: var(--v2-gold); color: var(--v2-bg); }
.comment-edit-actions .cancel-btn { background: var(--v2-bg-4); color: var(--v2-ink); }
.comment-input-row, .reply-input-row { display: flex; align-items: center; gap: 8px; margin: 4px 0 12px; position: relative; }
.reply-input-row { margin-left: 44px; }
.comment-input-row input, .reply-input-row input, .lightbox-comment-input input {
    flex: 1;
    min-width: 0;
    min-height: 44px;
    padding: 10px 14px;
    border: 1px solid var(--v2-edge);
    background: var(--v2-bg-3);
    color: var(--v2-ink);
    font-family: var(--v2-font-body);
    font-size: 16px;
    outline: none;
}
.comment-input-row input:focus, .reply-input-row input:focus, .lightbox-comment-input input:focus { border-color: var(--v2-edge-gold); }
.comment-input-row input::placeholder, .reply-input-row input::placeholder, .lightbox-comment-input input::placeholder { color: var(--v2-ink-3); }
.comment-send { width: 44px; height: 44px; flex-shrink: 0; display: grid; place-items: center; border: 0; background: linear-gradient(180deg, var(--v2-gold-hi), var(--v2-gold)); color: var(--v2-bg-2); font-size: 15px; cursor: pointer; clip-path: polygon(0 0, 100% 0, 100% calc(100% - 8px), calc(100% - 8px) 100%, 0 100%); }
.comment-send.tl-emoji-btn { background: none; color: var(--v2-ink-3); clip-path: none; font-size: 17px; }
.comment-send.tl-emoji-btn:hover { color: var(--v2-gold); }
/* @mention autocomplete */
.mention-dropdown {
    position: absolute;
    left: 0;
    right: 0;
    bottom: calc(100% + 4px);
    z-index: 40;
    max-height: 220px;
    overflow-y: auto;
    display: none;
    background: var(--v2-bg-2);
    border: 1px solid var(--v2-edge-gold);
    box-shadow: 0 18px 50px rgba(2, 6, 30, 0.7);
}
.mention-dropdown.active { display: block; }
.mention-item { display: flex; align-items: center; gap: 10px; min-height: 52px; padding: 6px 12px; cursor: pointer; }
.mention-item:hover, .mention-item.selected { background: var(--v2-bg-3); }
.mention-item-name { font-family: var(--v2-font-display); font-size: 13.5px; font-weight: 700; }
.mention-item-username { font-size: 12px; color: var(--v2-ink-3); }

/* ── Brethren you may know (inline carousel + side list) ── */
.brethren-inline-wrap { --c: var(--v2-cut); position: relative; margin: 0 0 16px; padding: 18px 0 16px; background: var(--v2-bg-2); clip-path: polygon(0 0, calc(100% - var(--c)) 0, 100% var(--c), 100% 100%, var(--c) 100%, 0 calc(100% - var(--c))); box-shadow: inset 0 0 0 1px var(--v2-edge); }
.brethren-inline-header { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 0 16px 12px; }
.brethren-inline-title { font-family: var(--v2-font-display); font-size: 12.5px; font-weight: 800; letter-spacing: 0.14em; text-transform: uppercase; }
.brethren-inline-title i { color: var(--v2-gold); margin-right: 8px; }
.brethren-inline-see { min-height: 44px; display: inline-flex; align-items: center; font-size: 12.5px; font-weight: 700; color: var(--v2-gold); text-decoration: none; }
.brethren-scroll { display: flex; gap: 10px; overflow-x: auto; scroll-snap-type: x proximity; scrollbar-width: none; padding: 0 16px 2px; scroll-padding: 0 16px; }
.brethren-scroll::-webkit-scrollbar { display: none; }
.brethren-scroll-card { --c: 12px; scroll-snap-align: start; flex-shrink: 0; width: 150px; display: flex; flex-direction: column; align-items: center; gap: 4px; padding: 16px 12px 14px; text-align: center; background: var(--v2-bg-3); clip-path: polygon(0 0, calc(100% - var(--c)) 0, 100% var(--c), 100% 100%, var(--c) 100%, 0 calc(100% - var(--c))); }
.brethren-scroll-av, .brethren-card-av {
    flex-shrink: 0;
    display: grid;
    place-items: center;
    overflow: hidden;
    border-radius: 50%;
    background: var(--v2-bg-4);
    color: var(--v2-gold-hi);
    font-family: var(--v2-font-display);
    font-weight: 800;
}
.brethren-scroll-av { width: 68px; height: 68px; margin-bottom: 8px; font-size: 22px; box-shadow: 0 0 0 2px var(--v2-bg-3), 0 0 0 4px var(--v2-gold); }
.brethren-scroll-av img, .brethren-card-av img { width: 100%; height: 100%; object-fit: cover; display: block; }
.brethren-scroll-name { font-family: var(--v2-font-display); font-size: 14px; font-weight: 700; line-height: 1.25; max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.brethren-scroll-role { font-size: 12px; color: var(--v2-ink-3); max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.brethren-scroll-flag { font-size: 13px; }
.brethren-scroll-add { margin-top: 8px; width: 100%; min-height: 40px; display: inline-flex; align-items: center; justify-content: center; gap: 7px; border: 0; background: var(--v2-bg-2); color: var(--v2-ink); box-shadow: inset 0 0 0 1px var(--v2-edge-gold); font-family: var(--v2-font-display); font-size: 12px; font-weight: 700; cursor: pointer; }
.brethren-scroll-add i { color: var(--v2-gold); }
.brethren-scroll-add:disabled, .brethren-add-btn:disabled { opacity: 0.7; cursor: default; }
@media (max-width: 899px) { .brethren-scroll-add { min-height: 44px; } }

/* ── Side column cards ── */
.sb-card { padding: 18px 18px 12px; }
.sb-card .v2-section-head { margin-bottom: 6px; }
.sb-card .v2-section-head h2 { font-size: 12px; }
.tl-side .v2-row strong { font-size: 13.5px; }
.tl-side .v2-row { min-height: 56px; }
.tl-empty-row { padding: 10px 0 8px; font-size: 13px; color: var(--v2-ink-3); }
.tl-empty-row i { color: var(--v2-gold); margin-right: 8px; }
.tl-room-dot { width: 40px; height: 40px; display: grid; place-items: center; flex-shrink: 0; background: var(--v2-bg-3); border: 1px solid var(--v2-edge); color: var(--v2-gold); }
.tl-date-blk { width: 44px; flex-shrink: 0; padding: 5px 0 6px; text-align: center; background: var(--v2-bg-3); border: 1px solid var(--v2-edge); font-family: var(--v2-font-display); font-weight: 800; }
.tl-date-blk span { display: block; font-size: 9.5px; letter-spacing: 0.12em; color: var(--v2-gold); }
.tl-date-blk b { display: block; font-size: 18px; line-height: 1.1; color: var(--v2-ink); }
.trending-rank { width: 26px; flex-shrink: 0; font-family: var(--v2-font-display); font-size: 12px; font-weight: 800; color: var(--v2-ink-3); }
.trending-rank.pinned { color: var(--v2-gold); }
.trending-topic .tl-hash { color: var(--v2-gold); }
.brethren-card-av { width: 40px; height: 40px; font-size: 14px; }
.brethren-add-btn { width: 44px; height: 44px; flex-shrink: 0; display: grid; place-items: center; border: 0; background: none; color: var(--v2-gold); font-size: 15px; cursor: pointer; }
.brethren-add-btn:hover { background: var(--v2-bg-3); }
.v3-ticker { max-height: 220px; overflow: hidden; position: relative; }
.v3-ticker-track.v3-ticker-anim { animation: tl-up 36s linear infinite; }
.v3-ticker:hover .v3-ticker-track { animation-play-state: paused; }
@keyframes tl-up { to { transform: translateY(-50%); } }
.v3-chainrow { display: flex; gap: 10px; padding: 10px 0; border-bottom: 1px solid var(--v2-edge); font-size: 13px; line-height: 1.5; color: var(--v2-ink-2); }
.v3-chainrow i { color: var(--v2-gold); margin-top: 3px; }
.v3-chainrow b { color: var(--v2-ink); font-family: var(--v2-font-display); }
.v3-chain-empty { padding: 10px 0; font-size: 13px; color: var(--v2-ink-3); }
.v3-chainfoot { display: flex; align-items: center; gap: 8px; padding-top: 10px; font-size: 12.5px; color: var(--v2-ink-3); }
.v3-chainfoot-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--v2-live); }

/* ── Rooms filter panel ── */
.tl-filter-panel { padding: 16px 16px 6px; margin-bottom: 16px; }
.room-filter-item { display: flex; align-items: center; gap: 12px; min-height: 64px; padding: 8px 0; border-bottom: 1px solid var(--v2-edge); text-decoration: none; color: inherit; }
.room-filter-item:last-child { border-bottom: 0; }
.room-filter-icon { width: 42px; height: 42px; display: grid; place-items: center; flex-shrink: 0; background: var(--v2-bg-4); color: var(--v2-gold); clip-path: var(--v2-octagon); }
.room-filter-name { font-family: var(--v2-font-display); font-size: 14.5px; font-weight: 700; }
.room-filter-meta { font-size: 12.5px; color: var(--v2-ink-3); }
.room-filter-badge { flex-shrink: 0; padding: 4px 9px; font-family: var(--v2-font-display); font-size: 10px; font-weight: 800; letter-spacing: 0.1em; }
.room-filter-badge.live { background: var(--v2-alert); color: #fff; }
.room-filter-badge.soon { background: var(--v2-gold); color: var(--v2-bg); }

/* ── States ── */
.loading { padding: 40px 20px; text-align: center; color: var(--v2-ink-3); font-size: 14px; }
.loading i { color: var(--v2-gold); margin-right: 8px; animation: fa-spin 1s linear infinite; }
.empty-state { padding: 40px 20px; text-align: center; color: var(--v2-ink-3); margin-bottom: 16px; }
.empty-state > i { display: block; margin-bottom: 10px; font-size: 28px; color: var(--v2-gold); opacity: 0.85; }
.empty-state h3 { font-size: 16px; color: var(--v2-ink); margin: 0 0 4px; }
.empty-state p { margin: 0; font-size: 14px; }

/* ── Scripture plates from bible-quote.js (page-level v2 skin) ── */
html.v2 .post-body .grv-quote {
    display: block;
    margin: 10px 0 6px;
    padding: 14px 16px 12px 18px;
    background: var(--v2-bg-3);
    border-left: 3px solid var(--v2-gold);
    font-family: var(--v2-font-body);
    white-space: normal;
    text-align: left;
}
html.v2 .grv-quote::before, html.v2 .grv-quote::after, html.v2 .grv-quote-orn, html.v2 .grv-quote-divider { display: none; }
html.v2 .grv-quote-text { font-family: var(--v2-font-body); font-size: 17px; font-weight: 500; font-style: italic; line-height: 1.6; color: var(--v2-ink); text-align: left; text-shadow: none; margin: 0 0 6px; }
html.v2 .grv-quote-text .jesus { color: #ffd79a; }
html.v2 .grv-quote-ref-block { align-items: flex-start; flex-direction: row; flex-wrap: wrap; gap: 8px; }
html.v2 .grv-quote-ref { font-family: var(--v2-font-display); font-size: 11px; font-weight: 800; letter-spacing: 0.14em; color: var(--v2-gold); text-shadow: none; }
html.v2 .grv-quote-badge { font-family: var(--v2-font-display); border-radius: 0; background: var(--v2-bg-4); border: 0; box-shadow: none; font-size: 9.5px; }
html.v2 .grv-open-reader { display: inline-flex; align-items: center; gap: 6px; min-height: 36px; margin-top: 4px; font-size: 12.5px; font-weight: 700; color: var(--v2-gold); text-decoration: none; }
/* Bible verse picker: above the composer sheet */
html.v2 .grv-picker-overlay { z-index: 10060; background: rgba(6, 12, 46, 0.82); }
html.v2 .grv-picker { border-radius: 0; background: var(--v2-bg-2); border: 1px solid var(--v2-edge-gold); font-family: var(--v2-font-body); box-shadow: 0 18px 60px rgba(2, 6, 30, 0.7); }
html.v2 .grv-picker-header, html.v2 .grv-picker-search, html.v2 .grv-picker-footer { border-color: var(--v2-edge); }
html.v2 .grv-picker-header h3 { font-family: var(--v2-font-display); color: var(--v2-ink); }
html.v2 .grv-picker-header h3 i, html.v2 .grv-book-item .abbr, html.v2 .grv-verse-num, html.v2 .grv-search-ref, html.v2 .grv-breadcrumb span, html.v2 .grv-picker-footer .sel-ref { color: var(--v2-gold); }
html.v2 .grv-picker-back, html.v2 .grv-picker-close { width: 44px; height: 44px; border-radius: 0; }
html.v2 .grv-picker-search input { border-radius: 0; background: var(--v2-bg); border-color: var(--v2-edge); font-size: 16px; font-family: var(--v2-font-body); }
html.v2 .grv-testament-tab, html.v2 .grv-chapter-btn { border-radius: 0; background: var(--v2-bg-3); font-family: var(--v2-font-body); min-height: 40px; }
html.v2 .grv-testament-tab.active { background: var(--v2-gold); color: var(--v2-bg); }
html.v2 .grv-chapter-btn:hover { border-color: var(--v2-gold); color: var(--v2-gold); background: var(--v2-bg-4); }
html.v2 .grv-book-item, html.v2 .grv-verse-item, html.v2 .grv-search-result { border-bottom-color: var(--v2-edge); min-height: 44px; }
html.v2 .grv-book-item:hover, html.v2 .grv-verse-item:hover, html.v2 .grv-search-result:hover { background: var(--v2-bg-3); }
html.v2 .grv-verse-item.selected { background: var(--v2-bg-4); border-left-color: var(--v2-gold); }
html.v2 .grv-picker-insert { border-radius: 0; background: linear-gradient(180deg, var(--v2-gold-hi), var(--v2-gold)); color: var(--v2-bg-2); font-family: var(--v2-font-display); min-height: 44px; }
@media (max-width: 699px) {
    html.v2 .grv-picker-overlay { align-items: flex-end; }
    html.v2 .grv-picker { width: 100%; max-width: 100%; max-height: 90vh; border-width: 1px 0 0; }
}

/* ── Modals → v2 sheets (bottom sheet on phones, centred on desktop) ── */
.modal-overlay {
    position: fixed;
    inset: 0;
    z-index: 1290;
    display: none;
    align-items: flex-end;
    justify-content: center;
    background: rgba(6, 12, 46, 0.82);
    -webkit-backdrop-filter: blur(6px);
    backdrop-filter: blur(6px);
}
.modal-overlay.active { display: flex; }
.modal {
    position: relative;
    width: 100%;
    max-height: 92vh;
    max-height: 92dvh;
    display: flex;
    flex-direction: column;
    background: var(--v2-bg-2);
    border-top: 1px solid var(--v2-edge-gold);
    color: var(--v2-ink);
    animation: v2-rise 0.3s var(--v2-ease);
}
.modal-header { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 18px 18px 12px; border-bottom: 1px solid var(--v2-edge); }
.modal-header h3 { font-family: var(--v2-font-display); font-size: 18px; font-weight: 800; margin: 0; display: flex; align-items: center; gap: 10px; }
.modal-header h3 i { color: var(--v2-gold); }
.modal-close { width: 44px; height: 44px; margin-right: -10px; display: grid; place-items: center; border: 0; background: none; color: var(--v2-ink-2); font-size: 17px; cursor: pointer; }
.modal-close:hover { color: var(--v2-gold); }
.modal-body { padding: 16px 18px 4px; overflow-y: auto; overscroll-behavior: contain; }
.modal-footer { display: flex; justify-content: flex-end; gap: 8px; padding: 14px 18px calc(14px + var(--v2-safe-bottom)); border-top: 1px solid var(--v2-edge); }
.tl-confirm { padding: 26px 20px calc(22px + var(--v2-safe-bottom)); text-align: center; }
.tl-confirm-ico { width: 52px; height: 52px; margin: 0 auto 14px; display: grid; place-items: center; background: rgba(255, 93, 108, 0.14); color: var(--v2-alert); font-size: 20px; clip-path: var(--v2-octagon); }
.tl-confirm h3 { font-size: 18px; margin: 0 0 6px; }
.tl-confirm p { margin: 0 0 20px; font-size: 14px; color: var(--v2-ink-3); }
.tl-confirm-btns { display: flex; gap: 10px; justify-content: center; }
.tl-confirm-btns .v2-btn { flex: 1; max-width: 180px; }
@media (min-width: 700px) {
    .modal-overlay { align-items: center; padding: 24px; }
    .modal { width: min(560px, 100%); max-height: calc(100vh - 48px); border: 1px solid var(--v2-edge-gold); }
    .modal.tl-confirm { width: min(400px, 100%); }
    .modal-footer { padding-bottom: 14px; }
}
@media (min-width: 900px) { .modal-overlay { padding-left: calc(var(--v2-rail-w) + 24px); } }

/* ── Lightbox ── */
.lightbox { position: fixed; inset: 0; z-index: 1500; display: none; background: var(--v2-bg); }
.lightbox.active { display: flex; }
.lightbox-close { position: absolute; top: calc(8px + var(--v2-safe-top)); right: 8px; z-index: 3; width: 44px; height: 44px; display: grid; place-items: center; border: 0; background: rgba(10, 20, 66, 0.9); color: var(--v2-ink); font-size: 18px; cursor: pointer; }
.lightbox-container { display: flex; flex-direction: column; width: 100%; height: 100%; overflow-y: auto; }
.lightbox-media { position: relative; flex-shrink: 0; min-height: 55vh; display: grid; place-items: center; background: var(--v2-bg); }
.lightbox-media img { max-width: 100%; max-height: 70vh; object-fit: contain; transition: opacity 0.15s ease; }
.lightbox-nav { position: absolute; top: 50%; z-index: 2; width: 44px; height: 44px; transform: translateY(-50%); display: grid; place-items: center; border: 0; background: rgba(10, 20, 66, 0.9); color: var(--v2-ink); cursor: pointer; }
.lightbox-nav.prev { left: 8px; }
.lightbox-nav.next { right: 8px; }
.lb-counter { position: absolute; bottom: 14px; left: 50%; transform: translateX(-50%); padding: 4px 12px; background: rgba(10, 20, 66, 0.9); font-family: var(--v2-font-display); font-size: 12px; font-weight: 700; }
.lightbox-sidebar { display: flex; flex-direction: column; background: var(--v2-bg-2); border-top: 1px solid var(--v2-edge-gold); padding: 16px 16px calc(16px + var(--v2-safe-bottom)); }
.lightbox-post-header { display: flex; align-items: center; gap: 12px; margin-bottom: 10px; }
.lb-avatar { --s: 40px; }
.lb-author { font-family: var(--v2-font-display); font-weight: 700; }
.lb-time { font-size: 12px; color: var(--v2-ink-3); }
.lightbox-caption { font-size: 14px; line-height: 1.6; color: var(--v2-ink-2); margin-bottom: 10px; white-space: pre-wrap; overflow-wrap: anywhere; }
.lightbox-caption .post-text-preview, .lightbox-caption .see-more-link { display: none !important; }
.lightbox-caption .post-text-full { display: inline !important; }
.lightbox-reactions { display: flex; justify-content: space-between; font-size: 13px; color: var(--v2-ink-3); padding: 6px 0; }
.lightbox-reactions .reaction-icon { color: var(--v2-gold); }
.lightbox-actions { display: flex; border-top: 1px solid var(--v2-edge); border-bottom: 1px solid var(--v2-edge); margin-bottom: 10px; }
.lightbox-actions button { flex: 1; min-height: 46px; display: inline-flex; align-items: center; justify-content: center; gap: 8px; border: 0; background: none; color: var(--v2-ink-3); font-family: var(--v2-font-body); font-size: 13px; font-weight: 700; cursor: pointer; }
.lightbox-actions button:hover, .lightbox-actions button.liked { color: var(--v2-gold); }
.lightbox-comments-scroll { flex: 1; }
.lightbox-comments-scroll .comment-input-row, .lightbox-comments-scroll .reply-input-row { display: none; }
.lightbox-comment-input { display: flex; align-items: center; gap: 8px; padding-top: 8px; }
.lightbox-comment-input button { width: 44px; height: 44px; flex-shrink: 0; border: 0; background: linear-gradient(180deg, var(--v2-gold-hi), var(--v2-gold)); color: var(--v2-bg-2); cursor: pointer; }
@media (min-width: 900px) {
    .lightbox-container { flex-direction: row; overflow: hidden; }
    .lightbox-media { flex: 1; min-height: 0; }
    .lightbox-media img { max-height: 100vh; }
    .lightbox-sidebar { width: 380px; flex-shrink: 0; overflow-y: auto; border-top: 0; border-left: 1px solid var(--v2-edge-gold); }
}

/* ── Story viewer ── */
.sv-overlay { position: fixed; inset: 0; z-index: 1500; display: none; align-items: center; justify-content: center; background: rgba(6, 12, 46, 0.96); }
.sv-overlay.open { display: flex; }
.sv-stage { position: relative; width: min(420px, 100vw); height: min(760px, 100vh); display: flex; flex-direction: column; overflow: hidden; background: var(--v2-bg); border: 1px solid var(--v2-edge-gold); }
@media (max-width: 600px) { .sv-stage { width: 100vw; height: 100vh; height: 100dvh; border: 0; } }
.sv-bars { position: absolute; top: calc(var(--v2-safe-top)); left: 0; right: 0; z-index: 6; display: flex; gap: 4px; padding: 12px 12px 0; }
.sv-bar { flex: 1; height: 3px; background: rgba(240, 242, 255, 0.25); overflow: hidden; }
.sv-bar i { display: block; height: 100%; width: 0; background: var(--v2-gold); }
.sv-bar.done i { width: 100%; }
.sv-head { position: absolute; top: calc(22px + var(--v2-safe-top)); left: 0; right: 0; z-index: 6; display: flex; align-items: center; gap: 11px; padding: 0 6px 0 14px; pointer-events: none; }
.sv-head .sv-x, .sv-head .sv-av { pointer-events: auto; }
.sv-av { width: 38px; height: 38px; flex-shrink: 0; display: grid; place-items: center; border-radius: 50%; background: var(--v2-bg-4) center / cover; color: var(--v2-gold); box-shadow: 0 0 0 2px var(--v2-gold); }
.sv-meta { flex: 1; min-width: 0; }
.sv-name { font-family: var(--v2-font-display); font-weight: 700; font-size: 14.5px; color: #fff; text-shadow: 0 1px 6px rgba(6, 12, 46, 0.7); }
.sv-time { font-size: 11.5px; color: var(--v2-ink-2); }
.sv-x { width: 44px; height: 44px; border: 0; background: none; color: #fff; font-size: 20px; cursor: pointer; }
.sv-body { flex: 1; display: flex; align-items: center; justify-content: center; overflow: hidden; background: var(--v2-bg); }
.sv-media { max-width: 100%; max-height: 100%; object-fit: contain; }
.sv-textstory { width: 100%; height: 100%; display: grid; place-items: center; padding: 34px; }
.sv-textstory p { font-family: var(--v2-font-display); font-size: 24px; font-weight: 700; line-height: 1.4; text-align: center; color: #fff; }
.sv-live { width: 100%; height: 100%; background-size: cover; background-position: center; }
.sv-live-plain { display: grid; place-items: center; font-size: 64px; color: var(--v2-gold); }
.sv-audio { width: 100%; height: 100%; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 26px; padding: 30px; }
.sv-audio-art { width: 180px; height: 180px; display: grid; place-items: center; font-size: 60px; color: var(--v2-gold); clip-path: var(--v2-octagon); }
.sv-aud { width: 100%; }
.sv-cap { position: absolute; bottom: calc(80px + var(--v2-safe-bottom)); left: 0; right: 0; z-index: 6; padding: 0 20px; text-align: center; color: #fff; font-size: 14.5px; font-weight: 600; text-shadow: 0 2px 10px rgba(6, 12, 46, 0.8); pointer-events: none; }
.sv-cta { position: absolute; bottom: calc(22px + var(--v2-safe-bottom)); left: 0; right: 0; z-index: 7; display: flex; justify-content: center; pointer-events: none; }
.sv-join { pointer-events: auto; display: inline-flex; align-items: center; gap: 9px; min-height: 48px; padding: 0 24px; background: linear-gradient(180deg, var(--v2-gold-hi), var(--v2-gold)); color: var(--v2-bg-2); font-family: var(--v2-font-display); font-weight: 700; text-decoration: none; clip-path: polygon(0 0, 100% 0, 100% calc(100% - 10px), calc(100% - 10px) 100%, 0 100%); }
.sv-nav { position: absolute; top: 0; bottom: 0; z-index: 5; width: 28%; border: 0; background: none; cursor: pointer; }
.sv-prev { left: 0; }
.sv-next { right: 0; }

/* ── Emoji picker ── */
.emoji-picker-overlay { position: fixed; inset: 0; z-index: 2; }
.emoji-picker {
    position: absolute;
    bottom: calc(100% + 8px);
    right: 0;
    z-index: 50;
    width: min(340px, calc(100vw - 32px));
    max-height: 360px;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    background: var(--v2-bg-2);
    border: 1px solid var(--v2-edge-gold);
    box-shadow: 0 18px 50px rgba(2, 6, 30, 0.7);
}
.emoji-picker-search { padding: 10px; border-bottom: 1px solid var(--v2-edge); }
.emoji-picker-search input { width: 100%; min-height: 40px; padding: 8px 12px; border: 1px solid var(--v2-edge); background: var(--v2-bg); color: var(--v2-ink); font-family: var(--v2-font-body); font-size: 16px; outline: none; }
.emoji-picker-categories { display: flex; overflow-x: auto; scrollbar-width: none; border-bottom: 1px solid var(--v2-edge); }
.emoji-picker-categories button { flex-shrink: 0; width: 40px; height: 40px; border: 0; border-bottom: 2px solid transparent; background: none; font-size: 17px; cursor: pointer; }
.emoji-picker-categories button.active { border-bottom-color: var(--v2-gold); }
.emoji-picker-grid { flex: 1; overflow-y: auto; display: grid; grid-template-columns: repeat(8, 1fr); padding: 6px; overscroll-behavior: contain; }
.emoji-picker-label { grid-column: 1 / -1; padding: 8px 4px 4px; font-family: var(--v2-font-display); font-size: 10px; font-weight: 800; letter-spacing: 0.14em; text-transform: uppercase; color: var(--v2-ink-3); }
.emoji-item { aspect-ratio: 1; border: 0; background: none; font-size: 21px; cursor: pointer; }
.emoji-item:hover { background: var(--v2-bg-3); }
.composer-toolbar .emoji-picker { left: 0; right: auto; }

/* ── Mini player (video keeps playing when scrolled away) ── */
.as-mini-player {
    position: fixed !important;
    right: 12px !important;
    bottom: calc(var(--v2-dock-h) + var(--v2-safe-bottom) + 12px) !important;
    left: auto !important;
    top: auto !important;
    width: 220px !important;
    max-width: 60vw !important;
    margin: 0 !important;
    z-index: 1180 !important;
    overflow: hidden !important;
    background: var(--v2-bg) !important;
    border: 1px solid var(--v2-edge-gold) !important;
    box-shadow: 0 18px 50px rgba(2, 6, 30, 0.7) !important;
}
@media (min-width: 900px) { .as-mini-player { width: 360px !important; bottom: 24px !important; right: 24px !important; } }
.as-mini-player iframe, .as-mini-player video { width: 100% !important; aspect-ratio: 16 / 9; display: block; border: 0; }
.mini-player-header { position: absolute; top: 0; left: 0; right: 0; z-index: 2; display: flex; align-items: center; gap: 6px; padding: 4px 4px 4px 10px; background: linear-gradient(to bottom, rgba(6, 12, 46, 0.92), transparent); }
.mini-player-title { flex: 1; min-width: 0; font-size: 12px; font-weight: 700; color: #fff; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.mini-player-actions { display: flex; }
.mini-player-actions button { width: 36px; height: 36px; border: 0; background: none; color: #fff; cursor: pointer; }
.mini-player-actions .mp-close:hover { color: var(--v2-alert); }
@media (hover: hover) and (min-width: 900px) { .mini-player-header { opacity: 0; transition: opacity 0.2s ease; } .as-mini-player:hover .mini-player-header { opacity: 1; } }
.mini-player-placeholder { display: flex; align-items: center; justify-content: center; gap: 8px; min-height: 64px; margin-top: 14px; padding: 16px; border: 1px dashed var(--v2-edge-gold); color: var(--v2-ink-3); font-size: 13px; cursor: pointer; text-align: center; }
.mini-player-placeholder i { color: var(--v2-gold); font-size: 18px; }

/* ── Broadcast guest invitation ── */
.invite-notification {
    --c: 12px;
    position: fixed;
    top: calc(var(--v2-top-h) + var(--v2-safe-top) + 10px);
    right: 12px;
    left: 12px;
    z-index: 1320;
    padding: 16px;
    background: var(--v2-bg-2);
    border: 1px solid var(--v2-edge-gold);
    box-shadow: 0 18px 60px rgba(2, 6, 30, 0.7);
    animation: v2-rise 0.3s var(--v2-ease);
}
@media (min-width: 600px) { .invite-notification { left: auto; width: 360px; } }
@media (min-width: 900px) { .invite-notification { top: 20px; right: 20px; } }
.invite-notification .inv-header { display: flex; align-items: center; gap: 10px; margin-bottom: 10px; padding-right: 30px; }
.invite-notification .inv-icon { width: 38px; height: 38px; flex-shrink: 0; display: grid; place-items: center; background: var(--v2-gold); color: var(--v2-bg); clip-path: var(--v2-octagon); }
.invite-notification .inv-title { font-family: var(--v2-font-display); font-size: 14.5px; font-weight: 700; }
.invite-notification .inv-sub { font-size: 12px; color: var(--v2-ink-3); }
.invite-notification .inv-body { font-size: 13px; line-height: 1.5; color: var(--v2-ink-2); margin-bottom: 12px; }
.invite-notification .inv-actions { display: flex; gap: 8px; }
.invite-notification .inv-btn { flex: 1; min-height: 44px; border: 0; font-family: var(--v2-font-display); font-size: 13px; font-weight: 700; cursor: pointer; }
.invite-notification .inv-accept { background: linear-gradient(180deg, var(--v2-gold-hi), var(--v2-gold)); color: var(--v2-bg-2); }
.invite-notification .inv-decline { background: var(--v2-bg-3); color: var(--v2-ink-2); box-shadow: inset 0 0 0 1px var(--v2-edge); }
.invite-notification .inv-close { position: absolute; top: 4px; right: 4px; width: 40px; height: 40px; border: 0; background: none; color: var(--v2-ink-3); cursor: pointer; }
.invite-notification .inv-timer { margin-top: 8px; font-size: 11px; color: var(--v2-ink-3); text-align: center; }

/* The shared chat bubble (chat-widget.js) would float over sheets and overlays */
body.m-sheet-open .cw-bubble,
body.sv-lock .cw-bubble,
body.v3-mode-map .cw-bubble,
body:has(.modal-overlay.active) .cw-bubble,
body:has(.lightbox.active) .cw-bubble,
body:has(.grv-picker-overlay.active) .cw-bubble { display: none !important; }

/* Globe tooltip (built by the map script) */
#globe-tooltip { font-family: var(--v2-font-body); }

@media (prefers-reduced-motion: reduce) {
    .sanct-river-track, .v3-ticker-track.v3-ticker-anim { animation: none !important; }
}
