/* Approved 2026-10 compact achievement progress and Arabic RTL navigation.
   Previous is physically RIGHT, Next LEFT, without changing lesson logic. */
body.juz-learning-page.card-detail-active{padding-bottom:94px!important;}
body.juz-learning-page .mla-visually-hidden{position:absolute!important;width:1px!important;height:1px!important;overflow:hidden!important;clip:rect(0,0,0,0)!important;white-space:nowrap!important;}
body.juz-learning-page .learning-detail-bar.mla-compact-progress-header{
  margin:12px auto 12px!important;padding:9px clamp(12px,2vw,25px)!important;
  width:min(1380px,calc(100% - 24px))!important;
  background:#0a3561!important;border:1px solid #2a6394!important;
  box-shadow:0 9px 22px #031e3850!important;border-radius:20px!important;
  min-height:78px!important;max-height:none!important;
}
body.juz-learning-page .learning-detail-bar.mla-compact-progress-header[hidden]{display:none!important;}
body.juz-learning-page .mla-learning-topline{display:grid!important;grid-template-columns:minmax(160px,1fr) minmax(250px,1.4fr) minmax(120px,1fr);gap:clamp(10px,2vw,25px);align-items:center;direction:rtl;}
body.juz-learning-page .mla-back-to-library{
 display:inline-flex!important;gap:10px;justify-content:center;align-items:center;min-height:48px;max-width:220px;
 font-weight:850;font-size:clamp(13px,1.3vw,16px);white-space:nowrap;text-decoration:none!important;
 border:1px solid #78b6e9;background:#135385;color:#fff!important;border-radius:14px;padding:9px 14px;
}
body.juz-learning-page .mla-back-to-library:hover,body.juz-learning-page .mla-back-to-library:focus-visible{background:#206ca8!important;}
body.juz-learning-page .mla-back-to-library span{font-size:22px;line-height:1;}
body.juz-learning-page .mla-completion-area{display:grid;gap:7px;max-width:620px;width:100%;margin:auto;justify-items:center;}
body.juz-learning-page .mla-completion-label{font-size:clamp(15px,1.5vw,20px);font-weight:900;color:#fff;line-height:1.3;text-align:center;}
body.juz-learning-page .mla-completion-meter{direction:rtl;background:#47749b;height:10px;border:1px solid #6ba4cf;border-radius:999px;width:100%;overflow:hidden;}
body.juz-learning-page .mla-completion-meter>span{display:block;width:0;height:100%;border-radius:999px;background:linear-gradient(90deg,#19b990,#45e9ad);transition:width .25s ease;}
body.juz-learning-page .mla-card-location{justify-self:end;font-size:14px;color:#d2eaff;font-weight:800;}
/* Keep the only visible lesson title in the actual card, not duplicated in the banner. */
body.juz-learning-page.card-detail-active .learning-detail-bar.mla-compact-progress-header .learning-eyebrow,
body.juz-learning-page.card-detail-active .learning-detail-bar.mla-compact-progress-header .learning-detail-navigation{display:none!important;}
body.juz-learning-page .mla-card-navigation[hidden]{display:none!important;}
body.juz-learning-page .mla-card-navigation{
 position:fixed;bottom:max(10px,env(safe-area-inset-bottom));left:50%;transform:translateX(-50%);
 z-index:500;width:min(1070px,calc(100% - 20px));
 display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1.35fr) minmax(0,1fr);gap:10px;
 padding:11px;border-radius:18px;background:rgba(255,255,255,.97);border:1px solid #c5e5f8;
 box-shadow:0 10px 32px rgba(3,27,55,.23);direction:rtl;
}
body.juz-learning-page .mla-card-navigation>button{
 display:flex;justify-content:center;align-items:center;gap:7px;box-sizing:border-box;
 min-height:49px;min-width:0;border:1px solid #94c7ed;border-radius:13px;
 background:#edf7ff;color:#0c4d80;font-size:clamp(12px,1.25vw,16px);font-weight:900;
 white-space:normal;line-height:1.35;cursor:pointer;padding:8px 6px;
}
body.juz-learning-page .mla-card-navigation .mla-primary-card-action,
body.juz-learning-page .mla-card-navigation .mla-next-card{background:#097df0;color:#fff;border-color:#479ef0;}
body.juz-learning-page .mla-card-navigation .mla-primary-card-action{font-size:clamp(12px,1.4vw,18px);}
body.juz-learning-page .mla-card-navigation .mla-primary-card-action[hidden]{display:none!important;}
body.juz-learning-page .mla-card-navigation:has(.mla-primary-card-action[hidden]){grid-template-columns:minmax(0,1fr) minmax(0,1fr);}
body.juz-learning-page .mla-card-navigation button:disabled{opacity:.45;cursor:not-allowed;background:#e5ecf3!important;color:#5b6b78!important;border-color:#b8cad9!important;}
body.juz-learning-page .mla-card-navigation button:not(:disabled):hover{filter:brightness(1.07)}
body.juz-learning-page .mla-card-navigation button:focus-visible{outline:3px solid #ffce67;outline-offset:3px;}
/* Existing in-card action remains the source of truth: its working event
   handlers are invoked through the visible footer action. */
body.juz-learning-page.card-detail-active #cards .modern-card.open .tree>.quiz-start{display:none!important;}
body.juz-learning-page.card-detail-active #cards .modern-card.open .tree>.quiz-start:focus{outline:none;}
/* Reading buttons are deliberately gone; audio and word selection remain. */
body.juz-learning-page.card-detail-active #cards .branch-footer:empty{display:none!important;}
@media(max-width:650px){
 body.juz-learning-page.card-detail-active{padding-bottom:94px!important;}
 body.juz-learning-page .learning-detail-bar.mla-compact-progress-header{margin:7px auto 10px!important;min-height:0!important;padding:9px!important;border-radius:14px!important;width:calc(100% - 16px)!important;}
 body.juz-learning-page .mla-learning-topline{grid-template-columns:minmax(0,1fr) minmax(0,1.3fr);gap:8px!important;}
 body.juz-learning-page .mla-back-to-library{font-size:12px;min-height:42px;padding:6px 7px;max-width:none;}
 body.juz-learning-page .mla-back-to-library span{font-size:18px;}
 body.juz-learning-page .mla-completion-label{font-size:12px;white-space:normal;}
 body.juz-learning-page .mla-card-location{grid-column:1/-1;justify-self:center;font-size:12px;}
 body.juz-learning-page .mla-completion-meter{height:8px;}
 body.juz-learning-page .mla-card-navigation{width:calc(100% - 10px);bottom:max(4px,env(safe-area-inset-bottom));border-radius:13px;padding:6px;gap:5px;}
 body.juz-learning-page .mla-card-navigation>button{font-size:11px;min-height:45px;padding:6px 3px;gap:3px;border-radius:10px;}
 body.juz-learning-page .mla-card-navigation .mla-primary-card-action{font-size:11px;}
}
@media(prefers-reduced-motion:reduce){body.juz-learning-page .mla-completion-meter>span{transition:none!important;}}
/* The approved library hero has its own display:grid !important rule.
   During lesson view the progress strip must be the ONLY hero. */
body.juz-learning-page.card-detail-active #learning-library-header,
body.juz-learning-page.card-detail-active #learning-library-header[hidden]{display:none!important;}
