:root {
  --bg: #0b0820;
  --bg2: #17123a;
  --panel: rgba(30, 24, 70, .72);
  --line: rgba(150, 130, 255, .22);
  --text: #f4f0ff;
  --muted: #a49cd0;
  --accent: #ff5470;
  --accent2: #ffd166;
  --ok: #06d6a0;
  --radius: 18px;
  --font: "Segoe UI", system-ui, -apple-system, Roboto, sans-serif;
  --display: "Segoe UI Black", "Arial Black", Impact, var(--font);
}
* { box-sizing: border-box; }
html, body { margin: 0; height: 100%; }
body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--font);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
[hidden] { display: none !important; }

/* animated backdrop */
body::before, body::after {
  content: ""; position: fixed; z-index: -2; width: 70vmax; height: 70vmax; border-radius: 50%;
  filter: blur(80px); opacity: .55; pointer-events: none;
}
body::before { background: radial-gradient(circle, #6c3df5 0%, transparent 65%); top: -25vmax; left: -20vmax; animation: drift1 18s ease-in-out infinite alternate; }
body::after { background: radial-gradient(circle, #e0407a 0%, transparent 65%); bottom: -30vmax; right: -20vmax; animation: drift2 22s ease-in-out infinite alternate; }
@keyframes drift1 { to { transform: translate(14vmax, 10vmax) scale(1.15); } }
@keyframes drift2 { to { transform: translate(-12vmax, -8vmax) scale(1.1); } }
.screen::before {
  content: ""; position: fixed; inset: 0; z-index: -1; pointer-events: none; opacity: .5;
  background-image: radial-gradient(rgba(255,255,255,.55) 1px, transparent 1.4px);
  background-size: 90px 90px; background-position: 0 0;
  mask-image: radial-gradient(ellipse at center, #000 20%, transparent 75%);
}

.screen { max-width: 1000px; margin: 0 auto; padding: 26px 16px 56px; display: flex; flex-direction: column; gap: 20px; animation: rise .45s cubic-bezier(.2,.8,.2,1) both; }
@keyframes rise { from { opacity: 0; transform: translateY(14px); } }

/* brand */
.brand { text-align: center; padding: 14px 0 0; }
.logo-bomb { font-size: 54px; line-height: 1; filter: drop-shadow(0 0 18px rgba(255, 84, 112, .7)); animation: bob 2.4s ease-in-out infinite; }
@keyframes bob { 50% { transform: translateY(-8px) rotate(6deg); } }
.brand h1 {
  margin: 4px 0 0; font-family: var(--display); font-size: clamp(44px, 10vw, 84px); letter-spacing: 5px; font-weight: 900; line-height: 1;
  text-shadow: 0 4px 0 rgba(0,0,0,.35), 0 0 40px rgba(108, 61, 245, .55);
}
.brand h1 span {
  background: linear-gradient(180deg, #ff8aa0, #ff3d63 70%); -webkit-background-clip: text; background-clip: text; color: transparent;
  filter: drop-shadow(0 0 18px rgba(255, 84, 112, .55));
}
.brand p { margin: 10px 0 0; color: var(--muted); font-size: 16px; }

/* glass panels */
.panel {
  background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 20px;
  backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px);
  box-shadow: 0 18px 50px rgba(0,0,0,.35), inset 0 1px 0 rgba(255,255,255,.07);
}
.panel h2 { margin: 0 0 14px; font-size: 14px; letter-spacing: 2.5px; text-transform: uppercase; color: var(--muted); font-weight: 800; }
.join-panel { max-width: 540px; width: 100%; margin: 0 auto; }

.field { display: flex; flex-direction: column; gap: 6px; margin-bottom: 14px; }
.field span { color: var(--muted); font-size: 12px; letter-spacing: 1.5px; text-transform: uppercase; font-weight: 700; }
input {
  background: rgba(8, 5, 28, .6); border: 2px solid var(--line); color: var(--text);
  border-radius: 12px; padding: 13px 15px; font-size: 17px; font-weight: 600; outline: none; width: 100%;
  transition: border-color .15s, box-shadow .15s;
}
input:focus { border-color: var(--accent); box-shadow: 0 0 0 4px rgba(255, 84, 112, .18); }
.code-input { text-transform: uppercase; text-align: center; letter-spacing: 10px; font-weight: 900; font-size: 24px; max-width: 190px; padding-left: 24px; }

.join-row { display: flex; gap: 10px; justify-content: center; align-items: stretch; }
.or { display: flex; align-items: center; gap: 12px; color: var(--muted); font-size: 12px; letter-spacing: 1.5px; text-transform: uppercase; margin: 18px 0; }
.or::before, .or::after { content: ""; height: 1px; background: var(--line); flex: 1; }

/* buttons */
.btn {
  background: rgba(255,255,255,.06); color: var(--text); border: 2px solid var(--line); border-radius: 12px;
  padding: 10px 16px; font-size: 15px; font-weight: 800; cursor: pointer; font-family: inherit;
  transition: transform .1s, border-color .15s, background .15s, box-shadow .2s, filter .15s;
}
.btn:hover:not(:disabled) { border-color: rgba(255,255,255,.5); background: rgba(255,255,255,.1); }
.btn:active:not(:disabled) { transform: translateY(2px) scale(.99); }
.btn:disabled { opacity: .4; cursor: not-allowed; }
.btn.primary {
  background: linear-gradient(180deg, #ff6b87, #ff3d63); border-color: #ff8aa0; color: #fff;
  box-shadow: 0 6px 0 #a3203d, 0 10px 28px rgba(255, 61, 99, .4); text-shadow: 0 1px 0 rgba(0,0,0,.25);
}
.btn.primary:hover:not(:disabled) { filter: brightness(1.08); background: linear-gradient(180deg, #ff6b87, #ff3d63); border-color: #ffc0cc; }
.btn.primary:active:not(:disabled) { transform: translateY(4px); box-shadow: 0 2px 0 #a3203d, 0 6px 18px rgba(255, 61, 99, .4); }
.btn.primary:disabled { box-shadow: 0 6px 0 #5a2230; }
.btn.danger:hover:not(:disabled) { border-color: #ff3b3b; color: #ff9a9a; }
.btn.big { padding: 14px 24px; font-size: 17px; }
.btn.small { padding: 8px 13px; font-size: 13px; }
.join-row .btn.primary { flex: 1; }

/* game cards */
.games { display: grid; grid-template-columns: repeat(auto-fill, minmax(235px, 1fr)); gap: 14px; }
.card {
  --gc: #ff5470;
  position: relative; overflow: hidden; text-align: left; border: 2px solid var(--line); border-radius: 16px;
  padding: 16px; display: flex; flex-direction: column; gap: 8px; color: var(--text); font: inherit;
  background: linear-gradient(160deg, color-mix(in srgb, var(--gc) 22%, #1a1445) 0%, #140f36 70%);
  transition: transform .15s, border-color .15s, box-shadow .2s;
}
.card::after {
  content: ""; position: absolute; right: -30px; top: -30px; width: 120px; height: 120px; border-radius: 50%;
  background: radial-gradient(circle, color-mix(in srgb, var(--gc) 55%, transparent), transparent 70%); opacity: .55; pointer-events: none;
}
.card .icon { font-size: 38px; line-height: 1; filter: drop-shadow(0 4px 10px rgba(0,0,0,.5)); position: relative; z-index: 1; }
.card.selectable { cursor: pointer; }
.card.selectable:hover { transform: translateY(-4px) rotate(-.4deg); border-color: var(--gc); box-shadow: 0 14px 30px rgba(0,0,0,.4), 0 0 0 1px var(--gc); }
.card.selected { border-color: var(--gc); box-shadow: 0 0 0 3px color-mix(in srgb, var(--gc) 45%, transparent), 0 16px 34px rgba(0,0,0,.45); transform: translateY(-2px); }
.card.selected::before {
  content: "✓ AUSGEWÄHLT"; position: absolute; top: 12px; right: 12px; font-size: 10px; font-weight: 900; letter-spacing: 1px;
  background: var(--gc); color: #170d2e; padding: 3px 8px; border-radius: 999px; z-index: 2;
}
.card.soon { filter: saturate(.55); opacity: .72; }
.card .name { font-family: var(--display); font-size: 15px; letter-spacing: 1.2px; position: relative; z-index: 1; }
.card .tag { color: var(--muted); font-size: 13px; line-height: 1.4; flex: 1; position: relative; z-index: 1; }
.card .meta { display: flex; justify-content: space-between; align-items: center; font-size: 13px; font-weight: 700; position: relative; z-index: 1; }
.pill { background: rgba(255,255,255,.08); border-radius: 999px; padding: 4px 11px; font-weight: 800; font-size: 11px; letter-spacing: .5px; }
.pill.soon { background: rgba(255, 209, 102, .16); color: var(--accent2); }
.pill.live { background: rgba(6, 214, 160, .16); color: var(--ok); }

/* lobby */
.lobby-head { display: flex; justify-content: space-between; align-items: flex-end; flex-wrap: wrap; gap: 14px; }
.code-big {
  font-family: var(--display); font-size: clamp(46px, 11vw, 84px); letter-spacing: 14px; line-height: 1; padding-left: 14px;
  background: linear-gradient(180deg, #ffe49a, #ffb347); -webkit-background-clip: text; background-clip: text; color: transparent;
  filter: drop-shadow(0 0 22px rgba(255, 190, 80, .4));
}
.head-actions { display: flex; gap: 8px; flex-wrap: wrap; }
.lobby-grid { display: grid; grid-template-columns: 310px 1fr; gap: 20px; align-items: start; }
@media (max-width: 780px) { .lobby-grid { grid-template-columns: 1fr; } }

.players { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 8px; }
.players li { display: flex; align-items: center; gap: 12px; background: rgba(8, 5, 28, .5); border: 1px solid var(--line); border-radius: 14px; padding: 8px 12px; animation: rise .3s both; }
.avatar {
  width: 34px; height: 34px; border-radius: 50%; flex: none; display: grid; place-items: center; font-weight: 900; font-size: 15px; color: #1a0f2e;
  box-shadow: inset 0 -4px 0 rgba(0,0,0,.2), inset 0 3px 0 rgba(255,255,255,.35), 0 3px 8px rgba(0,0,0,.4);
}
.avatar.sm { width: 28px; height: 28px; font-size: 13px; }
.dot { width: 14px; height: 14px; border-radius: 50%; flex: none; }
.players .me { border-color: rgba(255, 209, 102, .7); background: rgba(255, 209, 102, .07); }
.players .nm { flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-weight: 700; }
.players .host { font-size: 11px; color: var(--accent2); font-weight: 900; letter-spacing: 1px; }
.count { color: var(--muted); font-weight: 700; font-size: 14px; margin-left: 6px; letter-spacing: 0; }
.muted { color: var(--muted); }
.small-text { font-size: 12px; text-transform: none; letter-spacing: 0; font-weight: 600; margin-left: 8px; }

.start-row { display: flex; align-items: center; gap: 16px; margin-top: 20px; flex-wrap: wrap; }
.reason { color: var(--accent2); font-size: 14px; font-weight: 600; }

/* results */
.results { max-width: 540px; width: 100%; margin: 40px auto 0; text-align: center; }
.results h2 { font-family: var(--display); font-size: 30px; letter-spacing: 1px; text-transform: none; color: var(--accent2); margin: 4px 0 0; }
.ranking { list-style: none; padding: 0; margin: 18px 0 22px; display: flex; flex-direction: column; gap: 8px; text-align: left; }
.ranking li { display: flex; gap: 12px; align-items: center; background: rgba(8, 5, 28, .5); border: 1px solid var(--line); border-radius: 14px; padding: 10px 14px; font-weight: 800; animation: rise .4s both; }
.ranking li:nth-child(2) { animation-delay: .06s; } .ranking li:nth-child(3) { animation-delay: .12s; } .ranking li:nth-child(n+4) { animation-delay: .18s; }
.ranking li .place { width: 28px; color: var(--muted); font-family: var(--display); }
.ranking li.first { background: linear-gradient(90deg, rgba(255, 209, 102, .22), rgba(255, 209, 102, .05)); border: 2px solid var(--accent2); box-shadow: 0 0 30px rgba(255, 209, 102, .25); }
.ranking li.first .place { color: var(--accent2); }
.res-actions { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; }

/* game */
.screen-game { position: fixed; inset: 0; background: #0a0816; touch-action: none; }
#game-canvas { width: 100%; height: 100%; display: block; touch-action: none; }
.game-leave { position: fixed; right: 10px; bottom: 10px; opacity: .7; }
.game-leave:hover { opacity: 1; }

.toast {
  position: fixed; top: 16px; left: 50%; transform: translateX(-50%); z-index: 50;
  background: rgba(58, 18, 32, .96); border: 2px solid var(--accent); color: #fff; padding: 11px 20px;
  border-radius: 12px; font-weight: 700; max-width: 90vw; text-align: center; box-shadow: 0 10px 30px rgba(0,0,0,.5);
  animation: toastin .25s cubic-bezier(.2,.9,.3,1.3) both;
}
@keyframes toastin { from { opacity: 0; transform: translate(-50%, -14px) scale(.95); } }
.toast.info { background: rgba(17, 38, 58, .96); border-color: #4cc9f0; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
}

/* name + skin row */
.name-row { display: flex; gap: 12px; align-items: flex-end; }
.name-row .field { flex: 1; }
.skin-btn {
  display: flex; flex-direction: column; align-items: center; gap: 2px; margin-bottom: 14px; padding: 6px 10px 5px; cursor: pointer;
  background: rgba(255,255,255,.06); border: 2px solid var(--line); border-radius: 14px; color: var(--text); font: inherit;
  transition: border-color .15s, transform .1s, background .15s;
}
.skin-btn:hover { border-color: var(--accent); background: rgba(255,255,255,.1); }
.skin-btn:active { transform: scale(.97); }
.skin-btn-label { font-size: 11px; font-weight: 800; letter-spacing: 1px; color: var(--muted); }
.btn.full { width: 100%; margin-bottom: 14px; }
.avatar-wrap { display: grid; place-items: center; width: 40px; height: 40px; flex: none; }
.players li.bot { opacity: .85; border-style: dashed; }
.bottag { font-size: 11px; font-weight: 900; letter-spacing: 1px; color: #7ee0ff; }

/* bots box */
.bot-box { margin-top: 16px; padding: 14px 16px; border: 1px dashed var(--line); border-radius: 14px; background: rgba(8,5,28,.35); }
.bot-head { display: flex; align-items: center; justify-content: space-between; gap: 14px; flex-wrap: wrap; }
.switch { display: inline-flex; align-items: center; gap: 10px; cursor: pointer; font-weight: 800; position: relative; }
.switch input { position: absolute; opacity: 0; width: 0; height: 0; }
.slider { width: 44px; height: 26px; border-radius: 999px; background: rgba(255,255,255,.12); border: 2px solid var(--line); position: relative; transition: background .2s; flex: none; }
.slider::after { content: ""; position: absolute; top: 2px; left: 2px; width: 18px; height: 18px; border-radius: 50%; background: #fff; transition: transform .2s; }
.switch input:checked + .slider { background: var(--ok); border-color: var(--ok); }
.switch input:checked + .slider::after { transform: translateX(18px); }
.switch input:disabled ~ .switch-label, .switch input:disabled + .slider { opacity: .5; cursor: not-allowed; }
.switch input:focus-visible + .slider { box-shadow: 0 0 0 3px rgba(255,84,112,.4); }
.stepper { display: inline-flex; align-items: center; gap: 10px; }
.stepper.off { opacity: .4; }
.stepper-val { min-width: 26px; text-align: center; font-family: var(--display); font-size: 22px; }
.bot-box .small-text { display: block; margin: 8px 0 0; }

/* skin editor */
.modal { position: fixed; inset: 0; z-index: 40; background: rgba(5, 3, 18, .78); backdrop-filter: blur(6px); display: grid; place-items: center; padding: 16px; animation: rise .25s both; }
.modal-card { width: min(860px, 100%); max-height: 94vh; overflow: auto; }
.modal-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 8px; }
.modal-head h2 { margin: 0; }
.skin-layout { display: grid; grid-template-columns: 290px 1fr; gap: 20px; align-items: start; }
@media (max-width: 720px) { .skin-layout { grid-template-columns: 1fr; } }
.skin-preview { display: flex; flex-direction: column; gap: 10px; }
#skin-canvas { width: 100%; height: 270px; border-radius: 16px; background: linear-gradient(180deg, rgba(8,5,28,.7), rgba(30,22,80,.7)); border: 1px solid var(--line); display: block; }
.skin-tools { display: flex; justify-content: space-between; align-items: center; gap: 10px; flex-wrap: wrap; }
.check { display: inline-flex; align-items: center; gap: 8px; font-size: 13px; color: var(--muted); cursor: pointer; }
.check input { width: auto; accent-color: var(--accent); }
.tabs { display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 14px; }
.tab { background: rgba(255,255,255,.06); color: var(--muted); border: 2px solid transparent; border-radius: 999px; padding: 8px 15px; font: inherit; font-weight: 800; font-size: 13px; cursor: pointer; transition: all .15s; }
.tab:hover { color: var(--text); }
.tab.active { background: var(--accent); color: #fff; box-shadow: 0 4px 14px rgba(255,61,99,.4); }
.opts { display: grid; grid-template-columns: repeat(auto-fill, minmax(92px, 1fr)); gap: 10px; }
.opts.colors { grid-template-columns: repeat(auto-fill, minmax(46px, 1fr)); }
.swatch { aspect-ratio: 1; border-radius: 50%; border: 3px solid rgba(255,255,255,.18); cursor: pointer; transition: transform .12s, border-color .15s; box-shadow: inset 0 -5px 0 rgba(0,0,0,.18), inset 0 4px 0 rgba(255,255,255,.3); }
.swatch:hover { transform: scale(1.12); }
.swatch.sel { border-color: #fff; box-shadow: 0 0 0 3px var(--accent), inset 0 -5px 0 rgba(0,0,0,.18), inset 0 4px 0 rgba(255,255,255,.3); transform: scale(1.08); }
.tile { display: flex; flex-direction: column; align-items: center; gap: 4px; padding: 8px 4px 7px; background: rgba(8,5,28,.5); border: 2px solid var(--line); border-radius: 14px; color: var(--text); font: inherit; cursor: pointer; transition: transform .12s, border-color .15s, background .15s; }
.tile:hover { transform: translateY(-3px); border-color: rgba(255,255,255,.5); }
.tile.sel { border-color: var(--accent); background: rgba(255,84,112,.14); box-shadow: 0 0 0 2px rgba(255,84,112,.35); }
.tile-art { display: grid; place-items: center; width: 64px; height: 64px; font-size: 34px; }
.tile-label { font-size: 11px; font-weight: 800; color: var(--muted); text-align: center; line-height: 1.15; }
.tile.sel .tile-label { color: var(--text); }

.ranking li .rname { flex: 1; }
.ranking li .rextra { color: var(--accent2); font-family: var(--display); }
#res-sub { margin-top: 4px; font-size: 13px; }
.game-dom { position: absolute; inset: 0; overflow: auto; -webkit-overflow-scrolling: touch; background: radial-gradient(1100px 650px at 50% -10%, #2d2166 0%, #120c2e 55%, #0a0816 100%); }

/* ---------- Telephone Doodle ---------- */
.td { max-width: 880px; margin: 0 auto; padding: 14px 14px 90px; display: flex; flex-direction: column; gap: 12px; min-height: 100%; }
.td-top { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.td-title { font-family: var(--display); letter-spacing: 3px; font-size: 13px; color: var(--muted); }
.td-round { font-weight: 800; font-size: 13px; color: var(--accent2); min-width: 90px; }
.td-mute { background: none; border: 0; color: var(--text); font-size: 18px; cursor: pointer; min-width: 90px; text-align: right; }
.td-bar { height: 10px; border-radius: 6px; background: rgba(255,255,255,.1); overflow: hidden; }
.td-bar-fill { height: 100%; width: 100%; background: linear-gradient(90deg, #06d6a0, #ffd166); border-radius: 6px; transition: width .1s linear; }
.td-bar-fill.low { background: linear-gradient(90deg, #ff5470, #ffb347); animation: tdpulse .5s infinite alternate; }
@keyframes tdpulse { to { opacity: .55; } }
.td-stage { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: flex-start; padding-top: 6px; }
.td-card { width: min(560px, 100%); background: var(--panel); border: 1px solid var(--line); border-radius: 18px; padding: 20px; display: flex; flex-direction: column; gap: 12px; backdrop-filter: blur(12px); box-shadow: 0 18px 50px rgba(0,0,0,.35); animation: rise .3s both; text-align: center; }
.td-card.wide { width: min(760px, 100%); }
.td-card h2 { margin: 0; font-family: var(--display); font-size: 22px; letter-spacing: 1px; }
.td-hint { margin: 0; color: var(--muted); font-size: 14px; }
.td-input { width: 100%; resize: none; background: rgba(8,5,28,.6); border: 2px solid var(--line); color: var(--text); border-radius: 12px; padding: 12px 14px; font: 600 18px var(--font); outline: none; text-align: center; }
.td-input:focus { border-color: var(--accent); box-shadow: 0 0 0 4px rgba(255,84,112,.18); }
.td-row { display: flex; gap: 10px; justify-content: center; flex-wrap: wrap; }
.td-dots { font-size: 22px; letter-spacing: 6px; color: var(--accent2); animation: tdpulse 1s infinite alternate; }
.td-prompt { display: flex; flex-direction: column; gap: 2px; align-items: center; }
.td-prompt-label { font-size: 12px; letter-spacing: 2px; text-transform: uppercase; color: var(--muted); font-weight: 800; }
.td-prompt-text { font-family: var(--display); font-size: clamp(18px, 3.4vw, 26px); color: var(--accent2); }
.td-canvas { width: max(260px, min(100%, calc((100vh - 360px) * 1.3333))); height: auto; margin: 0 auto; aspect-ratio: 4 / 3; border-radius: 14px; background: #fff; touch-action: none; cursor: crosshair; box-shadow: inset 0 0 0 3px rgba(0,0,0,.15), 0 8px 24px rgba(0,0,0,.35); display: block; }
.td-tools { display: flex; align-items: center; justify-content: center; gap: 10px; flex-wrap: wrap; }
.td-palette { display: grid; grid-template-columns: repeat(8, 1fr); gap: 6px; max-width: 320px; }
.td-col { width: 30px; height: 30px; border-radius: 50%; border: 3px solid rgba(255,255,255,.25); cursor: pointer; padding: 0; }
.td-col.sel { border-color: #fff; box-shadow: 0 0 0 3px var(--accent); transform: scale(1.1); }
.td-sizes { display: flex; gap: 6px; }
.td-size { width: 38px; height: 38px; border-radius: 10px; background: rgba(255,255,255,.08); border: 2px solid var(--line); display: grid; place-items: center; cursor: pointer; padding: 0; }
.td-size span { display: block; background: #fff; border-radius: 50%; }
.td-size.sel { border-color: var(--accent); background: rgba(255,84,112,.18); }
.td-chips { display: flex; flex-wrap: wrap; gap: 8px; justify-content: center; }
.td-chip { display: flex; align-items: center; gap: 6px; background: rgba(8,5,28,.55); border: 1px solid var(--line); border-radius: 999px; padding: 3px 12px 3px 4px; font-size: 12px; font-weight: 700; opacity: .65; }
.td-chip.me { border-color: rgba(255,209,102,.6); }
.td-chip.done { opacity: 1; border-color: var(--ok); }
.td-chip-av { display: grid; place-items: center; width: 30px; height: 30px; }
.td-chip-ok { color: var(--ok); display: none; }
.td-chip.done .td-chip-ok { display: inline; }

/* reveal */
.td-reveal { width: min(760px, 100%); display: flex; flex-direction: column; gap: 12px; padding-bottom: 20px; }
.td-rv-head { display: flex; justify-content: space-between; align-items: baseline; }
.td-rv-owner { font-family: var(--display); font-size: 20px; color: var(--accent2); }
.td-rv-count { color: var(--muted); font-weight: 700; font-size: 13px; }
.td-rv-list { display: flex; flex-direction: column; gap: 12px; }
.td-entry { background: var(--panel); border: 1px solid var(--line); border-radius: 16px; padding: 12px; display: flex; flex-direction: column; gap: 8px; animation: rise .4s both; transition: opacity .3s; }
.td-entry.old { opacity: .88; }
.td-entry.draw .td-canvas { cursor: default; width: min(100%, 520px); }
.td-entry-head { display: flex; align-items: center; gap: 8px; }
.td-entry-name { font-weight: 800; }
.td-entry-kind { margin-left: auto; font-size: 11px; letter-spacing: 1.5px; text-transform: uppercase; color: var(--muted); font-weight: 800; }
.td-bubble { background: rgba(255,255,255,.08); border-radius: 14px; padding: 14px 16px; font-size: clamp(18px, 3vw, 24px); font-weight: 800; text-align: center; }
.td-entry-foot { display: flex; justify-content: flex-end; }
.td-star { display: inline-flex; align-items: center; gap: 6px; background: rgba(255,209,102,.12); border: 2px solid rgba(255,209,102,.4); color: var(--accent2); border-radius: 999px; padding: 6px 14px; font: 800 15px var(--font); cursor: pointer; transition: transform .1s, background .15s; }
.td-star:hover { background: rgba(255,209,102,.25); }
.td-star.pop { animation: starpop .35s; }
.td-star.mine { background: rgba(255,209,102,.3); border-color: var(--accent2); }
@keyframes starpop { 40% { transform: scale(1.3) rotate(-6deg); } }
.td-chainend { text-align: center; font-family: var(--display); color: var(--muted); padding: 10px; letter-spacing: 1px; }
.td-reactions { position: sticky; bottom: 8px; display: flex; gap: 6px; justify-content: center; align-items: center; flex-wrap: wrap; background: rgba(12,8,34,.85); border: 1px solid var(--line); border-radius: 999px; padding: 6px 10px; backdrop-filter: blur(10px); }
.td-react { background: none; border: 0; font-size: 24px; cursor: pointer; padding: 2px 6px; transition: transform .1s; }
.td-react:hover { transform: scale(1.25); }
.td-react:active { transform: scale(.9); }
.td-next { margin-left: 8px; padding: 8px 16px; }
.td-float { position: absolute; bottom: 70px; display: flex; flex-direction: column; align-items: center; pointer-events: none; animation: tdfloat 2.3s ease-out forwards; z-index: 5; }
.td-float-e { font-size: 38px; }
.td-float-n { font-size: 11px; font-weight: 800; background: rgba(8,5,28,.7); border-radius: 999px; padding: 1px 8px; }
@keyframes tdfloat { from { transform: translateY(0) scale(.6); opacity: 1; } to { transform: translateY(-340px) scale(1.2); opacity: 0; } }
@media (max-width: 560px) { .td-palette { grid-template-columns: repeat(8, 1fr); } .td-col { width: 26px; height: 26px; } }

/* ---------- control scheme picker ---------- */
.ctl-ui { position: absolute; inset: 0; pointer-events: none; z-index: 8; }
.ctl-pick {
  position: absolute; left: 50%; bottom: 96px; transform: translateX(-50%); width: min(620px, calc(100% - 24px));
  background: rgba(14, 9, 40, .92); border: 1px solid var(--line); border-radius: 18px; padding: 14px 16px 10px;
  backdrop-filter: blur(10px); box-shadow: 0 18px 50px rgba(0,0,0,.5); pointer-events: auto; text-align: center;
  transition: opacity .5s, transform .5s;
}
.ctl-pick.gone { opacity: 0; transform: translateX(-50%) translateY(20px); pointer-events: none; }
.ctl-title { font-family: var(--display); letter-spacing: 1px; font-size: 15px; margin-bottom: 10px; color: var(--accent2); }
.ctl-opts { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.ctl-opt {
  display: flex; flex-direction: column; align-items: center; gap: 3px; padding: 10px 10px 9px; cursor: pointer; font: inherit; color: var(--text);
  background: rgba(255,255,255,.06); border: 2px solid var(--line); border-radius: 14px; transition: border-color .15s, background .15s, transform .1s;
}
.ctl-opt:hover { border-color: rgba(255,255,255,.5); transform: translateY(-2px); }
.ctl-opt.sel { border-color: var(--accent); background: rgba(255,84,112,.16); box-shadow: 0 0 0 2px rgba(255,84,112,.3); }
.ctl-ico { font-size: 26px; line-height: 1; }
.ctl-opt b { font-size: 15px; }
.ctl-opt small { color: var(--muted); font-size: 11.5px; line-height: 1.35; }
.ctl-foot { margin-top: 8px; font-size: 11px; color: var(--muted); }
.ctl-foot kbd { background: rgba(255,255,255,.12); border-radius: 5px; padding: 1px 6px; font: 700 11px var(--font); }
.ctl-badge {
  position: absolute; right: 10px; bottom: 56px; pointer-events: auto; cursor: pointer; font: 800 12px var(--font); color: var(--text);
  background: rgba(14, 9, 40, .8); border: 1px solid var(--line); border-radius: 999px; padding: 6px 12px; opacity: .8;
}
.ctl-badge:hover { opacity: 1; border-color: var(--accent); }
@media (max-width: 560px) { .ctl-opts { grid-template-columns: 1fr; } .ctl-pick { bottom: 70px; } }

/* ---------- login ---------- */
.login-panel { max-width: 520px; width: 100%; margin: 0 auto; text-align: center; display: flex; flex-direction: column; gap: 14px; }
.login-panel h2 { margin-bottom: 0; }
.login-text { margin: 0; color: var(--text); line-height: 1.5; }
.login-fine { margin: 0; font-size: 12px; }
.login-msg { background: rgba(255, 84, 112, .14); border: 1px solid rgba(255, 84, 112, .5); border-radius: 12px; padding: 10px 14px; font-weight: 700; font-size: 14px; }
.btn.discord { background: linear-gradient(180deg, #6d7cff, #5865f2); border-color: #8c97ff; box-shadow: 0 6px 0 #3a45b8, 0 10px 28px rgba(88, 101, 242, .4); text-decoration: none; display: block; }
.btn.discord:hover { background: linear-gradient(180deg, #7d8bff, #5f6cf5); }
.dev-login { display: flex; flex-direction: column; gap: 8px; }

/* ---------- profile bar ---------- */
.profile { max-width: 540px; width: 100%; margin: 0 auto; display: flex; align-items: center; gap: 14px; padding: 14px 16px; }
.pf-avatar { width: 54px; height: 54px; border-radius: 50%; border: 2px solid var(--line); flex: none; }
.pf-main { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 4px; }
.pf-name { font-family: var(--display); font-size: 18px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pf-lv { display: flex; align-items: center; gap: 10px; font-size: 13px; }
.pf-lv b { color: var(--accent2); white-space: nowrap; }
.pf-bar, .xp-bar { flex: 1; height: 10px; border-radius: 6px; background: rgba(255,255,255,.1); overflow: hidden; min-width: 60px; }
.pf-bar div, .xp-bar div { height: 100%; width: 0; border-radius: 6px; background: linear-gradient(90deg, #06d6a0, #ffd166); transition: width 1s cubic-bezier(.2,.8,.2,1); }
.pf-stats { font-size: 12px; }
.lv { font-size: 11px; font-weight: 900; color: var(--accent2); background: rgba(255, 209, 102, .12); border-radius: 999px; padding: 2px 8px; letter-spacing: .5px; }

/* ---------- XP after a match ---------- */
.xp-box { margin: 0 0 18px; padding: 14px 16px; background: rgba(8, 5, 28, .5); border: 1px solid var(--line); border-radius: 14px; text-align: left; display: flex; flex-direction: column; gap: 10px; animation: rise .4s .2s both; }
.xp-head { display: flex; justify-content: space-between; align-items: baseline; gap: 10px; flex-wrap: wrap; }
.xp-gain { font-family: var(--display); font-size: 26px; color: var(--ok); }
.xp-up { font-family: var(--display); font-size: 16px; color: var(--accent2); animation: tdpulse .6s infinite alternate; }
.xp-bar { height: 14px; flex: none; }
.xp-parts { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 3px; font-size: 13px; font-weight: 700; }
.xp-unlocks { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.xp-unl-title { width: 100%; font-weight: 900; font-size: 13px; color: var(--accent2); }
.xp-chip { background: rgba(255, 209, 102, .14); border: 1px solid rgba(255, 209, 102, .4); border-radius: 999px; padding: 3px 10px; font-size: 12px; font-weight: 800; }

/* ---------- locked cosmetics ---------- */
.tab small { opacity: .7; font-weight: 700; margin-left: 2px; }
.tile.locked { opacity: .55; cursor: not-allowed; }
.tile.locked .tile-art { filter: grayscale(1) brightness(.55); }
.tile.locked:hover { transform: none; border-color: var(--line); }
.tile-lock { position: absolute; top: 6px; right: 6px; background: rgba(8, 5, 28, .88); border: 1px solid var(--line); border-radius: 999px; padding: 1px 7px; font-size: 10px; font-weight: 900; color: var(--accent2); }
.tile { position: relative; }
.swatch { position: relative; display: grid; place-items: center; }
.swatch.locked { filter: grayscale(.85) brightness(.5); cursor: not-allowed; }
.swatch.locked:hover { transform: none; }
.swatch-lock { font-size: 14px; filter: none; }

.xp-dot { display: inline-block; width: 12px; height: 12px; border-radius: 50%; vertical-align: -1px; border: 1px solid rgba(255,255,255,.6); }

/* ---------- chat dock ---------- */
.dock { position: fixed; right: 14px; bottom: 14px; z-index: 30; display: flex; flex-direction: column; align-items: flex-end; gap: 10px; }
.dock[hidden] { display: none; }
.dock-toggle { position: relative; width: 56px; height: 56px; border-radius: 50%; border: 2px solid var(--line); background: linear-gradient(180deg, #3a2f7a, #241c52); color: #fff; font-size: 26px; cursor: pointer; box-shadow: 0 10px 28px rgba(0,0,0,.45); transition: transform .12s, border-color .15s; }
.dock-toggle:hover { transform: scale(1.06); border-color: var(--accent); }
.dock-toggle.open { border-color: var(--accent); }
.dock-badge { position: absolute; top: -4px; right: -4px; min-width: 22px; height: 22px; padding: 0 5px; border-radius: 999px; background: var(--accent); color: #fff; font: 900 12px var(--font); display: grid; place-items: center; box-shadow: 0 2px 8px rgba(0,0,0,.5); }
.dock-badge[hidden] { display: none; }
.dock-panel { width: min(380px, calc(100vw - 28px)); height: min(520px, calc(100vh - 110px)); background: rgba(18, 13, 46, .96); border: 1px solid var(--line); border-radius: 18px; box-shadow: 0 20px 60px rgba(0,0,0,.6); backdrop-filter: blur(14px); display: flex; flex-direction: column; overflow: hidden; animation: rise .2s both; }
.dock-panel[hidden] { display: none; }
.dock-tabs { display: flex; align-items: center; gap: 4px; padding: 8px 8px 0; border-bottom: 1px solid var(--line); }
.dock-tab { position: relative; background: none; border: 0; border-bottom: 3px solid transparent; color: var(--muted); font: 800 13px var(--font); padding: 8px 12px; cursor: pointer; }
.dock-tab:hover { color: var(--text); }
.dock-tab.on { color: #fff; border-bottom-color: var(--accent); }
.dock-tb { position: absolute; top: 2px; right: 0; background: var(--accent); color: #fff; border-radius: 999px; font: 900 10px var(--font); padding: 1px 5px; }
.dock-x { margin-left: auto; background: none; border: 0; color: var(--muted); font-size: 16px; cursor: pointer; padding: 6px 8px; }
.dock-x:hover { color: #fff; }
.dock-body { flex: 1; min-height: 0; display: flex; flex-direction: column; }
.chat-pane, .dm-pane { flex: 1; min-height: 0; display: flex; flex-direction: column; }
.msgs { flex: 1; min-height: 0; overflow-y: auto; padding: 10px 12px; display: flex; flex-direction: column; gap: 8px; scroll-behavior: smooth; }
.cm { max-width: 100%; }
.cm-head { display: flex; align-items: baseline; gap: 6px; }
.cm-name { background: none; border: 0; padding: 0; font: 800 13px var(--font); cursor: pointer; color: #cfc8ee; }
.cm-name:hover { text-decoration: underline; }
.cm-time { margin-left: auto; font-size: 10px; color: var(--muted); }
.cm-text { font-size: 14px; line-height: 1.4; word-break: break-word; overflow-wrap: anywhere; white-space: pre-wrap; }
.cm-text.big { font-size: 30px; line-height: 1.2; }
.cm.mine .cm-text { color: #fff0c2; }
.cm.sys { text-align: center; font-size: 12px; color: var(--muted); font-style: italic; }
.cm.sys.empty { padding: 24px 12px; font-style: normal; line-height: 1.5; }
.composer { position: relative; border-top: 1px solid var(--line); padding: 8px 10px 10px; display: flex; flex-direction: column; gap: 6px; }
.quick { display: flex; gap: 4px; flex-wrap: wrap; }
.quick-b { background: rgba(255,255,255,.07); border: 1px solid var(--line); border-radius: 999px; padding: 2px 9px; color: #fff; font: 800 13px var(--font); cursor: pointer; }
.quick-b:hover { border-color: var(--accent); background: rgba(255,84,112,.15); }
.cmp-row { display: flex; gap: 6px; align-items: center; }
.cmp-input { flex: 1; min-width: 0; background: rgba(8,5,28,.7); border: 2px solid var(--line); color: var(--text); border-radius: 10px; padding: 8px 10px; font: 600 14px var(--font); outline: none; }
.cmp-input:focus { border-color: var(--accent); }
.emo-btn, .cmp-send { background: rgba(255,255,255,.08); border: 1px solid var(--line); border-radius: 10px; width: 38px; height: 38px; color: #fff; font-size: 18px; cursor: pointer; flex: none; }
.cmp-send { background: var(--accent); border-color: var(--accent); font-size: 15px; }
.emo-btn:hover { border-color: var(--accent2); }
.emo-picker { position: absolute; left: 8px; right: 8px; bottom: 100%; margin-bottom: 4px; background: #1c1646; border: 1px solid var(--line); border-radius: 14px; box-shadow: 0 14px 40px rgba(0,0,0,.6); overflow: hidden; z-index: 5; }
.emo-picker[hidden] { display: none; }
.emo-cats { display: flex; border-bottom: 1px solid var(--line); }
.emo-cats button { flex: 1; background: none; border: 0; padding: 7px 0; font-size: 18px; cursor: pointer; opacity: .6; }
.emo-cats button.on { opacity: 1; background: rgba(255,255,255,.08); }
.emo-grid { display: grid; grid-template-columns: repeat(8, 1fr); gap: 2px; padding: 6px; max-height: 170px; overflow-y: auto; }
.emo { background: none; border: 0; font-size: 22px; padding: 3px 0; cursor: pointer; border-radius: 8px; }
.emo:hover { background: rgba(255,255,255,.12); transform: scale(1.15); }
.name-menu { position: fixed; z-index: 60; background: #1c1646; border: 1px solid var(--line); border-radius: 12px; box-shadow: 0 14px 40px rgba(0,0,0,.6); padding: 4px; display: flex; flex-direction: column; min-width: 190px; }
.name-menu button { background: none; border: 0; color: var(--text); text-align: left; font: 700 13px var(--font); padding: 9px 12px; border-radius: 8px; cursor: pointer; }
.name-menu button:hover { background: rgba(255,255,255,.1); }

/* friends */
.friends-pane { flex: 1; overflow-y: auto; padding: 10px 12px 14px; display: flex; flex-direction: column; gap: 6px; }
.fr-me { background: rgba(255,209,102,.08); border: 1px solid rgba(255,209,102,.3); border-radius: 12px; padding: 8px 12px; }
.fr-me-l { font-size: 11px; letter-spacing: 1.5px; text-transform: uppercase; color: var(--muted); font-weight: 800; }
.fr-me-r { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-top: 2px; }
.fr-code { font-family: var(--display); font-size: 22px; letter-spacing: 3px; color: var(--accent2); }
.fr-add { display: flex; gap: 6px; margin: 4px 0 6px; }
.fr-sec { font-size: 11px; letter-spacing: 1.5px; text-transform: uppercase; color: var(--muted); font-weight: 800; margin-top: 8px; }
.fr { display: flex; align-items: center; gap: 8px; background: rgba(8,5,28,.5); border: 1px solid var(--line); border-radius: 12px; padding: 6px 8px; }
.fr-dot { width: 9px; height: 9px; border-radius: 50%; background: #5b5780; flex: none; }
.fr-dot.home { background: #06d6a0; } .fr-dot.lobby { background: #ffd166; } .fr-dot.playing { background: #ff5470; }
.fr-av { width: 34px; height: 34px; border-radius: 50%; background: #3a2f7a; display: grid; place-items: center; font-weight: 900; flex: none; overflow: hidden; }
.fr-av img { width: 100%; height: 100%; object-fit: cover; }
.fr-info { flex: 1; min-width: 0; }
.fr-name { font-weight: 800; font-size: 14px; display: flex; align-items: center; gap: 6px; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.fr-sub { font-size: 11px; color: var(--muted); overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.fr-sub.home { color: #06d6a0; } .fr-sub.lobby { color: #ffd166; } .fr-sub.playing { color: #ff8a9a; }
.fr-acts { display: flex; gap: 4px; flex: none; }
.fr-b { position: relative; background: rgba(255,255,255,.08); border: 1px solid var(--line); color: #fff; border-radius: 8px; width: 30px; height: 30px; cursor: pointer; font-size: 13px; }
.fr-b:hover { border-color: rgba(255,255,255,.5); }
.fr-b.go { background: rgba(6,214,160,.2); border-color: rgba(6,214,160,.6); }
.fr-b.del:hover { border-color: #ff5470; color: #ff8a9a; }
.fr-unread { position: absolute; top: -6px; right: -6px; background: var(--accent); color: #fff; border-radius: 999px; font: 900 10px var(--font); padding: 1px 5px; }
.dm-head { display: flex; align-items: center; gap: 10px; padding: 8px 12px; border-bottom: 1px solid var(--line); }
.dm-title { font-family: var(--display); font-size: 15px; }
.chat-pane.grow { flex: 1; }

/* in-game party chat */
.ig-chat { position: fixed; left: 14px; bottom: 120px; width: min(340px, 60vw); z-index: 12; pointer-events: none; display: flex; flex-direction: column; gap: 4px; }
.ig-list { display: flex; flex-direction: column; gap: 3px; }
.ig-line { background: rgba(8,5,24,.72); border-radius: 10px; padding: 4px 10px; font-size: 13px; line-height: 1.35; word-break: break-word; transition: opacity 1.4s; text-shadow: 0 1px 2px rgba(0,0,0,.6); }
.ig-line.sys { color: var(--muted); font-style: italic; font-size: 12px; }
.ig-line.fade { opacity: 0; }
.ig-input { pointer-events: auto; background: rgba(8,5,28,.9); border: 2px solid var(--accent); color: var(--text); border-radius: 10px; padding: 8px 10px; font: 600 14px var(--font); outline: none; }
.ig-input[hidden] { display: none; }

/* invite */
.invite { position: fixed; left: 50%; top: 18px; transform: translateX(-50%); z-index: 70; background: rgba(28, 22, 70, .97); border: 2px solid var(--accent2); border-radius: 16px; padding: 12px 16px; box-shadow: 0 16px 50px rgba(0,0,0,.6); text-align: center; animation: toastin .25s cubic-bezier(.2,.9,.3,1.3) both; }
.invite-t { font-family: var(--display); font-size: 16px; }
.invite-s { color: var(--muted); font-size: 12px; margin: 2px 0 8px; }
.invite-b { display: flex; gap: 8px; justify-content: center; }
@media (max-width: 560px) { .dock { right: 8px; bottom: 8px; } .dock-panel { height: min(70vh, 560px); } }

/* ---------- Trading Floor ---------- */
.tf { max-width: 1240px; margin: 0 auto; padding: 12px 14px 90px; display: flex; flex-direction: column; gap: 10px; }
.tf-top { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.tf-title { font-family: var(--display); letter-spacing: 3px; font-size: 13px; color: var(--muted); margin-right: auto; }
.tf-chip { background: rgba(8,5,28,.7); border: 1px solid var(--line); border-radius: 999px; padding: 5px 12px; font: 800 13px var(--font); }
.tf-time { font-family: var(--display); font-size: 18px; min-width: 64px; text-align: center; color: var(--accent2); }
.tf-main { display: grid; grid-template-columns: minmax(0, 1.9fr) minmax(280px, 1fr); gap: 12px; align-items: start; }
@media (max-width: 920px) { .tf-main { grid-template-columns: 1fr; } }
.tf-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 10px; }
.tf-card { background: var(--panel); border: 1px solid var(--line); border-radius: 16px; padding: 10px 12px 12px; display: flex; flex-direction: column; gap: 6px; backdrop-filter: blur(10px); }
.tf-ch { display: flex; align-items: baseline; gap: 8px; }
.tf-icon { font-size: 20px; }
.tf-name { font-weight: 800; font-size: 14px; flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.tf-price { font-family: var(--display); font-size: 22px; transition: color .6s; }
.tf-price.flash-up { animation: fup .7s; } .tf-price.flash-dn { animation: fdn .7s; }
@keyframes fup { 0% { color: #06d6a0; transform: scale(1.12); } 100% { color: inherit; transform: none; } }
@keyframes fdn { 0% { color: #ff5470; transform: scale(1.12); } 100% { color: inherit; transform: none; } }
.tf-chg { font: 800 12px var(--font); min-width: 62px; text-align: right; }
.tf-chg.up { color: #06d6a0; } .tf-chg.dn { color: #ff5470; }
.tf-spark { width: 100%; height: 70px; border-radius: 10px; background: rgba(0,0,0,.25); display: block; }
.tf-own { font-size: 12px; color: var(--muted); font-weight: 700; }
.tf-btns { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; }
.tf-buy, .tf-sell { border: 0; border-radius: 10px; padding: 9px 4px; font: 900 13px var(--font); color: #fff; cursor: pointer; transition: transform .08s, filter .15s; }
.tf-buy { background: linear-gradient(180deg, #14c98f, #0a9a6c); box-shadow: 0 3px 0 #06694a; }
.tf-sell { background: linear-gradient(180deg, #ff6b83, #e0364f); box-shadow: 0 3px 0 #9d1f33; }
.tf-buy:hover:not(:disabled), .tf-sell:hover:not(:disabled) { filter: brightness(1.1); }
.tf-buy:active:not(:disabled), .tf-sell:active:not(:disabled) { transform: translateY(2px); box-shadow: none; }
.tf-buy:disabled, .tf-sell:disabled { opacity: .35; cursor: not-allowed; }
.tf-ctrl { display: flex; align-items: center; gap: 6px; margin-top: 10px; flex-wrap: wrap; }
.tf-ctrl-l { color: var(--muted); font-weight: 800; font-size: 13px; margin-right: 4px; }
.tf-q { background: rgba(255,255,255,.07); border: 2px solid var(--line); color: #fff; border-radius: 10px; padding: 7px 14px; font: 900 13px var(--font); cursor: pointer; }
.tf-q.on { border-color: var(--accent2); background: rgba(255,209,102,.16); color: var(--accent2); }
.tf-status { margin-left: 8px; font: 800 13px var(--font); }
.tf-status.ok { color: #8dffc8; } .tf-status.bad { color: #ff8a9a; }
.tf-right { display: flex; flex-direction: column; gap: 10px; }
.tf-panel { background: var(--panel); border: 1px solid var(--line); border-radius: 16px; padding: 10px 12px; }
.tf-panel h3 { margin: 0 0 8px; font-size: 12px; letter-spacing: 1.5px; text-transform: uppercase; color: var(--muted); }
.tf-list { display: flex; flex-direction: column; gap: 6px; max-height: 230px; overflow-y: auto; }
.tf-empty { color: var(--muted); font-size: 12px; font-style: italic; padding: 6px 2px; }
.tf-tip { border-radius: 12px; padding: 8px 10px; border: 1px solid var(--line); background: rgba(8,5,28,.6); animation: rise .3s both; }
.tf-tip.up { border-color: rgba(6,214,160,.55); } .tf-tip.dn { border-color: rgba(255,84,112,.55); }
.tf-tip.old { opacity: .6; }
.tf-tip-h { display: flex; justify-content: space-between; font-size: 12px; font-weight: 800; }
.tf-stars { color: var(--accent2); letter-spacing: 1px; }
.tf-tip-eta { color: var(--muted); }
.tf-tip-t { font-weight: 800; margin: 3px 0 6px; font-size: 14px; }
.tf-tip-b { display: flex; gap: 6px; flex-wrap: wrap; }
.tf-share { background: rgba(255,255,255,.08); border: 1px solid var(--line); color: #fff; border-radius: 8px; padding: 4px 9px; font: 800 11px var(--font); cursor: pointer; }
.tf-share:hover { border-color: rgba(255,255,255,.5); } .tf-share.lie:hover { border-color: #ff5470; }
.tf-news { font-size: 13px; padding: 5px 9px; border-radius: 9px; background: rgba(8,5,28,.55); border-left: 4px solid #6d63a8; animation: rise .3s both; }
.tf-news.news.up { border-left-color: #06d6a0; font-weight: 800; background: rgba(6,214,160,.1); }
.tf-news.news.dn { border-left-color: #ff5470; font-weight: 800; background: rgba(255,84,112,.1); }
.tf-news.rumor { color: #d6d0f2; }
.tf-spread { display: flex; gap: 5px; flex-wrap: wrap; margin-top: 8px; align-items: center; }
.tf-spread select { flex: 1 1 100%; background: rgba(8,5,28,.7); color: var(--text); border: 2px solid var(--line); border-radius: 9px; padding: 6px 8px; font: 700 13px var(--font); }
.tf-sp { flex: 1; border: 1px solid var(--line); background: rgba(255,255,255,.08); color: #fff; border-radius: 9px; padding: 6px; font: 800 12px var(--font); cursor: pointer; }
.tf-sp.up:hover { border-color: #06d6a0; } .tf-sp.dn:hover { border-color: #ff5470; }
.tf-sp-info { flex: 1 1 100%; font-size: 11px; color: var(--muted); }
.tf-lb { display: flex; flex-direction: column; gap: 5px; }
.tf-lbr { display: grid; grid-template-columns: 18px 28px minmax(0, 1fr) 70px 70px; align-items: center; gap: 6px; font-size: 12px; font-weight: 800; padding: 2px 4px; border-radius: 8px; }
.tf-lbr.me { background: rgba(255,209,102,.12); }
.tf-lbp { color: var(--muted); } .tf-lbav { display: grid; place-items: center; width: 28px; height: 28px; }
.tf-lbn { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.tf-lbbar { height: 7px; background: rgba(255,255,255,.1); border-radius: 4px; overflow: hidden; }
.tf-lbbar i { display: block; height: 100%; background: linear-gradient(90deg, #06d6a0, #ffd166); border-radius: 4px; transition: width .6s; }
.tf-lbw { text-align: right; color: var(--accent2); }
.tf-intro { position: fixed; inset: 0; z-index: 20; background: rgba(5,3,18,.8); backdrop-filter: blur(5px); display: grid; place-items: center; padding: 16px; }
.tf-intro[hidden] { display: none; }
.tf-intro-card { max-width: 520px; background: var(--panel); border: 1px solid var(--line); border-radius: 18px; padding: 22px 24px; display: flex; flex-direction: column; gap: 4px; animation: rise .4s both; }
.tf-intro-card h2 { margin: 0 0 6px; font-family: var(--display); font-size: 22px; text-transform: none; letter-spacing: 0; color: var(--accent2); }
.tf-intro-card p { margin: 6px 0; line-height: 1.5; }
