/* AGENTIC RADIO — late-night hi-fi. Bungee (display), Inter (text), Space Mono (numbers). */
@font-face { font-family: "Bungee"; src: url(../fonts/bungee-latin-400-normal.woff2) format("woff2"); font-display: swap; }
@font-face { font-family: "Inter"; src: url(../fonts/inter-latin-400-normal.woff2) format("woff2"); font-weight: 400; font-display: swap; }
@font-face { font-family: "Inter"; src: url(../fonts/inter-latin-500-normal.woff2) format("woff2"); font-weight: 500; font-display: swap; }
@font-face { font-family: "Inter"; src: url(../fonts/inter-latin-700-normal.woff2) format("woff2"); font-weight: 700; font-display: swap; }
@font-face { font-family: "SpaceMono"; src: url(../fonts/space-mono-latin-400-normal.woff2) format("woff2"); font-weight: 400; font-display: swap; }
@font-face { font-family: "SpaceMono"; src: url(../fonts/space-mono-latin-700-normal.woff2) format("woff2"); font-weight: 700; font-display: swap; }

:root {
  --bg: #0c0a14; --bg2: #121019; --panel: #17141f; --panel2: #1f1a29; --line: #2a2536; --line2: #3b3449;
  --ink: #f5f1e6; --mute: #a39cb0; --dim: #6e6680; --y: #fcd535; --amber: #ffb547; --pink: #ff7ab6; --cyan: #5ad1ff;
  --red: #ff4d5e; --g: #2ebd85;
  --dp: "Bungee", system-ui, sans-serif; --tx: "Inter", system-ui, sans-serif; --mono: "SpaceMono", ui-monospace, monospace;
  --wrap: 1240px; --r: 6px;
}
* { box-sizing: border-box; }
[hidden] { display: none !important; }
html { scroll-behavior: smooth; scroll-padding-top: 72px; }
body {
  margin: 0; color: var(--ink); font: 400 16px/1.55 var(--tx); -webkit-font-smoothing: antialiased; overflow-x: hidden;
  background-color: var(--bg);
  background-image:
    radial-gradient(800px 520px at 78% 160px, rgba(255, 122, 182, .10), transparent 70%),
    radial-gradient(700px 500px at 10% 30px, rgba(252, 213, 53, .07), transparent 70%),
    radial-gradient(rgba(255, 255, 255, .045) 1px, transparent 1.4px);
  background-size: auto, auto, 14px 14px;
}
a { color: inherit; }
code, .num { font-family: var(--mono); }
.num { font-variant-numeric: tabular-nums; }
.wrap { max-width: var(--wrap); margin: 0 auto; padding: 0 24px; }
button { font: inherit; color: inherit; cursor: pointer; }
:focus-visible { outline: 2px solid var(--y); outline-offset: 2px; }

/* header */
.bar { position: sticky; top: 0; z-index: 30; background: rgba(12, 10, 20, .86); backdrop-filter: blur(10px); border-bottom: 1px solid var(--line); }
.bar .wrap { display: flex; align-items: center; gap: 18px; height: 62px; }
.logo { display: flex; align-items: center; gap: 10px; text-decoration: none; }
.logo b { font: 400 19px/1 var(--dp); letter-spacing: .02em; }
.nav { display: flex; gap: 4px; }
.nav a { text-decoration: none; color: var(--mute); padding: 6px 10px; border-radius: var(--r); font-weight: 500; white-space: nowrap; }
.nav a:hover { color: var(--ink); background: var(--panel2); }
.spacer { flex: 1; }
.search input, .lib-tools input { width: 190px; background: var(--bg2); border: 1px solid var(--line); color: var(--ink); border-radius: var(--r); padding: 8px 12px; font: 400 14px var(--mono); }
.search input::placeholder, .lib-tools input::placeholder { color: var(--dim); }
.chain { display: flex; align-items: center; gap: 8px; font: 700 12px var(--mono); color: var(--mute); border: 1px solid var(--line); padding: 6px 11px; border-radius: 99px; white-space: nowrap; }
.chain i { width: 8px; height: 8px; border-radius: 50%; background: var(--dim); }
.chain.live i { background: var(--g); box-shadow: 0 0 0 3px rgba(46, 189, 133, .2); }
.chain.preview i { background: var(--amber); }
.burger { display: none; background: none; border: 1px solid var(--line); border-radius: var(--r); width: 40px; height: 36px; font-size: 20px; }
.notice { background: #2a2012; color: #f6dd8a; border-bottom: 1px solid #4a3a14; text-align: center; padding: 9px 16px; font-size: 14px; }
.notice b { color: var(--y); }

/* hero */
.hero { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 640px); gap: 46px; padding-top: 46px; padding-bottom: 30px; align-items: start; }
.tag { display: inline-flex; align-items: center; gap: 8px; font: 700 12px var(--mono); text-transform: uppercase; letter-spacing: .1em; color: var(--mute); border: 1px solid var(--line); padding: 6px 12px; border-radius: 99px; background: var(--bg2); }
.tag .dot { width: 8px; height: 8px; border-radius: 50%; background: var(--red); box-shadow: 0 0 10px var(--red); }
h1 { font: 400 clamp(60px, 7.4vw, 110px)/.92 var(--dp); margin: 22px 0 16px; color: var(--ink); letter-spacing: .01em; }
h1 span { color: var(--y); text-shadow: 0 0 34px rgba(252, 213, 53, .35); }
.sub { font: 700 clamp(22px, 2.2vw, 28px)/1.25 var(--tx); margin: 0 0 14px; letter-spacing: -.01em; }
.lede { color: #cfc8d8; max-width: 560px; margin: 0 0 22px; }
.lede q { color: var(--ink); font-style: italic; quotes: "“" "”"; }
.cta { display: flex; gap: 12px; flex-wrap: wrap; margin-bottom: 26px; }
.btn { display: inline-block; text-decoration: none; font: 700 15px var(--tx); padding: 12px 18px; border-radius: 99px; border: 1px solid var(--line2); background: var(--panel); transition: transform .12s, background .12s; }
.btn:hover { transform: translateY(-1px); background: var(--panel2); }
.btn.y { background: var(--y); color: var(--bg); border-color: var(--y); box-shadow: 0 8px 26px rgba(252, 213, 53, .25); }
.btn.y:hover { background: #ffe066; }
.supply { background: var(--panel); border: 1px solid var(--line); border-radius: 10px; padding: 16px 18px; max-width: 560px; }
.supply-t { display: flex; justify-content: space-between; font-size: 15px; color: var(--mute); }
.supply-t b { color: var(--ink); font-size: 20px; }
.meter { height: 10px; background: #0e0c15; border: 1px solid var(--line); border-radius: 99px; margin: 10px 0 12px; overflow: hidden; }
.meter i { display: block; height: 100%; width: 0; background: linear-gradient(90deg, var(--pink), var(--y)); border-radius: 99px; transition: width .6s; }
.supply-b { display: flex; gap: 18px; flex-wrap: wrap; font-size: 14px; color: var(--mute); }
.supply-b b { color: var(--ink); }

/* console */
.console { background: linear-gradient(160deg, #2a2335, #18141f 60%); border-radius: 18px; padding: 16px; box-shadow: 0 40px 90px rgba(0, 0, 0, .6), inset 0 1px 0 rgba(255, 255, 255, .07), 0 0 0 1px #08070c; }
.c-top { display: flex; align-items: center; gap: 14px; margin-bottom: 12px; }
.onair { display: inline-flex; align-items: center; gap: 8px; font: 400 14px var(--dp); letter-spacing: .06em; color: #6b4a52; border: 2px solid #4a2f37; border-radius: 6px; padding: 4px 10px; background: #1a1016; transition: .3s; }
.onair i { width: 9px; height: 9px; border-radius: 50%; background: #5a2a33; }
.onair.on { color: #fff; border-color: var(--red); background: #3a0f18; box-shadow: 0 0 22px rgba(255, 77, 94, .45); }
.onair.on i { background: var(--red); box-shadow: 0 0 10px var(--red); }
.dial { position: relative; flex: 1; height: 34px; background: linear-gradient(#ffd27a, #e9a83d); border-radius: 6px; box-shadow: inset 0 2px 6px rgba(0, 0, 0, .45); overflow: hidden; }
.dial-scale { position: absolute; inset: 0; display: flex; justify-content: space-between; align-items: flex-end; padding: 0 8px 4px; font: 700 9px var(--mono); color: #5a3a0a; }
.dial-scale span { display: flex; flex-direction: column; align-items: center; gap: 1px; }
.dial-scale span::before { content: ""; width: 1px; height: 9px; background: #5a3a0a; }
.needle { position: absolute; top: 3px; bottom: 3px; width: 3px; background: var(--red); left: 8px; border-radius: 2px; box-shadow: 0 0 6px rgba(255, 77, 94, .7); transition: left .8s cubic-bezier(.3, 1.4, .5, 1); }
.freq { font: 700 18px var(--mono); color: var(--amber); min-width: 70px; text-align: right; text-shadow: 0 0 10px rgba(255, 181, 71, .5); }
.screen { position: relative; aspect-ratio: 16 / 9; background: #0b0910; border-radius: 10px; box-shadow: inset 0 0 0 1px #2c2638, inset 0 6px 24px rgba(0, 0, 0, .6); overflow: hidden; }
.screen canvas { position: absolute; inset: 0; width: 100%; height: 100%; }
.tune { position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%); background: var(--y); color: var(--bg); border: 0; border-radius: 99px; padding: 14px 26px; font: 400 18px var(--dp); letter-spacing: .04em; box-shadow: 0 0 0 8px rgba(252, 213, 53, .18), 0 10px 30px rgba(0, 0, 0, .5); }
.tune span { margin-right: 6px; }
.np { display: flex; justify-content: space-between; align-items: flex-end; gap: 12px; margin: 14px 4px 10px; }
.np-l { min-width: 0; }
.np-t { font: 400 26px/1.1 var(--dp); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.np-s { color: var(--mute); font-size: 14px; margin-top: 4px; }
.np-s span:first-child { color: var(--ink); font-weight: 700; }
.np-r { display: flex; flex-direction: column; align-items: flex-end; gap: 6px; flex: 0 0 auto; }
.crown { font: 700 11px var(--mono); background: var(--y); color: var(--bg); padding: 3px 9px; border-radius: 99px; letter-spacing: .04em; }
.votes { font-size: 12px; color: var(--mute); }
.ctrl { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; padding: 10px 4px; border-top: 1px solid var(--line); }
.cb { width: 42px; height: 42px; border-radius: 50%; border: 1px solid var(--line2); background: var(--panel2); font-size: 15px; display: grid; place-items: center; }
.cb.play { width: 52px; height: 52px; background: var(--y); color: var(--bg); border: 0; font-size: 18px; }
.cb:hover { filter: brightness(1.15); }
.seg { display: inline-flex; border: 1px solid var(--line); border-radius: 99px; overflow: hidden; }
.seg button { background: transparent; border: 0; padding: 7px 12px; font: 700 12px var(--mono); color: var(--mute); }
.seg button.on { background: var(--panel2); color: var(--y); }
.vol { display: flex; align-items: center; gap: 8px; margin-left: auto; font: 700 11px var(--mono); color: var(--dim); }
.vol input { width: 90px; accent-color: var(--y); }
.next { display: flex; gap: 12px; align-items: baseline; padding: 8px 4px 2px; border-top: 1px solid var(--line); font-size: 13px; color: var(--mute); }
.next-l { font: 700 11px var(--mono); text-transform: uppercase; letter-spacing: .1em; color: var(--dim); white-space: nowrap; }
.next ol { list-style: none; margin: 0; padding: 0; display: flex; gap: 14px; overflow: hidden; white-space: nowrap; }
.next li { cursor: pointer; overflow: hidden; text-overflow: ellipsis; }
.next li:hover { color: var(--ink); }
.next li b { color: var(--ink); font-weight: 500; }

/* sections */
.sect { padding-top: 76px; }
.sect-h { display: flex; justify-content: space-between; align-items: baseline; gap: 16px; flex-wrap: wrap; margin-bottom: 14px; }
h2 { font: 400 clamp(30px, 3.6vw, 44px)/1 var(--dp); margin: 0; }
h3 { font: 700 19px/1.25 var(--tx); margin: 0 0 8px; }
.sub-h { margin-top: 36px; }
.sect-r { margin: 0; color: var(--mute); font-size: 15px; }
.sect-r b { color: var(--ink); }
.sect-lede { color: #cfc8d8; max-width: 760px; margin: 0 0 22px; }

/* chart */
.race { display: grid; grid-template-columns: minmax(0, .9fr) minmax(0, 1.1fr); gap: 20px; }
.leader { position: relative; background: linear-gradient(150deg, #3a2a10, #1d1610 70%); border: 1px solid #5a4417; border-radius: 14px; padding: 20px; display: flex; flex-direction: column; gap: 12px; min-height: 280px; }
.leader .lt { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; font: 700 12px var(--mono); letter-spacing: .12em; text-transform: uppercase; color: var(--y); }
.leader canvas { width: 100%; flex: 1 1 0; min-height: 230px; border-radius: 8px; background: #0b0910; }
.leader .ln { font: 400 26px/1.1 var(--dp); }
.leader .lb { color: var(--mute); font-size: 14px; }
.leader .lv { font: 700 28px/1 var(--mono); color: var(--y); letter-spacing: 0; }
.leader .lv small { font-size: 11px; color: var(--mute); letter-spacing: .1em; }
.bars { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 8px; }
.bars li { display: grid; grid-template-columns: 26px minmax(0, 1fr) 44px 40px; gap: 10px; align-items: center; background: var(--panel); border: 1px solid var(--line); border-radius: 10px; padding: 10px 12px; cursor: pointer; }
.bars li:hover { border-color: var(--line2); }
.bars .rk { font: 700 13px var(--mono); color: var(--dim); }
.bars .nm { min-width: 0; }
.bars .nm b { display: block; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; font-weight: 700; }
.bars .nm small { color: var(--dim); font: 400 12px var(--mono); }
.bars .track { display: block; height: 6px; background: #0e0c15; border-radius: 99px; overflow: hidden; margin-top: 6px; }
.bars .track i { display: block; height: 100%; background: linear-gradient(90deg, var(--pink), var(--y)); }
.bars .v { font: 700 16px var(--mono); text-align: right; }
.bars .pl { width: 34px; height: 34px; border-radius: 50%; border: 1px solid var(--line2); background: var(--panel2); font-size: 12px; }
.crowns { display: flex; gap: 14px; overflow-x: auto; padding-bottom: 8px; }
.crownc { flex: 0 0 220px; background: var(--panel); border: 1px solid var(--line); border-radius: 12px; padding: 12px; cursor: pointer; }
.crownc:hover { border-color: #5a4417; }
.crownc canvas { width: 100%; height: 86px; border-radius: 6px; display: block; }
.crownc .cd { font: 700 11px var(--mono); color: var(--y); letter-spacing: .1em; margin-top: 10px; }
.crownc .cn { font-weight: 700; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.crownc .cb2 { color: var(--mute); font-size: 13px; }
.empty { color: var(--mute); border: 1px dashed var(--line2); border-radius: 10px; padding: 20px; }

/* library */
.lib-tools { display: flex; gap: 10px; flex-wrap: wrap; }
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); gap: 16px; }
.card { background: var(--panel); border: 1px solid var(--line); border-radius: 12px; overflow: hidden; cursor: pointer; transition: transform .15s, border-color .15s; }
.card:hover { transform: translateY(-3px); border-color: var(--line2); }
.card.playing { border-color: var(--y); box-shadow: 0 0 0 1px var(--y), 0 10px 30px rgba(252, 213, 53, .15); }
.card canvas { display: block; width: 100%; aspect-ratio: 1; }
.card .ci { padding: 10px 12px 12px; }
.card .ct { font-weight: 700; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.card .cm { display: flex; justify-content: space-between; color: var(--dim); font: 400 12px var(--mono); margin-top: 3px; gap: 6px; }
.card .cm span:first-child { color: var(--mute); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.more { display: block; margin: 22px auto 0; }

/* mint */
.steps { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px; align-items: start; margin-top: 34px; }
.step { position: relative; background: var(--panel); border: 1px solid var(--line); border-radius: 12px; padding: 24px 20px 20px; }
.step .n { position: absolute; top: -15px; left: 18px; width: 32px; height: 32px; display: grid; place-items: center; background: var(--y); color: var(--bg); font: 400 17px var(--dp); border-radius: 50%; }
.step p { color: #cbc4d4; font-size: 15px; margin: 0 0 14px; }
.code { display: flex; align-items: center; gap: 10px; background: var(--bg); border: 1px solid var(--line); border-radius: var(--r); padding: 9px 10px; margin-top: 8px; }
.code code { flex: 1; font-size: 12.5px; overflow-wrap: anywhere; }
.copy { background: var(--panel2); border: 1px solid var(--line2); border-radius: 4px; padding: 4px 10px; font: 700 12px var(--mono); color: var(--mute); white-space: nowrap; }
.copy:hover { color: var(--y); }
.chat { display: flex; flex-direction: column; gap: 8px; }
.msg { max-width: 94%; padding: 8px 11px; border-radius: 12px; font-size: 14px; line-height: 1.45; }
.msg.me { align-self: flex-end; background: #2b2410; color: #f6e7a8; border: 1px solid #4b3f14; border-bottom-right-radius: 3px; }
.msg.bot { align-self: flex-start; background: var(--bg2); border: 1px solid var(--line); border-bottom-left-radius: 3px; display: flex; gap: 10px; align-items: flex-start; }
.msg.bot.ok { display: block; color: var(--g); }
.chat-roll { width: 88px; height: 56px; border-radius: 4px; flex: 0 0 auto; background: #0b0910; }
.mini-play { background: var(--panel2); border: 1px solid var(--line2); border-radius: 99px; padding: 1px 9px; font: 700 11px var(--mono); color: var(--y); }
.format { display: grid; grid-template-columns: minmax(0, .8fr) minmax(0, 1.6fr); gap: 22px; align-items: start; margin-top: 22px; background: var(--panel); border: 1px solid var(--line); border-radius: 12px; padding: 20px; }
.format-l p { color: #cbc4d4; font-size: 15px; margin: 0 0 12px; }
.format-l code { color: var(--y); }
.legend { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; font-size: 14px; color: var(--mute); }
.legend i { display: inline-block; width: 12px; height: 12px; border-radius: 3px; margin-right: 8px; vertical-align: -1px; }
.songfile { margin: 0; background: #0b0910; border: 1px solid var(--line); border-radius: 8px; padding: 14px 16px; font: 400 12.5px/1.65 var(--mono); overflow-x: auto; color: #8e86a0; white-space: pre; }
.songfile .k { color: var(--mute); }
.songfile .l { color: var(--y); }
.songfile .h { color: var(--pink); }
.songfile .b { color: var(--cyan); }
.songfile .d { color: var(--ink); }
.cli { margin-top: 22px; background: #08070c; border: 1px solid var(--line); border-radius: 12px; overflow: hidden; }
.cli-h { display: flex; align-items: center; gap: 12px; padding: 9px 14px; border-bottom: 1px solid var(--line); font: 700 12px var(--mono); color: var(--dim); }
.dots { display: flex; gap: 6px; }
.dots i { width: 10px; height: 10px; border-radius: 50%; background: #2c2738; }
.cli pre { margin: 0; padding: 16px 18px; font: 400 13.5px/1.7 var(--mono); color: #e7e1ef; overflow-x: auto; }
.cli .c { color: #6e6680; }

/* rules */
.rules { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 1px; background: var(--line); border: 1px solid var(--line); border-radius: 12px; overflow: hidden; }
.rule { background: var(--panel); padding: 20px 16px; display: flex; flex-direction: column; gap: 6px; }
.rule .big { font: 400 30px/1.1 var(--dp); color: var(--y); }
.rule .big.num { font: 700 28px/1.1 var(--mono); }
.rule span { color: var(--mute); font-size: 14px; line-height: 1.4; }
.faq { margin-top: 22px; display: grid; gap: 8px; }
.faq details { background: var(--panel); border: 1px solid var(--line); border-radius: 10px; padding: 0 16px; }
.faq summary { cursor: pointer; padding: 14px 0; font-weight: 700; list-style: none; }
.faq summary::before { content: "+"; display: inline-block; width: 18px; color: var(--y); font-family: var(--mono); }
.faq details[open] summary::before { content: "−"; }
.faq p { margin: 0 0 16px; color: #cbc4d4; font-size: 15px; }
.faq code { color: var(--y); font-size: 13px; }

/* footer */
.foot { margin-top: 90px; border-top: 1px solid var(--line); background: var(--bg2); padding: 28px 0 40px; }
.foot .wrap { display: flex; justify-content: space-between; gap: 20px; flex-wrap: wrap; }
.foot-l { display: flex; flex-direction: column; gap: 4px; color: var(--mute); font-size: 14px; }
.foot-l b { font: 400 18px var(--dp); color: var(--ink); }
.foot-r { display: flex; gap: 8px 18px; flex-wrap: wrap; align-items: center; font: 400 13px var(--mono); }
.foot-r a { color: var(--mute); }
.foot-r a:hover { color: var(--y); }
.toast { position: fixed; bottom: 22px; left: 50%; transform: translateX(-50%); background: var(--y); color: var(--bg); font-weight: 700; padding: 10px 16px; border-radius: 99px; z-index: 50; }

/* responsive */
@media (max-width: 1100px) {
  .hero { grid-template-columns: minmax(0, 1fr); gap: 30px; }
  .hero-r { order: -1; max-width: 680px; width: 100%; margin: 0 auto; }
  .rules { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .steps { grid-template-columns: 1fr; }
  .format { grid-template-columns: 1fr; }
  .race { grid-template-columns: 1fr; }
}
@media (max-width: 860px) {
  .nav { display: none; position: absolute; top: 62px; left: 0; right: 0; flex-direction: column; background: var(--bg); border-bottom: 1px solid var(--line); padding: 8px 16px 14px; }
  .nav.open { display: flex; }
  .burger { display: block; }
  .search { display: none; }
}
@media (max-width: 560px) {
  .wrap { padding-left: 16px; padding-right: 16px; }
  .bar .wrap { gap: 10px; }
  .logo b { font-size: 15px; }
  .chain span { display: none; }
  .hero { padding-top: 18px; }
  h1 { font-size: 12.4vw; }
  .console { padding: 12px; border-radius: 14px; }
  .c-top { gap: 8px; }
  .onair { font-size: 11px; padding: 3px 7px; }
  .freq { font-size: 14px; min-width: 52px; }
  .dial-scale { font-size: 7px; }
  .np { flex-direction: column; align-items: flex-start; gap: 8px; }
  .np-l { width: 100%; }
  .np-r { flex-direction: row; align-items: center; flex-wrap: wrap; }
  .np-t { font-size: 20px; }
  .vol { display: none; }
  .seg button { padding: 6px 9px; font-size: 11px; }
  .next ol li:nth-child(n+3) { display: none; }
  .rules { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
  .bars li { grid-template-columns: 22px minmax(0, 1fr) 34px 34px; padding: 9px; }
  .leader .ln { font-size: 21px; }
  .lib-tools input { width: 100%; }
}
