/* Final chart alignment and responsive composition. */
[hidden]{display:none!important}
.scene{padding-inline:clamp(20px,5vw,72px);overflow:clip}
h1{font-size:clamp(44px,5.2vw,76px);font-weight:800;letter-spacing:-.045em;line-height:1}
h2{font-size:clamp(28px,3.4vw,48px);letter-spacing:-.035em;line-height:1.08}
.hero-copy{max-width:none;width:max-content;max-width:100%;margin-left:0;padding-top:10px}
.hero-copy p{font-weight:400;font-size:clamp(14px,1.3vw,18px)}
.hero-note{top:40%;left:6%;max-width:135px}
.sun{top:40%;width:clamp(180px,24vw,310px);background:radial-gradient(circle at 40% 30%,#fff6c1,#f8df9d);box-shadow:0 0 45px #f8df9d50;transition:transform .45s cubic-bezier(.2,.8,.3,1)}
.sun span{font-size:54px}.sun strong{font-size:14px}
.hero .scene-image{filter:brightness(calc(.94 + var(--wake,0)*.12)) saturate(calc(.98 + var(--wake,0)*.06));transition:filter .65s}
.town-nav nav{background:#fff7efed;backdrop-filter:none}.resident-inspector{background:#fff7eff5;backdrop-filter:none}
.town-nav.on-night .mark{background:#fff7ef;color:#10244b}
.section-copy{max-width:100%}.section-copy span{font-size:26px;line-height:1.25}.section-copy p{font-size:11px;letter-spacing:.075em;font-weight:500;margin-top:10px}
.chart-plot{margin-top:70px;width:min(830px,72%);margin-left:12%;overflow:visible;background:repeating-linear-gradient(90deg,transparent 0 calc(25% - 1px),#10244b12 25%);border-top:0}
.time-axis{left:8%;right:8%;display:flex;justify-content:space-between;top:-30px}.time-axis span:nth-child(2){background:none;padding:0}
.wake-count{right:5%;top:54%;font-size:44px}
.wheel .scene-image{height:52%;object-position:50% 76%;opacity:.78;mask-image:linear-gradient(transparent,#000 38%)}
.wheel-stage{height:auto;min-height:540px;align-items:center}.wheel-structure{position:relative;background:#cfe7fa78;border-radius:50%;filter:none}
.wheel-structure>g.spokes{transform-origin:260px 260px;transform:rotate(var(--rotation,0deg))}
.wheel-structure circle{stroke:#fff7ef;stroke-width:5;fill:transparent}.wheel-structure circle:last-of-type{fill:#304264;stroke-width:3}.wheel-structure line{stroke:#30426470;stroke-width:1.5}
.wheel-panel{background:#fff7eff5;box-shadow:0 7px 20px #10244b0b;border-radius:12px;max-width:260px;font-size:14px}
.wheel-panel::before{content:'';display:block;height:130px;background:url('./assets/cafe.webp') center 45%/cover;border-radius:7px;margin-bottom:15px}
.sankey-wrap{width:72%;margin-left:7%;margin-top:72px}.commute .hand-note{top:auto;bottom:12%;font-size:24px}.destination-controls{top:32%;right:5%;gap:12px}
.destination-controls button{min-width:145px;box-shadow:none;background:#fff7ef;border:1px solid #10244b15;font-size:12px}
[data-destination][aria-pressed=true],[data-filter][aria-pressed=true],[data-relation][aria-pressed=true]{background:#b7ded0!important;color:#10244b!important;box-shadow:inset 0 0 0 1px #304264}
#commute-story{bottom:9%;right:6%;font-size:14px;box-shadow:none}
.apartments .scene-image{content:url('./assets/town.webp');height:38%;object-position:center bottom;opacity:.5;mask-image:linear-gradient(transparent,#000 65%)}
.building-row{height:460px;gap:clamp(14px,3vw,42px);padding-bottom:70px;margin-top:70px}
.building{height:var(--h);min-height:0;padding:18px 10px 40px;border-radius:2px;box-shadow:5px 7px 0 #30426425,inset -9px 0 #30426412;border:1px solid #30426425;overflow:visible}
.building::before{left:-9%;right:-9%;top:-15px;height:24px;border-radius:1px;clip-path:polygon(15% 0,85% 0,100% 80%,100% 100%,0 100%,0 80%);background:#8293a4}
.building:nth-child(2n)::before{background:#bd8c89}.building:nth-child(3n)::before{height:32px;top:-25px;background:#667c96;clip-path:polygon(50% 0,100% 90%,100% 100%,0 100%,0 90%)}
.building::after{bottom:0;height:28px;width:20px;border-radius:7px 7px 0 0;background:#526772}
.windows{grid-template-columns:repeat(3,1fr);gap:6px 8px;height:100%;grid-auto-rows:minmax(10px,1fr);padding-bottom:6px}
.windows span{aspect-ratio:auto;min-height:10px;max-height:24px;border-radius:1px;background:linear-gradient(90deg,#f8df9d 44%,#b3a896 45% 54%,#fff7ef 55%);border:2px solid #fff7ef85;box-shadow:1px 2px 0 #30426455}
.building b{bottom:-38px;font-size:13px}.building em{bottom:-63px;font-size:20px}.building:hover{transform:translateY(-4px)}
.mood-plot{margin:70px auto 0;width:70%;height:440px;background:linear-gradient(transparent 49.8%,#30426430 50%,transparent 50.2%),linear-gradient(90deg,transparent 49.8%,#30426430 50%,transparent 50.2%);border:none}
.mood-plot::before{content:'';position:absolute;left:8%;right:8%;top:86%;border-bottom:1px solid #30426485}.mood-plot::after{content:'';position:absolute;left:8%;top:14%;bottom:14%;border-left:1px solid #30426485}
.axis-label.top{top:1%;left:8%}.axis-label.bottom{left:8%;bottom:0}.axis-label.left{left:8%;bottom:7%}.axis-label.right{right:8%;bottom:7%}.axis-label{font-size:12px}
.filter-stack{right:4%;top:31%;gap:6px}.filter-stack button{min-width:100px;font-size:12px;box-shadow:none}
.network{background:#0c1c3b}.network::before{background:none}.network-plot{width:78%;margin-left:0;height:560px}.relation-controls{right:5%;top:30%}.relation-controls button{color:#fff7ef;background:#152b55;border:1px solid #ffffff35;box-shadow:none}
.lost .scene-image{display:none}.lost-grid{grid-template-columns:200px minmax(0,1fr);gap:30px}.lost-items{background:url('./assets/park.webp') center/cover;border-radius:40% 40% 4px 4px;height:440px}
.lost-object{background:transparent!important;box-shadow:none!important;border:0!important;width:44px;height:44px;min-width:44px;padding:8px;transform:rotate(var(--tilt));color:#10244b}
.lost-object svg{width:28px;height:28px;filter:drop-shadow(1px 2px 1px #10244b55)}
.lost-object.found{opacity:.24;transform:translateY(-10px) scale(.8);transition:transform .32s,opacity .32s}
.hints .lost-object:not(.found){outline:2px dashed #10244b;outline-offset:1px;animation:hint .8s 1}
.lost-counts{font-size:15px}.lost-counts li{border-bottom:1px solid #10244b15;padding:13px 0}
.night{min-height:115svh;background:#0c1c3b}.night::before{background:none}.night .scene-image{object-position:center bottom;height:85%;opacity:1;mask-image:linear-gradient(transparent,#000 35%)}
#night-lights{position:absolute;inset:0}.night-window{position:absolute;width:7px;height:10px;border-radius:1px;background:#142646;transition:background .18s}.night-window.lit{background:#f8df9d;box-shadow:0 0 5px #f8df9d90}
#awake-count{font-size:58px;top:28%;right:44%}.night .last-resident{background:#fff7ef;color:#10244b;max-width:240px;font-size:13px;z-index:7}
.result{min-height:75svh;background:#fff7ef}.result .section-copy{padding-top:12px}.result .section-copy h2{font-size:32px}
.donut{border-radius:50%;aspect-ratio:1;display:grid;place-items:center;width:260px;height:260px;background:#e8e6df}
.donut::after{content:'• ᴗ •';display:grid;place-items:center;width:58%;height:58%;background:#fff7ef;border-radius:50%;font-size:27px;color:#10244b;font-weight:700}
.stats div{display:flex;gap:18px;align-items:baseline;line-height:2}.stats strong{min-width:30px;font-size:25px}.stats span{font-size:14px}
#resident-tooltip{position:fixed;max-width:205px;z-index:30;transform:none;pointer-events:none;background:#fff7ef;padding:12px;border-radius:12px}#resident-tooltip span{display:block;font-size:12px;margin-top:5px}
.interior-image{position:relative;background-size:cover;min-height:260px}.interior-resident{position:absolute;left:46%;bottom:18%;width:56px;height:70px}.interior-prop{position:absolute;right:16%;bottom:14%;width:42px;height:42px}
.interior-image.interior-active .interior-prop{transform:rotate(-15deg) translateY(-12px);transition:transform .32s}.interior-sleep.interior-active{filter:brightness(.3)}
.cloud-overlay{position:absolute;z-index:2;width:90px;pointer-events:none;opacity:.85}.hero.is-awake .cloud-overlay{animation:cloud-drift 16s ease-in-out infinite alternate}@keyframes cloud-drift{to{translate:45px 0}}
@media(min-width:1441px){.scene{padding-inline:max(72px,calc((100vw - 1300px)/2))}}
@media(max-width:900px){.scene{padding-top:100px;padding-bottom:80px}.hero{padding-top:100px}.hero-copy{padding-top:0}.hero-copy h1{font-size:clamp(38px,6vw,62px)}.wheel-stage{min-height:0}.chart-plot{margin-left:0;width:100%}.wake-count{right:auto;top:auto}.destination-controls,.filter-stack,.relation-controls{position:relative;inset:auto}.sankey-wrap{width:100%;margin-left:0}.network-plot{width:100%}.mood-plot{width:95%}.lost-grid{grid-template-columns:1fr}.night{min-height:110svh}#awake-count{position:relative;inset:auto}.last-resident{position:relative!important;inset:auto!important}.result .donut{position:relative;inset:auto;margin:30px auto}.result .stats{margin:30px 0}.building-row{height:580px;grid-template-columns:repeat(3,minmax(0,1fr));grid-template-rows:1fr 1fr;row-gap:90px}.building{height:calc(var(--h) * 1.25)}.result .primary-cta{display:block;margin:30px auto}}
@media(max-width:767px){
.town-nav{left:10px;right:10px;gap:6px}.town-nav .mark{width:38px;height:38px;min-height:38px;flex-shrink:0;font-size:9px}.town-nav nav{max-width:none;flex:1;gap:0;justify-content:space-between;padding:3px 5px;overflow:visible;border-radius:10px}.town-nav button{padding:0 5px;white-space:nowrap;font-size:9px;letter-spacing:0;flex-shrink:0}#sound-toggle span{width:9px;height:9px;margin-left:3px}
.hero{min-height:100svh}.hero-copy{width:100%;padding-top:14px}.hero-copy h1{font-size:clamp(36px,10.8vw,58px)}.hero-copy p{font-size:12px;max-width:300px}.hero-note{display:none}.sun{top:43%;width:60vw;max-width:250px}.sun span{font-size:44px}.sun strong{font-size:11px}#wake-town{bottom:8%;white-space:nowrap;font-size:11px;padding:12px 16px}.hero .scene-image{object-position:center bottom}
.section-copy{grid-template-columns:30px 1fr;gap:10px}.section-copy span{font-size:20px}.section-copy h2{font-size:28px}.section-copy p{font-size:9px;line-height:1.5}.chart-plot{height:480px;margin-top:40px;overflow:visible;border:0;background:repeating-linear-gradient(180deg,transparent 0 calc(25% - 1px),#10244b18 25%)}
.time-axis{top:8%;bottom:8%;left:0;right:auto;flex-direction:column;font-size:11px}.wake-count{font-size:32px;margin-top:20px}.wake-count small{display:inline-block;margin-left:14px;font-size:13px}.wheel-structure{width:82vw;max-width:100%;margin:auto}.wheel-panel{max-width:100%;width:100%;margin:20px 0}.wheel-panel::before{height:120px}.wheel-stage{gap:0}.wheel .scene-image{height:38%}
.sankey-wrap{height:450px;margin-top:38px}.destination-controls{overflow:visible;display:grid;grid-template-columns:repeat(5,minmax(0,1fr));gap:2px}.destination-controls button{display:flex;flex-direction:column;justify-content:center;gap:4px;min-width:0;font-size:8px;padding:5px 1px}.destination-controls b{font-size:14px}#commute-story{position:relative;inset:auto;max-width:100%;font-size:13px}
.building-row{height:600px;gap:80px 16px;margin-top:56px;padding-bottom:55px;grid-template-columns:repeat(3,minmax(0,1fr));grid-template-rows:1fr 1fr}.building{padding:12px 7px 32px}.windows{gap:5px 4px}.windows span{border-width:1px}.building b{font-size:11px;left:0;right:0}.building em{font-size:18px}.apartments .scene-image{height:28%}
.mood-plot{width:100%;height:auto;aspect-ratio:1;margin-top:48px}.axis-label{font-size:10px}.axis-label.top{top:0}.axis-label.bottom{bottom:-4px}.axis-label.left,.axis-label.right{bottom:4%}.axis-label.left{left:8%}.axis-label.right{right:8%}.filter-stack{margin-top:30px;gap:6px}.filter-stack button{min-width:70px;font-size:11px}.network-plot{height:550px;margin:15px 0}.relation-controls{margin-top:0;gap:5px}.relation-controls button{min-width:85px;font-size:11px}
.lost-grid{gap:20px;margin-top:25px}.lost-counts{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:5px 20px;padding:0;font-size:13px}.lost-items{height:420px;margin-inline:-10px;width:calc(100% + 20px);border-radius:30% 30% 2px 2px}.lost-object{padding:10px}.lost-object svg{width:24px;height:24px}#found-status{font-size:12px;max-width:100%}.night{min-height:115svh}.night-town{height:300px;bottom:12%;left:0;right:0}.night .scene-image{width:auto;min-width:100%;height:75%;left:50%;translate:-50% 0;max-width:none}#awake-count{font-size:48px;margin-top:35px}.night .last-resident{max-width:210px}.night-window{width:5px;height:7px}
.resident-inspector{padding:9px;bottom:8px;max-height:132px}.resident-inspector p{font-size:11px;max-height:34px;overflow:auto;margin-bottom:5px}.inspector-actions{gap:5px}.inspector-actions button{min-height:44px}.result .section-copy h2{font-size:28px}.stats strong{font-size:23px}.result footer{gap:12px;flex-wrap:wrap;padding-bottom:20px}.cloud-overlay{width:60px}
}
@media(prefers-reduced-motion:reduce){.sun,.lost-object,.interior-image,.night-window{transition:none!important}.cloud-overlay{animation:none!important}}
.mood{background:#cfe7fa}.mood::after{bottom:0;height:150px;background:url('./assets/park.webp') right 75%/cover;mask-image:linear-gradient(transparent,#000);opacity:.42}
.network::before{top:0;height:70px;background:linear-gradient(#cfe7fa,#0c1c3b);opacity:.8}.network::after{bottom:0;height:160px;background:url('./assets/night.webp') center 65%/cover;mask-image:linear-gradient(transparent,#000);opacity:.35}
#awake-count::after{content:'residents awake.';display:block;font:14px 'DM Sans',sans-serif;letter-spacing:.02em;white-space:nowrap;margin-top:8px}
#bloom-connections{display:block;margin-top:10px;padding:8px 12px;font-size:11px;color:#fff7ef;border:1px solid #ffffff35;border-radius:20px;background:#152b55;min-height:44px}
@media(max-width:767px){.mood::after{height:90px}.network::after{height:100px}}
.hero-window{position:absolute;width:5px;height:8px;z-index:3;background:transparent;pointer-events:none;transition:background .32s}.hero-window.lit{background:#ffe9a5;box-shadow:0 0 6px #ffe9a5}.hero .hero-window{opacity:.8}@media(max-width:767px){.hero-window{display:none}}
.wake-plot,.mood-plot,.network-plot,.wheel-structure{touch-action:none}.sun{transition:transform .65s cubic-bezier(.34,1.4,.64,1)}
