/* ============================================================
   WebAngelz — "edgy Frutiger Aero". Dark neon + scene energy, sharp
   Win98 edges, but glossy gel gradients and glass. Alive & animated.
   ============================================================ */

:root {
  /* --user-accent (set by the theme dialog's colour picker) overrides the accent
     of EVERY theme/skin; falls back to each theme's own default when unset. */
  --accent: var(--user-accent, #00d8ff);   /* neon cyan */
  --accent-ink: #04252e;       /* dark text that sits on the accent */
  --magenta: #ff2d9b;
  --lime: #b6ff3d;
  --ink: #eaf1ff;
  --ink-dim: #96a6c8;
  --link: #64e0ff;
  --win-a: #221a3e;            /* window gradient top */
  --win-b: #150e28;            /* window gradient bottom */
  --line: rgba(0, 216, 255, 0.45);
  --radius: 3px;
  --shadow: 0 18px 44px rgba(0, 0, 0, 0.7), 0 4px 12px rgba(0, 0, 0, 0.45);
  --glow: 0 0 16px rgba(0, 216, 255, 0.45);
  --font: Tahoma, "Segoe UI", Geneva, Verdana, sans-serif;
  --mono: "Lucida Console", Consolas, monospace;

  /* Chrome (taskbar / start menu / tray) skinning — overridden per data-theme.
     Defaults reproduce the original neon "scene" look exactly. */
  --chrome-accent: var(--user-accent, #00d8ff);
  --chrome-text: #e7f4ff;
  --chrome-line: rgba(0, 216, 255, 0.35);
  --tb-bg: linear-gradient(180deg, rgba(42,32,72,0.96), rgba(13,8,32,0.98));
  --tb-border: var(--accent);
  --tb-glow: inset 0 1px 0 rgba(0,216,255,0.4), 0 8px 26px rgba(0,0,0,0.7), 0 0 22px rgba(0,216,255,0.25);
  --tb-radius: 14px;
  --sm-bg: linear-gradient(180deg, #201738, #0e0820);
  --sm-border: var(--accent);
  --sm-band: linear-gradient(180deg, var(--magenta), #6a1bc0 60%, var(--accent));

  /* Corner rounding — flipped by html[data-corners]. Sharp is the Win98 default. */
  --radius-round: 12px;
}

* { box-sizing: border-box; }
html, body { height: 100%; }
html { overflow-x: hidden; }

body {
  margin: 0;
  font-family: var(--font);
  font-size: 13.5px;
  line-height: 1.5;
  color: var(--ink);
  /* Clear the floating taskbar (bottom:10 + height:52) so the last content is
     never stuck underneath it once you've scrolled as far as the page goes. */
  padding-bottom: 96px;
  background:
    repeating-linear-gradient(45deg, rgba(255,255,255,0.015) 0 2px, transparent 2px 7px),
    repeating-linear-gradient(0deg, rgba(0,216,255,0.035) 0 1px, transparent 1px 44px),
    repeating-linear-gradient(90deg, rgba(255,45,155,0.03) 0 1px, transparent 1px 44px),
    linear-gradient(160deg, #0b0718 0%, #150a2a 45%, #0a0716 100%);
  background-attachment: fixed;
}
/* Animated aurora layer behind everything — slow parallax drift. */
.bg-aurora {
  position: fixed; inset: -20% -20% -20% -20%; z-index: -1; pointer-events: none;
  background:
    radial-gradient(40% 40% at 20% 25%, rgba(0,216,255,0.22), transparent 60%),
    radial-gradient(45% 45% at 82% 30%, rgba(255,45,155,0.20), transparent 60%),
    radial-gradient(50% 50% at 55% 85%, rgba(182,255,61,0.14), transparent 60%),
    radial-gradient(40% 40% at 12% 88%, rgba(123,47,247,0.20), transparent 60%);
  filter: blur(30px); animation: auroraDrift 26s ease-in-out infinite alternate;
}
@keyframes auroraDrift {
  0%   { transform: translate(0, 0) scale(1); }
  50%  { transform: translate(3%, 2%) scale(1.08); }
  100% { transform: translate(-3%, -2%) scale(1.04); }
}

a { color: var(--link); text-decoration: none; }
a:hover { text-decoration: underline; }
img { max-width: 100%; display: block; }
h1, h2, h3 { margin: 0 0 .5em; line-height: 1.2; }

.container { width: 100%; max-width: 1320px; margin: 0 auto; padding: 16px 20px; }
.dim { color: var(--ink-dim); }

.skip { position: absolute; left: -9999px; top: 0; background: #000; color: #fff; padding: 6px 12px; z-index: 100; }
.skip:focus { left: 6px; top: 6px; }

/* ===================== Star field ========================= */
.bg-stars { position: fixed; inset: 0; z-index: 0; overflow: hidden; pointer-events: none; }
.twinkle {
  position: absolute; bottom: -40px; color: var(--accent); font-size: 16px; line-height: 1;
  text-shadow: 0 0 8px currentColor; opacity: 0; animation: drift linear infinite;
}
@keyframes drift {
  0% { transform: translateY(0) rotate(0deg) scale(0.6); opacity: 0; }
  12% { opacity: 1; }
  88% { opacity: 1; }
  100% { transform: translateY(-118vh) rotate(240deg) scale(1); opacity: 0; }
}
main.container { position: relative; z-index: 1; }

/* Wallpaper brightness: a black sheet over the backdrop (wallpaper + ambient
   layers), under all windows/chrome. --wp-dim (0–0.95) is set from the
   Appearance dialog's brightness slider. */
.wp-dim { position: fixed; inset: 0; z-index: 1; pointer-events: none; background: #000; opacity: var(--wp-dim, 0); transition: opacity .25s ease; }
.comment-ticker { position: relative; z-index: 2; }   /* stay readable above the dim */

/* ===================== Windows ============================ */
.panel {
  position: relative;
  background: linear-gradient(180deg, var(--win-a), var(--win-b));
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow), inset 0 0 24px rgba(0, 216, 255, 0.05);
  overflow: hidden;
  transition: box-shadow .18s ease;               /* NOT transform — keeps dragging snappy */
  animation: winopen .28s ease both;
}
@keyframes winopen { from { opacity: 0; transform: translateY(10px) scale(0.99); } }
/* Very slight idle "float" so windows never feel dead. Uses the standalone
   `translate` property (NOT `transform`) so it composes with the drag transform
   the window manager writes — dragging still works, the window just gently bobs.
   Staggered (negative delays) so they don't all breathe in unison. */
/* Idle float on the `translate` property so it composes with the drag transform.
   winFloat = gentle (real windows); winFloatStrong = the decorative glare windows,
   which drift more. main.js gives each window a random duration + phase so they
   never bob in sync. */
@keyframes winFloat { 0%, 100% { translate: 0 0; } 50% { translate: 0 -4px; } }
@keyframes winFloatStrong { 0%, 100% { translate: 0 0; } 33% { translate: 3px -9px; } 66% { translate: -3px -13px; } }
/* Intro: each window flies up from a random point along the bottom (--fly-x), like
   a restoring minimized window. `backwards` fill (NOT forwards) so the finished
   animation doesn't pin `transform` — that pin is what broke window dragging. */
@keyframes winFlyIn { from { transform: translate(var(--fly-x, 0), 62vh) scale(0.35); opacity: 0; } to { transform: none; opacity: 1; } }
.panel { animation: winopen .28s ease both, winFloat 7s ease-in-out infinite; }
.panel:nth-child(2n) { animation-delay: 0s, -1.6s; }
.panel:nth-child(3n) { animation-delay: 0s, -3.3s; }
.panel:nth-child(4n) { animation-delay: 0s, -5.1s; }
/* Pause ONLY the idle float while hovering, dragging, resizing or maximized —
   never the fly-in intro, which must finish even if the cursor already sits over
   the window. animation-play-state takes a positional list, and every window runs
   exactly `animation: <intro>, <float>` (from the .panel rule above and from the
   inline shorthand main.js writes), so `running, paused` hits only the float.
   !important beats that inline shorthand; holding the float still is also what
   keeps dragging rock-steady. */
.panel:hover, .panel.dragging, .panel.resizing, .panel.win-max,
.glare-win:hover { animation-play-state: running, paused !important; }
.panel.win-max { translate: none !important; }
@media (prefers-reduced-motion: reduce) { .panel { animation: winopen .28s ease both !important; } }
.panel:hover { box-shadow: var(--shadow), 0 0 20px rgba(0, 216, 255, 0.22), inset 0 0 24px rgba(0, 216, 255, 0.06); }

/* ---- Window highlight ring (shared ::after) -----------------------------
   A bold, deliberately theme-independent colour (white core + magenta) so it
   always stands out. Hovering shows a gentle static ring; clicking a taskbar
   button scrolls to the window and pulses the ring (main.js toggles
   .win-highlight). Inset box-shadow so overflow:hidden never clips it. */
:root { --hl-color: #ff2fd0; }
.panel:hover::after, .panel.win-highlight::after {
  content: ""; position: absolute; inset: 0; border-radius: inherit; pointer-events: none; z-index: 30;
}
.panel:hover::after {
  box-shadow: inset 0 0 0 2px var(--hl-color), inset 0 0 22px color-mix(in srgb, var(--hl-color) 30%, transparent);
}
.panel.win-highlight::after { animation: winHighlight 1.5s ease-out; }
@keyframes winHighlight {
  0%   { box-shadow: inset 0 0 0 0 transparent; }
  15%  { box-shadow: inset 0 0 0 3px #fff, inset 0 0 0 6px var(--hl-color), inset 0 0 44px color-mix(in srgb, var(--hl-color) 60%, transparent); }
  50%  { box-shadow: inset 0 0 0 3px #fff, inset 0 0 0 6px var(--hl-color), inset 0 0 20px color-mix(in srgb, var(--hl-color) 32%, transparent); }
  85%  { box-shadow: inset 0 0 0 3px #fff, inset 0 0 0 6px var(--hl-color), inset 0 0 44px color-mix(in srgb, var(--hl-color) 60%, transparent); }
  100% { box-shadow: inset 0 0 0 0 transparent; }
}
@media (prefers-reduced-motion: reduce) { .panel.win-highlight::after { animation: none; box-shadow: inset 0 0 0 3px var(--hl-color); } }
.panel-title {
  position: relative;
  background: linear-gradient(180deg,
    color-mix(in srgb, var(--accent) 55%, #ffffff) 0%,
    var(--accent) 46%,
    color-mix(in srgb, var(--accent) 62%, #000018) 100%);
  color: var(--accent-ink);
  font-weight: 700; padding: 7px 9px; display: flex; align-items: center; gap: 8px; min-height: 28px;
  border-bottom: 1px solid rgba(0, 0, 0, 0.4);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.7);
  text-shadow: 0 1px 0 rgba(255, 255, 255, 0.35);
  cursor: grab;
}
.panel-title::before {
  content: ""; position: absolute; left: 0; right: 0; top: 0; height: 48%;
  background: linear-gradient(rgba(255, 255, 255, 0.6), rgba(255, 255, 255, 0));
  pointer-events: none;
}
.panel-title > span:first-child { flex: 1; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; position: relative; z-index: 1; }
/* real, clickable min/max/close controls are injected by JS (window manager) */
.panel-title { --tbc-scan: repeating-linear-gradient(180deg, rgba(255,255,255,0.10) 0 1px, transparent 1px 3px); }
.panel-title::after { content: ""; position: absolute; inset: 0; background: var(--tbc-scan); pointer-events: none; opacity: .5; }
.panel-more { color: var(--accent-ink); font-weight: 700; font-size: 12px; position: relative; text-decoration: underline; }
.title-bar-controls { display: flex; gap: 4px; margin-left: auto; position: relative; z-index: 1; }
.title-bar-controls .tb-btn { width: 24px; height: 19px; font-size: 12px; line-height: 1; display: grid; place-items: center; cursor: pointer; text-decoration: none;
  color: #04252e; border: 1px solid rgba(255,255,255,0.6); border-radius: 2px; background: linear-gradient(180deg, #e9ffff, #18b4e2); box-shadow: inset 0 1px 0 rgba(255,255,255,0.8); }
.title-bar-controls .tb-btn:hover { filter: brightness(1.1); }
.title-bar-controls .tb-btn.close { color: #fff; background: linear-gradient(180deg, #ff86d0, #e0359b); }
.panel-inner { padding: 14px; }
.panel-inner a:not(.btn):not(.card):not(.tab):not(.tagpill):not(.mini):not(.byline-user):not(.follow-chip):not(.comment-avatar):not(.guest-avatar) { color: var(--link); }

/* ===================== Taskbar ============================ */
.taskbar {
  position: fixed; left: 10px; right: 10px; bottom: 10px; height: 52px; z-index: 90;
  display: flex; align-items: center; gap: 7px; padding: 0 10px; border-radius: var(--tb-radius);
  background: var(--tb-bg);
  border: 1px solid var(--tb-border);
  box-shadow: var(--tb-glow);
  backdrop-filter: blur(8px);
  color: var(--chrome-text);
}
.tb-start {
  width: 40px; height: 38px; flex: none; padding: 0; cursor: pointer; display: grid; place-items: center;
  border: 1px solid var(--chrome-line); border-radius: var(--radius);
  background: linear-gradient(180deg, #33264f 0%, #1a1030 50%, #120a24 100%);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.25), 0 0 10px rgba(0, 216, 255, 0.35);
  animation: orbpulse 3s ease-in-out infinite;
}
.tb-start:hover { filter: brightness(1.15); box-shadow: inset 0 1px 0 rgba(255,255,255,0.3), 0 0 16px rgba(0,216,255,0.8); }
.tb-start.open { box-shadow: inset 0 2px 5px rgba(0,0,0,0.6); }
@keyframes orbpulse { 50% { box-shadow: inset 0 1px 0 rgba(255,255,255,0.25), 0 0 16px rgba(255,45,155,0.5); } }
.tb-start .flag {
  width: 18px; height: 16px; display: inline-block; border-radius: 2px; filter: drop-shadow(0 0 3px rgba(0,216,255,0.8));
  background:
    linear-gradient(#ff6a9c, #e2357a) 0 0/9px 8px no-repeat,
    linear-gradient(#7fe6ff, #17b4e2) 9px 0/9px 8px no-repeat,
    linear-gradient(#b6ff3d, #7ad012) 0 8px/9px 8px no-repeat,
    linear-gradient(#ffd76a, #f2b400) 9px 8px/9px 8px no-repeat;
}
.tb-divider { width: 1px; align-self: stretch; margin: 8px 2px; background: var(--chrome-line); }
.tb-tasks { display: flex; gap: 5px; flex: 1; overflow: hidden; }
.tb-task {
  display: inline-flex; align-items: center; gap: 7px; min-width: 100px; max-width: 168px; height: 32px; padding: 0 11px;
  color: #e7f4ff; font-size: 12.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
  border: 1px solid rgba(0, 216, 255, 0.35); border-radius: var(--radius);
  background: linear-gradient(180deg, rgba(0, 216, 255, 0.14), rgba(0, 216, 255, 0.03));
  transition: box-shadow .15s, transform .1s;
}
.tb-task:hover { text-decoration: none; box-shadow: 0 0 12px rgba(0, 216, 255, 0.4); transform: translateY(-1px); }
.tb-task.on { background: linear-gradient(180deg, rgba(0, 216, 255, 0.32), rgba(0, 216, 255, 0.1)); box-shadow: inset 0 0 12px rgba(0, 216, 255, 0.4); font-weight: 700; }
.tray {
  display: flex; align-items: center; gap: 9px; height: 32px; padding: 0 10px; color: var(--chrome-text); font-size: 12.5px;
  border: 1px solid var(--chrome-line); border-radius: var(--radius);
  /* Theme-adaptive tint (was a hardcoded dark fill that hid the profile name on
     light themes). A faint accent wash always sits behind the readable chrome text. */
  background: color-mix(in srgb, var(--chrome-accent) 12%, transparent);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.18);
}
.tray-btn { background: none; border: none; cursor: pointer; font-size: 15px; padding: 0; line-height: 1; filter: drop-shadow(0 0 4px rgba(0,216,255,0.5)); }
.tray-user { display: inline-flex; align-items: center; gap: 6px; color: var(--chrome-text); }
.tray-user:hover { text-decoration: none; filter: brightness(1.15); }
.tray-clock { font-variant-numeric: tabular-nums; min-width: 62px; text-align: right; color: var(--chrome-accent); text-shadow: 0 0 6px rgba(0,216,255,0.6); }
.tray-ava { width: 18px; height: 18px; object-fit: cover; border-radius: 2px; box-shadow: 0 0 0 1px var(--chrome-accent); }
.tray-ava-empty { width: 18px; height: 18px; display: grid; place-items: center; border-radius: 2px; background: var(--chrome-accent); color: #04252e; font-size: 11px; font-weight: 700; }

/* ===================== Start menu ========================= */
.startmenu {
  position: fixed; bottom: 70px; left: 14px; width: 300px; z-index: 95; display: none;
  border: 1px solid var(--sm-border); border-radius: var(--radius); overflow: hidden;
  background: var(--sm-bg);
  box-shadow: var(--shadow), 0 0 20px rgba(0, 216, 255, 0.3);
  color: var(--chrome-text);
}
.startmenu.open { display: flex; animation: pop .14s ease; }
@keyframes pop { from { transform: translateY(8px) scale(.98); opacity: 0; } }
.sm-band {
  width: 34px; flex: none; background: var(--sm-band);
  color: #fff; writing-mode: vertical-rl; transform: rotate(180deg);
  text-align: right; font-weight: 800; font-size: 17px; letter-spacing: .5px; padding: 12px 6px;
  text-shadow: 0 0 8px rgba(0,0,0,0.5);
}
.sm-list { flex: 1; padding: 6px; }
/* Shared by <a> links AND <button>s (Add shortcut / Themes / Wallpaper / Log
   Off). Reset the UA button chrome so the button items match the links instead
   of showing a grey system background that's unreadable under a light theme. */
.sm-item { display: flex; align-items: center; gap: 11px; padding: 8px 10px; color: var(--chrome-text); font-size: 13.5px; border: 1px solid transparent; border-radius: var(--radius);
  -webkit-appearance: none; appearance: none; background: none; font-family: inherit; cursor: pointer; text-align: left; }
.sm-item .ico { width: 22px; text-align: center; font-size: 16px; flex: none; }
.sm-item:hover { text-decoration: none; color: #04252e; border-color: rgba(255,255,255,0.4);
  background: linear-gradient(180deg, color-mix(in srgb, var(--chrome-accent) 60%, #fff), var(--chrome-accent)); box-shadow: 0 0 12px color-mix(in srgb, var(--chrome-accent) 40%, transparent); }
.sm-item:hover .dim { color: #04353f; }
.sm-sep { height: 1px; margin: 5px 8px; background: var(--chrome-line); }
.sm-find { padding: 8px 10px; }
.sm-find form { display: flex; gap: 6px; }
.sm-find .input { flex: 1; }

/* ===================== Desktop icons ====================== */
.desktop-icons { display: flex; flex-wrap: wrap; gap: 4px; margin-bottom: 16px; }
.dicon { width: 92px; display: flex; flex-direction: column; align-items: center; gap: 6px; padding: 10px 6px; border-radius: var(--radius); text-align: center; color: #fff; animation: floaty 4s ease-in-out infinite; }
.dicon:nth-child(2n) { animation-delay: -1.3s; }
.dicon:nth-child(3n) { animation-delay: -2.4s; }
@keyframes floaty { 50% { transform: translateY(-6px); } }
.dicon:hover { text-decoration: none; background: rgba(0, 216, 255, 0.12); box-shadow: inset 0 0 0 1px rgba(0, 216, 255, 0.5); }
.dicon-img {
  width: 54px; height: 54px; border-radius: var(--radius); display: grid; place-items: center; font-size: 27px;
  background: linear-gradient(180deg, #2b2150 0%, #191033 48%, #120a26 52%, #221844 100%);
  border: 1px solid rgba(0, 216, 255, 0.55);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.2), 0 0 12px rgba(0, 216, 255, 0.25);
  transition: box-shadow .15s, transform .15s;
}
.dicon:hover .dicon-img { box-shadow: inset 0 1px 0 rgba(255,255,255,0.3), 0 0 18px rgba(0,216,255,0.7); transform: scale(1.06); }
.dicon-label { font-size: 12px; line-height: 1.25; padding: 1px 5px; text-shadow: 0 0 6px rgba(0,216,255,0.7), 0 1px 2px #000; }
.dicon:hover .dicon-label { background: var(--accent); color: #04252e; text-shadow: none; }

/* ===================== Buttons (gel) ====================== */
.btn {
  position: relative; display: inline-block; font-family: var(--font); font-size: 13px; font-weight: 600; color: #eaf1ff;
  padding: 7px 15px; cursor: pointer; text-align: center; border-radius: var(--radius);
  border: 1px solid rgba(0, 216, 255, 0.5);
  background: linear-gradient(180deg, #352a55, #1c1338);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.14), 0 2px 6px rgba(0, 0, 0, 0.5);
  overflow: hidden; transition: transform .1s, box-shadow .15s, filter .15s;
}
.btn::before { content: ""; position: absolute; left: 0; right: 0; top: 0; height: 46%; background: linear-gradient(rgba(255,255,255,0.22), rgba(255,255,255,0)); pointer-events: none; }
.btn:hover { text-decoration: none; transform: translateY(-2px); box-shadow: inset 0 1px 0 rgba(255,255,255,0.16), 0 6px 14px rgba(0,0,0,0.55), 0 0 14px rgba(0,216,255,0.45); }
.btn:active { transform: translateY(1px); box-shadow: inset 0 2px 5px rgba(0,0,0,0.6); }
.btn:focus-visible { outline: 2px solid var(--accent); outline-offset: 1px; }
.btn-primary { color: #fff; border-color: #ff5cb4; text-shadow: 0 -1px 0 rgba(0,0,0,0.3);
  background: linear-gradient(180deg, #ff7ec8, #ff2d9b 52%, #cf1580); }
.btn-primary:hover { box-shadow: inset 0 1px 0 rgba(255,255,255,0.3), 0 6px 14px rgba(0,0,0,0.55), 0 0 16px rgba(255,45,155,0.6); }
.btn-block { display: block; width: 100%; }
.btn-sm { padding: 4px 11px; font-size: 12px; }

.linkbtn { background: none; border: none; color: var(--link); cursor: pointer; font: inherit; padding: 0; text-decoration: underline; }
.linkbtn:hover { color: var(--magenta); }
.linkbtn.danger { color: #ff6b8a; }
.linkbtn.tiny { font-size: 12px; }
.inline { display: inline; margin: 0; }

/* ===================== Forms ============================== */
.stack { display: grid; gap: 13px; }
.field { display: grid; gap: 5px; }
.field > span { font-weight: 700; }
.input {
  width: 100%; font-family: var(--font); font-size: 13.5px; color: #eaf1ff;
  background: #141026; border: 1px solid rgba(0, 216, 255, 0.3); border-radius: var(--radius); padding: 8px 10px;
  box-shadow: inset 0 1px 4px rgba(0, 0, 0, 0.5);
}
.input::placeholder { color: #7f8db0; }
.input:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 2px rgba(0, 216, 255, 0.3), inset 0 1px 4px rgba(0, 0, 0, 0.5); }
textarea.input, .textarea { resize: vertical; line-height: 1.45; }
.hint { color: var(--ink-dim); font-weight: 400; font-size: 12px; }
.formerrors { background: rgba(60, 12, 30, 0.7); border: 1px solid #ff6b8a; border-radius: var(--radius); padding: 9px 12px; margin-bottom: 13px; color: #ffb3c4; display: grid; gap: 3px; font-size: 13px; }
.authswitch { text-align: center; margin: 13px 0 0; color: var(--ink-dim); }
.authwrap { display: grid; place-items: center; padding: 26px 0; }
.authcard { width: 100%; max-width: 400px; }

/* ===================== Flash ============================== */
.flash { margin: 4px 0 16px; padding: 10px 13px; display: flex; gap: 8px; align-items: center; border-radius: var(--radius); font-size: 13px; font-weight: 600;
  background: rgba(0, 60, 80, 0.55); border: 1px solid var(--accent); color: #bff2ff; box-shadow: 0 0 14px rgba(0,216,255,0.25); }
.flash::before { content: "✓"; }
.flash-bad { background: rgba(70, 12, 34, 0.6); border-color: #ff6b8a; color: #ffc0cf; box-shadow: 0 0 14px rgba(255,45,155,0.25); }
.flash-bad::before { content: "!"; }

/* ===================== Marquee ============================ */
.marquee { overflow: hidden; white-space: nowrap; border: 1px solid var(--line); border-radius: var(--radius); padding: 6px 0; margin-bottom: 16px;
  background: linear-gradient(180deg, #1a1234, #0c0820); color: var(--accent); font-family: var(--mono); font-size: 12px; text-shadow: 0 0 6px rgba(0,216,255,0.5); box-shadow: inset 0 0 16px rgba(0,216,255,0.1); }
.marquee-track { display: inline-block; animation: scroll 40s linear infinite; }
.marquee:hover .marquee-track { animation-play-state: paused; }
.marquee-item { padding: 0 24px; }
@keyframes scroll { from { transform: translateX(0); } to { transform: translateX(-50%); } }

/* ===================== Layout ============================= */
.layout { display: grid; grid-template-columns: 1fr 262px; gap: 16px; align-items: start; }
.content { display: grid; gap: 16px; min-width: 0; }
.sidebar { display: grid; gap: 16px; }

/* ===================== Grid / cards ======================= */
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(158px, 1fr)); gap: 12px; }
/* cards are always dark tiles — keep their text theme-independent */
.card { display: flex; flex-direction: column; color: #eef3ff; border-radius: var(--radius); overflow: hidden;
  background: linear-gradient(180deg, #221a3e, #150e28); border: 1px solid rgba(0, 216, 255, 0.28); box-shadow: 0 4px 12px rgba(0,0,0,0.45);
  transition: transform .14s ease, box-shadow .14s ease, border-color .14s; }
.card:hover { text-decoration: none; transform: translateY(-5px); border-color: var(--accent); box-shadow: 0 12px 24px rgba(0,0,0,0.55), 0 0 18px rgba(0,216,255,0.4); }
.card-thumb { position: relative; aspect-ratio: 1/1; background: #06040e; overflow: hidden; display: grid; place-items: center; }
.card-thumb img, .card-thumb video { width: 100%; height: 100%; object-fit: cover; }
.card-thumb::after { content: ""; position: absolute; inset: 0; background: linear-gradient(rgba(255,255,255,0.16), rgba(255,255,255,0) 42%); pointer-events: none; }
.badge-new { position: absolute; top: 6px; left: 6px; z-index: 2; color: #fff; font-size: 10px; font-weight: 800; letter-spacing: .5px; padding: 2px 7px;
  background: var(--magenta); box-shadow: 0 0 10px rgba(255,45,155,0.8); }
.card-type { position: absolute; bottom: 6px; right: 6px; z-index: 2; background: rgba(0,0,0,0.7); color: var(--accent); font-family: var(--mono); font-size: 10px; padding: 1px 5px; border: 1px solid rgba(0,216,255,0.4); }
.play, .play-sm { position: absolute; inset: 0; margin: auto; width: 42px; height: 42px; display: grid; place-items: center; background: rgba(0,0,0,0.5); color: var(--accent); border: 1px solid var(--accent); font-size: 15px; pointer-events: none; box-shadow: 0 0 12px rgba(0,216,255,0.5); }
.play-sm { width: 24px; height: 24px; font-size: 9px; }
.card-body { padding: 8px 10px 10px; display: flex; flex-direction: column; gap: 3px; }
.card-title { font-size: 12.5px; font-weight: 700; line-height: 1.25; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.card-author { font-size: 11.5px; color: #9fb0d0; }
.card-meta { display: flex; gap: 9px; font-size: 11.5px; color: #9fb0d0; margin-top: 2px; flex-wrap: wrap; }
.stars-mini { color: #ffcf33; letter-spacing: -1px; text-shadow: 0 0 5px rgba(255,207,51,0.5); }
.stars-mini .dim { color: rgba(255,255,255,0.18); text-shadow: none; }

/* ===================== Decorative "glare" windows ========== */
/* Only meaningful where there's empty gutter space beside the centered layout. */
.desktop-decor { display: none; }
@media (min-width: 1450px) { .desktop-decor { display: block; } }
.glare-win {
  position: fixed; z-index: 0; pointer-events: none; border-radius: var(--radius); overflow: hidden;
  border: 1px solid color-mix(in srgb, var(--accent) 35%, rgba(255,255,255,0.25));
  background:
    linear-gradient(135deg, rgba(255,255,255,0.14), rgba(255,255,255,0.02) 42%, transparent 62%),
    linear-gradient(180deg, color-mix(in srgb, var(--accent) 16%, transparent), rgba(0,0,0,0.14));
  box-shadow: var(--shadow), inset 0 1px 0 rgba(255,255,255,0.3);
  opacity: 0.7;
  animation: winFloatStrong 9s ease-in-out infinite;
}
/* fake glossy title bar */
.glare-win::after { content: ""; position: absolute; top: 0; left: 0; right: 0; height: 20px;
  background: linear-gradient(180deg, color-mix(in srgb, var(--accent) 60%, #fff), var(--accent)); opacity: .5; }
/* diagonal light sweep = the "glare" */
.glare-win::before { content: ""; position: absolute; top: -50%; width: 55%; height: 200%; left: -70%;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,0.4), transparent); transform: rotate(18deg);
  animation: glareSweep 7s ease-in-out infinite; }
@keyframes glareSweep { 0% { left: -70%; } 55%, 100% { left: 135%; } }
@media (prefers-reduced-motion: reduce) { .glare-win { animation: none; } .glare-win::before { animation: none; } }

/* ===================== Home: top forum + new members ====== */
.mini-forum { list-style: none; margin: 0; padding: 0; display: grid; gap: 9px; }
.mini-forum li { display: flex; flex-direction: column; gap: 1px; padding-bottom: 8px; border-bottom: 1px solid rgba(0,216,255,0.13); }
.mini-forum li:last-child { border-bottom: none; padding-bottom: 0; }
.mini-forum-title { font-weight: 700; font-size: 13.5px; color: var(--ink); }
.mini-forum-title:hover { color: var(--link); }
.mini-forum-meta { font-size: 12px; color: var(--ink-dim); display: inline-flex; align-items: center; gap: 5px; }
.mini-forum-meta .ico { width: 12px; height: 12px; }
.member-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.member-row { display: flex; align-items: center; gap: 9px; color: var(--ink); }
.member-row:hover { text-decoration: none; }
.member-row:hover .member-name { color: var(--link); }
.member-row img, .member-row .avatar-empty { width: 34px; height: 34px; border-radius: 8px; object-fit: cover; box-shadow: 0 0 0 1px rgba(0,216,255,0.5); flex: none; }
.member-row .avatar-empty { display: grid; place-items: center; background: var(--accent); color: #04252e; font-weight: 800; }
.member-info { display: flex; flex-direction: column; min-width: 0; }
.member-name { font-weight: 700; font-size: 13px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.member-when { font-size: 11.5px; color: var(--ink-dim); }
.mod-dot { color: #ff8a3c; }

/* ===================== Sidebar bits ======================= */
.statlist { list-style: none; margin: 0; padding: 0; display: grid; gap: 7px; }
.statlist li { display: flex; justify-content: space-between; padding-bottom: 6px; border-bottom: 1px solid rgba(0,216,255,0.15); }
.statlist li span:last-child { font-weight: 700; color: var(--accent); text-shadow: 0 0 6px rgba(0,216,255,0.5); }
.rules { margin: 0; padding-left: 18px; display: grid; gap: 5px; }
.sidebar-cta { text-align: center; display: grid; gap: 8px; }
.sidebar-cta p { margin: 0; font-weight: 700; }

/* ===================== Empty states ======================= */
.empty { text-align: center; padding: 28px 14px; display: grid; gap: 10px; justify-items: center; color: var(--ink-dim); }
.empty p { margin: 0; }
.empty-sm { color: var(--ink-dim); text-align: center; padding: 12px; }

/* ===================== Tabs =============================== */
.tabs { display: flex; gap: 4px; padding: 0 4px; margin-bottom: -1px; position: relative; z-index: 2; }
.tab { color: #eaf1ff; padding: 6px 14px; font-size: 12.5px; border: 1px solid rgba(0,216,255,0.4); border-bottom: none; border-radius: var(--radius) var(--radius) 0 0;
  background: linear-gradient(180deg, #2a2048, #1a1030); }
.tab:hover { text-decoration: none; box-shadow: 0 0 10px rgba(0,216,255,0.35); }
.tab.on { font-weight: 700; color: var(--accent-ink); background: linear-gradient(180deg, color-mix(in srgb, var(--accent) 55%, #fff), var(--accent)); }
.tab-clear { color: var(--magenta); }
.tabbody { border: 1px solid rgba(0,216,255,0.4); border-radius: 0 var(--radius) var(--radius) var(--radius); background: linear-gradient(180deg, #1c1436, #130c26); padding: 14px; color: #eaf1ff; }
.tabbody .dim { color: #93a4c4; }
.pager { display: flex; align-items: center; justify-content: center; gap: 12px; margin-top: 18px; }
.pager-pos { color: var(--ink-dim); font-size: 12.5px; }
.tagpill { display: inline-block; padding: 3px 11px; font-size: 12px; color: var(--accent); border-radius: var(--radius); border: 1px solid rgba(0,216,255,0.45);
  background: linear-gradient(180deg, rgba(0,216,255,0.14), rgba(0,216,255,0.03)); }
.tagpill:hover { text-decoration: none; box-shadow: 0 0 10px rgba(0,216,255,0.4); }

/* ===================== Upload ============================= */
.uploadpanel { max-width: 620px; margin: 0 auto; }
.dropzone { position: relative; background: rgba(0,0,0,0.3); border: 2px dashed rgba(0,216,255,0.5); border-radius: var(--radius); min-height: 160px; display: grid; place-items: center; text-align: center; }
.dropzone.drag { background: rgba(0,216,255,0.08); border-color: var(--accent); box-shadow: inset 0 0 20px rgba(0,216,255,0.2); }
.dropzone input[type=file] { position: absolute; inset: 0; opacity: 0; cursor: pointer; }
.dropzone-inner { padding: 22px; color: #b9c6e0; pointer-events: none; }
.dropzone-icon { font-size: 32px; margin-bottom: 6px; }
.dropzone-preview { padding: 14px; width: 100%; }
.dropzone-preview img, .dropzone-preview video { max-height: 320px; margin: 0 auto; border: 1px solid rgba(0,216,255,0.4); }
.dropzone-preview .fname { margin-top: 8px; font-family: var(--mono); font-size: 12px; color: var(--ink-dim); }

/* ===================== Post page ========================== */
.postpage { display: grid; grid-template-columns: 1fr 250px; gap: 16px; align-items: start; }
.postmain { display: grid; gap: 16px; min-width: 0; }
.postside { display: grid; gap: 16px; }
.win-media .panel-title::after { display: none; }
.title-bar-controls { display: flex; gap: 4px; margin-left: auto; position: relative; }
.tb-btn { width: 26px; height: 20px; font-size: 12px; line-height: 1; color: #04252e; display: grid; place-items: center; cursor: pointer; text-decoration: none;
  border: 1px solid rgba(255,255,255,0.6); background: linear-gradient(180deg, #e9ffff, #18b4e2); box-shadow: inset 0 1px 0 rgba(255,255,255,0.8); }
.tb-btn:hover { filter: brightness(1.08); text-decoration: none; }
.tb-btn.close { color: #fff; background: linear-gradient(180deg, #ff86d0, #e0359b); }
.stage { display: grid; place-items: center; padding: 6px; background: radial-gradient(circle at 50% 40%, #10132e, #05060f); min-height: 220px; }
.stage-media { width: auto; height: auto; max-width: 100%; max-height: 84vh; object-fit: contain; background: #05060f; box-shadow: 0 0 24px rgba(0,216,255,0.25); }
/* a video with a poster adopts the poster's size immediately — no black collapse */
.win-media.minimized .stage { display: none; }
.win-media.maximized .stage-media { max-height: 88vh; }
.post-title { font-size: 20px; }
.post-byline { display: flex; align-items: center; gap: 9px; flex-wrap: wrap; color: var(--ink-dim); }
.byline-user { display: inline-flex; align-items: center; gap: 7px; color: var(--ink); font-weight: 700; }
.byline-user:hover { text-decoration: none; }
.avatar-sm { width: 30px; height: 30px; object-fit: cover; border-radius: 2px; box-shadow: 0 0 0 1px var(--accent); background: #06040e; }
.avatar-empty { display: grid; place-items: center; background: linear-gradient(180deg, #7fe6ff, #17b4e2); color: #04252e; font-weight: 800; }
.post-delete { margin-left: auto; }
.post-desc { margin-top: 14px; word-wrap: break-word; }
.tagrow { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 14px; }
.rate-box { display: flex; align-items: center; gap: 20px; flex-wrap: wrap; }
.rate-score { display: flex; align-items: baseline; gap: 4px; }
.rate-avg { font-size: 34px; font-weight: 800; color: var(--accent); text-shadow: 0 0 12px rgba(0,216,255,0.5); }
.rate-outof { color: var(--ink-dim); }
.rate-count { color: var(--ink-dim); font-size: 12.5px; margin-left: 6px; align-self: center; }
.rate-stars { display: inline-flex; gap: 2px; }
.rate-stars .star { background: none; border: none; cursor: pointer; font-size: 28px; line-height: 1; color: rgba(255,255,255,0.2); padding: 0 1px; transition: transform .08s; }
.rate-stars .star.set, .rate-stars .star.hot { color: #ffcf33; text-shadow: 0 0 10px rgba(255,207,51,0.7); }
.rate-stars:not(.readonly) .star:hover { transform: scale(1.2); }
.rate-stars.readonly .star { cursor: default; font-size: 23px; }
.commentform { display: grid; gap: 9px; margin-bottom: 18px; }
.commentform .btn { justify-self: start; }
.loginnote { color: var(--ink-dim); padding: 6px 0 14px; }
.comments { list-style: none; margin: 0; padding: 0; display: grid; gap: 13px; }
.comment { display: flex; gap: 10px; padding-top: 13px; border-top: 1px solid rgba(0,216,255,0.15); }
.comment:first-child { border-top: none; padding-top: 0; }
.comment-avatar img, .comment-avatar .avatar-empty { width: 36px; height: 36px; object-fit: cover; border-radius: 2px; box-shadow: 0 0 0 1px rgba(0,216,255,0.5); }
.comment-body { flex: 1; min-width: 0; }
.comment-head a { color: var(--ink); }
.comment-text { word-wrap: break-word; }
.mini-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; margin-bottom: 12px; }
.mini { position: relative; aspect-ratio: 1/1; overflow: hidden; background: #06040e; border: 1px solid rgba(0,216,255,0.3); }
.mini img, .mini video { width: 100%; height: 100%; object-fit: cover; }
.mini:hover { border-color: var(--accent); box-shadow: 0 0 12px rgba(0,216,255,0.4); }
.followrow { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }

/* ===================== Profile =========================== */
.profilepage { display: grid; gap: 16px; }
.profile-head { display: flex; align-items: center; gap: 16px; flex-wrap: wrap; }
.profile-avatar { width: 80px; height: 80px; object-fit: cover; border-radius: var(--radius); background: #06040e; flex: none; box-shadow: 0 0 0 1px var(--accent), 0 0 18px rgba(0,216,255,0.4); }
.profile-avatar-empty { display: grid; place-items: center; font-size: 34px; font-weight: 800; color: #04252e; background: linear-gradient(180deg, #7fe6ff, #17b4e2); }
.profile-id h1 { font-size: 22px; }
.you-badge { font-size: 11px; background: var(--lime); color: #143000; padding: 2px 8px; border-radius: var(--radius); font-weight: 700; box-shadow: 0 0 10px rgba(182,255,61,0.5); }
.mod-badge { font-size: 11px; font-weight: 800; letter-spacing: .5px; display: inline-flex; align-items: center; gap: 3px; vertical-align: middle;
  background: linear-gradient(180deg, #ff9a3c, #e0561f); color: #fff; padding: 2px 9px; border-radius: var(--radius); box-shadow: 0 0 10px rgba(255,90,20,0.55); text-shadow: 0 1px 0 rgba(0,0,0,0.25); }
.mod-badge .ico { width: 12px; height: 12px; }
.profile-tags { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 9px; }
.ptag { font-size: 12px; padding: 3px 11px; border-radius: 12px; color: var(--accent);
  background: rgba(0,216,255,0.12); border: 1px solid rgba(0,216,255,0.35); }
.profile-since { color: var(--ink-dim); font-size: 12.5px; }
.profile-stats { display: flex; gap: 16px; margin-top: 5px; font-size: 13px; flex-wrap: wrap; }
.profile-stats b { color: var(--accent); }
.profile-actions { margin-left: auto; display: flex; gap: 8px; align-items: center; }
.profile-bio { margin-top: 12px; background: rgba(0,0,0,0.32); border: 1px solid rgba(0,216,255,0.2); border-radius: var(--radius); padding: 12px; color: #e8eefc; }
.guestform { display: grid; gap: 9px; margin-bottom: 18px; }
.guestform .btn { justify-self: start; }
.guestlist { list-style: none; margin: 0; padding: 0; display: grid; gap: 12px; }
.guestentry { display: flex; gap: 10px; padding-top: 12px; border-top: 1px solid rgba(0,216,255,0.15); }
.guestentry:first-child { border-top: none; padding-top: 0; }
.guest-avatar img, .guest-avatar .avatar-empty { width: 34px; height: 34px; object-fit: cover; border-radius: 2px; box-shadow: 0 0 0 1px rgba(0,216,255,0.5); }
.guest-body { flex: 1; min-width: 0; }
.guest-text { word-wrap: break-word; }

/* ===================== Feed ============================== */
.followers-strip { display: flex; gap: 14px; flex-wrap: wrap; }
.follow-chip { display: inline-flex; flex-direction: column; align-items: center; gap: 4px; width: 68px; text-align: center; color: var(--ink); }
.follow-chip:hover { text-decoration: none; }
.follow-chip:hover img, .follow-chip:hover .avatar-empty { box-shadow: 0 0 0 1px var(--accent), 0 0 14px rgba(0,216,255,0.6); }
.follow-chip img, .follow-chip .avatar-empty { width: 48px; height: 48px; object-fit: cover; border-radius: var(--radius); box-shadow: 0 0 0 1px rgba(0,216,255,0.5); transition: box-shadow .15s; }
.follow-chip-name { font-size: 12px; max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* ===================== Settings ========================== */
.settingspanel { max-width: 560px; margin: 0 auto; }
.avatar-edit { display: flex; gap: 16px; align-items: flex-start; }
.avatar-preview { width: 80px; height: 80px; object-fit: cover; border-radius: var(--radius); background: #06040e; font-size: 32px; font-weight: 800; flex: none; display: grid; place-items: center; color: #04252e; box-shadow: 0 0 0 1px var(--accent); }
.avatar-field { flex: 1; }
.colorrow { display: flex; align-items: center; gap: 10px; }
.colorrow input[type=color] { width: 46px; height: 30px; border: 1px solid rgba(0,216,255,0.4); border-radius: var(--radius); background: none; cursor: pointer; padding: 2px; }
.colorrow code { font-family: var(--mono); color: var(--ink-dim); }

/* ===================== Error ============================= */
.errorpanel { max-width: 460px; margin: 34px auto; }
.error-inner { display: flex; gap: 16px; align-items: center; padding: 22px; }
.error-code { font-size: 44px; font-weight: 800; color: var(--accent); text-shadow: 0 0 14px rgba(0,216,255,0.5); flex: none; }
.error-msg { margin: 0 0 12px; }

/* ===================== Wordmark ========================== */
.wordmark { font-weight: 800; letter-spacing: -.5px; color: var(--accent); text-shadow: 0 0 10px rgba(0,216,255,0.5); }

/* ===================== Responsive ======================== */
@media (max-width: 860px) {
  .layout, .postpage { grid-template-columns: 1fr; }
}
@media (max-width: 520px) {
  .grid { grid-template-columns: repeat(auto-fill, minmax(120px, 1fr)); }
  .tb-task span { display: none; }
  .tb-task { min-width: 0; }
  .startmenu { width: calc(100vw - 16px); }
}
@media (prefers-reduced-motion: reduce) {
  .marquee-track, .twinkle, #boot .boot-bar i, .dicon, .tb-start, .panel, .startmenu.open, .deco span { animation: none; }
  .card, .btn, .dicon-img { transition: none; }
}

/* ============================================================
   MIX-AND-MATCH: classic Windows 98 window skin (.win98)
   Classic navy header + beveled sharp frame; keeps the dark body.
   ============================================================ */
.panel.skin-win98 {
  border-radius: 0; border: 1px solid #000;
  box-shadow: 3px 3px 0 rgba(0,0,0,0.5), inset 1px 1px 0 rgba(255,255,255,0.16), inset -1px -1px 0 rgba(0,0,0,0.75);
}
.panel.skin-win98 .panel-title {
  border-radius: 0; cursor: grab; --tbc-scan: none;
  background: linear-gradient(90deg, #0a1e8f 0%, #1a63c8 60%, #2f97e0 100%);
  color: #fff; text-shadow: none; border-bottom: 1px solid #000;
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.35);
  font-weight: 700; letter-spacing: .3px;
}
.panel.skin-win98 .panel-title::before, .panel.skin-win98 .panel-title::after { display: none; }
.panel.skin-win98 .panel-more { color: #cfe0ff; }
.panel.skin-win98 .title-bar-controls .tb-btn {
  color: #000; background: #c0c0c0; border: 1px solid; border-color: #fff #000 #000 #fff; border-radius: 0;
  box-shadow: inset -1px -1px 0 #808080, inset 1px 1px 0 #dfdfdf;
}
.panel.skin-win98 .title-bar-controls .tb-btn:active { border-color: #000 #fff #fff #000; }

/* ============================================================
   TEXTURE — hatch on scene bodies, scanlines on media, dot grid
   ============================================================ */
.panel:not(.skin-win98):not(.skin-frutiger):not(.skin-ethereal):not(.skin-oldweb) .panel-inner {
  background-image: repeating-linear-gradient(135deg, rgba(255,255,255,0.016) 0 2px, transparent 2px 6px);
}
.stage { position: relative; }
.stage::after { content: ""; position: absolute; inset: 0; pointer-events: none;
  background: repeating-linear-gradient(180deg, rgba(0,0,0,0.22) 0 1px, transparent 1px 3px); }
.bg-stars::before { content: ""; position: absolute; inset: 0;
  background-image: radial-gradient(rgba(255,255,255,0.09) 1px, transparent 1.6px); background-size: 26px 26px; opacity: .45; }
.bg-stars::after { content: ""; position: absolute; inset: 0; opacity: .06; mix-blend-mode: overlay;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.8' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  background-size: 220px 220px; }

/* ============================================================
   WALLPAPER presets (html[data-wp="..."]) — default is scene
   ============================================================ */
html[data-wp="aero"] body { background: radial-gradient(120% 90% at 50% -18%, rgba(255,255,255,0.85), transparent 55%), linear-gradient(180deg, #7fc5ff 0%, #cbeffb 46%, #b9edcf 70%, #86d46a 100%); background-attachment: fixed; }
html[data-wp="bliss"] body { background: linear-gradient(180deg, #2f7ff0 0%, #86b7ff 42%, #57b657 52%, #1f7a1f 100%); background-attachment: fixed; }
html[data-wp="teal98"] body { background: #10807f; }
html[data-wp="sunset"] body { background: linear-gradient(180deg, #2a0b3f 0%, #7a1e5a 45%, #ff7a3c 100%); background-attachment: fixed; }
html[data-wp="vapor"] body { background: linear-gradient(180deg, #2b1055 0%, #7b2ff7 42%, #f857a6 100%); background-attachment: fixed; }
html[data-wp="matrix"] body { background: radial-gradient(circle at 50% 28%, #0a2a12, #020a05 75%); background-attachment: fixed; }

/* ============================================================
   Taskbar: minimized-window buttons + maximize state
   ============================================================ */
.tb-tasks { flex: 0 1 auto; }
.tb-min { display: flex; gap: 5px; align-items: center; flex: 1; overflow: hidden; }
.min-btn { display: inline-flex; align-items: center; gap: 6px; height: 30px; max-width: 160px; padding: 0 10px; color: #d3ecff; font-size: 12px; cursor: pointer;
  border: 1px solid rgba(0,216,255,0.35); border-radius: var(--radius); white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
  background: linear-gradient(180deg, rgba(0,216,255,0.10), rgba(0,0,0,0.25)); }
.min-btn:hover { box-shadow: 0 0 10px rgba(0,216,255,0.45); }
.min-btn::before { content: "▣"; color: var(--accent); }

.panel.win-max {
  /* Sit above the sticky top banner (z-index 80) so the title-bar controls are
     never covered — but stay BELOW the start menu (95), notifications (96) and
     the modal pickers (200/300) so that OS chrome still works over a maximized
     window. !important defeats the inline style.zIndex that focusWin() writes on
     every pointerdown (that inline value is what used to bury the controls). */
  position: fixed !important; inset: 12px 12px 58px 12px; z-index: 85 !important; margin: 0 !important;
  transform: none !important; display: flex; flex-direction: column; max-width: none;
}
.panel.win-max > .panel-inner, .panel.win-max > .stage { flex: 1; overflow: auto; }
.panel.win-max .stage-media { max-height: 100%; }
.win-hidden { display: none !important; }

/* ============================================================
   Wallpaper picker (floating dialog)
   ============================================================ */
.picker-overlay { position: fixed; inset: 0; z-index: 200; display: none; align-items: center; justify-content: center; background: rgba(0,0,0,0.55); backdrop-filter: blur(2px); }
.picker-overlay.open { display: flex; }
.picker { width: min(480px, 92vw); }
.swatches { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.swatch { height: 66px; border: 2px solid rgba(255,255,255,0.35); border-radius: var(--radius); cursor: pointer; position: relative; overflow: hidden; }
.swatch:hover { border-color: var(--accent); }
.swatch.sel { border-color: var(--accent); box-shadow: 0 0 12px var(--accent); }
.swatch span { position: absolute; left: 0; right: 0; bottom: 0; background: rgba(0,0,0,0.6); color: #fff; font-size: 11px; text-align: center; padding: 2px; }
.sw-needy { background: #e3d9f4 url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='48' height='26' viewBox='0 0 48 26'%3E%3Cpath d='M0 13 Q 12 3 24 13 T 48 13' fill='none' stroke='%23cbd2f0' stroke-width='2'/%3E%3C/svg%3E") repeat; background-size: 24px 13px; }
.sw-scene { background: linear-gradient(160deg, #0b0718, #150a2a); }
.sw-aero { background: linear-gradient(180deg, #7fc5ff, #cbeffb 55%, #86d46a); }
.sw-bliss { background: linear-gradient(180deg, #2f7ff0, #86b7ff 45%, #1f7a1f); }
.sw-teal98 { background: #10807f; }
.sw-sunset { background: linear-gradient(180deg, #2a0b3f, #7a1e5a 45%, #ff7a3c); }
.sw-vapor { background: linear-gradient(180deg, #2b1055, #7b2ff7 45%, #f857a6); }
.sw-matrix { background: radial-gradient(circle at 50% 30%, #0a2a12, #020a05); }

/* ============================================================
   MySpace-style animated profile decorations
   ============================================================ */
.deco { position: fixed; inset: 0; z-index: 40; pointer-events: none; overflow: hidden; }
.deco span { position: absolute; bottom: -32px; font-size: 18px; opacity: 0; line-height: 1;
  animation-name: decofloat; animation-timing-function: linear; animation-iteration-count: infinite; text-shadow: 0 0 8px currentColor; }
@keyframes decofloat {
  0% { transform: translateY(0) rotate(0deg) scale(.7); opacity: 0; }
  12% { opacity: 1; }
  88% { opacity: 1; }
  100% { transform: translateY(-108vh) rotate(220deg) scale(1); opacity: 0; }
}
.deco-stars span { color: #7fd0ff; }
.deco-hearts span { color: #ff6ab0; }
.deco-sparkle span { color: #cf9bff; }
.deco-glitter span { color: #ffe37a; font-size: 15px; }

/* profile header glitter shimmer for decorated pages */
.profile-decorated .profile-avatar { animation: glitterpulse 2.4s ease-in-out infinite; }
@keyframes glitterpulse { 50% { box-shadow: 0 0 0 1px var(--accent), 0 0 26px rgba(0,216,255,0.7); } }

/* ============================================================
   Infinite scroll loader
   ============================================================ */
.infinite-sentinel { height: 1px; }
.infinite-status { text-align: center; color: var(--ink-dim); padding: 14px; font-size: 12.5px; }
.infinite-status .spin { display: inline-block; width: 16px; height: 16px; border: 2px solid rgba(0,216,255,0.3); border-top-color: var(--accent); border-radius: 50%; animation: spin .8s linear infinite; vertical-align: middle; margin-right: 6px; }
@keyframes spin { to { transform: rotate(360deg); } }

/* ============================================================
   Taskbar: quick-launch + live window list (open windows)
   ============================================================ */
.tb-quick { display: flex; gap: 3px; align-items: center; }
.ql { width: 32px; height: 32px; display: grid; place-items: center; font-size: 16px; border-radius: var(--radius); border: 1px solid transparent; color: var(--chrome-text); }
.ql:hover { text-decoration: none; background: color-mix(in srgb, var(--chrome-accent) 16%, transparent); border-color: var(--chrome-line); box-shadow: 0 0 8px color-mix(in srgb, var(--chrome-accent) 40%, transparent); }
.ql.on { background: color-mix(in srgb, var(--chrome-accent) 22%, transparent); border-color: var(--chrome-line); }
.tb-windows { display: flex; gap: 5px; align-items: center; flex: 1; overflow-x: auto; overflow-y: hidden; }
.tb-windows::-webkit-scrollbar { height: 0; }
.win-task { display: inline-flex; align-items: center; gap: 6px; height: 32px; min-width: 84px; max-width: 170px; padding: 0 11px; color: var(--chrome-text); font-size: 12.5px; cursor: pointer;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis; flex: 0 0 auto;
  border: 1px solid var(--chrome-line); border-radius: var(--radius);
  background: linear-gradient(180deg, color-mix(in srgb, var(--chrome-accent) 14%, transparent), rgba(0,0,0,0.22)); }
.win-task:hover { box-shadow: 0 0 10px color-mix(in srgb, var(--chrome-accent) 40%, transparent); }
.win-task.active { background: linear-gradient(180deg, color-mix(in srgb, var(--chrome-accent) 34%, transparent), color-mix(in srgb, var(--chrome-accent) 10%, transparent)); box-shadow: inset 0 0 12px color-mix(in srgb, var(--chrome-accent) 40%, transparent); font-weight: 700; }
.win-task.min { opacity: .55; }
.win-task .wt-ico { flex: none; }

/* ============================================================
   Desktop right-click context menu
   ============================================================ */
.ctxmenu { position: fixed; z-index: 300; min-width: 194px; margin: 0; padding: 3px; list-style: none;
  background: linear-gradient(180deg, #1c1436, #100a24); border: 1px solid var(--accent); border-radius: var(--radius);
  box-shadow: var(--shadow), 0 0 18px rgba(0,216,255,0.3); }
.ctxmenu[hidden] { display: none; }
.ctx-item { display: flex; align-items: center; gap: 10px; padding: 7px 12px; color: var(--ink); font-size: 13px; cursor: pointer; border-radius: var(--radius); }
.ctx-item .ico { width: 18px; text-align: center; }
.ctx-item:hover { background: linear-gradient(180deg, #5ec9f0, #1c8fd6); color: #04252e; }
.ctx-sep { height: 1px; margin: 4px 8px; background: rgba(0,216,255,0.3); }

/* ============================================================
   Profile song widget ("now playing")
   ============================================================ */
.song-widget { position: fixed; left: 12px; bottom: 58px; z-index: 60; display: flex; align-items: center; gap: 9px;
  padding: 6px 13px 6px 7px; border: 1px solid var(--accent); border-radius: 22px;
  background: linear-gradient(180deg, rgba(30,20,52,0.94), rgba(14,8,28,0.94)); backdrop-filter: blur(6px);
  box-shadow: var(--shadow), 0 0 18px rgba(0,216,255,0.4); }
.song-btn { width: 30px; height: 30px; border-radius: 50%; border: 1px solid rgba(255,255,255,0.5); cursor: pointer; color: #04252e; font-size: 12px;
  background: linear-gradient(180deg, #7fe6ff, #17b4e2); box-shadow: inset 0 1px 0 rgba(255,255,255,0.7); display: grid; place-items: center; }
.song-btn:hover { filter: brightness(1.1); }
.song-info { display: flex; align-items: center; gap: 9px; }
.song-label { font-size: 12px; color: var(--ink); white-space: nowrap; }
.song-eq { display: flex; align-items: flex-end; gap: 2px; height: 16px; }
.song-eq i { width: 3px; height: 4px; background: var(--accent); box-shadow: 0 0 5px var(--accent); }
.song-widget.playing .song-eq i { animation: eq .8s ease-in-out infinite; }
.song-eq i:nth-child(2) { animation-delay: .2s; }
.song-eq i:nth-child(3) { animation-delay: .4s; }
.song-eq i:nth-child(4) { animation-delay: .1s; }
@keyframes eq { 0%, 100% { height: 4px; } 50% { height: 15px; } }

/* ============================================================
   Custom wallpaper + upload swatch
   ============================================================ */
html[data-wp="custom"] body { background: #06040e var(--wp-custom, none) center / cover no-repeat fixed; }
.swatch.sw-custom { background: repeating-linear-gradient(45deg, #241a3c 0 8px, #1a1030 8px 16px); }

@media (prefers-reduced-motion: reduce) { .song-widget.playing .song-eq i { animation: none; } }

/* ============================================================
   WINDOW SKINS — a jumble of aesthetics, randomly assigned per
   window by JS. Cards / inputs stay theme-independent (above),
   so any skin's body text remains readable.
   ============================================================ */

/* Frutiger Aero — glossy light aqua glass */
.panel.skin-frutiger {
  --accent: var(--user-accent, #2aa9e0); --ink: #12354e; --ink-dim: #5c7488; --link: #0a6ebd;
  color: #12354e; background: linear-gradient(180deg, rgba(248,252,255,0.95), rgba(226,242,252,0.95));
  border: 1px solid rgba(255,255,255,0.8); border-radius: 12px;
  box-shadow: 0 16px 36px rgba(10,40,72,0.42), inset 0 1px 0 rgba(255,255,255,0.9);
}
.panel.skin-frutiger .panel-title { --tbc-scan: none; background: linear-gradient(180deg, #ffffff, #c3e8fb 55%, #8fd0f4); color: #0d3350; border-bottom: 1px solid rgba(255,255,255,0.7); box-shadow: inset 0 1px 0 rgba(255,255,255,0.95); text-shadow: 0 1px 0 rgba(255,255,255,0.6); }
.panel.skin-frutiger .panel-title::before { background: linear-gradient(rgba(255,255,255,0.75), rgba(255,255,255,0)); }
.panel.skin-frutiger .panel-more { color: #0a6ebd; }

/* Dreamcore — hazy pastel, Comic Sans, soft glow */
.panel.skin-dreamcore {
  --accent: var(--user-accent, #c9a3ff); --ink: #4a3560; --ink-dim: #7d6a92; --link: #8a4bd6;
  color: #4a3560; font-family: "Comic Sans MS", "Comic Sans", "Chalkboard SE", cursive;
  background: linear-gradient(160deg, #f3e6ff, #e6eeff 55%, #ffe9f6);
  border: 1px solid #dcc9f7; border-radius: 16px;
  box-shadow: 0 0 44px rgba(201,163,255,0.5), 0 12px 30px rgba(0,0,0,0.32);
}
.panel.skin-dreamcore .panel-title { --tbc-scan: none; background: linear-gradient(180deg, #f7ecff, #d9b8ff 60%, #c39bf0); color: #5a3d78; border-bottom: 1px solid rgba(255,255,255,0.6); box-shadow: inset 0 1px 0 rgba(255,255,255,0.8); text-shadow: 0 1px 2px rgba(255,255,255,0.7); }
.panel.skin-dreamcore .panel-title::before { background: linear-gradient(rgba(255,255,255,0.6), rgba(255,255,255,0)); }

/* Ethereal — angelcore cream + gold, serif, italic glow */
.panel.skin-ethereal {
  --accent: var(--user-accent, #e0b84e); --ink: #5a4a26; --ink-dim: #8a7a52; --link: #b8860b;
  color: #5a4a26; font-family: Georgia, "Times New Roman", serif;
  background: linear-gradient(180deg, #fffdf4, #f8efd8);
  border: 1px solid #efe0b8; border-radius: 12px;
  box-shadow: 0 0 40px rgba(224,184,78,0.45), 0 12px 28px rgba(0,0,0,0.28);
}
.panel.skin-ethereal .panel-title { --tbc-scan: none; background: linear-gradient(180deg, #fffdf0, #f0d98a 55%, #e3bd57); color: #6a5320; border-bottom: 1px solid rgba(255,255,255,0.6); box-shadow: inset 0 1px 0 rgba(255,255,255,0.9); text-shadow: 0 1px 0 rgba(255,255,255,0.7); font-style: italic; letter-spacing: .5px; }
.panel.skin-ethereal .panel-title::before { background: linear-gradient(rgba(255,255,255,0.7), rgba(255,255,255,0)); }
.panel.skin-ethereal .panel-more { color: #9c7a10; }

/* Hyper-digital — matrix chrome, mono, green scanlines */
.panel.skin-hyperdigital {
  --accent: var(--user-accent, #39ff14); --ink: #c6ffd2; --ink-dim: #6fbf80; --link: #7dff9a;
  color: #c6ffd2; font-family: "Courier New", Consolas, monospace;
  background: linear-gradient(180deg, #04140b, #020a06);
  border: 1px solid rgba(57,255,20,0.5); border-radius: 2px;
  box-shadow: 0 0 24px rgba(57,255,20,0.35), 0 12px 30px rgba(0,0,0,0.6);
}
.panel.skin-hyperdigital .panel-title { --tbc-scan: repeating-linear-gradient(180deg, rgba(57,255,20,0.14) 0 1px, transparent 1px 3px); background: linear-gradient(180deg, #0a3a1a, #062610); color: #8fff9f; border-bottom: 1px solid rgba(57,255,20,0.5); box-shadow: inset 0 1px 0 rgba(57,255,20,0.4); text-shadow: 0 0 7px rgba(57,255,20,0.8); }
.panel.skin-hyperdigital .panel-title::before { display: none; }
.panel.skin-hyperdigital .panel-inner { background-image: repeating-linear-gradient(180deg, rgba(57,255,20,0.05) 0 1px, transparent 1px 3px) !important; }
.panel.skin-hyperdigital .title-bar-controls .tb-btn { background: linear-gradient(180deg,#0c4020,#062610); color: #8fff9f; border-color: rgba(57,255,20,0.5); }
.panel.skin-hyperdigital .title-bar-controls .tb-btn.close { background: linear-gradient(180deg,#5a1414,#320a0a); color: #ff9a9a; }

/* Vaporwave — purple/pink/cyan gradient + grid */
.panel.skin-vapor {
  --accent: var(--user-accent, #ff6ad5); --ink: #f2e9ff; --ink-dim: #c3a8e0; --link: #7bf0ff;
  color: #f2e9ff; background: linear-gradient(180deg, #2a1150, #3a1a6a);
  border: 1px solid rgba(255,106,213,0.5); border-radius: 4px;
  box-shadow: 0 0 28px rgba(123,240,255,0.32), 0 12px 30px rgba(0,0,0,0.5);
}
.panel.skin-vapor .panel-title { --tbc-scan: none; background: linear-gradient(90deg, #ff6ad5, #9b5cff 50%, #4fe0ff); color: #22103a; border-bottom: 1px solid rgba(255,255,255,0.35); box-shadow: inset 0 1px 0 rgba(255,255,255,0.5); text-shadow: 0 1px 0 rgba(255,255,255,0.3); }
.panel.skin-vapor .panel-inner { background-image: linear-gradient(rgba(255,106,213,0.09) 1px, transparent 1px), linear-gradient(90deg, rgba(123,240,255,0.09) 1px, transparent 1px); background-size: 22px 22px; }

/* Old Web — Geocities garish yellow, ridge borders, Times */
.panel.skin-oldweb {
  --accent: var(--user-accent, #0000cc); --ink: #000000; --ink-dim: #333333; --link: #0000ee;
  color: #000; font-family: "Times New Roman", Times, serif;
  background: #fffbe6; border: 3px ridge #ff00ff; border-radius: 0;
  box-shadow: 4px 4px 0 rgba(0,0,0,0.5);
}
.panel.skin-oldweb .panel-title { --tbc-scan: none; background: #000080; color: #ffff00; font-family: "Comic Sans MS", cursive; border-bottom: 2px solid #ff00ff; box-shadow: none; text-shadow: none; }
.panel.skin-oldweb .panel-title::before { display: none; }
.panel.skin-oldweb .panel-inner { background-image: radial-gradient(#ffcdf1 1px, transparent 1.6px); background-size: 15px 15px; }
.panel.skin-oldweb .panel-more { color: #0000ee; text-decoration: underline; }
.panel.skin-oldweb .title-bar-controls .tb-btn { border-radius: 0; background: #c0c0c0; color: #000; border: 1px solid; border-color: #fff #000 #000 #fff; box-shadow: inset -1px -1px 0 #808080, inset 1px 1px 0 #dfdfdf; }

/* ============================================================
   ICONS (inline SVG, inherit text colour)
   ============================================================ */
.ico { width: 16px; height: 16px; display: inline-block; vertical-align: -0.18em; flex: none; }
.sm-item .ico, .ctx-item .ico { width: 17px; height: 17px; }
.tb-btn .ico { width: 13px; height: 13px; }
.ql .ico { width: 18px; height: 18px; }
.dicon-img .ico { width: 28px; height: 28px; }
.card-meta .ico { width: 12px; height: 12px; vertical-align: -0.1em; }
.panel-title > span:first-child .ico { vertical-align: -0.16em; margin-right: 3px; }
.tray-user .ico, .btn .ico { vertical-align: -0.18em; }

/* ============================================================
   ANIMATED ACCENT GLOWS
   ============================================================ */
@keyframes glowText { 0%,100% { text-shadow: 0 0 4px currentColor; } 50% { text-shadow: 0 0 11px currentColor, 0 0 3px currentColor; } }
@keyframes glowBox  { 0%,100% { box-shadow: 0 0 6px 0 var(--accent); } 50% { box-shadow: 0 0 15px 1px var(--accent); } }
@keyframes hueSpin  { to { filter: hue-rotate(360deg); } }
.rate-avg, .tray-clock, .statlist li span:last-child, .streak-num { animation: glowText 2.6s ease-in-out infinite; }
.badge-new { animation: glowBox 1.7s ease-in-out infinite; }
.win-task.active { animation: glowBox 2.2s ease-in-out infinite; }
.stars-mini { animation: glowText 3s ease-in-out infinite; }
.dicon-img { animation: floaty 4s ease-in-out infinite, glowBox 3.4s ease-in-out infinite; }
@media (prefers-reduced-motion: reduce) {
  .rate-avg,.tray-clock,.statlist li span:last-child,.streak-num,.badge-new,.win-task.active,.stars-mini,.dicon-img { animation: none; }
}

/* ============================================================
   START LOGO (replaces the Windows flag)
   ============================================================ */
.tb-logo { width: 22px; height: 22px; display: block; color: var(--chrome-accent); filter: drop-shadow(0 0 5px var(--chrome-accent)); animation: logoPulse 2.4s ease-in-out infinite; }
@keyframes logoPulse { 50% { filter: drop-shadow(0 0 11px var(--accent)); transform: scale(1.06); } }

/* ============================================================
   STREAK + STATUS
   ============================================================ */
.streak-badge { display: inline-flex; align-items: center; gap: 5px; padding: 3px 11px; border-radius: 14px;
  background: linear-gradient(180deg, #3a2410, #1d1106); border: 1px solid #ff8a3c; color: #ffb26b; font-weight: 700; font-size: 13px; }
.streak-badge .ico { color: #ff8a3c; }
.streak-num { color: #ffcf33; }
.status-box { display: flex; gap: 9px; align-items: flex-start; margin: 0 0 14px; padding: 10px 13px; border-radius: 10px;
  background: linear-gradient(180deg, rgba(0,216,255,0.10), rgba(0,0,0,0.25)); border: 1px solid var(--line); box-shadow: inset 0 0 16px rgba(0,216,255,0.06); }
.status-box .ico { color: var(--accent); margin-top: 2px; flex: none; }
.status-quote { font-size: 15px; color: var(--ink); }
.status-empty { color: var(--ink-dim); font-style: italic; }

/* ============================================================
   AVATAR BORDERS (wrap the avatar in .avatar-frame.ab-*)
   ============================================================ */
.avatar-frame { display: inline-grid; place-items: center; border-radius: 16px; padding: 0; position: relative; flex: none; }
.avatar-frame .profile-avatar, .avatar-frame .profile-avatar-empty { display: block; }
.avatar-frame.ab-gold { padding: 4px; background: linear-gradient(135deg, #fff3c4, #e0b84e 50%, #a9821f); box-shadow: 0 0 16px rgba(224,184,78,0.7); }
.avatar-frame.ab-neon { padding: 3px; background: var(--accent); box-shadow: 0 0 18px var(--accent); animation: glowBox 2s ease-in-out infinite; }
.avatar-frame.ab-pixel { padding: 5px; background:
  repeating-conic-gradient(#ff2d9b 0 25%, #00d8ff 0 50%) 50% / 12px 12px; image-rendering: pixelated; border-radius: 4px; }
.avatar-frame.ab-pixel .profile-avatar, .avatar-frame.ab-pixel .profile-avatar-empty { border-radius: 2px; }
.avatar-frame.ab-rainbow { padding: 4px; background: conic-gradient(#ff004c, #ffb700, #b6ff3d, #00d8ff, #7b2ff7, #ff004c); animation: hueSpin 6s linear infinite; box-shadow: 0 0 16px rgba(255,255,255,0.3); }
.avatar-frame.ab-hearts { padding: 4px; background: repeating-linear-gradient(45deg, #ff6ab0 0 6px, #ff2d9b 6px 12px); box-shadow: 0 0 16px rgba(255,45,155,0.6); }
.avatar-frame.ab-flames { padding: 4px; background: linear-gradient(0deg, #ffd23f, #ff7a1a 55%, #e01f1f); box-shadow: 0 0 18px rgba(255,90,20,0.75); animation: glowBox 1.3s ease-in-out infinite; }
.avatar-frame.ab-chrome { padding: 4px; background: linear-gradient(135deg, #ffffff, #9aa6b5 30%, #4a5563 55%, #cfd8e3 80%, #6b7683); box-shadow: 0 0 12px rgba(200,220,255,0.5); }

/* ============================================================
   PLAYLISTS
   ============================================================ */
.playlists-row { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 12px; }
.pl-card { display: flex; flex-direction: column; border-radius: var(--radius); overflow: hidden; color: var(--ink);
  background: linear-gradient(180deg, #221a3e, #150e28); border: 1px solid rgba(0,216,255,0.28); box-shadow: 0 4px 12px rgba(0,0,0,0.45); transition: transform .12s, box-shadow .12s, border-color .12s; }
.pl-card:hover { text-decoration: none; transform: translateY(-4px); border-color: var(--accent); box-shadow: 0 12px 24px rgba(0,0,0,0.55), 0 0 16px rgba(0,216,255,0.4); }
.pl-cover { position: relative; aspect-ratio: 16/10; background: #06040e; display: grid; place-items: center; overflow: hidden; }
.pl-cover img, .pl-cover video { width: 100%; height: 100%; object-fit: cover; }
.pl-cover .ico { width: 34px; height: 34px; color: rgba(255,255,255,0.4); }
.pl-cover .pl-count { position: absolute; bottom: 6px; right: 6px; background: rgba(0,0,0,0.7); color: var(--accent); border: 1px solid rgba(0,216,255,0.4); font-size: 11px; padding: 1px 7px; border-radius: 8px; }
.pl-name { padding: 8px 10px; font-size: 13px; font-weight: 700; color: #eef3ff; display: flex; align-items: center; gap: 6px; }
.pl-new { display: flex; gap: 6px; }
.pl-new .input { flex: 1; }

/* add-to-playlist control on posts */
.addpl { position: relative; }
.addpl-menu { display: none; position: absolute; z-index: 30; right: 0; top: calc(100% + 4px); min-width: 220px; padding: 8px;
  background: linear-gradient(180deg, #1c1436, #100a24); border: 1px solid var(--accent); border-radius: var(--radius); box-shadow: var(--shadow); }
.addpl.open .addpl-menu { display: block; }
.addpl-menu form { margin: 0 0 4px; }
.addpl-menu .plpick { display: flex; width: 100%; text-align: left; gap: 6px; align-items: center; padding: 6px 8px; color: var(--ink); background: none; border: none; cursor: pointer; border-radius: var(--radius); }
.addpl-menu .plpick:hover { background: rgba(0,216,255,0.15); }
.addpl-sep { height: 1px; margin: 5px 4px; background: rgba(0,216,255,0.3); }

/* ============================================================
   MESSAGES (Messenger window)
   ============================================================ */
.msgapp { display: grid; grid-template-columns: 230px 1fr; min-height: 460px; }
.conv-list { border-right: 1px solid rgba(0,216,255,0.25); overflow-y: auto; max-height: 560px; }
.conv-item { display: flex; gap: 9px; align-items: center; padding: 9px 11px; color: var(--ink); border-bottom: 1px solid rgba(0,216,255,0.12); }
.conv-item:hover { text-decoration: none; background: rgba(0,216,255,0.08); }
.conv-item.active { background: rgba(0,216,255,0.16); }
.conv-item img, .conv-item .avatar-empty { width: 34px; height: 34px; border-radius: 8px; object-fit: cover; box-shadow: 0 0 0 1px rgba(0,216,255,0.5); flex: none; }
.conv-main { min-width: 0; flex: 1; }
.conv-name { font-weight: 700; font-size: 13px; display: flex; align-items: center; gap: 6px; }
.conv-last { font-size: 12px; color: var(--ink-dim); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.conv-unread { margin-left: auto; background: var(--magenta); color: #fff; font-size: 10px; font-weight: 700; border-radius: 9px; padding: 1px 7px; box-shadow: 0 0 8px var(--magenta); }
.msg-pane { display: flex; flex-direction: column; min-width: 0; }
.msg-head { padding: 10px 14px; border-bottom: 1px solid rgba(0,216,255,0.25); font-weight: 700; display: flex; align-items: center; gap: 8px; }
.thread { flex: 1; overflow-y: auto; max-height: 460px; padding: 14px; display: flex; flex-direction: column; gap: 9px; }
.msg-row { display: flex; }
.msg-row.mine { justify-content: flex-end; }
.msg-bubble { max-width: 74%; padding: 8px 12px; border-radius: 12px; font-size: 13.5px; word-wrap: break-word; }
.msg-row.theirs .msg-bubble { background: linear-gradient(180deg, #2a2048, #1c1338); border: 1px solid rgba(0,216,255,0.3); border-bottom-left-radius: 3px; }
.msg-row.mine .msg-bubble { background: linear-gradient(180deg, #2298dd, #1272ad); color: #fff; border-bottom-right-radius: 3px; }
.msg-time { font-size: 10px; color: var(--ink-dim); margin-top: 3px; }
.msg-form { display: flex; gap: 8px; padding: 12px 14px; border-top: 1px solid rgba(0,216,255,0.25); }
.msg-form .input { flex: 1; }
.msg-empty { flex: 1; display: grid; place-items: center; color: var(--ink-dim); text-align: center; padding: 30px; }
.nav-badge { background: var(--magenta); color: #fff; font-size: 10px; font-weight: 700; border-radius: 9px; padding: 0 6px; box-shadow: 0 0 8px var(--magenta); margin-left: 3px; }

/* ============================================================
   CUSTOM HTML/CSS section + profile preview
   ============================================================ */
.custom-box { margin-top: 14px; padding: 12px; border: 1px dashed var(--line); border-radius: var(--radius); background: rgba(0,0,0,0.2); }
.custom-box .custom-label { font-size: 11px; color: var(--ink-dim); text-transform: uppercase; letter-spacing: 1px; margin-bottom: 6px; }
.profile-preview { margin-top: 14px; }
.profile-preview iframe { width: 100%; height: 560px; border: 2px solid var(--line); border-radius: var(--radius); background: #0b0718; }
.preview-bar { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-bottom: 6px; }
.mono-input { font-family: var(--mono); font-size: 12px; }

/* ============================================================
   TOP BANNER (full-width identity + primary nav)
   ============================================================ */
.topbanner {
  position: sticky; top: 0; z-index: 80; width: 100%;
  background: linear-gradient(180deg, rgba(20,12,40,0.94), rgba(12,8,26,0.80));
  border-bottom: 1px solid var(--accent);
  box-shadow: 0 2px 18px rgba(0,0,0,0.5), inset 0 -1px 0 rgba(0,216,255,0.25);
  backdrop-filter: blur(10px);
}
.banner-inner { display: flex; align-items: center; gap: 14px; padding: 8px 18px; }
.banner-brand .wordmark { font-size: 25px; animation: glowText 2.8s ease-in-out infinite; }
.banner-brand:hover { text-decoration: none; }
.banner-nav { margin-left: auto; display: flex; align-items: center; gap: 4px; flex-wrap: wrap; }
.banner-nav > a { color: #d7e6ff; padding: 6px 11px; border-radius: 8px; font-weight: 600; font-size: 13.5px; }
.banner-nav > a:hover { text-decoration: none; background: rgba(0,216,255,0.14); }
.banner-nav > a.on { color: var(--accent); box-shadow: inset 0 -2px 0 var(--accent); }
.banner-icon { position: relative; background: rgba(0,216,255,0.10); border: 1px solid rgba(0,216,255,0.3); color: var(--accent); width: 34px; height: 32px; border-radius: 8px; cursor: pointer; display: grid; place-items: center; }
.banner-icon:hover { box-shadow: 0 0 12px rgba(0,216,255,0.5); }
.banner-icon .ico { width: 18px; height: 18px; }
.bell-badge { position: absolute; top: -5px; right: -5px; background: var(--magenta); color: #fff; font-size: 10px; font-weight: 700; border-radius: 9px; padding: 0 5px; box-shadow: 0 0 8px var(--magenta); }
.banner-me { display: inline-flex; align-items: center; gap: 7px; color: #eaf2ff; font-weight: 700; padding: 3px 12px 3px 3px; border-radius: 20px; background: rgba(0,216,255,0.10); border: 1px solid rgba(0,216,255,0.3); }
.banner-me:hover { text-decoration: none; box-shadow: 0 0 12px rgba(0,216,255,0.4); }
.banner-me img, .banner-me-empty { width: 26px; height: 26px; border-radius: 50%; object-fit: cover; }
.banner-me-empty { display: grid; place-items: center; background: var(--accent); color: #04252e; font-weight: 800; font-size: 12px; }
.banner-cta { background: linear-gradient(180deg,#ff7ec8,#ff2d9b); color: #fff !important; padding: 6px 14px !important; border-radius: 8px; font-weight: 700; }
.banner-cta:hover { text-decoration: none; box-shadow: 0 0 14px rgba(255,45,155,0.6); }
@media (max-width: 640px) { .banner-me-name { display: none; } .banner-nav { gap: 2px; } .banner-nav > a { padding: 6px 8px; font-size: 12.5px; } .banner-brand .wordmark { font-size: 21px; } }

/* ============================================================
   NOTIFICATIONS PANEL
   ============================================================ */
.notif-panel { position: fixed; top: 58px; right: 12px; width: 344px; max-width: calc(100vw - 24px); max-height: 70vh; overflow: auto; z-index: 96;
  background: linear-gradient(180deg,#201738,#0e0820); border: 1px solid var(--accent); border-radius: 10px;
  box-shadow: var(--shadow), 0 0 22px rgba(0,216,255,0.3); display: none; }
.notif-panel.open { display: block; animation: pop .14s ease; }
.notif-head { padding: 10px 14px; font-weight: 700; border-bottom: 1px solid rgba(0,216,255,0.25); display: flex; align-items: center; gap: 8px; color: var(--accent); position: sticky; top: 0; background: linear-gradient(180deg,#201738,#1a1330); }
.notif-head .ico { width: 16px; height: 16px; }
.notif-body { padding: 4px; }
/* Notifications as a spawned window (themed like Messages/Upload). */
.notifwin.spawned { width: min(440px, 94vw); }
.notifwin .notif-body { max-height: 60vh; overflow-y: auto; }
.notifwin .notif-item { color: var(--ink); }
.notif-item { display: flex; gap: 10px; padding: 9px 10px; border-radius: 8px; color: var(--ink); align-items: flex-start; }
.notif-item:hover { text-decoration: none; background: rgba(0,216,255,0.10); }
.notif-item img, .notif-item .avatar-empty { width: 34px; height: 34px; border-radius: 8px; object-fit: cover; flex: none; box-shadow: 0 0 0 1px rgba(0,216,255,0.5); }
.notif-item .avatar-empty { display: grid; place-items: center; background: var(--accent); color: #04252e; font-weight: 800; }
.notif-text { font-size: 13px; min-width: 0; line-height: 1.35; }
.notif-preview { display: block; color: var(--ink-dim); font-size: 12px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 260px; }
.notif-time { display: block; color: var(--ink-dim); font-size: 11px; margin-top: 2px; }
.notif-empty { padding: 24px; text-align: center; color: var(--ink-dim); }

/* ============================================================
   THEME PICKER
   ============================================================ */
.theme-pick { width: min(520px, 94vw); }
.theme-swatches { display: grid; grid-template-columns: repeat(auto-fill, minmax(112px,1fr)); gap: 10px; }
.theme-swatch { padding: 0; overflow: hidden; border: 2px solid rgba(255,255,255,0.22); border-radius: 16px; cursor: pointer; background: #14102a; color: #fff; text-align: left; transition: transform .12s, box-shadow .12s; }
.theme-swatch:hover { border-color: var(--accent); transform: translateY(-2px); }
.theme-swatch.sel { border-color: var(--accent); box-shadow: 0 0 14px var(--accent); }
.tsw-bar { display: block; height: 30px; border-radius: 13px 13px 0 0; border-bottom: 1px solid rgba(0,0,0,0.3); }
.tsw-name { display: block; padding: 6px 8px; font-size: 12px; font-weight: 700; }
.tsw-scene { background:#150e28; } .tsw-scene .tsw-bar { background: linear-gradient(180deg,#7fe6ff,#0a86c0); }
.tsw-frutiger { background:#e6f2fc; color:#12354e; } .tsw-frutiger .tsw-bar { background: linear-gradient(180deg,#fff,#8fd0f4); }
.tsw-win98 { background:#1a1330; } .tsw-win98 .tsw-bar { background: linear-gradient(90deg,#0a1e8f,#2f97e0); }
.tsw-dreamcore { background:#efe6fb; color:#4a3560; font-family:"Comic Sans MS",cursive; } .tsw-dreamcore .tsw-bar { background: linear-gradient(180deg,#f7ecff,#c39bf0); }
.tsw-ethereal { background:#faf1dc; color:#5a4a26; font-family:Georgia,serif; } .tsw-ethereal .tsw-bar { background: linear-gradient(180deg,#fffdf0,#e3bd57); }
.tsw-hyperdigital { background:#04140b; color:#8fff9f; font-family:"Courier New",monospace; } .tsw-hyperdigital .tsw-bar { background: linear-gradient(180deg,#0a3a1a,#062610); }
.tsw-vapor { background:#2a1150; } .tsw-vapor .tsw-bar { background: linear-gradient(90deg,#ff6ad5,#4fe0ff); }
.tsw-oldweb { background:#fffbe6; color:#000; font-family:"Times New Roman",serif; } .tsw-oldweb .tsw-bar { background:#000080; }

/* ============================================================
   FREE-SPREAD WINDOW LAYOUT — JS packs windows into columns across
   the full width (not a rigid single-column grid), with jitter.
   ============================================================ */
.masonry { display: flex; align-items: flex-start; gap: 18px; }
.mason-col { display: flex; flex-direction: column; gap: 16px; flex: 1; min-width: 0; }
.masonry .panel:hover, .postmain > .panel:hover, .profilepage > .panel:hover { z-index: 6; }
/* when JS hasn't (or can't) run, plain flow still looks fine */

/* Drag physics — tilt while dragging, spring back level on drop */
.panel.dragging { transition: none !important; cursor: grabbing; will-change: transform;
  box-shadow: var(--shadow), 0 20px 44px rgba(0,0,0,0.75), 0 0 28px rgba(0,216,255,0.4); }
.panel.drag-release { transition: transform .4s cubic-bezier(.34,1.56,.64,1); }

/* ============================================================
   POST PAGE — media beside details/rating on desktop
   ============================================================ */
.post-top { display: grid; grid-template-columns: 1fr; gap: 14px; }
.post-meta-col { display: grid; gap: 14px; align-content: start; }
@media (min-width: 820px) {
  .post-top { grid-template-columns: minmax(0, 2.5fr) minmax(220px, 0.85fr); align-items: start; }
}

@media (prefers-reduced-motion: reduce) {
  .bg-aurora, .banner-brand .wordmark, .brand-band .wordmark, .ticker-track { animation: none; }
}

/* ============================================================
   FILM GRAIN — tactile, hand-made texture over everything
   ============================================================ */
.bg-grain {
  position: fixed; inset: 0; z-index: 1; pointer-events: none; opacity: 0.055; mix-blend-mode: overlay;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='120' height='120'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='120' height='120' filter='url(%23n)'/%3E%3C/svg%3E");
}
/* soft vignette so the desktop feels less flat-corporate */
body::after { content: ""; position: fixed; inset: 0; z-index: 0; pointer-events: none;
  background: radial-gradient(120% 120% at 50% 40%, transparent 58%, rgba(0,0,0,0.32) 100%); }

/* ============================================================
   RECENT-COMMENTS TICKER (scrolls under the banner)
   ============================================================ */
.comment-ticker { display: flex; align-items: stretch; overflow: hidden; border-bottom: 1px solid rgba(0,216,255,0.2);
  background: linear-gradient(180deg, rgba(20,12,40,0.7), rgba(12,8,26,0.55)); backdrop-filter: blur(6px); }
.ticker-label { flex: none; display: flex; align-items: center; gap: 6px; padding: 6px 14px; font-size: 11px; font-weight: 800; letter-spacing: 1px; text-transform: uppercase;
  color: #04252e; background: linear-gradient(180deg, var(--accent), #0a86c0); box-shadow: 2px 0 10px rgba(0,216,255,0.4); z-index: 1; }
.ticker-label .ico { width: 14px; height: 14px; }
.ticker-track { display: inline-flex; white-space: nowrap; align-items: center; animation: tickerScroll 48s linear infinite; padding: 6px 0; }
.comment-ticker:hover .ticker-track { animation-play-state: paused; }
.ticker-item { color: #cfe0f5; font-size: 12.5px; padding: 0 26px; flex: none; }
.ticker-item:hover { text-decoration: none; color: #fff; }
.ticker-item b { color: var(--accent); }
.ticker-on { color: var(--ink-dim); }
@keyframes tickerScroll { from { transform: translateX(0); } to { transform: translateX(-50%); } }

/* ============================================================
   START-MENU CUSTOM SHORTCUTS
   ============================================================ */
.sm-shortcut { display: flex; align-items: center; }
.sm-shortcut .sm-item { flex: 1; }
.sm-sc-x { flex: none; background: none; border: none; color: var(--ink-dim); cursor: pointer; font-size: 16px; padding: 4px 10px; border-radius: 6px; }
.sm-sc-x:hover { color: #fff; background: var(--magenta); }

/* ============================================================
   MINIMIZE / RESTORE window animations
   ============================================================ */
@keyframes winMinimize {
  0%   { transform: scale(1) translateY(0); opacity: 1; }
  100% { transform: scale(0.4) translateY(60vh); opacity: 0; }
}
@keyframes winRestore {
  0%   { transform: scale(0.5) translateY(40vh); opacity: 0; }
  100% { transform: scale(1) translateY(0); opacity: 1; }
}
.panel.win-minimizing { animation: winMinimize .26s ease forwards; transform-origin: 50% 100%; pointer-events: none; }
.panel.win-restoring { animation: winRestore .3s cubic-bezier(.2,.9,.3,1.2); transform-origin: 50% 100%; }
@media (prefers-reduced-motion: reduce) { .panel.win-minimizing, .panel.win-restoring { animation: none; } }

/* ============================================================
   SCRAPBOOK skin (default theme) — paper, washi-tape title bar,
   hand-torn wobbly border, doodle dot-grid body.
   ============================================================ */
.panel.skin-scrapbook {
  --accent: var(--user-accent, #d9553b); --ink: #3b3128; --ink-dim: #8a7868; --link: #b8412a;
  color: #3b3128;
  font-family: "Segoe Print", "Bradley Hand", "Comic Sans MS", "Comic Sans", "Chalkboard SE", cursive;
  background:
    repeating-linear-gradient(0deg, rgba(150,120,80,0.05) 0 1px, transparent 1px 26px),
    linear-gradient(180deg, #fdf6e6, #f4e9cf);
  border: 1px solid #cbb88f;
  border-radius: 10px 4px 12px 6px / 6px 12px 4px 10px;   /* hand-torn wobble */
  box-shadow: 0 10px 26px rgba(70,50,25,0.28), inset 0 0 44px rgba(190,160,110,0.10);
}
.panel.skin-scrapbook .panel-title {
  --tbc-scan: none;
  background: repeating-linear-gradient(45deg, #ffd76a 0 11px, #ffcb3d 11px 22px);   /* washi tape */
  color: #5a3d10; text-shadow: 0 1px 0 rgba(255,255,255,0.45);
  border-bottom: 1px dashed #b89a5a; box-shadow: none;
  font-family: inherit; letter-spacing: .3px; cursor: grab;
}
.panel.skin-scrapbook .panel-title::before, .panel.skin-scrapbook .panel-title::after { display: none; }
.panel.skin-scrapbook .panel-inner {
  background-image: radial-gradient(rgba(150,120,80,0.07) 1px, transparent 1.4px) !important;
  background-size: 16px 16px;
}
.panel.skin-scrapbook .panel-more { color: #b8412a; text-decoration: underline; }
.panel.skin-scrapbook .title-bar-controls .tb-btn {
  color: #5a3d10; background: #fff7e0; border: 1px solid #b89a5a; border-radius: 3px; box-shadow: none;
}
.panel.skin-scrapbook .title-bar-controls .tb-btn.close { color: #7a1c1c; background: #ffdcc0; }
.tsw-scrapbook { background:#f4e9cf; color:#3b3128; font-family:"Segoe Print","Comic Sans MS",cursive; }
.tsw-scrapbook .tsw-bar { background: repeating-linear-gradient(45deg,#ffd76a 0 8px,#ffcb3d 8px 16px); }

/* ── Needy: pastel-lavender pixel desktop, the default look ────────────────
   Original CSS homage to the soft lilac "chat-sim OS" aesthetic: lavender
   windows, purple bitmap-style title bars in a monospace/pixel stack, crisp
   beveled borders, cyan + pink micro-accents. No third-party assets. */
.panel.skin-needy {
  --accent: var(--user-accent, #a07fe0); --ink: #5f478f; --ink-dim: #9d8bc4; --link: #8a5fc4;
  --nso-cyan: #63cfe6; --nso-pink: #ef9fda;
  color: #5f478f;
  font-family: "DejaVu Sans Mono", "Courier New", ui-monospace, monospace;
  background: linear-gradient(180deg, #f6f1fd, #ebe3f9);
  border: 2px solid #a98fd6;
  border-radius: 3px;
  box-shadow: inset 1px 1px 0 #ffffff, inset -1px -1px 0 #bda8e6,
              0 9px 24px rgba(120,90,180,0.30);
}
.panel.skin-needy .panel-title {
  --tbc-scan: none;
  background: linear-gradient(180deg, #e4d8f8, #cdbaee);
  color: #6b4ea6; text-shadow: 0 1px 0 rgba(255,255,255,0.7);
  border-bottom: 2px solid #a98fd6; box-shadow: inset 0 1px 0 rgba(255,255,255,0.85);
  text-transform: uppercase; letter-spacing: 1.2px; font-weight: 700;
}
.panel.skin-needy .panel-title::before { background: linear-gradient(rgba(255,255,255,0.5), rgba(255,255,255,0)); }
.panel.skin-needy .panel-title::after { display: none; }
.panel.skin-needy .panel-inner {
  background-image: radial-gradient(rgba(160,130,220,0.10) 1px, transparent 1.5px) !important;
  background-size: 14px 14px;
}
.panel.skin-needy .panel-more { color: #8a5fc4; text-decoration: underline; }
/* Square, pixel-y window controls with a lilac bevel. */
.panel.skin-needy .title-bar-controls .tb-btn {
  color: #6b4ea6; background: #efe7fb; border: 1.5px solid #a98fd6; border-radius: 2px;
  box-shadow: inset 1px 1px 0 #fff, inset -1px -1px 0 #c6b4ec;
}
.panel.skin-needy .title-bar-controls .tb-btn.close { color: #7a3f6e; background: #f6d9ee; border-color: #d99ec9; }
.tsw-needy { background: linear-gradient(180deg,#efe7fb,#ddcef4); color: #5f478f; font-family: "Courier New", monospace; }
.tsw-needy .tsw-bar { background: linear-gradient(180deg,#e4d8f8,#c0a9ea); }

/* ============================================================
   CHROME (taskbar / start menu / tray) RE-SKIN per data-theme.
   scene = the :root defaults, so it needs no block.
   ============================================================ */
html[data-theme="scrapbook"] {
  --chrome-accent: var(--user-accent, #d9553b); --chrome-text: #3b3128; --chrome-line: rgba(120,90,50,0.35);
  --tb-bg: repeating-linear-gradient(0deg, rgba(150,120,80,0.05) 0 1px, transparent 1px 24px), linear-gradient(180deg,#fdf6e6,#efe2c6);
  --tb-border: #cbb88f; --tb-glow: 0 8px 22px rgba(70,50,25,0.30), inset 0 1px 0 rgba(255,255,255,0.55);
  --sm-bg: linear-gradient(180deg,#fdf6e6,#f2e6cb); --sm-border: #cbb88f;
  --sm-band: repeating-linear-gradient(45deg,#ffd76a 0 12px,#ffcb3d 12px 24px);
}
html[data-theme="needy"] {
  --chrome-accent: var(--user-accent, #9a7fd0); --chrome-text: #5f478f; --chrome-line: #a98fd6;
  --tb-bg: linear-gradient(180deg,#ece3fa,#d6c8f2); --tb-border: #a98fd6;
  --tb-glow: inset 0 1px 0 rgba(255,255,255,0.9), 0 -2px 0 #c6b4ec inset, 0 4px 16px rgba(120,90,180,0.28);
  --sm-bg: linear-gradient(180deg,#f4effc,#e6dcf8); --sm-border: #a98fd6;
  --sm-band: linear-gradient(180deg,#ddcef4,#c0a9ea);
}
/* Lavender desktop with a soft wavy line pattern, like the chat-sim OS. This is
   now its OWN wallpaper (data-wp="needy"), independent of the theme, so it can be
   picked or replaced from the wallpaper picker like any other. */
html[data-wp="needy"] body {
  background-color: #e3d9f4;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='48' height='26' viewBox='0 0 48 26'%3E%3Cpath d='M0 13 Q 12 3 24 13 T 48 13' fill='none' stroke='%23cbd2f0' stroke-width='2'/%3E%3C/svg%3E");
  background-size: 48px 26px;
}
/* Clean lavender desktop — drop the neon ambiance layers for this wallpaper. */
html[data-wp="needy"] .bg-aurora,
html[data-wp="needy"] .bg-stars,
html[data-wp="needy"] .bg-grain { display: none; }
/* Pixel/monospace bitmap-style chrome, uppercase like the reference. */
html[data-theme="needy"] .taskbar,
html[data-theme="needy"] .startmenu {
  font-family: "DejaVu Sans Mono", "Courier New", ui-monospace, monospace;
}
html[data-theme="needy"] .sm-band,
html[data-theme="needy"] .win-task,
html[data-theme="needy"] .sm-item,
html[data-theme="needy"] .tray-clock,
html[data-theme="needy"] .tray-user { text-transform: uppercase; letter-spacing: .5px; }
html[data-theme="win98"] {
  --chrome-accent: var(--user-accent, #0a1e8f); --chrome-text: #000; --chrome-line: #808080;
  --tb-bg: #c0c0c0; --tb-border: #000; --tb-radius: 0;
  --tb-glow: inset 1px 1px 0 #dfdfdf, inset -1px -1px 0 #808080, 0 3px 8px rgba(0,0,0,0.4);
  --sm-bg: #c0c0c0; --sm-border: #000; --sm-band: linear-gradient(180deg,#0a1e8f,#1a63c8);
}
html[data-theme="frutiger"] {
  --chrome-accent: var(--user-accent, #2aa9e0); --chrome-text: #0d3350; --chrome-line: rgba(42,169,224,0.4);
  --tb-bg: linear-gradient(180deg,#ffffff,#c3e8fb 60%,#8fd0f4); --tb-border: rgba(255,255,255,0.9);
  --tb-glow: inset 0 1px 0 rgba(255,255,255,0.95), 0 8px 24px rgba(10,40,72,0.35);
  --sm-bg: linear-gradient(180deg,#f8fcff,#dbeefb); --sm-border: #a9d6ef; --sm-band: linear-gradient(180deg,#8fd0f4,#2aa9e0);
}
html[data-theme="dreamcore"] {
  --chrome-accent: var(--user-accent, #a15ce0); --chrome-text: #4a3560; --chrome-line: rgba(160,92,224,0.35);
  --tb-bg: linear-gradient(180deg,#f7ecff,#d9b8ff); --tb-border: #dcc9f7;
  --tb-glow: 0 8px 26px rgba(201,163,255,0.5), inset 0 1px 0 rgba(255,255,255,0.8);
  --sm-bg: linear-gradient(180deg,#f7ecff,#e6d6ff); --sm-border: #dcc9f7; --sm-band: linear-gradient(180deg,#d9b8ff,#a15ce0);
}
html[data-theme="ethereal"] {
  --chrome-accent: var(--user-accent, #b8860b); --chrome-text: #5a4a26; --chrome-line: rgba(184,134,11,0.35);
  --tb-bg: linear-gradient(180deg,#fffdf0,#f0d98a); --tb-border: #efe0b8;
  --tb-glow: 0 8px 24px rgba(224,184,78,0.45), inset 0 1px 0 rgba(255,255,255,0.9);
  --sm-bg: linear-gradient(180deg,#fffdf4,#f5ead0); --sm-border: #efe0b8; --sm-band: linear-gradient(180deg,#f0d98a,#c9971a);
}
html[data-theme="hyperdigital"] {
  --chrome-accent: var(--user-accent, #39ff14); --chrome-text: #b6ffc2; --chrome-line: rgba(57,255,20,0.4);
  --tb-bg: linear-gradient(180deg,#06210f,#020a06); --tb-border: rgba(57,255,20,0.5);
  --tb-glow: inset 0 1px 0 rgba(57,255,20,0.3), 0 8px 22px rgba(0,0,0,0.7), 0 0 20px rgba(57,255,20,0.25);
  --sm-bg: linear-gradient(180deg,#06210f,#020a06); --sm-border: rgba(57,255,20,0.5); --sm-band: linear-gradient(180deg,#0a3a1a,#062610);
}
html[data-theme="vapor"] {
  --chrome-accent: var(--user-accent, #ff6ad5); --chrome-text: #f2e9ff; --chrome-line: rgba(255,106,213,0.4);
  --tb-bg: linear-gradient(180deg,#3a1a6a,#2a1150); --tb-border: rgba(255,106,213,0.5);
  --tb-glow: inset 0 1px 0 rgba(255,255,255,0.2), 0 8px 24px rgba(0,0,0,0.55), 0 0 22px rgba(123,240,255,0.3);
  --sm-bg: linear-gradient(180deg,#3a1a6a,#22103a); --sm-border: rgba(255,106,213,0.5); --sm-band: linear-gradient(90deg,#ff6ad5,#4fe0ff);
}
html[data-theme="oldweb"] {
  --chrome-accent: var(--user-accent, #0000cc); --chrome-text: #000; --chrome-line: #808080;
  --tb-bg: linear-gradient(180deg,#e8e8e8,#c0c0c0); --tb-border: #000; --tb-radius: 0;
  --tb-glow: inset 1px 1px 0 #fff, inset -1px -1px 0 #808080, 0 3px 8px rgba(0,0,0,0.4);
  --sm-bg: #fffbe6; --sm-border: #000; --sm-band: #000080;
}

/* ============================================================
   ROUNDED-CORNERS toggle (html[data-corners]) — sharp is default.
   Rounds everything that reads var(--radius); skins that hardcode
   their own radius (win98/oldweb) intentionally stay as-is.
   Placed after the theme blocks so it wins the --tb-radius cascade.
   ============================================================ */
html[data-corners="round"] { --radius: var(--radius-round); --tb-radius: 22px; }
html[data-corners="round"] .title-bar-controls .tb-btn { border-radius: 5px; }
html[data-corners="round"] .card, html[data-corners="round"] .pl-card { border-radius: 12px; }

/* ============================================================
   FONT PICKER (html[data-font]) + optional bitmap face.
   The pixel face degrades to a monospace stack if the file is
   absent, so a missing font never breaks the layout.
   ============================================================ */
@font-face {
  font-family: "WebAngelzPixel";
  src: url("/static/fonts/pixel.woff2") format("woff2"),
       url("/static/fonts/pixel.ttf") format("truetype");
  font-display: swap;
}
html[data-font="pixel"] { --font: "WebAngelzPixel", "Monaco", "Courier New", monospace; letter-spacing: .2px; }
html[data-font="mono"]  { --font: var(--mono); }
html[data-font="serif"] { --font: Georgia, "Times New Roman", serif; }
html[data-font="comic"] { --font: "Comic Sans MS", "Comic Sans", "Chalkboard SE", cursive; }

/* ============================================================
   APPEARANCE dialog rows (corners + font pickers)
   ============================================================ */
.appearance-row { display: flex; align-items: center; gap: 12px; margin-top: 14px; flex-wrap: wrap; }
.appearance-label { font-weight: 700; min-width: 58px; color: #eaf1ff; }
.segmented { display: inline-flex; gap: 5px; flex-wrap: wrap; }
.seg-opt { padding: 6px 13px; font-size: 12.5px; cursor: pointer; color: #eaf1ff; font-family: var(--font);
  border: 1px solid rgba(0,216,255,0.4); border-radius: var(--radius);
  background: linear-gradient(180deg,#2a2048,#1a1030); }
.seg-opt:hover { box-shadow: 0 0 10px rgba(0,216,255,0.35); }
.seg-opt.sel { color: var(--accent-ink); font-weight: 700;
  background: linear-gradient(180deg, color-mix(in srgb, var(--accent) 55%, #fff), var(--accent)); }
.seg-pixel { font-family: "WebAngelzPixel", "Monaco", monospace; }
.theme-pick code { font-family: var(--mono); color: var(--accent); }
.dim-slider { display: flex; align-items: center; gap: 10px; flex: 1; min-width: 200px; }
.dim-slider input[type=range] { flex: 1; accent-color: var(--accent); cursor: pointer; height: 4px; }
.dim-ico { font-size: 15px; line-height: 1; }

/* ============================================================
   RESIZE HANDLES — grab an edge/corner to resize (disabled maxed)
   ============================================================ */
.resize-handle { position: absolute; z-index: 6; touch-action: none; }
.rh-se { right: 0; bottom: 0; width: 18px; height: 18px; cursor: nwse-resize; }
.rh-e  { top: 30px; bottom: 14px; right: 0; width: 6px; cursor: ew-resize; }
.rh-s  { left: 14px; right: 14px; bottom: 0; height: 6px; cursor: ns-resize; }
.rh-se::after { content: ""; position: absolute; right: 3px; bottom: 3px; width: 9px; height: 9px;
  border-right: 2px solid var(--accent); border-bottom: 2px solid var(--accent); opacity: .55; }
.panel:hover .rh-se::after { opacity: .9; }
.panel.win-max .resize-handle { display: none; }     /* no resizing while maximized */
.panel.resizing { transition: none !important; user-select: none; }

/* ============================================================
   SPAWNED APP WINDOWS (Upload / Messages opened anywhere)
   ============================================================ */
.panel.spawned {
  position: fixed; top: 74px; left: 0; right: 0; width: min(920px, 94vw);
  margin: 0 auto; max-height: calc(100vh - 150px); overflow: auto;
  box-shadow: var(--shadow), 0 0 30px rgba(0,0,0,0.5);
}
.panel.spawned .msgapp { min-height: 420px; }
/* Maximized spawned window: fill the screen. Needs higher specificity than the
   .panel.spawned rule above (same specificity, later in the file) so its centered
   920px / capped height don't win over .win-max and leave it stuck in a corner. */
.panel.spawned.win-max {
  top: 12px; left: 12px; right: 12px; bottom: 58px;
  width: auto; max-width: none; max-height: none; margin: 0;
}

/* ============================================================
   FLYING BACKGROUND PNG LAYER (user-supplied assets only) —
   behind window content, low opacity, motion-safe.
   ============================================================ */
.bg-flying { position: fixed; inset: 0; z-index: 0; pointer-events: none; overflow: hidden; }
.flyer { position: absolute; left: 0; max-width: 108px; max-height: 108px; opacity: 0.5; will-change: transform;
  animation-name: flyAcross; animation-timing-function: linear; animation-iteration-count: infinite; }
@keyframes flyAcross {
  from { transform: translate(-24vw, 0) rotate(0deg) scale(var(--fs, 1)); }
  to   { transform: translate(118vw, -26px) rotate(340deg) scale(var(--fs, 1)); }
}
@media (prefers-reduced-motion: reduce) { .bg-flying { display: none; } }

/* ============================================================
   COMMUNITY NOTE board (home page)
   ============================================================ */
.cnote-form { display: flex; flex-direction: column; gap: 8px; margin-bottom: 12px; }
.cnote-input { font-size: 15px; line-height: 1.45; }
.cnote-scroll { max-height: 280px; overflow-y: auto; }
.cnote-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 12px; }
.cnote { display: flex; gap: 10px; padding-top: 12px; border-top: 1px solid rgba(0,216,255,0.15); }
.cnote:first-child { border-top: none; padding-top: 0; }
.cnote-ava img, .cnote-ava .avatar-empty { width: 34px; height: 34px; border-radius: 2px; object-fit: cover; box-shadow: 0 0 0 1px rgba(0,216,255,0.5); flex: none; }
.cnote-ava .avatar-empty { display: grid; place-items: center; background: var(--accent); color: #04252e; font-weight: 800; }
.cnote-body { flex: 1; min-width: 0; }
.cnote-head a { color: var(--ink); font-weight: 700; }
.cnote-head a:hover { color: var(--link); }
.cnote-time { color: var(--ink-dim); font-size: 12px; margin-left: 4px; }
.cnote-text { word-wrap: break-word; }
.cnote-empty { color: var(--ink-dim); font-size: 16px; padding: 20px 6px; text-align: center; font-style: italic; }

/* ============================================================
   UPLOAD dropzone icon (SVG, not emoji)
   ============================================================ */
.dropzone-icon { display: flex; gap: 10px; justify-content: center; color: var(--accent); }
.dropzone-icon .ico { width: 30px; height: 30px; }

/* ============================================================
   MESSAGES redesign — per-message avatars, wider bubbles,
   custom scrollbars matching the skin accent.
   ============================================================ */
.msgapp { grid-template-columns: 264px 1fr; min-height: 520px; }
.msgwin { width: 100%; }
/* The window title bar (with the min/max/close controls) stays pinned to the top
   of the messenger window no matter how far the thread is scrolled. */
.msgwin .panel-title { position: sticky; top: 0; z-index: 5; }
/* Classic messenger layout: your own messages hug the RIGHT (avatar on the
   right), the other person's hug the LEFT (avatar on the left). */
.msg-row { display: flex; align-items: flex-end; gap: 8px; }
.msg-row.theirs { flex-direction: row; justify-content: flex-start; }
.msg-row.mine   { flex-direction: row-reverse; justify-content: flex-start; }
.msg-ava { flex: none; }
.msg-ava img, .msg-ava .avatar-empty { width: 30px; height: 30px; border-radius: 9px; object-fit: cover; box-shadow: 0 0 0 1px rgba(0,216,255,0.45); }
.msg-ava .avatar-empty { display: grid; place-items: center; background: var(--accent); color: #04252e; font-weight: 800; font-size: 12px; }
.msg-col { display: flex; flex-direction: column; min-width: 0; max-width: 78%; }
.msg-row.theirs .msg-col { align-items: flex-start; }
.msg-row.mine   .msg-col { align-items: flex-end; }
/* Bubbles are always coloured tiles (like cards), so their text stays fixed light
   regardless of skin — otherwise a light skin's dark --ink is unreadable. Tail
   points bottom-left for theirs, bottom-right for mine. */
.msg-bubble { max-width: 100%; color: #eef3ff; }
.msg-row.theirs .msg-bubble { border-radius: 12px; border-bottom-left-radius: 3px; }
.msg-row.mine   .msg-bubble { border-radius: 12px; border-bottom-right-radius: 3px; }
.msg-time { font-size: 10px; color: var(--ink-dim); margin-top: 3px; }
@media (max-width: 620px) { .msgapp { grid-template-columns: 1fr; } .conv-list { max-height: 180px; } }

/* Custom scrollbars for the hand-built chrome (thread / conversation list /
   community note), tinted with whatever skin accent is in scope. */
.thread, .conv-list, .cnote-scroll { scrollbar-width: thin; scrollbar-color: var(--accent) transparent; }
.thread::-webkit-scrollbar, .conv-list::-webkit-scrollbar, .cnote-scroll::-webkit-scrollbar { width: 11px; }
.thread::-webkit-scrollbar-track, .conv-list::-webkit-scrollbar-track, .cnote-scroll::-webkit-scrollbar-track {
  background: rgba(0,0,0,0.22); border-radius: 8px; }
.thread::-webkit-scrollbar-thumb, .conv-list::-webkit-scrollbar-thumb, .cnote-scroll::-webkit-scrollbar-thumb {
  background: linear-gradient(180deg, var(--accent), color-mix(in srgb, var(--accent) 55%, #000));
  border-radius: 8px; border: 2px solid transparent; background-clip: padding-box; }
.thread::-webkit-scrollbar-thumb:hover, .conv-list::-webkit-scrollbar-thumb:hover, .cnote-scroll::-webkit-scrollbar-thumb:hover {
  background: var(--accent); background-clip: padding-box; }

/* ============================================================
   HEADER REMOVED — floating "WebAngelz" brand overlay + top band
   ============================================================ */
body { padding-top: 32px; }                 /* reserve the top banner strip */
/* Full-width top banner: the wordmark tiled edge to edge on a dark, cool bar. */
.brand-band {
  position: fixed; top: 0; left: 0; right: 0; height: 30px; z-index: 84;
  display: flex; align-items: center; overflow: hidden;
  background: linear-gradient(180deg, rgba(7,12,30,0.95), rgba(9,15,36,0.82));
  border-bottom: 1px solid color-mix(in srgb, var(--chrome-accent) 55%, transparent);
  box-shadow: 0 2px 14px rgba(0,0,0,0.45), inset 0 -1px 0 color-mix(in srgb, var(--chrome-accent) 25%, transparent);
  backdrop-filter: blur(7px);
}
.brand-band:hover { text-decoration: none; }
.brand-track { display: flex; align-items: center; gap: 22px; white-space: nowrap; padding: 0 14px; }
.brand-band .wordmark {
  font-size: 18px; font-weight: 800; letter-spacing: -0.5px; flex: none;
  /* Old-web "shine" wordmark: a white highlight scrolls across the letters.
     The gradient starts AND ends on the accent colour, so the tile butts up
     against its own copy invisibly — as long as one loop scrolls by exactly one
     tile width. With background-size 200%, a percentage offset p resolves to
     p/100 × (W − 2W) = −pW/100, so 0% → −200% moves the pattern exactly 2W = one
     tile, and the loop is seamless. (It used to run 130% → −130% over a 260% tile
     = 1.6 tiles, which restarted mid-pattern and made the jitter.) */
  background-image: linear-gradient(100deg,
      var(--chrome-accent) 0%, var(--chrome-accent) 34%, #ffffff 50%,
      var(--chrome-accent) 66%, var(--chrome-accent) 100%);
  background-size: 200% 100%;
  background-repeat: repeat;
  -webkit-background-clip: text; background-clip: text;
  -webkit-text-fill-color: transparent; color: transparent;
  filter: drop-shadow(0 1px 1px rgba(0,0,0,0.55)) drop-shadow(0 0 8px color-mix(in srgb, var(--chrome-accent) 55%, transparent));
  animation: brandShine 3.6s linear infinite;
}
.brand-band .wordmark:nth-child(3n) { animation-delay: -1.2s; }
.brand-band .wordmark:nth-child(3n+1) { animation-delay: -2.4s; }
@keyframes brandShine { from { background-position: 0% 0; } to { background-position: -200% 0; } }
.brand-band:hover .wordmark { filter: brightness(1.14); }
/* Buzz banner sits flush at the far left, just under the top banner. */
.comment-ticker { padding-left: 0; }
@media (max-width: 560px) {
  .brand-band .wordmark { font-size: 15px; }
}
@media (prefers-reduced-motion: reduce) { .brand-band .wordmark { animation: none; } }

/* Notification button, relocated into the tray (left of the profile) */
.tray-notif { position: relative; color: var(--chrome-accent); display: grid; place-items: center; width: 24px; height: 24px; filter: drop-shadow(0 0 4px color-mix(in srgb, var(--chrome-accent) 50%, transparent)); }
.tray-notif .ico { width: 17px; height: 17px; }
.tray-notif .bell-badge { top: -4px; right: -5px; }

/* Unread badge on the Messages quick-launch icon */
.ql-badged { position: relative; }
.ql-badge { position: absolute; top: -3px; right: -3px; background: var(--magenta); color: #fff; font-size: 9px; font-weight: 800;
  line-height: 1; padding: 1px 4px; border-radius: 8px; box-shadow: 0 0 6px var(--magenta); pointer-events: none; }

/* Settings: appearance opener block */
.settings-appearance { margin-bottom: 16px; padding-bottom: 14px; border-bottom: 1px solid rgba(0,216,255,0.15); }
.settings-appearance .field > span { font-weight: 700; }

/* ============================================================
   ACCENT COLOUR PICKER (Appearance dialog) — recolour any theme
   ============================================================ */
.accent-picker { align-items: center; }
.accent-swatch { width: 26px; height: 26px; padding: 0; border-radius: 50%; background: var(--sw); border: 2px solid rgba(255,255,255,0.35); transition: transform .1s, box-shadow .12s; }
.accent-swatch:hover { transform: translateY(-1px); box-shadow: 0 0 10px var(--sw); }
.accent-swatch.sel { border-color: #fff; box-shadow: 0 0 0 2px var(--accent), 0 0 10px var(--sw); }
.accent-default.sel { background: linear-gradient(180deg, color-mix(in srgb, var(--accent) 55%, #fff), var(--accent)); color: var(--accent-ink); }
.accent-custom { display: inline-flex; align-items: center; gap: 6px; cursor: pointer; }
.accent-custom input[type=color] { width: 22px; height: 22px; padding: 0; border: none; background: none; cursor: pointer; }

/* ============================================================
   CLICK "IMPACT" BURST — a ring + sparks at the pointer
   ============================================================ */
.click-fx { position: fixed; z-index: 9998; pointer-events: none; width: 0; height: 0; }
.click-fx .cfx-ring { position: absolute; left: -11px; top: -11px; width: 22px; height: 22px; border-radius: 50%;
  border: 2px solid var(--chrome-accent); animation: cfxRing .42s ease-out forwards; }
.click-fx .cfx-spark { position: absolute; left: -3px; top: -3px; width: 6px; height: 6px; border-radius: 50%;
  background: var(--chrome-accent); animation: cfxSpark .42s ease-out forwards; }
@keyframes cfxRing { from { transform: scale(.25); opacity: .85; } to { transform: scale(1.7); opacity: 0; } }
@keyframes cfxSpark { from { transform: rotate(var(--a)) translateX(2px) scale(1); opacity: 1; }
                      to   { transform: rotate(var(--a)) translateX(20px) scale(.4); opacity: 0; } }
@media (prefers-reduced-motion: reduce) { .click-fx { display: none; } }

/* Honeypot: kept in the DOM for spam bots, invisible & unreachable for humans. */
.hp { position: absolute !important; left: -9999px !important; width: 1px; height: 1px; overflow: hidden; }

/* Verified-email badge next to a profile name. */
.verified-badge { display: inline-flex; align-items: center; color: #2e9d4e; vertical-align: baseline; }
.verified-badge .ico { width: 16px; height: 16px; }

/* ============================================================
   FORUM — topic list + thread view
   ============================================================ */
.forumpage { display: grid; gap: 16px; max-width: 1040px; margin: 0 auto; }
/* The single-topic ("forum post") view is roomy — bigger text, more air. */
.forumpage-topic { max-width: 1080px; }
.forum-topic-panel .panel-inner { padding: 22px 24px; }
.forum-topic-panel .topic-op-text { font-size: 15.5px; line-height: 1.6; }
.forum-topic-panel .comment-text { font-size: 14.5px; line-height: 1.55; }
.topic-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
/* Theme-adaptive row tint (was a fixed dark fill that put dark theme-text on a
   dark background under light skins). A faint accent wash always contrasts with
   the panel's own --ink text. */
.topic-row { display: flex; gap: 12px; align-items: center; padding: 10px 12px; border-radius: var(--radius);
  background: color-mix(in srgb, var(--accent) 9%, transparent);
  border: 1px solid color-mix(in srgb, var(--accent) 28%, transparent); transition: border-color .14s, box-shadow .14s; }
.topic-row:hover { border-color: var(--accent); box-shadow: 0 0 14px color-mix(in srgb, var(--accent) 30%, transparent); }
.topic-ava { flex: none; }
.topic-ava img, .topic-ava .avatar-empty { width: 40px; height: 40px; border-radius: 9px; object-fit: cover; box-shadow: 0 0 0 1px rgba(0,216,255,0.5); }
.topic-ava .avatar-empty { display: grid; place-items: center; background: var(--accent); color: #04252e; font-weight: 800; }
.topic-main { flex: 1; min-width: 0; }
.topic-title { display: block; font-size: 15px; font-weight: 700; color: var(--ink); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.topic-title:hover { color: var(--link); }
.topic-sub { font-size: 12px; color: var(--ink-dim); margin-top: 2px; }
.topic-sub a { color: var(--ink-dim); }
.topic-sub a:hover { color: var(--link); }
.topic-count { flex: none; display: inline-flex; align-items: center; gap: 5px; font-size: 13px; font-weight: 700; color: var(--accent);
  padding: 4px 10px; border-radius: 12px; background: rgba(0,216,255,0.10); border: 1px solid rgba(0,216,255,0.3); }
.topic-count .ico { width: 14px; height: 14px; }

.topic-op { display: flex; gap: 12px; padding-bottom: 14px; margin-bottom: 4px; border-bottom: 1px solid rgba(0,216,255,0.2); }
.topic-op .topic-ava img, .topic-op .topic-ava .avatar-empty { width: 44px; height: 44px; }
.topic-op-body { flex: 1; min-width: 0; }
.topic-op-head { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.topic-op-head a { color: var(--ink); }
.topic-op-text { margin-top: 8px; word-wrap: break-word; color: var(--ink); }
.topic-replies { margin-top: 6px; }
.topic-replies-head { font-size: 14px; color: var(--ink-dim); margin: 0 0 10px; }
.topic-attach { color: var(--accent); vertical-align: -0.15em; }
.topic-attach .ico { width: 14px; height: 14px; }

/* Forum attachments (image/video inside a topic or reply) */
.forum-media { margin-top: 12px; }
.forum-media img, .forum-media video { max-width: 100%; max-height: 460px; border-radius: var(--radius);
  border: 1px solid rgba(0,216,255,0.3); background: #06040e; }
.forum-media-sm img, .forum-media-sm video { max-height: 280px; }

/* Formatting toolbar (bold / italic / strike) above forum textareas */
.fmt-toolbar { display: flex; align-items: center; gap: 5px; margin-bottom: 6px; flex-wrap: wrap; }
.fmt-btn { width: 30px; height: 27px; display: grid; place-items: center; cursor: pointer; font-size: 14px;
  color: #eaf1ff; border: 1px solid rgba(0,216,255,0.4); border-radius: var(--radius);
  background: linear-gradient(180deg, #2a2048, #1a1030); }
.fmt-btn:hover { box-shadow: 0 0 10px rgba(0,216,255,0.4); }
.fmt-btn:active { transform: translateY(1px); }
.fmt-hint { font-size: 11px; color: var(--ink-dim); margin-left: 6px; }
.forum-reply-attach { margin: 8px 0; }
.forum-reply-attach span { font-weight: 400; }

/* ============================================================
   REACTION STAMPS — one-click feedback row (post page)
   Fixed dark chip (like .btn) so the light icon/text reads on
   every skin — light AND dark panel backgrounds.
   ============================================================ */
.react-row { display: flex; gap: 7px; flex-wrap: wrap; width: 100%; margin-top: 4px; padding-top: 10px; border-top: 1px dashed rgba(127,127,127,0.4); }
.react-btn { display: inline-flex; align-items: center; gap: 5px; font-family: var(--font); font-size: 12px; font-weight: 700;
  color: #eaf1ff; padding: 4px 10px; cursor: pointer; border-radius: var(--radius);
  border: 1px solid rgba(255,255,255,0.3); background: linear-gradient(180deg, #352a55, #1c1338);
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.14), 0 2px 6px rgba(0,0,0,0.35);
  transition: transform .1s, box-shadow .15s, filter .15s; }
.react-btn .ico { width: 14px; height: 14px; }
.react-btn:hover { transform: translateY(-2px); filter: brightness(1.25); box-shadow: 0 4px 10px rgba(0,0,0,0.4); }
.react-btn.on { color: #fff; border-color: #fff; background: var(--accent); box-shadow: 0 0 10px var(--accent); text-shadow: 0 1px 2px rgba(0,0,0,0.45); }
.react-btn.is-static { cursor: default; opacity: 0.8; }
.react-btn.is-static:hover { transform: none; filter: none; box-shadow: inset 0 1px 0 rgba(255,255,255,0.14), 0 2px 6px rgba(0,0,0,0.35); }
.react-n { min-width: 10px; text-align: left; }

/* ============================================================
   BROWSE SEARCH BAR
   ============================================================ */
.searchbar { display: flex; gap: 7px; margin: 0 0 12px; }
.searchbar .input { flex: 1; min-width: 0; }

/* "say hi" link beside a Recently-joined member row. */
.member-li { display: flex; align-items: center; gap: 8px; }
.member-li .member-row { flex: 1; min-width: 0; }
.member-hi { flex: none; font-size: 11px; font-weight: 700; }
