/* Windows keep their frame and commands still; only the content collection scrolls. */
.ac-world-shell:not([data-ac-route=home]):not([data-ac-route=play]) #screen-host{width:min(1120px,calc(100vw - 80px));overflow:hidden;padding:0}
.ac-world-shell:not([data-ac-route=home]):not([data-ac-route=play]) #screen-host>.ac-frame,
.ac-world-shell #screen-host>.ac-community{height:100%;min-height:0;max-width:none}
.ac-world-shell #screen-host>.ac-community>.ac-frame{height:100%;min-height:0}
.ac-world-shell:not([data-ac-route=home]):not([data-ac-route=play]) #screen-host .ac-frame__surface{height:100%;min-height:0;display:flex;flex-direction:column;padding:22px 24px}
.ac-world-shell:not([data-ac-route=home]):not([data-ac-route=play]) #screen-host .ac-frame__header{flex:0 0 auto;margin-bottom:16px;padding-bottom:12px;border-bottom:1px solid var(--ac-line)}
.ac-world-shell:not([data-ac-route=home]):not([data-ac-route=play]) #screen-host .ac-frame__body{flex:1;min-height:0;overflow:hidden}
.ac-world-shell #screen-host .ac-community-content{height:100%;min-height:0;display:flex;flex-direction:column;overflow:hidden;gap:12px}
.ac-world-shell #screen-host .ac-community-content>.ac-community-columns{flex:1;min-height:0}
.ac-world-shell .ac-community-columns>.ac-community-section,.ac-world-shell .ac-community-columns>.ac-community-stack{min-height:0;overflow:auto}
.ac-world-shell .ac-community-form{display:flex;flex-direction:column;min-height:0}
.ac-world-shell .ac-community-form-fields{min-height:0;overflow:auto;display:grid;gap:10px;overscroll-behavior:contain;padding:2px 6px 6px 2px}
.ac-world-shell .ac-community-form>button[type=submit]{flex:0 0 auto;align-self:flex-start}
.ac-world-shell .ac-community-content>.ac-community-form{flex:1;min-height:0}
.ac-world-shell .ac-community-content>.ac-community-form>.ac-community-form-fields{flex:1;min-height:0}
.ac-world-shell .ac-community-columns{gap:20px;grid-template-rows:minmax(0,1fr);align-items:stretch}
.ac-world-shell .ac-community-columns>.ac-community-section{max-height:100%;display:flex;flex-direction:column;overflow:hidden}
.ac-world-shell .ac-community-columns>.ac-community-section>.ac-community-form{flex:1;min-height:0}
.ac-world-shell .ac-community-columns>.ac-community-section>.ac-community-form>.ac-community-form-fields{flex:1;min-height:0}
.ac-world-shell .ac-community-columns>.ac-community-section>.ac-community-history{flex:1;min-height:0;max-height:none}
.ac-world-shell[data-ac-route=collab] .ac-community-form-fields{grid-template-columns:1fr 1fr;align-content:start}
.ac-world-shell[data-ac-route=collab] .ac-community-form-fields>.ac-field:nth-child(-n+2){grid-column:1/-1}
.ac-world-shell[data-ac-route=collab] textarea{min-height:76px;height:76px}
.ac-world-shell[data-ac-route=collab] .ac-community-columns>.ac-community-section:first-child>h3{display:none}
.ac-world-shell[data-ac-route=profile] .ac-community-columns{grid-template-columns:1.1fr 1fr 1fr;grid-template-rows:minmax(0,1.1fr) minmax(0,1fr)}
.ac-world-shell[data-ac-route=profile] .ac-community-columns>.ac-community-section:first-child{grid-row:1/3}
.ac-world-shell[data-ac-route=profile] .ac-community-columns>.ac-community-stack{display:contents}
.ac-world-shell[data-ac-route=profile] .ac-community-columns>.ac-community-stack>.ac-community-section{min-height:0;overflow:auto}
.ac-world-shell[data-ac-route=profile] .ac-community-columns>.ac-community-stack>.ac-community-section:last-child{grid-column:2/4}
.ac-world-shell[data-ac-route=profile] .ac-community-avatar-group .ac-card__header{font-size:18px;padding:8px}
.ac-world-shell[data-ac-route=profile] .ac-community-avatar-group .ac-card__status{font-size:10px;padding:4px 8px}
.ac-world-shell[data-ac-route=profile] .ac-community-avatar-group{grid-template-columns:repeat(2,minmax(0,1fr))}
.ac-world-shell[data-ac-route=profile] .ac-community-columns>.ac-community-stack>.ac-community-section:last-child{display:grid;grid-template-columns:minmax(0,1fr) 160px;align-content:start;gap:6px 12px}
.ac-world-shell[data-ac-route=profile] .ac-community-columns>.ac-community-stack>.ac-community-section:last-child>p{grid-column:1/-1;margin:0}
.ac-world-shell[data-ac-route=profile] .ac-community-columns>.ac-community-stack>.ac-community-section:last-child>.ac-button{align-self:end}
.ac-world-shell[data-ac-route=profile] .ac-profile-invitation>.ac-stat{font-size:10px;padding:0;display:flex;flex-direction:column;gap:1px;line-height:1.2}
.ac-world-shell[data-ac-route=profile] .ac-community-columns>.ac-community-stack>.ac-community-section:last-child p{font-size:11px}
.ac-world-shell[data-ac-route=profile] .ac-community-avatar-group .ac-community-avatar{height:76px;max-height:76px}
.ac-world-shell[data-ac-route=profile] .ac-community-section>.ac-community-section{margin-top:12px}
.ac-world-shell[data-ac-route=profile] canvas{max-height:140px;width:auto;max-width:100%;object-fit:contain}
.ac-world-shell .ac-community-section{padding-bottom:10px}
.ac-world-shell .ac-community-section>h3{margin-bottom:10px;padding:9px 12px;font-size:18px}
.ac-world-shell .ac-community-form,.ac-world-shell .ac-community-stack{gap:10px}
.ac-world-shell .ac-community-avatar-group .ac-community-avatar{max-height:115px;aspect-ratio:auto;height:115px;background-size:200% auto;background-position-y:center}
.ac-world-shell .ac-community-avatar--large{width:130px}
.ac-world-shell .ac-community-history{max-height:340px;overflow:auto;overscroll-behavior:contain;padding-right:6px}
.ac-world-shell[data-ac-route=leaderboard] .ac-community-content{display:flex;flex-direction:column;overflow:hidden}
.ac-world-shell .ac-community-ranking-scroll{flex:1;min-height:0;overflow:auto;overscroll-behavior:contain}
.ac-world-shell .ac-community-ranking thead{position:sticky;top:0;z-index:1}
.ac-world-shell[data-ac-route=leaderboard] .ac-community-content>.ac-community-columns{flex:0 0 auto;grid-template-columns:1fr}
.ac-world-shell[data-ac-route=leaderboard] .ac-community-columns h3{display:none}
.ac-world-shell .ac10-settings{height:100%;min-height:0;display:grid;grid-template-columns:minmax(0,1.6fr) minmax(0,1fr);grid-template-rows:auto minmax(0,1fr) auto;gap:0 24px}
.ac-world-shell .ac10-settings>form{grid-column:1;grid-row:2;min-height:0;display:flex;flex-direction:column}
.ac-world-shell .ac10-settings>.ac10-save-tools{grid-column:2;grid-row:2;margin:0;padding:0 0 0 20px;border:0;border-left:1px solid var(--ac-line);min-height:0;display:flex;flex-direction:column;gap:8px;overflow:hidden}
.ac-world-shell .ac10-save-tools:has(.ac10-test-tools){overflow:auto;overscroll-behavior:contain}
.ac-world-shell .ac10-test-tools{flex:none}
.ac-world-shell .ac10-save-tools>h2,.ac-world-shell .ac10-save-tools>p,.ac-world-shell .ac10-save-tools>.ac-input,.ac-world-shell .ac10-save-tools>.ac10-actions{flex:0 0 auto}
.ac-world-shell .ac10-save-advanced{min-height:0;display:flex;flex-direction:column;overflow:hidden}
.ac-world-shell .ac10-save-advanced>summary{font-weight:800;cursor:pointer;min-height:40px;padding:8px 0;flex:0 0 auto}
.ac-world-shell .ac10-save-advanced>.ac10-actions{display:grid;grid-template-columns:1fr 1fr;min-height:0;overflow:auto;padding:3px 4px 8px 2px}
.ac-world-shell .ac-button.ac-music-control{position:fixed;right:22px;bottom:20px;z-index:24;min-height:44px;padding:6px 16px;gap:9px;font-size:13px;min-width:114px}
.ac-world-shell .ac-music-note{font-size:24px;color:var(--ac-mint-edge);line-height:1}
.ac-world-shell[data-ac-route=home] .ac10-launch-frame{bottom:84px}
@media(max-width:900px){.ac-world-shell .ac-button.ac-music-control{right:18px;bottom:18px}.ac-world-shell[data-ac-route=play] .ac-button.ac-music-control{top:22px;bottom:auto}}
.ac-world-shell .ac10-settings>.ac10-note,.ac-world-shell .ac10-settings>.ac10-result{grid-column:1/-1;margin:0 0 12px}
.ac-world-shell .ac10-settings>.ac10-result{grid-row:3;margin:8px 0 0}
.ac-world-shell .ac10-settings__fields{flex:1;min-height:0;overflow:auto;gap:18px;margin:0 0 12px}
.ac-world-shell .ac10-settings__fields>section:nth-child(2){display:grid;grid-template-columns:1fr 1fr;align-content:start;gap:8px 12px;min-width:0}
.ac-world-shell .ac10-settings__fields>section:nth-child(2)>:is(h2,p){grid-column:1/-1}
.ac-world-shell .ac10-settings__fields>section:nth-child(2)>.ac10-volume{min-width:0}
.ac-world-shell .ac10-settings .ac10-actions{flex:0 0 auto;gap:8px;padding-bottom:6px}
.ac-world-shell .ac10-settings .ac10-note{font-size:12px;line-height:1.4;margin:6px 0}
.ac-world-shell .ac10-settings h2{font-size:18px;margin-bottom:10px}
.ac-world-shell .ac10-settings .ac10-check{min-height:38px;padding:4px 0;font-size:13px}
.ac-world-shell .ac10-settings .ac10-volume{margin-bottom:8px}
.ac-world-shell .ac10-settings input[type=range]{min-height:36px}
.ac-world-shell .ac10-save-tools>.ac10-actions{display:grid;grid-template-columns:1fr 1fr}
.ac-world-shell .ac10-help{height:100%;min-height:0;display:flex;flex-direction:column;gap:12px}
.ac-world-shell .ac10-help>p{margin:0;flex:0 0 auto}
.ac-world-shell .ac10-help>.ac-tabs{flex:1;min-height:0;display:flex;flex-direction:column}
.ac-world-shell .ac10-help .ac-tabs__list{flex:0 0 auto}
.ac-world-shell .ac10-help .ac-tabs__panel:not([hidden]){flex:1;min-height:0;overflow:hidden}
.ac-world-shell .ac10-guide{height:100%;min-height:0;gap:20px}
.ac-world-shell .ac10-guide .ac10-articles,.ac-world-shell .ac10-guide .ac10-contents,.ac-world-shell .ac10-faq{height:100%;min-height:0;overflow:auto;overscroll-behavior:contain;padding-right:8px}
.ac-world-shell .ac09-window[data-panel=market] .ac09-panel{overflow:hidden;align-content:stretch;min-height:0;height:100%}
.ac-world-shell .ac09-market-products{min-height:0;grid-template-rows:auto minmax(0,1fr);align-content:stretch}
.ac-world-shell .ac09-market-products>.ac09-grid{min-height:0;overflow:auto;align-content:start;padding:2px 8px 12px 2px;overscroll-behavior:contain}
.ac-world-shell .ac09-category-rail{min-height:0;overflow:auto;padding:2px 6px 10px 2px;position:static}
.ac-world-shell .ac09-window[data-panel=inventory] .ac09-panel{display:flex;flex-direction:column;overflow:hidden}
.ac-world-shell .ac09-window[data-panel=inventory] .ac09-panel>.ac-button{align-self:flex-start;flex:0 0 auto}
.ac-world-shell .ac09-window[data-panel=inventory] .ac09-filters{flex:0 0 auto}
.ac-world-shell .ac09-scroll-list{flex:1;min-height:0;overflow:auto;align-content:start;overscroll-behavior:contain;padding:2px 8px 12px 2px}
.ac-world-shell .ac09-window[data-panel=agents] .ac09-panel{display:flex;flex-direction:column;overflow:hidden}
.ac-world-shell .ac09-collection{flex:1;min-height:0;align-items:stretch}
.ac-world-shell .ac09-agent-list{min-height:0;overflow:auto;align-content:start;padding-right:7px;overscroll-behavior:contain}
.ac-world-shell .ac09-agent-detail{align-content:start;position:static}
.ac-world-shell .ac09-window[data-panel=care] .ac09-panel{display:flex;flex-direction:column;overflow:hidden}
.ac-world-shell .ac09-window[data-panel=care] .ac09-panel>.ac09-grid{flex:1;min-height:0;overflow:auto;align-content:start;padding-right:8px;overscroll-behavior:contain}
.ac-world-shell .ac09-window[data-panel=care] .ac09-panel>.ac09-field{flex:0 0 auto}
.ac-world-shell .ac09-starters{grid-template-columns:repeat(4,minmax(0,1fr))}
.ac-world-shell .ac09-starters .ac09-portrait{height:110px}
.ac-world-shell .ac09-starters .ac09-card{gap:7px}
.ac-world-shell .ac09-window[data-panel=starter] .ac09-panel{display:flex;flex-direction:column;overflow:hidden;gap:10px}
.ac-world-shell .ac09-window[data-panel=starter] .ac09-panel>.ac09-starters{flex:1;min-height:0;overflow:auto;align-content:start;overscroll-behavior:contain;padding:2px 5px 12px 2px}
.ac-world-shell .ac09-starters .ac-stat{padding-block:5px;font-size:12px}
.ac-world-shell .ac09-starters .ac09-portrait{height:82px}
.ac-world-shell .ac09-starters .ac09-card>h3{padding:8px 12px;font-size:17px}
.ac-world-shell .ac09-window[data-panel=energy] .ac09-panel{grid-template-columns:1fr 1fr;gap:12px 20px;overflow:auto}
.ac-world-shell .ac09-window[data-panel=energy] .ac09-panel>.ac09-grid{grid-column:1/-1}
.ac-world-shell .ac09-window[data-panel=energy] .ac09-panel>.ac09-hint:first-child{grid-column:1/-1}
@media(min-width:901px){.ac-world-shell .ac09-window[data-panel=starter]{height:min(660px,calc(100dvh - 205px))}.ac-world-shell .ac09-window[data-panel=boost]{height:auto;max-height:calc(100dvh - 205px);width:min(700px,100%)}}
@media(max-width:1000px){.ac-world-shell .ac10-settings{grid-template-columns:minmax(0,1fr) minmax(0,1fr);gap:0 16px}.ac-world-shell .ac10-settings__fields{grid-template-columns:1fr}.ac-world-shell .ac10-save-tools>.ac10-actions{grid-template-columns:1fr}.ac-world-shell .ac09-starters{grid-template-columns:repeat(2,minmax(0,1fr))}}
@media(max-width:1000px){.ac-world-shell[data-ac-route=profile] .ac-community-columns{grid-template-columns:1fr 1fr;grid-template-rows:minmax(0,1fr) minmax(0,1fr)}.ac-world-shell[data-ac-route=profile] .ac-community-columns>.ac-community-section:first-child{grid-row:1}.ac-world-shell[data-ac-route=profile] .ac-community-columns>.ac-community-stack>.ac-community-section:last-child{grid-column:1;grid-row:2}.ac-world-shell .ac10-save-advanced>.ac10-actions{grid-template-columns:1fr}}
@media(max-height:780px) and (min-width:701px){.ac-world-shell #screen-host .ac-community-test{font-size:12px;margin:4px 0 0}.ac-world-shell #screen-host .ac-frame__description{font-size:13px;margin:4px 0}.ac-world-shell #screen-host .ac-frame__header{margin-bottom:10px;padding-bottom:8px}.ac-world-shell .ac-community .ac-field{gap:4px}.ac-world-shell .ac-community .ac-input{min-height:40px;padding:8px 12px}.ac-world-shell .ac-community .ac-field__label{font-size:13px}.ac-world-shell .ac-community .ac-field__hint{font-size:11px}.ac-world-shell .ac-community .ac-stat{padding:7px 0;font-size:13px}.ac-world-shell .ac10-save-tools .ac-button{min-height:42px;padding:8px 10px;font-size:12px}}
@media(max-width:700px){.ac-world-shell:not([data-ac-route=home]):not([data-ac-route=play]) #screen-host{width:calc(100vw - 16px)}.ac-world-shell .ac09-market-products{grid-template-rows:auto minmax(0,1fr)}.ac-world-shell .ac09-window[data-panel=market] .ac09-panel{grid-template-rows:auto minmax(0,1fr)}.ac-world-shell .ac09-window[data-panel=agents] .ac09-panel{overflow:auto}.ac-world-shell .ac09-collection{flex:none;min-height:350px}.ac-world-shell .ac09-starters{grid-template-columns:1fr}.ac-world-shell .ac09-window[data-panel=energy] .ac09-panel{grid-template-columns:1fr}}
/* PC short forms: fit useful content before creating an inner scroller. */
.ac-world-shell #screen-host .ac-community .ac-window-header{gap:5px 16px}
.ac-world-shell #screen-host .ac-community .ac-frame__description{font-size:13px;line-height:1.4;max-width:none}
.ac-world-shell #screen-host .ac-community-test{font-size:12px;line-height:1.4}
.ac-world-shell #screen-host .ac-community-note{margin:0;line-height:1.4}
.ac-world-shell[data-ac-route=leaderboard] #screen-host .ac-community-content{display:grid;grid-template-rows:minmax(0,1fr) auto auto;gap:10px}
.ac-world-shell[data-ac-route=leaderboard] .ac-community-ranking{margin-bottom:0}
.ac-world-shell[data-ac-route=leaderboard] .ac-community-ranking :is(th,td){padding:8px 12px}
.ac-world-shell[data-ac-route=leaderboard] .ac-community-ranking caption{padding-bottom:8px;font-size:18px}
.ac-world-shell[data-ac-route=leaderboard] .ac-community-content>.ac-community-note{font-size:12px}
.ac-world-shell[data-ac-route=leaderboard] .ac-community-section{padding:0}
.ac-world-shell[data-ac-route=profile] .ac-community-avatar-group .ac-card__header{min-height:38px;padding:6px;gap:6px;flex-wrap:nowrap}
.ac-world-shell[data-ac-route=profile] .ac-community-avatar-group .ac-card__header .ac-card__title{font-size:16px}
.ac-world-shell[data-ac-route=profile] .ac-community-avatar-group .ac-card__status{padding:4px}
.ac-world-shell[data-ac-route=profile] .ac-community-avatar-group .ac-card__status>span{position:absolute;width:1px;height:1px;overflow:hidden;clip-path:inset(50%)}
.ac-world-shell[data-ac-route=profile] .ac-community-avatar-group .ac-card__status::after{width:20px;height:20px}
.ac-world-shell[data-ac-route=profile] .ac-community-avatar-group legend{margin-bottom:6px}
.ac-world-shell[data-ac-route=profile] .ac-community-form-fields>.ac-field>.ac-field__hint{display:none}
.ac-world-shell[data-ac-route=profile] .ac-profile-stats{display:grid!important;grid-template-columns:1fr 1fr;align-content:start;gap:0 12px}
.ac-world-shell[data-ac-route=profile] .ac-profile-stats>h3{grid-column:1/-1}
.ac-world-shell[data-ac-route=profile] .ac-profile-stats>.ac-stat{display:flex;flex-direction:column;gap:2px;padding:6px 0;font-size:13px}
.ac-world-shell[data-ac-route=profile] .ac-profile-stats .ac-stat__label,.ac-world-shell[data-ac-route=profile] .ac-profile-stats .ac-stat__value{flex:initial;text-align:left}
.ac-world-shell[data-ac-route=profile] .ac-profile-stats .ac-stat__label{font-size:11px;line-height:1.3}
.ac-world-shell[data-ac-route=profile] .ac-profile-card canvas{margin-bottom:8px}
.ac-world-shell[data-ac-route=profile] .ac-profile-invitation .ac-stat__label,.ac-world-shell[data-ac-route=profile] .ac-profile-invitation .ac-stat__value{flex:initial;text-align:left}
.ac-world-shell[data-ac-route=profile] .ac-profile-invitation{padding-bottom:0}
.ac-world-shell:not([data-ac-route=home]):not([data-ac-route=play]) .ac-button.ac-music-control{top:22px;bottom:auto}
.ac-world-shell .ac09-world-help{right:160px;max-width:calc(100vw - 180px)}
@media(max-height:780px) and (min-width:701px){
 .ac-world-shell:not([data-ac-route=home]):not([data-ac-route=play]) #screen-host .ac-community .ac-frame__surface{padding:16px 24px}
 .ac-world-shell:not([data-ac-route=home]):not([data-ac-route=play]) #screen-host .ac-community .ac-frame__header{margin-bottom:10px;padding-bottom:8px}
 .ac-world-shell #screen-host .ac-community .ac-frame__header>h1{font-size:28px;line-height:1.2}
 .ac-world-shell[data-ac-route=collab] textarea{height:64px;min-height:64px}
 .ac-world-shell[data-ac-route=collab] .ac-field__hint{line-height:1.25}
 .ac-world-shell[data-ac-route=collab] .ac-community-form-fields>.ac-field:nth-child(-n+2){grid-column:auto}
 .ac-world-shell[data-ac-route=profile] .ac-community-columns{grid-template-rows:minmax(0,1fr) 154px}
 .ac-world-shell[data-ac-route=profile] .ac-community-section>h3{padding:6px 10px;font-size:16px}
 .ac-world-shell[data-ac-route=profile] .ac-profile-card canvas{max-height:96px}
 .ac-world-shell[data-ac-route=profile] .ac-profile-card>.ac-button{min-height:42px;font-size:12px;padding:8px 12px}
 .ac-world-shell[data-ac-route=profile] .ac-profile-invitation>h3{grid-column:1;grid-row:1;margin:0;padding:6px 10px;font-size:16px}
 .ac-world-shell[data-ac-route=profile] .ac-profile-invitation>.ac-stat{grid-column:2;grid-row:1;display:flex;flex-direction:column;gap:1px;padding:0;font-size:10px;line-height:1.2}
 .ac-world-shell[data-ac-route=profile] .ac-profile-invitation .ac-stat__label,.ac-world-shell[data-ac-route=profile] .ac-profile-invitation .ac-stat__value{flex:initial;text-align:left}
}
/* Phone chrome is three separate zones: navigation, window and audio key.
   Dynamic viewport/safe-area spacing also covers Safari's visible toolbars. */
@media(max-width:600px){
 .ac-world-shell .ac-button.ac-music-control,
 .ac-world-shell:is([data-ac-route=home],[data-ac-route=play]) .ac-button.ac-music-control,
 .ac-world-shell:not([data-ac-route=home]):not([data-ac-route=play]) .ac-button.ac-music-control{
  top:auto;right:12px;bottom:calc(12px + env(safe-area-inset-bottom,0px));width:44px;height:44px;min-width:44px;min-height:44px;padding:6px;gap:0;font-size:0;line-height:1;display:grid;place-items:center;z-index:36;
 }
 .ac-world-shell .ac-button.ac-music-control .ac-music-note{font-size:24px;margin:0;line-height:1}
 .ac-world-shell[data-ac-route=play] .ac-button.ac-music-control{left:68px;right:auto;top:calc(12px + env(safe-area-inset-top,0px));bottom:auto}
 .ac-world-shell:not([data-ac-route=home]):not([data-ac-route=play]) #screen-host{
  top:calc(76px + env(safe-area-inset-top,0px));bottom:calc(70px + env(safe-area-inset-bottom,0px));width:calc(100vw - 20px);max-height:calc(100dvh - 146px - env(safe-area-inset-top,0px) - env(safe-area-inset-bottom,0px));overflow:visible;padding:0;
 }
 .ac-world-shell:not([data-ac-route=home]):not([data-ac-route=play]) #screen-host .ac-frame__surface{padding:14px 14px 16px}
 .ac-world-shell:not([data-ac-route=home]):not([data-ac-route=play]) #screen-host .ac-frame__header{margin-bottom:14px;padding-bottom:12px;gap:8px 12px}
 .ac-world-shell:not([data-ac-route=home]):not([data-ac-route=play]) #screen-host .ac-frame__body{overflow:auto;overscroll-behavior:contain;scrollbar-gutter:stable;padding:2px 4px 8px 0}
 .ac-world-shell #screen-host .ac-community .ac-frame__description{font-size:13px;line-height:1.45}
 .ac-world-shell #screen-host .ac-community-test{font-size:12px;margin:0}
 .ac-world-shell #screen-host .ac-community-content{height:auto;overflow:visible;gap:14px}
 .ac-world-shell #screen-host .ac-community-content>.ac-community-columns,
 .ac-world-shell[data-ac-route=profile] .ac-community-columns{display:grid;grid-template-columns:minmax(0,1fr);grid-template-rows:auto;gap:20px;flex:none;align-items:start}
 .ac-world-shell .ac-community-columns>.ac-community-section,
 .ac-world-shell .ac-community-columns>.ac-community-stack{overflow:visible;max-height:none;display:block}
 .ac-world-shell .ac-community-columns>.ac-community-stack>.ac-community-section{margin-bottom:20px}
 .ac-world-shell .ac-community-form-fields{overflow:visible;flex:none;gap:12px;padding:0}
 .ac-world-shell[data-ac-route=collab] .ac-community-form-fields{grid-template-columns:minmax(0,1fr)}
 .ac-world-shell[data-ac-route=collab] textarea{height:92px;min-height:92px}
 .ac-world-shell .ac-community-form>button[type=submit]{position:sticky;bottom:4px;z-index:2;margin-top:6px;max-width:100%;white-space:normal;overflow-wrap:normal;min-height:44px}
 .ac-world-shell .ac-community-section>h3{font-size:18px;margin-bottom:12px}
 .ac-world-shell .ac-community-history{max-height:240px;overflow:auto;overscroll-behavior:contain;padding-right:6px}
 .ac-world-shell[data-ac-route=profile] .ac-community-columns>.ac-community-section:first-child,
 .ac-world-shell[data-ac-route=profile] .ac-community-columns>.ac-community-stack>.ac-community-section:last-child{grid-column:auto;grid-row:auto}
 .ac-world-shell[data-ac-route=profile] .ac-community-columns>.ac-community-stack{display:grid;grid-template-columns:minmax(0,1fr);gap:18px}
 .ac-world-shell[data-ac-route=profile] .ac-community-columns>.ac-community-stack>.ac-community-section:last-child{display:block}
 .ac-world-shell[data-ac-route=profile] .ac-profile-invitation>.ac-stat{font-size:13px;margin-bottom:12px}
 .ac-world-shell[data-ac-route=profile] .ac-profile-card canvas{max-height:none;width:100%;height:auto}
 .ac-world-shell[data-ac-route=leaderboard] #screen-host .ac-community-content{display:flex}
 .ac-world-shell .ac10-settings{height:auto;display:flex;flex-direction:column;gap:18px}
 .ac-world-shell .ac10-settings>form,.ac-world-shell .ac10-settings>.ac10-save-tools{display:flex;flex-direction:column;flex:none;overflow:visible;min-height:0}
 .ac-world-shell .ac10-settings>.ac10-save-tools{padding:18px 0 0;margin:0;border-left:0;border-top:1px solid var(--ac-line)}
 .ac-world-shell .ac10-settings__fields{overflow:visible;display:grid;grid-template-columns:minmax(0,1fr);gap:20px;margin:0 0 16px}
 .ac-world-shell .ac10-settings__fields>section:nth-child(2){grid-template-columns:minmax(0,1fr)}
 .ac-world-shell .ac10-settings .ac10-actions{flex-wrap:wrap}
 .ac-world-shell .ac10-settings .ac10-actions>.ac-button{min-height:44px;overflow-wrap:normal;white-space:normal}
 .ac-world-shell .ac10-save-advanced{overflow:visible}
 .ac-world-shell .ac10-save-advanced>.ac10-actions{overflow:visible;grid-template-columns:minmax(0,1fr)}
 .ac-world-shell .ac10-help .ac-tabs__list{gap:8px;margin-bottom:14px}
 .ac-world-shell .ac10-help .ac-tab{flex:1;min-width:0;font-size:13px;padding:8px;white-space:normal}
 .ac-world-shell .ac10-guide{display:flex;flex-direction:column;gap:14px;overflow:auto}
 .ac-world-shell .ac10-guide .ac10-contents{height:auto;overflow:visible;flex:none;padding-right:0}
 .ac-world-shell .ac10-guide .ac10-articles{height:auto;overflow:visible;padding-right:0}
 /* A first-visit empty state should wrap its useful content, not fill the phone. */
 .ac-world-shell:not([data-ac-route=home]):not([data-ac-route=play]) #screen-host:has(.ac-community-content>.ac-state){bottom:auto;height:auto;overflow:hidden}
 .ac-world-shell #screen-host:has(.ac-community-content>.ac-state)>.ac-community,
 .ac-world-shell #screen-host:has(.ac-community-content>.ac-state)>.ac-community>.ac-frame,
 .ac-world-shell:not([data-ac-route=home]):not([data-ac-route=play]) #screen-host:has(.ac-community-content>.ac-state) .ac-frame__surface,
 .ac-world-shell #screen-host:has(.ac-community-content>.ac-state) .ac-frame__body{height:auto;max-height:inherit}
 .ac-world-shell #screen-host:has(.ac-community-content>.ac-state) .ac-frame__surface{max-height:calc(100dvh - 178px - env(safe-area-inset-top,0px) - env(safe-area-inset-bottom,0px))}
 .ac-world-shell #screen-host .ac-community-content>.ac-state{padding:14px;gap:10px}
 .ac-world-shell #screen-host .ac-community-content>.ac-state>.ac-icon{margin-top:4px}
 .ac-world-shell #screen-host .ac-community-content>.ac-state .ac-title{font-size:18px;line-height:1.3}
 .ac-world-shell #screen-host .ac-community-content>.ac-state p{font-size:14px;line-height:1.5;margin-top:8px}
 .ac-world-shell #screen-host .ac-community-content>.ac-state .ac-button{font-size:14px;line-height:1.3;min-height:44px;padding:10px 12px;overflow-wrap:normal;white-space:normal}
}

/* Phone gameplay: one task occupies the usable screen. The mounted world
   controls stay connected underneath; only the task's content can scroll. */
@media(max-width:700px){
 .ac09-game--panel>:is(.ac09-hud,.ac09-tools,.ac09-dock,.ac09-context,.ac09-first-agent,.ac09-world-help){visibility:hidden;pointer-events:none}
 .ac-world-shell .ac09-window-layer{padding:calc(72px + env(safe-area-inset-top,0px)) 9px calc(10px + env(safe-area-inset-bottom,0px))}
 .ac-world-shell .ac09-window:not(.ac09-window--robot-viewer):not(.ac09-window--welcome){height:calc(100dvh - 82px - env(safe-area-inset-top,0px) - env(safe-area-inset-bottom,0px));max-height:calc(100dvh - 82px - env(safe-area-inset-top,0px) - env(safe-area-inset-bottom,0px));width:100%}
 .ac-world-shell .ac09-window .ac-frame__surface{padding:12px}
 .ac-world-shell .ac09-window .ac-frame__header{flex:none;gap:8px;padding-bottom:8px;margin-bottom:0}
 .ac-world-shell .ac09-window .ac-display{font-size:20px;line-height:1.2;overflow-wrap:normal}
 .ac-world-shell .ac09-window .ac09-window-close{width:44px;min-width:44px;height:44px;min-height:44px;flex-basis:44px}
 .ac-world-shell .ac09-window .ac-frame__body{min-height:0;padding-top:10px}
 .ac-world-shell .ac09-window-foot{font-size:10px;line-height:1.2;margin-top:5px}
 .ac-world-shell .ac09-panel{gap:10px;min-width:0}
 .ac-world-shell .ac09-panel .ac09-field{gap:4px}
 .ac-world-shell .ac09-panel .ac09-label{font-size:12px}
 .ac-world-shell .ac09-window select{min-height:44px;padding:8px;font-size:14px;max-width:100%}
 .ac-world-shell .ac09-window .ac-button{min-height:44px;white-space:normal;overflow-wrap:normal}
 .ac-world-shell .ac09-build-layout,.ac-world-shell .ac09-care-layout,.ac-world-shell .ac09-expansion-layout{display:flex;flex-direction:column;gap:10px;overflow:auto;overscroll-behavior:contain;min-height:0;flex:1}
 .ac-world-shell .ac09-visual-hero{display:grid;grid-template-columns:88px minmax(0,1fr);grid-template-rows:auto;align-items:start;gap:5px 10px;flex:none;overflow:visible;padding:0}
 .ac-world-shell .ac09-visual-hero>.ac-title{grid-column:2;grid-row:1;font-size:17px;align-self:center;margin:0}
 .ac-world-shell .ac09-visual-hero>.ac09-hint{grid-column:2;grid-row:2;margin:0;font-size:12px}
 .ac-world-shell .ac09-hero-portrait,.ac-world-shell .ac09-expansion-layout .ac09-campus-portrait{grid-column:1;grid-row:1/4;width:88px;height:94px;flex-basis:94px}
 .ac-world-shell .ac09-visual-hero>.ac09-change-stat,.ac-world-shell .ac09-visual-hero>.ac-stat,.ac-world-shell .ac09-visual-hero>.ac-progress{grid-column:2;margin:0;font-size:12px}
 .ac-world-shell .ac09-editor,.ac-world-shell .ac09-service-list,.ac-world-shell .ac09-expansion-list{flex:none;min-height:auto;overflow:visible;padding:2px;gap:10px}
 .ac-world-shell .ac09-part-tabs .ac09-visual-pick{flex-basis:86px;min-height:94px;padding:6px;font-size:11px}
 .ac-world-shell .ac09-part-tabs{gap:6px;padding-bottom:6px;scroll-snap-type:x proximity}
 .ac-world-shell .ac09-part-tabs>.ac-button{scroll-snap-align:start}
 .ac-world-shell .ac09-visual-footer{flex:none;margin-top:8px;padding-top:8px;gap:7px;grid-template-columns:minmax(0,1fr)}
 .ac-world-shell .ac09-visual-footer>.ac09-actions{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:6px}
 .ac-world-shell .ac09-visual-footer .ac-button{font-size:12px;padding:8px 4px;line-height:1.25}
 .ac-world-shell .ac09-footer-metrics{gap:8px}
 .ac-world-shell .ac09-footer-copy{font-size:12px;line-height:1.35}
 .ac-world-shell .ac09-service-list{grid-template-columns:repeat(2,minmax(0,1fr))}
 .ac-world-shell .ac09-window[data-panel=starter] .ac09-mobile-starter{overflow:hidden;gap:10px;padding-right:0}
 .ac09-mobile-starter>.ac09-field,.ac09-mobile-starter>.ac-state{flex:none}
 .ac09-mobile-starter>.ac-state{padding:8px;gap:8px;font-size:12px}
 .ac09-mobile-starter>.ac-state .ac-title{font-size:15px;line-height:1.3}
 .ac09-mobile-starter>.ac-state p{margin:4px 0;font-size:12px;line-height:1.4}
 .ac09-mobile-starter>.ac-state .ac-button{font-size:12px;padding:6px 12px}
 .ac09-starter-choices{display:flex;flex:none;gap:8px;overflow-x:auto;overscroll-behavior:contain;scroll-snap-type:x proximity;padding:2px 3px 8px}
 .ac-world-shell .ac09-starter-choice{flex:0 0 82px;min-height:94px;display:flex;flex-direction:column;gap:4px;padding:7px;font-size:12px;scroll-snap-align:start;box-shadow:none;border:2px solid var(--ac-line);background:var(--ac-paper-raised);border-radius:10px}
 .ac09-starter-choice[aria-pressed=true]{border-color:var(--ac-mint-edge);background:var(--ac-selected)}
 .ac09-starter-choice .ac09-agent-portrait{width:56px;height:56px;margin:0;object-fit:contain}
 .ac09-starter-detail{display:grid;grid-template-columns:100px minmax(0,1fr);align-content:start;gap:12px;flex:1;min-height:0;overflow:auto;overscroll-behavior:contain}
 .ac09-starter-detail>.ac09-agent-portrait{width:100px;height:140px;margin:0;object-fit:contain;background:var(--ac-selected);border-radius:12px}
 .ac09-starter-copy{min-width:0}
 .ac09-starter-copy>.ac-title{font-size:20px;margin:0 0 6px}
 .ac09-starter-copy>.ac09-hint{font-size:12px;line-height:1.4;margin:0 0 8px}
 .ac09-starter-copy .ac-stat{font-size:12px;padding-block:5px;gap:6px}
 .ac09-starter-copy .ac-stat{display:grid;grid-template-columns:minmax(0,1fr);gap:2px}
 .ac09-starter-copy .ac-stat__label{font-size:11px}
 .ac09-starter-copy .ac-stat__value{text-align:left;white-space:nowrap}
 .ac09-starter-commandbar{flex:none;display:grid;grid-template-columns:1fr 1fr;gap:8px;padding-top:10px;margin-top:8px;border-top:1px solid var(--ac-line)}
 .ac09-starter-commandbar>.ac-stat,.ac09-starter-commandbar>.ac09-hint{grid-column:1/-1;margin:0}
 .ac09-starter-commandbar>.ac-stat{font-size:15px;padding:0 0 2px}
 .ac-world-shell .ac09-starter-commandbar>.ac-button{font-size:14px;padding:9px;grid-row:2}
 .ac09-starter-commandbar>.ac09-hint{font-size:12px;line-height:1.4}
 .ac-world-shell .ac09-window[data-panel=agents] .ac09-panel{overflow:hidden}
 .ac-world-shell .ac09-collection{display:flex;flex-direction:column;flex:1;min-height:0;gap:10px}
 .ac-world-shell .ac09-agent-list{display:flex;flex:none;gap:8px;overflow:auto;overscroll-behavior:contain;padding:2px 3px 8px}
 .ac-world-shell .ac09-agent-list>.ac09-agent-tile{flex:0 0 105px;gap:4px;padding:7px;font-size:11px;box-shadow:none;min-height:100px;scroll-snap-align:start}
 .ac-world-shell .ac09-agent-list .ac09-agent-portrait{height:46px;margin:0}
 .ac-world-shell .ac09-agent-detail{flex:1;min-height:0;overflow:auto;overscroll-behavior:contain;padding:10px;gap:7px;grid-template-columns:minmax(0,1fr) 72px}
 .ac-world-shell .ac09-agent-detail .ac-stat{font-size:12px}
 .ac-world-shell .ac09-agent-commandbar{flex:none;grid-template-columns:minmax(0,1fr) 100px;gap:8px;margin-top:8px;padding-top:8px}
 .ac-world-shell .ac09-agent-commandbar .ac09-actions{display:grid;grid-column:1/-1;grid-template-columns:repeat(3,minmax(0,1fr));gap:6px}
 .ac-world-shell .ac09-agent-commandbar .ac-button{min-height:44px;min-width:0;white-space:normal;padding:7px 4px;font-size:11px;line-height:1.25}
 .ac-world-shell .ac09-agent-commandbar .ac09-label{font-size:12px}
 .ac-world-shell .ac10-settings{display:flex;flex-direction:column;height:auto;min-height:0;gap:16px}
 .ac-world-shell .ac10-settings>form,.ac-world-shell .ac10-settings>.ac10-save-tools{flex:none;min-height:auto;overflow:visible;padding:0;border:0}
 .ac-world-shell .ac10-settings__fields{flex:none;overflow:visible;margin-bottom:14px}
 .ac-world-shell .ac10-settings__fields>section:nth-child(2){grid-template-columns:minmax(0,1fr)}
 .ac-world-shell .ac10-settings input[type=range]{min-height:44px}
 .ac-world-shell .ac10-settings .ac10-check{min-height:44px}
 .ac-world-shell .ac10-settings>.ac10-note{order:-2}
 .ac-world-shell .ac10-settings>.ac10-save-tools{order:-1}
 .ac-world-shell .ac10-test-tools{padding-top:8px;border-top:1px solid var(--ac-line)}
 .ac-world-shell .ac10-test-tools .ac-button{width:100%;font-size:14px;min-height:44px}
 .ac-world-shell .ac10-test-tools p{font-size:13px;line-height:1.5;margin-bottom:12px}
}
