/* Line Counter — локальные стили */
.lc-cards { display: grid; grid-template-columns: 1.4fr repeat(4, minmax(0, 1fr)); gap: 10px; padding: 16px 16px 0; }
.lc-card { border: 1px solid var(--border); border-radius: var(--r-ctl); padding: 10px 12px; background: var(--canvas); min-width: 0; }
.lc-card b { display: block; font-size: 24px; font-weight: 700; line-height: 1.2; font-variant-numeric: tabular-nums; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.lc-card span { display: block; font-size: 13px; color: var(--muted); }
.lc-card.lc-total { background: var(--blue-tint); border-color: transparent; }
.lc-card.lc-total b { font-size: 32px; color: var(--blue); }
.lc-pane { padding-bottom: 10px; }
.lc-editor { position: relative; display: flex; border: 1px solid var(--border); border-radius: var(--r-ctl); background: var(--code-bg); overflow: hidden; min-height: 320px; }
.lc-editor:focus-within { border-color: var(--blue); box-shadow: var(--focus); }
.lc-gutter { position: relative; flex: none; width: 4.5ch; overflow: hidden; border-right: 1px solid var(--border); background: var(--canvas); font: 400 14px/1.6 var(--mono); color: var(--muted); text-align: right; user-select: none; }
.lc-gutter-inner { position: absolute; inset: 0; }
.lc-gutter-inner span { position: absolute; right: 8px; font-variant-numeric: tabular-nums; }
.lc-gutter-inner span.hl { color: var(--blue); font-weight: 700; }
.lc-editor .lc-input { border: 0; border-radius: 0; box-shadow: none; min-height: 320px; height: 360px; resize: vertical; background: transparent; max-width: none; }
.lc-editor .lc-input:focus { box-shadow: none; }
.lc-editor .lc-input.wrap { white-space: pre-wrap; overflow-wrap: anywhere; }
.lc-editor .lc-input[readonly] { background: var(--canvas); }
.lc-editor.no-gutter .lc-gutter { display: none; }
.lc-mirror { position: absolute; visibility: hidden; left: -10000px; top: 0; font: 400 14px/1.6 var(--mono); white-space: pre-wrap; overflow-wrap: anywhere; tab-size: 4; }
.lc-mirror div { min-height: 1.6em; }
.lc-file { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px; padding: 8px 12px; margin-bottom: 8px; border-radius: var(--r-ctl); background: var(--blue-tint); }
.lc-file[hidden] { display: none; }
.lc-file-actions { display: inline-flex; gap: 6px; flex-wrap: wrap; }
.lc-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 10px; margin-top: 10px; }
.lc-quick { display: inline-flex; flex-wrap: wrap; gap: 4px 14px; margin-left: auto; }
.lc-quick[hidden] { display: none; }
.lc-link { font: inherit; color: var(--blue); background: none; border: 0; padding: 4px 0; cursor: pointer; }
.lc-link:hover { color: var(--blue-hover); text-decoration: underline; }
.stats .lc-link { padding: 0; font-weight: 600; }
.lc-options { border-top: 1px solid var(--border); }
.lc-options > summary { display: none; }
.lc-options .options { border-top: 0; }
.lc-tip { display: inline-grid; place-items: center; width: 18px; height: 18px; border-radius: 50%; border: 1px solid var(--border); font-size: 12px; font-weight: 600; color: var(--muted); position: relative; cursor: help; }
.lc-tip:hover::after, .lc-tip:focus::after { content: attr(data-tip); position: absolute; left: 50%; bottom: calc(100% + 6px); transform: translateX(-50%); width: 260px; padding: 8px 10px; background: var(--ink); color: var(--surface); border-radius: 8px; font-weight: 400; font-size: 13px; line-height: 1.4; z-index: 5; text-align: left; }
@media (max-width: 900px) { .lc-cards { grid-template-columns: repeat(3, minmax(0, 1fr)); } .lc-card.lc-total { grid-column: 1 / -1; } }
@media (max-width: 768px) {
  .lc-cards { grid-template-columns: repeat(2, minmax(0, 1fr)); padding: 12px 12px 0; gap: 8px; }
  .lc-card { padding: 8px 10px; }
  .lc-card b { font-size: 20px; }
  .lc-card.lc-total b { font-size: 28px; }
  .lc-options { padding: 0; }
  .lc-options > summary { display: flex; align-items: center; justify-content: space-between; cursor: pointer; padding: 12px; font-weight: 600; list-style: none; min-height: 44px; }
  .lc-options > summary::-webkit-details-marker { display: none; }
  .lc-options > summary::after { content: "+"; color: var(--muted); font-weight: 400; }
  .lc-options[open] > summary::after { content: "−"; }
  .lc-options .options { padding-top: 0; }
  .lc-editor, .lc-editor .lc-input { min-height: 220px; height: 260px; }
  .lc-quick { margin-left: 0; }
  .lc-tip:hover::after, .lc-tip:focus::after { left: auto; right: -8px; transform: none; width: 220px; }
}
@media (max-width: 399px) { .lc-gutter { display: none; } }
