/* Browser UI changes the visible height; device insets protect screen edges. */
.desktop-home{display:contents}
:root{
 --mobile-safe-top:env(safe-area-inset-top,0px);
 --mobile-safe-right:env(safe-area-inset-right,0px);
 --mobile-safe-bottom:env(safe-area-inset-bottom,0px);
 --mobile-safe-left:env(safe-area-inset-left,0px);
}
@media(max-width:650px), (max-width:950px) and (max-height:500px){
 .system-bar{height:calc(54px + var(--mobile-safe-top));padding:var(--mobile-safe-top) calc(17px + var(--mobile-safe-right)) 0 calc(17px + var(--mobile-safe-left))}
 #desktop{height:calc(100dvh - 54px - var(--mobile-safe-top));min-height:0}
 #window-layer{inset:0}
 .app-window,.app-window.maximized{transform:none!important;inset:8px calc(8px + var(--mobile-safe-right)) calc(8px + var(--mobile-safe-bottom)) calc(8px + var(--mobile-safe-left))!important;width:auto!important;height:auto!important;border-radius:12px}
 .window-titlebar{height:45px;min-height:45px;padding:0 12px 0 16px;cursor:default}
 .window-identity{font-size:10px}
 .window-controls{gap:4px}
 .window-controls button{width:29px;height:29px}
 .window-controls button[data-window-action=maximize]{display:none}
 .dock-area{height:calc(112px + var(--mobile-safe-bottom));padding:0 max(var(--mobile-safe-left),var(--mobile-safe-right)) var(--mobile-safe-bottom);align-items:center}
 .dock{height:88px;max-width:calc(100% - 144px);padding:7px 8px;border-radius:19px}
 body.has-visible-windows .dock-area{visibility:hidden;pointer-events:none}
 .task-list{gap:3px}
 .dock.has-windows .dock-settings{margin-left:7px;padding-left:7px}
 .dock-settings{gap:0}
 .dock-button,.setting-button{width:60px;height:66px}
 .dock-button .app-icon,.setting-button .setting-icon{width:56px;height:56px;border-radius:17px}
 .dock-button .app-icon svg,.setting-button .setting-icon svg{width:30px;height:30px}
 .desktop-toggle,.dock-tooltip{display:none}
 .language-code{font-size:17px}
 .desktop-shortcuts{top:auto;bottom:calc(112px + var(--mobile-safe-bottom));gap:24px 12px}
 .shortcut{gap:8px}
 .shortcut .app-icon{width:64px;height:64px;border-radius:19px}
 .shortcut .app-icon svg{width:34px;height:34px}
 .shortcut-label{font-size:12px;line-height:1.4}
 .helper{right:calc(14px + var(--mobile-safe-right));bottom:calc(12px + var(--mobile-safe-bottom))}
 .helper-avatar{width:52px;height:90px}
 .avatar-art{left:0;right:0;top:0;height:auto;aspect-ratio:1/2}
 .helper-name{display:none}
 .helper-bubble{position:absolute;right:0;bottom:102px;width:min(280px,calc(100vw - 28px - var(--mobile-safe-left) - var(--mobile-safe-right)));max-height:calc(100dvh - 184px - var(--mobile-safe-top) - var(--mobile-safe-bottom));overflow:auto;margin-bottom:0}
}
@media(max-width:360px){.dock-button,.setting-button{width:60px}}
/* Center the shortcuts between the introduction and the visible top of the dock. */
@media(max-width:650px) and (min-height:501px){
 .desktop-home{position:absolute;inset:0 0 calc(100px + var(--mobile-safe-bottom));display:flex;flex-direction:column;gap:24px;padding:20px calc(24px + var(--mobile-safe-right)) 24px calc(24px + var(--mobile-safe-left));overflow-y:auto;overflow-x:hidden;overscroll-behavior-y:contain;scrollbar-width:none}
 .desktop-home::-webkit-scrollbar{display:none}
 .desktop-intro{position:static;inset:auto;width:100%;flex:none}
 .desktop-intro .eyebrow{font-size:11px;line-height:1.4}
 .desktop-intro h1{font-size:36px;line-height:1.12;letter-spacing:-1px;margin-top:12px}
 .desktop-intro p{font-size:15px;line-height:1.5;margin-top:14px;max-width:none;text-wrap:pretty}
 .desktop-shortcuts{position:static;inset:auto;flex:none;width:100%;margin-block:auto;grid-template-columns:repeat(3,minmax(0,1fr));gap:16px 12px;padding-top:0}
 .wallpaper-caption{display:none}
}
@media(max-width:360px) and (min-height:501px){
 .desktop-home{padding-left:18px;padding-right:18px}
 .desktop-intro h1{font-size:34px}
 .shortcut-label{font-size:11px}
}
@media(max-width:950px) and (max-height:500px){
 .desktop-intro{top:20px;left:calc(24px + var(--mobile-safe-left));width:30%}
 .desktop-intro h1{font-size:25px}
 .desktop-intro p{font-size:10px;margin-top:10px}
 .desktop-shortcuts{top:26px;bottom:auto;left:calc(39% + var(--mobile-safe-left));right:calc(20px + var(--mobile-safe-right));grid-template-columns:repeat(3,minmax(0,1fr));gap:18px 12px}
 .shortcut .app-icon{width:56px;height:56px;border-radius:17px}
 .shortcut .app-icon svg{width:30px;height:30px}
 .wallpaper-caption,.desktop-footnote{display:none}
}
