/* =========================================================
   Winndex - Terms Page (style)
   Arquivo: /assets/css/wx-terms.css
   Isolado: só classes wx-terms__*
   ========================================================= */

.wx-terms{
  width: 100%;
  padding: 28px 16px 56px;
}

.wx-terms__wrap{
  width: min(1120px, 100%);
  margin: 0 auto;

  display: grid;
  grid-template-columns: 280px minmax(0, 1fr);
  gap: 32px;
  align-items: start;
}

/* -----------------------------
   Sidebar / Sumário (sticky)
------------------------------ */
.wx-terms__toc{
  grid-column: 1;
  align-self: start;

  position: sticky;
  top: 96px; /* ajuste conforme altura real da sua navbar */

  max-height: calc(100vh - 120px);
  overflow-y: auto;

  padding: 14px;
  border-radius: 0px;
  border: 0px solid #e5e7eb;

  background: #f6f7f9;
}

.wx-terms__tocTitle{
  margin: 0 0 10px;
  font-size: 13px;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: #6b7280;
}

.wx-terms__tocList{
  list-style: none;
  padding: 0;
  margin: 0;

  display: grid;
  gap: 6px;
}

/* Scrollbar discreta */
.wx-terms__toc::-webkit-scrollbar{ width: 6px; }
.wx-terms__toc::-webkit-scrollbar-thumb{
  background: rgba(0,0,0,.14);
  border-radius: 999px;
}
.wx-terms__toc::-webkit-scrollbar-track{ background: transparent; }

/* Links */
.wx-terms__link{
  display: block;
  padding: 8px 10px;
  border-radius: 10px;
  text-decoration: none;
  color: #374151;
  background: transparent;
  transition: background-color .15s ease, color .15s ease, transform .05s ease;
}
.wx-terms__link:hover{ background: #eef2f6; }
.wx-terms__link:active{ transform: translateY(1px); }

.wx-terms__link.is-active{
  background: #e7f0ff;
  color: #0b5ed7;
  font-weight: 600;
}

/* -----------------------------
   Coluna direita (conteúdo)
------------------------------ */
.wx-terms__content{
  grid-column: 2;
  min-width: 0;
}

/* Header */
.wx-terms__header{
  padding: 18px 18px;
  margin: 0 0 12px 0; /* reduz “vão” visual */
  margin-bottom: 50px;
  background-color: beige;
}

.wx-terms__title{
  margin: 0 0 10px;
  font-size: 28px;
  line-height: 1.15;
  letter-spacing: -0.02em;
  color: #111827;

  width: 100%;
  display: block;
}

.wx-terms__meta{
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
  color: #6b7280;
  font-size: 13px;
}

.wx-terms__dot{ opacity: .65; }

.wx-terms__lead{
  margin: 14px 0 0;
  color: #374151;
  line-height: 1.6;
}

/* Notice legal (suave mas chamativo) */
.wx-terms__notice{
  margin: 14px 0 0;
  padding: 14px 16px;
  border-radius: 12px;

  background: linear-gradient(90deg,
    rgba(240, 244, 248, 0.95),
    rgba(248, 250, 252, 0.95)
  );

  border: 1px solid rgba(91,124,250,.22);
  border-left: 4px solid #5b7cfa;

  color: #1f2937;
  font-size: 0.95rem;
  line-height: 1.55;

  box-shadow: 0 2px 6px rgba(0,0,0,0.04);
  animation: wxNoticeFade 0.35s ease-out both;
}

.wx-terms__notice strong{
  color: #374151;
  font-weight: 700;
}

@keyframes wxNoticeFade{
  from { opacity: 0; transform: translateY(-4px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* -----------------------------
   Seções (agora dentro de wx-terms__content)
   - aqui tiramos o “vão” percebido com padding/margem controlados
------------------------------ */
.wx-terms__section{
  padding: 10px 18px 0; /* menor no topo para “colar” após o header */
  margin: 0;
  scroll-margin-top: 110px;
}

/* Ajuste fino: primeira seção mais colada ainda */
.wx-terms__section:first-of-type{
  padding-top: 6px;
}

.wx-terms__h2{
  margin: 0 0 10px;
  font-size: 18px;
  line-height: 1.25;
  color: #111827;
}

.wx-terms__p{
  margin: 0 0 14px;
  line-height: 1.65;
  font-size: 0.95rem;
  color: #374151;

  text-align: justify;
  text-justify: inter-word;

  hyphens: auto;
  -webkit-hyphens: auto;
  -ms-hyphens: auto;
}

.wx-terms__list{
  margin: 0 0 14px;
  padding-left: 18px;
  color: #374151;
  line-height: 1.75;
}

.wx-terms__list li{ margin: 6px 0; }

/* -----------------------------
   Ações / botões
------------------------------ */
.wx-terms__actions{
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 14px;
}

.wx-terms__btn{
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 10px 14px;
  border-radius: 12px;
  border: 1px solid #d1d5db;
  background: #fff;
  color: #111827;
  text-decoration: none;
  font-weight: 600;
  transition: transform .05s ease, filter .15s ease, background-color .15s ease;
}
.wx-terms__btn:hover{ filter: brightness(0.98); }
.wx-terms__btn:active{ transform: translateY(1px); }

.wx-terms__btn--primary{
  border-color: transparent;
  background: #0b5ed7;
  color: #fff;
}

/* Rodapé */
.wx-terms__footer{
  padding: 22px 18px 0;
}

.wx-terms__small{
  margin: 0;
  color: #6b7280;
  font-size: 13px;
}

/* -----------------------------
   Responsivo
------------------------------ */
@media (max-width: 900px){
  .wx-terms__wrap{
    grid-template-columns: 1fr;
    gap: 16px;
  }

  .wx-terms__toc{
    position: static;
    max-height: none;
    overflow: visible;
  }

  .wx-terms__content{
    grid-column: 1;
  }

  .wx-terms__header,
  .wx-terms__section,
  .wx-terms__footer{
    padding-left: 18px;
    padding-right: 18px;
  }

  .wx-terms__section{
    scroll-margin-top: 90px;
  }
}

/* Menos animação */
@media (prefers-reduced-motion: reduce){
  .wx-terms__link,
  .wx-terms__btn,
  .wx-terms__notice{
    transition: none;
    animation: none;
  }
}
