/* ============================================================
   פורטל ההקלטות · שכבת העיצוב
   נייר, דיו וכתום אחד. הצבעים והגופנים זהים לדף המכירה של
   ההקלטות, כי זה מה שהקונה ראה שניות לפני שנכנס לכאן.
   ============================================================ */

:root{
  /* ---- נייר ודיו ---- */
  --paper:#FCF9F2; --paper-2:#F4EEDF; --paper-3:#EAE2D2; --surface:#fff;
  --navy:#080D2F; --ink:#29304B; --dim:#66708E;
  --line:rgba(8,13,47,.13); --line-2:rgba(8,13,47,.07);
  --shadow:0 2px 10px -6px rgba(8,13,47,.28);
  --shadow-lg:0 18px 44px -20px rgba(8,13,47,.35);

  /* ---- הדגש היחיד ---- */
  --orange:#F38420; --orange-dark:#D96D0C; --orange-soft:#FFE8CE;
  /* 🔴 נמדד: לבן על הכתום הזה נותן 2.6:1 ונכשל. נייבי נותן 6.6:1.
     ולכן כל שטח כתום נושא טקסט נייבי, בדיוק כמו בדפי המכירה. */
  --on-orange:#080D2F;

  --ok:#0FA98D; --ok-ink:#0B7A65; --warn:#92400E; --bad:#C0392B;

  --bg:var(--paper);
  --safe-b:env(safe-area-inset-bottom,0px);
  --radius:18px; --radius-sm:12px;
  --bar-h:0px;          /* גובה הבאר התחתון. נדרס בטלפון */
  --mini-h:0px;         /* גובה הנגן המיני כשהוא פתוח */

  --f-head:Rubik,'Heebo',system-ui,sans-serif;
  --f-body:Alef,'Heebo',system-ui,sans-serif;
}

/* מצב כהה. הטוקנים בלבד מתחלפים, ואף רכיב לא מגדיר צבע בתוך הבלוק
   הזה, אחרת הצבע קיים רק במצב אחד. */
:root[data-theme="dark"]{
  --paper:#0B1024; --paper-2:#121936; --paper-3:#1B2447; --surface:#111834;
  --navy:#F2F5FF; --ink:#DDE3F5; --dim:#98A2C4;
  --line:rgba(255,255,255,.14); --line-2:rgba(255,255,255,.07);
  --shadow:0 2px 10px -6px rgba(0,0,0,.6);
  --shadow-lg:0 18px 44px -20px rgba(0,0,0,.8);
  --orange:#F79A45; --orange-dark:#FFB266; --orange-soft:rgba(243,132,32,.16);
  --on-orange:#0B1024;
  --ok:#2ECFAE; --ok-ink:#2ECFAE; --warn:#F0B85E; --bad:#F0685A;
}

*{box-sizing:border-box;margin:0;padding:0}
html{-webkit-text-size-adjust:100%}
body{font-family:var(--f-body);background:var(--bg);color:var(--ink);
     line-height:1.6;-webkit-font-smoothing:antialiased}
button,input,select,textarea{font-family:inherit}
h1,h2,h3,h4{font-family:var(--f-head);color:var(--navy);letter-spacing:-.02em;
  text-wrap:balance;font-weight:800}
/* מספרים ברוחב אחיד, ותמיד משמאל לימין כמו שעון */
.num,time,.t2 span+span{font-variant-numeric:tabular-nums}
.ltr{direction:ltr;unicode-bidi:isolate}

/* טבעת מיקוד אחת לכל האלמנטים שאפשר להגיע אליהם במקלדת.
   🔴 לעולם לא כתום על כתום: על שטח כתום הטבעת נייבי, ובכהה ענבר. */
:focus-visible{outline:3px solid var(--navy);outline-offset:2px;border-radius:8px}
[style*="background:var(--orange)"]:focus-visible,
.btn.cta:focus-visible,.tab.on:focus-visible{outline-color:var(--navy)}
:root[data-theme="dark"] :focus-visible{outline-color:#FFB266}

.sr-only{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;
  clip:rect(0 0 0 0);white-space:nowrap;border:0}
.skip{position:absolute;inset-inline-start:8px;top:-60px;z-index:200;background:var(--surface);
  border:2px solid var(--orange-dark);border-radius:10px;padding:10px 16px;font-weight:700;
  color:var(--ink);text-decoration:none;transition:top .15s}
.skip:focus{top:8px}
@media (prefers-reduced-motion:reduce){
  *,*::before,*::after{animation-duration:.01ms !important;transition-duration:.01ms !important}
  html{scroll-behavior:auto}
}

/* ---------- שער ---------- */
#gate{position:fixed;inset:0;z-index:100;background:var(--paper);display:flex;
      flex-direction:column;align-items:center;justify-content:center;padding:24px;text-align:center}
#gate h1{font-weight:900;font-size:clamp(1.7rem,6vw,2.3rem);color:var(--navy);margin-bottom:.5rem}
#gate p{color:var(--dim);margin-bottom:1.5rem;max-width:24rem}
#gate input{font-size:1.2rem;text-align:center;padding:14px 20px;border:2px solid var(--line);
            border-radius:12px;margin-bottom:1rem;width:100%;max-width:320px;outline:none;
            background:var(--surface);color:var(--ink)}
#gate input:focus{border-color:var(--orange)}
#gate button{background:var(--orange);color:var(--on-orange);border:0;padding:15px 32px;
             font-size:1.05rem;font-weight:800;border-radius:12px;width:100%;max-width:320px;
             cursor:pointer;min-height:52px;font-family:var(--f-head)}
#gate button:hover{background:var(--orange-dark)}
#gate .err{color:var(--bad);margin-top:1rem;font-weight:700;visibility:hidden}

/* ---------- שלד ---------- */
#app{display:none;max-width:1180px;margin:0 auto;overflow-x:clip;
  padding:16px 16px calc(32px + var(--safe-b) + var(--bar-h) + var(--mini-h))}
header{display:flex;align-items:center;justify-content:space-between;gap:12px;
  margin-bottom:18px;flex-wrap:wrap}
header h1{font-weight:900;font-size:1.35rem;color:var(--navy)}
header .sub{color:var(--dim);font-size:.88rem}

/* מסכים. אחד פעיל בכל רגע, והמעבר ביניהם הוא החלפת מחלקה בלבד. */
.screen{display:none}
.screen.is-active{display:block}
/* 🔴 המסך הזה מחזיק את הנגן, ולכן הוא לעולם לא נמחק מהתצוגה.
   נמדד בכרום: display:none על אב של video אינו עוצר את הניגון
   (הווידאו התקדם 2.50 שניות בדיוק ב-2.5 שניות שעון). אבל בספארי
   באייפון זה לא נבדק כאן, ושם רוב הצופים. לכן במקום למחוק מהתצוגה,
   המסך מוזז אל מחוץ לחלון, וכך הניגון מובטח בכל מנוע. */
/* 🔴 הניסיון הראשון היה ‎top:-200vh‎, וזה נכשל בעין: המסך הזה גבוה
   מ-200vh (44 שורות), ולכן הזנב שלו חזר לתוך החלון ודלף מעל דף
   ההעמקה. הזזה לא מספיקה כשלא יודעים את הגובה. לכן קיצוץ לגובה
   פיקסל אחד עם ‎overflow:hidden‎: האלמנט נשאר בעץ הרינדור והניגון
   ממשיך, ואין שום דבר לראות. */
#screen-conf:not(.is-active){display:block;position:fixed;top:0;
  inset-inline-start:0;width:100%;height:1px;overflow:hidden;opacity:0;
  pointer-events:none;z-index:-1}

/* ‎minmax(0,1fr)‎ ולא ‎1fr‎: לעמודת גריד יש רוחב מינימלי אוטומטי, ולכן
   שם מרצה ארוך מותח את כל הפריסה מעבר לרוחב המסך. נמדד בטלפון —
   375 פיקסל נראים, 533 בפועל, וחצי מהנגן יוצא מהמסך. */
.layout{display:grid;grid-template-columns:minmax(0,1fr);gap:20px}
@media(min-width:900px){.layout{grid-template-columns:minmax(0,2fr) minmax(300px,1fr);align-items:start}}

/* ---------- נגן ---------- */
.stage-wrap{position:relative;width:100%;aspect-ratio:16/9;background:#05070F;
            border-radius:var(--radius);overflow:hidden;box-shadow:var(--shadow-lg)}
.stage-mount{position:absolute;inset:0}
.stage-wrap video,.stage-wrap iframe{width:100%;height:100%;display:block;border:0}
.drive-cover{position:absolute;inset:0;width:100%;height:100%;border:0;padding:0;
  cursor:pointer;background:#000 center/cover no-repeat;display:flex;
  align-items:center;justify-content:center}
.drive-cover::after{content:'';position:absolute;inset:0;background:rgba(5,7,15,.32)}
.drive-play{position:relative;z-index:1;width:74px;height:74px;border-radius:50%;
  background:var(--orange);box-shadow:0 8px 26px rgba(0,0,0,.45)}
.drive-play::before{content:'';position:absolute;top:50%;left:50%;
  transform:translate(-46%,-50%);border-style:solid;border-width:15px 0 15px 24px;
  border-color:transparent transparent transparent #080D2F}
.drive-cover:hover .drive-play{background:#FF9838}

/* פס הבקרה של הנגן הוא בגובה קבוע ולא באחוזים, ולכן ההרחקה ממנו
   נמדדת בפיקסלים. אחרת הכתובית יושבת עליו בדיוק כשמזיזים עכבר. */
.cap-layer{position:absolute;inset-inline:0;bottom:56px;display:flex;justify-content:center;
           pointer-events:none;padding:0 4%;z-index:2}
@media(max-width:640px){.cap-layer{bottom:44px;padding:0 3%}}
.cap-layer .cap{
  background:rgba(8,13,47,.82);
  -webkit-backdrop-filter:blur(6px);backdrop-filter:blur(6px);
  color:rgba(255,255,255,.68);
  font-size:clamp(1rem,2.1vw,1.3rem);
  font-weight:400;line-height:1.5;letter-spacing:-.01em;
  padding:.42em .9em;border-radius:14px;
  text-align:center;max-width:min(100%,46ch);
  text-shadow:0 2px 10px rgba(0,0,0,.65);
  box-shadow:0 10px 30px rgba(0,0,0,.4);
}
.stage-wrap:fullscreen{width:100vw;height:100vh;aspect-ratio:auto;border-radius:0}
.stage-wrap:-webkit-full-screen{width:100vw;height:100vh;border-radius:0}
.stage-wrap:fullscreen video{object-fit:contain}
.stage-wrap:fullscreen .cap-layer{bottom:9vh}
.stage-wrap:fullscreen .cap-layer .cap{font-size:clamp(1.1rem,1.9vw,1.7rem)}
/* מה שכבר נאמר בלבן מלא, המילה שנאמרת עכשיו בענבר, וההמשך עמום. */
.cap-layer .cap i{font-style:normal;transition:color .1s linear}
.cap-layer .cap i.said{color:#fff}
.cap-layer .cap i.now{color:#FFB35C;text-shadow:0 0 14px rgba(255,179,92,.5),0 2px 10px rgba(0,0,0,.7)}
.cap-layer:empty{display:none}
@media (prefers-reduced-motion:reduce){.cap-layer .cap i{transition:none}}
.placeholder{position:absolute;inset:0;display:grid;place-items:center;color:#fff;
             text-align:center;padding:24px;background:#080D2F;font-family:var(--f-head)}
.placeholder small{color:#98A2C4;display:block;margin-top:8px;font-family:var(--f-body)}

/* ---------- פס הבקרה שלנו ----------
   הנגן של הדפדפן נראה אחרת בכל מערכת הפעלה, וציר הזמן שלו מתהפך
   בעברית. לכן פס משלנו, וכל הפס כולו LTR כמו שעון. */
.pbar{margin-top:12px;background:var(--surface);border:1px solid var(--line);
  border-radius:var(--radius-sm);padding:8px 12px 10px;box-shadow:var(--shadow);
  display:none}
.pbar.live{display:block}
.pbar .seek{direction:ltr;position:relative;height:26px;display:flex;align-items:center;
  cursor:pointer;touch-action:none}
.pbar .seek .rail{position:absolute;inset-inline:0;height:6px;border-radius:3px;
  background:var(--paper-3);overflow:hidden}
.pbar .seek .buf{position:absolute;inset-block:0;left:0;background:var(--line);width:0}
.pbar .seek .fill{position:absolute;inset-block:0;left:0;background:var(--orange);width:0}
.pbar .seek .knob{position:absolute;left:0;width:15px;height:15px;border-radius:50%;
  background:var(--orange);border:2.5px solid var(--surface);
  box-shadow:0 2px 6px rgba(8,13,47,.35);transform:translateX(-50%);pointer-events:none}
/* סימוני הפרקים יושבים על הפס עצמו, כי שם העין כבר נמצאת */
.pbar .seek .ch{position:absolute;top:50%;width:2px;height:11px;margin-top:-5.5px;
  background:var(--dim);opacity:.5;pointer-events:none}
.pbar .row2{display:flex;align-items:center;gap:6px;margin-top:6px}
.pbar .time{direction:ltr;font-family:var(--f-head);font-size:12.5px;color:var(--dim);
  font-variant-numeric:tabular-nums;flex:none;min-width:92px}
.pbar .time b{color:var(--navy);font-weight:700}
/* יעד מגע: 44 ולא 38. נמדד בשער, ו-38 נכשל. */
.cbtn{background:none;border:0;padding:0;width:44px;height:44px;border-radius:11px;
  cursor:pointer;color:var(--ink);display:grid;place-items:center;flex:none}
.cbtn:hover{background:var(--paper-2);color:var(--navy)}
.cbtn svg{width:19px;height:19px;fill:none;stroke:currentColor;stroke-width:2;
  stroke-linecap:round;stroke-linejoin:round}
.cbtn.play svg{width:22px;height:22px}
.cbtn.on{color:var(--orange-dark);background:var(--orange-soft)}
/* ‎1×‎ בהקשר עברי מתהפך ל-‎×1‎. חייב כיוון מפורש. */
.cbtn.rate{width:auto;min-width:44px;padding:0 8px;font-family:var(--f-head);
  font-weight:700;font-size:13.5px;direction:ltr;unicode-bidi:isolate}
.pbar .grow{flex:1}
.pbar .chip{font-size:12px;color:var(--dim);font-family:var(--f-head);
  white-space:nowrap;overflow:hidden;text-overflow:ellipsis;max-width:40%}

.bar{display:flex;gap:8px;flex-wrap:wrap;align-items:center;margin-top:12px}
.btn{background:var(--surface);border:1px solid var(--line);border-radius:11px;padding:10px 15px;
     font-weight:700;font-size:.9rem;cursor:pointer;color:var(--ink);white-space:nowrap;
     font-family:var(--f-head);min-height:44px}
.btn:hover{background:var(--orange-soft);border-color:var(--orange);color:var(--orange-dark)}
.btn[disabled]{opacity:.4;cursor:not-allowed}
.btn.primary{background:var(--navy);color:var(--paper);border-color:var(--navy)}
.btn.primary:hover{background:var(--ink);color:var(--paper)}
@media(min-width:520px){.btn.primary{margin-inline-start:auto}}
@media(max-width:519px){.bar{display:grid;grid-template-columns:1fr 1fr}
  .btn.primary{grid-column:1/-1}}
.btn.primary.done{background:var(--ok);border-color:var(--ok);color:#04231D}
.btn.cta{background:var(--orange);border-color:var(--orange);color:var(--on-orange)}
.btn.cta:hover{background:var(--orange-dark);color:var(--on-orange)}
.notice{margin-top:12px;background:var(--orange-soft);border:1px solid var(--orange);
        color:var(--warn);border-radius:12px;padding:10px 14px;font-size:.88rem;display:none}
.notice.show{display:block}
.notice{position:relative;padding-inline-end:44px}
.notice .nx{position:absolute;inset-inline-end:4px;top:2px;background:none;border:0;
  color:var(--warn);font-size:15px;cursor:pointer;min-width:44px;min-height:44px;
  border-radius:10px}
.notice .nx:hover{background:rgba(146,64,14,.1)}

/* ---------- מה מתנגן עכשיו ---------- */
.now{margin-top:16px;display:flex;gap:14px;align-items:flex-start}
.now .face{width:56px;height:56px;border-radius:14px;flex:none;object-fit:cover;
  background:var(--paper-3);box-shadow:var(--shadow)}
.now .nt{flex:1;min-width:0}
.now h2{font-size:1.2rem;font-weight:800;line-height:1.3}
.now .who{color:var(--dim);font-size:.9rem;margin-top:2px}
.now .note{margin-top:.5rem;font-size:.84rem;line-height:1.5;color:var(--dim);
  border-inline-start:3px solid var(--orange);padding-inline-start:.6rem}

/* ---------- כרטיסים ---------- */
.card{background:var(--surface);border:1px solid var(--line);border-radius:var(--radius);
      padding:15px;box-shadow:var(--shadow)}
.search{margin-top:18px}
.search h3{font-size:1rem;margin-bottom:10px}
.search input,.qbox input{width:100%;padding:12px 14px;border:1px solid var(--line);
  border-radius:11px;font-size:1rem;outline:none;background:var(--paper);color:var(--ink);
  min-height:46px}
.search input:focus,.qbox input:focus{border-color:var(--orange)}
.hits{max-height:min(58vh,520px);overflow-y:auto;overscroll-behavior:contain;
  margin-top:10px;display:flex;flex-direction:column;gap:8px}
.hit{padding:10px 12px;background:var(--paper);border:1px solid transparent;border-radius:10px;
     cursor:pointer;font-size:.9rem;text-align:right;font:inherit;color:inherit;
     font-size:.9rem;width:100%}
.hit:hover{border-color:var(--orange);background:var(--orange-soft)}
.hit b{display:block;color:var(--orange-dark);font-size:.78rem;margin-bottom:3px;font-weight:800;
  font-family:var(--f-head);font-variant-numeric:tabular-nums;direction:ltr;text-align:right}
.hit mark{background:var(--orange-soft);color:var(--orange-dark);border-radius:3px;padding:0 2px;
  font-weight:700}
.hit .where{display:block;color:var(--dim);font-size:.76rem;margin-top:4px}
.hit.other{background:var(--surface);border-color:var(--line)}
.hits-head{font-size:.8rem;color:var(--dim);font-weight:700;margin:12px 0 2px;
  padding-top:10px;border-top:1px solid var(--line);font-family:var(--f-head)}

/* ---------- רשימת השיעורים ---------- */
.side{display:flex;flex-direction:column;gap:14px}
.day{background:var(--surface);border:1px solid var(--line);border-radius:var(--radius);
  padding:14px;box-shadow:var(--shadow)}
.day-top{display:flex;justify-content:space-between;align-items:center;gap:8px;margin-bottom:10px}
.day-top h3{font-size:1.02rem;font-weight:800}
.day-top span{font-size:.8rem;color:var(--dim);font-weight:700;font-family:var(--f-head);
  font-variant-numeric:tabular-nums}
.track{height:6px;background:var(--paper-3);border-radius:3px;overflow:hidden;margin-bottom:12px}
.track i{display:block;height:100%;background:var(--orange);width:0;transition:width .3s}
/* שורת הרצאה היא button ולא div: 44 השורות היו בלתי נגישות מהמקלדת
   ומקורא המסך, וזה הכשל הנגישותי הגדול ביותר שהיה כאן. */
.row{display:flex;align-items:center;gap:11px;padding:9px;border-radius:13px;cursor:pointer;
     border:1px solid transparent;background:var(--paper);margin-bottom:7px;width:100%;
     text-align:right;font:inherit;color:inherit;min-height:60px;
     transition:border-color .15s,background .15s}
.row:hover{border-color:var(--orange);background:var(--orange-soft)}
.row.active{border-color:var(--orange);background:var(--orange-soft);
  box-shadow:inset 0 0 0 1px var(--orange)}
.row[hidden]{display:none}
/* תצלום המרצה במקום פריים מהווידאו. הפריים הראשון של הקלטה חיה
   הוא כמעט תמיד המרצה הקודם או שקופית ריקה. */
.row .thumb{display:block;width:46px;height:46px;border-radius:12px;flex:0 0 auto;
  overflow:hidden;background:var(--paper-3)}
.row .thumb img{width:100%;height:100%;object-fit:cover;display:block}
.row .txt{display:block;flex:1 1 auto;min-width:0}
.row .t1{display:block;font-size:.92rem;font-weight:700;overflow:hidden;
  text-overflow:ellipsis;white-space:nowrap}
.row .t2{font-size:.77rem;color:var(--dim);display:flex;gap:8px;margin-top:1px}
.row .t2 > span:first-child{overflow:hidden;text-overflow:ellipsis;white-space:nowrap;min-width:0}
.row .t2 > span + span{flex:0 0 auto;margin-inline-start:auto;font-family:var(--f-head);
  font-variant-numeric:tabular-nums}
.row .tick{width:21px;height:21px;border-radius:50%;border:2px solid var(--line);flex:0 0 auto;
           display:grid;place-items:center;font-size:11px;color:#fff;font-weight:800}
.row.done .tick{background:var(--ok);border-color:var(--ok)}
.row.done .tick::after{content:'✓'}
.mini{display:block;height:3px;background:var(--line);border-radius:2px;margin-top:5px;
  overflow:hidden}
.mini i{display:block;height:100%;background:var(--orange);width:0}

/* ---------- התקנת האפליקציה ---------- */
.install-chip{display:flex;align-items:flex-start;gap:4px;width:100%;
  background:var(--orange-soft);border:1.5px dashed var(--orange);border-radius:var(--radius);
  padding:6px;margin:0 0 14px;color:var(--ink)}
.install-chip .ic-main{flex:1;min-width:0;display:flex;align-items:center;gap:12px;
  text-align:right;background:none;border:0;padding:4px 6px;cursor:pointer;
  font:inherit;color:inherit}
.install-chip img{border-radius:10px;flex:none}
.install-chip .c1{font-weight:700;font-family:var(--f-head)}
.install-chip .c2{font-size:13px;color:var(--dim)}
.install-chip .ic-x{flex:none;background:none;border:0;color:var(--dim);
  font-size:16px;line-height:1;min-width:44px;min-height:44px;cursor:pointer;border-radius:9px}
.install-chip .ic-x:hover{background:rgba(8,13,47,.08);color:var(--ink)}
.sheet-backdrop{position:fixed;inset:0;background:rgba(8,13,47,.55);z-index:120;
  display:flex;align-items:flex-end;justify-content:center}
.sheet-backdrop[hidden]{display:none}
.sheet{background:var(--surface);width:min(560px,100%);border-radius:22px 22px 0 0;
  padding:10px 20px calc(24px + var(--safe-b));max-height:88dvh;overflow:auto}
.sheet-handle{width:44px;height:5px;border-radius:99px;background:var(--line);margin:6px auto 14px}
.sheet h3{margin:0 0 6px;font-size:19px}
.sheet .faint{color:var(--dim);font-size:14px}
.ig-step{display:flex;gap:12px;align-items:flex-start;margin:12px 0;line-height:1.55}
.ig-num{flex:none;width:26px;height:26px;border-radius:50%;background:var(--orange);
  color:var(--on-orange);font-weight:800;display:flex;align-items:center;justify-content:center;
  font-size:14px;font-family:var(--f-head)}
.ig-glyph{display:inline-flex;vertical-align:-4px;color:#0A84FF;margin:0 3px}
.ig-glyph svg{width:19px;height:19px}
.ig-cta{display:block;width:100%;margin-top:14px;background:var(--orange);color:var(--on-orange);
  border:0;border-radius:12px;padding:14px;font:inherit;font-weight:800;font-size:16px;
  cursor:pointer;min-height:48px;font-family:var(--f-head)}
.ig-x{display:block;width:100%;margin-top:8px;background:none;border:0;color:var(--dim);
  font:inherit;font-size:14px;cursor:pointer;padding:12px;min-height:44px;border-radius:10px}
.ig-x:hover{background:var(--paper-2);color:var(--ink)}

/* ---------- הובלה למאסטר ספיקר פרו ---------- */
.msp-card{background:var(--navy);color:#fff;border-radius:var(--radius);padding:16px;margin:0 0 14px}
.msp-card .mark{font-weight:800;font-size:15px;letter-spacing:.06em;direction:ltr;text-align:right;
  font-family:var(--f-head)}
.msp-card .mark b{color:var(--orange)}
.msp-card p{margin:8px 0 12px;font-size:14px;line-height:1.55;color:#C7CDEA}
.msp-card a{display:block;text-align:center;background:var(--orange);color:#080D2F;font-weight:800;
  border-radius:999px;padding:12px 16px;text-decoration:none;font-size:15px;font-family:var(--f-head)}

/* ---------- סיכום ומשימות ---------- */
.docbar{display:flex;gap:10px;margin-top:12px;flex-wrap:wrap}
.docbar a{flex:1;min-width:150px;text-align:center;border:1.5px solid var(--line);border-radius:12px;
  padding:11px 14px;text-decoration:none;color:var(--ink);font-weight:700;background:var(--surface);
  min-height:48px;display:flex;align-items:center;justify-content:center;font-family:var(--f-head);
  font-size:.92rem}
.docbar a:hover{border-color:var(--orange);color:var(--orange-dark);background:var(--orange-soft)}
.foot{margin-top:26px;padding-top:14px;border-top:1px solid var(--line);text-align:center;
  font-size:13px;color:var(--dim)}
.foot a{color:var(--dim);display:inline-flex;align-items:center;min-height:44px;padding:0 12px;
  border-radius:10px}
.foot a:hover{color:var(--ink);background:var(--surface)}

/* ---------- מסנן הרשימה ---------- */
.filter{position:relative;margin-bottom:12px}
.filter input{width:100%;padding:12px 40px 12px 14px;border:1px solid var(--line);
  border-radius:12px;font-size:.95rem;background:var(--surface);outline:none;min-height:46px;
  color:var(--ink)}
.filter input:focus{border-color:var(--orange)}
.filter .fx{position:absolute;inset-inline-start:4px;top:50%;transform:translateY(-50%);
  background:none;border:0;color:var(--dim);font-size:15px;cursor:pointer;
  min-width:38px;min-height:38px;border-radius:9px;display:none}
.filter.has .fx{display:block}
.filter .fx:hover{background:var(--paper-2);color:var(--ink)}
.filter-none{padding:14px;text-align:center;color:var(--dim);font-size:.9rem}

/* ---------- התקדמות כוללת ---------- */
.overall{display:flex;align-items:center;gap:10px;margin-bottom:14px;font-size:.85rem;
  color:var(--dim);flex-wrap:wrap}
.overall .bar2{flex:1 1 140px;height:8px;background:var(--paper-3);border-radius:4px;overflow:hidden}
@media(max-width:520px){.overall .bar2{flex-basis:100%}}
.overall .bar2 i{display:block;height:100%;background:var(--ok);width:0;transition:width .3s}
.overall b{color:var(--navy);font-weight:800;font-family:var(--f-head)}

.allbtn{display:block;width:100%;margin-top:10px;background:var(--surface);
  border:1.5px solid var(--line);border-radius:12px;padding:12px;font:inherit;
  font-weight:700;font-size:.9rem;color:var(--ink);cursor:pointer;min-height:46px;
  font-family:var(--f-head)}
.allbtn:hover{border-color:var(--orange);background:var(--orange-soft);color:var(--orange-dark)}
.allbtn[disabled]{opacity:.55;cursor:progress}

/* ============================================================
   הבאר התחתון והנגן המיני
   הבאר קיים בטלפון בלבד. במחשב יש מקום לשתי עמודות, ובאר תחתון שם
   הוא רעש. הנגן המיני הוא מה שהופך את הבאר לאפשרי בכלל: בלעדיו כל
   מעבר בין מסכים היה הורג את הניגון.
   ============================================================ */
.tabbar{position:fixed;inset-inline:0;bottom:0;z-index:60;display:none;
  background:var(--surface);border-top:1px solid var(--line);
  padding-bottom:var(--safe-b);box-shadow:0 -6px 24px -14px rgba(8,13,47,.4)}
.tabbar ul{display:flex;list-style:none;margin:0;padding:0}
.tab{flex:1;background:none;border:0;padding:7px 2px 6px;cursor:pointer;color:var(--dim);
  display:flex;flex-direction:column;align-items:center;gap:3px;min-height:56px;
  font-family:var(--f-head);font-size:11.5px;font-weight:700;position:relative}
.tab svg{width:22px;height:22px;fill:none;stroke:currentColor;stroke-width:1.9;
  stroke-linecap:round;stroke-linejoin:round}
.tab.on{color:var(--orange-dark)}
.tab.on::before{content:'';position:absolute;top:0;inset-inline:22%;height:3px;
  border-radius:0 0 3px 3px;background:var(--orange)}
.tab .dot{position:absolute;top:5px;inset-inline-end:calc(50% - 17px);width:7px;height:7px;
  border-radius:50%;background:var(--orange);display:none}
.tab.has-dot .dot{display:block}

.miniplayer{position:fixed;inset-inline:0;z-index:59;display:none;
  background:var(--navy);color:#fff;align-items:center;gap:10px;padding:8px 12px;
  border-top:1px solid rgba(255,255,255,.1)}
.miniplayer.live{display:flex}
.miniplayer img{width:38px;height:38px;border-radius:10px;object-fit:cover;flex:none;
  background:#1B2447}
.miniplayer .mt{flex:1;min-width:0}
.miniplayer .m1,.miniplayer .m2{display:block}
.miniplayer .m1{font-size:13px;font-weight:700;overflow:hidden;text-overflow:ellipsis;
  white-space:nowrap;font-family:var(--f-head)}
.miniplayer .m2{font-size:11.5px;color:#98A2C4;overflow:hidden;text-overflow:ellipsis;
  white-space:nowrap}
.miniplayer button{background:none;border:0;color:#fff;cursor:pointer;width:40px;height:40px;
  border-radius:10px;display:grid;place-items:center;flex:none}
.miniplayer button:hover{background:rgba(255,255,255,.12)}
.miniplayer svg{width:20px;height:20px;fill:none;stroke:currentColor;stroke-width:2;
  stroke-linecap:round;stroke-linejoin:round}
.miniplayer .mprog{position:absolute;inset-inline:0;top:0;height:2px;background:rgba(255,255,255,.14)}
.miniplayer .mprog i{display:block;height:100%;background:var(--orange);width:0}

@media(max-width:899px){
  :root{--bar-h:56px}
  .tabbar{display:block}
  .miniplayer{bottom:calc(56px + var(--safe-b))}
  .miniplayer.live ~ #app,body:has(.miniplayer.live){--mini-h:54px}
}

/* ============================================================
   מסך "הכנס": בורר תצוגה וקטגוריות
   ============================================================ */
.segs{display:flex;gap:6px;background:var(--paper-2);border:1px solid var(--line);
  border-radius:13px;padding:4px;margin-bottom:14px}
.seg{flex:1;background:none;border:0;border-radius:10px;padding:9px 6px;cursor:pointer;
  font-family:var(--f-head);font-weight:700;font-size:13.5px;color:var(--dim);min-height:42px}
.seg:hover{color:var(--navy)}
.seg.on{background:var(--surface);color:var(--navy);box-shadow:var(--shadow)}

.cats{display:grid;gap:12px;grid-template-columns:repeat(auto-fill,minmax(230px,1fr))}
.cat{background:var(--surface);border:1px solid var(--line);border-radius:var(--radius);
  padding:15px 16px;text-align:right;cursor:pointer;font:inherit;color:inherit;
  box-shadow:var(--shadow);display:flex;flex-direction:column;gap:5px;min-height:104px}
.cat:hover{border-color:var(--orange);background:var(--orange-soft)}
.cat h3{font-size:1.02rem;font-weight:800}
.cat .cd{font-size:.83rem;color:var(--dim);line-height:1.5;flex:1}
.cat .cc{font-size:.78rem;color:var(--orange-dark);font-weight:800;font-family:var(--f-head);
  font-variant-numeric:tabular-nums}
.backlink{background:none;border:0;color:var(--dim);font:inherit;font-weight:700;
  cursor:pointer;padding:8px 0;min-height:44px;font-family:var(--f-head);font-size:.9rem}
.backlink:hover{color:var(--navy)}

/* ---------- כרטיס "להמשיך" ---------- */
.resume{background:var(--navy);color:#fff;border-radius:var(--radius);padding:16px;
  margin-bottom:16px;display:flex;gap:13px;align-items:center;text-align:right;
  width:100%;border:0;font:inherit;cursor:pointer}
.resume img{width:60px;height:60px;border-radius:14px;object-fit:cover;flex:none;background:#1B2447}
.resume .rt{flex:1;min-width:0}
/* ‎span‎ הוא inline כברירת מחדל, ובלי ההצהרה הזאת שלוש השורות רצות
   אחת על השנייה. נתפס בעין בטלפון. */
.resume .r0,.resume .r1,.resume .r2,.resume .rbar{display:block}
.resume .r0{font-size:11.5px;letter-spacing:.1em;color:var(--orange);font-weight:800;
  font-family:var(--f-head);margin-bottom:3px}
.resume .r1{font-size:1rem;font-weight:800;font-family:var(--f-head);overflow:hidden;
  text-overflow:ellipsis;white-space:nowrap}
.resume .r2{font-size:12.5px;color:#98A2C4;margin-top:2px}
.resume .rbar{height:4px;background:rgba(255,255,255,.16);border-radius:2px;margin-top:8px;
  overflow:hidden}
.resume .rbar i{display:block;height:100%;background:var(--orange);width:0}

.hgrid{display:grid;gap:12px;grid-template-columns:minmax(0,1fr)}
@media(min-width:700px){.hgrid{grid-template-columns:1fr 1fr}}
.tile{background:var(--surface);border:1px solid var(--line);border-radius:var(--radius);
  padding:15px 16px;text-align:right;font:inherit;color:inherit;cursor:pointer;
  box-shadow:var(--shadow)}
.tile:hover{border-color:var(--orange);background:var(--orange-soft)}
.tile .k{font-size:11.5px;letter-spacing:.1em;color:var(--orange-dark);font-weight:800;
  font-family:var(--f-head);display:block;margin-bottom:5px}
.tile h3{font-size:1.02rem;font-weight:800;margin-bottom:3px}
.tile p{font-size:.85rem;color:var(--dim);line-height:1.5}
.sec-h{font-size:1.05rem;font-weight:800;margin:22px 0 11px}
.sec-h small{display:block;font-family:var(--f-body);font-weight:400;font-size:.83rem;
  color:var(--dim);margin-top:2px}

/* ---------- "שלי" ---------- */
.mine .card{margin-bottom:12px}
.mine h3{font-size:1rem;margin-bottom:4px}
.mine .lead{font-size:.86rem;color:var(--dim);margin-bottom:11px;line-height:1.55}
.bigstat{display:flex;gap:20px;flex-wrap:wrap;margin-bottom:12px}
.bigstat b{display:block;font-family:var(--f-head);font-weight:900;font-size:1.7rem;
  color:var(--navy);font-variant-numeric:tabular-nums;direction:ltr;text-align:right;line-height:1.1}
.bigstat span{font-size:.78rem;color:var(--dim)}
.code{font-family:var(--f-head);font-weight:900;font-size:1.5rem;letter-spacing:.16em;
  color:var(--orange-dark);direction:ltr;text-align:right;background:var(--orange-soft);
  border-radius:11px;padding:11px 16px;display:inline-block}
.switch{display:flex;align-items:center;justify-content:space-between;gap:12px;
  padding:11px 0;border-top:1px solid var(--line-2)}
.switch:first-of-type{border-top:0}
.switch .sl,.switch .ss{display:block}
.switch .sl{font-size:.92rem;font-weight:700}
.switch .ss{font-size:.79rem;color:var(--dim);margin-top:1px}
/* מתג בעברית: הידית במנוחה בצד ימין ונוסעת שמאלה, כמו במערכת ההפעלה.
   כאן משתמשים במאפיינים פיזיים בכוונה — האפליקציה כולה ‎dir=rtl‎ —
   כי ‎inset-inline-end‎ עם ‎translateX‎ שלילי הוציא את הידית מהמסילה. */
.toggle{position:relative;width:50px;height:29px;border-radius:99px;background:var(--paper-3);
  border:0;cursor:pointer;flex:none;transition:background .2s}
.toggle::after{content:'';position:absolute;top:3px;right:3px;width:23px;height:23px;
  border-radius:50%;background:var(--surface);box-shadow:0 1px 4px rgba(8,13,47,.3);
  transition:transform .2s}
.toggle[aria-pressed="true"]{background:var(--orange)}
.toggle[aria-pressed="true"]::after{transform:translateX(-21px)}
.danger{background:none;border:1.5px solid var(--bad);color:var(--bad);border-radius:11px;
  padding:11px 16px;font:inherit;font-weight:700;cursor:pointer;min-height:46px;
  font-family:var(--f-head);font-size:.9rem}
.danger:hover{background:var(--bad);color:#fff}

/* ---------- השאלון ---------- */
.quiz{max-width:600px;margin:0 auto;text-align:center;padding:10px 0 30px}
.quiz .qn{font-family:var(--f-head);font-size:12px;letter-spacing:.12em;color:var(--orange-dark);
  font-weight:800;margin-bottom:10px}
.quiz h2{font-size:clamp(1.25rem,4.4vw,1.75rem);font-weight:900;line-height:1.25}
.quiz .qs{color:var(--dim);font-size:.92rem;margin-top:8px}
.qopts{display:flex;flex-direction:column;gap:10px;margin-top:22px}
.qopt{background:var(--surface);border:1.5px solid var(--line);border-radius:15px;
  padding:15px 17px;text-align:right;font:inherit;color:inherit;cursor:pointer;
  box-shadow:var(--shadow);min-height:56px}
.qopt:hover{border-color:var(--orange);background:var(--orange-soft)}
.qopt b{display:block;font-family:var(--f-head);font-weight:800;font-size:1rem}
.qopt span{display:block;font-size:.83rem;color:var(--dim);margin-top:2px;line-height:1.45}
.qdots{display:flex;gap:6px;justify-content:center;margin-top:24px}
.qdots i{width:7px;height:7px;border-radius:50%;background:var(--paper-3)}
.qdots i.on{background:var(--orange);width:20px;border-radius:4px}
.route{text-align:right}
.route .rh{background:var(--navy);color:#fff;border-radius:var(--radius);padding:20px;
  margin-bottom:16px}
.route .rh .k{font-family:var(--f-head);font-size:11.5px;letter-spacing:.12em;
  color:var(--orange);font-weight:800;margin-bottom:6px}
.route .rh h2{font-size:1.4rem;font-weight:900;color:#fff}
.route .rh p{color:#C7CDEA;font-size:.92rem;margin-top:8px;line-height:1.6}

/* ---------- דף העמקה ---------- */
.deep{max-width:760px;margin:0 auto}
.deep .dh{display:flex;gap:16px;align-items:center;margin-bottom:20px}
.deep .dh img{width:88px;height:88px;border-radius:20px;object-fit:cover;flex:none;
  background:var(--paper-3);box-shadow:var(--shadow-lg)}
.deep .dh .k{font-family:var(--f-head);font-size:11.5px;letter-spacing:.12em;
  color:var(--orange-dark);font-weight:800;margin-bottom:5px}
.deep .dh h1{font-size:clamp(1.35rem,4.2vw,2rem);font-weight:900;line-height:1.18}
.deep .dh .who{color:var(--dim);font-size:.9rem;margin-top:4px}
.deep .lede{font-size:1.06rem;line-height:1.75;color:var(--ink);margin-bottom:22px}
.deep blockquote{background:var(--orange-soft);border:0;border-inline-start:4px solid var(--orange);
  border-radius:0 15px 15px 0;padding:18px 20px;margin:22px 0;
  font-family:var(--f-head);font-weight:700;font-size:1.12rem;line-height:1.6;color:var(--navy)}
.deep blockquote footer{font-family:var(--f-body);font-weight:400;font-size:.83rem;
  color:var(--orange-dark);margin-top:7px}
.deep h2{font-size:1.15rem;font-weight:800;margin:26px 0 8px;line-height:1.35}
.deep p{margin-bottom:14px;line-height:1.8}
.ts{background:none;border:0;padding:1px 7px;border-radius:8px;cursor:pointer;
  font-family:var(--f-head);font-weight:700;font-size:.82em;color:var(--orange-dark);
  background:var(--orange-soft);font-variant-numeric:tabular-nums;direction:ltr;
  unicode-bidi:isolate;vertical-align:.05em}
.ts:hover{background:var(--orange);color:var(--on-orange)}
.action{background:var(--navy);color:#fff;border-radius:var(--radius);padding:18px 20px;
  margin:22px 0}
.action .k{font-family:var(--f-head);font-size:11.5px;letter-spacing:.12em;color:var(--orange);
  font-weight:800;margin-bottom:7px}
.action p{font-size:1.08rem;font-weight:700;font-family:var(--f-head);line-height:1.5;margin:0}
.tasks{list-style:none;margin:12px 0 0}
.task{display:flex;gap:11px;align-items:flex-start;padding:12px 13px;background:var(--surface);
  border:1px solid var(--line);border-radius:14px;margin-bottom:9px;cursor:pointer;
  text-align:right;font:inherit;color:inherit;width:100%}
.task:hover{border-color:var(--orange)}
.task .box{width:22px;height:22px;border-radius:7px;border:2px solid var(--line);flex:none;
  display:grid;place-items:center;font-size:12px;color:#fff;font-weight:800;margin-top:1px}
.task.done .box{background:var(--ok);border-color:var(--ok)}
.task.done .box::after{content:'✓'}
.task.done .tb{opacity:.55;text-decoration:line-through}
.task .th{font-family:var(--f-head);font-weight:800;font-size:.97rem;margin-bottom:2px}
.task .tb{font-size:.88rem;color:var(--dim);line-height:1.55}
.ring{display:flex;align-items:center;gap:11px;margin-bottom:4px}
.ring svg{width:44px;height:44px;flex:none;transform:rotate(-90deg)}
.ring circle{fill:none;stroke-width:5}
.ring .bgc{stroke:var(--paper-3)}
.ring .fgc{stroke:var(--ok);stroke-linecap:round;transition:stroke-dashoffset .3s}
.chips{display:flex;gap:7px;flex-wrap:wrap;margin-top:12px}
.chip{background:var(--paper-2);border:1px solid var(--line);border-radius:99px;
  padding:6px 13px;font-size:.8rem;color:var(--dim);font-family:var(--f-head);font-weight:700}
