/* v0.7 app shell: fixed, safe-area-aware navigation; no change to the audio elements. */
:root{--nav-height:76px;--shell-max:540px}
[hidden]{display:none!important}
body{min-height:100vh;min-height:100dvh;background:var(--paper)}
main{max-width:var(--shell-max);padding:calc(14px + env(safe-area-inset-top)) 17px calc(var(--nav-height) + 20px + env(safe-area-inset-bottom));margin:auto}
.app-view{min-width:0;animation:appear .16s ease-out}@keyframes appear{from{opacity:.6}to{opacity:1}}@media(prefers-reduced-motion:reduce){.app-view{animation:none}}
.app-brand{gap:11px;margin:0 0 15px}.app-brand .brand-icon{width:57px;height:57px;border-radius:13px}.app-brand h1{font:600 clamp(20px,5.3vw,25px)/1.08 Georgia,serif;letter-spacing:-.02em}.app-brand .brand-reference{font-size:9px;margin-bottom:3px}.app-brand p{font:italic 12px/1.28 Georgia,serif;margin-top:4px}
.player{padding:18px 17px 15px;border-radius:23px}.player h2{font-size:clamp(30px,8.7vw,39px);margin:8px 0 4px}.player .version-select{min-height:44px;margin-top:5px;padding:7px 11px;font-size:14px}.player .sub{font-size:12px;margin:4px 0 12px}.player .timeline{margin:0 0 13px}.player .timeline input{height:26px}.player .mainbtn{min-height:64px;font-size:18px;border-radius:15px}.controls{gap:8px;margin-top:9px}.controls button{min-height:47px;font-size:14px}.ambient-select{margin-top:8px;min-height:45px;padding:7px 10px;font-size:13px}.ambient-label{gap:6px}.ambient-label svg{width:19px;height:19px}.player .next{padding-top:12px;margin-top:12px;font-size:14px}.status{font-size:12px;min-height:0;margin:10px 2px 0;line-height:1.4}.status:empty{display:none}
.listen-quick{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:7px;margin-top:10px}.listen-quick button,.listen-quick a{display:flex;align-items:center;justify-content:center;text-align:center;border:1px solid var(--line);border-radius:12px;min-height:44px;padding:6px;font-size:12px;font-weight:600;text-decoration:none;color:var(--ink);margin:0;background:#fffefa}.listen-quick button:active,.listen-quick a:active{background:#ede7db}.return-box{margin:10px 0 0}.return-box button{min-height:44px}
.app-nav{position:fixed;z-index:10;bottom:0;left:50%;transform:translateX(-50%);width:100%;max-width:var(--shell-max);display:grid;grid-template-columns:repeat(5,minmax(0,1fr));align-items:end;min-height:var(--nav-height);padding:3px 7px calc(5px + env(safe-area-inset-bottom));background:#fffefa;border-top:1px solid #dedcd4;box-shadow:0 -7px 24px #1029450a;border-radius:18px 18px 0 0}
.app-tab{background:transparent;border:0;border-radius:12px;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:4px;min-width:0;min-height:57px;padding:5px 0;color:#687585;font-size:10.5px;font-weight:600;white-space:nowrap}.app-tab svg{width:23px;height:23px}.app-tab[aria-current=page]{color:var(--ink);background:#f0ede5}.app-tab[aria-current=page] span{font-weight:750}.app-tab:active{background:#ece8de}.note-tab{color:var(--ink);font-weight:700;gap:3px}.note-icon{width:43px;height:43px;display:grid;place-items:center;border-radius:50%;background:var(--accent);color:#fff;box-shadow:0 2px 6px #10294525;border:1px solid #bc995a}.note-icon svg{width:23px;height:23px;stroke:#f5d58d}.note-tab:active .note-icon{background:#254c6f}
.view-heading{padding:8px 2px 15px}.view-heading h2{font:500 33px/1.1 Georgia,serif;margin:6px 0}.view-heading .eyebrow{margin:0;font-size:10px}.view-description{margin:6px 0 0;font-size:13px;line-height:1.4;color:var(--muted)}.view-links{display:grid;grid-template-columns:1fr 1fr;gap:8px}.view-links button{display:flex;align-items:center;justify-content:center;gap:7px;font-size:13px;min-height:47px;padding:7px}.view-links svg{width:19px;height:19px}.journey-progress{margin-top:12px;padding:16px 15px;border-radius:20px}.journey-progress h3{font-size:21px}.journey-intro{font-size:11px;margin-bottom:12px}.progress-item+.progress-item{margin-top:12px;padding-top:12px}.progress-item .start-testament{margin-top:7px;min-height:44px}.progress-detail{font-size:12px}.progress-head{font-size:14px}.journey-bar{margin-top:7px}
.history-tabs{display:grid;grid-template-columns:1fr 1fr;gap:4px;border:1px solid var(--line);background:#ece8de;padding:4px;border-radius:14px;margin-bottom:12px}.history-tabs button{min-height:44px;border:0;border-radius:10px;background:transparent;color:var(--muted);font-size:14px}.history-tabs button[aria-pressed=true]{background:#fffefa;color:var(--ink);box-shadow:0 1px 4px #10294510}
.inline-pane[open]{position:static;inset:auto;margin:0;width:100%;max-width:none;max-height:none;overflow:visible;padding:15px;border-radius:18px;background:var(--white);border:1px solid var(--line)}.inline-pane:not([open]){display:none}.inline-pane .note{margin:0 0 12px;font-size:13px}.inline-pane .privacy{margin-bottom:0}
.more-list{display:grid;gap:9px}.more-list button{width:100%;text-align:left;padding:13px 15px;min-height:50px;font-size:15px;display:flex;align-items:center;justify-content:space-between;margin:0}.more-action span{font-size:22px;color:var(--muted)}.more-list #refreshStatus:empty{display:none}.foot{margin-top:24px}.foot strong{font:600 19px Georgia,serif;color:var(--ink)}
#extraStatus{margin:9px 0 0;padding:9px 12px;background:#eeeadf;border-radius:10px;font-size:12px}#extraStatus[hidden]{display:none}
/* Voice notes and settings use modal sheets; scrolling is for content, not navigation. */
dialog:not(.inline-pane){max-height:calc(100dvh - 24px - env(safe-area-inset-top) - env(safe-area-inset-bottom));padding:19px 18px;overscroll-behavior:contain}dialog .close{min-width:44px;min-height:44px}.record-sheet[open]{position:fixed;inset:auto 0 0;margin:0 auto;max-width:var(--shell-max);width:100%;border-radius:25px 25px 0 0;padding:20px 20px calc(22px + env(safe-area-inset-bottom));box-shadow:0 -10px 38px #071a3433}.record-sheet .dialog-head{margin-bottom:10px}.record-reference{font-weight:700;color:var(--ink);font-size:17px;line-height:1.45;margin:6px 0 12px;background:#f2ede2;padding:12px;border-radius:12px}.record-sheet .record-button{min-height:65px;font-size:19px}.record-details{margin-top:16px;border-top:1px solid var(--line);padding-top:8px}.record-details summary{font-size:14px;font-weight:600;cursor:pointer;min-height:44px;display:list-item;align-content:center}.record-details input{font-size:16px}.record-sheet .privacy{margin-bottom:0}
@media(max-height:720px){main{padding-top:calc(9px + env(safe-area-inset-top))}.app-brand{margin-bottom:10px}.app-brand .brand-icon{width:48px;height:48px}.player{padding:14px 15px 12px}.player h2{font-size:32px;margin-top:5px}.player .sub{margin-bottom:7px}.player .timeline{margin-bottom:9px}.player .mainbtn{min-height:57px}.player .next{padding-top:9px;margin-top:9px}.status{margin-top:8px}.listen-quick{margin-top:8px}}
@media(max-width:350px){main{padding-left:12px;padding-right:12px}.app-brand h1{font-size:20px}.app-brand p{font-size:11px}.app-brand .brand-icon{width:44px;height:44px}.app-tab{font-size:10px}.listen-quick{gap:5px}}
@media(min-width:700px){main{padding-top:26px}.app-brand .brand-icon{width:64px;height:64px}.app-brand h1{font-size:28px}.app-nav{border:1px solid var(--line);border-bottom:0}}

.ambient-volume{gap:8px}.ambient-volume button{flex:0 0 44px;min-width:44px;min-height:44px;padding:4px;font-size:24px;line-height:1}.ambient-volume button:disabled{opacity:.4}.ambient-volume input{flex:1;min-width:0;width:auto}.ambient-volume output{min-width:40px}
