/* ============================================================
   BidenOS 95 — Period-accurate Win95 chrome
   ============================================================ */

:root {
  --c-face:      #c0c0c0;
  --c-face-2:    #dfdfdf;
  --c-hilight:   #ffffff;
  --c-shadow:    #808080;
  --c-dshadow:   #000000;
  --c-titlebar:  #000080;
  --c-titlebar2: #1084d0;
  --c-ti:        #808080;
  --c-ti2:       #b5b5b5;
  --c-desktop:   #008080;
  --c-selection: #000080;
}

* { box-sizing: border-box; }
html, body {
  margin: 0;
  height: 100%;
  font-family: "MS Sans Serif", "Microsoft Sans Serif", "Tahoma", sans-serif;
  font-size: 11px;
  background: radial-gradient(ellipse at center, #3a2a1a 0%, #120a05 80%);
  overflow: hidden;
  user-select: none;
  -webkit-font-smoothing: none;
}
button, input, select { font-family: inherit; font-size: 11px; }

/* ----- Room / Laptop ----- */
.room {
  width: 100vw; height: 100vh;
  display: flex; align-items: center; justify-content: center;
  perspective: 1600px;
}
.laptop {
  width: min(1100px, 92vw);
  transform: rotateX(6deg);
  transform-style: preserve-3d;
  filter: drop-shadow(0 40px 40px rgba(0,0,0,0.7));
}
.screen-bezel {
  background: #1a1a1a;
  border-radius: 14px 14px 4px 4px;
  padding: 26px 18px 22px;
  border: 2px solid #2a2a2a;
  position: relative;
}
.camera {
  width: 6px; height: 6px; border-radius: 50%;
  background: #444; position: absolute;
  top: 10px; left: 50%; transform: translateX(-50%);
  box-shadow: inset 0 0 2px #000;
}
.desktop {
  position: relative;
  width: 100%;
  aspect-ratio: 4 / 3;
  background: var(--c-desktop);
  overflow: hidden;
  border: 2px inset #888;
}
.hinge {
  height: 14px;
  background: linear-gradient(#2a2a2a, #444 50%, #1a1a1a);
  border-radius: 0 0 4px 4px;
  margin: 0 -6px;
}
.base {
  height: 24px;
  background: linear-gradient(#d0d0d0, #888);
  border-radius: 0 0 30px 30px / 0 0 50px 50px;
  margin: 0 -20px;
  position: relative;
  transform: rotateX(-30deg);
  transform-origin: top center;
}
.keyboard { position: absolute; inset: 4px 60px; display: flex; gap: 10px; }
.keys {
  flex: 2;
  background:
    repeating-linear-gradient(90deg, #555 0 18px, #888 18px 20px),
    repeating-linear-gradient(0deg, #555 0 10px, #888 10px 12px);
  border-radius: 4px; opacity: .55;
}
.trackpad { flex: 1; background: #aaa; border-radius: 4px; opacity: .7; }

/* ============================================================
   Desktop icons
   ============================================================ */
.icons {
  position: absolute;
  inset: 4px 4px 32px 4px;
  display: grid;
  grid-template-columns: repeat(auto-fill, 76px);
  grid-auto-rows: 80px;
  gap: 2px;
  align-content: start;
}
.icon {
  width: 76px;
  text-align: center;
  color: white;
  font-size: 11px;
  text-shadow: 1px 1px 0 #000;
  cursor: pointer;
  padding: 4px 2px;
  border: 1px dotted transparent;
  display: flex; flex-direction: column; align-items: center; gap: 2px;
  line-height: 1.15;
}
.icon.selected { border-color: #fff; }
.icon.selected .label { background: var(--c-selection); padding: 0 2px; }
.icon .glyph {
  font-size: 30px; line-height: 1;
  filter: drop-shadow(1px 1px 0 #000);
}
.icon .label { display: inline-block; }

/* ============================================================
   Windows
   ============================================================ */
.window {
  position: absolute;
  min-width: 200px; min-height: 100px;
  max-height: calc(100vh - 64px);
  background: var(--c-face);
  border: 2px solid;
  border-color: var(--c-hilight) var(--c-dshadow) var(--c-dshadow) var(--c-hilight);
  display: flex; flex-direction: column;
  padding: 2px;
  box-shadow: 1px 1px 0 0 var(--c-dshadow);
}
.window.app-pictures {
  height: min(640px, calc(100vh - 64px));
}
.window::before {
  content: "";
  position: absolute; inset: 0;
  border: 1px solid;
  border-color: var(--c-face-2) var(--c-shadow) var(--c-shadow) var(--c-face-2);
  pointer-events: none;
}

.titlebar {
  background: linear-gradient(90deg, var(--c-ti), var(--c-ti2));
  color: #d4d0c8;
  padding: 2px 2px 2px 4px;
  display: flex; align-items: center; gap: 2px;
  font-weight: bold;
  cursor: move;
  height: 18px;
  position: relative; z-index: 1;
}
.window.active .titlebar {
  background: linear-gradient(90deg, var(--c-titlebar), var(--c-titlebar2));
  color: white;
}
.titlebar .title-icon { font-size: 13px; line-height: 1; }
.titlebar .title {
  flex: 1; padding-left: 2px;
  overflow: hidden; white-space: nowrap; text-overflow: ellipsis;
}
.tb-btn {
  width: 16px; height: 14px;
  background: var(--c-face);
  border: 1px solid;
  border-color: var(--c-hilight) var(--c-dshadow) var(--c-dshadow) var(--c-hilight);
  padding: 0; cursor: pointer;
  font-size: 9px; font-weight: bold;
  font-family: "MS Sans Serif", sans-serif;
  color: black; line-height: 1;
}
.tb-btn:active {
  border-color: var(--c-dshadow) var(--c-hilight) var(--c-hilight) var(--c-dshadow);
}

.menubar {
  background: var(--c-face);
  padding: 1px 2px;
  display: flex; gap: 0;
  position: relative; z-index: 1;
  font-size: 11px;
}
.menubar span { padding: 2px 6px; cursor: default; }
.menubar span u { text-decoration: underline; }
.menubar span:hover { background: var(--c-selection); color: white; }

.window .content {
  flex: 1;
  background: white;
  padding: 4px;
  overflow: auto;
  border: 2px solid;
  border-color: var(--c-shadow) var(--c-hilight) var(--c-hilight) var(--c-shadow);
  margin: 2px 0 0;
  white-space: pre-wrap;
  line-height: 1.4;
  color: #000;
  position: relative; z-index: 1;
  font-family: "Courier New", monospace;
}
.window.app-paint .content,
.window.app-itunes .content,
.window.app-solitaire .content,
.window.app-browser .content,
.window.app-outlook .content,
.window.app-aim .content,
.window.app-winamp .content,
.window.app-mycomputer .content,
.window.app-pictures .content,
.window.app-minesweeper .content,
.window.app-donate .content,
.window.app-folder .content {
  font-family: "MS Sans Serif", sans-serif;
  white-space: normal;
  padding: 0;
}
.window.app-terminal .content {
  background: black; color: #c0c0c0;
  font-family: "Consolas", "Courier New", monospace;
  white-space: pre-wrap;
}
.statusbar {
  border-top: 1px solid var(--c-shadow);
  background: var(--c-face);
  padding: 2px 4px;
  display: flex; gap: 4px;
  font-size: 11px;
  position: relative; z-index: 1;
}
.statusbar .pane {
  border: 1px solid;
  border-color: var(--c-shadow) var(--c-hilight) var(--c-hilight) var(--c-shadow);
  padding: 1px 6px; min-width: 80px;
}

/* ============================================================
   Taskbar
   ============================================================ */
.taskbar {
  position: absolute;
  bottom: 0; left: 0; right: 0;
  height: 28px;
  background: var(--c-face);
  border-top: 1px solid var(--c-hilight);
  display: flex; align-items: center;
  padding: 2px; gap: 3px;
  z-index: 9999;
}
.start-btn {
  display: flex; align-items: center; gap: 4px;
  background: var(--c-face);
  border: 2px solid;
  border-color: var(--c-hilight) var(--c-dshadow) var(--c-dshadow) var(--c-hilight);
  padding: 2px 8px 2px 4px;
  font-weight: bold;
  cursor: pointer;
  font-size: 11px;
  height: 22px;
}
.start-btn:active, .start-btn.open {
  border-color: var(--c-dshadow) var(--c-hilight) var(--c-hilight) var(--c-dshadow);
}
.start-logo {
  display: inline-block;
  width: 16px; height: 16px;
  background:
    linear-gradient(135deg, #ff2222 0 50%, transparent 50%) no-repeat 0 0 / 50% 50%,
    linear-gradient(135deg, transparent 50%, #22ff22 50%) no-repeat 100% 100% / 50% 50%,
    linear-gradient(45deg, #2222ff 0 50%, #ffff22 50%) no-repeat 0 0 / 100% 100%;
  transform: skewX(-12deg);
  border: 1px solid #000;
  flex-shrink: 0;
}
.task-items {
  flex: 1; display: flex; gap: 3px;
  overflow: hidden;
  height: 22px; align-items: center;
}
.task-item {
  background: var(--c-face);
  border: 2px solid;
  border-color: var(--c-hilight) var(--c-dshadow) var(--c-dshadow) var(--c-hilight);
  padding: 2px 6px;
  font-size: 11px;
  max-width: 160px;
  overflow: hidden; white-space: nowrap; text-overflow: ellipsis;
  cursor: pointer; height: 22px;
  display: flex; align-items: center; gap: 4px;
}
.task-item.active {
  border-color: var(--c-dshadow) var(--c-hilight) var(--c-hilight) var(--c-dshadow);
  background:
    repeating-linear-gradient(45deg, #a0a0a0 0 2px, var(--c-face) 2px 4px);
}
.task-item .ti-icon { font-size: 12px; line-height: 1; }
.tray {
  border: 1px solid;
  border-color: var(--c-shadow) var(--c-hilight) var(--c-hilight) var(--c-shadow);
  padding: 2px 8px;
  font-variant-numeric: tabular-nums;
  display: flex; align-items: center; gap: 6px;
  height: 22px;
}
.tray .tray-icon { font-size: 12px; line-height: 1; }

/* ============================================================
   Start menu
   ============================================================ */
.start-menu {
  position: absolute;
  bottom: 30px; left: 2px;
  width: 230px;
  background: var(--c-face);
  border: 2px solid;
  border-color: var(--c-hilight) var(--c-dshadow) var(--c-dshadow) var(--c-hilight);
  display: flex;
  z-index: 10000;
  padding: 2px;
}
.start-menu.hidden { display: none; }
.start-side {
  background: linear-gradient(180deg, #08246b 0%, #0c2d8a 100%);
  color: white;
  writing-mode: vertical-rl;
  transform: rotate(180deg);
  padding: 8px 4px;
  font-weight: bold;
  text-align: right;
  font-size: 18px;
  letter-spacing: 1px;
}
.start-side small { font-size: 12px; opacity: .9; }
.start-menu ul { list-style: none; margin: 0; padding: 2px; flex: 1; }
.start-menu li {
  padding: 5px 18px 5px 32px;
  cursor: pointer;
  position: relative;
  font-size: 12px;
}
.start-menu li .glyph {
  position: absolute; left: 6px;
  width: 20px; text-align: center; font-size: 14px;
}
.start-menu li:hover { background: var(--c-selection); color: white; }
.start-menu li.sep {
  height: 0;
  border-top: 1px solid var(--c-shadow);
  border-bottom: 1px solid var(--c-hilight);
  margin: 3px 4px; padding: 0; cursor: default;
}
.start-menu li.sep:hover { background: transparent; }

/* ============================================================
   Boot
   ============================================================ */
.boot {
  position: absolute; inset: 0;
  background: black; color: #c0c0c0;
  font-family: "Courier New", monospace;
  font-size: 13px;
  padding: 14px;
  z-index: 20000;
  white-space: pre;
}
.boot.hidden { display: none; }

/* ============================================================
   Folder / My Computer
   ============================================================ */
.addr-bar {
  padding: 2px 4px;
  background: var(--c-face);
  border-bottom: 1px solid var(--c-shadow);
  display: flex; align-items: center; gap: 4px;
}
.addr-bar label { font-size: 11px; }
.addr-bar input {
  flex: 1; padding: 2px 4px;
  border: 2px solid;
  border-color: var(--c-shadow) var(--c-hilight) var(--c-hilight) var(--c-shadow);
  background: white;
}
.folder-list {
  display: grid;
  grid-template-columns: repeat(auto-fill, 80px);
  gap: 6px;
  padding: 8px;
  background: white;
  align-content: start;
  min-height: 100%;
}
.folder-item {
  display: flex; flex-direction: column; align-items: center;
  text-align: center; cursor: pointer;
  padding: 4px;
  font-size: 11px;
  line-height: 1.2;
  width: 76px;
}
.folder-item .glyph { font-size: 28px; line-height: 1; margin-bottom: 2px; }
.folder-item:hover { background: #d8e4ff; }

/* ============================================================
   Paint
   ============================================================ */
.paint-wrap { display: flex; flex-direction: column; background: var(--c-face); }
.paint-row { display: flex; gap: 4px; padding: 4px; }
.paint-tools {
  display: grid;
  grid-template-columns: repeat(2, 22px);
  gap: 1px;
  background: var(--c-face);
}
.paint-tool {
  width: 22px; height: 22px;
  background: var(--c-face);
  border: 1px solid;
  border-color: var(--c-hilight) var(--c-dshadow) var(--c-dshadow) var(--c-hilight);
  display: flex; align-items: center; justify-content: center;
  font-size: 12px; cursor: pointer;
}
.paint-canvas {
  flex: 1;
  height: 220px;
  background:
    radial-gradient(circle at 30% 40%, #f5c, transparent 40%),
    radial-gradient(circle at 70% 60%, #5cf, transparent 40%),
    radial-gradient(circle at 50% 80%, #fc5, transparent 40%),
    white;
  border: 2px solid;
  border-color: var(--c-shadow) var(--c-hilight) var(--c-hilight) var(--c-shadow);
}
.color-palette {
  display: grid;
  grid-template-columns: repeat(14, 14px);
  gap: 1px;
  padding: 4px;
  background: var(--c-face);
}
.swatch { width: 14px; height: 14px; border: 1px solid #000; cursor: pointer; }

/* ============================================================
   iTunes / WinAmp
   ============================================================ */
.itunes-list { list-style: none; padding: 0; margin: 0; background: white; }
.itunes-list li {
  padding: 3px 8px;
  border-bottom: 1px solid #ddd;
  display: flex; justify-content: space-between;
}
.itunes-list li:nth-child(odd) { background: #f0f4ff; }

.winamp {
  background: #2a2a2a; color: #00ff66;
  font-family: "Courier New", monospace;
  padding: 6px;
}
.winamp .wa-top {
  background: linear-gradient(180deg, #4a4a4a, #1a1a1a);
  color: #ccc;
  padding: 2px 6px;
  font-size: 10px;
  display: flex; justify-content: space-between;
  border: 1px solid #000;
  margin-bottom: 4px;
}
.winamp .wa-display {
  background: #000;
  border: 1px solid #444;
  padding: 4px 6px;
  font-size: 11px;
  letter-spacing: 1px;
}
.winamp .wa-bars {
  display: flex; gap: 1px; height: 22px; margin-top: 4px; align-items: flex-end;
}
.winamp .wa-bars div {
  flex: 1;
  background: linear-gradient(0deg, #0f0, #ff0, #f00);
}
.winamp .wa-ctrl { display: flex; gap: 4px; margin-top: 6px; justify-content: center; }
.winamp .wa-ctrl button {
  background: #555; color: #00ff66;
  border: 1px outset #888;
  font-family: inherit; padding: 1px 6px; cursor: pointer;
}

/* ============================================================
   Solitaire
   ============================================================ */
.solitaire {
  background: #017a3a;
  padding: 12px;
  min-height: 220px;
  color: white;
  font-family: "MS Sans Serif", sans-serif;
}
.card-row { display: flex; gap: 8px; flex-wrap: wrap; }
.card {
  width: 50px; height: 70px;
  background: white;
  color: black;
  border-radius: 4px;
  display: flex; align-items: flex-start; justify-content: flex-start;
  padding: 4px;
  font-weight: bold;
  border: 1px solid #333;
  font-family: "Times New Roman", serif;
  font-size: 14px;
}
.card.red { color: #c00; }

/* ============================================================
   Browser (IE)
   ============================================================ */
.browser-bar {
  display: flex; gap: 2px; padding: 3px;
  background: var(--c-face);
  border-bottom: 1px solid var(--c-shadow);
  align-items: center;
}
.browser-bar button {
  background: var(--c-face);
  border: 2px solid;
  border-color: var(--c-hilight) var(--c-dshadow) var(--c-dshadow) var(--c-hilight);
  padding: 1px 6px;
  cursor: pointer;
  font-size: 11px;
}
.browser-bar input {
  flex: 1; padding: 2px 4px;
  border: 2px solid;
  border-color: var(--c-shadow) var(--c-hilight) var(--c-hilight) var(--c-shadow);
  background: white;
}
.browser-page {
  padding: 12px;
  font-family: "Times New Roman", serif;
  background: white;
  color: #000;
}

/* ============================================================
   Outlook Express
   ============================================================ */
.outlook { display: grid; grid-template-rows: 1fr; height: 100%; background: white; }
.ol-grid { display: grid; grid-template-columns: 140px 1fr; height: 100%; }
.ol-folders {
  background: white;
  border-right: 1px solid var(--c-shadow);
  padding: 4px;
  font-size: 11px;
}
.ol-folders ul { list-style: none; padding: 0; margin: 0; }
.ol-folders li { padding: 2px 4px; cursor: pointer; }
.ol-folders li.sel, .ol-folders li:hover { background: var(--c-selection); color: white; }
.ol-right { display: grid; grid-template-rows: 1fr 1fr; min-height: 0; }
.ol-list { overflow: auto; border-bottom: 1px solid var(--c-shadow); }
.ol-list table { width: 100%; border-collapse: collapse; font-size: 11px; }
.ol-list th, .ol-list td {
  text-align: left; padding: 2px 6px;
  border-right: 1px solid var(--c-shadow);
  border-bottom: 1px solid #ddd;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.ol-list th {
  background: var(--c-face);
  border-top: 1px solid var(--c-hilight);
  border-bottom: 1px solid var(--c-shadow);
}
.ol-list tr { cursor: pointer; }
.ol-list tr.sel { background: var(--c-selection); color: white; }
.ol-list tr.unread td { font-weight: bold; }
.ol-preview {
  padding: 0;
  font-size: 12px;
  overflow: auto;
  background: white;
}
.ol-preview .hdr {
  background: var(--c-face);
  padding: 4px 6px;
  border-bottom: 1px solid var(--c-shadow);
  font-size: 11px;
}
.ol-preview .hdr div { margin: 1px 0; }
.ol-preview .body { padding: 8px; font-family: "MS Sans Serif", sans-serif; }

/* ============================================================
   AIM
   ============================================================ */
.aim { background: var(--c-face); font-size: 11px; height: 100%; display: flex; flex-direction: column; }
.aim .aim-hdr {
  background: linear-gradient(90deg, #ffcc00, #ffaa00);
  color: #000;
  padding: 3px 6px;
  font-weight: bold;
  border-bottom: 1px solid var(--c-shadow);
}
.aim .buddies { padding: 4px; background: white; flex: 1; overflow: auto; }
.aim .group {
  font-weight: bold;
  background: var(--c-face);
  padding: 2px 4px;
  margin: 4px 0 2px;
}
.aim .buddy { padding: 1px 4px 1px 18px; position: relative; cursor: default; }
.aim .buddy.on::before  { content: "●"; color: #0a0; position: absolute; left: 4px; }
.aim .buddy.off { color: var(--c-shadow); }
.aim .buddy.off::before { content: "○"; position: absolute; left: 4px; }
.aim .buddy.idle::before { content: "◐"; color: #c80; position: absolute; left: 4px; }

/* ============================================================
   Minesweeper
   ============================================================ */
.mine-frame { padding: 6px; background: var(--c-face); display: inline-block; }
.mine-head {
  display: flex; justify-content: space-between; align-items: center;
  padding: 4px 6px;
  margin-bottom: 4px;
  border: 2px solid;
  border-color: var(--c-shadow) var(--c-hilight) var(--c-hilight) var(--c-shadow);
}
.mine-num {
  background: black; color: red;
  font-family: "Courier New", monospace;
  font-weight: bold;
  padding: 2px 4px;
  font-size: 16px;
  letter-spacing: 1px;
  border: 1px solid #444;
  min-width: 38px;
  text-align: right;
}
.mine-face {
  width: 26px; height: 26px;
  background: var(--c-face);
  border: 2px solid;
  border-color: var(--c-hilight) var(--c-dshadow) var(--c-dshadow) var(--c-hilight);
  display: flex; align-items: center; justify-content: center;
  cursor: pointer;
  font-size: 14px;
}
.mine-grid {
  display: grid;
  border: 2px solid;
  border-color: var(--c-shadow) var(--c-hilight) var(--c-hilight) var(--c-shadow);
  width: max-content;
}
.mine-cell {
  width: 16px; height: 16px;
  background: var(--c-face);
  border: 2px solid;
  border-color: var(--c-hilight) var(--c-dshadow) var(--c-dshadow) var(--c-hilight);
  font-size: 11px; font-weight: bold;
  display: flex; align-items: center; justify-content: center;
  cursor: pointer;
}
.mine-cell.open { border: 1px solid var(--c-shadow); background: #bdbdbd; }
.mine-cell.n1 { color: #0000ff; }
.mine-cell.n2 { color: #008000; }
.mine-cell.n3 { color: #ff0000; }
.mine-cell.n4 { color: #000080; }
.mine-cell.n5 { color: #800000; }
.mine-cell.n6 { color: #008080; }

/* ---------------- Donate (Solana) ---------------- */
.window.app-donate { width: 360px; }
.donate-wrap {
  padding: 12px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  font-size: 12px;
}
.donate-title { font-weight: bold; font-size: 13px; }
.donate-sub { color: #222; font-size: 11px; line-height: 1.35; }
.donate-qr {
  align-self: center;
  padding: 6px;
  background: #fff;
  border: 1px solid var(--c-shadow, #808080);
  box-shadow: inset 1px 1px 0 #fff, inset -1px -1px 0 #404040;
}
.donate-addr-label { font-size: 11px; color: #444; margin-top: 2px; }
.donate-addr {
  border: 1px solid var(--c-shadow, #808080);
  background: #fff;
  padding: 4px 6px;
  font-family: "Courier New", monospace;
  font-size: 11px;
  word-break: break-all;
  user-select: all;
}
.donate-row { display: flex; gap: 6px; }
.donate-row .btn-95 {
  flex: 1;
  text-align: center;
  text-decoration: none;
  color: #000;
  font-family: "MS Sans Serif", sans-serif;
  font-size: 11px;
  padding: 4px 10px;
  background: var(--c-face, #c0c0c0);
  border: 1px solid #000;
  box-shadow: inset 1px 1px 0 #fff, inset -1px -1px 0 #808080;
  cursor: pointer;
}
.donate-row .btn-95:active {
  box-shadow: inset -1px -1px 0 #fff, inset 1px 1px 0 #808080;
}
.donate-foot { font-size: 10px; color: #555; line-height: 1.3; }
.donate-credit {
  margin-top: 4px;
  text-align: center;
  font-size: 11px;
  font-style: italic;
  color: #444;
}
