/* Consistent desktop icon boxes; smaller sizes stay in window chrome and menus. */
.desktop-icon img,.desktop-apps img { width:48px; height:48px; object-fit:contain; image-rendering:pixelated; }
.desktop-icon { gap:7px; }
.titlebar img { width:16px; height:16px; }
.task-button img { width:16px; height:16px; }
#start-button { min-width:64px; gap:5px; padding:2px 6px 2px 3px; }
#start-button img { width:20px; height:20px; }
#start-button b { font-size:12px; }
#start-menu { width:238px; display:grid; grid-template-columns:28px minmax(0,1fr); padding:2px; overflow:visible; }
#start-menu .start-brand { background:#808080; color:#c0c0c0; font:23px var(--system-font); letter-spacing:0; writing-mode:vertical-rl; transform:rotate(180deg); padding:8px 2px; white-space:nowrap; }
#start-menu .start-brand b { color:white; }
#start-menu .start-items { min-height:0; padding:1px 2px; max-height:calc(var(--viewport-height) - var(--taskbar-height) - 16px); overflow-y:auto; }
#start-menu button { display:flex; align-items:center; gap:9px; width:100%; height:38px; min-height:38px; padding:3px 6px; text-align:left; color:black; background:transparent; border:0; outline:none; white-space:nowrap; font:12px var(--system-font); }
#start-menu button span { font:inherit; }
#start-menu button img { width:32px; height:32px; flex:0 0 32px; object-fit:contain; image-rendering:pixelated; }
#start-menu button:hover,#start-menu button:focus-visible,#start-menu button[aria-expanded=true] { background:#000080; color:white; }
#start-menu hr { margin:3px 1px; border-top:1px solid #808080; border-bottom:1px solid white; }
.submenu-arrow { width:0; height:0; margin-left:auto; border-top:4px solid transparent; border-bottom:4px solid transparent; border-left:4px solid currentColor; }
#start-menu .start-submenu { position:fixed; width:228px; padding:2px; z-index:20001; max-height:calc(var(--viewport-height) - var(--taskbar-height) - 8px); overflow-y:auto; }
#start-menu .submenu-back { display:none; }
@media(max-width:680px),(max-width:1000px) and (max-height:500px){
  #start-menu button { min-height:42px; height:42px; }
  #start-menu .submenu-back { display:flex; height:32px; min-height:32px; border-bottom:1px solid #808080; margin-bottom:3px; }
  #start-menu .start-submenu { width:228px; }
}

/* Preserve the original My Computer artwork at its native desktop size. */
.desktop-icon[data-open="computer"] img { width:48px; height:48px; }

.desktop-icon[data-open="files"] span { white-space:normal; max-width:100%; line-height:1.15; }
.desktop-icon[data-open="paint"]::after,.desktop-icon[data-open="mines"]::after { content:''; position:absolute; width:16px; height:16px; top:34px; left:calc(50% - 24px); background:url('assets/shortcut.svg?v=original-1') center/contain no-repeat; pointer-events:none; }

#desktop.icons-ready .desktop-icon { height:94px; }
