/* =====================================================================
 * 🎮 게임 화면 (2026-10-09): 내 캐릭터 · 꾸미기 · 상점 · 도감 · 퀴즈 아이템
 * ===================================================================== */

/* ---------- 캐릭터 SVG ---------- */
.pet { display: block; overflow: visible; }
.pet .pe { display: none; }
.pet.ex-n .pe-n, .pet.ex-h .pe-h, .pet.ex-w .pe-w, .pet.ex-s .pe-s, .pet.ex-z .pe-z { display: inline; }
.pet .pt-bob, .pet .pt-char, .pet .pt-tail, .pet .pt-arm, .pet .pt-ears, .pet .pt-float, .pet .pt-spin, .pet .pt-sprout,
.pet .pe-n, .pet .pt-tw, .pet .pt-glow, .pet .pt-petal, .pet .pt-drift, .pet .pt-beam { transform-box: fill-box; }
.pet .pt-bob { transform-origin: 50% 100%; animation: ptBreath 2.6s ease-in-out infinite; }
.pet .pe-n { transform-origin: 50% 50%; animation: ptBlink 4.2s infinite; }
.pet .pt-tail { transform-origin: 0% 100%; animation: ptWag 1.6s ease-in-out infinite; }
.pet.sp-cat .pt-tail { transform-origin: 10% 90%; animation-duration: 2.4s; }
.pet .pt-arm { transform-origin: 30% 30%; animation: ptArm 3.2s ease-in-out infinite; }
.pet .pt-ears { transform-origin: 50% 100%; animation: ptEar 5s ease-in-out infinite; }
.pet .pt-sprout { transform-origin: 50% 100%; animation: ptWag 2.2s ease-in-out infinite; }
.pet .pt-float { transform-origin: 50% 100%; animation: ptFloat 3s ease-in-out infinite; }
.pet .pt-spin { transform-origin: 50% 50%; animation: ptSpin 9s linear infinite; }
.pet .pt-tw { transform-origin: 50% 50%; animation: ptTwinkle 2.2s ease-in-out infinite; }
.pet .pt-glow { transform-origin: 50% 50%; animation: ptGlow 1.8s ease-in-out infinite; }
.pet .pt-petal { animation: ptPetal 6s linear infinite; }
.pet .pt-drift { animation: ptDrift 14s ease-in-out infinite alternate; }
.pet .pt-beam { transform-origin: 50% 0%; animation: ptBeam 4s ease-in-out infinite alternate; }
.pet .pt-beam.b2 { animation-delay: -2s; }
.pet.still *, .pet.still { animation: none !important; }
@keyframes ptBreath { 0%, 100% { transform: scale(1, 1); } 50% { transform: scale(1.025, .97); } }
@keyframes ptBlink { 0%, 92%, 100% { transform: scaleY(1); } 95% { transform: scaleY(.1); } }
@keyframes ptWag { 0%, 100% { transform: rotate(-6deg); } 50% { transform: rotate(8deg); } }
@keyframes ptArm { 0%, 100% { transform: rotate(0); } 50% { transform: rotate(-7deg); } }
@keyframes ptEar { 0%, 86%, 100% { transform: rotate(0); } 90% { transform: rotate(-4deg); } 95% { transform: rotate(3deg); } }
@keyframes ptFloat { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-5px); } }
@keyframes ptSpin { to { transform: rotate(360deg); } }
@keyframes ptTwinkle { 0%, 100% { opacity: 1; transform: scale(1); } 50% { opacity: .35; transform: scale(.6); } }
@keyframes ptGlow { 0%, 100% { opacity: .65; transform: scale(.92); } 50% { opacity: 1; transform: scale(1.08); } }
@keyframes ptPetal { 0% { transform: translate(0, -30px) rotate(0); opacity: 0; } 10% { opacity: 1; } 100% { transform: translate(-40px, 220px) rotate(540deg); opacity: 0; } }
@keyframes ptDrift { from { transform: translateX(-8px); } to { transform: translateX(12px); } }
@keyframes ptBeam { from { transform: rotate(-6deg); } to { transform: rotate(6deg); } }

/* 반응 (JS 가 클래스를 붙였다 떼요) */
.pet.jump .pt-char { transform-box: fill-box; transform-origin: 50% 100%; animation: ptJump .6s cubic-bezier(.3, 1.6, .5, 1); }
.pet.shake .pt-char { transform-box: fill-box; transform-origin: 50% 100%; animation: ptShake .45s ease; }
.pet.spin .pt-char { transform-box: fill-box; transform-origin: 50% 60%; animation: ptTwirl .7s ease; }
@keyframes ptJump { 0% { transform: translateY(0) scale(1.08, .9); } 40% { transform: translateY(-26px) scale(.95, 1.06); } 70% { transform: translateY(0) scale(1.06, .94); } 100% { transform: none; } }
@keyframes ptShake { 20%, 60% { transform: translateX(-6px) rotate(-3deg); } 40%, 80% { transform: translateX(6px) rotate(3deg); } }
@keyframes ptTwirl { 0% { transform: rotate(0) scale(1); } 50% { transform: rotate(180deg) scale(.85); } 100% { transform: rotate(360deg) scale(1); } }
@media (prefers-reduced-motion: reduce) { .pet *, .pet { animation: none !important; } }

/* 퀴즈 응원 캐릭터: 통통 튀며 대기, 시간이 얼마 안 남으면 안절부절 */
.pet.buddy-pet .pt-char { transform-box: fill-box; transform-origin: 50% 100%; animation: ptHop 1.8s ease-in-out infinite; }
.pet.buddy-pet.nervous .pt-char { animation: ptNervous .35s ease-in-out infinite; }
.pet.buddy-pet.jump .pt-char { animation: ptJump .6s cubic-bezier(.3, 1.6, .5, 1) 2; }
.pet.buddy-pet.shake .pt-char { animation: ptShake .45s ease 2; }
.pet.buddy-pet.spin .pt-char { animation: ptTwirl .7s ease; }
@keyframes ptHop { 0%, 60%, 100% { transform: translateY(0) scale(1, 1); } 70% { transform: translateY(0) scale(1.06, .94); } 82% { transform: translateY(-9px) scale(.97, 1.03); } 92% { transform: translateY(0) scale(1.03, .97); } }
@keyframes ptNervous { 0%, 100% { transform: translateX(-2px) rotate(-2deg); } 50% { transform: translateX(2px) rotate(2deg); } }

/* ---------- 하단 탭 5개 (가운데 내 캐릭터) ---------- */
.tabbar.five { grid-template-columns: repeat(5, 1fr); align-items: end; }
.tabbar.five a { font-size: 11px; white-space: nowrap; }
.tab-pet { position: relative; }
.tab-pet .tp-face { display: grid; place-items: center; width: 54px; height: 54px; margin-top: -26px; border-radius: 50%;
  background: linear-gradient(150deg, #ffe3f1, #ece2ff); border: 3px solid #fff; box-shadow: 0 6px 16px rgba(169, 139, 255, .35); overflow: hidden; }
.tab-pet .tp-face svg { width: 50px; height: 50px; }
.tab-pet .tp-egg { font-size: 28px; animation: eggWob 2s ease-in-out infinite; }
.tab-pet.on .tp-face { border-color: #ff7eb6; }
@keyframes eggWob { 0%, 70%, 100% { transform: rotate(0); } 80% { transform: rotate(-12deg); } 90% { transform: rotate(10deg); } }

/* ---------- 숫자 · 알림 · 꽃가루 ---------- */
.pt-bump { display: inline-block; animation: ptBump .5s ease; }
@keyframes ptBump { 40% { transform: scale(1.3); color: #ff4f98; } }
.gm-toasts { position: fixed; left: 50%; bottom: calc(96px + env(safe-area-inset-bottom)); transform: translateX(-50%); z-index: 90;
  display: flex; flex-direction: column; gap: 6px; align-items: center; width: max-content; max-width: calc(100vw - 32px); pointer-events: none; }
.gm-toast { padding: 10px 16px; border-radius: 99px; background: #3b2b55; color: #fff; font-size: 14px; font-weight: 700; box-shadow: 0 8px 20px rgba(59, 43, 85, .3);
  animation: toastIn .3s cubic-bezier(.2, 1.5, .4, 1); text-align: center; word-break: keep-all; }
.gm-toast.ok { background: linear-gradient(135deg, #34c58e, #2bb3a3); }
.gm-toast.no { background: linear-gradient(135deg, #ff6b8a, #ff4f98); }
.gm-toast.info { background: linear-gradient(135deg, #9a7bff, #6cc4ff); }
.gm-toast.bye { opacity: 0; transform: translateY(8px); transition: .35s; }
@keyframes toastIn { from { opacity: 0; transform: translateY(14px) scale(.9); } }
.gm-confetti { position: fixed; inset: 0; pointer-events: none; z-index: 120; overflow: hidden; }
.gm-confetti i { position: absolute; top: -12px; width: 8px; height: 13px; border-radius: 2px; animation: cfFall linear forwards; }
.gm-confetti i.round { border-radius: 50%; width: 9px; height: 9px; }
@keyframes cfFall { 0% { transform: translate(0, 0) rotate(0); opacity: 1; } 100% { transform: translate(var(--dx), 105vh) rotate(var(--r)); opacity: .8; } }
.gm-float { position: absolute; z-index: 110; transform: translate(-50%, 0); pointer-events: none; font-family: var(--cute, sans-serif); font-size: 24px;
  color: #ff4f98; text-shadow: 0 2px 0 #fff, 0 0 10px #fff; animation: floatUp 1.2s ease-out forwards; white-space: nowrap; }
.gm-float.time { color: #1d8fe0; } .gm-float.xp { color: #20a96b; } .gm-float.buy { color: #ff8a1f; }
@keyframes floatUp { 0% { opacity: 0; transform: translate(-50%, 10px) scale(.6); } 20% { opacity: 1; transform: translate(-50%, -8px) scale(1.2); } 100% { opacity: 0; transform: translate(-50%, -60px) scale(1); } }

/* ---------- 팝업 ---------- */
.gm-modal { position: fixed; inset: 0; z-index: 100; display: grid; place-items: center; padding: 20px; background: rgba(40, 24, 70, .55);
  opacity: 0; transition: opacity .25s; -webkit-backdrop-filter: blur(3px); backdrop-filter: blur(3px); }
.gm-modal.show { opacity: 1; } .gm-modal.hide { opacity: 0; }
.gm-rays { position: absolute; left: 50%; top: 50%; width: 760px; height: 760px; margin: -380px 0 0 -380px; pointer-events: none; opacity: 0;
  background: repeating-conic-gradient(rgba(255, 255, 255, .16) 0 10deg, rgba(255, 255, 255, 0) 10deg 20deg); border-radius: 50%;
  -webkit-mask: radial-gradient(closest-side, #000 30%, transparent); mask: radial-gradient(closest-side, #000 30%, transparent); animation: ptSpin 18s linear infinite; }
.gm-modal.lvup .gm-rays, .gm-modal.ttl .gm-rays, .gm-modal.crd .gm-rays { opacity: 1; }
.gm-card { position: relative; width: 100%; max-width: 340px; padding: 22px 20px 18px; border-radius: 28px; background: #fff; text-align: center; color: #3b2b55;
  box-shadow: 0 24px 60px rgba(30, 10, 60, .35); transform: scale(.7); transition: transform .4s cubic-bezier(.2, 1.6, .4, 1); }
.gm-modal.show .gm-card { transform: scale(1); }
.gm-modal.lvup .gm-card { background: linear-gradient(170deg, #fff 55%, #fff3fa); border: 3px solid #ffd1e6; }
.gm-modal.stageup .gm-card { border-color: #ffd34d; box-shadow: 0 0 0 6px rgba(255, 211, 77, .35), 0 24px 60px rgba(30, 10, 60, .35); }
.gm-eyebrow { margin: 0; font-family: var(--cute, sans-serif); font-size: 15px; letter-spacing: .22em; color: #ff4f98; }
.gm-lv { font-family: var(--cute, sans-serif); font-size: 26px; color: #7b5cf5; line-height: 1; margin: 4px 0; }
.gm-lv b { font-size: 64px; font-weight: 400; background: linear-gradient(135deg, #ff6fae, #9a7bff); -webkit-background-clip: text; background-clip: text; color: transparent;
  display: inline-block; animation: lvPop .7s cubic-bezier(.2, 1.8, .4, 1) .15s both; }
@keyframes lvPop { from { transform: scale(.2) rotate(-20deg); opacity: 0; } }
.gm-pet { width: 150px; height: 150px; margin: -70px auto 0; filter: drop-shadow(0 10px 18px rgba(123, 92, 245, .35)); }
.gm-pet svg { width: 100%; height: 100%; }
.gm-sub { margin: 8px 0 0; font-size: 14px; color: #8a7ca3; line-height: 1.55; word-break: keep-all; }
.gm-stage { margin: 8px 0 0; padding: 8px 10px; border-radius: 14px; background: #fff7d6; color: #a06a00; font-size: 14.5px; }
.gm-h { margin: 6px 0 4px; font-family: var(--cute, sans-serif); font-weight: 400; font-size: 22px; }
.gm-rw { list-style: none; margin: 14px 0 4px; padding: 0; display: grid; gap: 7px; text-align: left; }
.gm-rw li { display: flex; align-items: center; gap: 9px; padding: 9px 12px; border-radius: 14px; background: #faf6ff; font-size: 14px; word-break: keep-all; }
.gm-rw li i { font-style: normal; font-size: 20px; }
.gm-rw li b { color: #ff4f98; }
.gm-rw li.cardline .fcard { width: 52px; flex: none; padding: 4px 2px; }
.gm-rw li.cardline .fcard .fc-emo { font-size: 22px; }
.gm-rw li.cardline .fcard b { font-size: 9px; } .gm-rw li.cardline .fcard small, .gm-rw li.cardline .fcard .fc-rar { display: none; }
.gm-btn { display: block; width: 100%; margin-top: 14px; padding: 14px; border: 0; border-radius: 16px; font: inherit; font-family: var(--cute, sans-serif); font-size: 19px; cursor: pointer;
  color: #fff; background: linear-gradient(135deg, #ff7eb6, #9a7bff); box-shadow: 0 5px 0 #6a4be0; }
.gm-btn:active { transform: translateY(2px); box-shadow: 0 3px 0 #6a4be0; }
.gm-btn.ghost { background: #f4effc; color: #8a7ca3; box-shadow: none; margin-top: 8px; font-size: 16px; padding: 11px; }
.gm-input { width: 100%; margin-top: 10px; padding: 13px; font: inherit; font-size: 17px; text-align: center; border: 2px solid #f1e2f1; border-radius: 14px; }
.gm-input:focus { outline: none; border-color: #ff7eb6; }
.gm-title { display: inline-flex; align-items: center; gap: 8px; margin: 14px 0 4px; padding: 10px 18px; border-radius: 99px; font-size: 20px; font-weight: 800;
  animation: lvPop .6s cubic-bezier(.2, 1.8, .4, 1) .1s both; }
.gm-title i { font-style: normal; font-size: 30px; }
.gift-row { display: flex; justify-content: center; gap: 8px; margin: 14px 0 4px; }
.gift-row svg { animation: lvPop .6s cubic-bezier(.2, 1.8, .4, 1) both; }
.gift-row svg:nth-child(2) { animation-delay: .1s; } .gift-row svg:nth-child(3) { animation-delay: .2s; } .gift-row svg:nth-child(4) { animation-delay: .3s; }

/* 등급 색 (일반 · 레어 · 에픽 · 전설) */
.rc { --r1: #7fd8b8; --r2: #3fbf98; --rbg: #ecfbf5; }
.rr { --r1: #7cc8ff; --r2: #3b8dff; --rbg: #eaf5ff; }
.re { --r1: #c3a6ff; --r2: #8b5cf6; --rbg: #f3edff; }
.rl { --r1: #ffd86b; --r2: #ff9a1f; --rbg: #fff6dc; }
.wt-rar { display: inline-block; padding: 1px 7px; border-radius: 99px; font-size: 10.5px; font-weight: 800; color: #fff; background: linear-gradient(135deg, var(--r1), var(--r2)); }
.gm-title { background: linear-gradient(135deg, var(--rbg), #fff); border: 2px solid var(--r1); color: #3b2b55; }

/* 칭호 뱃지 · 닉네임 색 */
.title-badge { display: inline-flex; align-items: center; gap: 4px; padding: 2px 9px 2px 6px; border-radius: 99px; font-size: 12px; font-weight: 800;
  background: var(--rbg); border: 1.5px solid var(--r1); color: #3b2b55; white-space: nowrap; vertical-align: middle; }
.title-badge i { font-style: normal; }
.nick { font-weight: 800; }
.nc-pink { color: #ff4f98; } .nc-mint { color: #1fb89a; } .nc-sky { color: #2b9bf0; } .nc-purple { color: #7b5cf5; }
.nc-sunset, .nc-gold, .nc-rainbow { -webkit-background-clip: text; background-clip: text; color: transparent; }
.nc-sunset { background-image: linear-gradient(90deg, #ff6f91, #ff9a52, #ffc24d); }
.nc-gold { background-image: linear-gradient(90deg, #c98a1c, #ffd24d, #f0a92b, #ffe36e); }
.nc-rainbow { background-image: linear-gradient(90deg, #ff4f98, #ff9a52, #ffd34d, #3fd3b4, #3b8dff, #8b5cf6, #ff4f98); background-size: 200% 100%; animation: rainbow 3s linear infinite; }
@keyframes rainbow { to { background-position: 200% 0; } }
.nc-sample { font-family: var(--cute, sans-serif); font-size: 22px; font-weight: 800; }

/* 운세 카드 */
.fcard { position: relative; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 1px; aspect-ratio: 3 / 4; padding: 10px 6px 8px;
  border-radius: 14px; background: linear-gradient(160deg, #fff, var(--rbg)); border: 2.5px solid var(--r1); box-shadow: inset 0 0 0 3px #fff, 0 4px 10px rgba(59, 43, 85, .1); overflow: hidden; }
.fcard::before { content: ""; position: absolute; inset: 0; background: radial-gradient(circle at 50% 38%, rgba(255, 255, 255, .9), transparent 55%); }
.fcard > * { position: relative; }
.fcard .fc-rar { position: absolute; top: 5px; left: 50%; transform: translateX(-50%); font-size: 9px; font-weight: 800; letter-spacing: .1em; color: var(--r2); }
.fcard .fc-emo { font-size: 34px; line-height: 1.15; filter: drop-shadow(0 3px 4px rgba(0, 0, 0, .12)); }
.fcard b { font-size: 12px; line-height: 1.25; text-align: center; word-break: keep-all; }
.fcard small { font-size: 10px; color: #8a7ca3; }
.fcard em { position: absolute; top: 4px; right: 4px; font-style: normal; font-size: 9px; font-weight: 900; color: #fff; background: #ff4f98; padding: 1px 5px; border-radius: 99px; }
.fcard em.qty { background: #7b5cf5; }
.fcard.rl { background: linear-gradient(160deg, #fffbe8, #ffe9b0); }
.fcard.rl::after { content: ""; position: absolute; inset: -40%; background: linear-gradient(115deg, transparent 40%, rgba(255, 255, 255, .8) 50%, transparent 60%); animation: shine 2.6s ease-in-out infinite; }
.fcard.re::after { content: ""; position: absolute; inset: -40%; background: linear-gradient(115deg, transparent 42%, rgba(255, 255, 255, .6) 50%, transparent 58%); animation: shine 3.4s ease-in-out infinite; }
@keyframes shine { 0% { transform: translateX(-60%); } 60%, 100% { transform: translateX(60%); } }
.fcard.big { width: 170px; margin: 12px auto 0; padding: 18px 10px 14px; border-width: 3px; }
.fcard.big .fc-emo { font-size: 72px; } .fcard.big b { font-size: 18px; } .fcard.big small { font-size: 12px; } .fcard.big .fc-rar { font-size: 11px; top: 9px; }
.fcard.back { background: repeating-linear-gradient(45deg, #f6f1ff 0 8px, #fff 8px 16px); border-style: dashed; border-color: #e3d8f5; box-shadow: none; }
.fcard.back::before { display: none; }
.fcard.back .fc-q { font-family: var(--cute, sans-serif); font-size: 32px; color: #d3c6ec; }

/* 카드 뒤집기 */
.flip { width: 170px; height: 227px; margin: 14px auto 0; perspective: 900px; cursor: pointer; }
.flip-in { position: relative; width: 100%; height: 100%; transition: transform .8s cubic-bezier(.3, 1.4, .5, 1); transform-style: preserve-3d; }
.flip.open .flip-in { transform: rotateY(180deg); }
.flip.wiggle .flip-in { animation: wig .4s ease infinite; }
@keyframes wig { 25% { transform: rotate(-4deg) scale(1.03); } 75% { transform: rotate(4deg) scale(1.03); } }
.flip-back, .flip-front { position: absolute; inset: 0; -webkit-backface-visibility: hidden; backface-visibility: hidden; border-radius: 16px; }
.flip-back { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px; color: #fff; border: 3px solid #fff;
  background: radial-gradient(circle at 50% 40%, #b18cff, #6a4be0 70%); box-shadow: 0 10px 24px rgba(106, 75, 224, .35), inset 0 0 0 6px rgba(255, 255, 255, .25); }
.flip-back span { font-size: 54px; line-height: 1; color: #ffe36e; animation: ptTwinkle 1.6s ease-in-out infinite; }
.flip-back b { font-family: var(--cute, sans-serif); font-weight: 400; letter-spacing: .2em; font-size: 15px; }
.flip-back small { letter-spacing: .3em; font-size: 10px; opacity: .8; }
.flip-front { transform: rotateY(180deg); }
.flip-front .fcard.big { width: 100%; height: 100%; margin: 0; aspect-ratio: auto; }
.flip.open.r-l .flip-front, .flip.open.r-e .flip-front { box-shadow: 0 0 30px 6px rgba(255, 211, 77, .7); }

/* ---------- 퀴즈: 응원 캐릭터 · 아이템 ---------- */
.buddy { display: flex; align-items: flex-end; gap: 8px; margin: -6px 0 10px; }
.buddy svg.pet { flex: none; width: 84px; height: 84px; cursor: pointer; margin-bottom: -6px; }
.bubble { position: relative; flex: 1; margin: 0 0 14px; padding: 9px 13px; border-radius: 16px 16px 16px 4px; background: #fff5fb; border: 1.5px solid #f8d4e8;
  font-size: 14px; font-weight: 700; color: #6b4a8a; line-height: 1.45; word-break: keep-all; }
.bubble.pop { animation: bubblePop .35s cubic-bezier(.2, 1.6, .4, 1); }
@keyframes bubblePop { from { transform: scale(.85); opacity: .3; } }
.itembar { display: grid; grid-template-columns: repeat(4, 1fr); gap: 7px; margin: 12px 0 2px; }
.itembar.busy { opacity: .7; pointer-events: none; }
.ib { position: relative; display: flex; flex-direction: column; align-items: center; gap: 1px; padding: 7px 2px 6px; border: 2px solid #f3e4f1; border-radius: 16px;
  background: #fff; font: inherit; cursor: pointer; transition: transform .1s; -webkit-tap-highlight-color: transparent; }
.ib:active:not(:disabled) { transform: scale(.94); }
.ib .ib-ico { display: block; line-height: 0; }
.ib .ib-ico svg { width: 38px; height: 38px; }
.ib .ib-name { font-size: 11.5px; font-weight: 800; color: #5b4a75; letter-spacing: -.02em; }
.ib .ib-cnt { position: absolute; top: -7px; right: -4px; min-width: 22px; padding: 1px 6px; border-radius: 99px; background: #7b5cf5; color: #fff; font-size: 11px; font-weight: 900; border: 2px solid #fff; }
.ib.empty .ib-cnt { background: #ffb020; }
.ib .ib-cnt em { font-style: normal; }
.ib .ib-ask { position: absolute; inset: -2px; display: none; place-items: center; border-radius: 16px; background: rgba(255, 79, 152, .94); color: #fff; font-size: 13px; font-weight: 900; }
.ib.ask .ib-ask { display: grid; animation: bubblePop .25s ease; }
.ib:disabled { cursor: default; }
.ib.used { opacity: .4; filter: grayscale(.7); }
.ib.used::after { content: "사용"; position: absolute; bottom: 4px; font-size: 10px; font-weight: 900; color: #fff; background: #3b2b55; padding: 0 6px; border-radius: 99px; }
.ib.blocked { opacity: .35; filter: grayscale(1); }
.ib.passive { border-style: dashed; }
.ib.passive .ib-name::after { content: " 자동"; color: #ff5a5f; }
.ib.fire { animation: ibFire .6s ease; }
@keyframes ibFire { 0% { transform: scale(1); } 30% { transform: scale(1.25) rotate(-6deg); box-shadow: 0 0 0 8px rgba(255, 111, 174, .25); } 100% { transform: scale(1); } }
.boost-tag { margin: -6px 0 10px; text-align: center; font-family: var(--cute, sans-serif); font-size: 17px; color: #fff; padding: 6px; border-radius: 12px;
  background: linear-gradient(90deg, #ffb020, #ff6fae, #ffb020); background-size: 200% 100%; animation: rainbow 1.6s linear infinite; text-shadow: 0 1px 0 rgba(0, 0, 0, .15); }
.card.boosted { border-color: #ffc24d !important; box-shadow: 0 0 0 3px rgba(255, 194, 77, .45), 0 10px 30px rgba(255, 138, 31, .25) !important; }
.card.boost-in { animation: boostIn .8s ease; }
@keyframes boostIn { 0% { transform: scale(1); } 25% { transform: scale(1.03); filter: brightness(1.15); } 100% { transform: scale(1); } }
.card.revived { animation: revived .9s ease; }
@keyframes revived { 0% { box-shadow: 0 0 0 0 rgba(255, 90, 95, .7); } 40% { box-shadow: 0 0 0 16px rgba(255, 90, 95, 0); filter: brightness(1.3); } 100% { filter: none; } }
.timer.plus .timer-bar { box-shadow: 0 0 0 4px rgba(59, 141, 255, .3); }
.timer.plus b { color: #1d8fe0; animation: tbeat .4s ease 2; }
.fun-opt.zap, .opt.zap { animation: zap .45s ease forwards; }
@keyframes zap { 0% { transform: none; } 30% { transform: translateX(-5px) rotate(-2deg); background: #fff0f3; } 60% { transform: translateX(5px) rotate(2deg); } 100% { transform: scale(.96); opacity: .5; } }
.fun-opt.gone, .opt.gone { opacity: .28; text-decoration: line-through; filter: grayscale(1); pointer-events: none; }
.fun-opt.miss, .opt.miss { background: #fff0f3 !important; border-color: #ff6b8a !important; animation: rshake .4s ease; }
.rs-chips { display: flex; gap: 6px; flex-wrap: wrap; margin-top: 6px; }
.rs-chips i { font-style: normal; font-size: 12px; font-weight: 800; padding: 3px 9px; border-radius: 99px; background: rgba(255, 255, 255, .8); color: #6b4a8a; }
.rs-chips i.xp { color: #1a9e6b; }
.x2 { font-style: normal; font-size: .8em; color: #fff; background: linear-gradient(135deg, #ffb020, #ff6fae); padding: 0 8px; border-radius: 99px; vertical-align: 2px; }
.fr-bag { display: flex; align-items: center; gap: 8px; margin: 12px 0 0; padding: 9px 12px; border-radius: 16px; background: #fff8fc; border: 1.5px dashed #f4c6e0; text-decoration: none; }
.frb-t { font-size: 13px; font-weight: 800; color: #6b4a8a; }
.frb-i { display: inline-flex; align-items: center; gap: 2px; font-size: 13px; }
.frb-i svg { width: 22px; height: 22px; }
.frb-go { margin-left: auto; font-size: 12px; font-weight: 800; color: #ff4f98; }
.egg-cta { display: grid; grid-template-columns: auto 1fr; gap: 0 10px; align-items: center; margin-top: 12px; padding: 12px 14px; border-radius: 18px; text-align: left; text-decoration: none;
  background: linear-gradient(135deg, #fff3d6, #ffe6f2); border: 1.5px solid #ffd9a8; }
.egg-cta span { grid-row: span 2; font-size: 30px; animation: eggWob 2s ease-in-out infinite; }
.egg-cta b { font-size: 14.5px; } .egg-cta small { font-size: 12px; color: #8a7ca3; }
.egg-cta.big { margin: 18px 0 0; padding: 16px; }

/* 부활할까요? */
.gm-revive { position: fixed; inset: 0; z-index: 100; display: grid; place-items: center; padding: 20px; background: rgba(20, 8, 36, .78); opacity: 0; transition: opacity .25s; }
.gm-revive.show { opacity: 1; }
.gm-revive.flash { background: #fff; transition: background .2s; }
.rv-box { width: 100%; max-width: 330px; text-align: center; color: #fff; }
.rv-eyebrow { margin: 0; font-family: var(--cute, sans-serif); font-size: 30px; letter-spacing: .14em; color: #ff8fb8; text-shadow: 0 0 18px rgba(255, 79, 152, .7); animation: tbeat 1s ease-in-out infinite; }
.rv-ring { position: relative; width: 150px; height: 150px; margin: 10px auto 6px; }
.rv-ring svg { width: 100%; height: 100%; transform: rotate(-90deg); }
.rv-ring circle { fill: none; stroke-width: 9; }
.rv-ring .rv-bg { stroke: rgba(255, 255, 255, .15); }
.rv-ring .rv-fg { stroke: #ff5a7e; stroke-linecap: round; filter: drop-shadow(0 0 6px #ff5a7e); }
.rv-heart { position: absolute; inset: 0; display: grid; place-items: center; font-size: 62px; animation: heartBeat .9s ease-in-out infinite; }
.rv-num { position: absolute; right: 2px; bottom: 6px; width: 40px; height: 40px; display: grid; place-items: center; border-radius: 50%; background: #fff; color: #ff4f6e;
  font-family: var(--cute, sans-serif); font-weight: 400; font-size: 24px; }
.gm-revive.hurry .rv-heart { animation-duration: .45s; }
@keyframes heartBeat { 0%, 100% { transform: scale(1); } 20% { transform: scale(1.18); } 40% { transform: scale(.96); } 60% { transform: scale(1.1); } }
.rv-box h2 { margin: 6px 0 2px; font-family: var(--cute, sans-serif); font-weight: 400; font-size: 26px; }
.rv-box p { margin: 0 0 16px; font-size: 14px; opacity: .85; word-break: keep-all; }
.rv-go { display: flex; flex-direction: column; align-items: center; width: 100%; padding: 14px; border: 0; border-radius: 18px; cursor: pointer; font: inherit;
  font-family: var(--cute, sans-serif); font-size: 21px; color: #fff; background: linear-gradient(135deg, #ff7a7a, #ff4f98); box-shadow: 0 6px 0 #c2306c, 0 0 30px rgba(255, 79, 152, .5); }
.rv-go small { font-family: "Pretendard", sans-serif; font-size: 12px; opacity: .9; }
.rv-go:active { transform: translateY(3px); box-shadow: 0 3px 0 #c2306c; }
.rv-no { margin-top: 12px; padding: 8px; border: 0; background: none; color: rgba(255, 255, 255, .7); font: inherit; font-size: 14px; text-decoration: underline; cursor: pointer; }

/* ---------- 친구 고르기 ---------- */
.pick { text-align: center; }
.pk-eyebrow { margin: 6px 0 0; font-family: var(--cute, sans-serif); letter-spacing: .2em; color: #ff4f98; }
.pick h1 { margin: 4px 0 6px; font-family: var(--cute, sans-serif); font-weight: 400; font-size: 27px; }
.pk-lead { margin: 0 0 16px; font-size: 14px; color: #8a7ca3; line-height: 1.6; }
.pk-lead b { color: #7b5cf5; }
.pk-list { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; }
.pk-list .pk-card:last-child { grid-column: span 2; max-width: 50%; justify-self: center; width: 100%; }
.pk-card { position: relative; display: flex; flex-direction: column; align-items: center; padding: 6px 8px 12px; border: 2px solid #f3e4f1; border-radius: 22px; background: #fff;
  font: inherit; cursor: pointer; transition: transform .15s, border-color .15s, opacity .2s; box-shadow: 0 6px 16px rgba(169, 139, 255, .1); }
.pk-card .pk-art { width: 108px; height: 108px; } .pk-card .pk-art svg { width: 100%; height: 100%; }
.pk-card b { font-family: var(--cute, sans-serif); font-weight: 400; font-size: 20px; }
.pk-card small { font-size: 12px; color: #8a7ca3; word-break: keep-all; line-height: 1.4; }
.pk-card .pk-check { position: absolute; top: 8px; right: 8px; display: none; width: 26px; height: 26px; place-items: center; border-radius: 50%; background: #ff4f98; color: #fff; font-style: normal; font-size: 14px; }
.pk-card.on { border-color: #ff7eb6; transform: translateY(-3px); box-shadow: 0 10px 24px rgba(255, 111, 174, .3); background: linear-gradient(180deg, #fff, #fff4fa); }
.pk-card.on .pk-check { display: grid; }
.pk-list.chosen .pk-card:not(.on) { opacity: .55; }
.pk-form { position: sticky; bottom: calc(86px + env(safe-area-inset-bottom)); margin-top: 14px; padding: 14px; border-radius: 22px; background: #fff; border: 2px solid #ffd1e6;
  box-shadow: 0 10px 30px rgba(169, 139, 255, .25); text-align: left; animation: bubblePop .3s ease; }
.pk-form label { font-size: 14px; font-weight: 800; } .pk-form label small { color: #8a7ca3; font-weight: 400; }
.pk-row { display: flex; gap: 8px; margin-top: 8px; }
.pk-row input { flex: 1; min-width: 0; padding: 12px; font: inherit; font-size: 17px; border: 2px solid #f1e2f1; border-radius: 14px; }
.pk-row input:focus { outline: none; border-color: #ff7eb6; }
.btn.pk-go { width: auto; margin: 0; padding: 12px 14px; white-space: nowrap; font-family: var(--cute, sans-serif); font-weight: 400; font-size: 16px; color: #fff; background: linear-gradient(135deg, #ff7eb6, #9a7bff); }
.pk-gift { margin: 8px 0 0; font-size: 12.5px; color: #a06a00; }

/* 알 부화 */
.hatch { position: fixed; inset: 0; z-index: 95; display: flex; flex-direction: column; align-items: center; justify-content: center; cursor: pointer;
  background: radial-gradient(circle at 50% 45%, #fff7fb 0%, #ffe3f1 45%, #d9c8ff 100%); transition: opacity .6s; -webkit-tap-highlight-color: transparent; }
.ht-top { font-family: var(--cute, sans-serif); font-size: 24px; color: #6b4a8a; margin: 0 0 10px; } .ht-top b { color: #ff4f98; font-weight: 400; }
.ht-egg { width: 240px; height: 240px; animation: eggIdle 1.6s ease-in-out infinite; }
.ht-egg svg { width: 100%; height: 100%; }
.ht-egg .crack { opacity: 0; transition: opacity .1s; }
.ht-egg.c1 .crack.c1, .ht-egg.c2 .crack.c1, .ht-egg.c2 .crack.c2, .ht-egg.c3 .crack { opacity: 1; }
.ht-egg.knock { animation: eggKnock .4s ease; }
.ht-count { font-family: var(--cute, sans-serif); font-size: 22px; color: #9a7bff; margin: 10px 0 0; height: 30px; }
.hatch.burst .ht-egg { animation: eggBurst .65s ease forwards; }
.hatch.done { opacity: 0; pointer-events: none; }
@keyframes eggIdle { 0%, 80%, 100% { transform: rotate(0); } 85% { transform: rotate(-5deg); } 90% { transform: rotate(5deg); } 95% { transform: rotate(-3deg); } }
@keyframes eggKnock { 20% { transform: rotate(-10deg) scale(1.05); } 50% { transform: rotate(9deg); } 80% { transform: rotate(-4deg); } }
@keyframes eggBurst { 0% { transform: scale(1); } 40% { transform: scale(1.18, .9); } 100% { transform: scale(2.2); opacity: 0; filter: brightness(2.2); } }

/* ---------- 마이룸 ---------- */
.room-stage { position: relative; border-radius: 28px; overflow: hidden; box-shadow: 0 14px 34px rgba(169, 139, 255, .3); border: 3px solid #fff; background: #ffe9f4; }
.room-svg { position: relative; aspect-ratio: 1; cursor: pointer; -webkit-tap-highlight-color: transparent; }
.room-svg svg { width: 100%; height: 100%; display: block; }
.room.dressing .room-stage { position: sticky; top: 8px; z-index: 5; }
.room-hud { position: absolute; left: 10px; top: 10px; right: 10px; display: flex; align-items: center; gap: 8px; pointer-events: none; }
.room-hud > * { pointer-events: auto; }
.lv-badge { display: flex; flex-direction: column; align-items: center; justify-content: center; width: 50px; height: 50px; border-radius: 16px; color: #fff; line-height: 1;
  background: linear-gradient(150deg, #ff7eb6, #9a7bff); border: 3px solid #fff; box-shadow: 0 4px 10px rgba(123, 92, 245, .35); }
.lv-badge small { font-size: 10px; font-weight: 800; opacity: .9; }
.lv-badge b { font-family: var(--cute, sans-serif); font-weight: 400; font-size: 22px; }
.hud-name { display: flex; flex-direction: column; align-items: flex-start; gap: 2px; padding: 5px 10px 6px; border-radius: 14px; background: rgba(255, 255, 255, .88); }
.hud-name b { font-family: var(--cute, sans-serif); font-weight: 400; font-size: 18px; color: #3b2b55; line-height: 1.1; }
.hud-edit { border: 0; background: none; color: #b9a3d6; font-size: 14px; cursor: pointer; padding: 0 0 0 4px; position: absolute; margin: 1px 0 0 0; }
.hud-name { position: relative; padding-right: 26px; }
.hud-edit { right: 7px; top: 5px; }
.stage-chip { font-size: 10.5px; font-weight: 800; padding: 1px 7px; border-radius: 99px; color: #fff; background: #3fbf98; }
.stage-chip.st2 { background: #3b8dff; } .stage-chip.st3 { background: #8b5cf6; } .stage-chip.st4 { background: linear-gradient(90deg, #ffb020, #ff6fae); }
.room-bubble { position: absolute; left: 50%; bottom: 66%; transform: translateX(-50%); max-width: 78%; margin: 0; padding: 8px 14px; border-radius: 16px;
  background: #fff; font-size: 14px; font-weight: 800; color: #6b4a8a; text-align: center; box-shadow: 0 6px 16px rgba(59, 43, 85, .15); word-break: keep-all; white-space: normal; }
.room-bubble::after { content: ""; position: absolute; left: 50%; bottom: -7px; margin-left: -7px; border: 7px solid transparent; border-bottom: 0; border-top-color: #fff; }
.room-bubble.pop { animation: rbPop .35s cubic-bezier(.2, 1.6, .4, 1); }
@keyframes rbPop { from { transform: translateX(-50%) scale(.8); opacity: .3; } }
.pat-hint { position: absolute; left: 50%; bottom: 10px; transform: translateX(-50%); padding: 6px 12px; border-radius: 99px; background: rgba(59, 43, 85, .75); color: #fff; font-size: 12.5px;
  white-space: nowrap; animation: hintBob2 1.6s ease-in-out infinite; pointer-events: none; }
.pat-hint b { color: #ffe36e; }
@keyframes hintBob2 { 50% { transform: translate(-50%, -4px); } }
.tap-heart { position: absolute; z-index: 3; pointer-events: none; font-size: 22px; animation: heartUp 1.2s ease-out forwards; }
@keyframes heartUp { 0% { transform: translate(-50%, 0) scale(.4); opacity: 0; } 20% { opacity: 1; transform: translate(-50%, -14px) scale(1.15); } 100% { transform: translate(-50%, -90px) scale(.9); opacity: 0; } }
.room-info { margin: 12px 2px 0; }
.ri-top { display: flex; align-items: center; justify-content: space-between; gap: 8px; flex-wrap: wrap; }
.ri-nick { font-size: 16px; }
.title-empty { font-size: 12px; color: #8a7ca3; }
.exp-bar { position: relative; height: 22px; margin-top: 8px; border-radius: 99px; background: #fff; border: 2px solid #f1e2f1; overflow: hidden; }
.exp-bar i { position: absolute; left: 0; top: 0; bottom: 0; min-width: 4%; border-radius: 99px; background: linear-gradient(90deg, #7ed99b, #3fd3b4, #6cc4ff); transition: width .8s cubic-bezier(.2, 1.2, .4, 1); }
.exp-bar i::after { content: ""; position: absolute; inset: 3px 6px auto; height: 5px; border-radius: 99px; background: rgba(255, 255, 255, .55); }
.exp-bar span { position: relative; display: block; text-align: center; font-size: 12px; font-weight: 900; line-height: 18px; color: #3b2b55; text-shadow: 0 0 4px #fff; }
.ri-tip { margin: 6px 0 0; font-size: 12px; color: #8a7ca3; text-align: center; } .ri-tip b { color: #1fb89a; }
.room-actions { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; margin-top: 14px; }
.ra { position: relative; display: flex; flex-direction: column; align-items: center; gap: 1px; padding: 11px 2px 9px; border-radius: 18px; border: 0; font: inherit; cursor: pointer; text-decoration: none; color: #fff; }
.ra i { font-style: normal; font-size: 26px; line-height: 1.1; filter: drop-shadow(0 2px 2px rgba(0, 0, 0, .12)); }
.ra b { font-size: 12.5px; letter-spacing: -.03em; white-space: nowrap; }
.ra small { font-size: 10px; opacity: .9; white-space: nowrap; }
.ra-deco { background: linear-gradient(150deg, #ff8fc6, #ff5fa2); box-shadow: 0 4px 0 #d9407f; }
.ra-card { background: linear-gradient(150deg, #b18cff, #7b5cf5); box-shadow: 0 4px 0 #5638c9; }
.ra-shop { background: linear-gradient(150deg, #ffc24d, #ff9a1f); box-shadow: 0 4px 0 #d4790e; }
.ra-col { background: linear-gradient(150deg, #5fd3c0, #2eb5a8); box-shadow: 0 4px 0 #1e8f84; }
.ra:active { transform: translateY(2px); }
.ra.hot::after { content: "!"; position: absolute; top: -5px; right: -3px; width: 20px; height: 20px; display: grid; place-items: center; border-radius: 50%; background: #ff3d6e; border: 2px solid #fff; font-size: 12px; font-weight: 900; animation: tbeat 1s ease-in-out infinite; }

/* 옷장 */
.wardrobe { margin-top: 18px; padding: 14px 12px 12px; border-radius: 24px; background: #fff; border: 1.5px solid #f6e3f2; box-shadow: 0 8px 22px rgba(169, 139, 255, .12); scroll-margin-top: 8px; }
.wd-head h2 { margin: 0; font-family: var(--cute, sans-serif); font-weight: 400; font-size: 21px; }
.wd-head span { font-size: 12.5px; color: #8a7ca3; }
.wd-tabs { display: grid; grid-template-columns: repeat(6, 1fr); gap: 4px; margin: 10px 0; padding: 4px; border-radius: 16px; background: #fbf6ff; }
.wd-tabs button { display: flex; flex-direction: column; align-items: center; padding: 6px 0 5px; border: 0; border-radius: 12px; background: none; font: inherit; font-size: 11.5px; font-weight: 800; color: #8a7ca3; cursor: pointer; }
.wd-tabs button i { font-style: normal; font-size: 18px; }
.wd-tabs button.on { background: linear-gradient(135deg, #ff7eb6, #9a7bff); color: #fff; }
.wd-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.wt { position: relative; display: flex; flex-direction: column; align-items: center; padding: 18px 4px 7px; border-radius: 16px; font: inherit; cursor: pointer;
  background: linear-gradient(180deg, #fff, var(--rbg, #fbf8ff)); border: 2px solid var(--r1, #eee6f6); transition: transform .12s; }
.wt:active { transform: scale(.95); }
.wt .wt-rar { position: absolute; top: 5px; left: 6px; font-size: 9px; padding: 0 5px; }
.wt-art { display: grid; place-items: center; width: 100%; height: 62px; font-size: 26px; }
.wt-art svg { width: 100%; height: 100%; }
.wt b { margin-top: 3px; font-size: 11.5px; line-height: 1.25; text-align: center; word-break: keep-all; color: #3b2b55; }
.wt em { margin-top: 2px; font-style: normal; font-size: 11px; font-weight: 900; color: #ff8a1f; }
.wt.owned em { color: #1fb89a; }
.wt.locked { filter: grayscale(.6); opacity: .7; }
.wt.locked em { color: #8a7ca3; }
.wt.on { box-shadow: 0 0 0 3px #ff7eb6; transform: translateY(-2px); }
.wt.wearing::after { content: "착용"; position: absolute; top: 4px; right: 5px; font-size: 9.5px; font-weight: 900; color: #fff; background: #ff4f98; border-radius: 99px; padding: 0 6px; }
.wt.got { animation: lvPop .5s cubic-bezier(.2, 1.8, .4, 1); }
.wt.none { --r1: #eee6f6; --rbg: #fbf8ff; }
.wd-bar { position: sticky; bottom: calc(82px + env(safe-area-inset-bottom)); z-index: 6; display: flex; align-items: center; gap: 8px; margin-top: 12px; padding: 10px 10px 10px 14px;
  border-radius: 20px; background: #3b2b55; color: #fff; box-shadow: 0 10px 26px rgba(59, 43, 85, .35); animation: bubblePop .3s ease; }
.wb-info { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.wb-info b { font-size: 15px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; } .wb-info small { font-size: 11.5px; opacity: .8; }
.wb-cancel { border: 0; background: rgba(255, 255, 255, .14); color: #fff; font: inherit; font-size: 13px; padding: 10px 12px; border-radius: 14px; cursor: pointer; }
.wb-buy { border: 0; font: inherit; font-family: var(--cute, sans-serif); font-size: 15px; padding: 10px 14px; border-radius: 14px; cursor: pointer; color: #3b2b55; background: linear-gradient(135deg, #ffe36e, #ffb020); white-space: nowrap; }
.wb-buy:disabled { background: #6b5a85; color: #c9bde0; }

.room-stats .rs-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; }
.rs-grid div { padding: 12px 4px; border-radius: 16px; background: #fff; border: 1.5px solid #f6e3f2; text-align: center; }
.rs-grid b { display: block; font-family: var(--cute, sans-serif); font-weight: 400; font-size: 21px; color: #7b5cf5; }
.rs-grid b small { font-size: 12px; color: #b9a3d6; }
.rs-grid span { font-size: 11.5px; color: #8a7ca3; }
.sp-change { display: block; width: 100%; margin-top: 12px; padding: 12px; border: 1.5px dashed #e3d8f5; border-radius: 16px; background: none; font: inherit; font-size: 14px; color: #6b4a8a; cursor: pointer; }
.sp-change small { display: block; font-size: 11.5px; color: #8a7ca3; }
.sp-list { display: grid; grid-template-columns: repeat(4, 1fr); gap: 6px; margin-top: 10px; }
.sp-item { display: flex; flex-direction: column; align-items: center; padding: 6px 2px; border: 2px solid #f3e4f1; border-radius: 16px; background: #fff; font: inherit; cursor: pointer; }
.sp-item svg { width: 62px; height: 62px; } .sp-item b { font-size: 12.5px; }

/* ---------- 상점 ---------- */
.shop-hero { position: relative; overflow: hidden; padding: 22px 20px 18px; border-radius: 26px; color: #fff;
  background: radial-gradient(70% 60% at 90% 10%, rgba(255, 255, 255, .4), transparent 60%), linear-gradient(135deg, #ffb020 0%, #ff6fae 55%, #9a7bff 100%); box-shadow: 0 14px 30px rgba(255, 111, 174, .35); }
.sh-eyebrow { margin: 0; font-family: var(--cute, sans-serif); letter-spacing: .2em; font-size: 13px; opacity: .9; }
.shop-hero h1 { margin: 4px 0 6px; font-family: var(--cute, sans-serif); font-weight: 400; font-size: 28px; text-shadow: 0 2px 0 rgba(123, 92, 245, .35); }
.shop-hero h1 em { font-style: normal; background: linear-gradient(transparent 58%, rgba(255, 227, 110, .85) 58%); padding: 0 2px; }
.shop-hero p { margin: 0 0 12px; font-size: 13.5px; max-width: 62%; word-break: keep-all; }
.sh-point { display: inline-flex; align-items: center; gap: 6px; padding: 7px 14px 7px 9px; border-radius: 99px; background: rgba(59, 43, 85, .35); font-size: 14px; }
.sh-point b { font-family: var(--cute, sans-serif); font-weight: 400; font-size: 20px; }
.sh-pet { position: absolute; right: -6px; bottom: -14px; width: 150px; height: 150px; }
.sh-pet svg { width: 100%; height: 100%; }
.pu-list { display: grid; gap: 10px; }
.pu-card { display: grid; grid-template-columns: auto 1fr; gap: 4px 12px; align-items: center; padding: 14px; border-radius: 22px; background: #fff; border: 1.5px solid #f6e3f2; box-shadow: 0 6px 18px rgba(169, 139, 255, .1); }
.pu-art { position: relative; grid-row: span 2; text-align: center; }
.pu-art svg { width: 62px; height: 62px; filter: drop-shadow(0 6px 8px rgba(59, 43, 85, .15)); }
.pu-own { display: block; margin-top: 2px; font-size: 11px; color: #8a7ca3; } .pu-own b { color: #7b5cf5; font-size: 13px; }
.pu-txt h3 { margin: 0; font-family: var(--cute, sans-serif); font-weight: 400; font-size: 19px; }
.pu-txt p { margin: 1px 0 2px; font-size: 13.5px; font-weight: 700; color: #5b4a75; }
.pu-txt small { font-size: 11.5px; color: #8a7ca3; word-break: keep-all; }
.pu-buy { display: flex; gap: 6px; }
.pb { flex: 1; display: flex; align-items: center; justify-content: center; gap: 6px; padding: 9px 6px; border: 0; border-radius: 14px; font: inherit; cursor: pointer; }
.pb span { font-size: 12.5px; font-weight: 700; } .pb b { font-family: var(--cute, sans-serif); font-weight: 400; font-size: 16px; }
.pb s { font-size: 11px; opacity: .6; }
.pb.one { background: #f4effc; color: #5b4a75; box-shadow: 0 3px 0 #e1d6f2; }
.pb.pack { background: linear-gradient(135deg, #ff7eb6, #9a7bff); color: #fff; box-shadow: 0 3px 0 #6a4be0; }
.pb:active { transform: translateY(2px); box-shadow: none; }
.pb:disabled { opacity: .6; }
.pu-card.bought { animation: boostIn .6s ease; }
.howto { margin-top: 16px; padding: 14px 16px; border-radius: 20px; background: #fff8fc; border: 1.5px dashed #f4c6e0; }
.howto h3 { margin: 0 0 6px; font-size: 15px; }
.howto ol { margin: 0; padding-left: 18px; font-size: 13px; line-height: 1.65; color: #5b4a75; word-break: keep-all; }
.pick3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.p3 { position: relative; display: flex; flex-direction: column; align-items: center; padding: 4px 4px 8px; border-radius: 18px; text-decoration: none;
  background: linear-gradient(180deg, #fff, var(--rbg)); border: 2px solid var(--r1); }
.p3-art { width: 100%; aspect-ratio: 1; } .p3-art svg { width: 100%; height: 100%; }
.p3 .wt-rar { position: absolute; top: 6px; left: 6px; font-size: 9px; }
.p3 b { font-size: 12px; text-align: center; word-break: keep-all; } .p3 em { font-style: normal; font-size: 11.5px; font-weight: 900; color: #ff8a1f; }
.shop-note { margin: 16px 2px 0; font-size: 12px; text-align: center; }

/* ---------- 칭호 · 도감 ---------- */
.col-tabs { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; padding: 5px; margin-bottom: 12px; border-radius: 18px; background: #fff; border: 1.5px solid #f6e3f2; }
.col-tabs a { padding: 11px 4px; border-radius: 13px; text-align: center; text-decoration: none; font-weight: 800; font-size: 14.5px; color: #8a7ca3; }
.col-tabs a b { font-size: 12px; opacity: .8; }
.col-tabs a.on { color: #fff; background: linear-gradient(135deg, #ff7eb6, #9a7bff); }
.col-lead { margin: 0 2px 10px; font-size: 13px; color: #8a7ca3; }
.ttl-list { display: grid; gap: 8px; }
.ttl { display: flex; align-items: center; gap: 10px; padding: 11px 12px; border-radius: 18px; background: #fff; border: 1.5px solid #f1eaf7; }
.ttl.got { background: linear-gradient(90deg, var(--rbg), #fff); border-color: var(--r1); }
.ttl.on { box-shadow: 0 0 0 3px #ff7eb6; }
.ttl-emo { flex: none; display: grid; place-items: center; width: 44px; height: 44px; border-radius: 14px; background: #f6f1fc; font-size: 24px; }
.ttl.got .ttl-emo { background: #fff; box-shadow: 0 3px 8px rgba(59, 43, 85, .1); }
.ttl-txt { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.ttl-txt b { font-size: 15px; } .ttl-txt b .wt-rar { vertical-align: 2px; margin-left: 2px; }
.ttl-txt > small { font-size: 12px; color: #8a7ca3; word-break: keep-all; }
.ttl:not(.got) .ttl-txt b { color: #8a7ca3; }
.ttl-bar { display: block; height: 7px; margin-top: 5px; border-radius: 99px; background: #f1eaf7; overflow: hidden; }
.ttl-bar i { display: block; height: 100%; border-radius: 99px; background: linear-gradient(90deg, var(--r1), var(--r2)); }
.ttl-txt em { font-style: normal; font-size: 11px; color: #8a7ca3; margin-top: 2px; }
.ttl-eq { flex: none; padding: 8px 12px; border: 0; border-radius: 12px; font: inherit; font-size: 13px; font-weight: 800; cursor: pointer; color: #fff; background: linear-gradient(135deg, var(--r1), var(--r2)); }
.ttl.on .ttl-eq { background: #3b2b55; }
.card-prog { margin-bottom: 12px; }
.cp-bar { height: 12px; border-radius: 99px; background: #fff; border: 1.5px solid #f1e2f1; overflow: hidden; }
.cp-bar i { display: block; height: 100%; background: linear-gradient(90deg, #ffd86b, #ff6fae, #9a7bff); border-radius: 99px; }
.card-prog p { margin: 6px 2px 0; font-size: 12.5px; color: #8a7ca3; word-break: keep-all; } .card-prog b { color: #ff8a1f; }
.card-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 7px; }
.cg { padding: 0; border: 0; background: none; font: inherit; cursor: pointer; }
.cg .fcard .fc-emo { font-size: 28px; } .cg .fcard b { font-size: 10.5px; } .cg .fcard small { font-size: 9px; }
.cg.lock { cursor: default; }
.rates { margin-top: 16px; padding: 14px; border-radius: 18px; background: #fff; border: 1.5px solid #f6e3f2; }
.rates h3 { margin: 0 0 8px; font-size: 15px; }
.rates table { font-size: 13px; } .rates th, .rates td { white-space: normal; padding: 7px 6px; }
.rates p { margin: 8px 0 0; font-size: 12px; color: #8a7ca3; word-break: keep-all; }

/* ---------- 홈: 내 캐릭터 카드 ---------- */
.home-pet { position: relative; display: grid; grid-template-columns: 112px 1fr; align-items: center; gap: 10px; margin-top: 16px; padding: 8px 14px 8px 6px;
  border-radius: 24px; text-decoration: none; background: linear-gradient(135deg, #fff, #fff4fa); border: 1.5px solid #f6e3f2; box-shadow: 0 8px 22px rgba(169, 139, 255, .14); overflow: hidden; }
.home-pet .hp-art { width: 112px; height: 112px; } .home-pet .hp-art svg { width: 100%; height: 100%; }
.hp-txt { min-width: 0; }
.hp-txt .hp-top { display: flex; align-items: center; gap: 6px; }
.hp-txt .hp-lv { font-family: var(--cute, sans-serif); font-size: 14px; color: #fff; background: linear-gradient(135deg, #ff7eb6, #9a7bff); padding: 1px 9px; border-radius: 99px; }
.hp-txt b { font-family: var(--cute, sans-serif); font-weight: 400; font-size: 19px; color: #3b2b55; }
.hp-txt p { margin: 2px 0 6px; font-size: 12.5px; color: #8a7ca3; word-break: keep-all; }
.hp-txt .exp-bar { height: 16px; margin: 0; } .hp-txt .exp-bar span { font-size: 10.5px; line-height: 12px; }
.hp-go { display: inline-block; margin-top: 6px; font-size: 12px; font-weight: 800; color: #ff4f98; }
.home-pet.egg .hp-art { display: grid; place-items: center; font-size: 60px; } .home-pet.egg .hp-art span { animation: eggWob 2s ease-in-out infinite; }
.hp-lineup { display: flex; margin: 4px 0 0 -4px; } .hp-lineup svg { width: 40px; height: 40px; margin-right: -8px; }

/* 랭킹 아바타 */
.rank-list .av { flex: none; width: 38px; height: 38px; border-radius: 50%; background: linear-gradient(150deg, #fff0f7, #f1ebff); overflow: hidden; display: grid; place-items: center; }
.rank-list .av svg { width: 38px; height: 38px; }
.rank-list .nm .title-badge { margin-left: 4px; font-size: 10.5px; padding: 1px 7px 1px 5px; }
.hall .hl .av { width: 48px; height: 48px; margin: 0 auto 2px; border-radius: 50%; background: #fff6fb; overflow: hidden; }
.hall .hl .av svg { width: 48px; height: 48px; }

@media (max-width: 360px) {
  .room-actions { gap: 5px; } .ra b { font-size: 11px; }
  .card-grid { grid-template-columns: repeat(3, 1fr); }
  .pk-card .pk-art { width: 110px; height: 110px; }
}

/* 꾸미기 모드: 캐릭터를 작게 위에 고정하고 옷장만 보여줘요 */
.room.dressing .room-stage { position: sticky; top: 6px; z-index: 7; width: 54%; margin: 0 auto; border-radius: 24px; }
.room.dressing .room-hud .hud-name, .room.dressing .pat-hint { display: none; }
.room.dressing .room-bubble { font-size: 12px; padding: 6px 10px; bottom: 70%; }
.room.dressing .lv-badge { width: 40px; height: 40px; border-radius: 13px; } .room.dressing .lv-badge b { font-size: 17px; }
.room.dressing .room-info, .room.dressing .room-actions { display: none; }
.room.dressing ~ .room-stats { display: none; }
.room.dressing .wardrobe { margin-top: 12px; }
.wd-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.wd-done { flex: none; padding: 9px 16px; border: 0; border-radius: 14px; font: inherit; font-weight: 800; color: #fff; cursor: pointer; background: linear-gradient(135deg, #ff7eb6, #9a7bff); box-shadow: 0 3px 0 #6a4be0; }
body.dressing-on .snd-toggle { display: none; }
.home-pet .hp-txt, .home-pet .hp-txt .exp-bar, .home-pet .hp-go { display: block; }
.home-pet .hp-txt .hp-top { display: flex; }
.home-pet .hp-txt .exp-bar i { display: block; }
.buddy svg.pet { width: 96px; height: 96px; }
