:root {
  --bg: #07070a;
  --bg2: #0e0e13;
  --card: #13131a;
  --card2: #191922;
  --line: rgba(244, 242, 238, 0.08);
  --line2: rgba(244, 242, 238, 0.16);
  --fg: #f4f2ee;
  --muted: #8b8a93;
  --lima: #c8ff5a;
  --violeta: #9d86ff;
  --naranja: #ff6b4a;
  --ease: cubic-bezier(0.16, 1, 0.3, 1);
  --sans: "Inter Tight", system-ui, -apple-system, sans-serif;
  --serif: "Instrument Serif", Georgia, serif;
  --mono: "JetBrains Mono", ui-monospace, monospace;
  color-scheme: dark;
}
* { box-sizing: border-box; }
html, body { margin: 0; background: var(--bg); color: var(--fg); font-family: var(--sans); font-size: 15px; letter-spacing: -0.01em; -webkit-font-smoothing: antialiased; }
body { min-height: 100dvh; background: radial-gradient(ellipse 80% 40% at 50% -10%, rgba(200, 255, 90, 0.06), transparent 70%), var(--bg); }
button { font: inherit; color: inherit; background: none; border: 0; cursor: pointer; padding: 0; -webkit-tap-highlight-color: transparent; }
input, textarea { font: inherit; color: inherit; }
svg { display: block; }
.mono { font-family: var(--mono); font-size: 10.5px; letter-spacing: 0.08em; text-transform: uppercase; }
em { font-family: var(--serif); font-style: italic; font-weight: 400; letter-spacing: 0; }

/* ---------- Cabecera ---------- */
.cab { position: sticky; top: 0; z-index: 20; background: rgba(7, 7, 10, 0.82); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); border-bottom: 1px solid var(--line); padding: 12px 20px 10px; padding-top: max(12px, env(safe-area-inset-top)); }
.cab-fila { display: flex; align-items: center; gap: 14px; }
.marca { font-weight: 700; font-size: 22px; letter-spacing: -0.04em; display: flex; align-items: center; gap: 8px; }
.marca b { color: var(--lima); font-weight: 700; }
.marca img { width: 26px; height: 26px; }
.semana { display: flex; align-items: center; gap: 4px; margin-left: auto; }
.semana h1 { font-size: 15px; font-weight: 600; margin: 0 6px; min-width: 104px; text-align: center; white-space: nowrap; }
.btn-ico { width: 34px; height: 34px; border-radius: 11px; display: grid; place-items: center; border: 1px solid var(--line); background: var(--bg2); transition: border-color 0.2s, transform 0.2s var(--ease); }
.btn-ico:hover { border-color: var(--line2); }
.btn-ico:active { transform: scale(0.94); }
.btn-hoy { height: 34px; padding: 0 12px; border-radius: 11px; border: 1px solid var(--line); background: var(--bg2); font-size: 13px; font-weight: 600; }
.btn-hoy[disabled] { opacity: 0.4; cursor: default; }
.resumen { display: flex; gap: 6px; flex-wrap: wrap; }
.pild { display: inline-flex; align-items: center; gap: 6px; height: 26px; padding: 0 10px; border-radius: 99px; background: var(--bg2); border: 1px solid var(--line); font-size: 12.5px; font-weight: 500; color: var(--muted); white-space: nowrap; }
.pild b { color: var(--fg); font-weight: 600; }
.pild i { width: 7px; height: 7px; border-radius: 50%; background: var(--c); }
.filtros { display: flex; gap: 6px; margin-top: 10px; overflow-x: auto; scrollbar-width: none; margin-inline: -20px; padding-inline: 20px; }
.filtros::-webkit-scrollbar { display: none; }
.chip { flex: none; display: inline-flex; align-items: center; gap: 7px; height: 32px; padding: 0 12px 0 6px; border-radius: 99px; border: 1px solid var(--line); background: var(--bg2); font-size: 13px; font-weight: 500; color: var(--muted); transition: all 0.25s var(--ease); }
.chip.todo { padding-left: 12px; }
.chip[aria-pressed="true"] { color: var(--fg); border-color: color-mix(in srgb, var(--c, var(--lima)) 60%, transparent); background: color-mix(in srgb, var(--c, var(--lima)) 12%, var(--bg2)); }
.chip small { font-family: var(--mono); font-size: 10px; opacity: 0.7; }
.logo { width: 20px; height: 20px; border-radius: 6px; object-fit: cover; flex: none; display: grid; place-items: center; font-size: 13px; background: var(--card2); }
.salir { font-size: 12px; color: var(--muted); }

/* ---------- Tablero (ordenador) ---------- */
main { padding: 14px 20px 120px; }
.tablero { position: relative; display: grid; grid-template-columns: 74px repeat(7, minmax(0, 1fr)); gap: 6px; }
.tablero > .ramas { position: absolute; inset: 0; width: 100%; height: 100%; pointer-events: none; z-index: 3; overflow: visible; }
.dia-cab { padding: 6px 8px 8px; border-radius: 14px; display: flex; align-items: baseline; gap: 6px; }
.dia-cab .mono { color: var(--muted); }
.dia-cab b { font-size: 18px; font-weight: 600; letter-spacing: -0.03em; }
.dia-cab.hoy { background: rgba(200, 255, 90, 0.08); }
.dia-cab.hoy b, .dia-cab.hoy .mono { color: var(--lima); }
.red-cab { display: flex; flex-direction: column; align-items: center; justify-content: flex-start; gap: 6px; padding-top: 14px; color: var(--muted); font-size: 11px; font-weight: 500; text-align: center; }
.red-cab svg { width: 22px; height: 22px; color: var(--fg); }
.celda { min-height: 110px; border-radius: 16px; background: rgba(255, 255, 255, 0.015); border: 1px solid var(--line); padding: 6px; display: flex; flex-direction: column; gap: 6px; transition: background 0.2s, border-color 0.2s; }
.celda.hoy { border-color: rgba(200, 255, 90, 0.18); }
.celda.pasado { opacity: 0.55; }
.celda.encima { background: rgba(200, 255, 90, 0.06); border-color: rgba(200, 255, 90, 0.45); border-style: dashed; }

/* ---------- Tarjeta ---------- */
.tarjeta { position: relative; z-index: 4; width: 100%; text-align: left; display: grid; grid-template-columns: 38px 1fr; gap: 8px; padding: 6px; border-radius: 13px; background: var(--card); border: 1px solid var(--line); transition: opacity 0.25s var(--ease), transform 0.25s var(--ease), border-color 0.25s, box-shadow 0.25s; }
.anima .tarjeta { animation: entra 0.5s var(--ease) both; }
.tarjeta:hover { border-color: var(--line2); }
.tarjeta:active { transform: scale(0.98); }
.tarjeta[draggable="true"] { cursor: grab; }
.tarjeta.arrastrando { opacity: 0.4; }
.mini { position: relative; width: 38px; aspect-ratio: 9 / 16; border-radius: 8px; overflow: hidden; background: var(--card2); box-shadow: 0 0 0 1.5px var(--c); }
.mini img { width: 100%; height: 100%; object-fit: cover; display: block; }
.mini .proy { position: absolute; left: 2px; bottom: 2px; width: 14px; height: 14px; border-radius: 4px; font-size: 9px; }
.tarjeta .meta { min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.tarjeta .fila1 { display: flex; align-items: center; gap: 6px; }
.tarjeta .hora { font-family: var(--mono); font-size: 11px; font-weight: 500; }
.tarjeta .est { margin-left: auto; color: var(--muted); }
.tarjeta .nom { font-size: 12.5px; font-weight: 600; line-height: 1.2; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.tarjeta .txt { font-size: 11.5px; line-height: 1.3; color: var(--muted); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.tarjeta .hermanas { display: flex; gap: 3px; margin-top: 2px; color: var(--muted); }
.tarjeta .hermanas svg { width: 11px; height: 11px; }
.tarjeta .punto-aviso { position: absolute; top: -3px; right: -3px; width: 10px; height: 10px; border-radius: 50%; background: var(--naranja); box-shadow: 0 0 0 3px var(--bg); }

.tarjeta[data-estado="borrador"] { border-style: dashed; border-color: var(--line2); }
.tarjeta[data-estado="aprobada"] { border-color: rgba(200, 255, 90, 0.5); box-shadow: 0 0 0 1px rgba(200, 255, 90, 0.08), 0 6px 22px -10px rgba(200, 255, 90, 0.35); }
.tarjeta[data-estado="aprobada"] .est { color: var(--lima); }
.tarjeta[data-estado="programada"] { border-color: rgba(157, 134, 255, 0.55); }
.tarjeta[data-estado="programada"] .est { color: var(--violeta); }
.tarjeta[data-estado="publicada"] { opacity: 0.6; }
.tarjeta[data-estado="descartada"] { display: none; }

.foco .tarjeta { opacity: 0.28; }
.foco .tarjeta.hermana { opacity: 1; border-color: color-mix(in srgb, var(--c) 70%, transparent); }
.ramas path { fill: none; stroke: var(--c); stroke-width: 1.5; opacity: 0.4; transition: opacity 0.25s, stroke-width 0.25s; stroke-linecap: round; }
.ramas circle { fill: var(--c); opacity: 0.6; }
.anima .ramas .rama { stroke-dasharray: var(--l); stroke-dashoffset: var(--l); animation: traza 0.9s 0.15s var(--ease) forwards; }
.foco .ramas g { opacity: 0.12; }
.foco .ramas g.activa { opacity: 1; }
.foco .ramas g.activa path { opacity: 0.95; stroke-width: 2; }
@keyframes traza { to { stroke-dashoffset: 0; } }
@keyframes entra { from { opacity: 0; transform: translateY(6px); } }

.sin-fecha { margin-bottom: 14px; border: 1px dashed var(--line2); border-radius: 18px; padding: 10px; }
.sin-fecha h2 { margin: 0 0 8px 4px; }
.sin-fecha .lista { display: grid; grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); gap: 6px; }
h2.mono { color: var(--muted); font-weight: 500; }

.vacio { text-align: center; padding: 60px 20px; color: var(--muted); max-width: 440px; margin: 0 auto; line-height: 1.5; }
.vacio b { display: block; color: var(--fg); font-size: 22px; font-weight: 600; letter-spacing: -0.03em; margin-bottom: 6px; }

.pie { margin-top: 18px; display: flex; flex-wrap: wrap; gap: 8px 18px; align-items: center; color: var(--muted); font-size: 12.5px; }
.leyenda { display: flex; align-items: center; gap: 6px; }
.leyenda svg { width: 14px; height: 14px; }
.orden { margin-left: auto; display: inline-flex; align-items: center; gap: 8px; height: 34px; padding: 0 14px; border-radius: 99px; background: rgba(200, 255, 90, 0.1); color: var(--lima); font-weight: 600; font-size: 13px; border: 1px solid rgba(200, 255, 90, 0.3); }

/* ---------- Móvil: un día cada vez ---------- */
.dias { display: grid; grid-template-columns: repeat(7, 1fr); gap: 4px; margin: 0 0 14px; }
.dia-tab { display: flex; flex-direction: column; align-items: center; gap: 3px; padding: 7px 0 8px; border-radius: 14px; border: 1px solid transparent; color: var(--muted); transition: all 0.25s var(--ease); }
.dia-tab b { font-size: 17px; font-weight: 600; color: var(--fg); letter-spacing: -0.03em; }
.dia-tab.hoy b, .dia-tab.hoy .mono { color: var(--lima); }
.dia-tab[aria-selected="true"] { background: var(--card); border-color: var(--line2); }
.dia-tab .puntos { display: flex; gap: 2px; height: 5px; }
.dia-tab .puntos i { width: 5px; height: 5px; border-radius: 50%; background: var(--c); }
.dia-movil { position: relative; }
.dia-movil > .ramas { position: absolute; inset: 0; width: 100%; height: 100%; pointer-events: none; z-index: 3; overflow: visible; }
.bloque-red { margin-bottom: 16px; padding-left: 20px; }
.dia-movil .ramas path { opacity: 0.65; stroke-width: 2; }
.bloque-red h2 { display: flex; align-items: center; gap: 8px; margin: 0 0 8px -20px; font-size: 13px; font-weight: 600; letter-spacing: -0.01em; }
.bloque-red h2 svg { width: 18px; height: 18px; }
.bloque-red h2 small { color: var(--muted); font-weight: 500; }
.bloque-red .lista { display: flex; flex-direction: column; gap: 8px; }
.bloque-red .nada { color: var(--muted); font-size: 13px; padding: 12px 0 4px; }
.movil .tarjeta { grid-template-columns: 54px 1fr; gap: 12px; padding: 8px; border-radius: 16px; }
.movil .mini { width: 54px; border-radius: 10px; }
.movil .mini .proy { width: 18px; height: 18px; font-size: 11px; }
.movil .tarjeta .hora { font-size: 12.5px; }
.movil .tarjeta .nom { font-size: 14.5px; }
.movil .tarjeta .txt { font-size: 13px; }

/* ---------- Ficha de una pieza ---------- */
dialog#ficha { padding: 0; border: 0; color: var(--fg); background: var(--bg2); max-width: none; max-height: none; margin: 0 0 0 auto; width: min(480px, 100vw); height: 100dvh; border-left: 1px solid var(--line2); overflow: hidden; }
dialog#ficha[open] { display: flex; flex-direction: column; animation: panel 0.45s var(--ease); }
dialog#ficha::backdrop { background: rgba(0, 0, 0, 0.55); backdrop-filter: blur(3px); }
@keyframes panel { from { transform: translateX(40px); opacity: 0; } }
.f-cab { display: flex; align-items: center; gap: 10px; padding: 14px 16px; padding-top: max(14px, env(safe-area-inset-top)); border-bottom: 1px solid var(--line); }
.f-cab .logo { width: 30px; height: 30px; border-radius: 9px; font-size: 18px; }
.f-cab h2 { margin: 0; font-size: 17px; font-weight: 600; letter-spacing: -0.02em; line-height: 1.15; }
.f-cab .mono { color: var(--muted); }
.f-cab .btn-ico { margin-left: auto; }
.f-cuerpo { overflow-y: auto; padding: 16px 16px max(28px, env(safe-area-inset-bottom)); flex: 1; overscroll-behavior: contain; }
.f-media { display: flex; gap: 14px; align-items: flex-start; margin-bottom: 14px; }
.f-media video, .f-media img { width: 132px; aspect-ratio: 9 / 16; border-radius: 14px; background: #000; object-fit: cover; flex: none; box-shadow: 0 0 0 1.5px var(--c); }
.f-info { display: flex; flex-direction: column; gap: 8px; min-width: 0; font-size: 13px; color: var(--muted); line-height: 1.45; }
.f-info .archivo { font-family: var(--mono); font-size: 10.5px; word-break: break-all; }
.nota { background: var(--card); border: 1px solid var(--line); border-radius: 14px; padding: 10px 12px; color: var(--fg); }
.alerta { background: rgba(255, 107, 74, 0.1); border: 1px solid rgba(255, 107, 74, 0.35); color: #ffb3a1; border-radius: 14px; padding: 10px 12px; font-size: 13px; line-height: 1.4; margin-bottom: 12px; }
.todas { width: 100%; height: 46px; border-radius: 14px; background: var(--lima); color: #0b0d06; font-weight: 700; font-size: 15px; display: flex; align-items: center; justify-content: center; gap: 8px; margin-bottom: 14px; transition: transform 0.2s var(--ease), opacity 0.2s; }
.todas:active { transform: scale(0.98); }
.todas svg { width: 18px; height: 18px; }
.salida { border: 1px solid var(--line); border-radius: 20px; background: var(--card); padding: 12px; margin-bottom: 10px; transition: border-color 0.35s, box-shadow 0.35s; }
.salida.elegida { box-shadow: 0 0 0 1.5px color-mix(in srgb, var(--c) 65%, transparent); }
.hora-sel { display: flex; align-items: center; gap: 4px; }
.hora-sel b { color: var(--muted); font-weight: 600; }
.hora-sel select { flex: 1; min-width: 0; appearance: none; -webkit-appearance: none; background: var(--bg2); border: 1px solid var(--line); border-radius: 11px; padding: 9px 6px; font: 500 15px var(--mono); color: var(--fg); text-align: center; text-align-last: center; outline: none; }
.hora-sel select:focus { border-color: rgba(200, 255, 90, 0.5); }
.hora-sel select:disabled { opacity: 0.75; }
.pild.zona { margin-left: auto; color: var(--muted); }
.salida[data-estado="aprobada"] { border-color: rgba(200, 255, 90, 0.45); }
.salida[data-estado="programada"] { border-color: rgba(157, 134, 255, 0.5); }
.s-cab { display: flex; align-items: center; gap: 8px; margin-bottom: 10px; }
.s-cab svg.red { width: 20px; height: 20px; }
.s-cab b { font-size: 14px; font-weight: 600; }
.s-cab .cuenta { font-size: 12px; color: var(--muted); }
.s-cab .cuenta.falta { color: #ffb3a1; }
.estado-pill { margin-left: auto; display: inline-flex; align-items: center; gap: 5px; height: 24px; padding: 0 9px; border-radius: 99px; background: var(--bg2); border: 1px solid var(--line); font-size: 11.5px; font-weight: 600; color: var(--muted); }
.estado-pill svg { width: 13px; height: 13px; }
.estado-pill[data-e="aprobada"] { color: var(--lima); border-color: rgba(200, 255, 90, 0.35); }
.estado-pill[data-e="programada"] { color: var(--violeta); border-color: rgba(157, 134, 255, 0.4); }
.campos { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.campo { display: flex; flex-direction: column; gap: 4px; }
.campo.ancho { grid-column: 1 / -1; }
.campo label { display: flex; justify-content: space-between; color: var(--muted); }
.campo label .cuenta-c.pasa { color: var(--naranja); }
.campo input, .campo textarea { width: 100%; background: var(--bg2); border: 1px solid var(--line); border-radius: 11px; padding: 9px 10px; font-size: 14px; line-height: 1.4; outline: none; transition: border-color 0.2s; resize: none; }
.campo textarea { min-height: 76px; field-sizing: content; }
.campo input:focus, .campo textarea:focus { border-color: rgba(200, 255, 90, 0.5); }
.campo input:disabled, .campo textarea:disabled { opacity: 0.75; color: var(--fg); -webkit-text-fill-color: var(--fg); }
.campo input::-webkit-calendar-picker-indicator { filter: invert(1); opacity: 0.6; }
.s-pie { display: flex; align-items: center; gap: 8px; margin-top: 10px; }
.candado { display: inline-flex; align-items: center; gap: 8px; height: 40px; padding: 0 16px 0 12px; border-radius: 12px; font-weight: 600; font-size: 14px; border: 1px solid var(--line2); background: var(--bg2); transition: all 0.3s var(--ease); }
.candado svg { width: 20px; height: 20px; }
.candado .arco { transition: transform 0.45s var(--ease); transform-origin: 16px 10px; }
.candado.abierto .arco { transform: translateY(-3px) rotate(-18deg); }
.candado.cerrar { background: var(--lima); color: #0b0d06; border-color: var(--lima); }
.candado.cerrar:hover { box-shadow: 0 6px 22px -8px rgba(200, 255, 90, 0.7); }
.candado.cerrar:active, .todas:active { transform: scale(0.97); }
.enlace { font-size: 12.5px; color: var(--muted); text-decoration: underline; text-underline-offset: 3px; }
.guardado { margin-left: auto; font-size: 11.5px; color: var(--muted); opacity: 0; transition: opacity 0.3s; }
.guardado.si { opacity: 1; }
.salida.recien { animation: sello 0.7s var(--ease); }
@keyframes sello { 30% { box-shadow: 0 0 0 4px rgba(200, 255, 90, 0.25), 0 0 40px -6px rgba(200, 255, 90, 0.6); } }

/* ---------- Entrar ---------- */
.entrar { min-height: 100dvh; display: grid; place-items: center; padding: 24px; }
.entrar form { width: min(380px, 100%); display: flex; flex-direction: column; gap: 12px; }
.entrar h1 { font-size: 44px; font-weight: 700; letter-spacing: -0.05em; margin: 0; }
.entrar h1 b { color: var(--lima); }
.entrar p { color: var(--muted); margin: 0 0 8px; line-height: 1.5; }
.entrar input { height: 52px; border-radius: 14px; border: 1px solid var(--line2); background: var(--bg2); padding: 0 16px; font-size: 17px; outline: none; }
.entrar input:focus { border-color: rgba(200, 255, 90, 0.6); }
.entrar input.codigo { font-family: var(--mono); letter-spacing: 0.4em; text-align: center; font-size: 22px; }
.entrar button { height: 52px; border-radius: 14px; background: var(--lima); color: #0b0d06; font-weight: 700; font-size: 16px; }
.entrar .error { color: #ffb3a1; font-size: 14px; min-height: 20px; }
.entrar .otra { background: none; color: var(--muted); height: auto; font-weight: 500; font-size: 14px; }

#aviso { position: fixed; left: 50%; bottom: max(20px, env(safe-area-inset-bottom)); transform: translate(-50%, 20px); opacity: 0; z-index: 60; background: var(--fg); color: var(--bg); padding: 10px 16px; border-radius: 12px; font-weight: 600; font-size: 14px; pointer-events: none; transition: all 0.35s var(--ease); max-width: calc(100vw - 32px); text-align: center; }
#aviso.si { opacity: 1; transform: translate(-50%, 0); }
#aviso.mal { background: var(--naranja); color: #fff; }

@media (max-width: 860px) {
  .cab { padding: 10px 16px 8px; padding-top: max(10px, env(safe-area-inset-top)); }
  .filtros { margin-inline: -16px; padding-inline: 16px; }
  main { padding: 12px 16px 100px; }
  .semana h1 { min-width: 0; font-size: 14px; }
  .resumen-cab { display: none; }
  .marca span { display: none; }
  .resumen { margin-top: 2px; }
  .pie .orden { margin-left: 0; }
  dialog#ficha { width: 100vw; border-left: 0; }
  @keyframes panel { from { transform: translateY(30px); opacity: 0; } }
  .f-media video, .f-media img { width: 118px; }
  .campo input, .campo textarea, .hora-sel select { font-size: 16px; }
  .pild.zona { margin-left: 0; }
}
/* ---------- Filtro por red y botón de proyectos ---------- */
.btn-proy { display: inline-flex; align-items: center; gap: 7px; height: 34px; padding: 0 12px; border-radius: 11px; border: 1px solid var(--line); background: var(--bg2); font-size: 13px; font-weight: 600; transition: border-color 0.2s, transform 0.2s var(--ease); }
.btn-proy:hover { border-color: var(--line2); }
.btn-proy:active { transform: scale(0.96); }
.filtro-red { display: grid; grid-template-columns: 0.8fr 1fr 1fr 1fr; gap: 3px; margin-top: 8px; padding: 3px; border-radius: 14px; background: var(--bg2); border: 1px solid var(--line); max-width: 520px; }
.filtro-red button { height: 32px; border-radius: 11px; display: inline-flex; align-items: center; justify-content: center; gap: 6px; font-size: 13px; font-weight: 600; color: var(--muted); transition: background 0.25s var(--ease), color 0.25s; }
.filtro-red button svg { width: 15px; height: 15px; }
.filtro-red button[aria-pressed="true"] { background: var(--card2); color: var(--fg); box-shadow: 0 0 0 1px var(--line2); }
@media (max-width: 400px) { .filtro-red button span { display: none; } .filtro-red button svg { width: 18px; height: 18px; } }

.btn-proy { position: relative; }
.btn-proy .num { position: absolute; top: -5px; right: -5px; min-width: 17px; height: 17px; padding: 0 4px; border-radius: 99px; background: var(--lima); color: #0b0d06; font: 700 10.5px/17px var(--sans); font-style: normal; text-align: center; }
.desde { margin: 0; display: flex; align-items: center; gap: 8px; font-size: 13.5px; color: var(--muted); padding: 10px; border-radius: 14px; background: rgba(0, 0, 0, 0.25); border: 1px solid var(--line); }
.desde b { color: var(--fg); font-weight: 600; }
.select { width: 100%; appearance: none; -webkit-appearance: none; background: var(--bg2); border: 1px solid var(--line); border-radius: 11px; padding: 10px 12px; font: 500 15px var(--sans); color: var(--fg); }
.propias[hidden] { display: none; }
.ideas { max-width: 680px; margin: 0 auto; }
.nueva-idea { display: flex; flex-direction: column; gap: 10px; margin-bottom: 18px; }
.nueva-idea textarea { width: 100%; background: var(--bg2); border: 1px solid var(--line2); border-radius: 16px; padding: 14px; font-size: 16px; line-height: 1.45; resize: none; outline: none; field-sizing: content; min-height: 84px; }
.nueva-idea textarea:focus { border-color: rgba(200, 255, 90, 0.5); }
.nueva-idea .filtros { margin: 0 -20px; }
.nueva-idea .todas { margin: 0; }
.lista-ideas { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 8px; }
.idea { display: flex; align-items: flex-start; gap: 12px; padding: 12px; border-radius: 16px; background: var(--card); border: 1px solid var(--line); border-left: 3px solid var(--c); animation: entra 0.4s var(--ease) both; }
.idea > div { flex: 1; min-width: 0; }
.idea p { margin: 0 0 4px; font-size: 15px; line-height: 1.4; white-space: pre-wrap; word-wrap: break-word; }
.idea .mono { color: var(--muted); }
.idea .check { flex: none; width: 24px; height: 24px; border-radius: 8px; border: 1.5px solid var(--line2); display: grid; place-items: center; color: #0b0d06; margin-top: 1px; }
.idea.hecha { opacity: 0.55; }
.idea.hecha p { text-decoration: line-through; }
.idea.hecha .check { background: var(--lima); border-color: var(--lima); }
.idea .borrar { flex: none; color: var(--muted); padding: 4px; }
/* ---------- Pantalla Proyectos ---------- */
.tit { font-size: 18px; font-weight: 600; letter-spacing: -0.02em; margin: 0; }
.btn-nuevo { margin-left: auto; display: inline-flex; align-items: center; gap: 6px; height: 36px; padding: 0 14px; border-radius: 12px; background: var(--lima); color: #0b0d06; font-weight: 700; font-size: 14px; transition: transform 0.2s var(--ease); }
.btn-nuevo:active { transform: scale(0.96); }
.proyectos { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 12px; }
.proyectos.ocultos { opacity: 0.6; }
.ficha-proy { border: 1px solid var(--line); border-radius: 22px; background: linear-gradient(160deg, color-mix(in srgb, var(--c) 9%, var(--card)), var(--card) 55%); padding: 14px; display: flex; flex-direction: column; gap: 10px; animation: entra 0.5s var(--ease) both; }
.proy-cab { display: flex; align-items: center; gap: 12px; text-align: left; width: 100%; }
.proy-cab > span:nth-child(2) { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.proy-cab b { font-size: 18px; font-weight: 600; letter-spacing: -0.03em; }
.proy-cab .mono { color: var(--muted); }
.proy-cab .editar { margin-left: auto; font-size: 12.5px; color: var(--muted); border: 1px solid var(--line); border-radius: 99px; padding: 5px 11px; }
.logo.grande { width: 46px; height: 46px; border-radius: 13px; font-size: 26px; box-shadow: 0 0 0 1.5px color-mix(in srgb, var(--c) 50%, transparent); }
.ficha-proy .desc { margin: 0; color: var(--muted); font-size: 13.5px; line-height: 1.45; }
.cuentas { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 6px; }
.cuentas li { display: flex; align-items: center; gap: 10px; padding: 8px 8px 8px 10px; border-radius: 14px; background: rgba(0, 0, 0, 0.25); border: 1px solid var(--line); }
.cuentas li > svg { width: 17px; height: 17px; flex: none; }
.cuentas .quien { display: flex; flex-direction: column; min-width: 0; flex: 1; font-size: 13.5px; }
.cuentas .quien b { font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cuentas .quien small { color: var(--muted); font-size: 11.5px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cuentas .falta { color: var(--muted); }
.mini-btn { flex: none; height: 30px; padding: 0 11px; border-radius: 10px; border: 1px solid var(--line2); background: var(--bg2); color: var(--fg); font-size: 12.5px; font-weight: 600; text-decoration: none; display: inline-flex; align-items: center; transition: transform 0.2s var(--ease), border-color 0.2s; }
.mini-btn:active { transform: scale(0.95); }
.aviso-claves { color: var(--muted); font-size: 12.5px; line-height: 1.5; margin: 18px 0 0; display: flex; gap: 8px; align-items: flex-start; }
.aviso-claves svg { flex: none; margin-top: 2px; color: var(--lima); }
.aviso-claves b { color: var(--fg); }
.fila-logo { display: flex; gap: 8px; }
.fila-logo input[name="emoji"] { width: 120px; flex: none; text-align: center; }
.campo label.subir, .subir { flex: 1; display: inline-flex; align-items: center; justify-content: center; color: var(--fg); gap: 6px; height: 42px; border-radius: 11px; border: 1px dashed var(--line2); background: var(--bg2); font-size: 14px; font-weight: 600; cursor: pointer; }
.colores { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.color { width: 30px; height: 30px; border-radius: 50%; background: var(--c); box-shadow: inset 0 0 0 1px rgba(0, 0, 0, 0.3); transition: transform 0.2s var(--ease), box-shadow 0.2s; }
.color.si { box-shadow: 0 0 0 2px var(--bg2), 0 0 0 4px var(--c); transform: scale(1.05); }
.colores input[type="color"] { width: 38px; height: 30px; padding: 0; border: 1px solid var(--line2); border-radius: 9px; background: none; }
.cuenta-red { margin-top: 12px; }
#f-proy .enlace { display: block; margin: 0 auto; }
.ayuda p { margin: 0; color: var(--muted); font-size: 14px; line-height: 1.5; }
.ayuda .ico-e { width: 28px; height: 28px; border-radius: 9px; display: grid; place-items: center; color: var(--e); background: color-mix(in srgb, var(--e) 14%, transparent); }
.ayuda .ico-e svg { width: 16px; height: 16px; }

@media (max-width: 860px) {
  .btn-proy span { display: none; }
  .btn-proy { width: 34px; padding: 0; justify-content: center; }
  .cab-fila { gap: 8px; }
  .nueva-idea .filtros { margin: 0 -16px; }
  .proyectos { grid-template-columns: 1fr; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 0.01ms !important; animation-delay: 0ms !important; transition-duration: 0.01ms !important; }
  .anima .ramas .rama { stroke-dashoffset: 0; }
}
