/* ========================================================================
   NIMBER — PÁGINAS JURÍDICAS
   Base Bootstrap + componentes isolados.
   Container útil: 1476px + padding externo.
   ======================================================================== */

.nimber-terms-page {
  --container: 1476px;
  --terms-gutter: clamp(20px, 3vw, 48px);
  --terms-ink: #172432;
  --terms-blue: #5186a7;
  --terms-cyan: #00b9f2;
  --terms-soft-blue: #dcecf6;
  --terms-border: rgba(23, 36, 50, .24);
  color: var(--terms-ink);
}

.nimber-terms-page .terms-page-container {
  width: 100%;
  max-width: calc(var(--container) + (var(--terms-gutter) * 2));
  margin-inline: auto;
  padding-inline: var(--terms-gutter);
}

.nimber-terms-page .terms-hero > .terms-page-container {
  max-width: calc(var(--container-wide) + (var(--terms-gutter) * 2));
}

/* Header sólido --------------------------------------------------------- */
body.nimber-terms-page .site-header::before,
body.nimber-terms-page .site-header.is-scrolled::before {
  border-bottom-color: rgba(81, 134, 167, .10);
  background: rgba(255, 255, 255, .985);
  box-shadow: 0 10px 28px rgba(23, 36, 50, .06);
  opacity: 1;
}

html.js.nimber-hero-booting body.nimber-terms-page .terms-hero__title {
  opacity: 0;
  visibility: hidden;
}

/* Hero ----------------------------------------------------------------- */
.nimber-terms-page .terms-hero {
  position: relative;
  min-height: 430px;
  padding-top: 146px;
  overflow: hidden;
  color: #fff;
  background: #1d2c3a;
  isolation: isolate;
}

.nimber-terms-page .terms-hero::after {
  content: "";
  position: absolute;
  z-index: -1;
  inset: 0;
  background: linear-gradient(90deg, rgba(19, 33, 45, .17), rgba(19, 33, 45, 0) 65%);
  pointer-events: none;
}

.nimber-terms-page .terms-hero__background {
  position: absolute;
  z-index: -2;
  inset: 0;
  width: 100%;
  height: 100%;
  max-width: none;
  object-fit: cover;
  object-position: center;
  transform: scale(1.01);
  will-change: transform;
}

.nimber-terms-page .terms-hero__row {
  min-height: 284px;
  padding-block: 48px;
}

.nimber-terms-page .terms-hero__title {
  max-width: 900px;
  margin: 0;
  color: #fff;
  font-size: clamp(34px, 3vw, 48px);
  font-weight: 600;
  line-height: 1.1;
  letter-spacing: -.035em;
}

/* Conteúdo + sidebar ---------------------------------------------------- */
.nimber-terms-page .terms-content {
  padding: clamp(66px, 6.5vw, 104px) 0 clamp(76px, 8vw, 130px);
  background: #fff;
}

.nimber-terms-page .terms-content > .terms-page-container {
  max-width: calc(var(--container-wide) + (var(--terms-gutter) * 2));
}

.nimber-terms-page .terms-content__row {
  align-items: stretch;
}

.nimber-terms-page .terms-sidebar-column {
  align-self: stretch;
}

.nimber-terms-page .terms-sidebar {
  position: -webkit-sticky;
  position: sticky;
  top: 112px;
  z-index: 5;
  height: max-content;
  padding-right: clamp(26px, 3vw, 52px);
}

.nimber-terms-page .terms-sidebar__nav {
  padding: 6px 0 10px;
  border-right: 1px solid var(--terms-border);
}

.nimber-terms-page .terms-sidebar__nav ol {
  display: grid;
  gap: 12px;
  padding-right: clamp(20px, 2vw, 34px);
}

.nimber-terms-page .terms-sidebar__nav a {
  position: relative;
  display: block;
  padding: 7px 0 7px 17px;
  color: #273845;
  font-size: 16px;
  font-weight: 500;
  line-height: 1.35;
  text-transform: uppercase;
  letter-spacing: .035em;
  transition: color .28s ease, transform .28s cubic-bezier(.22, 1, .36, 1);
}

.nimber-terms-page .terms-sidebar__nav a::before {
  content: "";
  position: absolute;
  top: 50%;
  left: 0;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: transparent;
  transform: translateY(-50%) scale(.4);
  transition: background-color .28s ease, transform .28s cubic-bezier(.22, 1, .36, 1);
}

.nimber-terms-page .terms-sidebar__nav a.is-active,
.nimber-terms-page .terms-sidebar__nav a[aria-current="location"] {
  color: var(--terms-blue);
  transform: translateX(4px);
}

.nimber-terms-page .terms-sidebar__nav a.is-active::before,
.nimber-terms-page .terms-sidebar__nav a[aria-current="location"]::before {
  background: var(--terms-cyan);
  transform: translateY(-50%) scale(1);
}

@media (hover: hover) and (pointer: fine) {
  .nimber-terms-page .terms-sidebar__nav a:hover,
  .nimber-terms-page .terms-sidebar__nav a:focus-visible {
    color: var(--terms-blue);
    transform: translateX(4px);
  }
}

.nimber-terms-page .terms-article {
  padding-left: clamp(10px, 1.2vw, 24px);
}

.nimber-terms-page .terms-article-section {
  scroll-margin-top: 132px;
}

.nimber-terms-page .terms-article-section + .terms-article-section {
  margin-top: clamp(54px, 5.5vw, 88px);
}

.nimber-terms-page .terms-article-section h2 {
  margin: 0 0 clamp(18px, 2vw, 28px);
  color: var(--terms-blue);
  font-size: clamp(25px, 2.25vw, 38px);
  font-weight: 600;
  line-height: 1.15;
  letter-spacing: -.035em;
}

.nimber-terms-page .terms-article-section p {
  margin: 0;
  color: #27343f;
  font-size: 18px;
  font-weight: 400;
  line-height: 1.72;
}

.nimber-terms-page .terms-article-section p + p {
  margin-top: clamp(19px, 2vw, 30px);
}

/* Faixa da central de ajuda -------------------------------------------- */
.nimber-terms-page .terms-help {
  position: relative;
  z-index: 2;
  padding: clamp(34px, 3.4vw, 47px) 0;
  background: linear-gradient(90deg, #d7eaf6 0%, #bcd8ea 100%);
  box-shadow: 0 -18px 38px rgba(81, 134, 167, .16), 0 18px 38px rgba(81, 134, 167, .18);
}

.nimber-terms-page .terms-help > .terms-page-container {
  max-width: calc(var(--container) + (var(--terms-gutter) * 2));
}

.nimber-terms-page .terms-help__title {
  color: #101820;
  font-size: clamp(24px, 2.4vw, 40px);
  font-weight: 600;
  line-height: 1.18;
  letter-spacing: -.03em;
}

.nimber-terms-page .terms-help__button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: min(100%, 330px);
  min-height: 58px;
  padding: 14px 30px;
  border: 1px solid rgba(255, 255, 255, .16);
  border-radius: 999px;
  color: #fff;
  background: linear-gradient(90deg, #172432 0%, #294b61 100%);
  box-shadow: 0 12px 28px rgba(23, 36, 50, .16);
  font-size: 10px;
  font-weight: 500;
  line-height: 1;
  letter-spacing: .25em;
  text-align: center;
  text-transform: uppercase;
  transition: transform .35s cubic-bezier(.22, 1, .36, 1), box-shadow .35s ease, filter .35s ease;
}

@media (hover: hover) and (pointer: fine) {
  .nimber-terms-page .terms-help__button:hover,
  .nimber-terms-page .terms-help__button:focus-visible {
    color: #fff;
    transform: translateY(-2px);
    filter: brightness(1.05);
    box-shadow: 0 16px 34px rgba(23, 36, 50, .22);
  }
}



/* Faixa de download do Código de Ética -------------------------------- */
.nimber-terms-page .terms-download {
  position: relative;
  z-index: 2;
  padding: clamp(30px, 3vw, 48px) 0;
  background: linear-gradient(90deg, #d7eaf6 0%, #b7d5e8 100%);
  box-shadow: 0 -18px 38px rgba(81, 134, 167, .15), 0 18px 38px rgba(81, 134, 167, .18);
}

.nimber-terms-page .terms-download__title {
  margin: 0;
  color: #172432;
  font-size: clamp(23px, 2.25vw, 37px);
  font-weight: 600;
  line-height: 1.2;
  letter-spacing: -.03em;
}

.nimber-terms-page .terms-download__button {
  display: inline-flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  width: min(100%, 360px);
  min-height: 58px;
  padding: 13px 18px 13px 30px;
  border: 1px solid rgba(255, 255, 255, .18);
  border-radius: 999px;
  color: #fff;
  background: linear-gradient(90deg, #172432 0%, #4b86a8 100%);
  box-shadow: 0 12px 28px rgba(23, 36, 50, .16);
  font-size: 10px;
  font-weight: 500;
  line-height: 1;
  letter-spacing: .25em;
  text-align: center;
  text-transform: uppercase;
  transition: transform .35s cubic-bezier(.22, 1, .36, 1), box-shadow .35s ease, filter .35s ease;
}

.nimber-terms-page .terms-download__icon {
  display: inline-flex;
  flex: 0 0 42px;
  align-items: center;
  justify-content: center;
  width: 42px;
  height: 34px;
  border-radius: 999px;
  color: #fff;
  font-size: 20px;
}

.nimber-code-page .terms-hero__title {
  max-width: 560px;
}

@media (hover: hover) and (pointer: fine) {
  .nimber-terms-page .terms-download__button:hover,
  .nimber-terms-page .terms-download__button:focus-visible {
    color: #fff;
    transform: translateY(-2px);
    filter: brightness(1.05);
    box-shadow: 0 16px 34px rgba(23, 36, 50, .22);
  }
}

@media (max-width: 767.98px) {
  .nimber-terms-page .terms-download {
    text-align: center;
  }

  .nimber-terms-page .terms-download__button {
    width: 100%;
    max-width: 360px;
  }
}

/* Future CTA e newsletter ---------------------------------------------- */
.nimber-terms-page .terms-future-cta {
  z-index: 1;
}

.nimber-terms-page .newsletter--terms {
  padding-top: clamp(82px, 7vw, 118px);
}

/* Responsividade -------------------------------------------------------- */
@media (max-width: 1199.98px) {
  .nimber-terms-page .terms-sidebar {
    padding-right: 18px;
  }

  .nimber-terms-page .terms-sidebar__nav ol {
    padding-right: 18px;
  }
}

@media (max-width: 991.98px) {
  .nimber-terms-page .terms-hero {
    min-height: 360px;
    padding-top: 112px;
  }

  .nimber-terms-page .terms-hero__row {
    min-height: 248px;
    padding-block: 38px;
  }

  .nimber-terms-page .terms-content {
    padding-top: 42px;
  }

  .nimber-terms-page .terms-sidebar {
    position: -webkit-sticky;
    position: sticky;
    top: 86px;
    height: auto;
    z-index: 12;
    margin: 0 calc(var(--terms-gutter) * -1) 44px;
    padding: 12px var(--terms-gutter);
    background: rgba(255, 255, 255, .96);
    box-shadow: 0 10px 24px rgba(23, 36, 50, .07);
    backdrop-filter: blur(12px);
  }

  .nimber-terms-page .terms-sidebar__nav {
    overflow-x: auto;
    border-right: 0;
    scrollbar-width: none;
  }

  .nimber-terms-page .terms-sidebar__nav::-webkit-scrollbar {
    display: none;
  }

  .nimber-terms-page .terms-sidebar__nav ol {
    display: flex;
    gap: 12px;
    width: max-content;
    padding: 0;
  }

  .nimber-terms-page .terms-sidebar__nav a {
    min-width: max-content;
    padding: 9px 16px;
    border: 1px solid rgba(81, 134, 167, .20);
    border-radius: 999px;
    background: #fff;
    text-transform: none;
  }

  .nimber-terms-page .terms-sidebar__nav a::before {
    display: none;
  }

  .nimber-terms-page .terms-sidebar__nav a.is-active,
  .nimber-terms-page .terms-sidebar__nav a[aria-current="location"] {
    color: #fff;
    background: linear-gradient(90deg, #294b61, #5792b4);
    transform: none;
  }

  .nimber-terms-page .terms-article {
    padding-left: 0;
  }

  .nimber-terms-page .terms-article-section {
    scroll-margin-top: 164px;
  }
}

@media (max-width: 767.98px) {
  .nimber-terms-page .terms-hero {
    min-height: 320px;
    padding-top: 96px;
  }

  .nimber-terms-page .terms-hero__row {
    min-height: 224px;
    padding-block: 34px;
  }

  .nimber-terms-page .terms-hero__background {
    object-position: 66% center;
  }

  .nimber-terms-page .terms-content {
    padding-bottom: 76px;
  }

  .nimber-terms-page .terms-help {
    text-align: center;
  }

  .nimber-terms-page .terms-help__button {
    width: 100%;
    max-width: 340px;
  }
}

@media (max-width: 479.98px) {
  .nimber-terms-page {
    --terms-gutter: 18px;
  }

  .nimber-terms-page .terms-hero {
    min-height: 286px;
  }

  .nimber-terms-page .terms-hero__row {
    min-height: 190px;
  }

  .nimber-terms-page .terms-sidebar {
    top: 78px;
  }

  .nimber-terms-page .terms-article-section {
    scroll-margin-top: 152px;
  }

  .nimber-terms-page .terms-article-section + .terms-article-section {
    margin-top: 48px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .nimber-terms-page .terms-hero__background,
  .nimber-terms-page .terms-sidebar__nav a,
  .nimber-terms-page .terms-help__button,
  .nimber-terms-page .terms-download__button {
    transition: none !important;
  }
}

.nimber-terms-page .terms-anchor {
  display: block;
  width: 1px;
  height: 1px;
  scroll-margin-top: 132px;
}

@media (max-width: 991.98px) {
  .nimber-terms-page .terms-anchor { scroll-margin-top: 164px; }
}

/* Fase 9.12 — documentos estruturados e estados dinâmicos --------------- */
.nimber-terms-page .terms-content__row--without-sidebar {
  justify-content: center;
}

.nimber-terms-page .terms-article--centered {
  width: 100%;
  max-width: 1120px;
  margin-inline: auto;
  padding-left: 0;
}

.nimber-terms-page .terms-article__updated {
  margin: 0 0 clamp(30px, 3vw, 46px);
  color: #5c6b76;
  font-size: 14px;
  font-weight: 500;
  line-height: 1.5;
  letter-spacing: .02em;
}

.nimber-terms-page .terms-article-section--continuation {
  margin-top: clamp(19px, 2vw, 30px) !important;
}

.nimber-terms-page .terms-article-section__content > :first-child {
  margin-top: 0;
}

.nimber-terms-page .terms-article-section__content > :last-child {
  margin-bottom: 0;
}

.nimber-terms-page .terms-article-section :is(p, li, blockquote, td, th) {
  color: #27343f;
  font-size: 18px;
  font-weight: 400;
  line-height: 1.72;
}

.nimber-terms-page .terms-article-section :is(p, ul, ol, blockquote, table) + :is(p, ul, ol, blockquote, table) {
  margin-top: clamp(19px, 2vw, 30px);
}

.nimber-terms-page .terms-article-section :is(ul, ol) {
  display: grid;
  gap: 10px;
  margin-bottom: 0;
  padding-left: 1.35em;
}

.nimber-terms-page .terms-article-section h3 {
  margin: clamp(28px, 3vw, 44px) 0 14px;
  color: #273845;
  font-size: clamp(21px, 1.8vw, 29px);
  font-weight: 600;
  line-height: 1.25;
}

.nimber-terms-page .terms-article-section h4 {
  margin: 24px 0 12px;
  color: #273845;
  font-size: clamp(18px, 1.4vw, 23px);
  font-weight: 600;
  line-height: 1.3;
}

.nimber-terms-page .terms-article-section a {
  color: var(--terms-blue);
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
}

.nimber-terms-page .terms-article-section blockquote {
  margin-inline: 0;
  padding: 18px 22px;
  border-left: 4px solid var(--terms-blue);
  background: rgba(220, 236, 246, .42);
}

.nimber-terms-page .terms-article-section .wp-block-table,
.nimber-terms-page .terms-article-section table {
  width: 100%;
  overflow-x: auto;
  border-collapse: collapse;
}

.nimber-terms-page .terms-article-section :is(th, td) {
  padding: 13px 15px;
  border: 1px solid rgba(23, 36, 50, .16);
  vertical-align: top;
}

.nimber-terms-page .terms-article-section th {
  color: #172432;
  background: rgba(220, 236, 246, .55);
  font-weight: 600;
}

.nimber-terms-page .terms-download__row--without-title .terms-download__button {
  margin-inline: auto;
}

@media (max-width: 991.98px) {
  .nimber-terms-page .terms-sidebar__nav ol {
    margin-inline: auto;
  }
}

@media (max-width: 767.98px) {
  .nimber-terms-page .terms-article-section :is(p, li, blockquote, td, th) {
    font-size: 16px;
  }

  .nimber-terms-page .terms-article-section .wp-block-table,
  .nimber-terms-page .terms-article-section table {
    display: block;
    max-width: 100%;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
  }
}
