/* A single portrait game, with the original information hierarchy. */
:root{font-family:"Microsoft YaHei UI","PingFang SC",system-ui,sans-serif;color:#294337;background:#d6dbd3;font-size:14px;--green:#3c9b83;--dim:#7d8979;--head:#657b74;--line:#dce3d4;--paper:#fffef8;--nav-h:126px}
*{box-sizing:border-box}body{margin:0}button,input,select{font:inherit}button{cursor:pointer;color:inherit;touch-action:manipulation;-webkit-tap-highlight-color:transparent}button:disabled{cursor:default;opacity:.55}button:focus-visible,input:focus-visible,select:focus-visible{outline:3px solid #cca35a;outline-offset:2px}button img,button svg{pointer-events:none}img{display:block;max-width:100%}h1,h2,h3,p{margin:0}small{font-size:11px}.muted{color:var(--dim)}.good{color:#2d936b}.bad{color:#b9644d}.gold{color:#b38d46}.mono{font-variant-numeric:tabular-nums}.loading{padding:50px;text-align:center}.line-icon{width:21px;height:21px;fill:none;stroke:currentColor;stroke-width:1.65;stroke-linecap:round;stroke-linejoin:round;flex:none}
.game-shell,.start-shell{width:min(520px,100%);margin:auto;min-height:100dvh;background:#edf0e6;position:relative;box-shadow:0 8px 60px #34473b20}.game-shell{padding-bottom:calc(var(--nav-h) + 13px + env(safe-area-inset-bottom))}.topbar{position:sticky;top:0;z-index:30;background:linear-gradient(125deg,#607b73,#788981);color:#fffceb;border-bottom:2px solid #b7c5b2;padding:calc(10px + env(safe-area-inset-top)) 11px 9px;box-shadow:0 3px 10px #183d2915}.top-primary{display:flex;align-items:center;gap:9px}.status-bars{width:111px;flex:none;display:grid;gap:7px}.status-line{display:grid;grid-template-columns:25px 1fr 18px;align-items:center;gap:4px;font-size:9px;line-height:1}.top-meter{height:7px;background:#435b5455;border-radius:2px;overflow:hidden;border:1px solid #ffffff20}.top-meter i{display:block;height:100%;transition:width .25s}.status-line b{font-size:9px;text-align:right;font-weight:500}.cash-block{min-width:76px;flex:1;font-size:13px;line-height:1.5;letter-spacing:-.3px}.cash-block span{display:block;font-size:9px;color:#e8e8d8}.cash-block strong{font-weight:650;white-space:nowrap}.bank-total{color:#cde1b5}.calendar-block{min-width:116px;flex:none;text-align:right}.calendar-main{display:flex;align-items:center;justify-content:flex-end;gap:9px}.calendar-label{font-size:12px;line-height:1.6}.top-tools{display:flex;gap:5px}.top-tool{padding:3px;border:0;background:none;color:#fffce8;display:grid;place-items:center;position:relative;width:27px;height:31px}.top-tool .line-icon{width:24px;height:24px}.calendar-minor{display:flex;align-items:center;justify-content:space-between;font-size:9px;color:#e9ecda;margin:1px 0 6px}.week-controls{display:flex;justify-content:flex-end;gap:4px}.week-btn{width:29px;height:29px;border-radius:50%;border:1px solid #ebeedaab;background:#e1e6d233;color:#fffce8;font-size:9px;padding:0;box-shadow:inset 0 0 0 2px #657b7433}.week-btn.active{background:#fff7d9;color:#45665a;border-color:#fff7d9;font-weight:700}.week-btn:active{transform:scale(.92)}.notification-count{position:absolute;right:0;top:0;width:14px;height:14px;background:#bd6a50;border-radius:50%;font-size:9px;display:grid;place-items:center}
.main-page{min-height:calc(100dvh - 240px)}.section-tabs{display:flex;align-items:center;background:#dce4d8;border-top:1px solid #cad4c5;border-bottom:1px solid #cad4c5;padding:5px 6px;gap:3px;min-height:39px}.section-tabs button{flex:1;white-space:nowrap;border:0;border-radius:15px;background:none;padding:6px 5px;font-size:12px;color:#64786d}.section-tabs button.active{background:var(--paper);box-shadow:0 2px 5px #35503f16;color:#294c3e;font-weight:700}.section-tabs .shop-tab{flex:.75;font-size:11px;color:#557665}.section-title{font-size:13px;font-weight:650;padding:10px 12px 8px;display:flex;justify-content:space-between;align-items:center;border-bottom:1px solid #d7e0d1;color:#4b6656;background:#e8ede1}.section-title small{font-size:10px;font-weight:400;color:#7f8b76}.section-note,.detail-copy{font-size:11px;line-height:1.8;padding:9px 12px;color:#7c8778;background:#f5f5eb;border-bottom:1px solid #dfe4d9}.empty{font-size:12px;color:#7b877a;line-height:1.9;text-align:center;padding:28px 18px}.small-banner{margin:10px 10px 4px;padding:12px;background:#e3eadb;border:1px solid #d2ddc8;border-radius:7px;line-height:1.8;font-size:12px}.small-banner strong{color:#456650}
.family-strip{display:flex;gap:14px;overflow-x:auto;padding:12px 12px 9px;background:linear-gradient(#f6f6ec,#e9eddf);border-bottom:1px solid #d9dfd0;scrollbar-width:thin}.family-person{flex:none;max-width:76px;min-width:64px;border:0;background:none;padding:0;text-align:center;font-size:11px;line-height:1.6}.family-person .portrait-wrap{height:65px;width:65px;border-radius:50% 50% 42% 42%;background:#dbe5d4;margin:0 auto 5px;overflow:hidden;border:1px solid #d1dbca}.family-person.self .portrait-wrap{background:#ede4c9;border-color:#d4bd8d}.portrait-wrap img{width:100%;height:100%;object-fit:contain}.family-person span{display:block;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.family-person small{font-size:9px;color:#829078}.identity{display:grid;grid-template-columns:1.2fr 1fr;gap:9px;padding:10px 13px 8px;background:#f2f3e8;line-height:1.8;font-size:12px}.identity-key{color:#5d6c60;display:inline-block;min-width:39px}.identity-value{color:#35533f;font-weight:550}.identity-attrs{align-self:center;display:grid;gap:7px}.identity-attr{display:grid;grid-template-columns:26px 1fr 20px;gap:4px;align-items:center;font-size:10px}.mini-meter{height:7px;background:#dae0cf;border-radius:2px;overflow:hidden}.mini-meter span{display:block;background:#99b68b;height:100%}.identity-attr:nth-child(2) .mini-meter span{background:#bca76c}.identity-attr:nth-child(3) .mini-meter span{background:#8baea5}.identity-attr b{font-size:9px;font-weight:400}.summary-rows{padding:0 12px 9px;background:#f2f3e8}.summary-link{display:flex;width:100%;align-items:center;justify-content:space-between;border:0;border-bottom:1px solid #dbe1d2;background:none;padding:8px 1px;text-align:left;font-size:12px;min-height:33px;gap:12px}.summary-link:last-child{border-bottom:0}.summary-link small{color:#83917b}.chevron{color:#7c907b;font-size:19px;line-height:1;margin-left:auto}.summary-link .value{margin-left:auto;font-size:11px;color:#6e8468}.summary-link .value.cash{color:#3c8b6b}
.list{display:grid;gap:4px;padding:5px}.list-row{display:flex;align-items:center;gap:9px;padding:10px 8px;min-height:80px;border:1px solid #dce4d5;border-radius:5px;background:#fffef9;position:relative}.list-row.unavailable{background:#f6f6ef}.row-illustration{width:51px;height:56px;flex:none;object-fit:contain}.row-portrait{border-radius:7px;background:#e3e9da;object-fit:contain;height:58px;width:52px}.row-copy{min-width:0;flex:1;line-height:1.6}.row-title{font-size:13px;font-weight:600;line-height:1.5;color:#2e493b;display:block;border:0;background:none;text-align:left;padding:0;width:100%}.row-subtitle{font-size:10px;color:#84917d;line-height:1.65}.row-price{font-size:11px;line-height:1.7;color:#4c936b}.row-warning{font-size:10px;color:#a06959;line-height:1.5}.row-description{font-size:10px;color:#788671;margin-top:2px;line-height:1.6}.row-actions{display:flex;gap:4px;flex-wrap:wrap;align-items:center;justify-content:flex-end;max-width:142px;flex-shrink:0}.action-button{font-size:11px;line-height:1.2;padding:9px 8px;min-height:35px;min-width:48px;border-radius:8px;border:1px solid #38977e;background:linear-gradient(#4eaf92,#3e9b81);color:#fffef1;box-shadow:0 2px 2px #426b4d13}.action-button.secondary,.action-button.quiet{background:#edf1e3;color:#607a60;border-color:#d2dec9;box-shadow:none}.action-button:disabled{background:#93a298;border-color:#93a298;color:#fffef2;opacity:.72}.action-button.danger{background:#b67560;border-color:#b67560}.progress{height:7px;background:#dfe5d7;position:relative;border-radius:2px;overflow:hidden;margin-top:5px}.progress span{position:absolute;inset:0 auto 0 0;background:#73a675}.progress-label{font-size:9px;line-height:1.5;color:#8c967f;display:flex;justify-content:space-between;margin-top:3px}.owned-label{display:inline-block;font-size:9px;border-radius:3px;padding:1px 5px;background:#edf1df;color:#7b945f;margin-left:4px;vertical-align:1px}.locked-reason{font-size:9px;color:#9e8c72;max-width:130px;line-height:1.5;text-align:right}.item-detail-link{border:0;background:none;padding:0;color:inherit;text-align:left;flex:1;min-width:0;display:flex;align-items:center;gap:9px}.section-list-footer{padding:12px;text-align:center;font-size:10px;color:#8a957d}.weekly-net{font-size:11px;color:#687e62;padding:8px 12px;background:#e6edde;display:flex;justify-content:space-between;gap:10px}
.intensity-panel{position:sticky;bottom:calc(var(--nav-h) + env(safe-area-inset-bottom));display:grid;grid-template-columns:repeat(3,1fr);gap:5px;padding:7px;background:#e2e8daef;border-top:1px solid #cad7c1;z-index:18;backdrop-filter:blur(8px)}.intensity-button{border:1px solid #c0ceb6;background:#f2f4e8;border-radius:5px;padding:8px 2px;color:#71856a;font-size:11px;line-height:1.7}.intensity-button.active{background:#5c8668;color:#fff7dd;border-color:#5c8668}.intensity-button small{display:block;font-size:9px;opacity:.82}.intensity-button .pay{font-size:11px;font-weight:600}.bottom-nav{position:fixed;bottom:0;left:50%;transform:translateX(-50%);width:min(520px,100%);z-index:40;background:#fafbefee;border:1px solid #cbd5c2;border-bottom:0;box-shadow:0 -4px 15px #34502b0c;display:grid;grid-template-columns:repeat(7,minmax(0,1fr));grid-template-rows:repeat(2,1fr);padding:5px 3px calc(4px + env(safe-area-inset-bottom));backdrop-filter:blur(15px);min-height:calc(var(--nav-h) + env(safe-area-inset-bottom))}.nav-button{border:0;background:none;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:3px;color:#829277;font-size:11px;line-height:1.3;border-radius:6px;padding:4px 0;min-height:55px;position:relative}.nav-button.active{color:#315c43;background:#e5ecd9}.nav-button.active:after{content:"";position:absolute;bottom:2px;width:12px;height:2px;background:#7e9b68;border-radius:3px}.nav-picture{height:31px;width:34px;object-fit:contain;filter:saturate(.85)}.nav-button.active .nav-picture{filter:saturate(1.1)}.nav-people{position:relative;width:34px;height:31px}.nav-people img{position:absolute;width:26px;height:30px;object-fit:contain;left:0;bottom:0;filter:saturate(.8)}.nav-people img+img{left:10px;width:25px;filter:saturate(.9)}
.detail-page{position:fixed;inset:0;z-index:65;width:min(520px,100%);margin:auto;background:#eef1e7;overflow-y:auto;overscroll-behavior:contain;padding-bottom:18px;box-shadow:0 0 80px #293b4326}.detail-top{position:sticky;top:0;z-index:3;background:var(--head);color:#fffae5;display:flex;justify-content:space-between;align-items:center;padding:calc(13px + env(safe-area-inset-top)) 14px 13px;min-height:54px}.detail-top h2{font-size:16px;font-weight:550}.close-detail{border:0;padding:5px 0 5px 15px;background:none;color:#fffae5;font-size:13px;min-width:50px;min-height:30px}.detail-hero{padding:15px 16px 12px;text-align:center;border-bottom:1px solid #d6dfcc;background:#e8eddc}.detail-hero img{height:98px;width:104px;object-fit:contain;margin:0 auto 6px}.detail-hero .portrait{height:105px;width:105px;background:#d9e3cd;border-radius:13px}.detail-hero h3{font-size:17px;font-weight:550}.detail-hero p{font-size:11px;color:#79896e;line-height:1.85;margin:7px auto 0;max-width:410px}.facts{padding:11px 16px;display:grid;gap:7px;font-size:12px;line-height:1.65;background:#f2f4e8}.fact{display:flex;justify-content:space-between;gap:20px}.fact span{color:#7b8973}.fact b{font-weight:500;text-align:right}.detail-progress{padding:6px 16px 12px;background:#f2f4e8}.detail-actions .list-row{min-height:69px;padding:10px 11px}.detail-actions .row-illustration{width:42px;height:43px}.detail-actions .row-actions{max-width:120px}.detail-actions .action-button{min-width:70px;max-width:120px}.stages{display:flex;justify-content:space-between;padding:13px 17px 20px;font-size:10px;color:#839078;border-bottom:1px solid #d8e1cd}.stage{text-align:center;min-width:28px}.stage:before{content:"";display:block;width:8px;height:8px;margin:0 auto 7px;background:#c6d3ba;border-radius:50%}.stage.done{color:#477a4e}.stage.done:before{background:#64905b}.amount-input{width:108px;max-width:100%;padding:8px;border:1px solid #cbd8c1;background:#fffef7;color:#32543d;border-radius:6px;text-align:right;font-size:13px}.amount-line{display:flex;align-items:center;justify-content:space-between;gap:12px;padding:12px 15px;background:#f5f5e9;border-bottom:1px solid #dce5d2;font-size:12px}.bank-summary{display:grid;grid-template-columns:repeat(3,1fr);background:#e7eddc;padding:14px 5px;text-align:center;gap:6px}.bank-summary strong{display:block;font-size:16px;font-weight:600;color:#48734d;line-height:1.8}.bank-summary small{color:#87937a}.journal{padding:5px 9px}.journal-entry{padding:10px 5px;border-bottom:1px solid #dae2d1;font-size:11px;line-height:1.8}.journal-entry time{font-size:9px;color:#9ca48e}.journal-entry h3{font-size:12px;color:#526d4f;font-weight:600}.journal-entry p{color:#7c8970}.stats-grid{display:grid;grid-template-columns:repeat(2,1fr);gap:8px;padding:12px}.stat-tile{padding:10px;background:#fffdf2;border:1px solid #d9e2cc;border-radius:5px;font-size:12px}.stat-tile b{float:right;color:#63855b}.skill-line{padding:9px 12px;font-size:12px;border-bottom:1px solid #dbe2d0}.skill-line b{float:right;color:#66875c}.tree-person{margin:12px 25px;padding:12px;text-align:center;background:#fffdf0;border:1px solid #cdddc0;border-radius:7px;font-size:12px}.tree-person img{height:65px;width:65px;object-fit:contain;margin:auto}.tree-line{width:1px;height:20px;margin:auto;background:#a5bd94}.tree-label{text-align:center;font-size:11px;color:#94a17f}.toggle-row{display:flex;justify-content:space-between;align-items:center;padding:13px 14px;background:#fffdf4;border-bottom:1px solid #e0e5d6;font-size:12px}.toggle{width:37px;height:23px;padding:0;border:0;background:#c8d2bd;border-radius:15px;position:relative}.toggle:after{content:"";position:absolute;width:17px;height:17px;left:3px;top:3px;border-radius:50%;background:#fffef5}.toggle.on{background:#6c9c72}.toggle.on:after{left:17px}.save-slot{padding:12px;background:#fffdf5;border-bottom:1px solid #dce4d1;display:flex;justify-content:space-between;align-items:center;gap:10px;font-size:11px}.save-slot p{color:#8c987d;line-height:1.8;font-size:10px}.save-slot .action-button{padding:7px;min-width:45px;font-size:10px}.save-notice{font-size:10px;line-height:1.8;padding:10px 13px;color:#8a957b}.save-notice.unsaved{color:#a7694f}
.dialog-backdrop{position:fixed;inset:0;z-index:100;background:#233e32a8;display:flex;align-items:center;justify-content:center;padding:18px;backdrop-filter:blur(3px)}.dialog{width:min(410px,100%);background:#fcf9ed;border:1px solid #d6d8be;border-radius:9px;box-shadow:0 25px 80px #193c2d44;overflow:hidden;max-height:88dvh;display:flex;flex-direction:column}.dialog-title{padding:14px 15px;background:#e4ead6;border-bottom:1px solid #ced9c0;display:flex;align-items:center;gap:15px;justify-content:space-between}.dialog-title h2{font-size:16px;font-weight:550}.dialog-close{border:0;background:none;padding:3px;color:#7e8e71;font-size:19px;line-height:1}.dialog-body{padding:17px 16px;font-size:13px;line-height:1.9;color:#65785e;overflow-y:auto;min-height:0}.dialog-body .event-image{width:100%;max-height:150px;object-fit:cover;border-radius:4px;margin-bottom:13px}.dialog-footer{display:flex;gap:7px;justify-content:flex-end;padding:0 15px 15px}.dialog-footer .action-button{padding:11px 15px}.dialog-options{padding:0 12px 12px;display:grid;gap:6px}.dialog-option{display:block;width:100%;text-align:left;background:#e9efda;border:1px solid #d0ddbf;border-radius:5px;padding:11px;font-size:12px;color:#426a42;line-height:1.6}.dialog-option small{display:block;color:#8a9878;font-size:10px;line-height:1.7;margin-top:3px}.effect-list{font-size:11px;margin-top:8px;color:#8b916d}.modal-lock{overflow:hidden}.notice-button{width:100%;padding:9px 12px;background:#f5ecd6;border:0;border-bottom:1px solid #e4daba;color:#9a7b48;display:flex;justify-content:space-between;align-items:center;text-align:left;font-size:11px;gap:10px}.notice-button strong{font-weight:550}.notice-button span{font-size:10px;flex:none}#toast{position:fixed;bottom:calc(var(--nav-h) + 12px + env(safe-area-inset-bottom));left:50%;transform:translate(-50%,10px);max-width:min(450px,90vw);width:max-content;background:#3a5c47f5;border:1px solid #718669;color:#fffae1;border-radius:7px;box-shadow:0 5px 20px #2b4a3022;padding:11px 16px;font-size:12px;line-height:1.6;z-index:140;pointer-events:none;opacity:0;transition:opacity .15s,transform .15s}#toast.show{opacity:1;transform:translate(-50%,0)}
.start-hero{position:relative;height:270px;overflow:hidden;background:#527068}.start-hero>img{width:100%;height:100%;object-fit:cover;object-position:43% 55%}.start-hero:after{content:"";position:absolute;inset:0;background:linear-gradient(transparent,#133e36b0)}.start-title{position:absolute;z-index:1;bottom:22px;left:23px;color:#fff5d9}.start-title h1{font-family:"Songti SC","STSong","SimSun",serif;font-size:46px;font-weight:500;letter-spacing:5px;text-shadow:0 1px 15px #073b3180}.start-title p{font-size:12px;letter-spacing:2px;margin-top:9px;color:#e4dfc1}.start-actions{padding:20px 17px;display:grid;gap:10px}.start-actions .action-button{font-size:14px;min-height:43px}.start-note{padding:0 20px 20px;font-size:11px;color:#8b967d;line-height:1.9;text-align:center}.birth-header{background:#657b74;color:#fffae5;display:flex;align-items:center;justify-content:space-between;padding:18px 14px}.birth-header h1{font-size:18px;font-weight:500}.birth-header button{background:none;border:0;color:#fffae5;font-size:12px}.birth-list .list-row{align-items:flex-start;min-height:120px;padding:14px 11px}.birth-list .row-illustration{width:61px;height:70px;margin-top:9px}.birth-list .row-title{font-size:16px}.birth-list .row-subtitle{color:#ab905f;font-size:11px}.birth-list .row-description{font-size:12px;line-height:1.9;margin-top:4px}.birth-list .action-button{margin-top:33px}.create-profile{padding:15px;display:flex;align-items:center;justify-content:center;gap:22px;background:#e7eddc}.create-profile img{width:100px;height:110px;object-fit:contain}.create-profile h2{font-size:18px}.create-profile p{font-size:11px;color:#8a967d;line-height:1.9;margin-top:7px}.create-form{padding:17px 14px;display:grid;gap:15px}.form-line label{display:block;font-size:12px;color:#718268;margin-bottom:8px}.form-line input,.form-line select{width:100%;height:40px;padding:8px 11px;border:1px solid #cdd9bf;border-radius:5px;background:#fffdf2;color:#42643f}.gender-buttons{display:flex;gap:8px}.gender-buttons button{flex:1;background:#fffdf2;border:1px solid #cfdbc2;border-radius:5px;padding:9px;color:#819374}.gender-buttons button.active{border-color:#739b6b;background:#e0eacf;color:#466d42}.creation-footer{padding:0 14px 25px}.creation-footer .action-button{width:100%;font-size:14px;min-height:43px}.town-letter{background:#e7eddc;border-top:1px solid #d3dec5;padding:15px;font-size:12px;line-height:2;color:#7a8b6d}.large-text .row-description,.large-text .row-subtitle,.large-text .detail-copy,.large-text .journal-entry,.large-text .section-note{font-size:13px}.large-text .dialog-body{font-size:15px}.reduced-motion *{transition:none!important;animation:none!important;scroll-behavior:auto!important}
@media(min-width:700px){body{padding:18px 0;background:radial-gradient(ellipse at 30% 20%,#e6e7d8,#c9d2c7)}.game-shell,.start-shell{border:1px solid #c4d0bc;border-radius:10px 10px 0 0;overflow:clip;min-height:calc(100dvh - 18px)}.detail-page{border-left:1px solid #c4d0bc;border-right:1px solid #c4d0bc}.bottom-nav{border-radius:8px 8px 0 0}.status-bars{width:142px}.top-primary{gap:13px}.cash-block{font-size:16px}.calendar-block{min-width:160px}.calendar-main{gap:12px}.calendar-label{font-size:14px}.calendar-minor{font-size:11px}.week-btn{width:32px;height:32px;font-size:10px}.topbar{padding:12px 15px}.row-title{font-size:15px}.row-subtitle,.row-description{font-size:11px}.action-button{font-size:12px}.list-row{gap:12px;padding:12px 10px;min-height:87px}.identity,.summary-link{font-size:14px}.family-strip{gap:22px}.family-person{font-size:12px}.row-illustration{width:58px;height:61px}.nav-button{font-size:12px}.nav-picture{width:37px;height:33px}}
@media(max-width:359px){:root{font-size:12px;--nav-h:114px}.topbar{padding-left:7px;padding-right:7px}.status-bars{width:99px}.top-primary{gap:5px}.calendar-block{min-width:110px}.cash-block{font-size:11px;min-width:68px}.calendar-label{font-size:10px}.top-tools{gap:1px}.week-btn{width:25px;height:25px;font-size:8px}.status-line{font-size:8px;grid-template-columns:22px 1fr 17px}.nav-picture{width:29px;height:28px}.nav-button{font-size:10px;min-height:50px}.row-illustration{width:43px;height:48px}.row-title{font-size:12px}.row-actions{max-width:123px}.action-button{min-width:42px;padding:8px 6px;font-size:10px}.identity{font-size:11px}.section-tabs button{font-size:11px;padding-left:2px;padding-right:2px}}
@media(prefers-reduced-motion:reduce){*{transition:none!important;animation:none!important;scroll-behavior:auto!important}}
