:root {
  --bg: #1a0033;
  --panel: #c0c0c0;
  --hot: #ff00ff;
  --lime: #00ff00;
  --cyan: #00ffff;
  --yellow: #ffff00;
  --ink: #000;
  --touch: 44px;
  --ms-orange: #ff6600;
  --ms-blue: #003399;
}
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  marquee, .blink, .sparkle, .spin, .jiggling, .spinning, .wobbling { animation: none !important; }
}
body.earlyweb, body {
  margin: 0;
  font-family: "Comic Sans MS", "Comic Sans", "Trebuchet MS", Geneva, Tahoma, sans-serif;
  color: var(--yellow);
  background:
    radial-gradient(circle at 10% 20%, #ff00aa55 0, transparent 35%),
    radial-gradient(circle at 90% 10%, #00ffff44 0, transparent 30%),
    radial-gradient(circle at 50% 100%, #ffff0044 0, transparent 40%),
    repeating-linear-gradient(45deg, #120028 0 10px, #1a0033 10px 20px);
  min-height: 100vh;
  line-height: 1.45;
  -webkit-font-smoothing: antialiased;
}
a { color: var(--cyan); }
a:visited { color: #cc99ff; }
a:focus-visible, button:focus-visible, .fun-click:focus-visible {
  outline: 3px solid var(--yellow);
  outline-offset: 3px;
}
img { max-width: 100%; height: auto; display: block; }
.skip {
  position: absolute; left: -9999px; top: auto;
  width: 1px; height: 1px; overflow: hidden;
}
.skip:focus {
  position: fixed; left: 8px; top: 8px; z-index: 99;
  width: auto; height: auto; padding: 10px 14px;
  background: var(--yellow); color: #000; font-weight: bold;
}
.wrap {
  width: min(980px, 100% - 1rem);
  margin: 0.6rem auto 2rem;
}
.win95 {
  background: var(--panel);
  color: var(--ink);
  border: 3px solid;
  border-color: #ffffff #404040 #404040 #ffffff;
  box-shadow: 6px 6px 0 #000, 0 0 0 4px #ff00ff, 0 0 0 8px #00ffff;
}
.titlebar {
  background: linear-gradient(90deg, #000080, #1084d0 40%, #ff00aa);
  color: #fff;
  font-weight: bold;
  font-family: "MS Sans Serif", Tahoma, sans-serif;
  font-size: 13px;
  padding: 4px 8px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}
.titlebar .btns span {
  display: inline-block;
  width: 16px; height: 14px;
  background: var(--panel);
  border: 2px solid;
  border-color: #fff #404040 #404040 #fff;
  color: #000;
  font-size: 10px;
  line-height: 10px;
  text-align: center;
  margin-left: 2px;
  cursor: pointer;
  touch-action: manipulation;
}
.panel-body { padding: 12px; }
marquee {
  background: #000;
  color: var(--lime);
  border: 3px solid var(--hot);
  padding: 4px 0;
  font-family: "Courier New", monospace;
  margin-bottom: 10px;
  box-shadow: 0 0 12px #ff00ff;
}
.nav {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 0 0 12px;
}
.nav a {
  min-height: var(--touch);
  display: inline-flex;
  align-items: center;
  padding: 8px 14px;
  background: linear-gradient(#3366ff, #000088);
  color: #ffff00 !important;
  border: 3px outset #6699ff;
  text-decoration: none;
  font-weight: bold;
  box-shadow: 2px 2px 0 #000;
}
.nav a:active { border-style: inset; }
.nav a[aria-current="page"] {
  background: linear-gradient(#ff66cc, #990066);
  border-color: #ff99ff;
}
.footer {
  margin-top: 1rem;
  text-align: center;
  font-size: 0.85rem;
  color: #ffccff;
  font-family: Tahoma, sans-serif;
}
.footer a { color: #ffff66; }
.blurb {
  background: #fff0ff;
  border: 4px ridge #ff00aa;
  padding: 10px;
  color: #330033;
  font-family: Tahoma, sans-serif;
}
.blurb h2 {
  margin: 0 0 0.4rem;
  color: #cc0066;
  text-shadow: 1px 1px 0 #ffccff;
  font-family: "Comic Sans MS", cursive, sans-serif;
}
.blink { animation: blink 1.1s step-start infinite; }
@keyframes blink { 50% { opacity: 0; } }
.sparkle {
  animation: sparkle 1.4s ease-in-out infinite;
}
@keyframes sparkle {
  0%, 100% { text-shadow: 0 0 2px #fff, 0 0 8px #ff0; }
  50% { text-shadow: 0 0 6px #f0f, 0 0 16px #0ff; }
}
.badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: var(--touch);
  padding: 6px 12px;
  border: 3px outset #fff;
  background: linear-gradient(#ffff99, #ff9900);
  color: #000;
  font-weight: bold;
  font-size: 0.85rem;
  text-decoration: none;
  box-shadow: 2px 2px 0 #000;
  cursor: pointer;
}
.badge:active { border-style: inset; }
.badge.blue { background: linear-gradient(#aaddff, #3366ff); color: #fff; }
.badge.green { background: linear-gradient(#ccffcc, #00aa00); color: #003300; }
.badge.pink { background: linear-gradient(#ffccff, #ff00aa); color: #fff; }

/* Fun clickable chrome — jiggle / spin / wobble */
.fun-click {
  cursor: pointer;
  touch-action: manipulation;
  -webkit-tap-highlight-color: transparent;
  user-select: none;
  -webkit-user-select: none;
}
.fun-click:focus-visible { outline: 3px solid var(--yellow); outline-offset: 2px; }
@keyframes jiggle {
  0%, 100% { transform: rotate(0deg) translateX(0); }
  20% { transform: rotate(-10deg) translateX(-2px); }
  40% { transform: rotate(10deg) translateX(2px); }
  60% { transform: rotate(-6deg) translateX(-1px); }
  80% { transform: rotate(6deg) translateX(1px); }
}
@keyframes spin-once {
  from { transform: rotate(0deg) scale(1); }
  50% { transform: rotate(180deg) scale(1.12); }
  to { transform: rotate(360deg) scale(1); }
}
@keyframes wobble {
  0%, 100% { transform: translateY(0) scale(1); }
  25% { transform: translateY(-4px) scale(1.06); }
  50% { transform: translateY(2px) scale(0.98); }
  75% { transform: translateY(-2px) scale(1.03); }
}
.jiggling { animation: jiggle 0.5s ease-in-out; }
.spinning { animation: spin-once 0.55s ease-in-out; }
.wobbling { animation: wobble 0.45s ease-in-out; }
.friend a {
  display: block;
  text-decoration: none;
  color: inherit;
  min-height: var(--touch);
}
.friend a:hover .avatar { filter: brightness(1.15); }
.friend .avatar {
  transition: transform 0.15s ease;
}

@media (max-width: 700px) {
  .wrap { width: min(100% - 0.6rem, 980px); }
  body { font-size: 16px; }
}
