/* ============================================
   LEGAL PAGES — Privacy & Terms (CodProfit dark)
   Shared styles. Matches the new landing-apple.html design system.
   ============================================ */

:root {
  --brand: #00ff88;
  --brand-deep: #00cc6a;
  --on-brand: #062014;

  --bg-app: #0d1421;
  --bg-app-deep: #0a0f1a;
  --bg-surface: #111827;

  --on-dark: #ffffff;
  --on-dark-muted: rgba(255,255,255,0.66);
  --ink-muted-80: rgba(255,255,255,0.72);
  --ink-muted-48: rgba(255,255,255,0.48);

  --hairline: rgba(255,255,255,0.08);
  --hairline-strong: rgba(255,255,255,0.14);
}

*, *::before, *::after { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }

body {
  background: var(--bg-app);
  color: var(--on-dark);
  font-family: 'SF Pro Text', system-ui, -apple-system, BlinkMacSystemFont,
               'Inter', 'Segoe UI', Roboto, sans-serif;
  font-size: 17px;
  font-weight: 400;
  line-height: 1.6;
  letter-spacing: -0.012em;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: 0; cursor: pointer; padding: 0; }
img { max-width: 100%; display: block; }

/* ============================================
   NAV (matches landing-apple.html)
   ============================================ */
.nav {
  position: sticky;
  top: 0;
  z-index: 50;
  height: 68px;
  background: rgba(10, 15, 26, 0.62);
  backdrop-filter: saturate(180%) blur(24px);
  -webkit-backdrop-filter: saturate(180%) blur(24px);
  border-bottom: 1px solid rgba(255,255,255,0.05);
}
.nav-inner {
  max-width: 1320px;
  height: 100%;
  margin: 0 auto;
  padding: 0 24px;
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 40px;
}
.nav-logo {
  display: inline-flex;
  align-items: center;
  text-decoration: none;
  transition: opacity .15s ease;
}
.nav-logo:hover { opacity: 0.88; }
.nav-logo-img {
  height: 28px;
  width: auto;
  display: block;
}

.nav-links {
  display: flex; gap: 4px; justify-self: center;
}
.nav-links a {
  font-size: 14px; font-weight: 500;
  letter-spacing: -0.014em;
  color: rgba(255,255,255,0.62);
  padding: 8px 14px;
  border-radius: 7px;
  position: relative;
  transition: color .15s ease, background-color .15s ease;
}
.nav-links a::after {
  content: '';
  position: absolute;
  left: 14px; right: 14px; bottom: 4px;
  height: 1px;
  background: var(--brand);
  transform: scaleX(0);
  transition: transform .25s cubic-bezier(0.4, 0, 0.2, 1);
}
.nav-links a:hover {
  color: var(--on-dark);
  background: rgba(255,255,255,0.03);
}
.nav-links a:hover::after { transform: scaleX(0.55); }

.nav-actions { display: flex; align-items: center; gap: 6px; }
.nav-link-login {
  font-size: 14px; font-weight: 500;
  letter-spacing: -0.014em;
  color: rgba(255,255,255,0.78);
  padding: 0 14px; height: 38px;
  display: inline-flex; align-items: center;
  border-radius: 8px;
  transition: color .15s ease, background-color .15s ease;
}
.nav-link-login:hover {
  color: var(--on-dark);
  background: rgba(255,255,255,0.04);
}
.nav-cta {
  display: inline-flex; align-items: center; gap: 6px;
  background: var(--brand); color: var(--on-brand);
  font-size: 14px; font-weight: 600;
  letter-spacing: -0.014em; line-height: 1;
  padding: 0 18px; height: 38px;
  border-radius: 8px;
  border: 1px solid var(--brand);
  transition: all .2s ease;
  box-shadow: 0 1px 2px rgba(0,0,0,0.20), inset 0 1px 0 rgba(255,255,255,0.18);
}
.nav-cta:hover {
  background: #00e679; border-color: #00e679;
  transform: translateY(-1px);
  box-shadow: 0 8px 20px rgba(0,255,136,0.20),
              0 1px 2px rgba(0,0,0,0.20),
              inset 0 1px 0 rgba(255,255,255,0.20);
}
.nav-cta svg { transition: transform .18s ease; }
.nav-cta:hover svg { transform: translateX(2px); }

/* ============================================
   LEGAL PAGE LAYOUT
   ============================================ */
.legal-page {
  position: relative;
  padding: 72px 24px 96px;
  overflow: hidden;
}
.legal-page::before {
  content: '';
  position: absolute;
  top: -160px; left: 50%;
  transform: translateX(-50%);
  width: 1100px; height: 600px;
  background: radial-gradient(ellipse at center,
              rgba(0,255,136,0.08) 0%,
              rgba(0,255,136,0.03) 35%,
              transparent 70%);
  pointer-events: none;
  z-index: 0;
}
.legal-container {
  position: relative;
  z-index: 1;
  max-width: 800px;
  margin: 0 auto;
}

/* Breadcrumb back link */
.legal-back {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 13px;
  color: var(--on-dark-muted);
  margin-bottom: 32px;
  transition: color .15s ease;
}
.legal-back:hover { color: var(--on-dark); }
.legal-back svg { width: 14px; height: 14px; transition: transform .15s ease; }
.legal-back:hover svg { transform: translateX(-2px); }

/* Header: title + meta + lang toggle */
.legal-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 24px;
  margin-bottom: 32px;
  flex-wrap: wrap;
}
.legal-title {
  font-family: 'SF Pro Display', system-ui, sans-serif;
  font-size: clamp(36px, 5vw, 48px);
  font-weight: 600;
  line-height: 1.05;
  letter-spacing: -0.03em;
  color: var(--on-dark);
  margin: 0 0 12px;
}
.legal-updated {
  font-size: 13px;
  color: var(--on-dark-muted);
  letter-spacing: -0.005em;
}

/* PT / EN toggle pill */
.lang-toggle {
  display: inline-flex;
  background: rgba(255,255,255,0.04);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 9999px;
  padding: 3px;
  flex-shrink: 0;
}
.lang-btn {
  font-family: inherit;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.04em;
  color: var(--on-dark-muted);
  padding: 6px 14px;
  border-radius: 9999px;
  cursor: pointer;
  transition: all .18s ease;
}
.lang-btn:hover { color: var(--on-dark); }
.lang-btn.active {
  background: var(--brand);
  color: var(--on-brand);
  box-shadow: 0 1px 0 rgba(255,255,255,0.20) inset;
}

.legal-divider {
  height: 1px;
  background: linear-gradient(90deg,
              transparent 0%,
              var(--hairline) 30%,
              var(--hairline) 70%,
              transparent 100%);
  margin: 0 0 40px;
}

/* Content sections */
.legal-section {
  margin-bottom: 40px;
  scroll-margin-top: 96px;
}
.legal-section:last-child { margin-bottom: 0; }

.legal-section h2 {
  font-family: 'SF Pro Display', system-ui, sans-serif;
  font-size: 22px;
  font-weight: 600;
  line-height: 1.25;
  letter-spacing: -0.022em;
  color: var(--on-dark);
  margin: 0 0 16px;
}
.legal-section h3 {
  font-family: 'SF Pro Display', system-ui, sans-serif;
  font-size: 17px;
  font-weight: 600;
  line-height: 1.35;
  letter-spacing: -0.014em;
  color: var(--on-dark);
  margin: 28px 0 12px;
}
.legal-section p {
  color: var(--on-dark-muted);
  line-height: 1.65;
  margin: 0 0 14px;
  font-size: 16px;
  letter-spacing: -0.005em;
}
.legal-section p:last-child { margin-bottom: 0; }

.legal-section ul {
  list-style: none;
  padding: 0;
  margin: 0 0 18px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.legal-section ul li {
  position: relative;
  padding-left: 22px;
  color: var(--on-dark-muted);
  line-height: 1.6;
  font-size: 16px;
  letter-spacing: -0.005em;
}
.legal-section ul li::before {
  content: '';
  position: absolute;
  left: 4px;
  top: 11px;
  width: 6px; height: 6px;
  border-radius: 50%;
  background: var(--brand);
  opacity: 0.7;
}

.legal-section strong {
  color: var(--on-dark);
  font-weight: 600;
}

.legal-section a {
  color: var(--brand);
  text-decoration: underline;
  text-underline-offset: 2px;
  text-decoration-color: rgba(0,255,136,0.4);
  transition: color .15s ease, text-decoration-color .15s ease;
}
.legal-section a:hover {
  color: var(--brand-deep);
  text-decoration-color: var(--brand-deep);
}

/* Final contact card stands out */
.legal-section.contact-card {
  margin-top: 56px;
  padding: 28px 32px;
  background: linear-gradient(160deg,
              rgba(0,255,136,0.05) 0%,
              rgba(255,255,255,0.025) 60%);
  border: 1px solid rgba(0,255,136,0.18);
  border-radius: 14px;
}
.legal-section.contact-card h2 { margin-bottom: 12px; }
.legal-section.contact-card p { color: var(--on-dark); }

/* ============================================
   FOOTER (matches landing-apple.html)
   ============================================ */
footer {
  background: var(--bg-app-deep);
  color: var(--on-dark-muted);
  padding: 56px 24px 32px;
  font-size: 12px;
  border-top: 1px solid rgba(255,255,255,0.06);
}
.footer-inner {
  max-width: 1200px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1.2fr 1fr 1fr 1fr 1fr;
  gap: 32px;
}
.footer-col h4 {
  font-size: 12px;
  font-weight: 600;
  color: var(--on-dark);
  margin: 0 0 14px;
  letter-spacing: 0;
}
.footer-col a {
  display: block;
  padding: 6px 0;
  font-size: 12px;
  color: var(--on-dark-muted);
  line-height: 2;
}
.footer-col a:hover { color: var(--on-dark); text-decoration: underline; }
.footer-brand .logo {
  font-family: 'SF Pro Display', system-ui, sans-serif;
  font-weight: 600; font-size: 18px; letter-spacing: -0.025em;
  color: var(--on-dark);
}
.footer-brand .logo .c { color: var(--brand); }
.footer-brand p { margin: 8px 0 0; max-width: 260px; line-height: 1.55; }

.footer-company {
  max-width: 1200px;
  margin: 24px auto 0;
  padding: 18px 0 0;
  border-top: 1px solid rgba(255,255,255,0.06);
  font-size: 12px;
  color: var(--on-dark-muted);
  line-height: 1.6;
  letter-spacing: -0.005em;
}
.footer-company strong { color: var(--on-dark); font-weight: 600; }

.footer-legal {
  max-width: 1200px;
  margin: 32px auto 0;
  padding-top: 18px;
  border-top: 1px solid rgba(255,255,255,0.06);
  display: flex;
  justify-content: center;
  font-size: 11px;
  color: rgba(255,255,255,0.40);
  letter-spacing: -0.005em;
}

/* ============================================
   COOKIE CONSENT BANNER (LGPD) — same as landing
   ============================================ */
.cookie-banner {
  position: fixed;
  bottom: 16px; left: 16px; right: 16px;
  z-index: 100;
  max-width: 900px;
  margin: 0 auto;
  background: rgba(13, 20, 33, 0.92);
  border: 1px solid rgba(255,255,255,0.10);
  border-radius: 14px;
  backdrop-filter: saturate(180%) blur(24px);
  -webkit-backdrop-filter: saturate(180%) blur(24px);
  box-shadow: 0 24px 48px -16px rgba(0,0,0,0.55),
              0 8px 16px -8px rgba(0,0,0,0.40),
              inset 0 1px 0 rgba(255,255,255,0.06);
  animation: cookie-slide-up .35s cubic-bezier(0.16, 1, 0.3, 1);
}
.cookie-banner[hidden] { display: none; }
@keyframes cookie-slide-up {
  from { transform: translateY(20px); opacity: 0; }
  to { transform: translateY(0); opacity: 1; }
}
.cookie-inner {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 20px;
  padding: 18px 22px;
}
.cookie-icon {
  width: 40px; height: 40px;
  border-radius: 10px;
  background: rgba(0,255,136,0.10);
  border: 1px solid rgba(0,255,136,0.24);
  color: var(--brand);
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0;
}
.cookie-icon svg { width: 20px; height: 20px; }
.cookie-text { font-size: 14px; line-height: 1.5; color: var(--on-dark-muted); }
.cookie-text strong { color: var(--on-dark); font-weight: 600; }
.cookie-text a {
  color: var(--brand);
  text-decoration: underline;
  text-underline-offset: 2px;
}
.cookie-actions { display: flex; gap: 8px; flex-shrink: 0; }
.cookie-btn {
  display: inline-flex; align-items: center; justify-content: center;
  font-family: inherit; font-size: 13px; font-weight: 600;
  letter-spacing: -0.014em; line-height: 1;
  padding: 0 16px; height: 38px;
  border-radius: 8px;
  cursor: pointer;
  transition: all .15s ease;
  white-space: nowrap;
}
.cookie-btn-secondary {
  background: transparent; color: var(--on-dark);
  border: 1px solid rgba(255,255,255,0.18);
}
.cookie-btn-secondary:hover {
  background: rgba(255,255,255,0.05);
  border-color: rgba(255,255,255,0.32);
}
.cookie-btn-primary {
  background: var(--brand); color: var(--on-brand);
  border: 1px solid var(--brand);
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.18);
}
.cookie-btn-primary:hover {
  background: #00e679; border-color: #00e679;
  transform: translateY(-1px);
  box-shadow: 0 6px 14px rgba(0,255,136,0.18),
              inset 0 1px 0 rgba(255,255,255,0.20);
}

/* ============================================
   SELECTION + UTILS
   ============================================ */
::selection { background: rgba(0,255,136,0.30); color: #fff; }

/* ============================================
   RESPONSIVE
   ============================================ */
@media (max-width: 1068px) {
  .footer-inner { grid-template-columns: 1fr 1fr 1fr; }
  .footer-brand { grid-column: 1 / -1; }
}
@media (max-width: 833px) {
  .nav-links { display: none; }
  .nav-inner { gap: 16px; }
  .legal-page { padding: 48px 20px 72px; }
  .legal-title { font-size: 32px; }
  .legal-section.contact-card { padding: 24px 22px; }
}
@media (max-width: 640px) {
  .footer-inner { grid-template-columns: 1fr 1fr; }
  .legal-header { flex-direction: column; }
  .cookie-banner { left: 12px; right: 12px; bottom: 12px; }
  .cookie-inner {
    grid-template-columns: 1fr;
    gap: 14px;
    padding: 16px 18px;
    text-align: center;
  }
  .cookie-icon { margin: 0 auto; }
  .cookie-actions { justify-content: stretch; flex-wrap: wrap; }
  .cookie-actions .cookie-btn { flex: 1; min-width: 140px; }
}
@media (max-width: 480px) {
  .footer-inner { grid-template-columns: 1fr; }
  .legal-section h2 { font-size: 20px; }
  .nav-link-login { display: none; }
}
