#novenas{scroll-margin-top:24px}
#novenas .tgbgn-dates{color:#6c5e42;font-weight:600;line-height:1.5}
#novenas .tgbgn-dates small{font-weight:400;font-size:.9em}
#novenas .tgbgn-count{color:#18364c;font-weight:600;margin:.9rem 0}
#novenas [data-novena-open]{text-align:left}
#novenas .tgbgn-dialog{box-sizing:border-box;width:min(820px,calc(100% - 24px));max-height:calc(100dvh - 32px);padding:24px;border:1px solid #c9ab68;border-radius:18px;background:#fffaf0;color:#18364c;overflow:auto;font:16px/1.6 Arial,Helvetica,sans-serif}
#novenas .tgbgn-dialog::backdrop{background:rgba(12,32,49,.6)}
#novenas .tgbgn-dialog-head{display:flex;align-items:flex-start;justify-content:space-between;gap:16px;border-bottom:1px solid #dfd0ab;padding-bottom:14px}
#novenas .tgbgn-dialog-head h2{font:700 28px/1.2 Georgia,serif;margin:0}
#novenas [data-novena-close]{flex-shrink:0;padding:8px 14px;border:1px solid #a9873e;border-radius:24px;background:#fff;color:#18364c;font-size:16px;cursor:pointer}
#novenas .tgbgn-year{display:flex;flex-wrap:wrap;align-items:center;justify-content:space-between;gap:12px;margin:20px 0}
#novenas .tgbgn-year label{display:flex;align-items:center;gap:10px}
#novenas .tgbgn-year select{font:inherit;padding:6px 10px;background:#fff;border:1px solid #c9ab68;border-radius:6px;width:auto}
#novenas .tgbgn-year p{margin:0;font-weight:600}
#novenas .tgbgn-days{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px;list-style:none;padding:0;margin:0}
#novenas .tgbgn-days li{display:flex;align-items:center;justify-content:space-between;gap:12px;padding:14px;border:1px solid #dfd0ab;border-radius:10px;background:#fff;min-width:0}
#novenas .tgbgn-day-label{display:block;font-weight:700}
#novenas .tgbgn-day-label span{display:block;font-size:14px;font-weight:400;color:#6c5e42}
#novenas .tgbgn-days a{color:#204733;text-decoration:underline;text-underline-offset:3px}
#novenas .tgbgn-check{display:flex;align-items:center;gap:8px;cursor:pointer;font-size:15px;white-space:nowrap;min-height:44px}
#novenas .tgbgn-check input{width:20px;height:20px;accent-color:#18364c;cursor:pointer}
#novenas .tgbgn-storage,#novenas .tgbgn-source{font-size:14px;line-height:1.55}
#novenas a:focus-visible,#novenas button:focus-visible,#novenas select:focus-visible,#novenas input:focus-visible{outline:2px solid #a9873e;outline-offset:4px}
@media(max-width:600px){#novenas .tgbgn-dialog{padding:18px}#novenas .tgbgn-dialog-head h2{font-size:24px}#novenas .tgbgn-days{grid-template-columns:minmax(0,1fr)}}

/* Clear, high-contrast prayer-card action. */
#novenas .tgbgn-card>button[data-novena-open]{background:#18364c!important;color:#fff!important;border:1px solid #a9873e!important;border-radius:999px;padding:12px 18px;font:600 16px/1.45 Arial,Helvetica,sans-serif!important;text-align:center;text-decoration:none;cursor:pointer}
#novenas .tgbgn-card>button[data-novena-open]:hover{background:#0c283e!important;color:#fff!important}
/* Keep the navigation on the right side of the existing hero image. */
@media(min-width:768px){body .tgbgc-prayer-hero .tgbgc-prayer-nav{left:20px!important;right:20px!important;bottom:8px!important;width:auto!important;display:flex!important;flex-wrap:nowrap!important;justify-content:flex-end!important;gap:10px!important}body .tgbgc-prayer-hero .tgbgc-prayer-nav>*{white-space:nowrap!important;flex:0 0 auto!important}}
@media(min-width:768px) and (max-width:1100px){body .tgbgc-prayer-hero .tgbgc-prayer-nav{gap:6px!important}body .tgbgc-prayer-hero .tgbgc-prayer-nav>*{font-size:clamp(11px,1.1vw,14px)!important;padding:10px 9px!important}}

#novenas .tgbgn-intention{margin:20px 0 24px;padding:18px;border:1px solid #dfd0ab;border-radius:12px;background:#fff}
#novenas .tgbgn-intention>label{display:block;font-weight:700;margin-bottom:8px}
#novenas .tgbgn-intention>label span{font-weight:400;font-size:.9em}
#novenas .tgbgn-intention textarea{box-sizing:border-box;width:100%;min-height:100px;padding:12px;border:1px solid #b9a16b;border-radius:8px;color:#18364c;background:#fffaf0;font:16px/1.5 Arial,Helvetica,sans-serif;resize:vertical}
#novenas .tgbgn-privacy{font-size:14px;line-height:1.55;margin:10px 0 14px}
#novenas .tgbgn-intention-actions{display:flex;flex-wrap:wrap;gap:10px}
#novenas .tgbgn-intention-actions button{padding:10px 14px;border:1px solid #a9873e;border-radius:24px;color:#18364c!important;background:#fffaf0!important;font:600 14px/1.4 Arial,Helvetica,sans-serif;cursor:pointer}
#novenas .tgbgn-intention-actions [data-intention-save]{background:#18364c!important;color:#fff!important}
#novenas .tgbgn-intention-status{font-size:14px;line-height:1.45;margin:10px 0 0;min-height:1.45em}
#novenas .tgbgn-intention textarea:focus-visible{outline:2px solid #a9873e;outline-offset:3px}

/* Separate Novenas from the Manual of Prayers. */
#novenas{border-bottom:1px solid #c9ab68;padding-bottom:48px;margin-bottom:48px}

body #novenas.tgbgc-prayer-section{border-bottom:1px solid #c9ab68!important;padding-bottom:48px!important;margin-bottom:48px!important}

/* Collection browsing, scoped to Novenas. */
#novenas [hidden]{display:none!important}
#novenas .tgbgn-browse{max-width:1000px;margin:24px auto 32px;text-align:left}
#novenas .tgbgn-collections{display:flex;gap:10px;flex-wrap:wrap;margin-bottom:20px}
#novenas .tgbgn-collections button{border:1px solid #a9873e;border-radius:999px;background:#fffaf0;color:#18364c;padding:10px 18px;font:600 16px/1.4 Arial,Helvetica,sans-serif;cursor:pointer}
#novenas .tgbgn-collections button[aria-pressed=true]{background:#18364c;color:#fff}
#novenas .tgbgn-search-row{display:grid;grid-template-columns:2fr 1fr;gap:18px}
#novenas .tgbgn-search-row label{font-weight:600;color:#18364c}
#novenas .tgbgn-search-row input,#novenas .tgbgn-search-row select{box-sizing:border-box;display:block;width:100%;margin-top:6px;min-height:46px;border:1px solid #b9a16b;border-radius:8px;background:#fff;color:#18364c;padding:10px 12px;font:16px/1.4 Arial,Helvetica,sans-serif}
#novenas .tgbgn-browse-note,#novenas [data-novena-results]{font:14px/1.6 Arial,Helvetica,sans-serif;color:#5e5b50;margin:14px 0 0}
#novenas .tgbgn-card>h3{font-size:clamp(24px,2.2vw,32px);line-height:1.25}
#novenas .tgbgn-card .tgbgn-dates{font-size:15px}
#novenas .tgbgn-card{min-width:0}
#novenas .tgbgn-source-button{display:inline-block;padding:10px 16px;border:1px solid #a9873e;border-radius:24px;color:#18364c;background:#fff;text-decoration:underline;text-underline-offset:3px;font-weight:600}
#novenas .tgbgn-dialog-head{position:sticky;top:-24px;background:#fffaf0;z-index:1;padding-top:14px}
@media(max-width:600px){#novenas .tgbgn-search-row{grid-template-columns:1fr}#novenas .tgbgn-dialog-head{top:-18px}#novenas .tgbgn-collections{gap:8px}#novenas .tgbgn-collections button{padding:9px 12px;font-size:14px}}

/* Reserve two title lines and anchor actions to the card bottom. */
#novenas [data-novena-grid]{align-items:stretch}
#novenas .tgbgn-card{display:flex!important;flex-direction:column!important}
#novenas .tgbgn-card>h3{min-height:2.5em}
#novenas .tgbgn-card>.tgbgn-count{margin-top:auto!important;padding-top:16px}
#novenas .tgbgn-card>button[data-novena-open]{width:100%;margin-bottom:0!important;flex-shrink:0}

#novenas .tgbgn-card[hidden]{display:none!important}
