/* ============================================================
   CLOSE QUARTERS: Win98-desktop theme (on top of 98.css)
   ============================================================ */
:root {
  --navy: #000080;
  --teal: #008080;
  --silver: #c0c0c0;
  --taskbar-h: 30px;
  --wallpaper: none;
}
* { box-sizing: border-box; }
html, body { height: 100%; margin: 0; }
body {
  font-family: "Pixelated MS Sans Serif", Tahoma, Arial, sans-serif;
  font-size: 11px;
  background: var(--teal);
  overflow: hidden;
  -webkit-font-smoothing: none;
}
img { display: block; max-width: 100%; }
[hidden] { display: none !important; }
:focus-visible { outline: 1px dotted #000; outline-offset: -4px; }

/* ---------- desktop + wallpaper ---------- */
.desktop {
  position: fixed; inset: 0 0 var(--taskbar-h) 0;
  background: var(--teal) var(--wallpaper) center / cover no-repeat;
  overflow: hidden;
}
.desktop::after { /* faint CRT scanlines */
  content: ""; position: absolute; inset: 0; pointer-events: none; z-index: 9000;
  background: repeating-linear-gradient(0deg, rgba(0,0,0,.07) 0 1px, transparent 1px 3px);
  mix-blend-mode: multiply;
}

/* ---------- icons ---------- */
.icons {
  list-style: none; margin: 0; padding: 10px 6px;
  display: grid; grid-auto-flow: column; grid-template-rows: repeat(auto-fill, 78px);
  gap: 4px 6px; height: 100%; width: max-content; position: relative; z-index: 1;
}
.dicon {
  all: unset; box-sizing: border-box; cursor: default;
  width: 76px; display: flex; flex-direction: column; align-items: center; gap: 4px;
  padding: 4px 2px; text-align: center; color: #fff; text-decoration: none;
}
.dicon svg { width: 32px; height: 32px; image-rendering: pixelated; filter: drop-shadow(1px 1px 0 rgba(0,0,0,.35)); }
.dicon span {
  font-size: 11px; line-height: 13px; padding: 0 2px;
  text-shadow: 1px 1px 0 #000, 0 0 2px #000;
}
.dicon:focus span, .dicon.is-selected span { background: var(--navy); outline: 1px dotted #ff0; text-shadow: none; }
.dicon:focus svg, .dicon.is-selected svg { filter: drop-shadow(1px 1px 0 rgba(0,0,0,.35)) sepia(1) hue-rotate(190deg) saturate(4) brightness(.8); }

/* ---------- windows ---------- */
.win { position: absolute; display: flex; flex-direction: column; min-width: 200px; max-width: calc(100vw - 8px); box-shadow: inset -1px -1px #0a0a0a, inset 1px 1px #dfdfdf, inset -2px -2px grey, inset 2px 2px #fff, 4px 4px 0 rgba(0,0,0,.35); }
.win:not(.is-open) { display: none; }
.win .title-bar { cursor: default; user-select: none; touch-action: none; }
.win:not(.is-active) .title-bar { background: linear-gradient(90deg, #808080, #b5b5b5); }
.win:not(.is-active) .title-bar-text { color: #d4d0c8; }
.title-bar-text { display: flex; align-items: center; gap: 4px; }
.ti { width: 16px; height: 16px; flex: none; }
.window-body { margin: 6px; }
.win > .window-body { flex: 1; min-height: 0; overflow: auto; }
.status-grow { flex: 1; }
.menubar { display: flex; gap: 2px; padding: 2px 4px 0; user-select: none; }
.menubar span { padding: 1px 6px; }
.menubar span:hover { background: var(--navy); color: #fff; }
.sunken {
  box-shadow: inset -1px -1px #fff, inset 1px 1px grey, inset -2px -2px #dfdfdf, inset 2px 2px #0a0a0a;
  background: #fff;
}
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; }

/* sizes */
.win--player { width: 440px; }
.win--cd { width: 560px; }
.win--readme { width: 420px; height: 330px; }
.win--buddy { width: 232px; }
.win--im { width: 380px; }
.win--mail { width: 330px; }
.win--photo { width: 520px; }
.win--dialog { width: 340px; }
.win--profile { width: 300px; }

/* ---------- media player ---------- */
.screen {
  position: relative; height: 240px; overflow: hidden;
  background: #000; border: 2px inset #808080;
  display: grid; place-items: end center; padding-bottom: 30px;
}
.screen__art {
  position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover;
  object-position: 50% 4%;
  opacity: .78; filter: saturate(1.25) contrast(1.1);
}
.screen__fx {
  position: absolute; inset: 0; pointer-events: none;
  background:
    repeating-linear-gradient(0deg, rgba(0,0,0,.45) 0 2px, transparent 2px 4px),
    linear-gradient(180deg, transparent 45%, rgba(0,0,0,.7) 100%),
    radial-gradient(ellipse at center, transparent 60%, rgba(0,0,0,.6));
}
.glitch {
  position: relative; z-index: 2;
  font-family: Impact, "Arial Black", "Helvetica Neue", sans-serif;
  font-size: 52px; letter-spacing: -1px; line-height: 1; color: #f2e33a;
  text-shadow: 3px 3px 0 #000;
  transform: scaleY(1.15);
}
.glitch::before, .glitch::after {
  content: attr(data-text); position: absolute; inset: 0; pointer-events: none;
}
.glitch::before { color: #ff00c8; transform: translate(-3px, 0); mix-blend-mode: screen; clip-path: inset(0 0 60% 0); animation: gl1 2.8s steps(1) infinite; }
.glitch::after  { color: #00f0ff; transform: translate(3px, 0);  mix-blend-mode: screen; clip-path: inset(55% 0 0 0); animation: gl2 3.4s steps(1) infinite; }
@keyframes gl1 { 0%,86%,100% { clip-path: inset(0 0 100% 0); } 88% { clip-path: inset(10% 0 55% 0); transform: translate(-6px,0); } 92% { clip-path: inset(40% 0 30% 0); transform: translate(5px,0); } }
@keyframes gl2 { 0%,80%,100% { clip-path: inset(100% 0 0 0); } 83% { clip-path: inset(60% 0 10% 0); transform: translate(6px,0); } 90% { clip-path: inset(20% 0 65% 0); transform: translate(-4px,0); } }
.screen__sub {
  position: absolute; left: 0; right: 0; bottom: 8px; z-index: 2; text-align: center;
  font-family: "Courier New", monospace; font-size: 12px; letter-spacing: 3px; color: #9fff9f;
  text-shadow: 0 0 4px #3f3;
}
.screen.is-playing .screen__art { animation: drift 18s ease-in-out infinite alternate; transform-origin: 50% 10%; }
@keyframes drift { to { transform: scale(1.06); } }

.transport { display: flex; align-items: center; gap: 4px; margin: 6px 0; }
.transport button { min-width: 30px; padding: 0 6px; font-size: 12px; }
.seek { flex: 1; height: 16px; position: relative; cursor: pointer; background: #fff; }
.seek i { position: absolute; left: 2px; top: 2px; bottom: 2px; width: 0; max-width: calc(100% - 4px);
  background: repeating-linear-gradient(90deg, var(--navy) 0 8px, transparent 8px 10px); }

.tabs { margin-top: 4px; }
.tabpanel { margin-top: -2px; }
.tabpanel .window-body { margin: 6px; }
.embed-holder { background: #000; min-height: 80px; }
.embed-holder iframe { display: block; border: 0; }
.vol-label { margin-left: auto; }
#sdk-vol { width: 90px; }

/* ---------- CD burner ---------- */
.cd-grid { display: grid; grid-template-columns: 150px 1fr; gap: 8px; }
.cd-art { padding: 3px; align-self: start; }
.cd-art img { width: 100%; aspect-ratio: 1; object-fit: cover; background: #000; }
.cd-main { min-width: 0; display: flex; flex-direction: column; gap: 6px; }
.cd-meta { margin: 0; color: #444; }
.cd-table { height: 220px; overflow: auto; }
.cd-table table { width: 100%; }
.cd-table td:first-child, .cd-table th:first-child { width: 26px; text-align: right; }
.cd-table td:last-child { width: 44px; text-align: right; }
.cd-table td { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 0; }
.cd-table td:nth-child(2) { width: 50%; }
.cd-table tr.is-playing td { font-weight: bold; }
.cd-table tr.is-playing td:first-child::before { content: "♪ "; }
.cd-actions { flex-wrap: wrap; gap: 4px; }
.cd-links { display: inline-flex; flex-wrap: wrap; gap: 4px; }
.cd-links a { color: #000; }

/* ---------- notepad ---------- */
.win--readme .window-body { margin: 0 2px 2px; display: flex; }
.notepad {
  flex: 1; width: 100%; resize: none; padding: 6px 8px;
  font-family: "Pixelated MS Sans Serif", Tahoma, sans-serif; font-size: 13px; line-height: 1.45;
  border: 0; box-shadow: inset -1px -1px #fff, inset 1px 1px grey, inset -2px -2px #dfdfdf, inset 2px 2px #0a0a0a;
}

/* ---------- buddy list ---------- */
.buddy-banner { display: flex; gap: 6px; align-items: center; padding: 6px; margin-bottom: 6px; background: linear-gradient(90deg, #000080, #1084d0); color: #fff; }
.buddy-banner svg { width: 28px; height: 28px; }
.buddy-tree { height: 200px; overflow: auto; }
.buddy-tree details summary { font-weight: bold; }
.buddy-tree .bud { display: flex; align-items: center; gap: 4px; cursor: default; padding: 1px 2px; }
.buddy-tree .bud:hover, .buddy-tree .bud:focus { background: var(--navy); color: #fff; outline: none; }
.buddy-tree .dot { width: 8px; height: 8px; background: #2c2; border: 1px solid #000; flex: none; }
.buddy-tree .away { color: #808080; font-style: italic; }
.buddy-actions { margin-top: 6px; justify-content: space-between; }

/* ---------- profile ---------- */
.profile-photo { padding: 3px; }
.profile-photo img { width: 100%; aspect-ratio: 1; object-fit: cover; }
.profile-away { margin: 6px 0 0; padding: 6px; background: #ffffe1; border: 1px solid #000; }

/* ---------- IM ---------- */
.im-log { height: 180px; overflow: auto; padding: 6px; font-family: Arial, sans-serif; font-size: 12px; line-height: 1.4; }
.im-log p { margin: 0 0 4px; word-wrap: break-word; }
.im-log .sn { font-weight: bold; }
.im-log .sn--band { color: #00f; }
.im-log .sn--you { color: #f00; }
.im-log .sn--fan { color: #c00; }
.im-log .meta { color: #808080; font-size: 11px; }
.im-log .sys { color: #808080; font-style: italic; }
.im-form { display: flex; flex-direction: column; gap: 6px; margin-top: 6px; }
.im-form .field-row input { min-width: 0; flex: 1; }
.im-form textarea { width: 100%; resize: vertical; font-family: Arial, sans-serif; font-size: 12px; }
.im-send { justify-content: space-between; }
.im-status { margin: 0; color: #444; }

/* ---------- dialogs ---------- */
.dialog-row { display: flex; gap: 12px; align-items: flex-start; margin: 6px 4px 12px; }
.dialog-row p { margin: 4px 0 0; line-height: 1.4; }
.dialog-icon { width: 32px; height: 32px; flex: none; }
.dialog-buttons { display: flex; justify-content: center; gap: 8px; margin: 8px 0 2px; }
.dialog-buttons button { min-width: 75px; }
.field-row-stacked input { width: 100%; }

/* ---------- photo ---------- */
.photo-frame { padding: 3px; }
.photo-frame img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; background: #000; }

/* ---------- taskbar ---------- */
.taskbar {
  position: fixed; left: 0; right: 0; bottom: 0; height: var(--taskbar-h); z-index: 10000;
  display: flex; align-items: center; gap: 4px; padding: 2px 3px;
  background: var(--silver); box-shadow: inset 0 1px #dfdfdf, inset 0 2px #fff;
}
.start { display: inline-flex; align-items: center; gap: 4px; min-width: 0; padding: 0 6px; height: 24px; }
.start svg { width: 16px; height: 16px; }
.start.is-on { box-shadow: inset -1px -1px #fff, inset 1px 1px #0a0a0a, inset -2px -2px #dfdfdf, inset 2px 2px grey; }
.tasks { flex: 1; display: flex; gap: 3px; min-width: 0; overflow: hidden; }
.task {
  display: inline-flex; align-items: center; gap: 4px; justify-content: flex-start;
  min-width: 0; width: 150px; flex: 0 1 150px; height: 24px; padding: 0 6px; text-align: left;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.task svg { width: 16px; height: 16px; flex: none; }
.task span { overflow: hidden; text-overflow: ellipsis; }
.task.is-active {
  font-weight: bold;
  background: repeating-conic-gradient(#fff 0 25%, var(--silver) 0 50%) 0 0 / 2px 2px;
  box-shadow: inset -1px -1px #fff, inset 1px 1px #0a0a0a, inset -2px -2px #dfdfdf, inset 2px 2px grey;
}
.tray { display: flex; align-items: center; gap: 6px; height: 24px; padding: 0 8px; background: var(--silver); }
.tray__eq { display: inline-flex; gap: 1px; align-items: flex-end; height: 12px; }
.tray__eq i { width: 3px; height: 3px; background: #008000; }
.tray__eq.is-on i { animation: eq .6s ease-in-out infinite alternate; }
.tray__eq.is-on i:nth-child(2) { animation-delay: .2s; }
.tray__eq.is-on i:nth-child(3) { animation-delay: .4s; }
@keyframes eq { to { height: 12px; } }

/* ---------- start menu ---------- */
.startmenu { position: fixed; left: 2px; bottom: calc(var(--taskbar-h) - 2px); z-index: 10001; display: flex; padding: 3px; }
.startmenu__side {
  width: 24px; background: linear-gradient(0deg, #000080, #1084d0);
  display: flex; align-items: flex-end; justify-content: center; padding-bottom: 6px;
}
.startmenu__side span { writing-mode: vertical-rl; transform: rotate(180deg); color: #c0c0c0; font-size: 18px; font-family: "Arial Black", Arial, sans-serif; letter-spacing: 1px; }
.startmenu__side b { color: #fff; }
.startmenu__items { list-style: none; margin: 0; padding: 0; min-width: 190px; }
.startmenu__items button, .startmenu__items a {
  all: unset; box-sizing: border-box; display: flex; align-items: center; gap: 8px; width: 100%;
  padding: 4px 18px 4px 6px; cursor: default; color: #000; font-size: 11px;
}
.startmenu__items svg { width: 24px; height: 24px; flex: none; }
.startmenu__items button:hover, .startmenu__items a:hover,
.startmenu__items button:focus-visible, .startmenu__items a:focus-visible { background: var(--navy); color: #fff; }
.startmenu__items .sep { height: 2px; margin: 3px 2px; border-top: 1px solid grey; border-bottom: 1px solid #fff; }

/* ---------- shutdown ---------- */
.shutdown {
  position: fixed; inset: 0; z-index: 20000; background: #000; color: #ff8c00;
  display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center;
  font-family: Arial, sans-serif; cursor: pointer;
}
.shutdown p { font-size: clamp(22px, 4vw, 40px); margin: 0 0 20px; line-height: 1.3; }
.shutdown small { color: #555; font-size: 12px; }

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

/* ============================================================
   EXTRAS: Surfari, Hallway, cmd, display, snake, menus, eggs
   ============================================================ */
.win--web { width: 640px; height: 520px; }
.win--board { width: 470px; height: 540px; }
.win--cmd { width: 560px; height: 340px; }
.win--run { width: 360px; }
.win--display { width: 400px; }
.win--snake { width: 270px; }

/* Surfari */
.web-toolbar { display: flex; gap: 3px; align-items: center; padding: 3px 4px; border-bottom: 1px solid grey; box-shadow: 0 1px #fff; }
.web-toolbar button { min-width: 0; padding: 0 8px; }
.web-logo { margin-left: auto; width: 34px; height: 26px; background: #000; display: grid; place-items: center; box-shadow: inset 1px 1px grey, inset -1px -1px #fff; }
.web-logo svg { width: 20px; height: 20px; }
.web-logo.is-loading svg { animation: spin 0.8s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.web-address { display: flex; gap: 4px; align-items: center; padding: 3px 4px; }
.web-address input { flex: 1; min-width: 0; }
.win--web .web-body { margin: 0 4px 4px; display: flex; }
.web-page { flex: 1; overflow: auto; background: #fff; transition: opacity .2s; }
.web-page.is-loading { opacity: .35; }
.pg { padding: 12px 16px; font-family: "Times New Roman", Times, serif; font-size: 15px; line-height: 1.4; color: #000; }
.pg a { color: #00e; text-decoration: underline; cursor: pointer; }
.pg a:visited { color: #551a8b; }
.pg h1, .pg h2, .pg h3 { font-family: Arial, sans-serif; margin: .5em 0 .3em; }
.pg-foot { font-size: 11px; color: #666; text-align: center; margin-top: 18px; font-family: Arial, sans-serif; }
.pg-portal { font-family: Arial, sans-serif; font-size: 13px; }
.portal-head { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; justify-content: space-between; border-bottom: 3px solid #ff6a00; padding-bottom: 8px; }
.portal-logo { font: italic 900 30px "Arial Black", Arial, sans-serif; color: #000080; letter-spacing: -1px; }
.portal-logo span { color: #ff6a00; font-size: 20px; }
.portal-search { display: flex; gap: 4px; }
.portal-search input { width: 190px; }
.portal-nav { background: #e6ecff; padding: 4px 8px; margin: 8px 0; font-weight: bold; }
.portal-cols { display: grid; grid-template-columns: 1fr 180px; gap: 14px; }
.portal-cols h3 { font-size: 13px; background: #000080; color: #fff; padding: 2px 6px; }
.portal-box { border: 1px solid #99a; background: #fffbe8; padding: 6px 8px; margin-bottom: 8px; }
.portal-tracks { margin: 0; padding-left: 22px; columns: 2; }
.b88-grid { display: flex; flex-wrap: wrap; gap: 6px; margin: 10px 0; }
.b88 { width: 88px; height: 31px; display: grid; place-items: center; text-align: center; font: bold 9px/1 Verdana, sans-serif; color: #fff !important; text-decoration: none !important;
  background: linear-gradient(#555, #111); border: 2px outset #999; letter-spacing: .5px; }
.b88--spotify { background: linear-gradient(#2fe06f, #138a3e); }
.b88--appleMusic { background: linear-gradient(#ff5f78, #c3112c); }
.b88--youtubeMusic { background: linear-gradient(#ff4040, #a40000); }
.b88--deezer { background: linear-gradient(#b25bff, #5f1fb0); }
.b88--tidal { background: linear-gradient(#333, #000); }
.b88--amazonMusic { background: linear-gradient(#36d5e0, #0b7f9a); }
.b88--pandora { background: linear-gradient(#3b8cff, #0b3fa8); }
.b88--boomplay { background: linear-gradient(#1f6bff, #0a2f8a); }
.b88--allPlatforms { background: linear-gradient(#ffd400, #e08a00); color: #000 !important; }
.listen-cover { width: 160px; border: 2px solid #000; }
.pg-shrine { background: #000 repeating-conic-gradient(#120024 0 25%, #000 0 50%) 0 0 / 20px 20px; color: #0f0; font-family: "Comic Sans MS", "Comic Sans", cursive; text-align: center; min-height: 100%; }
.pg-shrine a { color: #ff0; }
.pg-shrine h1 { color: #ff00e6; font-family: "Comic Sans MS", cursive; text-shadow: 2px 2px #00f; }
.pg-shrine h2 { color: #0ff; font-family: "Comic Sans MS", cursive; }
.pg-shrine marquee { color: #ff0; background: #00f; padding: 2px; }
.uc { display: inline-block; padding: 6px 16px; margin: 6px; color: #000; font: bold 13px Arial, sans-serif; background: repeating-linear-gradient(45deg, #ffd400 0 12px, #000 12px 24px); }
.uc { text-shadow: 0 0 3px #ffd400, 0 0 3px #ffd400; }
.shrine-img { max-width: 260px; margin: 8px auto; border: 4px ridge #ff00e6; }
.shrine-list { list-style: none; padding: 0; }
.shrine-count { background: #000; color: #f33; font-family: monospace; padding: 0 4px; border: 1px solid #555; }
.webring-bar { margin-top: 12px; color: #fff; }
.pg-404 { font-family: Verdana, Arial, sans-serif; font-size: 12px; }
.pg-404 h2 { font-size: 16px; }
.pg-secret { text-align: center; }
.hallpass { display: inline-block; text-align: left; border: 3px dashed #000; padding: 12px 16px; background: #ffb6d9; font-family: "Courier New", monospace; transform: rotate(-2deg); }

/* Hallway */
.win--board .board-body { display: flex; flex-direction: column; gap: 6px; }
.board-head { display: flex; justify-content: space-between; align-items: center; gap: 8px; padding: 6px 8px; color: #fff; background: linear-gradient(90deg, #5a0f0f, #b03030); }
.board-head small { color: #ffd; }
.board-new { display: flex; flex-direction: column; gap: 4px; }
.board-new textarea { width: 100%; resize: vertical; font: 12px Arial, sans-serif; }
.board-new .field-row input { flex: 1; }
.board-send { justify-content: space-between; }
.board-list { flex: 1; min-height: 120px; overflow: auto; padding: 6px; background: #f4f1e6; font-family: Arial, sans-serif; font-size: 12px; }
.board-empty { text-align: center; color: #666; margin: 20px 0; }
.thread { background: #fff; border: 1px solid #aaa; margin-bottom: 8px; padding: 6px 8px; box-shadow: 2px 2px 0 rgba(0,0,0,.15); }
.bp-head { display: flex; justify-content: space-between; gap: 8px; color: #800000; }
.bp-head span { color: #888; font-size: 11px; }
.bp-body { margin: 3px 0; white-space: pre-wrap; word-wrap: break-word; }
.bp--reply { margin: 6px 0 0 14px; padding: 4px 0 0 8px; border-left: 3px solid #d8c9a0; }
.linkish { all: unset; color: #00e; text-decoration: underline; cursor: pointer; font-size: 11px; }
.reply-form { display: flex; gap: 4px; margin-top: 6px; }
.reply-form input[name=name] { width: 90px; }
.reply-form input[name=body] { flex: 1; min-width: 0; }

/* Command prompt */
.win--cmd .cmd-body { margin: 2px; background: #000; color: #c0c0c0; font: 14px/1.25 "Courier New", Consolas, monospace; padding: 4px 6px; overflow: auto; cursor: text; }
.cmd-body pre { margin: 0; white-space: pre-wrap; font: inherit; color: inherit; background: transparent !important; border: 0 !important; box-shadow: none !important; padding: 0 !important; }
.cmd-line { display: flex; }
.cmd-line label { white-space: nowrap; }
.cmd-line input { flex: 1; background: transparent !important; border: 0 !important; box-shadow: none !important; color: #c0c0c0; font: inherit; padding: 0; height: auto; outline: none; caret-color: #c0c0c0; }

/* Display properties */
.monitor { width: 180px; margin: 4px auto 10px; padding: 10px 10px 18px; background: #c0c0c0; box-shadow: inset -1px -1px #0a0a0a, inset 1px 1px #fff, inset -2px -2px grey, inset 2px 2px #dfdfdf; }
.monitor__screen { height: 110px; background: #008080; box-shadow: inset 1px 1px #0a0a0a; }
.display-options { display: grid; grid-template-columns: 1fr 1fr; gap: 2px 10px; }

/* Snake */
.snake-body { display: flex; flex-direction: column; align-items: center; gap: 8px; }
.snake-lcd { background: #8bac0f; padding: 6px; border: 3px inset #556b0a; position: relative; }
.snake-score { display: flex; justify-content: space-between; font: bold 12px "Courier New", monospace; color: #0f380f; margin-bottom: 4px; }
#snake-cv { display: block; image-rendering: pixelated; width: 220px; height: 220px; }
.snake-msg { position: absolute; left: 0; right: 0; bottom: 40%; text-align: center; font: bold 12px "Courier New", monospace; color: #0f380f; margin: 0; }
.snake-pad { display: grid; grid-template-columns: repeat(3, 44px); grid-template-rows: repeat(3, 34px); gap: 2px; }
.snake-pad button { min-width: 0; padding: 0; }
.snake-pad [data-d=up] { grid-column: 2; grid-row: 1; }
.snake-pad [data-d=left] { grid-column: 1; grid-row: 2; }
.snake-pad #snake-start { grid-column: 2; grid-row: 2; }
.snake-pad [data-d=right] { grid-column: 3; grid-row: 2; }
.snake-pad [data-d=down] { grid-column: 2; grid-row: 3; }

/* context menu */
.ctxmenu { position: fixed; list-style: none; margin: 0; padding: 3px; min-width: 160px; }
.ctxmenu button { all: unset; box-sizing: border-box; display: block; width: 100%; padding: 3px 20px; cursor: default; }
.ctxmenu button:hover, .ctxmenu button:focus-visible { background: var(--navy); color: #fff; }
.ctxmenu .sep { height: 2px; margin: 3px 2px; border-top: 1px solid grey; border-bottom: 1px solid #fff; }

/* toast, flash, screensaver */
.cq-toast { position: fixed; left: 50%; bottom: 44px; transform: translate(-50%, 200%); z-index: 30000; background: #ffffe1; color: #000; border: 1px solid #000; padding: 6px 12px; font-size: 12px; transition: transform .25s; box-shadow: 2px 2px 0 rgba(0,0,0,.4); }
.cq-toast.is-on { transform: translate(-50%, 0); }
.flash { position: fixed; inset: 0; z-index: 25000; pointer-events: none; }
.flash.is-on { animation: flash .6s steps(6) both; }
@keyframes flash {
  0% { background: #fff; } 17% { background: transparent; backdrop-filter: invert(1) hue-rotate(90deg); }
  33% { background: rgba(255,0,200,.4); } 50% { backdrop-filter: invert(1); background: transparent; }
  67% { background: rgba(0,240,255,.35); } 100% { background: transparent; backdrop-filter: none; }
}
.screensaver { position: fixed; inset: 0; z-index: 40000; background: #000; cursor: none; }
.screensaver canvas { display: block; }

/* ============================================================
   PHONE MODE: a Y2K cell phone, not a desktop
   ============================================================ */
.ph-status, .ph-home, .ph-np, .ph-keys { display: none; }
html:has(body.phone) { overflow: hidden; overscroll-behavior: none; }
body.phone { overflow-x: hidden; overscroll-behavior: none; touch-action: pan-y; width: 100vw; max-width: 100%; }
body.phone .ph-home, body.phone .win > .window-body, body.phone .web-page, body.phone .board-list, body.phone .im-log,
body.phone .cmd-body, body.phone .startmenu, body.phone .notepad { overflow-x: hidden !important; overscroll-behavior: contain; }
body.phone .ph-ticker { margin-left: 0; margin-right: 0; }
body.phone .win img, body.phone .pg img { max-width: 100%; height: auto; }
body.phone .cd-table table { table-layout: fixed; width: 100%; }
body.phone .cd-table th:nth-child(3), body.phone .cd-table td:nth-child(3) { display: none; }
body.phone .cd-table td:nth-child(2) { width: auto; }
body.phone .pg { word-wrap: break-word; overflow-wrap: anywhere; }
body.phone .pg marquee { max-width: 100%; }
body.phone .portal-search input { width: 100%; min-width: 0; }
body.phone .portal-search { flex: 1; min-width: 0; }
body.phone .web-address input, body.phone .field-row input { min-width: 0; }
body.phone .field-row { flex-wrap: wrap; }
body.phone .web-toolbar { flex-wrap: wrap; }
body.phone.ph-menu-on .ph-home { visibility: hidden; }
body.phone { --ph-top: 24px; --ph-keys: 52px; --ph-np: 0px; overflow: hidden; background: #000; font-size: 13px; }
body.phone.ph-np-on { --ph-np: 56px; }
body.phone .taskbar, body.phone .icons, body.phone #w-alert, body.phone .ctxmenu, body.phone .desktop::after { display: none !important; }
body.phone .desktop { inset: 0; z-index: 150; background: transparent !important; pointer-events: none; }
body.phone .desktop .win { pointer-events: auto; }

/* status bar */
body.phone .ph-status {
  display: flex; position: fixed; top: 0; left: 0; right: 0; height: var(--ph-top); z-index: 50000;
  align-items: center; gap: 8px; padding: 0 10px; color: #b8ffcf; background: #05070d;
  font: 12px/1 "Courier New", monospace; letter-spacing: 1px; text-shadow: 0 0 4px rgba(120,255,170,.6);
}
.ph-sig { display: inline-flex; align-items: flex-end; gap: 1px; height: 12px; }
.ph-sig i { width: 3px; background: #b8ffcf; }
.ph-sig i:nth-child(1) { height: 4px; } .ph-sig i:nth-child(2) { height: 6px; } .ph-sig i:nth-child(3) { height: 9px; } .ph-sig i:nth-child(4) { height: 12px; }
.ph-carrier { flex: 1; }
.ph-batt { width: 22px; height: 10px; border: 1px solid #b8ffcf; position: relative; padding: 1px; }
.ph-batt::after { content: ""; position: absolute; right: -3px; top: 2px; width: 2px; height: 4px; background: #b8ffcf; }
.ph-batt i { display: block; height: 100%; width: 75%; background: #b8ffcf; }

/* home screen */
body.phone .ph-home {
  display: flex; flex-direction: column; position: fixed; z-index: 100;
  top: var(--ph-top); bottom: calc(var(--ph-keys) + var(--ph-np)); left: 0; right: 0; overflow: auto;
  background: linear-gradient(180deg, rgba(0,10,40,.35), rgba(0,0,0,.75)), var(--ph-wall, none) center / cover, #0b1430;
  padding: 18px 14px 14px;
}
.ph-clock { text-align: center; color: #fff; text-shadow: 0 2px 0 #000, 0 0 12px rgba(0,180,255,.6); margin-bottom: 10px; }
.ph-clock b { display: block; font: 64px/1 "Courier New", monospace; font-weight: bold; letter-spacing: -2px; }
.ph-clock span { font: 13px "Courier New", monospace; letter-spacing: 3px; color: #cde; }
.ph-ticker { overflow: hidden; white-space: nowrap; margin: 6px -14px 16px; max-width: 100vw; background: rgba(0,0,0,.55); border-block: 1px solid rgba(120,200,255,.4); color: #7fffd4; font: 12px "Courier New", monospace; padding: 4px 0; }
.ph-ticker span { display: inline-block; padding-left: 100%; animation: phtick 18s linear infinite; }
@keyframes phtick { to { transform: translateX(-100%); } }
.ph-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px 10px; }
.ph-tile { all: unset; display: flex; flex-direction: column; align-items: center; gap: 6px; cursor: pointer; -webkit-tap-highlight-color: transparent; text-decoration: none; }
.ph-ico {
  width: 64px; height: 64px; border-radius: 16px; display: grid; place-items: center; position: relative; overflow: hidden;
  background: radial-gradient(120% 90% at 30% 10%, rgba(255,255,255,.55), transparent 45%), linear-gradient(160deg, var(--tile), color-mix(in srgb, var(--tile) 55%, #000));
  border: 2px solid rgba(255,255,255,.85); box-shadow: 0 3px 0 rgba(0,0,0,.5), 0 0 0 1px #000, inset 0 -6px 10px rgba(0,0,0,.25);
}
.ph-ico::before { content: ""; position: absolute; left: 4px; right: 4px; top: 3px; height: 45%; border-radius: 12px 12px 40% 40%; background: linear-gradient(rgba(255,255,255,.55), rgba(255,255,255,.05)); }
.ph-ico svg { width: 36px; height: 36px; position: relative; filter: drop-shadow(0 1px 0 rgba(0,0,0,.6)); }
.ph-ico--snake { font-size: 32px; }
.ph-lbl { color: #fff; font-size: 12px; text-align: center; text-shadow: 0 1px 2px #000, 0 0 2px #000; max-width: 90px; }
.ph-tile:active .ph-ico { transform: translateY(2px); box-shadow: 0 1px 0 rgba(0,0,0,.5), 0 0 0 1px #000; }

/* apps go full screen, one at a time */
body.phone .win {
  position: fixed !important; left: 0 !important; right: 0; top: var(--ph-top) !important; bottom: calc(var(--ph-keys) + var(--ph-np));
  width: auto !important; height: auto !important; max-width: none; min-width: 0; margin: 0; z-index: 200 !important;
  transform: none !important; box-shadow: none; padding: 0; background: #dfe3ec;
}
body.phone .win.is-open:not(.is-active) { display: none; }
body.phone .win.is-active { animation: phslide .22s ease-out; }
@keyframes phslide { from { transform: translateX(30px) !important; opacity: .4; } }
body.phone .win .title-bar {
  height: 40px; padding: 0 12px; border-radius: 0;
  background: linear-gradient(#5aa9ff, #1d5fd6 55%, #164bb0) !important; box-shadow: inset 0 1px rgba(255,255,255,.6), 0 2px 0 rgba(0,0,0,.25);
}
body.phone .win .title-bar-text { color: #fff !important; font-size: 15px; font-weight: bold; text-shadow: 0 1px 0 rgba(0,0,0,.4); }
body.phone .win .title-bar-controls, body.phone .win .menubar { display: none; }
body.phone .win > .window-body { margin: 8px; overflow: auto; flex: 1; }
body.phone .win .status-bar { margin: 0; }
body.phone .win--readme .notepad { font-size: 15px; }
body.phone .screen { height: 210px; }
body.phone .glitch { font-size: 44px; }
body.phone .cd-grid { grid-template-columns: 1fr; }
body.phone .cd-art { max-width: 180px; margin: 0 auto; }
body.phone .cd-table { height: auto; max-height: none; }
body.phone .buddy-tree { height: auto; }
body.phone .im-log { height: 40vh; }
body.phone .web-toolbar .web-logo { display: none; }
body.phone .portal-cols { grid-template-columns: 1fr; }
body.phone .portal-tracks { columns: 1; }
body.phone .win--cmd .cmd-body { font-size: 13px; }
body.phone .snake-body { padding-top: 10px; }
body.phone #snake-cv { width: 260px; height: 260px; }
body.phone .snake-pad { grid-template-columns: repeat(3, 64px); grid-template-rows: repeat(3, 48px); }
body.phone input, body.phone textarea, body.phone select { font-size: 16px; }

/* now playing bar */
body.phone .ph-np:not([hidden]) {
  display: flex; position: fixed; left: 0; right: 0; bottom: var(--ph-keys); height: var(--ph-np); z-index: 50000;
  align-items: center; gap: 8px; padding: 6px 8px; color: #fff;
  background: linear-gradient(#2a2f3d, #12151d); border-top: 1px solid #556;
}
.ph-np img { width: 42px; height: 42px; object-fit: cover; border: 1px solid #000; }
.ph-np-info { all: unset; flex: 1; min-width: 0; display: flex; flex-direction: column; }
.ph-np-info b { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; font-size: 13px; }
.ph-np-info small { color: #9ab; font-size: 11px; }
.ph-np > button:not(.ph-np-info) { min-width: 40px; height: 36px; font-size: 14px; }

/* softkeys */
body.phone .ph-keys {
  display: grid; grid-template-columns: 1fr 64px 1fr; position: fixed; left: 0; right: 0; bottom: 0; height: var(--ph-keys); z-index: 50000;
  background: linear-gradient(#3b4252, #1a1e27); border-top: 2px solid #000; padding: 6px 8px; gap: 8px;
}
.ph-keys button {
  min-width: 0; height: 100%; border-radius: 18px; color: #fff; font: bold 13px Arial, sans-serif; letter-spacing: .5px;
  background: linear-gradient(#69758c, #3a4254); box-shadow: inset 0 1px rgba(255,255,255,.4), 0 2px 0 #000; border: 1px solid #000;
}
.ph-keys #ph-mid { border-radius: 50%; width: 52px; height: 40px; justify-self: center; background: radial-gradient(circle at 35% 30%, #9fd2ff, #1d5fd6 60%, #0b2f7a); font-size: 18px; }
.ph-keys button:active { transform: translateY(1px); box-shadow: inset 0 1px rgba(255,255,255,.2); }
body.phone .ph-keys button:focus-visible { outline: 2px solid #7fffd4; }

/* phone menu = start menu as a list */
body.phone .startmenu { left: 0; right: 0; top: var(--ph-top); bottom: var(--ph-keys); z-index: 60000; padding: 0; background: #0d1220; border: 0; box-shadow: none; overflow: auto; }
body.phone .startmenu__side { display: none; }
body.phone .startmenu__items { width: 100%; }
body.phone .startmenu__items button, body.phone .startmenu__items a { color: #e8f0ff; padding: 10px 14px; font-size: 15px; border-bottom: 1px solid #1f2840; }
body.phone .startmenu__items button:hover, body.phone .startmenu__items a:hover { background: #1d5fd6; }
body.phone .startmenu__items .sep { display: none; }

@media (prefers-reduced-motion: reduce) {
  .ph-ticker span, body.phone .win.is-active { animation: none !important; }
}

/* ============================================================
   MUSIC SERVICES + ICON CONTROLS
   ============================================================ */
.transport button { display: inline-grid; place-items: center; height: 24px; }
.transport button svg { width: 12px; height: 12px; color: #000; }
.transport.is-off button, .transport.is-off .seek { opacity: .45; pointer-events: none; }
.svc-bar { display: flex; align-items: center; justify-content: space-between; gap: 6px; margin: 6px 0 4px; }
.svc-now { display: inline-flex; align-items: center; gap: 6px; min-width: 0; }
.svc-now svg { width: 16px; height: 16px; flex: none; }
.svc-q { margin: 0 0 8px; }
.svc-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(118px, 1fr)); gap: 6px; }
.svc-btn { display: grid; grid-template-columns: 24px 1fr; grid-template-rows: auto auto; column-gap: 6px; align-items: center; text-align: left; height: auto; padding: 6px 8px; min-width: 0; }
.svc-btn svg { grid-row: 1 / 3; width: 24px; height: 24px; }
.svc-btn span { font-weight: bold; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.svc-btn small { color: #555; font-size: 10px; }
.svc-btn.is-current { outline: 1px dotted #000; outline-offset: -4px; background: #e8e8ff; }
.svc-hint { margin: 6px 0 0; color: #333; font-size: 11px; }
.ext-frame { display: block; width: 100%; border: 0; background: #000; height: 420px; }
.ext-frame--appleMusic { height: 450px; border-radius: 8px; background: transparent; }
.ext-frame--deezer { height: 300px; }
.ext-frame--tidal { height: 400px; }
.svc-link { display: flex; gap: 12px; align-items: center; padding: 6px 2px; }
.svc-link-ico { width: 40px; height: 40px; flex: none; }
.button-like {
  display: inline-block; padding: 6px 16px; color: #000; text-decoration: none; background: silver; min-width: 120px; text-align: center;
  box-shadow: inset -1px -1px #0a0a0a, inset 1px 1px #fff, inset -2px -2px grey, inset 2px 2px #dfdfdf;
}
.button-like:active { box-shadow: inset -1px -1px #fff, inset 1px 1px #0a0a0a, inset -2px -2px #dfdfdf, inset 2px 2px grey; }
.win--player .tabpanel .window-body { max-height: 520px; overflow: auto; }

/* phone music bar icons */
.ph-np > button:not(.ph-np-info) { display: inline-grid; place-items: center; padding: 0; }
.ph-np > button:not(.ph-np-info) svg { width: 16px; height: 16px; color: #000; display: block; }
.ph-np img:not([src]), .ph-np img[src=""] { visibility: hidden; }
body.phone .ext-frame { height: 60vh; }
body.phone .svc-grid { grid-template-columns: 1fr 1fr; }
body.phone .svc-btn { padding: 10px; }
body.phone .svc-bar { flex-wrap: wrap; }

/* ============================================================
   PHONE: incoming call screen
   ============================================================ */
.ph-call { position: fixed; inset: 0; z-index: 90000; color: #dffcff; font-family: "Courier New", monospace; }
.call-ring {
  position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; padding: 26px 20px 24px;
  background:
    repeating-linear-gradient(0deg, rgba(0,0,0,.25) 0 1px, transparent 1px 3px),
    radial-gradient(120% 70% at 50% 30%, #1a4fb8 0%, #0a1e55 45%, #030816 100%);
}
.call-top { width: 100%; display: flex; justify-content: space-between; font-size: 13px; letter-spacing: 2px; }
.call-blink { color: #7fffd4; animation: callblink 1s steps(2) infinite; text-shadow: 0 0 6px #7fffd4; }
.call-line { color: #8fb3ff; }
@keyframes callblink { 50% { opacity: .2; } }
.call-waves { position: relative; width: 210px; height: 210px; margin: 30px 0 0; display: grid; place-items: center; }
.call-waves i { position: absolute; inset: 40px; border: 2px solid rgba(127,255,212,.55); border-radius: 50%; animation: callwave 2s ease-out infinite; }
.call-waves i:nth-child(2) { animation-delay: .66s; } .call-waves i:nth-child(3) { animation-delay: 1.33s; }
@keyframes callwave { from { transform: scale(.7); opacity: 1; } to { transform: scale(1.5); opacity: 0; } }
.call-photo { position: absolute; top: 106px; left: 50%; transform: translateX(-50%); width: 134px; height: 134px; padding: 4px;
  background: linear-gradient(#c8d4ff, #6b7fb8); border: 2px solid #000; box-shadow: 0 0 0 2px #7fffd4, 0 0 24px rgba(127,255,212,.5); }
.call-photo img { width: 100%; height: 100%; object-fit: cover; image-rendering: pixelated; filter: contrast(1.1) saturate(1.2); }
.call-name { margin-top: 18px; font: bold 40px/1 Impact, "Arial Black", sans-serif; letter-spacing: 3px; color: #fff; text-shadow: 0 2px 0 #000, 0 0 14px rgba(127,255,212,.6); }
.call-num { margin-top: 6px; font-size: 14px; color: #a9c4ff; letter-spacing: 1px; }
.call-vibe { margin-top: auto; margin-bottom: 18px; }
.call-vibe svg { width: 44px; height: 44px; animation: callshake .12s linear infinite alternate; }
@keyframes callshake { from { transform: translateX(-3px) rotate(-6deg); } to { transform: translateX(3px) rotate(6deg); } }
.call-keys, .call-live-keys { display: flex; gap: 14px; width: 100%; max-width: 360px; }
.call-btn {
  flex: 1; min-width: 0; height: 64px; display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  border-radius: 32px; border: 2px solid #000; color: #fff; font: bold 18px Arial, sans-serif; letter-spacing: 1px;
  box-shadow: inset 0 2px rgba(255,255,255,.5), 0 3px 0 #000; text-shadow: 0 1px 0 rgba(0,0,0,.5);
}
.call-btn svg { width: 24px; height: 24px; }
.call-btn--yes { background: linear-gradient(#5fe36a, #1c9a2b); animation: callpulse 1s ease-in-out infinite; }
.call-btn--no { background: linear-gradient(#ff6b6b, #b81c1c); }
.call-btn:active { transform: translateY(2px); box-shadow: inset 0 2px rgba(255,255,255,.3); }
@keyframes callpulse { 50% { box-shadow: inset 0 2px rgba(255,255,255,.5), 0 3px 0 #000, 0 0 0 6px rgba(95,227,106,.35); } }
.call-live { position: absolute; inset: 0; background: #000; }
.call-live video { width: 100%; height: 100%; object-fit: cover; }
.call-live-top { position: absolute; top: 0; left: 0; right: 0; display: flex; justify-content: space-between; padding: 14px 18px;
  background: linear-gradient(rgba(0,0,0,.75), transparent); font-size: 16px; letter-spacing: 2px; text-shadow: 0 1px 2px #000; }
.call-live-top b { font: bold 22px Impact, "Arial Black", sans-serif; letter-spacing: 2px; }
.call-live-keys { position: absolute; left: 50%; bottom: 26px; transform: translateX(-50%); width: calc(100% - 60px); max-width: 280px; }
.call-ended { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 10px;
  background: #030816; font-size: 22px; letter-spacing: 4px; color: #7fffd4; }
.call-ended span { color: #a9c4ff; font-size: 16px; }
body.ph-calling .ph-keys, body.ph-calling .ph-np { visibility: hidden; }
@media (prefers-reduced-motion: reduce) { .call-waves i, .call-vibe svg, .call-btn--yes, .call-blink { animation: none !important; } }

/* phone: home affordances */
.ph-home-btn { display: none; }
body.phone .win .title-bar { justify-content: space-between; }
body.phone .ph-home-btn {
  display: inline-grid; place-items: center; min-width: 0; width: 34px; height: 28px; padding: 0; margin-left: 8px; flex: none;
  border-radius: 8px; border: 1px solid rgba(0,0,0,.6); color: #fff;
  background: linear-gradient(rgba(255,255,255,.35), rgba(255,255,255,.08)); box-shadow: inset 0 1px rgba(255,255,255,.5);
}
body.phone .ph-home-btn svg { width: 16px; height: 16px; }
.ph-keys #ph-right { display: inline-flex; align-items: center; justify-content: center; gap: 6px; }
.ph-key-ico { width: 14px; height: 14px; }
body.phone .win .title-bar-text { min-width: 0; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }

/* open in Spotify */
.svc-open-row { display: flex; align-items: center; gap: 10px; margin-top: 6px; flex-wrap: wrap; }
.svc-open { display: inline-flex; align-items: center; gap: 6px; min-width: 0; font-weight: bold; }
.svc-open svg { width: 16px; height: 16px; }
.svc-open-row .svc-hint { flex: 1; min-width: 160px; margin: 0; }
.ph-np-open { display: inline-grid; place-items: center; width: 40px; height: 36px; border-radius: 8px; background: #111; border: 1px solid #000; box-shadow: inset 0 1px rgba(255,255,255,.2); }
.ph-np-open[hidden] { display: none; }
.ph-np-open svg { width: 22px; height: 22px; }

/* ============================================================
   CQ ARCADE
   ============================================================ */
.win--arcade { width: 400px; }
.arc-body { background: #05070f; color: #dfe6ff; margin: 2px !important; padding: 8px; }
.arc-marquee { display: flex; flex-direction: column; align-items: center; padding: 8px; margin-bottom: 8px; border: 2px solid #f2e33a;
  background: repeating-linear-gradient(90deg, #1a0b2e 0 12px, #12071f 12px 24px); box-shadow: 0 0 12px rgba(242,227,58,.35) inset; }
.arc-marquee b { font: 28px/1 Impact, "Arial Black", sans-serif; letter-spacing: 3px; color: #f2e33a; text-shadow: 2px 2px 0 #ff3ea5, 0 0 10px rgba(242,227,58,.6); }
.arc-marquee span { font: 11px "Courier New", monospace; color: #3ee0ff; margin-top: 4px; }
.arc-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; max-height: 470px; overflow: auto; padding-right: 2px; }
.arc-card { all: unset; box-sizing: border-box; cursor: pointer; display: flex; flex-direction: column; gap: 3px; padding: 6px;
  background: #11152a; border: 2px solid var(--c); box-shadow: 3px 3px 0 #000; font-family: "Courier New", monospace; color: #fff; }
.arc-card:hover, .arc-card:focus-visible { background: #1b2140; transform: translate(-1px, -1px); box-shadow: 4px 4px 0 #000; }
.arc-card canvas { width: 100%; height: auto; aspect-ratio: 3 / 2; image-rendering: pixelated; background: #0b0f24; border: 1px solid #000; }
.arc-card b { font: 15px Impact, "Arial Black", sans-serif; letter-spacing: 1px; color: var(--c); }
.arc-card small { color: #ff8ad0; font-size: 10px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.arc-hi { color: #8fa0d0; font-size: 10px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.arc-top { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-bottom: 6px; }
.arc-song { font: 11px "Courier New", monospace; color: #ff8ad0; text-align: right; min-width: 0; }
.arc-song a { color: #3ee0ff; }
.arc-screen { position: relative; }
#arc-cv { display: block; width: 100%; aspect-ratio: 3 / 4; background: #0b0f24; border: 2px solid #f2e33a; image-rendering: pixelated; touch-action: none; outline: none; }
.arc-over { position: absolute; inset: 22px 2px 2px; background: rgba(5,7,15,.94); display: flex; flex-direction: column; align-items: center; padding: 14px 16px; overflow: auto;
  font-family: "Courier New", monospace; color: #fff; text-align: center; }
.arc-over h3 { font: 30px Impact, "Arial Black", sans-serif; color: #ff3ea5; margin: 4px 0; letter-spacing: 2px; }
.arc-over h4 { margin: 10px 0 4px; color: #3ee0ff; font-size: 12px; }
.arc-final { font: 40px Impact, "Arial Black", sans-serif; color: #f2e33a; margin: 0 0 8px; }
.arc-submit { display: flex; gap: 6px; }
.arc-submit input { width: 140px; }
.arc-ok { color: #b6ff3b; margin: 4px 0; }
.arc-board { list-style: none; padding: 0; margin: 0; width: 100%; max-width: 230px; font-size: 13px; }
.arc-board li { display: flex; justify-content: space-between; padding: 2px 0; border-bottom: 1px dashed #2a3050; }
.arc-board b { color: #f2e33a; }
.arc-over-btns { display: flex; gap: 8px; margin-top: 12px; }
.arc-pad { display: none; justify-content: space-between; align-items: center; padding: 10px 6px 4px; user-select: none; -webkit-user-select: none; touch-action: none; }
.arc-dpad { display: grid; grid-template-columns: repeat(3, 46px); grid-template-rows: repeat(3, 40px); }
.arc-dpad button, .arc-ab button { min-width: 0; padding: 0; touch-action: none; }
.arc-dpad [data-k=up] { grid-column: 2; grid-row: 1; } .arc-dpad [data-k=left] { grid-column: 1; grid-row: 2; }
.arc-dpad [data-k=right] { grid-column: 3; grid-row: 2; } .arc-dpad [data-k=down] { grid-column: 2; grid-row: 3; }
.arc-ab button { width: 72px; height: 72px; border-radius: 50%; font: bold 24px Arial, sans-serif; color: #fff;
  background: radial-gradient(circle at 35% 30%, #ff7cc4, #ff3ea5 55%, #a8105e); box-shadow: 0 3px 0 #000, inset 0 2px rgba(255,255,255,.5); border: 2px solid #000; }
.arc-pad button.is-down { filter: brightness(.8); transform: translateY(2px); }
.arc-keys { margin: 6px 0 0; font: 10px "Courier New", monospace; color: #6b7290; text-align: center; }
@media (pointer: coarse) { .arc-pad { display: flex; } .arc-keys { display: none; } }
body.phone .arc-pad { display: flex; }
body.phone .arc-keys { display: none; }
body.phone .win--arcade > .window-body { padding: 6px; }
body.phone #arc-cv { width: min(100%, calc((100dvh - 330px) * .75)); margin: 0 auto; }
body.phone .arc-grid { max-height: none; }
body.phone .arc-over { inset: 22px 0 0; }

/* voice call (no video) */
.call-live { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; padding: 26px 20px 24px;
  background: repeating-linear-gradient(0deg, rgba(0,0,0,.25) 0 1px, transparent 1px 3px), radial-gradient(120% 70% at 50% 30%, #0f6b4a 0%, #07352a 45%, #020a08 100%); }
.call-live .call-top { width: 100%; }
.call-on { color: #7fffa1; text-shadow: 0 0 6px #7fffa1; }
#call-timer { color: #dffcff; letter-spacing: 2px; }
.call-photo--live { position: static; transform: none; margin-top: 48px; box-shadow: 0 0 0 2px #7fffa1, 0 0 24px rgba(127,255,161,.45); }
.call-live .call-name { margin-top: 18px; }
.call-eq { display: flex; align-items: flex-end; gap: 5px; height: 46px; margin-top: 26px; }
.call-eq i { width: 8px; height: 6px; background: #7fffa1; box-shadow: 0 0 6px rgba(127,255,161,.6); animation: calleq .5s ease-in-out infinite alternate; }
.call-eq i:nth-child(2) { animation-delay: .1s; } .call-eq i:nth-child(3) { animation-delay: .25s; } .call-eq i:nth-child(4) { animation-delay: .05s; }
.call-eq i:nth-child(5) { animation-delay: .3s; } .call-eq i:nth-child(6) { animation-delay: .15s; } .call-eq i:nth-child(7) { animation-delay: .35s; }
@keyframes calleq { to { height: 44px; } }
.call-icons { display: flex; gap: 22px; margin-top: auto; margin-bottom: 22px; font-size: 12px; color: #a9e8c4; letter-spacing: 1px; }
.call-live .call-live-keys { position: static; transform: none; width: 100%; max-width: 280px; }
.call-live-top { display: none; }

/* Music app: releases */
.rel-row { display: flex; gap: 8px; overflow-x: auto; padding: 2px 2px 8px; margin-bottom: 6px; border-bottom: 1px solid grey; }
.rel { display: flex; flex-direction: column; align-items: flex-start; gap: 2px; width: 118px; flex: none; padding: 4px; height: auto; text-align: left; }
.rel img, .rel-blank { width: 100%; aspect-ratio: 1; object-fit: cover; background: #000; display: block; }
.rel b { font-size: 11px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 100%; }
.rel small { color: #555; font-size: 10px; }
.rel[aria-selected="true"] { outline: 1px dotted #000; outline-offset: -4px; background: #e8e8ff; }
.cd-title { margin: 0; font-size: 16px; }
.cd-links { display: flex; flex-wrap: wrap; gap: 4px; margin-top: 4px; }
.cd-links .plat { display: inline-flex; align-items: center; gap: 4px; padding: 2px 6px 2px 3px; color: #000; text-decoration: none; background: silver;
  box-shadow: inset -1px -1px #0a0a0a, inset 1px 1px #fff, inset -2px -2px grey, inset 2px 2px #dfdfdf; font-size: 11px; }
.cd-links .plat svg { width: 16px; height: 16px; }
.cd-links .plat:active { box-shadow: inset -1px -1px #fff, inset 1px 1px #0a0a0a; }
body.phone .rel { width: 104px; }
body.phone .rel-row { overflow-x: auto; overscroll-behavior-x: contain; }

/* Contacts */
.win--buddy { width: 250px; }
.contacts-search input { width: 100%; margin-bottom: 6px; }
.contacts { list-style: none; margin: 0; padding: 2px; height: 300px; overflow: auto; background: #fff; }
.ct-letter { font-weight: bold; color: #000080; padding: 4px 6px 2px; border-bottom: 1px solid #c0c0c0; font-size: 11px; }
.ct { all: unset; box-sizing: border-box; display: flex; align-items: center; gap: 8px; width: 100%; padding: 4px 6px; cursor: pointer; }
.ct:hover, .ct:focus-visible { background: #000080; color: #fff; }
.ct:hover small, .ct:focus-visible small { color: #cfd8ff; }
.ct-av { width: 30px; height: 30px; flex: none; display: grid; place-items: center; color: #fff; font-weight: bold; font-size: 11px; overflow: hidden; border: 1px solid #000; }
.ct-av img { width: 100%; height: 100%; object-fit: cover; }
.ct-txt { display: flex; flex-direction: column; min-width: 0; }
.ct-txt b { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ct-txt small { color: #666; font-size: 10px; }
.ct-empty { padding: 10px; color: #666; }
.ct-card { text-align: center; }
.ct-card-av { width: 140px; height: 140px; margin: 6px auto 8px; display: grid; place-items: center; color: #fff; font: bold 40px Arial, sans-serif; overflow: hidden; border: 2px solid #000;
  box-shadow: inset -1px -1px #fff, inset 1px 1px grey; }
.ct-card-av img { width: 100%; height: 100%; object-fit: cover; }
.ct-card h3 { margin: 4px 0 0; font-size: 16px; }
.ct-sub { margin: 2px 0 10px; color: #555; }
.ct-actions { display: flex; flex-wrap: wrap; justify-content: center; gap: 6px; }
.ct-actions .button-like { min-width: 75px; padding: 4px 10px; }
.ct-note { color: #444; font-size: 11px; margin-top: 10px; }
body.phone .contacts { height: auto; min-height: 50vh; }
body.phone .ct { padding: 8px; }
body.phone .ct-av { width: 40px; height: 40px; border-radius: 50%; }
body.phone .cd-art { display: none; }
.web-page.has-frame { overflow: hidden; display: flex; }
.web-frame { flex: 1; width: 100%; height: 100%; border: 0; display: block; background: #fff; }

/* arcade: per-game controller, no accidental selection */
.win--arcade, .win--arcade *, #arc-cv, .arc-pad, .ph-keys, .ph-np, .ph-home, .ph-call { -webkit-user-select: none; user-select: none; -webkit-touch-callout: none; -webkit-tap-highlight-color: transparent; }
.win--arcade input { -webkit-user-select: text; user-select: text; }
body.phone { -webkit-user-select: none; user-select: none; -webkit-touch-callout: none; }
body.phone input, body.phone textarea, body.phone .notepad, body.phone .bp-body, body.phone .im-log { -webkit-user-select: text; user-select: text; }
.arc-pad button { touch-action: none; }
#arc-mute { min-width: 0; padding: 0 8px; flex: none; }
.arc-top { flex-wrap: nowrap; }
.arc-song { flex: 1; }
.arc-song-go { min-width: 0; padding: 2px 8px; font-weight: bold; }
.arc-hint { margin: 4px 0 0; text-align: center; font: 11px "Courier New", monospace; color: #ff8ad0; }
.arc-hint:empty { display: none; }
.arc-pad { gap: 10px; }
.arc-pad.is-empty { display: none !important; }
.arc-pad.only-ab { justify-content: center; }
.arc-dpad { position: relative; }
.arc-dpad .pu { grid-column: 2; grid-row: 1; } .arc-dpad .pl { grid-column: 1; grid-row: 2; }
.arc-dpad .pr { grid-column: 3; grid-row: 2; } .arc-dpad .pd { grid-column: 2; grid-row: 3; }
.arc-dpad--lr, .arc-dpad--lrd { grid-template-columns: 64px 64px; grid-template-rows: 64px; gap: 10px; }
.arc-dpad--lr .pl, .arc-dpad--lrd .pl { grid-column: 1; grid-row: 1; }
.arc-dpad--lr .pr, .arc-dpad--lrd .pr { grid-column: 2; grid-row: 1; }
.arc-dpad--lrd { grid-template-columns: 56px 56px 56px; }
.arc-dpad--lrd .pd { grid-column: 3; grid-row: 1; }
.arc-dpad button { font-size: 18px; }
.arc-ab { display: flex; gap: 12px; align-items: center; }
.arc-ab button { font-size: 13px !important; letter-spacing: 1px; }
.arc-b { background: radial-gradient(circle at 35% 30%, #9fd2ff, #3b7dff 55%, #12408f) !important; }
.only-ab .arc-ab button { width: 110px; height: 80px; border-radius: 40px; }
body.phone .arc-dpad { grid-template-columns: repeat(3, 58px); grid-template-rows: repeat(3, 50px); }
body.phone .arc-dpad--lr, body.phone .arc-dpad--lrd { grid-template-rows: 64px; }
body.phone .arc-dpad--lr { grid-template-columns: 76px 76px; }
body.phone #arc-cv { width: min(100%, calc((100dvh - 400px) * .75)); }

/* Clubs window */
.win--clubs { width: 720px; height: 560px; }
.win--clubs .clubs-body { margin: 2px; display: flex; }
#clubs-frame { flex: 1; width: 100%; height: 100%; border: 0; background: #0a1a5a; }

/* tray heart */
.tray__heart { min-width: 0; min-height: 0; width: 18px; height: 18px; padding: 0; border: 0; box-shadow: none; background: transparent; display: grid; place-items: center; cursor: pointer; }
.tray__heart svg { width: 14px; height: 14px; }
.tray__heart:hover svg { transform: scale(1.2); }

/* Crush.exe */
.win--crush { width: 340px; }
.crush-body { margin: 2px !important; padding: 10px; background: linear-gradient(#ffe3f3, #f7d1ff); }
.crush-head { display: flex; align-items: baseline; justify-content: space-between; margin-bottom: 8px; }
.crush-head b { font: italic 900 26px "Arial Black", Arial, sans-serif; color: #ff3ea5; text-shadow: 2px 2px 0 #fff, 3px 3px 0 #a8105e; letter-spacing: -1px; }
.crush-head b span { color: #8b5cff; }
.crush-head small { font: 11px "Courier New", monospace; color: #8a2a6a; }
.crush-stage { position: relative; min-height: 430px; }
.crush-card { background: #fff; border: 2px solid #000; box-shadow: 4px 4px 0 #a8105e; touch-action: pan-y; transition: transform .25s, opacity .25s; user-select: none; -webkit-user-select: none; }
.crush-card.dragging { transition: none; }
.crush-card.fly-right { transform: translateX(140%) rotate(22deg) !important; opacity: 0; }
.crush-card.fly-left { transform: translateX(-140%) rotate(-22deg) !important; opacity: 0; }
.crush-pic { position: relative; aspect-ratio: 4 / 5; background: #000; overflow: hidden; }
.crush-pic img { width: 100%; height: 100%; object-fit: cover; display: block; pointer-events: none; }
.crush-dots { position: absolute; top: 6px; left: 6px; right: 6px; display: flex; gap: 4px; }
.crush-dots i { flex: 1; height: 3px; background: rgba(255,255,255,.45); }
.crush-dots i.on { background: #fff; }
.crush-tap { all: unset; position: absolute; top: 0; bottom: 0; width: 40%; cursor: pointer; }
.crush-tap--l { left: 0; } .crush-tap--r { right: 0; }
.crush-stamp { position: absolute; top: 26px; padding: 2px 10px; font: 900 26px Impact, "Arial Black", sans-serif; letter-spacing: 2px; border: 4px solid; opacity: 0; transition: opacity .1s; }
.crush-stamp--yes { left: 14px; color: #2fd06a; border-color: #2fd06a; transform: rotate(-14deg); }
.crush-stamp--no { right: 14px; color: #ff4d4d; border-color: #ff4d4d; transform: rotate(14deg); }
.lean-yes .crush-stamp--yes, .fly-right .crush-stamp--yes { opacity: 1; }
.lean-no .crush-stamp--no, .fly-left .crush-stamp--no { opacity: 1; }
.crush-info { padding: 8px 10px 10px; }
.crush-info h3 { margin: 0; font: bold 18px Verdana, sans-serif; display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.crush-online { font: bold 10px Verdana, sans-serif; color: #2fd06a; }
.crush-meta { margin: 2px 0 6px; color: #8a2a6a; font-size: 11px; }
.crush-bio { margin: 0 0 6px; font-size: 12px; line-height: 1.4; }
.crush-links { display: flex; gap: 10px; flex-wrap: wrap; font-size: 11px; }
.crush-links a { color: #a8105e; font-weight: bold; }
.crush-btns { display: flex; justify-content: center; gap: 26px; margin-top: 10px; }
.crush-btns button { width: 62px; height: 62px; min-width: 0; padding: 0; border-radius: 50%; display: grid; place-items: center; font: bold 26px Arial, sans-serif; border: 2px solid #000; box-shadow: 0 3px 0 #000, inset 0 2px rgba(255,255,255,.6); }
.crush-no { background: linear-gradient(#fff, #e6e6e6); color: #ff4d4d; }
.crush-yes { background: linear-gradient(#ffd0ea, #ff3ea5); }
.crush-yes svg { width: 30px; height: 30px; }
.crush-btns button:active { transform: translateY(2px); box-shadow: 0 1px 0 #000; }
.crush-match, .crush-empty { text-align: center; padding: 30px 10px; }
.crush-match h2 { margin: 0 0 14px; font: italic 900 30px "Arial Black", Arial, sans-serif; color: #ff3ea5; text-shadow: 2px 2px 0 #fff, 4px 4px 0 #8b5cff; animation: crushpop .5s cubic-bezier(.3,1.6,.5,1); }
@keyframes crushpop { from { transform: scale(.4); } }
.crush-pair { display: flex; align-items: center; justify-content: center; gap: 12px; margin-bottom: 12px; }
.crush-pair img, .crush-you { width: 86px; height: 86px; object-fit: cover; border: 3px solid #fff; box-shadow: 0 0 0 2px #ff3ea5; border-radius: 50%; }
.crush-you { display: grid; place-items: center; background: #8b5cff; color: #fff; font: bold 14px Verdana, sans-serif; }
.crush-pair svg { width: 34px; height: 34px; animation: crushbeat .8s ease-in-out infinite; }
@keyframes crushbeat { 50% { transform: scale(1.25); } }
.crush-match-btns { display: flex; flex-direction: column; align-items: center; gap: 6px; }
.crush-empty svg { width: 48px; height: 48px; }
.crush-empty h3 { font: bold 16px Verdana, sans-serif; margin: 8px 0 4px; }
.crush-empty p { margin: 4px 0; color: #8a2a6a; }
body.phone .crush-stage { min-height: 0; }
body.phone .crush-pic { aspect-ratio: auto; height: 44vh; }
