/* עיצוב דף הקריאה, לפי ההדמיה "Dan and the Picnic Basket Reading App".
   המידות נמדדו בהדמיה ברוחב 1536 ומתורגמות לאחוזים מרוחב המסך. */

@font-face { font-family: 'Rubik Reader'; src: url('rubik-hebrew.woff2') format('woff2'); font-weight: 400 600; font-display: swap;
  unicode-range: U+0307-0308, U+0590-05FF, U+200C-2010, U+20AA, U+25CC, U+FB1D-FB4F; }
@font-face { font-family: 'Rubik Reader'; src: url('rubik-latin.woff2') format('woff2'); font-weight: 400 600; font-display: swap;
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: 'Fredoka Reader'; src: url('fredoka-hebrew.woff2') format('woff2'); font-weight: 300 700; font-display: swap;
  unicode-range: U+0307-0308, U+0590-05FF, U+200C-2010, U+20AA, U+25CC, U+FB1D-FB4F; }
@font-face { font-family: 'Fredoka Reader'; src: url('fredoka-latin.woff2') format('woff2'); font-weight: 300 700; font-display: swap;
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }

:root {
  /* צבעים שנדגמו מההדמיה */
  --page: #F6F2E6;
  --paper: #FEFEFB;
  --side: rgba(254, 250, 240, .95);
  --card: #FEFDFB;
  --ink: #0C2136;
  --ink-soft: #4C5C66;

  --teal: #2E958D;
  --teal-deep: #25938B;
  --teal-dark: #1F6E6A;
  --teal-text: #2B7F7A;
  --teal-soft: #E2F3EF;
  --teal-seen: #A7D7CF;
  --dot: #D8E4E3;

  --orange: #FC8837;
  --orange-top: #F7852D;
  --orange-bottom: #EA6F15;
  --orange-soft: #FFE3C2;

  --green: #2E7D4A;
  --green-ink: #1E5C36;
  --green-soft: #E8F5E9;
  --green-edge: #A8D6B3;

  --tip: #FEF1CB;

  --read-font: 'Rubik Reader', 'Arial Hebrew', Arial, sans-serif;
  --ui-font: 'Fredoka Reader', 'Rubik Reader', 'Arial Hebrew', Arial, sans-serif;

  /* גודל טקסט הקריאה. --scale משתנה מהכפתורים + ו-− */
  --read: clamp(32px, 2.2vw, 37px);
  --scale: 1;
  --read-size: calc(var(--read) * var(--scale));

  --shadow-panel: 0 18px 50px -18px rgba(60, 45, 15, .28);
  --shadow-soft: 0 4px 14px rgba(60, 60, 40, .10);
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }

body {
  margin: 0;
  min-height: 100vh;
  background: var(--page);
  color: var(--ink);
  font-family: var(--ui-font);
  font-size: 18px;
  line-height: 1.5;
  -webkit-tap-highlight-color: transparent;
  touch-action: manipulation;
}

/* הרקע: האיור מההדמיה, קבוע במקומו בזמן שהטקסט נגלל */
.backdrop {
  position: fixed;
  inset: 0;
  z-index: -1;
  background: var(--art-bg) left center / cover no-repeat, var(--page);
}

.m-only { display: none !important; }

/* חלקים שמתחלפים בין הסיפור לשאלות */
[data-view="questions"] .only-story,
[data-view="story"] .only-quiz { display: none !important; }

/* ===== פריסה במחשב ובטאבלט לרוחב ===== */

.stage {
  display: grid;
  /* ב-RTL הטור הראשון הוא הימני: לוח הצד בימין, דף הקריאה משמאלו, והאיור נשאר גלוי בשמאל */
  grid-template-columns: clamp(340px, 28.1vw, 480px) clamp(560px, 42vw, 900px);
  column-gap: 1.5vw;
  justify-content: start;
  align-items: start;
  padding: 39px 1.76vw 28px 20px;
}

.reader {
  grid-column: 2;
  grid-row: 1;
  min-height: calc(100vh - 67px);
  padding: 24px 27px 40px 38px;
  background: var(--paper);
  border-radius: 26px;
  box-shadow: var(--shadow-panel);
}

.side {
  grid-column: 1;
  grid-row: 1;
  position: sticky;
  top: 73px;
  margin-top: 34px;
  padding: 18px 18px 20px;
  background: var(--side);
  border-radius: 26px;
  box-shadow: var(--shadow-panel);
}

/* כפתור הבית בפינה */
.home {
  position: absolute;
  top: 10px;
  right: 24px;
  z-index: 6;
  display: grid;
  place-items: center;
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: #FDFEFE;
  box-shadow: var(--shadow-soft);
}
.home svg { width: 27px; height: 27px; fill: #26646A; }

/* ===== כותרת על משיכת מכחול ===== */

.title-brush {
  position: relative;
  width: fit-content;
  margin: 0 auto 22px;
  padding: 8px 72px 12px;
  text-align: center;
}
.brush { position: absolute; inset: 0; width: 100%; height: 100%; z-index: 0; }
.title-text {
  position: relative;
  z-index: 1;
  font: 700 clamp(48px, 5vw, 84px)/1.32 var(--ui-font);
  color: var(--ink);
}
.title-brush::after {
  content: '';
  position: absolute;
  z-index: 1;
  left: 50%;
  bottom: -9px;
  width: 90px;
  height: 5px;
  margin-left: -45px;
  border-radius: 3px;
  background: var(--orange);
}

/* ===== הסיפור ===== */

.story {
  margin: 0;
  padding: 0;
  list-style: none;
  font-family: var(--read-font);
  font-size: var(--read-size);
  font-weight: 500;
  line-height: 1.7;
  color: var(--ink);
  text-align: right;
  /* בלי שבירת מילים ובלי יישור דו צדדי */
  word-break: keep-all;
  overflow-wrap: normal;
  hyphens: none;
  -webkit-user-select: none;
  user-select: none;
  -webkit-touch-callout: none;
}

/* כל משפט בשורה משלו. ריפוד קבוע, ולכן הסימון לא מזיז כלום.
   משפט שנשבר: השורה השנייה מוזחת פנימה וצמודה יותר, כדי שלא תיקרא כמשפט חדש. */
.sentence {
  display: block;
  padding-block: .08em;
  padding-inline-start: 1.3em;
  padding-inline-end: .8em;
  text-indent: -.5em;
  text-wrap: balance;
  border-radius: 14px;
  cursor: pointer;
  scroll-margin-top: 24px;
  scroll-margin-bottom: 110px;
  transition: background-color .15s ease;
}
.sentence.is-active { background: var(--teal-soft); }
@media (hover: hover) {
  .sentence:not(.is-active):hover { background: #F3F9F7; }
}
.sentence:focus-visible { outline: 3px solid var(--orange); outline-offset: 2px; }

/* הריפוד האנכי רק צובע ולא משנה את גובה השורה, כך שהניקוד נשאר בתוך הסימון */
.w {
  border-radius: .24em;
  padding: .08em .06em .3em;
  -webkit-box-decoration-break: clone;
  box-decoration-break: clone;
}
.w.is-word { background: var(--orange-soft); box-shadow: inset 0 -.09em 0 var(--orange); }

/* ===== לוח הצד ===== */

.eyebrow {
  margin: 18px 0 0;
  text-align: center;
  font-size: 17px;
  font-weight: 500;
  color: var(--teal-text);
}
.side-title { position: relative; display: flex; justify-content: center; }
.title-2 { margin: 0; font: 700 clamp(46px, 4.7vw, 76px)/1.4 var(--ui-font); color: var(--ink); }
.leaf { position: absolute; left: 0; top: 50%; width: 46px; height: auto; transform: translateY(-38%); }
.underline { display: block; width: 76px; height: 5px; margin: 8px auto 26px; border-radius: 3px; background: var(--orange); }

.card { background: var(--card); border-radius: 18px; box-shadow: 0 2px 10px rgba(80, 60, 20, .05); }

.progress-card { display: flex; flex-direction: column; gap: 14px; padding: 14px 18px 18px; }
.count { font-size: 17px; font-weight: 500; color: var(--ink); font-variant-numeric: tabular-nums; }

.dots { display: flex; justify-content: space-between; gap: 4px; }
.seg { width: 15px; height: 15px; border-radius: 50%; background: var(--dot); transition: background-color .2s ease; }
.seg.is-seen { background: var(--teal-seen); }
.seg.is-current { background: var(--teal-deep); }

.nav { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin: 22px 6px; }
.nav-text { font-size: 18px; font-weight: 500; color: var(--ink); font-variant-numeric: tabular-nums; white-space: nowrap; }

.round {
  display: grid;
  place-items: center;
  width: 62px;
  height: 62px;
  flex: none;
  padding: 0;
  border: 0;
  border-radius: 50%;
  font: 500 32px/1 var(--ui-font);
  color: var(--ink);
  cursor: pointer;
  transition: transform .1s ease, opacity .15s ease;
}
.round svg { width: 26px; height: 26px; fill: none; stroke: currentColor; stroke-width: 2.6; stroke-linecap: round; stroke-linejoin: round; }
.round:active:not(:disabled) { transform: scale(.95); }
.round:disabled { opacity: .35; cursor: default; }
.round-teal { background: var(--teal); color: #fff; box-shadow: 0 8px 18px -6px rgba(46, 149, 141, .55); }
.round-soft { background: #F3FAFA; color: var(--teal-dark); box-shadow: 0 6px 16px -6px rgba(40, 70, 70, .28); }
.round-white { width: 62px; height: 62px; background: #fff; box-shadow: var(--shadow-soft); }

.tools { display: flex; flex-direction: column; gap: 8px; padding: 12px 18px 16px; }

/* ===== הקראה ===== */
.listen { display: flex; flex-direction: column; gap: 12px; padding: 14px 16px 16px; margin-bottom: 14px; }
.listen-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  width: 100%;
  min-height: 56px;
  padding: 8px 16px;
  border: 2px solid #BFE3DB;
  border-radius: 16px;
  background: #fff;
  color: var(--teal-dark);
  font: 600 20px/1.2 var(--ui-font);
  cursor: pointer;
}
.listen-btn:hover { background: var(--teal-soft); }
.listen-btn.is-playing { background: var(--teal); border-color: var(--teal); color: #fff; }
.listen-btn svg, .round-listen svg { width: 24px; height: 24px; fill: currentColor; flex: none; }
.listen-btn .i-pause, .round-listen .i-pause { display: none; }
.listen-btn.is-playing .i-play, .round-listen.is-playing .i-play { display: none; }
.listen-btn.is-playing .i-pause, .round-listen.is-playing .i-pause { display: block; }
.rate { display: flex; align-items: center; gap: 6px; }
.rate-label { font-size: 15px; color: var(--ink); margin-inline-end: auto; }
.rate-btn {
  min-height: 44px;
  min-width: 58px;
  padding: 0 12px;
  border: 2px solid #E6DCC8;
  border-radius: 999px;
  background: #fff;
  color: var(--ink);
  font: 500 16px/1 var(--ui-font);
  cursor: pointer;
}
.rate-btn[aria-pressed="true"] { background: var(--teal); border-color: var(--teal); color: #fff; }
.listen-btn:focus-visible, .rate-btn:focus-visible { outline: 3px solid var(--orange); outline-offset: 3px; }
.round-say { width: 56px; height: 56px; background: var(--teal-soft); color: var(--teal-dark); box-shadow: none; }
.round-say.is-playing { background: var(--teal); color: #fff; }
.round-say svg { width: 28px; height: 28px; }
.round-say .spk { fill: currentColor; stroke: none; }
.round-say .wave { fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; }
.q-row { display: flex; align-items: center; gap: 14px; margin: 10px 0 22px; }
.q-row .q-text { margin: 0; padding-inline: 0; }
.answer-slot { gap: 14px; }
.rate-quiz { margin-top: 22px; padding-top: 16px; border-top: 2px dashed #EEE6D6; }
.round-listen { background: #FFF1DE; color: #C2570F; box-shadow: 0 6px 16px -6px rgba(200, 100, 20, .35); }
.round-listen.is-playing { background: var(--orange); color: #fff; }
.tools-label { font-size: 15px; color: var(--ink); }
.tools-row { display: flex; align-items: center; gap: 10px; }
.pill {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-height: 62px;
  margin-inline-start: auto;
  padding: 0 16px;
  border: 0;
  border-radius: 30px;
  white-space: nowrap;
  background: #fff;
  box-shadow: var(--shadow-soft);
  font: 500 18px/1 var(--ui-font);
  color: var(--ink);
  cursor: pointer;
}
.pill svg { width: 24px; height: 24px; }
.eraser-body { fill: #fff; stroke: var(--ink); stroke-width: 1.8; stroke-linejoin: round; }
.eraser-tip { fill: var(--ink); }
.eraser-line { fill: none; stroke: var(--ink); stroke-width: 1.8; stroke-linecap: round; }

.resume { margin: 16px 0 -6px; text-align: center; font-size: 16px; color: var(--ink-soft); }

.btn-orange {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  width: 100%;
  min-height: 72px;
  margin-top: 18px;
  padding: 10px 14px;
  border: 0;
  border-radius: 18px;
  background: linear-gradient(var(--orange-top), var(--orange-bottom));
  box-shadow: 0 8px 18px -6px rgba(234, 111, 21, .55);
  font: 600 clamp(18px, 1.4vw, 21px)/1.2 var(--ui-font);
  color: #fff;
  white-space: nowrap;
  cursor: pointer;
}
.btn-orange svg { width: 24px; height: 24px; flex: none; fill: none; stroke: #fff; stroke-width: 2.8; stroke-linecap: round; stroke-linejoin: round; }
.btn-orange:active { transform: translateY(2px); }

.tip {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  margin-top: 18px;
  padding: 16px 18px 16px 22px;
  background: var(--tip);
  border-radius: 18px;
}
.tip img { flex: none; width: 34px; height: auto; margin-top: 2px; }
.tip p { margin: 0; font-size: 18px; line-height: 1.75; color: var(--ink); }

.btn {
  font: 600 20px/1.2 var(--ui-font);
  min-height: 58px;
  padding: 12px 26px;
  border-radius: 18px;
  border: 2px solid transparent;
  cursor: pointer;
}
.btn:active:not(:disabled) { transform: translateY(2px); }
.btn-wide { width: 100%; margin-top: 18px; }
.btn-teal { background: var(--teal); color: #fff; box-shadow: 0 8px 18px -8px rgba(46, 149, 141, .6); }
.btn-soft { background: #fff; color: var(--teal-dark); border-color: #BFE3DB; }
.btn-check { min-height: 64px; padding: 14px 36px; font-size: 22px; background: var(--green); color: #fff; box-shadow: 0 8px 18px -8px rgba(46, 125, 74, .6); }
.btn:focus-visible, .round:focus-visible, .pill:focus-visible, .btn-orange:focus-visible, .home:focus-visible {
  outline: 3px solid var(--orange);
  outline-offset: 3px;
}

/* ===== שאלות ===== */

.quiz { padding: 8px 4px 0; }
.q-text, .a-text {
  margin: 0;
  font-family: var(--read-font);
  font-size: calc(var(--read-size) * 1.15);
  line-height: 1.9;
  text-align: right;
  word-break: keep-all;
  overflow-wrap: normal;
}
.q-text { font-weight: 500; padding-inline: .7em; margin: 10px 0 22px; }

/* הכפתור והתשובה באותה מסגרת בגובה קבוע, כדי שהעמוד לא יקפוץ */
.answer-slot {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: calc(var(--read-size) * 1.15 * 1.9 + 48px);
  padding: 12px 22px;
  border: 2px dashed #E3D8C2;
  border-radius: 20px;
  background: #FFFDF7;
}
.answer-slot.is-open { justify-content: flex-start; border: 2px solid var(--green-edge); background: var(--green-soft); }
.a-text { font-weight: 600; color: var(--green-ink); animation: appear .25s ease; }
@keyframes appear { from { opacity: 0; } to { opacity: 1; } }

.q-nav { display: flex; justify-content: space-between; gap: 12px; margin-top: 28px; }
.q-nav .is-invisible { visibility: hidden; }

.done { text-align: center; padding: 10px 0 0; }
.vignette {
  width: 190px;
  height: 190px;
  margin: 6px auto 24px;
  border-radius: 50%;
  overflow: hidden;
  box-shadow: 0 0 0 8px var(--teal-soft);
}
.vignette img { display: block; width: 100%; height: 100%; object-fit: cover; }
.done-text { margin: 0 0 26px; font-size: clamp(26px, 2.4vw, 34px); font-weight: 600; line-height: 1.55; }

noscript p { text-align: center; font-size: 20px; }

/* ===== טאבלט לאורך וטלפון: טור אחד ===== */

@media (max-width: 1023px) {
  :root { --read: 30px; }
  .backdrop { display: none; }
  .d-only { display: none !important; }
  /* :not([hidden]) כדי שחלק מוסתר (למשל הקראה בסיפור בלי קול) לא יופיע בטלפון */
  .m-only:not([hidden]) { display: block !important; }
  .dock.m-only:not([hidden]), .quiz-top.m-only:not([hidden]) { display: flex !important; }

  .stage { display: flex; flex-direction: column; align-items: stretch; gap: 14px; padding: 12px 12px 32px; max-width: 860px; margin: 0 auto; }
  .reader { min-height: 0; padding: 12px 12px 24px; border-radius: 24px; }
  .side { position: static; margin: 0; padding: 16px; border-radius: 24px; }

  .home { top: 22px; right: 22px; width: 50px; height: 50px; }
  .banner { margin: 0 0 6px; height: clamp(200px, 48vw, 340px); border-radius: 18px; overflow: hidden; }
  .banner img { display: block; width: 100%; height: 100%; object-fit: cover; object-position: 50% 66%; }
  .eyebrow.m-only { margin: 10px 0 4px; }
  .title-brush { margin-bottom: 22px; }

  .dock {
    position: sticky;
    bottom: 10px;
    z-index: 5;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    margin-top: 18px;
    padding: 8px;
    background: #fff;
    border-radius: 40px;
    box-shadow: 0 14px 34px -12px rgba(60, 45, 15, .35);
  }
  .dock-mid { display: flex; flex-direction: column; align-items: center; gap: 8px; min-width: 0; flex: 1; }
  .dock .dots { width: 100%; max-width: 240px; }
  .dock .seg, .quiz-top .seg { width: 11px; height: 11px; }

  .quiz-top { align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 12px; margin: 2px 4px 14px; }
  .quiz-top .dock-mid { flex: 0 1 auto; }
  .quiz-top .dots { width: 120px; }

  .btn-orange { margin-top: 16px; }
  .listen.m-only { margin: 0 0 16px; background: var(--card); box-shadow: none; border: 1px solid #EEE6D6; }
  /* בטלפון כל מה שצריך לשאלות נמצא בדף עצמו */
  [data-view="questions"] .side { display: none; }
}
@media (max-width: 1023px) and (max-height: 520px) { .dock { position: static; } }

/* מחשב עם מסך נמוך: לוח הצד מתכווץ, כדי שכל הכפתורים ייכנסו בגובה המסך */
@media (min-width: 1024px) and (max-height: 1000px) {
  .side { top: 24px; padding-top: 10px; }
  .eyebrow { margin-top: 10px; }
  .title-2 { font-size: clamp(42px, 3.6vw, 56px); line-height: 1.35; }
  .underline { margin: 4px auto 16px; }
  .nav { margin: 14px 6px; }
  .round, .round-white { width: 54px; height: 54px; }
  .pill { min-height: 54px; }
  .btn-orange { min-height: 62px; margin-top: 14px; }
  .tip { margin-top: 14px; padding-block: 12px; }
  .listen { padding: 10px 14px 12px; gap: 8px; margin-bottom: 10px; }
  .side { padding-bottom: 14px; }
  .title-2 { font-size: clamp(38px, 3.2vw, 50px); }
  .leaf { width: 36px; }
  .progress-card { padding: 10px 14px 12px; gap: 10px; }
  .tools { padding: 8px 14px 12px; gap: 6px; }
  .btn-orange { min-height: 56px; }
  .tip { padding: 10px 14px; }
  .tip p { font-size: 15px; line-height: 1.55; }
  .listen-btn { min-height: 48px; font-size: 18px; }
  .rate-btn { min-height: 44px; }
  .tip p { font-size: 16px; line-height: 1.65; }
}

@media (max-width: 640px) {
  :root { --read: 28px; }
  .title-text { font-size: 46px; }
  .title-brush { padding: 6px 34px 10px; }
  .btn { font-size: 18px; padding: 10px 18px; }
  .btn-check { font-size: 20px; padding: 12px 24px; }
  .btn-orange { font-size: 19px; }
  .round { width: 54px; height: 54px; }
  .round-white { width: 52px; height: 52px; }
  .nav-text { font-size: 16px; }
  .sentence { padding-inline-start: 1.1em; padding-inline-end: .45em; text-indent: -.6em; }
  .tip p { font-size: 16px; }
}

@media (prefers-reduced-motion: reduce) {
  * { transition: none !important; animation: none !important; }
}

/* לוח צד צר (מחשב קטן וטאבלט לרוחב): כפתורים עגולים קטנים יותר כדי שהשורה לא תישבר */
@media (min-width: 1024px) and (max-width: 1279px) {
  .round, .round-white { width: 52px; height: 52px; }
  .pill { min-height: 52px; padding: 0 14px; font-size: 17px; }
}

/* מסך נמוך מאוד (טאבלט לרוחב, 768 גובה): בלי שורת הכותרת הקטנה בלוח, הכותרת כבר בדף */
@media (min-width: 1024px) and (max-height: 800px) {
  .side .eyebrow { display: none; }
  .title-2 { font-size: 38px; }
  .nav { margin: 8px 6px; }
  .round, .round-white { width: 50px; height: 50px; }
  .pill { min-height: 50px; }
  .listen-btn { min-height: 44px; }
}

/* ===== מיתוג (16/11/2026). מרינה: "אין מיתוג בטקסטים, אפשר לצלם מסך ולא ידעו שזה שלנו". ===== */
/* הלוגו בפינה מול סימן הבית, ושורת זכויות בסוף הדף (מתחת לסיפור ומתחת לשאלות) */
.brand {
  position: absolute;
  top: 10px;
  left: 24px;
  z-index: 6;
  display: block;
  padding: 8px 12px;
  border-radius: 16px;
  background: #FDFEFE;
  box-shadow: var(--shadow-soft);
}
.brand img { display: block; width: 116px; height: auto; }
.brand:focus-visible { outline: 3px solid var(--teal); outline-offset: 3px; }
.credit { margin: 26px 0 0; text-align: center; font-size: 15px; line-height: 1.7; color: var(--ink-soft); text-wrap: balance; }
.credit bdi { unicode-bidi: isolate; direction: ltr; }
@media (max-width: 1023px) {
  .brand { top: 22px; left: 22px; padding: 6px 10px; border-radius: 14px; }
  .brand img { width: 88px; }
  .credit { font-size: 14px; margin-top: 20px; }
}

/* ===== מיתוג בתוך כרטיס הסיפור (16/11/2026). מרינה: "אפשר לגזור ולא יהיה שום חלק לאריאדנה" ===== */
/* סימן מים מאחורי השורות (חוזר לאורך כל הכרטיס) ולוגו קטן מתחת לכותרת, כך שכל חיתוך של הטקסט כולל את אריאדנה */
.reader { position: relative; isolation: isolate; }
.reader::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: url("watermark-ariadna.png") center 200px / min(62%, 400px) auto repeat-y;
  opacity: .07;
  pointer-events: none;
}
.title-logo { display: block; width: 92px; height: auto; margin: -10px auto 20px; }
@media (max-width: 1023px) {
  .reader::before { background-position: center 420px; background-size: min(70%, 320px) auto; }
  .title-logo { width: 78px; margin: -12px auto 16px; }
}

/* ===== דף להדפסה בלוח הצד ===== */
.print-card { margin-top: 14px; }
.print-row { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 10px; }
.print-row .pill { text-decoration: none; color: inherit; }
.print-row .pill svg { width: 22px; height: 22px; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linejoin: round; }

/* ===== גרסת ההדפסה ===== */
.print-doc { display: none; }

@media print {
  @page { size: A4; margin: 12mm 14mm 12mm; }
  html, body { background: #fff !important; }
  body > *:not(.print-doc) { display: none !important; }
  .print-doc { display: block; color: #0C2136; font-family: var(--read-font); }

  /* סימן מים ושורת זכויות: position: fixed חוזר בכל עמוד מודפס */
  .pd-wm { position: fixed; top: 50%; left: 50%; width: 120mm; transform: translate(-50%, -50%); opacity: .08; z-index: 0; }
  .pd-foot { position: fixed; bottom: 0; left: 0; right: 0; margin: 0; text-align: center; font: 9pt var(--ui-font); color: #4C5C66; }
  .pd-foot bdi { unicode-bidi: isolate; direction: ltr; }

  .pd-page { position: relative; z-index: 1; padding-bottom: 10mm; break-after: page; }
  .pd-page:last-of-type { break-after: auto; }
  .pd-head { display: flex; align-items: center; justify-content: space-between; padding-bottom: 3mm; margin-bottom: 4mm; border-bottom: 1.5pt solid #F36F23; }
  .pd-logo { width: 34mm; height: auto; }
  .pd-eyebrow { font: 600 11pt var(--ui-font); color: #2B7F7A; }
  .pd-title { margin: 0 0 4mm; text-align: center; font: 700 30pt/1.2 var(--ui-font); }
  .pd-art { display: block; width: 100%; height: 50mm; object-fit: cover; object-position: 50% 62%; border-radius: 5mm; margin: 0 0 5mm; }
  .pd-lines { list-style: none; margin: 0; padding: 0; font-size: 18pt; line-height: 1.68; font-weight: 500; }
  .pd-lines li { break-inside: avoid; }

  .pd-h2 { margin: 0 0 5mm; text-align: center; font: 700 22pt/1.3 var(--ui-font); }
  .pd-name { margin: 0 0 7mm; font: 600 14pt var(--ui-font); }
  .pd-blank { display: inline-block; width: 70mm; border-bottom: 1.2pt solid #8FA0A6; }
  .pd-qs { margin: 0; padding: 0 9mm 0 0; font-size: 18pt; line-height: 1.6; }
  .pd-qs li { break-inside: avoid; margin-bottom: 6mm; }
  .pd-qs li::marker { font: 700 16pt var(--ui-font); color: #EA6F15; }
  .pd-q { margin: 0 0 2mm; font-weight: 500; }
  .pd-write { display: block; height: 13mm; border-bottom: 1.2pt solid #8FA0A6; }

  .pd-answers { margin: 0; padding: 0 9mm 0 0; font-size: 15pt; line-height: 1.9; }
  .pd-kq { font-weight: 500; }
  .pd-ka { color: #1E5C36; font-weight: 600; }

  /* שחור לבן: בלי צבע בכלל, והאיור באפור בהיר שחוסך דיו */
  [data-print-mode="bw"] .print-doc { color: #000; }
  [data-print-mode="bw"] .pd-head { border-bottom-color: #000; }
  [data-print-mode="bw"] .pd-eyebrow, [data-print-mode="bw"] .pd-foot, [data-print-mode="bw"] .pd-ka { color: #000; }
  [data-print-mode="bw"] .pd-qs li::marker { color: #000; }
  [data-print-mode="bw"] .pd-blank, [data-print-mode="bw"] .pd-write { border-bottom-color: #777; }
  [data-print-mode="bw"] .pd-logo, [data-print-mode="bw"] .pd-wm { filter: grayscale(1); }
  [data-print-mode="bw"] .pd-art { filter: grayscale(1) contrast(.7) brightness(1.25); }
}
