@import url('https://fonts.googleapis.com/css2?family=Fira+Code:wght@400;600&family=Ubuntu:wght@400;500;700&display=swap');

* {
  box-sizing: border-box;
  font-family: 'Ubuntu', sans-serif;
}

body {
  margin: 0;
  padding: 0;
  min-height: 100vh;
  overflow: hidden;
  background: #2c001e url('https://images.unsplash.com/photo-1618005182384-a83a8bd57fbe?w=1920') no-repeat center center fixed;
  background-size: cover;
}

#topBar {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 30px;
  background: #111111;
  color: #eeeeee;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0 14px;
  font-size: 12px;
  font-weight: 500;
  z-index: 9999;
  border-bottom: 1px solid #333;
}

.top-bar-left,
.top-bar-right {
  display: flex;
  align-items: center;
  gap: 16px;
}

.top-bar-item {
  cursor: pointer;
  padding: 2px 6px;
  border-radius: 4px;
}

.top-bar-item:hover {
  background: rgba(255, 255, 255, 0.15);
}

.window {
  position: absolute;
  width: 440px;
  background: #1e1e1e;
  border: 1px solid #3c3c3c;
  border-radius: 8px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.6);
  display: flex;
  flex-direction: column;
  z-index: 10;
  overflow: hidden;
  color: #cccccc;
}

.window-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 8px 12px;
  background: #2d2d2d;
  border-bottom: 1px solid #3c3c3c;
  cursor: grab;
  user-select: none;
}

.window-header:active {
  cursor: grabbing;
}

.window-title {
  font-size: 12px;
  font-weight: 700;
  color: #e0e0e0;
  font-family: 'Fira Code', monospace;
}

.close-btn {
  width: 13px;
  height: 13px;
  background-color: #e95420;
  border-radius: 50%;
  cursor: pointer;
  border: none;
  transition: transform 0.1s;
}

.close-btn:hover {
  transform: scale(1.1);
}

.window-body {
  padding: 16px;
}

#desktopApps {
  padding-top: 42px;
  padding-left: 16px;
  display: flex;
  flex-direction: column;
  flex-wrap: wrap;
  height: calc(100vh - 40px);
  gap: 12px;
  align-content: flex-start;
}

.desktop-icon {
  text-align: center;
  padding: 8px;
  width: 86px;
  border-radius: 6px;
  cursor: pointer;
  user-select: none;
  display: flex;
  flex-direction: column;
  align-items: center;
  transition: background 0.15s;
}

.desktop-icon:hover {
  background: rgba(255, 255, 255, 0.1);
}

.desktop-icon.selected {
  background: rgba(233, 84, 32, 0.3);
  outline: 1px solid #395420;
}

.desktop-icon-img {
  width: 48px;
  height: 48px;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 24px;
  background: #252526;
  border: 1px solid #3e3e42;
  box-shadow: 0 1px 8px rgba(0, 0, 0, 0.4);
}

.desktop-icon p {
  margin: 6px 0 0;
  color: #ffffff;
  font-size: 11px;
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.9);
  word-break: break-word;
}

.terminal-body {
  background: #0d0d0d;
  color: #3ade80;
  font-family: 'Fira Code', monospace;
  padding: 12px;
  height: 280px;
  overflow-y: auto;
}

.btn-ubuntu {
  background: #e95420;
  color: #ffffff;
  border: none;
  padding: 6px 14px;
  border-radius: 4px;
  font-weight: 600;
  font-size: 11px;
  cursor: pointer;
}

.btn-ubuntu:hover {
  background: #c84315;
}

.pixel-grid {
  display: grid;
  grid-template-columns: repeat(16, 16px);
  grid-template-rows: repeat(16, 16px);
  gap: 1px;
  background: #333;
  padding: 2px;
}

.pixel-cell {
  width: 16px;
  height: 16px;
  background: #1e1e1e;
  cursor: pointer;
}