/*! hugOS - a "web desktop" theme for Hugo - by Paradox (https://github.com/paradox-ng) - Unlicense */

/* Authentic retro bitmap font (from 98.css / XP.css), used by the '95 & XP eras */
@font-face { font-family: "Pixelated MS Sans Serif"; font-weight: 400; src: url("../fonts/ms_sans_serif.woff2") format("woff2"); }
@font-face { font-family: "Pixelated MS Sans Serif"; font-weight: 700; src: url("../fonts/ms_sans_serif_bold.woff2") format("woff2"); }

:root {
  --accent: #3daee9;          /* accent */
  --accent-dark: #2980b9;
  --win-bg: #2a2e32;          /* window surface */
  --view-bg: #1b1e20;
  --titlebar: #31363b;
  --titlebar-inactive: #2a2e32;
  --text: #eff0f1;
  --muted: #a7adba;
  --border: #1116;
  --close: #da4453;
  --radius: 8px;
  --panel-h: 46px;
  --panel-bg: #181c22e0;
  --kickoff-bg: #1c2128f2;
}

/* Light theme */
body.light {
  --win-bg: #eff0f1;
  --view-bg: #fcfcfc;
  --titlebar: #dde1e6;
  --titlebar-inactive: #eaecef;
  --text: #232629;
  --muted: #5c616c;
  --border: #00000022;
  --panel-bg: #dde1e6ee;
  --kickoff-bg: #f3f4f6f5;
}
body.light .kickoff-app:hover,
body.light .seg button.active,
body.light .btn:not(.btn-ghost) { color: #fff; }
body.light #launcher { color: #232629; }
body.light .tb-btn:hover { background: #00000014; color: #232629; }

* { box-sizing: border-box; }

/* ---------- Themed scrollbars ---------- */
* { scrollbar-width: thin; scrollbar-color: #444b59 transparent; }
::-webkit-scrollbar { width: 12px; height: 12px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb {
  background: #3c424e; border-radius: 7px;
  border: 3px solid transparent; background-clip: padding-box;
}
::-webkit-scrollbar-thumb:hover { background: #515a6b; background-clip: padding-box; }
::-webkit-scrollbar-thumb:active { background: var(--accent); background-clip: padding-box; }
::-webkit-scrollbar-corner { background: transparent; }
html, body { height: 100%; }
body {
  margin: 0;
  font: 14px/1.55 "Noto Sans", "Segoe UI", Roboto, system-ui, sans-serif;
  color: var(--text);
  overflow: hidden;
  user-select: none;
  -webkit-user-select: none;
}

/* ---------- Desktop ---------- */
#desktop {
  position: fixed;
  inset: 0 0 var(--panel-h) 0;
  background:
    radial-gradient(1200px 700px at 75% 15%, #3a4a63 0%, transparent 60%),
    radial-gradient(900px 600px at 15% 85%, #2b3b55 0%, transparent 55%),
    linear-gradient(135deg, #1a2030 0%, #232c3d 50%, #2a3447 100%);
  overflow: hidden;
}

.desktop-icons {
  position: absolute;
  top: 14px; left: 14px;
  display: flex; flex-direction: column; flex-wrap: wrap;
  gap: 6px; max-height: calc(100vh - var(--panel-h) - 28px);
}
.desk-icon {
  width: 92px; padding: 10px 6px;
  display: flex; flex-direction: column; align-items: center; gap: 6px;
  background: transparent; border: 1px solid transparent; border-radius: 6px;
  color: #fff; cursor: pointer; text-decoration: none; font: inherit;
  text-align: center;
}
.desk-icon .i { font-size: 38px; line-height: 1; filter: drop-shadow(0 1px 2px #0008); }
.desk-icon .l { font-size: 12px; text-shadow: 0 1px 3px #000a, 0 0 2px #000a; }
.desk-icon:hover { background: #3daee926; border-color: #3daee955; }
.desk-icon.selected { background: #3daee93d; border-color: var(--accent); }


/* ---------- Windows ---------- */
.window {
  position: absolute; min-width: 280px; min-height: 160px;
  width: 560px; max-width: 92vw;
  max-height: calc(100dvh - var(--panel-h) - 12px);   /* never taller than the screen; content scrolls */
  display: flex; flex-direction: column;
  background: var(--win-bg);
  border: 1px solid #0007; border-radius: var(--radius);
  box-shadow: 0 18px 50px -8px #000a, 0 6px 18px #0007;
  overflow: hidden; opacity: 0; transform: scale(.96);
  transition: opacity .14s ease, transform .16s cubic-bezier(.2,.8,.2,1);
}
/* ...but maximized / tiled windows fill the desktop exactly (no bottom gap above the panel) */
.window.maximized, .window.snapped { max-height: none; }
.window.show { opacity: 1; transform: scale(1); }
/* Minimize-to-taskbar: shrink and drop toward the panel */
.window.minimizing { opacity: 0; transform: translateY(42vh) scale(.45); }
/* Temporarily animate geometry on maximize / restore / snap */
.window.win-anim {
  transition: left .18s cubic-bezier(.2,.8,.2,1), top .18s cubic-bezier(.2,.8,.2,1),
              width .18s cubic-bezier(.2,.8,.2,1), height .18s cubic-bezier(.2,.8,.2,1),
              opacity .14s ease, transform .16s ease;
}
/* Un-snap: ease the size back while the position keeps tracking the cursor */
.window.win-unsnap { transition: width .18s cubic-bezier(.2,.8,.2,1), height .18s cubic-bezier(.2,.8,.2,1); }
.window.active { box-shadow: 0 22px 60px -6px #000c, 0 0 0 1px var(--accent); }
.window.maximized { border-radius: 0; max-width: none; }

.titlebar {
  height: 38px; flex: 0 0 38px;
  display: flex; align-items: center; gap: 8px; padding: 0 6px 0 12px;
  background: var(--titlebar-inactive); cursor: move;
  border-bottom: 1px solid #0005;
}
.window.active .titlebar { background: var(--titlebar); }
.titlebar .tb-icon { font-size: 15px; }
.titlebar .tb-title { flex: 1; font-size: 13px; font-weight: 600; color: var(--muted);
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.window.active .titlebar .tb-title { color: var(--text); }

.tb-controls { display: flex; gap: 2px; }
.tb-btn {
  width: 28px; height: 26px; border: none; background: transparent; color: var(--muted);
  border-radius: 5px; cursor: pointer; line-height: 1;
  display: grid; place-items: center;
  transition: background .12s ease, color .12s ease;
}
.tb-btn svg { width: 10px; height: 10px; fill: none; stroke: currentColor; stroke-width: 1.3; stroke-linecap: round; }
.window.active .tb-btn { color: var(--text); }
.tb-btn:hover { background: #ffffff1f; color: #fff; }
.tb-btn.close:hover { background: var(--close); color: #fff; }

.win-content {
  flex: 1; overflow: auto; background: var(--view-bg);
  user-select: text; -webkit-user-select: text;
}

/* ---------- Document styling inside windows ---------- */
.doc { padding: 22px 26px; }
.doc h1 { font-size: 1.5rem; margin: 0 0 4px; }
.doc h2 { font-size: 1.1rem; margin: 1.4em 0 .4em; color: var(--accent);
  border-bottom: 1px solid #ffffff14; padding-bottom: 4px; }
.doc p { margin: .6em 0; }
.doc a { color: var(--accent); }
.doc ul { margin: .4em 0; padding-left: 1.2em; }
.doc img { max-width: 100%; border-radius: 6px; }
.doc blockquote { border-left: 3px solid var(--accent); margin: 1em 0; padding: .2em 1em;
  background: #ffffff0a; color: var(--muted); border-radius: 0 6px 6px 0; }
.doc code { background: #ffffff12; padding: .12em .4em; border-radius: 4px; font-size: .9em; }
.muted { color: var(--muted); }
.small { font-size: .85em; }
.accent { color: var(--accent); font-weight: 600; }

.cv-head { margin-bottom: .6em; }
.cv-item { margin: .7em 0; }
.cv-row { display: flex; align-items: baseline; gap: 6px; flex-wrap: wrap; }
.cv-period { margin-left: auto; color: var(--muted); font-size: .82em; white-space: nowrap; }
.skill-group { margin: .25em 0; }

.contact-list { list-style: none; padding: 0; }
.contact-list li { padding: .35em 0; font-size: 1.02em; }

/* File-manager style (projects / blog) */
.filemanager { padding: 12px; display: grid; gap: 6px; }
.file {
  display: grid; grid-template-columns: 34px 1fr; grid-template-rows: auto auto;
  align-items: center; column-gap: 10px;
  padding: 9px 12px; border-radius: 6px; text-decoration: none; color: var(--text);
  background: transparent; border: 1px solid transparent; cursor: pointer; text-align: left;
  font: inherit; width: 100%;
}
.file:hover { background: #3daee91f; border-color: #3daee955; }
.file .fi { grid-row: 1 / 3; font-size: 26px; }
.file .fn { font-weight: 600; }
.file .fd { color: var(--muted); font-size: .85em; }

/* ---------- Panel ---------- */
#panel {
  position: fixed; left: 0; right: 0; bottom: 0; height: var(--panel-h);
  display: flex; align-items: center; gap: 6px; padding: 0 8px;
  background: var(--panel-bg); backdrop-filter: blur(12px);
  border-top: 1px solid #ffffff14; z-index: 100000;
}
#launcher {
  display: flex; align-items: center; gap: 9px; height: 36px; padding: 0 12px;
  background: transparent; border: none; color: #fff; cursor: pointer; border-radius: 6px;
}
#launcher:hover, #launcher.active { background: var(--accent); }
.dots { display: grid; grid-template-columns: repeat(3, 4px); gap: 3px; }
.dots i { width: 4px; height: 4px; background: currentColor; border-radius: 1px; display: block; }
.launcher-label { font-size: 13px; font-weight: 600; }

#tasklist { flex: 1; display: flex; align-items: center; gap: 4px; overflow: hidden; }
.task {
  display: flex; align-items: center; gap: 7px; max-width: 200px; height: 34px; padding: 0 12px;
  background: #ffffff10; border: 1px solid transparent; border-bottom: 2px solid transparent;
  color: var(--text); cursor: pointer; border-radius: 5px; font: inherit; font-size: 12.5px;
}
.task:hover { background: #ffffff1c; }
.task.active { background: #3daee926; border-bottom-color: var(--accent); }
.task.minimized { opacity: .6; }
.task .tk-title { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

#systray { display: flex; align-items: center; gap: 12px; padding: 0 4px; }
.tray-icon { font-size: 14px; opacity: .85; }
#clock { display: flex; flex-direction: column; align-items: center; line-height: 1.15;
  font-variant-numeric: tabular-nums; padding: 4px 8px; border-radius: 7px; cursor: pointer;
  transition: background .12s ease; }
#clock:hover { background: color-mix(in srgb, var(--accent) 22%, transparent); }
#clock-time { font-size: 13px; font-weight: 600; }
#clock-date { font-size: 10.5px; color: var(--muted); }

/* Show-desktop button (far right of panel) */
#show-desktop {
  align-self: stretch; width: 38px; display: grid; place-items: center;
  background: transparent; border: none; cursor: pointer; color: var(--muted);
  transition: background .12s ease, color .12s ease;
}
#show-desktop svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 1.3; stroke-linecap: round; }
#show-desktop:hover { background: color-mix(in srgb, var(--accent) 22%, transparent); color: var(--text); }

/* ---------- Kickoff ---------- */
#kickoff {
  position: fixed; left: 8px; bottom: calc(var(--panel-h) + 6px); width: 280px;
  background: var(--kickoff-bg); backdrop-filter: blur(14px);
  border: 1px solid #ffffff1f; border-radius: 10px; z-index: 100001;
  box-shadow: 0 18px 50px #000a; overflow: hidden;
  transform-origin: bottom left;
  transition: opacity .16s ease, transform .18s cubic-bezier(.2,.9,.2,1);
  opacity: 0; transform: scale(.92) translateY(10px); pointer-events: none;
}
#kickoff.open { opacity: 1; transform: none; pointer-events: auto; }
.kickoff-header { display: flex; align-items: center; gap: 12px; padding: 16px;
  background: linear-gradient(135deg, var(--accent-dark), var(--accent)); color: #fff; }
.kickoff-avatar { width: 44px; height: 44px; border-radius: 50%; background: #ffffff2a;
  display: grid; place-items: center; font-weight: 700; font-size: 16px; }
.kickoff-name { font-weight: 700; }
.kickoff-sub { font-size: 12px; opacity: .9; }
.kickoff-apps { padding: 8px; display: grid; gap: 2px; }
.kickoff-credit { border-top: 1px solid var(--border); padding: 9px 14px; display: flex; align-items: center;
  justify-content: space-between; gap: 10px; font-size: 11.5px; color: var(--muted); flex-wrap: wrap; }
.kickoff-credit b { color: var(--text); font-weight: 600; }
.kc-links { display: flex; gap: 12px; }
.kickoff-credit a { color: var(--accent); text-decoration: none; }
.kickoff-credit a:hover { text-decoration: underline; }
.kickoff-app { display: flex; align-items: center; gap: 12px; padding: 10px 12px;
  background: transparent; border: none; color: var(--text); cursor: pointer; border-radius: 6px;
  font: inherit; font-size: 14px; text-align: left; }
.kickoff-app:hover { background: var(--accent); }
.kickoff-app .i { font-size: 18px; }

/* Terminal icon */
.term-ico {
  font-family: "JetBrains Mono", "Fira Code", monospace; font-weight: 700;
  background: #14181d; color: var(--accent); border: 1px solid #3daee955;
  border-radius: 7px; padding: 4px 8px; font-size: 20px !important;
  display: inline-block; line-height: 1;
}
.kickoff-app .term-ico { font-size: 13px !important; padding: 3px 6px; }

/* Terminal app */
.terminal {
  min-height: 100%; background: #14181d; color: #d6deeb;
  font-family: "JetBrains Mono", "Fira Code", "DejaVu Sans Mono", monospace;
  font-size: 13px; line-height: 1.5; padding: 12px 14px; cursor: text;
}
.term-out { white-space: pre-wrap; word-break: break-word; }
.term-out .ln { white-space: pre-wrap; }
.term-out .cmd-echo { color: #d6deeb; }
.term-out .ok { color: #41cd8c; }
.term-out .acc { color: var(--accent); }
.term-out .warn { color: #f0c674; }
.term-out .err { color: #da4453; }
.term-out .dim { color: #7a8699; }
.term-out a { color: var(--accent); }
.term-out h3 { color: var(--accent); margin: .6em 0 .2em; font-size: 13px; }
.term-inline { display: flex; align-items: baseline; gap: 8px; }
.term-prompt { color: #41cd8c; white-space: nowrap; }
.term-prompt .term-path { color: var(--accent); }
.term-input {
  flex: 1; background: transparent; border: none; outline: none;
  color: #d6deeb; font: inherit; caret-color: var(--accent); padding: 0;
}

/* ---------- Browser app ---------- */
.browser { display: flex; flex-direction: column; height: 100%; min-height: 380px; background: var(--win-bg); }
.browser-toolbar {
  flex: 0 0 auto; display: flex; align-items: center; gap: 4px; padding: 6px 8px;
  background: var(--titlebar); border-bottom: 1px solid var(--border);
}
.bb {
  width: 30px; height: 30px; border: none; background: transparent; color: var(--text);
  border-radius: 6px; cursor: pointer; font-size: 16px; line-height: 1; display: grid; place-items: center;
}
.bb:hover:not(:disabled) { background: color-mix(in srgb, var(--text) 14%, transparent); }
.bb:disabled { opacity: .35; cursor: default; }
.url-wrap {
  flex: 1; display: flex; align-items: center; gap: 6px; height: 30px; padding: 0 10px;
  background: var(--view-bg); border: 1px solid var(--border); border-radius: 16px;
}
.url-wrap:focus-within { border-color: var(--accent); }
.url-lock { font-size: 11px; opacity: .7; }
.url-bar { flex: 1; background: transparent; border: none; outline: none; color: var(--text);
  font: inherit; font-size: 13px; }
.browser-view { flex: 1; position: relative; overflow: auto; background: var(--view-bg); }
.browser-view iframe { width: 100%; height: 100%; border: 0; display: block; background: #fff; }

/* Browser: generic "blocked" / fallback page */
.bpage { padding: 48px 28px; max-width: 540px; margin: 0 auto; text-align: center; color: var(--text); }
.bpage .big { font-size: 52px; margin-bottom: 8px; }
.bpage h2 { margin: 6px 0; }
.bpage p { color: var(--muted); }
.bpage .url { font-family: monospace; background: #ffffff10; padding: 2px 8px; border-radius: 5px; word-break: break-all; }
.bpage .btn-ext {
  display: inline-block; margin-top: 18px; background: var(--accent); color: #06101f;
  padding: 10px 18px; border-radius: 8px; font-weight: 600; text-decoration: none; border: none;
  cursor: pointer; font-size: 14px;
}
.bpage .btn-ext:hover { opacity: .9; }
.bpage .spinner { width: 34px; height: 34px; border: 3px solid #ffffff22; border-top-color: var(--accent);
  border-radius: 50%; animation: spin 1s linear infinite; margin: 0 auto 14px; }
@keyframes spin { to { transform: rotate(360deg); } }

/* Browser: home page with bookmark tiles */
.bhome { padding: 40px 24px; text-align: center; color: var(--text); }
.bhome .logo { font-size: 40px; margin-bottom: 4px; }
.bhome h2 { margin: 4px 0 22px; font-weight: 600; }
.tiles { display: flex; flex-wrap: wrap; gap: 14px; justify-content: center; }
.tile {
  width: 110px; padding: 16px 10px; background: #ffffff0c; border: 1px solid #ffffff14;
  border-radius: 12px; cursor: pointer; color: var(--text); font: inherit; display: grid; gap: 8px;
}
.tile:hover { background: #3daee91f; border-color: #3daee955; }
.tile .ti { font-size: 30px; }
.tile .tn { font-size: 13px; }

/* Browser: Hugoogle (the fake search engine) */
.hugoogle { min-height: 100%; background: #fff; color: #202124; display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 42px 20px; text-align: center; font-family: arial, "Segoe UI", sans-serif; }
.hg-logo { font-size: 56px; font-weight: 700; letter-spacing: -2px; margin-bottom: 26px; }
.hg-box { display: flex; align-items: center; gap: 10px; width: min(560px, 94%); border: 1px solid #dfe1e5; border-radius: 24px; padding: 11px 18px; box-shadow: 0 1px 6px rgba(32,33,36,.18); }
.hg-box:focus-within { box-shadow: 0 1px 10px rgba(32,33,36,.3); border-color: transparent; }
.hg-mag { opacity: .55; }
.hg-input { flex: 1; border: none; outline: none; font-size: 16px; background: transparent; color: #202124; }
.hg-btns { display: flex; gap: 12px; margin-top: 26px; flex-wrap: wrap; justify-content: center; }
.hg-btn { background: #f8f9fa; border: 1px solid #f8f9fa; border-radius: 4px; color: #3c4043; font: inherit; font-size: 14px; padding: 9px 16px; cursor: pointer; }
.hg-btn:hover { border-color: #dadce0; box-shadow: 0 1px 1px rgba(0,0,0,.1); color: #202124; }
.hg-links { display: flex; flex-wrap: wrap; gap: 6px 14px; justify-content: center; margin-top: 24px; }
.hg-link { background: none; border: none; color: #1a73e8; cursor: pointer; font: inherit; font-size: 14px; padding: 4px 6px; }
.hg-link:hover { text-decoration: underline; }
.hg-tag { margin-top: 30px; color: #70757a; font-size: 12.5px; max-width: 460px; line-height: 1.5; }
/* Hugoogle: results + lucky */
.hg-results { min-height: 100%; background: #fff; color: #202124; padding: 22px 30px 30px; font-family: arial, "Segoe UI", sans-serif; }
.hg-mini { font-size: 26px; font-weight: 700; letter-spacing: -1px; margin-bottom: 6px; }
.hg-stats { color: #70757a; font-size: 13px; margin-bottom: 12px; }
.hg-did { font-size: 14px; color: #4d5156; margin-bottom: 22px; }
.hg-result { max-width: 600px; margin-bottom: 22px; }
.hg-rurl { color: #202124; font-size: 12.5px; }
.hg-rtitle { color: #1a0dab; font-size: 18px; cursor: pointer; display: inline-block; margin: 2px 0; }
.hg-rtitle:hover { text-decoration: underline; }
.hg-result p { color: #4d5156; font-size: 13.5px; margin: 2px 0 0; line-height: 1.55; }
.hg-result code, .hg-lucky code { background: #f1f3f4; border-radius: 4px; padding: 0 4px; font-size: .92em; }
.hg-foot { margin-top: 8px; }
.hg-lucky { min-height: 100%; background: #fff; color: #3c4043; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 16px; padding: 40px; text-align: center; font-family: arial, "Segoe UI", sans-serif; }
.hg-clover { font-size: 54px; }
.hg-lucky p { font-size: 16px; max-width: 440px; line-height: 1.5; }

/* Hugoogle themed to match how Google looked in each era */
/* 1995: primitive early-web / Netscape vibe */
body.era-win95 .hugoogle, body.era-win95 .hg-results, body.era-win95 .hg-lucky { font-family: "Times New Roman", Times, serif; }
body.era-win95 .hg-logo, body.era-win95 .hg-mini { font-family: "Times New Roman", Times, serif; letter-spacing: 0; text-shadow: 1px 1px 0 #9a9a9a; }
body.era-win95 .hg-box { border: 2px inset #b0b0b0; border-radius: 0; box-shadow: none; padding: 6px 10px; }
body.era-win95 .hg-input { font-family: "Times New Roman", Times, serif; }
body.era-win95 .hg-btn { border-radius: 0; background: silver; color: #000; border: 0; box-shadow: inset -1px -1px #0a0a0a, inset 1px 1px #fff, inset -2px -2px grey, inset 2px 2px #dfdfdf; }
body.era-win95 .hg-btn:hover { background: silver; box-shadow: inset -1px -1px #0a0a0a, inset 1px 1px #fff, inset -2px -2px grey, inset 2px 2px #dfdfdf; }
body.era-win95 .hg-tag::after { content: " · Best viewed in Netscape Navigator 3.0 at 800×600."; }
body.era-win95 .hg-rtitle { color: #0000ee; text-decoration: underline; }

/* 2001: the classic shadowed-logo, beveled-button Google */
body.era-winxp .hugoogle, body.era-winxp .hg-results, body.era-winxp .hg-lucky { font-family: Arial, Helvetica, sans-serif; }
body.era-winxp .hg-logo, body.era-winxp .hg-mini { letter-spacing: -1px; text-shadow: 2px 2px 1px #b4b4b4; }
body.era-winxp .hg-box { border: 1px solid #b9b9b9; border-radius: 0; box-shadow: inset 0 1px 2px #00000022; }
body.era-winxp .hg-btn { border-radius: 2px; background: linear-gradient(#fafafa, #e6e6e6); border: 1px solid #a9a9a9; color: #000; box-shadow: inset 0 1px 0 #fff; }
body.era-winxp .hg-btn:hover { border-color: #888; color: #000; }

/* 2009: late-2000s Google - cleaner, soft shadows, gradient buttons */
body.era-win7 .hugoogle, body.era-win7 .hg-results, body.era-win7 .hg-lucky { font-family: Arial, "Helvetica Neue", sans-serif; }
body.era-win7 .hg-logo, body.era-win7 .hg-mini { text-shadow: 1px 1px 2px #cacaca; }
body.era-win7 .hg-box { border: 1px solid #ccc; border-radius: 1px; box-shadow: 0 2px 4px rgba(0,0,0,.15); }
body.era-win7 .hg-box:focus-within { box-shadow: 0 3px 8px rgba(0,0,0,.2); }
body.era-win7 .hg-btn { border-radius: 2px; background: linear-gradient(#f5f5f5, #dcdcdc); border: 1px solid #c6c6c6; color: #333; }
body.era-win7 .hg-btn:hover { border-color: #999; box-shadow: 0 1px 1px rgba(0,0,0,.1); color: #222; }

/* Browser: rendered GitHub profile */
.ghp { color: #e6edf3; font-size: 14px; max-width: 920px; margin: 0 auto; padding: 22px; }
.ghp-top { display: flex; gap: 18px; align-items: center; margin-bottom: 16px; }
.ghp-avatar { width: 80px; height: 80px; border-radius: 50%; border: 1px solid #30363d; background: #21262d; }
.ghp-name { font-size: 1.4rem; font-weight: 700; }
.ghp-login { color: #8b949e; font-weight: 400; font-size: 1.1rem; }
.ghp-bio { color: #c9d1d9; margin: 4px 0; }
.ghp-meta { color: #8b949e; font-size: 13px; display: flex; gap: 16px; flex-wrap: wrap; margin-top: 6px; }
.ghp h3 { border-bottom: 1px solid #21262d; padding-bottom: 6px; margin: 18px 0 12px; font-size: 1rem; }
.ghp-repos { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.ghp-repo { border: 1px solid #30363d; border-radius: 8px; padding: 14px; background: #0d1117; }
.ghp-repo a { color: #2f81f7; font-weight: 600; text-decoration: none; }
.ghp-repo a:hover { text-decoration: underline; }
.ghp-repo p { color: #8b949e; font-size: 12.5px; margin: 6px 0 10px; }
.ghp-repo .rmeta { color: #8b949e; font-size: 12px; display: flex; gap: 14px; }
.ghp-dot { display: inline-block; width: 10px; height: 10px; border-radius: 50%; background: #3178c6; vertical-align: middle; margin-right: 4px; }
@media (max-width: 560px) { .ghp-repos { grid-template-columns: 1fr; } }

/* ---------- Resize handles ---------- */
.rz { position: absolute; z-index: 6; }
.rz-n { top: -3px; left: 8px; right: 8px; height: 7px; cursor: ns-resize; }
.rz-s { bottom: -3px; left: 8px; right: 8px; height: 7px; cursor: ns-resize; }
.rz-e { right: -3px; top: 8px; bottom: 8px; width: 7px; cursor: ew-resize; }
.rz-w { left: -3px; top: 8px; bottom: 8px; width: 7px; cursor: ew-resize; }
.rz-ne { top: -4px; right: -4px; width: 14px; height: 14px; cursor: nesw-resize; z-index: 7; }
.rz-nw { top: -4px; left: -4px; width: 14px; height: 14px; cursor: nwse-resize; z-index: 7; }
.rz-se { bottom: -4px; right: -4px; width: 14px; height: 14px; cursor: nwse-resize; z-index: 7; }
.rz-sw { bottom: -4px; left: -4px; width: 14px; height: 14px; cursor: nesw-resize; z-index: 7; }
.window.maximized .rz { display: none; }

/* ---------- Snap preview ---------- */
#snap-preview {
  position: absolute; z-index: 99998; pointer-events: none;
  background: color-mix(in srgb, var(--accent) 16%, transparent);
  border: 2px solid var(--accent); border-radius: 8px;
  opacity: 0; transform: scale(.985);
  transition: opacity .12s ease, transform .12s ease,
              left .14s cubic-bezier(.2,.8,.2,1), top .14s cubic-bezier(.2,.8,.2,1),
              width .14s cubic-bezier(.2,.8,.2,1), height .14s cubic-bezier(.2,.8,.2,1);
}
#snap-preview.show { opacity: 1; transform: scale(1); }

/* ---------- Context menu ---------- */
#context-menu {
  position: fixed; z-index: 200000; display: none; min-width: 196px;
  background: var(--kickoff-bg); backdrop-filter: blur(12px);
  border: 1px solid var(--border); border-radius: 9px; padding: 6px;
  box-shadow: 0 16px 44px #000a;
}
#context-menu button {
  display: flex; align-items: center; gap: 10px; width: 100%; padding: 8px 12px;
  background: transparent; border: none; color: var(--text); font: inherit; font-size: 13px;
  text-align: left; border-radius: 6px; cursor: pointer;
}
#context-menu button:hover { background: var(--accent); color: #06101f; }
#context-menu .cm-ico { width: 18px; text-align: center; display: inline-block; }
#context-menu .cm-sep { height: 1px; background: var(--border); margin: 5px 6px; }

/* Launcher: icon-only (no name) */
#launcher { padding: 0 14px; }
.dots { grid-template-columns: repeat(3, 5px); gap: 4px; }
.dots i { width: 5px; height: 5px; }

/* ---------- Plain fallback pages (no-JS / SEO / direct links) ---------- */
body.plain { overflow: auto; user-select: text; -webkit-user-select: text; display: block; }
.plain-header { padding: 14px 22px; border-bottom: 1px solid var(--border); background: var(--titlebar); }
.plain-header a { color: var(--accent); font-weight: 600; }
.plain-main { max-width: 760px; margin: 0 auto; padding: 8px 22px 60px; }
.plain-main .doc { padding: 24px 0; }
.plain-list { list-style: none; padding: 0; }
.plain-list li { padding: 8px 0; border-bottom: 1px solid var(--border); }

/* ---------- Settings app ---------- */
.settings { padding: 22px 26px; }
.settings section { margin-bottom: 26px; }
.settings h3 { font-size: 12px; color: var(--muted); text-transform: uppercase; letter-spacing: .05em; margin: 0 0 12px; }
.swatches { display: flex; flex-wrap: wrap; gap: 12px; }
.swatch { width: 34px; height: 34px; border-radius: 50%; border: 2px solid transparent; cursor: pointer; padding: 0; transition: transform .1s; }
.swatch:hover { transform: scale(1.1); }
.swatch.active { border-color: var(--text); box-shadow: 0 0 0 2px var(--win-bg) inset; }
.seg { display: inline-flex; border: 1px solid var(--border); border-radius: 9px; overflow: hidden; }
.seg button { padding: 9px 18px; background: transparent; border: none; color: var(--text); cursor: pointer; font: inherit; font-size: 13px; }
.seg button.active { background: var(--accent); color: #06101f; }
.walls { display: flex; flex-wrap: wrap; gap: 12px; }
.wall { width: 92px; height: 56px; border-radius: 9px; border: 2px solid transparent; cursor: pointer; padding: 0; }
.wall:hover { border-color: var(--border); }
.wall.active { border-color: var(--accent); box-shadow: 0 0 0 2px var(--accent); }

/* ---------- Gallery ---------- */
.gallery { padding: 12px; display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 10px; }
.photo-thumb { padding: 0; border: 1px solid var(--border); background: var(--view-bg); border-radius: 8px; overflow: hidden; cursor: pointer; aspect-ratio: 4 / 3; }
.photo-thumb img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform .2s; }
.photo-thumb:hover { border-color: var(--accent); }
.photo-thumb:hover img { transform: scale(1.05); }

/* ---------- Lightbox ---------- */
#lightbox {
  position: fixed; inset: 0; z-index: 300000;
  display: grid; grid-template-rows: 1fr auto; place-items: center;
  background: #000000a6; backdrop-filter: blur(5px);
  opacity: 0; pointer-events: none; transition: opacity .2s ease;
}
#lightbox.show { opacity: 1; pointer-events: auto; }
#lightbox .lb-img {
  max-width: 90vw; max-height: 80vh; border-radius: 8px; box-shadow: 0 24px 70px #000;
  transition: transform .2s ease;
}
#lightbox:not(.show) .lb-img { transform: scale(.9); }      /* scale-in on open */
.lb-img.slide-r { animation: lbSlideR .24s ease; }
.lb-img.slide-l { animation: lbSlideL .24s ease; }
@keyframes lbSlideR { from { opacity: 0; transform: translateX(48px); } to { opacity: 1; transform: translateX(0); } }
@keyframes lbSlideL { from { opacity: 0; transform: translateX(-48px); } to { opacity: 1; transform: translateX(0); } }
#lightbox .lb-cap { color: #fff; padding: 14px; font-size: 14px; }
#lightbox .lb-counter { position: absolute; top: 18px; left: 22px; color: #fff; font-size: 13px; background: #0006; padding: 5px 12px; border-radius: 999px; }
#lightbox .lb-close { position: absolute; top: 14px; right: 18px; font-size: 22px; }
#lightbox .lb-nav { position: absolute; top: 50%; transform: translateY(-50%); font-size: 30px; width: 52px; height: 52px; }
#lightbox .lb-prev { left: 16px; } #lightbox .lb-next { right: 16px; }
#lightbox .lb-close, #lightbox .lb-nav { color: #fff; background: #ffffff1f; border: none; border-radius: 50%; cursor: pointer; display: grid; place-items: center; line-height: 1; }
#lightbox .lb-close { width: 44px; height: 44px; }
#lightbox button:hover { background: var(--accent); color: #06101f; }

/* ---------- Calendar popup ---------- */
#calendar {
  position: fixed; right: 8px; bottom: calc(var(--panel-h) + 6px); width: 262px; z-index: 100001;
  background: var(--kickoff-bg); backdrop-filter: blur(14px);
  border: 1px solid #ffffff1f; border-radius: 10px; padding: 12px;
  box-shadow: 0 18px 50px #000a; color: var(--text);
}
.cal-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 8px; }
.cal-title { font-weight: 600; }
.cal-head button { width: 28px; height: 28px; border: none; background: transparent; color: var(--text); border-radius: 6px; cursor: pointer; font-size: 16px; }
.cal-head button:hover { background: #ffffff1c; }
.cal-grid { display: grid; grid-template-columns: repeat(7, 1fr); gap: 2px; text-align: center; }
.cal-grid > span { padding: 6px 0; font-size: 12.5px; border-radius: 6px; }
.cal-dow { color: var(--muted); font-size: 11px; font-weight: 600; }
.cal-day:hover { background: #ffffff14; }
.cal-day.today { background: var(--accent); color: #06101f; font-weight: 700; }
.cal-foot { display: flex; gap: 6px; margin-top: 10px; }
.cal-today, .cal-travel { flex: 1; padding: 7px; border: none; border-radius: 7px; background: #ffffff12; color: var(--text); cursor: pointer; font: inherit; font-size: 12.5px; white-space: nowrap; }
.cal-today:hover, .cal-travel:hover { background: var(--accent); color: #06101f; }

/* ---------- Calculator ---------- */
.calc { display: flex; flex-direction: column; height: 100%; min-height: 360px; padding: 10px; gap: 10px; }
.calc-display {
  background: var(--view-bg); border-radius: 10px; padding: 18px 16px; text-align: right;
  font-size: 2.1rem; font-weight: 600; overflow: hidden; word-break: break-all;
  font-variant-numeric: tabular-nums; min-height: 64px; display: flex; align-items: center; justify-content: flex-end;
}
.calc-keys { flex: 1; display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; }
.ckey { border: none; border-radius: 10px; cursor: pointer; font: inherit; font-size: 1.15rem;
  background: var(--titlebar); color: var(--text); transition: filter .1s ease, background .1s ease; }
.ckey:hover { filter: brightness(1.15); }
.ckey:active { filter: brightness(.92); }
.ckey.fn { background: var(--win-bg); color: var(--muted); }
.ckey.op { background: #3daee933; color: var(--accent); font-weight: 700; }
.ckey.eq { background: var(--accent); color: #06101f; font-weight: 700; }
.ckey.wide { grid-column: span 2; }

/* ---------- Sticky notes ---------- */
.sticky-board { padding: 14px; display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 12px; align-content: start; }
.sticky { position: relative; border-radius: 6px; box-shadow: 0 4px 12px #0004; aspect-ratio: 1 / 1; }
.sticky textarea {
  width: 100%; height: 100%; border: none; background: transparent; resize: none; outline: none;
  padding: 26px 12px 12px; font: inherit; font-size: 13px; color: #1a1a1a; line-height: 1.4;
}
.sticky-del { position: absolute; top: 4px; right: 4px; width: 20px; height: 20px; border: none; border-radius: 5px;
  background: #00000012; color: #00000088; cursor: pointer; font-size: 11px; line-height: 1; opacity: 0; transition: opacity .12s; }
.sticky:hover .sticky-del { opacity: 1; }
.sticky-del:hover { background: #da445399; color: #fff; }
.sticky-add { aspect-ratio: 1 / 1; border: 2px dashed var(--border); background: transparent; color: var(--muted);
  border-radius: 6px; cursor: pointer; font-size: 28px; transition: border-color .12s, color .12s; }
.sticky-add:hover { border-color: var(--accent); color: var(--accent); }

/* ---------- System monitor ---------- */
.sysmon { padding: 18px 20px; }
.sm-head { display: flex; align-items: center; gap: 12px; margin-bottom: 18px; }
.sm-logo { font-size: 30px; }
.sm-title { font-weight: 700; }
.sm-sub { color: var(--muted); font-size: 12px; }
.sm-row { margin: 14px 0; }
.sm-top { display: flex; justify-content: space-between; font-size: 13px; margin-bottom: 5px; }
.sm-val { color: var(--muted); font-variant-numeric: tabular-nums; }
.sm-bar { height: 9px; background: var(--view-bg); border-radius: 6px; overflow: hidden; }
.sm-bar i { display: block; height: 100%; background: var(--accent); border-radius: 6px; transition: width .8s ease; }
.sm-foot { margin-top: 18px; color: var(--muted); font-size: 12px; font-variant-numeric: tabular-nums; }

/* ---------- Wiki ---------- */
/* The handbook (wiki) needs room for a sidebar + readable column - open it wider/taller */
.window[data-type="wiki"] { width: 920px; height: 620px; }
/* The terminal opens as a big, near-square window */
.window[data-type="terminal"] { width: 720px; height: 620px; }
/* About opens as a small window; its content scrolls */
.window[data-app="about"] { width: 520px; height: 560px; }
.wiki { display: flex; height: 100%; min-height: 320px; }
.wiki-side { width: 210px; flex: 0 0 210px; border-right: 1px solid var(--border); padding: 12px; overflow: auto; background: var(--win-bg); }
.wiki-search { width: 100%; padding: 7px 10px; margin-bottom: 10px; border: 1px solid var(--border); border-radius: 7px;
  background: var(--view-bg); color: var(--text); font: inherit; font-size: 13px; outline: none; }
.wiki-search:focus { border-color: var(--accent); }
.wiki-nav { list-style: none; margin: 0; padding: 0; }
.wiki-nav li { margin: 1px 0; }
.wiki-link { width: 100%; text-align: left; padding: 7px 10px; border: none; background: transparent; color: var(--text);
  font: inherit; font-size: 13px; border-radius: 6px; cursor: pointer; }
.wiki-link:hover { background: #3daee91f; }
.wiki-link.active { background: var(--accent); color: #06101f; font-weight: 600; }
.wiki-main { flex: 1; overflow: auto; }
.wiki-page { padding: 22px 26px; }

/* ---------- Trash ---------- */
.trash { height: 100%; min-height: 300px; }
.trash-empty { height: 100%; min-height: 300px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 6px; padding: 30px; text-align: center; }
.trash-icon { font-size: 70px; opacity: .85; }
.trash-msg { font-size: 1.2rem; font-weight: 600; }
.trash-sub { color: var(--muted); font-size: 13px; max-width: 36ch; min-height: 1.4em; }
.trash-btn { margin-top: 14px; background: var(--accent); color: #06101f; border: none; padding: 9px 18px;
  border-radius: 8px; font: inherit; font-weight: 600; cursor: pointer; }
.trash-btn:hover { filter: brightness(1.1); }
.secret { font-family: "JetBrains Mono", monospace; font-size: 13px; line-height: 1.5; white-space: pre-wrap;
  color: var(--text); background: var(--view-bg); padding: 16px; border-radius: 8px; }

/* ---------- Time travel: overlay (dialog + loading) ---------- */
#timewarp { position: fixed; inset: 0; z-index: 400000; display: none; place-items: center;
  background: #0009; backdrop-filter: blur(3px); }
#timewarp.show { display: grid; }
.tw-dialog { background: var(--kickoff-bg); border: 1px solid var(--border); border-radius: 12px;
  padding: 24px; width: 340px; max-width: 90vw; text-align: center; box-shadow: 0 20px 60px #000a; }
.tw-dialog h2 { margin: 0 0 4px; }
.tw-sub { color: var(--muted); font-size: 13px; margin: 0 0 18px; }
.tw-years { display: grid; gap: 8px; margin-bottom: 14px; }
.tw-year { display: flex; flex-direction: column; gap: 2px; padding: 11px; border: 1px solid var(--border);
  border-radius: 10px; background: var(--view-bg); color: var(--text); cursor: pointer; font: inherit; }
.tw-year b { font-size: 1.25rem; }
.tw-year span { font-size: 12px; color: var(--muted); }
.tw-year:not(:disabled):hover { border-color: var(--accent); background: color-mix(in srgb, var(--accent) 12%, transparent); }
.tw-year.tw-soon { opacity: .5; cursor: default; }
.tw-cancel { background: transparent; border: none; color: var(--muted); cursor: pointer; font: inherit; padding: 6px 14px; }
.tw-cancel:hover { color: var(--text); }
.tw-loading { text-align: center; color: #fff; }
.tw-logo { font-size: 56px; animation: twPulse 1.2s ease-in-out infinite; }
@keyframes twPulse { 0%,100% { transform: scale(1); } 50% { transform: scale(1.12); } }
.tw-text { font-size: 1.15rem; margin: 14px 0 18px; }
.tw-bar { width: 300px; max-width: 80vw; height: 12px; background: #ffffff22; border-radius: 7px; overflow: hidden; margin: 0 auto; }
.tw-bar i { display: block; height: 100%; width: 0; background: linear-gradient(90deg, #41cd8c, #3daee9); }

/* ---- Per-era boot splashes (shown while time-travelling) ---- */
/* The hugOS waving flag (4 gapped panes) - single source of truth, reused by the Start orb and boot splashes */
:root { --flag: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 285 265'%3E%3Cpath d='M45,62 C85,44 120,42 138,56 L138,124 C120,110 85,112 45,130 Z' fill='%23f0501f'/%3E%3Cpath d='M146,56 C170,72 205,74 238,58 L238,126 C205,142 170,140 146,124 Z' fill='%237cbb00'/%3E%3Cpath d='M45,138 C85,120 120,118 138,132 L138,200 C120,186 85,188 45,206 Z' fill='%2321a9e1'/%3E%3Cpath d='M146,132 C170,148 205,150 238,134 L238,202 C205,218 170,216 146,200 Z' fill='%23ffba00'/%3E%3C/svg%3E"); }
.tw-splash { display: none; flex-direction: column; align-items: center; gap: 12px; margin-bottom: 10px; }
.tw-flag { background: var(--flag) center / contain no-repeat; }
#timewarp[class*="boot-"] { background: #000; backdrop-filter: none; animation: bootFade .5s ease; }
@keyframes bootFade { from { opacity: 0; } }
#timewarp[class*="boot-"] .tw-logo { display: none; }
#timewarp[class*="boot-"] .tw-splash { display: flex; }
/* Win95 */
#timewarp.boot-win95 .tw-flag { width: 88px; height: 74px; }
#timewarp.boot-win95 .tw-word { font-family: "Pixelated MS Sans Serif", sans-serif; font-size: 30px; color: #fff; text-shadow: 2px 2px #4a4a4a; }
#timewarp.boot-win95 .tw-text { font-family: "Pixelated MS Sans Serif", sans-serif; font-size: .95rem; }
#timewarp.boot-win95 .tw-bar { height: 16px; background: #181818; border: 2px solid #8a8a8a; border-radius: 0; padding: 2px; }
#timewarp.boot-win95 .tw-bar i { border-radius: 0; background: repeating-linear-gradient(90deg, #000086 0 11px, transparent 11px 14px); }
/* WinXP */
#timewarp.boot-winxp .tw-flag { width: 98px; height: 82px; filter: drop-shadow(0 2px 7px #0009); }
#timewarp.boot-winxp .tw-word { font-family: "Franklin Gothic Medium", "Trebuchet MS", sans-serif; font-size: 38px; font-weight: 600; color: #fff; }
#timewarp.boot-winxp .tw-word::after { content: "\00ae"; font-size: .45em; vertical-align: super; margin-left: 2px; }
#timewarp.boot-winxp .tw-text { color: #d6d6ea; }
#timewarp.boot-winxp .tw-bar { position: relative; width: 150px; height: 16px; background: #07070f; border: 2px solid #34345a; border-radius: 4px; padding: 0; overflow: hidden; }
#timewarp.boot-winxp .tw-bar i { display: none; }
#timewarp.boot-winxp .tw-bar::after { content: ""; position: absolute; top: 2px; bottom: 2px; left: 0; width: 44px; border-radius: 2px;
  background: repeating-linear-gradient(90deg, #2a6fe0 0 10px, transparent 10px 15px); animation: xpBoot 1.25s linear infinite; }
@keyframes xpBoot { from { transform: translateX(-46px); } to { transform: translateX(152px); } }
/* Win7 */
#timewarp.boot-win7 { background: radial-gradient(circle at 50% 44%, #0c1838 0%, #000 72%); }
#timewarp.boot-win7 .tw-flag { width: 86px; height: 76px; filter: drop-shadow(0 0 14px rgba(80, 160, 255, .85)); }
#timewarp.boot-win7 .tw-word { font-family: "Segoe UI", "Tahoma", sans-serif; font-weight: 300; font-size: 28px; color: #dcecff; letter-spacing: .5px; }
#timewarp.boot-win7 .tw-text { color: #bcd6f5; font-weight: 300; }
#timewarp.boot-win7 .tw-bar { background: #ffffff1a; }
#timewarp.boot-win7 .tw-bar i { background: linear-gradient(90deg, #3aa0ff, #9ad4ff); }

/* ---- Clippy (XP assistant easter egg) ---- */
#clippy { position: fixed; right: 18px; bottom: calc(var(--panel-h) + 14px); z-index: 99999; width: 224px; display: none; flex-direction: column; align-items: flex-end; gap: 4px; }
#clippy.show { display: flex; animation: clippyIn .4s ease; }
@keyframes clippyIn { from { transform: translateY(24px) scale(.8); opacity: 0; } }
.clippy-bubble { position: relative; align-self: stretch; background: #ffffe1; border: 1px solid #cbb978; border-radius: 8px; padding: 10px 26px 10px 12px; font: 12.5px/1.45 "Tahoma", "Trebuchet MS", sans-serif; color: #222; box-shadow: 0 8px 22px #0006; }
.clippy-bubble::before { content: ""; position: absolute; right: 28px; bottom: -11px; border: 10px solid transparent; border-top-color: #cbb978; border-bottom: 0; }
.clippy-bubble::after { content: ""; position: absolute; right: 29px; bottom: -9px; border: 9px solid transparent; border-top-color: #ffffe1; border-bottom: 0; }
.clippy-x { position: absolute; top: 3px; right: 5px; border: none; background: none; cursor: pointer; color: #998; font-size: 15px; line-height: 1; padding: 0; }
.clippy-x:hover { color: #222; }
.clippy-clip { width: 54px; height: 82px; margin-right: 14px; border: none; background: none; padding: 0; cursor: pointer; filter: drop-shadow(2px 3px 2px #0004); animation: clippyBob 3s ease-in-out infinite; }
.clippy-clip svg { width: 100%; height: 100%; display: block; }
.clippy-clip:hover { animation-play-state: paused; }
@keyframes clippyBob { 0%, 100% { transform: translateY(0) rotate(0); } 50% { transform: translateY(-5px) rotate(-3deg); } }

/* ---- Windows Update gag (plays on arriving in Win7) ---- */
#winupdate { position: fixed; inset: 0; z-index: 450000; display: grid; place-items: center; text-align: center;
  opacity: 0; visibility: hidden; transition: opacity .55s ease, visibility .55s;
  background: radial-gradient(circle at 50% 42%, #2c5d88 0%, #163f60 65%, #0c2438 100%); color: #fff;
  font-family: "Segoe UI", "Tahoma", sans-serif; font-weight: 300; }
#winupdate.show { opacity: 1; visibility: visible; }
.wu-title { font-size: 1.75rem; margin-top: 30px; }
.wu-pct { font-size: 1.15rem; margin-top: 12px; opacity: .95; }
.wu-warn { font-size: 1.05rem; margin-top: 26px; opacity: .82; }
.wu-ring { width: 60px; height: 60px; margin: 0 auto; position: relative; animation: wuSpin 1s linear infinite; }
.wu-ring i { position: absolute; top: 0; left: 50%; width: 9px; height: 9px; margin-left: -4.5px; border-radius: 50%; background: #dcecff; transform-origin: 4.5px 30px; }
.wu-ring i:nth-child(1) { transform: rotate(0deg); opacity: 1; }
.wu-ring i:nth-child(2) { transform: rotate(55deg); opacity: .82; }
.wu-ring i:nth-child(3) { transform: rotate(110deg); opacity: .64; }
.wu-ring i:nth-child(4) { transform: rotate(165deg); opacity: .46; }
.wu-ring i:nth-child(5) { transform: rotate(220deg); opacity: .3; }
.wu-ring i:nth-child(6) { transform: rotate(275deg); opacity: .16; }
@keyframes wuSpin { to { transform: rotate(360deg); } }

/* =======================================================================
   Time travel: Windows 95 skin (scoped to body.era-win95)
   ======================================================================= */
body.era-win95 {
  --win-bg: #c0c0c0; --view-bg: #ffffff; --titlebar: #000080; --titlebar-inactive: #7b7b7b;
  --text: #000000; --muted: #404040; --border: #000000; --accent: #000080;
  --panel-bg: #c0c0c0; --kickoff-bg: #c0c0c0; --radius: 0;
  font-family: "Pixelated MS Sans Serif", "MS Sans Serif", Tahoma, sans-serif;
}
body.era-win95 #desktop { background: #008080 !important; }
body.era-win95 .window {
  border: none; border-radius: 0; background: silver;
  box-shadow: inset -1px -1px #0a0a0a, inset 1px 1px #dfdfdf, inset -2px -2px grey, inset 2px 2px #fff, 2px 2px 6px #0006;
  transition: none !important;   /* '95 had no window animations */
}
body.era-win95 .window.minimizing { transform: none; }
body.era-win95 .titlebar { background: linear-gradient(90deg, navy, #1084d0); border-bottom: none; padding-left: 4px; }
body.era-win95 .window:not(.active) .titlebar { background: linear-gradient(90deg, grey, #b5b5b5); }
body.era-win95 .titlebar .tb-title, body.era-win95 .tb-icon { color: #fff; }
body.era-win95 .tb-btn { width: 20px; height: 18px; border-radius: 0; background: #c0c0c0; color: #000;
  border: 1px solid #fff; border-right-color: #000; border-bottom-color: #000; box-shadow: inset -1px -1px 0 #808080; margin-left: 2px; }
body.era-win95 .tb-btn:hover { background: #c0c0c0; filter: none; }
body.era-win95 .tb-btn:active { box-shadow: inset 1px 1px 0 #808080; }
body.era-win95 .tb-btn svg { stroke: #000; stroke-width: 1.5; }
body.era-win95 .tb-btn.close:hover { background: #c0c0c0; color: #000; }
body.era-win95 #panel { background: #c0c0c0; border-top: 2px solid #fff; backdrop-filter: none; }
body.era-win95 .task { background: #c0c0c0; color: #000; border: 1px solid #fff; border-right-color: #000;
  border-bottom-color: #000; box-shadow: inset -1px -1px 0 #808080; border-radius: 0; }
body.era-win95 .task.active { box-shadow: inset 1px 1px 0 #808080; }
body.era-win95 #launcher { background: #c0c0c0; color: #000; font-weight: 700; border: 1px solid #fff;
  border-right-color: #000; border-bottom-color: #000; box-shadow: inset -1px -1px 0 #808080; border-radius: 0; gap: 6px; }
body.era-win95 #launcher:hover, body.era-win95 #launcher.active { background: #c0c0c0; }
body.era-win95 #launcher .dots { display: none; }
body.era-win95 #launcher::before { content: ""; width: 17px; height: 14px; flex: 0 0 auto; transform: skewX(-8deg);
  background:
    linear-gradient(#ff3b3b, #ff3b3b) 0 0 / 8px 6.5px no-repeat,
    linear-gradient(#41cd5c, #41cd5c) 9px 0 / 8px 6.5px no-repeat,
    linear-gradient(#3b7bff, #3b7bff) 0 7.5px / 8px 6.5px no-repeat,
    linear-gradient(#ffd23b, #ffd23b) 9px 7.5px / 8px 6.5px no-repeat; }
body.era-win95 #launcher::after { content: "Start"; }
body.era-win95 #systray { border: 1px solid #808080; box-shadow: inset 1px 1px 0 #fff; }
body.era-win95 #clock { color: #000; }
body.era-win95 #clock:hover { background: transparent; }
body.era-win95 #show-desktop { color: #000; }
body.era-win95 #show-desktop:hover { background: #00000018; }
body.era-win95 #kickoff, body.era-win95 #context-menu, body.era-win95 #calendar {
  background: #c0c0c0; color: #000; border: 2px solid #fff; border-right-color: #000; border-bottom-color: #000; border-radius: 0; }
body.era-win95 .kickoff-header { background: #000080; }
body.era-win95 #context-menu button { color: #000; }
body.era-win95 #context-menu button:hover { background: #000080; color: #fff; }
body.era-win95 .desk-icon .l { text-shadow: 1px 1px 1px #000; }
body.era-win95 .win-content, body.era-win95 .doc, body.era-win95 .filemanager { border-radius: 0; }

/* --- Win95 fixes: title, button centering, readability, hidden apps --- */
body.era-win95 .window.active .titlebar .tb-title { color: #fff; }   /* keep title white when focused */
body.era-win95 .tb-controls { align-items: center; }
body.era-win95 .tb-btn { display: grid; place-items: center; padding: 0; }

/* Hide apps that don't suit the era */
body.era-win95 .desk-icon[data-window="settings"],
body.era-win95 .desk-icon[data-window="terminal"],
body.era-win95 .desk-icon[data-window="stickies"],
body.era-win95 .kickoff-app[data-window="settings"],
body.era-win95 .kickoff-app[data-window="terminal"],
body.era-win95 .kickoff-app[data-window="stickies"] { display: none; }

/* Minesweeper: a '95-only app (it just... crashes 💣) */
.desk-icon[data-window="minesweeper"], .kickoff-app[data-window="minesweeper"] { display: none; }
body.era-win95 .desk-icon[data-window="minesweeper"] { display: flex; }
body.era-win95 .kickoff-app[data-window="minesweeper"] { display: flex; }

/* Text sitting on the navy accent -> white */
body.era-win95 .kickoff-app:hover,
body.era-win95 .cal-today:hover, body.era-win95 .cal-travel:hover,
body.era-win95 .cal-day.today { color: #fff; }

/* Calculator -> grey beveled keys */
body.era-win95 .calc-display { background: #fff; color: #000; border: 1px solid #808080; box-shadow: inset 1px 1px 0 #00000022; border-radius: 0; }
body.era-win95 .ckey { background: #c0c0c0; color: #000; border: 1px solid #fff; border-right-color: #000; border-bottom-color: #000; box-shadow: inset -1px -1px 0 #808080; border-radius: 0; }
body.era-win95 .ckey:hover { filter: none; }
body.era-win95 .ckey:active { box-shadow: inset 1px 1px 0 #808080; }
body.era-win95 .ckey.op { color: #000080; }
body.era-win95 .ckey.eq { background: #000080; color: #fff; }

/* Trash button + Handbook active link -> readable */
body.era-win95 .trash-btn { background: #c0c0c0; color: #000; border: 1px solid #fff; border-right-color: #000; border-bottom-color: #000; box-shadow: inset -1px -1px 0 #808080; border-radius: 0; }
body.era-win95 .trash-btn:hover { filter: none; background: #c0c0c0; }
body.era-win95 .wiki-link.active { background: #000080; color: #fff; }
body.era-win95 .wiki-link:hover { background: #000080; color: #fff; }

/* Browser toolbar -> grey (not the navy titlebar colour) */
body.era-win95 .browser-toolbar { background: #c0c0c0; border-bottom: 1px solid #808080; }
body.era-win95 .bb { color: #000; }
body.era-win95 .bb:hover:not(:disabled) { background: #00000018; }
body.era-win95 .url-wrap { background: #fff; border: 1px solid #808080; box-shadow: inset 1px 1px 0 #00000022; border-radius: 2px; }

/* =======================================================================
   Time travel: Windows XP (Luna) skin
   ======================================================================= */
body.era-winxp {
  --win-bg: #ece9d8; --view-bg: #ffffff; --titlebar: #0a5bd3; --titlebar-inactive: #9db8e8;
  --text: #000000; --muted: #4a4a4a; --border: #4a7bc7; --accent: #1a64d6;
  --panel-bg: #2157d4; --kickoff-bg: #ffffff; --radius: 6px;
  font-family: Tahoma, Verdana, Geneva, sans-serif;
}
body.era-winxp #desktop {
  background:
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='1440' height='500' viewBox='0 0 1440 500' preserveAspectRatio='none'%3E%3Cdefs%3E%3ClinearGradient id='h' x1='0' y1='0' x2='0' y2='1'%3E%3Cstop offset='0' stop-color='%2391c95a'/%3E%3Cstop offset='0.5' stop-color='%2369aa3e'/%3E%3Cstop offset='1' stop-color='%23508730'/%3E%3C/linearGradient%3E%3C/defs%3E%3Cpath d='M0,215 C250,118 520,112 780,182 C1040,252 1245,250 1440,205 L1440,500 L0,500 Z' fill='url(%23h)'/%3E%3C/svg%3E") left bottom / 100% 46% no-repeat,
    linear-gradient(180deg, #2766cf 0%, #4f8ce4 28%, #94bcef 50%, #cfe3fb 66%, #eef6ff 80%, #ffffff 100%) !important;
}
body.era-winxp .window { border: 1px solid #0831d9; border-top: none; border-radius: 8px 8px 0 0; box-shadow: 0 8px 26px #0006; }
body.era-winxp .titlebar {
  background: linear-gradient(180deg,#0997ff,#0053ee 8%,#0050ee 40%,#06f 88%,#06f 93%,#005bff 95%,#003dd7 96%,#003dd7);
  border-bottom: none; border-radius: 8px 8px 0 0;
  border-top: 1px solid #0831d9; border-left: 1px solid #0831d9; border-right: 1px solid #001ea0;
}
body.era-winxp .titlebar .tb-title { font-family: "Trebuchet MS", Tahoma, sans-serif; text-shadow: 1px 1px #0f1089; }
body.era-winxp .window:not(.active) .titlebar { background: linear-gradient(180deg, #c3d6f4, #87a9e3); }
body.era-winxp .titlebar .tb-title { color: #fff; font-weight: 700; text-shadow: 1px 1px 1px #00000066; }
body.era-winxp .tb-btn {
  width: 22px; height: 21px; border-radius: 4px; border: 1px solid #ffffffaa; color: #fff;
  background: linear-gradient(180deg, #5a9bff, #1559dd); box-shadow: inset 0 1px 0 #ffffff88;
}
body.era-winxp .tb-btn svg { stroke: #fff; stroke-width: 1.7; }
body.era-winxp .tb-btn { display: grid; place-items: center; padding: 0; }
body.era-winxp .window.active .titlebar .tb-title { color: #fff; }   /* keep title white when focused */
body.era-winxp .tb-btn:hover { filter: brightness(1.12); }
body.era-winxp .tb-btn.close { background: linear-gradient(180deg, #f0916f, #d54a28); }
body.era-winxp .tb-btn.close:hover { background: linear-gradient(180deg, #f6a98c, #e0552f); filter: none; }
/* Taskbar */
body.era-winxp #panel {
  background: linear-gradient(180deg, #3f8cf3 0, #2157d4 9%, #1c4dc4 50%, #1842b8 92%, #2563e0 100%);
  border-top: 1px solid #5c9bff; backdrop-filter: none;
}
body.era-winxp .task { background: linear-gradient(180deg, #4a8df0, #2a63d8); color: #fff; border: 1px solid #1a47ad; border-radius: 4px; box-shadow: inset 0 1px 0 #ffffff44; }
body.era-winxp .task.active { background: linear-gradient(180deg, #214fb0, #3f7de8); box-shadow: inset 0 1px 3px #00000055; }
/* Green Start button */
body.era-winxp #launcher {
  background: linear-gradient(180deg, #79c95a 0, #4ca22e 52%, #3d8a23 100%);
  color: #fff; font-style: italic; font-weight: 700; font-size: 15px;
  border: 1px solid #2f6e1a; border-left: none; border-radius: 0 13px 13px 0; box-shadow: inset 0 1px 0 #ffffff66;
  text-shadow: 1px 1px 1px #00000066; gap: 8px; padding: 0 28px 0 16px;
  align-self: stretch; height: auto; margin: 0 4px 0 -8px;   /* flush to the left edge, full taskbar height */
}
body.era-winxp #launcher:hover, body.era-winxp #launcher.active { background: linear-gradient(180deg, #86d466, #55ab37); }
body.era-winxp #launcher .dots { display: none; }
body.era-winxp #launcher::before {
  content: ""; width: 18px; height: 16px; flex: 0 0 auto; border-radius: 3px; transform: skewX(-6deg);
  background:
    linear-gradient(#f55, #e33) 0 0 / 8px 7px no-repeat,
    linear-gradient(#6c6, #3a3) 9px 0 / 8px 7px no-repeat,
    linear-gradient(#59f, #37d) 0 8px / 8px 7px no-repeat,
    linear-gradient(#fd5, #fb3) 9px 8px / 8px 7px no-repeat;
}
body.era-winxp #launcher::after { content: "start"; }
/* Tray + clock */
body.era-winxp #systray { background: linear-gradient(180deg, #18a0e8, #1574d6); border-left: 1px solid #0d52a8; box-shadow: inset 1px 0 0 #5cc0ff; border-radius: 0; padding: 0 10px; }
body.era-winxp #clock { color: #fff; }
body.era-winxp #clock:hover { background: #ffffff26; }
body.era-winxp #show-desktop { color: #fff; }
body.era-winxp #show-desktop:hover { background: #ffffff26; }
/* Beige controls */
body.era-winxp .trash-btn, body.era-winxp .cal-today, body.era-winxp .cal-travel, body.era-winxp .ckey, body.era-winxp .tw-year {
  background: linear-gradient(180deg, #ffffff, #ece9d8); color: #000; border: 1px solid #7f9db9; border-radius: 4px; }
body.era-winxp .ckey.op { color: #1a3e8c; }
body.era-winxp .ckey.eq { background: linear-gradient(180deg, #5a9bff, #1559dd); color: #fff; }
body.era-winxp .trash-btn:hover, body.era-winxp .ckey:hover, body.era-winxp .cal-today:hover, body.era-winxp .cal-travel:hover {
  filter: none; border-color: #f0a000; background: linear-gradient(180deg, #fff, #fdf2d4); color: #000; }
body.era-winxp .calc-display { background: #fff; color: #000; border: 1px solid #7f9db9; }
/* Start menu / popups */
body.era-winxp #kickoff { border: 1px solid #0831d9; border-radius: 8px 8px 0 0; }
body.era-winxp .kickoff-header { background: linear-gradient(180deg, #2e8aff, #0a4bd6); }
body.era-winxp #context-menu, body.era-winxp #calendar { background: #fff; color: #000; border: 1px solid #4a7bc7; }
body.era-winxp #context-menu button:hover { background: #2f6fd6; color: #fff; }
body.era-winxp .wiki-link.active, body.era-winxp .cal-day.today { background: #2f6fd6; color: #fff; }
body.era-winxp .cal-today:hover, body.era-winxp .cal-travel:hover { color: #000; }
/* Browser toolbar -> beige */
body.era-winxp .browser-toolbar { background: linear-gradient(180deg, #f5f4ec, #ddd9c3); border-bottom: 1px solid #9b977f; }
body.era-winxp .bb { color: #000; }
body.era-winxp .bb:hover:not(:disabled) { background: #00000012; }
body.era-winxp .url-wrap { background: #fff; border: 1px solid #7f9db9; border-radius: 3px; }
/* Hide ill-fitting apps; show Minesweeper */
body.era-winxp .desk-icon[data-window="settings"], body.era-winxp .desk-icon[data-window="terminal"], body.era-winxp .desk-icon[data-window="stickies"],
body.era-winxp .kickoff-app[data-window="settings"], body.era-winxp .kickoff-app[data-window="terminal"], body.era-winxp .kickoff-app[data-window="stickies"] { display: none; }
body.era-winxp .desk-icon[data-window="minesweeper"] { display: flex; }
body.era-winxp .kickoff-app[data-window="minesweeper"] { display: flex; }

/* =======================================================================
   Time travel: Windows 7 (Aero glass) skin
   ======================================================================= */
body.era-win7 {
  --win-bg: #ffffff; --view-bg: #ffffff; --titlebar: #d6e6f7; --titlebar-inactive: #e8eef5;
  --text: #1a1a1a; --muted: #5a5a5a; --border: #88a8d0; --accent: #2f7fdb;
  --panel-bg: rgba(20, 38, 66, 0.55); --kickoff-bg: rgba(244, 249, 255, 0.94); --radius: 8px;
  font-family: "Segoe UI", "Selawik", "Open Sans", Tahoma, sans-serif;
}
/* Win7 wallpaper lives on a fixed full-screen backdrop so the panel's backdrop-filter
   has pixels to blur, WITHOUT letting windows/icons extend behind the taskbar
   (the desktop itself keeps its default bottom inset above the panel). */
body.era-win7 #desktop { background: transparent; }
body.era-win7::before {
  content: ""; position: fixed; inset: 0; z-index: -1; pointer-events: none;
  background:
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 285 265'%3E%3Cdefs%3E%3CclipPath id='fc'%3E%3Cpath d='M45,62 C85,44 120,42 138,56 L138,124 C120,110 85,112 45,130 Z'/%3E%3Cpath d='M146,56 C170,72 205,74 238,58 L238,126 C205,142 170,140 146,124 Z'/%3E%3Cpath d='M45,138 C85,120 120,118 138,132 L138,200 C120,186 85,188 45,206 Z'/%3E%3Cpath d='M146,132 C170,148 205,150 238,134 L238,202 C205,218 170,216 146,200 Z'/%3E%3C/clipPath%3E%3ClinearGradient id='gl' x1='0' y1='0' x2='0' y2='1'%3E%3Cstop offset='0' stop-color='%23fff' stop-opacity='0.5'/%3E%3Cstop offset='0.42' stop-color='%23fff' stop-opacity='0.08'/%3E%3Cstop offset='1' stop-color='%23fff' stop-opacity='0'/%3E%3C/linearGradient%3E%3C/defs%3E%3Cpath d='M45,62 C85,44 120,42 138,56 L138,124 C120,110 85,112 45,130 Z' fill='%23f0501f'/%3E%3Cpath d='M146,56 C170,72 205,74 238,58 L238,126 C205,142 170,140 146,124 Z' fill='%237cbb00'/%3E%3Cpath d='M45,138 C85,120 120,118 138,132 L138,200 C120,186 85,188 45,206 Z' fill='%2321a9e1'/%3E%3Cpath d='M146,132 C170,148 205,150 238,134 L238,202 C205,218 170,216 146,200 Z' fill='%23ffba00'/%3E%3Crect x='0' y='0' width='285' height='265' fill='url(%23gl)' clip-path='url(%23fc)'/%3E%3C/svg%3E") center 40% / 480px auto no-repeat,
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 1200 750' preserveAspectRatio='xMidYMax slice'%3E%3Cg fill='none' stroke='%23ffffff' stroke-linecap='round'%3E%3Cpath d='M-40,758 C300,650 640,470 1260,170' stroke-width='1.7' opacity='0.42'/%3E%3Cpath d='M40,762 C360,680 760,520 1260,300' stroke-width='1.2' opacity='0.32'/%3E%3Cpath d='M-30,726 C240,660 540,560 900,400' stroke-width='1' opacity='0.24'/%3E%3Cpath d='M260,764 C470,702 740,624 1060,506' stroke-width='0.9' opacity='0.22'/%3E%3C/g%3E%3Cpath d='M48,762 C120,700 168,662 222,606 C260,568 288,544 322,502' fill='none' stroke='%237db82a' stroke-width='2.7' opacity='0.88'/%3E%3Cpath d='M92,708 c9,-13 24,-11 28,-2 c-9,13 -24,11 -28,2 z' fill='%237db82a' opacity='0.88'/%3E%3Cpath d='M152,660 c9,-13 24,-11 28,-2 c-9,13 -24,11 -28,2 z' fill='%2389c93a' opacity='0.88'/%3E%3Cpath d='M242,568 c9,-13 24,-11 28,-2 c-9,13 -24,11 -28,2 z' fill='%237db82a' opacity='0.88'/%3E%3C/svg%3E") center bottom / cover no-repeat,
    radial-gradient(46% 52% at 14% 80%, rgba(178,226,255,0.5) 0%, transparent 56%),
    radial-gradient(40% 34% at 50% 40%, rgba(150,210,255,0.38) 0%, transparent 64%),
    linear-gradient(to top right, #4aa0e6 0%, #3380cf 38%, #2461ab 72%, #1c5093 100%);
}
/* Glass windows (7.css recipe: translucent frame + inner white highlight) */
body.era-win7 .window {
  background: transparent; border: 1px solid rgba(160, 195, 235, 0.6); border-radius: 8px;
  box-shadow: 2px 2px 10px 1px rgba(110, 160, 220, 0.5), inset 0 0 0 1px #fffa, 0 16px 40px #0009;
}
body.era-win7 .win-content { background: #fff; }
/* drop the resting scale() so the title-bar's backdrop-filter can blur the desktop
   (a transformed ancestor otherwise clips backdrop-filter) */
body.era-win7 .window.show { transform: none; }
body.era-win7 .titlebar {
  background: linear-gradient(180deg, rgba(220, 238, 255, 0.05), rgba(165, 205, 245, 0.02));
  backdrop-filter: blur(10px) saturate(1.25); -webkit-backdrop-filter: blur(10px) saturate(1.25);
  border-bottom: 1px solid rgba(255, 255, 255, 0.4); border-radius: 8px 8px 0 0; color: #1a1a1a;
}
/* override the base `.window.active .titlebar` (opaque) so active windows stay glass */
body.era-win7 .window.active .titlebar { background: linear-gradient(180deg, rgba(220,238,255,0.05), rgba(165,205,245,0.02)); }
body.era-win7 .window:not(.active) .titlebar { background: linear-gradient(180deg, rgba(238,243,249,.4), rgba(226,234,244,.3)); }
/* Aero title text: dark text made legible on glass with a white halo (7.css trick) */
body.era-win7 .titlebar .tb-title { color: #1a1a1a; font-weight: 500; text-shadow: 0 0 10px #fff, 0 0 10px #fff, 0 0 9px #fff, 0 0 8px #fff; }
/* Glass window buttons */
body.era-win7 .tb-btn {
  width: 29px; height: 20px; border-radius: 0 0 4px 4px; color: #103a6e;
  background: linear-gradient(180deg, rgba(255,255,255,.7), rgba(206,226,247,.55));
  border: 1px solid rgba(255,255,255,.7); box-shadow: inset 0 0 0 1px rgba(120,160,210,.35);
}
body.era-win7 .tb-btn svg { stroke: #0e3666; stroke-width: 1.6; }
body.era-win7 .tb-btn:hover { background: linear-gradient(180deg, #eaf4ff, #bcdcff); filter: none; }
body.era-win7 .tb-btn.close { color: #fff; }
body.era-win7 .tb-btn.close svg { stroke: #fff; }
body.era-win7 .tb-btn.close { background: linear-gradient(180deg, #f08a82, #d23b30); }
body.era-win7 .tb-btn.close:hover { background: linear-gradient(180deg, #ff7b70, #e0392b); }
/* Glass taskbar */
body.era-win7 #panel {
  background: linear-gradient(180deg, rgba(60,105,160,.03), rgba(12,28,56,.07));
  backdrop-filter: blur(12px) saturate(1.2); -webkit-backdrop-filter: blur(12px) saturate(1.2);
  border-top: 1px solid rgba(255,255,255,.34); box-shadow: inset 0 1px 0 rgba(255,255,255,.18);
}
body.era-win7 .task { background: rgba(255,255,255,.08); color: #fff; border: 1px solid rgba(255,255,255,.18); border-radius: 5px; box-shadow: inset 0 1px 0 rgba(255,255,255,.12); }
body.era-win7 .task.active { background: rgba(255,255,255,.22); border-color: rgba(255,255,255,.4); }
/* Round Start orb */
body.era-win7 #launcher {
  width: 44px; height: 44px; border-radius: 50%; padding: 0; gap: 0; margin: 0 4px 0 0;
  justify-content: center;
  background: radial-gradient(circle at 50% 30%, #eaf6ff 0%, #86c5f5 22%, #2a82d8 54%, #0e5098 80%, #08366c 100%);
  border: 1px solid #06325c; box-shadow: 0 0 0 1px rgba(255,255,255,.5) inset, 0 0 14px rgba(90,180,255,.7), 0 2px 5px #0007;
}
body.era-win7 #launcher:hover, body.era-win7 #launcher.active { box-shadow: 0 0 0 1px rgba(255,255,255,.7) inset, 0 0 20px rgba(120,200,255,.95), 0 2px 5px #0007; }
body.era-win7 #launcher .dots { display: none; }
/* Start orb logo = the same waving flag as the wallpaper */
body.era-win7 #launcher::after { content: ""; width: 33px; height: 29px; transform: perspective(46px) rotateY(-13deg);
  filter: drop-shadow(0 1px 1px #0007);
  background: var(--flag) center / contain no-repeat; }
/* Tray / clock */
body.era-win7 #systray { padding: 0 8px; }
body.era-win7 #clock { color: #fff; text-shadow: 0 1px 2px #0008; }
body.era-win7 #clock:hover { background: rgba(255,255,255,.18); }
body.era-win7 #show-desktop { color: #fff; border-left: 1px solid rgba(255,255,255,.25); }
body.era-win7 #show-desktop:hover { background: rgba(255,255,255,.18); }
/* Controls -> Aero light buttons */
body.era-win7 .trash-btn, body.era-win7 .cal-today, body.era-win7 .cal-travel, body.era-win7 .ckey, body.era-win7 .tw-year {
  background: linear-gradient(180deg, #fdfeff, #e4eef8); color: #1a1a1a; border: 1px solid #aac4e0; border-radius: 4px; }
body.era-win7 .ckey.op { color: #1565b8; }
body.era-win7 .ckey.eq { background: linear-gradient(180deg, #6cb3f0, #1f78d6); color: #fff; }
body.era-win7 .trash-btn:hover, body.era-win7 .ckey:hover, body.era-win7 .cal-today:hover, body.era-win7 .cal-travel:hover {
  filter: none; border-color: #4aa3e8; background: linear-gradient(180deg, #fff, #dcefff); color: #1a1a1a; box-shadow: 0 0 6px rgba(74,163,232,.5); }
body.era-win7 .calc-display { background: #fff; color: #000; border: 1px solid #aac4e0; }
/* Popups -> glass */
body.era-win7 #kickoff { border: 1px solid rgba(140,180,230,.7); border-radius: 6px; backdrop-filter: blur(14px); }
body.era-win7 .kickoff-header { background: linear-gradient(180deg, #3f93e6, #1664bf); }
body.era-win7 #context-menu, body.era-win7 #calendar { background: rgba(248,251,255,.97); color: #1a1a1a; border: 1px solid #88a8d0; backdrop-filter: blur(12px); }
body.era-win7 #context-menu button:hover { background: linear-gradient(180deg, #6cb3f0, #2f7fdb); color: #fff; }
body.era-win7 .wiki-link.active, body.era-win7 .cal-day.today { background: linear-gradient(180deg, #6cb3f0, #2f7fdb); color: #fff; }
body.era-win7 .cal-today:hover, body.era-win7 .cal-travel:hover { color: #1a1a1a; }
/* Browser toolbar -> light glass */
body.era-win7 .browser-toolbar { background: linear-gradient(180deg, #f3f8fe, #dde8f4); border-bottom: 1px solid #aac4e0; }
body.era-win7 .bb { color: #1a3252; }
body.era-win7 .bb:hover:not(:disabled) { background: #2f7fdb22; }
body.era-win7 .url-wrap { background: #fff; border: 1px solid #aac4e0; border-radius: 4px; }
/* Hide settings/terminal; show Solitaire (Sticky Notes stays - it debuted in Win7) */
body.era-win7 .desk-icon[data-window="settings"], body.era-win7 .desk-icon[data-window="terminal"],
body.era-win7 .kickoff-app[data-window="settings"], body.era-win7 .kickoff-app[data-window="terminal"] { display: none; }
body.era-win7 .desk-icon[data-window="solitaire"] { display: flex; }
body.era-win7 .kickoff-app[data-window="solitaire"] { display: flex; }

/* Solitaire is a Win7-only app (hidden elsewhere) */
.desk-icon[data-window="solitaire"], .kickoff-app[data-window="solitaire"] { display: none; }

/* ---------- Busy spinning-clock cursor (Minesweeper -> crash) ---------- */
body.busy, body.busy * { cursor: none !important; }
#fake-cursor { position: fixed; z-index: 480000; display: none; transform: translate(-50%, -50%); pointer-events: none; }
#fake-cursor svg { display: block; }
#fake-cursor.show { display: block; animation: hgSpin 1.1s linear infinite; }
@keyframes hgSpin {
  from { transform: translate(-50%, -50%) rotate(0deg); }
  to   { transform: translate(-50%, -50%) rotate(360deg); }
}

/* ---------- Win95 cursor (classic white arrow) ----------
   Set on <body> only and let it INHERIT, so elements with their own cursor
   (resize handles, the move-titlebar, text fields, buttons) keep theirs. */
body.era-win95 {
  cursor: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='22' height='30' viewBox='0 0 22 30'%3E%3Cpath d='M3 2 L3 22 L8.5 16.5 L12 24 L15.5 22.5 L12 15 L19 15 Z' fill='white' stroke='black' stroke-width='1.6' stroke-linejoin='round'/%3E%3C/svg%3E") 3 2, auto;
}
body.era-win95 input, body.era-win95 textarea { cursor: text; }

/* Win XP / Win7 cursor (smooth white arrow with a soft shadow) */
body.era-winxp, body.era-win7 {
  cursor: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='32' viewBox='0 0 24 32'%3E%3Cpath d='M4 3 L4 23 L9.5 17.5 L13 25 L16.5 23.5 L13 16 L20 16 Z' fill='black' opacity='0.35'/%3E%3Cpath d='M3 2 L3 22 L8.5 16.5 L12 24 L15.5 22.5 L12 15 L19 15 Z' fill='white' stroke='%23222' stroke-width='1.3' stroke-linejoin='round'/%3E%3C/svg%3E") 3 2, auto;
}
body.era-winxp input, body.era-winxp textarea,
body.era-win7 input, body.era-win7 textarea { cursor: text; }

/* ---------- Blue Screen of Death ---------- */
#bsod {
  position: fixed; inset: 0; z-index: 500000; display: none;
  background: #0000aa; color: #fff; cursor: pointer;
  font-family: "Lucida Console", "Consolas", "Courier New", monospace;
}
#bsod.show { display: grid; place-items: center; }
.bsod-inner { max-width: 620px; padding: 28px; font-size: 15px; line-height: 1.55; white-space: pre-wrap; }
.bsod-head { text-align: center; margin-bottom: 20px; }
.bsod-title { background: #aaaaaa; color: #0000aa; padding: 1px 10px; font-weight: 700; }
#bsod p { margin: 16px 0; }
.bsod-cont { text-align: center; margin-top: 24px; }
.bsod-cursor { animation: bsodBlink 1s steps(1) infinite; }
@keyframes bsodBlink { 50% { opacity: 0; } }
/* XP STOP-error variant: left-aligned, top of screen */
#bsod.isxp.show { place-items: start center; }
.bsod-xp { max-width: 780px; padding: 56px 34px; font-size: 14px; line-height: 1.5; white-space: pre-wrap; }
.bsod-xp p { margin: 13px 0; }
/* Kernel panic variant (modern/KDE mode): a TTY console dump, not a blue screen */
#bsod.panic { background: #000; color: #c9ccc9; }
#bsod.panic.show { place-items: start center; }
.panic-log { max-width: 880px; width: 92vw; margin: 0; padding: 40px 22px; font-size: 13px; line-height: 1.55; white-space: pre-wrap; word-break: break-word; }
.panic-log .ok-r { color: #d85c5c; }

.hidden { display: none; }

@media (prefers-reduced-motion: reduce) {
  * { transition: none !important; animation: none !important; }
}

/* ---------- Mobile mode ---------- */
@media (max-width: 760px) {
  /* Windows become fullscreen, stacked (z-index decides what's on top) */
  .window {
    position: fixed !important;
    inset: 0 0 var(--panel-h) 0 !important;
    width: auto !important; height: auto !important;
    max-width: none !important; border-radius: 0; border: none;
  }
  .window .rz { display: none; }          /* no resize on touch */
  .titlebar { cursor: default; }
  #clippy { display: none !important; }   /* would cover fullscreen windows on phones */
  .window.minimizing { transform: translateY(60vh) scale(.6); }

  /* Desktop icons: phone-style grid */
  .desktop-icons {
    flex-direction: row; flex-wrap: wrap; align-content: flex-start;
    gap: 4px; width: 100%; max-height: none; inset: 18px 0 auto 0; padding: 0 8px;
  }
  .desk-icon { width: 25%; }

  /* Launcher menu spans the width */
  #kickoff { left: 8px; right: 8px; width: auto; }
  #systray .tray-icon { display: none; }  /* keep the clock, drop the rest */
  .task { max-width: 130px; }
}

@media (max-width: 430px) {
  .desk-icon { width: 33.33%; }
}
