/* ============================================================
   משחקי האגם · עולם 8 (במספור של הילד) · 🆕 20.10.2026
   e הקסם (magic-e) ואגם שתי ההשתקפויות (lake-mirror)
   🔴 המילים תמיד כהות על משטח בהיר, כמו בכל הקורס
   ============================================================ */

/* --- אריחים של צליל עם קו (a_e). 20.10, שני: "צפוף בפנים" --- */
.tile[data-ch*="_"] { min-width: 150px; height: 104px; padding: 0 22px; font-size: 46px; letter-spacing: 4px; }
.letter-card[data-ch*="_"] .letter-card-ch { font-size: clamp(30px, 4.4vw, 46px); letter-spacing: 4px; }
.letters-tray:has(.letter-card[data-ch*="_"]) { gap: 18px; }
.demo-note { display: block; margin-bottom: 10px; color: var(--text); font-size: 18px; font-weight: 700; line-height: 1.5; }
@media (max-width: 600px) {
  .tile[data-ch*="_"] { min-width: 112px; height: 84px; font-size: 36px; }
}

/* --- e הקסם --- */
.me-stage { position: relative; display: flex; align-items: center; justify-content: center; gap: 22px; flex-wrap: wrap; min-height: 140px; }
.me-pic { padding: 0; border: 0; background: none; border-radius: 18px; cursor: pointer; }
.me-pic .art { border-radius: 16px; box-shadow: 0 0 0 3px var(--white); }
.me-row { display: flex; align-items: center; gap: 26px; transition: gap .45s ease-in; }
.me-stage.is-joined .me-row { gap: 4px; }
.me-word { display: flex; gap: 4px; padding: 0; border: 0; background: none; cursor: pointer; border-radius: 16px; }
.me-l { cursor: inherit; transition: background .4s, box-shadow .4s, color .4s; }
.me-e { opacity: .35; transition: opacity .3s, transform .3s; }
.me-e.is-ready { opacity: 1; animation: me-wiggle 1.4s ease-in-out infinite; }
.me-stage.is-joined .me-e { animation: none; }
.me-l.is-magic, .me-e.is-magic { background: linear-gradient(180deg, #ffe1f0, #ffa3d3); box-shadow: 0 6px 0 #c4157a, 0 0 0 2.5px var(--pink); }
.me-arc { position: absolute; inset: 0; width: 100%; height: 100%; overflow: visible; pointer-events: none; }
.me-arc path { fill: none; stroke: var(--pink); stroke-width: 4; stroke-linecap: round; stroke-dasharray: 400; stroke-dashoffset: 400;
  filter: drop-shadow(0 0 6px rgba(255, 62, 165, .8)); }
.me-stage.is-arc .me-arc path { animation: me-draw .7s ease-out forwards; }
.pm-w .is-magic { color: #c4157a; text-decoration: underline 4px var(--pink); text-underline-offset: 6px; }
@keyframes me-wiggle { 0%, 100% { transform: rotate(0); } 20% { transform: rotate(-8deg); } 40% { transform: rotate(8deg); } 60% { transform: rotate(0); } }
@keyframes me-draw { to { stroke-dashoffset: 0; } }

/* --- אגם שתי ההשתקפויות --- */
.lk-scene {
  position: relative; width: min(100%, 620px); aspect-ratio: 16 / 9; margin: 4px 0 8px; overflow: hidden;
  border-radius: 22px; box-shadow: 0 0 0 2px var(--steel), 0 0 0 4px rgba(25, 211, 197, .3);
  background: url(../assets/img/lake/lake.jpg) 50% 50% / cover no-repeat,
    linear-gradient(180deg, #2a2560 0%, #7b3f8f 34%, #ff8fb8 44%, #1b4f7a 46%, #0d2b4a 100%);
}
.lk-scene::after { content: ''; position: absolute; inset: 0; background: rgba(8, 10, 30, .25); transition: background 1.2s; pointer-events: none; }
.lk-scene.is-lit::after { background: rgba(255, 210, 240, .1); }

/* השלט על החוף, ועליו המילה */
.lk-sign { position: absolute; left: 50%; top: 5%; transform: translateX(-50%); z-index: 3; padding: 8px 18px; border-radius: 16px;
  background: linear-gradient(180deg, #fffbea, #f5ecd2); box-shadow: 0 0 0 3px var(--teal), 0 0 24px rgba(25, 211, 197, .55); }
.lk-word { display: block; color: var(--ink); font-family: 'Andika', 'Trebuchet MS', sans-serif;
  font-size: clamp(26px, 5.6vw, 40px); font-weight: 700; line-height: 1.1; letter-spacing: .5px; }

/* עלי הלוטוס: אחד לכל סיבוב, נדלקים */
.lk-pads { position: absolute; left: 4%; right: 4%; bottom: 4%; z-index: 1; display: flex; justify-content: space-between; pointer-events: none; }
.lk-pad { width: 7%; aspect-ratio: 2 / 1; border-radius: 50%; background: rgba(20, 70, 60, .8); box-shadow: inset 0 0 0 1.5px rgba(255, 255, 255, .2);
  transition: background .4s, box-shadow .4s; }
.lk-pad.is-on { background: #ff8fd0; box-shadow: 0 0 10px #ff8fd0, 0 0 22px rgba(255, 62, 165, .7); }

/* התמונות על המים, וההשתקפות שלהן מתחת */
.lk-pics { position: absolute; left: 6%; right: 6%; top: 24%; bottom: 10%; z-index: 2; display: flex; justify-content: space-around; align-items: center; }
.lk-pic { position: relative; width: 30%; padding: 0; border: 0; background: none; cursor: pointer; border-radius: 18px;
  display: flex; flex-direction: column; align-items: center; touch-action: manipulation; transition: opacity .6s, transform .3s; }
.lk-up .art, .lk-down .art { width: 100%; height: auto; aspect-ratio: 1; border-radius: 14px; }
.lk-up { display: block; width: 78%; }
.lk-up .art { box-shadow: 0 0 0 3px var(--white), 0 4px 10px rgba(0, 0, 0, .4); }
.lk-down { display: block; width: 78%; margin-top: 4px; transform: scaleY(-1); opacity: .38; filter: blur(1px) saturate(1.3);
  -webkit-mask-image: linear-gradient(0deg, #000 0%, transparent 70%); mask-image: linear-gradient(0deg, #000 0%, transparent 70%);
  animation: lk-ripple 3s ease-in-out infinite alternate; pointer-events: none; }
.lk-pic:nth-child(2) .lk-down { animation-delay: -1.5s; }
.lk-pic.is-wrong { animation: shake .3s; }
.lk-pic.is-wrong .lk-up .art { box-shadow: 0 0 0 3px var(--err); }
.lk-pic.is-right .lk-up .art { box-shadow: 0 0 0 4px var(--pink), 0 0 36px 10px rgba(255, 62, 165, .55); }
.lk-pic.is-gone { opacity: 0; transform: translateY(14px); }
@keyframes lk-ripple { to { transform: scaleY(-1) skewX(3deg) translateX(3px); } }

/* --- שרביט ה-e --- */
.mw-stage { display: flex; align-items: center; justify-content: center; gap: 24px; flex-wrap: wrap; margin: 6px 0 14px; }
.mw-pic { position: relative; padding: 0; border: 0; background: none; border-radius: 18px; cursor: pointer; }
.mw-pic .art { border-radius: 16px; box-shadow: 0 0 0 3px var(--white); }
.mw-ear { position: absolute; left: -8px; bottom: -8px; width: 34px; height: 34px; border-radius: 50%; background: var(--teal);
  display: grid; place-items: center; box-shadow: 0 3px 0 var(--teal-dark); }
.mw-ear svg { width: 20px; height: 20px; fill: var(--ink); stroke: var(--ink); }
.mw-word { display: flex; gap: 4px; }
.mw-l { cursor: default; transition: background .4s, box-shadow .4s; }
.mw-slot { cursor: default; background: transparent; box-shadow: inset 0 0 0 3px rgba(255, 255, 255, .35); color: var(--ink);
  transition: background .4s, box-shadow .4s, opacity .4s, transform .4s; }
.mw-slot.is-on, .mw-l.is-magic { background: linear-gradient(180deg, #ffe1f0, #ffa3d3); box-shadow: 0 6px 0 #c4157a, 0 0 0 2.5px var(--pink); }
.mw-slot.is-gone { opacity: 0; transform: scale(.6); }
.mw-choices { display: flex; gap: 14px; justify-content: center; flex-wrap: wrap; }
.mw-add { display: inline-flex; align-items: center; gap: 10px; }
.mw-wand { width: 26px; height: 6px; border-radius: 3px; background: linear-gradient(90deg, var(--ink) 70%, #fff 70%); transform: rotate(-35deg);
  box-shadow: 14px -2px 8px rgba(255, 255, 255, .9); }
.mw-choices .is-wrong { animation: shake .3s; }

/* --- המילה החסרה --- */
.gb-card { display: flex; align-items: center; gap: 18px; padding: 12px 18px; margin: 6px 0 12px; border-radius: 20px; background: var(--gray-light); }
.gb-card .art { border-radius: 14px; flex: none; }
.gb-text { color: var(--ink); font-family: 'Andika', 'Trebuchet MS', sans-serif; font-size: clamp(24px, 4.4vw, 36px); font-weight: 700; line-height: 1.3; }
.gb-gap { display: inline-block; min-width: 3.2em; margin: 0; border-bottom: 4px dashed var(--pink); text-align: center; }
.gb-gap.is-filled { border-bottom-style: solid; border-color: var(--teal); }
.gb-gap .is-magic { color: #c4157a; }
.gb-boats { display: flex; justify-content: center; gap: 28px; }
.gb-boat { position: relative; width: 170px; padding: 0; border: 0; background: none; cursor: pointer; display: flex; flex-direction: column; align-items: center;
  animation: bb-bob 2.4s ease-in-out infinite alternate; transition: opacity .5s, transform .5s; touch-action: manipulation; }
.gb-boat:nth-child(2) { animation-delay: -1.2s; }
.gb-w { position: relative; z-index: 1; padding: 6px 16px; margin-bottom: -14px; border-radius: 14px; background: #fffbea; color: var(--ink);
  font-family: 'Andika', 'Trebuchet MS', sans-serif; font-size: 32px; font-weight: 700; box-shadow: 0 0 0 3px var(--teal); }
.gb-hull { width: 100%; height: auto; display: block; filter: drop-shadow(0 6px 6px rgba(0, 0, 0, .4)); }
.gb-hull-css { height: 46px; border-radius: 0 0 60px 60px; background: linear-gradient(180deg, #ff6bb8, #c4157a); }
.gb-boat.is-wrong .gb-w { box-shadow: 0 0 0 3px var(--err); animation: shake .3s; }
.gb-boat.is-right .gb-w { box-shadow: 0 0 0 4px var(--pink), 0 0 30px rgba(255, 62, 165, .6); }
.gb-boat.is-gone { opacity: 0; transform: translateY(16px); }

@media (prefers-reduced-motion: reduce) { .lk-down, .me-e.is-ready, .gb-boat { animation: none; } }
@media (max-width: 600px) {
  .gb-card { flex-direction: column; gap: 8px; }
  .gb-boat { width: 130px; }
  .gb-w { font-size: 26px; }
}
@media (max-width: 600px) {
  .lk-word { font-size: 26px; }
  .lk-pic { width: 40%; }
  .lk-pics { top: 26%; }
  .me-stage { gap: 12px; }
}

/* --- מסך הפתיחה של העולם: אריח רחב לצליל עם קו (a_e). 21.10 --- */
.letters-strip span.is-wide { flex: 0 1 104px; aspect-ratio: 104 / 66; letter-spacing: 3px; }
