@charset "UTF-8";
:root{--ink:#244a3c;--red:#ad3a29;--paper:#f6f1e6;--white:#fffef9;--line:#244a3c30;--sans:"Noto Sans JP","Hiragino Kaku Gothic ProN",Meiryo,sans-serif;--rail:190px;--edge:60px}
*{box-sizing:border-box}html{scroll-behavior:smooth;scroll-padding-top:40px}body{margin:0;background:var(--white);color:var(--ink);font-family:var(--sans);font-size:15px;line-height:2;overflow-x:clip}a{color:inherit;text-decoration:none}button{font:inherit;color:inherit;cursor:pointer;background:none;border:0}h1,h2,h3,p,figure{margin:0}h1,h2,h3{font-family:var(--sans);font-weight:600}h2{font-size:clamp(30px,3.1vw,46px);line-height:1.65;letter-spacing:.025em}a:focus-visible,button:focus-visible,iframe:focus-visible{outline:3px solid var(--red);outline-offset:5px}.skip{position:fixed;z-index:100;top:-100px;background:var(--ink);color:#fff;padding:10px}.skip:focus{top:0}main,footer{margin-left:var(--rail);margin-right:var(--edge)}.section{padding:100px 7%}.eyebrow{font-size:12px;font-weight:700;letter-spacing:.06em;margin-bottom:24px;display:flex;align-items:center;gap:13px}.eyebrow:before{content:"";width:20px;height:2px;background:var(--red)}
/* The fixed rail and vertical headline retain the Japanese editorial direction. */
.rail{position:fixed;inset:0 auto 0 0;width:var(--rail);z-index:20;padding:36px 22px;display:flex;flex-direction:column;align-items:center;background:var(--white)}.brand{display:flex;flex-direction:column;align-items:center}.brand-name{font-family:var(--sans);font-size:20px;font-weight:700;white-space:nowrap}.brand-sub{font-size:9px;letter-spacing:.02em;margin-top:5px}.rail nav{margin-block:auto;display:flex;flex-direction:column;gap:21px;padding-top:45px;width:100%}.rail nav a{font-size:12px;position:relative;padding-left:16px}.rail nav a:before{content:"";position:absolute;left:0;top:10px;width:5px;height:5px;background:var(--red);opacity:0;transform:rotate(45deg)}.rail nav a:hover:before,.rail nav a.is-current:before{opacity:1}.rail-bottom{writing-mode:vertical-rl;align-self:flex-start;font-size:10px;letter-spacing:.14em;margin-top:35px}.menu-button{display:none}.fixed-contact{position:fixed;right:0;top:0;width:var(--edge);background:var(--red);color:var(--white);display:flex;flex-direction:column;align-items:center;gap:17px;padding:24px 12px 30px;z-index:25}.fixed-contact>span:first-child{font-size:24px}.fixed-contact>span:last-child{writing-mode:vertical-rl;font-size:13px;letter-spacing:.1em}.fixed-contact:hover{background:#8e3023}
/* One large, accurate abacus takes the place of decorative stock scenes. */
.hero{position:relative;height:min(880px,100svh);min-height:720px;background:var(--paper);overflow:hidden}.hero:before{content:"";position:absolute;width:530px;height:530px;border-radius:50%;background:#e9e0c9;right:-125px;top:65px}.hero-location{position:absolute;top:33px;right:35px;font-size:11px;letter-spacing:.08em}.hero-title{position:absolute;left:8%;top:13%;z-index:2;display:flex;flex-direction:row-reverse;gap:24px}.hero h1{writing-mode:vertical-rl;font-size:clamp(46px,4.9vw,73px);line-height:1.7;letter-spacing:.1em;white-space:nowrap}.hero h1>span{display:block;animation:ink-arrive 1s ease both}.hero h1>span:last-child{margin-top:85px;animation-delay:.15s}.hero-title>p{writing-mode:vertical-rl;font-family:var(--sans);font-size:16px;letter-spacing:.12em;padding-top:10px}.hero-art{position:absolute;width:77%;left:37%;top:38%;transform:rotate(-23deg);transform-origin:center}.hero-art svg{display:block;width:100%;overflow:visible;filter:drop-shadow(0 16px 0 #55452a0b)}.hero-five{animation:five-arrive 1.1s cubic-bezier(.22,1,.36,1) both;animation-delay:calc(.4s + var(--delay))}.hero-ones{animation:ones-arrive 1.1s cubic-bezier(.22,1,.36,1) both;animation-delay:calc(.4s + var(--delay))}.hero-scroll{position:absolute;left:8%;bottom:125px;display:flex;align-items:center;gap:25px;font-size:12px}.hero-scroll span{font-size:25px;transition:transform .25s}.hero-scroll:hover span{transform:translateY(5px)}.hero-footer{position:absolute;inset:auto 0 0;height:70px;display:flex;align-items:center;justify-content:space-between;gap:15px;padding:0 6%;border-top:1px solid var(--line);background:var(--white);font-size:12px}.hero-footer a{font-weight:700}.hero-footer a span{padding-left:18px;font-size:20px}
.introduction{display:grid;grid-template-columns:1fr 1fr;gap:9%;padding-block:120px}.intro-heading h2{font-size:clamp(30px,3.2vw,48px)}.intro-copy{padding-top:45px;line-height:2.25}.intro-copy p+p{margin-top:24px}.intro-local{font-weight:700;font-size:14px}.text-link{display:inline-flex;align-items:center;justify-content:space-between;gap:35px;padding:8px 0;border-bottom:1px solid var(--ink);margin-top:18px;font-size:13px}.text-link span{font-size:21px}
.lesson{background:var(--ink);color:var(--paper);display:grid;grid-template-columns:.8fr 1.2fr;gap:8%;align-items:center;padding-block:90px}.lesson .eyebrow:before{background:#d7ae6b}.lesson-heading h2{font-size:clamp(46px,5vw,68px);line-height:1.4;margin-bottom:25px}.lesson-heading>p:not(.eyebrow){font-size:14px;line-height:2.15}.number-examples{display:flex;gap:12px;margin:25px 0 16px}.number-examples button{border:1px solid #e7ddc570;padding:2px 13px;font-family:var(--sans);font-size:27px;transition:background .2s,color .2s}.number-examples button span{font-family:var(--sans);font-size:11px;margin-left:5px}.number-examples button[aria-pressed=true]{background:var(--paper);color:var(--ink);border-color:var(--paper)}.number-examples button:hover{border-color:var(--paper)}.example-note{min-height:48px;font-size:12px!important;color:#e3d5b9}.board-instruction{font-size:12px;text-align:center;margin-bottom:25px}.abacus-wrap{max-width:520px;width:100%;margin-inline:auto}.abacus{height:275px;display:flex;gap:5%;padding:18px;position:relative;border:12px solid #8c6442;border-radius:3px;background:#e8dbb5;box-shadow:0 7px 0 #4c3827}.abacus:after{content:"";position:absolute;top:84px;left:0;right:0;height:10px;background:#725134;z-index:3;pointer-events:none;box-shadow:0 2px 0 #4b3124}.abacus-column{flex:1;position:relative}.abacus-column:before{content:"";position:absolute;width:3px;inset:0 auto 0 calc(50% - 1.5px);background:#ac8751}.bead{position:absolute;width:100%;height:30px;clip-path:polygon(0 50%,27% 0,73% 0,100% 50%,73% 100%,27% 100%);background:linear-gradient(#b16642 0 48%,#85442d 49%);z-index:2;padding:0;transition:transform .28s ease}.bead:focus-visible{clip-path:none;outline-color:#ffde89}.bead.heaven{top:0}.bead.heaven.is-active{transform:translateY(36px)}.bead.earth{top:calc(109px + var(--bead-index)*30px)}.bead.earth.is-active{transform:translateY(-31px)}.abacus-caption{display:flex;align-items:center;justify-content:space-between;margin-top:24px;font-size:12px}.abacus-caption output{font-family:var(--sans);font-size:34px;font-variant-numeric:tabular-nums}.abacus-caption button{font-size:12px;text-decoration:underline;text-underline-offset:4px}.board-footnote{font-size:11px;line-height:1.9;margin-top:20px;text-align:center;color:#e3d5b9}.lesson a:focus-visible,.lesson button:focus-visible{outline-color:#e8c887}
.timetable{display:grid;grid-template-columns:.85fr 1.2fr;gap:8%;align-items:center}.timetable-heading h2{font-size:35px}.timetable-heading>p:last-child{font-size:13px;margin-top:24px;line-height:2.15}.schedule{width:100%;border-collapse:collapse;font-size:13px;table-layout:fixed}.schedule caption{position:absolute;width:1px;height:1px;overflow:hidden;clip-path:inset(50%)}.schedule th,.schedule td{border-bottom:1px solid var(--line);padding:19px 0;text-align:center}.schedule thead th{font-weight:500;font-size:12px;border-bottom:1px solid var(--ink)}.schedule th:first-child{width:35%;text-align:left}.schedule tbody th{font-size:13px;font-weight:600}.schedule th a{display:block}.schedule th a span{font-size:12px;margin-left:5px;color:var(--red)}.schedule td{color:#9bada2;font-size:10px}.schedule td>span{color:var(--red);font-size:13px}.schedule-note{font-size:11px;line-height:1.8;margin-top:18px}
.classrooms{padding-top:45px}.section-heading{padding-bottom:30px}.section-heading .eyebrow{margin-bottom:12px}.school{display:grid;grid-template-columns:.7fr 1.3fr;gap:6%;padding:37px 0;border-top:1px solid var(--line);scroll-margin-top:25px}.school-number{font-family:var(--sans);font-style:italic;font-size:18px;color:var(--red);display:block;margin-bottom:15px}.school h3{font-size:29px;line-height:1.5;letter-spacing:.015em}.school-address{font-size:13px;line-height:1.9;margin-top:18px}.school-days{margin-top:25px;display:flex;align-items:center;gap:25px}.school-days>span{font-size:11px}.school-days strong{font-size:22px;font-weight:500}.school-days i{font-style:normal;font-size:14px;color:var(--red)}.school-map{display:block;width:100%;height:265px;border:0;background:#e4e5dc}.school-location>a{display:flex;justify-content:space-between;align-items:center;margin-top:8px;font-size:12px}.school-location>a>span{font-size:21px}.school-location>a:hover{text-decoration:underline;text-underline-offset:5px}
.guide{background:var(--paper);padding-block:70px}.guide-layout{display:grid;grid-template-columns:1fr 1fr;gap:10%}.guide h2{font-size:30px;line-height:1.8}.guide-layout>div>p{font-size:14px;line-height:2.1}.guide-layout>div>p+p{margin-top:18px}.contact{display:flex;align-items:center;justify-content:space-between;gap:5%;padding-block:75px;background:var(--ink);color:var(--paper)}.contact .eyebrow{color:#dbc28e;font-weight:500}.contact .eyebrow:before{background:#dbc28e}.contact h2{font-size:29px}.contact-number>p{font-size:12px}.phone{display:block;font-family:var(--sans);font-size:clamp(27px,3.2vw,46px);line-height:1.7;white-space:nowrap}.phone span{font-size:25px}.contact-help{font-size:10px!important;color:#dddccf}.contact a:focus-visible{outline-color:#e8c887}footer{display:flex;align-items:center;gap:30px;padding:42px 7%;flex-wrap:wrap}.footer-brand{font-family:var(--sans);font-size:21px;font-weight:600}footer p,footer>a{font-size:10px}footer small{font-size:10px;flex-basis:100%;color:#6b7c70}.back-top{margin-left:auto;white-space:nowrap}
@keyframes ink-arrive{from{opacity:0;translate:0 16px}to{opacity:1;translate:0 0}}@keyframes five-arrive{from{translate:0 19px}to{translate:0 0}}@keyframes ones-arrive{from{translate:0 -12px}to{translate:0 0}}
@media(min-width:1600px){:root{--rail:220px;--edge:75px}.section{padding-inline:9%}.hero-art{top:34%;left:36%;width:74%}.hero h1{font-size:80px}}
@media(max-width:1150px){:root{--rail:165px;--edge:50px}.rail{padding-inline:14px}.brand-name{font-size:18px}.rail nav a{font-size:11px}.section{padding-inline:6%}.hero h1{font-size:53px}.hero-title{left:6%;gap:15px}.hero-art{top:38%;left:36%;width:90%}.intro-heading h2{font-size:32px}.intro-copy{font-size:14px}.lesson{gap:6%;grid-template-columns:.85fr 1.15fr}.lesson-heading h2{font-size:49px}.abacus{padding:12px;border-width:9px;gap:4%}.abacus:after{top:78px}.abacus{height:263px}.timetable{gap:5%;grid-template-columns:.75fr 1.25fr}.timetable-heading h2{font-size:29px}.schedule th:first-child{width:38%}.school h3{font-size:25px}.guide h2{font-size:26px}.contact h2{font-size:26px}.phone{font-size:32px}}
@media(max-width:900px){:root{--rail:0px;--edge:0px}html{scroll-padding-top:100px}.rail{height:78px;bottom:auto;width:100%;padding:10px 5%;flex-direction:row;justify-content:space-between;border-bottom:1px solid var(--line)}.brand{display:grid;grid-template-columns:39px auto;column-gap:12px}.brand-name{font-size:19px}.brand-sub{font-size:9px}.menu-button{display:flex;align-items:center;gap:10px;font-size:11px;padding:10px 0}.menu-lines{width:21px;height:12px;border-block:1px solid var(--ink)}.rail nav{display:none;position:absolute;top:78px;left:0;right:0;padding:25px 6%;margin:0;background:var(--white);gap:20px;border-bottom:1px solid var(--line)}.rail nav.is-open{display:flex}.rail nav a{font-size:14px}.rail-bottom{display:none}main{padding-top:78px}.fixed-contact{width:auto;top:auto;bottom:14px;right:14px;padding:10px 18px;flex-direction:row;gap:10px;transform:translateY(100px);opacity:0;pointer-events:none;transition:transform .25s,opacity .25s}.past-hero .fixed-contact{transform:none;opacity:1;pointer-events:auto}.fixed-contact>span:last-child{writing-mode:horizontal-tb;letter-spacing:0;font-size:12px}.fixed-contact>span:first-child{font-size:18px}.hero{height:calc(100svh - 78px);min-height:690px;max-height:830px}.hero h1{font-size:59px}.hero-title{left:8%;top:12%}.hero-art{left:36%;top:38%;width:78%}.section{padding:80px 7%}.introduction{gap:7%}.lesson{gap:7%}.timetable{grid-template-columns:1fr;gap:30px}.timetable-heading{display:grid;grid-template-columns:1fr 1fr;column-gap:7%}.timetable-heading .eyebrow{grid-column:1/-1}.timetable-heading>p:last-child{margin-top:5px}.schedule th:first-child{width:35%}.school{scroll-margin-top:90px}.phone{font-size:36px}.contact{padding-inline:6%}footer{padding-bottom:90px}}
@media(max-width:600px){.rail{height:72px}.rail nav{top:72px}.brand-name{font-size:17px}.brand-sub{font-size:8px}.brand{column-gap:10px}.menu-button{font-size:10px}main{padding-top:72px}.hero{height:calc(100svh - 72px);min-height:685px;max-height:810px}.hero:before{width:310px;height:310px;right:-110px;top:180px}.hero-location{top:20px;right:6%;font-size:10px}.hero-title{top:65px;left:8%;gap:17px}.hero h1{font-size:46px;line-height:1.65;letter-spacing:.07em}.hero h1>span:last-child{margin-top:60px}.hero-title>p{font-size:12px}.hero-art{width:111%;left:33%;top:52%;transform:rotate(-29deg)}.hero-scroll{left:8%;bottom:159px;gap:18px;font-size:11px;max-width:150px}.hero-scroll span{font-size:22px}.hero-footer{height:76px;padding:10px 7%;align-items:flex-start;justify-content:center;flex-direction:column;gap:0;font-size:10px}.hero-footer a{font-size:12px}.hero-footer a span{font-size:16px}.section{padding:65px 7%}.eyebrow{font-size:11px;margin-bottom:22px}.introduction{grid-template-columns:1fr;gap:30px}.intro-heading h2{font-size:32px}.intro-copy{padding-top:0;font-size:15px;line-height:2.2}.desktop-break{display:none}.intro-copy p+p{margin-top:22px}.intro-local{font-size:13px}.lesson{display:flex;flex-direction:column;align-items:stretch;gap:32px}.lesson-heading h2{font-size:47px;margin-bottom:20px}.lesson-heading>p:not(.eyebrow){font-size:14px}.number-examples{margin-top:23px}.number-examples button{padding:3px 15px}.example-note{min-height:0}.board-instruction{font-size:11px;margin-bottom:18px}.abacus{height:259px}.abacus-caption{margin-top:21px;font-size:11px}.abacus-caption button{font-size:11px}.board-footnote{font-size:10px;margin-top:16px;text-align:left}.timetable-heading{display:block}.timetable-heading h2{font-size:30px}.timetable-heading>p:last-child{margin-top:22px;font-size:13px}.schedule th:first-child{width:35%}.schedule tbody th{font-size:12px}.schedule th a span{margin-left:0;font-size:10px}.schedule th,.schedule td{padding-block:17px}.schedule-note{font-size:10px}.classrooms{padding-top:20px}.section-heading h2{font-size:33px}.school{grid-template-columns:1fr;gap:23px;padding:30px 0}.school-info{display:grid;grid-template-columns:32px 1fr;column-gap:10px}.school-number{font-size:16px;margin:4px 0 0;grid-row:1/4}.school h3{font-size:27px}.school-address{font-size:13px;margin-top:12px;grid-column:2}.school-days{margin-top:14px;grid-column:2;gap:22px}.school-days strong{font-size:20px}.school-map{height:240px}.school-location>a{font-size:11px}.guide-layout{grid-template-columns:1fr;gap:25px}.guide h2{font-size:27px}.guide-layout>div>p{font-size:14px}.contact{flex-direction:column;align-items:flex-start;gap:28px}.contact h2{font-size:29px}.phone{font-size:clamp(29px,8.3vw,43px)}.phone span{font-size:22px}.contact-help{font-size:10px}.contact-number{width:100%}footer{padding:35px 7% 90px;gap:20px}footer>div{flex-basis:100%}footer>a{font-size:9px}.footer-brand{font-size:22px}.fixed-contact{bottom:10px;right:10px}.fixed-contact>span:last-child{font-size:11px}}
@media(prefers-reduced-motion:reduce){html{scroll-behavior:auto}*,*:before,*:after{animation:none!important;transition:none!important}}

/* Noto Sans JP: restrained heading weight and tighter tracking. */
body{font-weight:400}.hero h1{font-weight:500;letter-spacing:.04em}.hero-title>p{font-weight:500}.brand-name,.footer-brand{font-weight:600;letter-spacing:-.025em}h2,h3{letter-spacing:0}.phone{font-weight:500;letter-spacing:-.035em;font-variant-numeric:tabular-nums}.school-number{font-style:normal;font-weight:500}.abacus-caption output{font-weight:500}.number-examples button{font-weight:500}
@media(max-width:600px){.guide h2{font-size:25px}.hero h1{letter-spacing:.035em}}

/* Photo stage: the existing abacus remains in the foreground. */
.hero{isolation:isolate}
.hero-photos{position:absolute;inset:0 0 70px;z-index:-2;background:var(--paper);overflow:hidden}
.hero-photo{position:absolute;inset:0;opacity:0;visibility:hidden;transform:translateX(3%);transition:opacity 1.6s ease,transform 2.2s cubic-bezier(.2,.7,.25,1),visibility 1.6s;will-change:opacity,transform}
.hero-photo.is-active{opacity:1;visibility:visible;transform:translateX(0)}
.hero-photo img{display:block;width:100%;height:100%;object-fit:cover;object-position:60% center;transform:scale(1.09)}
.hero-photo.is-active img{animation:photo-journey 9s linear both}
.hero:before{inset:0 0 70px;width:auto;height:auto;border-radius:0;background:linear-gradient(90deg,#f6f1e6ed 0%,#f6f1e6db 22%,#f6f1e657 57%,#f6f1e617 100%),linear-gradient(0deg,#f6f1e6df,transparent 40%);z-index:-1;pointer-events:none}
.hero-title{z-index:3}.hero-location,.hero-scroll,.hero-footer{z-index:3}
.hero-art{z-index:2;translate:0 var(--hero-shift,0px)}
.hero-art svg{filter:drop-shadow(0 22px 14px #33251324);animation:abacus-drift 8s ease-in-out infinite}

.hero-slideshow{position:absolute;right:6%;bottom:96px;z-index:4;display:flex;gap:10px;align-items:center;flex-wrap:wrap;justify-content:flex-end}
.slide-count{font-size:12px;font-weight:600;margin-right:5px;font-variant-numeric:tabular-nums}.slide-count i{font-style:normal;font-weight:400;opacity:.65;margin-left:5px}
.slide-dot{padding:10px 0;width:34px;min-height:36px;display:grid;align-items:center}.slide-dot>span{height:3px;background:#244a3c40;position:relative;overflow:hidden}.slide-dot>span:after{content:"";position:absolute;inset:0;background:var(--red);transform:scaleX(0);transform-origin:left}.slide-dot.is-active>span:after{animation:slide-progress 7s linear both}.slideshow-paused .slide-dot.is-active>span:after{animation:none;transform:scaleX(1)}
.slide-pause{width:36px;height:36px;border:1px solid #244a3c60;border-radius:50%;font-size:14px;line-height:1;background:#fffef95e}.slide-pause:hover{background:var(--white)}
.photo-disclosure{font-size:9px;flex-basis:100%;text-align:right;line-height:1.4}
.hero.is-offscreen .hero-art svg,.hero.is-offscreen .hero-photo img{animation-play-state:paused}
.slideshow-paused .hero-photo img{animation-play-state:paused}
/* Progressive enhancement: content stays visible without JavaScript. */
.motion-ready [data-reveal]{opacity:0;transform:translate3d(0,32px,0);transition:opacity .95s ease,transform 1.15s cubic-bezier(.16,1,.3,1),clip-path 1.3s cubic-bezier(.16,1,.3,1);transition-delay:var(--reveal-delay,0ms)}
.motion-ready [data-reveal="heading"]{transform:translate3d(0,24px,0)}
.motion-ready [data-reveal="map"]{transform:translate3d(24px,0,0)}
.motion-ready [data-reveal="board"]{transform:translate3d(0,48px,0) rotate(3deg) scale(.95);transform-origin:center}
.motion-ready [data-reveal="row"]{transform:translate3d(20px,0,0)}
.motion-ready [data-reveal].is-revealed{opacity:1;transform:none;clip-path:inset(0)}
.motion-ready .eyebrow:before{transform:scaleX(0);transform-origin:left;transition:transform .8s cubic-bezier(.16,1,.3,1) .15s}
.motion-ready .eyebrow.is-revealed:before{transform:scaleX(1)}
.text-link,.school-location>a{transition:gap .25s,color .25s}.text-link:hover{gap:48px;color:var(--red)}
@keyframes photo-journey{from{transform:scale(1.09) translateX(-.5%)}to{transform:scale(1.015) translateX(.5%)}}
@keyframes abacus-drift{0%,100%{transform:translateY(0) rotate(0)}50%{transform:translateY(-12px) rotate(.7deg)}}
@keyframes slide-progress{to{transform:scaleX(1)}}
@media(max-width:900px){.hero-slideshow{right:6%;bottom:96px}}
@media(max-width:600px){.hero-photos{bottom:76px}.hero:before{bottom:76px;background:linear-gradient(90deg,#f6f1e6e8,#f6f1e6ba 35%,#f6f1e626),linear-gradient(0deg,#f6f1e6d9,transparent 50%)}.hero-photo img{object-position:62% center}.hero-slideshow{bottom:92px;right:6%;gap:7px;max-width:170px}.slide-count{font-size:10px}.slide-dot{width:26px}.slide-pause{width:32px;height:32px}.photo-disclosure{font-size:8px}.hero-scroll{bottom:158px}.hero-art{top:49%}.motion-ready [data-reveal]{transform:translate3d(0,24px,0)}.motion-ready [data-reveal="map"]{transform:none}.motion-ready [data-reveal].is-revealed{transform:none}}
@media(prefers-reduced-motion:reduce){.motion-ready [data-reveal]{opacity:1;transform:none;clip-path:none;transition:none}.motion-ready .eyebrow:before{transform:none}.hero-art{translate:none}.hero-art svg,.hero-photo img,.slide-dot.is-active>span:after{animation:none}.slide-dot.is-active>span:after{transform:scaleX(1)}}

.motion-ready [data-reveal="heading"].is-revealed{animation:heading-unveil 1.2s cubic-bezier(.16,1,.3,1) var(--reveal-delay,0ms) both}.motion-ready [data-reveal="map"].is-revealed{animation:map-unveil 1.35s cubic-bezier(.16,1,.3,1) var(--reveal-delay,0ms) both}
@keyframes heading-unveil{from{clip-path:inset(0 0 100% 0)}to{clip-path:inset(0)}}@keyframes map-unveil{from{clip-path:inset(0 100% 0 0)}to{clip-path:inset(0)}}

/* Editorial benefit stories: photographs, practice diagram and outcome notes. */
.introduction{display:block;padding-block:110px}
.intro-heading{position:static;display:grid;grid-template-columns:1fr 1fr;column-gap:8%;align-items:end;margin-bottom:72px}
.intro-heading .eyebrow{grid-column:1/-1}
.intro-heading h2{font-size:clamp(28px,3vw,44px);line-height:1.65}
.benefits-lead{font-size:14px;line-height:2.2;max-width:32em;margin:0;padding-bottom:5px}
.benefits-stories{display:grid;gap:86px}
.learning-benefit{display:grid;grid-template-columns:1.08fr 1fr;gap:7%;align-items:center;min-width:0}
.benefit-media{margin:0;min-width:0}
.benefit-photo img{display:block;width:100%;height:auto;aspect-ratio:1.12;object-fit:cover;object-position:62% center}
.benefit-photo figcaption{display:flex;flex-wrap:wrap;justify-content:space-between;gap:4px 12px;font-size:11px;line-height:1.8;margin-top:12px}
.benefit-photo figcaption span{font-size:10px;color:#6a766c}
.benefit-text{min-width:0}
.benefit-label{display:flex;align-items:center;gap:15px;font-size:12px;font-weight:600;color:var(--red);margin:0 0 18px}
.benefit-label>span{font-size:25px;font-weight:400;line-height:1;border-right:1px solid #c4c9bb;padding-right:15px}
.learning-benefit h3{font-size:clamp(21px,2vw,29px);line-height:1.7;font-weight:600;margin:0 0 20px}
.benefit-text>p:not(.benefit-label){font-size:14px;line-height:2.15;margin:0}
.benefit-text>p.benefit-outcome{margin-top:23px;padding:16px 0 0;border-top:1px solid var(--line)}
.benefit-outcome:before{content:'勉強へのつながり';display:block;color:var(--red);font-size:11px;font-weight:500;letter-spacing:.05em;margin-bottom:6px}
.benefit-02{grid-template-columns:1fr 1.08fr}
.benefit-02 .benefit-media{grid-column:2;grid-row:1}
.benefit-02 .benefit-text{grid-column:1;grid-row:1}
.benefit-03 .benefit-photo img{aspect-ratio:1.15;object-position:67% center}
.practice-diagram{background:#e8ecdf;padding:34px 28px;color:var(--ink)}
.practice-diagram>figcaption{font-size:17px;font-weight:500;margin-bottom:27px}

.benefits-footer{margin-top:58px;text-align:right}

.lesson-heading h2{font-size:clamp(31px,3.2vw,47px);line-height:1.6}
.lesson-heading .lesson-tip{font-size:12px!important;margin-top:16px;color:#e3d5b9}
@media(max-width:1150px){.intro-heading h2{font-size:30px}.learning-benefit{gap:5%}.practice-diagram{padding:28px 20px}.lesson-heading h2{font-size:clamp(28px,2.8vw,32px)}}
@media(max-width:900px){.introduction{padding-block:80px}.intro-heading{gap:14px 6%;margin-bottom:48px}.intro-heading h2{font-size:29px}.benefits-lead{font-size:13px}.benefits-stories{gap:65px}.lesson-heading h2{font-size:31px}}
@media(max-width:700px){.intro-heading{grid-template-columns:1fr;gap:0;margin-bottom:38px}.intro-heading h2{font-size:32px}.benefits-lead{font-size:14px;margin-top:20px}.learning-benefit{grid-template-columns:1fr;gap:26px}.benefit-02 .benefit-media,.benefit-02 .benefit-text{grid-column:auto;grid-row:auto}.benefit-photo img,.benefit-03 .benefit-photo img{aspect-ratio:1.4}.benefit-label{margin-bottom:14px}.learning-benefit h3{font-size:25px}.benefit-text>p:not(.benefit-label){font-size:15px}.benefits-stories{gap:55px}.practice-diagram{padding:28px}.benefits-footer{margin-top:34px}.lesson-heading h2{font-size:34px}}
@media(max-width:380px){.practice-diagram{padding:24px 18px}.intro-heading h2{font-size:29px}.learning-benefit h3{font-size:23px}}

/* Clear first-screen routes and an unobtrusive mobile contact shortcut. */
.hero{min-height:820px}
.hero-title{top:8%}
.hero-intro{position:absolute;left:8%;bottom:118px;z-index:4;max-width:84%}
.hero-intro>p{font-size:16px;font-weight:500;line-height:1.9}
.hero-intro>p>span{font-size:12px;font-weight:400}
.hero-actions{display:flex;align-items:center;flex-wrap:wrap;gap:12px 25px;margin-top:18px}
.primary-link{display:inline-flex;align-items:center;justify-content:space-between;gap:25px;min-height:48px;padding:10px 19px;background:var(--ink);color:var(--white);font-size:13px;transition:background .2s}
.primary-link:hover{background:#38604d}
.hero-benefits-link{font-size:12px;padding-block:10px;border-bottom:1px solid var(--ink);display:inline-flex;gap:18px;align-items:center}
.hero:before{background:linear-gradient(90deg,#f6f1e6ef 0%,#f6f1e6d9 25%,#f6f1e645 60%,#f6f1e617 100%),linear-gradient(0deg,#f6f1e6 0%,#f6f1e6e6 16%,transparent 50%)}
.contact-label-mobile{display:none}
.guide{padding-block:90px}
.guide-intro{display:grid;grid-template-columns:1fr 1fr;gap:8%;align-items:end;margin-bottom:48px}
.guide-intro>p{font-size:14px;line-height:2.2;padding-bottom:5px}
.guide h2{font-size:clamp(27px,3vw,38px)}
.enrollment-layout{display:grid;grid-template-columns:.85fr 1.15fr;gap:8%;align-items:start}
.enrollment-layout h3{font-size:17px;margin-bottom:25px;font-weight:500}
.inquiry-flow ol{list-style:none;padding:0;margin:0}
.inquiry-flow li{display:flex;gap:20px;padding:22px 0;border-top:1px solid var(--line)}
.inquiry-flow li>span{font-size:20px;color:var(--red);line-height:1.7;font-weight:400}
.inquiry-flow h4{font-size:15px;font-weight:500;margin:0 0 8px}
.inquiry-flow li p{font-size:13px;line-height:2}
.inquiry-flow .text-link{font-size:12px;margin-top:8px;padding-block:4px}
.phone-memo{padding:21px 23px;margin-top:15px;background:#fffef9}
.phone-memo>p{font-size:11px;color:var(--red)}
.phone-memo blockquote{margin:10px 0;font-size:13px;line-height:2}
.enrollment-faq details{border-top:1px solid var(--line)}
.enrollment-faq details:last-child{border-bottom:1px solid var(--line)}
.enrollment-faq summary{cursor:pointer;display:flex;align-items:center;justify-content:space-between;gap:18px;list-style:none;font-size:14px;font-weight:500;padding:22px 0;line-height:1.9}
.enrollment-faq summary::-webkit-details-marker{display:none}
.enrollment-faq summary:after{content:'+';font-size:23px;line-height:1;font-weight:400;color:var(--red);flex-shrink:0}
.enrollment-faq details[open] summary:after{content:'−'}
.enrollment-faq details>div{padding:0 28px 22px 0;font-size:13px;line-height:2.15}
.enrollment-faq summary:focus-visible{outline:2px solid var(--red);outline-offset:4px}
.enrollment-faq .text-link{font-size:12px;margin-top:8px}
@media(max-width:1150px){.hero-intro{left:6%;max-width:88%}.hero-actions{gap:15px}.enrollment-layout{gap:6%}}
@media(max-width:900px){.hero{min-height:810px;max-height:none}.hero-title{top:7%}.hero-intro{left:7%;bottom:118px}.hero-slideshow{bottom:85px}.fixed-contact{padding:9px 13px;gap:6px;min-height:44px;border-radius:2px;bottom:max(10px,env(safe-area-inset-bottom));right:10px}.fixed-contact>span:first-child{font-size:16px}.fixed-contact>span:last-child{font-size:11px}.contact-label-desktop{display:none}.contact-label-mobile{display:inline}.past-hero .fixed-contact.is-context-hidden{opacity:0;visibility:hidden;pointer-events:none;transform:translateY(80px)}.guide-intro{gap:6%}.guide-intro>p{font-size:13px}.enrollment-layout{gap:7%}}
@media(max-width:700px){.guide-intro,.enrollment-layout{grid-template-columns:1fr;gap:30px}.guide-intro{margin-bottom:38px}.guide-intro>p{font-size:14px}.enrollment-layout{gap:44px}.enrollment-layout h3{font-size:18px;margin-bottom:18px}.enrollment-faq summary{font-size:14px}.enrollment-faq details>div{font-size:14px}.inquiry-flow li p{font-size:14px}.phone-memo blockquote{font-size:14px}}
@media(max-width:600px){.hero{min-height:775px}.hero-title{top:57px}.hero h1{font-size:42px}.hero-art{top:43%;left:38%;width:107%}.hero-intro{bottom:124px;left:7%;max-width:86%}.hero-intro>p{font-size:15px}.hero-intro>p>span{display:block;font-size:12px;line-height:1.85;max-width:24em;margin-top:5px}.hero-intro>p>br{display:none}.hero-actions{align-items:flex-start;gap:10px;margin-top:14px}.primary-link{font-size:12px;min-height:46px;padding:9px 14px;gap:16px}.hero-benefits-link{font-size:11px;gap:10px;padding-block:8px}.hero-slideshow{bottom:84px}.hero-footer{flex-direction:row;align-items:center;justify-content:space-between;font-size:9px;gap:10px}.hero-footer p{max-width:15em;line-height:1.8}.hero-footer a{font-size:10px;white-space:nowrap}.hero-footer a span{padding-left:5px}.guide{padding-block:65px}}

.benefit-01 .benefit-photo img{aspect-ratio:1.5;object-position:center}.benefit-03 .benefit-photo img{object-position:50% center}
@media(max-width:900px){.fixed-contact{line-height:1.5}}
@media(max-width:600px){.hero-art{top:29%}.hero-intro{bottom:152px}}

/* Practice habits, without promising automatic transfer to other subjects. */
.practice-diagram>figcaption{font-size:22px;line-height:1.7;margin-bottom:24px}
.learning-habits{list-style:none;padding:0;margin:0}
.learning-habits li{display:flex;gap:17px;align-items:center;padding:25px 0;border-top:1px solid #cbd3c2}
.habit-icon{flex:0 0 42px;color:var(--ink)}
.habit-icon svg{display:block;width:100%;stroke:currentColor;stroke-width:1.5;stroke-linecap:round;stroke-linejoin:round}
.learning-habits strong{display:block;font-size:16px;font-weight:500;line-height:1.8}
.learning-habits p{font-size:12px;line-height:1.9;margin-top:6px}
.habit-caption{font-size:13px;line-height:1.9;border-top:1px solid #cbd3c2;padding-top:20px;color:#52664e}
.benefit-text>p.habit-body{margin-top:15px}
.benefit-02 .benefit-outcome:before{content:'ご家庭の学習でも'}
@media(max-width:1150px){.learning-habits li{gap:13px}.habit-icon{flex-basis:35px}.learning-habits strong{font-size:15px}}
@media(max-width:700px){.practice-diagram>figcaption{font-size:23px}.learning-habits strong{font-size:16px}}

/* Text-only school identity, sized for the side rail and mobile header. */
.brand{display:flex;flex-direction:column;align-items:flex-start;gap:7px;min-width:0;padding-block:4px;line-height:1.4}
.brand-name{font-size:22px;font-weight:600;letter-spacing:.025em}
.brand-sub{font-size:9px;letter-spacing:.02em;margin:0}
@media(min-width:901px) and (max-width:1150px){.brand-name{font-size:20px}}
@media(max-width:900px){.brand{gap:5px}.brand-name{font-size:22px}.brand-sub{font-size:10px}}
@media(max-width:600px){.brand-name{font-size:20px}.brand-sub{font-size:9px}}

/* Compact editorial navigation for the top-right menu. */
@media(max-width:900px){
.menu-button{min-height:44px;min-width:104px;padding:10px 15px;gap:12px;border:1px solid #244a3c40;border-radius:28px;background:#f6f1e6;font-size:11px;line-height:1;letter-spacing:.07em;justify-content:center;transition:background .25s,color .25s,border-color .25s}
.menu-button:hover{border-color:var(--ink);background:#e8ecdf}
.menu-button[aria-expanded=true]{background:var(--ink);border-color:var(--ink);color:var(--white)}
.menu-lines{position:relative;width:19px;height:14px;border:0;flex-shrink:0}
.menu-lines:before,.menu-lines:after{content:'';position:absolute;left:0;height:1px;background:currentColor;transition:transform .3s,width .3s,top .3s}
.menu-lines:before{top:3px;width:19px}.menu-lines:after{top:10px;width:13px}
.menu-button:hover .menu-lines:after{width:19px}
.menu-button[aria-expanded=true] .menu-lines:before{top:6px;transform:rotate(45deg)}
.menu-button[aria-expanded=true] .menu-lines:after{top:6px;width:19px;transform:rotate(-45deg)}
.rail nav{top:calc(100% + 10px);left:14px;right:14px;width:auto;padding:24px 28px 28px;gap:0;background:var(--white);border:1px solid #244a3c25;border-radius:4px 4px 18px 18px;box-shadow:0 18px 40px #142e2426;max-height:calc(100dvh - 110px);overflow-y:auto;overscroll-behavior:contain;counter-reset:menu-item}
.rail nav:before{content:'宮村速算学院';font-size:11px;font-weight:500;letter-spacing:.1em;color:#6b7c70;padding-bottom:17px;border-bottom:1px solid var(--line)}
.rail nav.is-open{animation:menu-unfold .3s cubic-bezier(.16,1,.3,1) both}
.rail nav a{display:grid;grid-template-columns:25px 1fr 20px;align-items:center;gap:13px;padding:18px 0;font-size:15px;font-weight:500;line-height:1.65;border-bottom:1px solid var(--line);counter-increment:menu-item;transition:color .2s}
.rail nav a:before{content:counter(menu-item,decimal-leading-zero);position:static;width:auto;height:auto;background:none;opacity:1;transform:none;color:var(--red);font-size:10px;font-weight:400;letter-spacing:.03em}
.rail nav a:after{content:'↗';font-size:19px;font-weight:400;text-align:right;transition:transform .2s}
.rail nav a:hover,.rail nav a.is-current{color:var(--red)}
.rail nav a:hover:after{transform:translate(2px,-2px)}
.rail nav a:focus-visible{outline-offset:0}
}
@keyframes menu-unfold{from{opacity:0;transform:translateY(-10px)}to{opacity:1;transform:translateY(0)}}
@media(max-width:380px){.menu-button{min-width:92px;padding-inline:12px;gap:9px}.rail nav{padding:20px}.rail nav a{font-size:14px;gap:10px}}
@media(prefers-reduced-motion:reduce){.rail nav.is-open{animation:none}}

/* Readable body copy and secondary information at every screen width. */
body{font-size:16px}
.brand-sub,.rail-bottom,.hero-location,.slide-count,.photo-disclosure,.benefit-photo figcaption span,footer small{font-size:12px}
.brand{max-width:100%}.brand-sub{line-height:1.6}
.eyebrow,.benefit-label,.benefit-outcome:before,.phone-memo>p{font-size:13px}
.benefits-lead,.benefit-text>p:not(.benefit-label),.lesson-heading>p:not(.eyebrow),.timetable-heading>p:last-child,.guide-intro>p,.inquiry-flow li p,.phone-memo blockquote,.enrollment-faq details>div,.school-address{font-size:16px;line-height:2}
.text-link,.school-location>a,.learning-habits p,.habit-caption,.benefit-photo figcaption,.board-instruction,.board-footnote,.abacus-caption,.abacus-caption button,.number-examples button span,.schedule-note,.school-days>span,.contact-number>p,.inquiry-flow .text-link,.enrollment-faq .text-link,footer p,footer>a{font-size:14px;line-height:1.9}
.lesson-heading .lesson-tip,.example-note{font-size:14px!important}
.contact-help{font-size:14px!important;line-height:1.8}
.learning-habits strong,.enrollment-faq summary,.inquiry-flow h4{font-size:16px}
.schedule,.schedule thead th,.schedule tbody th{font-size:15px}
.schedule td,.schedule td>span,.schedule th a span{font-size:14px}
.schedule td{color:#6b7c70}
.schedule th a{line-height:1.8}
.schedule-note{line-height:1.9}
.hero-intro>p{font-size:17px}.hero-intro>p>span,.primary-link,.hero-benefits-link,.hero-footer,.hero-footer a{font-size:14px}
.hero-footer{line-height:1.7}
.benefit-photo figcaption span{color:#55664f}
.hero-slideshow{max-width:220px}
@media(min-width:901px){.rail nav a{font-size:14px;padding-left:12px}.rail{padding-inline:18px}:root{--rail:210px}}
@media(min-width:1600px){:root{--rail:220px}}
@media(max-width:900px){
.menu-button{font-size:13px;letter-spacing:0;min-width:108px}
.rail nav:before,.rail nav a:before{font-size:12px}.rail nav a{font-size:16px}
.fixed-contact>span:last-child{font-size:13px}
.hero-footer{font-size:13px}
}
@media(max-width:600px){
.hero{min-height:870px}.hero-art{top:26%}
.hero-intro>p{font-size:16px}.hero-intro>p>span{font-size:14px;max-width:24em}
.hero-actions{gap:12px 16px}.primary-link{font-size:14px}.hero-benefits-link{font-size:14px}
.hero-footer{gap:10px;font-size:12px}.hero-footer p{max-width:14em}.hero-footer a{font-size:12px;white-space:normal;flex-shrink:0}
.hero-slideshow{max-width:200px}.photo-disclosure,.slide-count{font-size:12px}
.schedule th:first-child{width:110px}.schedule th a{display:flex;align-items:center;gap:3px}.schedule th a span{margin:0;flex-shrink:0}
.abacus-caption{flex-wrap:wrap;gap:8px 14px}.number-examples{gap:10px}.number-examples button{padding-inline:12px}
footer{gap:18px}.back-top{margin-left:0}
}
@media(max-width:380px){.menu-button{min-width:98px;padding-inline:10px}.brand-sub{font-size:12px;letter-spacing:0}.hero{min-height:910px}.hero-art{top:25%}.hero-footer p{max-width:12em}.hero-footer a{max-width:10em}}
.number-examples{max-width:330px}.number-examples button{display:inline-flex;flex-direction:column;align-items:center;justify-content:center;flex:1;min-width:0;padding:10px 12px;line-height:1.4}.number-examples button span{margin-left:0;white-space:nowrap}

/* Generous touch targets without enlarging the decorative controls. */
.slide-dot{width:36px;min-height:44px}
.slide-pause{width:44px;height:44px;flex-shrink:0}
#reset-abacus{min-height:44px;padding:8px 4px}
.hero-slideshow{max-width:230px}
.school{scroll-margin-top:16px}
@media(max-width:900px){.fixed-contact{bottom:calc(14px + env(safe-area-inset-bottom,0px))}}

/* Mobile inquiry stays within reach throughout the page. */
@media(max-width:900px){
html{scroll-padding-bottom:100px}
body{padding-bottom:calc(84px + env(safe-area-inset-bottom,0px))}
.fixed-contact,.past-hero .fixed-contact{left:max(16px,calc((100% - 520px)/2));right:max(16px,calc((100% - 520px)/2));bottom:calc(14px + env(safe-area-inset-bottom,0px));top:auto;width:auto;min-height:56px;padding:14px 24px;flex-direction:row-reverse;justify-content:center;gap:24px;border:1px solid #fffef940;border-radius:32px;box-shadow:0 6px 22px #61251d30,0 0 0 7px #fffef9e8;opacity:1;visibility:visible;pointer-events:auto;transform:none;animation:contact-enter .7s .35s cubic-bezier(.16,1,.3,1) backwards;transition:background .2s,transform .2s,opacity .2s}
.fixed-contact>span:last-child{font-size:16px;font-weight:600;letter-spacing:.04em}
.fixed-contact>span:first-child{font-size:23px;line-height:1;animation:contact-arrow 2.5s 1.2s 3}
.fixed-contact:active{transform:scale(.98)}
.fixed-contact.is-context-hidden,.past-hero .fixed-contact.is-context-hidden{opacity:0;visibility:hidden;pointer-events:none;transform:translateY(100px)}
}
@keyframes contact-enter{from{opacity:0;transform:translateY(90px)}to{opacity:1;transform:translateY(0)}}
@keyframes contact-arrow{0%,70%,100%{transform:translate(0,0)}35%{transform:translate(3px,-3px)}}
@media(prefers-reduced-motion:reduce){.fixed-contact,.fixed-contact>span:first-child{animation:none!important;transition:none!important}}
@media(max-width:600px){.hero-slideshow{gap:7px;max-width:220px}.slide-dot{width:32px}}

/* Floating mobile inquiry button over the page, without a background strip. */
.page-scroll{display:contents}
@media(max-width:900px){
html,body{height:100%;overflow:hidden;scroll-padding:0}
body{--mobile-header:78px;--contact-dock:calc(84px + env(safe-area-inset-bottom,0px));padding-bottom:0}
.page-scroll{display:block;position:fixed;inset:var(--mobile-header) 0 0;overflow-y:auto;overflow-x:hidden;scroll-behavior:smooth;scroll-padding-top:20px;scroll-padding-bottom:var(--contact-dock);overscroll-behavior-y:contain}
.page-scroll main{padding-top:0}
.page-scroll footer{padding-bottom:calc(35px + var(--contact-dock))}
.fixed-contact,.past-hero .fixed-contact{border:0;box-shadow:0 4px 14px #61251d30}
.rail nav{max-height:calc(100dvh - var(--mobile-header) - var(--contact-dock) - 20px)}
}
@media(max-width:600px){body{--mobile-header:72px}}
@media(prefers-reduced-motion:reduce){.page-scroll{scroll-behavior:auto}}

/* Compose the mobile hero for a narrow screen rather than cropping the desktop stage. */
@media(max-width:600px){
.hero-photos{inset:0 0 auto;height:560px}
.hero-photo img{object-position:78% center;transform:scale(1.02)}
.hero-photo.is-active img{animation-name:mobile-photo-journey}
.hero:before{inset:0 0 auto;height:565px;background:linear-gradient(90deg,#f6f1e6e6 0%,#f6f1e6a6 28%,#f6f1e61a 60%,transparent),linear-gradient(0deg,var(--paper),#f6f1e600 32%)}
.hero-art{width:90%;left:8%;top:41%;transform:rotate(-14deg)}
}
@media(max-width:380px){.hero-photos{height:550px}.hero:before{height:555px}.hero-art{top:40%;width:92%;left:6%}}
@keyframes mobile-photo-journey{from{transform:scale(1.025)}to{transform:scale(1)}}

/* Let the photograph fade into the title's negative space. */
.hero-title{color:#173d30}
.hero-title>p{font-weight:500}
.hero-location{color:#173d30;font-weight:500;letter-spacing:.12em}
@media(max-width:600px){
.hero:before{background:linear-gradient(90deg,#f6f1e6fa 0%,#f6f1e6eb 24%,#f6f1e6d9 46%,#f6f1e661 66%,#f6f1e600 88%),linear-gradient(180deg,#f6f1e6b3,transparent 18%),linear-gradient(0deg,var(--paper),#f6f1e600 32%)}
.hero-location{top:24px;left:7%;right:auto;font-size:11px;letter-spacing:.15em}
.hero-title{top:70px;left:7%;gap:15px}
.hero h1{font-size:38px;font-weight:500;line-height:1.7;letter-spacing:.08em}
.hero h1>span:last-child{margin-top:52px}
.hero-title>p{font-size:12px;letter-spacing:.17em;padding-top:6px}
}
