.tx-radar, .tx-order, .tx-rundown-tools {
  --tx-panel: #fff;
  --tx-ink: #17212c;
  --tx-muted: #475569;
  --tx-line: #cad0d7;
  --tx-accent: #b45309;
  color: var(--tx-ink);
}
body[data-theme="dark"] :is(.tx-radar, .tx-order, .tx-rundown-tools), .tx-studio {
  --tx-panel: #121820;
  --tx-ink: #f4f6f8;
  --tx-muted: #bdc7d2;
  --tx-line: #465362;
  --tx-accent: #f6c888;
}
.tx-btn, .tx-radar input, .tx-radar select, .tx-studio select {
  min-width: 0;
  max-width: 100%;
  min-height: 38px;
  padding: .45rem .8rem;
  border: 1px solid var(--tx-line);
  border-radius: .55rem;
  background: var(--tx-panel);
  color: var(--tx-ink);
  font: inherit;
  font-size: .84rem;
}
.tx-btn { cursor: pointer; font-weight: 700; }
.tx-btn:disabled { cursor: default; opacity: .55; }
.tx-btn:not(:disabled):hover { border-color: var(--tx-accent); }
:is(.tx-radar, .tx-order, .tx-rundown-tools, .tx-studio) :focus-visible {
  outline: 3px solid var(--tx-accent);
  outline-offset: 2px;
}
.tx-rundown-tools, .tx-order, .tx-filters, .tx-controls, .tx-bar, .tx-news-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: .5rem;
  min-width: 0;
}
.tx-rundown-tools { margin-bottom: 1rem; justify-content: space-between; }
.tx-action { color: #fff; background: #dc2626; border-color: #dc2626; }
.tx-action:hover:not(:disabled) { background: #b91c1c; border-color: #b91c1c; }
.tx-order { justify-content: flex-end; margin-top: .7rem; }
.tx-order button { min-height: 32px; font-size: .78rem; }
.tx-radar {
  margin-top: 1.25rem; padding: clamp(.9rem, 3vw, 1.5rem);
  border: 1px solid var(--tx-line); border-radius: 1rem; background: var(--tx-panel);
}
.tx-radar h3 { margin: 0 0 .85rem; font-size: 1.2rem; font-weight: 800; }
.tx-radar summary { cursor: pointer; color: var(--tx-accent); font-size: .84rem; font-weight: 700; }
.tx-radar details { margin: .85rem 0; }
.tx-radar details form { margin: .7rem 0; }
.tx-radar :is(input,select) { flex: 1 1 11rem; }
.tx-status, .tx-meta, .tx-story-meta { color: var(--tx-muted); font-size: .8rem; }
.tx-story-meta { font-weight: 700; white-space: nowrap; }
.tx-news { list-style: none; margin: 0; padding: 0; }
.tx-news li {
  display: grid; grid-template-columns: minmax(0,1fr) auto; align-items: center; gap: .8rem;
  border-top: 1px solid var(--tx-line); padding: .85rem 0; overflow-wrap: anywhere;
}
.tx-news li:first-child { margin-top: .75rem; }
.tx-news-title { display: inline-block; color: var(--tx-ink); font-size: 1rem; font-weight: 700; }
a.tx-news-title:hover { text-decoration: underline; }
.tx-news-summary {
  color: var(--tx-muted); font-size: .85rem; margin-top: .25rem;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}
.tx-studio {
  position: fixed; inset: 0; z-index: 2147483647; box-sizing: border-box; width: 100%; max-width: none;
  height: 100vh; height: 100dvh; display: grid; grid-template-rows: auto minmax(0,1fr) auto;
  background: #080c11; color: var(--tx-ink); overflow: hidden;
}
.tx-studio .tx-bar, .tx-studio .tx-controls {
  padding: .65rem max(.85rem, env(safe-area-inset-right)) .65rem max(.85rem, env(safe-area-inset-left));
  background: var(--tx-panel); color: var(--tx-ink);
}
.tx-studio .tx-bar { border-bottom: 1px solid var(--tx-line); padding-top: max(.65rem, env(safe-area-inset-top)); }
.tx-studio .tx-controls {
  justify-content: center; border-top: 1px solid var(--tx-line);
  padding-bottom: max(.65rem, env(safe-area-inset-bottom));
}
.tx-studio .tx-btn, .tx-studio select { min-height: 40px; }
.tx-studio .tx-bar select { flex: 1 1 8rem; }
.tx-clock-label { font-size: .8rem; color: var(--tx-muted); }
.tx-clock { font-variant-numeric: tabular-nums; font-size: 1.2rem; font-weight: 800; color: var(--tx-accent); }
.tx-speed { display: inline-flex; align-items: center; gap: .5rem; min-width: 0; max-width: 100%; font-size: .8rem; }
.tx-speed input { width: clamp(5rem, 12vw, 9rem); max-width: 100%; accent-color: var(--tx-accent); }
.tx-speed span { font-variant-numeric: tabular-nums; min-width: 4rem; }
.tx-stage {
  position: relative;
  min-height: 0;
  display: flex;
  flex-direction: column;
}
.tx-cueline {
  position: absolute;
  left: 0;
  right: 0;
  top: 28%;
  height: 2px;
  background: linear-gradient(90deg, #ef4444, rgba(246, 200, 136, 0.55), #ef4444);
  pointer-events: none;
  z-index: 5;
  box-shadow: 0 0 12px rgba(239, 68, 68, 0.5);
}
.tx-cueline::before {
  content: "▶";
  position: absolute;
  left: 10px;
  top: -11px;
  color: #ef4444;
  font-size: 16px;
}
.tx-reader {
  flex: 1;
  min-width: 0;
  overflow-y: auto;
  overscroll-behavior: contain;
  scrollbar-gutter: stable;
  padding: 22vh clamp(1.2rem, 7vw, 9rem) 45vh;
  font-size: var(--tx-font, 48px);
  line-height: 1.52;
  overflow-wrap: anywhere;
  text-align: left;
  transition: transform 0.2s ease;
}
.tx-reader.tx-mirrored {
  transform: scaleX(-1);
}
.tx-kicker {
  font-size: 0.36em;
  letter-spacing: 0.08em;
  font-weight: 800;
  color: #f87171;
  margin-bottom: 0.5em;
}
.tx-reader h2 { font-size: 1.05em; color: var(--tx-accent); line-height: 1.16; font-weight: 800; margin: 0 0 .75em; }
.tx-reader p { margin: 0; color: var(--tx-ink); white-space: pre-wrap; font-weight: 500; }
@media (max-width: 600px) {
  .tx-news li { grid-template-columns: 1fr; }
  .tx-news-actions { justify-content: flex-start; }
  .tx-studio .tx-controls { gap: .35rem; }
  .tx-studio .tx-btn { min-height: 42px; padding-inline: .55rem; font-size: .78rem; }
  .tx-studio .tx-speed { justify-content: center; flex-basis: 100%; }
  .tx-studio .tx-speed input { flex: 1; max-width: 12rem; }
}
@media print {
  .tx-order,.tx-rundown-tools,.tx-studio,.tx-radar { display: none !important; }
}
