:root {
  --bg: #f7f8fb;
  --surface: #ffffff;
  --surface-soft: #f1f4f9;
  --text: #101828;
  --muted: #667085;
  --border: #dfe4ec;
  --blue: #2563eb;
  --blue-soft: #eaf0ff;
  --navy: #172033;
  --green: #087443;
  --shadow: 0 18px 50px rgba(16, 24, 40, .08);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: "Plus Jakarta Sans", Inter, ui-sans-serif, system-ui, sans-serif;
}
a { color: inherit; text-decoration: none; }
button { font: inherit; }
:focus-visible { outline: 2px solid var(--blue); outline-offset: 3px; }

.skip {
  position: absolute; left: 12px; top: -40px; z-index: 80;
  padding: 8px 12px; border-radius: 8px; background: var(--navy); color: #fff;
  font-size: 13px; font-weight: 750;
}
.skip:focus { top: 12px; }

.container { max-width: 1160px; margin: 0 auto; padding: 0 24px; }

header.site {
  height: 68px;
  display: flex;
  align-items: center;
  border-bottom: 1px solid var(--border);
  background: rgba(255, 255, 255, .86);
  backdrop-filter: blur(12px);
  position: sticky;
  top: 0;
  z-index: 10;
}
.site-in {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}
header.site .brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 800;
  font-size: 19px;
  letter-spacing: -.03em;
  color: #1a2332;
}
header.site .brand img { width: 28px; height: 28px; }
header.site .brand span { color: var(--blue); }
header.site .brand small { font-weight: 500; color: var(--muted); font-size: 11px; margin-left: 4px; }
.crumb { font-size: 13px; color: var(--muted); }
.crumb a { color: var(--blue); font-weight: 700; }
.crumb strong { color: var(--blue); }

main { padding: 38px 0 70px; }

.eyebrow {
  color: var(--blue);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: .11em;
  text-transform: uppercase;
}
body:not([data-tool="hub"]) h1 {
  font-family: Fraunces, Georgia, "Times New Roman", serif;
  font-size: clamp(38px, 5vw, 64px);
  line-height: .98;
  letter-spacing: -.045em;
  margin: 12px 0 14px;
  max-width: 850px;
  font-weight: 700;
}
body[data-tool="hub"] main { padding: 0 0 70px; }
.lead { font-size: 17px; line-height: 1.55; color: #526079; max-width: 720px; margin: 0; }

.layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(360px, .72fr);
  gap: 18px;
  margin-top: 34px;
}
.panel {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 22px;
  box-shadow: var(--shadow);
}
.inputs { padding: 26px; }
.result {
  padding: 26px;
  display: flex;
  flex-direction: column;
  min-height: 570px;
}
.section-title { font-size: 15px; font-weight: 800; margin-bottom: 5px; }
.section-sub { font-size: 13px; color: var(--muted); line-height: 1.5; }

.modes {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin: 20px 0 22px;
}
.mode {
  appearance: none;
  border: 1px solid var(--border);
  background: #fff;
  border-radius: 14px;
  padding: 15px;
  text-align: left;
  cursor: pointer;
  transition: .18s;
  color: var(--text);
}
.mode:hover { border-color: #aeb9cb; }
.mode.active {
  border-color: var(--blue);
  background: var(--blue-soft);
}
.mode .icon { font-size: 19px; }
.mode b { display: block; margin-top: 7px; font-size: 14px; }
.mode span { display: block; margin-top: 4px; color: var(--muted); font-size: 12px; line-height: 1.4; }

.fields {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}
label { display: block; }
.label {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  font-weight: 750;
  color: #475467;
  margin-bottom: 7px;
}

.tip { position: relative; display: inline-flex; }
.tip-btn {
  width: 18px;
  height: 18px;
  border-radius: 99px;
  border: 1px solid #d1d5db;
  background: #fff;
  color: #64748b;
  font-size: 10px;
  font-weight: 800;
  line-height: 1;
  padding: 0;
  cursor: help;
}
.tip-btn:hover,
.tip.is-open .tip-btn {
  border-color: #2563eb;
  color: #2563eb;
  background: #eff6ff;
}
.tip-pop {
  position: absolute;
  left: 0;
  bottom: calc(100% + 10px);
  width: min(260px, 72vw);
  background: #0f172a;
  color: #fff;
  border-radius: 10px;
  padding: 0.55rem 0.75rem;
  font-size: 12.5px;
  font-weight: 500;
  line-height: 1.45;
  box-shadow: 0 8px 20px rgba(15, 23, 42, .22);
  z-index: 30;
  opacity: 0;
  visibility: hidden;
  transform: translateY(4px);
  pointer-events: none;
  transition: opacity .12s ease, transform .12s ease, visibility .12s ease;
}
.tip-pop::after {
  content: "";
  position: absolute;
  left: 8px;
  bottom: -5px;
  width: 8px;
  height: 8px;
  background: #0f172a;
  transform: rotate(45deg);
}
.tip:hover .tip-pop,
.tip:focus-within .tip-pop,
.tip.is-open .tip-pop {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.ap-more {
  margin-top: 20px;
  border: 1px solid var(--border);
  border-radius: 14px;
  background: var(--surface-soft);
  padding: 4px 14px 4px;
}
.ap-more summary {
  cursor: pointer;
  list-style: none;
  min-height: 44px;
  display: flex;
  align-items: center;
  font-size: 13px;
  font-weight: 750;
  color: #344054;
}
.ap-more summary::-webkit-details-marker { display: none; }
.ap-more summary::after {
  content: "";
  width: 8px;
  height: 8px;
  margin-left: auto;
  border-right: 2px solid #98a2b3;
  border-bottom: 2px solid #98a2b3;
  transform: rotate(45deg);
}
.ap-more[open] summary::after { transform: rotate(225deg); margin-top: 4px; }
.ap-more[open] { padding-bottom: 14px; }
.ap-more-lead {
  margin: 0 0 10px;
  font-size: 12px;
  color: var(--muted);
  line-height: 1.45;
}
input, select {
  width: 100%;
  height: 47px;
  border: 1px solid var(--border);
  border-radius: 11px;
  padding: 0 13px;
  font-size: 15px;
  color: var(--text);
  background: #fff;
  outline: none;
}
input:focus, select:focus {
  border-color: var(--blue);
  box-shadow: 0 0 0 3px var(--blue-soft);
}
.rate-box {
  margin-top: 18px;
  background: var(--surface-soft);
  border: 1px solid var(--border);
  border-radius: 15px;
  padding: 15px;
}
.row { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.row strong { font-variant-numeric: tabular-nums; }
input[type=range] {
  height: auto;
  padding: 0;
  border: 0;
  box-shadow: none;
  margin: 12px 0 0;
  accent-color: var(--blue);
}
.range-labels { font-size: 11px; color: var(--muted); }
.scenario-title { font-size: 13px; font-weight: 800; margin: 22px 0 10px; }
.scenarios { display: grid; grid-template-columns: repeat(3, 1fr); gap: 9px; }
.scenario {
  border: 1px solid var(--border);
  background: #fff;
  border-radius: 11px;
  padding: 10px 11px;
  cursor: pointer;
  color: var(--text);
  font-size: 12px;
  font-weight: 700;
}
.scenario:hover { border-color: #aeb9cb; }

.top-result { padding-bottom: 21px; border-bottom: 1px solid var(--border); }
.result-kicker {
  font-size: 11px; font-weight: 800; letter-spacing: .1em; text-transform: uppercase; color: var(--muted);
}
.pill {
  display: inline-flex; align-items: center; padding: 5px 9px; border-radius: 999px;
  background: var(--blue-soft); color: var(--blue); font-size: 10px; font-weight: 800;
}
.result-label { color: var(--muted); font-size: 14px; margin-top: 22px; }
.result-main {
  font-family: Fraunces, Georgia, "Times New Roman", serif;
  font-size: 43px;
  line-height: 1.05;
  font-weight: 700;
  letter-spacing: -.04em;
  margin-top: 4px;
  font-variant-numeric: tabular-nums;
}
.result-sub { font-size: 13px; color: var(--muted); line-height: 1.5; margin-top: 9px; }

/* Hero no idioma visual dos KPIs do app (elevacash.css) */
body[data-tool="comparar"] .top-result,
body[data-tool="aposentadoria"] .top-result {
  padding: 1rem 1.1rem 1.05rem;
  margin-bottom: 2px;
  background: #f7f8fa;
  border: 1px solid #e5e7eb;
  border-radius: 12px;
  box-shadow: 0 1px 2px rgba(23, 32, 51, .04), 0 1px 3px rgba(23, 32, 51, .06);
}
body[data-tool="comparar"] .result-kicker,
body[data-tool="aposentadoria"] .result-kicker {
  font-size: 11.5px;
  font-weight: 600;
  letter-spacing: .04em;
  color: #64748b;
}
body[data-tool="comparar"] .pill,
body[data-tool="aposentadoria"] .pill {
  padding: 4px 10px;
  background: #eff6ff;
  color: #2563eb;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: .02em;
}
body[data-tool="comparar"] .result-label,
body[data-tool="aposentadoria"] .result-label {
  margin-top: 10px;
  color: #172033;
  font-size: 13px;
  font-weight: 650;
  letter-spacing: -.01em;
}
body[data-tool="comparar"] .result-main,
body[data-tool="aposentadoria"] .result-main {
  font-family: "Plus Jakarta Sans", Inter, system-ui, sans-serif;
  font-size: 1.7rem;
  font-weight: 650;
  letter-spacing: -.03em;
  line-height: 1.15;
  color: #172033;
  margin-top: 6px;
}
body[data-tool="comparar"] .result-sub,
body[data-tool="aposentadoria"] .result-sub {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 10px;
}
body[data-tool="comparar"] .result-chip,
body[data-tool="aposentadoria"] .result-chip {
  display: inline-flex;
  align-items: center;
  padding: 3px 8px;
  border-radius: 8px;
  font-size: 12.5px;
  font-weight: 600;
  background: #f1f5f9;
  color: #64748b;
}
body[data-tool="comparar"] .result-chip.is-up,
body[data-tool="aposentadoria"] .result-chip.is-up {
  background: #dcfce7;
  color: #15803d;
}
body[data-tool="comparar"] .result-chip.is-down,
body[data-tool="aposentadoria"] .result-chip.is-down {
  background: #fee2e2;
  color: #b91c1c;
}
.ap-path {
  list-style: none;
  margin: 18px 0 0;
  padding: 0;
  display: grid;
  gap: 0;
}
.ap-path li {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 12px;
  padding: 9px 0;
  border-bottom: 1px solid #eef2f6;
  font-size: 13px;
}
.ap-path li:last-child { border-bottom: 0; }
.ap-path .when { color: #64748b; }
.ap-path .amt { font-variant-numeric: tabular-nums; font-weight: 750; color: #172033; }
.ap-path li.is-now .when { font-weight: 650; color: #344054; }
.ap-path li.is-grow .amt { color: #2563eb; }
.ap-path li.is-goal .amt { color: #172033; }
.ap-path li.is-gap .when,
.ap-path li.is-gap .amt { color: #b91c1c; font-weight: 750; }
.ap-path li.is-ok .when,
.ap-path li.is-ok .amt { color: #15803d; font-weight: 750; }
.ap-path-note {
  margin: 10px 0 0;
  font-size: 12.5px;
  line-height: 1.5;
  color: #64748b;
}
.metrics { display: grid; gap: 13px; margin-top: 21px; }
.metric { display: flex; justify-content: space-between; gap: 14px; font-size: 13px; }
.metric span { color: var(--muted); }
.metric strong { font-variant-numeric: tabular-nums; }
.progress { margin-top: 22px; }
.progress-head { display: flex; justify-content: space-between; font-size: 12px; font-weight: 750; margin-bottom: 8px; }
.bar { height: 8px; border-radius: 99px; background: var(--surface-soft); overflow: hidden; }
.bar span { display: block; height: 100%; background: var(--blue); border-radius: 99px; transition: width .25s; }

.progress-card {
  margin-top: 18px;
  padding: 14px 16px 16px;
  background: #f7f8fa;
  border: 1px solid #e5e7eb;
  border-radius: 12px;
}
.progress-card .bar { height: 10px; background: #e5e7eb; }

.result-foot {
  margin-top: auto;
  padding-top: 22px;
}
.result-foot .cta { margin-top: 0; }

.cta {
  margin-top: auto;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 0;
  background: var(--navy);
  color: #fff;
  min-height: 48px;
  border-radius: 12px;
  font-weight: 800;
  cursor: pointer;
  font-size: 13px;
  width: 100%;
}
.cta:hover { background: #101828; }
.disclaimer-inline { text-align: center; color: var(--muted); font-size: 11px; line-height: 1.45; margin-top: 10px; }

.chart-panel { margin-top: 18px; padding: 24px; }
.chart-head { display: flex; justify-content: space-between; gap: 16px; align-items: end; }
.chart-title { font-size: 18px; font-weight: 800; }
.chart-sub { font-size: 12px; color: var(--muted); margin-top: 4px; }
.chart { height: 270px; margin-top: 12px; }
.chart svg { width: 100%; height: 100%; display: block; }

.scenario-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 14px;
  margin-top: 18px;
}
.scenario-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 17px;
  padding: 19px;
}
.scenario-card.is-ok { border-color: #86efac; background: #f0fdf4; }
.scenario-card .tag { font-size: 11px; color: var(--muted); }
.scenario-card .value { font-size: 19px; font-weight: 800; margin-top: 5px; font-variant-numeric: tabular-nums; }
.scenario-card .detail { font-size: 12px; color: var(--muted); margin-top: 6px; }

.explain {
  margin-top: 18px;
  padding: 17px 19px;
  border: 1px solid var(--border);
  border-radius: 15px;
  background: var(--surface-soft);
  color: var(--muted);
  font-size: 12px;
  line-height: 1.6;
}
.explain strong { color: var(--text); }

.cross {
  display: grid;
  gap: 8px;
  margin-top: 18px;
  padding: 17px 19px;
  border: 1px solid var(--border);
  border-radius: 15px;
  background: #fff;
}
.cross a { font-size: 14px; font-weight: 700; color: var(--blue); }
.cross a:hover { text-decoration: underline; }

.hub-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
  margin-top: 34px;
}
.hub-card {
  display: grid;
  gap: 10px;
  padding: 26px 24px 22px;
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 22px;
  box-shadow: var(--shadow);
  min-height: 280px;
}
.hub-card:hover { border-color: #c7d2fe; transform: translateY(-2px); }
.hub-card .n { font-size: 12px; font-weight: 800; letter-spacing: .1em; text-transform: uppercase; color: var(--blue); }
.hub-card h2 { margin: 0; font-family: Fraunces, Georgia, serif; font-size: 28px; letter-spacing: -.04em; line-height: 1.1; }
.hub-card p { margin: 0; color: var(--muted); font-size: 14px; line-height: 1.5; }
.hub-card em { margin-top: auto; font-style: normal; font-size: 13px; font-weight: 800; color: var(--blue); }

.landing-strip {
  margin-top: 48px;
  padding: 32px;
  background: var(--navy);
  color: #fff;
  border-radius: 22px;
}
.landing-strip h2 {
  font-family: Fraunces, Georgia, serif;
  font-size: clamp(28px, 4vw, 40px);
  letter-spacing: -.04em;
  margin: 10px 0 8px;
}
.landing-strip .lead { color: #9db1d2; }
.landing-cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; margin-top: 22px; }
.landing-cards a {
  display: grid; gap: 4px; padding: 16px; background: #13233d; border-radius: 14px; color: #fff;
}
.landing-cards a:hover { background: #193054; }
.landing-cards strong { font-size: 15px; }
.landing-cards span { font-size: 13px; color: #9db1d2; }

.inv-row {
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 14px;
  margin-top: 12px;
}
.inv-row header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 8px; }
.inv-row header strong { font-size: 13px; }
.linkish { border: 0; background: none; color: var(--blue); font-size: 12px; font-weight: 700; cursor: pointer; }
.add-btn {
  margin-top: 12px;
  width: 100%;
  height: 44px;
  border: 1px dashed var(--border);
  border-radius: 12px;
  background: #fff;
  font-weight: 750;
  color: var(--text);
  cursor: pointer;
}
.add-btn:hover { border-color: var(--blue); color: var(--blue); }

.table-wrap { overflow-x: auto; margin-top: 16px; }
table { width: 100%; border-collapse: collapse; font-size: 13px; }
th, td { text-align: left; padding: 10px 8px; border-bottom: 1px solid var(--border); }
th { color: var(--muted); font-weight: 650; }
tr.is-win td { font-weight: 750; background: var(--blue-soft); }
tr.is-ref td { color: var(--muted); }

.why { margin-top: 18px; }
.why h3 { margin: 0 0 8px; font-size: 15px; }
.why ol { margin: 0; padding-left: 18px; color: #475467; font-size: 13px; line-height: 1.55; }

.pick-hint {
  margin: 18px 0 8px;
  font-size: 12px;
  color: var(--muted);
  line-height: 1.45;
}
.pick-list { display: grid; gap: 8px; }
.pick-row {
  appearance: none;
  width: 100%;
  display: grid;
  grid-template-columns: 34px minmax(0, 1fr) auto;
  gap: 10px;
  align-items: center;
  text-align: left;
  border: 1px solid var(--border);
  background: #fff;
  border-radius: 14px;
  padding: 10px 12px;
  cursor: pointer;
  color: var(--text);
}
.pick-row:hover { border-color: #aeb9cb; }
.pick-row.is-on {
  border-color: var(--blue);
  background: var(--blue-soft);
}
.pick-row.is-ref .pick-name,
.pick-row.is-ref .pick-val { color: var(--muted); }
.pick-rank {
  font-size: 11px;
  font-weight: 800;
  color: var(--muted);
}
.pick-row.is-win .pick-rank { color: var(--blue); }
.pick-name { display: block; font-size: 12px; font-weight: 750; }
.pick-row .track {
  margin-top: 6px;
  height: 6px;
  border-radius: 99px;
  background: #eef2f6;
  overflow: hidden;
}
.pick-row .track i {
  display: block;
  height: 100%;
  border-radius: 99px;
  background: #93c5fd;
}
.pick-row.is-win .track i { background: var(--blue); }
.pick-row.is-ref .track i { background: #d0d5dd; }
.pick-row.is-on .track i { background: var(--blue); }
.pick-val {
  font-variant-numeric: tabular-nums;
  font-size: 13px;
  font-weight: 800;
  white-space: nowrap;
}

.why-box {
  margin-top: 18px;
  padding: 14px 16px;
  border-radius: 16px;
  background: #f8fafc;
  border: 1px solid var(--border);
}
.why-box h3 {
  margin: 0 0 6px;
  font-size: 14px;
  display: flex;
  align-items: center;
  gap: 8px;
}
.why-box p { margin: 0; font-size: 13px; color: #475467; line-height: 1.55; }

.cmp-accs { display: grid; gap: 8px; margin: 16px 0 18px; }
.cmp-acc {
  border: 1px solid var(--border);
  border-radius: 14px;
  background: #fff;
  padding: 0 14px;
}
.cmp-acc summary {
  list-style: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 48px;
  font-size: 13px;
  font-weight: 750;
}
.cmp-acc summary::-webkit-details-marker { display: none; }
.cmp-acc summary::after {
  content: "";
  width: 8px;
  height: 8px;
  margin-left: auto;
  border-right: 2px solid #98a2b3;
  border-bottom: 2px solid #98a2b3;
  transform: rotate(45deg);
}
.cmp-acc[open] summary::after { transform: rotate(225deg); margin-top: 4px; }
.acc-ico {
  width: 28px;
  height: 28px;
  border-radius: 8px;
  background: var(--surface-soft);
  display: grid;
  place-items: center;
  font-size: 11px;
  font-weight: 800;
  color: #475467;
}
.cmp-acc ul {
  margin: 0 0 14px 38px;
  padding: 0;
  list-style: none;
}
.cmp-acc li {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  font-size: 13px;
  color: #475467;
  padding: 4px 0;
}
.cmp-acc li strong { font-variant-numeric: tabular-nums; color: var(--text); }

.hidden { display: none !important; }

@media (max-width: 800px) {
  .layout { grid-template-columns: 1fr; }
  .result { min-height: 0; }
  .hub-grid, .landing-cards { grid-template-columns: 1fr; }
}
@media (max-width: 600px) {
  .container { padding: 0 16px; }
  header.site { height: 60px; }
  header.site .brand small { display: none; }
  main { padding-top: 26px; }
  h1 { font-size: 42px; }
  .layout { margin-top: 25px; }
  .inputs, .result, .chart-panel { padding: 20px; }
  .fields, .modes, .scenario-grid { grid-template-columns: 1fr; }
  .scenarios { grid-template-columns: 1fr; }
  .result-main { font-size: 38px; }
  body[data-tool="comparar"] .result-main,
  body[data-tool="aposentadoria"] .result-main { font-size: 1.5rem; }
  .chart { height: 220px; }
}
