:root {
  --desktop: #007c7a;
  --chrome: #c0c0c0;
  --active: #000080;
  --active-light: #1084d0;
  --paper: #ffffff;
  --ink: #101010;
  --signal: #ffd24a;
  --taskbar-height: 36px;
  --ui-font: "MS Sans Serif", Tahoma, Geneva, sans-serif;
  --mono-font: "Lucida Console", "Courier New", monospace;
}

* {
  box-sizing: border-box;
}

html,
body {
  width: 100%;
  height: 100%;
  margin: 0;
  overflow: hidden;
}

body {
  color: var(--ink);
  font-family: var(--ui-font);
  font-size: 12px;
  background: #000;
}

button,
input,
label,
select,
textarea {
  font-family: var(--ui-font);
}

button,
a {
  -webkit-tap-highlight-color: transparent;
}

button:focus-visible,
a:focus-visible,
input:focus-visible {
  outline: 1px dotted #000;
  outline-offset: 2px;
}

[hidden] {
  display: none !important;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.skip-link {
  position: fixed;
  z-index: 99999;
  top: 4px;
  left: 4px;
  padding: 7px 10px;
  color: #fff;
  background: #000080;
  transform: translateY(-150%);
}

.skip-link:focus {
  transform: translateY(0);
}

.desktop {
  position: relative;
  isolation: isolate;
  width: 100%;
  height: 100dvh;
  min-height: 440px;
  overflow: hidden;
  padding-bottom: var(--taskbar-height);
  background-color: var(--desktop);
  background-image:
    linear-gradient(135deg, transparent 0 48%, rgb(255 255 255 / 4%) 48% 52%, transparent 52%),
    linear-gradient(45deg, transparent 0 48%, rgb(0 0 0 / 5%) 48% 52%, transparent 52%);
  background-size: 40px 40px;
}

.desktop::before,
.desktop::after {
  position: absolute;
  z-index: 9998;
  inset: 0 0 var(--taskbar-height);
  pointer-events: none;
  content: "";
}

.desktop::before {
  opacity: 0.24;
  background-image:
    radial-gradient(circle at 1px 1px, rgb(255 255 255 / 35%) 1px, transparent 1px),
    radial-gradient(circle at 3px 3px, rgb(0 0 0 / 22%) 1px, transparent 1px);
  background-size: 4px 4px;
}

.desktop::after {
  opacity: 0.09;
  background: repeating-linear-gradient(
    to bottom,
    transparent 0,
    transparent 3px,
    rgb(0 0 0 / 52%) 3px,
    rgb(0 0 0 / 52%) 4px
  );
  mix-blend-mode: multiply;
}

body.no-dither .desktop::before,
body.no-scanlines .desktop::after {
  display: none;
}

body[data-wallpaper="navy"] .desktop {
  background-color: #071a61;
  background-image:
    radial-gradient(circle at 20% 15%, rgb(59 105 188 / 40%) 0 2px, transparent 3px),
    radial-gradient(circle at 80% 65%, rgb(255 255 255 / 35%) 0 1px, transparent 2px);
  background-size:
    71px 71px,
    43px 43px;
}

body[data-wallpaper="clouds"] .desktop {
  background-color: #3a72a8;
  background-image:
    linear-gradient(90deg, rgb(255 255 255 / 10%) 1px, transparent 1px),
    linear-gradient(rgb(255 255 255 / 10%) 1px, transparent 1px),
    radial-gradient(circle at 20% 30%, rgb(255 255 255 / 26%) 0 50px, transparent 52px),
    radial-gradient(circle at 80% 70%, rgb(255 255 255 / 18%) 0 80px, transparent 82px);
  background-size:
    32px 32px,
    32px 32px,
    100% 100%,
    100% 100%;
}

.desktop-watermark {
  position: absolute;
  z-index: 0;
  right: 28px;
  bottom: 65px;
  color: rgb(255 255 255 / 13%);
  font-family: "Arial Black", Impact, sans-serif;
  font-size: clamp(36px, 7vw, 104px);
  font-weight: 900;
  line-height: 0.74;
  letter-spacing: -0.06em;
  text-align: right;
  text-transform: uppercase;
  user-select: none;
}

.desktop-watermark span,
.desktop-watermark small {
  display: block;
}

.desktop-watermark small {
  margin-top: 22px;
  font-family: var(--mono-font);
  font-size: clamp(8px, 1.1vw, 13px);
  line-height: 1;
  letter-spacing: 0.24em;
}

/* Boot */

.boot-screen {
  position: fixed;
  z-index: 100000;
  inset: 0;
  display: grid;
  place-content: center;
  justify-items: center;
  gap: 14px;
  color: #fff;
  background:
    radial-gradient(circle at center, #24246e 0, #00004b 48%, #000 100%);
  font-family: var(--mono-font);
  text-align: center;
}

.boot-screen.is-finished {
  animation: boot-away 220ms steps(4, end) forwards;
}

.boot-logo {
  display: flex;
  align-items: flex-end;
  gap: 18px;
}

.boot-logo-mark {
  display: grid;
  width: 74px;
  height: 74px;
  place-items: center;
  border: 4px solid #fff;
  color: #000080;
  background:
    linear-gradient(90deg, #ff3228 0 50%, #47b831 50%) 0 0 / 100% 50%,
    linear-gradient(90deg, #2a75d5 0 50%, #ffd12e 50%) 0 100% / 100% 50%;
  background-repeat: no-repeat;
  box-shadow: 5px 5px 0 rgb(0 0 0 / 40%);
  font-family: "Arial Black", Impact, sans-serif;
  font-size: 28px;
  text-shadow: 1px 1px #fff;
}

.boot-logo-word {
  font-family: "Arial Black", Impact, sans-serif;
  font-size: clamp(38px, 8vw, 74px);
  letter-spacing: -0.07em;
}

.boot-logo-word strong {
  color: #ffd24a;
  font-size: 0.55em;
  letter-spacing: 0;
}

.boot-screen p {
  margin: 0;
  color: #d7d7d7;
}

.boot-progress {
  width: min(340px, 70vw);
}

.boot-progress .progress-indicator-bar {
  width: 100%;
  animation: boot-progress 900ms steps(9, end) both;
}

.boot-screen button {
  min-width: 88px;
}

@keyframes boot-progress {
  from {
    width: 0;
  }
}

@keyframes boot-away {
  to {
    opacity: 0;
    visibility: hidden;
    clip-path: inset(50% 0);
  }
}

/* Desktop shortcuts and pixel icons */

.desktop-shortcuts {
  position: absolute;
  z-index: 2;
  top: 12px;
  bottom: calc(var(--taskbar-height) + 10px);
  left: 8px;
  display: grid;
  width: 104px;
  grid-auto-rows: min-content;
  gap: 8px;
  align-content: start;
  overflow-y: auto;
  scrollbar-width: none;
}

.desktop-shortcuts::-webkit-scrollbar {
  display: none;
}

.desktop-shortcut {
  display: flex;
  min-width: 0;
  min-height: 66px;
  padding: 2px;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  border: 1px solid transparent;
  color: #fff;
  background: transparent;
  box-shadow: none;
  font-size: 10px;
  line-height: 1.15;
  text-shadow: 1px 1px #000;
}

.desktop-shortcut:hover {
  border-color: rgb(255 255 255 / 35%);
  background: rgb(0 0 128 / 20%);
}

.desktop-shortcut:active,
.desktop-shortcut.is-selected {
  padding: 2px;
  box-shadow: none;
}

.desktop-shortcut:focus-visible {
  outline-color: #fff;
}

.desktop-shortcut.is-selected .desktop-shortcut-label {
  color: #fff;
  background: #000080;
}

.desktop-shortcut-label {
  max-width: 100%;
  padding: 2px 3px;
  text-align: center;
  overflow-wrap: anywhere;
}

.pixel-icon {
  display: block;
  width: 40px;
  height: 40px;
  flex: 0 0 auto;
  object-fit: contain;
  image-rendering: pixelated;
  filter: drop-shadow(1px 1px 0 #000);
}

.pixel-icon.large {
  width: 52px;
  height: 52px;
}

/* Application windows */

.window-layer {
  position: absolute;
  z-index: 3;
  inset: 0 0 var(--taskbar-height);
  pointer-events: none;
}

.app-window {
  position: absolute;
  z-index: 10;
  top: var(--y, 20px);
  left: var(--x, 120px);
  display: flex;
  width: min(var(--w, 620px), calc(100vw - 20px));
  min-width: 270px;
  max-width: calc(100vw - 12px);
  max-height: calc(100dvh - var(--taskbar-height) - 12px);
  flex-direction: column;
  overflow: hidden;
  resize: both;
  pointer-events: auto;
  transform-origin: center;
}

.app-window:focus {
  outline: none;
}

.app-window.is-opening {
  animation: window-open 130ms steps(4, end);
}

.app-window.is-minimized {
  display: none;
}

.app-window.is-maximized {
  top: 4px !important;
  left: 4px !important;
  width: calc(100vw - 8px) !important;
  height: calc(100dvh - var(--taskbar-height) - 8px) !important;
  max-width: none;
  max-height: none;
  resize: none;
}

.app-window > .title-bar {
  flex: 0 0 auto;
  cursor: grab;
  user-select: none;
}

.app-window > .title-bar:active {
  cursor: grabbing;
}

.app-window .title-bar.inactive {
  background: linear-gradient(90deg, #7d7d7d, #b5b5b5);
}

.app-window > .window-body {
  min-height: 0;
  flex: 1 1 auto;
  overflow: auto;
}

.app-window > .status-bar {
  flex: 0 0 auto;
}

.content-window {
  min-height: 370px;
}

.compact-window {
  min-width: 230px;
  resize: none;
}

.title-bar-text {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.menu-bar {
  display: flex;
  min-height: 25px;
  padding: 2px 4px;
  flex: 0 0 auto;
  gap: 2px;
  border-bottom: 1px solid #808080;
  background: var(--chrome);
}

.menu-bar button {
  min-width: 0;
  min-height: 20px;
  padding: 2px 8px;
  border: 1px solid transparent;
  background: transparent;
  box-shadow: none;
}

.menu-bar button:hover,
.menu-bar button:focus-visible {
  border-color: #808080 #fff #fff #808080;
}

.menu-bar button:active {
  padding: 3px 7px 1px 9px;
  border-color: #000 #fff #fff #000;
  box-shadow: none;
}

@keyframes window-open {
  from {
    opacity: 0;
    clip-path: inset(45% 45%);
    transform: scale(0.94);
  }
}

/* Hero */

.hero-window-body {
  padding: 13px 15px 15px;
}

.hero-grid {
  display: grid;
  grid-template-columns: 116px minmax(0, 1fr);
  gap: 18px;
  align-items: center;
}

.hero-avatar {
  position: relative;
  display: grid;
  width: 110px;
  height: 126px;
  place-items: center;
  overflow: hidden;
  border: 3px inset #fff;
  background:
    linear-gradient(90deg, transparent 0 49%, rgb(255 255 255 / 14%) 49% 51%, transparent 51%),
    linear-gradient(transparent 0 49%, rgb(255 255 255 / 14%) 49% 51%, transparent 51%),
    linear-gradient(135deg, #000080, #1084d0);
  background-size:
    14px 14px,
    14px 14px,
    100% 100%;
  box-shadow: inset 0 0 28px #000080;
}

.avatar-initials {
  color: #fff;
  font-family: "Arial Black", Impact, sans-serif;
  font-size: 47px;
  letter-spacing: -0.1em;
  text-shadow:
    2px 2px 0 #000080,
    4px 4px 0 #ffd24a;
}

.avatar-cursor {
  position: absolute;
  right: 9px;
  bottom: 9px;
  width: 10px;
  height: 18px;
  background: #fff;
  clip-path: polygon(0 0, 0 100%, 34% 71%, 55% 100%, 72% 91%, 51% 62%, 100% 62%);
  filter: drop-shadow(1px 1px #000);
}

.hero-kicker,
.eyebrow {
  margin: 0 0 6px;
  color: #000080;
  font-family: var(--mono-font);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.08em;
}

.hero-copy h1 {
  margin: 0;
  color: #000;
  font-family: "Arial Black", Impact, var(--ui-font);
  font-size: clamp(36px, 5.4vw, 62px);
  font-weight: 900;
  line-height: 0.77;
  letter-spacing: -0.07em;
  text-transform: uppercase;
}

.hero-thesis {
  max-width: 530px;
  margin: 14px 0 0;
  font-size: 13px;
  font-weight: 700;
  line-height: 1.38;
}

.hero-actions,
.button-row,
.dialog-actions,
.lineage-controls {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
}

.hero-actions {
  margin: 16px 0 13px;
}

.hero-actions button {
  min-width: 116px;
}

.hero-details-grid {
  display: grid;
  grid-template-columns: 1fr 0.9fr;
  gap: 10px;
}

.property-list {
  display: grid;
  gap: 5px;
  margin: 0;
}

.property-list > div {
  display: grid;
  grid-template-columns: 86px minmax(0, 1fr);
  gap: 8px;
}

.property-list dt {
  color: #4f4f4f;
}

.property-list dd {
  margin: 0;
  font-weight: 700;
}

.status-led {
  display: inline-block;
  width: 7px;
  height: 7px;
  margin-right: 3px;
  border: 1px solid #173500;
  border-radius: 50%;
  background: #39b54a;
  box-shadow: inset 1px 1px #8cff96;
  vertical-align: 0;
}

.system-quote {
  min-height: 118px;
  padding: 11px;
  color: #a8f26c;
  background: #050505;
  font-family: var(--mono-font);
  font-size: 11px;
  line-height: 1.45;
}

.system-quote code {
  color: #fff;
  font-family: inherit;
}

.system-quote p {
  margin: 8px 0;
}

.terminal-caret {
  color: #fff;
}

/* Monitor */

.monitor-body {
  padding: 8px;
}

.monitor-row {
  display: flex;
  padding: 4px 0;
  justify-content: space-between;
  gap: 12px;
  border-bottom: 1px dotted #808080;
}

.monitor-row strong {
  color: #000080;
  text-align: right;
}

.monitor-progress {
  margin: 9px 0 7px;
}

.monitor-link {
  width: 100%;
}

/* Signature lineage app */

.lineage-window {
  min-height: 250px;
}

.lineage-window > .window-body {
  padding: 9px;
}

.lineage-intro {
  margin: 0 0 8px;
}

.lineage-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.55fr) minmax(205px, 0.75fr);
  gap: 10px;
}

.lineage-track {
  position: relative;
  display: grid;
  min-height: 94px;
  padding: 17px 8px 10px;
  grid-template-columns: repeat(5, minmax(72px, 1fr));
  gap: 5px;
  align-items: center;
  overflow: hidden;
  background: #fff;
}

.lineage-rail {
  position: absolute;
  z-index: 0;
  top: 52px;
  right: 11%;
  left: 11%;
  height: 4px;
  border-top: 1px solid #000;
  border-bottom: 1px solid #fff;
  background: #808080;
}

.lineage-signal {
  position: absolute;
  z-index: 2;
  top: 46px;
  left: calc(10% + (var(--step) * 20%));
  width: 12px;
  height: 12px;
  border: 2px solid #402c00;
  border-radius: 50%;
  background: var(--signal);
  box-shadow:
    inset 1px 1px #fff1a1,
    0 0 0 2px #fff;
  transition: left 480ms steps(8, end);
  transform: translateX(-50%);
}

.lineage-node {
  position: relative;
  z-index: 3;
  min-width: 0;
  min-height: 54px;
  padding: 5px 3px;
  background: var(--chrome);
  font-size: 10px;
  line-height: 1.1;
}

.lineage-node span {
  display: block;
  margin-bottom: 4px;
  color: #4b4b4b;
  font-family: var(--mono-font);
  font-size: 8px;
}

.lineage-node.is-current {
  color: #fff;
  background: #000080;
  box-shadow:
    inset -1px -1px #fff,
    inset 1px 1px #0a0a0a,
    inset -2px -2px #808080,
    inset 2px 2px #000;
}

.lineage-node.is-current span {
  color: var(--signal);
}

.lineage-controls {
  margin-top: 7px;
}

.lineage-detail {
  min-height: 130px;
  padding: 10px;
  background: #fff;
}

.lineage-detail-year {
  display: inline-block;
  padding: 2px 4px;
  color: #000;
  background: var(--signal);
  font-family: var(--mono-font);
  font-size: 9px;
  font-weight: 700;
}

.lineage-detail h2 {
  margin: 5px 0 6px;
  color: #000080;
  font-size: 17px;
}

.lineage-detail p {
  margin: 4px 0 7px;
  line-height: 1.35;
}

.branch-link {
  width: 100%;
  min-height: 20px;
  margin-top: 7px;
  padding: 2px 6px;
  border: 0;
  color: #000080;
  background: transparent;
  box-shadow: none;
  text-align: left;
}

.branch-link:hover {
  text-decoration: underline;
}

.lineage-progress {
  height: 11px;
  margin-top: 5px;
}

.lineage-progress .progress-indicator-bar {
  transition: width 300ms steps(5, end);
}

.lineage-complete {
  animation: drive-flash 650ms steps(2, end) 2;
}

@keyframes drive-flash {
  50% {
    filter: brightness(1.8) drop-shadow(0 0 5px var(--signal));
  }
}

/* Explorer and tabs */

.work-tabs,
.properties-tabs {
  margin-top: 4px;
  margin-bottom: -2px;
}

.tab-panel {
  min-height: 330px;
}

.tab-panel > .window-body {
  height: 100%;
  min-height: 326px;
  padding: 9px;
}

.explorer-layout {
  display: grid;
  grid-template-columns: 180px minmax(0, 1fr);
  gap: 9px;
}

.explorer-tree {
  min-height: 295px;
  margin: 0;
  overflow: auto;
}

.project-list {
  display: grid;
  align-content: start;
  gap: 3px;
}

.project-file {
  display: grid;
  min-height: 51px;
  padding: 5px 7px;
  grid-template-columns: 35px minmax(0, 1fr) auto;
  gap: 8px;
  align-items: center;
  border: 1px solid transparent;
  background: transparent;
  box-shadow: none;
  text-align: left;
}

.project-file:hover,
.project-file:focus-visible {
  border-color: #000080;
  color: #fff;
  background: #000080;
}

.project-file:active {
  padding: 5px 7px;
  box-shadow: none;
}

.project-file span:not(.file-icon) {
  min-width: 0;
}

.project-file strong,
.project-file small {
  display: block;
}

.project-file strong {
  margin-bottom: 3px;
}

.project-file small {
  color: #555;
  font-size: 10px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.project-file:hover small,
.project-file:focus-visible small {
  color: #fff;
}

.project-file em {
  color: #555;
  font-family: var(--mono-font);
  font-size: 9px;
  font-style: normal;
}

.project-file:hover em,
.project-file:focus-visible em {
  color: var(--signal);
}

.file-icon {
  display: block;
  width: 32px;
  height: 32px;
  object-fit: contain;
  image-rendering: pixelated;
  filter: drop-shadow(1px 1px 0 rgb(0 0 0 / 28%));
}

.astral-panel {
  display: grid;
  grid-template-columns: 155px minmax(0, 1fr);
  gap: 18px;
  align-items: center;
  min-height: 326px;
  padding: 20px !important;
  color: #fff;
  background:
    linear-gradient(135deg, rgb(16 132 208 / 12%) 0 25%, transparent 25% 75%, rgb(255 210 74 / 12%) 75%),
    #060c28;
}

.astral-mark {
  display: grid;
  width: 140px;
  height: 140px;
  place-items: center;
  border: 3px solid #fff;
  color: var(--signal);
  background:
    linear-gradient(45deg, transparent 45%, rgb(255 255 255 / 18%) 45% 55%, transparent 55%),
    #000080;
  box-shadow:
    8px 8px 0 #1084d0,
    13px 13px 0 rgb(255 210 74 / 80%);
  font-family: "Arial Black", Impact, sans-serif;
  font-size: 48px;
}

.astral-panel h2 {
  margin: 2px 0 8px;
  color: #fff;
  font-family: "Arial Black", Impact, sans-serif;
  font-size: 40px;
  letter-spacing: -0.05em;
}

.astral-panel p {
  max-width: 520px;
  line-height: 1.45;
}

.astral-panel .eyebrow {
  color: var(--signal);
}

.astral-panel .tech-line {
  padding: 5px 7px;
  border-left: 3px solid var(--signal);
  color: #dcecff;
  background: rgb(0 0 0 / 22%);
  font-family: var(--mono-font);
  font-size: 10px;
}

.astral-panel .tech-line strong {
  color: var(--signal);
}

.fact-strip {
  display: grid;
  margin: 14px 0;
  grid-template-columns: repeat(3, 1fr);
  gap: 5px;
}

.fact-strip span {
  padding: 8px;
  border: 1px solid #5a74ba;
  background: rgb(16 132 208 / 18%);
  font-size: 10px;
}

.fact-strip strong {
  display: block;
  margin-bottom: 2px;
  color: var(--signal);
  font-family: var(--mono-font);
  font-size: 16px;
}

.button-row {
  align-items: center;
}

.button-row a,
.scholar-link {
  display: inline-flex;
  min-height: 23px;
  padding: 4px 10px;
  align-items: center;
  color: #000;
  background: silver;
  box-shadow:
    inset -1px -1px #0a0a0a,
    inset 1px 1px #fff,
    inset -2px -2px grey,
    inset 2px 2px #dfdfdf;
  text-decoration: none;
}

.button-row a:active,
.scholar-link:active {
  padding: 5px 9px 3px 11px;
  box-shadow:
    inset -1px -1px #fff,
    inset 1px 1px #0a0a0a,
    inset -2px -2px #dfdfdf,
    inset 2px 2px grey;
}

.panel-lede {
  margin: 0 0 10px;
  line-height: 1.45;
}

.lab-projects {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.papers-header {
  display: grid;
  margin-bottom: 10px;
  grid-template-columns: minmax(0, 1fr) repeat(3, 74px);
  gap: 7px;
  align-items: center;
}

.papers-header h2 {
  margin: 2px 0 0;
  font-size: 22px;
}

.citation-counter {
  padding: 7px 4px;
  border: 2px inset #fff;
  background: #fff;
  text-align: center;
}

.citation-counter strong,
.citation-counter span {
  display: block;
}

.citation-counter strong {
  color: #000080;
  font-family: var(--mono-font);
  font-size: 20px;
}

.citation-counter span {
  font-size: 9px;
}

.paper-list {
  display: grid;
  max-height: 220px;
  overflow-y: auto;
  background: #fff;
}

.paper-list button {
  display: block;
  min-height: 48px;
  padding: 7px 9px;
  border: 0;
  border-bottom: 1px dotted #888;
  background: transparent;
  box-shadow: none;
  text-align: left;
}

.paper-list button:hover,
.paper-list button:focus-visible {
  color: #fff;
  background: #000080;
}

.paper-list button:active {
  padding: 7px 9px;
  box-shadow: none;
}

.paper-list strong,
.paper-list span {
  display: block;
}

.paper-list span {
  margin-top: 3px;
  color: #555;
  font-size: 10px;
}

.paper-list button:hover span,
.paper-list button:focus-visible span {
  color: #fff;
}

.scholar-link {
  margin-top: 9px;
}

/* Career and properties */

.career-log {
  height: min(64vh, 500px);
  padding: 15px 18px;
  overflow-y: auto;
  background: #fff;
}

.career-log header {
  padding-bottom: 12px;
  border-bottom: 2px solid #000080;
}

.career-log header p {
  margin: 0 0 5px;
  color: #555;
  font-family: var(--mono-font);
}

.career-log h2 {
  margin: 0;
  font-family: "Arial Black", Impact, sans-serif;
  font-size: 25px;
  letter-spacing: -0.04em;
}

.timeline {
  position: relative;
  margin: 16px 0 0;
  padding: 0;
  list-style: none;
}

.timeline::before {
  position: absolute;
  top: 6px;
  bottom: 8px;
  left: 74px;
  width: 3px;
  background: #000080;
  content: "";
}

.timeline li {
  position: relative;
  display: grid;
  padding-bottom: 18px;
  grid-template-columns: 64px minmax(0, 1fr);
  gap: 22px;
}

.timeline li::before {
  position: absolute;
  top: 3px;
  left: 69px;
  width: 9px;
  height: 9px;
  border: 2px solid #000080;
  background: var(--signal);
  content: "";
}

.timeline time {
  color: #000080;
  font-family: var(--mono-font);
  font-size: 9px;
  font-weight: 700;
  text-align: right;
}

.timeline h3 {
  margin: 0 0 5px;
  font-size: 15px;
}

.timeline p {
  margin: 0 0 7px;
  line-height: 1.45;
}

.properties-body {
  padding: 8px 10px 10px;
}

.properties-header {
  display: flex;
  margin-bottom: 9px;
  gap: 14px;
  align-items: center;
}

.properties-header h2,
.properties-header p {
  margin: 0;
}

.properties-header h2 {
  margin-bottom: 4px;
  font-size: 17px;
}

.properties-body hr {
  height: 2px;
  margin: 9px 0;
  border: 0;
  box-shadow:
    inset 0 1px #808080,
    inset 0 -1px #fff;
}

.detailed-properties {
  margin-bottom: 12px;
}

.detailed-properties > div {
  grid-template-columns: 92px minmax(0, 1fr);
}

.compact-list {
  margin: 5px 0;
  padding-left: 20px;
  line-height: 1.5;
}

.dialog-actions {
  margin-top: 12px;
  justify-content: flex-end;
}

/* Project detail */

.project-detail-window {
  min-height: 360px;
}

.project-detail-window > .window-body {
  padding: 14px;
}

.project-detail-window h2 {
  margin: 2px 0 6px;
  font-family: "Arial Black", Impact, sans-serif;
  font-size: 29px;
  letter-spacing: -0.04em;
}

.project-summary {
  margin: 0 0 10px;
  font-size: 13px;
  font-weight: 700;
  line-height: 1.45;
}

.tag-list {
  display: flex;
  margin-bottom: 10px;
  flex-wrap: wrap;
  gap: 4px;
}

.tag-list span {
  padding: 2px 5px;
  border: 1px solid #000080;
  color: #000080;
  background: #fff;
  font-family: var(--mono-font);
  font-size: 9px;
}

.project-facts {
  margin: 5px 0;
  padding-left: 20px;
}

.project-facts li {
  margin: 5px 0;
  line-height: 1.4;
}

.project-links {
  margin-top: 11px;
}

/* Terminal */

.terminal-window {
  min-height: 340px;
}

.terminal-body {
  display: flex;
  min-height: 310px;
  padding: 8px;
  flex-direction: column;
  color: #d6d6d6;
  background: #050505;
  font-family: var(--mono-font);
}

.terminal-body pre {
  min-height: 0;
  margin: 0 0 8px;
  padding: 8px;
  flex: 1 1 auto;
  overflow: auto;
  border: 2px inset #c0c0c0;
  color: #f2f2f2;
  background: #000;
  font-family: inherit;
  font-size: 12px;
  line-height: 1.42;
  white-space: pre-wrap;
  text-shadow: 0 0 2px rgb(168 242 108 / 24%);
}

.terminal-form {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  gap: 6px;
  align-items: center;
}

.terminal-form label {
  color: #a8f26c;
}

.terminal-form input {
  width: 100%;
  color: #fff;
  background: #000;
  caret-color: #a8f26c;
  font-family: inherit;
}

.terminal-body small {
  margin-top: 7px;
  color: #bcbcbc;
}

/* Games */

.games-window {
  min-height: 330px;
}

.games-hub {
  padding: 14px;
}

.game-launcher-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin-top: 16px;
}

.game-launcher-grid > button {
  display: grid;
  min-height: 112px;
  padding: 12px;
  grid-template-columns: 52px minmax(0, 1fr);
  gap: 12px;
  align-items: center;
  color: #000;
  text-align: left;
}

.game-launcher-grid > button img {
  display: block;
  width: 48px;
  height: 48px;
  object-fit: contain;
  image-rendering: pixelated;
}

.game-launcher-grid > button span,
.game-launcher-grid > button strong,
.game-launcher-grid > button small {
  display: block;
  min-width: 0;
}

.game-launcher-grid > button strong {
  margin-bottom: 6px;
  font-size: 14px;
}

.game-launcher-grid > button small {
  color: #444;
  line-height: 1.35;
}

.game-window {
  min-height: 0;
}

.game-status {
  min-height: 28px;
  margin: 9px 0 0;
  line-height: 1.35;
  text-align: center;
}

.mine-shell {
  display: grid;
  padding: 9px;
  place-items: center;
  background: var(--chrome);
}

.mine-scoreboard {
  display: flex;
  width: max-content;
  min-width: 243px;
  margin-bottom: 8px;
  padding: 5px 7px;
  align-items: center;
  justify-content: space-between;
  border: 2px solid;
  border-color: #808080 #fff #fff #808080;
  background: #c0c0c0;
}

.mine-scoreboard output {
  display: grid;
  width: 56px;
  height: 34px;
  place-items: center;
  border: 2px inset #fff;
  color: #ff2929;
  background:
    repeating-linear-gradient(90deg, transparent 0 2px, rgb(255 0 0 / 5%) 2px 3px),
    #080000;
  font-family: "Courier New", monospace;
  font-size: 27px;
  font-weight: 700;
  line-height: 1;
  letter-spacing: 1px;
  text-shadow: 0 0 4px #b00000;
}

.mine-scoreboard button {
  width: 36px;
  min-width: 36px;
  height: 34px;
  min-height: 34px;
  padding: 0;
  font-family: Arial, sans-serif;
  font-size: 22px;
  line-height: 28px;
}

.minesweeper-board {
  display: grid;
  width: max-content;
  padding: 3px;
  grid-template-columns: repeat(var(--mine-columns), 27px);
  grid-template-rows: repeat(var(--mine-rows), 27px);
  border: 3px solid;
  border-color: #808080 #fff #fff #808080;
  background: #808080;
}

.mine-cell {
  display: grid;
  width: 27px;
  min-width: 27px;
  height: 27px;
  min-height: 27px;
  padding: 0;
  place-items: center;
  border: 2px solid;
  border-color: #fff #404040 #404040 #fff;
  border-radius: 0;
  color: #000;
  background: #c0c0c0;
  box-shadow: none;
  font-family: Arial, sans-serif;
  font-size: 17px;
  font-weight: 900;
  line-height: 1;
  text-shadow: none;
}

.mine-cell:not(.is-revealed):active {
  border: 1px solid #808080;
}

.mine-cell.is-revealed {
  border: 1px solid #808080;
  background: #c0c0c0;
}

.mine-cell.is-flagged {
  color: #d00000;
}

.mine-cell.is-mine {
  color: #000;
}

.mine-cell.is-exploded {
  color: #000;
  background: #f00;
}

.mine-cell.is-wrong-flag {
  color: #f00;
  background:
    linear-gradient(45deg, transparent 43%, #f00 44% 53%, transparent 54%),
    #c0c0c0;
}

.mine-cell.mine-count-1 {
  color: #0000f0;
}

.mine-cell.mine-count-2 {
  color: #005800;
}

.mine-cell.mine-count-3 {
  color: #9b0000;
}

.mine-cell.mine-count-4 {
  color: #000080;
}

.mine-cell.mine-count-5 {
  color: #800000;
}

.mine-cell.mine-count-6 {
  color: #005454;
}

.mine-cell.mine-count-7 {
  color: #000;
}

.mine-cell.mine-count-8 {
  color: #484848;
}

.mine-cell:focus-visible {
  position: relative;
  z-index: 2;
  outline: 2px dotted #000;
  outline-offset: -5px;
}

.freecell-window {
  min-height: min(650px, calc(100dvh - var(--taskbar-height) - 12px));
}

.freecell-shell {
  padding: 0 !important;
  background: #0a7045;
}

.freecell-toolbar {
  position: sticky;
  z-index: 20;
  top: 0;
  left: 0;
  display: flex;
  min-width: 720px;
  min-height: 40px;
  padding: 7px 8px;
  gap: 7px;
  align-items: center;
  border-bottom: 1px solid #404040;
  background: var(--chrome);
}

.freecell-toolbar span {
  min-width: 0;
  margin-left: 4px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.freecell-board {
  --card-width: 68px;
  --card-height: 94px;
  min-width: 720px;
  min-height: 520px;
  padding: 12px 14px 20px;
  color: #fff;
  background:
    radial-gradient(circle at 1px 1px, rgb(255 255 255 / 8%) 1px, transparent 1.2px) 0 0 / 4px 4px,
    linear-gradient(135deg, rgb(0 0 0 / 10%), transparent 50%, rgb(255 255 255 / 5%)),
    #0a7045;
  box-shadow: inset 1px 1px #004b2d;
}

.freecell-top-row {
  display: flex;
  margin-bottom: 18px;
  gap: 32px;
  justify-content: space-between;
}

.freecell-top-row section {
  min-width: calc((var(--card-width) * 4) + 21px);
}

.freecell-top-row strong {
  display: block;
  margin-bottom: 5px;
  color: #fff;
  font-weight: 700;
  text-shadow: 1px 1px #004020;
}

.freecell-slots {
  display: grid;
  grid-template-columns: repeat(4, var(--card-width));
  gap: 7px;
}

.card-slot,
.tableau-column {
  position: relative;
  width: var(--card-width);
}

.card-slot {
  height: var(--card-height);
  border: 2px solid rgb(0 45 25 / 72%);
  border-radius: 5px;
  box-shadow:
    1px 1px rgb(255 255 255 / 22%),
    inset 1px 1px rgb(0 0 0 / 24%);
}

.foundation-slot {
  border-color: rgb(255 255 255 / 35%);
}

.card-slot .playing-card,
.card-slot .card-drop-target {
  position: absolute;
  inset: -2px;
}

.foundation-marker {
  color: rgb(255 255 255 / 42%);
  font-family: Georgia, serif;
  font-size: 46px;
  line-height: 1;
}

.freecell-tableau {
  display: grid;
  grid-template-columns: repeat(8, var(--card-width));
  gap: 17px;
  align-items: start;
}

.tableau-column {
  min-height: max(
    360px,
    calc(var(--card-height) + ((var(--tableau-count) - 1) * 27px))
  );
  border-radius: 5px;
}

.tableau-column:empty,
.tableau-column:has(> .card-drop-target) {
  height: var(--card-height);
  min-height: var(--card-height);
  border: 2px solid rgb(0 45 25 / 72%);
}

.playing-card,
.card-drop-target {
  width: var(--card-width);
  min-width: var(--card-width);
  height: var(--card-height);
  min-height: var(--card-height);
  padding: 0;
  border-radius: 5px;
}

.card-drop-target {
  display: grid;
  place-items: center;
  border: 1px dashed rgb(255 255 255 / 48%);
  color: #fff;
  background: rgb(0 55 30 / 18%);
  box-shadow: none;
}

.card-drop-target:hover,
.card-drop-target:focus-visible {
  border-color: #fff;
  background: rgb(255 255 255 / 10%);
}

.tableau-column > .card-drop-target {
  position: absolute;
  top: 0;
  left: 0;
}

.playing-card {
  position: relative;
  display: block;
  overflow: hidden;
  border: 1px solid #111;
  color: #111;
  background:
    linear-gradient(135deg, rgb(255 255 255 / 75%), transparent 40%),
    #fff;
  box-shadow:
    1px 1px 0 rgb(0 0 0 / 65%),
    inset 1px 1px #fff;
  font-family: Georgia, "Times New Roman", serif;
  line-height: 1;
  text-align: left;
}

.tableau-column > .playing-card {
  position: absolute;
  z-index: calc(var(--card-index) + 1);
  top: calc(var(--card-index) * 27px);
  left: 0;
}

.playing-card[data-movable="false"] {
  cursor: default;
}

.playing-card:hover[data-movable="true"] {
  transform: translateY(-2px);
  box-shadow:
    2px 3px 0 rgb(0 0 0 / 55%),
    inset 1px 1px #fff;
}

.playing-card.is-selected {
  border: 3px solid #fff;
  outline: 3px dotted #000080;
  outline-offset: -6px;
  background: #ffffca;
  box-shadow: 0 0 0 3px #000080;
}

.playing-card:focus-visible,
.card-drop-target:focus-visible {
  z-index: 30;
  outline: 3px dotted #000;
  outline-offset: -6px;
}

.card-red {
  color: #c00000;
}

.card-black {
  color: #080808;
}

.card-corner {
  position: absolute;
  font-size: 17px;
  font-weight: 700;
  line-height: 1;
}

.card-corner-top {
  top: 6px;
  left: 6px;
}

.card-corner-bottom {
  right: 6px;
  bottom: 6px;
  transform: rotate(180deg);
}

.card-suit {
  position: absolute;
  top: 50%;
  left: 50%;
  font-size: 35px;
  transform: translate(-50%, -50%);
}

/* Network, settings, recycle, help */

.network-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 7px;
}

.network-grid a {
  display: grid;
  min-height: 68px;
  padding: 8px;
  grid-template-columns: 46px minmax(0, 1fr);
  grid-template-rows: 1fr 1fr;
  column-gap: 10px;
  align-items: center;
  border: 2px outset #fff;
  color: #000;
  background: #c0c0c0;
  text-decoration: none;
}

.network-grid a:active {
  border-style: inset;
}

.network-icon {
  display: block;
  width: 44px;
  height: 44px;
  grid-row: 1 / 3;
  object-fit: contain;
  image-rendering: pixelated;
  filter: drop-shadow(1px 1px 0 rgb(0 0 0 / 28%));
}

.network-grid strong {
  align-self: end;
}

.network-grid small {
  align-self: start;
  color: #444;
}

.settings-body fieldset + fieldset {
  margin-top: 10px;
}

.recycle-list {
  display: grid;
  max-height: 260px;
  overflow-y: auto;
  background: #fff;
}

.recycle-list button {
  display: grid;
  min-height: 55px;
  padding: 6px 8px;
  grid-template-columns: 34px minmax(0, 1fr);
  grid-template-rows: auto auto;
  gap: 2px 8px;
  border: 0;
  border-bottom: 1px dotted #888;
  background: transparent;
  box-shadow: none;
  text-align: left;
}

.recycle-list button > img {
  display: block;
  width: 30px;
  height: 30px;
  grid-row: 1 / 3;
  object-fit: contain;
  image-rendering: pixelated;
}

.recycle-list button:hover,
.recycle-list button:focus-visible,
.recycle-list button.is-selected {
  color: #fff;
  background: #000080;
}

.recycle-list small {
  color: #555;
}

.recycle-list button:hover small,
.recycle-list button:focus-visible small,
.recycle-list button.is-selected small {
  color: #fff;
}

.empty-state {
  min-height: 190px;
  padding: 28px;
  border: 2px inset #fff;
  background: #fff;
  text-align: center;
}

.empty-state .pixel-icon {
  margin: auto;
}

.empty-state p {
  margin-bottom: 4px;
  font-weight: 700;
}

.help-list {
  padding-left: 22px;
  line-height: 1.55;
}

/* Start menu and taskbar */

.taskbar {
  position: fixed;
  z-index: 20000;
  right: 0;
  bottom: 0;
  left: 0;
  display: flex;
  height: var(--taskbar-height);
  padding: 3px 4px;
  align-items: center;
  gap: 4px;
  border-top: 2px solid #fff;
  background: #c0c0c0;
  box-shadow: inset 0 1px #dfdfdf;
}

.start-button {
  display: flex;
  min-width: 74px;
  height: 29px;
  padding: 3px 7px;
  align-items: center;
  gap: 5px;
  font-size: 12px;
}

.start-button[aria-expanded="true"] {
  box-shadow:
    inset -1px -1px #fff,
    inset 1px 1px #0a0a0a,
    inset -2px -2px #dfdfdf,
    inset 2px 2px #808080;
}

.start-icon {
  display: block;
  width: 19px;
  height: 19px;
  object-fit: contain;
  image-rendering: pixelated;
}

.taskbar-divider {
  width: 2px;
  height: 26px;
  border-left: 1px solid #808080;
  border-right: 1px solid #fff;
}

.taskbar-apps {
  display: flex;
  min-width: 0;
  flex: 1 1 auto;
  gap: 3px;
  overflow: hidden;
}

.taskbar-app {
  display: flex;
  min-width: 90px;
  max-width: 180px;
  height: 28px;
  padding: 3px 8px;
  flex: 1 1 130px;
  align-items: center;
  gap: 5px;
  overflow: hidden;
  text-align: left;
  white-space: nowrap;
}

.taskbar-app span {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
}

.taskbar-icon {
  display: block;
  width: 17px;
  height: 17px;
  flex: 0 0 17px;
  object-fit: contain;
  image-rendering: pixelated;
}

.taskbar-app.is-active {
  font-weight: 700;
  background:
    repeating-linear-gradient(135deg, #fff 0 1px, #c0c0c0 1px 3px);
  box-shadow:
    inset -1px -1px #fff,
    inset 1px 1px #0a0a0a,
    inset -2px -2px #dfdfdf,
    inset 2px 2px #808080;
}

.show-desktop {
  width: 26px;
  min-width: 26px;
  height: 27px;
  padding: 2px;
}

.show-desktop-icon {
  display: block;
  width: 18px;
  height: 18px;
  object-fit: contain;
  image-rendering: pixelated;
}

.tray-clock {
  display: flex;
  min-width: 102px;
  height: 28px;
  padding: 3px 7px;
  align-items: center;
  justify-content: center;
  gap: 5px;
  border: 2px inset #fff;
  background: #c0c0c0;
  box-shadow: none;
}

.tray-led {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #39b54a;
  box-shadow:
    inset 1px 1px #aaffb0,
    0 0 0 1px #215b29;
}

.start-menu {
  position: fixed;
  z-index: 19000;
  bottom: calc(var(--taskbar-height) - 1px);
  left: 3px;
  display: grid;
  width: 310px;
  min-height: 390px;
  grid-template-columns: 34px 1fr;
  padding: 3px;
}

.start-menu-rail {
  display: flex;
  padding: 8px 5px;
  align-items: center;
  color: #c0c0c0;
  background: linear-gradient(#000080, #1084d0);
  font-size: 17px;
  font-weight: 700;
  letter-spacing: -0.03em;
  text-orientation: mixed;
  transform: rotate(180deg);
  writing-mode: vertical-rl;
}

.start-menu-rail strong {
  color: #fff;
}

.start-menu-items {
  display: flex;
  padding: 3px;
  flex-direction: column;
  background: #c0c0c0;
}

.start-menu-items > button {
  display: grid;
  min-height: 48px;
  padding: 4px 6px;
  grid-template-columns: 38px minmax(0, 1fr);
  gap: 8px;
  align-items: center;
  border: 0;
  background: transparent;
  box-shadow: none;
  text-align: left;
}

.start-menu-items > button:hover,
.start-menu-items > button:focus-visible {
  color: #fff;
  background: #000080;
}

.start-menu-items > button:active {
  padding: 4px 6px;
  box-shadow: none;
}

.start-menu-items strong,
.start-menu-items small {
  display: block;
}

.start-menu-items small {
  margin-top: 2px;
  color: #555;
  font-size: 9px;
}

.start-menu-items > button:hover small,
.start-menu-items > button:focus-visible small {
  color: #fff;
}

.mini-icon {
  display: block;
  width: 34px;
  height: 34px;
  object-fit: contain;
  image-rendering: pixelated;
}

.start-menu-items hr {
  width: 100%;
  height: 2px;
  margin: 3px 0;
  border: 0;
  box-shadow:
    inset 0 1px #808080,
    inset 0 -1px #fff;
}

.clock-popover {
  position: fixed;
  z-index: 19001;
  right: 4px;
  bottom: calc(var(--taskbar-height) + 4px);
  width: 250px;
}

.clock-popover .window-body {
  text-align: center;
}

.clock-popover strong,
.clock-popover p {
  display: block;
}

.clock-popover p {
  margin: 8px 0;
  color: #000080;
  font-family: var(--mono-font);
  font-size: 22px;
  font-weight: 700;
}

/* Clippy */

.clippy {
  position: fixed;
  z-index: 15000;
  right: 18px;
  bottom: calc(var(--taskbar-height) + 5px);
  display: block;
  width: 300px;
  height: 116px;
  pointer-events: none;
}

.clippy.is-hidden {
  display: none;
}

.clippy-character {
  position: relative;
  display: block;
  width: 112px;
  min-width: 112px;
  height: 116px;
  margin-left: auto;
  padding: 0;
  border: 0;
  background: transparent;
  box-shadow: none;
  pointer-events: auto;
  filter: drop-shadow(2px 3px 1px rgb(0 0 0 / 36%));
}

.clippy-character:active {
  padding: 0;
  box-shadow: none;
}

.clippy-character:focus-visible {
  outline: 2px dotted #fff;
  outline-offset: 2px;
}

.clippy-sprite {
  --clippy-frame-x: 0;
  --clippy-frame-y: 0;

  position: absolute;
  bottom: -3px;
  left: 50%;
  display: block;
  width: 124px;
  height: 93px;
  background-image: url("clippy-sprites-transparent.png");
  background-repeat: no-repeat;
  background-position:
    calc(var(--clippy-frame-x) * -124px)
    calc(var(--clippy-frame-y) * -93px);
  background-size: 2729px 3813px;
  image-rendering: auto;
  transform: translateX(-50%) scale(1);
  transform-origin: center bottom;
  will-change: background-position;
}

.clippy-balloon {
  position: absolute;
  right: 0;
  bottom: 104px;
  width: 280px;
  margin: 0;
  pointer-events: auto;
  transform-origin: calc(100% - 40px) 100%;
}

.clippy-balloon.is-speaking {
  animation: clippy-balloon-pop 180ms steps(3, end);
}

@keyframes clippy-balloon-pop {
  0% {
    opacity: 0;
    transform: scale(0.82);
  }

  66% {
    opacity: 1;
    transform: scale(1.03);
  }

  100% {
    opacity: 1;
    transform: scale(1);
  }
}

.clippy-balloon::after {
  position: absolute;
  right: 30px;
  bottom: -12px;
  width: 22px;
  height: 22px;
  border-right: 2px outset #fff;
  border-bottom: 2px outset #fff;
  background: #ffffd0;
  content: "";
  transform: rotate(45deg);
}

.clippy-balloon-body {
  position: relative;
  z-index: 1;
  max-height: min(260px, calc(100dvh - var(--taskbar-height) - 145px));
  padding: 11px;
  overflow: auto;
  border: 2px outset #fff;
  background: #ffffd0;
  box-shadow: 2px 2px 0 rgb(0 0 0 / 30%);
}

.clippy-balloon strong {
  display: block;
  margin-bottom: 5px;
}

.clippy-balloon p {
  margin: 0 0 9px;
  line-height: 1.4;
}

.clippy-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
}

.clippy-actions button {
  min-width: 0;
  padding-right: 6px;
  padding-left: 6px;
  font-size: 10px;
}

.clippy-balloon.is-closed {
  display: none;
}

/* Dialogs, toast, power states */

.system-dialog {
  max-width: calc(100vw - 24px);
  padding: 0;
  border: 0;
  color: #000;
  background: transparent;
}

.system-dialog::backdrop {
  background: rgb(0 0 0 / 35%);
}

.system-dialog > .window {
  width: min(430px, calc(100vw - 24px));
}

.system-dialog .window-body {
  padding: 12px;
}

.run-prompt {
  display: flex;
  margin-bottom: 8px;
  gap: 12px;
  align-items: center;
}

.run-prompt p {
  margin: 0;
}

.dialog-error {
  margin: 8px 0 0;
  color: #b00000;
  font-weight: 700;
}

.screensaver,
.power-screen {
  position: fixed;
  z-index: 99998;
  inset: 0;
}

.screensaver {
  overflow: hidden;
  background:
    radial-gradient(circle at 30% 30%, #000080, transparent 24%),
    radial-gradient(circle at 70% 65%, #1084d0, transparent 20%),
    #000;
}

.screensaver button {
  width: 100%;
  height: 100%;
  padding: 0;
  border: 0;
  color: #fff;
  background: transparent;
  box-shadow: none;
}

.screensaver-logo {
  display: block;
  color: var(--signal);
  font-family: "Arial Black", Impact, sans-serif;
  font-size: clamp(50px, 12vw, 150px);
  letter-spacing: -0.07em;
  text-shadow:
    4px 4px #000080,
    8px 8px #1084d0;
}

.screensaver button > span:not(.screensaver-logo),
.screensaver button small {
  display: block;
  margin-top: 14px;
  font-family: var(--mono-font);
}

.power-screen {
  display: grid;
  place-items: center;
  color: #ffb000;
  background: #000;
  font-family: var(--mono-font);
  font-size: 17px;
  text-align: center;
}

.power-screen button {
  margin-top: 14px;
}

.toast {
  position: fixed;
  z-index: 30000;
  top: 12px;
  right: 12px;
  bottom: auto;
  max-width: min(360px, calc(100vw - 24px));
}

.toast .window-body {
  padding: 8px 12px;
  background: #ffffd0;
}

.no-script-message {
  position: fixed;
  z-index: 200000;
  inset: 20px;
  padding: 20px;
  color: #000;
  background: #fff;
}

/* Mobile */

@media (max-width: 720px) {
  :root {
    --taskbar-height: 42px;
  }

  .desktop {
    min-height: 0;
  }

  .desktop-watermark {
    display: none;
  }

  .desktop-shortcuts {
    top: 4px;
    right: 3px;
    bottom: auto;
    left: 3px;
    display: flex;
    width: auto;
    height: 68px;
    gap: 3px;
    overflow-x: auto;
    overflow-y: hidden;
  }

  .desktop-shortcut {
    width: 74px;
    min-width: 74px;
    min-height: 63px;
  }

  .desktop-shortcut .pixel-icon {
    width: 30px;
    height: 30px;
  }

  .desktop-shortcut-label {
    max-height: 24px;
    overflow: hidden;
    font-size: 8px;
  }

  .window-layer {
    top: 74px;
    bottom: var(--taskbar-height);
    padding: 4px;
  }

  .app-window,
  .app-window.is-maximized {
    position: absolute;
    top: 4px !important;
    right: 4px !important;
    bottom: 4px !important;
    left: 4px !important;
    display: none;
    width: auto !important;
    height: auto !important;
    min-width: 0;
    max-width: none;
    max-height: none;
    resize: none;
  }

  .app-window.is-mobile-active:not(.is-minimized) {
    display: flex;
  }

  .app-window > .title-bar {
    cursor: default;
  }

  .compact-window {
    min-width: 0;
  }

  .hero-window-body {
    padding: 9px;
  }

  .hero-grid {
    grid-template-columns: 74px minmax(0, 1fr);
    gap: 10px;
  }

  .hero-avatar {
    width: 70px;
    height: 86px;
  }

  .avatar-initials {
    font-size: 30px;
  }

  .hero-copy h1 {
    font-size: clamp(32px, 12vw, 48px);
  }

  .hero-kicker {
    font-size: 8px;
  }

  .hero-thesis {
    margin-top: 8px;
    font-size: 11px;
  }

  .hero-details-grid,
  .lineage-layout,
  .explorer-layout,
  .astral-panel,
  .network-grid {
    grid-template-columns: 1fr;
  }

  .system-quote {
    min-height: 95px;
  }

  .lineage-track {
    min-height: 285px;
    grid-template-columns: 1fr;
    grid-template-rows: repeat(5, 1fr);
    padding: 8px 12px;
  }

  .lineage-rail {
    top: 10%;
    bottom: 10%;
    left: 50%;
    width: 4px;
    height: auto;
    border-top: 0;
    border-right: 1px solid #fff;
    border-left: 1px solid #000;
  }

  .lineage-signal {
    top: calc(10% + (var(--step) * 20%));
    left: 50%;
    transition: top 480ms steps(8, end);
    transform: translate(-50%, -50%);
  }

  .lineage-node {
    width: 70%;
    min-height: 45px;
    margin: auto;
  }

  .lineage-detail {
    min-height: 115px;
  }

  ul.explorer-tree {
    display: none;
  }

  .tab-panel,
  .tab-panel > .window-body {
    min-height: 0;
  }

  .work-tabs {
    display: flex;
    max-width: 100%;
    overflow-x: auto;
  }

  .work-tabs li {
    flex: 0 0 auto;
  }

  .project-file {
    grid-template-columns: 32px minmax(0, 1fr);
  }

  .project-file em {
    display: none;
  }

  .lab-projects {
    grid-template-columns: 1fr;
  }

  .astral-panel {
    padding: 13px !important;
  }

  .astral-mark {
    width: 80px;
    height: 80px;
    margin: auto;
    font-size: 28px;
  }

  .astral-panel h2 {
    font-size: 31px;
  }

  .fact-strip {
    grid-template-columns: 1fr;
  }

  .papers-header {
    grid-template-columns: repeat(3, 1fr);
  }

  .papers-header > div:first-child {
    grid-column: 1 / -1;
  }

  .career-log {
    height: auto;
  }

  .network-grid a {
    min-height: 58px;
  }

  .game-launcher-grid {
    grid-template-columns: 1fr;
  }

  .game-launcher-grid > button {
    min-height: 76px;
    padding: 8px;
    grid-template-columns: 42px minmax(0, 1fr);
  }

  .game-launcher-grid > button img {
    width: 38px;
    height: 38px;
  }

  .mine-scoreboard {
    min-width: 225px;
  }

  .minesweeper-board {
    grid-template-columns: repeat(var(--mine-columns), 25px);
    grid-template-rows: repeat(var(--mine-rows), 25px);
  }

  .mine-cell {
    width: 25px;
    min-width: 25px;
    height: 25px;
    min-height: 25px;
    font-size: 15px;
  }

  .freecell-window {
    min-height: 0;
  }

  .freecell-toolbar {
    position: sticky;
    min-width: 0;
    flex-wrap: wrap;
  }

  .freecell-toolbar span {
    width: 100%;
    margin: 2px 0 0;
    white-space: normal;
  }

  .freecell-board {
    min-width: 720px;
  }

  .taskbar-apps {
    padding-right: 40px;
  }

  .clippy {
    z-index: 20001;
    right: 82px;
    bottom: 3px;
    width: 36px;
    height: 36px;
  }

  .clippy-character {
    width: 36px;
    min-width: 36px;
    height: 36px;
  }

  .clippy-sprite {
    bottom: -1px;
    transform: translateX(-50%) scale(0.32);
  }

  .clippy-balloon {
    right: -77px;
    bottom: 41px;
    width: min(270px, calc(100vw - 70px));
  }

  .clippy-balloon::after {
    right: 94px;
  }

  .clippy-actions button {
    min-height: 26px;
  }

  .start-menu {
    right: 3px;
    width: auto;
    max-height: calc(100dvh - var(--taskbar-height) - 6px);
    min-height: 0;
    overflow-y: auto;
  }

  .start-menu-items > button {
    min-height: 46px;
  }

  .taskbar {
    gap: 2px;
  }

  .start-button {
    min-width: 66px;
  }

  .taskbar-divider,
  .show-desktop {
    display: none;
  }

  .taskbar-app {
    min-width: 44px;
    padding: 3px 5px;
    font-size: 9px;
  }

  .tray-clock {
    min-width: 78px;
    padding: 3px;
    font-size: 9px;
  }

  .tray-led {
    display: none;
  }

  .clock-popover {
    right: 3px;
    bottom: calc(var(--taskbar-height) + 3px);
  }
}

@media (max-height: 680px) and (min-width: 721px) {
  .desktop-shortcuts {
    grid-template-columns: repeat(2, 86px);
    width: 180px;
  }

  .desktop-shortcut {
    min-height: 58px;
  }

  .lineage-window {
    --y: calc(100vh - 290px) !important;
  }

  .clippy-balloon {
    bottom: 82px;
    width: 260px;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }

  .boot-screen {
    display: none;
  }
}

@media (forced-colors: active) {
  .desktop::before,
  .desktop::after {
    display: none;
  }

  .desktop-shortcut,
  .clippy-character {
    forced-color-adjust: none;
  }

  .lineage-node.is-current,
  .network-icon {
    border: 2px solid CanvasText;
  }
}

@media print {
  html,
  body {
    overflow: visible;
  }

  .desktop {
    height: auto;
    overflow: visible;
    padding: 0;
    background: #fff;
  }

  .desktop::before,
  .desktop::after,
  .desktop-shortcuts,
  .taskbar,
  .start-menu,
  .clippy,
  .boot-screen,
  .desktop-watermark {
    display: none !important;
  }

  .window-layer {
    position: static;
  }

  .app-window {
    position: static;
    display: block !important;
    width: 100% !important;
    max-height: none;
    margin-bottom: 16px;
    break-inside: avoid;
  }
}

/* Résumé window */
.resume-window .properties-header {
  margin-bottom: 12px;
}

.resume-headline {
  font-weight: 700;
}

.resume-meta {
  color: #404040;
  font-size: 11px;
}

.resume-note {
  padding: 8px 10px;
  margin-bottom: 12px;
  line-height: 1.5;
}

.resume-note p {
  margin: 0 0 6px;
}

.resume-note p:last-child {
  margin-bottom: 0;
}

.resume-window fieldset {
  margin-bottom: 12px;
}

.resume-role + .resume-role {
  margin-top: 10px;
  padding-top: 8px;
  border-top: 1px solid #dfdfdf;
}

.resume-role h3 {
  display: flex;
  margin: 0 0 3px;
  gap: 10px;
  align-items: baseline;
  justify-content: space-between;
  font-size: 13px;
}

.resume-role h3 span {
  color: #000080;
  font-family: var(--mono-font);
  font-size: 10px;
  font-weight: 400;
  white-space: nowrap;
}

.resume-org {
  margin: 0 0 4px;
  font-style: italic;
}

.resume-role ul {
  margin: 4px 0 0;
  padding-left: 18px;
  line-height: 1.45;
}

.resume-role ul li {
  margin: 3px 0;
}

.resume-skills {
  margin-bottom: 0;
}

.resume-actions {
  margin-top: 4px;
}
