:root{--mh-app-safe-bottom:env(safe-area-inset-bottom,0px)}
@media (display-mode:standalone){
  body{padding-bottom:var(--mh-app-safe-bottom)}
}
.mh-install-button{
  position:fixed;right:18px;bottom:calc(18px + var(--mh-app-safe-bottom));z-index:9998;
  appearance:none;border:1px solid rgba(23,61,80,.22);border-radius:999px;
  background:rgba(252,251,247,.96);color:#173d50;padding:10px 16px;
  font:600 12px/1.2 system-ui,-apple-system,"Noto Sans JP",sans-serif;
  letter-spacing:.04em;box-shadow:0 10px 30px rgba(23,61,80,.16);cursor:pointer;
}
.mh-install-button[hidden]{display:none!important}
.mh-ios-tip{
  position:fixed;left:14px;right:14px;bottom:calc(14px + var(--mh-app-safe-bottom));z-index:9999;
  max-width:480px;margin:0 auto;padding:14px 44px 14px 16px;border-radius:14px;
  background:rgba(252,251,247,.98);color:#173d50;border:1px solid rgba(23,61,80,.16);
  box-shadow:0 14px 36px rgba(23,61,80,.18);font:13px/1.65 system-ui,-apple-system,"Noto Sans JP",sans-serif;
}
.mh-ios-tip button{position:absolute;right:10px;top:9px;border:0;background:transparent;color:#173d50;font-size:20px;cursor:pointer}

/* ===== Mobile app navigation / safety onboarding ===== */
html.mh-consent-open, html.mh-consent-open body{overflow:hidden}
.mh-safety-overlay{position:fixed;inset:0;z-index:10050;display:grid;place-items:center;padding:20px;background:rgba(13,34,47,.58);backdrop-filter:blur(8px)}
.mh-safety-card{width:min(100%,620px);max-height:min(88vh,760px);overflow:auto;background:#fffdf8;border:1px solid rgba(65,74,130,.18);border-radius:22px;padding:28px 28px 24px;box-shadow:0 30px 90px rgba(19,39,55,.30);color:#3f4a67;font-family:system-ui,-apple-system,"Noto Sans JP",sans-serif;line-height:1.7;letter-spacing:.02em}
.mh-safety-kicker{font-size:12px;letter-spacing:.12em;color:#777e9e;margin-bottom:7px}
.mh-safety-card h2{font-family:inherit;font-weight:700;font-size:24px;line-height:1.45;margin:0 0 16px;color:#414a82;letter-spacing:.02em}
.mh-safety-card p{font-size:14px;line-height:1.75;margin:0 0 14px}
.mh-safety-alert{margin:16px 0;padding:15px 17px;border-radius:14px;background:#fff6e8;border:1px solid rgba(180,121,38,.20);font-size:13px}
.mh-safety-alert strong{display:block;margin-bottom:7px;color:#715122}
.mh-safety-alert ul{margin:0;padding-left:20px;line-height:1.75}
.mh-safety-example{background:#f4f6fb;border-radius:12px;padding:12px 14px}
.mh-safety-consent{display:flex;align-items:flex-start;gap:10px;margin:18px 0 16px;padding:13px 14px;border:1px solid rgba(65,74,130,.16);border-radius:12px;background:#fff}
.mh-safety-consent input{margin-top:5px;width:18px;height:18px;flex:0 0 auto}
.mh-safety-consent span{font-size:13px;line-height:1.65}
.mh-safety-actions{display:flex;align-items:center;justify-content:space-between;gap:12px;flex-wrap:wrap}
.mh-safety-link{font-size:12px;text-decoration:underline;text-underline-offset:3px}
#mhSafetyStart{appearance:none;border:0;border-radius:999px;padding:12px 20px;background:#414a82;color:white;font-weight:700;font-size:14px;cursor:pointer}
#mhSafetyStart:disabled{opacity:.35;cursor:not-allowed}

.mh-secret-reminder{position:relative;z-index:20;max-width:980px;margin:16px auto 0;padding:11px 16px;border:1px solid rgba(180,121,38,.20);border-radius:12px;background:rgba(255,248,234,.96);color:#6c5430;font:12px/1.65 system-ui,-apple-system,"Noto Sans JP",sans-serif;letter-spacing:.01em}
.mh-secret-reminder a{text-decoration:underline;text-underline-offset:2px}

body{transition:opacity .16s ease,transform .16s ease}
body.mh-page-leaving{opacity:.64;transform:translateY(2px)}

.mh-mobile-nav,.mh-step-nav{display:none}

@media(max-width:760px){
  body{padding-bottom:calc(76px + env(safe-area-inset-bottom,0px))!important}
  .mh-mobile-nav{position:fixed;left:0;right:0;bottom:0;z-index:9996;display:grid;grid-template-columns:repeat(4,1fr);padding:7px 8px calc(7px + env(safe-area-inset-bottom,0px));background:rgba(252,251,247,.97);border-top:1px solid rgba(65,74,130,.14);box-shadow:0 -8px 28px rgba(28,44,68,.10);backdrop-filter:blur(12px);font-family:system-ui,-apple-system,"Noto Sans JP",sans-serif}
  .mh-mobile-nav a,.mh-mobile-nav button{appearance:none;border:0;background:transparent;color:#727892;display:flex;min-height:50px;flex-direction:column;align-items:center;justify-content:center;gap:1px;border-radius:12px;font:inherit;text-decoration:none;cursor:pointer}
  .mh-mobile-nav a.active{background:rgba(65,74,130,.09);color:#414a82}
  .mh-mobile-nav span{font-size:22px;line-height:1.05;font-weight:500}
  .mh-mobile-nav small{font-size:10px;line-height:1.3;letter-spacing:.02em}

  .mh-step-nav{position:fixed;left:10px;right:10px;bottom:calc(72px + env(safe-area-inset-bottom,0px));z-index:9995;display:flex;justify-content:space-between;gap:10px;pointer-events:none}
  .mh-step-nav a{pointer-events:auto;flex:1;max-width:47%;padding:10px 13px;border:1px solid rgba(65,74,130,.16);border-radius:999px;background:rgba(255,255,255,.96);box-shadow:0 8px 24px rgba(30,48,78,.12);color:#414a82;font:600 11px/1.35 system-ui,-apple-system,"Noto Sans JP",sans-serif;text-align:center;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
  .mh-step-next{margin-left:auto}

  .site-header,.nav{position:sticky!important;top:0;z-index:70;min-height:56px;height:auto;padding:8px 14px;background:rgba(252,251,247,.96);backdrop-filter:blur(12px)}
  .navlinks{display:none!important}
  .brand{font-size:28px}
  .mh-secret-reminder{margin:10px 12px 0}
  .mh-install-button{bottom:calc(84px + env(safe-area-inset-bottom,0px));right:12px}
  .mh-ios-tip{bottom:calc(84px + env(safe-area-inset-bottom,0px))}
  .mh-safety-overlay{padding:12px}
  .mh-safety-card{padding:22px 18px 18px;border-radius:18px;max-height:90vh}
  .mh-safety-card h2{font-size:21px}
  .mh-safety-actions{display:grid;grid-template-columns:1fr;align-items:stretch}
  #mhSafetyStart{width:100%;order:-1}
  .mh-safety-link{text-align:center}
}

/* ===== Compact account / hamburger menu ===== */
.mh-account-menu{position:relative;margin-left:auto;z-index:10020;font-family:system-ui,-apple-system,"Noto Sans JP",sans-serif}
.mh-account-trigger{appearance:none;border:1px solid rgba(65,74,130,.16);background:rgba(255,255,255,.84);color:#414a82;border-radius:999px;min-width:76px;height:40px;padding:5px 11px;display:flex;align-items:center;justify-content:center;gap:6px;cursor:pointer;box-shadow:0 5px 18px rgba(45,54,90,.08)}
.mh-account-trigger span{font-size:18px;line-height:1}.mh-account-trigger small{font-size:10px;letter-spacing:.03em}
.mh-account-dropdown{position:absolute;right:0;top:calc(100% + 8px);width:min(270px,calc(100vw - 28px));padding:9px;border-radius:18px;background:rgba(255,253,248,.99);border:1px solid rgba(65,74,130,.15);box-shadow:0 18px 46px rgba(36,47,79,.18);backdrop-filter:blur(14px)}
.mh-account-dropdown[hidden]{display:none!important}
.mh-account-dropdown a{display:flex;align-items:center;min-height:43px;padding:9px 13px;border-radius:11px;color:#414a82;text-decoration:none;font-size:13px;letter-spacing:.02em}
.mh-account-dropdown a:hover,.mh-account-dropdown a:focus-visible{background:rgba(65,74,130,.08);outline:none}
.mh-menu-divider{height:1px;background:rgba(65,74,130,.12);margin:6px 5px}

@media(max-width:760px){
  .site-header,.nav{display:flex!important;flex-direction:row!important;align-items:center!important;justify-content:space-between!important;gap:10px!important}
  .mh-account-menu{display:block;flex:0 0 auto}
  .mh-account-trigger{min-width:44px;width:44px;height:44px;padding:0;border-radius:50%}
  .mh-account-trigger small{display:none}
  .mh-account-trigger span{font-size:21px}

  /* Keep the two playful moving ships on mobile, but scale them down. */
  body[data-page="home"] section.content.note .boundary-moving-logo .moving-ship-link,
  body[data-page="home"] section.content.cta .boundary-moving-logo .moving-ship-link{
    width:68px!important;
    top:-54px!important;
    animation-duration:34s!important;
    will-change:left;
  }
  body[data-page="home"] section.content.note .boundary-moving-logo .moving-ship-link img,
  body[data-page="home"] section.content.cta .boundary-moving-logo .moving-ship-link img{
    width:68px!important;
  }
  @keyframes boundaryShipMoveRightToLeft{
    from{left:calc(100% + 18px)}
    to{left:-90px}
  }
}

/* ===== First-run onboarding wizard ===== */
.mh-onboarding-step{display:none}.mh-onboarding-step.is-active{display:block}
.mh-onboarding-card .text-input{width:100%;box-sizing:border-box;margin-top:6px}
.mh-onboarding-actions{display:flex;justify-content:flex-end;gap:10px;margin-top:20px}
.mh-onboarding-actions button,#mhToProfile{appearance:none;border:0;border-radius:999px;padding:12px 20px;background:#414a82;color:#fff;font-weight:700;font-size:14px;cursor:pointer}
.mh-onboarding-actions button:disabled,#mhToProfile:disabled{opacity:.35;cursor:not-allowed}
.mh-secondary-btn{background:#eef0f6!important;color:#414a82!important}
.mh-howto-list{display:grid;gap:10px;margin:16px 0}.mh-howto-list>div{display:grid;grid-template-columns:150px 1fr;gap:12px;padding:12px 14px;border-radius:13px;background:#f5f6fa}.mh-howto-list strong{color:#414a82}.mh-howto-list span{font-size:13px;line-height:1.6}
@media(max-width:760px){.mh-onboarding-actions{display:grid;grid-template-columns:1fr 1fr}.mh-onboarding-actions button{width:100%}.mh-howto-list>div{grid-template-columns:1fr;gap:4px}}

/* ===== 2026-09-24 Home mobile slide layout ===== */
body[data-page="home"].mh-home-mobile-layout{
  background:linear-gradient(180deg,#f4f4fb 0%,#fcfbf7 18%,#ffffff 100%);
}
body[data-page="home"] .demo-banner{margin-bottom:0}
body[data-page="home"] .hero.mh-app-home-hero{
  min-height:auto;
  display:flex;
  flex-direction:column;
  align-items:center;
  justify-content:center;
  gap:10px;
  padding:28px 20px 18px;
  text-align:center;
  background:transparent;
}
body[data-page="home"] .mh-home-top-icon{display:inline-flex;align-items:center;justify-content:center}
body[data-page="home"] .mh-home-top-icon .hero-full-logo{
  width:min(88px,22vw);
  height:auto;
}
body[data-page="home"] .hero.mh-app-home-hero h1{
  margin:0;
  font-size:clamp(28px,8vw,38px);
  letter-spacing:.06em;
  color:#173d50;
}
body[data-page="home"] .hero.mh-app-home-hero p{
  margin:0;
  max-width:28em;
  font-size:13px;
  line-height:1.7;
  color:#425165;
}
body[data-page="home"] .mh-home-ship-lane{
  position:relative;
  max-width:980px;
  margin:0 auto;
  padding:4px 14px;
  height:92px;
  overflow:hidden;
}
body[data-page="home"] .mh-home-ship-link{
  position:absolute;
  left:calc(100% + 30px);
  top:10px;
  display:flex;
  flex-direction:column;
  align-items:center;
  gap:6px;
  text-decoration:none;
  animation:mhShipCruise 40s linear infinite;
}
body[data-page="home"] .mh-home-ship-lane-second .mh-home-ship-link{animation-delay:3s}
body[data-page="home"] .mh-home-ship-link img{
  width:86px;
  height:auto;
  filter:drop-shadow(0 7px 16px rgba(64,74,130,.16));
}
body[data-page="home"] .mh-home-ship-badge{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  min-height:28px;
  padding:4px 12px;
  border-radius:999px;
  background:rgba(255,255,255,.94);
  border:1px solid rgba(65,74,130,.15);
  box-shadow:0 4px 14px rgba(64,74,130,.08);
  color:#414a82;
  font:700 11px/1.2 system-ui,-apple-system,"Noto Sans JP",sans-serif;
  letter-spacing:.03em;
  white-space:nowrap;
}
@keyframes mhShipCruise{
  from{left:calc(100% + 32px)}
  to{left:-118px}
}
body[data-page="home"] .mh-home-slideshow-wrap{
  max-width:980px;
  margin:0 auto;
  padding:0 16px 10px;
}
body[data-page="home"] .mh-home-slideshow{
  width:100%;
  max-width:460px;
  margin:0 auto;
  aspect-ratio: 11 / 15;
  border-radius:28px;
  overflow:hidden;
  background:#f7f4ef;
  box-shadow:0 18px 50px rgba(23,61,80,.10);
}
body[data-page="home"] .mh-home-slideshow .slide{
  object-fit:cover;
  object-position:center;
}
body[data-page="home"] .mh-home-slideshow .dots{
  left:50%;
  right:auto;
  bottom:14px;
  transform:translateX(-50%);
  background:rgba(255,255,255,.7);
  padding:7px 10px;
  border-radius:999px;
  backdrop-filter:blur(8px);
}
body[data-page="home"] .mh-home-slideshow .dot{
  width:8px;height:8px;border:0;background:#c7ccd7;
}
body[data-page="home"] .mh-home-slideshow .dot.active{background:#414a82}
body[data-page="home"] .mh-home-nav-area{
  max-width:980px;
  margin:6px auto 0;
  padding:12px 16px 22px;
}
body[data-page="home"] .mh-home-nav-area .eyebrow{
  margin-bottom:10px;
  text-align:center;
}
body[data-page="home"] .mh-home-nav-grid{
  display:grid;
  grid-template-columns:repeat(2,minmax(0,1fr));
  gap:10px;
}
body[data-page="home"] .mh-home-nav-grid a{
  display:flex;
  align-items:center;
  justify-content:center;
  min-height:46px;
  padding:10px 12px;
  border-radius:16px;
  background:#fff;
  border:1px solid rgba(65,74,130,.12);
  box-shadow:0 8px 24px rgba(32,45,78,.06);
  color:#414a82;
  text-decoration:none;
  font:600 13px/1.4 system-ui,-apple-system,"Noto Sans JP",sans-serif;
}
body[data-page="home"] footer{
  margin-top:0;
}
@media(max-width:760px){
  body[data-page="home"]{padding-bottom:0!important}
  body[data-page="home"] .mh-mobile-nav{display:none!important}
}

/* final mobile home top bar */
body[data-page="home"] .mh-app-topbar{
  position:sticky!important;top:0;z-index:10010;
  display:flex!important;align-items:center!important;justify-content:space-between!important;
  min-height:54px;height:auto;padding:7px 12px!important;
  background:rgba(252,251,247,.94);backdrop-filter:blur(12px);
  border-bottom:1px solid rgba(65,74,130,.10);
}
body[data-page="home"] .mh-app-topbar .brand{font-size:20px;letter-spacing:.04em}

/* ===== 2026-09-24 Mobile app home: ivory + moving gradient waves ===== */
body[data-page="home"].mh-home-mobile-layout{
  background:#FCFAF5!important;
}
body[data-page="home"] .mh-app-topbar{
  background:rgba(252,250,245,.95)!important;
}
body[data-page="home"] .hero.mh-app-home-hero{
  gap:8px!important;
  padding:26px 20px 20px!important;
}
body[data-page="home"] .mh-home-top-icon .hero-full-logo{
  width:min(122px,31vw)!important;
  height:auto;
  filter:none!important;
}
body[data-page="home"] .hero.mh-app-home-hero h1{
  margin-top:2px!important;
}
body[data-page="home"] .mh-home-tagline{
  font-family:"Zen Old Mincho","Yu Mincho","Hiragino Mincho ProN",serif;
  font-size:clamp(17px,4.7vw,21px);
  font-weight:500;
  letter-spacing:.10em;
  color:#39445a;
  line-height:1.7;
}
body[data-page="home"] .hero.mh-app-home-hero p{
  margin-top:4px!important;
  max-width:32em!important;
  font-size:13px!important;
  line-height:1.85!important;
}

body[data-page="home"] .mh-home-ship-lane{
  position:relative;
  width:100%;
  max-width:none;
  height:118px;
  margin:0;
  padding:0;
  overflow:hidden;
}
body[data-page="home"] .mh-home-ship-route{
  position:absolute;
  left:100%;
  top:8px;
  display:flex;
  align-items:center;
  justify-content:center;
  width:62vw;
  min-width:250px;
  max-width:390px;
  height:102px;
  text-decoration:none;
  cursor:pointer;
  touch-action:manipulation;
  animation:mhWaveShipCruise 40s linear infinite;
}
body[data-page="home"] .mh-home-ship-lane-second .mh-home-ship-route{
  animation-delay:3s;
}
body[data-page="home"] .mh-home-route-ship{
  position:relative;
  z-index:2;
  flex:0 0 auto;
  width:104px;
  height:auto;
  pointer-events:none;
}
body[data-page="home"] .mh-home-wave{
  position:relative;
  z-index:1;
  flex:1 1 0;
  min-width:62px;
  height:34px;
  pointer-events:none;
  -webkit-mask-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 240 40'%3E%3Cpath d='M0 22 C20 8 40 8 60 22 S100 36 120 22 S160 8 180 22 S220 36 240 22' fill='none' stroke='black' stroke-width='6' stroke-linecap='round'/%3E%3C/svg%3E");
  mask-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 240 40'%3E%3Cpath d='M0 22 C20 8 40 8 60 22 S100 36 120 22 S160 8 180 22 S220 36 240 22' fill='none' stroke='black' stroke-width='6' stroke-linecap='round'/%3E%3C/svg%3E");
  -webkit-mask-repeat:no-repeat;
  mask-repeat:no-repeat;
  -webkit-mask-position:center;
  mask-position:center;
  -webkit-mask-size:100% 100%;
  mask-size:100% 100%;
}
body[data-page="home"] .blue-route .mh-home-wave{
  background:linear-gradient(90deg,
    rgba(169,216,243,0) 0%,
    rgba(169,216,243,.34) 18%,
    rgba(255,255,255,.94) 50%,
    rgba(169,216,243,.34) 82%,
    rgba(169,216,243,0) 100%);
}
body[data-page="home"] .pink-route .mh-home-wave{
  background:linear-gradient(90deg,
    rgba(244,183,200,0) 0%,
    rgba(244,183,200,.34) 18%,
    rgba(255,255,255,.94) 50%,
    rgba(244,183,200,.34) 82%,
    rgba(244,183,200,0) 100%);
}
body[data-page="home"] .mh-home-ship-route:active{opacity:.72}
body[data-page="home"] .mh-home-ship-route:focus-visible{
  outline:3px solid rgba(65,74,130,.35);
  outline-offset:3px;
  border-radius:999px;
}
@keyframes mhWaveShipCruise{
  from{transform:translateX(0)}
  to{transform:translateX(calc(-100vw - 100%))}
}

body[data-page="home"] .mh-home-copy-block{
  max-width:620px;
  margin:0 auto;
  padding:2px 24px 18px;
  text-align:center;
}
body[data-page="home"] .mh-home-copy-block p{
  margin:0;
  color:#425165;
  font-size:13px;
  line-height:1.95;
}
body[data-page="home"] .mh-home-copy-block-short{
  padding-top:0;
  padding-bottom:26px;
}
body[data-page="home"] .mh-home-copy-block-short p{
  font-family:"Zen Old Mincho","Yu Mincho","Hiragino Mincho ProN",serif;
  font-size:17px;
  line-height:1.9;
  letter-spacing:.07em;
  color:#39445a;
}
body[data-page="home"] .mh-home-slideshow-wrap{
  padding-top:0!important;
}

@media (prefers-reduced-motion: reduce){
  body[data-page="home"] .mh-home-ship-route{
    animation:none!important;
    position:relative;
    left:auto;
    margin:0 auto;
  }
}
