/* Al-Hamid V17 | Presentation edition
   One coherent Qur'an reading experience, balanced cards, responsive navigation.
   This stylesheet intentionally overrides older V13–V16 presentation rules. */
:root{--v17-green:#075344;--v17-deep:#073e33;--v17-gold:#cda45b;--v17-cream:#fffaf0;--v17-paper:#fffdf8;--v17-ink:#13382f;--v17-muted:#758980;--v17-border:#e7dfcf;--v17-shadow:0 14px 45px rgba(29,50,36,.055)}
html{scroll-behavior:smooth}
body{background:#f3f1e9}
.app-layout{max-width:1600px;min-height:100dvh;background:#fffcf7}
.main-area{background:#fffcf7;min-width:0}
.page-frame{max-width:1160px;padding:38px clamp(24px,3vw,48px) 90px}
.page-header{margin:0 0 26px;align-items:center}
.page-header h1{font-size:clamp(27px,2.5vw,37px);line-height:1.18;letter-spacing:-.8px}
.page-header p{margin-top:7px;line-height:1.5}
.section-head{margin:32px 0 17px}
.section-title{font-size:clamp(23px,2.1vw,29px)}
.button,.feature-tile,.adhkar-quick-card,.dhikr-choice,.prayer-row,.inline-card,.adhkar-card{transition:border-color .18s,box-shadow .18s,transform .18s}
.button:hover,.feature-tile:hover,.adhkar-quick-card:hover{border-color:#d8c9a8;box-shadow:0 8px 22px #253b2110}
/* Sidebar: its own scrolling area, fixed brand and footer; no clipping of first nav item. */
@media(min-width:920px){
 .sidebar{width:254px;flex:0 0 254px;height:100dvh;min-height:0;position:sticky;top:0;overflow:hidden;padding:25px 15px 17px;background:linear-gradient(160deg,#074638 0%,#02382e 55%,#022d27 100%);box-shadow:inset -1px 0 #ffffff1b}
 .sidebar .brand{flex:0 0 auto;padding:0 10px 19px;min-height:0}
 .sidebar-rule{flex:0 0 auto}
 .side-nav{flex:1 1 auto;min-height:0;overflow-y:auto;overscroll-behavior:contain;padding:8px 4px 14px 0;scrollbar-width:thin;scrollbar-color:#ffffff3d transparent}
 .side-nav::-webkit-scrollbar{width:5px}.side-nav::-webkit-scrollbar-thumb{background:#ffffff36;border-radius:99px}
 .side-group{margin-bottom:12px}.side-group-label{margin:15px 14px 8px;font-size:10px;letter-spacing:1.9px}
 .side-link{min-height:42px;border-radius:12px;padding:10px 13px;gap:13px}
 .side-link .icon{width:18px;height:18px}
 .sidebar-bottom{flex:0 0 auto;margin-top:9px;padding:13px 12px 12px;border-radius:17px}
 .sidebar-verse{font-size:18px;line-height:1.65}.sidebar-urdu{font-size:11px;line-height:2.1}
 .sidebar-source{font-size:9px;letter-spacing:1px}.sidebar-lang{margin-top:8px;min-height:33px}
 .home-frame{max-width:1120px;margin:0 auto;padding-bottom:76px}
 .home-sections{padding-left:clamp(22px,3vw,43px);padding-right:clamp(22px,3vw,43px)}
 .home-hero{border-radius:0 0 24px 24px}
 .hero-main{margin-left:clamp(18px,2.5vw,32px);margin-right:clamp(18px,2.5vw,32px)}
}
/* Hadith: editorial cards with natural height, not an artificially tall empty box. */
.hadith-slider{align-items:flex-start!important;gap:17px;padding-bottom:9px}
.hadith-card,.home-frame .hadith-card,.page-frame .hadith-card{height:auto!important;min-height:0!important;max-height:none!important;align-self:flex-start;box-shadow:var(--v17-shadow);border-color:var(--v17-border);border-radius:21px;background:var(--v17-paper)}
.hadith-inner,.home-frame .hadith-inner{min-height:0!important;flex:0 0 auto!important;padding:18px 21px 15px}
.hadith-card .hadith-cover{height:158px;flex:0 0 158px}
.hadith-card .arabic-source{margin:9px 0 9px;padding-bottom:7px}
.hadith-card .arabic-source-caption{font-size:10px;letter-spacing:.2px}
.hadith-card .hadith-arabic{font-size:clamp(19px,1.7vw,23px)!important;line-height:1.95!important;max-height:none!important;overflow:visible!important;-webkit-line-clamp:unset!important;margin:6px 0 8px}
.hadith-card .translation-stack{display:grid;gap:10px;margin:6px 0 9px;flex:0 0 auto!important}
.hadith-card .translation-unit{margin:0;padding:0}
.hadith-card .urdu-translation{font-size:clamp(13px,1.1vw,16px)!important;line-height:2.0!important;margin:3px 0 2px}
.hadith-card .english-translation{font-size:13px!important;line-height:1.65!important;margin:4px 0 3px}
.hadith-card .hadith-translation{flex:0 0 auto!important}
.hadith-card .gold-rule{margin:7px 0 5px!important;flex:0 0 auto!important}
.hadith-card .hadith-ref{margin:4px 0 11px!important;font-size:11px}
.hadith-card .card-actions{margin-top:0;padding-top:8px;gap:6px}
.hadith-card .card-actions button{min-height:35px;font-size:11px}
.home-frame .hadith-card .hadith-cover{height:148px;flex-basis:148px}
.home-frame .hadith-card .hadith-inner{padding:15px 18px 12px}
.home-frame .hadith-card .hadith-arabic{font-size:19px!important;line-height:1.85!important;display:-webkit-box!important;-webkit-box-orient:vertical!important;-webkit-line-clamp:3!important;overflow:hidden!important;max-height:112px!important}
.home-frame .hadith-card .urdu-translation{display:-webkit-box;-webkit-box-orient:vertical;-webkit-line-clamp:3;overflow:hidden;font-size:13px!important;line-height:2!important}
.home-frame .hadith-card .english-translation{display:-webkit-box;-webkit-box-orient:vertical;-webkit-line-clamp:3;overflow:hidden;font-size:12px!important}
.home-frame .hadith-card .translation-stack{gap:6px}
.hadith-view .hadith-card{flex-basis:calc(50% - 9px)}
.hadith-view .inline-card{max-width:100%;padding:12px 18px}.hadith-view .inline-card p{margin:0}
/* Qur'an: unified reading canvas, not three disconnected tabs. */
.quran-read-layout{max-width:1180px!important;padding-top:31px!important;padding-bottom:110px!important}
.quran-page-heading{display:flex;justify-content:space-between;align-items:center;gap:16px;margin:0 0 22px}
.quran-kicker{font-size:10px;font-weight:800;letter-spacing:1.65px;color:#b08b4d}
.quran-page-heading h1{font:700 clamp(31px,3.2vw,44px)/1.12 var(--serif);letter-spacing:-1.2px;color:#12382e;margin:5px 0 5px}
.quran-page-heading p{font-size:13px;color:#819087;margin:0}
.quran-heading-actions{display:flex;gap:9px;align-items:center}
.quran-heading-button{display:inline-flex;align-items:center;gap:8px;background:#fffdf8;border:1px solid var(--v17-border);border-radius:13px;color:#27584b;padding:10px 14px;font-size:12px;font-weight:700;min-height:42px;white-space:nowrap}
.quran-heading-button.icon-only{width:42px;padding:9px;justify-content:center}
.quran-reader-surface{background:#fffdf8;border:1px solid #e6decf;border-radius:25px;box-shadow:0 15px 45px rgba(50,60,39,.06);overflow:visible}
.quran-read-layout .reader-config{display:grid!important;grid-template-columns:210px minmax(220px,1fr) minmax(190px,.85fr)!important;align-items:end!important;gap:18px!important;background:#f8f5ee!important;border:0!important;border-bottom:1px solid #ebe4d8!important;border-radius:24px 24px 0 0!important;margin:0!important;padding:20px 24px!important}
.quran-browse-choice,.quran-select-group,.quran-search-group{display:flex;flex-direction:column;gap:8px;min-width:0;position:relative}
.quran-control-caption,.quran-read-layout .quran-select-label{font-size:10px!important;letter-spacing:.6px;color:#6d7d73;font-weight:800}
.quran-read-layout .reader-mode-toggle{display:grid!important;grid-template-columns:1fr 1fr!important;grid-row:auto!important;align-self:auto!important;width:100%;height:45px;gap:3px!important;background:#ebe7dd!important;border:1px solid #e3dccc!important;border-radius:11px!important;padding:3px!important}
.quran-read-layout .reader-mode-toggle button{padding:7px 4px!important;white-space:nowrap;font-size:12px!important;border-radius:8px!important}
.quran-read-layout .reader-mode-toggle button.chosen{background:#0b5b48!important;color:#fff!important}
.quran-read-layout .quran-choose,.quran-read-layout .quran-search{height:45px!important;min-height:45px!important;border:1px solid #ded9cb!important;border-radius:11px!important;background:#fffefa!important;padding:9px 13px!important;font-size:12px!important;color:#20483c;grid-column:auto!important;grid-row:auto!important}
.quran-read-layout .quran-search-results{position:absolute;top:calc(100% + 4px);left:0;right:0;z-index:45;max-height:280px;box-shadow:0 15px 35px #1c332b2b}
.quran-read-layout .reader-title{border:0!important;border-bottom:1px solid #eee4d4!important;border-radius:0!important;background:radial-gradient(ellipse at 50% 35%,#fffef8 0%,#fffaf0 78%,#f9f2e3 100%)!important;margin:0!important;padding:29px 20px 25px!important;text-align:center;position:relative}
.surah-ornament{display:flex;align-items:center;justify-content:center;gap:15px;font-size:22px;line-height:1;color:#c69d4e;margin:0 0 12px}
.surah-ornament span{height:1px;width:65px;background:linear-gradient(90deg,transparent,#d6b875)}.surah-ornament span:last-child{transform:rotate(180deg)}
.quran-read-layout .reader-arabic-title{font:400 clamp(29px,3vw,37px)/1.9 var(--arabic)!important;color:#0a5b45!important;margin:0 0 1px}
.quran-read-layout .reader-title h2{font:700 clamp(25px,2.4vw,32px)/1.2 var(--serif)!important;letter-spacing:-.5px;color:#193a31;margin:0 0 6px}
.quran-read-layout .reader-title>span{color:#7c8d81;font-size:12px}
.quran-utility-bar{display:flex;justify-content:space-between;align-items:center;gap:12px;padding:13px 23px;background:#fffdf9;border-bottom:1px solid #eee7db;position:relative;z-index:10}
.quran-utility-label{display:flex;align-items:center;gap:8px;font:700 13px var(--serif);color:#305e4d}
.quran-utility-label .icon{color:#b38b45}
.quran-utility-actions{display:flex;align-items:center;gap:8px}
.quran-tool{display:inline-flex;align-items:center;justify-content:center;gap:7px;min-height:38px;border:1px solid #e5dece;background:#fffdf8;color:#375d50;padding:8px 12px;border-radius:11px;font-size:11px;font-weight:750;white-space:nowrap}
.quran-tool.active{background:#ecf5ec;border-color:#b8d9c5;color:#095c44}
.quran-tool-state{font-size:10px;opacity:.7}
.quran-reading-settings{position:relative}
.quran-reading-settings>summary{list-style:none;cursor:pointer}.quran-reading-settings>summary::-webkit-details-marker{display:none}
.quran-settings-popover{position:absolute;right:0;top:calc(100% + 9px);z-index:60;width:min(450px,calc(100vw - 38px));background:#fffdf8;border:1px solid #e1d6c1;border-radius:17px;box-shadow:0 18px 45px #142d222c;padding:17px}
.quran-settings-heading{font:700 18px var(--serif);margin-bottom:11px}
.quran-settings-popover .translation-choice{display:flex;flex-wrap:wrap;gap:6px;margin:0 0 12px;padding:0}
.quran-settings-popover .translation-choice button{padding:8px 10px;min-height:33px;font-size:10px}
.quran-settings-popover .translation-title{flex:0 0 100%;font-size:11px;margin-bottom:2px}
.quran-font-row{border-top:1px solid #eee8dc;padding:12px 0 9px;display:flex;align-items:center;gap:10px;flex-wrap:wrap}
.quran-font-row .font-size-label{font-size:11px;margin:0;flex:0 0 auto}.quran-font-row input{flex:1 1 120px}
.quran-settings-popover .tajweed-legend{display:flex;flex-wrap:wrap;gap:5px;margin:5px 0 0}
.quran-settings-popover .tajweed-legend .legend-head{width:100%;margin:0 0 3px}
/* Recitation is part of the same page: one elegant player, not a separate mode. */
.quran-read-layout .quran-player{display:grid!important;grid-template-columns:minmax(145px,1fr) auto minmax(190px,1.4fr) auto!important;grid-template-rows:auto 3px auto!important;align-items:center!important;gap:8px 17px!important;margin:17px 22px 16px!important;padding:13px 17px 10px!important;border-radius:17px!important;background:linear-gradient(110deg,#083f33,#09604c 75%,#064538)!important;border:1px solid #175d4a!important;box-shadow:0 9px 23px #0a4e3c19!important;color:#fff}
.quran-player .player-title{grid-column:1;grid-row:1;display:flex;align-items:center;gap:10px;margin:0}
.quran-player .player-title>.icon{width:23px;height:23px;color:#e9c784}
.quran-player .player-title>div{display:flex;flex-direction:column;gap:3px}
.quran-player .player-title strong{font:700 16px var(--serif);white-space:nowrap}
.quran-player .player-title span{font-size:10px;color:#c4dbd0;white-space:nowrap}
.quran-player .player-controls{grid-column:2;grid-row:1;display:flex;align-items:center;justify-content:center;gap:7px;margin:0}
.quran-player .transport-play{width:43px;height:43px;min-width:43px;display:grid;place-items:center;background:#f2dfb3;color:#083f33;border-radius:50%;border:0}
.quran-player .transport-light{width:32px;height:38px;min-width:32px;border:0;background:transparent;color:#f4f1e4;padding:5px}
.quran-player .player-selects{grid-column:3;grid-row:1;display:grid;grid-template-columns:minmax(120px,1fr) 78px;gap:8px;min-width:0;margin:0}
.quran-player .player-selects label{min-width:0;display:flex;flex-direction:column;gap:4px;color:#b6d2c6;font-size:9px;line-height:1.1}
.quran-player .player-selects select{min-width:0;max-width:100%;height:34px;padding:5px 9px;border-radius:8px;background:#ffffff13;color:#fff;border:1px solid #ffffff35;font-size:11px;outline-offset:2px}
.quran-player .player-selects select option{color:#163d31;background:#fff}
.quran-player .transport-repeat{grid-column:4;grid-row:1;display:flex;align-items:center;justify-content:center;gap:5px;padding:8px 7px!important;margin:0!important;color:#d2e4d9;font-size:10px;border-radius:9px;border:1px solid #ffffff2b;white-space:nowrap}
.quran-player .transport-repeat.on{background:#e3c786;color:#0c4034}
.quran-player .player-progress-track{grid-column:1 / -1;grid-row:2;height:3px;background:#ffffff3c;border-radius:99px;margin:0}
.quran-player .player-progress-track span{background:#dfc17f}
.quran-player .player-foot{grid-column:1 / -1;grid-row:3;display:flex;justify-content:space-between;align-items:center;font-size:10px;color:#c0d8cc;line-height:1.2}
.quran-read-layout .quran-verses{display:block!important;max-width:1000px!important;margin:0 auto!important;padding:3px 28px 12px!important;background:#fffdf8!important;border:0!important;border-radius:0!important;box-shadow:none!important;overflow:visible!important}
.quran-read-layout .mushaf-ayah{background:transparent!important;border:0!important;border-bottom:1px solid #ede6d9!important;border-radius:0!important;box-shadow:none!important;padding:24px 20px 26px!important;margin:0!important;min-width:0}
.quran-read-layout .mushaf-ayah:last-child{border-bottom:0!important}
.quran-read-layout .mushaf-ayah.is-playing{background:linear-gradient(90deg,#eef8ee,transparent)!important;box-shadow:inset 3px 0 #0a7a5b!important}
.quran-read-layout .ayah-top{display:flex;align-items:center;gap:9px;opacity:1!important;margin-bottom:10px}
.quran-read-layout .ayah-rosette{width:35px;height:35px;min-width:35px;border-radius:11px;background:#f9f0db;border:1px solid #ead6a8;color:#9b7439;font:700 14px var(--serif)}
.quran-read-layout .ayah-label{font-size:11px;color:#8b988e;font-weight:700}
.quran-read-layout .ayah-actions{margin-left:auto;gap:5px}
.quran-read-layout .ayah-icon{width:34px;min-width:34px;height:34px;border-radius:9px;background:#f1f5ef;color:#31634f}
.quran-read-layout .ayah-icon:hover{background:#e0eee3}
.quran-read-layout .mushaf-arabic{font-family:var(--arabic)!important;font-weight:400!important;line-height:2.35!important;text-align:right!important;text-align-last:auto!important;margin:12px 2px 17px!important;color:#123e31!important;overflow-wrap:break-word;word-break:normal}
.quran-read-layout .translation-stack{display:grid;gap:12px;margin:0 2px 10px}
.quran-read-layout .translation-unit{margin:0!important}
.quran-read-layout .translation-unit-label{display:block;font-size:10px!important;letter-spacing:.2px;color:#b18d51!important;margin:0 0 3px}
.quran-read-layout .urdu-translation{font-family:'Noto Nastaliq Urdu',serif!important;font-size:clamp(14px,1.15vw,16px)!important;line-height:2.5!important;color:#325f4d!important;margin:0!important}
.quran-read-layout .english-translation{font-size:13px!important;line-height:1.75!important;color:#65776d!important;margin:0!important}
.quran-read-layout .ayah-ref{font-size:10px;color:#a68b61}
.quran-read-layout .surah-status{margin:12px 27px;font-size:12px}
.quran-read-layout .surah-status[hidden]{display:none!important}
.quran-read-layout .quran-load-more{margin:20px auto 22px;border:1px solid #b7d2c0}
.reader-bottom-line{display:flex;align-items:center;justify-content:center;gap:10px;padding:18px 10px 15px;color:#a38b61;font:italic 15px var(--serif);text-align:center;border-top:1px solid #f0e8d9}
.reader-bottom-line span{font-style:normal;color:#d4ad60}
.quran-read-layout .sources-details{margin:0 22px 20px;background:#faf7ef;border-color:#ede6d8;font-size:11px;padding:11px 14px}
.quran-read-layout .sources-details summary{font-size:11px}
/* Remaining app modules: common rhythm and accessible controls. */
.standard-view{max-width:1080px}
.prayer-row,.adhkar-card,.inline-card,.quran-feature{background:#fffefa;border-color:#e9e1d4}
.prayer-row{min-height:64px;padding:14px 19px}
.dhikr-choice{background:#fffefa;border-color:#e9e1d4}
.adhkar-list{gap:13px}
.adhkar-card{padding:20px 22px}
.setting-row{min-height:68px}
/* Tablet/mobile: six clear primary destinations, Qur'an in the center. */
@media(max-width:919px){
 body{background:#fffcf7}
 .app-layout{max-width:none;display:block;min-height:100dvh}
 .main-area{width:100%}
 .page-frame{padding:20px 15px calc(104px + env(safe-area-inset-bottom));max-width:740px;margin:auto}
 .page-header{margin:5px 1px 22px;gap:12px}
 .page-header h1{font-size:27px;max-width:none}
 .header-actions{gap:8px}.location-chip{max-width:158px;font-size:11px}
 .home-frame{padding-bottom:calc(96px + env(safe-area-inset-bottom))}
 .home-hero{border-radius:0}
 .bottom-nav{grid-template-columns:repeat(6,minmax(0,1fr))!important;padding:8px max(4px,env(safe-area-inset-right)) calc(8px + env(safe-area-inset-bottom)) max(4px,env(safe-area-inset-left))!important;box-shadow:0 -6px 25px #1b352016;min-height:69px;z-index:500}
 .bottom-nav button{font-size:10px!important;min-width:0;gap:4px!important;min-height:48px;padding:3px 0!important;letter-spacing:-.15px}
 .bottom-nav .icon{width:21px!important;height:21px!important}
 .bottom-nav button.active:before{top:-8px;width:21px;height:3px}
 .bottom-nav button[data-route="quran"].active .icon{stroke:#075344}
 .hadith-slider{gap:11px}
 .home-frame .hadith-card,.hadith-view .hadith-card{flex-basis:min(84%,365px)!important}
 .hadith-view .hadith-cover{height:165px!important}
 .hadith-card .hadith-inner{padding:14px 15px 13px!important}
 .hadith-card .hadith-arabic{font-size:19px!important;line-height:1.95!important}
 .hadith-card .urdu-translation{font-size:14px!important;line-height:2.1!important}
 .hadith-card .english-translation{font-size:12px!important}
 .quran-read-layout{padding:18px 12px calc(105px + env(safe-area-inset-bottom))!important}
 .quran-page-heading{margin:2px 3px 17px}
 .quran-page-heading h1{font-size:33px}
 .quran-kicker{font-size:9px;letter-spacing:1px}
 .quran-page-heading p{font-size:12px}
 .quran-heading-button{width:38px;height:38px;min-height:38px;padding:8px;justify-content:center}
 .quran-heading-button span{display:none}
 .quran-reader-surface{border-radius:20px}
 .quran-read-layout .reader-config{display:grid!important;grid-template-columns:1fr 1fr!important;gap:13px!important;padding:15px!important;border-radius:19px 19px 0 0!important}
 .quran-browse-choice{grid-column:1 / -1}
 .quran-select-group{grid-column:1 / -1}
 .quran-search-group{grid-column:1 / -1}
 .quran-read-layout .reader-mode-toggle{width:100%;height:42px}
 .quran-read-layout .reader-mode-toggle button{font-size:12px!important}
 .quran-read-layout .quran-choose,.quran-read-layout .quran-search{height:43px!important;min-height:43px!important}
 .quran-read-layout .reader-title{padding:22px 12px 20px!important}
 .quran-read-layout .reader-arabic-title{font-size:29px!important;line-height:1.9!important}
 .quran-read-layout .reader-title h2{font-size:26px!important}
 .quran-utility-bar{padding:12px 13px;gap:6px}
 .quran-utility-label{font-size:12px}
 .quran-utility-actions{gap:6px}
 .quran-tool{padding:7px 9px;min-height:36px;font-size:10px;gap:4px}
 .quran-tool .icon{width:14px;height:14px}
 .quran-tool-state{display:none}
 .quran-settings-popover{right:-1px;width:min(375px,calc(100vw - 40px));padding:14px}
 .quran-read-layout .quran-player{display:grid!important;grid-template-columns:1fr auto!important;grid-template-rows:auto auto 3px auto!important;gap:10px!important;margin:12px 12px 14px!important;padding:14px 13px 11px!important;border-radius:15px!important}
 .quran-player .player-title{grid-column:1;grid-row:1}
 .quran-player .player-title strong{font-size:15px}
 .quran-player .player-title span{font-size:10px}
 .quran-player .player-controls{grid-column:2;grid-row:1;gap:3px}
 .quran-player .transport-play{width:39px;height:39px;min-width:39px}
 .quran-player .transport-light{width:28px;min-width:28px}
 .quran-player .player-selects{grid-column:1;grid-row:2;grid-template-columns:minmax(0,1fr) 70px;gap:7px}
 .quran-player .player-selects select{height:32px;font-size:10px;padding:4px 7px}
 .quran-player .transport-repeat{grid-column:2;grid-row:2;align-self:end;min-height:32px;font-size:10px}
 .quran-player .transport-repeat span{display:none}
 .quran-player .player-progress-track{grid-column:1 / -1;grid-row:3}
 .quran-player .player-foot{grid-column:1 / -1;grid-row:4}
 .quran-read-layout .quran-verses{padding:2px 14px 10px!important}
 .quran-read-layout .mushaf-ayah{padding:19px 1px 21px!important}
 .quran-read-layout .mushaf-arabic{line-height:2.3!important;margin:13px 0 15px!important}
 .quran-read-layout .urdu-translation{font-size:14px!important;line-height:2.55!important}
 .quran-read-layout .english-translation{font-size:12px!important;line-height:1.75!important}
 .quran-read-layout .ayah-icon{width:33px;min-width:33px;height:33px}
 .quran-read-layout .surah-status{margin:9px 14px}
 .quran-read-layout .sources-details{margin:0 12px 15px}
 .reader-bottom-line{font-size:12px;gap:6px;padding:17px 8px}
 .quran-read-layout.audio-active .quran-player{position:sticky;bottom:calc(70px + env(safe-area-inset-bottom));z-index:17;box-shadow:0 12px 40px #04372d40!important}
}
@media(max-width:390px){
 .page-frame{padding-left:12px;padding-right:12px}
 .quran-page-heading h1{font-size:29px}
 .quran-page-heading p{font-size:11px}
 .quran-utility-label span{display:none}
 .quran-read-layout .quran-verses{padding:0 12px 9px!important}
 .bottom-nav button{font-size:9px!important}
 .bottom-nav .icon{width:20px!important;height:20px!important}
 .hadith-view .hadith-card{flex-basis:89%!important}
}
@media(max-width:340px){.quran-utility-bar{padding:10px}.quran-tool{font-size:9px;padding:6px 7px}.quran-settings-popover{right:-3px}.quran-read-layout .mushaf-arabic{font-size:29px!important}.quran-player .player-title span{display:none}}
/* Respect existing dark theme without sacrificing readable Qur'anic text. */
.app-layout[data-theme="dark"] .main-area{background:#12271f}
.app-layout[data-theme="dark"] .quran-page-heading h1{color:#f8eed8}
.app-layout[data-theme="dark"] .quran-reader-surface,.app-layout[data-theme="dark"] .quran-utility-bar,.app-layout[data-theme="dark"] .quran-verses,.app-layout[data-theme="dark"] .mushaf-ayah{background:#1b342b!important;border-color:#365b4c!important}
.app-layout[data-theme="dark"] .reader-config,.app-layout[data-theme="dark"] .reader-title,.app-layout[data-theme="dark"] .quran-settings-popover{background:#18392f!important;border-color:#3e5f51!important}
.app-layout[data-theme="dark"] .reader-title h2,.app-layout[data-theme="dark"] .quran-utility-label,.app-layout[data-theme="dark"] .quran-settings-heading{color:#f2e2bf}
.app-layout[data-theme="dark"] .quran-read-layout .mushaf-arabic{color:#f6e6c5!important}
.app-layout[data-theme="dark"] .quran-read-layout .urdu-translation,.app-layout[data-theme="dark"] .quran-read-layout .english-translation{color:#d5e4d8!important}
.app-layout[data-theme="dark"] .quran-heading-button,.app-layout[data-theme="dark"] .quran-tool{background:#214c3e;color:#e8f2e6;border-color:#3b6451}
@media(prefers-reduced-motion:reduce){.quran-read-layout *{scroll-behavior:auto!important}}
/* Compact mobile Surah search: optional, not a permanent extra form field. */
.quran-search-toggle{display:none}
@media(max-width:919px){
 .quran-read-layout .reader-config{grid-template-columns:minmax(0,1fr) 44px!important;gap:10px!important}
 .quran-browse-choice{grid-column:1 / -1}
 .quran-select-group{grid-column:1;min-width:0}
 .quran-search-group{grid-column:2;align-items:flex-end;justify-content:flex-end;align-self:end}
 .quran-search-group>.quran-select-label,.quran-search-group>.quran-search{display:none!important}
 .quran-search-toggle{display:grid;place-items:center;width:44px;height:43px;background:#fffefa;border:1px solid #ded9cb;border-radius:11px;color:#205846;cursor:pointer}
 .quran-search-group.search-open{grid-column:1 / -1;display:grid;grid-template-columns:minmax(0,1fr) 44px;align-items:center;gap:7px}
 .quran-search-group.search-open>.quran-search{display:block!important;grid-column:1;grid-row:1}
 .quran-search-group.search-open>.quran-search-toggle{grid-column:2;grid-row:1}
 .quran-search-group.search-open .quran-search-results{top:calc(100% + 3px)}
 .quran-read-layout .reader-title{padding:15px 10px 16px!important}
 .surah-ornament{margin:0 0 4px;font-size:17px}
 .quran-read-layout .reader-arabic-title{font-size:26px!important;line-height:1.7!important}
 .quran-read-layout .reader-title h2{font-size:24px!important}
 .quran-read-layout .reader-title>span{font-size:11px}
 .quran-utility-bar{padding:10px 13px}
 .quran-read-layout .quran-player{margin-top:10px!important}
}
