/* ════════════════════════ Threads · monocromo elegante ════════════════════════ */
.th-seccion { display: flex; flex-direction: column; }
.th-entrar { animation: aparecer .4s cubic-bezier(.2,.8,.2,1); }
.th-1linea { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
:root[data-red="threads"] .tarjeta { background: rgba(255, 255, 255, .035); }
:root[data-red="threads"][data-tema="claro"] .tarjeta { background: rgba(255, 255, 255, .85); }
:root[data-red="threads"] .kpi .chispa path[stroke] { stroke: #C9C9FF; }

/* Héroe: negro profundo con hilos de luz que se dibujan */
.th-heroe { position: relative; border-radius: 26px; overflow: hidden; margin: 6px 0 20px; padding: 28px 30px 24px; color: #fff;
  background: radial-gradient(circle at 85% 0%, rgba(201, 201, 255, .18), transparent 45%), linear-gradient(160deg, #141414 0%, #050505 60%, #0d0d14 100%);
  border: 1px solid #2a2a2a; box-shadow: 0 24px 70px rgba(0, 0, 0, .55), inset 0 1px 0 rgba(255, 255, 255, .06); }
.th-heroe-fondo { position: absolute; right: -50px; bottom: -70px; width: 320px; height: 320px; opacity: .07; animation: th-giro 40s linear infinite; }
.th-heroe-fondo svg { width: 100%; height: 100%; }
@keyframes th-giro { to { transform: rotate(360deg); } }
.th-heroe-hilos { position: absolute; inset: 0; pointer-events: none; overflow: hidden; }
.th-heroe-hilos i { position: absolute; left: -10%; width: 120%; height: 1px; background: linear-gradient(90deg, transparent, rgba(255, 255, 255, .5), transparent); animation: th-hilo 7s ease-in-out infinite; opacity: 0; }
.th-heroe-hilos i:nth-child(1) { top: 30%; }
.th-heroe-hilos i:nth-child(2) { top: 62%; animation-delay: 2.3s; }
.th-heroe-hilos i:nth-child(3) { top: 84%; animation-delay: 4.6s; }
@keyframes th-hilo { 0% { transform: translateX(-60%); opacity: 0; } 30% { opacity: 1; } 100% { transform: translateX(60%); opacity: 0; } }
.th-heroe-fila { position: relative; display: flex; align-items: flex-start; gap: 20px; }
.th-heroe-txt { flex: 1; min-width: 0; }
.th-heroe-txt h1 { font-size: 30px; letter-spacing: -.03em; display: flex; align-items: center; gap: 8px; }
.th-verif .ico { width: 22px; height: 22px; color: #0095F6; }
.th-usuario { margin-top: 4px; font-size: 15px; display: flex; align-items: center; gap: 8px; color: #e5e5e5; }
.th-chip-net { font-size: 11.5px; padding: 3px 10px; border-radius: 20px; background: #262626; color: #a8a8a8; }
.th-bio { margin-top: 12px; max-width: 620px; white-space: pre-wrap; color: #d4d4d4; }
.th-heroe-stats { margin-top: 12px; color: #8e8e8e; font-size: 14px; }
.th-heroe-stats b { color: #fff; }
.th-heroe-foto { width: 84px; height: 84px; border-radius: 50%; overflow: hidden; flex: none; background: #1f1f1f; display: grid; place-items: center; font-size: 28px; font-weight: 700; border: 1px solid #333; }
.th-heroe-foto img { width: 100%; height: 100%; object-fit: cover; }
.th-heroe-acc { position: relative; display: flex; gap: 8px; margin-top: 20px; }
.th-heroe-acc .btn { flex: 1; max-width: 260px; background: transparent; border: 1px solid #3a3a3a; color: #fff; text-decoration: none; }
.th-heroe-acc .btn:hover { background: #1a1a1a; border-color: #555; }
.th-heroe-acc .btn.blanco { background: #fff; color: #000; border: 0; font-weight: 800; }
.th-heroe-acc .btn.blanco:hover { background: #e9e9e9; }

/* Editor de hilos */
.th-partes { display: flex; flex-direction: column; margin-top: 14px; }
.th-parte { display: flex; gap: 14px; align-items: flex-start; padding-bottom: 14px; }
.th-parte-col { display: flex; flex-direction: column; align-items: center; align-self: stretch; padding-top: 4px; }
.th-parte-n { width: 30px; height: 30px; border-radius: 50%; display: grid; place-items: center; font-weight: 800; font-size: 13px; background: var(--texto); color: var(--fondo); flex: none; }
.th-parte-linea { flex: 1; width: 2px; margin-top: 6px; border-radius: 2px; background: linear-gradient(var(--borde-fuerte), var(--borde)); min-height: 20px; }
.th-barra-publicar { position: sticky; bottom: 0; padding: 14px 18px; border-radius: 18px; background: var(--panel-solido); border: 1px solid var(--borde-fuerte); box-shadow: var(--sombra-2); z-index: 3; }

/* Vista previa (app oscura) */
.thp { position: absolute; inset: 0; overflow-y: auto; overflow-x: hidden; background: #101010; color: #f3f5f7; padding-top: 40px; font-size: 13px; scrollbar-width: none; padding-bottom: 60px; }
.thp::-webkit-scrollbar { display: none; }
.thp-barra { display: flex; justify-content: center; padding: 4px 0 8px; }
.thp-logo { width: 26px; height: 26px; }
.thp-logo svg { width: 100%; height: 100%; }
.thp-pest { display: flex; border-bottom: 1px solid #262626; }
.thp-pest b, .thp-pest span { flex: 1; text-align: center; padding: 8px 0; font-size: 13px; }
.thp-pest b { border-bottom: 1px solid #f3f5f7; }
.thp-pest span { color: #777; }
.thp-parte { display: flex; gap: 10px; padding: 12px 12px 0; }
.thp-col { display: flex; flex-direction: column; align-items: center; }
.thp-av { border-radius: 50%; object-fit: cover; flex: none; }
.thp-av-ini { display: grid; place-items: center; background: #2a2a2a; color: #fff; font-weight: 800; font-size: 12px; border: 1px solid #3a3a3a; }
.thp-linea { flex: 1; width: 2px; background: #333; margin: 6px 0 -2px; border-radius: 2px; min-height: 16px; }
.thp-cuerpo { flex: 1; min-width: 0; padding-bottom: 10px; }
.thp-cab { display: flex; align-items: center; gap: 4px; font-size: 13.5px; }
.thp-cab > .ico { width: 16px; height: 16px; color: #777; }
.thp-tema { display: inline-flex; align-items: center; gap: 1px; color: #9a9a9a; font-weight: 500; }
.thp-tema .ico { width: 12px; height: 12px; }
.thp-hora { color: #777; margin-left: 4px; }
.thp-txt { margin-top: 2px; white-space: pre-wrap; word-break: break-word; line-height: 1.38; }
.thp-enl { color: #6CA8FF; }
.thp-medio { margin-top: 8px; border-radius: 10px; overflow: hidden; border: 1px solid #262626; }
.thp-medio img, .thp-medio video { width: 100%; max-height: 300px; object-fit: cover; display: block; }
.thp-carrusel { display: flex; gap: 6px; overflow-x: auto; margin-top: 8px; scrollbar-width: none; }
.thp-c { flex: none; width: 150px; height: 200px; border-radius: 10px; overflow: hidden; border: 1px solid #262626; }
.thp-c img, .thp-c video { width: 100%; height: 100%; object-fit: cover; }
.thp-tarjeta-enlace { margin-top: 8px; display: flex; gap: 8px; align-items: center; padding: 10px 12px; border-radius: 10px; border: 1px solid #333; color: #bbb; font-size: 12.5px; }
.thp-tarjeta-enlace .ico { width: 15px; height: 15px; }
.thp-cita { margin-top: 8px; padding: 10px 12px; border-radius: 10px; border: 1px solid #333; font-size: 12.5px; }
.thp-gris { color: #777; margin-top: 3px; font-size: 11.5px; }
.thp-acc { display: flex; gap: 16px; align-items: center; margin-top: 10px; color: #ccc; }
.thp-acc .ico { width: 19px; height: 19px; }
.thp-num { margin-left: auto; color: #777; font-size: 11.5px; }
.thp-aviso { display: flex; gap: 6px; align-items: center; margin: 4px 12px 0 58px; color: #777; font-size: 11.5px; }
.thp-aviso .ico { width: 13px; height: 13px; }
.thp-fantasma { display: flex; gap: 10px; padding: 16px 12px; border-top: 1px solid #262626; margin-top: 12px; }
.thp-barrita { height: 9px; border-radius: 6px; background: #222; margin-bottom: 7px; }
.thp-dock { position: absolute; left: 0; right: 0; bottom: 0; height: 50px; display: flex; justify-content: space-around; align-items: center; background: rgba(16, 16, 16, .95); border-top: 1px solid #222; color: #777; }
.thp-dock .ico { width: 22px; height: 22px; }
.thp-dock .ico:first-child { color: #fff; }

/* Feed de hilos */
.th-feed-wrap { max-width: 760px; margin: 0 auto; }
.th-feed { display: flex; flex-direction: column; max-width: 760px; margin: 0 auto; width: 100%; border-radius: 20px; border: 1px solid var(--borde); background: var(--panel); overflow: hidden; }
.th-post { display: flex; gap: 12px; padding: 16px 18px; border-bottom: 1px solid var(--borde); animation: aparecer .4s ease both; transition: background var(--transicion); }
.th-post:last-child { border-bottom: 0; }
.th-post:hover { background: var(--panel-2); }
.th-post-av { width: 40px; height: 40px; border-radius: 50%; overflow: hidden; flex: none; background: var(--panel-3); display: grid; place-items: center; font-weight: 800; font-size: 13px; border: 1px solid var(--borde-fuerte); }
.th-post-av img { width: 100%; height: 100%; object-fit: cover; }
.th-post-cab { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.th-tema { display: inline-flex; align-items: center; color: var(--apagado); font-weight: 600; font-size: 13px; }
.th-tema .ico { width: 13px; height: 13px; }
.th-post-txt { margin-top: 3px; white-space: pre-wrap; word-break: break-word; line-height: 1.45; }
.th-medio { position: relative; margin-top: 10px; border-radius: 14px; overflow: hidden; border: 1px solid var(--borde); max-width: 420px; }
.th-medio img { width: 100%; max-height: 380px; object-fit: cover; display: block; }
.th-play { position: absolute; left: 12px; top: 12px; width: 32px; height: 32px; border-radius: 50%; background: rgba(0, 0, 0, .6); display: grid; place-items: center; color: #fff; }
.th-play .ico { width: 14px; height: 14px; }
.th-medios-carr { display: flex; gap: 6px; overflow-x: auto; margin-top: 10px; }
.th-medios-carr img { width: 160px; height: 210px; border-radius: 12px; object-fit: cover; flex: none; border: 1px solid var(--borde); }
.th-enlace-adj { margin-top: 8px; display: inline-flex; gap: 6px; align-items: center; padding: 7px 11px; border-radius: 10px; border: 1px solid var(--borde); font-size: 12.5px; color: var(--apagado); }
.th-metricas { display: flex; gap: 16px; flex-wrap: wrap; margin-top: 12px; font-size: 12.5px; font-weight: 700; color: var(--texto-2); }
.th-metricas span { display: inline-flex; gap: 5px; align-items: center; }
.th-metricas .ico { width: 16px; height: 16px; color: var(--apagado); }

/* Respuestas */
.th-respuestas { display: grid; grid-template-columns: 320px minmax(0, 1fr); gap: 18px; align-items: start; }
.th-lista { position: sticky; top: 8px; max-height: calc(100vh - 360px); min-height: 280px; overflow-y: auto; }
.th-item { display: flex; gap: 10px; align-items: center; padding: 9px; border-radius: 12px; cursor: pointer; }
.th-item:hover { background: var(--panel-2); }
.th-item.activo { background: var(--panel-3); box-shadow: inset 0 0 0 1px var(--borde-fuerte); }
.th-item img, .th-item-txt { width: 42px; height: 42px; border-radius: 10px; object-fit: cover; flex: none; background: var(--panel-3); display: grid; place-items: center; }
.th-original { display: flex; gap: 10px; align-items: flex-start; padding: 14px; border-radius: 14px; background: var(--panel-2); border-left: 3px solid var(--texto); font-weight: 600; }
.th-resp { display: flex; gap: 10px; padding: 10px 4px; border-bottom: 1px solid var(--borde); animation: aparecer .3s ease; }
.th-resp.oculta { opacity: .55; }
.th-resp.mia .th-resp-av { background: var(--texto); color: var(--fondo); }
.th-resp-av { width: 32px; height: 32px; border-radius: 50%; display: grid; place-items: center; background: var(--panel-3); font-size: 11px; font-weight: 800; flex: none; border: 1px solid var(--borde-fuerte); }
.th-resp-txt { white-space: pre-wrap; word-break: break-word; margin-top: 2px; }
.th-resp-img { max-width: 220px; border-radius: 10px; margin-top: 6px; display: block; }
.th-resp-acc { display: flex; gap: 14px; flex-wrap: wrap; margin-top: 6px; }
.th-resp-acc button { border: 0; background: none; padding: 0; display: inline-flex; gap: 4px; align-items: center; font-weight: 700; font-size: 12.5px; color: var(--apagado); }
.th-resp-acc button:hover { color: var(--texto); }
.th-resp-acc button.peligro:hover { color: var(--peligro); }
.th-resp-acc .ico { width: 15px; height: 15px; }
.th-caja { display: flex; flex-direction: column; gap: 8px; margin-top: 8px; padding: 10px; border-radius: 14px; background: var(--panel); border: 1px solid var(--borde); }

/* Buscar */
.th-buscador { display: flex; align-items: center; gap: 12px; padding: 10px 12px 10px 18px; border-radius: 22px; background: var(--panel); border: 1px solid var(--borde-fuerte); }
.th-buscador > .ico { width: 20px; height: 20px; color: var(--apagado); }
.th-buscador input { flex: 1; border: 0; outline: none; background: transparent; font-size: 16px; min-width: 120px; }

/* Resumen */
.th-ultimos { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; margin-top: 14px; }
.th-mini { position: relative; display: flex; flex-direction: column; gap: 8px; padding: 14px; border-radius: 16px; background: var(--panel-2); border: 1px solid var(--borde); cursor: pointer; transition: transform var(--transicion), border-color var(--transicion); overflow: hidden; }
.th-mini:hover { transform: translateY(-2px); border-color: var(--borde-fuerte); }
.th-mini-txt { display: -webkit-box; -webkit-line-clamp: 4; -webkit-box-orient: vertical; overflow: hidden; white-space: pre-wrap; font-size: 13px; }
.th-mini img { width: 100%; height: 110px; object-fit: cover; border-radius: 10px; }
.th-mini-met { display: flex; gap: 10px; align-items: center; font-size: 12px; font-weight: 700; margin-top: auto; }
.th-mini-met span { display: inline-flex; gap: 3px; align-items: center; }
.th-mini-met .ico { width: 13px; height: 13px; }
.th-rapidas { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin-top: 12px; }
.th-rapida { display: flex; flex-direction: column; align-items: center; gap: 6px; padding: 12px 6px; border-radius: 14px; background: var(--panel-2); border: 1px solid var(--borde); color: var(--texto); text-decoration: none; font-weight: 700; font-size: 12.5px; transition: all var(--transicion); }
.th-rapida span { width: 38px; height: 38px; border-radius: 50%; display: grid; place-items: center; background: var(--texto); color: var(--fondo); transition: transform var(--rebote); }
.th-rapida:hover { border-color: var(--borde-fuerte); transform: translateY(-2px); }
.th-rapida:hover span { transform: scale(1.12) rotate(8deg); }
.th-puesto { width: 26px; height: 26px; border-radius: 50%; display: grid; place-items: center; font-weight: 800; font-size: 12px; background: var(--texto); color: var(--fondo); }

@media (max-width: 1250px) {
  .th-respuestas { grid-template-columns: 1fr; }
  .th-lista { position: static; max-height: 260px; }
  .th-ultimos { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
