:root{--bg:#faf9f6;--paper:#fffefa;--panel:#f3f3ed;--ink:#273b34;--muted:#626b61;--line:#e5e6dd;--accent:#365f4f;--soft:#e7ede3;--gold:#ac8753;--serif:Georgia,'Times New Roman',serif;color-scheme:light}*{box-sizing:border-box}body{margin:0;background:var(--bg);color:var(--ink);font-family:Arial,Helvetica,sans-serif;font-size:14px}body.dark{--bg:#18231f;--paper:#1d2924;--panel:#202e27;--ink:#e1e6da;--muted:#aab6a7;--line:#37453a;--accent:#a7c4a3;--soft:#334738;color-scheme:dark}button,input,select,textarea{font:inherit;color:inherit}button,a,select{touch-action:manipulation}button{cursor:pointer;border:0;background:none;border-radius:7px;padding:9px 12px}button:hover{background:var(--soft)}button:disabled{opacity:.4;cursor:default}button:focus-visible,a:focus-visible,select:focus-visible{outline:2px solid var(--accent);outline-offset:3px}input,select,textarea{border:1px solid var(--line);background:var(--paper);border-radius:7px;padding:10px;min-width:0}input:focus,textarea:focus{outline:2px solid var(--accent)}a{color:var(--accent)}.topbar{height:92px;border-bottom:1px solid var(--line);display:flex;align-items:center;padding:0 36px;gap:60px;background:var(--paper)}.brand{display:flex;gap:12px;text-decoration:none;align-items:center;font-family:var(--serif);font-size:27px;color:var(--ink)}.logo{font-size:47px;line-height:1}.logo span{color:var(--gold)}.brand small{font:8px Arial;letter-spacing:2.2px;display:block;margin-top:6px;color:var(--muted)}nav{display:flex;height:100%;align-items:center;gap:20px}nav button{height:100%;border-radius:0;color:var(--muted);position:relative;padding:0 8px;font-size:13px}.nav-active{color:var(--accent);font-weight:600}.nav-active:after{content:'';position:absolute;bottom:0;left:0;right:0;height:3px;background:var(--accent)}#noteCount{font-size:10px;background:var(--soft);padding:3px 6px;border-radius:5px}.top-actions{margin-left:auto;display:flex;gap:8px;font-family:var(--serif);font-size:20px}.workspace{display:grid;grid-template-columns:235px minmax(340px,1fr) 380px;max-width:1800px;margin:auto;min-height:calc(100vh - 92px)}.sidebar{padding:32px 23px 0;border-right:1px solid var(--line);display:flex;flex-direction:column;height:calc(100vh - 92px);position:sticky;top:0}.eyebrow{font-size:9px;letter-spacing:1.7px;font-weight:600;color:var(--muted)}h2{font-family:var(--serif);font-size:24px;font-weight:400;margin:10px 0}.sidebar h2{font-size:25px;margin:16px 0 7px}.muted{color:var(--muted);font-size:12px;line-height:1.7}.sidebar>.muted{font-size:11px;margin-top:0}.searchbox{display:flex;align-items:center;gap:5px;border:1px solid var(--line);border-radius:7px;padding:0 10px;margin:18px 0 15px;background:var(--paper)}.searchbox input{width:100%;border:0;background:none;font-size:12px;padding:11px 4px}.testaments{display:flex;gap:6px;border-bottom:1px solid var(--line);padding-bottom:14px}.testaments button{font-size:11px;flex:1;padding:7px 0;color:var(--muted)}.testaments .active{background:var(--soft);color:var(--accent)}.books{overflow:auto;flex:1;padding:14px 0}.books button{display:flex;align-items:center;width:100%;text-align:left;font-size:12px;padding:10px 12px;margin:2px 0;color:var(--muted)}.books .chosen{background:var(--soft);color:var(--accent);font-weight:600}.books .chosen:after{content:'•';margin-left:auto}.sidebar footer{border-top:1px solid var(--line);padding:15px 0;font-size:11px;color:var(--muted);display:grid;grid-template-columns:20px 1fr;gap:5px}.sidebar footer p{line-height:1.6;margin:0}.sidebar footer button{grid-column:1/3;text-align:left;font-size:10px;padding-left:0}.small-leaf{color:var(--gold);font-size:20px}main{min-width:0;background:var(--paper)}.reader-toolbar{height:76px;border-bottom:1px solid var(--line);display:flex;align-items:center;justify-content:space-between;padding:0 35px}.passage-controls{display:flex;gap:6px}.passage-controls select{border:0;background:none;max-width:175px;font-size:13px}.version-pill{border:1px solid var(--line);font-size:11px;border-radius:20px;padding:8px 15px}.reading-content{max-width:790px;margin:auto;padding:45px 50px 25px}.chapter-heading{display:flex;justify-content:space-between;align-items:center}.chapter-heading h1{font-family:var(--serif);font-size:51px;font-weight:400;margin:13px 0 23px;letter-spacing:-1.8px}.chapter-heading h1 span{color:var(--gold)}.round{font-size:22px;color:var(--muted);border:1px solid var(--line);border-radius:50%;width:36px;height:36px;padding:0}.chapter-intro{display:flex;justify-content:space-between;gap:10px;font-size:10px;color:var(--muted);border-bottom:1px solid var(--line);padding-bottom:21px;line-height:1.6}.green{color:var(--accent)}.scripture{font-family:var(--serif);font-size:var(--reading-size,20px);line-height:1.9;padding-top:15px}.scripture h3{font:500 15px Arial;color:var(--ink);margin:25px 0 14px}.verse{display:block;width:100%;text-align:start;font:inherit;line-height:inherit;padding:5px 12px;margin:0 -12px;width:calc(100% + 24px);border-left:2px solid transparent;border-radius:0 5px 5px 0}.verse:hover{background:var(--panel)}.verse.selected{background:var(--soft);border-left-color:var(--accent)}.verse.highlighted{background:#f4e7b966}.verse.selected.highlighted{border-left-color:var(--gold)}.verse sup{font:10px Arial;color:var(--gold);margin-right:11px}.note-dot{font:12px Arial;color:var(--accent);margin-left:8px}.chapter-nav{display:flex;align-items:center;justify-content:space-between;border-top:1px solid var(--line);margin-top:30px;padding-top:20px;font-size:12px}.chapter-nav span{color:var(--muted);font-size:10px}.attribution{font-size:10px;line-height:1.7;color:var(--muted);margin-top:25px;overflow-wrap:anywhere}.study{border-left:1px solid var(--line);background:var(--panel);height:calc(100vh - 92px);position:sticky;top:0;display:flex;flex-direction:column}.study-header{display:flex;justify-content:space-between;align-items:center;padding:32px 25px 15px}.study-header h2{font-size:28px;margin-bottom:0}.study-badge{font-size:8px;letter-spacing:1px;border:1px solid var(--line);border-radius:5px;padding:6px;color:var(--accent)}.tabs{display:flex;margin:8px 20px 0;border-bottom:1px solid var(--line)}.tabs button{font-size:11px;flex:1;border-radius:0;padding:14px 3px;color:var(--muted)}.tabs button[aria-selected=true]{color:var(--accent);border-bottom:2px solid var(--accent);font-weight:600}.study-body{overflow:auto;flex:1;padding:24px}.study-body select{width:100%;font-size:12px;margin-bottom:20px}.quote{font:italic 16px/1.7 var(--serif);border-left:2px solid var(--gold);padding-left:15px;margin:0 0 24px;color:var(--muted)}.study-body h3{font-family:var(--serif);font-weight:400;font-size:22px;margin:18px 0 12px}.commentary-text{font-family:var(--serif);font-size:16px;line-height:1.85;white-space:pre-wrap;overflow-wrap:anywhere}.source-label{font-size:9px;letter-spacing:1.2px;color:var(--muted);line-height:1.8}.study-foot{text-align:center;font-family:var(--serif);font-style:italic;color:var(--muted);font-size:12px;border-top:1px solid var(--line);padding:19px}.word-grid{display:flex;flex-wrap:wrap;gap:8px}.word{background:var(--paper);border:1px solid var(--line);padding:12px 8px;flex:1 0 28%;max-width:100%;text-align:center}.word b{display:block;font:23px var(--serif)}.word small{display:block;font-size:10px;color:var(--muted);margin:6px 0}.word span{font-size:11px;color:var(--accent)}.lexicon{background:var(--paper);padding:18px;margin-top:15px;border:1px solid var(--line);border-radius:8px}.lexicon p{white-space:pre-wrap;line-height:1.7;font-size:13px}.primary{background:var(--accent);color:var(--paper)}.primary:hover{opacity:.85;background:var(--accent)}textarea{width:100%;resize:vertical;min-height:210px;line-height:1.7;font-family:var(--serif);font-size:16px}.button-row{display:flex;flex-wrap:wrap;gap:8px;margin:14px 0}.button-row button{border:1px solid var(--line);font-size:11px}.save-status{font-size:11px;color:var(--accent);min-height:15px}.compare-card{border-top:1px solid var(--line);padding:16px 0;font:18px/1.7 var(--serif)}.compare-card small{display:block;font:10px Arial;color:var(--accent);margin-bottom:10px}dialog{max-width:650px;width:calc(100% - 32px);max-height:85vh;overflow:auto;border:1px solid var(--line);background:var(--paper);color:var(--ink);border-radius:15px;padding:28px;box-shadow:0 25px 100px #14281a33}dialog::backdrop{background:#14281a66;backdrop-filter:blur(3px)}.modal-top{display:flex;align-items:center;justify-content:space-between;margin-bottom:18px}.modal-top h2{margin:0}.modal-top button{font-size:18px}.full-input{width:100%;margin-bottom:15px}.translation-option{display:block;text-align:left;width:100%;border-bottom:1px solid var(--line);border-radius:0;padding:13px}.translation-option small{display:block;color:var(--muted);font-size:11px;margin-top:6px}.modal-copy{line-height:1.8;color:var(--muted)}.notebook-entry{padding:18px 0;border-bottom:1px solid var(--line)}.notebook-entry p{white-space:pre-wrap;line-height:1.7;max-height:160px;overflow:auto}.notebook-entry button:not(.primary){color:var(--accent);font-weight:600;padding-left:0}#toast{position:fixed;bottom:25px;left:50%;transform:translateX(-50%);background:var(--ink);color:var(--paper);padding:12px 24px;border-radius:8px;display:none;z-index:10;font-size:12px}.error{padding:18px;background:var(--soft);border-radius:8px;line-height:1.7}.loading{color:var(--muted);font-size:12px;padding:20px 0}.label{display:block;font-size:11px;color:var(--muted);margin-bottom:8px}#modalBody input[type=range]{width:100%}@media(min-width:1500px){.workspace{grid-template-columns:260px minmax(340px,1fr) 420px}.reading-content{padding-top:60px}}@media(max-width:1100px){.workspace{grid-template-columns:185px minmax(320px,1fr) 330px}.sidebar{padding:25px 15px}.reading-content{padding:35px 30px}.topbar{padding:0 24px;gap:30px}.study-body{padding:20px}.study-header{padding:28px 20px 10px}}@media(max-width:900px){.workspace{grid-template-columns:minmax(320px,1fr) 340px}.sidebar{display:none}.topbar{height:75px}.study{height:calc(100vh - 75px)}.brand{font-size:24px}.reader-toolbar{padding:0 20px}.topbar nav{gap:8px}.topbar{gap:20px}}@media(max-width:680px){.topbar{padding:0 16px;height:70px;gap:10px}.brand{font-size:21px;gap:6px}.brand small{font-size:6px;letter-spacing:1px}.logo{font-size:38px}.topbar nav{margin-left:auto}.topbar nav button{font-size:10px;padding:0 4px}.top-actions{gap:0;margin:0}.top-actions button{padding:7px;font-size:18px}#noteCount{display:none}.workspace{display:block}.reading-content{padding:28px 25px 25px}.reader-toolbar{height:65px}.chapter-heading h1{font-size:43px}.study{height:auto;min-height:400px;max-height:none;position:static;border-left:0;border-top:1px solid var(--line)}.study-body{max-height:650px}.study-header{padding:25px 24px 10px}.chapter-intro{font-size:9px}.scripture{font-size:var(--reading-size,19px)}.study-foot{display:none}.tabs button{font-size:12px}.study-header h2{font-size:26px}.topbar nav button:first-child{display:none}}
.account-control{margin-left:auto;display:flex;align-items:flex-end;flex-direction:column;gap:3px}.account-control button{background:var(--soft);color:var(--accent);font-size:12px;padding:8px 15px}.account-control span{font-size:9px;color:var(--muted)}.top-actions{margin-left:0}.conflict-note{white-space:pre-wrap;max-height:180px;overflow:auto;line-height:1.7;padding:15px;background:var(--soft);border-radius:6px}@media(max-width:680px){.account-control button{font-size:10px;padding:6px 8px}.account-control span{font-size:7px;max-width:90px}.account-control{margin-left:4px}.topbar nav{margin-left:auto}.top-actions button{padding:5px}}
.legal-links{display:flex;gap:10px;flex-wrap:wrap;line-height:1.8;font-size:10px;margin:8px 0}.legal-links a{color:var(--muted)}.sidebar footer .legal-links{grid-column:1/3}.mobile-legal{display:none}.community-nav{display:flex;gap:4px;border-bottom:1px solid var(--line);margin-bottom:20px;flex-wrap:wrap}.community-nav button{font-size:11px}.community-nav .active{background:var(--soft);color:var(--accent)}.profile-intro{display:flex;gap:15px;align-items:center;margin:18px 0}.profile-avatar{width:58px;height:58px;border-radius:50%;object-fit:cover;flex-shrink:0;background:var(--soft);border:1px solid var(--line)}.initials{display:grid;place-items:center;font:26px var(--serif);color:var(--accent)}.friend-row{display:flex;align-items:center;gap:12px;padding:14px 0;border-bottom:1px solid var(--line)}.friend-row .profile-avatar{width:42px;height:42px}.friend-row>div:first-of-type{flex:1;min-width:0}.friend-row strong{font-weight:500;display:block;overflow-wrap:anywhere}.friend-row small{font-size:10px;color:var(--muted);display:block;margin-top:5px}.friend-actions{display:flex;flex-wrap:wrap;gap:2px;justify-content:flex-end}.friend-row button{font-size:11px}.check-label{display:flex;align-items:flex-start;gap:8px;font-size:12px;line-height:1.8;margin:14px 0;flex-wrap:wrap}.check-label input{margin-top:4px}.inline-form{display:flex;gap:8px;margin:18px 0}.inline-form input{flex:1;min-width:0}.profile-bio{white-space:pre-wrap;line-height:1.8}.chat-top{display:flex;gap:8px;justify-content:space-between;align-items:center;font-size:11px}.message-thread{height:310px;overflow:auto;padding:10px;background:var(--bg);border:1px solid var(--line);border-radius:8px;overscroll-behavior:contain}.message{padding:13px;background:var(--panel);margin:10px 35px 10px 0;border-radius:12px;overflow-wrap:anywhere}.message.mine{margin:10px 0 10px 35px;background:var(--soft)}.message small{font-size:9px;color:var(--muted)}.message p{white-space:pre-wrap;line-height:1.7;margin:7px 0;font-size:13px}.message .small-action{font-size:9px;color:var(--muted);padding:4px}.verse-share{display:block;background:var(--paper);padding:12px;border-radius:6px;text-decoration:none;font-size:12px;line-height:1.7;margin:8px 0}#messageText{min-height:85px;height:85px;font:14px/1.6 Arial}#profileBio{min-height:100px;height:100px;margin-bottom:15px}.danger{color:#a73e36;border:1px solid #b65b5366}.sr-only{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border:0}@media(max-width:680px){.mobile-legal{display:flex;justify-content:center;padding:20px;background:var(--panel);border-top:1px solid var(--line)}.topbar nav{gap:2px}.topbar nav button{font-size:9px;padding:0 3px}.brand{font-size:19px}.topbar{padding:0 10px;gap:6px}.friend-row{gap:8px}.friend-actions{max-width:130px}.community-nav button{font-size:10px;padding:8px}.message-thread{height:260px}}
/* The phone has one reading surface and a separate study drawer. */
.mobile-only,.mobile-nav,.mobile-study-backdrop{display:none}
@media(max-width:760px){
 body{padding-bottom:calc(76px + env(safe-area-inset-bottom));overflow-x:hidden}
 .topbar{height:70px;padding:env(safe-area-inset-top) 20px 0;gap:12px;position:relative;background:var(--paper)}
 .topbar .brand{font-size:24px;gap:10px;flex:1}.brand .logo{font-size:40px}.brand small{font-size:7px;letter-spacing:1.5px}
 .topbar>nav,.topbar>.account-control{display:none}.top-actions{margin:0;gap:4px}.top-actions button{min-height:44px;min-width:44px;font-size:21px;padding:8px}
 .workspace{display:block;min-height:calc(100dvh - 145px)}.sidebar{display:none!important}
 .reader-toolbar{position:sticky;top:0;z-index:12;height:66px;padding:8px 20px;gap:12px;background:var(--paper);box-shadow:0 3px 10px #15261a04}
 .reader-toolbar .passage-controls{display:none}.mobile-only{display:block}
 #mobilePassageButton{font-size:16px;font-weight:600;padding:10px 12px;min-height:46px;border:1px solid var(--line);border-radius:10px;flex:1;text-align:left;max-width:calc(100% - 85px);overflow:hidden;white-space:nowrap;text-overflow:ellipsis}
 .version-pill{font-size:12px;min-height:44px;min-width:70px;background:var(--soft);border:0}
 .reading-content{padding:32px 26px 22px;max-width:630px}.chapter-heading h1{font-size:46px;line-height:1.2;margin:13px 0 22px}.chapter-heading .eyebrow{font-size:9px;letter-spacing:1.5px}
 #focus{display:none}.chapter-intro{font-size:10px;flex-wrap:wrap;gap:4px 15px;padding-bottom:18px}.scripture{font-size:var(--reading-size,20px);line-height:1.95;padding-top:6px}.scripture h3{font-size:14px;line-height:1.6;margin-top:26px}
 .verse{padding:7px 10px;margin:0 -10px;width:calc(100% + 20px);border-radius:7px}.verse sup{font-size:11px;margin-right:9px}.chapter-nav button{min-height:48px;padding:10px 9px}.chapter-nav{font-size:12px;gap:8px}.chapter-nav span{font-size:10px;white-space:nowrap}.attribution{font-size:11px;line-height:1.8}
 .mobile-nav{display:grid;grid-template-columns:repeat(5,minmax(0,1fr));height:calc(70px + env(safe-area-inset-bottom));padding:5px max(8px,env(safe-area-inset-left)) calc(5px + env(safe-area-inset-bottom));position:fixed;inset:auto 0 0;background:var(--paper);border-top:1px solid var(--line);z-index:50;gap:2px;box-shadow:0 -5px 20px #14281a08}
 .mobile-nav button{display:flex;flex-direction:column;justify-content:center;align-items:center;gap:5px;height:100%;min-width:0;padding:6px 2px;border-radius:10px;color:var(--muted);font-size:10px;line-height:1.2}.mobile-nav svg{width:22px;height:22px;stroke:currentColor;stroke-width:1.6;stroke-linecap:round;stroke-linejoin:round;fill:none}.mobile-nav button.active{color:var(--accent);background:var(--soft)}.mobile-nav .active:after{content:none}

 .study{display:none!important}.mobile-study-open{overflow:hidden}.mobile-study-open .study{display:flex!important;position:fixed;inset:auto 0 max(calc(70px + env(safe-area-inset-bottom)),var(--mobile-viewport-bottom,0px));height:min(82dvh,calc(var(--mobile-viewport-height,100dvh) - 86px));min-height:0;max-height:none;z-index:42;border:1px solid var(--line);border-bottom:0;border-radius:22px 22px 0 0;box-shadow:0 -12px 60px #14281a33;overflow:hidden;background:var(--paper)}
 .mobile-study-backdrop:not([hidden]){display:block;position:fixed;inset:0;background:#12251c55;z-index:40;border-radius:0;backdrop-filter:blur(2px)}
 .study-header{padding:23px 22px 8px;flex:0 0 auto;position:relative}.study-header:before{content:'';position:absolute;top:8px;left:calc(50% - 20px);width:40px;height:4px;background:var(--line);border-radius:10px}.study-header .eyebrow{font-size:8px}.study-header h2{font-size:28px;margin-top:7px}.study-badge{display:none}#mobileCloseStudy{height:44px;width:44px;font-size:20px;color:var(--muted)}
 .study .tabs{flex:0 0 auto;margin:0 14px}.study .tabs button{font-size:12px;min-height:48px;padding:12px 3px}.study-body{padding:20px 23px 35px;max-height:none;min-height:0;overflow:auto;overscroll-behavior:contain;-webkit-overflow-scrolling:touch}.study-body select{font-size:16px;min-height:48px}.study-body .quote{font-size:17px}.commentary-text{font-size:17px;line-height:1.85}.study-foot{display:none}
 textarea,input,select{font-size:16px}textarea{font-size:18px;min-height:180px}.button-row button{min-height:44px;font-size:12px}.word{min-height:90px;flex-basis:28%}.word small{font-size:11px}.word span{font-size:12px}.lexicon p{font-size:15px;line-height:1.85}
 dialog#modal[open]{display:flex;flex-direction:column;position:fixed;inset:var(--mobile-viewport-top,0px) 0 auto;margin:0;width:100%;max-width:none;height:var(--mobile-viewport-height,100dvh);max-height:100dvh;border:0;border-radius:0;padding:0;background:var(--paper);overflow:hidden}
 #modal .modal-top{flex-shrink:0;margin:0;border-bottom:1px solid var(--line);padding:calc(14px + env(safe-area-inset-top)) 20px 14px;min-height:72px;gap:12px;background:var(--paper)}#modal .modal-top h2{font-size:26px;line-height:1.2;overflow-wrap:anywhere}#modal .modal-top button{height:44px;width:44px;flex-shrink:0}
 #modalBody{padding:22px 22px calc(24px + env(safe-area-inset-bottom));overflow:auto;overscroll-behavior:contain;flex:1;min-height:0;-webkit-overflow-scrolling:touch;scroll-padding-bottom:25px}
 #modalBody .full-input{min-height:49px;font-size:16px;margin-bottom:19px}#modalBody .label{font-size:12px;margin:5px 0 9px}#modalBody .primary{min-height:48px;padding:12px 18px;font-size:14px}#modalBody .muted{font-size:13px}#modalBody .translation-option{padding:17px 10px;min-height:62px;font-size:15px}#modalBody .translation-option small{font-size:12px}
 .mobile-testament-filter{display:flex;gap:6px;margin:3px 0 20px}.mobile-testament-filter button{flex:1;min-height:44px;font-size:11px;padding:8px 3px;border:1px solid var(--line)}.mobile-testament-filter button[aria-pressed=true]{background:var(--soft);color:var(--accent);border-color:var(--soft)}.mobile-book-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:10px}.mobile-book-grid button{text-align:left;border:1px solid var(--line);padding:14px 12px;min-height:72px;font-size:15px;border-radius:10px}.mobile-book-grid small{display:block;color:var(--muted);font-size:11px;margin-top:7px}.mobile-book-grid .current,.mobile-chapter-grid .current{background:var(--soft);border-color:var(--accent)}.mobile-chapter-grid{display:grid;grid-template-columns:repeat(5,minmax(0,1fr));gap:9px}.mobile-chapter-grid button{border:1px solid var(--line);min-height:54px;font-size:18px;border-radius:9px}.mobile-back{min-height:44px;padding-left:0;color:var(--accent)}
 .community-nav{position:sticky;top:-22px;padding:8px 0 10px;margin:0 0 20px;background:var(--paper);z-index:2;display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:3px;flex-wrap:nowrap}.community-nav button{min-height:46px;font-size:10px;line-height:1.5;padding:6px 2px;border-radius:7px}.friend-row{gap:10px;flex-wrap:wrap;padding:17px 0}.friend-row .friend-actions{max-width:none;flex-basis:100%;justify-content:flex-start;margin-left:52px}.friend-row button{min-height:44px;font-size:12px}.profile-intro h3{font-size:23px}.check-label{font-size:13px;line-height:1.9}.check-label input{min-height:20px;min-width:20px}.inline-form{gap:7px}.inline-form input{font-size:16px;width:0;min-height:48px}.inline-form button{flex-shrink:0;font-size:12px!important;padding:10px!important}
 .chat-top{font-size:11px;gap:3px}.chat-top button{min-height:44px;padding:8px 6px}.message-thread{height:clamp(170px,35dvh,390px)}.message{margin-right:20px}.message.mine{margin-left:20px}.message p{font-size:15px}.message small{font-size:10px}.message .small-action{min-height:38px;font-size:11px}.verse-share{min-height:48px;font-size:13px}#messageText{min-height:100px;height:100px;font-size:16px}.mobile-legal{display:flex;padding:20px 26px 25px;gap:12px 18px;font-size:11px;justify-content:center;border-top:1px solid var(--line)}#toast{bottom:calc(86px + env(safe-area-inset-bottom));width:max-content;max-width:calc(100% - 36px);padding:13px 17px;font-size:13px;line-height:1.5;z-index:60}
 
}
@media(max-width:350px){.topbar{padding-left:15px;padding-right:12px}.brand small{font-size:6px}.topbar .brand{font-size:22px}.reading-content{padding-left:21px;padding-right:21px}.mobile-nav button{font-size:9px}#modalBody{padding-left:18px;padding-right:18px}.mobile-chapter-grid{gap:6px}}
@media(prefers-reduced-motion:reduce){*{scroll-behavior:auto!important}}

.account-avatar{width:36px;height:36px;object-fit:cover;border-radius:50%;flex-shrink:0;background:var(--soft);border:1px solid var(--line)}.account-initial{display:grid;place-items:center;color:var(--accent);font:20px var(--serif)}#accountButton.has-account-avatar{padding:4px;min-width:44px;min-height:44px;display:grid;place-items:center;border-radius:50%}.mobile-nav .account-avatar{width:26px;height:26px;font-size:16px}.mobile-nav svg[hidden]{display:none}@media(max-width:760px){#accountButton.has-account-avatar{display:none}}

[hidden]{display:none!important}.skip-link{position:fixed;top:8px;left:8px;z-index:2000;background:var(--accent);color:white;padding:12px 18px;border-radius:8px;transform:translateY(-160%)}.skip-link:focus{transform:translateY(0)}.app-loading{position:fixed;inset:0;z-index:1500;display:flex;flex-direction:column;align-items:center;justify-content:center;background:var(--paper,#f7f5ef);text-align:center;padding:24px}.app-loading h1{font:clamp(28px,5vw,42px) var(--serif);margin:18px 0}.loading-emblem{font:72px Georgia;color:var(--accent);line-height:1}.loading-emblem span{color:#b69562}.loading-dots{display:flex;gap:8px;margin:20px}.loading-dots i{width:6px;height:6px;background:var(--accent);border-radius:50%;animation:loading-breathe 1.3s ease-in-out infinite}.loading-dots i:nth-child(2){animation-delay:.18s}.loading-dots i:nth-child(3){animation-delay:.36s}@keyframes loading-breathe{50%{opacity:.25;transform:translateY(-4px)}}.connection-banner{padding:12px 20px;background:var(--soft);border-bottom:1px solid var(--line);font:13px/1.6 Arial;color:var(--ink)}.passage-skeleton{min-height:450px;padding:12px 0}.skeleton-line{height:13px;margin:23px 0;background:var(--line);opacity:.55;border-radius:6px;animation:loading-breathe 1.8s ease-in-out infinite}.skeleton-line:nth-child(3n){width:74%}.skeleton-line:nth-child(4n){width:91%}.resource-error{padding:24px;border:1px solid var(--line);border-radius:12px;background:var(--soft);font:14px/1.7 Arial}.resource-error h3{font:25px var(--serif)}.resource-error a{color:var(--accent)}button:focus-visible,a:focus-visible,select:focus-visible,input:focus-visible,textarea:focus-visible{outline:2px solid var(--accent);outline-offset:3px}.not-found{max-width:660px;margin:10vh auto;padding:36px;text-align:center}.not-found .error-code{font:100px var(--serif);color:var(--accent);margin:20px 0}.not-found h1{font:36px var(--serif)}.not-found p{line-height:1.8}.not-found .button-row{justify-content:center;gap:16px;margin:28px 0}.not-found a:not(.primary){color:var(--accent)}.not-found .button-row{align-items:center}.not-found .primary{display:inline-flex;align-items:center;justify-content:center;min-height:44px;padding:10px 16px;border-radius:8px;text-decoration:none;font-weight:600}@media(prefers-reduced-motion:reduce){.loading-dots i,.skeleton-line{animation:none}}

#chapterText>h3{font:600 20px/1.4 var(--serif);color:var(--ink);margin:32px 0 16px;text-align:start}#chapterText>h3:first-child{margin-top:8px}@media(max-width:760px){#chapterText>h3{font-size:19px;margin:28px 0 14px}}

.streak-card{display:flex;align-items:center;gap:12px;width:100%;padding:12px 16px;margin:0 0 28px;border:1px solid var(--line);background:var(--panel);border-radius:14px;text-align:left}.streak-card>svg{width:30px;height:38px;flex-shrink:0}.streak-card strong{display:block;font:600 18px var(--serif)}.streak-card small{display:block;margin-top:4px;color:var(--muted);font-size:11px}.streak-week{display:flex;gap:5px;margin-left:auto}.streak-week i{width:9px;height:9px;border-radius:50%;background:var(--line)}.streak-week .done{background:#dc9841;box-shadow:0 0 0 3px #dc984118}.streak-celebration{text-align:center;line-height:1.7}.streak-celebration svg{width:70px;height:82px;filter:drop-shadow(0 4px 14px #e89b4333)}.streak-celebration h3{font:28px var(--serif)}.streak-calendar{display:grid;grid-template-columns:repeat(7,1fr);gap:5px;margin:26px 0;text-align:center}.streak-calendar small{font-size:10px;color:var(--muted)}.streak-calendar span{display:grid;place-items:center;width:34px;height:34px;margin:9px auto;background:var(--soft);border-radius:50%;color:var(--muted)}.streak-calendar .done{background:#e89b43;color:#342711;font-weight:bold}@media(max-width:760px){.streak-card{margin-bottom:24px;padding:10px 13px}.streak-card>svg{width:25px;height:31px}.streak-card strong{font-size:16px}.streak-week{gap:4px}.streak-week i{width:7px;height:7px}}

/* One themed passage picker on every screen size. */
.mobile-testament-filter{display:flex;gap:6px;margin:3px 0 20px}.mobile-testament-filter button{flex:1;min-height:44px;font-size:11px;padding:8px 3px;border:1px solid var(--line)}.mobile-testament-filter button[aria-pressed=true]{background:var(--soft);color:var(--accent);border-color:var(--soft)}.mobile-book-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:10px}.mobile-book-grid button{text-align:left;border:1px solid var(--line);padding:14px 12px;min-height:72px;font-size:15px;border-radius:10px}.mobile-book-grid small{display:block;color:var(--muted);font-size:11px;margin-top:7px}.mobile-book-grid .current,.mobile-chapter-grid .current{background:var(--soft);border-color:var(--accent)}.mobile-chapter-grid{display:grid;grid-template-columns:repeat(5,minmax(0,1fr));gap:9px}.mobile-chapter-grid button{border:1px solid var(--line);min-height:54px;font-size:18px;border-radius:9px}.mobile-back{min-height:44px;padding-left:0;color:var(--accent)}
.reader-toolbar .passage-controls{display:none}#mobilePassageButton{display:block;font-size:15px;font-weight:600;padding:11px 15px;min-height:44px;border:1px solid var(--line);border-radius:10px;background:var(--panel);color:var(--ink);text-align:left;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;max-width:calc(100% - 95px)}#mobilePassageButton:hover{background:var(--soft);border-color:var(--accent)}.picker-current-chapter{display:block;width:100%;padding:14px 16px;margin:0 0 22px;text-align:left;border:1px solid var(--line);background:var(--soft);color:var(--accent);border-radius:10px}.mobile-book-grid button:hover,.mobile-chapter-grid button:hover{background:var(--soft);border-color:var(--accent)}@media(min-width:761px){.mobile-book-grid{grid-template-columns:repeat(3,minmax(0,1fr))}.mobile-chapter-grid{grid-template-columns:repeat(7,minmax(0,1fr))}}

/* Keep streak progress in the header, away from the passage. */
.account-area{display:flex;align-items:center;gap:10px;margin-left:auto;flex-shrink:0}.account-area .account-control{margin-left:0}#readingStreak{display:inline-flex;align-items:center;justify-content:center;gap:5px;width:auto;min-width:54px;min-height:44px;padding:5px 9px;margin:0;border:1px solid var(--line);border-radius:22px;background:var(--panel);color:var(--ink);flex-shrink:0}#readingStreak>svg{width:20px;height:25px}#readingStreak strong{font:600 14px/1 Arial}#readingStreak:hover{background:var(--soft)}@media(max-width:760px){.account-area{margin-left:auto;gap:0}.account-area .account-control{display:none}.topbar{gap:8px}#readingStreak{min-width:46px;padding:5px 7px}#readingStreak>svg{width:18px;height:23px}#readingStreak strong{font-size:13px}.top-actions{flex-shrink:0}}@media(max-width:350px){.topbar .brand small{display:none}.topbar .brand{font-size:19px}.topbar{gap:4px}}

.account-menu{max-width:540px;margin:0 auto}.account-identity{display:flex;align-items:center;gap:14px;padding:3px 0 23px}.account-menu-picture{width:54px;height:54px;border-radius:50%;object-fit:cover;flex-shrink:0;background:var(--soft)}.account-menu-initial{display:grid;place-items:center;font:25px var(--serif);color:var(--accent)}.account-identity strong{display:block;font:23px var(--serif);font-weight:400}.account-identity>div{min-width:0}.account-identity span:not(.account-menu-picture){display:block;color:var(--muted);font-size:12px;overflow-wrap:anywhere;margin-top:6px}.account-sync{display:flex;align-items:center;gap:11px;padding:14px 15px;border-radius:12px;background:var(--soft);margin-bottom:23px}.account-sync>span{display:grid;place-items:center;border-radius:50%;width:23px;height:23px;flex-shrink:0;background:var(--accent);color:var(--paper);font-weight:bold}.account-sync strong{font-size:12px;display:block}.account-sync small{display:block;font-size:11px;color:var(--muted);margin-top:4px;line-height:1.5}.account-sync.needs-attention{border:1px solid var(--gold)}.account-menu-group{border:1px solid var(--line);border-radius:13px;overflow:hidden}.account-menu .account-menu-row{display:flex;align-items:center;gap:13px;width:100%;text-align:left;border:0;border-radius:0;background:none;padding:17px 15px;min-height:72px;font:inherit;line-height:1.5}.account-menu-row+.account-menu-row{border-top:1px solid var(--line)!important}.account-menu .account-menu-row:hover{background:var(--soft)}.account-row-icon{width:34px;height:34px;flex-shrink:0;display:grid;place-items:center;background:var(--panel);border-radius:10px;color:var(--accent)}.account-row-icon svg{width:19px;height:19px;stroke:currentColor;stroke-width:1.6;fill:none;stroke-linecap:round;stroke-linejoin:round}.account-row-copy{flex:1;min-width:0}.account-row-copy strong{font-size:14px;font-weight:500;display:block}.account-row-copy small{display:block;color:var(--muted);font-size:11px;line-height:1.5;margin-top:3px}.account-row-arrow{font-size:22px;color:var(--muted)}.account-data{margin-top:21px}.account-data summary{display:flex;justify-content:space-between;align-items:center;cursor:pointer;padding:13px 2px;font-size:12px;color:var(--muted);list-style:none}.account-data summary::-webkit-details-marker{display:none}.account-data[open] summary{color:var(--ink)}.account-data>p,.account-signout>p{font-size:10px;line-height:1.65;padding:0 2px;margin:12px 0}.account-signout{border-top:1px solid var(--line);margin-top:22px;padding-top:7px}.account-signout .account-menu-row{padding-left:0;padding-right:0;min-height:58px}.account-conflicts h3{font:19px var(--serif)}@media(max-width:760px){.account-menu{max-width:none}.account-menu .account-menu-row{font-size:14px;padding:16px 13px}.account-identity{padding-top:3px}.account-signout .account-menu-row{padding-left:0;padding-right:0}}

/* Calm, consistent community pages. */
.community-space{max-width:620px;margin:0 auto}.community-space .community-nav{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:4px;height:auto;padding:5px;background:var(--panel);border:1px solid var(--line);border-radius:12px;margin:0 0 25px}.community-space .community-nav button{display:flex;align-items:center;justify-content:center;gap:6px;padding:11px 5px;border-radius:8px;font-size:11px;min-height:46px;color:var(--muted);height:auto}.community-space .community-nav button:first-child{display:flex}.community-space .community-nav .active{color:var(--accent);background:var(--paper);box-shadow:0 1px 4px #0000000d}.community-nav svg{width:17px;height:17px;fill:none;stroke:currentColor;stroke-width:1.7;stroke-linecap:round;stroke-linejoin:round;flex-shrink:0}.community-page-intro{margin:0 0 24px}.community-page-intro h3{font:26px/1.3 var(--serif);margin:0 0 10px}.community-card{padding:20px;margin:17px 0;border:1px solid var(--line);border-radius:13px;background:var(--paper)}.community-card h3{font:20px var(--serif);margin:0 0 15px}.community-space .profile-intro{padding:5px 0 17px;gap:16px;margin-top:0}.community-space .profile-intro .profile-avatar{width:66px;height:66px}.community-space .profile-intro h3{font:25px var(--serif);margin:0 0 6px}.community-space .profile-intro p{margin:0}.community-space .label{font-size:12px;letter-spacing:0;text-transform:none;line-height:1.6;margin:16px 0 7px}.community-space .full-input,.community-space textarea{background:var(--panel);border-radius:9px;padding:12px 13px;font-size:14px}.community-space .check-label{display:grid;grid-template-columns:18px 1fr;gap:9px;line-height:1.7;align-items:start}.community-space .check-label input{margin-top:4px}.community-space .check-label:has(#profileTerms){display:block}.community-space .check-label #profileTerms{margin-right:7px}.photo-card input[type=file]{font-size:12px;line-height:1.8}.photo-card input::file-selector-button{font:inherit;border:0;border-radius:6px;background:var(--soft);color:var(--accent);padding:8px 12px;margin-right:10px;cursor:pointer}.photo-card #removePhoto{font-size:11px;color:var(--muted);margin-top:8px}.photo-card #photoStatus{font-size:10px;margin-bottom:0}.profile-save{display:flex;align-items:center;justify-content:flex-end;gap:12px;margin:20px 0}.profile-save p{flex:1;font-size:12px}.profile-save button{min-height:46px;padding:12px 24px}.community-space .friend-row{padding:15px;border:1px solid var(--line);border-radius:12px;margin:10px 0;background:var(--paper)}.community-space .friend-row strong{font-size:14px}.community-space .friend-row small{font-size:11px}.community-space .friend-actions{gap:6px}.community-space .friend-row button{border-radius:7px;min-height:40px;font-size:11px;padding:8px 10px;background:var(--soft)}.community-empty{padding:24px 20px;margin:12px 0 25px;border:1px dashed var(--line);border-radius:12px;text-align:center;background:var(--panel)}.community-empty strong{display:block;font:19px var(--serif)}.community-empty p{color:var(--muted);font-size:12px;line-height:1.7;margin:9px auto 0;max-width:340px}.community-space .inline-form{margin:12px 0 0}.community-space .inline-form input{background:var(--panel);padding:12px;border-radius:9px;min-width:0}.community-space .inline-form button{white-space:nowrap}.community-space details:not(.account-data){border:1px solid var(--line);border-radius:10px;padding:14px;margin-top:18px}.community-space summary{cursor:pointer;font-size:12px;color:var(--muted)}.privacy-actions>button{display:flex;justify-content:space-between;align-items:center;gap:16px;width:100%;padding:15px 0;text-align:left;border-radius:0}.privacy-actions>button+button{border-top:1px solid var(--line)}.privacy-actions strong{font-size:13px;font-weight:500;display:block}.privacy-actions small{display:block;font-size:11px;color:var(--muted);line-height:1.6;margin-top:4px}.danger-zone{border-color:#b65b5344}.danger-zone button{min-height:44px;padding:10px 16px}.community-space .legal-links{justify-content:center;gap:12px;font-size:10px;margin:23px 0}.community-space #profileBio{min-height:120px}.community-space #findFriend+div:empty{display:none}@media(max-width:760px){.community-space .community-nav button{flex-direction:column;gap:7px;font-size:10px;min-height:62px;padding:9px 3px}.community-nav svg{width:19px;height:19px}.community-space .community-nav{margin-bottom:24px}.community-card{padding:17px;margin:15px 0}.community-space .full-input,.community-space textarea,.community-space .inline-form input{font-size:16px}.community-space .friend-row{padding:13px;flex-wrap:wrap}.community-space .friend-actions{max-width:none;justify-content:flex-start;margin-left:54px;width:calc(100% - 54px)}.community-space .friend-row>button{margin-left:auto}.community-space .inline-form{flex-direction:column;gap:9px}.community-space .inline-form button{min-height:44px}.profile-save{display:block}.profile-save button{width:100%}.community-page-intro h3{font-size:25px}.community-space .profile-intro h3{font-size:23px}}

.study-tool-intro h3{font:25px var(--serif);margin:0 0 8px}.study-tool-intro{margin-bottom:20px}.note-passage{border:1px solid var(--line);border-radius:10px;padding:12px;margin:15px 0}.note-passage summary,.note-more summary{cursor:pointer;font-size:12px;color:var(--muted)}.note-passage .quote{margin-bottom:0}.note-prompts{display:flex;gap:6px;margin:20px 0 10px}.note-prompts button{background:var(--soft);color:var(--accent);border:1px solid var(--line);border-radius:20px;font-size:11px;min-height:38px;flex:1}#noteText.study-note-editor{min-height:270px;resize:vertical;border-radius:12px;background:var(--paper);font:15px/1.9 Arial;padding:16px}.note-more{padding:15px 0;border-top:1px solid var(--line);margin:15px 0}.note-more button{margin-top:12px}.compare-navigation{display:flex;justify-content:space-between;align-items:center;gap:10px;background:var(--soft);padding:5px;border-radius:10px;margin:20px 0}.compare-navigation button{min-width:44px;min-height:44px}.compare-navigation strong{font:18px var(--serif)}.translation-compare-card{border:1px solid var(--line);border-radius:12px;background:var(--paper);padding:18px;margin:0 0 13px}.translation-compare-card small{display:block;color:var(--accent);font:600 10px/1.5 Arial;letter-spacing:.5px;margin-bottom:12px}.translation-compare-card>div{font:20px/1.75 var(--serif)}.compare-note{font-size:10px}.passage-highlights{margin:10px 0 24px;border:1px solid var(--line);border-radius:12px;background:var(--panel);font:12px Arial}.highlight-heading{display:flex;align-items:center;justify-content:space-between;padding:6px 10px;gap:10px}.highlight-heading button{min-height:40px;font-size:12px;color:var(--accent)}.highlight-heading>span{font-size:10px}.highlight-range-panel{padding:4px 16px 16px;border-top:1px solid var(--line)}.highlight-range-inputs{display:flex;align-items:center;gap:14px;margin:13px 0}.highlight-range-inputs label{flex:1;font-size:11px;color:var(--muted)}.highlight-range-inputs input{width:100%;display:block;margin-top:7px;font-size:16px;background:var(--paper)}.highlight-range-panel .button-row button{min-height:44px}.verse.range-selected{outline:2px solid var(--gold);outline-offset:-2px;background:var(--soft)}@media(max-width:760px){#noteText.study-note-editor{font-size:16px;min-height:230px}.highlight-heading{align-items:flex-start;flex-direction:column;gap:0;padding-bottom:12px}.highlight-heading>span{padding-left:12px}.highlight-range-panel .button-row{display:grid;grid-template-columns:1fr 1fr;gap:6px}.highlight-range-panel .button-row button{font-size:11px;padding:9px}}

.direct-chat{max-width:620px;margin:0 auto}.chat-toolbar{display:flex;align-items:center;justify-content:space-between;margin:-5px 0 15px}.chat-toolbar>button{padding-left:0;color:var(--accent);min-height:42px}.chat-options{position:relative}.chat-options summary{cursor:pointer;list-style:none;padding:10px;font-weight:bold;letter-spacing:3px;min-height:42px}.chat-options summary::-webkit-details-marker{display:none}.chat-options>div{position:absolute;right:0;top:100%;z-index:2;min-width:175px;padding:6px;background:var(--paper);border:1px solid var(--line);border-radius:10px;box-shadow:0 8px 24px #0002}.chat-options button{display:block;width:100%;text-align:left;min-height:42px}.chat-person{display:flex;align-items:center;gap:12px;padding:0 0 16px}.chat-person .profile-avatar{width:42px;height:42px}.chat-person strong{display:block;font:21px var(--serif)}.chat-person small{display:block;font-size:10px;color:var(--muted);margin-top:5px}.direct-chat .message-thread{height:clamp(240px,39dvh,430px);padding:14px;border-radius:14px;background:var(--panel);border:1px solid var(--line)}.direct-chat .message{margin:8px 36px 12px 0;border-radius:13px 13px 13px 3px;background:var(--paper);padding:12px 14px}.direct-chat .message.mine{margin:8px 0 12px 36px;border-radius:13px 13px 3px 13px;background:var(--soft)}.direct-chat .message small{font-size:9px;line-height:1.5}.direct-chat .message p{font-size:14px;line-height:1.7;margin:7px 0}.direct-chat .verse-share{background:var(--panel);border-left:3px solid var(--gold);border-radius:7px;font-size:12px}.chat-composer{margin-top:15px;border:1px solid var(--line);background:var(--paper);border-radius:13px;padding:10px 12px}.chat-composer #messageText{border:0;background:none;outline-offset:0;min-height:75px;height:90px;max-height:220px;resize:vertical;padding:8px 2px;width:100%;font:14px/1.7 Arial}.composer-actions{display:flex;justify-content:space-between;align-items:center;gap:12px;border-top:1px solid var(--line);padding-top:10px}.verse-attachment{display:flex;align-items:center;gap:8px;font-size:11px;line-height:1.6}.verse-attachment small{display:block;color:var(--muted);font-size:9px}.composer-actions>button{min-width:78px;min-height:44px;border-radius:10px}.chat-composer #messageStatus{margin:7px 0 0;font-size:10px}.chat-composer #messageStatus:empty{display:none}.chat-privacy{margin:14px 0}.chat-privacy summary{cursor:pointer;color:var(--muted);font-size:10px;padding:7px 0}.friend-search-match{flex-wrap:wrap}.friend-search-match>button{margin-left:auto;min-height:44px}.request-sent{color:var(--accent);font-size:11px}.community-space #friendSearchHelp{font-size:10px;line-height:1.6;margin-bottom:0}#friendSearchResult:empty{display:none}@media(max-width:760px){.direct-chat .message-thread{height:clamp(210px,38dvh,390px);padding:10px}.direct-chat .message{margin-right:25px}.direct-chat .message.mine{margin-left:25px}.chat-composer #messageText{font-size:16px;min-height:70px;height:80px}.chat-composer{padding:9px 11px}.chat-person{padding-bottom:13px}.chat-person strong{font-size:20px}.composer-actions{gap:8px}.friend-search-match>button{width:100%;margin-top:8px}}

/* Search inputs must not inherit the zero-width flex sizing used by older phone forms. */
.community-space #findFriend{display:grid;grid-template-columns:minmax(0,1fr) auto;align-items:stretch;gap:10px}.community-space #findFriend #friendUsername{width:100%;min-width:0;min-height:48px;box-sizing:border-box;flex:none;font-size:16px;line-height:1.5;padding:12px 14px}.community-space #findFriend button{min-height:48px}@media(max-width:760px){.community-space #findFriend{grid-template-columns:minmax(0,1fr)}.community-space #findFriend #friendUsername{width:100%;min-height:50px}}

/* A single foreground scroll container; the reader remains fixed behind it. */
dialog#modal[open]{display:flex;flex-direction:column;overflow:hidden;overscroll-behavior:none;padding:0;max-height:85dvh}#modal .modal-top{flex:0 0 auto;padding:22px 26px;margin:0;border-bottom:1px solid var(--line)}#modalBody{flex:1 1 auto;min-height:0;overflow-y:auto;overscroll-behavior-y:contain;-webkit-overflow-scrolling:touch;padding:24px 26px}.study-body,.message-thread{overscroll-behavior-y:contain}@media(max-width:760px){dialog#modal[open]{height:var(--mobile-viewport-height,100dvh);max-height:100dvh}#modal .modal-top{padding:calc(14px + env(safe-area-inset-top)) 20px 14px}#modalBody{padding:22px 22px calc(24px + env(safe-area-inset-bottom))}}

/* Minimal highlighter: toggle on, tap verses, done. */
.passage-highlights{display:inline-block;margin:6px 0 20px;background:var(--paper);max-width:100%;vertical-align:top}.passage-highlights .highlight-heading{display:flex;flex-direction:row;align-items:center;gap:8px;padding:4px 7px}.passage-highlights .highlight-heading button{font-size:12px;white-space:nowrap;min-height:40px}.passage-highlights .highlight-heading>span{padding:0 7px 0 0;font-size:11px;line-height:1.5}.passage-highlights.is-highlighting{display:block;position:sticky;top:74px;z-index:6;background:var(--paper);border-color:var(--accent);box-shadow:0 3px 12px #0000000d}.passage-highlights.is-highlighting button{background:var(--soft);color:var(--accent)}@media(max-width:760px){.passage-highlights.is-highlighting{top:74px}.passage-highlights .highlight-heading>span{font-size:10px}}

/* Keep Highlight/Done available throughout the chapter, not just in active mode. */
#passageHighlights{position:sticky;top:74px;z-index:6;background:var(--paper);box-shadow:0 3px 12px #0000000d}#passageHighlights:not(.is-highlighting){border-radius:22px;width:max-content;max-width:100%}#passageHighlights .highlight-heading{margin:0}@media(max-width:760px){#passageHighlights{top:calc(74px + env(safe-area-inset-top,0px))}}

#togglePassageHighlights{display:inline-flex;align-items:center;justify-content:center;gap:5px;min-width:44px;min-height:44px}#togglePassageHighlights .highlighter-icon{width:23px;height:23px;fill:none;stroke:currentColor;stroke-width:1.8;stroke-linecap:round;stroke-linejoin:round}#togglePassageHighlights[aria-pressed=true] .highlighter-icon{fill:var(--gold);fill-opacity:.22}.highlighter-check{font-size:11px}#passageHighlights .highlight-heading{padding:3px 5px}

#passageHighlights.is-highlighting{display:inline-block;width:max-content;max-width:100%;border-radius:22px}

/* Active highlighter fills the complete visible pill, including its outer padding. */
#passageHighlights.is-highlighting{background:var(--soft);border-color:var(--accent)}#passageHighlights.is-highlighting .highlight-heading{background:transparent}#togglePassageHighlights[aria-pressed=true]{background:transparent;color:var(--accent)}

/* Highlighter stays within thumb reach and clear of the phone navigation. */
#passageHighlights,#passageHighlights.is-highlighting{position:fixed;top:auto;right:24px;bottom:24px;left:auto;z-index:35;display:block;width:auto;max-width:none;margin:0;border-radius:50%;box-shadow:0 4px 18px #14281a26}#passageHighlights .highlight-heading{padding:4px}#togglePassageHighlights{width:48px;height:48px;padding:10px;border-radius:50%}@media(max-width:760px){#passageHighlights,#passageHighlights.is-highlighting{right:18px;bottom:calc(90px + env(safe-area-inset-bottom))}body.mobile-study-open #passageHighlights{display:none}}

/* Equal dimensions in both states keep the floating control perfectly circular. */
#passageHighlights,#passageHighlights:not(.is-highlighting),#passageHighlights.is-highlighting{width:56px;height:56px;min-width:56px;max-width:56px;padding:0;border-radius:50%}#passageHighlights .highlight-heading{width:100%;height:100%;padding:3px;display:flex;align-items:center;justify-content:center;border-radius:50%}#togglePassageHighlights{width:48px;height:48px;min-width:48px;min-height:48px;margin:0;border-radius:50%;flex-shrink:0}

.google-auth-form{display:grid;gap:12px;margin:20px 0}.google-signin{display:flex;align-items:center;justify-content:center;gap:12px;width:100%;min-height:48px;border:1px solid var(--line);background:var(--paper);color:var(--ink);font-weight:600;border-radius:10px}.google-g{font:bold 22px Arial;color:var(--accent)}.google-signin:disabled{opacity:.6;cursor:not-allowed}.auth-divider{display:flex;align-items:center;gap:12px;color:var(--muted);font-size:12px;margin:24px 0}.auth-divider:before,.auth-divider:after{content:'';flex:1;height:1px;background:var(--line)}

/* Passage navigation: stable search controls and book-local chapter grids. */
@media(min-width:1101px){.workspace{grid-template-columns:270px minmax(340px,1fr) 380px}}
@media(min-width:1500px){.workspace{grid-template-columns:285px minmax(340px,1fr) 420px}}
.sidebar{padding-top:24px;min-height:0}.sidebar h2{margin-top:10px}.sidebar-search .label{font-size:11px;margin:12px 0 8px}.sidebar-search .searchbox{margin:0;border-radius:10px;padding:0 0 0 8px;min-height:46px}.sidebar-search input{font-size:13px;padding:12px 2px}.sidebar-search input::-webkit-search-cancel-button{display:none}.sidebar-search .searchbox:focus-within{outline:2px solid var(--accent);outline-offset:2px}.sidebar-search input:focus{outline:none}.sidebar-search button{padding:5px;min-width:30px;min-height:34px;font-size:20px}.sidebar-search-help{font-size:10px;line-height:1.6;color:var(--muted);margin:8px 0 12px}.sidebar-search-help kbd{border:1px solid var(--line);padding:0 4px;border-radius:3px;font:11px monospace}.sidebar .testaments{padding-bottom:8px}.sidebar .testaments button{min-height:36px}.sidebar-search-status{font-size:10px;line-height:1.5;color:var(--muted);margin:10px 0 0;flex-shrink:0}.books{overscroll-behavior:contain;scrollbar-width:thin;padding:6px 2px 20px;scroll-padding:12px}.book-group-label{font-size:9px;letter-spacing:1.1px;text-transform:uppercase;margin:18px 10px 8px;color:var(--muted)}.sidebar-book>button{min-height:48px;padding:10px;border-radius:9px;gap:6px;color:var(--ink)}.sidebar-book>button span:first-child{flex:1;min-width:0}.sidebar-book>button small{display:block;font-size:9px;font-weight:400;color:var(--muted);margin-top:4px}.books .chosen:after{content:none}.book-chevron{font-size:16px;color:var(--muted)}.sidebar-chapters{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:5px;padding:6px 4px 12px}.books .sidebar-chapters button{display:block;text-align:center;min-height:36px;margin:0;padding:6px 0;border:1px solid var(--line);border-radius:7px;font-size:12px;color:var(--ink)}.sidebar-chapters button[aria-current=page]{background:var(--accent);color:var(--paper);border-color:var(--accent)}.books .passage-search-result,.mobile-book-grid .passage-search-result{display:flex;flex-direction:column;align-items:flex-start;gap:8px;background:var(--soft);border:1px solid var(--accent);padding:16px 12px;border-radius:10px;color:var(--ink);grid-column:1/-1;margin-bottom:12px}.passage-search-result small{font-size:9px;letter-spacing:1px;color:var(--accent)}.passage-search-result strong{font:22px var(--serif)}.passage-search-result span{font-size:11px;color:var(--accent)}.book-search-empty{padding:18px 8px;line-height:1.6;font-size:12px;color:var(--muted)}.sidebar footer{padding:10px 0}.sidebar footer>.small-leaf,.sidebar footer>p{display:none}.sidebar footer .legal-links{font-size:9px;gap:6px}
@media(min-width:901px) and (max-width:1100px){.workspace{grid-template-columns:225px minmax(320px,1fr) 300px}.sidebar-search input{font-size:12px}}

.commentary-unavailable{border:1px solid var(--line);border-radius:12px;padding:20px;background:var(--paper);line-height:1.7}.commentary-unavailable h3{margin:0 0 12px;font:24px/1.3 var(--serif)}.commentary-unavailable p{font-size:13px;color:var(--muted)}.commentary-unavailable button{border:1px solid var(--line);min-height:44px;color:var(--accent)}#commentaryHelp{margin:8px 0 20px}#commentarySelect{width:100%;min-height:44px}#commentaryContent{min-width:0}

.translation-row {
 display: flex;
 align-items: center;
 gap: 8px;
}
.translation-row .translation-option {
 flex: 1;
 min-width: 0;
 overflow-wrap: anywhere;
}
.translation-favorite {
 flex: 0 0 44px;
 width: 44px;
 height: 44px;
 padding: 0;
 border: 1px solid var(--line);
 border-radius: 10px;
 font-size: 23px;
 color: var(--accent);
}
.translation-favorite[aria-pressed="true"] {
 background: var(--soft);
}
.compare-translation-controls {
 display: flex;
 align-items: center;
 justify-content: space-between;
 gap: 10px;
 margin-bottom: 18px;
}
.compare-translation-controls button { min-height: 44px; }

.notebook-views {
 display: flex;
 gap: 8px;
 margin-bottom: 16px;
}
.notebook-views button {
 flex: 1;
 min-height: 44px;
 border: 1px solid var(--line);
 border-radius: 10px;
}
.notebook-views button[aria-pressed="true"] {
 background: var(--soft);
 color: var(--accent);
 font-weight: 600;
}

.verse-search-result {
 display: block;
 width: 100%;
 min-height: 48px;
 text-align: start;
 padding: 12px 14px;
 margin: 8px 0;
 border: 1px solid var(--line);
 border-radius: 10px;
 background: var(--paper);
}
.verse-search-result strong {
 color: var(--accent);
}
.verse-search-result span {
 display: block;
 margin-top: 5px;
 font: 17px/1.55 var(--serif);
}

.mobile-bible-search {
 display: flex;
 align-items: stretch;
 gap: 8px;
 margin-bottom: 12px;
}
#modalBody .mobile-bible-search .full-input {
 flex: 1;
 min-width: 0;
 margin: 0;
}
#submitMobileBibleSearch, #submitBookSearch {
 flex: 0 0 44px;
 min-width: 44px;
 min-height: 44px;
 border: 1px solid var(--line);
 border-radius: 8px;
 color: var(--accent);
}
.mobile-book-grid > .inline-verse-search {
 grid-column: 1 / -1;
}
.inline-verse-search .label select {
 display: block;
 margin-top: 6px;
}

.sidebar-search .searchbox input { min-width: 0; }
#submitBookSearch {
 align-self: stretch;
 border: 0;
 border-left: 1px solid var(--line);
 border-radius: 0 9px 9px 0;
}

.notebook-highlight {
 background: var(--paper);
 border: 1px solid var(--line);
 border-radius: 12px;
 padding: 16px;
 margin: 0 0 12px;
}
.notebook-highlight h3 { margin: 0 0 10px; }
.notebook-highlight-text > div { font: 17px/1.6 var(--serif); }
.notebook-highlight-text p { margin: 0 0 7px; white-space: normal; max-height: none; overflow: visible; }
.notebook-highlight-text sup { color: var(--accent); }
.notebook-highlight-notes { border-top: 1px solid var(--line); margin-top: 12px; }
.notebook-highlight-notes h4 { margin: 12px 0 8px; }
.notebook-highlight-notes p { white-space: pre-wrap; overflow-wrap: anywhere; }
.notebook-highlight .button-row button {
 min-height: 44px;
 padding: 8px 14px;
 text-align: center;
}
.highlight-card-actions button { flex: 1 1 0; }
.comparison-credits { margin-top: 18px; }
.comparison-credits .attribution { margin: 0 0 12px; }
.highlight-note-form { margin-top: 10px; }
.highlight-note-form label { display: block; margin-bottom: 8px; }
.highlight-note-form textarea { display: block; width: 100%; min-height: 100px; font-size: 16px; }

@media (min-width: 761px) {
 .study {
  height: 100vh;
  height: 100dvh;
 }
 .study-header, .study .tabs { flex-shrink: 0; }
 .study-body { min-height: 0; }
 .reader-highlighter {
  position: sticky;
  top: calc(100vh - 80px);
  top: calc(100dvh - 80px);
  height: 0;
  z-index: 35;
  pointer-events: none;
 }
 .reader-highlighter #passageHighlights,
 .reader-highlighter #passageHighlights.is-highlighting {
  position: absolute;
  top: 0;
  right: 24px;
  bottom: auto;
  pointer-events: auto;
 }
}

.panel-handles { display: none; }

@media (min-width: 761px) {
 .workspace[data-books] {
  --books-width: 225px;
  --study-width: 300px;
  --books-column: var(--books-width);
  --study-column: var(--study-width);
  --panel-duration: 0ms;
  --panel-motion: var(--panel-duration) ease;
  grid-template-columns: var(--books-column) minmax(0, 1fr) var(--study-column);
  overflow-x: clip;
  transition: grid-template-columns var(--panel-motion);
 }
 .workspace[data-panel-motion] { --panel-duration: 220ms; }
 .workspace[data-books="closed"] { --books-column: 0px; }
 .workspace[data-study="closed"] { --study-column: 0px; }
 .workspace[data-books] .sidebar,
 .workspace[data-books] .study {
  display: flex;
  grid-row: 1;
  min-width: 0;
  transition: transform var(--panel-motion), visibility 0s;
 }
 .workspace[data-books] .sidebar { grid-column: 1; width: var(--books-width); justify-self: start; }
 .workspace[data-books] #reader { grid-column: 2; grid-row: 1; }
 .workspace[data-books] .study { grid-column: 3; width: var(--study-width); justify-self: end; }
 .workspace[data-books="closed"] .sidebar,
 .workspace[data-study="closed"] .study {
  visibility: hidden;
  transition-delay: 0s, var(--panel-duration);
  pointer-events: none;
 }
 .workspace[data-books="closed"] .sidebar { transform: translateX(-100%); }
 .workspace[data-study="closed"] .study { transform: translateX(100%); }
 
 .reader-toolbar {
  position: sticky;
  top: 0;
  z-index: 36;
  gap: 8px;
  background: var(--paper);
 }
 .reader-toolbar .passage-picker-button { min-width: 0; margin-right: auto; }
 .panel-handles {
  display: block;
  position: sticky;
  top: 88px;
  height: 0;
  z-index: 34;
  pointer-events: none;
 }
 .panel-handle {
  position: absolute;
  top: 0;
  display: grid;
  place-items: center;
  width: 32px;
  height: 48px;
  padding: 0;
  border: 1px solid var(--line);
  background: var(--panel);
  color: var(--accent);
  pointer-events: auto;
 }
 #toggleBooksPanel { left: 0; border-radius: 0 10px 10px 0; }
 #toggleStudyPanel { right: 0; border-radius: 10px 0 0 10px; }
 .panel-handle:hover { background: var(--soft); }
 .panel-handle svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 2; }
 .panel-handle[aria-expanded="true"] svg { transform: rotate(180deg); }
 .verse { scroll-margin-top: 84px; }
}
@media (min-width: 761px) and (max-width: 900px) {
 .workspace[data-books] { --books-width: 175px; }
 .workspace[data-books] { --study-width: 265px; }
 .reader-toolbar { padding-inline: 12px; }
}
@media (min-width: 1101px) {
 .workspace[data-books] { --books-width: 270px; }
 .workspace[data-books] { --study-width: 380px; }
}
@media (min-width: 1500px) {
 .workspace[data-books] { --books-width: 285px; }
 .workspace[data-books] { --study-width: 420px; }
}

@media (min-width: 761px) and (prefers-reduced-motion: reduce) {
 .workspace[data-books],
 .workspace[data-books] .sidebar,
 .workspace[data-books] .study { transition: none; }
}

.changelog-page {
 max-width: 780px;
 min-height: 100vh;
 margin: 0 auto;
 padding: clamp(24px, 6vw, 64px);
}
.changelog-header { margin-bottom: 32px; }
.changelog-header h1 { margin: 24px 0 8px; font-family: var(--serif); }
.changelog-header p { color: var(--muted); }
.changelog-topbar { justify-content: space-between; }
.changelog-back { color: var(--accent); font-size: 13px; }
.changelog-entry { padding: 24px 0; border-top: 1px solid var(--line); }
.changelog-entry h2 { margin: 0 0 12px; font-size: 20px; }
.changelog-entry ul { margin: 0; padding-inline-start: 22px; }
.changelog-entry li { margin: 8px 0; line-height: 1.6; }

@media (max-width: 760px) {
 #closeSidePanels { display: none; }
}

.verse, .notebook-highlight { touch-action: manipulation; }

.compare-reference-form input{min-width:0;width:100%;flex:1 1 9rem}

.related-back{padding:8px 10px;color:var(--accent);border:1px solid var(--line);font-size:12px}
.related-reference{border:1px solid var(--line);border-radius:8px;margin:0 0 8px}
.related-reference summary{cursor:pointer;padding:12px;color:var(--accent);font-weight:600}
.related-preview{padding:0 12px 12px}
.related-preview .quote{margin-block:8px}
#relatedMore{margin-top:6px;border:1px solid var(--line)}
/* Give long labels their natural width and share the remaining space evenly. */
.study .tabs{gap:2px;margin-inline:10px}
.study .tabs button{
 flex:1 0 auto;
 min-width:0;
 min-height:44px;
 padding:10px 2px;
 border-bottom:2px solid transparent;
 font-size:11px;
 white-space:nowrap;
}
.study .tabs button[aria-selected=true]{border-bottom-color:var(--accent)}
@media (min-width:361px) and (max-width:760px), (min-width:1200px){
 .study .tabs{gap:4px;margin-inline:14px}
 .study .tabs button{font-size:12px}
}

@media (min-width:761px) and (max-width:900px){
 .study .tabs{margin-inline:6px;gap:1px}
 .study .tabs button{padding-inline:1px;font-size:10px}
}

.verse-with-translator-notes{position:relative}
.verse-with-translator-notes .verse{padding-inline-end:52px;min-height:48px}
.translator-note-marker{
 position:absolute;inset-block-start:2px;inset-inline-end:0;
 width:44px;min-height:44px;display:grid;place-items:center;
 border-radius:8px;color:var(--accent);font-size:17px;
}
.translator-note-marker:hover,.translator-note-marker:focus-visible{background:var(--soft)}
.translator-note-marker small{font-size:10px;margin-inline-start:2px}
.translator-notes h3{margin-block:0 4px}
.translator-notes ol{padding-inline-start:1.5em}
.translator-notes li{padding-inline-start:4px;margin-block:10px;white-space:pre-line;overflow-wrap:anywhere}

/* iOS can zoom when focusing a form control with text below 16px. */
@media(max-width:760px),(pointer:coarse){
 input:not([type=checkbox],[type=radio],[type=file],[type=button],[type=submit],[type=range],[type=color]),textarea,select{
  font-size:max(16px,1em)!important;
 }
}
