/* =========================================================
   GOLIFY — LEGAL PAGES (Términos / Aviso de Privacidad)
   Shared styles to keep both legal docs consistent with the
   main Golify.html aesthetic.
   ========================================================= */
:root {
  --c-navy:   #162140;
  --c-teal:   #123a3b;
  --c-forest: #0d5035;
  --c-green:  #1a6334;
  --c-lime:   #84ae2f;
  --c-lime-bright: #b4e042;
  --c-deep:   #0a1228;

  --ink:        #ffffff;
  --ink-mute:   rgba(255,255,255,0.72);
  --ink-faint:  rgba(255,255,255,0.48);
  --ink-ghost:  rgba(255,255,255,0.18);
  --hairline:        rgba(255,255,255,0.10);
  --hairline-strong: rgba(255,255,255,0.22);

  --font-display: "Anton", "Montserrat", system-ui, sans-serif;
  --font-heading: "Montserrat", system-ui, sans-serif;
  --font-body:    "Inter", system-ui, sans-serif;
  --font-mono:    "JetBrains Mono", ui-monospace, monospace;

  --max-w: 1280px;
  --gutter: clamp(20px, 4vw, 56px);
}

*, *::before, *::after { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
  background: var(--c-deep);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
body::before {
  content: "";
  position: fixed; inset: 0;
  background: linear-gradient(180deg, #0a1228 0%, #162140 60%, #0a1228 100%);
  z-index: -2;
}
body::after {
  content: "";
  position: fixed; inset: 0;
  pointer-events: none;
  z-index: -1;
  opacity: 0.04;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='160' height='160'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2' stitchTiles='stitch'/></filter><rect width='100%' height='100%' filter='url(%23n)' opacity='1'/></svg>");
}

a { color: var(--c-lime); text-decoration: none; transition: color 180ms; }
a:hover { color: var(--c-lime-bright); }
::selection { background: var(--c-lime); color: var(--c-navy); }

.wrap { max-width: var(--max-w); margin: 0 auto; padding-left: var(--gutter); padding-right: var(--gutter); }

/* ============= NAV (shared with home) ============= */
nav.top {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 50;
  padding: 16px var(--gutter);
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 24px;
  background: rgba(10,18,40,0.92);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--hairline);
}
nav.top .logo { display: inline-flex; align-items: center; }
nav.top .logo img { height: 32px; width: auto; display: block; }
nav.top ul {
  display: flex; gap: 32px;
  list-style: none; margin: 0; padding: 0;
  justify-content: center;
}
nav.top ul a {
  font-family: var(--font-body);
  font-size: 13px;
  font-weight: 500;
  color: var(--ink-mute);
}
nav.top ul a:hover { color: var(--ink); }
nav.top .back-cta {
  justify-self: end;
  display: inline-flex; align-items: center; gap: 8px;
  padding: 10px 18px;
  background: var(--c-lime);
  color: var(--c-navy);
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 13px;
  border-radius: 999px;
  transition: background 180ms;
}
nav.top .back-cta:hover { background: var(--c-lime-bright); color: var(--c-navy); }
nav.top .back-cta svg { width: 14px; height: 14px; }

/* ============= HERO TITLE ============= */
.legal-hero {
  padding: 160px 0 60px;
  border-bottom: 1px solid var(--hairline);
}
.legal-hero .crumb {
  display: inline-flex; align-items: center; gap: 12px;
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--c-lime);
  margin-bottom: 24px;
}
.legal-hero .crumb::before {
  content: "";
  width: 28px; height: 1px;
  background: var(--c-lime);
}
.legal-hero h1 {
  font-family: var(--font-heading);
  font-weight: 800;
  font-size: clamp(40px, 6vw, 84px);
  line-height: 0.98;
  margin: 0 0 24px;
  letter-spacing: -0.025em;
  text-wrap: balance;
}
.legal-hero h1 .lime { color: var(--c-lime); }
.legal-hero .lede {
  font-size: clamp(16px, 1.6vw, 19px);
  color: var(--ink-mute);
  max-width: 60ch;
  margin: 0;
  line-height: 1.55;
}
.legal-hero .meta {
  margin-top: 32px;
  display: flex;
  gap: 32px;
  flex-wrap: wrap;
  padding-top: 24px;
  border-top: 1px solid var(--hairline);
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--ink-faint);
}
.legal-hero .meta strong { color: var(--ink); font-weight: 500; }

/* ============= ADVISORY BANNER ============= */
.advisory {
  margin: 32px 0 0;
  padding: 16px 20px;
  background: rgba(132,174,47,0.08);
  border: 1px dashed var(--c-lime);
  border-radius: 12px;
  display: flex;
  gap: 12px;
  align-items: flex-start;
  font-size: 13px;
  color: var(--ink);
  line-height: 1.55;
}
.advisory svg { flex-shrink: 0; color: var(--c-lime); margin-top: 2px; }
.advisory strong { color: var(--c-lime); }

/* ============= LAYOUT ============= */
.legal-body {
  padding: 80px 0 120px;
  display: grid;
  grid-template-columns: 260px 1fr;
  gap: 72px;
  align-items: start;
}
.toc {
  position: sticky;
  top: 100px;
}
.toc-label {
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.20em;
  text-transform: uppercase;
  color: var(--c-lime);
  margin-bottom: 18px;
}
.toc ol {
  list-style: none;
  margin: 0; padding: 0;
  display: flex;
  flex-direction: column;
  gap: 4px;
  counter-reset: toc;
}
.toc li {
  counter-increment: toc;
}
.toc a {
  display: flex;
  gap: 12px;
  padding: 8px 12px;
  border-radius: 8px;
  color: var(--ink-mute);
  font-size: 13.5px;
  line-height: 1.4;
  transition: all 180ms;
  border-left: 2px solid transparent;
}
.toc a::before {
  content: counter(toc, decimal-leading-zero);
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.12em;
  color: var(--ink-faint);
  flex-shrink: 0;
  margin-top: 2px;
}
.toc a:hover {
  color: var(--ink);
  background: rgba(255,255,255,0.03);
}
.toc a.active {
  color: var(--ink);
  border-left-color: var(--c-lime);
  background: rgba(132,174,47,0.05);
}
.toc a.active::before { color: var(--c-lime); }

/* ============= CONTENT ============= */
.content { max-width: 70ch; }
.content section {
  padding: 36px 0;
  border-top: 1px solid var(--hairline);
  counter-increment: sec;
  scroll-margin-top: 100px;
}
.content section:first-of-type { border-top: 0; padding-top: 0; }
.content section h2 {
  font-family: var(--font-heading);
  font-weight: 800;
  font-size: clamp(24px, 2.6vw, 32px);
  letter-spacing: -0.015em;
  line-height: 1.15;
  margin: 0 0 8px;
  display: flex;
  gap: 16px;
  align-items: baseline;
  text-wrap: balance;
}
.content section h2::before {
  content: counter(sec, decimal-leading-zero);
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.18em;
  color: var(--c-lime);
  font-weight: 500;
  flex-shrink: 0;
}
.content { counter-reset: sec; }
.content section h3 {
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 17px;
  letter-spacing: -0.005em;
  margin: 28px 0 8px;
  color: var(--ink);
}
.content section p {
  color: var(--ink-mute);
  margin: 0 0 14px;
  line-height: 1.7;
}
.content section ul, .content section ol {
  margin: 4px 0 16px;
  padding-left: 22px;
  color: var(--ink-mute);
  line-height: 1.7;
}
.content section li { margin-bottom: 6px; }
.content section li::marker { color: var(--c-lime); }
.content strong { color: var(--ink); font-weight: 600; }
.content em { color: var(--ink); font-style: normal; font-weight: 500; }

.content section .callout {
  margin: 20px 0;
  padding: 16px 20px;
  border-left: 3px solid var(--c-lime);
  background: rgba(132,174,47,0.06);
  border-radius: 0 8px 8px 0;
  font-size: 14px;
  line-height: 1.6;
}
.content section .callout strong { color: var(--c-lime); }

.content table {
  width: 100%;
  border-collapse: collapse;
  margin: 16px 0 24px;
  font-size: 14px;
}
.content th, .content td {
  text-align: left;
  padding: 12px 14px;
  border-bottom: 1px solid var(--hairline);
  vertical-align: top;
}
.content th {
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 11px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--c-lime);
}
.content td { color: var(--ink-mute); }

.content .end-mark {
  margin-top: 56px;
  padding-top: 32px;
  border-top: 1px solid var(--hairline);
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--ink-faint);
  display: flex;
  align-items: center;
  gap: 12px;
}
.content .end-mark::before {
  content: "";
  width: 28px; height: 1px;
  background: var(--c-lime);
}

/* ============= FOOTER ============= */
footer.legal-footer {
  padding: 60px 0 32px;
  border-top: 1px solid var(--hairline);
  background: rgba(10,18,40,0.6);
}
footer.legal-footer .row {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 48px;
  margin-bottom: 48px;
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--ink-faint);
}
footer.legal-footer .row .brand-col p {
  text-transform: none;
  letter-spacing: 0;
  color: var(--ink-mute);
  font-family: var(--font-body);
  font-size: 13px;
  line-height: 1.6;
  margin: 18px 0 0;
  max-width: 38ch;
}
footer.legal-footer .row .brand-col .legal {
  margin-top: 18px;
  color: var(--ink-faint);
  line-height: 1.7;
}
footer.legal-footer .row .brand-col .legal strong { color: var(--ink-mute); font-weight: 500; }
footer.legal-footer .col h5 {
  color: var(--ink);
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 13px;
  letter-spacing: 0.10em;
  margin: 0 0 18px;
}
footer.legal-footer .col ul {
  list-style: none; padding: 0; margin: 0;
  display: flex; flex-direction: column; gap: 12px;
}
footer.legal-footer .col a {
  color: var(--ink-mute);
  font-size: 14px;
  letter-spacing: 0;
  text-transform: none;
  font-family: var(--font-body);
}
footer.legal-footer .col a:hover { color: var(--c-lime); }
footer.legal-footer .bottom {
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 16px;
  padding-top: 24px;
  border-top: 1px solid var(--hairline);
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--ink-faint);
}
footer.legal-footer .bottom .links { display: flex; gap: 24px; flex-wrap: wrap; }
footer.legal-footer .bottom a { color: var(--ink-faint); }
footer.legal-footer .bottom a:hover { color: var(--c-lime); }

/* ============= RESPONSIVE ============= */
@media (max-width: 1000px) {
  .legal-body {
    grid-template-columns: 1fr;
    gap: 40px;
  }
  .toc {
    position: static;
    padding: 20px;
    border: 1px solid var(--hairline);
    border-radius: 12px;
    background: rgba(22,33,64,0.4);
  }
  footer.legal-footer .row { grid-template-columns: 1fr 1fr; gap: 32px; }
}
@media (max-width: 700px) {
  nav.top { grid-template-columns: auto 1fr; padding: 12px 20px; }
  nav.top ul { display: none; }
  nav.top .back-cta { justify-self: end; }
  .legal-hero { padding: 110px 0 48px; }
  .legal-body { padding: 56px 0 80px; }
  footer.legal-footer .row { grid-template-columns: 1fr; }
}
