:root {
  --ret-navy: #100b3d;
  --ret-navy-2: #1b1558;
  --ret-indigo: #312e81;
  --ret-violet: #6257d9;
  --ret-violet-soft: #eeecff;
  --ret-gold: #b59652;
  --ret-gold-deep: #6c5522;
  --ret-paper: #fbfaf7;
  --ret-surface: #ffffff;
  --ret-ink: #17162c;
  --ret-muted: #5e6076;
  --ret-line: #dedde7;
  --ret-cream: #f4f0e7;
  --ret-green: #1f6655;
  --ret-red: #8b3043;
  --ret-shadow: 0 22px 60px rgba(16, 11, 61, .09);
  --ret-radius: 22px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  color: var(--ret-ink);
  background: var(--ret-paper);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  line-height: 1.7;
}
a { color: #413a9d; text-decoration-thickness: 1px; text-underline-offset: 3px; }
a:hover { color: var(--ret-indigo); }

.preview-topbar {
  position: sticky;
  top: 0;
  z-index: 80;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 20px;
  min-height: 52px;
  padding: 10px clamp(20px, 5vw, 72px);
  color: #fff;
  background: rgba(16, 11, 61, .97);
  backdrop-filter: blur(12px);
}
.preview-brand { font-size: 1.25rem; font-weight: 900; letter-spacing: -.055em; }
.preview-brand em { color: #aaa2ff; font-style: normal; }
.preview-status {
  padding: 5px 10px;
  border: 1px solid rgba(255,255,255,.34);
  border-radius: 999px;
  font-size: .68rem;
  font-weight: 850;
  letter-spacing: .1em;
  text-transform: uppercase;
}

.ret-hero {
  position: relative;
  overflow: hidden;
  color: #fff;
  background:
    radial-gradient(58% 95% at 91% 4%, rgba(98,87,217,.42), transparent 62%),
    radial-gradient(45% 70% at 4% 100%, rgba(181,150,82,.13), transparent 62%),
    linear-gradient(116deg, transparent 36%, rgba(255,255,255,.052) 50%, transparent 64%),
    linear-gradient(137deg, var(--ret-navy) 0%, #191354 60%, #292278 100%);
}
.ret-hero::before {
  content: "";
  position: absolute;
  inset: 0;
  opacity: .15;
  background-image: linear-gradient(rgba(255,255,255,.14) 1px, transparent 1px), linear-gradient(90deg, rgba(255,255,255,.1) 1px, transparent 1px);
  background-size: 44px 44px;
  mask-image: linear-gradient(to bottom, #000, transparent 93%);
}
.ret-hero__inner {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(360px, .8fr);
  gap: clamp(44px, 7vw, 96px);
  align-items: center;
  width: min(1180px, calc(100% - 48px));
  margin: 0 auto;
  padding: clamp(68px, 8vw, 112px) 0 clamp(64px, 8vw, 96px);
}
.ret-breadcrumbs { margin: 0 0 22px; color: rgba(255,255,255,.69); font-size: .78rem; }
.ret-kicker {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 17px;
  color: #ead79e;
  font-size: .72rem;
  font-weight: 850;
  letter-spacing: .15em;
  text-transform: uppercase;
}
.ret-kicker::before { content: ""; width: 30px; height: 2px; background: currentColor; }
.ret-hero h1 {
  max-width: 790px;
  margin: 0;
  font-size: clamp(2.8rem, 5.6vw, 5rem);
  font-weight: 900;
  line-height: .99;
  letter-spacing: -.064em;
}
.ret-hero__deck {
  max-width: 710px;
  margin: 24px 0 0;
  color: rgba(255,255,255,.8);
  font-size: clamp(1.04rem, 1.7vw, 1.25rem);
  line-height: 1.58;
}
.ret-hero__meta { display: flex; flex-wrap: wrap; gap: 9px 20px; margin-top: 27px; color: rgba(255,255,255,.68); font-size: .78rem; }

.ret-hero-art { position: relative; min-height: 430px; isolation: isolate; }
.ret-hero-art__panel {
  position: absolute;
  inset: 25px 2px 20px 35px;
  border: 1px solid rgba(255,255,255,.24);
  border-radius: 26px;
  background: linear-gradient(145deg, rgba(255,255,255,.14), rgba(255,255,255,.045));
  box-shadow: 0 28px 80px rgba(3, 2, 20, .35);
  backdrop-filter: blur(8px);
}
.ret-hero-art__panel::after { content: ""; position: absolute; inset: 0; border-radius: inherit; background: linear-gradient(115deg, transparent 35%, rgba(255,255,255,.09) 50%, transparent 65%); }
.ret-hero-art__node {
  position: absolute;
  z-index: 2;
  display: grid;
  align-content: center;
  min-height: 82px;
  padding: 15px 17px;
  border: 1px solid rgba(255,255,255,.28);
  border-radius: 16px;
  color: #fff;
  background: rgba(16,11,61,.78);
  box-shadow: 0 15px 36px rgba(4,3,25,.28);
}
.ret-hero-art__node span { color: #e4ce8c; font-size: .62rem; font-weight: 900; letter-spacing: .13em; text-transform: uppercase; }
.ret-hero-art__node strong { margin-top: 4px; font-size: .92rem; line-height: 1.25; }
.ret-hero-art__node--contract { left: 0; top: 58px; width: 184px; }
.ret-hero-art__node--regime { right: 4px; top: 22px; width: 178px; }
.ret-hero-art__node--year { right: 0; top: 174px; width: 178px; }
.ret-hero-art__node--output { left: 34px; bottom: 24px; width: 205px; }
.ret-hero-art__core {
  position: absolute;
  z-index: 3;
  left: 50%;
  top: 49%;
  display: grid;
  place-items: center;
  width: 138px;
  height: 138px;
  transform: translate(-50%, -50%);
  border: 1px solid rgba(255,255,255,.42);
  border-radius: 28px;
  color: var(--ret-navy);
  background: linear-gradient(145deg, #fff, #e9e6ff);
  box-shadow: 0 22px 50px rgba(4,3,25,.34);
  text-align: center;
}
.ret-hero-art__core span { color: var(--ret-gold-deep); font-size: .62rem; font-weight: 900; letter-spacing: .13em; }
.ret-hero-art__core strong { font-size: 1.55rem; line-height: 1.05; }
.ret-hero-art__line { position: absolute; z-index: 1; height: 2px; transform-origin: left center; background: linear-gradient(90deg, rgba(230,209,149,.85), rgba(255,255,255,.16)); }
.ret-hero-art__line--a { left: 166px; top: 125px; width: 126px; transform: rotate(23deg); }
.ret-hero-art__line--b { left: 266px; top: 150px; width: 122px; transform: rotate(-35deg); }
.ret-hero-art__line--c { left: 279px; top: 232px; width: 110px; transform: rotate(7deg); }
.ret-hero-art__line--d { left: 174px; top: 288px; width: 116px; transform: rotate(-27deg); }

.preview-main { width: min(1180px, calc(100% - 48px)); margin: 0 auto; padding: 76px 0 96px; }
.ret-layout { display: grid; grid-template-columns: minmax(0, 800px) 230px; gap: 72px; align-items: start; justify-content: center; }
.ret-toc { position: sticky; top: 82px; padding-top: 6px; }
.ret-toc > strong { display: block; margin-bottom: 13px; color: var(--ret-navy); font-size: .68rem; font-weight: 900; letter-spacing: .14em; text-transform: uppercase; }
.ret-toc ol { margin: 0; padding: 0; list-style: none; counter-reset: toc; }
.ret-toc li { counter-increment: toc; margin: 0 0 10px; }
.ret-toc a { display: grid; grid-template-columns: 24px 1fr; gap: 8px; color: var(--ret-muted); font-size: .75rem; line-height: 1.36; text-decoration: none; }
.ret-toc a::before { content: counter(toc, decimal-leading-zero); color: var(--ret-gold-deep); font-weight: 850; }

.taxup-retencoes-saas { min-width: 0; font-size: 1.035rem; }
.taxup-retencoes-saas p { margin: 0 0 1.22rem; }
.taxup-retencoes-saas > h2 {
  scroll-margin-top: 84px;
  margin: 38px 0 18px;
  color: var(--ret-navy);
  font-size: clamp(2rem, 3.7vw, 3.03rem);
  font-weight: 900;
  line-height: 1.04;
  letter-spacing: -.052em;
}
.taxup-retencoes-saas > h2:first-of-type { margin-top: 42px; }
.taxup-retencoes-saas h3 { margin: 0 0 10px; color: var(--ret-navy); font-size: 1.18rem; line-height: 1.3; }
.taxup-retencoes-saas ul, .taxup-retencoes-saas ol { margin: 0 0 1.35rem; padding-left: 1.35rem; }
.taxup-retencoes-saas li { margin-bottom: .58rem; }

.ret-answer {
  padding: 28px 30px 25px;
  border: 1px solid #d9d6ef;
  border-left: 5px solid var(--ret-violet);
  border-radius: 20px;
  background: linear-gradient(135deg, #fff, #f2f0ff);
  box-shadow: 0 18px 46px rgba(16,11,61,.07);
}
.ret-answer p:last-child { margin-bottom: 0; }
.ret-eyebrow { display: block; margin-bottom: 8px; color: var(--ret-indigo); font-size: .7rem; font-weight: 900; letter-spacing: .14em; text-transform: uppercase; }

.ret-premises { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1px; margin: 22px 0 26px; overflow: hidden; border: 1px solid var(--ret-line); border-radius: 18px; background: var(--ret-line); box-shadow: var(--ret-shadow); }
.ret-premises > div { min-height: 126px; padding: 18px 16px; background: #fff; }
.ret-premises span, .ret-decision-flow span, .ret-doc-chain span { display: block; color: var(--ret-gold-deep); font-size: .64rem; font-weight: 900; letter-spacing: .12em; }
.ret-premises strong, .ret-decision-flow strong, .ret-doc-chain strong { display: block; margin-top: 8px; color: var(--ret-navy); font-size: .91rem; line-height: 1.3; }
.ret-premises small, .ret-decision-flow small, .ret-doc-chain small { display: block; margin-top: 6px; color: var(--ret-muted); font-size: .71rem; line-height: 1.4; }

.ret-decision-flow { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; margin: 0 0 24px; }
.ret-decision-flow > div { position: relative; min-height: 155px; padding: 22px 20px; border: 1px solid var(--ret-line); border-radius: 18px; background: #fff; box-shadow: var(--ret-shadow); }
.ret-decision-flow > div:not(:last-child)::after { content: "→"; position: absolute; z-index: 2; top: 50%; right: -21px; display: grid; place-items: center; width: 28px; height: 28px; transform: translateY(-50%); border-radius: 50%; color: #fff; background: var(--ret-violet); font-weight: 900; }

.ret-figure { margin: 0 0 24px; }
.ret-figure--indexable { display: block; overflow: visible; }
.ret-figure__semantic { position: absolute !important; width: 1px !important; height: 1px !important; margin: -1px !important; padding: 0 !important; overflow: hidden !important; clip: rect(0 0 0 0) !important; clip-path: inset(50%) !important; border: 0 !important; }
.ret-figure__media, .ret-figure__media img { display: block; width: 100%; }
.ret-figure__media img { height: auto; border: 1px solid var(--ret-line); border-radius: var(--ret-radius) var(--ret-radius) 0 0; background: #fff; }
.ret-figure figcaption { padding: 13px 18px; color: var(--ret-muted); border: 1px solid var(--ret-line); border-top: 0; border-radius: 0 0 var(--ret-radius) var(--ret-radius); background: #faf9fc; font-size: .76rem; line-height: 1.45; }

.ret-matrix { display: grid; grid-template-columns: repeat(2, 1fr); gap: 1px; overflow: hidden; border: 1px solid var(--ret-line); border-radius: var(--ret-radius); background: var(--ret-line); box-shadow: var(--ret-shadow); }
.ret-matrix > div { min-height: 192px; padding: 25px 23px; background: #fff; }
.ret-matrix span { color: var(--ret-gold-deep); font-size: .66rem; font-weight: 900; letter-spacing: .11em; text-transform: uppercase; }
.ret-matrix strong, .ret-matrix b { display: block; margin-top: 14px; color: var(--ret-navy); font-size: 1rem; line-height: 1.2; }
.ret-matrix b { margin-top: 6px; }
.ret-matrix small { display: block; margin-top: 16px; color: var(--ret-muted); font-size: .74rem; line-height: 1.45; }
.ret-matrix .is-clear { background: #f1f8f5; }
.ret-matrix .is-asymmetric { color: #fff; background: var(--ret-navy); }
.ret-matrix .is-asymmetric span { color: #ead79e; }
.ret-matrix .is-asymmetric strong, .ret-matrix .is-asymmetric b { color: #fff; }
.ret-matrix .is-asymmetric small { color: rgba(255,255,255,.76); }
.ret-matrix .is-variable { background: var(--ret-cream); }

.ret-source-note { margin: 0 0 24px; padding: 22px 24px; border-left: 4px solid var(--ret-gold); background: #fff; box-shadow: var(--ret-shadow); }
.ret-source-note > strong { color: var(--ret-navy); font-size: .72rem; letter-spacing: .12em; text-transform: uppercase; }
.ret-source-note p { margin: 8px 0 0; }

.ret-year-compare { display: grid; grid-template-columns: 1fr 1fr; overflow: hidden; border: 1px solid var(--ret-line); border-radius: var(--ret-radius); box-shadow: var(--ret-shadow); }
.ret-year-compare section { min-height: 240px; padding: 36px; }
.ret-year-compare section:first-child { background: #fff; }
.ret-year-compare section:last-child { color: #fff; background: linear-gradient(145deg, var(--ret-navy), var(--ret-indigo)); }
.ret-year-compare span { color: var(--ret-gold-deep); font-size: .7rem; font-weight: 900; letter-spacing: .12em; text-transform: uppercase; }
.ret-year-compare section:last-child span { color: #ead79e; }
.ret-year-compare strong { display: block; margin-top: 20px; color: inherit; font-size: 2rem; line-height: 1.05; }
.ret-year-compare p { margin: 16px 0 0; color: inherit; opacity: .78; }

.ret-compare-table { margin-bottom: 8px; overflow: hidden; border: 1px solid var(--ret-line); border-radius: var(--ret-radius); background: #fff; box-shadow: var(--ret-shadow); }
.ret-compare-table > div { display: grid; grid-template-columns: 1.05fr 1fr 1fr; }
.ret-compare-table > div > * { padding: 15px 18px; border-bottom: 1px solid var(--ret-line); }
.ret-compare-table > div:last-child > * { border-bottom: 0; }
.ret-compare-table__head { color: #fff; background: var(--ret-navy); font-size: .7rem; font-weight: 900; letter-spacing: .09em; text-transform: uppercase; }
.ret-compare-table strong { color: var(--ret-navy); }
.ret-footnote { color: var(--ret-muted); font-size: .78rem; }

.ret-asymmetry { display: grid; grid-template-columns: 1fr 58px 1fr; align-items: stretch; margin-bottom: 24px; overflow: hidden; border: 1px solid var(--ret-line); border-radius: var(--ret-radius); background: #fff; box-shadow: var(--ret-shadow); }
.ret-asymmetry section { min-height: 190px; padding: 28px; }
.ret-asymmetry section:first-child { background: var(--ret-cream); }
.ret-asymmetry section:last-child { color: #fff; background: var(--ret-navy); }
.ret-asymmetry > div { display: grid; place-items: center; color: var(--ret-violet); background: #fff; font-size: 1.6rem; font-weight: 900; }
.ret-asymmetry span, .ret-poles span, .ret-thresholds span, .ret-public-warning > span, .ret-ops-grid span, .ret-cases > section > span { color: var(--ret-gold-deep); font-size: .67rem; font-weight: 900; letter-spacing: .12em; text-transform: uppercase; }
.ret-asymmetry section:last-child span { color: #ead79e; }
.ret-asymmetry strong { display: block; margin-top: 13px; color: inherit; font-size: 2rem; }
.ret-asymmetry p { margin: 10px 0 0; color: inherit; opacity: .78; font-size: .84rem; }

.ret-poles { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin-bottom: 24px; }
.ret-poles section { min-height: 210px; padding: 28px; border: 1px solid var(--ret-line); border-radius: var(--ret-radius); background: #fff; box-shadow: var(--ret-shadow); }
.ret-poles section:last-child { background: linear-gradient(135deg, #fff, #f1efff); }
.ret-poles strong { display: block; margin-top: 17px; color: var(--ret-navy); font-size: 1.24rem; line-height: 1.25; }
.ret-poles p { margin: 12px 0 0; color: var(--ret-muted); }

.ret-thresholds { display: grid; grid-template-columns: 1fr 1fr; gap: 1px; margin-bottom: 24px; overflow: hidden; border: 1px solid var(--ret-line); border-radius: var(--ret-radius); background: var(--ret-line); box-shadow: var(--ret-shadow); }
.ret-thresholds section { min-height: 170px; padding: 27px; background: #fff; }
.ret-thresholds section strong { display: block; margin-top: 15px; color: var(--ret-navy); font-size: 1.2rem; }
.ret-thresholds section p { margin: 9px 0 0; color: var(--ret-muted); }
.ret-thresholds aside { grid-column: 1 / -1; padding: 18px 27px; color: #fff; background: var(--ret-indigo); }
.ret-thresholds aside p { display: inline; margin: 0 0 0 8px; color: rgba(255,255,255,.8); }

.ret-public-warning { position: relative; margin-bottom: 24px; overflow: hidden; padding: 30px 34px; border-radius: var(--ret-radius); color: #fff; background: linear-gradient(137deg, var(--ret-navy), #27206e); box-shadow: var(--ret-shadow); }
.ret-public-warning::after { content: ""; position: absolute; inset: 0; pointer-events: none; background: linear-gradient(115deg, transparent 42%, rgba(255,255,255,.07) 52%, transparent 62%); }
.ret-public-warning > span { color: #ead79e; }
.ret-public-warning > strong { position: relative; z-index: 1; display: block; max-width: 620px; margin-top: 15px; font-size: 1.45rem; line-height: 1.25; }
.ret-public-warning p { position: relative; z-index: 1; margin: 13px 0 0; color: rgba(255,255,255,.81); }
.ret-public-warning a { color: #fff; }

.ret-doc-chain { display: grid; grid-template-columns: repeat(6, 1fr); gap: 1px; margin-bottom: 24px; overflow: hidden; border: 1px solid var(--ret-line); border-radius: var(--ret-radius); background: var(--ret-line); box-shadow: var(--ret-shadow); }
.ret-doc-chain > div { min-height: 144px; padding: 19px 15px; background: #fff; }

.ret-ops-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; margin-bottom: 24px; }
.ret-ops-grid > div { min-height: 150px; padding: 23px; border: 1px solid var(--ret-line); border-radius: 18px; background: #fff; box-shadow: var(--ret-shadow); }
.ret-ops-grid strong { display: block; margin-top: 15px; color: var(--ret-navy); font-size: 1.15rem; line-height: 1.2; }
.ret-ops-grid small { display: block; margin-top: 9px; color: var(--ret-muted); line-height: 1.4; }

.ret-tool { margin-bottom: 24px; overflow: hidden; border: 1px solid #d7d4ea; border-radius: var(--ret-radius); background: #fff; box-shadow: var(--ret-shadow); }
.ret-tool__head { padding: 30px 32px 26px; color: #fff; background: linear-gradient(137deg, var(--ret-navy), var(--ret-indigo)); }
.ret-tool__head span { color: #ead79e; font-size: .68rem; font-weight: 900; letter-spacing: .13em; text-transform: uppercase; }
.ret-tool__head h3 { margin: 10px 0 0; color: #fff; font-size: 1.8rem; }
.ret-tool__head p { margin: 9px 0 0; color: rgba(255,255,255,.78); }
.ret-tool__form { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; padding: 28px 32px; }
.ret-tool label { color: var(--ret-navy); font-size: .79rem; font-weight: 850; }
.ret-tool select { width: 100%; min-height: 48px; margin-top: 8px; padding: 0 42px 0 13px; border: 1px solid #c9c7d8; border-radius: 10px; color: var(--ret-ink); background: #fff; font: inherit; font-weight: 500; }
.ret-tool select:focus-visible { outline: 3px solid rgba(98,87,217,.35); outline-offset: 2px; }
.ret-tool__result { margin: 0 32px 24px; padding: 22px 24px; border-left: 4px solid var(--ret-violet); background: #f2f0ff; }
.ret-tool__result span { color: var(--ret-indigo); font-size: .67rem; font-weight: 900; letter-spacing: .12em; text-transform: uppercase; }
.ret-tool__result strong { display: block; margin-top: 8px; color: var(--ret-navy); font-size: 1.18rem; }
.ret-tool__result p { margin: 8px 0 0; color: var(--ret-muted); font-size: .86rem; }
.ret-tool__privacy { margin: 0 32px 26px !important; color: var(--ret-muted); font-size: .72rem; }

.ret-cases { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; margin-bottom: 24px; }
.ret-cases section { min-height: 220px; padding: 24px; border: 1px solid var(--ret-line); border-top: 4px solid var(--ret-gold); border-radius: 16px; background: #fff; box-shadow: var(--ret-shadow); }
.ret-cases h3 { margin-top: 11px; }
.ret-cases p { margin: 0 0 15px; color: var(--ret-muted); font-size: .88rem; }
.ret-cases strong { display: block; color: var(--ret-navy); font-size: 1rem; }
.ret-cases small { display: block; margin-top: 6px; color: var(--ret-muted); }

.ret-timeline { position: relative; display: grid; grid-template-columns: repeat(4, 1fr); gap: 18px; margin-bottom: 24px; padding: 30px; border: 1px solid var(--ret-line); border-radius: var(--ret-radius); background: #fff; box-shadow: var(--ret-shadow); }
.ret-timeline::before { content: ""; position: absolute; top: 57px; left: 8%; right: 8%; height: 2px; background: linear-gradient(90deg, var(--ret-gold), var(--ret-violet)); }
.ret-timeline > div { position: relative; padding-top: 50px; }
.ret-timeline > div::before { content: ""; position: absolute; top: 17px; left: 0; width: 15px; height: 15px; border: 4px solid #fff; border-radius: 50%; background: var(--ret-violet); box-shadow: 0 0 0 2px var(--ret-violet); }
.ret-timeline span { color: var(--ret-gold-deep); font-size: .68rem; font-weight: 900; }
.ret-timeline strong { display: block; margin-top: 6px; color: var(--ret-navy); font-size: .92rem; line-height: 1.25; }
.ret-timeline small { display: block; margin-top: 7px; color: var(--ret-muted); font-size: .72rem; line-height: 1.45; }

.ret-checklist { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; margin-bottom: 24px; }
.ret-checklist section { padding: 24px; border: 1px solid var(--ret-line); border-radius: 18px; background: #fff; box-shadow: var(--ret-shadow); }
.ret-checklist h3 { padding-bottom: 13px; border-bottom: 2px solid var(--ret-gold); }
.ret-checklist ul { margin: 16px 0 0; padding-left: 18px; }
.ret-checklist li { font-size: .84rem; }

.ret-cta { position: relative; overflow: hidden; margin: 42px 0 8px; padding: 38px 40px; border-radius: var(--ret-radius); color: #fff; background: linear-gradient(137deg, var(--ret-navy), #292278); box-shadow: 0 24px 70px rgba(16,11,61,.2); }
.ret-cta::after { content: ""; position: absolute; inset: 0; pointer-events: none; background: linear-gradient(115deg, transparent 42%, rgba(255,255,255,.07) 52%, transparent 62%); }
.ret-cta > span { position: relative; z-index: 1; color: #ead79e; font-size: .67rem; font-weight: 900; letter-spacing: .14em; text-transform: uppercase; }
.ret-cta h2 { position: relative; z-index: 1; max-width: 650px; margin: 12px 0 14px; color: #fff; font-size: clamp(1.85rem, 3.5vw, 2.8rem); line-height: 1.06; letter-spacing: -.04em; }
.ret-cta p { position: relative; z-index: 1; color: rgba(255,255,255,.78); }
.ret-cta > a { position: relative; z-index: 1; display: inline-flex; justify-content: space-between; align-items: center; gap: 18px; min-height: 50px; margin-top: 8px; padding: 12px 18px; border: 2px solid #fff; border-radius: 12px; color: var(--ret-navy); background: #fff; font-weight: 900; text-decoration: none; }
.ret-cta > a:hover, .ret-cta > a:focus-visible { color: #fff; background: transparent; }

.ret-faq-intro { display: flex; justify-content: space-between; gap: 20px; margin-bottom: 14px; padding: 17px 20px; border-top: 3px solid var(--ret-gold); background: #fff; box-shadow: var(--ret-shadow); }
.ret-faq-intro span { color: var(--ret-gold-deep); font-size: .69rem; font-weight: 900; letter-spacing: .1em; text-transform: uppercase; }
.ret-faq-intro strong { color: var(--ret-navy); font-size: .88rem; text-align: right; }
.taxup-retencoes-saas details { border-bottom: 1px solid var(--ret-line); background: #fff; }
.taxup-retencoes-saas details:first-of-type { border-top: 1px solid var(--ret-line); }
.taxup-retencoes-saas summary { position: relative; padding: 20px 48px 20px 18px; color: var(--ret-navy); font-weight: 850; cursor: pointer; list-style: none; }
.taxup-retencoes-saas summary::-webkit-details-marker { display: none; }
.taxup-retencoes-saas summary::after { content: "+"; position: absolute; top: 17px; right: 18px; color: var(--ret-violet); font-size: 1.3rem; }
.taxup-retencoes-saas details[open] summary::after { content: "−"; }
.taxup-retencoes-saas details p { padding: 0 18px 20px; color: var(--ret-muted); }

.ret-sources { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin-bottom: 24px; }
.ret-sources a { display: block; min-height: 110px; padding: 20px; border: 1px solid var(--ret-line); border-radius: 15px; color: var(--ret-navy); background: #fff; box-shadow: var(--ret-shadow); text-decoration: none; }
.ret-sources a:hover { border-color: var(--ret-violet); transform: translateY(-1px); }
.ret-sources span { display: block; color: var(--ret-gold-deep); font-size: .65rem; font-weight: 900; letter-spacing: .1em; text-transform: uppercase; }
.ret-sources strong { display: block; margin-top: 10px; line-height: 1.3; }
.ret-disclaimer { padding: 20px 23px; border: 1px solid var(--ret-line); border-radius: 16px; color: var(--ret-muted); background: #fff; font-size: .82rem; }

.preview-footer { padding: 26px 24px; color: #d8d5e8; background: var(--ret-navy); font-size: .75rem; text-align: center; }

@media (max-width: 1050px) {
  .ret-hero__inner { grid-template-columns: 1fr; }
  .ret-hero-art { display: none; }
  .ret-layout { grid-template-columns: minmax(0, 800px); }
  .ret-toc { position: static; order: -1; padding: 20px; border: 1px solid var(--ret-line); border-radius: 16px; background: #fff; }
  .ret-toc ol { columns: 2; column-gap: 28px; }
}

@media (max-width: 780px) {
  .preview-main { padding-top: 42px; }
  .ret-premises, .ret-decision-flow, .ret-ops-grid, .ret-checklist { grid-template-columns: 1fr 1fr; }
  .ret-doc-chain { grid-template-columns: repeat(3, 1fr); }
  .ret-cases { grid-template-columns: 1fr; }
  .ret-matrix { grid-template-columns: 1fr 1fr; }
  .ret-timeline { grid-template-columns: 1fr 1fr; }
  .ret-timeline::before { display: none; }
  .ret-timeline > div { padding-top: 36px; }
  .ret-timeline > div::before { top: 6px; }
}

@media (max-width: 520px) {
  .preview-topbar { align-items: flex-start; }
  .preview-status { max-width: 180px; text-align: center; }
  .ret-hero__inner, .preview-main { width: calc(100% - 40px); }
  .ret-hero__inner { padding: 52px 0 56px; }
  .ret-hero h1 { font-size: clamp(2.35rem, 12.2vw, 2.8rem); line-height: 1.01; }
  .ret-hero__deck { font-size: 1rem; }
  .ret-layout { gap: 32px; }
  .ret-toc ol { columns: 1; }
  .taxup-retencoes-saas { font-size: 1rem; }
  .taxup-retencoes-saas > h2 { margin: 30px 0 15px; font-size: clamp(1.9rem, 9vw, 2.18rem); line-height: 1.07; }
  .taxup-retencoes-saas > h2:first-of-type { margin-top: 32px; }
  .ret-answer { padding: 24px 22px 22px; }
  .ret-figure__media {
    position: absolute !important;
    width: 1px !important;
    height: 1px !important;
    margin: -1px !important;
    overflow: hidden !important;
    clip: rect(0 0 0 0) !important;
    clip-path: inset(50%) !important;
  }
  .ret-figure__semantic {
    position: static !important;
    width: auto !important;
    height: auto !important;
    margin: 0 !important;
    padding: 0 !important;
    overflow: visible !important;
    clip: auto !important;
    clip-path: none !important;
    border: 0 !important;
  }
  .ret-year-compare { grid-template-columns: 1fr; }
  .ret-year-compare section { min-height: auto; padding: 28px 24px; }
  .ret-figure figcaption { border-top: 0; border-radius: 0 0 var(--ret-radius) var(--ret-radius); }
  .ret-premises, .ret-decision-flow, .ret-matrix, .ret-poles, .ret-thresholds, .ret-ops-grid, .ret-tool__form, .ret-checklist, .ret-sources { grid-template-columns: 1fr; }
  .ret-premises > div { min-height: auto; padding: 19px 20px; }
  .ret-decision-flow > div { min-height: auto; padding: 22px; }
  .ret-decision-flow > div:not(:last-child)::after { content: "↓"; top: auto; right: 50%; bottom: -21px; transform: translateX(50%); }
  .ret-figure figcaption { padding: 13px 15px; }
  .ret-compare-table > div { grid-template-columns: 1fr; padding: 16px 18px; border-bottom: 1px solid var(--ret-line); }
  .ret-compare-table > div > * { padding: 3px 0; border: 0; }
  .ret-compare-table__head { display: none !important; }
  .ret-compare-table > div span::before { display: inline-block; min-width: 54px; margin-right: 8px; color: var(--ret-gold-deep); font-size: .68rem; font-weight: 900; text-transform: uppercase; }
  .ret-compare-table > div span:nth-child(2)::before { content: "2026"; }
  .ret-compare-table > div span:nth-child(3)::before { content: "2027"; }
  .ret-asymmetry { grid-template-columns: 1fr; }
  .ret-asymmetry > div { min-height: 50px; }
  .ret-thresholds aside { grid-column: auto; }
  .ret-thresholds aside p { display: block; margin: 5px 0 0; }
  .ret-public-warning { padding: 27px 24px; }
  .ret-doc-chain { grid-template-columns: 1fr 1fr; }
  .ret-doc-chain > div { min-height: 122px; padding: 18px; }
  .ret-tool__head { padding: 26px 22px 22px; }
  .ret-tool__form { padding: 24px 22px; }
  .ret-tool__result { margin: 0 22px 20px; padding: 20px; }
  .ret-tool__privacy { margin: 0 22px 22px !important; }
  .ret-cases section { min-height: auto; }
  .ret-timeline { grid-template-columns: 1fr; padding: 24px; }
  .ret-checklist section { padding: 22px; }
  .ret-cta { margin-top: 34px; padding: 30px 24px; }
  .ret-cta > a { width: 100%; }
  .ret-faq-intro { display: block; }
  .ret-faq-intro strong { display: block; margin-top: 6px; text-align: left; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition-duration: .01ms !important; animation-duration: .01ms !important; }
}

.taxup-tech-owner-search-cover {
  position: absolute !important;
  width: 1px !important;
  height: 1px !important;
  overflow: hidden !important;
  clip: rect(0 0 0 0) !important;
  clip-path: inset(50%) !important;
  white-space: nowrap !important;
}

/* Premium v2: corpo editorial nativo do single.php, sem hero/sumario/CTA duplicados. */
.taxup-retencoes-saas--v2 {
  --ret-radius: 4px;
  --ret-shadow: 0 18px 46px rgba(13, 11, 62, .075);
  --ret-brand-surface:
    linear-gradient(135deg, transparent 0 53%, rgba(255, 255, 255, .11) 54% 61%, transparent 62%) top right / 92px 92px no-repeat,
    radial-gradient(circle at 100% 0%, rgba(91, 91, 240, .24), transparent 46%),
    linear-gradient(135deg, #211d61 0%, #0d0b3e 78%);
  --ret-paper-surface:
    linear-gradient(135deg, rgba(70, 65, 152, .055), transparent 32%),
    linear-gradient(135deg, transparent 0 82%, rgba(181, 151, 79, .06) 82% 100%),
    #fbfaf7;
}

body:has(.taxup-retencoes-saas--v2) {
  color: #17162c;
  background: #fff;
}

body:has(.taxup-retencoes-saas--v2) .editorial-post-hero .institucional-h1,
.taxup-retencoes-saas--v2 > h2,
.taxup-theme .editorial-post-content .taxup-retencoes-saas--v2 > h2,
.taxup-retencoes-saas--v2 h3,
.taxup-theme .editorial-post-content .taxup-retencoes-saas--v2 h3 {
  font-family: "Inter", -apple-system, BlinkMacSystemFont, sans-serif;
}

body:has(.taxup-retencoes-saas--v2) .editorial-post-hero .institucional-h1 {
  max-width: 18ch;
  font-family: "Inter", -apple-system, BlinkMacSystemFont, sans-serif !important;
  font-weight: 800 !important;
  line-height: 1.02 !important;
  letter-spacing: -.045em !important;
}

body:has(.taxup-retencoes-saas--v2) .editorial-post-hero-bg img {
  object-position: 86% 50% !important;
  transform: scale(1.18);
  transform-origin: right center;
}

.taxup-retencoes-saas--v2 > h2,
.taxup-retencoes-saas--v2 > h2:first-of-type,
.taxup-theme .editorial-post-content .taxup-retencoes-saas--v2 > h2,
.taxup-theme .editorial-post-content .taxup-retencoes-saas--v2 > h2:first-of-type {
  max-width: 25ch;
  margin: 36px 0 16px;
  padding-top: 0;
  border-top: 0;
  font-size: clamp(1.9rem, 3.4vw, 2.55rem);
  font-weight: 800;
  line-height: 1.08;
  letter-spacing: -.038em;
  text-wrap: balance;
}

.taxup-retencoes-saas--v2 h3,
.taxup-theme .editorial-post-content .taxup-retencoes-saas--v2 h3 {
  font-weight: 760;
  letter-spacing: -.025em;
}

.taxup-retencoes-saas--v2 .ret-answer {
  padding: 24px 26px;
  border: 1px solid var(--ret-line);
  border-top: 3px solid var(--ret-gold);
  border-left: 1px solid var(--ret-line);
  border-radius: 4px;
  background: var(--ret-paper-surface);
  box-shadow: none;
}

.taxup-theme .editorial-post-content .taxup-retencoes-saas--v2 .post-summary {
  margin: 22px 0 26px;
  padding: 25px 26px;
  border: 0;
  border-radius: 4px;
  color: #fff;
  background: var(--ret-brand-surface);
  box-shadow: var(--ret-shadow);
}

.taxup-theme .editorial-post-content .taxup-retencoes-saas--v2 .post-summary-label {
  color: #ead9a8;
}

.taxup-theme .editorial-post-content .taxup-retencoes-saas--v2 .post-summary p {
  color: #f5f1e6;
}

.taxup-retencoes-saas--v2 .ret-premises,
.taxup-retencoes-saas--v2 .ret-decision-flow > div,
.taxup-retencoes-saas--v2 .ret-figure__media img,
.taxup-retencoes-saas--v2 .ret-figure figcaption,
.taxup-retencoes-saas--v2 .ret-source-note,
.taxup-retencoes-saas--v2 .ret-compare-table,
.taxup-retencoes-saas--v2 .ret-asymmetry,
.taxup-retencoes-saas--v2 .ret-poles section,
.taxup-retencoes-saas--v2 .ret-thresholds,
.taxup-retencoes-saas--v2 .ret-public-warning,
.taxup-retencoes-saas--v2 .ret-doc-chain,
.taxup-retencoes-saas--v2 .ret-ops-grid > div,
.taxup-retencoes-saas--v2 .ret-tool,
.taxup-retencoes-saas--v2 .ret-cases section,
.taxup-retencoes-saas--v2 .ret-timeline,
.taxup-retencoes-saas--v2 .ret-checklist section,
.taxup-retencoes-saas--v2 .ret-faq-intro,
.taxup-retencoes-saas--v2 .ret-sources a,
.taxup-retencoes-saas--v2 .ret-disclaimer {
  border-radius: 4px;
}

.taxup-retencoes-saas--v2 .ret-premises,
.taxup-retencoes-saas--v2 .ret-decision-flow,
.taxup-retencoes-saas--v2 .ret-figure,
.taxup-retencoes-saas--v2 .ret-compare-table,
.taxup-retencoes-saas--v2 .ret-asymmetry,
.taxup-retencoes-saas--v2 .ret-poles,
.taxup-retencoes-saas--v2 .ret-thresholds,
.taxup-retencoes-saas--v2 .ret-public-warning,
.taxup-retencoes-saas--v2 .ret-doc-chain,
.taxup-retencoes-saas--v2 .ret-ops-grid,
.taxup-retencoes-saas--v2 .ret-tool,
.taxup-retencoes-saas--v2 .ret-cases,
.taxup-retencoes-saas--v2 .ret-timeline,
.taxup-retencoes-saas--v2 .ret-checklist,
.taxup-retencoes-saas--v2 .ret-sources {
  margin-bottom: clamp(26px, 2.6vw, 34px);
}

.taxup-retencoes-saas--v2 .ret-public-warning,
.taxup-retencoes-saas--v2 .ret-tool__head,
.taxup-retencoes-saas--v2 .ret-thresholds aside {
  background: var(--ret-brand-surface);
}

.taxup-retencoes-saas--v2 .ret-public-warning,
.taxup-retencoes-saas--v2 .ret-public-warning strong,
.taxup-retencoes-saas--v2 .ret-tool__head,
.taxup-retencoes-saas--v2 .ret-tool__head h3,
.taxup-retencoes-saas--v2 .ret-thresholds aside,
.taxup-retencoes-saas--v2 .ret-thresholds aside strong {
  color: #fff;
}

.taxup-retencoes-saas--v2 .ret-public-warning p,
.taxup-retencoes-saas--v2 .ret-tool__head p,
.taxup-retencoes-saas--v2 .ret-thresholds aside p {
  color: #f5f1e6;
  opacity: 1;
}

.taxup-retencoes-saas--v2 .ret-faq-intro {
  border: 0;
  color: #fff;
  background: var(--ret-brand-surface);
}

.taxup-retencoes-saas--v2 .ret-faq-intro span,
.taxup-retencoes-saas--v2 .ret-faq-intro strong {
  color: #f5f1e6;
}

body:has(.taxup-retencoes-saas--v2) .post-faq__item {
  margin: 0;
  border-color: var(--ret-line);
  border-radius: 0;
  box-shadow: none;
}

body:has(.taxup-retencoes-saas--v2) .post-faq__item:first-of-type {
  margin-top: 12px;
  border-top: 3px solid var(--ret-gold);
  border-radius: 4px 4px 0 0;
}

body:has(.taxup-retencoes-saas--v2) .post-faq__item:last-of-type {
  border-radius: 0 0 4px 4px;
}

body:has(.taxup-retencoes-saas--v2) .editorial-post-cta--close {
  border-radius: 6px;
  color: #fff;
  background: var(--ret-brand-surface);
}

body:has(.taxup-retencoes-saas--v2) .editorial-post-cta--close h3 {
  color: #fff;
  font-family: "Inter", -apple-system, BlinkMacSystemFont, sans-serif;
  font-weight: 800;
  line-height: 1.12;
  letter-spacing: -.035em;
}

body:has(.taxup-retencoes-saas--v2) .editorial-post-cta--close p,
body:has(.taxup-retencoes-saas--v2) .editorial-post-cta--close .editorial-post-cta-micro {
  color: #f5f1e6;
  opacity: 1;
}

body:has(.taxup-retencoes-saas--v2) .editorial-post-cta--close .btn-primary,
body:has(.taxup-retencoes-saas--v2) .editorial-post-cta--close .btn-primary--lg {
  border-color: #fff !important;
  color: #0d0b3e !important;
  background: #fff !important;
  box-shadow: 0 8px 20px rgba(0, 0, 0, .18);
}

body:has(.taxup-retencoes-saas--v2) .editorial-post-cta--close .btn-primary:hover,
body:has(.taxup-retencoes-saas--v2) .editorial-post-cta--close .btn-primary:focus-visible {
  color: #fff !important;
  background: transparent !important;
}

@media (max-width: 980px) {
  .taxup-retencoes-saas--v2 .ret-year-compare section,
  .taxup-retencoes-saas--v2 .ret-asymmetry section,
  .taxup-retencoes-saas--v2 .ret-poles section,
  .taxup-retencoes-saas--v2 .ret-thresholds section,
  .taxup-retencoes-saas--v2 .ret-cases section,
  .taxup-retencoes-saas--v2 .ret-checklist section {
    min-height: 0;
    padding: 24px 22px !important;
  }

  body:has(.taxup-retencoes-saas--v2) .editorial-post-author-box,
  body:has(.taxup-retencoes-saas--v2) .cluster-related-explore {
    width: auto;
    margin-right: 20px;
    margin-left: 20px;
  }

  body:has(.taxup-retencoes-saas--v2) .editorial-post-author-box {
    padding: clamp(30px, 4vw, 40px) clamp(24px, 4vw, 36px) !important;
  }

  body:has(.taxup-retencoes-saas--v2) .cluster-related-explore {
    padding-top: 32px !important;
    padding-bottom: 24px !important;
  }

  body:has(.taxup-retencoes-saas--v2) .editorial-post-cta--close {
    width: auto !important;
    margin: 12px 20px 0 !important;
    padding: clamp(36px, 5vw, 48px) clamp(24px, 4vw, 36px) !important;
  }
}

@media (min-width: 981px) {
  body:has(.taxup-retencoes-saas--v2) .editorial-post-hero .institucional-hero-inner,
  body:has(.taxup-retencoes-saas--v2) .editorial-post-body.wrap {
    width: 100%;
    max-width: none;
    padding-right: clamp(32px, 4vw, 72px);
    padding-left: clamp(32px, 4vw, 72px);
  }

  body:has(.taxup-retencoes-saas--v2) .editorial-post-layout,
  body:has(.taxup-retencoes-saas--v2) .editorial-post-author-box,
  body:has(.taxup-retencoes-saas--v2) .cluster-related-explore,
  body:has(.taxup-retencoes-saas--v2) .editorial-post-cta--close {
    width: 100%;
    max-width: 1760px;
    margin-right: auto;
    margin-left: auto;
  }

  body:has(.taxup-retencoes-saas--v2) .editorial-post-layout {
    grid-template-columns: clamp(220px, 15vw, 250px) minmax(0, 1fr);
    gap: clamp(40px, 4vw, 72px);
  }
}

@media (min-width: 1600px) {
  .taxup-retencoes-saas--v2 > p,
  .taxup-retencoes-saas--v2 > ul,
  .taxup-retencoes-saas--v2 > ol {
    max-width: 1040px;
  }
}

@media (max-width: 720px) {
  body:has(.taxup-retencoes-saas--v2) .editorial-post-hero .institucional-h1 {
    max-width: none;
    font-size: clamp(2rem, 9.2vw, 2.7rem) !important;
  }

  body:has(.taxup-retencoes-saas--v2) .editorial-post-hero-bg img {
    object-position: 82% 50% !important;
    transform: scale(1.08);
  }

  .taxup-retencoes-saas--v2 > h2,
  .taxup-retencoes-saas--v2 > h2:first-of-type,
  .taxup-theme .editorial-post-content .taxup-retencoes-saas--v2 > h2,
  .taxup-theme .editorial-post-content .taxup-retencoes-saas--v2 > h2:first-of-type {
    margin-top: 28px;
    margin-bottom: 14px;
    font-size: clamp(1.7rem, 8vw, 2.05rem);
    line-height: 1.1;
  }

  .taxup-theme .editorial-post-content .taxup-retencoes-saas--v2 p {
    text-align: left;
    hyphens: none;
  }

  .taxup-retencoes-saas--v2 .ret-answer {
    padding: 21px 19px;
  }

  .taxup-retencoes-saas--v2 .ret-premises > div,
  .taxup-retencoes-saas--v2 .ret-decision-flow > div,
  .taxup-retencoes-saas--v2 .ret-doc-chain > div,
  .taxup-retencoes-saas--v2 .ret-ops-grid > div,
  .taxup-retencoes-saas--v2 .ret-sources a {
    padding-right: 20px;
    padding-left: 20px;
  }

  body:has(.taxup-retencoes-saas--v2) .editorial-post-cta--close {
    width: auto !important;
    margin: 12px 20px 0 !important;
    padding: 36px 24px !important;
  }

  body:has(.taxup-retencoes-saas--v2) .editorial-post-cta--close .btn-primary,
  body:has(.taxup-retencoes-saas--v2) .editorial-post-cta--close .btn-primary--lg {
    width: 100%;
    max-width: 100%;
    justify-content: center;
    text-align: center;
  }
}
