/* Phone layout. Windows open maximized (wm.js), one at a time; the taskbar is the navigation.
   Everything here is additive: desktop look is unchanged above 760px. */
html, body { touch-action: manipulation; -webkit-text-size-adjust: 100%; }

@media (max-width: 760px), (pointer: coarse) and (max-width: 1024px) {
  :root { --tb: 44px; }
  body { font-size: 12px; }

  /* Logon */
  .wl-mid { flex-direction: column; justify-content: center; gap: 24px; }
  .wl-left { align-items: center; padding: 0; text-align: center; }
  .wl-logo img { width: 56px; height: 56px; }
  .wl-win { font-size: 34px; } .wl-hint { margin-top: 16px; font-size: 14px; }
  .wl-divider { display: none; }
  .wl-right { padding: 0; }
  .wl-user { padding: 10px 24px; border-radius: 8px; }
  .wl-note { display: none; }
  .wl-welcome-text { font-size: 40px; }

  /* Desktop + taskbar */
  #desktop { inset: 0 0 var(--tb) 0; }
  .dicon-label { font-size: 11px; }
  #taskbar { height: var(--tb); }
  #start-btn { font-size: 18px; padding: 0 14px 0 8px; }
  #task-buttons { gap: 4px; padding: 0 4px; overflow-x: auto; }
  .task-btn { flex: 0 0 auto; max-width: 150px; height: 34px; }
  #tray { gap: 10px; padding: 0 10px; } #tray-net, #tray-vol { display: none; }
  #toasts { bottom: calc(var(--tb) + 4px); left: 6px; align-items: stretch; }
  .toast { width: auto; }
  #fs-tip { display: none !important; }

  /* Windows: full screen, bigger controls */
  .xpwin.maximized { height: calc(100% - var(--tb) + 30px) !important; }
  #windows { inset: 0; }
  .xpwin .title-bar { height: 36px; }
  .title-bar-controls button { width: 28px !important; height: 28px !important; min-width: 28px !important; background-size: 18px !important; }
  .title-bar-controls button.fs { width: 28px; height: 28px; }
  .xpwin:not(.maximized):not(.dialog) { left: 0 !important; top: 0 !important; width: 100% !important; }
  .dialog { max-width: 94vw; }
  .rz { display: none; }
  .xp-btn { height: 30px; min-width: 84px; font-size: 12px; }
  .xp-input { height: 28px; font-size: 13px; }

  /* Start menu: full width */
  #start-menu { width: 100%; height: calc(100% - var(--tb)); bottom: var(--tb); border-radius: 0; }
  .sm-right { width: 150px; }
  .sm-item, .sm-ritem { padding: 8px 8px; font-size: 12px; }
  #all-programs { left: 0 !important; right: 0; min-width: 0; }
  #all-programs button { padding: 8px 10px; font-size: 12px; }

  /* IE: compact toolbar, scrollable tabs */
  .ie__toolbar { display: none; }
  .ie__btn-text, .ie__arrow, .ie__separate, [data-b="history"], [data-b="mail"], [data-b="print"], [data-b="edit"], [data-b="msn"], [data-b="search"] { display: none !important; }
  .ie__function_bar { height: 34px; }
  .ie__address_bar__title, .ie__address_bar__separate, .ie__address_bar__links { display: none; }
  .ie__address_bar { height: 32px; padding: 2px 4px 4px; }
  .ie__address_input { font-size: 13px; }
  .ie__address_bar__go { padding: 0 6px; }
  .ie__tabs { overflow-x: auto; overflow-y: hidden; height: 34px; padding-top: 5px; scrollbar-width: none; }
  .ie__tabs::-webkit-scrollbar { display: none; }
  .ie__tabstrip { overflow: visible; flex: 0 0 auto; }
  .ie__tab { height: 26px; min-width: 100px; max-width: 160px; font-size: 12px; }
  .ie__tab.active { height: 28px; }
  .ie__tab-close { visibility: visible; width: 20px; height: 20px; }
  .ie__footer { display: none; }

  /* Explorer: no task pane */
  .ex-side, .ex-toolbar, .ex-menubar { display: none; }
  .ex-table td { padding: 8px 6px; white-space: normal; }
  .ex-table th:nth-child(3), .ex-table td:nth-child(3) { display: none; }

  /* Notepad / System Properties / Add-Remove / charts */
  .notepad textarea { font-size: 12px; white-space: pre-wrap; }
  .sp-devices { columns: 1; }
  .sp-general dl { grid-template-columns: 80px 1fr; }
  .arp .window-body { flex-direction: column; }
  .arp-side { width: auto; flex-direction: row; justify-content: space-around; padding: 6px; gap: 4px; }
  .arp-nav { font-size: 10px; padding: 4px; } .arp-nav img { width: 24px; height: 24px; }
  .arp-detail { padding-left: 12px; }

  /* MSN */
  .im .im-pics { display: none; }
  .im .im-compose textarea { height: 70px; font-size: 14px; }
  .msn-list .ct { padding: 8px 6px 8px 10px; }
  .msn-head { padding: 10px; }
  .me-name, .me-psm { font-size: 12px; }
  .msn7 .mb-item { padding: 6px 7px; }
  .plus-prefs .pp { flex-direction: column; } .pp-side { width: auto; display: flex; flex-wrap: wrap; } .pp-i { padding: 4px 8px; }

  /* Outlook Express / media player */
  .oe-bar button:not(:first-child) { display: none; }
}
