body {
  margin: 0;
  font-family: Tahoma, sans-serif;
  overflow: hidden;
}

#desktop {
  width: 100vw;
  height: 100vh;
  background: url('wallpaper.jpg') center/cover no-repeat;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
}

.icon {
  width: 80px;
  text-align: center;
  color: white;
  cursor: pointer;
  margin: 10px;
  user-select: none;
}

.icon span {
  display: block;
  margin-top: 4px;
  text-shadow: 0 1px 2px rgba(0,0,0,0.7);
}

.window {
  position: absolute;
  top: 120px;
  left: 120px;
  display: none;
  width: 320px;
}

/* TASKBAR */

#taskbar {
  position: fixed;
  bottom: 0;
  width: 100%;
  background: silver;
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 4px;
  box-sizing: border-box;
}

#taskbarApps {
  flex: 1;
  display: flex;
  gap: 6px;
  overflow-x: auto;
  padding: 0 6px;
}

.task-btn {
  max-width: 200px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.task-btn.active {
  font-weight: bold;
}

#startMenu {
  position: fixed;
  bottom: 35px;
  left: 0;
  background: silver;
  display: none;
  flex-direction: column;
  padding: 6px;
}

#clock {
  padding-right: 10px;
}

/* Generic large window */
.large-window {
  width: 640px;
  height: 520px;
}

/* -------------------------
   Voice Window (VDO.Ninja)
-------------------------- */

#voice.large-window {
  width: min(900px, 85vw);
  height: min(650px, 75vh);
}

#voice .window-body.voice-body {
  height: calc(100% - 26px);
  display: flex;
  flex-direction: column;
  padding: 6px 6px 10px 6px;
  box-sizing: border-box;
}

.voice-embed {
  flex: 1 1 auto;
  width: 100%;
  border: 0;
  min-height: 240px;
  margin-bottom: 10px;
}

.voice-footer {
  flex: 0 0 auto;
  text-align: center;
}

.voice-footer small {
  display: block;
  margin: 0 0 4px 0;
}

.voice-footer button {
  margin: 0;
}

/* -------------------------
   Minesweeper + Snake shared layout
-------------------------- */

#minesweeper.large-window,
#snake.large-window {
  width: min(900px, 85vw);
  height: min(650px, 75vh);
}

#minesweeper .window-body.mines-body,
#snake .window-body.mines-body {
  height: calc(100% - 26px);
  display: flex;
  flex-direction: column;
  padding: 6px 6px 10px 6px;
  box-sizing: border-box;
}

.mines-embed {
  flex: 1 1 auto;
  width: 100%;
  border: 0;
  min-height: 300px;
  margin-bottom: 10px;
}

.mines-footer {
  flex: 0 0 auto;
  text-align: center;
}

.mines-footer small {
  display: block;
  margin: 0 0 4px 0;
}

.mines-footer button {
  margin: 0;
}

/* -------------------------
   Toonami Window
-------------------------- */

#toonami.large-window {
  width: min(960px, 88vw);
  height: min(720px, 80vh);
}

#toonami .window-body.toonami-body {
  height: calc(100% - 26px);
  display: flex;
  flex-direction: column;
  padding: 6px 6px 10px 6px;
  box-sizing: border-box;
}

.toonami-embed {
  flex: 1 1 auto;
  width: 100%;
  border: 0;
  min-height: 360px;
  margin-bottom: 10px;
}

.toonami-footer {
  text-align: center;
}

.toonami-footer small {
  display: block;
  margin-bottom: 4px;
}

.toonami-footer button {
  margin: 0;
}

/* -------------------------
   XP Explorer-style Folder (Games)
-------------------------- */

#gamesFolder.large-window {
  width: min(920px, 86vw);
  height: min(640px, 74vh);
}

#gamesFolder .window-body.explorer-body {
  height: calc(100% - 26px);
  display: flex;
  flex-direction: column;
  padding: 0;
  box-sizing: border-box;
}

.explorer-content {
  flex: 1 1 auto;
  display: flex;
  min-height: 0;
}

.explorer-sidebar {
  width: 220px;
  padding: 10px;
  box-sizing: border-box;
  border-right: 1px solid #9a9a9a;
  background: linear-gradient(#d6e6ff, #f3f7ff);
  overflow: auto;
}

.explorer-section {
  margin-bottom: 12px;
  padding: 8px;
  border: 1px solid #a6b7d6;
  background: rgba(255, 255, 255, 0.7);
}

.explorer-section-title {
  font-weight: bold;
  margin-bottom: 8px;
  color: #1f3a7a;
}

.explorer-link {
  display: block;
  width: 100%;
  text-align: left;
  margin: 4px 0;
  padding: 4px 6px;
  border: 1px solid transparent;
  background: transparent;
  cursor: pointer;
  font-family: inherit;
}

.explorer-link:hover {
  border-color: #7aa7ff;
  background: rgba(122, 167, 255, 0.25);
}

.explorer-files {
  flex: 1 1 auto;
  display: flex;
  flex-direction: column;
  min-width: 0;
  min-height: 0;
  background: #ffffff;
}

.explorer-path {
  padding: 6px 8px;
  border-bottom: 1px solid #c7c7c7;
  background: linear-gradient(#ffffff, #f1f1f1);
  font-size: 12px;
}

.explorer-grid {
  flex: 1 1 auto;
  padding: 10px;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
  gap: 10px;
  overflow: auto;
}

.explorer-item {
  display: flex;
  gap: 10px;
  align-items: center;
  padding: 8px 10px;
  border: 1px solid #d6d6d6;
  background: #fbfbfb;
  cursor: pointer;
  user-select: none;
}

.explorer-item:hover {
  border-color: #7aa7ff;
  background: rgba(122, 167, 255, 0.18);
}

.explorer-status {
  padding: 4px 8px;
  border-top: 1px solid #c7c7c7;
  background: linear-gradient(#f1f1f1, #e2e2e2);
  font-size: 12px;
}