@font-face{font-family:Nunito;src:url(media/Nunito.ttf) format("truetype");font-style:normal;font-weight:400 900;font-display:swap}
:root{
  color-scheme:light;
  --ink:#3f352d;
  --muted:#786a59;
  --paper:#f7f2e7;
  --green:#526a4b;
  --sage:#dce5ce;
  --clay:#aa5b3f;
  --line:#dfd6c6;
  --ease:cubic-bezier(.23,1,.32,1);
}
*{box-sizing:border-box}
[hidden]{display:none!important}
html{background:var(--paper);height:100%;-webkit-tap-highlight-color:transparent}
body{margin:0;color:var(--ink);font:600 15px/1.45 Nunito,ui-rounded,system-ui,sans-serif}
button,input{font:inherit}
button{cursor:pointer;touch-action:manipulation}
button{color:inherit}
button:disabled{cursor:default;opacity:.55}
button:focus-visible,input:focus-visible{outline:3px solid var(--clay);outline-offset:3px}
button svg{pointer-events:none}
button{transition:background-color .15s var(--ease)}
svg{width:24px;height:24px;display:block;flex-shrink:0}
::selection{background:var(--sage);color:var(--ink)}
html,body{width:100%;height:100%;overflow:hidden;overscroll-behavior:none}
.app,main,.play-area{width:100%;height:100dvh;position:relative}
.topbar{position:absolute;inset:max(16px,env(safe-area-inset-top)) max(20px,env(safe-area-inset-right)) auto max(20px,env(safe-area-inset-left));z-index:30;display:flex;align-items:center;justify-content:space-between;gap:12px;pointer-events:none}
.identity{display:flex;align-items:center;gap:12px;padding:9px 15px 9px 9px;background:#fff9ecee;border-radius:22px}
.paw-mark{display:grid;place-items:center;background:#e7cba7;color:#754c32;width:42px;height:42px;border-radius:50%}
.paw-mark svg{width:26px;height:26px}
h1{font-weight:900;letter-spacing:-.035em;font-size:25px;margin:0}
.identity p{margin:0;color:var(--muted);font-size:12px}
.top-actions{display:flex;gap:8px;pointer-events:auto}
.icon-button{border:0;background:transparent;width:44px;height:44px;border-radius:50%;padding:10px;display:grid;place-items:center}
.icon-button:hover{background:#e9e0d2}
.top-actions .icon-button{background:#fff9ecee;box-shadow:0 3px 12px #68472c12}
.room{position:absolute;inset:0;isolation:isolate;overflow:hidden;background:#e9dec9 url(media/room.png) center 53%/cover no-repeat}
.scene-top{position:absolute;top:max(99px,calc(env(safe-area-inset-top) + 85px));right:max(22px,env(safe-area-inset-right));left:max(22px,env(safe-area-inset-left));display:flex;justify-content:flex-end;gap:8px;z-index:22;pointer-events:none}
.room-menu-button{pointer-events:auto;position:relative;display:flex;align-items:center;gap:8px;padding:10px 14px;min-height:46px;border:0;background:#fffaedee;border-radius:16px;box-shadow:0 3px 13px #68472c13;font-size:13px;font-weight:900}
.room-menu-button>span>svg{width:21px;height:21px;color:#716044}
.wallet{display:flex;align-items:center;gap:4px;margin-left:4px;font-weight:800;color:#89603a}
.wallet svg{width:18px;height:18px}
#discovery-dot{position:absolute;width:10px;height:10px;border-radius:50%;right:1px;top:1px;background:#b25b3e;outline:3px solid #fff8e9}
.cat-wrap{position:absolute;width:min(86vw,66dvh,660px);aspect-ratio:1;left:50%;bottom:calc(170px + env(safe-area-inset-bottom));margin-left:calc(min(86vw,66dvh,660px) / -2);transform-origin:50% 84%;pointer-events:none;z-index:5}
#cat{position:absolute;inset:18% 19% 3%;border:0;padding:0;background:transparent;pointer-events:auto;cursor:grab;touch-action:manipulation}
.cat-art{display:block;position:absolute;inset:0;background-image:url(media/lucik.png);background-size:300% 200%;background-position:0 0;background-repeat:no-repeat;pointer-events:none;transform-origin:50% 84%}
#cat:active{cursor:grabbing}
.cat-wrap.breathing{animation:breathe 3.2s ease-in-out infinite}
.cat-wrap.reacting{animation:happy .65s var(--ease) both}
@keyframes breathe{0%,100%{transform:translateY(0) scale(1)}50%{transform:translateY(-2px) scale(1.008,1.015)}}
@keyframes happy{0%{transform:translateY(0)}35%{transform:translateY(-10px) rotate(-2deg)}70%{transform:translateY(-2px) rotate(1deg)}100%{transform:translateY(0)}}
.speech{position:absolute;top:24%;left:50%;transform:translateX(-50%);background:#fffaf0f5;max-width:min(83%,440px);width:max-content;border-radius:18px 18px 18px 3px;padding:10px 15px;box-shadow:0 5px 18px #6b4b2313;font-size:14px;text-align:center;z-index:18;pointer-events:none}
.prop-art{display:block;width:100%;height:100%;background:url(media/objects.png) 0 0/400% 300% no-repeat;pointer-events:none}
.art-food{background-position:0 0}
.food-bowl.empty .art-food{background-position:33.333333% 0}
.art-water{background-position:66.666667% 0}
.water-bowl.empty .art-water{background-position:100% 0}
.art-tray{background-position:0 50%}
.art-tray.dirty{background-position:33.333333% 50%}
.art-blanket{background-position:66.666667% 50%}
.art-plant{background-position:100% 50%}
.art-bed{background-position:0 100%}
.art-rug{background-position:33.333333% 100%}
.art-cushion{background-position:66.666667% 100%}
.art-lights{background-position:100% 100%}
.scene-item{position:absolute;bottom:calc(160px + env(safe-area-inset-bottom));width:clamp(95px,16vw,160px);height:clamp(95px,16vw,160px);padding:0;border:0;background:transparent;z-index:10}
.food-bowl{left:calc(50% - clamp(165px,23vw,265px))}
.water-bowl{left:calc(50% - clamp(70px,9vw,100px))}
.litter-tray{right:calc(50% - clamp(160px,28vw,350px));width:clamp(130px,20vw,205px);height:clamp(130px,20vw,205px);bottom:calc(155px + env(safe-area-inset-bottom))}
.scene-item:hover{filter:brightness(1.05)}
.room-decoration{position:absolute;inset:0;pointer-events:none;z-index:3}
.room-prop{position:absolute;display:block;aspect-ratio:1;pointer-events:none}
.prop-blanket{width:clamp(95px,17vw,200px);right:7%;bottom:43%}
.prop-plant{width:clamp(100px,19vw,220px);left:9%;bottom:63%}
.prop-bed{width:clamp(130px,23vw,250px);right:6%;bottom:34%}
.prop-rug{width:min(83vw,620px);left:50%;margin-left:calc(min(83vw,620px) / -2);bottom:calc(145px + env(safe-area-inset-bottom));transform:scaleY(.37);transform-origin:50% 90%;z-index:-1}
.prop-cushion{width:clamp(85px,13vw,155px);left:11%;bottom:33%}
.prop-lights{width:min(52vw,500px);right:12%;top:9%}
.room-prop.prop-cushion.is-moved{left:24%;bottom:39%}
.room-prop.prop-plant.is-moved{left:18%}
.room-prop.prop-blanket.is-moved{right:17%}
.room-prop.prop-bed.is-moved{right:12%}
.prop-rug.is-moved{left:56%}
.prop-lights.is-moved{right:23%}
.needs{position:absolute;z-index:20;bottom:calc(107px + env(safe-area-inset-bottom));left:50%;transform:translateX(-50%);width:min(550px,calc(100% - 28px));display:grid;grid-template-columns:repeat(6,1fr);gap:8px;padding:11px 9px;background:#fff9ecef;border-radius:18px;box-shadow:0 4px 18px #68472c14}
.needs button{padding:0 1px;background:transparent;border:0;display:flex;flex-direction:column;align-items:center;gap:3px;min-width:0}
.needs button>span:first-child{color:var(--green)}
.needs svg{width:21px;height:21px}
.need-name{font-size:12px;font-weight:800}
.need-track{height:5px;background:#e4dccb;width:78%;border-radius:6px;overflow:hidden}
.need-track i{height:100%;display:block;background:#8fa778;width:80%;border-radius:6px;transition:width .25s linear}
.needs .low .need-track i{background:#bc7553}
.needs .low>span:first-child{color:var(--clay)}
.need-value{display:none}
.actions{position:absolute;z-index:20;bottom:max(15px,env(safe-area-inset-bottom));left:50%;transform:translateX(-50%);width:min(620px,calc(100% - 28px));display:grid;grid-template-columns:repeat(6,1fr);padding:7px;gap:4px;background:#fff9ecf5;border-radius:20px;box-shadow:0 5px 25px #68472c1c}
.actions button{background:transparent;border:0;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:6px;min-height:68px;border-radius:14px;font-size:12px;font-weight:800;padding:7px 0}
.actions svg{height:26px;width:26px}
.actions button:hover{background:#e9e0d2}
.actions .play-button{background:var(--sage);color:#3f5839}

.journal-heading{display:flex;align-items:center;justify-content:space-between;gap:10px;margin-bottom:24px}
h2{font-size:21px;letter-spacing:-.025em;line-height:1.2;margin:0;font-weight:900}
.chapter-count{font-size:12px;color:var(--muted);font-variant-numeric:tabular-nums}
.quest{padding:24px;border-radius:18px;background:#ece7d7;min-height:265px}
.quest-meta{display:flex;align-items:center;justify-content:space-between;color:#586344;font-size:12px}
.quest-meta svg{width:22px;height:22px}
.quest h3{font-size:25px;line-height:1.14;letter-spacing:-.025em;margin:14px 0 12px;font-weight:900}
.quest p{font-size:14px;color:#6d624f;margin:0 0 18px;line-height:1.6}
#quest-tasks{list-style:none;padding:0;margin:0;display:grid;gap:12px}
#quest-tasks li{font-size:14px;display:flex;align-items:center;gap:9px}
#quest-tasks .task-check{width:20px;height:20px;border:1.5px solid #b4b49b;border-radius:50%;display:grid;place-items:center;flex-shrink:0}
.task-check svg{width:13px;height:13px}
#quest-tasks .done{color:#5a6b49}
#quest-tasks .done .task-check{background:#6a7f56;color:#fff8e9;border-color:#6a7f56}
#quest-tasks .task-count{margin-left:auto;font-size:12px;color:#766b55;white-space:nowrap}
.primary-button{background:var(--green);color:#fff9e9;border:0;border-radius:12px;min-height:48px;padding:12px 20px;font-weight:900;font-size:14px}
.primary-button:hover{background:#405a3a}
#claim{width:100%;margin-top:20px}
.quest .quest-wait{margin:18px 0 0;padding-top:12px;border-top:1px solid #d9d3be;font-size:12px}
.growth{margin:28px 0}
.section-row{display:flex;justify-content:space-between;gap:12px;align-items:center;margin-bottom:12px}
h3{font-size:14px;margin:0;font-weight:900}
#growth-time{font-size:12px;color:var(--muted);white-space:nowrap}
.growth-track{height:7px;background:#e3dbca;border-radius:8px;overflow:hidden}
#growth-fill{height:100%;display:block;background:#a5b888;min-width:2px}
.growth-ages{display:flex;justify-content:space-between;margin-top:8px;font-size:12px;color:#71634f}
.growth-ages .current{color:var(--green);font-weight:900}
#next-growth{color:var(--muted);font-size:12px;margin:13px 0 0}
.save-note{font-size:12px;color:var(--muted);display:flex;align-items:center;gap:5px}
.save-note svg{width:13px;height:13px}
dialog{color:var(--ink);border:0;border-radius:26px;padding:26px;background:#fbf6ea;max-width:460px;width:calc(100% - 28px);box-shadow:0 18px 90px #34271945;max-height:88dvh;overflow-y:auto}
dialog::backdrop{background:#2f3d2d8c}
#welcome{text-align:center;padding:14px 28px 28px}
.welcome-art{width:210px;height:190px;position:relative;margin:0 auto}
.welcome-art .cat-art{background-size:300% 200%}
.welcome-name{font-size:13px;color:#7e5e3e;margin:4px 0 12px}
#welcome h2{font-size:29px;line-height:1.1}
#welcome>p:not(.welcome-name){font-size:14px;line-height:1.6;color:var(--muted);margin:18px auto 20px;max-width:32ch}
#welcome .primary-button{width:100%}
#welcome small{display:block;font-size:12px;color:var(--muted);margin-top:14px}
.sheet-heading{display:flex;align-items:center;justify-content:space-between;gap:12px;margin-bottom:16px}
#sheet-content>p{color:var(--muted);font-size:13px}
.toy-options{display:grid;gap:10px}
.toy-option{display:flex;align-items:center;gap:14px;border:0;background:#eee8d9;border-radius:14px;padding:17px;text-align:left}
.toy-option>svg{width:36px;height:36px;color:#81774d}
.toy-option strong{font-size:16px}
.toy-option small{display:block;color:var(--muted);font-size:12px;margin-top:3px}
.toy-option b{margin-left:auto;color:#8b6a43;font-size:12px}
.shop-item{padding:10px 0;display:flex;gap:10px;align-items:center;border-bottom:1px solid var(--line)}
.shop-preview{width:82px;height:82px;flex-shrink:0}
.shop-item p{margin:0}
.shop-item small{font-size:12px;color:var(--muted);display:block}
.shop-item button{margin-left:auto;border:0;border-radius:10px;min-width:65px;min-height:42px;font-weight:900;background:var(--sage);font-size:12px;padding:5px}
.setting{display:flex;justify-content:space-between;align-items:center;gap:20px;padding:14px 0;border-bottom:1px solid var(--line)}
.setting span{display:flex;gap:10px;align-items:center;font-size:14px}
.setting input{width:23px;height:23px;accent-color:var(--green)}
.favorite-select{display:flex;gap:8px;margin:10px 0 20px}
.favorite-select button{flex:1;border:1px solid var(--line);border-radius:12px;padding:8px;background:transparent;display:grid;justify-items:center;gap:5px;font-size:12px}
.favorite-select button.selected{background:var(--sage);border-color:#8ca275}
.danger-button{background:transparent;color:#9e5138;border:1px solid #d2bca7;border-radius:10px;padding:10px 12px;font-size:12px}
.album-entry{display:flex;align-items:center;gap:13px;padding:13px 0;border-bottom:1px solid var(--line)}
.album-entry>span{width:34px;height:34px;display:grid;place-items:center;border-radius:50%;background:var(--sage);color:#60754d}
.album-entry.locked{opacity:.5}
.album-entry p{margin:0;font-size:13px}
.album-entry small{display:block;color:var(--muted);font-size:12px}
#toast{position:fixed;bottom:max(20px,env(safe-area-inset-bottom));left:50%;transform:translateX(-50%);width:max-content;max-width:90vw;background:#3d4e35;color:#fff9e9;padding:12px 20px;border-radius:14px;text-align:center;font-size:13px;z-index:20;box-shadow:0 4px 18px #34271924}
#cat-fx{position:absolute;left:50%;top:25%;color:#b06757;pointer-events:none}
#cat-fx span{position:absolute;animation:float-away 1.3s var(--ease) both}
#cat-fx svg{width:25px;height:25px;fill:#deb39a}
@keyframes float-away{0%{opacity:0;transform:translateY(0) scale(.9)}20%{opacity:1}100%{opacity:0;transform:translateY(-85px) rotate(15deg) scale(1.12)}}
.room.sleeping{filter:brightness(.8)}
.room.sleeping .scene-top{color:#5c584d}
.sleep-stars{position:absolute;left:56%;top:40%;color:#fff7d4;font-weight:900;font-size:25px;z-index:4;animation:float-z 2s ease-in-out infinite}
.sleep-stars span{font-size:18px;position:absolute;left:20px;top:-19px}.sleep-stars b{position:absolute;left:38px;top:-32px;font-size:13px}
@keyframes float-z{0%,100%{transform:translateY(0);opacity:.6}50%{transform:translateY(-12px);opacity:1}}
#minigame{position:absolute;inset:max(90px,calc(env(safe-area-inset-top) + 80px)) max(14px,env(safe-area-inset-right)) calc(185px + env(safe-area-inset-bottom)) max(14px,env(safe-area-inset-left));z-index:25;border-radius:22px;background:#f5f0e3f5;padding:18px;display:flex;flex-direction:column}
.game-top{display:flex;justify-content:space-between;align-items:center;gap:8px}
.game-top strong{font-size:19px}
#game-instruction{font-size:13px;color:var(--muted);margin:0 0 10px}
.game-score{display:flex;justify-content:space-between;font-size:12px;color:var(--green)}
#game-field{position:relative;flex:1;min-height:130px;touch-action:manipulation;overflow:hidden;border-radius:16px;background:#e8e4d2;margin-top:12px}
.mini-art{display:block;background:url(media/mini-toys.png) 0 0/200% 200% no-repeat;width:100%;height:100%;pointer-events:none}
.toy-ball{background-position:0 0}
.toy-feather{background-position:100% 0}
.toy-mouse{background-position:0 100%}
.toy-cushion{background-position:100% 100%}
.toy-option>.mini-art{width:60px;height:60px;flex-shrink:0}
.favorite-select .mini-art{width:40px;height:40px}
#game-field.ball{background:#e4cba3}
#game-field.feather{background:radial-gradient(ellipse at 50% 0%,#e4f3e6,#b2d5d1 55%,#85b9be)}
#game-field.feather::before{content:"";position:absolute;inset:0;border-radius:16px;box-shadow:inset 0 12px 32px #ffffff35;pointer-events:none}
.game-target{position:absolute;width:96px;height:96px;border:0;background:transparent;padding:0;touch-action:manipulation}
.game-target:active{filter:brightness(1.07)}
.target-ball::before{content:"";position:absolute;left:19%;right:19%;bottom:8%;height:9%;border-radius:50%;background:#6a4d3a33;filter:blur(3px);pointer-events:none}
.target-fish{width:112px;height:112px}
.target-fish>.mini-art{animation:swim .85s ease-in-out infinite}
@keyframes swim{0%,100%{transform:translateY(2px) rotate(-2deg)}50%{transform:translateY(-2px) rotate(2deg)}}
#game-field.mouse{display:flex;justify-content:space-evenly;align-items:center}
.cushion-choice{position:relative;width:31%;aspect-ratio:1;background:transparent;border:0;padding:0;display:grid;place-items:center}
.cushion-choice .mouse-glimpse{position:absolute;width:78%;height:78%;left:11%;top:-17%}
.cushion-choice.reveal .toy-cushion{transform:translateY(12%) rotate(-7deg)}
@media(prefers-reduced-motion:reduce){.target-fish>.mini-art{animation:none}}
.journal-panel{padding-bottom:6px}
.album-intro{font-size:13px;color:var(--muted);margin:0 0 12px}
#journal{max-width:480px}
#journal .journal-heading{margin-bottom:18px}
#journal .journal-heading h2{font-size:18px}
#journal .quest{padding:20px}
#journal .growth{margin:6px 0 22px}
@media(min-aspect-ratio:6/5){
 .room{background-image:url(media/room-wide.png);background-position:center 57%}
 .scene-top{top:max(25px,env(safe-area-inset-top));left:auto;right:132px}
 .cat-wrap{bottom:calc(158px + env(safe-area-inset-bottom))}
 .speech{top:22%}
 .prop-plant{left:14%;bottom:56%}
 .prop-blanket{right:15%;bottom:30%}
 .prop-bed{right:13%;bottom:20%}
 .prop-cushion{left:16%;bottom:25%}
 .prop-lights{top:4%;right:19%;width:min(40vw,500px)}
}
@media(max-width:600px){
 .topbar{left:max(12px,env(safe-area-inset-left));right:max(12px,env(safe-area-inset-right));top:max(12px,env(safe-area-inset-top))}
 .identity{gap:8px;padding:7px 11px 7px 7px;border-radius:18px}
 .paw-mark{width:35px;height:35px}
 .paw-mark svg{width:23px;height:23px}
 h1{font-size:22px}
 .identity p{font-size:11px}
 .top-actions{gap:5px}
 .icon-button{width:41px;height:41px;padding:9px}
 .scene-top{top:max(88px,calc(env(safe-area-inset-top) + 78px));left:10px;right:10px;display:grid;grid-template-columns:1.15fr .75fr .9fr 1.1fr;gap:5px}
 .room-menu-button{justify-content:center;padding:9px 6px;font-size:12px;gap:4px}
 .room-menu-button>span>svg{width:17px;height:17px}
 .wallet{margin-left:0;gap:2px}
 .wallet svg{width:14px;height:14px}
 .speech{top:24%;font-size:13px}
 .cat-wrap{width:94vw;margin-left:-47vw;bottom:calc(175px + env(safe-area-inset-bottom))}
 .needs{padding:9px 7px;gap:4px;bottom:calc(93px + env(safe-area-inset-bottom))}
 .needs svg{width:18px;height:18px}
 .need-name{font-size:11px}
 .actions{gap:2px;padding:6px}
 .actions button{min-height:60px;font-size:11px;gap:5px}
 .actions svg{width:23px;height:23px}
 .scene-item{bottom:calc(153px + env(safe-area-inset-bottom))}
 .litter-tray{bottom:calc(145px + env(safe-area-inset-bottom))}
 .shop-preview{width:73px;height:73px}
 .shop-item small{font-size:11px}
 .shop-item strong{font-size:13px}
}
@media(max-height:520px) and (min-width:600px){
 .identity{padding:5px 10px 5px 5px}
 h1{font-size:19px}
 .identity p{font-size:10px}
 .paw-mark{width:32px;height:32px}
 .scene-top{top:17px;right:125px}
 .room-menu-button{min-height:40px;padding:8px 10px;font-size:11px}
 .room-menu-button svg{width:18px;height:18px}
 .needs{width:300px;left:16px;bottom:13px;transform:none;gap:3px;padding:10px 5px}
 .need-name{font-size:10px}
 .needs svg{width:17px;height:17px}
 .actions{width:350px;right:16px;left:auto;bottom:13px;transform:none}
 .actions button{min-height:52px;font-size:10px}
 .actions svg{width:22px;height:22px}
 .cat-wrap{width:70dvh;margin-left:-35dvh;bottom:68px}
 .scene-item{width:90px;height:90px;bottom:67px}
 .food-bowl{left:calc(50% - 145px)}
 .water-bowl{left:calc(50% - 70px)}
 .litter-tray{width:120px;height:120px;right:calc(50% - 195px);bottom:57px}
 .speech{top:24%;font-size:12px;padding:7px 12px}
 #minigame{inset:75px 18% 88px}
 #game-field{min-height:80px}
 .game-top strong{font-size:16px}
 #game-instruction{font-size:12px}
 .prop-rug{width:360px;margin-left:-180px;bottom:50px}
}
@media(prefers-reduced-motion:reduce){.cat-wrap.breathing,.cat-wrap.reacting,.sleep-stars,#cat-fx span{animation:none}.need-track i{transition:none}}

.cat-art.kitten-purr{background-image:url(media/kitten-purr.png);background-size:200% 100%}
@media(max-height:520px) and (min-width:600px){
 .game-target{width:76px;height:76px}
 .target-fish{width:84px;height:84px}
}
.cushion-choice:disabled{opacity:1}
