* { margin: 0; padding: 0; box-sizing: border-box; }

body {
  background: #008080;
  overflow: hidden;
  height: 100vh;
  width: 100vw;
}

/* ── Boot Screen ── */
.boot-screen {
  position: fixed;
  inset: 0;
  background: #000;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 99999;
  transition: opacity 0.4s;
}

.boot-logo {
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 20px;
}

.boot-eth { opacity: 0.9; }

.boot-title {
  font-family: 'Courier New', monospace;
  font-size: 36px;
  color: #c0c0c0;
  letter-spacing: 2px;
}

.boot-title span { color: #627EEA; }

.boot-progress-container {
  width: 300px;
  height: 18px;
  background: #000;
  border: 2px inset #444;
  padding: 2px;
}

.boot-progress-bar {
  height: 100%;
  width: 0%;
  background: repeating-linear-gradient(
    90deg,
    #000080 0px, #000080 8px,
    transparent 8px, transparent 12px
  );
}

/* ── BSOD ── */
.bsod {
  position: fixed;
  inset: 0;
  background: #0000AA;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 99999;
  font-family: 'Courier New', monospace;
  color: #fff;
  font-size: 14px;
  padding: 40px;
}

.bsod-content { max-width: 700px; line-height: 1.6; }

.bsod-header {
  background: #aaa;
  color: #0000AA;
  display: inline;
  padding: 0 8px;
  font-weight: bold;
}

/* ── Desktop ── */
.desktop {
  height: calc(100vh - 32px);
  padding: 16px;
  position: relative;
}

/* ── Built By ── */
.built-by {
  position: absolute;
  top: 8px;
  left: 12px;
  color: rgba(255,255,255,0.35);
  font-size: 11px;
  text-decoration: none;
  text-shadow: 1px 1px 1px rgba(0,0,0,0.3);
}

.built-by:hover { color: rgba(255,255,255,0.6); }

/* ── Desktop Icons ── */
.desktop-icons {
  position: absolute;
  top: 30px;
  left: 16px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.desktop-icon {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  text-decoration: none;
  color: #fff;
  font-size: 11px;
  width: 70px;
  padding: 4px;
  text-align: center;
  text-shadow: 1px 1px 1px #000;
  cursor: pointer;
}

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

.desktop-icon-img {
  width: 32px;
  height: 32px;
  image-rendering: pixelated;
}

/* ── Context Menu ── */
.context-menu {
  position: fixed;
  width: 180px;
  z-index: 9002;
}

.context-item {
  padding: 4px 16px;
  font-size: 12px;
  cursor: pointer;
}

.context-item:hover {
  background: #000080;
  color: #fff;
}

.context-menu hr {
  border: none;
  border-top: 1px solid #808080;
  border-bottom: 1px solid #fff;
  margin: 2px 4px;
}

/* ── Metric Windows ── */
.metric-window, .about-window {
  position: absolute;
  width: 680px;
  min-width: 400px;
  user-select: none;
}

.metric-window .window-body {
  padding: 8px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

/* ── Tabs ── */
.win-tabs { display: flex; gap: 4px; }
.tab-btn { flex: 1; font-size: 11px; }
.tab-btn.active { font-weight: bold; }

/* ── Stats ── */
.win-stats { display: flex; gap: 6px; }

.stat-box {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
  padding: 4px;
  border: 1px solid #888;
  background: #fff;
}

.stat-label {
  font-size: 9px;
  text-transform: uppercase;
  color: #666;
}

.stat-value {
  font-size: 14px;
  font-weight: bold;
  font-family: 'Courier New', monospace;
}

.stat-value.high { color: #aa0000; }
.stat-value.low { color: #006600; }

/* ── Chart ── */
.win-chart {
  height: 260px;
  padding: 4px;
  background: #fff;
}

.win-chart canvas {
  width: 100% !important;
  height: 100% !important;
}

/* ── About Window ── */
.about-window {
  width: 380px;
  min-width: 300px;
}

/* ── Taskbar ── */
.taskbar {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  height: 32px;
  background: #c0c0c0;
  border-top: 2px outset #fff;
  display: flex;
  align-items: center;
  padding: 2px 4px;
  z-index: 9000;
}

.start-btn {
  display: flex;
  align-items: center;
  gap: 4px;
  padding: 2px 8px;
  font-weight: bold;
  font-size: 12px;
  min-height: 24px;
  flex-shrink: 0;
}

.start-btn img { flex-shrink: 0; }

.sheep-btn {
  min-height: 24px;
  min-width: 26px;
  padding: 2px 4px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  margin-left: 2px;
}

.taskbar-windows {
  display: flex;
  flex: 1;
  gap: 2px;
  padding: 0 4px;
  overflow: hidden;
}

.taskbar-win-btn {
  max-width: 160px;
  min-width: 60px;
  height: 24px;
  font-size: 11px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  text-align: left;
  padding: 2px 6px;
}

.taskbar-win-btn.active { font-weight: bold; }

.taskbar-tray {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 0 8px;
  border: 1px inset #c0c0c0;
  height: 24px;
  flex-shrink: 0;
}

.tray-eth {
  font-size: 11px;
  font-weight: bold;
  font-family: 'Courier New', monospace;
}

.tray-sep { color: #888; font-size: 10px; }

.taskbar-clock {
  font-size: 11px;
  font-family: 'Courier New', monospace;
}

/* ── Start Menu ── */
.start-menu {
  position: fixed;
  bottom: 32px;
  left: 4px;
  width: 220px;
  z-index: 9001;
}

.start-menu-sidebar {
  position: absolute;
  left: 3px;
  top: 21px;
  bottom: 3px;
  width: 22px;
  background: linear-gradient(to top, #000080, #1084d0);
  color: #fff;
  font-weight: bold;
  font-size: 10px;
  writing-mode: vertical-rl;
  text-orientation: mixed;
  transform: rotate(180deg);
  display: flex;
  align-items: center;
  justify-content: flex-start;
  padding: 8px 3px;
  letter-spacing: 1px;
}

.start-menu-items {
  margin-left: 24px;
  padding: 4px 0;
}

.start-menu-section {
  padding: 3px 12px;
  font-size: 11px;
  font-weight: bold;
  color: #444;
  cursor: default;
}

.start-menu-item {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 5px 12px;
  font-size: 12px;
  cursor: pointer;
  text-decoration: none;
  color: #000;
}

.start-menu-item:hover {
  background: #000080;
  color: #fff;
}

.start-menu-item img { flex-shrink: 0; }

.start-menu hr {
  border: none;
  border-top: 1px solid #808080;
  border-bottom: 1px solid #fff;
  margin: 2px 8px;
}

/* ── Responsive ── */
@media (max-width: 700px) {
  .desktop { padding: 8px; }
  .desktop-icons { display: none; }
  .metric-window { width: calc(100vw - 16px); min-width: 0; left: 8px !important; }
  .about-window { width: calc(100vw - 16px); min-width: 0; }
  .win-stats { flex-wrap: wrap; }
  .stat-box { flex: 1 1 45%; }
  .win-chart { height: 200px; }
  .tab-btn { font-size: 10px; padding: 3px 2px; }
}
