/* ==========================================================================
   LEGAL PAGES — Política de Privacidade & Termos de Uso
   ========================================================================== */

.legal-hero {
  background: var(--gradient-hero);
  padding: 5rem 0 3.75rem;
  color: var(--primary-foreground);
}
.legal-hero .container { max-width: 1280px; }
.legal-hero .section-tag {
  background: rgba(255, 255, 255, 0.14);
  color: #fff;
  border-color: rgba(255, 255, 255, 0.25);
}
.legal-hero h1 {
  font-size: clamp(1.85rem, 4vw, 2.6rem);
  font-weight: 800;
  color: #fff;
  margin: 0.85rem 0 0.65rem;
  letter-spacing: -0.015em;
  line-height: 1.15;
}
.legal-hero p {
  color: rgba(255, 255, 255, 0.85);
  font-size: 1.05rem;
  line-height: 1.6;
  max-width: 56ch;
  margin: 0;
}
.legal-updated {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  margin-top: 1.5rem;
  font-size: 0.82rem;
  font-weight: 600;
  color: rgba(255, 255, 255, 0.78);
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.2);
  padding: 0.45rem 0.95rem;
  border-radius: 999px;
}

.legal-body {
  background: var(--background);
  padding: 4rem 0 5.5rem;
}
.legal-layout {
  max-width: 1280px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr 240px;
  gap: 3.5rem;
  align-items: start;
}
@media (max-width: 760px) {
  .legal-layout { grid-template-columns: 1fr; gap: 2.25rem; }
}

/* ── Índice lateral (à direita do conteúdo) ── */
.legal-toc {
  order: 2;
  position: sticky;
  top: 1.75rem;
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
}
.legal-toc-label {
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.09em;
  text-transform: uppercase;
  color: var(--muted-foreground);
  margin-bottom: 0.85rem;
}
.legal-toc a {
  font-size: 0.87rem;
  font-weight: 500;
  color: var(--muted-foreground);
  text-decoration: none;
  padding: 0.42rem 0;
  border-left: 2px solid var(--border);
  padding-left: 0.85rem;
  transition: color var(--transition-fast), border-color var(--transition-fast);
  line-height: 1.4;
}
.legal-toc a:hover { color: var(--primary); border-left-color: var(--primary); }
@media (max-width: 760px) {
  .legal-toc { position: static; flex-direction: row; flex-wrap: wrap; gap: 0.5rem; }
  .legal-toc a { border-left: none; padding: 0.4rem 0.85rem; background: var(--secondary); border-radius: 999px; }
}

/* ── Conteúdo ── */
.legal-content { order: 1; min-width: 0; }
.legal-content section {
  padding-bottom: 2.75rem;
  margin-bottom: 2.75rem;
  border-bottom: 1px solid var(--border);
  scroll-margin-top: 1.75rem;
}
.legal-content section:last-child {
  padding-bottom: 0;
  margin-bottom: 0;
  border-bottom: none;
}
.legal-content h2 {
  font-size: 1.4rem;
  font-weight: 800;
  color: var(--foreground);
  margin: 0 0 1.25rem;
  display: flex;
  align-items: center;
  gap: 0.7rem;
}
.legal-content h2 .legal-num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background: color-mix(in srgb, var(--primary) 10%, transparent);
  color: var(--primary);
  font-size: 0.78rem;
  font-weight: 800;
  flex-shrink: 0;
}
.legal-content h3 {
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--foreground);
  margin: 1.85rem 0 0.75rem;
}
.legal-content h3:first-child { margin-top: 0; }
.legal-content p {
  font-size: 1rem;
  line-height: 1.8;
  color: var(--secondary-foreground);
  margin: 0 0 1.25rem;
  max-width: 68ch;
}
.legal-content p:last-child { margin-bottom: 0; }
.legal-content ul {
  margin: 0 0 1.25rem;
  padding-left: 1.2rem;
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
  max-width: 68ch;
}
.legal-content ul:last-child { margin-bottom: 0; }
.legal-content li {
  font-size: 1rem;
  line-height: 1.7;
  color: var(--secondary-foreground);
}
.legal-content li strong,
.legal-content p strong { color: var(--foreground); }
.legal-content a { color: var(--primary); font-weight: 600; text-decoration: underline; text-underline-offset: 2px; }

.legal-callout {
  background: var(--secondary);
  border: 1px solid var(--border);
  border-left: 3px solid var(--primary);
  border-radius: var(--radius-md);
  padding: 1.1rem 1.35rem;
  font-size: 0.95rem;
  line-height: 1.7;
  color: var(--secondary-foreground);
  margin: 0 0 1.25rem;
}

.legal-table-wrap { overflow-x: auto; margin: 0 0 1.25rem; border: 1px solid var(--border); border-radius: var(--radius-md); }
.legal-table { width: 100%; border-collapse: collapse; font-size: 0.9rem; }
.legal-table th, .legal-table td { text-align: left; padding: 0.8rem 1.05rem; line-height: 1.5; border-bottom: 1px solid var(--border); vertical-align: top; }
.legal-table th { background: var(--secondary); font-weight: 700; color: var(--foreground); white-space: nowrap; }
.legal-table tr:last-child td { border-bottom: none; }

.legal-placeholder {
  background: color-mix(in srgb, var(--accent) 16%, transparent);
  color: var(--sunset-deep);
  border-radius: 4px;
  padding: 0.1rem 0.45rem;
  font-weight: 700;
  font-size: 0.9em;
  white-space: nowrap;
}

.legal-contact-box {
  background: var(--secondary);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 1.75rem;
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
  margin-top: 0.75rem;
}
.legal-contact-box .legal-contact-row {
  display: flex;
  align-items: center;
  gap: 0.7rem;
  font-size: 0.95rem;
  color: var(--secondary-foreground);
}
.legal-contact-box i { color: var(--primary); flex-shrink: 0; }
.legal-contact-box a { color: var(--foreground); font-weight: 600; text-decoration: none; }
.legal-contact-box a:hover { color: var(--primary); }
