/* TubePainel — complementos do visual instapainel (preto + ouro) */
.hidden { display: none !important; }
.grow { flex: 1; min-width: 0; }
.tp-row { display: flex; align-items: center; gap: 8px; }
.tp-row.wrap, .tp-row .wrap { flex-wrap: wrap; }
.tp-mt { margin-top: 14px; }
.tp-ellipsis { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.tp-grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.tp-grid3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 0 14px; }
.tp-grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.tp-grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; }
.tp-two { display: grid; grid-template-columns: 1fr 1.2fr; gap: 14px; }
.og-select { font-size: 13px; padding: 8px 10px; color: var(--text); }
input.og-select { min-width: 180px; }
.tp-nav-count { margin-left: auto; font-size: 10px; font-weight: 700; background: var(--primary); color: #0a0a0a; padding: 1px 7px; }
.sidebar:not(:hover):not(.is-pinned) .tp-nav-count { display: none; }
.brand-logo { border-radius: 8px; }
.btn-new { text-decoration: none; display: flex; }
.btn .lucide, .btn svg { width: 15px; height: 15px; vertical-align: -3px; }
.btn { display: inline-flex; align-items: center; gap: 6px; text-decoration: none; }
code { font-family: ui-monospace, Consolas, monospace; font-size: 12px; background: rgba(255,255,255,0.06); padding: 1px 6px; color: #E8D48B; }

/* toast + modal */
.tp-toast { position: fixed; left: 50%; bottom: 24px; transform: translate(-50%, 20px); z-index: 10000; opacity: 0; pointer-events: none; transition: .25s; max-width: min(92vw, 560px); }
.tp-toast.on { opacity: 1; transform: translate(-50%, 0); }
.tp-toast .alert { margin: 0; box-shadow: 0 20px 50px -10px rgba(0,0,0,.8); background: #0a0a0a; }
.tp-modal-card { max-width: 560px; max-height: 88vh; overflow: auto; }
.tp-modal-head { display: flex; justify-content: space-between; align-items: center; gap: 10px; }
.modal-card .form-grid textarea { min-height: 90px; }

/* barras */
.tp-bar { height: 5px; background: rgba(255,255,255,0.06); overflow: hidden; margin-top: 6px; }
.tp-bar > i { display: block; height: 100%; background: linear-gradient(90deg, #F5E08A, #C9A227 50%, #8B6914); transition: width .4s; }
.tp-bar--bad > i { background: var(--danger); }
.tp-quota-row { display: flex; justify-content: space-between; font-size: 12.5px; margin: 12px 0 4px; color: var(--text-sec); }
.tp-quota-row b { color: var(--text); }
.tp-quota .tp-bar { height: 8px; }
.tp-up-item { padding: 10px 0; border-bottom: 1px solid rgba(255,255,255,0.04); }
.tp-up-item strong { display: block; font-size: 13px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.tp-up-item span { font-size: 11.5px; color: var(--muted); }
.tp-onboard { margin-bottom: 14px; }
.tp-steps { margin: 0; padding-left: 20px; line-height: 2; color: var(--text-sec); font-size: 14px; }
.tp-steps a, .tp-guide a, .og-empty a { color: #E8D48B; }

/* canais */
.tp-inline-form { display: flex; gap: 8px; align-items: center; margin: 0; }
.tp-empty-card { text-align: center; padding: 42px 20px; }
.tp-empty-card .lucide { width: 34px; height: 34px; color: #C9A227; }
.tp-empty-card h3 { margin: 10px 0 6px; font-family: var(--font-display); }
.tp-channel-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); gap: 14px; }
.tp-channel { display: flex; flex-direction: column; gap: 10px; }
.tp-channel-head { display: flex; gap: 12px; align-items: center; }
.tp-avatar { width: 46px; height: 46px; border-radius: 50%; object-fit: cover; border: 1px solid rgba(201,162,39,0.4); flex: none; background: #111; }
.tp-nums { display: grid; grid-template-columns: repeat(4, 1fr); text-align: center; border-top: 1px solid rgba(255,255,255,0.05); border-bottom: 1px solid rgba(255,255,255,0.05); padding: 10px 0; }
.tp-nums--3 { grid-template-columns: repeat(3, 1fr); }
.tp-nums b { display: block; font: 700 16px var(--font-display); }
.tp-nums span { font-size: 11px; color: var(--muted); }
.tp-actions { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.tp-actions form { margin: 0; }
.tp-err { color: #fca5a5; font-size: 12.5px; margin: 4px 0 0; }
.tp-warn { color: #E8D48B; font-size: 12.5px; margin: 4px 0 0; }
.tp-err-inline { color: #fca5a5; }
.tp-guide ol { line-height: 1.9; padding-left: 20px; color: var(--text-sec); }
.tp-guide h3 { margin-top: 0; }
.tp-copy { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; margin: 6px 0; }
.tp-copy code { padding: 7px 10px; word-break: break-all; }
.tp-app-row { display: flex; gap: 10px; align-items: center; padding: 10px 0; border-bottom: 1px solid rgba(255,255,255,0.04); }
.tp-app-row form { margin: 0; }
.tp-app-row strong { display: block; font-size: 13px; }
.tp-app-row span { font-size: 11.5px; }

/* publicar */
.tp-step { margin-bottom: 14px; }
.form-section-head { flex-wrap: wrap; }
.tp-count { font-size: 11px; color: var(--muted); white-space: nowrap; }
.tp-count .bad, .tp-count.bad { color: var(--danger); }
.dropzone.over { border-color: #C9A227; background: rgba(201,162,39,0.18); }
.tp-vlist { margin-top: 12px; }
.tp-vrow { display: grid; grid-template-columns: 176px 1fr auto; gap: 14px; padding: 10px; margin-bottom: 8px; border: 1px solid rgba(255,255,255,0.06); background: rgba(255,255,255,0.012); }
.tp-vrow:hover { border-color: rgba(201,162,39,0.28); }
.tp-vprev { position: relative; width: 176px; aspect-ratio: 16/9; background: #111; overflow: hidden; cursor: pointer; }
.tp-vprev img, .tp-vprev video { width: 100%; height: 100%; object-fit: cover; display: block; }
.tp-vnum { position: absolute; top: 5px; left: 5px; background: #C9A227; color: #000; font-weight: 700; font-size: 11px; padding: 0 7px; }
.tp-vswap { position: absolute; inset: auto 0 0 0; font-size: 10.5px; text-align: center; background: #000c; color: #F5E08A; padding: 3px; opacity: 0; transition: opacity .2s; }
.tp-vprev:hover .tp-vswap { opacity: 1; }
.tp-vbody { min-width: 0; }
.tp-vtitle { flex: 1; font-weight: 600; }
.tp-vbody input, .tp-vbody textarea, .tp-vbody select, .tp-grid3 input, .tp-grid3 select, .tp-step select, .tp-step input[type=number],
.tp-filters input, .tp-filters select, .tp-cm-box textarea, .tp-templates textarea, .modal-card input, .modal-card select, .modal-card textarea {
  background: #0a0a0a; color: var(--text); border: 1px solid rgba(255,255,255,0.08); padding: 9px 11px; font: 14px var(--font); outline: none; width: 100%;
}
.tp-vbody input:focus, .tp-vbody textarea:focus, .modal-card input:focus, .modal-card textarea:focus, .tp-cm-box textarea:focus { border-color: rgba(201,162,39,0.55); }
.tp-filters select, .tp-filters input, .tp-row select { width: auto; }
.tp-vinfo { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; margin-top: 7px; font-size: 12px; }
.tp-pill { display: inline-flex; align-items: center; gap: 5px; padding: 3px 8px; border: 1px solid rgba(255,255,255,0.07); color: var(--text-sec); font-size: 12px; background: rgba(255,255,255,0.02); }
.tp-pill .lucide { width: 13px; height: 13px; }
.tp-pill.ok { color: var(--success); border-color: rgba(34,197,94,0.3); }
.tp-pill.bad { color: #fca5a5; border-color: rgba(239,68,68,0.35); }
.tp-pill select { width: auto !important; padding: 0 2px !important; border: 0 !important; background: none !important; font-size: 12px !important; color: #E8D48B !important; }
.tp-pill button { background: none; border: 0; color: var(--muted); cursor: pointer; font-size: 12px; padding: 0 2px; }
.tp-vdet { margin-top: 10px; }
.tp-vacts { display: flex; flex-direction: column; gap: 6px; }
.tp-chanpick { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 10px; }
.tp-chan { border: 1px solid rgba(255,255,255,0.06); padding: 10px 12px; background: rgba(255,255,255,0.015); }
.tp-chan.on { border-color: rgba(201,162,39,0.5); background: rgba(201,162,39,0.06); }
.tp-chan.off { opacity: .55; }
.tp-chan-head { display: flex !important; flex-direction: row !important; align-items: center; gap: 10px; cursor: pointer; color: var(--text) !important; font-size: 13.5px !important; font-weight: 600; margin: 0; }
.tp-chan-head input { accent-color: #C9A227; width: auto; }
.tp-chan-head img { width: 26px; height: 26px; border-radius: 50%; object-fit: cover; }
.tp-chan select { margin-top: 8px; font-size: 12.5px; padding: 7px 9px; }
.tp-toggles { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; margin-top: 14px; }
.tp-tg { display: flex; gap: 12px; align-items: flex-start; padding: 12px 14px; border: 1px solid rgba(255,255,255,0.06); background: rgba(255,255,255,0.015); cursor: pointer; font-size: 13px; color: var(--text); }
.tp-tg--row { margin-bottom: 8px; }
.tp-tg:has(input:checked) { border-color: rgba(201,162,39,0.5); background: rgba(201,162,39,0.06); }
.tp-tg input[type="checkbox"] { margin-top: 1px; }
.tp-tg b { display: block; font-weight: 600; }
.tp-tg small { display: block; color: var(--muted); font-size: 11.5px; margin-top: 2px; }
.tp-sub { border-top: 1px solid rgba(255,255,255,0.05); margin-top: 18px; padding-top: 14px; }
.tp-sub p { font-size: 13px; margin: 4px 0; }
.tp-sub-tit { display: flex; align-items: center; gap: 8px; font-weight: 600; flex-wrap: wrap; }
.tp-sub-tit .lucide { width: 16px; height: 16px; color: #C9A227; }
.tp-sub--locked .tp-sub-tit, .tp-sub--locked .tp-sub-tit .lucide { color: var(--muted); }
.tp-chips { display: flex; flex-wrap: wrap; gap: 6px; margin: 10px 0 6px; }
.tp-chip { font-size: 12px; padding: 6px 11px; border: 1px solid rgba(255,255,255,0.08); background: rgba(255,255,255,0.02); color: var(--text-sec); cursor: pointer; user-select: none; }
.tp-chip.on { border-color: rgba(201,162,39,0.6); background: rgba(201,162,39,0.12); color: #F5E08A; }
.tp-chip.off { cursor: default; opacity: .5; text-decoration: line-through; }
.tp-check { display: flex !important; flex-direction: row !important; gap: 8px; align-items: center; color: var(--text) !important; font-size: 13px !important; cursor: pointer; margin-top: 6px; }
.tp-check input { accent-color: #C9A227; width: auto; }
.tp-summary { margin-bottom: 30px; }
.tp-send { width: 100%; padding: 14px; font-size: 15px; justify-content: center; margin-top: 12px; }
.tp-sumkpis { display: flex; gap: 10px; flex-wrap: wrap; margin-bottom: 12px; }
.tp-sumkpis div { border: 1px solid rgba(255,255,255,0.06); padding: 8px 12px; font-size: 12px; color: var(--muted); }
.tp-sumkpis b { font: 700 18px var(--font-display); color: var(--text); margin-right: 5px; }
.tp-sumtable { max-height: 340px; overflow: auto !important; border: 1px solid rgba(255,255,255,0.05); }
.tp-sumtable th { position: sticky; top: 0; background: #070707; }

/* agenda */
.tp-toolbar { display: flex; flex-direction: column; align-items: flex-start; gap: 10px; margin-bottom: 14px; padding: 14px 16px; }
.tp-toolbar .og-period-pills, .tp-step .og-period-pills { margin-left: 0; flex-wrap: wrap; }
.og-period-pills .period-pill { cursor: pointer; }
.tp-filters { flex-wrap: wrap; }
.tp-day { font-size: 11.5px; font-weight: 600; text-transform: uppercase; letter-spacing: .08em; color: #E8D48B; margin: 20px 0 10px; display: flex; gap: 10px; align-items: center; }
.tp-day::after { content: ""; flex: 1; height: 1px; background: rgba(255,255,255,0.06); }
.tp-item { display: grid; grid-template-columns: 136px 1fr auto; gap: 14px; align-items: center; padding: 10px 12px; margin-bottom: 8px; border: 1px solid rgba(255,255,255,0.05); background: radial-gradient(ellipse 100% 75% at 50% 115%, rgba(201,162,39,0.05), transparent 55%), #050505; }
.tp-item:hover { border-color: rgba(201,162,39,0.28); }
.tp-thumb { width: 136px; aspect-ratio: 16/9; object-fit: cover; background: #111; display: block; }
.tp-thumb--ph { display: grid; place-items: center; color: #6b7280; }
.tp-item-body { min-width: 0; }
.tp-item-title { display: block; font-size: 14px; overflow: hidden; text-overflow: ellipsis; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
.tp-item-meta { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; margin-top: 5px; font-size: 12px; color: var(--muted); }
.tp-chan-mini { display: inline-flex; gap: 6px; align-items: center; color: var(--text-sec); }
.tp-chan-mini img { width: 18px; height: 18px; border-radius: 50%; }
.tp-item-acts { display: flex; gap: 6px; flex-wrap: wrap; justify-content: flex-end; max-width: 300px; }
.tp-cal { margin-bottom: 14px; }
.tp-cal-head { display: flex; align-items: center; gap: 12px; margin-bottom: 12px; flex-wrap: wrap; }
.tp-cal-head strong { font: 700 16px var(--font-display); text-transform: capitalize; min-width: 160px; text-align: center; }
.tp-cal-legend { margin-left: auto; font-size: 11px; color: var(--muted); display: flex; gap: 8px; align-items: center; }
.tp-cal-legend i, .tp-cal-dots i { display: inline-block; min-width: 10px; height: 10px; }
.tp-cal-grid { display: grid; grid-template-columns: repeat(7, 1fr); gap: 4px; }
.tp-cal-wd { font-size: 10.5px; text-transform: uppercase; letter-spacing: .08em; color: var(--muted); text-align: center; padding: 4px 0; }
.tp-cal-cell { min-height: 92px; border: 1px solid rgba(255,255,255,0.05); background: rgba(255,255,255,0.015); padding: 6px; text-align: left; color: var(--text); cursor: pointer; display: flex; flex-direction: column; gap: 3px; font: 12px var(--font); overflow: hidden; }
.tp-cal-cell:hover { border-color: rgba(201,162,39,0.35); }
.tp-cal-cell.today { border-color: rgba(201,162,39,0.6); }
.tp-cal-cell.sel { background: rgba(201,162,39,0.1); border-color: #C9A227; }
.tp-cal-cell--off { background: none; border: 0; cursor: default; }
.tp-cal-n { font-weight: 700; }
.tp-cal-dots { display: flex; gap: 3px; flex-wrap: wrap; }
.tp-cal-dots i { font-style: normal; font-size: 10px; font-weight: 700; padding: 0 4px; color: #0a0a0a; height: auto; }
:is(.tp-cal-dots, .tp-cal-legend) i.g { background: #C9A227; }
:is(.tp-cal-dots, .tp-cal-legend) i.ok { background: #22c55e; }
:is(.tp-cal-dots, .tp-cal-legend) i.y { background: #fbbf24; }
:is(.tp-cal-dots, .tp-cal-legend) i.r { background: #ef4444; }
.tp-cal-legend i { margin-left: 6px; }
.tp-cal-ev { font-size: 10.5px; color: var(--text-sec); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.tp-cal-more { font-size: 10px; color: #E8D48B; }

/* comentários */
.tp-comments-layout { display: grid; grid-template-columns: 1fr 300px; gap: 14px; align-items: start; }
.tp-templates { position: sticky; top: 0; }
.tp-tpl-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 6px; }
.tp-tpl-list li { display: flex; gap: 8px; align-items: flex-start; font-size: 12.5px; padding: 8px; border: 1px solid rgba(255,255,255,0.06); color: var(--text-sec); }
.tp-tpl-list li span { flex: 1; white-space: pre-wrap; }
.tp-x { background: none; border: 0; color: var(--muted); cursor: pointer; font-size: 12px; padding: 0 4px; }
.tp-x:hover { color: var(--danger); }
.tp-cm { margin-bottom: 10px; padding: 16px 18px; }
.tp-cm.answered { border-color: rgba(34,197,94,0.18); }
.tp-cm-head { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.tp-cm-av { width: 36px; height: 36px; border-radius: 50%; flex: none; background: #111; }
.tp-cm-video { display: flex; gap: 8px; align-items: center; max-width: 260px; font-size: 12px; color: var(--text-sec); text-decoration: none; margin-left: auto; }
.tp-cm-video img { width: 64px; aspect-ratio: 16/9; object-fit: cover; flex: none; }
.tp-cm-video span { overflow: hidden; text-overflow: ellipsis; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
.tp-cm-text { margin: 10px 0 6px; white-space: pre-wrap; word-break: break-word; line-height: 1.55; font-size: 14px; }
.tp-cm-replies { margin-left: 46px; display: flex; flex-direction: column; gap: 6px; }
.tp-cm-reply { display: flex; gap: 8px; align-items: flex-start; font-size: 13px; padding: 8px; background: rgba(255,255,255,0.02); }
.tp-cm-reply.mine { background: rgba(201,162,39,0.06); border-left: 2px solid #C9A227; }
.tp-cm-reply img { width: 24px; height: 24px; border-radius: 50%; flex: none; }
.tp-cm-reply p { margin: 3px 0 0; white-space: pre-wrap; word-break: break-word; }
.tp-cm-box { margin: 10px 0 0 46px; display: flex; flex-direction: column; gap: 8px; }
.tp-tpl-pick { max-width: 220px; }

/* vídeos */
.tp-vgrid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 14px; }
.tp-vcard { display: flex; flex-direction: column; gap: 8px; padding: 12px; }
.tp-vcard-thumb { position: relative; display: block; aspect-ratio: 16/9; background: #111; overflow: hidden; }
.tp-vcard-thumb img { width: 100%; height: 100%; object-fit: cover; }
.tp-vcard-thumb span { position: absolute; right: 6px; bottom: 6px; background: #000c; color: #fff; font-size: 11px; padding: 1px 5px; }
.tp-vcard-title { font-size: 13.5px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; min-height: 2.6em; }

/* analytics */
.tp-minikpis { display: flex; gap: 10px; flex-wrap: wrap; }
.tp-minikpis div { flex: 1; min-width: 120px; border: 1px solid rgba(255,255,255,0.05); padding: 10px 14px; background: #050505; }
.tp-minikpis b { display: block; font: 700 18px var(--font-display); }
.tp-minikpis span { font-size: 11px; color: var(--muted); }
.tp-hbar { margin-bottom: 10px; }
.tp-hbar-top { display: flex; justify-content: space-between; gap: 10px; font-size: 12.5px; color: var(--text-sec); }
.tp-hbar-top b { color: var(--text); font-weight: 600; white-space: nowrap; }
.tp-top td { vertical-align: middle; }
.tp-top-v { display: flex; gap: 10px; align-items: center; color: var(--text); text-decoration: none; max-width: 340px; }
.tp-top-v img { width: 72px; aspect-ratio: 16/9; object-fit: cover; flex: none; }
.tp-top-v span { overflow: hidden; text-overflow: ellipsis; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; font-size: 12.5px; }

/* notificações */
.tp-notif a { display: block; padding: 10px 12px; color: var(--text); text-decoration: none; }
.tp-notif a:hover { background: rgba(201,162,39,0.05); }
.tp-notif.unread a { background: rgba(201,162,39,0.06); }
.tp-notif b { display: block; font-size: 12.5px; }
.tp-notif span { display: block; font-size: 11.5px; color: var(--muted); margin-top: 2px; }
.tp-notif small { display: block; font-size: 10.5px; color: #6b7280; margin-top: 3px; }
.notif-list li.tp-notif { padding: 0; }
.tp-notif-page { max-height: none !important; }

/* páginas públicas */
body.tp-public { overflow: auto; height: auto; background: #050505; }
html:has(body.tp-public) { overflow: auto; }
.tp-doc { max-width: 760px; margin: 0 auto; padding: 40px 20px 60px; line-height: 1.7; color: var(--text-sec); }
.tp-doc h1 { font-family: var(--font-display); color: var(--text); margin: 18px 0 4px; }
.tp-doc h2 { color: var(--text); font-size: 17px; margin: 26px 0 6px; }
.tp-doc a { color: #E8D48B; }
.tp-doc-brand { display: inline-flex; align-items: center; gap: 10px; font: 700 20px var(--font-display); color: var(--text) !important; text-decoration: none; }
.tp-doc-brand span { color: #C9A227; }
.tp-doc-brand img { border-radius: 8px; }

@media (max-width: 1100px) {
  .tp-toggles { grid-template-columns: 1fr 1fr; }
  .tp-comments-layout { grid-template-columns: 1fr; }
  .tp-templates { position: static; }
  .tp-grid-3 { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 860px) {
  .tp-grid2, .tp-grid3, .tp-grid-2, .tp-grid-3, .tp-two, .tp-toggles { grid-template-columns: 1fr; }
  .tp-vrow { grid-template-columns: 1fr; }
  .tp-vprev { width: 100%; }
  .tp-vacts { flex-direction: row; }
  .tp-item { grid-template-columns: 96px 1fr; }
  .tp-thumb { width: 96px; }
  .tp-item-acts { grid-column: 1 / -1; justify-content: flex-start; max-width: none; }
  .tp-cal-cell { min-height: 58px; }
  .tp-cal-ev { display: none; }
  .tp-cm-replies, .tp-cm-box { margin-left: 0; }
  .tp-cm-video { margin-left: 0; max-width: 100%; }
  .tp-filters select, .tp-filters input { width: 100%; }
  input.og-select { min-width: 0; }
  .tp-inline-form { flex-wrap: wrap; }
}
