/* 포포 FurFor — 웹 프로토타입
   톤: '따뜻한 오후의 거실' · Soft Toon */
:root {
  --cream: #fff6ea;
  --paper: #fffdf8;
  --ink: #4a3428;
  --ink-soft: #8a7262;
  --line: #ecdcc8;
  --peach: #f4a98a;
  --peach-deep: #e58a68;
  --sage: #9fbf9a;
  --butter: #f6d58a;
  --lav: #b9b3e0;
  --night: #2b2850;
  --star: #f5c96a;
  --radius: 18px;
  --shadow: 0 6px 20px rgba(110, 76, 50, .12);
  --font: -apple-system, BlinkMacSystemFont, "Apple SD Gothic Neo", "Pretendard", "Noto Sans KR", "Malgun Gothic", sans-serif;
  --hand: "Nanum Pen Script", "Gaegu", "Apple SD Gothic Neo", cursive;
}
* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
html, body { margin: 0; height: 100%; }
body {
  font-family: var(--font);
  color: var(--ink);
  background: radial-gradient(1200px 600px at 20% 0%, #ffe9d4, transparent), linear-gradient(#f6ead9, #efe0cc);
  display: flex; justify-content: center; align-items: center;
  -webkit-font-smoothing: antialiased;
}
button { font: inherit; color: inherit; cursor: pointer; border: 0; background: none; }
input, textarea, select { font: inherit; color: inherit; }
h1, h2, h3, p { margin: 0; }

#phone {
  position: relative;
  width: 100%; max-width: 430px;
  height: 100dvh; max-height: 920px;
  background: var(--cream);
  overflow: hidden;
  box-shadow: 0 20px 60px rgba(90, 60, 40, .25);
}
@media (min-width: 500px) { #phone { border-radius: 36px; height: min(920px, 96dvh); } }
#app { height: 100%; display: flex; flex-direction: column; }

/* ---------- 공통 ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  min-height: 48px; padding: 0 20px; border-radius: 999px;
  background: var(--peach); color: #fff; font-weight: 700; font-size: 16px;
  box-shadow: 0 4px 0 var(--peach-deep); white-space: nowrap;
  transition: transform .1s, box-shadow .1s, opacity .2s;
}
.btn:active { transform: translateY(3px); box-shadow: 0 1px 0 var(--peach-deep); }
.btn[disabled] { opacity: .45; pointer-events: none; }
.btn.block { width: 100%; }
.btn.ghost { background: transparent; color: var(--ink-soft); box-shadow: none; font-weight: 600; }
.btn.soft { background: #fff; color: var(--ink); box-shadow: 0 3px 0 var(--line); border: 1.5px solid var(--line); }
.btn.night { background: #5a548f; box-shadow: 0 4px 0 #3e3a6c; }
.btn.sm { min-height: 38px; padding: 0 14px; font-size: 14px; }
.chip {
  display: inline-flex; align-items: center; gap: 4px;
  padding: 8px 13px; border-radius: 999px; font-size: 14px; font-weight: 600;
  background: #fff; border: 1.5px solid var(--line);
  transition: background .15s, border-color .15s;
}
.chip.on { background: #ffe6da; border-color: var(--peach); color: #b25a3b; }
.chip[disabled] { opacity: .4; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
/* 아이콘 세트 (assets/icons) */
.icon { display: inline-block; width: 24px; height: 24px; object-fit: contain; vertical-align: middle; flex: none; user-select: none; -webkit-user-drag: none; }
.icon.xs { width: 16px; height: 16px; }
.icon.sm { width: 20px; height: 20px; }
.icon.md { width: 30px; height: 30px; }
.icon.lg { width: 38px; height: 38px; }
.icon.xl { width: 64px; height: 64px; }
.icon.dim { filter: grayscale(.6) opacity(.6); }
.card { background: var(--paper); border-radius: var(--radius); box-shadow: var(--shadow); padding: 16px; }
.muted { color: var(--ink-soft); }
.small { font-size: 13px; }
.label { font-size: 14px; font-weight: 700; margin: 18px 0 8px; display: block; }
.field {
  width: 100%; padding: 13px 14px; border-radius: 14px; border: 1.5px solid var(--line);
  background: #fff; font-size: 16px; outline: none;
}
.field:focus { border-color: var(--peach); }
textarea.field { resize: none; line-height: 1.6; }
.row { display: flex; align-items: center; gap: 10px; }
.between { justify-content: space-between; }
.stack > * + * { margin-top: 12px; }
.lock { font-size: 12px; color: var(--ink-soft); }
.badge { font-size: 11px; font-weight: 700; padding: 3px 8px; border-radius: 999px; background: #f1e6d8; color: var(--ink-soft); }
.badge.plus { background: #efe9ff; color: #6a5fb3; }
.dot { width: 8px; height: 8px; border-radius: 50%; background: var(--peach-deep); display: inline-block; }

/* ---------- 탭/뷰 ---------- */
.view { flex: 1; overflow-y: auto; overflow-x: hidden; padding-bottom: 24px; scrollbar-width: none; }
.view::-webkit-scrollbar { display: none; }
.view-pad { padding: 18px 18px 0; }
.page-title { font-size: 24px; font-weight: 800; letter-spacing: -.02em; }
.page-sub { font-size: 14px; color: var(--ink-soft); margin-top: 4px; }

.tabbar {
  display: grid; grid-template-columns: repeat(5, 1fr);
  background: var(--paper); border-top: 1px solid var(--line);
  padding: 6px 4px calc(6px + env(safe-area-inset-bottom));
}
.tab { display: flex; flex-direction: column; align-items: center; gap: 3px; padding: 6px 0; font-size: 11px; font-weight: 600; color: #b8a594; position: relative; }
.tab .icon { width: 28px; height: 28px; filter: grayscale(1) opacity(.45); transition: filter .2s, transform .2s; }
.tab.on .icon { filter: none; transform: translateY(-1px) scale(1.06); }
.tab.on { color: var(--peach-deep); }
.tab .dot { position: absolute; top: 4px; right: 26%; }

/* ---------- 토스트 / 시트 ---------- */
#toast {
  position: absolute; left: 50%; bottom: 96px; transform: translate(-50%, 20px);
  background: rgba(74, 52, 40, .92); color: #fff; padding: 11px 18px; border-radius: 999px;
  font-size: 14px; opacity: 0; pointer-events: none; transition: .3s; white-space: nowrap; z-index: 90;
}
#toast.show { opacity: 1; transform: translate(-50%, 0); }
.backdrop {
  position: absolute; inset: 0; background: rgba(60, 40, 28, .38); z-index: 50;
  display: flex; align-items: flex-end; animation: fadein .2s;
}
.sheet {
  width: 100%; max-height: 92%; overflow-y: auto; background: var(--cream);
  border-radius: 26px 26px 0 0; padding: 10px 20px 28px; animation: slideup .28s cubic-bezier(.2, .9, .3, 1);
}
.sheet .grip { width: 40px; height: 5px; border-radius: 9px; background: var(--line); margin: 0 auto 14px; }
.sheet h2 { font-size: 20px; font-weight: 800; }
.full {
  position: absolute; inset: 0; z-index: 40; display: flex; flex-direction: column;
  background: var(--cream); animation: fadein .3s;
}
@keyframes fadein { from { opacity: 0 } }
@keyframes slideup { from { transform: translateY(100%) } }

/* ---------- 온보딩 ---------- */
.onb { flex: 1; display: flex; flex-direction: column; padding: 18px 22px 22px; overflow-y: auto; }
.onb-top { display: flex; justify-content: space-between; align-items: center; min-height: 36px; }
.progress { display: flex; gap: 5px; }
.progress i { width: 22px; height: 5px; border-radius: 9px; background: var(--line); }
.progress i.on { background: var(--peach); }
.onb h1 { font-size: 25px; line-height: 1.4; font-weight: 800; margin-top: 18px; letter-spacing: -.02em; }
.onb .lead { color: var(--ink-soft); margin-top: 8px; line-height: 1.6; font-size: 15px; }
.onb-foot { margin-top: auto; padding-top: 20px; display: grid; gap: 6px; }
.splash { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; padding: 30px; background: radial-gradient(circle at 50% 40%, #fff1e2, var(--cream)); }
.logo { font-size: 44px; font-weight: 900; letter-spacing: -.04em; color: var(--peach-deep); }
.logo small { display: block; font-size: 14px; font-weight: 600; color: var(--ink-soft); letter-spacing: .2em; margin-top: 4px; }
.species { display: grid; gap: 12px; margin-top: 24px; }
.species button {
  display: flex; align-items: center; gap: 14px; padding: 12px 16px; border-radius: 20px;
  background: #fff; border: 2px solid var(--line); text-align: left; transition: .15s;
}
.species button.on { border-color: var(--peach); background: #fff3ec; }
.species .mini { width: 74px; height: 74px; flex: none; }
.species b { font-size: 18px; }
.preview-stage {
  position: relative; margin-top: 14px; border-radius: 22px; height: 230px;
  background: radial-gradient(circle at 50% 70%, #ffe7d2, #fff6ea 70%);
  display: flex; align-items: center; justify-content: center; gap: 10px;
}
.preview-stage .pv { width: 190px; height: 190px; }
.preview-stage .photo-cmp { width: 120px; height: 150px; border-radius: 14px; object-fit: cover; border: 4px solid #fff; box-shadow: var(--shadow); transform: rotate(-3deg); }
.swatches { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.swatch { width: 34px; height: 34px; border-radius: 50%; border: 3px solid #fff; box-shadow: 0 0 0 1.5px var(--line); }
.swatch.on { box-shadow: 0 0 0 3px var(--peach); }
.swatch-input { width: 34px; height: 34px; border: 0; padding: 0; background: none; border-radius: 50%; overflow: hidden; cursor: pointer; }
.swatch-input::-webkit-color-swatch-wrapper { padding: 0; }
.swatch-input::-webkit-color-swatch { border: 3px solid #fff; border-radius: 50%; box-shadow: 0 0 0 1.5px var(--line); }
.swatch-input::-moz-color-swatch { border: 3px solid #fff; border-radius: 50%; }
.range { width: 100%; accent-color: var(--peach); }
.reunion { flex: 1; position: relative; display: flex; align-items: center; justify-content: center; background: radial-gradient(circle at 50% 55%, #fff4dc 0, #f6dfc2 40%, #3d3355 100%); overflow: hidden; }
.reunion .light { position: absolute; width: 8px; height: 8px; border-radius: 50%; background: #fff7d6; box-shadow: 0 0 14px 4px #ffe9a8; animation: gather 2.6s ease-in forwards; }
.reunion .pet-in { width: 220px; opacity: 0; animation: appear 1.6s 2.4s ease-out forwards; }
.reunion .msg { position: absolute; bottom: 18%; left: 0; right: 0; text-align: center; color: #5a3f30; font-size: 20px; font-weight: 700; opacity: 0; animation: fadeup 1s 4.2s forwards; padding: 0 24px; line-height: 1.5; }
.reunion .skip { position: absolute; top: 18px; right: 18px; color: #fff; opacity: .8; z-index: 2; }
@keyframes gather { to { transform: translate(var(--tx), var(--ty)) scale(.4); opacity: 0; } }
@keyframes appear { 0% { opacity: 0; transform: scale(.4); filter: brightness(3) blur(6px); } 60% { opacity: 1; transform: scale(1.08); filter: brightness(1.4); } 100% { opacity: 1; transform: scale(1); filter: none; } }
@keyframes fadeup { from { opacity: 0; transform: translateY(10px) } to { opacity: 1 } }

/* ---------- 펫 SVG 애니메이션 ---------- */
.pet-svg { width: 100%; height: 100%; overflow: visible; display: block; }
.pet-img { width: 100%; height: 100%; object-fit: contain; object-position: 50% 100%; display: block; pointer-events: none; user-select: none; -webkit-user-drag: none; }
.pet-img.flip { transform: scaleX(-1); }
.sp-dog.a-wag .pet-body, .sp-cat.a-wag .pet-body, .sp-hamster.a-wag .pet-body { animation: wiggle .32s ease-in-out 5; }
.dog-views { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; margin-top: 10px; }
.dog-views > div { height: 76px; background: #fff; border-radius: 14px; border: 1.5px solid var(--line); padding: 6px; }
.pet-svg .tail { transform-box: fill-box; transform-origin: 0% 100%; animation: wag 1.6s ease-in-out infinite; }
.pet-svg .eyes { transform-box: fill-box; transform-origin: center; animation: blink 5.5s infinite; }
@keyframes wag { 0%, 100% { transform: rotate(-8deg) } 50% { transform: rotate(10deg) } }
@keyframes blink { 0%, 93%, 100% { transform: scaleY(1) } 96% { transform: scaleY(.1) } }
.a-wag .pet-svg .tail { animation-duration: .28s; }
.pet-body { width: 100%; height: 100%; transform-origin: 50% 90%; }
.a-bob .pet-body { animation: bob .42s ease-in-out infinite; }
.a-jump .pet-body { animation: jump .55s ease-out 2; }
.a-spin .pet-body { animation: spin .9s ease-in-out 2; }
.a-roll .pet-body { animation: roll 3s ease-in-out; }
.a-wiggle .pet-body { animation: wiggle .5s ease-in-out 4; }
.a-loaf .pet-body { animation: loaf 3.5s ease-in-out; }
.a-eat .pet-body { animation: eat .5s ease-in-out infinite; }
.a-puff .pet-body { animation: puff 1s ease-in-out 3; }
.a-sleep .pet-body { animation: breathe 3.2s ease-in-out infinite; }
.a-stretch .pet-body { animation: stretch 2.4s ease-in-out; }
@keyframes bob { 50% { transform: translateY(-6px) } }
@keyframes jump { 40% { transform: translateY(-34px) scale(1.02, .98) } 80% { transform: translateY(0) scale(1.06, .92) } }
@keyframes spin { 50% { transform: rotate(180deg) translateY(-8px) } 100% { transform: rotate(360deg) } }
@keyframes roll { 20%, 80% { transform: rotate(170deg) translateY(30px) } }
@keyframes wiggle { 25% { transform: rotate(-6deg) } 75% { transform: rotate(6deg) } }
@keyframes loaf { 20%, 80% { transform: scale(1.12, .82) } }
@keyframes eat { 50% { transform: translateY(8px) rotate(3deg) } }
@keyframes puff { 50% { transform: scale(1.1, 1.05) } }
@keyframes breathe { 50% { transform: scale(1.03, .97) } }
@keyframes stretch { 30%, 60% { transform: scale(1.18, .8) translateY(6px) } }

/* ---------- 내 집 ---------- */
.topbar { display: flex; justify-content: space-between; align-items: flex-start; padding: 14px 18px 10px; }
.pet-title { font-size: 22px; font-weight: 800; letter-spacing: -.02em; }
.topbar .sub { font-size: 12.5px; color: var(--ink-soft); margin-top: 3px; }
.topbar .chips { gap: 6px; justify-content: flex-end; }
.topbar .chip { padding: 6px 11px; font-size: 13px; }
.anniv { margin: 0 18px 10px; padding: 12px 14px; border-radius: 16px; background: linear-gradient(90deg, #ffe7d6, #fff3dc); font-size: 14px; font-weight: 600; display: flex; gap: 10px; align-items: center; }
.anniv.soft { background: linear-gradient(90deg, #ece9fb, #f6f2ff); color: #5c548f; }

@keyframes rain { to { background-position: -8px 40px } }
/* 거실: 아이소메트릭 일러스트 (assets/living-room.webp, 1376×768)
   방 부분(가로 853px)만 잘라 보이도록 배경을 161.3%로 확대한다. 좌표는 잘린 영역 기준 %. */
/* 메인 홈: 거실이 화면을 채우고, 위에 펫 카드·별조각, 아래에 둥근 행동 버튼 */
.view.home-view { padding-bottom: 0; overflow: hidden; }
.home2 { height: 100%; display: flex; flex-direction: column; background: #d5d4ab; }
.home-stage { position: relative; flex: 1; min-height: 0; overflow: hidden; }
.room { position: absolute; top: 0; left: 50%; height: 100%; aspect-ratio: 853 / 768; transform: translateX(-50%); overflow: hidden; user-select: none; -webkit-user-select: none; touch-action: pan-y; background: #d5d4ab; }
.home-hud { position: absolute; top: 14px; left: 14px; right: 14px; display: flex; justify-content: space-between; align-items: flex-start; z-index: 10; pointer-events: none; }
.hud-card { pointer-events: auto; display: flex; align-items: center; gap: 10px; background: rgba(255, 250, 241, .88); border-radius: 26px; box-shadow: 0 6px 18px rgba(110, 80, 50, .14); backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px); text-align: left; }
.pet-card { padding: 8px 18px 8px 8px; }
.hud-avatar { width: 56px; height: 56px; border-radius: 50%; background: radial-gradient(circle at 50% 60%, #fff3e3, #f3e2cc); display: flex; align-items: flex-end; justify-content: center; overflow: hidden; flex: none; box-shadow: inset 0 0 0 2px rgba(255,255,255,.8); }
.hud-avatar .pet-head { width: 100%; height: 100%; -webkit-mask-image: none; mask-image: none; background-size: 120% auto; background-position: 50% 6%; }
.hud-avatar.lg { width: 64px; height: 64px; }
.hud-txt { display: flex; flex-direction: column; line-height: 1.25; }
.hud-txt b { font-size: 20px; font-weight: 800; color: #3e2e24; }
.hud-heart { color: #e5546a; font-size: 17px; }
.hud-txt small { font-size: 13.5px; font-weight: 700; color: #5a4636; margin-top: 2px; }
.star-card { padding: 12px 18px; gap: 8px; }
.hud-star { color: #f5c04a; font-size: 26px; line-height: 1; text-shadow: 0 1px 0 #d99a2b, 0 0 8px rgba(255, 210, 100, .6); }
.star-card b { font-size: 21px; font-weight: 800; color: #3e2e24; }
.hud-sub { position: absolute; top: 92px; left: 14px; right: 14px; display: flex; gap: 6px; flex-wrap: wrap; z-index: 10; pointer-events: none; }
.hud-pill { pointer-events: auto; display: inline-flex; align-items: center; gap: 5px; padding: 5px 11px; border-radius: 99px; font-size: 12.5px; font-weight: 700; color: #5a4636; background: rgba(255, 250, 241, .78); box-shadow: 0 3px 10px rgba(110, 80, 50, .1); }
.hud-pill.rainbow { background: rgba(246, 240, 255, .9); color: #5c4a6e; }
.hud-hint { position: absolute; left: 0; right: 0; bottom: 10px; text-align: center; font-size: 12.5px; font-weight: 700; color: #5a4636; z-index: 10; opacity: 0; transition: opacity .3s; pointer-events: none; }
.hud-hint.show { opacity: 1; text-shadow: 0 1px 6px rgba(255, 245, 230, .95); }
.home-actions { flex: none; margin: -46px 12px 12px; position: relative; z-index: 11; padding: 14px 6px 12px; border-radius: 30px; background: rgba(250, 245, 230, .9); box-shadow: 0 8px 24px rgba(110, 90, 50, .16); backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px); }
.home-actions.napping { padding: 14px; }
.act-row { display: grid; grid-auto-flow: column; grid-auto-columns: 20%; overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none; }
.act-row::-webkit-scrollbar { display: none; }
.act2 { scroll-snap-align: start; display: flex; flex-direction: column; align-items: center; gap: 6px; font-size: 14px; font-weight: 800; color: #3e2e24; white-space: nowrap; }
.act2-ic { width: 60px; height: 60px; border-radius: 50%; background: #fffaf2; box-shadow: 0 4px 10px rgba(110, 80, 50, .12), inset 0 0 0 1px rgba(214, 196, 170, .35); display: flex; align-items: center; justify-content: center; transition: transform .12s; }
.act2-ic .icon { width: 36px; height: 36px; }
.act2:active .act2-ic { transform: scale(.93); }
.act2.on .act2-ic { box-shadow: 0 0 0 3px var(--peach); }
/* 더 있는 버튼 힌트: 가장자리 흐림 + 작은 화살표 (끝에 닿으면 뒤로 가는 화살표) */
.home-actions .act-row { -webkit-mask-image: linear-gradient(90deg, #000 88%, transparent); mask-image: linear-gradient(90deg, #000 88%, transparent); }
.home-actions.at-end .act-row { -webkit-mask-image: linear-gradient(90deg, transparent, #000 12%); mask-image: linear-gradient(90deg, transparent, #000 12%); }
.home-actions:not(.at-start):not(.at-end) .act-row { -webkit-mask-image: linear-gradient(90deg, transparent, #000 10%, #000 90%, transparent); mask-image: linear-gradient(90deg, transparent, #000 10%, #000 90%, transparent); }
.act-more { position: absolute; right: -6px; top: 34px; width: 28px; height: 28px; border-radius: 50%; background: #fffaf2; color: #b0775a; box-shadow: 0 3px 10px rgba(110, 80, 50, .2); display: flex; align-items: center; justify-content: center; z-index: 2; animation: nudge 2.4s ease-in-out 1s 3; }
.act-more svg { width: 16px; height: 16px; transition: transform .25s; }
.home-actions.at-end .act-more { right: auto; left: -6px; animation: none; }
.home-actions.at-end .act-more svg { transform: rotate(180deg); }
.home-actions.napping .act-more { display: none; }
@keyframes nudge { 0%, 70%, 100% { translate: 0 0; } 80% { translate: 4px 0; } 90% { translate: 0 0; } }
@media (max-width: 370px) { .act2-ic { width: 52px; height: 52px; } .act2 { font-size: 12.5px; } }
.room-bg { position: absolute; inset: 0; background: url(assets/living-room.webp) 50% 50% / 161.3% auto no-repeat; transition: filter 1.5s; }
.tod-dawn .room-bg { filter: brightness(.9) saturate(.9) hue-rotate(-6deg); }
.tod-sunset .room-bg { filter: sepia(.18) saturate(1.1) brightness(.95); }
.tod-night .room-bg { filter: brightness(.6) saturate(.8) sepia(.25) hue-rotate(-12deg); }
.room.calm .room-bg { filter: brightness(.8) saturate(.7); }
.tod-night.calm .room-bg { filter: brightness(.55) saturate(.6) sepia(.2); }
/* 창문 위에 겹치는 효과 레이어 (왼쪽 벽 기울기에 맞춤) */
.win-fx { position: absolute; left: 16.8%; top: 25.8%; width: 21.7%; height: 14.5%; transform: skewY(-27deg); overflow: hidden; pointer-events: none; transition: background 2s; }
.tod-night .win-fx { background: rgba(35, 32, 80, .55); }
.tod-sunset .win-fx { background: rgba(255, 150, 90, .25); }
.win-fx .rain { position: absolute; inset: 0; opacity: 0; background: repeating-linear-gradient(105deg, transparent 0 7px, rgba(255,255,255,.7) 7px 8px); background-size: 30px 30px; animation: rain .5s linear infinite; transition: opacity 1s; }
.room.calm .win-fx { background: rgba(120, 135, 160, .45); }
.room.calm .rain { opacity: 1; }
/* 오른쪽 벽의 작은 액자 2개 자리에 내 사진을 건다 */
.wf { position: absolute; width: 7.5%; transform: translate(-50%, -50%) skewY(27deg); cursor: pointer; z-index: 2; }
.wf.a { left: 54.3%; top: 19.5%; }
.wf.b { left: 76.6%; top: 34.9%; }
.wall-frame-empty { width: 100%; aspect-ratio: 3 / 4; border: 2px dashed rgba(185, 140, 100, .8); border-radius: 4px; background: rgba(255, 246, 234, .75); display: flex; align-items: center; justify-content: center; color: #b07f58; font-weight: 800; font-size: 15px; }
.room.nap::after { content: ""; position: absolute; inset: 0; background: rgba(30, 24, 50, .55); transition: .8s; pointer-events: none; }
.rug { position: absolute; left: 62%; width: 20%; bottom: 13%; height: 7%; border-radius: 50%; background: radial-gradient(#f3c9b8 0 40%, #eab4a0 41% 60%, #f3c9b8 61%); opacity: .9; transform: translateX(-50%); }
.decor { position: absolute; font-size: 26px; line-height: 1; pointer-events: none; filter: drop-shadow(0 3px 2px rgba(0,0,0,.15)); }
.bowl { position: absolute; left: 22%; bottom: 25%; width: 36px; height: 16px; border-radius: 0 0 18px 18px; background: #8fb4d9; box-shadow: inset 0 -4px 0 #7298c0; transform: translateX(-50%); z-index: 3; }
.bowl.full::before, .bowl.water::before { content: ""; position: absolute; left: 5px; right: 5px; top: -5px; height: 8px; border-radius: 8px 8px 0 0; background: #c9874f; }
.bowl.water::before { background: #a9d4f2; height: 6px; top: -3px; border-radius: 6px; }
.lamp-glow { position: absolute; left: 10%; top: 30%; width: 60%; height: 60%; background: radial-gradient(rgba(255, 210, 140, .4), transparent 70%); opacity: 0; transition: 2s; pointer-events: none; }
.tod-night .lamp-glow { opacity: 1; }

.pet-actor { position: absolute; bottom: 28%; width: 84px; height: 84px; transform: translateX(-50%); transition: left 1.8s ease-in-out, bottom 1.8s ease-in-out; z-index: 5; cursor: grab; touch-action: none; }
.pet-actor.fast { transition-duration: .7s; }
.bubble {
  position: absolute; bottom: 100%; left: 50%; transform: translate(-50%, 6px) scale(.9);
  background: #fff; padding: 8px 12px; border-radius: 16px; font-size: 13px; font-weight: 600; white-space: nowrap;
  box-shadow: 0 4px 12px rgba(0,0,0,.1); opacity: 0; transition: .25s; pointer-events: none; max-width: 240px;
}
.bubble::after { content: ""; position: absolute; left: 50%; bottom: -6px; margin-left: -6px; border: 6px solid transparent; border-top-color: #fff; border-bottom: 0; }
.bubble.show { opacity: 1; transform: translate(-50%, 0) scale(1); }
.fx { position: absolute; inset: 0; pointer-events: none; z-index: 8; }
.particle { position: absolute; font-size: 18px; animation: floatup 1.4s ease-out forwards; }
@keyframes floatup { from { opacity: 1; transform: translate(-50%, 0) scale(.6) } to { opacity: 0; transform: translate(calc(-50% + var(--dx, 0px)), -70px) scale(1.2) } }
.zzz { position: absolute; font-weight: 800; color: #8a82c9; font-size: 16px; animation: zzz 2.4s ease-out infinite; }
@keyframes zzz { from { opacity: 0; transform: translate(0, 0) } 30% { opacity: 1 } to { opacity: 0; transform: translate(18px, -40px) scale(1.4) } }
.ball { position: absolute; width: 22px; height: 22px; border-radius: 50%; background: radial-gradient(circle at 35% 35%, #fff 0 10%, #ef6f6f 11%); bottom: 8%; z-index: 4; transition: left .9s cubic-bezier(.3, .8, .4, 1), bottom .9s; }

.stats { display: grid; grid-template-columns: repeat(3, 1fr) auto; gap: 10px; align-items: center; margin: 14px 18px 0; padding: 12px 14px; }
.stat { font-size: 12px; font-weight: 700; color: var(--ink-soft); }
.stat .bar { height: 8px; border-radius: 9px; background: #f1e5d6; margin-top: 5px; overflow: hidden; }
.stat .bar i { display: block; height: 100%; border-radius: 9px; transition: width .6s; }
.bond { text-align: center; padding-left: 6px; border-left: 1px solid var(--line); }
.bond b { display: block; font-size: 17px; color: var(--peach-deep); }
.bond .bar { width: 54px; }
.actions { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; margin: 12px 18px 0; }
.act {
  display: flex; flex-direction: column; align-items: center; gap: 4px; padding: 12px 2px 10px;
  border-radius: 18px; background: var(--paper); box-shadow: var(--shadow); font-size: 12.5px; font-weight: 700;
  transition: transform .12s;
}
.act:active { transform: scale(.95); }
.act .act-ic { width: 32px; height: 32px; }
.act.on { background: #ffe9dd; box-shadow: 0 0 0 2px var(--peach); }
.hint { margin: 12px 18px 0; font-size: 12.5px; color: var(--ink-soft); text-align: center; }
.moods { display: grid; grid-template-columns: repeat(5, 1fr); gap: 8px; margin-top: 16px; }
.moods button { padding: 14px 0 10px; border-radius: 18px; background: #fff; border: 2px solid var(--line); display: flex; flex-direction: column; align-items: center; gap: 6px; font-size: 12px; font-weight: 700; }
.moods button.on { border-color: var(--peach); background: #fff3ec; }

.shop-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; margin-top: 14px; }
.shop-item { background: #fff; border-radius: 16px; padding: 12px 6px; text-align: center; border: 1.5px solid var(--line); font-size: 13px; font-weight: 700; }
.shop-item .ic { font-size: 30px; display: block; margin-bottom: 4px; }
.shop-item.owned { border-color: var(--sage); background: #f2f8ef; }

/* ---------- 액자 ---------- */
.photo { display: block; width: 100%; height: 100%; object-fit: cover; }
.frame { position: relative; container-type: inline-size; }
.fb { position: relative; box-sizing: border-box; width: 100%; filter: drop-shadow(0 4px 5px rgba(90, 60, 40, .16)); }
.fb-slice { border-style: solid; }
.fb-stretch { background: 0 0 / 100% 100% no-repeat; }
.frame .inner { width: 100%; overflow: hidden; background: #eee3d6; }
.frame .inner.oval { border-radius: 50%; }
.fr-polaroid .cap { position: absolute; left: 0; right: 0; bottom: calc(-1 * var(--pb)); height: var(--pb); display: flex; align-items: center; justify-content: center; font-family: "Gaegu", var(--hand); font-size: clamp(9px, 9cqw, 22px); color: #5a463a; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; padding: 0 8%; }
.f-warm { filter: sepia(.28) saturate(1.12) brightness(1.03); }
.f-bright { filter: brightness(1.13) contrast(1.02); }
.f-soft { filter: contrast(.9) brightness(1.06) saturate(.88); }

.slots { display: grid; grid-template-columns: repeat(2, 1fr); gap: 16px; padding: 16px 18px 0; }
.slot { border-radius: 20px; background: var(--paper); box-shadow: var(--shadow); padding: 14px; text-align: left; display: flex; flex-direction: column; gap: 10px; min-height: 196px; }
.slot .holder { flex: 1; display: flex; align-items: center; justify-content: center; }
.slot .holder .frame { width: 78%; }
.slot .t { font-size: 13.5px; font-weight: 700; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.slot.empty { border: 2px dashed var(--line); background: transparent; box-shadow: none; align-items: center; justify-content: center; color: var(--ink-soft); font-weight: 600; font-size: 14px; }
.slot.empty b { font-size: 30px; color: #d8bfa4; }
.gal-actions { display: flex; gap: 8px; padding: 14px 18px 0; }
.gal-actions .btn { flex: 1; }
.editor-preview { margin-top: 10px; border-radius: 20px; background: #f6e8d8; padding: 22px; display: flex; justify-content: center; min-height: 220px; align-items: center; }
.editor-preview .frame { width: 62%; }
.upload-box { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 6px; width: 100%; height: 180px; border-radius: 18px; border: 2px dashed #e2c7aa; color: var(--ink-soft); font-weight: 600; font-size: 14px; cursor: pointer; background: #fffaf3; }
.upload-box input { display: none; }
.frame-types { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; }
.frame-types button { padding: 8px 2px; border-radius: 14px; background: #fff; border: 2px solid var(--line); font-size: 11.5px; font-weight: 700; display: flex; flex-direction: column; align-items: center; gap: 6px; }
.frame-types button.on { border-color: var(--peach); }
.frame-types .sw { width: 40px; height: 40px; object-fit: contain; }
.frame-types .lock { font-size: 10px; font-weight: 600; }

.memory-room { background: linear-gradient(#f3dcc2 0 64%, #c99a6e 64%); }
.memory-room .mr-top { display: flex; justify-content: space-between; align-items: center; padding: 16px 18px; }
.walls { flex: 1; display: flex; overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none; }
.walls::-webkit-scrollbar { display: none; }
.wallp { flex: none; width: 100%; scroll-snap-align: center; padding: 6px 26px; display: grid; grid-template-columns: 1fr 1fr; gap: 22px 26px; align-content: start; position: relative; }
.wallp .nm { position: absolute; top: -2px; left: 26px; font-size: 12px; color: #a8805e; font-weight: 700; }
.wallp .frame { margin-top: 18px; cursor: pointer; transition: transform .2s; }
.wallp .frame:active { transform: scale(.97); }
.wallp .sz-S { width: 70%; justify-self: center; }
.wallp .sz-M { width: 88%; justify-self: center; }
.wallp .sz-L { width: 100%; }
.mr-bottom { position: relative; height: 200px; flex: none; }
.sofa { position: absolute; left: 10%; bottom: 26px; width: 58%; height: 88px; }
.sofa::before { content: ""; position: absolute; inset: 0 0 30px 0; background: #b7c9a8; border-radius: 26px 26px 8px 8px; }
.sofa::after { content: ""; position: absolute; left: -6%; right: -6%; bottom: 0; height: 48px; background: #a2b893; border-radius: 22px; }
.mr-pet { position: absolute; right: 8%; bottom: 20px; width: 120px; height: 120px; }
.mr-dots { display: flex; justify-content: center; gap: 6px; padding: 6px 0 12px; }
.mr-dots i { width: 7px; height: 7px; border-radius: 50%; background: rgba(120,80,50,.25); }
.mr-dots i.on { background: var(--peach-deep); }

.viewer { background: rgba(28, 20, 16, .94); color: #fff; align-items: stretch; z-index: 60; }
.viewer .vtop { display: flex; justify-content: space-between; padding: 16px 18px; align-items: center; }
.viewer .vimg { flex: 1; display: flex; align-items: center; justify-content: center; padding: 0 18px; overflow: hidden; }
.viewer .vimg img { max-width: 100%; max-height: 100%; border-radius: 6px; touch-action: pinch-zoom; }
.viewer .vcap { padding: 18px 22px 30px; line-height: 1.7; }
.viewer .vcap h3 { font-size: 19px; }
.viewer .vcap .d { font-size: 13px; opacity: .65; margin: 2px 0 8px; }
.viewer .vcap p { font-size: 15px; opacity: .9; white-space: pre-wrap; }
.slideshow .vimg img { animation: kenburns 6.2s ease-out both; }
@keyframes kenburns { from { transform: scale(1.12); opacity: 0 } 15% { opacity: 1 } to { transform: scale(1) } }
.slideshow .vcap { animation: fadeup 1.2s .8s both; }
.ss-progress { display: flex; gap: 4px; padding: 0 18px; }
.ss-progress i { flex: 1; height: 3px; border-radius: 3px; background: rgba(255,255,255,.25); overflow: hidden; }
.ss-progress i.done { background: rgba(255,255,255,.85); }
.ss-progress i.now::after { content: ""; display: block; height: 100%; background: #fff; animation: prog 6s linear forwards; }
@keyframes prog { from { width: 0 } to { width: 100% } }

/* ---------- 편지함 ---------- */
.letter-list { padding: 14px 18px 0; display: grid; gap: 12px; }
.letter-item { text-align: left; display: flex; gap: 12px; align-items: flex-start; }
.letter-item .env { line-height: 0; margin-top: 2px; }
.letter-item .pv { font-size: 14px; line-height: 1.5; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.letter-item .st { font-size: 12.5px; margin-top: 6px; color: var(--ink-soft); display: flex; align-items: center; gap: 6px; }
.paper { background: #fffdf6; background-image: repeating-linear-gradient(transparent 0 31px, #f1e4d2 31px 32px); border-radius: 18px; padding: 20px 20px 24px; line-height: 32px; background-position: 0 21px; box-shadow: var(--shadow); white-space: pre-wrap; font-size: 15.5px; }
.paper.reply { background-color: #fbf8ff; background-image: repeating-linear-gradient(transparent 0 31px, #e8e2f6 31px 32px); }
.paper .sign { text-align: right; font-weight: 700; margin-top: 6px; }
/* 편지 쓰기 화면 */
.letter-write { background: linear-gradient(rgba(214, 218, 178, .62), rgba(208, 213, 170, .78)), url(assets/living-room.webp) 50% 30% / 230% auto no-repeat, #d3d7ad; }
.lw-top { display: flex; align-items: center; gap: 10px; padding: 18px 16px 6px; flex: none; }
.lw-back { width: 46px; height: 46px; flex: none; border-radius: 14px; background: rgba(255, 248, 236, .9); color: var(--ink); display: flex; align-items: center; justify-content: center; box-shadow: 0 3px 10px rgba(110, 90, 50, .15); }
.lw-back svg { width: 22px; height: 22px; }
.lw-titles { flex: 1; text-align: center; min-width: 0; }
.lw-sub { font-size: 15px; font-weight: 700; color: #5a4636; }
.lw-titles h1 { font-size: 23px; font-weight: 900; letter-spacing: -.03em; color: #3e2e24; margin-top: 2px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pet-head { display: inline-block; flex: none; background-repeat: no-repeat; background-size: 128% auto; background-position: 50% 0%; -webkit-mask-image: radial-gradient(ellipse 55% 52% at 50% 46%, #000 75%, transparent 100%); mask-image: radial-gradient(ellipse 55% 52% at 50% 46%, #000 75%, transparent 100%); }
.lw-head-corner { width: 58px; height: 54px; }
.lw-scroll { flex: 1; overflow-y: auto; padding: 8px 18px 10px; scrollbar-width: none; }
.lw-scroll::-webkit-scrollbar { display: none; }
.lw-prompt { margin: 4px 22px 0; padding: 14px 16px 10px; border-radius: 20px; background: rgba(255, 249, 238, .82); box-shadow: 0 4px 14px rgba(110, 90, 50, .12); text-align: center; backdrop-filter: blur(4px); -webkit-backdrop-filter: blur(4px); }
.lw-prompt p { font-size: 15px; font-weight: 700; line-height: 1.55; color: #3e2e24; min-height: 46px; display: flex; align-items: center; justify-content: center; }
.lw-qrow { display: flex; justify-content: center; gap: 14px; margin-top: 6px; }
.lw-qrow button { font-size: 12px; font-weight: 700; color: #b0775a; }
.lw-paper { position: relative; margin: 22px 0 0; padding: 70px 30px 46px; min-height: 440px; background-color: #fffbf1; background-image: linear-gradient(rgba(214, 196, 170, .28) 1px, transparent 1px), linear-gradient(90deg, rgba(214, 196, 170, .22) 1px, transparent 1px); background-size: 26px 40px, 26px 40px; background-position: 0 70px, 13px 0; border-radius: 50% 50% 44% 44% / 30% 30% 22% 22%; box-shadow: 0 10px 30px rgba(110, 90, 50, .18), inset 0 0 0 1px rgba(214, 196, 170, .4); }
.lw-paper-top { position: absolute; top: 4px; left: 0; right: 0; display: flex; justify-content: center; align-items: center; gap: 18px; }
.lw-head-center { width: 76px; height: 70px; }
.lw-head-peek { position: absolute; left: -12px; top: 18px; width: 70px; height: 64px; transform: rotate(-12deg); }
.lw-paw { width: 30px; height: 30px; opacity: .85; }
.lw-paw.flip { transform: scaleX(-1); }
.lw-text { display: block; width: 100%; min-height: 300px; border: 0; background: transparent; resize: none; outline: none; font-family: "Gaegu", var(--hand), var(--font); font-size: 23px; line-height: 40px; color: #3e2e24; padding: 0 6px; position: relative; z-index: 1; }
.lw-text::placeholder { color: #b9a58f; }
.lw-deco { position: absolute; inset: 0; pointer-events: none; }
.lw-deco .deco-flower { position: absolute; width: 26px; height: 26px; }
.lw-deco .f1 { left: 20px; bottom: 74px; }
.lw-deco .f2 { left: 50px; bottom: 50px; width: 18px; height: 18px; }
.lw-deco .deco-star, .lw-send .deco-star { position: absolute; width: 18px; height: 18px; }
.lw-deco .s1 { left: 24px; bottom: 120px; }
.lw-deco .s2 { right: 26px; bottom: 132px; }
.lw-deco .lw-paw { position: absolute; width: 22px; height: 22px; opacity: .7; }
.lw-deco .p1 { right: 22px; bottom: 96px; transform: rotate(18deg); }
.lw-deco .p2 { right: 40px; bottom: 62px; transform: rotate(-10deg); }
.lw-count { position: absolute; right: 44px; bottom: 22px; font-size: 14px; color: #9a8676; font-weight: 600; }
.lw-note { text-align: center; font-size: 12px; color: #6f6550; margin-top: 12px; }
.lw-send { position: relative; flex: none; padding: 14px 0 20px; display: flex; justify-content: center; }
.lw-send-btn { position: relative; z-index: 1; display: inline-flex; align-items: center; gap: 10px; padding: 0 44px; height: 64px; border-radius: 999px; font-size: 21px; font-weight: 800; color: #fff; background: linear-gradient(#f4ab8c, #e98d6c); box-shadow: 0 6px 0 #d4775a, 0 10px 24px rgba(200, 110, 80, .35); transition: transform .1s, box-shadow .1s; }
.lw-send-btn:active { transform: translateY(4px); box-shadow: 0 2px 0 #d4775a; }
.lw-send-btn .btn-star { position: static; width: 30px; height: 30px; filter: drop-shadow(0 0 6px rgba(255, 220, 120, .8)); }
.lw-cloud { position: absolute; width: 46px; height: 18px; border-radius: 20px; background: #fffdf8; box-shadow: 10px -8px 0 2px #fffdf8, 22px 0 0 0 #fffdf8; opacity: .95; }
.lw-cloud.c1 { left: 50%; margin-left: 20px; top: 2px; transform: scale(.7); }
.lw-cloud.c2 { right: 14%; bottom: 10px; }
.lw-spark { position: absolute; color: #fff7d0; text-shadow: 0 0 6px #fff1a8; font-size: 14px; animation: twinkle 2.4s ease-in-out infinite; }
.lw-spark.k1 { left: 20%; top: 4px; } .lw-spark.k2 { right: 12%; top: 10px; animation-delay: .8s; } .lw-spark.k3 { left: 10%; bottom: 14px; animation-delay: 1.4s; }
.lw-heart { position: absolute; color: #f2a7a0; font-size: 18px; }
.lw-heart.h1 { right: 14%; top: 0; } .lw-heart.h2 { right: 6%; bottom: 30px; color: #f08b9b; font-size: 14px; }
.lw-send .s3 { left: 9%; top: 30px; }
.send-anim { position: absolute; inset: 0; z-index: 70; display: flex; align-items: center; justify-content: center; background: linear-gradient(#2b2850, #5a4f86 70%, #f1b89a); color: #fff; flex-direction: column; overflow: hidden; }
.send-anim .mailbox { line-height: 0; }
.send-anim .mailbox .icon { width: 84px; height: 84px; }
.send-anim .starlet { position: absolute; left: 50%; top: 52%; width: 10px; height: 10px; margin-left: -5px; border-radius: 50%; background: #fff6c8; box-shadow: 0 0 20px 8px #ffe48a; animation: rise 3s 1s ease-in forwards; opacity: 0; }
.send-anim p { position: absolute; bottom: 16%; font-size: 17px; font-weight: 600; opacity: 0; animation: fadeup 1s 2.2s forwards; text-align: center; padding: 0 30px; line-height: 1.6; }
@keyframes rise { 0% { opacity: 1; transform: translateY(0) } 100% { opacity: 0; transform: translateY(-360px) scale(.4) } }
.help { background: #fffaf3; }
.help .num { font-size: 22px; font-weight: 800; color: var(--peach-deep); }
.help-item { display: flex; justify-content: space-between; align-items: center; padding: 14px 0; border-bottom: 1px solid var(--line); }
.anniv-cards { display: flex; gap: 10px; overflow-x: auto; padding: 14px 18px 2px; scrollbar-width: none; }
.anniv-card { flex: none; width: 150px; padding: 14px; border-radius: 18px; background: linear-gradient(160deg, #fff, #fff1e4); box-shadow: var(--shadow); }
.anniv-card .k { font-size: 12px; color: var(--ink-soft); font-weight: 700; }
.anniv-card .d { font-size: 20px; font-weight: 800; margin-top: 6px; }
.anniv-card .s { font-size: 12px; color: var(--ink-soft); margin-top: 2px; }

/* ---------- 월드 ---------- */
.places { display: grid; gap: 12px; padding: 16px 18px 0; }
.place { display: flex; gap: 14px; align-items: center; text-align: left; padding: 14px; border-radius: 20px; background: var(--paper); box-shadow: var(--shadow); }
.place .thumb { width: 64px; height: 64px; border-radius: 16px; flex: none; display: flex; align-items: center; justify-content: center; }
.place .thumb-ic { width: 42px; height: 42px; }
.place h3 { font-size: 16px; }
.place p { font-size: 13px; color: var(--ink-soft); margin-top: 3px; line-height: 1.4; }
.place.locked { opacity: .55; }
.walk { overflow: hidden; }
.walk .sky { position: absolute; inset: 0 0 30% 0; }
.walk .ground { position: absolute; inset: 70% 0 0 0; }
.layer { position: absolute; left: 0; display: flex; white-space: nowrap; animation: scroll linear infinite; }
.layer span { display: inline-block; }
@keyframes scroll { from { transform: translateX(0) } to { transform: translateX(-50%) } }
.walk .walker { position: absolute; left: 50%; bottom: 22%; width: 140px; height: 140px; transform: translateX(-50%); }
.walk .walker.a-jump .pet-body { animation: jump .55s ease-out 2; }
.walk-top { position: relative; z-index: 3; display: flex; justify-content: space-between; align-items: center; padding: 16px 18px; }
.pickup { position: absolute; font-size: 26px; z-index: 4; cursor: pointer; animation: twinkle 1.2s ease-in-out infinite; filter: drop-shadow(0 0 6px #ffe48a); }
@keyframes twinkle { 50% { transform: scale(1.2) rotate(15deg) } }
.butterfly { position: absolute; font-size: 22px; z-index: 3; animation: flutter 7s linear forwards; }
@keyframes flutter { from { transform: translate(0, 0) } 25% { transform: translate(-25vw, -30px) } 50% { transform: translate(-50vw, 10px) } 75% { transform: translate(-75vw, -20px) } to { transform: translate(-110vw, 0) } }
.walk-art { position: absolute; inset: 0; background: center / cover no-repeat; }
.petals { position: absolute; inset: 0; pointer-events: none; overflow: hidden; z-index: 2; }
.petals i { position: absolute; top: -20px; width: 10px; height: 8px; border-radius: 80% 10% 80% 10%; background: linear-gradient(135deg, #ffd9e2, #f6a9bd); opacity: .9; animation: petal linear infinite; }
.petals.leaf i { width: 14px; height: 12px; border-radius: 0 80% 0 80%; background: linear-gradient(135deg, #f6b24a, #d9542c); opacity: .95; }
.petals.leaf i:nth-child(3n) { background: linear-gradient(135deg, #f4d35e, #e09a2a); }
.petals.leaf i:nth-child(4n) { background: linear-gradient(135deg, #e0703a, #a8321e); }
.petals.rain i { width: 1.5px; height: 18px; border-radius: 2px; background: linear-gradient(transparent, rgba(235, 245, 255, .9)); animation-name: raindrop; animation-timing-function: linear; }
@keyframes raindrop { from { translate: 0 -30px; } to { translate: -24px 110vh; } }
.petals.snow i { width: 7px; height: 7px; border-radius: 50%; background: radial-gradient(#fff 40%, rgba(255,255,255,.4)); box-shadow: 0 0 4px rgba(255,255,255,.8); }
.petals.snow i:nth-child(2n) { width: 4px; height: 4px; }
@keyframes petal { from { translate: 0 0; rotate: 0deg; } to { translate: var(--drift) 110vh; rotate: var(--rot); } }
.walk-foot { position: absolute; left: 0; right: 0; bottom: 0; z-index: 5; padding: 16px 18px 26px; }

.plaza { background: linear-gradient(#4a4466, #2a2645 40%, #1f1c3a); color: #f6f1ff; }
.plaza-scene { position: relative; flex: none; height: 50%; min-height: 300px; }
.plaza-scroll { position: absolute; inset: 0; overflow-x: auto; overflow-y: hidden; scrollbar-width: none; cursor: grab; touch-action: pan-x; }
.plaza-scroll::-webkit-scrollbar { display: none; }
.plaza-art { position: relative; height: 100%; aspect-ratio: 1376 / 768; background: url(assets/plaza.webp) center / cover no-repeat; }
.plaza-scene::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 60px; background: linear-gradient(transparent, #4a4466); pointer-events: none; }
.plaza-top { position: absolute; left: 0; right: 0; top: 0; z-index: 3; pointer-events: none; }
.plaza-top > * { pointer-events: auto; }
.plaza-chip { background: rgba(30, 26, 60, .55); border-color: rgba(255,255,255,.18); color: #fff; backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px); }
.plaza-hint { position: absolute; left: 50%; bottom: 18px; transform: translateX(-50%); z-index: 3; font-size: 12px; font-weight: 600; padding: 6px 12px; border-radius: 99px; background: rgba(30, 26, 60, .6); color: #fff; white-space: nowrap; pointer-events: none; transition: opacity .6s; }
.plaza-hint.gone { opacity: 0; }
.plaza-spot { position: absolute; transform: translate(-50%, -50%); font-size: 11px; font-weight: 700; color: #fff; padding: 5px 10px; border-radius: 99px; background: rgba(30, 26, 60, .55); border: 1px solid rgba(245, 201, 106, .5); }
.plaza-mine { position: absolute; left: 59%; top: 79%; transform: translate(-50%, -100%); display: flex; align-items: flex-end; gap: 4px; padding-top: 26px; }
.plaza-tag { position: absolute; top: 0; left: 50%; transform: translateX(-50%); font-size: 11px; font-weight: 800; color: #3a2a1a; background: #ffe7b0; padding: 3px 9px; border-radius: 99px; white-space: nowrap; box-shadow: 0 0 14px rgba(255, 200, 110, .8); }
.mini-candle { width: 10px; height: 20px; border-radius: 3px; background: linear-gradient(#fff9ef, #e8dccb); position: relative; }
.mini-candle.sm { height: 14px; }
.mini-candle::before { content: ""; position: absolute; left: 50%; top: -12px; width: 8px; height: 12px; margin-left: -4px; border-radius: 50% 50% 50% 50% / 60% 60% 40% 40%; background: radial-gradient(circle at 50% 70%, #fff6c8, #ffb94a 60%, transparent 75%); box-shadow: 0 0 16px 6px rgba(255, 190, 90, .55); animation: flicker 1.4s ease-in-out infinite; }
.plaza-cons { position: absolute; left: 27%; top: 14%; width: 18%; text-align: center; font-size: 11px; font-weight: 700; color: #ffe7b0; text-shadow: 0 0 8px rgba(255, 220, 150, .8); }
.plaza-cons svg { width: 100%; display: block; }
.plaza-body { position: relative; flex: 1; overflow-y: auto; padding: 4px 18px 24px; }
.candles { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; margin-top: 16px; }
.candle { background: linear-gradient(rgba(255, 214, 150, .1), rgba(255,255,255,.04)); border: 1px solid rgba(255, 220, 170, .16); border-radius: 18px; padding: 14px 6px 10px; text-align: center; color: inherit; }
.candle.mine { border-color: rgba(245, 201, 106, .6); background: rgba(245, 201, 106, .1); }
.candle .wax { width: 16px; height: 30px; margin: 16px auto 8px; background: linear-gradient(#fff9ef, #e8dccb); border-radius: 4px; position: relative; }
.candle .wax::before { content: ""; position: absolute; left: 50%; top: -18px; width: 10px; height: 16px; margin-left: -5px; border-radius: 50% 50% 50% 50% / 60% 60% 40% 40%; background: radial-gradient(circle at 50% 70%, #fff6c8, #ffb94a 60%, rgba(255,120,40,.0) 75%); box-shadow: 0 0 18px 6px rgba(255, 190, 90, .45); animation: flicker 1.4s ease-in-out infinite; }
@keyframes flicker { 50% { transform: scale(.92, 1.08) rotate(2deg); opacity: .9 } }
.candle b { display: block; font-size: 14px; }
.candle span { font-size: 11px; opacity: .7; }
.candle .rc { font-size: 11px; margin-top: 6px; opacity: .85; }
.hill { background: linear-gradient(#c3b5de 0%, #cbbbe0 35%, #9aa86e 62%, #7e905f 100%); }
.hill-art { position: absolute; background: url(assets/rainbow-hill.webp) 0 0 / 100% 100% no-repeat; -webkit-mask-image: linear-gradient(transparent, #000 9%, #000 90%, transparent); mask-image: linear-gradient(transparent, #000 9%, #000 90%, transparent); }
.hill-text { position: absolute; top: 12%; left: 0; right: 0; padding: 0 24px; text-align: center; color: #5e4434; font-weight: 700; line-height: 1.7; text-shadow: 0 1px 8px rgba(255, 240, 225, .9); z-index: 2; }
.hill-pet { position: absolute; transform: translateX(-50%); z-index: 2; }
.hill-sparkles { position: absolute; inset: 0; pointer-events: none; }
.hill-sparkles i { position: absolute; width: 4px; height: 4px; border-radius: 50%; background: #fff8dc; box-shadow: 0 0 8px 2px rgba(255, 244, 200, .9); animation: tw 3s ease-in-out infinite; }
@keyframes tw { 50% { opacity: .15 } }
.place .thumb-img { background-size: 260% auto; background-position: 22% 38%; }
.anniv.rainbow { background: linear-gradient(90deg, rgba(246, 240, 255, .9), rgba(255, 240, 230, .55)), url(assets/rainbow-hill.webp) 30% 35% / 220% auto; color: #5c4a6e; }
.anniv-card.rainbow { background: linear-gradient(rgba(255, 252, 248, .78), rgba(255, 246, 238, .9)), url(assets/rainbow-hill.webp) 25% 30% / 320% auto; }

/* ---------- 마이 ---------- */
.profile { display: flex; gap: 14px; align-items: center; margin: 16px 18px 0; }
.profile .av { width: 86px; height: 86px; flex: none; border-radius: 26px; background: radial-gradient(circle at 50% 70%, #ffe7d2, #fff6ea); }
.menu { margin: 14px 18px 0; padding: 4px 16px; }
.menu-item { display: flex; justify-content: space-between; align-items: center; padding: 15px 0; width: 100%; text-align: left; font-size: 15px; font-weight: 600; border-bottom: 1px solid #f3e7d9; }
.menu-item:last-child { border-bottom: 0; }
.menu-item .r { color: var(--ink-soft); font-size: 13px; font-weight: 500; }
.menu h3 { font-size: 13px; color: var(--ink-soft); padding: 14px 0 0; }
.switch { position: relative; width: 46px; height: 28px; flex: none; }
.switch input { opacity: 0; width: 0; height: 0; }
.switch span { position: absolute; inset: 0; border-radius: 99px; background: #e5d7c7; transition: .2s; }
.switch span::after { content: ""; position: absolute; left: 3px; top: 3px; width: 22px; height: 22px; border-radius: 50%; background: #fff; transition: .2s; box-shadow: 0 1px 3px rgba(0,0,0,.2); }
.switch input:checked + span { background: var(--peach); }
.switch input:checked + span::after { transform: translateX(18px); }
.seg { display: inline-flex; background: #f1e6d8; border-radius: 99px; padding: 3px; }
.seg button { padding: 5px 10px; border-radius: 99px; font-size: 12.5px; font-weight: 600; color: var(--ink-soft); }
.seg button.on { background: #fff; color: var(--ink); box-shadow: 0 1px 3px rgba(0,0,0,.1); }
.ritual { background: radial-gradient(circle at 50% 30%, #4d4685, #1d1a38 70%); color: #fff; align-items: center; justify-content: center; text-align: center; padding: 30px; }
.ritual .rpet { width: 180px; height: 180px; animation: ascend 5s 1s ease-in forwards; }
@keyframes ascend { 60% { opacity: .8; transform: translateY(-120px) scale(.6); filter: brightness(2) blur(1px) } 100% { opacity: 0; transform: translateY(-200px) scale(.2); filter: brightness(3) blur(4px) } }
.ritual .cons { opacity: 0; animation: fadeup 1.5s 5s forwards; }
.ritual p { line-height: 1.7; }
.foot-note { text-align: center; font-size: 12px; color: var(--ink-soft); padding: 22px 30px 4px; line-height: 1.6; }

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