:root {
  --ink: #080c21;
  --chrome: #c4c5cb;
  --sky: url('../assets/images/sky-day-night.webp');
  --hand-cursor: url('../assets/icons/hand-cursor.svg') 11 1, pointer;
  --pink: #b85d85;
  --pixel: 'Pixelify Sans', monospace;
}
* {
  box-sizing: border-box;
}
html,
body {
  margin: 0;
  min-height: 100%;
  background: #1264dc;
}
body {
  font-family: var(--pixel);
  color: var(--ink);
  overflow-x: hidden;
}
button,
a,
input {
  font: inherit;
}
button {
  color: inherit;
}
button,
a,
[role='button'] {
  touch-action: manipulation;
}
button:not(:disabled),
a[href],
.titlebar {
  cursor: var(--hand-cursor);
}
button:focus-visible,
a:focus-visible {
  outline: 3px dashed #f1cd56;
  outline-offset: 5px;
}
button {
  border-radius: 0;
}
a {
  color: inherit;
}
button::-moz-focus-inner {
  border: 0;
}
[hidden] {
  display: none !important;
}
.desktop {
  position: relative;
  isolation: isolate;
  width: 100%;
  height: 100svh;
  min-height: 740px;
  overflow: hidden;
  background: #1264dc;
  transition: background 2.2s;
}
.sky {
  position: absolute;
  inset: -1.2%;
  background-image: var(--sky);
  background-size: 200% 100%;
  background-repeat: no-repeat;
  pointer-events: none;
  image-rendering: pixelated;
  transition: opacity 2.2s ease;
  will-change: opacity;
}
.sky.day {
  background-position: left center;
}
.sky.night {
  background-position: right center;
  opacity: 0;
}
[data-period='night'] .sky.day {
  opacity: 0;
}
[data-period='night'] .sky.night {
  opacity: 1;
}
[data-period='night'] .desktop {
  background: #101339;
}
.outer-skies {
  position: absolute;
  inset: 0;
  z-index: -2;
  overflow: hidden;
}
.outer-skies .sky {
  animation: cloud-drift 30s ease-in-out infinite alternate;
}
.outer-skies:after {
  content: '';
  position: absolute;
  inset: 0;
  opacity: 0.035;
  background: repeating-linear-gradient(0deg, #001a5b 0 1px, transparent 1px 4px);
  pointer-events: none;
}
.stage {
  position: absolute;
  inset: 22px 20px 115px 20px;
}
.shortcuts {
  position: absolute;
  z-index: 8;
  left: clamp(16px, 3.5vw, 65px);
  top: clamp(32px, 6vh, 70px);
  display: flex;
  flex-direction: column;
  gap: 18px;
}
.shortcut {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 9px;
  padding: 10px 7px 8px;
  width: 106px;
  background: transparent;
  border: 1px solid transparent;
  color: #fff;
  font-size: 17px;
  line-height: 1;
  white-space: nowrap;
  /* Label plates (white, inverted when selected) live in css/mac.css. */
}
.shortcut:hover {
  background: #a8bdff35;
  border-color: #d3dfff66;
}
.shortcut:focus-visible {
  outline-offset: 0;
}
.shortcut[aria-expanded='true'] {
  background: #a7a4f35c;
  border-color: #e0d7ff99;
  box-shadow: inset 0 0 0 1px #eee5ff3b;
}
.shortcut svg {
  width: 48px;
  height: 48px;
  image-rendering: pixelated;
  filter: drop-shadow(2px 3px #00174955);
}
.os-window {
  position: absolute;
  padding: 4px;
  background: var(--chrome);
  border: 1px solid #f9f4e9;
  box-shadow:
    inset 1px 1px #fff,
    inset -2px -2px #454751,
    3px 4px 0 #03144355,
    0 17px 45px #00226425;
  max-width: 100%;
}
.main-window {
  width: min(850px, 69vw);
  height: min(690px, calc(100% - 28px));
  min-height: 480px;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  z-index: 3;
  display: flex;
  flex-direction: column;
}
.titlebar {
  height: 29px;
  min-height: 29px;
  display: flex;
  align-items: center;
  gap: 7px;
  justify-content: space-between;
  padding: 3px 4px 3px 7px;
  background: linear-gradient(90deg, #0c087d, #1736b5);
  color: #fff;
  user-select: none;
  touch-action: none;
}
.window-title {
  display: flex;
  align-items: center;
  gap: 7px;
  min-width: 0;
  font-size: 19px;
  line-height: 1;
  letter-spacing: 0.1px;
  font-weight: 500;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.window-title svg {
  height: 21px;
  width: 18px;
  flex-shrink: 0;
}
.controls {
  display: flex;
  gap: 4px;
  flex-shrink: 0;
}
.os-button {
  display: grid;
  place-items: center;
  width: 23px;
  height: 22px;
  padding: 0;
  border: 0;
  background: #ceced3;
  box-shadow:
    inset 1px 1px #fff,
    inset -1px -1px #10121c,
    inset -2px -2px #777a85;
  color: #080c21;
  line-height: 1;
}
.os-button:active,
.retro-button:active {
  box-shadow:
    inset 1px 1px #222,
    inset -1px -1px #fff;
  transform: translate(1px, 1px);
}
.os-button svg {
  width: 13px;
  height: 13px;
}
.main-content {
  position: relative;
  flex: 1;
  min-height: 0;
  margin-top: 4px;
  border: 1px solid #4b4e66;
  overflow: hidden;
  background: #2979ef;
}
.inner-skies {
  position: absolute;
  inset: 0;
  overflow: hidden;
}
.inner-skies .sky {
  inset: -1.5%;
  animation: inner-drift 24s ease-in-out infinite alternate;
}
.cloud-bed {
  position: absolute;
  inset: auto -2px -2px;
  height: 41%;
  pointer-events: none;
  background: linear-gradient(0deg, #edf1ffed, #f0f2ffad 58%, #f4f5ff00);
  opacity: 0.67;
  transition: opacity 2.2s;
}
[data-period='night'] .cloud-bed {
  opacity: 0.9;
  background: linear-gradient(0deg, #c4bbebeb, #e2d4f0b0 65%, #f0d9f000);
}
.pineapple {
  position: absolute;
  display: block;
  height: 66%;
  width: 49%;
  object-fit: contain;
  left: 50%;
  top: 2%;
  transform: translateX(-50%);
  image-rendering: pixelated;
  filter: drop-shadow(0 7px 0 #24315e0c);
  animation: pine-bob 6s ease-in-out infinite;
  user-select: none;
  -webkit-user-drag: none;
  pointer-events: none;
}
.headline {
  position: absolute;
  bottom: 9%;
  left: 2%;
  right: 2%;
  text-align: center;
  margin: 0;
  font-size: clamp(37px, 4.5vw, 69px);
  line-height: 0.98;
  letter-spacing: -1.3px;
  font-weight: 700;
  color: #080b1b;
  text-shadow: 0 2px #fff5;
  z-index: 2;
}
.headline .line {
  display: block;
  white-space: nowrap;
}
.headline .promise {
  display: inline-flex;
  align-items: baseline;
  justify-content: center;
  gap: 0.12em;
}
.period {
  color: #ad4e7d;
}
.pinky {
  width: 0.58em;
  height: 0.64em;
  align-self: center;
  flex-shrink: 0;
  overflow: visible;
  image-rendering: pixelated;
  margin-left: 0.02em;
  opacity: 0.86;
}
.popup {
  width: 330px;
  z-index: 12;
  left: calc(50% + 280px);
  top: 26%;
  color: #17162c;
  min-width: 230px;
  max-width: calc(100% - 16px);
}
.popup .window-title {
  font-size: 19px;
}
.pop-body {
  padding: 22px 22px 21px;
  background: #edecef;
  box-shadow:
    inset 1px 1px #777,
    inset -1px -1px #fff;
  margin-top: 4px;
  min-height: 126px;
}
.pop-body p {
  font-size: 20px;
  line-height: 1.25;
  margin: 0 0 18px;
}
.pop-body p:last-child {
  margin: 0;
}
.pop-body h2 {
  font-size: 25px;
  line-height: 1.05;
  font-weight: 700;
  margin: 0 0 15px;
}
.pop-body a {
  display: inline-block;
  word-break: break-word;
  font-size: 17px;
  line-height: 1.3;
  text-underline-offset: 3px;
}
.pop-body .retro-button {
  font-size: 18px;
  text-decoration: none;
  padding: 9px 15px;
  background: #cbccd2;
  box-shadow:
    inset 1px 1px #fff,
    inset -2px -2px #656572;
  border: 1px solid #17192a;
}
.task-dock {
  position: absolute;
  bottom: 25px;
  left: 28px;
  z-index: 40;
  display: flex;
  gap: 8px;
  max-width: calc(50% - 105px);
  flex-wrap: wrap;
}
.task-button {
  display: flex;
  align-items: center;
  gap: 8px;
  color: #11152b;
  border: 1px solid #fff;
  background: #c7c8d0;
  box-shadow:
    inset -2px -2px #535867,
    inset 1px 1px white,
    2px 3px #15235466;
  padding: 8px 15px;
  font-size: 17px;
}
.task-button svg {
  width: 20px;
  height: 22px;
}
.main-window.maximized {
  left: 135px !important;
  top: 8px !important;
  width: calc(100% - 150px);
  height: calc(100% - 16px);
  min-height: 0;
  transform: none !important;
}
.main-window.maximized .pineapple {
  height: 67%;
}
.main-window.maximized .headline {
  font-size: clamp(40px, 5.2vw, 84px);
}
.popup.maximized {
  left: 145px !important;
  top: 30px !important;
  width: calc(100% - 170px);
  height: calc(100% - 60px);
  display: flex;
  flex-direction: column;
}
.popup.maximized .pop-body {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: flex-start;
  padding: clamp(24px, 8vw, 100px);
}
.popup.maximized .pop-body p {
  font-size: clamp(24px, 3vw, 40px);
  max-width: 700px;
}
.popup.maximized .pop-body h2 {
  font-size: clamp(30px, 4vw, 60px);
}
.dragging {
  transition: none !important;
  user-select: none;
}
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  clip-path: inset(50%);
  overflow: hidden;
  white-space: nowrap;
}
.sprite-defs {
  position: absolute;
  width: 0;
  height: 0;
  overflow: hidden;
}
@keyframes cloud-drift {
  to {
    transform: translateX(0.6%) translateY(-0.3%);
  }
}
@keyframes inner-drift {
  to {
    transform: scale(1.02) translateX(-0.3%);
  }
}
@keyframes pine-bob {
  0%,
  100% {
    translate: 0 0;
  }
  50% {
    translate: 0 -8px;
  }
}
@media (min-width: 1600px) {
  .main-window {
    width: 940px;
  }
  .headline {
    font-size: 76px;
  }
  .popup {
    left: calc(50% + 320px);
  }
}
@media (max-width: 1000px) and (min-width: 701px) {
  .main-window {
    left: 55%;
    width: 76vw;
  }
  .shortcuts {
    left: 12px;
  }
  .shortcut {
    width: 88px;
    font-size: 15px;
  }
  .shortcut svg {
    width: 42px;
    height: 42px;
  }
  .popup {
    left: auto;
    right: 14px;
    top: 31%;
  }
  .headline {
    font-size: clamp(36px, 4.9vw, 55px);
  }
}
@media (max-width: 700px) {
  .desktop {
    height: 100svh;
    min-height: 740px;
  }
  .stage {
    inset: 130px 10px 102px;
  }
  .shortcuts {
    left: 10px;
    right: 10px;
    top: 16px;
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 3px;
  }
  .shortcut {
    width: 100%;
    font-size: 14px;
    gap: 6px;
    padding: 8px 3px;
  }
  .shortcut svg {
    width: 37px;
    height: 37px;
  }
  .main-window {
    width: 100%;
    height: 100%;
    min-height: 0;
    left: 0;
    top: 0;
    transform: none;
  }
  .main-content {
    min-height: 0;
  }
  .pineapple {
    width: 68%;
    height: 64%;
    top: 2.5%;
  }
  .headline {
    font-size: clamp(28px, 7.5vw, 50px);
    bottom: 10%;
    letter-spacing: -0.7px;
    line-height: 1.06;
  }
  .titlebar {
    height: 29px;
  }
  .window-title {
    font-size: 17px;
  }
  .controls {
    gap: 5px;
  }
  .os-button {
    width: 25px;
    height: 23px;
  }
  .popup {
    top: 22%;
    left: 5% !important;
    right: auto;
    width: 90%;
    max-width: 90%;
  }
  .popup .pop-body {
    padding: 22px 20px;
  }
  .pop-body p {
    font-size: 20px;
  }
  .task-dock {
    bottom: 15px;
    left: 12px;
    max-width: calc(50% - 65px);
  }
  .task-button {
    font-size: 13px;
    padding: 7px 8px;
    gap: 4px;
  }
  .task-button svg {
    width: 16px;
    height: 18px;
  }
  .main-window.maximized {
    left: 0 !important;
    top: -22px !important;
    width: 100%;
    height: calc(100% + 34px);
  }
  .main-window.maximized .headline {
    font-size: clamp(28px, 7.5vw, 50px);
  }
  .popup.maximized {
    left: 0 !important;
    top: 0 !important;
    width: 100%;
    max-width: 100%;
    height: 100%;
  }
  .popup.maximized .pop-body {
    padding: 25px;
  }
  .popup.maximized .pop-body p {
    font-size: 25px;
  }
}
@media (max-height: 720px) and (min-width: 701px) {
  .desktop {
    min-height: 580px;
  }
  .stage {
    bottom: 80px;
    top: 12px;
  }
  .main-window {
    height: 100%;
    min-height: 0;
    width: min(760px, 72vw);
  }
  .headline {
    font-size: clamp(33px, 4vw, 55px);
    bottom: 7%;
  }
  .shortcuts {
    gap: 5px;
    top: 15px;
  }
  .shortcut {
    font-size: 14px;
  }
  .shortcut svg {
    width: 35px;
    height: 35px;
  }
  .popup {
    top: 20%;
  }
}

/* Refined lettering, native pixel icons and the original stacked masthead. */
.top-logo {
  position: absolute;
  z-index: 9;
  left: clamp(26px, 3.7vw, 65px);
  top: 28px;
  display: block;
  width: max-content;
  font-family: 'DM Sans', Arial, sans-serif;
  font-size: 29px;
  font-weight: 800;
  line-height: 0.82;
  letter-spacing: -1.6px;
  color: white;
  text-decoration: none;
  transform: rotate(-3deg);
  text-shadow: 1px 2px #173b7c22;
}
.top-logo span {
  display: block;
}
.shortcuts {
  top: 115px;
}
.main-content {
  container-type: inline-size;
}
.main-window .headline,
.main-window.maximized .headline {
  font-family: 'Jersey 10', monospace;
  font-size: clamp(36px, 7.7vw, 130px);
  font-size: clamp(32px, 14.7cqw, 138px);
  font-weight: 400;
  line-height: 0.82;
  letter-spacing: -0.015em;
  bottom: 8.8%;
}
.main-window .pinky {
  width: 0.27em;
  height: 0.38em;
  opacity: 0.9;
  margin-left: 0.04em;
  translate: 0 0.01em;
}
.pop-body {
  font-family: 'DM Sans', Arial, sans-serif;
}
.pop-body p {
  font-size: 16px;
  line-height: 1.55;
}
.pop-body h2 {
  font-size: 23px;
  line-height: 1.15;
  letter-spacing: -0.6px;
}
.pop-body .retro-button {
  font-size: 13px;
  line-height: 1.4;
}
.pop-body a {
  font-size: 14px;
}
@media (min-width: 701px) {
  .main-window .headline,
  .main-window.maximized .headline {
    font-size: clamp(32px, 13.5cqw, 138px);
  }
  .main-window .pineapple,
  .main-window.maximized .pineapple {
    height: 62%;
  }
}
@media (max-width: 1000px) and (min-width: 701px) {
  .top-logo {
    left: 22px;
    font-size: 26px;
  }
  .shortcuts {
    top: 110px;
  }
}
@media (max-width: 700px) {
  .top-logo {
    left: 22px;
    top: 23px;
    font-size: 25px;
  }
  .shortcuts {
    top: 84px;
  }
  .stage {
    top: 180px;
  }
  .main-window .headline,
  .main-window.maximized .headline {
    letter-spacing: -0.01em;
    line-height: 0.87;
    bottom: 10%;
  }
  .pop-body p {
    font-size: 16px;
  }
  .popup .pop-body {
    padding: 24px 22px;
  }
}
@media (max-height: 720px) and (min-width: 701px) {
  .top-logo {
    top: 20px;
    font-size: 24px;
  }
  .shortcuts {
    top: 87px;
    gap: 3px;
  }
  .shortcut {
    padding-top: 7px;
    padding-bottom: 7px;
  }
  .main-window .headline,
  .main-window.maximized .headline {
    bottom: 7%;
  }
}

/* Spacious desktop dialogs and a hidden, playable pineapple catcher. */
.popup {
  width: min(600px, calc(100% - 36px));
  left: calc(50% + 70px);
  min-width: 260px;
  top: 22%;
}
.popup .pop-body {
  padding: 36px 38px;
  min-height: 255px;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  justify-content: center;
}
.popup .pop-body p {
  font-size: 18px;
  line-height: 1.55;
  max-width: 48ch;
}
.popup .pop-body h2 {
  font-size: 30px;
  line-height: 1.12;
  max-width: 22ch;
  margin-bottom: 20px;
}
.popup .pop-body .retro-button {
  font-size: 15px;
  padding: 11px 18px;
  margin-top: 4px;
}
.secret-arcade {
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  z-index: 1;
  width: min(650px, 65vw);
  text-align: center;
  color: #10162f;
}
.arcade-heading {
  margin: 0 0 20px;
}
.arcade-heading h2 {
  font-family: 'Jersey 10', monospace;
  font-size: clamp(35px, 4.1vw, 58px);
  font-weight: 400;
  line-height: 0.96;
  margin: 12px auto 10px;
  max-width: 570px;
  color: #fff;
  text-shadow: 2px 3px #164489;
}
.arcade-heading > p {
  margin: 0;
  font-family: 'DM Sans', Arial, sans-serif;
  font-size: 14px;
  color: #fff;
  text-shadow: 1px 1px #164489;
}
.arcade-board {
  position: relative;
  border: 3px solid #172447;
  box-shadow:
    3px 3px #fff9,
    9px 10px #17244740;
  background: #c7e2ffb8;
  overflow: hidden;
  isolation: isolate;
}
.arcade-board:before {
  content: '';
  position: absolute;
  inset: 0;
  z-index: -1;
  background: linear-gradient(#96c8ff55, #fff9);
}
.arcade-hud {
  display: flex;
  justify-content: space-between;
  gap: 15px;
  padding: 14px 19px 10px;
  font-family: 'Pixelify Sans', monospace;
  font-size: 17px;
  background: #f2f4ffdf;
  border-bottom: 2px solid #17244755;
}
.arcade-hud b {
  font-weight: 700;
  margin-left: 8px;
}
.game-overlay {
  position: absolute;
  inset: 43px 0 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 12px;
  background: #dfefffdc;
  padding: 20px;
}
.game-overlay p {
  font-family: 'Jersey 10', monospace;
  font-size: 46px;
  line-height: 0.95;
  margin: 0;
  max-width: 95%;
}
.game-start {
  font-family: 'Pixelify Sans', monospace;
  font-size: 20px;
  background: #f8d45c;
  border: 2px solid #1a2442;
  box-shadow: 4px 4px #182344;
  padding: 11px 23px;
  line-height: 1.2;
}
.game-start:hover {
  background: #ffe999;
  translate: -1px -1px;
}
.game-start:active {
  translate: 2px 2px;
  box-shadow: 2px 2px #182344;
}
.game-help {
  font-family: 'DM Sans', Arial, sans-serif;
  color: white;
  font-size: 12px;
  text-shadow: 1px 1px #174485;
  margin: 15px 0 0;
}
[data-period='night'] .arcade-heading h2,
[data-period='night'] .arcade-heading > p,
[data-period='night'] .game-help {
  text-shadow: 2px 2px #070e2c;
}
[data-period='night'] .arcade-board {
  background: #a7a9dbbb;
}
[data-period='night'] .game-overlay {
  background: #d8d9efeb;
}
@media (max-width: 1000px) and (min-width: 701px) {
  .popup {
    width: min(560px, calc(100% - 100px));
    left: auto;
    right: 20px;
  }
  .secret-arcade {
    left: 55%;
    width: 70vw;
  }
}
@media (max-width: 700px) {
  .popup {
    width: 96%;
    max-width: 96%;
    left: 2% !important;
    top: 8%;
  }
  .popup .pop-body {
    padding: 28px 24px;
    min-height: 270px;
    max-height: calc(100svh - 290px);
    overflow-y: auto;
    justify-content: flex-start;
  }
  .popup .pop-body h2 {
    font-size: 25px;
  }
  .popup .pop-body p {
    font-size: 16px;
  }
  .popup .pop-body .retro-button {
    font-size: 14px;
  }
  .secret-arcade {
    width: 94%;
    top: 50%;
  }
  .arcade-heading {
    margin-bottom: 16px;
  }
  .arcade-heading h2 {
    font-size: 39px;
    line-height: 0.95;
    margin-top: 12px;
  }
  .arcade-heading > p {
    font-size: 12px;
  }
  .arcade-hud {
    font-size: 14px;
    padding: 12px;
  }
  .arcade-hud b {
    margin-left: 4px;
  }
  .game-overlay {
    inset: 40px 0 0;
    padding: 12px;
  }
  .game-overlay p {
    font-size: 31px;
  }
  .game-start {
    font-size: 17px;
    padding: 9px 18px;
  }
  .game-help {
    font-size: 10px;
  }
  .popup.maximized .pop-body {
    max-height: none;
  }
}
@media (max-height: 720px) and (min-width: 701px) {
  .secret-arcade {
    width: min(540px, 61vw);
  }
  .arcade-heading h2 {
    font-size: 40px;
  }
  .arcade-heading {
    margin-bottom: 12px;
  }
  .arcade-hud {
    padding-top: 10px;
    padding-bottom: 8px;
  }
  .game-help {
    margin-top: 11px;
  }
  .popup .pop-body {
    min-height: 210px;
    padding: 25px 30px;
  }
}

/* The personal avatar uses transparent pixels. */
.popup.about-window{width:min(700px,calc(100% - 36px))}.about-layout{display:grid;grid-template-columns:180px minmax(0,1fr);align-items:center;gap:28px;width:100%}.about-portrait{width:100%;height:250px;object-fit:contain;object-position:center bottom;image-rendering:pixelated}.about-copy{min-width:0}.popup.about-window .pop-body h2{font-size:32px;letter-spacing:-1px}.popup.about-window.maximized .about-layout{max-width:920px;grid-template-columns:minmax(200px,1fr) minmax(0,1.4fr);gap:50px}.popup.about-window.maximized .about-portrait{height:min(470px,50vh)}
.popup.about-window.maximized{width:calc(100% - 170px)}
@media(max-width:700px){.popup.about-window{width:96%;max-width:96%;top:0}.about-layout{grid-template-columns:1fr;gap:18px;text-align:left}.about-portrait{height:170px;width:160px;justify-self:center}.popup.about-window .pop-body h2{font-size:28px}.popup.about-window .pop-body{max-height:calc(100svh - 255px);padding:23px}.popup.about-window.maximized .about-layout{grid-template-columns:1fr;gap:20px}.popup.about-window.maximized .about-portrait{height:190px}.popup.about-window.maximized .pop-body{max-height:none}.game-help{font-size:11px}}
@media(max-height:720px) and (min-width:701px){.about-portrait{height:210px}.popup.about-window .pop-body{padding:25px 28px}}


@media(max-width:700px){.popup{max-height:calc(100% - 8px);display:flex;flex-direction:column}.popup .pop-body{min-height:0;flex:1 1 auto;max-height:none;overflow-y:auto;justify-content:flex-start}.popup.about-window .pop-body{max-height:none}}

/* An endless pixel space shooter with its own close/reopen lifecycle. */
.arcade-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  background: linear-gradient(90deg, #0c087d, #1736b5);
  color: white;
  padding: 4px 5px 4px 11px;
  font-family: 'Pixelify Sans', monospace;
  font-size: 18px;
  min-height: 32px;
}
.arcade-toolbar .os-button {
  flex-shrink: 0;
}
.arcade-toolbar .os-button svg {
  height: 13px;
  width: 13px;
}
#shooter-game {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 640/360;
  touch-action: none;
  cursor: var(--hand-cursor);
  background: #080d2a;
}
#shooter-game:focus-visible {
  outline: 3px dashed #f1cd56;
  outline-offset: -6px;
}
.arcade-hud {
  font-size: 16px;
  padding: 10px 15px;
  gap: 10px;
}
.arcade-hud b {
  margin-left: 5px;
}
.game-overlay {
  inset: 73px 0 0;
  background: #0c173be8;
  color: #f6f1df;
  gap: 14px;
}
.game-overlay h3 {
  font-family: 'Jersey 10', monospace;
  font-size: 62px;
  line-height: 0.85;
  font-weight: 400;
  margin: 0;
}
.game-overlay #game-summary {
  font-family: 'DM Sans', Arial, sans-serif;
  font-size: 14px;
  line-height: 1.4;
  margin: 0;
}
.game-overlay .game-start {
  color: #10162f;
  font-size: 19px;
  margin-top: 4px;
}
.game-overlay.is-over .game-start:not(.game-talk) {
  order: 4;
  background: none;
  color: #d5def7;
  font-size: 15px;
  padding: 7px 12px;
  border: 0;
  box-shadow: none;
  text-decoration: underline;
  text-underline-offset: 4px;
}
.game-talk {
  background: #f8d45c;
  color: #10162f;
}
.game-bottom {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 22px;
  margin: 13px 0 0;
}
.game-help {
  margin: 0;
  line-height: 1.6;
  font-size: 12px;
}
.game-help span {
  font-size: 11px;
  opacity: 0.9;
}
.arcade-reopen {
  position: absolute;
  right: 28px;
  bottom: 24px;
  z-index: 8;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 5px;
  background: none;
  color: #fff;
  font:
    17px 'Pixelify Sans',
    monospace;
  border: 1px solid transparent;
  padding: 9px;
  text-shadow: 1px 2px #164489;
}
.arcade-reopen:hover {
  background: #a8bdff35;
  border-color: #d3dfff66;
}
.arcade-reopen svg {
  height: 39px;
  width: 39px;
  filter: drop-shadow(2px 3px #00174955);
}
@media (max-width: 700px) {
  .arcade-heading h2 {
    font-size: 43px;
  }
  .arcade-heading > p {
    font-size: 11px;
  }
  .arcade-toolbar {
    font-size: 15px;
    min-height: 30px;
  }
  .arcade-hud {
    font-size: 12px;
    padding: 10px 8px;
    gap: 6px;
  }
  .arcade-hud b {
    margin-left: 3px;
  }
  .game-overlay {
    inset: 62px 0 0;
    gap: 10px;
    padding: 12px;
  }
  .game-overlay h3 {
    font-size: 43px;
  }
  .game-overlay #game-summary {
    font-size: 11px;
  }
  .game-overlay .game-start {
    font-size: 15px;
    padding: 8px 14px;
    margin-top: 0;
  }
  .game-overlay.is-over .game-start:not(.game-talk) {
    font-size: 12px;
    padding: 3px 8px;
  }
  .game-bottom {
    gap: 12px;
    margin-top: 12px;
  }
  .game-help {
    font-size: 10px;
  }
  .game-help span {
    font-size: 10px;
  }
  .arcade-reopen {
    right: 9px;
    bottom: 12px;
    font-size: 13px;
    padding: 7px;
  }
  .arcade-reopen svg {
    width: 29px;
    height: 29px;
  }
  .about-portrait {
    image-rendering: pixelated;
  }
}
@media (max-height: 720px) and (min-width: 701px) {
  .secret-arcade {
    width: min(520px, 59vw);
  }
  .arcade-heading h2 {
    font-size: 37px;
  }
  .arcade-heading {
    margin-bottom: 10px;
  }
  .arcade-heading > p {
    font-size: 12px;
  }
  .game-overlay h3 {
    font-size: 50px;
  }
  .game-bottom {
    margin-top: 10px;
  }
  .game-help {
    font-size: 10px;
  }
}

@media (max-width: 360px) {
  .game-overlay {
    gap: 7px;
    padding: 8px;
  }
  .game-overlay h3 {
    font-size: 37px;
  }
  .game-overlay #game-summary {
    font-size: 10px;
  }
  .game-overlay .game-start {
    font-size: 13px;
    padding: 7px 11px;
  }
  .game-overlay.is-over .game-start:not(.game-talk) {
    font-size: 11px;
    padding: 3px 8px;
  }
}

/* Quiet inset focus for window chrome. */
.os-button:focus-visible {
  outline: 1px dotted #17213a;
  outline-offset: -5px;
}

/* Phones use touch-sized controls and fixed, full-width dialogs. */
@media (max-width: 700px), (max-width: 1000px) and (hover: none) and (pointer: coarse) {
  .desktop {
    min-height: 740px;
  }
  .top-logo {
    left: 22px;
    top: 23px;
    font-size: 25px;
  }
  .shortcuts {
    left: 10px;
    right: 10px;
    top: 84px;
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 3px;
  }
  .shortcut {
    width: 100%;
    min-height: 80px;
    font-size: 14px;
    gap: 6px;
    padding: 8px 3px;
  }
  .shortcut svg {
    width: 37px;
    height: 37px;
  }
  .stage {
    inset: 180px 10px 26px;
  }
  .desktop:has(.task-button) .stage {
    bottom: 112px;
  }
  .main-window {
    width: 100%;
    height: 100%;
    min-height: 0;
    left: 0;
    top: 0;
    transform: none;
  }
  .titlebar {
    height: 52px;
    min-height: 52px;
    padding: 4px 5px 4px 8px;
    cursor: default;
    touch-action: pan-y;
  }
  .window-title,
  .popup .window-title {
    font-size: 17px;
  }
  .controls {
    gap: 5px;
  }
  .os-button {
    width: 44px;
    height: 44px;
    min-width: 44px;
    min-height: 44px;
  }
  .os-button svg {
    width: 14px;
    height: 14px;
  }
  .controls [data-action='maximize'] {
    display: none;
  }
  .popup,
  .popup.about-window,
  .popup.maximized {
    left: 0 !important;
    top: 0 !important;
    right: auto;
    width: 100%;
    max-width: 100%;
    height: auto;
    max-height: 100%;
    min-height: 0;
    transform: none;
    display: flex;
    flex-direction: column;
  }
  .popup .pop-body,
  .popup.about-window .pop-body {
    min-height: 0;
    flex: 1 1 auto;
    max-height: none;
    overflow-y: auto;
    overscroll-behavior: contain;
    -webkit-overflow-scrolling: touch;
    padding: 26px 22px;
    justify-content: flex-start;
  }
  .popup .pop-body h2 {
    font-size: 26px;
  }
  .popup .pop-body p {
    font-size: 16px;
  }
  .popup .pop-body .retro-button {
    min-height: 44px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    padding: 11px 16px;
  }
  .about-layout {
    grid-template-columns: 1fr;
    gap: 18px;
  }
  .about-portrait {
    height: 165px;
    width: 160px;
    justify-self: center;
  }
  .popup.about-window .pop-body h2 {
    font-size: 28px;
  }
  .task-dock {
    left: 10px;
    bottom: 12px;
    max-width: calc(100% - 108px);
    max-height: 96px;
    overflow-y: auto;
    gap: 6px;
  }
  .task-button {
    min-height: 44px;
    padding: 8px 11px;
    font-size: 14px;
    flex-shrink: 0;
  }
  .task-button svg {
    width: 18px;
    height: 20px;
  }
  .arcade-reopen {
    min-width: 80px;
    min-height: 72px;
    right: 8px;
    bottom: 9px;
  }
  .secret-arcade {
    width: 94%;
    left: 50%;
  }
  .arcade-toolbar {
    height: 52px;
    min-height: 52px;
    padding: 4px 5px 4px 10px;
    font-size: 15px;
  }
  .arcade-toolbar .os-button {
    width: 44px;
    height: 44px;
  }
  .arcade-hud {
    height: 36px;
    padding: 9px 8px;
    font-size: 12px;
    gap: 6px;
  }
  .arcade-hud b {
    margin-left: 3px;
  }
  .game-overlay {
    inset: 88px 0 0;
  }
  .game-start {
    min-height: 44px;
  }
  .game-overlay.is-over .game-start:not(.game-talk) {
    min-height: 32px;
  }
  .game-help {
    font-size: 10px;
    line-height: 1.6;
  }
  .game-help span {
    font-size: 10px;
  }
  .game-bottom {
    gap: 12px;
    margin-top: 12px;
  }
}
@media (max-width: 360px) {
  .game-overlay {
    gap: 5px;
    padding: 7px;
  }
  .game-overlay h3 {
    font-size: 34px;
  }
  .game-overlay #game-summary {
    font-size: 10px;
  }
  .game-overlay .game-start {
    font-size: 13px;
    padding: 8px 12px;
  }
  .game-overlay.is-over .game-start:not(.game-talk) {
    min-height: 28px;
    font-size: 11px;
    padding: 3px 8px;
  }
}
@media (hover: none) and (pointer: coarse) {
  button:not(:disabled),
  a[href],
  .titlebar,
  #shooter-game {
    cursor: auto;
  }
}

/* Selected logo study: Barlow Condensed, plain white stacked lettering. */
.outer-skies {
  background: #0864ed;
}
.outer-skies .sky {
  mask-image: linear-gradient(to bottom, transparent 0 78px, #000 145px);
}
[data-period='night'] .outer-skies {
  background: #101339;
}
.top-logo,
[data-period='night'] .top-logo {
  font-family: 'Barlow Condensed', Arial, sans-serif;
  font-weight: 700;
  font-style: normal;
  font-size: 36px;
  line-height: 0.86;
  letter-spacing: -0.35px;
  color: #fff;
  transform: rotate(-3deg);
  text-shadow: none;
  -webkit-text-stroke: 0;
  paint-order: normal;
}
@media (max-width: 700px), (max-width: 1000px) and (hover: none) and (pointer: coarse) {
  .top-logo,
  [data-period='night'] .top-logo {
    font-size: 32px;
  }
}

/* Small DM Sans arcade text: outline only, a drop would fill the letter counters.
   The night rules for these selectors are more specific and still win. */
.arcade-heading > p,
.game-help {
  text-shadow:
    1px 0 #0b2a66,
    -1px 0 #0b2a66,
    0 1px #0b2a66,
    0 -1px #0b2a66;
}

/* Popup buttons sit in one row and wrap on narrow screens. */
.pop-body .pop-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
}

/* Fits "Address copied" (150px at 15px, 137px at 14px) so the row stays put when it swaps. */
.pop-body .copy-email {
  min-width: 10em;
}

@media (prefers-reduced-motion: reduce) {
  *,
  *:before,
  *:after {
    animation: none !important;
    transition: none !important;
    scroll-behavior: auto !important;
  }
}

/* The night overlay used to be light with the same cream text, which made it unreadable; it
   stays dark like the day overlay. */
[data-period='night'] .game-overlay {
  background: #0c173bea;
}

/* Invaders.app high scores, shown on the game-over screen. Desktop: the game-over texts and
   buttons on the left, the board on the right. Phones: one column that scrolls inside the
   overlay, with Now let's talk first. */
.game-overlay.is-over {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  column-gap: 24px;
  row-gap: 12px;
  align-content: center;
  justify-items: center;
}
.game-overlay.is-over > :not(.hiscores) {
  grid-column: 1;
}
.hiscores {
  grid-column: 2;
  grid-row: 1 / span 4;
  align-self: center;
  width: 100%;
  max-width: 280px;
  font-family: 'Pixelify Sans', monospace;
  text-align: left;
  container-type: inline-size;
}
.hiscores h4 {
  margin: 0 0 8px;
  font-family: 'Jersey 10', monospace;
  font-weight: 400;
  font-size: 32px;
  line-height: 0.9;
  text-align: center;
}
.hiscore-form {
  display: grid;
  grid-template-columns: auto auto;
  justify-content: start;
  align-items: center;
  gap: 5px 8px;
  margin: 0 0 10px;
}
.hiscore-form[hidden] {
  display: none;
}
.hiscore-form label {
  grid-column: 1 / -1;
  font-family: 'DM Sans', Arial, sans-serif;
  font-size: 12px;
  font-weight: 700;
}
.hiscore-form input {
  width: 4.6em;
  font-family: 'Pixelify Sans', monospace;
  font-size: 20px;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  padding: 4px 6px 4px 10px;
  color: #10162f;
  background: #f6f1df;
  border: 2px solid #1a2442;
  border-radius: 0;
}
.hiscore-form input:focus-visible {
  outline: 2px solid #f8d45c;
  outline-offset: 2px;
}
.hiscore-save {
  font-family: 'Pixelify Sans', monospace;
  font-size: 16px;
  line-height: 1.2;
  padding: 6px 14px;
  color: #10162f;
  background: #f8d45c;
  border: 2px solid #1a2442;
  box-shadow: 3px 3px #000a;
}
.hiscore-save:hover:not(:disabled) {
  background: #ffe999;
}
.hiscore-save:active:not(:disabled) {
  translate: 2px 2px;
  box-shadow: 1px 1px #000a;
}
.hiscore-save:disabled {
  opacity: 0.6;
}
.hiscore-save:focus-visible {
  outline: 2px solid #f8d45c;
  outline-offset: 3px;
}
.game-overlay .hiscore-status {
  font-family: 'DM Sans', Arial, sans-serif;
  font-size: 12px;
  line-height: 1.4;
  max-width: none;
}
.hiscore-status:focus-visible {
  outline: 2px solid #f8d45c;
  outline-offset: 2px;
}
.hiscore-status:empty {
  display: none;
}
.hiscore-status {
  margin: 0 0 6px;
}
.hiscore-jump {
  display: none;
}
.hiscores h4:focus-visible {
  outline: 2px solid #f8d45c;
  outline-offset: 2px;
}
.hiscore-list {
  list-style: none;
  margin: 0;
  padding: 0;
  columns: 2;
  column-gap: 14px;
  font-size: 14px;
  line-height: 1.3;
}
.hiscore-list li {
  display: grid;
  grid-template-columns: 2.1em 1fr auto;
  gap: 4px;
  padding: 1px 4px;
  break-inside: avoid;
}
.hiscore-list .hs-score {
  text-align: right;
}
/* Narrow boards (small desktop windows, 320px phones) keep two columns with smaller type. */
@container (max-width: 250px) {
  .hiscore-list {
    font-size: 12px;
    column-gap: 6px;
  }
  .hiscore-list li {
    grid-template-columns: 1.9em 1fr auto;
    gap: 2px;
    padding: 1px 2px;
  }
}
.hiscore-list .is-me {
  background: #f8d45c;
  color: #10162f;
}
@media (max-width: 700px), (max-width: 1000px) and (hover: none) and (pointer: coarse) {
  .game-overlay.is-over {
    display: flex;
    overflow-y: auto;
    justify-content: flex-start;
  }
  /* Centred while it fits, scrollable from the top once it doesn't. */
  .game-overlay.is-over > h3 {
    margin-top: auto;
  }
  .hiscores {
    order: 5;
    margin: 8px 0 auto;
    max-width: 300px;
  }
  .hiscore-form input {
    font-size: 18px;
    min-height: 44px;
  }
  .hiscore-save {
    min-height: 44px;
  }
  /* The board starts below the game-over buttons; this link in the bottom corner scrolls to it. */
  .game-overlay.is-over .hiscore-jump:not([hidden]) {
    display: block;
    position: absolute;
    bottom: 2px;
    right: 4px;
    min-height: 32px;
    padding: 4px 6px;
    border: 0;
    background: none;
    color: #f8d45c;
    font-family: 'Pixelify Sans', monospace;
    font-size: 12px;
    text-decoration: underline;
    text-underline-offset: 3px;
  }
  .hiscore-jump:focus-visible {
    outline: 2px solid #f8d45c;
  }
}
