.rra-tax-calculator {
  --rra-primary: #0f766e;
  --rra-primary-dark: #115e59;
  --rra-blue: #2563eb;
  --rra-green: #16a34a;
  --rra-ink: #0f172a;
  --rra-muted: #475569;
  --rra-line: #e2e8f0;
  --rra-soft: #f8fafc;
  --rra-mint: #ecfdf5;
  color: var(--rra-ink);
  font-family: inherit;
  max-width: 100%;
  overflow-x: hidden;
  width: 100%;
}

.rra-tax-calculator *,
.rra-tax-calculator *::before,
.rra-tax-calculator *::after {
  box-sizing: border-box;
}

.rra-tax-calculator a {
  text-decoration: none;
}

.rra-container {
  max-width: 1180px;
  margin-inline: auto;
  padding-inline: clamp(14px, 3vw, 24px);
  width: 100%;
}

.rra-hero,
.rra-calculator-band,
.rra-content-band,
.rra-stats-band,
.rra-seo-band {
  margin-left: 0;
  margin-right: 0;
  max-width: 100%;
  overflow-x: hidden;
  position: relative;
  width: 100%;
}

.rra-hero {
  background: linear-gradient(135deg, #eef7fb 0%, #fff 52%, #ecfdf5 100%);
  padding: clamp(34px, 6vw, 64px) 0;
}

.rra-hero-grid,
.rra-calculator-grid,
.rra-content-grid {
  display: grid;
  gap: 32px;
  min-width: 0;
}

.rra-hero-grid {
  align-items: center;
  grid-template-columns: minmax(0, 1.12fr) minmax(280px, 0.88fr);
}

.rra-eyebrow {
  color: var(--rra-primary);
  font-size: 14px;
  font-weight: 800;
  letter-spacing: .06em;
  margin: 0;
  text-transform: uppercase;
}

.rra-tax-calculator h1 {
  color: var(--rra-ink);
  font-size: clamp(40px, 6vw, 58px);
  font-weight: 900;
  letter-spacing: 0;
  line-height: 1.08;
  margin: 18px 0 0;
  overflow-wrap: anywhere;
}

.rra-tax-calculator h2 {
  color: var(--rra-ink);
  font-size: clamp(22px, 3vw, 28px);
  font-weight: 900;
  letter-spacing: 0;
  line-height: 1.2;
  margin: 0;
}

.rra-hero-subtitle {
  color: var(--rra-primary);
  font-size: clamp(24px, 3vw, 32px);
  font-weight: 900;
  line-height: 1.2;
  margin: 16px 0 0;
  overflow-wrap: anywhere;
}

.rra-hero-copy {
  color: var(--rra-muted);
  font-size: 18px;
  line-height: 1.75;
  margin: 20px 0 0;
  max-width: 680px;
}

.rra-actions,
.rra-field-grid,
.rra-badge-grid,
.rra-stats-grid {
  display: grid;
  gap: 14px;
}

.rra-actions {
  grid-template-columns: repeat(2, minmax(0, max-content));
  margin-top: 30px;
  max-width: 100%;
}

.rra-button {
  align-items: center;
  border: 1px solid transparent;
  border-radius: 6px;
  cursor: pointer;
  display: inline-flex;
  font-size: 15px;
  font-weight: 900;
  justify-content: center;
  line-height: 1.2;
  min-height: 50px;
  max-width: 100%;
  padding: 14px 22px;
  text-align: center;
  transition: background-color .2s ease, border-color .2s ease, color .2s ease, opacity .2s ease;
  white-space: normal;
}

.rra-button-primary {
  background: var(--rra-primary);
  color: #fff !important;
}

.rra-button-primary:hover {
  background: var(--rra-primary-dark);
  color: #fff !important;
}

.rra-button-green {
  background: var(--rra-green);
  color: #fff !important;
}

.rra-button-green:hover {
  background: #15803d;
  color: #fff !important;
}

.rra-button-secondary {
  background: #fff;
  border-color: #cbd5e1;
  color: var(--rra-ink);
}

.rra-button-secondary:hover {
  border-color: var(--rra-primary);
  color: var(--rra-primary);
}

.rra-button-wide {
  width: 100%;
}

.rra-button[disabled] {
  cursor: wait;
  opacity: .72;
}

.rra-badge-grid {
  grid-template-columns: repeat(4, 1fr);
  margin-top: 34px;
}

.rra-mini-card,
.rra-card,
.rra-trust-card,
.rra-stats-grid > div {
  background: #fff;
  border: 1px solid var(--rra-line);
  border-radius: 8px;
  box-shadow: 0 10px 24px rgba(15, 23, 42, .05);
}

.rra-mini-card {
  padding: 16px;
  min-width: 0;
}

.rra-mini-card strong,
.rra-mini-card span,
.rra-link-list strong,
.rra-link-list span {
  display: block;
}

.rra-mini-card strong {
  color: var(--rra-ink);
  font-size: 14px;
  font-weight: 900;
}

.rra-mini-card span {
  color: #64748b;
  font-size: 14px;
  line-height: 1.55;
  margin-top: 4px;
}

.rra-trust-card {
  padding: 28px;
  text-align: center;
  min-width: 0;
}

.rra-trust-card img {
  border: 8px solid #eef7fb;
  border-radius: 999px;
  box-shadow: 0 8px 18px rgba(15, 23, 42, .08);
  height: 144px;
  object-fit: cover;
  width: 144px;
}

.rra-trust-card h2 {
  margin-top: 20px;
}

.rra-trust-card p {
  color: var(--rra-primary);
  font-size: 14px;
  font-weight: 800;
  margin: 8px 0 0;
}

.rra-trust-card ul {
  display: grid;
  gap: 12px;
  list-style: none;
  margin: 24px 0 0;
  padding: 0;
  text-align: left;
}

.rra-trust-card li {
  background: var(--rra-soft);
  border: 1px solid var(--rra-line);
  border-radius: 6px;
  color: #334155;
  font-size: 14px;
  font-weight: 700;
  padding: 12px 14px;
}

.rra-calculator-band,
.rra-stats-band {
  background: var(--rra-soft);
  padding: 48px 0;
}

.rra-calculator-grid {
  align-items: start;
  grid-template-columns: minmax(0, 1fr) minmax(320px, .88fr);
}

.rra-step-tabs {
  display: grid;
  gap: 12px;
  grid-template-columns: repeat(3, 1fr);
  margin-bottom: 12px;
  text-align: center;
}

.rra-step-tabs > div {
  background: #fff;
  border: 1px solid var(--rra-line);
  border-radius: 8px;
  padding: 16px 10px;
}

.rra-step-tabs .is-active {
  background: var(--rra-mint);
  border-color: var(--rra-primary);
}

.rra-step-tabs .is-complete {
  border-color: #99f6e4;
}

.rra-step-tabs span {
  align-items: center;
  background: #f1f5f9;
  border-radius: 999px;
  color: var(--rra-ink);
  display: inline-flex;
  font-size: 14px;
  font-weight: 900;
  height: 36px;
  justify-content: center;
  width: 36px;
}

.rra-step-tabs .is-active span {
  background: var(--rra-primary);
  color: #fff;
}

.rra-step-tabs strong {
  display: block;
  font-size: 14px;
  margin-top: 8px;
}

.rra-progress-track {
  background: #dbeafe;
  border-radius: 999px;
  height: 8px;
  margin: 0 0 20px;
  overflow: hidden;
}

.rra-progress-track span {
  background: linear-gradient(90deg, var(--rra-primary), var(--rra-green));
  border-radius: inherit;
  display: block;
  height: 100%;
  transition: width .25s ease;
  width: 33%;
}

.rra-form {
  display: grid;
  gap: 16px;
}

.rra-card {
  min-width: 0;
  padding: 24px;
  max-width: 100%;
}

.rra-card summary {
  align-items: center;
  cursor: pointer;
  display: flex;
  font-size: 20px;
  font-weight: 900;
  justify-content: space-between;
  list-style: none;
}

.rra-card summary::-webkit-details-marker {
  display: none;
}

.rra-field-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  margin-top: 22px;
}

.rra-age-options {
  border: 0;
  display: grid;
  gap: 12px;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  margin: 20px 0 0;
  padding: 0;
}

.rra-age-options legend {
  color: #334155;
  font-size: 14px;
  font-weight: 900;
  margin-bottom: 10px;
}

.rra-age-options label {
  align-items: flex-start;
  background: #fff;
  border: 1px solid var(--rra-line);
  border-radius: 8px;
  cursor: pointer;
  display: flex;
  gap: 10px;
  padding: 13px;
}

.rra-age-options input {
  accent-color: var(--rra-primary);
  margin-top: 3px;
}

.rra-age-options span {
  color: var(--rra-ink);
  font-size: 14px;
  font-weight: 900;
  line-height: 1.25;
}

.rra-age-options small {
  color: #64748b;
  display: block;
  font-size: 12px;
  font-weight: 700;
  margin-top: 4px;
}

.rra-field-grid-3 {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.rra-field-grid input,
.rra-card label input,
.rra-card input {
  background: #fff;
  border: 1px solid #cbd5e1;
  border-radius: 6px;
  color: var(--rra-ink);
  display: block;
  font-size: 14px;
  outline: none;
  padding: 13px 14px;
  width: 100%;
  min-width: 0;
}

.rra-card label span {
  align-items: center;
  color: #334155;
  display: flex;
  font-size: 14px;
  font-weight: 700;
  gap: 6px;
  margin-bottom: 8px;
}

.rra-help {
  align-items: center;
  background: #e0f2fe;
  border: 1px solid #bae6fd;
  border-radius: 999px;
  color: #075985;
  cursor: help;
  display: inline-flex;
  font-size: 11px;
  font-weight: 900;
  height: 20px;
  justify-content: center;
  line-height: 1;
  padding: 0;
  width: 20px;
}

.rra-field-grid input:focus,
.rra-card input:focus {
  border-color: var(--rra-primary);
  box-shadow: 0 0 0 4px rgba(15, 118, 110, .1);
}

.rra-card input[aria-invalid="true"] {
  border-color: #dc2626;
}

.rra-field-error,
[data-field-error],
[data-lead-error] {
  color: #dc2626;
  display: block;
  font-size: 12px;
  font-weight: 700;
  margin-top: 8px;
}

.rra-tax-calculator .hidden,
#rr-lead-capture-popup .hidden {
  display: none !important;
}

.rra-note {
  color: #64748b;
  font-size: 13px;
  line-height: 1.6;
  margin: 14px 0 0;
}

.rra-info-box {
  background: #eff6ff;
  border: 1px solid #bfdbfe;
  border-left: 4px solid var(--rra-blue);
  border-radius: 8px;
  margin-top: 18px;
  padding: 14px;
}

.rra-info-box strong,
.rra-info-box span {
  display: block;
}

.rra-info-box strong {
  color: #1e3a8a;
  font-size: 14px;
  font-weight: 900;
}

.rra-info-box span {
  color: #334155;
  font-size: 13px;
  line-height: 1.6;
  margin-top: 4px;
}

.rra-result-column {
  display: grid;
  gap: 20px;
  min-width: 0;
}

.rra-table-wrap {
  border: 1px solid var(--rra-line);
  border-radius: 8px;
  margin-top: 20px;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  width: 100%;
  max-width: 100%;
}

.rra-table-wrap table {
  border-collapse: collapse;
  font-size: 13px;
  table-layout: fixed;
  width: 100%;
}

.rra-table-wrap th,
.rra-table-wrap td {
  border-right: 1px solid var(--rra-line);
  overflow-wrap: anywhere;
  padding: 12px 10px;
  text-align: left;
  vertical-align: top;
  word-break: normal;
}

.rra-table-wrap th:last-child,
.rra-table-wrap td:last-child {
  border-right: 0;
}

.rra-table-wrap tr {
  border-top: 1px solid var(--rra-line);
}

.rra-table-wrap thead tr {
  border-top: 0;
}

.rra-table-wrap th,
.rra-table-wrap .is-total {
  background: var(--rra-soft);
  font-weight: 900;
}

.rra-recommendation-box {
  background: var(--rra-mint);
  border: 1px solid #99f6e4;
  border-radius: 8px;
  margin-top: 20px;
  padding: 20px;
}

.rra-chart {
  background: #fff;
  border: 1px solid var(--rra-line);
  border-radius: 8px;
  display: grid;
  gap: 14px;
  margin-top: 18px;
  padding: 16px;
}

.rra-chart__row {
  align-items: center;
  display: grid;
  gap: 10px;
  grid-template-columns: 84px minmax(0, 1fr) minmax(84px, max-content);
}

.rra-chart__row span,
.rra-chart__row strong {
  color: var(--rra-ink);
  font-size: 13px;
  font-weight: 900;
}

.rra-chart__row div {
  background: #e2e8f0;
  border-radius: 999px;
  height: 12px;
  overflow: hidden;
}

.rra-chart__row i {
  background: var(--rra-primary);
  border-radius: inherit;
  display: block;
  height: 100%;
  min-width: 3px;
  transition: width .25s ease;
}

.rra-chart__row:nth-child(2) i {
  background: var(--rra-green);
}

.rra-recommendation-box p {
  color: var(--rra-ink);
  font-size: 18px;
  font-weight: 900;
  line-height: 1.35;
  margin: 0;
}

.rra-recommendation-box span {
  color: #334155;
  display: block;
  font-size: 14px;
  line-height: 1.6;
  margin-top: 8px;
}

.rra-result-metrics {
  display: grid;
  gap: 12px;
  grid-template-columns: repeat(3, 1fr);
  margin-top: 16px;
}

.rra-result-metrics div {
  background: #fff;
  border-radius: 6px;
  padding: 12px;
}

.rra-result-metrics span {
  color: #64748b;
  display: block;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: .04em;
  text-transform: uppercase;
}

.rra-result-metrics strong {
  color: var(--rra-ink);
  display: block;
  font-size: 16px;
  margin-top: 4px;
  overflow-wrap: anywhere;
}

.rra-submit-card {
  background: linear-gradient(135deg, #ffffff 0%, #ecfdf5 100%);
}

.rra-consult-card {
  align-items: center;
  display: flex;
  gap: 18px;
}

.rra-consult-card img {
  border-radius: 999px;
  height: 96px;
  object-fit: cover;
  width: 96px;
}

.rra-consult-card p:not(.rra-eyebrow) {
  color: var(--rra-muted);
  font-size: 14px;
  line-height: 1.65;
  margin: 8px 0 0;
}

.rra-content-band,
.rra-seo-band {
  background: #fff;
  padding: 48px 0;
}

.rra-content-grid {
  grid-template-columns: minmax(280px, .72fr) minmax(0, 1fr);
}

.rra-link-list {
  list-style: none;
  margin: 18px 0 0;
  padding: 0;
}

.rra-link-list li {
  border-top: 1px solid var(--rra-line);
  padding: 15px 0;
}

.rra-link-list li:first-child {
  border-top: 0;
}

.rra-link-list strong {
  font-size: 14px;
  font-weight: 900;
}

.rra-link-list span,
.rra-faq p,
.rra-seo-band p {
  color: var(--rra-muted);
  font-size: 14px;
  line-height: 1.65;
  margin: 4px 0 0;
}

.rra-faq {
  border: 1px solid var(--rra-line);
  border-radius: 8px;
  margin-top: 18px;
  overflow: hidden;
}

.rra-faq details {
  border-top: 1px solid var(--rra-line);
  padding: 16px;
}

.rra-faq details:first-child {
  border-top: 0;
}

.rra-faq summary {
  cursor: pointer;
  font-size: 14px;
  font-weight: 900;
}

.rra-stats-grid {
  grid-template-columns: repeat(4, 1fr);
}

.rra-stats-grid > div {
  padding: 24px;
  text-align: center;
}

.rra-stats-grid strong {
  color: var(--rra-primary);
  display: block;
  font-size: 32px;
  font-weight: 900;
}

.rra-stats-grid span {
  color: #64748b;
  display: block;
  font-size: 14px;
  font-weight: 700;
  margin-top: 4px;
}

.rra-seo-band .rra-card p:last-child {
  font-size: 16px;
  margin-top: 14px;
}

.rra-popup {
  align-items: center;
  box-sizing: border-box;
  display: flex;
  inset: 0;
  justify-content: center;
  padding: 24px 16px;
  position: fixed;
  z-index: 99999;
  max-width: 100vw;
}

.rra-popup *,
.rra-popup *::before,
.rra-popup *::after {
  box-sizing: border-box;
}

.rra-popup.is-hidden {
  display: none;
}

.rra-popup__overlay {
  background: rgba(15, 23, 42, .62);
  inset: 0;
  position: absolute;
}

.rra-popup__panel {
  background: #fff;
  border-radius: 10px;
  box-shadow: 0 24px 60px rgba(15, 23, 42, .28);
  max-width: 460px;
  padding: 26px;
  position: relative;
  width: 100%;
  width: min(100%, calc(100vw - 32px));
  max-height: calc(100vh - 32px);
  overflow-y: auto;
}

.rra-popup__close {
  background: #f8fafc;
  border: 0;
  border-radius: 999px;
  color: #64748b;
  cursor: pointer;
  font-size: 24px;
  height: 36px;
  line-height: 1;
  position: absolute;
  right: 14px;
  top: 14px;
  width: 36px;
}

.rra-popup__form {
  display: grid;
  gap: 14px;
  margin-top: 22px;
}

.rra-popup__form label span {
  color: #334155;
  display: block;
  font-size: 14px;
  font-weight: 700;
  margin-bottom: 8px;
}

.rra-popup__form input {
  border: 1px solid #cbd5e1;
  border-radius: 6px;
  font-size: 14px;
  padding: 13px 14px;
  width: 100%;
}

.rra-popup__actions {
  display: grid;
  gap: 12px;
  grid-template-columns: repeat(2, 1fr);
  margin-top: 8px;
}

.rra-popup__actions .rra-button {
  color: #fff !important;
  min-height: 48px;
  text-align: center;
  width: 100%;
}

.rra-alert {
  border-radius: 6px;
  font-size: 14px;
  font-weight: 700;
  padding: 12px 14px;
}

.rra-alert-error {
  background: #fef2f2;
  border: 1px solid #fecaca;
  color: #b91c1c;
}

.rra-alert-success {
  background: #ecfdf5;
  border: 1px solid #bbf7d0;
  color: #047857;
}

.rra-green {
  color: var(--rra-primary);
}

@media (max-width: 980px) {
  .rra-hero-grid,
  .rra-calculator-grid,
  .rra-content-grid {
    grid-template-columns: 1fr;
  }

  .rra-badge-grid,
  .rra-stats-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .rra-result-column {
    order: 2;
  }

  .rra-calculator-grid {
    gap: 22px;
  }
}

@media (max-width: 640px) {
  .rra-container {
    padding-inline: 12px;
  }

  .rra-hero,
  .rra-calculator-band,
  .rra-content-band,
  .rra-stats-band,
  .rra-seo-band {
    padding: 28px 0;
  }

  .rra-actions,
  .rra-badge-grid,
  .rra-field-grid,
  .rra-field-grid-3,
  .rra-age-options,
  .rra-step-tabs,
  .rra-stats-grid,
  .rra-popup__actions,
  .rra-result-metrics {
    grid-template-columns: 1fr;
  }

  .rra-card,
  .rra-trust-card,
  .rra-popup__panel {
    padding: 16px;
  }

  .rra-tax-calculator {
    margin-inline: 0;
  }

  .rra-hero-grid,
  .rra-calculator-grid,
  .rra-content-grid {
    gap: 18px;
  }

  .rra-consult-card {
    align-items: flex-start;
    flex-direction: column;
  }

  .rra-tax-calculator h1 {
    font-size: clamp(28px, 8vw, 34px);
    line-height: 1.12;
  }

  .rra-hero-subtitle {
    font-size: clamp(19px, 5.6vw, 22px);
  }

  .rra-hero-copy {
    font-size: 16px;
    line-height: 1.65;
  }

  .rra-actions {
    width: 100%;
    margin-top: 22px;
  }

  .rra-actions .rra-button {
    width: 100%;
  }

  .rra-trust-card img {
    height: 120px;
    width: 120px;
  }

  .rra-badge-grid {
    margin-top: 22px;
  }

  .rra-mini-card,
  .rra-step-tabs > div,
  .rra-stats-grid > div {
    padding: 14px;
  }

  .rra-step-tabs strong {
    font-size: 13px;
  }

  .rra-progress-track {
    margin-bottom: 16px;
  }

  .rra-card summary {
    align-items: flex-start;
    gap: 12px;
    font-size: 18px;
    line-height: 1.25;
  }

  .rra-field-grid {
    margin-top: 16px;
  }

  .rra-field-grid input,
  .rra-card label input,
  .rra-card input,
  .rra-popup__form input {
    font-size: 16px;
    min-height: 48px;
  }

  .rra-table-wrap {
    border-radius: 6px;
    margin-inline: 0;
    width: 100%;
  }

  .rra-table-wrap table {
    font-size: 12px;
    min-width: 520px;
    table-layout: auto;
  }

  .rra-chart__row {
    grid-template-columns: 1fr;
  }

  .rra-table-wrap th,
  .rra-table-wrap td {
    padding: 10px 7px;
  }

  .rra-result-card h2 {
    font-size: 21px;
  }

  .rra-recommendation-box {
    padding: 16px;
  }

  .rra-recommendation-box p {
    font-size: 16px;
  }

  .rra-popup {
    align-items: flex-end;
    padding: 12px;
  }

  .rra-popup__panel {
    border-radius: 12px;
    max-height: calc(100vh - 24px);
    width: min(100%, calc(100vw - 24px));
  }
}

@media (max-width: 380px) {
  .rra-container {
    padding-inline: 10px;
  }

  .rra-card,
  .rra-trust-card,
  .rra-popup__panel {
    padding: 14px;
  }

  .rra-button {
    padding-inline: 14px;
  }

  .rra-table-wrap table {
    min-width: 480px;
  }
}
