/* Стилі модуля care: губка, лічильник чистоти, стан рибки в картці, записка з океану. */

/* Кнопка губки тихенько «кличе», коли скло позеленіло. */
#spongeBtn.care-pulse { animation: care-pulse 1.6s ease-in-out infinite; box-shadow: 0 0 0 0 rgba(160, 230, 120, 0.7); }
@keyframes care-pulse {
  0%, 100% { box-shadow: 0 0 0 0 rgba(160, 230, 120, 0.0); }
  50% { box-shadow: 0 0 0 6px rgba(160, 230, 120, 0.55); }
}

/* Режим чистки: панель ховається, замість неї велика кнопка «готово» і смужка чистоти. */
body.care-cleaning #bar { display: none; }
body.care-cleaning canvas#tank { cursor: none; }
.care-clean[hidden], .care-sponge[hidden] { display: none; }
.care-meter {
  position: fixed; left: 50%; top: calc(max(14px, env(safe-area-inset-top)) + 58px); transform: translateX(-50%);
  width: min(260px, calc(100% - 140px)); height: 22px; border-radius: 999px; z-index: 3;
  background: rgba(255, 255, 255, 0.22); border: 1px solid rgba(255, 255, 255, 0.45); overflow: hidden;
  backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px); pointer-events: none;
}
.care-meter i {
  position: absolute; left: 0; top: 0; bottom: 0; width: 0;
  background: linear-gradient(90deg, #9be7ff, #e8fbff); border-radius: 999px; transition: width .25s ease-out;
}
.care-meter span { position: absolute; right: 6px; top: 50%; transform: translateY(-50%); font-size: 15px; }
.care-done {
  position: fixed; left: 50%; bottom: max(18px, env(safe-area-inset-bottom)); transform: translateX(-50%); z-index: 3;
  width: 72px; height: 72px; padding: 0; border-radius: 50%;
  background: #5fd08a; color: #fff; font-size: 34px; font-weight: 700; line-height: 72px;
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.25);
}
.care-done:active { transform: translateX(-50%) scale(0.94); }
.care-sponge {
  position: fixed; left: 0; top: 0; z-index: 3; pointer-events: none;
  font-size: clamp(48px, 7vmin, 76px); line-height: 1; filter: drop-shadow(0 4px 6px rgba(0, 0, 0, 0.25));
  will-change: transform;
}
.care-sponge.rub { animation: care-rub .18s linear infinite alternate; }
@keyframes care-rub { to { rotate: 12deg; scale: 0.94; } }

/* Стан рибки в картці: для мами, коротко. Натиснув - як доглядати. */
.sheet-box .care-status {
  display: flex; align-items: center; gap: 10px; text-align: left; padding: 10px 12px; border-radius: 16px;
  background: #eaf6f2; color: var(--ink, #0b2236); min-height: 56px;
}
.care-status .care-ico { font-size: 28px; line-height: 1; }
.care-status .care-txt { display: grid; gap: 2px; flex: 1; }
.care-status .care-txt b { font-size: 15px; }
.care-status .care-txt small { font-size: 12.5px; color: var(--muted, #4a5a68); white-space: normal; }
.care-status .care-q {
  width: 26px; height: 26px; border-radius: 50%; display: grid; place-items: center; flex: none;
  background: rgba(11, 110, 138, 0.12); color: #0b6e8a; font-weight: 700; font-size: 14px;
}
.sheet-box .care-status.care-hungry { background: #fff4dc; }
.sheet-box .care-status.care-sad { background: #ffe9ee; }
.sheet-box .care-status.care-sleeping { background: #e8ecfb; }

/* Записка «я попливла у світовий океан»: велика картинка рибки і велика кнопка. */
.sheet-box.care-note .sheet-img { width: 160px; max-height: 110px; background: linear-gradient(#5ad0ea, #1176a8); }
.sheet-box.care-note p { font-size: 17px; color: var(--ink, #0b2236); }
.sheet-box.care-note button.main { padding: 16px; font-size: 18px; }

/* Місяць біля імені вночі: рибки сплять. */
.title .care-moon {
  position: absolute; right: -50px; top: 50%; transform: translateY(-50%);
  width: 44px; height: 44px; padding: 0; border-radius: 50%; font-size: 22px; line-height: 44px;
  background: rgba(10, 22, 60, 0.45); border: 1px solid rgba(255, 255, 255, 0.28); color: #fff;
}
/* Сам місяць лишається 44 px (місця біля імені мало), а зона дотику навколо нього - 56 px. */
.title .care-moon::after { content: ""; position: absolute; inset: -7px; border-radius: 50%; }
.title .care-moon[hidden] { display: none; }

/* Під час чистки шапка, мушлі, новини й інші значки не ловлять пальця: тертя, яке почалось на імені
   чи на мушлях, теж витирає скло. Працює лише кнопка ✓. */
body.care-cleaning > :not(#tank):not(#care-root):not(#sheet):not(#toast),
body.care-cleaning > :not(#tank):not(#care-root):not(#sheet):not(#toast) * { pointer-events: none !important; }
