/* Jukebox — goblincock.tf-inspired ASCII/terminal theme. No JS. */

@font-face {
  font-family: "Pixelout";
  src: url("fonts/Pixelout.ttf") format("truetype");
  font-display: swap;
}
@font-face {
  font-family: "CyberPunk";
  src: url("fonts/CyberpunkWaifus.ttf") format("truetype");
  font-display: swap;
}
@font-face {
  font-family: "VT323";
  src: url("fonts/VT323-Regular.ttf") format("truetype");
  font-display: swap;
}

:root {
  --bg: rgba(0, 0, 0, 0.955);
  --footer-bg: rgb(14, 14, 14);
  --text: #ffffff;
  --muted: #888888;
  --green: rgb(42, 232, 115);
  --pink: #fb85ce;
  --orange: rgb(255, 133, 89);
  --blue: #05D9FF;
  /* Height of the chat / comments auto-scroll box. Override via the
     JUKEBOX_CHAT_HEIGHT setting (injected into the page <head>). */
  --chat-height: 360px;
}

* { box-sizing: border-box; margin: 0; padding: 0; }

/* The [hidden] attribute must win over element/.btn display rules below
   (author rules otherwise override the UA [hidden]{display:none}). */
[hidden] { display: none !important; }

html, body {
  background-color: var(--bg);
  color: var(--text);
  font-family: "CyberPunk", "VT323", "Courier New", monospace;
  font-size: 20px;
  line-height: 1.4;
  min-height: 100vh;
}

::selection { background-color: var(--green); color: #000; }

a {
  color: var(--pink);
  text-decoration: none;
}
a:hover { text-decoration: underline; }

p { margin-top: 8px; line-height: 25px; }
p + p { margin-top: 8px; }

h1, h2, h3 {
  color: var(--green);
  font-family: "VT323", monospace;
  font-weight: 400;
}
h1 { font-size: 32px; margin-bottom: 4px; }
h2 { font-size: 26px; margin-bottom: 4px; }
h3 { font-size: 24px; margin-top: 16px; }

hr {
  border: none;
  border-top: 1px dashed #333;
  margin: 12px 0;
}

code {
  font-family: "VT323", monospace;
  color: var(--blue);
  background: transparent;
}

.muted { color: var(--muted); }
.small { font-size: 16px; }
.error { color: var(--orange); }

.pink, a.pink { color: var(--pink); }
.orange, a.orange { color: var(--orange); }
.blue, a.blue { color: var(--blue); }
.green, a.green { color: var(--green); }

/* ---- Header (big pixel logo) ---- */
header.brandbar {
  font-family: "Pixelout", "Courier New", monospace;
  color: var(--green);
  font-size: 60px;
  letter-spacing: 3px;
  font-weight: 400;
  margin: 1% 0 0 5%;
  padding-top: 20px;
  text-transform: lowercase;
}
header.brandbar a {
  color: var(--green);
  text-decoration: none;
}
header.brandbar a:hover { text-decoration: none; }

/* ---- Layout ---- */
.content {
  width: 80%;
  left: 10%;
  position: relative;
  padding-bottom: 40px;
}

.push_in {
  margin-left: 4%;
  padding-bottom: 5px;
}

/* ---- Menu (inline pink links) ---- */
.menu_links a {
  color: var(--blue);
  margin-right: 16px;
}
.menu_links a:hover { color: var(--pink); text-decoration: none; }
.menu_links .me {
  color: var(--orange);
  margin-left: 8px;
}

/* ---- Forms / inputs ---- */
input[type="text"],
input[type="search"],
input[type="url"] {
  background: transparent;
  border: 1px solid var(--pink);
  color: var(--text);
  font-family: inherit;
  font-size: 18px;
  padding: 4px 8px;
  outline: none;
  height: 30px;
}
input[type="text"]:focus,
input[type="search"]:focus,
input[type="url"]:focus { border-color: var(--blue); }
input::placeholder { color: var(--muted); }

button,
.btn {
  background: transparent;
  border: 1px solid var(--pink);
  color: var(--pink);
  font-family: inherit;
  font-size: 18px;
  padding: 2px 12px;
  cursor: pointer;
  text-decoration: none;
  display: inline-block;
  line-height: 24px;
  height: 30px;
}
button:hover,
.btn:hover {
  background: var(--pink);
  color: #000;
  text-decoration: none;
}

.btn.primary {
  border-color: var(--green);
  color: var(--green);
}
.btn.primary:hover {
  background: var(--green);
  color: #000;
}

.btn-icon {
  padding: 0;
  width: 28px;
  min-width: 28px;
  height: 28px;
  line-height: 24px;
  font-size: 16px;
  text-align: center;
}

.btn-danger {
  border-color: var(--orange);
  color: var(--orange);
}
.btn-danger:hover {
  background: var(--orange);
  color: #000;
}

.row-form {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  align-items: center;
  margin-top: 8px;
}
.row-form input[type="text"],
.row-form input[type="search"],
.row-form input[type="url"] {
  flex: 1;
  min-width: 220px;
}

/* ---- Box list ---- */
.box-list { list-style: none; }
.box-list li {
  padding: 2px 0;
}
.box-list li::before {
  content: "* ";
  color: var(--pink);
}
.box-list a { color: var(--text); }
.box-list a:hover { color: var(--pink); }

/* ---- Queue table ---- */
.queue {
  width: 100%;
  border-collapse: collapse;
  font-size: 18px;
}
.queue th, .queue td {
  padding: 4px 8px;
  text-align: left;
  vertical-align: middle;
}
.queue th {
  color: var(--green);
  font-weight: 400;
  border-bottom: 1px dashed #444;
  font-size: 16px;
  text-transform: uppercase;
  letter-spacing: 1px;
}
.queue td { border-bottom: 1px dashed #222; }
.queue td.pos { color: var(--muted); width: 32px; text-align: right; }
.queue td.thumb { width: 130px; }
.queue td.thumb img { display: block; border: 1px solid var(--pink); }
.queue td.title .t { color: var(--text); }
.queue td.dur { color: var(--muted); width: 60px; }
.queue td.status { width: 90px; }
.queue td.ops form { display: inline-block; margin-right: 2px; }
.queue tr.playing td .t { color: var(--orange); }
.queue tr.played td { opacity: 0.5; }

/* ---- Player ---- */
.player {
  margin: 12px 0;
}
.player iframe {
  border: 2px solid var(--pink);
  max-width: 100%;
  background: #000;
}

.now-playing { margin-top: 10px; }
.now-playing h2 {
  color: var(--orange);
  font-family: "VT323", monospace;
  font-size: 24px;
}
.now-playing .added-by { margin-top: 6px; }
.now-playing form { margin-top: 10px; }

/* ---- Search results ---- */
.search-results { list-style: none; margin-top: 8px; }
.search-result {
  display: flex;
  gap: 10px;
  align-items: center;
  padding: 3px 0;
}
.search-result::before {
  content: "* ";
  color: var(--pink);
}
.search-result img { border: 1px solid var(--pink); }
.search-result .meta { flex: 1; min-width: 0; }
.search-result .t { color: var(--text); }
.search-result .add-form { margin: 0; }

/* ---- Tags (status chips) ---- */
.tag {
  display: inline-block;
  font-family: inherit;
  font-size: 14px;
  padding: 0 6px;
  border: 1px solid;
  letter-spacing: 1px;
  text-transform: uppercase;
}
.tag.queued { color: var(--blue); border-color: var(--blue); }
.tag.playing { color: var(--orange); border-color: var(--orange); }
.tag.played { color: var(--muted); border-color: var(--muted); }

.badge {
  color: var(--green);
}

/* ---- Footer ---- */
footer.foot {
  width: 100%;
  text-align: center;
  font-family: "VT323", monospace;
  font-size: 20px;
  font-weight: 100;
  margin-top: 5%;
  margin-bottom: 2%;
  color: #ffffff;
}
footer.foot a { color: var(--pink); }

/* ---- Chat / comments (fixed-height auto-scroll log) ---- */
.chat-wrap { position: relative; margin-top: 8px; }
.chat-log {
  list-style: none;
  height: var(--chat-height, 360px);
  overflow-y: auto;
  overflow-anchor: none;
  border: 1px solid #333;
  padding: 6px 10px;
  font-size: 18px;
  scrollbar-width: thin;
}
.chat-log li {
  padding: 2px 0;
  overflow-wrap: anywhere;
}
.chat-log li .badge { margin-right: 4px; }
.chat-jump {
  position: absolute;
  right: 18px;        /* sit just left of the scrollbar */
  bottom: 8px;
  height: auto;
  line-height: 18px;
  font-size: 14px;
  padding: 2px 12px;
  border-color: var(--blue);
  color: var(--blue);
  background: rgba(0, 0, 0, 0.88);
  z-index: 2;
}
.chat-jump:hover { background: var(--blue); color: #000; }

/* ---- Mobile ---- */
@media (max-width: 640px) {
  header.brandbar { font-size: 36px; margin-left: 4%; }
  .content { width: 92%; left: 4%; }
  .queue td.thumb { display: none; }
  .queue td.status { display: none; }
  .player iframe { width: 100%; height: auto; aspect-ratio: 16 / 9; }
  .row-form input[type="text"],
  .row-form input[type="search"],
  .row-form input[type="url"] { min-width: 0; width: 100%; }
}
