:root {
  color-scheme: dark;
  --piss: #ffcc00;
  --piss-dark: #cc9900;
  --piss-glow: rgba(255, 204, 0, 0.28);
  --bg: #000000;
  --bg-olive: #0a0a00;
  --bg-panel: #090909;
  --panel-edge: #333333;
  --text: #c0c0c0;
  --text-bright: #ffffff;
  --muted: #808080;
  --green: #00ff00;
  --red: #ff0000;
  --purple: #4b0082;
  --ie-blue: #0a246a;
  --ie-blue-light: #3a6ea5;
  --win95-face: #c0c0c0;
  --win95-shadow: #404040;
  --win95-cream: #ece9d8;
}

* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  min-height: 100%;
}

body {
  background: #000;
  color: var(--text);
  font-family: "VT323", "Share Tech Mono", monospace;
  font-size: 16px;
  line-height: 1.4;
  image-rendering: pixelated;
  cursor: default;
  position: relative;
}

.scanlines::after {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 9999;
  background: repeating-linear-gradient(
    0deg,
    transparent,
    transparent 2px,
    rgba(255, 0, 255, 0.06) 2px,
    rgba(255, 0, 255, 0.06) 4px
  );
  animation: scanline 8s linear infinite;
}

@keyframes scanline {
  from {
    transform: translateY(0);
  }

  to {
    transform: translateY(100vh);
  }
}

.connection-strip {
  padding: 4px 16px;
  border-bottom: 1px solid var(--panel-edge);
  background: var(--bg-olive);
  color: var(--muted);
  text-align: center;
  font-size: 14px;
}

.flame-bar {
  background: #000 url("https://pissmissle.fun/pissmissile_content/og_flame.gif") repeat-x bottom;
  background-size: auto 40px;
}

.site-header {
  border-bottom: 2px solid var(--muted);
}

.marquee-ribbon {
  overflow: hidden;
  white-space: nowrap;
  background: var(--piss);
  color: #000;
  font-family: "Press Start 2P", monospace;
  font-size: 9px;
  padding: 3px 0;
}

.marquee-scroll {
  overflow: hidden;
  white-space: nowrap;
}

.marquee-scroll > span {
  display: inline-block;
  animation: marquee 20s linear infinite;
}

@keyframes marquee {
  from {
    transform: translateX(100%);
  }

  to {
    transform: translateX(-100%);
  }
}

.header-inner {
  max-width: 1280px;
  margin: 0 auto;
  padding: 10px 16px 34px;
}

.brand-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
}

.eyebrow,
.hero-kicker,
.skill-kicker,
.ticker-label {
  margin: 0;
  text-transform: uppercase;
  letter-spacing: 0.14em;
}

.eyebrow {
  color: var(--piss);
  font-size: 12px;
  margin-bottom: 6px;
}

h1,
h2 {
  margin: 0;
  color: var(--text-bright);
}

h1 {
  font-family: "Ribeye Marrow", cursive;
  font-size: clamp(36px, 5vw, 64px);
}

.glitch-text {
  position: relative;
  animation: glitch-text 3s ease-in-out infinite;
}

@keyframes glitch-text {
  0%,
  100% {
    text-shadow: 2px 2px var(--red), -2px -2px #00ffff;
    transform: translate(0);
  }

  25% {
    text-shadow: -2px 2px var(--red), 2px -2px #00ffff;
    transform: translate(1px, -1px);
  }

  50% {
    text-shadow: 2px -2px var(--red), -2px 2px #00ffff;
    transform: translate(-1px, 1px);
  }

  75% {
    text-shadow: -2px -2px var(--red), 2px 2px #00ffff;
    transform: translate(1px, 1px);
  }
}

.cycle-readout {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--muted);
  font-family: "Press Start 2P", monospace;
  font-size: 9px;
}

.cycle-label,
.cycle-divider {
  color: var(--red);
}

.cycle-value {
  color: var(--green);
}

.cycle-state {
  color: var(--piss);
}

.top-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 14px;
}

.top-nav a {
  border: 2px outset var(--win95-face);
  background: var(--win95-face);
  color: #000;
  padding: 6px 10px;
  text-decoration: none;
  font-family: "Press Start 2P", monospace;
  font-size: 8px;
}

.top-nav a:hover {
  background: var(--purple);
  color: var(--piss);
  text-shadow: 1px 1px 0 #000;
}

.app-shell {
  width: min(1280px, 100%);
  margin: 0 auto;
  padding: 24px 16px 40px;
}

.hero-panel {
  margin-bottom: 18px;
  text-align: center;
}

.hero-ascii {
  margin: 0 0 8px;
  white-space: pre;
  overflow-x: auto;
  font-size: 8px;
  line-height: 1.05;
}

.piss-glow {
  color: var(--piss);
  text-shadow: 0 0 10px rgba(255, 204, 0, 0.4), 0 0 20px rgba(255, 204, 0, 0.2), 2px 2px #000;
}

.hero-copy {
  max-width: 780px;
  margin: 0 auto;
}

.hero-kicker,
.ticker-label {
  color: var(--red);
  font-family: "Press Start 2P", monospace;
  font-size: 8px;
}

.hero-panel h2 {
  margin-top: 8px;
  color: var(--piss);
  font-family: "Ribeye Marrow", cursive;
  font-size: clamp(24px, 3.4vw, 38px);
  line-height: 1.15;
}

.hero-note,
.skill-note,
.room-copy,
.transcript-line {
  color: var(--text);
}

.hero-note {
  margin: 10px auto 0;
  max-width: 720px;
  font-size: 16px;
}

.ticker-strip {
  display: grid;
  grid-template-columns: minmax(180px, 0.9fr) minmax(360px, 1.5fr) minmax(160px, 0.8fr);
  gap: 12px;
  margin-bottom: 18px;
}

.piss-card {
  background: var(--bg-olive);
  border: 2px outset var(--panel-edge);
  box-shadow: 2px 2px #000;
}

.ticker-pill {
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 48px;
  padding: 10px 12px;
  color: var(--text-bright);
}

.ticker-pill-wide {
  min-width: 0;
}

#ceoTickerStatus,
#ceoTickerActivity,
#pissPriceTicker {
  min-width: 0;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}

.ie6-chrome {
  background: var(--win95-face);
  border: 3px outset var(--win95-face);
  box-shadow: 3px 3px #000;
}

.canvas-shell {
  margin-bottom: 18px;
}

.ie6-titlebar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 22px;
  padding: 2px 4px;
  background: linear-gradient(90deg, var(--ie-blue), var(--ie-blue-light));
  color: #fff;
  font-family: Tahoma, sans-serif;
  font-size: 11px;
  font-weight: 700;
}

.titlebar-group,
.titlebar-buttons {
  display: flex;
  align-items: center;
  gap: 4px;
}

.titlebar-icon {
  font-size: 12px;
}

.win95-btn {
  border: 2px outset var(--win95-face);
  background: var(--win95-face);
  color: #000;
  cursor: pointer;
  padding: 2px 8px;
  font-family: "Press Start 2P", monospace;
  font-size: 8px;
  text-shadow: none;
}

.win95-btn:active {
  border-style: inset;
}

.ie6-menubar,
.ie6-addressbar,
.ie6-statusbar {
  display: flex;
  align-items: center;
  gap: 12px;
  background: var(--win95-cream);
  color: #000;
  font-family: Tahoma, sans-serif;
}

.ie6-menubar {
  border-bottom: 1px solid #aca899;
  padding: 3px 8px;
  font-size: 11px;
}

.ie6-addressbar {
  gap: 6px;
  border-bottom: 1px solid #aca899;
  padding: 4px;
}

.address-field {
  flex: 1;
  min-width: 0;
  border: 2px inset var(--win95-face);
  background: #fff;
  color: #000;
  padding: 4px 8px;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
  font-size: 11px;
}

.ie6-statusbar {
  justify-content: space-between;
  border-top: 1px solid #aca899;
  padding: 4px 8px;
  font-size: 10px;
  flex-wrap: wrap;
}

.canvas-frame {
  position: relative;
  overflow: auto;
  padding: 16px;
  background:
    linear-gradient(180deg, rgba(20, 20, 20, 0.96), rgba(0, 0, 0, 0.98)),
    #111;
}

.canvas-frame::before {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background:
    linear-gradient(130deg, transparent 0 33%, rgba(255, 255, 255, 0.025) 33% 36%, transparent 36% 100%),
    linear-gradient(35deg, transparent 0 62%, rgba(255, 255, 255, 0.018) 62% 65%, transparent 65% 100%);
  opacity: 0.7;
}

canvas {
  display: block;
  width: min(1100px, 100%);
  height: auto;
  border: 2px inset var(--win95-face);
  background: #000;
  image-rendering: pixelated;
  image-rendering: crisp-edges;
}

.panel-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(0, 0.85fr);
  gap: 18px;
  margin-bottom: 18px;
}

.panel-body {
  background: var(--bg-panel);
  padding: 16px;
}

.skill-panel h2,
.room-panel h2,
.transcript-panel h2 {
  font-size: 24px;
  color: var(--text-bright);
}

.skill-kicker {
  margin-bottom: 8px;
  color: var(--green);
  font-family: "Press Start 2P", monospace;
  font-size: 8px;
}

.skill-note {
  margin-top: 8px;
  font-size: 15px;
  line-height: 1.5;
}

.skill-form {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 16px;
}

.skill-form input,
.skill-form select {
  border: 2px inset var(--win95-face);
  background: #000;
  color: var(--text-bright);
  padding: 10px 12px;
  font: inherit;
}

.skill-form button {
  border: 2px outset var(--win95-face);
  background: var(--purple);
  color: var(--piss);
  padding: 10px 14px;
  font-family: "Press Start 2P", monospace;
  font-size: 9px;
  text-shadow: 1px 1px 0 #000;
}

#agentName,
#agentRole,
#agentCustomRole,
#agentJob,
#agentHairColor,
#agentSkinColor,
#agentShirtColor,
#agentPantsColor,
#agentAccessory,
#agentShoes {
  min-width: 180px;
}

#agentPersonality,
#agentSkills {
  min-width: 260px;
}

.skill-status {
  margin-top: 12px;
  color: var(--piss);
  font-size: 13px;
}

.skill-registry {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 10px;
  margin-top: 12px;
}

.registry-card {
  border: 2px outset var(--panel-edge);
  background: var(--bg-olive);
  padding: 10px;
  box-shadow: 2px 2px #000;
}

.registry-name {
  margin: 0 0 6px;
  color: var(--text-bright);
  font-size: 14px;
}

.registry-meta {
  margin: 0;
  color: var(--green);
  font-size: 12px;
}

.registry-detail {
  margin: 6px 0 0;
  color: var(--text);
  font-size: 12px;
  line-height: 1.45;
}

.room-inspector,
.chat-transcript {
  margin-top: 14px;
  border: 2px inset var(--win95-face);
  background: #000;
  padding: 14px;
}

.room-inspector {
  min-height: 160px;
}

.room-name {
  margin: 0 0 8px;
  color: var(--piss);
  font-size: 17px;
}

.room-copy {
  margin: 0 0 8px;
  font-size: 14px;
  line-height: 1.5;
}

.chat-transcript {
  min-height: 190px;
  max-height: 320px;
  overflow: auto;
}

.transcript-line {
  margin: 0 0 8px;
  font-size: 13px;
  line-height: 1.45;
}

.transcript-line strong {
  color: var(--green);
}

::-webkit-scrollbar {
  width: 16px;
  height: 16px;
}

::-webkit-scrollbar-track {
  background: var(--win95-face);
  border: 1px inset gray;
}

::-webkit-scrollbar-thumb {
  background: var(--win95-face);
  border: 2px outset var(--win95-face);
}

::-webkit-scrollbar-thumb:hover {
  background: #d4d0c8;
}

::-webkit-scrollbar-button {
  height: 16px;
  background: var(--win95-face);
  border: 2px outset var(--win95-face);
}

@media (max-width: 1100px) {
  .ticker-strip,
  .panel-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 720px) {
  body {
    font-size: 15px;
  }

  .header-inner,
  .app-shell {
    padding-left: 12px;
    padding-right: 12px;
  }

  .hero-panel h2 {
    font-size: 28px;
  }

  .hero-ascii {
    font-size: 6px;
  }

  .skill-form {
    flex-direction: column;
  }

  #agentName,
  #agentRole,
  #agentCustomRole,
  #agentJob,
  #agentHairColor,
  #agentSkinColor,
  #agentShirtColor,
  #agentPantsColor,
  #agentAccessory,
  #agentShoes,
  #agentPersonality,
  #agentSkills {
    min-width: 0;
    width: 100%;
  }

  .ie6-statusbar {
    gap: 6px;
  }
}
