/* css/pwa.css — סבב 0 (PWA) של EaseFocus: תוספות בלבד, בלי נגיעה ב-styles.css.
   safe-area: עם viewport-fit=cover התוכן יכול להגיע מתחת לחריץ/לסרגל הבית.
   במכשיר בלי חריץ כל ה-inset הם 0, כך שמשתמש קיים רואה בדיוק מה שראה עד היום. */
.screen {
  padding-top: env(safe-area-inset-top);
  padding-right: env(safe-area-inset-right);
  padding-bottom: env(safe-area-inset-bottom);
  padding-left: env(safe-area-inset-left);
  box-sizing: border-box;
}
#fabShare    { bottom: calc(64px  + env(safe-area-inset-bottom)); }
#fabFeedback { bottom: calc(120px + env(safe-area-inset-bottom)); }
#fabInstall  { bottom: calc(176px + env(safe-area-inset-bottom)); }
/* D-16: away from the home page the share button is hidden, so feedback and install move down one slot (EyeFocus) */
body:not([data-screen="welcome"]) #fabFeedback { bottom: calc(64px + env(safe-area-inset-bottom)); }
body:not([data-screen="welcome"]) #fabInstall  { bottom: calc(120px + env(safe-area-inset-bottom)); }

/* ═══ באנרים בראש המסך (js/pwa-update.js): בהירים, בתוך הזרימה ═══
   המארח נכנס כילד ראשון של המסך הפעיל (אחרי פס המשתמשת), ללא position — לכן לא חופף ל-FABs
   (שבתחתית) ולא ל-safe-area (המסך מרוכך). מאפיינים לוגיים בלבד (RTL/LTR). */
.np-banners { flex-shrink: 0; align-self: stretch; padding: 8px 12px 0; }
.np-banners[hidden] { display: none; }
.np-banner {
  display: flex; align-items: center; justify-content: space-between; gap: 10px;
  margin: 0 0 8px; padding: 10px 14px; border-radius: 14px;
  font-family: var(--font-body, 'Assistant', sans-serif); font-size: 13px; font-weight: 600; line-height: 1.45;
  background: #EAF6FD; color: var(--navy, #1E293B); border: 1px solid rgba(14,165,233,.28);
}
.np-banner > span { min-width: 0; }
.np-banner-offline { background: #EEF2FF; border-color: #C7D2FE; justify-content: flex-start; }
.np-banner .np-btn { flex-shrink: 0; }

/* ═══ כרטיס התקנה + מדריך (js/pwa-install.js) — צבעי ה-EaseFocus ═══
   כפתור ראשי: גרדיאנט --gradient-cta עם טקסט --navy (ניגודיות 5.28:1 בקצה התכלת, 5.88:1 בקצה הטורקיז;
   ר' qa/pwa_ui_test.mjs). משני: ירוק/תכלת שקוף עם --accent-text. אין טקסט לבן על הגרדיאנט. */
.np-sheet-back {
  position: fixed; inset: 0; z-index: 2147483200; background: rgba(15,23,42,.55);
  display: flex; align-items: flex-end; justify-content: center;
}
.np-sheet {
  width: 100%; max-width: 520px; max-height: 88vh; overflow-y: auto; -webkit-overflow-scrolling: touch;
  background: var(--white, #fff); color: var(--text, #1E293B); border-radius: 24px 24px 0 0;
  padding: 12px 20px calc(18px + env(safe-area-inset-bottom));
  font-family: var(--font-body, 'Assistant', sans-serif); font-size: 15px; font-weight: 500; line-height: 1.55;
  box-shadow: 0 -8px 32px rgba(15,23,42,.25); user-select: text;
}
.np-sheet-grip { width: 40px; height: 4px; border-radius: 4px; background: var(--border, #E2E8F0); margin: 2px auto 10px; }
.np-sheet-logo { display: block; margin: 0 auto 8px; width: 56px; height: 56px; object-fit: contain; }
.np-sheet-title { font-family: var(--font-ui, 'Rubik', sans-serif); font-size: 19px; font-weight: 800; color: var(--navy, #1E293B); text-align: center; margin-bottom: 8px; }
.np-sub { margin: 6px 0 10px; font-weight: 700; text-align: center; }
.np-lbl { display: block; font-size: 11px; font-weight: 700; letter-spacing: .8px; text-transform: uppercase; color: var(--muted, #526079); margin-bottom: 4px; }
.np-hint { margin: 6px 0 10px; font-size: 13px; color: var(--muted, #526079); }
.np-field { margin-top: 14px; }
.np-steps { margin: 10px 0 14px; padding-inline-start: 22px; line-height: 1.7; font-weight: 700; }
.np-row, .np-row-gap { display: flex; gap: 8px; flex-wrap: wrap; margin: 8px 0; align-items: center; }
.np-btn {
  border: 0; border-radius: 999px; padding: 13px 20px; min-height: 44px; cursor: pointer;
  font-family: var(--font-ui, 'Rubik', sans-serif); font-size: 14px; font-weight: 900;
  background: var(--gradient-cta, linear-gradient(135deg, #0EA5E9 0%, #14B8A6 100%)); color: var(--navy, #1E293B);
  box-shadow: var(--glow-primary, 0 4px 12px rgba(14,165,233,.15)); transition: transform .12s, filter .15s;
}
.np-btn:hover { filter: brightness(0.95); }
.np-btn:active { transform: scale(0.96); }
.np-btn:focus-visible, .np-sheet a:focus-visible { outline: 3px solid var(--accent-dark, #0284C7); outline-offset: 2px; }
.np-btn-wide { width: 100%; }
.np-btn-sm { padding: 9px 16px; min-height: 40px; font-size: 13px; }
.np-btn-sec {
  background: var(--accent-soft, rgba(14,165,233,.08)); color: var(--accent-text, #0369A1);
  border: 1px solid rgba(14,165,233,.35); box-shadow: none; font-weight: 800;
}
.np-btn-ghost { background: transparent; color: var(--accent-text, #0369A1); box-shadow: none; text-decoration: underline; font-weight: 700; padding-inline: 10px; }
.np-sheet-foot { display: flex; justify-content: center; margin-top: 8px; }
.np-status { min-height: 1.4em; margin: 6px 0; font-weight: 700; color: var(--green-text, #0F766E); }
.np-status-bad { color: var(--red-text, #BE123C); }
.np-textarea { width: 100%; box-sizing: border-box; border: 1.5px solid var(--border, #E2E8F0); border-radius: 14px; padding: 10px; font: 13px/1.4 ui-monospace, Menlo, monospace; direction: ltr; user-select: text; box-shadow: 0 1px 4px rgba(0,0,0,.04); }
.np-textarea:focus { outline: none; box-shadow: 0 0 0 3px rgba(14,165,233,.12); border-color: var(--accent, #0EA5E9); }
.np-arrow { color: var(--accent-text, #0369A1); display: flex; justify-content: center; margin-top: 4px; }
.np-arrow-top { position: fixed; top: calc(8px + env(safe-area-inset-top)); inset-inline-end: 24px; }
@media (prefers-reduced-motion: no-preference) {
  .np-arrow svg { animation: npBob 1.2s ease-in-out infinite; }
  @keyframes npBob { 0%,100% { transform: translateY(0) } 50% { transform: translateY(6px) } }
}
/* כרטיס שורה (slot-card) — בתוך מסך הסיכום של האימון. כרטיס זכוכית משלו; לא ברשימת ה-glass המשותפת. */
.np-slot-card {
  display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap;
  margin: 0 0 12px; padding: 12px 14px; text-align: start;
  background: var(--glass-bg, rgba(255,255,255,.85)); border: 1px solid var(--border, #E2E8F0);
  border-radius: 18px; box-shadow: 0 2px 10px rgba(15,23,42,.06);
}
.np-sc-text { display: flex; flex-direction: column; gap: 2px; font-size: 13.5px; color: var(--text, #1E293B); min-width: 0; flex: 1 1 160px; }
.np-sc-text b { font-family: var(--font-ui, 'Rubik', sans-serif); color: var(--navy, #1E293B); font-size: 15px; }
.np-sc-text span { color: var(--muted, #526079); }
@media (prefers-reduced-motion: reduce) { .np-btn { transition: none; } }

/* לוגו שנכשל בטעינה (בלי רשת) — מוחלף בטקסט ה-alt (js/pwa-update.js) */
.np-logo-fallback { display: inline-block; font: 900 28px/1.2 system-ui, -apple-system, "Segoe UI", Arial, sans-serif; color: #0B2A4A; letter-spacing: .3px; text-align: center; }

/* ═══ סבב 0b — העברת פרופילים (iOS בלבד) ═══ */
.np-step-label { font-family: var(--font-ui, 'Rubik', sans-serif); font-size: 14px; font-weight: 800; color: var(--navy, #1E293B); }
.np-step2 { margin-top: 8px; }
.np-more { margin: 10px 0 4px; }
.np-more > summary {
  cursor: pointer; list-style: none; padding: 8px 2px; font-size: 13px; font-weight: 700;
  color: var(--accent-text, #0369A1); text-decoration: underline; text-underline-offset: 3px;
}
.np-more > summary::-webkit-details-marker { display: none; }
.np-more > summary:focus-visible { outline: 3px solid var(--accent-dark, #0284C7); outline-offset: 2px; }
/* קישור בתחתית מסך המשתמשים באפליקציה המותקנת */
.np-import-link { display: flex; align-items: center; gap: 4px; margin: 16px 8px 4px; }
.np-import-link .np-textlink { flex: 1 1 auto; }
.np-sheet:focus { outline: none; }
.np-textlink {
  background: none; border: 0; cursor: pointer; padding: 10px 8px; min-height: 44px; text-align: center;
  font-family: var(--font-body, 'Assistant', sans-serif); font-size: 14px; font-weight: 700; line-height: 1.4;
  color: var(--accent-text, #0369A1); text-decoration: underline; text-underline-offset: 3px;
}
.np-x {
  background: none; border: 0; cursor: pointer; width: 44px; height: 44px; font-size: 22px; line-height: 1;
  color: var(--muted, #526079); border-radius: 50%;
}
.np-textlink:focus-visible, .np-x:focus-visible, .np-bell-btn:focus-visible { outline: 3px solid var(--accent, #0EA5E9); outline-offset: 2px; }

/* ═══ סבב 0b — פעמון תזכורת בסגנון Daily Balance (כמו .icon-btn.small.bell-btn) ═══
   עיגול 30px, מסגרת #E9E6DE, רקע לבן, בלי צל, אייקון 15px (stroke 1.8) בצבע #1F5DD1.
   אזור הלחיצה 44px בעזרת ::before שקוף (30 + 2×7), בלי לשנות את הגודל הנראה. */
.np-bell-btn {
  position: relative; display: inline-flex; align-items: center; justify-content: center; flex-shrink: 0; align-self: center;
  width: 30px; height: 30px; padding: 0; margin-inline-start: 2px;
  border-radius: 50%; border: 1px solid #E9E6DE; background: #FFFFFF; color: #1F5DD1; cursor: pointer;
  box-shadow: none; transition: transform .1s;
}
.np-bell-btn::before { content: ""; position: absolute; inset: -7px; border-radius: 50%; }
.np-bell-btn svg { width: 15px; height: 15px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.np-bell-btn:active { transform: scale(.94); }
@media (prefers-reduced-motion: reduce) { .np-bell-btn { transition: none; } }
.np-xfer { margin-top: 16px; padding-top: 14px; border-top: 1px solid var(--border, #E2E8F0); }
.np-xfer-title { margin: 0 0 4px; font-family: var(--font-ui, 'Rubik', sans-serif); font-size: 15px; font-weight: 800; line-height: 1.35; color: var(--navy, #1E293B); text-align: start; }
.np-status:empty { min-height: 0; margin: 0; }

/* ═══ Round 1 — Daily Balance link (05 §4–§6) ═══
   Ported from MoveFocus css/pwa.css. The DB button uses DB's own colours (#1F5DD1 → #6246EA) with white text
   (white on both ends of that gradient is ≥ 4.5:1) — a deliberate exception to "navy text on the primary gradient",
   because this is Daily Balance's button, not an EaseFocus one. Logical properties only (RTL/LTR). */
.np-db-connect { margin: 14px 0 4px; text-align: center; }
.np-db-btn {
  display: flex; align-items: center; justify-content: center; gap: 10px; width: 100%; box-sizing: border-box;
  min-height: 48px; padding: 12px 16px; border: 0; border-radius: 14px; cursor: pointer;
  background: linear-gradient(135deg, #1F5DD1 0%, #6246EA 100%); color: #FFFFFF;
  font-family: var(--font-ui, 'Rubik', sans-serif); font-size: 15px; font-weight: 800; line-height: 1.2;
  box-shadow: 0 4px 14px rgba(70, 70, 220, .28);
}
.np-db-btn:focus-visible, .np-db-return:focus-visible, .np-db-primary:focus-visible, .np-db-bar:focus-visible,
.np-db-backlink:focus-visible { outline: 3px solid var(--accent, #0EA5E9); outline-offset: 2px; }
.np-db-icon { width: 24px; height: 24px; border-radius: 6px; flex-shrink: 0; object-fit: cover; }
.np-db-help { margin-top: 8px; font-size: 12.5px; line-height: 1.45; color: var(--muted, #526079); }
.np-db-copied {
  margin-top: 10px; padding: 10px 12px; border-radius: 12px; font-size: 13px; font-weight: 600; line-height: 1.5; text-align: start;
  background: #EEF2FF; color: var(--navy, #1E293B); border: 1px solid #C7D2FE;
}
.np-db-copied[hidden], .np-db-field[hidden] { display: none; }
.np-db-field { margin-top: 8px; font-size: 12px; }

/* day summary: "back to Daily Balance" card / the "mark ✓" card (installed iPhone) */
.np-db-return, .np-db-check {
  display: flex; align-items: center; gap: 12px; box-sizing: border-box; width: 100%; margin: 10px 0 0; padding: 12px 14px;
  border-radius: 16px; text-align: start; text-decoration: none;
  background: #EEF2FF; border: 1px solid #C7D2FE; color: var(--navy, #1E293B);
}
.np-db-return-text { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.np-db-return-text strong { font-family: var(--font-ui, 'Rubik', sans-serif); font-size: 15px; font-weight: 800; color: var(--navy, #1E293B); }
.np-db-return-text small { font-size: 12.5px; color: #475569; }

/* a primary button that is a link ("Finish and return to Daily Balance"): looks exactly like .btn-primary */
.np-db-primary { display: block; box-sizing: border-box; width: 100%; text-align: center; text-decoration: none; }
.np-db-primary[hidden], #sumViewProgram[hidden], .np-db-backlink[hidden], #trSummaryBackBtn[hidden] { display: none; }
/* small text link under the primary button / under the first-workout button / in the payment window */
.np-db-backlink, #sumViewProgram { display: block; margin: 12px auto 0; text-decoration: underline; text-underline-offset: 3px; }
a.np-db-backlink { padding: 10px 8px; min-height: 44px; box-sizing: border-box; text-align: center; font-family: var(--font-body, 'Assistant', sans-serif); font-size: 14px; font-weight: 700; line-height: 1.4; color: var(--accent-text, #0369A1); cursor: pointer; }
/* the safety bar at the top of the programme screens */
.np-db-bar {
  display: flex; align-items: center; justify-content: center; gap: 10px; box-sizing: border-box; width: 100%; max-width: 340px; margin: 0 auto 12px;
  padding: 10px 14px; border-radius: 14px; text-decoration: none; cursor: pointer; text-align: start;
  background: #EEF2FF; border: 1px solid #C7D2FE; color: var(--navy, #1E293B);
  font-family: var(--font-ui, 'Rubik', sans-serif); font-size: 14px; font-weight: 800; line-height: 1.35;
}
.np-db-bar > span { min-width: 0; }
