:root {
  --tax-blue: #2998ff;
  --tax-sky: #79bdf6;
  --tax-mint: #61d2aa;
  --tax-coral: #ff7f70;
}

.breadcrumbs,
.field-note,
.field-help,
.range-meta,
.site-footer,
.sources,
.conditions-grid span { color: #536174; }

.calculator-grid { align-items: stretch; }
.input-card,
.tax-result { height: 100%; }
.choice-group { margin: 0 0 22px; padding: 0; border: 0; }
.choice-group legend { margin-bottom: 9px; color: #0b203f; font-size: 13px; font-weight: 850; }
.year-switch,
.object-switch {
  padding: 5px;
  display: grid;
  gap: 5px;
  border-radius: 16px;
  background: #e8edf4;
}
.year-switch { grid-template-columns: 1fr 1fr; }
.object-switch { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.year-switch button,
.object-switch button {
  min-height: 44px;
  padding: 9px 11px;
  border: 0;
  border-radius: 12px;
  color: #526077;
  background: transparent;
  font: inherit;
  font-size: 12px;
  font-weight: 800;
  line-height: 1.25;
  cursor: pointer;
}
.year-switch button.is-active,
.object-switch button.is-active {
  color: #091b36;
  background: #fff;
  box-shadow: 0 5px 16px rgba(9, 27, 54, .1);
}
.year-switch button:focus-visible,
.object-switch button:focus-visible {
  outline: 3px solid rgba(41, 152, 255, .3);
  outline-offset: 2px;
}
.object-switch button:nth-child(4),
.object-switch button:nth-child(5) { grid-column: span 1; }
.tax-fields { margin-top: 3px; }
.field-link { color: #096fda; text-decoration: none; }
.field-link:hover { text-decoration: underline; }

.benefit-options { display: grid; gap: 12px; }
.tax-check {
  min-height: 68px;
  padding: 14px 15px;
  border: 1px solid #d3d9e2;
  border-radius: 14px;
  display: flex;
  align-items: flex-start;
  gap: 11px;
  background: #fff;
  cursor: pointer;
}
.tax-check[hidden] { display: none; }
.tax-check:has(input:checked) {
  border-color: var(--tax-blue);
  background: #eef6ff;
  box-shadow: 0 0 0 2px rgba(41, 152, 255, .09);
}
.tax-check input { width: 17px; height: 17px; margin: 2px 0 0; flex: 0 0 auto; accent-color: #0875e2; }
.tax-check strong,
.tax-check small { display: block; }
.tax-check strong { color: #0b203f; font-size: 13px; }
.tax-check small { margin-top: 4px; color: #647185; font-size: 11px; line-height: 1.4; }
.child-field { padding: 4px 2px 8px; }
.child-field[hidden] { display: none; }
.result-a11y-status {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.tax-result {
  background:
    radial-gradient(circle at 100% 0, rgba(41, 152, 255, .24), transparent 38%),
    linear-gradient(160deg, #071b38 0%, #0b2b55 100%);
}
.tax-result .primary { background: #0877e6; }
.tax-result .result-actions button { border-color: var(--tax-coral); color: #071b38; background: var(--tax-coral); }
.tax-result .result-actions button:hover { background: #ff958a; }
.tax-composition { margin-top: 23px; padding: 22px 0 20px; border-top: 1px solid rgba(255, 255, 255, .15); border-bottom: 1px solid rgba(255, 255, 255, .15); }
.tax-donut {
  --taxable-share: 66.67%;
  background: conic-gradient(var(--tax-blue) 0 var(--taxable-share), var(--tax-sky) var(--taxable-share) 100%);
}
.tax-metrics { margin-top: 14px; }
.total-metric dt { display: flex; align-items: center; gap: 9px; color: #fff; }
.total-metric dd { color: #fff; font-size: 18px; }
.total-dot { width: 9px; height: 9px; border-radius: 50%; background: #fff; box-shadow: 0 0 0 5px rgba(255, 255, 255, .09); }

.tax-breakdown { overflow: visible; }
.tax-area-visual {
  padding: 22px 24px;
  border: 1px solid rgba(9, 27, 54, .09);
  border-radius: 22px;
  background: #f8fafc;
  transition: opacity .45s ease, transform .6s cubic-bezier(.22, 1, .36, 1);
}
.tax-area-visual.is-waiting { opacity: .001; transform: translateY(32px); }
.tax-area-visual.is-building { opacity: 1; transform: translateY(0); }
.tax-area-bar {
  height: 30px;
  border-radius: 999px;
  display: flex;
  overflow: hidden;
  background: #e6eaf0;
  box-shadow: inset 0 0 0 1px rgba(9, 27, 54, .06);
}
.tax-area-bar span,
.tax-area-bar i { display: block; height: 100%; transition: width .55s cubic-bezier(.22, 1, .36, 1); }
.tax-area-bar span { width: 33.33%; background: var(--tax-sky); }
.tax-area-bar i { width: 66.67%; background: var(--tax-blue); }
.tax-area-labels { margin-top: 12px; display: flex; flex-wrap: wrap; gap: 18px; color: #5e6a7e; font-size: 11px; }
.tax-area-labels span { display: flex; align-items: center; gap: 7px; }
.tax-area-labels b { width: 9px; height: 9px; border-radius: 50%; background: var(--tax-sky); }
.tax-area-labels span:last-child b { background: var(--tax-blue); }

.formula-steps {
  margin: 18px 0 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
  list-style: none;
}
.formula-steps li {
  min-width: 0;
  padding: 17px;
  border: 1px solid rgba(9, 27, 54, .09);
  border-radius: 18px;
  display: grid;
  grid-template-columns: 30px minmax(0, 1fr);
  gap: 11px;
  background: #fff;
}
.formula-steps li > span {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  color: #fff;
  background: #0879ea;
  font-size: 11px;
  font-weight: 900;
}
.formula-steps small,
.formula-steps strong,
.formula-steps p { display: block; }
.formula-steps small { color: #68758a; font-size: 10px; line-height: 1.3; }
.formula-steps strong { margin-top: 5px; color: #0a203f; font-size: 16px; line-height: 1.2; }
.formula-steps p { margin: 7px 0 0; color: #778397; font-size: 10px; line-height: 1.4; }

@media (max-width: 900px) {
  .formula-steps { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 620px) {
  .object-switch { grid-template-columns: 1fr 1fr; }
  .object-switch button,
  .object-switch button:last-child { grid-column: span 1; }
  .choice-group { margin-bottom: 19px; }
  .year-switch button,
  .object-switch button { min-height: 46px; font-size: 11px; }
  .tax-composition .composition-body { grid-template-columns: 124px minmax(0, 1fr); }
  .tax-composition .program-donut { width: 124px; }
  .tax-area-visual { padding: 18px 14px; border-radius: 18px; }
  .tax-area-bar { height: 25px; }
  .formula-steps { grid-template-columns: 1fr; }
  .formula-steps li { padding: 15px; }
}

@media print {
  .site-header,
  .breadcrumbs,
  .hero,
  .input-card,
  .program-back-to-calculator,
  .result-actions,
  .program-schedule-actions,
  .seo-content,
  .site-footer { display: none !important; }
  .page,
  .calculator-grid { width: 100%; margin: 0; display: block; }
  .tax-result,
  .tax-breakdown { margin: 0 0 18px; break-inside: avoid; color: #000; background: #fff; box-shadow: none; }
  .tax-result * { color: #000 !important; }
}

@media (prefers-reduced-motion: reduce) {
  .tax-area-visual,
  .tax-area-bar span,
  .tax-area-bar i { transition: none; }
  .tax-donut.is-building { animation: none !important; }
}
