:root {
  color-scheme: light;
  --ink: #5b4033;
  --ink-soft: #9a7b6c;
  --pink: #ff6f91;
  --pink-deep: #f0507a;
  --pink-soft: #ffd1dc;
  --bg-top: #ffe1ea;
  --bg-bottom: #fff4e4;
  --card: #fffdfb;
  --bubu-bubble: #ffffff;
  --bubu-edge: #ffc9d6;
  --dudu-bubble: #f6dcc2;
  --dudu-edge: #e3b48a;
  --shadow: 0 6px 18px rgba(201, 107, 135, .18);
  --vvh: 100dvh;
  --safe-top: env(safe-area-inset-top, 0px);
  --safe-bottom: env(safe-area-inset-bottom, 0px);
  font-family: 'Fredoka', ui-rounded, 'SF Pro Rounded', system-ui, sans-serif;
  color: var(--ink);
  -webkit-tap-highlight-color: transparent;
}

* { box-sizing: border-box; }
html, body { margin: 0; height: 100%; overflow: hidden; overscroll-behavior: none; }
body {
  background: linear-gradient(180deg, var(--bg-top) 0%, #ffeef2 45%, var(--bg-bottom) 100%);
  -webkit-user-select: none; user-select: none;
  -webkit-text-size-adjust: 100%;
}
button { font: inherit; color: inherit; border: 0; background: none; cursor: pointer; padding: 0; touch-action: manipulation; }
textarea, input { font: inherit; color: inherit; -webkit-user-select: text; user-select: text; }
[hidden] { display: none !important; }

#app { position: fixed; inset: 0 0 auto 0; height: var(--vvh); display: flex; flex-direction: column; z-index: 1; }

/* ---------- dreamy background ---------- */
#sky { position: fixed; inset: 0; overflow: hidden; pointer-events: none; z-index: 0; }
.cloud {
  position: absolute; width: 120px; height: 40px; background: #fff; border-radius: 40px; opacity: .75;
  animation: drift linear infinite;
}
.cloud::before, .cloud::after { content: ''; position: absolute; background: #fff; border-radius: 50%; }
.cloud::before { width: 54px; height: 54px; left: 18px; top: -26px; }
.cloud::after { width: 40px; height: 40px; left: 58px; top: -16px; }
@keyframes drift { from { transform: translateX(-180px) scale(var(--s, 1)); } to { transform: translateX(calc(100vw + 60px)) scale(var(--s, 1)); } }
.sky-heart { position: absolute; bottom: -30px; font-size: var(--size, 18px); opacity: 0; animation: rise linear infinite; }
@keyframes rise {
  0% { transform: translate(0, 0) rotate(-10deg); opacity: 0; }
  10% { opacity: .55; }
  50% { transform: translate(var(--sway, 20px), -55vh) rotate(10deg); }
  90% { opacity: .45; }
  100% { transform: translate(0, -110vh) rotate(-10deg); opacity: 0; }
}

/* ---------- bear micro-animations ---------- */
.bear { display: block; overflow: visible; }
.bear .blink { transform-box: fill-box; transform-origin: center; animation: blink 4.5s infinite; }
@keyframes blink { 0%, 94%, 100% { transform: scaleY(1); } 96% { transform: scaleY(.1); } }
.bear .wave-arm { transform-box: fill-box; transform-origin: 20% 90%; animation: wave 1s ease-in-out infinite; }
@keyframes wave { 0%, 100% { transform: rotate(0); } 50% { transform: rotate(-22deg); } }
.bear .cheer-l, .bear .cheer-r { transform-box: fill-box; animation: cheer .6s ease-in-out infinite alternate; }
.bear .cheer-l { transform-origin: 90% 90%; }
.bear .cheer-r { transform-origin: 10% 90%; animation-delay: .3s; }
@keyframes cheer { to { transform: rotate(14deg) translateY(-2px); } }
.bear .beat { transform-box: fill-box; transform-origin: center; animation: beat 1.1s ease-in-out infinite; }
@keyframes beat { 0%, 100% { transform: scale(1); } 15% { transform: scale(1.18); } 30% { transform: scale(.96); } 45% { transform: scale(1.1); } }
.bear .float-a, .bear .float-b, .bear .float-c, .bear .kiss-heart { transform-box: fill-box; transform-origin: center; animation: floaty 2.4s ease-in-out infinite; }
.bear .float-b { animation-delay: .8s; }
.bear .float-c { animation-delay: 1.4s; }
.bear .kiss-heart { animation: kissy 1.6s ease-out infinite; }
@keyframes floaty { 0%, 100% { transform: translateY(0) scale(1); opacity: 1; } 50% { transform: translateY(-5px) scale(1.12); opacity: .85; } }
@keyframes kissy { 0% { transform: translate(-6px, 2px) scale(.3); opacity: 0; } 30% { opacity: 1; } 100% { transform: translate(6px, -14px) scale(1.1); opacity: 0; } }
.bear .tear { transform-box: fill-box; animation: drip 1.8s ease-in infinite; }
@keyframes drip { 0% { transform: translateY(-3px); opacity: 0; } 20% { opacity: 1; } 100% { transform: translateY(14px); opacity: 0; } }
.bear .stream { animation: streamy .5s ease-in-out infinite alternate; }
@keyframes streamy { to { opacity: .55; } }
.bear .bubble { transform-box: fill-box; transform-origin: 0% 50%; animation: snore 2.6s ease-in-out infinite; }
@keyframes snore { 0%, 100% { transform: scale(.5); } 50% { transform: scale(1.25); } }
.bear .zzz { animation: zz 2.6s ease-in-out infinite; }
.bear .z2 { animation-delay: .6s; }
@keyframes zz { 0% { opacity: 0; transform: translate(-4px, 6px); } 40% { opacity: 1; } 100% { opacity: 0; transform: translate(4px, -6px); } }
.bear .sparkle, .bear .star-eye { transform-box: fill-box; transform-origin: center; animation: twinkle 1.2s ease-in-out infinite; }
.bear .s2 { animation-delay: .4s; } .bear .s3 { animation-delay: .8s; }
@keyframes twinkle { 0%, 100% { transform: scale(1) rotate(0); } 50% { transform: scale(.7) rotate(20deg); } }
.bear .puff { animation: puff .5s steps(2) infinite; }
@keyframes puff { 50% { opacity: .4; } }
.bear .drool { transform-box: fill-box; transform-origin: top; animation: drool 2s ease-in-out infinite; }
@keyframes drool { 0%, 100% { transform: scaleY(.6); } 50% { transform: scaleY(1.2); } }
.bear .sweat { transform-box: fill-box; animation: drip 2.2s ease-in infinite; }
.bear .heart-eye { transform-box: fill-box; transform-origin: center; animation: beat 1s ease-in-out infinite; }
.bear .think { animation: floaty 2.6s ease-in-out infinite; transform-box: fill-box; }

.bounce-in { animation: bounceIn .55s cubic-bezier(.2, 1.6, .4, 1) both; }
@keyframes bounceIn { 0% { transform: scale(.3); opacity: 0; } 100% { transform: scale(1); opacity: 1; } }
.squish { animation: squish .5s ease; }
@keyframes squish { 0% { transform: scale(1); } 30% { transform: scale(1.15, .85); } 60% { transform: scale(.92, 1.08); } 100% { transform: scale(1); } }
.shake { animation: shake .45s ease; }
@keyframes shake { 20%, 60% { transform: translateX(-8px) rotate(-1deg); } 40%, 80% { transform: translateX(8px) rotate(1deg); } }
.idle-bob { animation: bob 2.8s ease-in-out infinite; }
@keyframes bob { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-4px); } }

/* ---------- install + login ---------- */
.screen {
  flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center;
  padding: calc(var(--safe-top) + 24px) 24px calc(var(--safe-bottom) + 24px); text-align: center; gap: 10px;
}
.logo { font-size: 44px; font-weight: 700; margin: 6px 0 0; letter-spacing: -.5px; color: var(--ink); }
.logo .accent { color: var(--pink); }
.sub { margin: 0; color: var(--ink-soft); font-size: 18px; }
.hero { width: min(300px, 78vw); }
.steps { list-style: none; padding: 0; margin: 14px 0; display: grid; gap: 10px; width: min(340px, 100%); text-align: left; }
.steps li { background: var(--card); border-radius: 18px; padding: 12px 16px; box-shadow: var(--shadow); font-size: 17px; display: flex; gap: 10px; align-items: center; }
.steps .num { flex: none; width: 28px; height: 28px; border-radius: 50%; background: var(--pink); color: #fff; display: grid; place-items: center; font-weight: 700; }
.steps svg { width: 20px; height: 20px; vertical-align: -3px; }
.linkish { color: var(--ink-soft); text-decoration: underline; font-size: 15px; margin-top: 6px; padding: 8px; }

.pick { display: flex; gap: 18px; margin-top: 18px; }
.pick button {
  background: var(--card); border-radius: 28px; padding: 14px 14px 12px; box-shadow: var(--shadow);
  display: flex; flex-direction: column; align-items: center; gap: 4px; font-size: 22px; font-weight: 600;
  transition: transform .15s;
}
.pick button:active { transform: scale(.94); }
.pick .bear { width: 118px; height: 118px; }

.pin-bear { width: 150px; height: 150px; }
.dots { display: flex; gap: 12px; height: 26px; align-items: center; margin: 6px 0 4px; }
.dots span { width: 18px; height: 18px; border-radius: 50%; background: #fff; border: 2.5px solid var(--pink-soft); transition: .15s; }
.dots span.on { background: var(--pink); border-color: var(--pink); transform: scale(1.15); }
.pad { display: grid; grid-template-columns: repeat(3, 72px); gap: 14px; margin-top: 10px; }
.pad button {
  height: 72px; border-radius: 50%; background: var(--card); box-shadow: var(--shadow);
  font-size: 28px; font-weight: 600; transition: transform .1s, background .1s;
}
.pad button:active { transform: scale(.9); background: var(--pink-soft); }
.pad .go { background: var(--pink); color: #fff; }
.err { color: var(--pink-deep); min-height: 22px; font-weight: 500; margin: 0; }

/* ---------- chat ---------- */
.top {
  display: flex; align-items: center; gap: 10px;
  padding: calc(var(--safe-top) + 6px) 12px 8px;
  background: rgba(255, 236, 242, .82); -webkit-backdrop-filter: blur(14px); backdrop-filter: blur(14px);
  border-bottom: 2px solid #ffd9e3; position: relative; z-index: 3;
}
.top .avatar { width: 54px; height: 54px; flex: none; border-radius: 50%; background: #fff; box-shadow: 0 3px 10px rgba(201, 107, 135, .2); display: grid; place-items: center; position: relative; }
.top .avatar .bear { width: 50px; height: 50px; }
.top .avatar .dot { position: absolute; right: 1px; bottom: 3px; width: 14px; height: 14px; border-radius: 50%; background: #c9bcb6; border: 2.5px solid #fff; transition: background .3s; }
.top .avatar .dot.on { background: #6ad48a; box-shadow: 0 0 0 0 rgba(106, 212, 138, .6); animation: ping 2s infinite; }
@keyframes ping { 70% { box-shadow: 0 0 0 8px rgba(106, 212, 138, 0); } 100% { box-shadow: 0 0 0 0 rgba(106, 212, 138, 0); } }
.who { flex: 1; min-width: 0; }
.who .name { font-size: 21px; font-weight: 700; display: flex; align-items: center; gap: 6px; }
.who .name .mini-heart { display: inline-block; animation: beat 1.3s infinite; font-size: 16px; }
.who .status { font-size: 13.5px; color: var(--ink-soft); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.days {
  background: #fff; border-radius: 999px; padding: 6px 11px; font-size: 13.5px; font-weight: 600;
  box-shadow: 0 3px 10px rgba(201, 107, 135, .18); white-space: nowrap; color: var(--pink-deep);
}
.icon-btn { width: 40px; height: 40px; border-radius: 50%; background: #fff; display: grid; place-items: center; font-size: 19px; box-shadow: 0 3px 10px rgba(201, 107, 135, .18); flex: none; }

.banner {
  margin: 8px 12px 0; padding: 10px 12px; border-radius: 18px; background: #fff; box-shadow: var(--shadow);
  display: flex; align-items: center; gap: 10px; font-size: 14.5px; position: relative; z-index: 2;
}
.banner .bear { width: 46px; height: 46px; flex: none; }
.banner p { margin: 0; flex: 1; }
.banner .btn { flex: none; }
.btn { background: var(--pink); color: #fff; border-radius: 999px; padding: 9px 16px; font-weight: 600; box-shadow: 0 4px 12px rgba(240, 80, 122, .3); }
.btn.ghost { background: #fff; color: var(--ink); box-shadow: 0 3px 10px rgba(201, 107, 135, .18); }
.btn:active { transform: scale(.95); }

.msgs { flex: 1; overflow-y: auto; -webkit-overflow-scrolling: touch; padding: 10px 10px 6px; position: relative; z-index: 1; overscroll-behavior: contain; }
.older { text-align: center; font-size: 13px; color: var(--ink-soft); min-height: 8px; }
.empty { text-align: center; padding: 40px 20px; color: var(--ink-soft); }
.empty .bear { width: 220px; margin: 0 auto 6px; }

.day { text-align: center; margin: 14px 0 8px; }
.day span { background: rgba(255, 255, 255, .8); padding: 4px 12px; border-radius: 999px; font-size: 12.5px; color: var(--ink-soft); font-weight: 500; }

.row { display: flex; align-items: flex-end; gap: 6px; margin-top: 10px; position: relative; }
.row.cont { margin-top: 3px; }
.row.mine { justify-content: flex-end; }
.row .face { width: 34px; height: 34px; flex: none; }
.row .face .bear { width: 34px; height: 34px; }
.row.cont .face { visibility: hidden; }
.row.mine .face { display: none; }
.row.new { animation: popIn .42s cubic-bezier(.2, 1.5, .4, 1) both; }
.row.mine.new { transform-origin: 100% 100%; }
.row.theirs.new { transform-origin: 0% 100%; }
@keyframes popIn { from { transform: scale(.4) translateY(14px); opacity: 0; } to { transform: none; opacity: 1; } }

.bubble {
  max-width: min(76%, 520px); padding: 9px 13px 7px; border-radius: 22px; font-size: 16.5px; line-height: 1.32;
  border: 2px solid; position: relative; word-wrap: break-word; overflow-wrap: anywhere; white-space: pre-wrap;
  box-shadow: 0 3px 8px rgba(91, 64, 51, .06);
  -webkit-user-select: text; user-select: text;
}
.from-bubu .bubble { background: var(--bubu-bubble); border-color: var(--bubu-edge); }
.from-dudu .bubble { background: var(--dudu-bubble); border-color: var(--dudu-edge); }
.row.mine .bubble { border-bottom-right-radius: 8px; }
.row.theirs .bubble { border-bottom-left-radius: 8px; }
.bubble a { color: var(--pink-deep); }
.bubble .time { display: inline-block; font-size: 11px; color: var(--ink-soft); margin-left: 8px; vertical-align: -1px; float: right; margin-top: 6px; }
.row.emoji .bubble { background: none !important; border: 0; box-shadow: none; font-size: 46px; line-height: 1.1; padding: 0 4px; }
.row.emoji .bubble .time, .row.sticker .time, .row.image .time { display: none; }

.row.sticker .sticker-wrap { width: 132px; }
.row.sticker .sticker-wrap .couple { width: 190px; }
.row.sticker .sticker-wrap:has(.couple) { width: 190px; }

.row.image .photo { max-width: min(68vw, 300px); border-radius: 20px; overflow: hidden; border: 3px solid #fff; box-shadow: var(--shadow); background: #ffe9ef; }
.row.image .photo img { display: block; width: 100%; height: auto; }

.react {
  position: absolute; bottom: -8px; background: #fff; border-radius: 999px; font-size: 14px; padding: 1px 5px;
  box-shadow: 0 2px 6px rgba(91, 64, 51, .18); animation: bounceIn .4s cubic-bezier(.2, 1.6, .4, 1) both;
}
.row.mine .react { right: 6px; }
.row.theirs .react { left: 46px; }
.row.has-react { margin-bottom: 8px; }

.event { display: flex; flex-direction: column; align-items: center; margin: 14px 0 6px; }
.event button { display: flex; flex-direction: column; align-items: center; }
.event .bear { width: 150px; }
.event .bear:not(.couple) { width: 92px; }
.event .label { background: rgba(255, 255, 255, .85); padding: 4px 12px; border-radius: 999px; font-size: 13.5px; font-weight: 500; margin-top: 2px; }

.seen { display: flex; justify-content: flex-end; align-items: center; gap: 4px; font-size: 12px; color: var(--ink-soft); margin: 3px 4px 0 0; }
.seen .bear { width: 20px; height: 20px; }
.seen.new { animation: popIn .35s ease both; }

.typing { display: flex; align-items: flex-end; gap: 6px; margin-top: 10px; }
.typing .face .bear { width: 34px; height: 34px; }
.typing .dots3 { display: flex; gap: 4px; padding: 13px 14px; border-radius: 22px; border-bottom-left-radius: 8px; border: 2px solid var(--bubu-edge); background: #fff; }
.typing.from-dudu .dots3 { background: var(--dudu-bubble); border-color: var(--dudu-edge); }
.typing .dots3 i { width: 8px; height: 8px; border-radius: 50%; background: var(--ink-soft); animation: tdot 1.1s infinite; }
.typing .dots3 i:nth-child(2) { animation-delay: .15s; }
.typing .dots3 i:nth-child(3) { animation-delay: .3s; }
@keyframes tdot { 0%, 60%, 100% { transform: translateY(0); opacity: .5; } 30% { transform: translateY(-5px); opacity: 1; } }

.pending-row .bubble { opacity: .6; }

/* ---------- trays ---------- */
.tray {
  background: rgba(255, 250, 251, .96); border-top: 2px solid #ffd9e3; max-height: 42vh; overflow-y: auto;
  position: relative; z-index: 2; animation: slideUp .25s ease both;
}
@keyframes slideUp { from { transform: translateY(30px); opacity: 0; } }
.tabs { display: flex; gap: 6px; padding: 10px 12px 4px; position: sticky; top: 0; background: rgba(255, 250, 251, .96); }
.tabs button { padding: 6px 14px; border-radius: 999px; background: #fff; font-weight: 600; font-size: 15px; box-shadow: 0 2px 6px rgba(201, 107, 135, .15); }
.tabs button.on { background: var(--pink); color: #fff; }
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(88px, 1fr)); gap: 6px; padding: 8px 10px 14px; }
.grid.wide { grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); }
.grid button { border-radius: 18px; padding: 4px; transition: transform .12s, background .12s; display: flex; flex-direction: column; align-items: center; font-size: 13px; font-weight: 500; }
.grid button:active { transform: scale(.9); background: var(--pink-soft); }
.grid .bear { width: 100%; height: auto; aspect-ratio: 1; }
.grid .couple { aspect-ratio: 208 / 146; }
.love-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; padding: 12px; }
.love-grid button { background: #fff; border-radius: 20px; padding: 6px 4px 8px; box-shadow: 0 3px 10px rgba(201, 107, 135, .15); font-weight: 600; font-size: 14px; display: flex; flex-direction: column; align-items: center; transition: transform .12s; }
.love-grid button:active { transform: scale(.92); }
.love-grid .bear { width: 100%; height: 74px; }

/* ---------- composer ---------- */
.composer {
  display: flex; align-items: flex-end; gap: 7px; padding: 8px 10px calc(var(--safe-bottom) + 8px);
  background: rgba(255, 240, 245, .9); -webkit-backdrop-filter: blur(14px); backdrop-filter: blur(14px);
  border-top: 2px solid #ffd9e3; position: relative; z-index: 3;
}
body.kb .composer { padding-bottom: 8px; }
.cbtn { width: 42px; height: 42px; border-radius: 50%; background: #fff; display: grid; place-items: center; font-size: 21px; flex: none; box-shadow: 0 3px 8px rgba(201, 107, 135, .18); transition: transform .12s; }
.cbtn:active, .cbtn.on { transform: scale(.9); background: var(--pink-soft); }
.input-wrap { flex: 1; min-width: 0; display: flex; align-items: flex-end; background: #fff; border-radius: 22px; border: 2px solid #ffd2de; min-height: 42px; }
.input-wrap textarea {
  flex: 1; min-width: 0; width: 0; border: 0; outline: 0; resize: none; background: none; font-size: 16.5px; line-height: 1.3;
  padding: 9px 4px 9px 14px; max-height: 120px; min-height: 38px;
}
.input-wrap textarea::placeholder { color: #c7aaa0; }
.input-wrap .cbtn { width: 34px; height: 38px; box-shadow: none; background: none; font-size: 20px; }
.send {
  width: 46px; height: 46px; border-radius: 50%; flex: none; display: grid; place-items: center; font-size: 22px;
  background: linear-gradient(145deg, #ff8fab, var(--pink-deep)); color: #fff; box-shadow: 0 5px 14px rgba(240, 80, 122, .4);
  transition: transform .15s;
}
.send:active { transform: scale(.88) rotate(-8deg); }
.send svg { width: 24px; height: 24px; }

/* ---------- sheets ---------- */
.sheet-back { position: fixed; inset: 0; background: rgba(91, 64, 51, .28); z-index: 20; display: flex; align-items: flex-end; animation: fadeIn .2s ease both; }
@keyframes fadeIn { from { opacity: 0; } }
.sheet {
  width: 100%; max-height: 88vh; overflow-y: auto; background: #fffafb; border-radius: 28px 28px 0 0;
  padding: 10px 18px calc(var(--safe-bottom) + 22px); animation: slideUp .3s cubic-bezier(.2, 1.2, .4, 1) both;
}
.sheet .grab { width: 44px; height: 5px; border-radius: 3px; background: #f1cfd8; margin: 0 auto 8px; }
.sheet h2 { margin: 6px 0 8px; font-size: 22px; }
.sheet h3 { margin: 18px 0 8px; font-size: 16px; color: var(--ink-soft); font-weight: 600; }
.sheet .moods { display: grid; grid-template-columns: repeat(4, 1fr); gap: 6px; }
.sheet .moods button { border-radius: 16px; padding: 4px 2px; font-size: 12px; display: flex; flex-direction: column; align-items: center; border: 2.5px solid transparent; }
.sheet .moods button.on { border-color: var(--pink); background: #fff; }
.sheet .moods .bear { width: 60px; height: 60px; }
.sheet .field { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.sheet .note { font-size: 13.5px; color: var(--ink-soft); margin: 6px 0 0; }
.sheet .foot { text-align: center; color: var(--ink-soft); font-size: 13px; margin-top: 22px; }

/* ---------- effects overlay ---------- */
#fx { position: fixed; inset: 0; pointer-events: none; z-index: 30; overflow: hidden; }
.fx-stage {
  position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center;
  background: radial-gradient(circle at 50% 45%, rgba(255, 255, 255, .92), rgba(255, 214, 226, .75) 60%, rgba(255, 190, 210, .55));
  pointer-events: auto; animation: fadeIn .25s ease both;
}
.fx-stage.out { animation: fadeOut .35s ease forwards; }
@keyframes fadeOut { to { opacity: 0; } }
.fx-stage .bear { width: min(330px, 80vw); animation: bigPop .8s cubic-bezier(.2, 1.5, .4, 1) both; }
.fx-stage .bear:not(.couple) { width: min(240px, 62vw); }
.fx-stage .caption { margin-top: 10px; font-size: 24px; font-weight: 700; text-align: center; padding: 0 24px; animation: bounceIn .6s .25s cubic-bezier(.2, 1.6, .4, 1) both; }
@keyframes bigPop { 0% { transform: scale(.2) rotate(-12deg); opacity: 0; } 60% { transform: scale(1.08) rotate(3deg); opacity: 1; } 80% { transform: scale(.96, 1.04); } 100% { transform: scale(1); } }
.fx-stage .bear.hugging { animation: bigPop .8s cubic-bezier(.2, 1.5, .4, 1) both, hugSquish 1.1s .8s ease-in-out infinite; }
@keyframes hugSquish { 0%, 100% { transform: scale(1); } 50% { transform: scale(1.06, .95); } }
.fx-stage .big-heart { font-size: 150px; animation: bigPop .7s cubic-bezier(.2, 1.5, .4, 1) both, beat 1s .7s infinite; filter: drop-shadow(0 10px 20px rgba(240, 80, 122, .35)); }
.fx-stage .poke-word { position: absolute; top: 22%; font-size: 56px; font-weight: 700; color: var(--pink-deep); -webkit-text-stroke: 2px #fff; animation: bounceIn .4s .1s both, shake .4s .5s 2; }

.particle { position: fixed; left: 0; top: 0; font-size: var(--fs, 24px); will-change: transform, opacity; pointer-events: none; z-index: 31; animation: burst var(--dur, 1.1s) cubic-bezier(.15, .7, .3, 1) forwards; }
@keyframes burst {
  0% { transform: translate(var(--x0), var(--y0)) scale(.3); opacity: 1; }
  70% { opacity: 1; }
  100% { transform: translate(var(--x1), var(--y1)) scale(1) rotate(var(--rot, 0deg)); opacity: 0; }
}
.rain { position: fixed; top: -40px; font-size: var(--fs, 26px); pointer-events: none; z-index: 31; animation: fall var(--dur, 3s) linear forwards; }
@keyframes fall { to { transform: translate(var(--sway, 0px), 110vh) rotate(var(--rot, 180deg)); } }

.toast {
  position: fixed; left: 0; right: 0; margin: 0 auto; width: fit-content; max-width: calc(100vw - 32px); text-align: center;
  bottom: calc(var(--safe-bottom) + 90px); z-index: 40;
  background: var(--ink); color: #fff; padding: 10px 18px; border-radius: 22px; font-size: 15px; box-shadow: var(--shadow);
  animation: bounceIn .35s cubic-bezier(.2, 1.6, .4, 1) both;
}

.viewer { position: fixed; inset: 0; z-index: 35; background: rgba(40, 25, 20, .9); display: grid; place-items: center; animation: fadeIn .2s both; }
.viewer img { max-width: 96vw; max-height: 86vh; border-radius: 16px; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; }
  #sky { display: none; }
}

/* ---------- your own Bubu & Dudu art ---------- */
img.bear.art { object-fit: contain; -webkit-touch-callout: none; }
.row.sticker .sticker-wrap img.art { width: 100%; height: auto; max-height: 160px; }
.grid img.art { width: 100%; aspect-ratio: 1; }
.add-tile { border: 2.5px dashed #ffb6c8 !important; background: rgba(255, 255, 255, .6) !important; color: var(--pink-deep); justify-content: center; min-height: 88px; gap: 2px; }
.add-tile .plus { font-size: 30px; line-height: 1; font-weight: 600; }
.grid .custom { position: relative; }

/* ---------- lists ---------- */
.row.list .listcard {
  width: min(78vw, 340px); border-radius: 22px; border: 2px solid; padding: 11px 12px 8px; position: relative;
  box-shadow: 0 3px 8px rgba(91, 64, 51, .06);
}
.from-bubu .listcard { background: var(--bubu-bubble); border-color: var(--bubu-edge); }
.from-dudu .listcard { background: var(--dudu-bubble); border-color: var(--dudu-edge); }
.row.mine .listcard { border-bottom-right-radius: 8px; }
.row.theirs .listcard { border-bottom-left-radius: 8px; }
.lc-head { display: flex; justify-content: space-between; align-items: baseline; gap: 8px; font-weight: 600; font-size: 17px; }
.lc-title { overflow-wrap: anywhere; }
.lc-count { font-size: 13px; color: var(--ink-soft); flex: none; }
.lc-bar { height: 6px; border-radius: 3px; background: rgba(91, 64, 51, .1); margin: 7px 0 4px; overflow: hidden; }
.lc-bar i { display: block; height: 100%; border-radius: 3px; background: linear-gradient(90deg, #ff9fb6, var(--pink)); transition: width .35s cubic-bezier(.2, 1.3, .4, 1); }
.listcard ul { list-style: none; margin: 0; padding: 0; }
.listcard li button { display: flex; align-items: center; gap: 9px; width: 100%; padding: 7px 2px; text-align: left; font-size: 16px; line-height: 1.25; border-radius: 10px; }
.listcard li button:active { background: rgba(255, 111, 145, .1); }
.listcard li + li button { border-top: 1px dashed rgba(91, 64, 51, .14); }
.listcard .tick {
  flex: none; width: 24px; height: 24px; border-radius: 50%; border: 2px solid #e8b6c4; background: #fff;
  display: grid; place-items: center; color: #fff; font-weight: 700; font-size: 14px; transition: background .2s, border-color .2s, transform .2s;
}
.listcard .done .tick { background: var(--pink); border-color: var(--pink); animation: squish .4s ease; }
.listcard .txt { flex: 1; overflow-wrap: anywhere; transition: color .2s; }
.listcard .done .txt { text-decoration: line-through; text-decoration-color: rgba(240, 80, 122, .7); text-decoration-thickness: 2px; color: var(--ink-soft); }
.listcard .by .bear { width: 20px; height: 20px; }
.lc-done { margin-top: 6px; text-align: center; font-weight: 600; color: var(--pink-deep); animation: bounceIn .5s cubic-bezier(.2, 1.6, .4, 1) both; }
.lc-done span { display: block; font-weight: 500; font-size: 12.5px; color: var(--ink-soft); }
.listcard .time { display: block; text-align: right; font-size: 11px; color: var(--ink-soft); margin-top: 2px; }
.listcard.complete { box-shadow: 0 0 0 3px rgba(255, 111, 145, .18), 0 3px 8px rgba(91, 64, 51, .06); }
.lt-input, .li-input {
  width: 100%; background: #fff; border: 2px solid #ffd2de; border-radius: 16px; padding: 10px 14px; font-size: 16px; outline: 0; margin-top: 8px; resize: none;
}
.lt-input:focus, .li-input:focus { border-color: var(--pink); }
.fx-stage .caption small { font-size: 17px; font-weight: 500; color: var(--ink-soft); }
