/* E-QURAN collection pages V13 — scoped to .hd-layout only; central header/footer untouched. */
.hd-layout.hd-lib .hd-lib-hero{border-top:3px solid var(--hd-gold);}
.hd-layout .hd-lib-chapters{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:11px}
.hd-layout .hd-lib-chapter{display:flex;align-items:center;gap:13px;min-width:0;text-decoration:none;color:var(--hd-text);padding:16px;border:1px solid var(--hd-line);border-radius:12px;background:var(--hd-card);transition:box-shadow .15s,border-color .15s}
.hd-layout .hd-lib-chapter:hover,.hd-layout .hd-lib-chapter:focus-visible{border-color:var(--hd-gold);box-shadow:0 3px 15px #0000000b}
.hd-layout .hd-lib-chapter>span:nth-child(2){flex:1;min-width:0}
.hd-layout .hd-lib-chapter strong,.hd-layout .hd-lib-chapter small{display:block}
.hd-layout .hd-lib-chapter strong{font-size:.9rem;line-height:1.7}
.hd-layout .hd-lib-chapter small{color:var(--hd-muted);font-size:.78rem;margin-top:4px}
.hd-layout .hd-lib-chapter-ico{display:grid;place-items:center;flex-shrink:0;width:41px;height:41px;color:var(--hd-primary);background:var(--hd-mint);border-radius:11px}
.hd-layout .hd-page-number{padding:12px;color:var(--hd-text);font-weight:700;white-space:nowrap}
.hd-layout .hd-lib-list .hd-num{font-size:.75rem;text-align:center}
.hd-layout .hd-lib-list .hd-snippet{unicode-bidi:plaintext}
.hd-layout .hd-lib-matn-box .hd-matn{white-space:normal;overflow-wrap:anywhere}
.hd-layout .hd-lib-home-callout{margin:17px 0}
.hd-layout .hd-lib-home-callout>p{line-height:1.8;color:var(--hd-muted)}
.hd-layout .hd-lib-reader-heading h1{max-width:45ch}
@media(max-width:680px){.hd-layout .hd-lib-chapters{grid-template-columns:1fr}.hd-layout .hd-lib-chapter{padding:14px 12px}.hd-layout .hd-page-number{width:100%;text-align:center}.hd-layout .hd-lib-panel{padding:14px}}
@media(prefers-reduced-motion:reduce){.hd-layout .hd-lib-chapter{transition:none}}

/* V13.1 - mobile clarity and premium reading controls: no unrelated styles */
.hd-layout .hd-premium-search{margin:0 0 18px;padding:clamp(17px,3vw,24px)}
.hd-layout .hd-portal-section{margin-bottom:18px}
.hd-layout .hd-portal-section .hd-mini-grid{gap:12px}
.hd-layout .hd-localnav{scrollbar-width:auto}
.hd-layout .hd-localnav a[aria-current=page]{border-color:var(--hd-gold);font-weight:900}
.hd-layout .hd-cta-row .hd-btn-main,.hd-layout .hd-search-inline .hd-btn-main{box-shadow:0 4px 14px rgba(8,69,45,.12)}
.hd-layout .hd-premium-search input{min-width:0}
.hd-layout .hd-lib-reader .hd-reading-toolbar{position:relative;z-index:1}
.hd-layout .hd-lib-reader .hd-matn{overflow-wrap:anywhere}
@media(max-width:680px){
 .hd-layout .hd-localnav{display:grid!important;grid-template-columns:repeat(5,minmax(0,1fr))!important;gap:3px!important;overflow:visible!important;padding:3px 0 8px!important}
 .hd-layout .hd-localnav a{display:flex!important;flex-direction:column!important;align-items:center!important;justify-content:center!important;text-align:center!important;font-size:.62rem!important;gap:3px!important;padding:8px 1px!important;min-height:57px!important;min-width:0!important;line-height:1.3!important;white-space:normal!important}
 .hd-layout .hd-localnav a .hd-icon{width:17px!important;height:17px!important;flex-shrink:0}
 .hd-layout .hd-portal-section .hd-mini-grid{grid-template-columns:repeat(2,minmax(0,1fr))!important;gap:9px}
 .hd-layout .hd-portal-section .hd-card{min-width:0}
 .hd-layout .hd-reading-toolbar{margin:0!important}
 .hd-layout .hd-premium-search .hd-search-inline{display:flex;min-width:0}
 .hd-layout .hd-premium-search .hd-search-inline input{flex:1;min-width:0}
 .hd-layout .hd-premium-search .hd-search-inline button{flex:none}
}
@media(max-width:350px){.hd-layout .hd-localnav a{font-size:.58rem!important}.hd-layout .hd-localnav a .hd-icon{width:15px!important}}

/* V14 — scoped context, no header/footer or global resets */
.hd-layout .hd-v14-related,.hd-layout .hd-v14-feature{margin-block:16px}
.hd-layout .hd-v14-related .hd-panel-head{margin-bottom:12px}
.hd-layout .hd-v14-relgrid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:10px}
.hd-layout .hd-v14-rel{display:flex;align-items:flex-start;gap:10px;min-width:0;padding:14px;border-radius:13px;text-decoration:none;background:var(--hd-card,transparent);border:1px solid var(--hd-border,#d6e4de);color:inherit}
.hd-layout .hd-v14-rel svg{flex:none;margin-top:3px}
.hd-layout .hd-v14-rel strong{display:block;line-height:1.65;overflow-wrap:anywhere}
.hd-layout .hd-v14-rel small{display:block;margin-top:6px;opacity:.82}
.hd-layout .hd-v14-kicker{font-weight:700;margin:14px 0 6px}
.hd-layout .hd-v14-chips{display:flex;flex-wrap:wrap;gap:9px;align-items:center;margin-block:10px}
.hd-layout .hd-v14-chips a{display:inline-flex;align-items:center;justify-content:center;border:1px solid var(--hd-border,#b2c9bb);border-radius:12px;padding:9px 13px;text-decoration:none;color:inherit;font-size:.89rem;font-weight:750;min-height:42px;background:transparent}
.hd-layout .hd-v14-chips a:hover,.hd-layout .hd-v14-chips a:focus-visible,.hd-layout .hd-v14-rel:hover{outline:2px solid var(--hd-gold,#c6a665);outline-offset:1px}
.hd-layout .hd-v14-count{font-size:.85rem;font-weight:700;line-height:1.6;white-space:normal}
.hd-layout .hd-v14-search-guide{padding:15px 0;margin:10px 0}
.hd-layout .hd-v14-search-guide p{font-size:.88rem;opacity:.85;line-height:1.75}
.hd-layout .hd-v14-pages{display:flex;align-items:center;justify-content:center;flex-wrap:wrap;gap:10px;margin-top:22px}
@media(max-width:680px){.hd-layout .hd-v14-relgrid{grid-template-columns:1fr}.hd-layout .hd-v14-count{font-size:.8rem}.hd-layout .hd-v14-chips a{font-size:.8rem;padding:9px 10px}}

/* V14 — scoped context, no header/footer or global resets */
.hd-layout .hd-v14-related,.hd-layout .hd-v14-feature{margin-block:16px}
.hd-layout .hd-v14-related .hd-panel-head{margin-bottom:12px}
.hd-layout .hd-v14-relgrid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:10px}
.hd-layout .hd-v14-rel{display:flex;align-items:flex-start;gap:10px;min-width:0;padding:14px;border-radius:13px;text-decoration:none;background:var(--hd-card,transparent);border:1px solid var(--hd-border,#d6e4de);color:inherit}
.hd-layout .hd-v14-rel svg{flex:none;margin-top:3px}
.hd-layout .hd-v14-rel strong{display:block;line-height:1.65;overflow-wrap:anywhere}
.hd-layout .hd-v14-rel small{display:block;margin-top:6px;opacity:.82}
.hd-layout .hd-v14-kicker{font-weight:700;margin:14px 0 6px}
.hd-layout .hd-v14-chips{display:flex;flex-wrap:wrap;gap:9px;align-items:center;margin-block:10px}
.hd-layout .hd-v14-chips a{display:inline-flex;align-items:center;justify-content:center;border:1px solid var(--hd-border,#b2c9bb);border-radius:12px;padding:9px 13px;text-decoration:none;color:inherit;font-size:.89rem;font-weight:750;min-height:42px;background:transparent}
.hd-layout .hd-v14-chips a:hover,.hd-layout .hd-v14-chips a:focus-visible,.hd-layout .hd-v14-rel:hover{outline:2px solid var(--hd-gold,#c6a665);outline-offset:1px}
.hd-layout .hd-v14-count{font-size:.85rem;font-weight:700;line-height:1.6;white-space:normal}
.hd-layout .hd-v14-search-guide{padding:15px 0;margin:10px 0}
.hd-layout .hd-v14-search-guide p{font-size:.88rem;opacity:.85;line-height:1.75}
.hd-layout .hd-v14-pages{display:flex;align-items:center;justify-content:center;flex-wrap:wrap;gap:10px;margin-top:22px}
@media(max-width:680px){.hd-layout .hd-v14-relgrid{grid-template-columns:1fr}.hd-layout .hd-v14-count{font-size:.8rem}.hd-layout .hd-v14-chips a{font-size:.8rem;padding:9px 10px}}
