/* The commentary panel (#cm, commentary.js): every rule here names the panel (#cm, #cm-*) or a commentary-only cm- class
   or body.cm-* state (or a cm- highlight), so none can reach the site header, the sections bar or another tab. Moved out of index.html as is
   (Greg 2026-10-16); publish.py stamps it commentary.css?v=<hash>. */
.lu-prose .cm-m, .lu-prose .cm-pn { vertical-align: super; font-size: 10px; line-height: 1; }
#cm { display: none; }
body.cm-open #cm { display: flex; flex-direction: column; background: var(--card); border: 1px solid var(--line); border-radius: var(--r); box-shadow: var(--sh-1); min-width: 0; }
@media (min-width: 641px) { body.cm-open #lu-body { display: grid; grid-template-columns: minmax(0, 1fr) clamp(260px, 36%, 380px); gap: 18px; align-items: start; } body.cm-open #cm { position: relative; box-sizing: border-box; margin-top: var(--cm-at, 0px); align-self: stretch; contain: size; height: auto; max-height: none; } }
.cm-top [role=tab][hidden] { display: none; }
.cm-top [role=tablist] { flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; min-width: 0; }
.cm-top [role=tablist]::-webkit-scrollbar { display: none; }
.cm-top [role=tab] { white-space: nowrap; flex: none; }
body.cm-open.cm-orig #lu-out .lu-t, body.cm-open.cm-orig #lu-out .lu-prt { cursor: pointer; }
.cm-ow { padding: 8px 10px; }
.cm-owo { margin: 0 0 2px; font-size: 30px; line-height: 1.3; color: var(--ink); font-family: "SBL Hebrew", "Ezra SIL", "Times New Roman", serif; }
.cm-owo[lang=grc] { font-size: 26px; }
.cm-owx { margin: 0 0 4px; font-size: 14px; color: var(--soft); }
.cm-owg { margin: 0 0 4px; font-weight: bold; }
.cm-owm { margin: 0 0 4px; font-size: 19px; }
.cm-owm i { font-size: 20px; }
.cm-oweq { color: var(--soft); }
.cm-owdl { margin: 4px 0 6px; font-size: 14px; }
.cm-owdl dt { font: bold 12px "Source Sans 3", "Source Sans 3 Fallback", Arial, sans-serif; color: var(--soft); margin-top: 4px; }
.cm-owdl dd { margin: 0 0 2px; }
.cm-owp { font-family: "Source Sans 3", "Source Sans 3 Fallback", Arial, sans-serif; letter-spacing: .02em; }
.cm-owrw { font-size: 20px; font-family: "SBL Hebrew", "Ezra SIL", "Times New Roman", serif; }
.cm-owna { color: var(--soft); font-style: italic; }
.cm-owdv { font-size: 13px; }
.cm-owd { margin: 0; font-size: 14px; }
.cm-owl { font: bold 12px "Source Sans 3", "Source Sans 3 Fallback", Arial, sans-serif; color: var(--soft); }
.cm-owlink { margin: 4px 0 8px; font-size: 14px; }
/* the word's card in the Word study (2026-11-21): a clear link, a full-size tap target on a phone */
.cm-owopen { margin: 2px 0 6px; font-size: 15px; }
.cm-owcard { display: inline-block; padding: 4px 0; font-weight: bold; }
.cm-owcard span[lang] { font-weight: normal; font-size: 18px; font-family: "SBL Hebrew", "Ezra SIL", "Times New Roman", serif; }
.cm-owid { font-weight: bold; }
@media (max-width: 640px) { .cm-owcard { display: block; min-height: 44px; padding: 10px 0; box-sizing: border-box; } }
.cm-owlist { list-style: none; margin: 0; padding: 0; }
.cm-owlist li { margin: 0; }
.cm-owpick { display: block; width: 100%; text-align: left; font: inherit; font-size: 14px; padding: 5px 6px; border: 0; border-top: 1px solid #eef0f3; background: none; cursor: pointer; border-radius: 4px; }
.cm-owpick:hover, .cm-owpick.on { background: var(--accent-soft, #e8f3f2); }
.cm-owpick span[lang] { font-size: 18px; color: var(--ink); }
.cm-owe { color: var(--soft); }
.cm-sub label, .cm-sub > span { white-space: nowrap; }
.cm-ts { display: none; }
.cm-top.cm-tight .cm-ts { display: inline; }
.cm-top.cm-tight .cm-tl { display: none; }
.cm-top.cm-tight [role=tab] { padding-left: 4px; padding-right: 4px; font-size: 13px; }
.cm-top.cm-tight [role=tablist] { gap: 1px; }
@media (max-width: 1100px) { .cm-top [role=tab] { padding: 6px 7px; } .cm-top { gap: 2px; padding: 6px 4px 0 6px; } #cm-x { padding: 2px 6px; } }
@media (max-width: 640px) { .cm-top [role=tab] { padding: 6px 7px; } .cm-owpick { min-height: 44px; } }
.cm-top, .cm-sub { flex: none; }
body.cm-open #cm { overflow: hidden; }
.cm-top { display: flex; align-items: center; gap: 6px; padding: 6px 8px 0; border-bottom: 1px solid var(--line); }
.cm-top [role=tablist] { flex: 1; display: flex; gap: 4px; }
.cm-top [role=tab] { font: inherit; font-size: 14px; padding: 6px 10px; border: 0; border-bottom: 3px solid transparent; background: none; color: var(--soft); cursor: pointer; }
.cm-top [role=tab][aria-selected="true"] { color: var(--ink); border-bottom-color: var(--gold); }
#cm .cm-top [role=tab]:hover { background: none; color: var(--ink); }
#cm .cm-top [role=tab]:not([aria-selected="true"]), #cm .cm-top [role=tab]:not([aria-selected="true"]):hover { border-bottom-color: transparent; }
#cm .cm-top [role=tab]:focus-visible { outline: 2px solid var(--gold); outline-offset: -2px; border-radius: 4px; }
#cm-x { flex: none; margin-left: auto; align-self: center; font-size: 22px; line-height: 1; padding: 2px 10px; border: 0; background: none; color: var(--soft); cursor: pointer; border-radius: var(--r-sm); }
#cm-x:hover { background: #e8f3f2; }
.cm-sub { display: flex; flex-wrap: wrap; gap: 6px 10px; align-items: center; justify-content: space-between; padding: 8px 12px; font-size: 14px; color: var(--soft); }
.cm-sub b { color: #2f3740; font-variant: small-caps; letter-spacing: .4px; font-size: 16px; }
#cm-pick { display: inline-flex; gap: 6px; align-items: center; min-width: 0; }
#cm-pick[hidden] { display: none; }
#cm-mod { font: inherit; font-size: 14px; color: var(--ink); padding: 4px 6px; border: 1px solid var(--line); border-radius: var(--r-sm); background: #ffffff; max-width: 100%; min-width: 0; }
body.cm-open.cm-chap #cm { overflow: clip; }
body.cm-chap #cm .cm-top { position: sticky; top: var(--pinh, 52px); z-index: 2; background: var(--card); }
body.cm-chap #cm .cm-sub { position: sticky; top: calc(var(--pinh, 52px) + var(--cm-toph, 40px)); z-index: 2; background: var(--card); }
.cm-e { padding: 6px 8px; margin: 0 -8px 6px; border-radius: var(--r-sm); }
.cm-e.on { background: var(--accent-soft, #e8f3f2); }
.cm-e h4 { font-size: 15px; margin: 8px 0 4px; color: #2f3740; }
.cm-e p { margin: 0 0 8px; }
.cm-h { font: bold 13px "Source Sans 3", "Source Sans 3 Fallback", Arial, sans-serif; letter-spacing: .5px; color: var(--gold); text-transform: uppercase; margin: 10px 0 4px; }
.cm-e .sc { font-variant: small-caps; }
.cm-note { font-size: 13px; color: var(--soft); }
@font-face { font-family: "Noto Sans Syriac"; src: local("Noto Sans Syriac"), local("NotoSansSyriac-Regular"), url("fonts/NotoSansSyriac-Regular.woff2") format("woff2"); font-display: swap; }
.cm-syr { margin: 2px 0 2px; font-family: "Estrangelo Edessa", "Noto Sans Syriac", serif; font-size: 22px; line-height: 1.7; color: var(--ink); text-align: right; unicode-bidi: isolate; overflow-wrap: anywhere; word-break: normal; }
.cm-ptr { margin: 0 0 4px; font-size: 13px; color: var(--soft); overflow-wrap: anywhere; }
.cm-pn2 { margin: 4px 0 2px; font-size: 13px; background: #f3f5f7; border-left: 3px solid #7fa9a4; padding: 4px 8px; }
.cm-pen { margin: 2px 0 4px; font-size: 15px; line-height: 1.45; overflow-wrap: anywhere; }
.cm-pel { display: block; font-size: 11px; letter-spacing: .03em; text-transform: uppercase; color: var(--soft); }
.cm-plab { font-weight: bold; color: #3f4852; }
.cm-pe { padding: 6px 10px; }
.cm-pe .cm-h { margin: 0; }
.cm-msg, .cm-src { color: var(--soft); font-style: italic; font-size: 14px; }
.cm-src { border-top: 1px solid var(--line); padding-top: 8px; margin-top: 10px; font-size: 12px; }
.cm-nl { display: block; font-weight: bold; color: #2f3740; margin: 8px 0 4px; }
#cm-note { width: 100%; box-sizing: border-box; font: inherit; font-size: 15px; padding: 8px; border: 1px solid var(--line); border-radius: var(--r-sm); resize: none; overflow: hidden; background: #ffffff; }
#cm-note:focus-visible { outline: 2px solid var(--gold); outline-offset: 1px; }
.cm-saved { min-height: 1.2em; margin: 2px 0; font-size: 12px; color: var(--soft); }
.cm-nlist { list-style: none; padding: 0; margin: 0; }
.cm-nlist li { padding: 4px 0; border-top: 1px solid #eef0f3; font-size: 14px; }
.cm-go { font: bold 13px "Source Sans 3", "Source Sans 3 Fallback", Arial, sans-serif; color: var(--gold); border: 1px solid var(--line); border-radius: var(--r-pill); background: #ffffff; padding: 0 8px; cursor: pointer; }
.cm-io { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 10px; }
.cm-ms { line-height: 0; }
.cm-m { font: bold 11px "Source Sans 3", "Source Sans 3 Fallback", Arial, sans-serif; color: var(--heb); background: none; border: 0; padding: 0 3px; margin-left: 1px; cursor: pointer; border-radius: 3px; vertical-align: baseline; }
.cm-m:hover, .cm-m:focus-visible { background: #e8eef7; text-decoration: underline; }
.cm-pn { font-size: 13px; line-height: 1; color: var(--gold); background: none; border: 0; padding: 0 3px; margin-left: 2px; cursor: pointer; border-radius: 3px; }
.cm-pn:hover, .cm-pn:focus-visible { background: #e8f3f2; }
.cm-h .cm-no { display: inline-block; min-width: 1.5em; text-align: center; font: bold 11px "Source Sans 3", "Source Sans 3 Fallback", Arial, sans-serif; color: #fff; background: var(--heb); border-radius: var(--r-pill); padding: 1px 4px; vertical-align: 1px; }
.cm-h .cm-ty { color: var(--soft); font-variant: small-caps; text-transform: none; letter-spacing: .4px; }
.cm-ref { font: bold 13px "Source Sans 3", "Source Sans 3 Fallback", Arial, sans-serif; letter-spacing: .3px; color: var(--heb); background: none; border: 0; padding: 0 2px; cursor: pointer; text-transform: none; text-decoration: underline; text-decoration-color: rgba(29, 78, 137, .35); text-underline-offset: 2px; }
.cm-ref:hover { text-decoration-color: currentColor; }
.cm-e.cur { box-shadow: inset 3px 0 0 var(--gold); }
@media (prefers-reduced-motion: reduce) { .cm-e.flash, .lu-v.cm-flash { animation: none; outline: 2px solid var(--gold); } }
@media (max-width: 640px) { .cm-m, .cm-pn { min-width: 28px; min-height: 28px; padding: 0 6px; } .cm-ref { min-height: 44px; } }
@media (forced-colors: active) { .cm-m, .cm-ref { color: LinkText; } .cm-h .cm-no { forced-color-adjust: none; background: Highlight; color: HighlightText; } }
#cm-tog[aria-expanded="true"] { background: #1f5f5a; color: #fff; border-color: #1f5f5a; }
@media (max-width: 640px) { #cm-tog { flex: 1 1 100%; min-height: 44px; } body.cm-open #cm { position: fixed; left: 0; right: 0; bottom: 0; height: 50vh; height: 50dvh; z-index: 20; border-radius: 14px 14px 0 0; box-shadow: 0 -6px 24px rgba(20, 28, 36, .3); } body.cm-open #lu-out { padding-bottom: 50vh; } .cm-top [role=tab], #cm-x, #cm-mod, .cm-go, .cm-io button { min-height: 44px; } }
@media (forced-colors: active) { .cm-e.on { outline: 2px solid Highlight; } .cm-top [role=tab][aria-selected="true"] { border-bottom-color: Highlight; } }
body.cm-hl-on #lu-out .lu-t,body.cm-hl-on #lu-out .lu-prt{cursor:cell}
.cm-hl{border:1px solid #ddd;border-radius:8px;padding:.5rem .6rem;margin:0 0 .8rem}
.cm-hlt{font-weight:600;font-size:.85rem;display:block;margin-bottom:.35rem}
.cm-hlcs{display:flex;flex-wrap:wrap;gap:.4rem}
.cm-hlc{width:32px;height:32px;border-radius:50%;border:2px solid rgba(0,0,0,.25);cursor:pointer;padding:0;font-size:1rem;background:#fff}
.cm-hlc[data-c="y"]{background:#ffe14d}
.cm-hlc[data-c="g"]{background:#7fd88a}
.cm-hlc[data-c="b"]{background:#86b8ff}
.cm-hlc[data-c="p"]{background:#ff9cc6}
.cm-hlc[data-c="o"]{background:#ffb35c}
.cm-hlc[data-c="v"]{background:#c4a0f0}
.cm-hlc[aria-pressed="true"]{border-color:#111;box-shadow:0 0 0 2px #fff,0 0 0 4px #111}
.cm-hlmsg{font-size:.85rem;margin:.45rem 0 0}
#cm-hlfoot{flex:none;border-top:2px solid #1a7f37;background:#f3fbf4;padding:6px 12px 8px;box-shadow:0 -4px 10px rgba(0,0,0,.06)}
#cm-hlfoot[hidden]{display:none}
/* (Greg 2026-10-22, Code Review round 3) the Apply bar always on screen: wide, while it is up it is fixed over the panel's column
   (.cm-hlfix, commentary.js hlFootFit), at the foot of the panel on screen, or compact (.cm-hlmini) in a gap clear of the headers and the
   panel's tabs, above the consent banner and under it in z-order. Narrow, the foot of the bottom sheet, clear of the phone's home bar. */
#cm-hlfoot{box-sizing:border-box;padding-bottom:calc(8px + env(safe-area-inset-bottom,0px))}
@media (max-width:640px){body.cm-open #gac{z-index:21;bottom:calc(12px + var(--hlfoot-h,0px))}}
@media (min-width:641px){body.cm-open #cm-hlfoot.cm-hlfix,body.cm-chap #cm-hlfoot.cm-hlfix{position:fixed;left:var(--hlf-l,auto);right:auto;width:var(--hlf-w,380px);bottom:var(--hlf-b,0px);z-index:14;border:1px solid var(--line);border-top:2px solid #1a7f37;border-radius:10px;box-shadow:0 -6px 18px rgba(20,28,36,.18)}#cm.cm-hlfix #cm-body{padding-bottom:calc(12px + var(--hlf-h,0px))}#cm-hlfoot.cm-hlmini{padding:5px 8px}#cm-hlfoot.cm-hlmini .cm-hlmsg{display:none}#cm-hlfoot.cm-hlmini .cm-hlgo{flex-wrap:nowrap;margin-top:0;gap:.3rem;overflow-x:auto}#cm-hlfoot.cm-hlmini .cm-hlgo button{white-space:nowrap;padding:.3rem .6rem;min-height:32px}#cm-hlfoot.cm-hlmini #cm-hl-ok{order:-1}}
#cm-hlfoot .cm-hlmsg b{font-size:15px}
#cm-hlfoot .cm-hlmsg{margin:0;font-size:14px;display:flex;align-items:center;gap:6px;flex-wrap:wrap}
.cm-hlsw{display:inline-block;width:18px;height:18px;border-radius:50%;border:1px solid rgba(0,0,0,.3);flex:none;text-align:center;line-height:16px;font-size:12px;background:#fff}
.cm-hlsw[data-c="y"]{background:#ffe14d}
.cm-hlsw[data-c="g"]{background:#7fd88a}
.cm-hlsw[data-c="b"]{background:#86b8ff}
.cm-hlsw[data-c="p"]{background:#ff9cc6}
.cm-hlsw[data-c="o"]{background:#ffb35c}
.cm-hlsw[data-c="v"]{background:#c4a0f0}
.cm-hlgo{display:flex;flex-wrap:wrap;gap:.4rem;margin-top:.4rem;align-items:center}
.cm-hl-ok{font-weight:700;background:#1a7f37;color:#fff;border:0;border-radius:6px;padding:.4rem .9rem;cursor:pointer;min-height:36px}
@media (max-width:700px),(pointer:coarse) { .cm-hlc{width:44px;height:44px} .cm-hl-ok,.cm-hlgo .xr-more{min-height:44px;min-width:44px} }
/* (moved with the rest, Greg 2026-10-16: the panel's scrolling box) */
::highlight(cm-ow-sel) { text-decoration: underline dotted #1f5f5a; text-decoration-thickness: 2px; text-underline-offset: 3px; background-color: rgba(31, 95, 90, .16); }
#cm-body:focus { outline: none; }
#cm-body::before, #cm-body::after { content: ""; display: block; height: var(--cm-pad, 0px); }
::highlight(cm-ow-hov) { text-decoration: underline dotted #1f5f5a; text-decoration-thickness: 2px; text-underline-offset: 3px; }
#cm-body { overflow-y: auto; overscroll-behavior: contain; padding: 0 12px 12px; font-size: 15px; line-height: 1.6; min-height: 0; flex: 1; }
body.cm-chap #cm-body { position: sticky; top: calc(var(--pinh, 52px) + var(--cm-hdh, 90px)); flex: none; max-height: calc(100vh - var(--pinh, 52px) - var(--cm-hdh, 90px) - 8px); max-height: calc(100dvh - var(--pinh, 52px) - var(--cm-hdh, 90px) - 8px); }
