/* Desktop composition is the visual source of truth. Keep a real device viewport,
   but stop narrow screens from swapping to unrelated stacked/cropped layouts. */
html{-webkit-text-size-adjust:100%;text-size-adjust:100%}
body.world-home{overflow-x:hidden}

@media(max-width:1120px){
  /* Stable iOS/iPadOS hero: svh avoids browser-chrome jumps. */
  body.world-home .portal-hero{height:calc(100svh + 11.5vw)!important;min-height:0!important;max-height:none!important}
  body.world-home .portal-hero-bg,body.world-home .portal-hero-video,body.world-home .portal-hero::after,body.world-home .hero-noise{width:100%!important;height:100%!important}
  body.world-home .portal-hero-video{object-fit:cover!important;object-position:center center!important}
  body.world-home .hero-game-title{width:clamp(300px,48vw,650px)!important;max-width:82vw!important;transform:translateY(calc(-9vh - 3vw))!important}

  /* Use the same paper-wave geometry as desktop instead of the 150% mobile crop. */
  body.world-home main>.world-paper-chapter{position:relative!important;isolation:isolate!important;z-index:7!important;overflow:visible!important;margin-top:-12.95vw!important;padding-top:clamp(150px,13vw,270px)!important;padding-bottom:clamp(175px,16vw,340px)!important;background:none!important}
  body.world-home main>.world-paper-chapter::before{content:""!important;display:block!important;position:absolute!important;left:0!important;top:-.213vw!important;width:100%!important;height:max(190px,47.42vw)!important;background:url('./assets/world/paper-wave-transition-original-004104.png?v=1') center top/100% 100% no-repeat!important;filter:brightness(.978) hue-rotate(-1.5deg) saturate(.982)!important;pointer-events:none!important;z-index:0!important}
  body.world-home main>.world-paper-chapter::after{content:none!important;display:none!important}
  body.world-home main>.world-paper-chapter>*{position:relative!important;z-index:2!important}
  body.world-home main>.world-about{margin-top:calc(-1 * clamp(115px,17vw,330px))!important;padding-top:clamp(155px,20vw,410px)!important}

  /* About remains one four-card strip, like desktop. */
  body.world-home .world-about .world-about-inner{width:min(94vw,1520px)!important;max-width:1520px!important}
  body.world-home .world-about h2{font-size:clamp(23px,3.2vw,34px)!important}
  body.world-home .world-about h2::before{width:clamp(58px,7.3vw,78px)!important;height:clamp(58px,7.3vw,78px)!important;background-size:clamp(46px,5.8vw,61px) clamp(46px,5.8vw,61px)!important;bottom:calc(100% + 6px)!important}
  body.world-home .world-about .world-about-description{width:min(82vw,820px)!important;margin-top:clamp(18px,2.1vw,26px)!important;font-size:clamp(12px,1.55vw,16px)!important}
  body.world-home .world-about .world-about-stats{width:min(92vw,1520px)!important;grid-template-columns:repeat(4,minmax(0,1fr))!important;margin-top:clamp(34px,4.4vw,56px)!important}
  body.world-home .world-about .about-stat,body.world-home .world-about .about-stat:nth-child(2),body.world-home .world-about .about-stat:nth-child(3),body.world-home .world-about .about-stat:nth-child(4){min-height:clamp(112px,16vw,188px)!important;padding:clamp(12px,2vw,24px) clamp(6px,1.2vw,18px)!important;border-right:1px solid rgba(126,216,255,.66)!important;border-bottom:0!important}
  body.world-home .world-about .about-stat:last-child{border-right:0!important}
  body.world-home .world-about .about-stat-icon{width:clamp(42px,6.7vw,80px)!important;height:clamp(31px,4.7vw,55px)!important;margin-bottom:clamp(6px,1vw,11px)!important}
  body.world-home .world-about .about-stat strong{font-size:clamp(9px,1.55vw,17px)!important}
  body.world-home .world-about .about-stat span{font-size:clamp(8px,1.2vw,14px)!important}

  /* Ecosystem keeps the two desktop cards beside each other. */
  body.world-home .world-ecosystem{width:min(94vw,1320px)!important;padding-top:clamp(28px,3.2vw,40px)!important;padding-bottom:clamp(58px,7vw,105px)!important}
  body.world-home .world-ecosystem .world-section-title>div::before{width:clamp(58px,7.3vw,82px)!important;height:clamp(58px,7.3vw,82px)!important}
  body.world-home .world-ecosystem .world-section-title h2{font-size:clamp(24px,3.4vw,40px)!important}
  body.world-home .world-ecosystem .world-ecosystem-grid{grid-template-columns:repeat(2,minmax(0,1fr))!important;gap:clamp(10px,1.8vw,24px)!important}
  body.world-home .world-ecosystem .world-game-card{aspect-ratio:1.72/1!important;min-height:0!important}
  body.world-home .world-ecosystem .world-game-card>img:not(.ecosystem-card-logo){transform:scale(1.27)!important;transform-origin:left center!important}
  body.world-home .world-ecosystem .world-game-card>.ecosystem-card-logo{width:48%!important;height:34%!important;bottom:6%!important}
  body.world-home .world-ecosystem .world-tiktok-link>.ecosystem-card-logo{width:40%!important;height:30%!important;bottom:7%!important}

  /* Token block stays centred on the same desktop axis. */
  body.world-home .world-panorama{height:clamp(620px,70vw,1100px)!important;padding-bottom:0!important}
  body.world-home .world-panorama::before{background-position:center 54%!important;background-size:cover!important}
  body.world-home .world-panorama .token-callout{top:clamp(72px,7.1vw,128px)!important;left:50%!important;width:min(86vw,760px)!important;transform:translateX(-50%)!important}
  body.world-home .world-panorama .token-callout::before{width:clamp(58px,7.3vw,82px)!important;height:clamp(58px,7.3vw,82px)!important;margin:0 auto 2px!important}
  body.world-home .world-panorama .token-callout-title{font-size:clamp(28px,4.3vw,58px)!important;white-space:nowrap!important}
  body.world-home .world-panorama .token-callout-copy{max-width:min(72vw,610px)!important;font-size:clamp(12px,1.5vw,16px)!important}

  /* Follow section keeps the desktop three-button row. */
  body.world-home .world-community{min-height:56.25vw!important}
  body.world-home .world-community .community-social-block{left:50%!important;bottom:clamp(92px,9.2vw,188px)!important;width:min(82vw,720px)!important;transform:translateX(-50%)!important}
  body.world-home .world-community .community-social-block .community-links{display:grid!important;grid-template-columns:repeat(3,minmax(0,1fr))!important;gap:clamp(7px,1.2vw,14px)!important;width:100%!important}
  body.world-home .world-community .community-social-block .community-links>a{width:100%!important;min-width:0!important;max-width:none!important;flex:none!important}
}

@media(max-width:760px){
  /* Header stays usable on touch, while matching the desktop visual weight. */
  .portal-header,.portal-nav{height:64px!important}.mobile-menu{top:64px!important;max-height:calc(100svh - 64px)!important}
  .portal-nav.shell{width:calc(100% - 24px)!important;padding-left:max(0px,env(safe-area-inset-left))!important;padding-right:max(0px,env(safe-area-inset-right))!important}
  body.world-home .hero-game-title{width:min(76vw,520px)!important;max-width:76vw!important;transform:translateY(calc(-7vh - 2.5vw))!important}

  /* Preserve the illustrated panel's desktop left-copy/right-character composition. */
  body.world-home .world-paper-chapter .world-welcome{width:calc(100% - 18px)!important;max-width:none!important}
  body.world-home .welcome-card,body.world-home .welcome-card-body{min-height:clamp(330px,92vw,440px)!important;padding:0!important;display:block!important}
  body.world-home .welcome-card::before{display:block!important;background-size:auto 100%!important;background-position:left top!important}
  body.world-home .welcome-card::after{display:block!important;left:-14px!important;top:-22px!important;width:clamp(82px,25vw,118px)!important;height:clamp(98px,30vw,143px)!important}
  body.world-home .welcome-card-bar{position:absolute!important;top:clamp(46px,13vw,65px)!important;left:6%!important;right:38%!important;min-height:clamp(42px,11vw,54px)!important;margin:0!important;padding:0 8px!important;font-size:clamp(16px,5vw,22px)!important}
  body.world-home .welcome-copy{position:relative!important;z-index:10!important;width:61%!important;max-width:none!important;padding:clamp(108px,31vw,145px) 8px 24px clamp(23px,7vw,34px)!important;text-align:left!important}
  body.world-home .welcome-copy::before{margin:0 0 9px!important;font-size:clamp(12px,3.5vw,16px)!important}
  body.world-home .welcome-copy p:not(.world-kicker){max-width:100%!important;margin:5px 0 7px!important;font-size:clamp(9.5px,2.75vw,12px)!important;line-height:1.34!important}
  body.world-home .welcome-copy .world-button{width:auto!important;min-width:0!important;min-height:38px!important;height:38px!important;margin-top:9px!important;padding:0 12px!important;border-width:3px!important;border-radius:11px!important;font-size:10px!important}
  body.world-home .welcome-note{display:none!important}
  body.world-home .welcome-card-body::after{content:""!important;display:block!important;position:absolute!important;z-index:7!important;right:1%!important;bottom:-9%!important;width:clamp(185px,50vw,265px)!important;margin:0!important;aspect-ratio:1086/1448!important;background:url('./assets/world/babyt-adventure-party.png?v=1') center bottom/contain no-repeat!important}

  body.world-home .world-about .world-about-stats{width:96vw!important}
  body.world-home .world-ecosystem{width:calc(100% - 24px)!important}
  body.world-home .world-ecosystem .world-ecosystem-grid{gap:10px!important}
  body.world-home .world-panorama{height:clamp(560px,145vw,780px)!important}
  body.world-home .world-panorama .token-callout{top:clamp(58px,15vw,82px)!important;width:94vw!important}
  body.world-home .world-panorama .token-callout-title{font-size:clamp(25px,7vw,34px)!important}
  body.world-home .world-panorama .token-callout-copy{max-width:82vw!important;font-size:clamp(10px,2.7vw,12px)!important}
  body.world-home .world-community{min-height:68vw!important}
  body.world-home .world-community .community-social-block{bottom:clamp(54px,12vw,82px)!important;width:88vw!important}
  body.world-home .world-community .community-social-block h2::after{font-size:clamp(18px,5vw,23px)!important}
  body.world-home .world-community .community-social-block .community-copy::after{font-size:clamp(9px,2.5vw,11px)!important}
  body.world-home .world-community .community-social-block .community-links>a{height:40px!important;min-height:40px!important;border-radius:12px!important}
}

/* Keep the cleaned original TikTok silhouette, but make it just a touch larger than the 18px pass. */
body.world-home .world-community .community-social-block .community-links>a.tiktok-link>svg{
  display:none!important;
}
body.world-home .world-community .community-social-block .community-links>a.tiktok-link::after{
  content:""!important;
  display:block!important;
  position:relative!important;
  z-index:1!important;
  width:19px!important;
  height:19px!important;
  background:transparent url('./assets/icons/tiktok-clean.svg?v=2') center/contain no-repeat!important;
  -webkit-mask:none!important;
  mask:none!important;
  pointer-events:none!important;
}
@media(max-width:760px){
  body.world-home .world-community .community-social-block .community-links>a.tiktok-link::after{
    width:19px!important;
    height:19px!important;
  }
}
