.sidebar-news-topics { display:flex; flex-wrap:nowrap; gap:6px; overflow-x:auto; overscroll-behavior-x:contain; scrollbar-width:thin; scrollbar-color:#aac6b8 transparent; padding:0 0 8px; margin:0 0 10px; }
.sidebar-news-topics button { flex:0 0 auto; min-height:30px; padding:5px 10px; border:1px solid #c4d9ce; border-radius:7px; background:#e7f1ec; color:#517c6c; font:600 12px/1.3 system-ui,sans-serif; cursor:pointer; white-space:nowrap; }
.sidebar-news-topics button:hover { background:#d9e9e1; }
.sidebar-news-topics button[aria-pressed="true"] { background:#143562; border-color:#143562; color:#fff; }
.sidebar-news-topics button:focus-visible { outline:2px solid #3478b8; outline-offset:-2px; }
.sidebar-news .sidebar-news-status { margin:8px 0; color:#63758c; font:400 12px/1.5 system-ui,sans-serif; }
.sidebar-news-status[hidden] { display:none; }
.sidebar-news-status.is-error { color:#b42318; }
.sidebar-news-card { padding:10px 0; border-bottom:1px solid #e2e8f0; }
.sidebar-news-card:first-child { padding-top:0; }
.sidebar-news-card > a { display:flow-root; overflow:hidden; color:inherit; text-decoration:none; }
.sidebar-news-card img { float:left; width:210px; aspect-ratio:1.45; object-fit:cover; border-radius:8px; margin:0 10px 6px 0; }
.sidebar-news-copy { min-width:0; overflow-wrap:anywhere; }
#drawer-body .sidebar-news-card h3 { margin:2px 0 0; color:#253247; font:600 14px/1.3 system-ui,sans-serif; }
.sidebar-news-card a:hover h3 { color:#426d5d; text-decoration:underline; }
#drawer-body .sidebar-news .sidebar-news-meta { margin:0; color:#688178; font:400 10px/1.3 system-ui,sans-serif; }
#drawer-body .sidebar-news .sidebar-news-summary { margin:3px 0 0; color:#63758c; font:400 12.5px/1.45 system-ui,sans-serif; }
#drawer-body .sidebar-news .sidebar-news-credit { margin:18px 0 0; color:#7a8793; font:400 11px/1.5 system-ui,sans-serif; }
@media(max-width:460px) { .sidebar-news-card img { width:180px; } }

.sidebar-news [hidden] { display:none!important; }
.sidebar-news-read, .sidebar-news-back { border:1px solid #bfd4c9; border-radius:6px; background:#e7f1ec; color:#426d5d; font:600 12px/1.4 system-ui,sans-serif; padding:5px 9px; cursor:pointer; }
.sidebar-news-read { margin-top:8px; }
.sidebar-news-read:hover, .sidebar-news-back:hover { background:#d9e9e1; }
.sidebar-news-back { margin-bottom:18px; }
#drawer-body .sidebar-news-reader article > h3 { margin:4px 0 14px; font:600 19px/1.35 system-ui,sans-serif; color:#253247; }
.sidebar-news-reader-body { display:flow-root; }
.sidebar-news-reader-body img { float:left; width:210px; aspect-ratio:1.45; object-fit:cover; border-radius:8px; margin:0 12px 8px 0; }
.sidebar-news .sidebar-news-reader-body p { margin:0; color:#53647a; font:400 13px/1.65 system-ui,sans-serif; overflow-wrap:anywhere; }
.sidebar-news-original { display:inline-block; margin-top:18px; color:#426d5d; font:600 12px/1.4 system-ui,sans-serif; }
@media(max-width:460px) { .sidebar-news-reader-body img { width:180px; } }

.sidebar-shortcuts{position:relative;display:flex;justify-content:flex-end;gap:6px;margin:0 0 6px;padding:0;flex-shrink:0}
.sidebar-shortcuts:before{content:'';position:absolute;left:0;right:0;top:50%;height:1px;background:#ffffff35}
.sidebar-shortcuts button{position:relative;border:1px solid #ffffff50;background:var(--brand);color:#e2ece7;border-radius:20px;padding:3px 8px;font-size:10px;display:flex;align-items:center;gap:4px;white-space:nowrap}
.sidebar-shortcuts svg{width:13px;height:13px}
.readings-controls{display:flex;gap:10px;align-items:center;flex-wrap:nowrap;margin-bottom:20px;min-width:0}.readings-controls button{border:1px solid var(--border);background:var(--tint);border-radius:7px;padding:6px 9px}.readings-controls input{max-width:150px;border:1px solid var(--border);border-radius:7px;padding:6px;background:#fff;color:var(--ink)}
.readings-controls .readings-date{font:clamp(15px,1.8vw,24px)/1.3 Georgia,serif;margin:0;white-space:nowrap;min-width:0}.readings-controls button{flex-shrink:0}.prayer-space .readings-controls{gap:8px}#drawer .readings-date{font-size:16px}.reading-entry{border-top:1px solid var(--border);padding:20px 0}.reading-entry h3{font:23px Georgia,serif;margin:8px 0}.reading-entry p{white-space:pre-line;font-size:14px;line-height:1.8}.reading-credit{font-size:11px;color:var(--muted);margin-top:18px}.reading-credit a{text-decoration:underline}

.reading-audio{display:flex;flex-wrap:wrap;gap:7px;margin:12px 0}.reading-audio button{background:var(--tint);border:1px solid var(--border);border-radius:7px;padding:6px 12px;font-size:12px;color:var(--brand)}.reading-audio button:disabled{cursor:default;opacity:.5}

.speech-settings{display:flex;gap:12px;flex-wrap:wrap;margin:0 0 18px}.speech-settings label{display:flex;gap:6px;align-items:center;color:var(--muted);font-size:11px}.speech-settings select{max-width:190px;padding:5px;border:1px solid var(--border);border-radius:6px;background:#fff;color:var(--ink);font-size:11px}
.prayer-tabs{display:flex;gap:8px;border-bottom:1px solid var(--border);padding-bottom:12px;margin-bottom:20px;flex-wrap:wrap}.prayer-tabs button{background:var(--tint);border:1px solid var(--border);color:var(--brand);border-radius:9px;padding:10px 14px;font-size:13px;font-weight:550}.prayer-tabs button[aria-selected=true]{background:var(--brand);border-color:var(--brand);color:#fff}.prayer-tab-panel[hidden],.form [hidden]{display:none!important}.prayer-community-intro{display:flex;justify-content:space-between;align-items:flex-start;gap:18px;margin:8px 0 24px;flex-wrap:wrap}.prayer-community-intro h2{font:28px Georgia,serif;margin-bottom:8px}.prayer-community-intro p{color:var(--muted);font-size:13px;max-width:620px}.community-prayer{display:flex;gap:12px;border-top:1px solid var(--border);padding:22px 0}.prayer-avatar{width:30px;height:30px;flex-shrink:0;border-radius:50%;display:grid;place-items:center;background:var(--tint);color:var(--muted);margin-top:2px}.prayer-avatar svg{width:18px;height:18px;stroke-width:1.5}.prayer-contribution{min-width:0;flex:1}.prayer-item-top{display:flex;gap:12px;align-items:center;justify-content:space-between;flex-wrap:wrap}.prayer-item-top h3{font:23px Georgia,serif}.prayer-message{white-space:pre-line;overflow-wrap:anywhere;font-size:14px;line-height:1.8;margin:10px 0}.prayer-signature,#drawer-body .prayer-signature{font-size:11px;color:var(--muted);margin:8px 0 0}.prayer-demo{font-size:9px;white-space:nowrap}.prayer-actions{display:flex;gap:10px;margin-top:12px}.prayer-actions button{font-size:11px;border:1px solid var(--border);background:#fff;border-radius:6px;color:var(--brand);padding:5px 9px}#drawer-body .prayer-message{margin:10px 0}#drawer-body .prayer-item-top h3{margin-bottom:0;font-size:22px}@media(max-width:700px){.prayer-tabs{gap:6px}.prayer-tabs button{font-size:11px;padding:9px 10px}.prayer-community-intro .btn{width:100%}.prayer-item-top h3{font-size:21px}.prayer-message{font-size:13px}}

@media(max-width:700px){.prayer-space .readings-controls{gap:5px}.readings-controls button{font-size:13px;padding:5px 7px}.readings-controls .readings-date,#drawer .readings-date{font-size:14px}}

/* La fascia introduttiva mantiene la stessa misura nelle due linguette. */
.prayer-space{--prayer-toolbar-height:160px;--prayer-toolbar-background:#fff}
.prayer-space .prayer-tabs{margin-bottom:0}
.prayer-toolbar,.prayer-community-intro{box-sizing:border-box;min-height:var(--prayer-toolbar-height);padding:20px;background:var(--prayer-toolbar-background);border-bottom:1px solid var(--border);margin:0}
.prayer-toolbar{display:flex;flex-direction:column;justify-content:center;gap:18px}
.prayer-toolbar .speech-settings,.prayer-toolbar .readings-controls{margin:0}
.prayer-community-intro{align-items:center;flex-wrap:nowrap}
.prayer-community-intro>div{flex:1;min-width:0}
.prayer-community-intro p{line-height:1.65;margin:0}
.prayer-compose-action{flex-shrink:0}
.prayer-space .reading-entry:first-of-type,.community-prayer:first-child{border-top:0}
#drawer .prayer-space{--prayer-toolbar-height:240px}
#drawer .prayer-community-intro{flex-direction:column;align-items:stretch;justify-content:center;gap:14px}
#drawer .prayer-community-intro>div{flex:0}
@media(max-width:700px){
 .prayer-space{--prayer-toolbar-height:240px}
 .prayer-toolbar,.prayer-community-intro{padding:16px}
 .prayer-community-intro{flex-direction:column;align-items:stretch;justify-content:center;gap:14px}
 .prayer-community-intro>div{flex:0}
 .prayer-community-intro h2{font-size:25px}
}

.prayer-space{container-type:inline-size}
.readings-controls [data-reading-step],.reading-calendar{width:32px;height:32px;display:inline-flex;align-items:center;justify-content:center;flex-shrink:0;border:1px solid var(--border);border-radius:50%;background:#fff;color:#111;padding:0}
.readings-controls [data-reading-today]{background:#fff;color:#111}
.readings-controls svg{width:17px;height:17px;fill:none;stroke:currentColor;stroke-width:1.8;stroke-linecap:round;stroke-linejoin:round}
.reading-calendar{position:relative;overflow:hidden;cursor:pointer}
.reading-calendar input[type=date]{position:absolute;inset:0;width:100%;height:100%;opacity:0;cursor:pointer;max-width:none;padding:0;border:0}
.reading-calendar input::-webkit-calendar-picker-indicator{position:absolute;inset:0;width:auto;height:auto;cursor:pointer}
.reading-calendar:focus-within{outline:2px solid var(--brand);outline-offset:2px}
@container(max-width:650px){
 .prayer-toolbar,.prayer-community-intro{min-height:240px}
 .prayer-community-intro{flex-direction:column;align-items:stretch;justify-content:center;gap:14px}
 .prayer-community-intro>div{flex:0}
}
@container(max-width:380px){
 .prayer-toolbar{padding:16px 10px}
 .prayer-space .readings-controls{gap:4px}
 .readings-controls .readings-date,#drawer .readings-date{font-size:12px}
 .readings-controls [data-reading-step],.reading-calendar{width:28px;height:28px}
 .readings-controls [data-reading-today]{font-size:12px;padding:5px 6px}
}

#drawer:has(.prayer-readings-only) .drawer-heading{padding:16px 20px;align-items:center}
#drawer:has(.prayer-readings-only) .drawer-heading .eyebrow{display:none}
#drawer:has(.prayer-readings-only) .drawer-heading h2{font-size:24px;margin:0}
#drawer:has(.prayer-readings-only) #drawer-body{padding:16px 20px}
#drawer .prayer-readings-only .prayer-toolbar{min-height:0;padding:16px 12px;gap:12px}
#drawer .prayer-readings-only .speech-settings{gap:8px}
#drawer .prayer-readings-only .speech-settings label{gap:4px}

/* Comandi prima del titolo, direttamente sulla superficie bianca. */
.section-toolbar{box-sizing:border-box;display:flex;flex-direction:column;align-items:flex-start;gap:12px;padding:0 0 16px;background:#fff;text-align:left}
.section-toolbar h2{font:28px/1.15 Georgia,serif;letter-spacing:-.6px;margin:0}
.section-toolbar .button-row{width:100%;margin:0;gap:8px;justify-content:flex-start;align-items:flex-start}
.section-toolbar .btn{padding:8px 12px;font-size:11px}
.section-toolbar .btn.secondary{background:#fff}
@media(max-width:700px){.section-toolbar h2{font-size:26px}}

/* La pagina Preghiera usa la stessa intestazione delle altre sezioni. */
.prayer-page>.section-toolbar-host .prayer-tabs{border:0;padding:0;margin:0;gap:8px}
.prayer-page>.section-toolbar-host .prayer-tabs button{font-size:11px;font-weight:550;padding:8px 12px;border-radius:9px}
.prayer-page>.section-toolbar-host .prayer-tabs button[aria-selected=false]{background:#fff;border-color:var(--border);color:var(--brand)}
.prayer-page>.section-toolbar-host .prayer-tabs button[aria-selected=true]{background:var(--brand);border-color:var(--brand);color:#fff}
.prayer-page>.prayer-tab-panel .prayer-toolbar{min-height:0;background:#fff;padding:20px 0;gap:18px}
.prayer-page>.prayer-tab-panel .prayer-community-intro{min-height:0;background:#fff;padding:20px 0;gap:18px}

.prayer-page>.prayer-tab-panel .prayer-community-intro{position:relative;display:block;padding-right:54px}
.prayer-page .prayer-community-intro .prayer-compose-action{position:absolute;right:0;top:20px}
.prayer-add{display:grid;place-items:center;width:36px;height:36px;border-radius:50%;border:1px solid #dce3d4;background:#edf1e7;color:var(--brand);cursor:pointer;padding:0}
.prayer-add svg{width:20px;height:20px;fill:none;stroke:currentColor;stroke-width:1.8;stroke-linecap:round}
.prayer-add:hover{background:#e1e8d8}
.prayer-add:focus-visible{outline:2px solid var(--brand);outline-offset:3px}

.page-heading:has(.speech-settings){flex-wrap:wrap;align-items:center;gap:8px 16px}.page-heading .speech-settings{margin:0 0 0 auto;justify-content:flex-end;gap:8px}.page-heading .speech-settings select{max-width:220px}.page-heading .speech-settings select[data-speech-rate]{max-width:150px}

.page-heading .prayer-compose-action{margin-left:16px;align-self:flex-start}.page-heading .prayer-add{background:#edf1e7;border-color:#dce3d4;color:#315c46}.page-heading .prayer-add:hover{background:#e1e8d8}

/* Sfondo ampio e tenue sul lato destro di letture e preghiere. */
.prayer-page :is(.readings-surface,.community-prayers){position:relative;isolation:isolate;background:#fff}
.prayer-page :is(.readings-surface,.community-prayers)::before{content:"";position:absolute;z-index:-1;pointer-events:none;inset:0;background:var(--reading-background,url('prayer-header-pencil.png')) right top/140% auto no-repeat;opacity:.38;mask-image:linear-gradient(to right,transparent 55%,#000 78%)}
@media(max-width:700px){.prayer-page :is(.readings-surface,.community-prayers)::before{background-size:200% auto;opacity:.28;mask-image:linear-gradient(to right,transparent 35%,#000 80%)}}

/* Giorno della settimana della data consultata: domenica=0, sabato=6. */
.prayer-page .readings-surface[data-weekday="0"]{--reading-background:url('prayer-sunday-pencil.png')}
.prayer-page .readings-surface[data-weekday="1"]{--reading-background:url('prayer-monday-pencil.png')}
.prayer-page .readings-surface[data-weekday="2"]{--reading-background:url('prayer-tuesday-pencil.png')}
.prayer-page .readings-surface[data-weekday="3"]{--reading-background:url('prayer-wednesday-pencil.png')}
.prayer-page .readings-surface[data-weekday="4"]{--reading-background:url('prayer-thursday-pencil.png')}
.prayer-page .readings-surface[data-weekday="5"]{--reading-background:url('prayer-friday-pencil.png')}
.prayer-page .readings-surface[data-weekday="6"]{--reading-background:url('prayer-header-pencil.png')}

/* Le tue preghiere: una persona in preghiera nella propria casa. */
.prayer-page .community-prayers{--reading-background:url('prayer-at-home-pencil.png')}

/* Le letture condividono un unico sfondo dalla linea sopra la data al testo. */
.prayer-page .readings-surface{margin-top:-12px;padding-top:12px}
.prayer-page .readings-surface .prayer-toolbar{background:transparent}
.prayer-page .readings-surface::before{background-size:170% auto}
@media(max-width:700px){.prayer-page .readings-surface::before{background-size:240% auto}}
