/* Shared fixed navigation, including Safari safe area. */
:root{--site-header-height:72px;--site-header-offset:calc(var(--site-header-height) + env(safe-area-inset-top,0px))}html{scroll-padding-top:calc(var(--site-header-offset) + 18px)}body{padding-top:var(--site-header-offset)}body>.header{position:fixed;inset:0 0 auto 0;z-index:1000;width:100%;max-width:none;margin:0;height:var(--site-header-offset);padding:calc(12px + env(safe-area-inset-top,0px)) max(24px,calc((100% - 1160px)/2)) 12px;box-sizing:border-box;display:flex;align-items:center;justify-content:space-between;gap:12px;background:#f2f5f9;border-bottom:2px solid #d9f36e;box-shadow:0 3px 15px #182d480a}body>.header .brand-lockup{display:flex;align-items:center;gap:11px;min-width:0;text-decoration:none;color:#182d48;flex-shrink:0}body>.header .brand-lockup img{display:block;width:40px;height:40px;flex-shrink:0}body>.header .brand-copy{display:block;color:#182d48;font-family:system-ui,-apple-system,sans-serif;letter-spacing:-.7px;line-height:1.4}body>.header .brand-copy strong{display:block;font-size:21px;font-weight:850}body>.header .brand-copy small{display:block;font-size:9px;font-weight:500;letter-spacing:0;color:#5f6b7a;white-space:nowrap}body>.header .back-link,body>.header>a:not(.brand-lockup){font-size:12px;min-height:44px;display:inline-flex;align-items:center;color:#182d48;text-decoration:none}body>.header .preview-label{font-size:11px;white-space:nowrap}#courses,#finder,.browse,.intro,[id$="-title"]{scroll-margin-top:18px}.skip{z-index:1100}.skip:focus{position:fixed;top:8px}.course-card{scroll-margin-top:18px}@media(max-width:650px){:root{--site-header-height:68px}body>.header{padding:calc(12px + env(safe-area-inset-top,0px)) 18px 12px;gap:7px}body>.header .brand-lockup{gap:8px}body>.header .brand-lockup img{width:33px;height:33px}body>.header .brand-copy strong{font-size:16px}body>.header .brand-copy small{font-size:7.5px}body>.header .preview-label{font-size:9px;padding:4px 6px}body>.header .back-link,body>.header>a:not(.brand-lockup){font-size:10px}body>.header .save-nav{font-size:10px;padding:0}body>.header .save-nav span{width:21px;height:21px;margin-left:3px}}

@font-face{font-family:RunToYou;src:url("/assets/fonts/Outfit-ExtraBold.ttf") format("truetype");font-weight:800;font-style:normal;font-display:swap}body>.header .brand-copy strong{font-family:RunToYou,Arial,sans-serif;font-weight:800;letter-spacing:.65px;font-size:23px;line-height:1.15}body>.header .brand-copy small{margin-top:4px}body>.header .brand-lockup img{object-fit:contain}@media(max-width:650px){body>.header .brand-copy strong{font-size:17px;letter-spacing:.4px}}

/* Keep both discovery actions available while browsing results. */
.header-actions{display:flex;align-items:center;gap:18px;flex-shrink:0}.header-actions .find-again{display:inline-flex;align-items:center;justify-content:center;position:relative;min-height:30px;padding:0 11px;border:1px solid #d9f36e;border-radius:999px;background:#d9f36e;text-decoration:none;color:#182d48;font-size:11px;font-weight:650;white-space:nowrap}.header-actions .find-again:hover{background:#cce85d;border-color:#cce85d}.header-actions .find-again::after{content:"";position:absolute;inset:-7px 0}.header-actions .save-nav{white-space:nowrap}#distance-title:focus{outline:none}@media(max-width:650px){body>.header:has(.header-actions){padding-left:12px;padding-right:12px}.header-actions{gap:10px}.header-actions .find-again{font-size:10px;padding:0 8px}body>.header:has(.header-actions) .brand-copy small{display:block}body>.header:has(.header-actions) .brand-copy strong{font-size:15px;letter-spacing:.2px}body>.header:has(.header-actions) .brand-lockup{gap:6px}body>.header:has(.header-actions) .brand-lockup img{width:30px;height:30px}}

.header-actions .saved-link{display:inline-flex;align-items:center;min-height:44px;color:#182d48;text-decoration:none;font-size:12px}.header-actions .saved-link span{display:inline-grid;place-items:center;width:24px;height:24px;margin-left:5px;border-radius:50%;background:#d9f36e;color:#182d48;font-size:11px}@media(max-width:650px){.header-actions .saved-link{font-size:10px}.header-actions .saved-link span{width:21px;height:21px;margin-left:3px}}

/* Same JA/KO pill control as Haruhanjul, using RUN TO YOU colors. */
.language-toggle{display:inline-flex;align-items:center;gap:2px;padding:3px;border:1px solid #d5dde7;border-radius:999px;background:#e3eaf3;white-space:nowrap;flex-shrink:0}.language-toggle button{position:relative;min-width:32px;border:0;border-radius:999px;background:transparent;color:#5f6b7a;padding:6px 9px;font:inherit;font-size:11px;font-weight:650;line-height:1.2;cursor:pointer}.language-toggle button::after{content:"";position:absolute;inset:-5px 0}.language-toggle button[aria-pressed=true]{background:#182d48;color:#fff;box-shadow:0 1px 3px #182d4830}.language-toggle button:focus-visible{outline:2px solid #182d48;outline-offset:3px}html[lang=ko] .course-card [lang=ja],html[lang=ko] .candidate-ja{display:none}html[lang=ja] .course-card [lang=ja],html[lang=ja] .candidate-ja{display:none}html[lang=ja] body{font-family:-apple-system,BlinkMacSystemFont,"Hiragino Kaku Gothic ProN","Yu Gothic",Meiryo,sans-serif}html[lang=ja] .welcome h1{letter-spacing:-1.5px;font-size:clamp(38px,4.6vw,60px);line-height:1.35}html[lang=ja] .card-body h3,html[lang=ja] .candidate-card h3{line-height:1.55;letter-spacing:0}html[lang=ja] p,html[lang=ja] li{line-height:1.85}html[lang=ja] .header .brand-copy small{line-height:1.4}.header-actions{gap:14px}@media(max-width:650px){.header-actions{gap:7px}.language-toggle{padding:2px}.language-toggle button{min-width:27px;font-size:10px;padding:6px 7px}html[lang=ja] .header-actions .saved-link,html[lang=ja] .header-actions .save-nav{font-size:9px}.header-actions .save-nav span{margin-left:3px}html[lang=ja] .welcome h1{font-size:38px}}@media(max-width:440px){body>.header:has(.language-toggle) .brand-copy{display:block}body>.header:has(.language-toggle){padding-left:12px;padding-right:12px}body>.header:has(.language-toggle) .brand-lockup img{width:32px;height:32px}.header-actions{gap:9px}}

html[lang=ja] h1,html[lang=ja] h2,html[lang=ja] h3,html[lang=ja] .card-description,html[lang=ja] .access-line{word-break:normal;overflow-wrap:anywhere;line-break:strict}html[lang=ja] .intro h1{letter-spacing:0;line-height:1.45}html[lang=ja] .detail-heading{flex-wrap:wrap;gap:10px}

/* Mobile: brand + language on row one, discovery actions on row two. */
@media(max-width:650px){
 :root{--site-header-height:104px}
 body>.header:has(.language-toggle){display:grid;grid-template-columns:minmax(0,1fr);grid-template-rows:40px 32px;align-content:center;row-gap:6px;padding:calc(10px + env(safe-area-inset-top,0px)) 14px 10px}
 body>.header:has(.language-toggle) .brand-lockup{grid-row:1;justify-self:start;gap:8px;max-width:calc(100% - 72px)}
 body>.header:has(.language-toggle) .brand-lockup img{width:32px;height:32px}
 body>.header:has(.language-toggle) .brand-copy{display:block;min-width:0}
 body>.header:has(.language-toggle) .brand-copy strong{display:block;font-size:18px;letter-spacing:.3px}
 body>.header:has(.language-toggle) .brand-copy small{display:block;margin-top:4px;font-size:8px;line-height:1.4;letter-spacing:0;white-space:normal;word-break:keep-all}
 body>.header:has(.language-toggle) .header-actions{grid-row:2;justify-self:end;justify-content:flex-end;gap:14px}
 body>.header:has(.language-toggle) .language-toggle{position:absolute;right:14px;top:calc(14px + env(safe-area-inset-top,0px))}
 body>.header:has(.language-toggle) .header-actions .save-nav{font-size:11px}
 body>.header:has(.language-toggle) .header-actions .find-again{font-size:11px;padding:0 11px}
 body>.header:has(.language-toggle)>.back-link,body>.header:has(.language-toggle)>.preview-label{grid-row:2;justify-self:end}
}

@media(max-width:650px){body input[type=search],body input[type=text],body select{font-size:16px}}

/* Keep primary map controls on one row, including narrow phones. */
.location-actions{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:8px}
.location-actions .primary,.location-actions .secondary{min-width:0;width:100%;padding:10px 6px;font-size:13px;white-space:nowrap}
.location-actions #stop-follow{grid-column:1/-1}
