/* Text tools */
.tx-layout { display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr); gap: 16px; align-items: start; }
.tx-layout textarea { width: 100%; resize: vertical; min-height: 260px; line-height: 1.6; }
.tx-side { display: flex; flex-direction: column; gap: 12px; }
.tx-stats { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; }
.tx-stats div { display: flex; flex-direction: column; padding: 8px 10px; border-radius: var(--radius-sm); background: var(--bg); }
.tx-stats b { font-size: 1.4rem; font-variant-numeric: tabular-nums; }
.tx-stats span { font-size: .78rem; color: var(--muted); }
.tx-stats div:first-child { background: var(--accent-soft); }
.tx-stats div:first-child b { color: var(--accent); }
.tx-limits { display: flex; flex-direction: column; gap: 10px; font-size: .85rem; }
.tx-bar { height: 6px; border-radius: 3px; background: var(--line); overflow: hidden; margin-top: 4px; }
.tx-bar i { display: block; height: 100%; background: var(--ok); }
.tx-limit.over { color: var(--bad); }
.tx-limit.over .tx-bar i { background: var(--bad); }
.tx-msg { position: fixed; left: 50%; bottom: 18px; transform: translateX(-50%); z-index: 50; margin: 0; padding: 10px 16px;
  border-radius: 999px; background: var(--text); color: var(--surface); box-shadow: 0 6px 20px rgb(0 0 0 / .25); }
.tx-sym-bar { position: sticky; top: 64px; z-index: 5; background: var(--surface); padding: 8px 0; border-bottom: 1px solid var(--line); }
.tx-sym-bar input { flex: 1; min-width: 160px; font-size: 1.2rem; }
.tx-group h2 { font-size: 1rem; margin: 18px 0 8px; }
.tx-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(48px, 1fr)); gap: 6px; }
.tx-grid button { aspect-ratio: 1; font-size: 1.5rem; border: 1px solid var(--line); border-radius: var(--radius-sm);
  background: var(--surface); color: var(--text); cursor: pointer; }
.tx-grid button:hover { border-color: var(--accent); background: var(--accent-soft); }
@media (max-width: 820px) { .tx-layout { grid-template-columns: minmax(0, 1fr); } }
