/* Stage 28: scoped header and picture-book menu. Existing footer stays unchanged. */
.hj-header .hj-header-inner{position:relative;background:none;display:flex;align-items:center;justify-content:space-between;height:59px;}
.hj-logo{margin:0;flex:0 0 405px;line-height:1;position:relative;z-index:2;}
.hj-logo a{display:inline-flex;align-items:center;border-radius:6px;}
.hj-logo img{width:405px;height:auto;}
.hj-logo a:focus-visible{outline:3px solid #de6492;outline-offset:2px;}
.hj-skyline{width:510px;height:59px;position:relative;overflow:hidden;pointer-events:none;flex:none;}
.hj-town{position:absolute;bottom:0;left:0;width:510px;height:59px;}
.hj-cloud{position:absolute;top:7px;left:0;width:25px;height:9px;background:#9abe76;border-radius:20px;opacity:.9;animation:hj-cloud-drift 42s linear infinite;}
.hj-cloud:before,.hj-cloud:after{content:"";position:absolute;background:inherit;border-radius:50%;width:13px;height:13px;left:4px;top:-6px;}
.hj-cloud:after{width:11px;height:11px;left:13px;top:-4px;}
.hj-cloud-one{animation-delay:-12s;}
.hj-cloud-two{top:12px;animation-duration:58s;animation-delay:-29s;opacity:.75;}
.hj-cloud-three{top:7px;animation-duration:49s;animation-delay:-40s;}
@keyframes hj-cloud-drift{from{transform:translateX(-35px)}to{transform:translateX(545px)}}
.home.hj-menu a{display:flex;align-items:center;width:440px;height:107px;box-sizing:border-box;overflow:hidden;background:#fff;border:0;border-radius:13px;box-shadow:0 5px 0 #205054,0 7px 14px rgba(10,52,54,.10);text-decoration:none;transform:translateY(0);transition:transform .18s cubic-bezier(.2,.8,.2,1),box-shadow .18s ease;}
.home.hj-menu a:hover{border:0;}
.home.hj-menu .hj-menu-art{width:114px;height:107px;flex:0 0 114px;overflow:hidden;}
.hj-menu-art svg{display:block;width:100%;height:100%;pointer-events:none;}
.hj-menu-label{flex:1;text-align:center;color:#393438;font-size:32px;font-weight:700;letter-spacing:.01em;white-space:nowrap;font-family:"Hiragino Maru Gothic ProN","BIZ UDPGothic","Yu Gothic",Meiryo,sans-serif;}
@media(hover:hover){.home.hj-menu a:hover{transform:translateY(-3px);box-shadow:0 7px 0 #205054,0 12px 20px rgba(10,52,54,.15);}.home.hj-menu a:hover .hj-menu-art svg{transform:rotate(-3deg) scale(1.035);}}
.hj-menu-art svg{transition:transform .22s ease;}
.home.hj-menu a:active{transform:translateY(3px) scale(.985);box-shadow:0 1px 0 #205054,0 2px 5px rgba(10,52,54,.12);transition-duration:.07s;}
.home.hj-menu a:focus-visible{outline:3px solid #ffc96c;outline-offset:5px;}

/* Original skyline, with the bridge reduced to a quarter of the scene width. */
.hj-original-town{position:absolute;bottom:0;left:0;width:365px;height:34px;overflow:hidden;}
.hj-small-bridge{position:absolute;bottom:0;right:0;width:130px;height:27px;overflow:hidden;}

/* Stage 30: scenery proportions and calm button feedback. */
.hj-cloud{width:16px;height:6px;}
.hj-cloud:before{width:9px;height:9px;left:2px;top:-4px;}
.hj-cloud:after{width:7px;height:7px;left:8px;top:-3px;}
.hj-small-bridge{width:145px;height:28px;}
.hj-skyline:after{content:"";position:absolute;bottom:0;left:0;right:0;height:1px;background:#9abe76;}
.home.hj-menu a:active{transform:translateY(2px) scale(.99);}
.home.hj-menu a:hover .hj-menu-art svg{transform:none;}
.hj-page-heading{margin:0 0 40px;}
.hj-blackboard-date{display:block;width:max-content;max-width:100%;margin:30px 35px 20px auto;writing-mode:vertical-rl;text-orientation:mixed;white-space:nowrap;color:#faf8e9;font-family:"UD Digi Kyokasho N-R","Yu Kyokasho","Yu Mincho",serif;font-size:25px;font-weight:400;line-height:1.6;letter-spacing:.15em;text-shadow:0 0 .65px rgba(255,255,245,.65);pointer-events:none;}
@media(min-width:1280px){.hj-blackboard-date{position:absolute;top:155px;right:clamp(22px,calc((100vw - 980px)/4 - 20px),140px);margin:0;font-size:27px;}}
@media(max-width:1279px){.hj-blackboard-date{font-size:21px;letter-spacing:.1em;}}

/* Stage 31: preserve the complete original town; enlarge only when space permits. */
.hj-header .hj-header-inner{width:calc(100% - 40px);min-width:980px;max-width:1082px;}
.hj-skyline{width:calc(100% - 470px);max-width:612px;}
.hj-original-town{width:71.56862745%;height:40.8px;}
.hj-small-bridge{width:28.43137255%;height:33.6px;}
.hj-original-town,.hj-small-bridge{overflow:visible;}

/* Stage 32: no extra baseline atop the header border. */
.hj-skyline:after{display:none;}
@font-face{font-family:HJChalk;src:url('../fonts/hj-chalk-date.woff') format('woff');font-weight:400;font-style:normal;font-display:block;}
#hj-blackboard-date{display:none;position:absolute;top:155px;right:24px;margin:0;width:max-content;max-width:none;font-family:HJChalk; font-size:30px;line-height:1.4;letter-spacing:.06em;font-weight:400;color:#fffdf0;text-shadow:none;-webkit-text-stroke:.25px #fffdf0;filter:url(#hj-chalk-grain);visibility:hidden;}
#hj-blackboard-date.hj-date-ready{display:block;}
#hj-blackboard-date.hj-date-ready.hj-date-fits{visibility:visible;}
