/* Калькулятор «Бухгалтерия» (components/calc/AccountingCalc.tsx).
   Строгий монохром: белая бумага, графит, прямые углы, без теней;
   итог печатается чековой лентой. Всё заперто под .acc. */

.acc {
  --acc-ink: #1b1b22; --acc-mute: #6d6d76; --acc-line: #d9d9de; --acc-paper: #fff; --acc-bg: #f2f2f0;
  display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr); gap: 0;
  min-height: 560px; background: var(--acc-bg); color: var(--acc-ink);
  font-family: var(--font-onest, system-ui, sans-serif);
}
.acc-form { padding: 36px 32px; background: var(--acc-paper); border-right: 1px solid var(--acc-line); }
.acc-h { font-size: 1.45rem; font-weight: 600; letter-spacing: -.01em; margin-bottom: 26px; }
.acc-field { margin-bottom: 20px; }
.acc-field > span { display: block; font-size: .8rem; color: var(--acc-mute); margin-bottom: 8px; }
.acc-seg { display: flex; border: 1px solid var(--acc-ink); }
.acc-seg button {
  flex: 1; padding: 11px 6px; background: none; border: 0; border-left: 1px solid var(--acc-ink);
  font-weight: 500; font-size: .9rem; line-height: 1; font-family: inherit; color: var(--acc-ink); cursor: pointer;
  transition: background .15s, color .15s;
}
.acc-seg button:first-child { border-left: 0; }
.acc-seg button:hover { background: #ececee; }
.acc-seg button[aria-checked="true"] { background: var(--acc-ink); color: #fff; }
.acc-check { display: flex; gap: 10px; align-items: center; font-size: .88rem; margin: -4px 0 20px; cursor: pointer; }
.acc-check input { width: 16px; height: 16px; accent-color: var(--acc-ink); }

.acc-tape-wrap { padding: 36px 28px; display: flex; flex-direction: column; gap: 18px; }
.acc-tape {
  position: relative; background: var(--acc-paper); padding: 22px 20px 26px;
  font-family: ui-monospace, 'Cascadia Mono', Consolas, monospace; font-size: .84rem;
  /* зубчатый отрыв ленты снизу */
  -webkit-mask: linear-gradient(#000 0 0) top / 100% calc(100% - 8px) no-repeat,
    conic-gradient(from -45deg at bottom, #0000, #000 1deg 89deg, #0000 90deg) bottom / 16px 8px repeat-x;
  mask: linear-gradient(#000 0 0) top / 100% calc(100% - 8px) no-repeat,
    conic-gradient(from -45deg at bottom, #0000, #000 1deg 89deg, #0000 90deg) bottom / 16px 8px repeat-x;
}
.acc-tape-head { display: flex; justify-content: space-between; letter-spacing: .12em; font-size: .72rem; color: var(--acc-mute); padding-bottom: 12px; border-bottom: 1px dashed var(--acc-line); margin-bottom: 12px; }
.acc-tape-line, .acc-tape-total { display: flex; align-items: baseline; gap: 8px; padding: 5px 0; animation: acc-print .35s calc(var(--i) * .12s) both; }
.acc-tape-line i { flex: 1; border-bottom: 1px dotted var(--acc-line); }
.acc-tape-line b { font-weight: 500; font-variant-numeric: tabular-nums; }
.acc-tape-total { justify-content: space-between; margin-top: 10px; padding-top: 12px; border-top: 1px solid var(--acc-ink); font-size: .9rem; }
.acc-tape-total b { font-size: 1.5rem; font-weight: 700; }
.acc-tape-total small { font-size: .78rem; font-weight: 400; }
.acc-tape-note { margin: 14px 0 0; font-size: .74rem; line-height: 1.5; color: var(--acc-mute); }
@keyframes acc-print { from { opacity: 0; transform: translateY(-6px); } }

.acc-btn {
  padding: 16px 18px; background: var(--acc-ink); color: #fff; border: 0; cursor: pointer;
  font-weight: 600; font-size: .95rem; line-height: 1; font-family: inherit; transition: background .15s;
}
.acc-btn:hover { background: #33333d; }
.acc-btn:focus-visible, .acc-seg button:focus-visible { outline: 2px solid #2b6cb0; outline-offset: 2px; }

@media (max-width: 720px) {
  .acc { grid-template-columns: 1fr; min-height: 0; }
  .acc-form { padding: 26px 18px; border-right: 0; border-bottom: 1px solid var(--acc-line); }
  .acc-tape-wrap { padding: 22px 18px; }
  .acc-seg button { font-size: .82rem; padding: 11px 2px; }
}
@media (prefers-reduced-motion: reduce) {
  .acc-tape-line, .acc-tape-total { animation: none; }
}
