/* Twitch-Kategorie / Titelzusatz (twitch-meta.js) – Desktop + Tablet + Handy */
.tw-meta { border: 1px solid var(--line-2, rgba(255,255,255,.12)); border-radius: 10px; padding: 10px 12px 12px; background: rgba(145,70,255,.06); display: flex; flex-direction: column; gap: 4px; }
.tw-meta-head { font-weight: 700; font-size: 13px; display: flex; align-items: center; gap: 6px; color: #c4a5ff; margin-bottom: 2px; }
.tw-meta-icon, .tw-media-ic { width: 14px; height: 14px; display: inline-block; flex: none; background: #9146ff; border-radius: 3px;
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M4 2 2 6v14h5v3h3l3-3h4l5-5V2H4zm16 12-3 3h-5l-3 3v-3H5V4h15v10zM15 7h2v5h-2zM10 7h2v5h-2z'/%3E%3C/svg%3E") center/contain no-repeat;
  mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M4 2 2 6v14h5v3h3l3-3h4l5-5V2H4zm16 12-3 3h-5l-3 3v-3H5V4h15v10zM15 7h2v5h-2zM10 7h2v5h-2z'/%3E%3C/svg%3E") center/contain no-repeat; }
.tw-lbl { font-size: 12px; color: var(--muted, #9b94ad); margin-top: 6px; }
.tw-lbl .opt { opacity: .75; font-weight: 400; }
.tw-meta input[type="search"], .tw-meta input[type="text"], .tw-meta select { width: 100%; box-sizing: border-box; min-height: 40px; font-size: 16px;
  border-radius: 10px; border: 1px solid var(--line-2, rgba(255,255,255,.12)); background: var(--elev, #15121f); color: var(--text, #f4f1fb); padding: 8px 10px; font-family: inherit; }
.tw-meta input:focus, .tw-meta select:focus { outline: none; border-color: rgba(145,70,255,.7); box-shadow: 0 0 0 3px rgba(145,70,255,.2); }
.tw-meta input::placeholder { color: var(--muted, #9b94ad); opacity: .8; }
@media (min-width: 1101px) and (pointer: fine) { .tw-meta input[type="search"], .tw-meta input[type="text"], .tw-meta select { font-size: 14px; } }
.tw-cat { position: relative; }
.tw-cat-list { position: absolute; z-index: 60; left: 0; right: 0; top: calc(100% + 4px); margin: 0; padding: 4px; list-style: none; max-height: 280px; overflow: auto;
  background: var(--card-2, #221e30); border: 1px solid var(--line-2, rgba(255,255,255,.12)); border-radius: 10px; box-shadow: 0 12px 30px rgba(0,0,0,.45); -webkit-overflow-scrolling: touch; }
.tw-cat-list li { display: flex; align-items: center; gap: 10px; padding: 6px 8px; border-radius: 8px; cursor: pointer; min-height: 44px; }
.tw-cat-list li:hover, .tw-cat-list li:focus { background: rgba(145,70,255,.18); }
.tw-cat-list img { width: 26px; height: 36px; object-fit: cover; border-radius: 3px; background: #000; flex: none; }
.tw-cat-list .tw-empty { color: var(--muted, #9b94ad); cursor: default; }
.tw-cat-chip { display: flex; align-items: center; gap: 8px; padding: 5px 6px 5px 8px; border-radius: 8px; background: rgba(145,70,255,.18); border: 1px solid rgba(145,70,255,.45); min-height: 40px; box-sizing: border-box; }
.tw-cat-chip[hidden] { display: none; }
.tw-cat-art { width: 22px; height: 30px; object-fit: cover; border-radius: 3px; }
.tw-cat-art[hidden] { display: none; }
.tw-cat-name { flex: 1; font-weight: 600; }
.tw-cat-clear { background: none; border: 0; color: inherit; font-size: 20px; line-height: 1; width: 36px; height: 36px; cursor: pointer; border-radius: 6px; }
.tw-cat-clear:hover { background: rgba(255,255,255,.08); }
.tw-check { display: flex; align-items: center; gap: 8px; margin-top: 8px; font-size: 14px; min-height: 36px; }
.tw-check input { width: 20px; height: 20px; }
.tw-preview { margin-top: 8px; font-size: 12px; color: var(--muted, #9b94ad); line-height: 1.4; word-break: break-word; }
.tw-prev-k { font-weight: 600; }
.tw-prev-cat { color: #c4a5ff; font-weight: 600; }
.tw-prev-title { color: var(--text, #f4f1fb); }
/* Sendeplan-Label */
.tw-cat-label { display: inline-flex; align-items: center; max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 10px; line-height: 1; font-weight: 600;
  padding: 2px 5px; border-radius: 4px; background: rgba(145,70,255,.22); color: #d6c2ff; border: 1px solid rgba(145,70,255,.4); margin-left: 4px; vertical-align: middle; }
.post.is-slim .tw-cat-label, .post.is-tiny .tw-cat-label { display: none; }
.slot-hover-tw { font-size: 12px; color: #c4a5ff; margin: 4px 0; }
/* Mediathek-Knopf */
.tw-media-btn { display: inline-flex; align-items: center; gap: 5px; font-size: 11px; font-weight: 600; padding: 3px 7px; border-radius: 6px; cursor: pointer; min-height: 26px;
  background: transparent; color: var(--muted, #9b94ad); border: 1px dashed rgba(145,70,255,.45); max-width: 180px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.tw-media-btn.has-cat { background: rgba(145,70,255,.18); color: #d6c2ff; border-style: solid; }
.tw-media-btn:hover { border-color: #9146ff; color: #fff; }
/* Dialog (Mediathek) */
.tw-modal { position: fixed; inset: 0; z-index: 1000; background: rgba(5,4,10,.65); display: flex; align-items: center; justify-content: center; padding: 16px; }
.tw-modal[hidden] { display: none; }
.tw-modal-card { width: min(480px, 100%); max-height: calc(100dvh - 32px); overflow: auto; background: var(--card, #1c1928); border: 1px solid var(--line-2, rgba(255,255,255,.12)); border-radius: 14px; padding: 16px; box-shadow: 0 20px 50px rgba(0,0,0,.5); }
.tw-modal-top { display: flex; align-items: center; justify-content: space-between; }
.tw-modal-top h2 { margin: 0; font-size: 18px; }
.tw-modal-x { background: none; border: 0; color: inherit; font-size: 26px; width: 44px; height: 44px; cursor: pointer; }
.tw-modal-name { color: var(--muted, #9b94ad); font-size: 13px; margin: 2px 0 10px; word-break: break-word; }
.tw-modal-err { color: #ff8a8a; font-size: 13px; margin-top: 8px; }
.tw-modal-actions { display: flex; gap: 8px; justify-content: flex-end; margin-top: 14px; }
.tw-modal-actions .btn { min-height: 44px; padding: 0 18px; border-radius: 10px; font-weight: 650; cursor: pointer; font-family: inherit; font-size: 15px; }
.tw-modal-actions .tw-modal-cancel { background: transparent; color: var(--text, #f4f1fb); border: 1px solid var(--line-2, rgba(255,255,255,.12)); }
.tw-modal-actions .tw-modal-save { width: auto; margin-top: 0; border: 0; color: #fff; background: linear-gradient(135deg, #a970ff 0%, #9146ff 55%, #772ce8 100%); box-shadow: 0 6px 16px rgba(145,70,255,.35); }
body.tw-modal-open { overflow: hidden; }
@media (max-width: 700px), (pointer: coarse) and (max-width: 1100px) {
  .tw-modal { align-items: flex-end; padding: 0; }
  .tw-modal-card { width: 100%; max-height: 92dvh; border-radius: 16px 16px 0 0; padding: 14px 14px calc(14px + env(safe-area-inset-bottom)); }
  .tw-modal-actions .btn { flex: 1; }
  .tw-media-btn { min-height: 32px; font-size: 12px; }
  .tw-cat-list { max-height: 45dvh; }
}
