/* HODL Desktop - Desktop & Icons */
#desktop {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: var(--taskbar-height);
  background:
    /* Subtle stars/particles */
    radial-gradient(1px 1px at 10% 15%, rgba(255,149,0,0.4) 50%, transparent 50%),
    radial-gradient(1px 1px at 85% 25%, rgba(0,212,255,0.3) 50%, transparent 50%),
    radial-gradient(1.5px 1.5px at 45% 8%, rgba(255,149,0,0.3) 50%, transparent 50%),
    radial-gradient(1px 1px at 70% 60%, rgba(0,212,255,0.25) 50%, transparent 50%),
    radial-gradient(1px 1px at 25% 75%, rgba(255,149,0,0.2) 50%, transparent 50%),
    radial-gradient(1.5px 1.5px at 90% 80%, rgba(0,212,255,0.3) 50%, transparent 50%),
    radial-gradient(1px 1px at 55% 45%, rgba(255,149,0,0.15) 50%, transparent 50%),
    radial-gradient(1px 1px at 15% 55%, rgba(0,212,255,0.2) 50%, transparent 50%),
    /* "Hills" at bottom - evoking XP Bliss */
    radial-gradient(ellipse 120% 60% at 25% 105%, rgba(255,149,0,0.12) 0%, transparent 60%),
    radial-gradient(ellipse 100% 50% at 75% 115%, rgba(0,212,255,0.08) 0%, transparent 60%),
    /* Grid subtle texture */
    linear-gradient(rgba(255,255,255,0.01) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,0.01) 1px, transparent 1px),
    /* Dark gradient base */
    linear-gradient(180deg, #0d1117 0%, #161b22 40%, #0d1117 100%);
  background-size:
    300px 300px, 300px 300px, 300px 300px, 300px 300px,
    300px 300px, 300px 300px, 300px 300px, 300px 300px,
    100% 100%, 100% 100%,
    50px 50px, 50px 50px,
    100% 100%;
  overflow: hidden;
}

#desktop-icons {
  position: absolute;
  top: 10px;
  left: 10px;
  display: flex;
  flex-direction: column;
  flex-wrap: wrap;
  gap: 4px;
  max-height: calc(100vh - var(--taskbar-height) - 20px);
  z-index: var(--z-desktop);
}

.desktop-icon {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 3px;
  padding: 6px 4px;
  cursor: pointer;
  border: 1px solid transparent;
  border-radius: 3px;
  text-align: center;
  transition: background 0.1s;
}

.desktop-icon:hover {
  background: rgba(255, 149, 0, 0.12);
  border-color: rgba(255, 149, 0, 0.25);
}

.desktop-icon.selected {
  background: rgba(255, 149, 0, 0.2);
  border-color: rgba(255, 149, 0, 0.4);
}

.desktop-icon svg,
.desktop-icon img {
  width: 32px;
  height: 32px;
  filter: drop-shadow(1px 1px 2px rgba(0,0,0,0.6));
}

.desktop-icon span {
  font-size: 11px;
  color: #fff;
  text-shadow: 1px 1px 2px #000, -1px -1px 2px #000, 1px -1px 2px #000, -1px 1px 2px #000;
  max-width: 72px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  line-height: 1.2;
}

#windows-container {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
}

/* Right-click context menu */
.context-menu {
  position: fixed;
  background: #fff;
  border: 1px solid #808080;
  box-shadow: 2px 2px 4px rgba(0,0,0,0.3);
  padding: 2px 0;
  z-index: var(--z-context-menu);
  min-width: 160px;
}

.context-menu-item {
  padding: 4px 24px;
  font-size: 11px;
  font-family: var(--font-system);
  cursor: pointer;
  white-space: nowrap;
}

.context-menu-item:hover {
  background: #0a246a;
  color: #fff;
}

.context-menu-separator {
  height: 1px;
  background: #c0c0c0;
  margin: 2px 0;
}
