/* The first-open tutorial (onboard.js) and the one light touch of progress, a thin bar to the end of the surah (.sbar).
   Redesigned 2026-10-30 (Muhammad, 11:38: "doesn't look so modern"): large type, soft surfaces instead of outlined boxes, round icon tiles, one slim
   progress line, a pill button and floating dock like the practice bar's, a short rise-in on each screen. Same tokens as every screen (style.css),
   light and dark; logical sides throughout so Arabic turns it round with no extra rules. No pictures of anything: shapes and the app's own type only. */
.ob{--ease:cubic-bezier(.22,1,.36,1);position:fixed;z-index:60;top:0;bottom:0;left:50%;width:min(100%,440px);translate:-50% 0;display:flex;flex-direction:column;box-sizing:border-box;
  padding:max(8px,env(safe-area-inset-top)) 20px max(16px,env(safe-area-inset-bottom));background:var(--bg);color:var(--ink);overflow:auto;overscroll-behavior:contain}
.ob[data-new]>*{animation:ob-rise .38s var(--ease) both}    /* only when the screen changes, not at each tap on it */
.ob[data-new]>:nth-child(2){animation-delay:40ms}.ob[data-new]>:nth-child(3){animation-delay:80ms}.ob[data-new]>:nth-child(4){animation-delay:120ms}
.ob[data-new] .ob-list>*{animation:ob-rise .42s var(--ease) both}
.ob[data-new] .ob-list>:nth-child(2){animation-delay:45ms}.ob[data-new] .ob-list>:nth-child(3){animation-delay:90ms}.ob[data-new] .ob-list>:nth-child(4){animation-delay:135ms}.ob[data-new] .ob-list>:nth-child(n+5){animation-delay:170ms}
@keyframes ob-rise{from{opacity:0;transform:translateY(12px)}to{opacity:1;transform:none}}
@media (prefers-reduced-motion:reduce){.ob>*,.ob-list>*,.ob-hbar,.ob-hint,.ob-dock{animation:none!important}.ob *{transition:none!important}}

/* the top: back, one slim line of progress, skip */
.ob-skip{min-width:44px;min-height:44px;display:inline-flex;align-items:center;justify-content:center;border:0;background:none;color:var(--muted);font:inherit;font-size:15px;font-weight:600;cursor:pointer;border-radius:999px;transition:background .2s,color .2s}

/* words */
.ob-h{margin:22px 2px 8px;font-size:29px;line-height:1.15;font-weight:750;letter-spacing:-.6px;text-wrap:balance}
[dir=rtl] .ob-h{letter-spacing:0;line-height:1.3}
.ob-sub,.ob-note{margin:0 2px 12px;font-size:16px;line-height:1.5;color:var(--muted);max-width:34ch}
.ob-note{margin-top:14px;font-size:14px}

/* rows: soft surfaces, a round tile first, a ring last */
.ob-list{display:flex;flex-direction:column;gap:12px;margin-top:18px}
.ob-scroll{flex:1;min-height:0;overflow:auto;margin-top:12px;padding:4px 2px 8px;scrollbar-width:none}
.ob-scroll::-webkit-scrollbar{display:none}
.ob-card,.ob-row,.ob-place{position:relative;display:flex;align-items:center;gap:14px;width:100%;box-sizing:border-box;padding:16px 18px;border:1px solid var(--line);border-radius:22px;background:var(--surface);color:var(--ink);font:inherit;text-align:start;cursor:pointer;box-shadow:var(--shadow);transition:transform .2s var(--ease),border-color .2s,background .2s,box-shadow .2s}
.ob-place{cursor:default}
.ob-card.on{border-color:var(--accent);background:color-mix(in srgb,var(--accent) 8%,var(--surface));box-shadow:0 0 0 1px var(--accent),var(--shadow)}
.ob-card:active,.ob-row:active{transform:scale(.985)}
.ob-ico{flex:none;display:inline-flex;align-items:center;justify-content:center;width:46px;height:46px;border-radius:15px;background:color-mix(in srgb,var(--accent) 14%,var(--card));color:var(--accent-text,var(--accent))}
.ob-card.on .ob-ico{background:var(--accent-grad);color:var(--accent-ink)}
.ob-t{display:flex;flex-direction:column;gap:3px;flex:1;min-width:0}
.ob-t strong{font-size:17px;line-height:1.3;font-weight:650}
.ob-t small{font-size:14px;line-height:1.4;color:var(--muted)}
.ob-check{flex:none;display:inline-flex;align-items:center;justify-content:center;width:26px;height:26px;border-radius:50%;border:2px solid var(--line);color:var(--accent-ink);transition:background .2s,border-color .2s}
.ob-check svg{scale:.8;opacity:0;transition:scale .25s var(--ease),opacity .2s}
.ob-card.on .ob-check{background:var(--accent-grad);border-color:transparent}
.ob-card.on .ob-check svg{scale:1;opacity:1}
.ob-big{padding:20px 18px}.ob-big .ob-t strong{font-size:19px}

/* the Qari rows: Hear is the round tile at the start, and the page icon stands in where there is no voice */

/* links, the foot, the pill (the same shape as the practice bar's button) */
.ob-link,.ob-alt{align-self:center;margin-top:12px;min-height:44px;padding:0 16px;border:0;background:none;color:var(--accent-text,var(--accent));font:inherit;font-size:15px;font-weight:650;cursor:pointer;text-decoration:none;border-radius:999px}
.ob-link:active,.ob-alt:active{background:var(--card)}
.ob-foot{position:sticky;bottom:0;margin-top:auto;padding-top:16px;background:linear-gradient(transparent,var(--bg) 22%);display:flex;flex-direction:column;align-items:stretch;gap:2px}
.ob-foot .ob-alt{margin-top:0;align-self:center}
.ob-go,.ob-start{display:flex;align-items:center;justify-content:center;gap:10px;min-height:56px;padding:0 24px;border:0;border-radius:28px;background:var(--accent-grad);color:var(--accent-ink);font:inherit;font-size:17px;font-weight:700;cursor:pointer;box-shadow:0 8px 20px -10px var(--glow);transition:transform .2s var(--ease),opacity .2s}
.ob-go:disabled,.ob-start:disabled{opacity:.4;cursor:default;box-shadow:none}
.ob-go:active:not(:disabled),.ob-start:active:not(:disabled){transform:scale(.97)}

/* surah and Juzzu rows */
.ob-row .ob-n,.ob-place .ob-n{flex:none;display:inline-flex;align-items:center;justify-content:center;width:42px;height:42px;border-radius:14px;background:var(--card);font-size:15px;font-weight:700;color:var(--muted);font-variant-numeric:tabular-nums}
.ob-whole{border-color:var(--accent);background:color-mix(in srgb,var(--accent) 8%,var(--surface))}
.ob-whole .ob-n{background:var(--accent-grad);color:var(--accent-ink)}
.ob-ar{font-family:AmiriQuran,serif;font-size:23px;line-height:1.2;color:var(--ink)}
.ob-find{box-sizing:border-box;width:100%;min-height:52px;margin:12px 0 0;padding:0 18px;border:1px solid var(--line);border-radius:18px;background:var(--surface);color:var(--ink);font:inherit;font-size:16px}
.ob-bar,.sbar{--dir:90deg;display:block;height:3px;border-radius:2px;background:var(--line);overflow:hidden}
[dir=rtl] .ob-bar,[dir=rtl] .sbar{--dir:270deg}
.ob-bar{position:absolute;inset-inline:18px;bottom:6px;background:linear-gradient(var(--dir),var(--accent) var(--p),var(--line) var(--p))}

/* the hafiz test: a strip over the lesson (which question, how far), and the results */
.ob-hbar{position:fixed;z-index:61;top:0;left:50%;translate:-50% 0;width:min(100%,440px);box-sizing:border-box;padding:max(8px,env(safe-area-inset-top)) 20px 12px;background:var(--bg);animation:ob-rise .3s var(--ease) both}
.ob-hbar-in{display:flex;align-items:center;justify-content:space-between;min-height:44px}
.ob-hbar-t{font-size:16px;font-weight:700;letter-spacing:-.1px}
.ob-hbar-seg{display:flex;gap:4px}
.ob-hbar-seg i{flex:1;height:4px;border-radius:2px;background:var(--line);transition:background .3s var(--ease)}
.ob-hbar-seg i.was{background:var(--accent)}
.ob-hbar-seg i.on{background:color-mix(in srgb,var(--accent) 45%,var(--line))}
.ob-chips{display:flex;flex-wrap:wrap;gap:8px;margin:4px 2px 0}
.ob-chip{padding:7px 12px;border-radius:999px;background:var(--card);font-size:14px;font-weight:600;color:var(--ink)}
.ob-why{display:flex;flex-wrap:wrap;gap:6px;margin-top:6px}
.ob-why i{font-style:normal;padding:4px 10px;border-radius:999px;background:color-mix(in srgb,var(--accent) 14%,var(--card));font-size:13px;font-weight:600;color:var(--ink)}
.ob-plan2{margin:0 0 12px;padding:16px 18px;border-radius:22px;background:color-mix(in srgb,var(--accent) 9%,var(--surface));border:1px solid color-mix(in srgb,var(--accent) 35%,var(--line))}
.ob-plan2 b{display:block;font-size:13px;font-weight:700;letter-spacing:.04em;text-transform:uppercase;color:var(--accent-text,var(--accent))}
[dir=rtl] .ob-plan2 b{letter-spacing:0;text-transform:none;font-size:14px}
.ob-plan2 p{margin:4px 0 0;font-size:16px;line-height:1.45}

/* progress to the end of the surah: one thin line under the page card, drawn once a first lesson is done; and on the lesson's end page */
.sbar{--p:0%;background:linear-gradient(var(--dir),var(--accent) var(--p),var(--line) var(--p))}
.page-card>.sbar{position:absolute;z-index:1;left:0;right:0;bottom:0;height:3px;border-radius:0}
.sbar-line{display:flex;flex-direction:column;gap:6px;margin:6px auto 0;width:min(240px,70%);text-align:center;font-size:13px;color:var(--muted)}
.sbar-line .sbar{height:4px}
/* No Qari: nothing of the reciter plays, so the buttons that play him are not drawn */
body.noq [data-action=sheet-hear]{display:none}

/* ---- 1 November (his words, 07:35): the Qari box, the guide to choosing, the how-it-works lines, the note, and the lesson's new bottom box ---- */
/* one box for learning with a Qari: its two voices inside it; the other way is its own card. The recommended one is first and chosen already. */
.ob-qhead{display:flex;align-items:center;gap:14px;width:100%;box-sizing:border-box;padding:16px 18px;border:0;background:none;color:var(--ink);font:inherit;text-align:start;cursor:pointer}
.ob-vsel{flex:1;min-width:0;min-height:44px;padding:0 10px;border:0;border-radius:12px;background:none;color:var(--ink);font:inherit;font-size:16px;font-weight:650;text-align:start;cursor:pointer}
/* ux1 (8 Nov): the chosen reciter shows the same round tick as Learn without a Qari; the others an empty ring */
/* the guide to choosing: a little page, a dot that holds the first line and slides to the last, three big lines */
.ob-demo{position:relative;flex:none;display:flex;flex-direction:column;justify-content:space-between;box-sizing:border-box;width:210px;height:166px;margin:20px auto 4px;padding:16px 18px;border-radius:22px;background:var(--surface);border:1px solid var(--line);box-shadow:var(--shadow);overflow:hidden}
.ob-demo i{display:block;height:8px;border-radius:4px;background:var(--line)}
.ob-demo i:last-of-type{width:60%}
.ob-dband{position:absolute;inset-inline:10px;top:10px;bottom:10px;border-radius:14px;background:color-mix(in srgb,var(--accent) 22%,transparent);transform-origin:top;transform:scaleY(0);animation:ob-band 3.8s var(--ease) infinite}
.ob-ddot{position:absolute;inset-inline-start:22px;top:6px;width:20px;height:20px;border-radius:50%;background:var(--accent-grad);box-shadow:0 0 0 7px color-mix(in srgb,var(--accent) 24%,transparent);opacity:0;animation:ob-dot 3.8s var(--ease) infinite}
@keyframes ob-band{0%,16%{transform:scaleY(0)}62%,88%{transform:scaleY(1)}100%{transform:scaleY(1);opacity:0}}
@keyframes ob-dot{0%{opacity:0;transform:translateY(0) scale(.6)}8%{opacity:1;transform:translateY(0) scale(1)}16%{transform:translateY(0) scale(1.2)}62%,88%{opacity:1;transform:translateY(128px) scale(1)}100%{opacity:0;transform:translateY(128px) scale(1)}}
@media (prefers-reduced-motion:reduce){.ob-dband{animation:none;transform:scaleY(.8)}.ob-ddot{animation:none;opacity:1;transform:translateY(112px)}}
.ob-steps{list-style:none;margin:18px 0 0;padding:0;display:flex;flex-direction:column;gap:10px}
.ob-steps li{display:flex;align-items:center;gap:14px;padding:14px 16px;border-radius:20px;background:var(--surface);border:1px solid var(--line);box-shadow:var(--shadow)}
.ob-steps .ob-n{flex:none;display:inline-flex;align-items:center;justify-content:center;width:40px;height:40px;border-radius:50%;background:var(--accent-grad);color:var(--accent-ink);font-size:17px;font-weight:800;font-variant-numeric:tabular-nums}
.ob-steps .ob-t strong{font-size:19px;line-height:1.3}
.ob-guide .ob-steps .ob-t strong{font-size:20px}
.ob-how li{padding:16px}
.ob-steps .ob-chip{flex:none;background:color-mix(in srgb,var(--accent) 16%,var(--card));color:var(--accent-text,var(--accent));font-weight:700}

/* the lesson's bottom box (his words: "I dont want to look like a playable audio lesson"): one rounded box. Above: the ayah before, pause or play,
   the next ayah, with words on them. Below: again, and the next step. Help sits up beside the intro button. */
.lesson-screen .control-row.deck{display:flex;flex-direction:column;align-items:stretch;gap:6px;height:auto;margin:0 8px 4px;padding:8px 10px;border-radius:28px;background:var(--surface);box-shadow:0 0 0 1px var(--line),0 14px 30px -16px rgba(0,0,0,.4)}
.deck-main{display:grid;grid-template-columns:1fr auto 1fr;align-items:center;gap:10px}
.deck .ctl.ayah-back,.deck .ctl.ayah-next{flex-direction:row;width:auto;max-width:none;height:46px;gap:6px;padding:0 16px;border-radius:23px;background:var(--card);color:var(--ink)}
.deck .ctl.ayah-back{justify-self:start}.deck .ctl.ayah-next{justify-self:end}
.deck .ctl span{font-size:15px;font-weight:650;line-height:1;color:inherit}
.deck .ctl svg{width:19px;height:19px}
.lesson-controls .deck .fab{width:54px;height:54px;box-shadow:0 6px 16px -6px var(--glow)}
.lesson-controls .deck .fab svg{width:24px;height:24px}
.deck-sub{display:grid;grid-template-columns:1fr 1.5fr;gap:8px}
.deck .ctl.again,.deck .ctl.plus-one{flex-direction:row;justify-content:center;gap:8px;width:100%;max-width:none;height:38px;border-radius:19px}
.deck .ctl.again{background:none;box-shadow:inset 0 0 0 1.5px var(--line);color:var(--ink)}
.deck .ctl.plus-one{background:color-mix(in srgb,var(--accent) 16%,var(--surface));color:var(--accent-text,var(--accent))}
.deck .ctl:active:not(:disabled){background:var(--card);color:var(--ink)}
.step-row .ctl.help.pill{display:inline-flex;flex-direction:row;align-items:center;flex:none;gap:6px;width:auto;max-width:none;height:auto;min-height:38px;margin-inline-start:auto;padding:0 14px;border-radius:999px;background:var(--surface);box-shadow:var(--shadow);color:var(--ink)}
.step-row .ctl.help.pill span{font-size:14px;font-weight:600;line-height:1;color:var(--ink)}
.step-row .ctl.help.pill svg{width:17px;height:17px;color:var(--accent)}
.step-row .ctl.help[hidden]{display:none}
/* the caption and the note float just above the box (they were placed above a 52 px row) */
.lesson-screen:has(.deck){--stage-bottom:calc(max(12px,env(safe-area-inset-bottom)) + 166px)}    /* the page is fitted to the room above the box and the row over it */
.lesson-controls:has(.deck)>.caption{bottom:calc(108px + max(4px,env(safe-area-inset-bottom)) + 2px)}
.lesson-controls:has(.deck):has(>.caption:not([hidden]))>.notice{bottom:calc(108px + max(4px,env(safe-area-inset-bottom)) + 8px + var(--cap-h,0px))}
.panel-jumps .wide{grid-column:1/-1}

/* PM L-408: the hafidh result, minimal: the lines, one recommendation, Start revision, Finish */
.ob-res .ob-lines{display:flex;flex-direction:column;gap:10px;margin:6px 0 0}
.ob-res .ob-lines p{margin:0;font-size:18px;line-height:1.45;color:var(--ink)}
.ob-res .ob-rec{margin:0 0 14px;font-size:17px;font-weight:650;line-height:1.45;color:var(--ink)}

/* L-749 (idea 5): the one question after sign up: a title and two large plain choices, no Skip, no steps */
.ob-ask{justify-content:center;padding-bottom:max(48px,env(safe-area-inset-bottom))}
.ob-ask .ob-h{margin:0 2px 8px}
.ob-choice{display:block;width:100%;box-sizing:border-box;min-height:76px;padding:18px 20px;border:0;border-radius:14px;background:var(--card,var(--surface));color:var(--ink);font:inherit;font-size:20px;font-weight:650;text-align:start;cursor:pointer}
.ob-choice:active{transform:scale(.985)}.ob-choice:focus-visible{outline:2px solid var(--accent);outline-offset:2px}
.ob-ask .ob-h:focus{outline:0}.ob-choice:focus:not(:focus-visible){outline:0;box-shadow:none}
