/* ============================================================
   FONTS  (exact roles from the Figma file)
   ============================================================ */
@font-face { font-family: "VT323";        src: url("../fonts/VT323-Regular.ttf") format("truetype"); font-weight: 400; font-display: block; }
@font-face { font-family: "DotGothic16";   src: url("../fonts/DotGothic16-Regular.ttf") format("truetype"); font-weight: 400; font-display: block; }
@font-face { font-family: "IBMPlexSansCond"; src: url("../fonts/IBMPlexSansCondensed-Regular.ttf") format("truetype"); font-weight: 400; font-display: block; }
@font-face { font-family: "Silkscreen";    src: url("../fonts/Silkscreen-Regular.ttf") format("truetype"); font-weight: 400; font-display: block; }
@font-face { font-family: "Silkscreen";    src: url("../fonts/Silkscreen-Bold.ttf") format("truetype"); font-weight: 700; font-display: block; }
/* aliases so the labels baked into the imported SVG icons resolve to the icon font */
@font-face { font-family: "IBM Plex Sans Condensed";   src: url("../fonts/IBMPlexSansCondensed-Regular.ttf") format("truetype"); font-weight: 400; font-display: block; }
@font-face { font-family: "IBMPlexSansCond-Regular";   src: url("../fonts/IBMPlexSansCondensed-Regular.ttf") format("truetype"); font-weight: 400; font-display: block; }
@font-face { font-family: "Input Mono Condensed";      src: url("../fonts/IBMPlexSansCondensed-Regular.ttf") format("truetype"); font-weight: 400; font-display: block; }
@font-face { font-family: "InputMonoCondensed-Regular";src: url("../fonts/IBMPlexSansCondensed-Regular.ttf") format("truetype"); font-weight: 400; font-display: block; }

:root {
  --title: "VT323", monospace;         /* project/mail/EoF big titles */
  --body:  "DotGothic16", monospace;   /* paragraph body text */
  --icon:  "IBMPlexSansCond", sans-serif; /* icon + list labels */
  --chrome:"Silkscreen", monospace;    /* window buttons + titles + meta */
}

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

html, body {
  width: 100%; height: 100%;
  overflow: hidden;
  background: #b8b8b8;
}

img { -webkit-user-drag: none; user-select: none; }

/* ============================================================
   STAGE  — fixed 1920x1080, scaled to viewport (pixel faithful)
   ============================================================ */
#stage {
  position: absolute;
  top: 0; left: 0;
  width: 1920px;
  height: 1080px;
  transform-origin: top left;
  background-image: url("../images/wallpaper.png");
  background-repeat: repeat;
  background-size: 240px 160px;
  overflow: hidden;
}

/* ============================================================
   MENU BAR
   ============================================================ */
.menu-bar {
  position: absolute;
  top: 40px; left: 305px;
  width: 1190px; height: 24px;
  background: #fff;
  border: 2px solid #000;
  border-radius: 2px;
}
.menu-bar__handle {
  position: absolute;
  top: -1px; bottom: -1px; right: 0;
  width: 29px;
  border-left: 2px solid #000;
  display: flex; flex-direction: column;
  align-items: center; justify-content: center;
  gap: 3px;
}
.menu-bar__handle span { display: block; width: 16px; height: 2px; background: #000; }

/* ============================================================
   DESKTOP ICONS
   ============================================================ */
/* ---- reusable inline-SVG icon (label baked in) ---- */
.ico {
  position: absolute;
  display: block;
  padding: 0; margin: 0; border: none; background: none;
  cursor: pointer;
  text-decoration: none;
  -webkit-tap-highlight-color: transparent;
  line-height: 0;
}
.ico .ico-svg { display: block; width: 100%; height: auto; overflow: visible; }
/* pressed / active state -> invert to black */
.ico.is-active { filter: invert(1); }

.desktop-icon { position: absolute; }
.desktop-icon.dragging { z-index: 5000; }

/* ============================================================
   WINDOWS
   ============================================================ */
#windows { position: absolute; inset: 0; }

.window {
  position: absolute;
  background: #fff;
  border: 2px solid #000;
  overflow: hidden;           /* NEVER scroll */
}
.window.dark { background: #000; }

/* ---- title bar ---- */
.win-titlebar {
  position: absolute; top: 0; left: 0; right: 0;
  height: 51px;
  border-bottom: 2px solid #000;
  background: repeating-conic-gradient(#000 0% 25%, #fff 0% 50%) 0 0 / 4px 4px;
  cursor: grab;
}
.win-titlebar:active { cursor: grabbing; }

.win-chrome-btn {
  position: absolute;
  background: #fff;
  border: 2px solid #000;
  border-radius: 2px;
  height: 17px;
  font-family: var(--chrome);
  font-size: 11px; line-height: 11px;
  color: #000;
  text-transform: lowercase;
  display: flex; align-items: center; justify-content: center;
  padding: 0;
  cursor: pointer;
}
.win-help  { left: 8px;  top: 27px; width: 18px; }
.win-close { left: 34px; top: 27px; width: 52px; }
.win-chrome-btn.is-active { background: #000; color: #fff; }

.win-title {
  position: absolute;
  top: 9px; left: 50%; transform: translateX(-50%);
  height: 17px;
  padding: 0 8px;
  background: #fff;
  border: 2px solid #000;
  border-radius: 2px;
  font-family: var(--chrome);
  font-size: 11px; line-height: 15px;
  text-transform: lowercase;
  white-space: nowrap;
  display: flex; align-items: center;
}

/* minimize + hamburger — aligned with the ?/Close row (lower), not the title box */
.win-min, .win-ham {
  position: absolute; top: 27px;
  width: 24px; height: 17px;
  background: #fff;
  border: 2px solid #000;
  border-radius: 2px;
  display: flex; flex-direction: column;
  align-items: center; justify-content: center;
  gap: 2.5px;
  cursor: pointer;
}
.win-min  { right: 36px; }
.win-ham  { right: 8px; }
.win-min i { display: block; width: 12px; height: 2px;   background: #000; }
.win-ham i { display: block; width: 14px; height: 1.5px; background: #000; }
.win-min.is-active, .win-ham.is-active { background: #000; }
.win-min.is-active i, .win-ham.is-active i { background: #fff; }

/* ============================================================
   SCROLLBARS  (aesthetic, styled after RESOURCES/REFERENCE)
   right bar (top->bottom):  down-arrow | minus | track | plus | up-arrow
   bottom bar (left->right): bracket | ->track | <-track | bracket | corner
   ============================================================ */
.win-scroll-y {
  position: absolute; top: 51px; right: 0; bottom: 20px;
  width: 20px;
  border-left: 2px solid #000;
  background: #fff;
  display: flex; flex-direction: column;
}
.win-scroll-y .sb-box {
  position: relative; flex: none;
  border-bottom: 2px solid #000;
  display: flex; align-items: center; justify-content: center;
}
.win-scroll-y .sb-arrow  { height: 46px; }
.win-scroll-y .sb-symbol { height: 22px; }
.win-scroll-y .sb-track  { flex: 1; }
.win-scroll-y .sb-box:last-child { border-bottom: none; border-top: 2px solid #000; }

.win-scroll-x {
  position: absolute; left: 0; right: 20px; bottom: 0;
  height: 20px;
  border-top: 2px solid #000;
  background: #fff;
  display: flex;
}
.win-scroll-x .sb-box {
  width: 20px; flex: none;
  border-right: 2px solid #000;
  display: flex; align-items: center; justify-content: center;
}
.win-scroll-x .sb-track { flex: 1; display: flex; align-items: center; justify-content: center; }
.win-scroll-x .sb-track.seg-a { border-right: 2px solid #000; }
.win-scroll-x .sb-box:last-child { border-right: none; border-left: 2px solid #000; }

.sb-ico { display: block; }

/* corner square where the two scrollbars meet */
.win-scroll-corner {
  position: absolute; right: 0; bottom: 0;
  width: 20px; height: 20px;
  border-left: 2px solid #000; border-top: 2px solid #000;
  background: #fff;
}

/* ---- project doc window ---- */
.doc-title {
  position: absolute;
  font-family: var(--title);
  font-size: 64px; line-height: 1; letter-spacing: 6.4px;
  color: #000; white-space: nowrap;
}
.doc-meta {
  position: absolute;
  font-family: var(--chrome);
  font-size: 12px; line-height: 20px; letter-spacing: 1.2px;
  color: #000;
}
.doc-meta b { font-weight: 700; }
.doc-body {
  position: absolute;
  font-family: var(--body);
  font-size: 14px; line-height: 1.88; letter-spacing: 1.12px;
  color: #000;
}
.doc-cover { position: absolute; object-fit: cover; display: block; }
.doc-incom {
  position: absolute;
  height: 17px;
  background: #fff; border: 2px solid #000; border-radius: 2px;
  font-family: var(--chrome); font-size: 11px; line-height: 11px;
  color: #000; text-transform: lowercase;
  display: flex; align-items: center; justify-content: center;
  text-decoration: none; cursor: pointer;
}
.doc-incom.is-active { background:#000; color:#fff; }

/* dark variant (End of File) */
.dark .doc-title, .dark .doc-meta, .dark .doc-body { color: #fff; }
.dark .doc-meta b { color: #fff; }

/* ---- tool image window ---- */
.tool-img { position: absolute; top: 51px; left: 0; width: 100%; height: calc(100% - 51px); object-fit: cover; display: block; }

/* ---- schedule ---- */
.sched-head {
  position: absolute;
  font-family: var(--chrome); font-weight: 700;
  font-size: 12px; line-height: 20px; letter-spacing: 1.2px;
  white-space: pre; color: #000;
}
.sched-body {
  position: absolute;
  font-family: var(--body);
  font-size: 14px; letter-spacing: 1.12px;
  white-space: pre; color: #000;
}
.sched-body .row { line-height: 40px; }
.sched-vline { position: absolute; width: 2px; background: #000; }
.sched-hline { position: absolute; height: 2px; background: #000; }
