.tax-page {
  padding: var(--space-8) var(--space-4) var(--space-12);
}

.tax-wrap {
  width: 100%;
  max-width: 980px;
  margin: 0 auto;
}

.tax-head {
  text-align: center;
  padding: var(--space-4) 0 var(--space-5);
  margin-bottom: var(--space-8);
}

.tax-head h1 {
  font-size: 1.7rem;
  letter-spacing: -0.02em;
  margin-bottom: var(--space-2);
  color: var(--text-primary);
}

.tax-head p {
  color: var(--text-secondary);
  font-size: 0.95rem;
  max-width: 760px;
  margin: 0 auto;
}

.tax-field--check {
  margin-top: var(--space-2);
}

.tax-check {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 0.88rem;
  color: var(--text-primary);
  cursor: pointer;
  font-weight: 600;
}

.tax-check input[type="checkbox"] {
  width: 18px;
  height: 18px;
  accent-color: var(--color-primary);
  margin: 0;
}

.tax-grid {
  display: grid;
  grid-template-columns: 320px 1fr;
  gap: var(--space-6);
  align-items: start;
}

.tax-card {
  background: var(--surface-1);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-xs);
}

.tax-settings {
  padding: var(--space-5);
  border-top: 4px solid var(--color-primary);
  position: sticky;
  top: 80px;
}

.tax-settings h2,
.tax-results h2 {
  font-size: 1.05rem;
  margin-bottom: var(--space-4);
  padding-bottom: var(--space-3);
  border-bottom: 1px solid var(--border);
}

.tax-field {
  margin-bottom: var(--space-4);
}

.tax-field label {
  display: block;
  font-size: 0.84rem;
  font-weight: 700;
  margin-bottom: 6px;
  color: var(--text-primary);
}

.tax-field--locked label {
  color: var(--text-tertiary);
}

.tax-input-wrap {
  position: relative;
}

.tax-input,
.tax-select {
  width: 100%;
  height: 40px;
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  background: var(--surface-2);
  color: var(--text-primary);
  padding: 0 12px;
  font-family: inherit;
  font-size: 0.92rem;
  outline: none;
  transition: border-color var(--dur-fast), box-shadow var(--dur-fast);
}

.tax-input:focus,
.tax-select:focus {
  border-color: var(--color-primary);
  box-shadow: 0 0 0 3px rgba(13, 148, 136, 0.14);
}

.tax-input:disabled {
  background: #eef0f2;
  color: #8a8f98;
  border-color: #d9dde3;
  cursor: not-allowed;
  box-shadow: none;
}

.tax-input--money {
  padding-left: 30px;
}

.tax-currency {
  position: absolute;
  left: 12px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-tertiary);
  font-size: 0.85rem;
}

.tax-note {
  background: var(--teal-50);
  border: 1px solid var(--teal-200);
  color: var(--teal-600);
  border-radius: var(--radius-md);
  padding: var(--space-3);
  font-size: 0.8rem;
  line-height: 1.6;
}

.tax-results {
  padding: var(--space-5);
}

.tax-summary {
  background: #272422;
  color: #fff;
  border-radius: var(--radius-lg);
  padding: var(--space-5);
  margin-bottom: var(--space-5);
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-4);
}

.tax-summary-label {
  color: #d8d0c8;
  font-size: 0.8rem;
}

.tax-summary-main {
  color: #7ee7dc;
  font-size: 2.1rem;
  font-weight: 800;
  margin-top: var(--space-2);
  letter-spacing: -0.02em;
}

.tax-summary-side {
  margin-top: var(--space-2);
  font-size: 1.3rem;
  font-weight: 700;
}

.tax-summary-rate {
  margin-top: 6px;
  color: #d8d0c8;
  font-size: 0.78rem;
}

.tax-breakdown {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-3);
}

.tax-row {
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: var(--space-3);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-2);
  font-size: 0.86rem;
}

.tax-row--danger {
  grid-column: 1 / -1;
  border-color: #f6c4bd;
  background: #fdf0ee;
}

.tax-row-title {
  color: var(--text-secondary);
  font-weight: 600;
}

.tax-row-value {
  color: var(--color-accent);
  font-weight: 800;
  white-space: nowrap;
}

.tax-kindergeld {
  margin-top: var(--space-4);
  border: 1px solid var(--teal-200);
  background: var(--teal-50);
  color: var(--teal-600);
  border-radius: var(--radius-md);
  padding: var(--space-3) var(--space-4);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-3);
  font-size: 0.9rem;
  font-weight: 700;
}

.tax-disclaimer {
  margin-top: var(--space-4);
  margin-bottom: 0;
  padding: var(--space-3) var(--space-4);
  border: 1px dashed var(--border);
  border-radius: var(--radius-md);
  color: var(--text-secondary);
  background: var(--surface-2);
  font-size: 0.82rem;
  line-height: 1.6;
  text-align: start;
}

@media (max-width: 920px) {
  .tax-grid {
    grid-template-columns: 1fr;
  }

  .tax-settings {
    position: static;
  }
}

@media (max-width: 640px) {
  .tax-summary {
    grid-template-columns: 1fr;
  }

  .tax-summary-main {
    font-size: 1.8rem;
  }

  .tax-breakdown {
    grid-template-columns: 1fr;
  }
}
