/* ---- Калькулятор стоимости декларации ---- */
.calc-wrap { padding: 72px 64px 96px; display: grid; grid-template-columns: minmax(0, 1fr) 340px; gap: 32px; align-items: start; max-width: 1180px; margin: 0 auto; width: 100%; }
.calc-card { background: var(--surface); border: 1px solid var(--line); border-radius: 20px; padding: 40px; min-height: 460px; display: flex; flex-direction: column; }
.calc-progress { height: 6px; border-radius: 999px; background: var(--surface-2); overflow: hidden; }
.calc-progress > span { display: block; height: 100%; width: 0; background: var(--accent); border-radius: 999px; transition: width .35s ease; }
.calc-meta { display: flex; justify-content: space-between; margin-top: 12px; font-size: 13px; color: var(--ink-faint); font-weight: 600; letter-spacing: .02em; }
.calc-step { margin-top: 28px; flex: 1; animation: calcIn .3s ease both; }
@keyframes calcIn { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }
@media (prefers-reduced-motion: reduce) { .calc-step { animation: none; } .calc-progress > span { transition: none; } }
.calc-q { margin: 0; font-size: 28px; line-height: 1.25; font-weight: 500; color: var(--ink); }
.calc-hint { margin: 10px 0 0; font-size: 15px; line-height: 1.6; color: var(--ink-soft); }
.calc-field + .calc-field { margin-top: 26px; }
.calc-q + .calc-field { margin-top: 22px; }
.calc-field-label { font-size: 15px; font-weight: 700; color: var(--ink); margin-bottom: 10px; display: block; }
.calc-options { display: grid; gap: 10px; margin-top: 22px; }
.calc-options.two { grid-template-columns: 1fr 1fr; }
.calc-opt { display: flex; align-items: flex-start; gap: 14px; padding: 15px 18px; border: 1.5px solid var(--line); border-radius: 12px; cursor: pointer; background: var(--surface); text-align: left; font: inherit; color: var(--ink); transition: border-color .15s, background .15s; width: 100%; }
.calc-opt:hover { border-color: var(--ink-faint); }
.calc-opt.on { border-color: var(--accent); background: var(--accent-soft); }
.calc-opt:focus-visible { outline: 2px solid var(--accent-dark); outline-offset: 2px; }
.calc-mark { flex: 0 0 20px; width: 20px; height: 20px; margin-top: 1px; border: 1.5px solid var(--ink-faint); border-radius: 50%; display: flex; align-items: center; justify-content: center; background: var(--surface); }
.calc-opt[role="checkbox"] .calc-mark { border-radius: 6px; }
.calc-opt.on .calc-mark { border-color: var(--accent-dark); background: var(--accent-dark); }
.calc-opt.on .calc-mark::after { content: ""; width: 8px; height: 8px; border-radius: 50%; background: #fff; }
.calc-opt[role="checkbox"].on .calc-mark::after { width: 10px; height: 6px; border-radius: 0; background: none; border-left: 2px solid #fff; border-bottom: 2px solid #fff; transform: rotate(-45deg) translate(1px, -1px); }
.calc-opt-title { font-size: 15.5px; font-weight: 600; line-height: 1.4; }
.calc-opt-sub { display: block; font-size: 13.5px; font-weight: 400; color: var(--ink-soft); line-height: 1.5; margin-top: 2px; }
.calc-sub { margin-top: 12px; padding: 18px 20px; border-radius: 12px; background: var(--surface-2); }
.calc-sub + .calc-sub { margin-top: 10px; }
.calc-num-row { display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.calc-num-row + .calc-num-row { margin-top: 14px; }
.calc-num-label { font-size: 14.5px; line-height: 1.45; color: var(--ink); }
.calc-stepper { display: inline-flex; align-items: center; border: 1.5px solid var(--line); border-radius: 10px; background: var(--surface); flex: 0 0 auto; }
.calc-stepper button { width: 38px; height: 38px; border: 0; background: none; font-size: 20px; color: var(--ink); cursor: pointer; border-radius: 8px; }
.calc-stepper button:hover { background: var(--surface-2); }
.calc-stepper output { min-width: 34px; text-align: center; font-weight: 700; font-size: 16px; }
.calc-input { width: 100%; padding: 14px 16px; border: 1.5px solid var(--line); border-radius: 10px; font: inherit; font-size: 15.5px; color: var(--ink); background: var(--surface); }
.calc-input:focus { outline: none; border-color: var(--accent); }
.calc-nav { display: flex; justify-content: space-between; align-items: center; gap: 12px; margin-top: 36px; padding-top: 24px; border-top: 1px solid var(--line); }
.calc-nav .btn-primary, .calc-nav .btn-secondary { cursor: pointer; font-family: inherit; }
.calc-nav .btn-primary[disabled] { opacity: .45; cursor: not-allowed; }
.calc-back { visibility: hidden; }
.calc-back.show { visibility: visible; }
.calc-error { margin-top: 14px; font-size: 14px; color: #B3261E; display: none; }
.calc-error.show { display: block; }

/* Живая оценка сбоку */
.calc-aside { position: sticky; top: 112px; /* ниже липкой шапки */ background: var(--ink); color: #fff; border-radius: 20px; padding: 28px; }
.calc-aside-label { font-size: 13px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: #F3C98E; }
.calc-aside-sum { margin-top: 10px; font-size: 38px; line-height: 1.1; font-weight: 500; }
.calc-aside-note { margin-top: 12px; font-size: 13.5px; line-height: 1.6; color: rgba(255,255,255,.72); }
.calc-aside-lines { margin: 18px 0 0; padding: 16px 0 0; border-top: 1px solid rgba(255,255,255,.16); list-style: none; display: grid; gap: 8px; font-size: 13.5px; max-height: 300px; overflow-y: auto; }
.calc-aside-lines li { display: flex; justify-content: space-between; gap: 12px; color: rgba(255,255,255,.86); line-height: 1.4; }
.calc-aside-lines li span:last-child { white-space: nowrap; font-weight: 700; color: #fff; }

/* Итог */
.calc-total { margin-top: 22px; padding: 24px 26px; border-radius: 14px; background: var(--accent-soft); display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 8px 20px; }
.calc-total-sum { font-size: 40px; line-height: 1.1; font-weight: 500; color: var(--ink); }
.calc-total-cap { font-size: 14px; color: var(--ink-soft); line-height: 1.5; max-width: 300px; }
.calc-h3 { margin: 34px 0 12px; font-size: 21px; font-weight: 600; color: var(--ink); }
.calc-table { width: 100%; border-collapse: collapse; font-size: 14.5px; }
.calc-table td { padding: 11px 0; border-bottom: 1px solid var(--line); vertical-align: top; line-height: 1.5; }
.calc-table td:last-child { text-align: right; white-space: nowrap; font-weight: 700; padding-left: 16px; }
.calc-notes { margin: 0; padding: 0; list-style: none; display: grid; gap: 10px; }
.calc-notes li { padding: 12px 16px; border-left: 3px solid var(--accent); background: var(--surface-2); border-radius: 0 10px 10px 0; font-size: 14.5px; line-height: 1.55; color: var(--ink); }
.calc-docs { margin: 0; padding: 0; list-style: none; columns: 2; column-gap: 28px; }
.calc-docs li { break-inside: avoid; padding: 6px 0 6px 26px; position: relative; font-size: 14.5px; line-height: 1.5; color: var(--ink); }
.calc-docs li::before { content: ""; position: absolute; left: 2px; top: 11px; width: 12px; height: 7px; border-left: 2px solid var(--accent-dark); border-bottom: 2px solid var(--accent-dark); transform: rotate(-45deg); }
.calc-result-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 32px; }
.calc-send { margin-top: 32px; padding: 26px; border: 1px solid var(--line); border-radius: 14px; display: grid; gap: 14px; }
.calc-consent { display: flex; gap: 10px; align-items: flex-start; font-size: 13px; line-height: 1.55; color: var(--ink-soft); }
.calc-consent input { margin-top: 3px; accent-color: var(--accent-dark); }

@media (max-width: 1000px) {
  .calc-wrap { grid-template-columns: 1fr; padding: 40px 16px 120px; }
  .calc-aside { display: none; }
}
@media (max-width: 700px) {
  .calc-card { padding: 24px 18px; border-radius: 16px; }
  .calc-q { font-size: 23px; }
  .calc-options.two { grid-template-columns: 1fr; }
  .calc-docs { columns: 1; }
  .calc-total-sum { font-size: 32px; }
  .calc-nav .btn-primary, .calc-nav .btn-secondary { padding: 14px 18px; }
}
/* Нижняя плашка с оценкой на мобильных */
.calc-mbar { display: none; }
@media (max-width: 1000px) {
  .calc-mbar { display: flex; position: fixed; left: 0; right: 0; bottom: 0; z-index: 50; background: var(--ink); color: #fff; padding: 12px 16px calc(12px + env(safe-area-inset-bottom)); justify-content: space-between; align-items: center; font-size: 14px; }
  .calc-mbar b { font-size: 19px; font-weight: 600; }
  .calc-mbar.hide { display: none; }
}
