/* Shared styles for terminos.html and privacidad.html */
:root {
  --bg:           oklch(1.000 0.000   0);
  --surface:      oklch(0.975 0.006 210);
  --border:       oklch(0.900 0.010 210);
  --ink:          oklch(0.13  0.015 210);
  --muted:        oklch(0.50  0.010 210);
  --subtle:       oklch(0.68  0.008 210);
  --primary:      oklch(0.42  0.110 210);
  --primary-dark: oklch(0.32  0.110 210);
  --primary-light:oklch(0.94  0.028 210);
  --font: 'Inter', system-ui, sans-serif;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }

body {
  font-family: var(--font); background: var(--bg);
  color: var(--ink); line-height: 1.7; -webkit-font-smoothing: antialiased;
}

/* ── Nav ─────────────────────────────────────────── */
.topbar {
  background: var(--bg); border-bottom: 1px solid var(--border);
  padding: 0 1.5rem; height: 56px;
  display: flex; align-items: center; justify-content: space-between;
  position: sticky; top: 0; z-index: 50;
}
.topbar-brand {
  display: flex; align-items: center; gap: .5rem;
  text-decoration: none; color: var(--ink);
}
.topbar-brand img { height: 28px; }
.topbar-brand span { font-size: .8125rem; font-weight: 700; }
.topbar-back {
  display: inline-flex; align-items: center; gap: .35rem;
  font-size: .8125rem; color: var(--muted); text-decoration: none;
  padding: .35rem .625rem; border-radius: 6px;
  transition: color .15s, background .15s;
}
.topbar-back:hover { color: var(--ink); background: var(--surface); }
.topbar-back svg { width: 14px; height: 14px; }

/* ── Hero del documento ──────────────────────────── */
.doc-hero {
  background: var(--surface); border-bottom: 1px solid var(--border);
  padding: 3rem 1.5rem 2.5rem;
}
.doc-hero-inner { max-width: 760px; margin: 0 auto; }
.doc-badge {
  display: inline-flex; align-items: center; gap: .4rem;
  background: var(--primary-light); color: var(--primary);
  font-size: .72rem; font-weight: 700; letter-spacing: .04em;
  padding: .3rem .75rem; border-radius: 999px;
  text-transform: uppercase; margin-bottom: 1rem;
}
.doc-badge svg { width: 13px; height: 13px; }
.doc-hero h1 {
  font-size: clamp(1.625rem, 3vw, 2.25rem);
  font-weight: 800; letter-spacing: -.03em; line-height: 1.2; margin-bottom: .75rem;
}
.doc-meta { font-size: .8125rem; color: var(--muted); }
.doc-meta strong { color: var(--ink); }

/* ── Contenido ───────────────────────────────────── */
.doc-body { max-width: 760px; margin: 0 auto; padding: 3rem 1.5rem 5rem; }

/* Índice */
.toc {
  background: var(--surface); border: 1px solid var(--border);
  border-radius: 12px; padding: 1.25rem 1.5rem; margin-bottom: 3rem;
}
.toc-title {
  font-size: .75rem; font-weight: 700; text-transform: uppercase;
  letter-spacing: .07em; color: var(--muted); margin-bottom: .75rem;
}
.toc ol {
  list-style: decimal; padding-left: 1.25rem;
  display: flex; flex-direction: column; gap: .3rem;
}
.toc li a { font-size: .875rem; color: var(--primary); text-decoration: none; }
.toc li a:hover { text-decoration: underline; }

/* Secciones */
.doc-section { margin-bottom: 2.75rem; scroll-margin-top: 72px; }
.doc-section h2 {
  font-size: 1.125rem; font-weight: 700; letter-spacing: -.02em;
  margin-bottom: .875rem; padding-bottom: .625rem;
  border-bottom: 1px solid var(--border);
  display: flex; align-items: center; gap: .625rem;
}
.doc-section h2 .num {
  display: inline-flex; align-items: center; justify-content: center;
  width: 1.625rem; height: 1.625rem;
  background: var(--primary); color: #fff;
  font-size: .7rem; font-weight: 800; border-radius: 50%; flex-shrink: 0;
}
.doc-section p { font-size: .9375rem; color: var(--ink); margin-bottom: .875rem; }
.doc-section p:last-child { margin-bottom: 0; }
.doc-section ul, .doc-section ol {
  padding-left: 1.5rem; display: flex; flex-direction: column; gap: .5rem; margin-bottom: .875rem;
}
.doc-section li { font-size: .9375rem; color: var(--ink); }
.doc-section strong { font-weight: 600; }
.doc-section a { color: var(--primary); }
.doc-section a:hover { text-decoration: underline; }

/* Tabla de datos (privacidad.html) */
.data-table { width: 100%; border-collapse: collapse; margin: 1.25rem 0; font-size: .875rem; }
.data-table th {
  background: var(--surface); padding: .625rem .875rem;
  text-align: left; font-size: .72rem; font-weight: 700;
  text-transform: uppercase; letter-spacing: .06em; color: var(--muted);
  border-bottom: 1px solid var(--border);
}
.data-table td {
  padding: .625rem .875rem; border-bottom: 1px solid var(--border);
  color: var(--ink); vertical-align: top;
}
.data-table tr:last-child td { border-bottom: none; }
.data-table tr:hover td { background: var(--surface); }

/* Callout */
.callout {
  background: var(--primary-light); border-left: 3px solid var(--primary);
  border-radius: 0 8px 8px 0; padding: 1rem 1.25rem; margin: 1.25rem 0;
  font-size: .875rem; color: var(--primary-dark); line-height: 1.6;
}
.callout strong { font-weight: 700; }

/* Footer de documento */
.doc-footer {
  border-top: 1px solid var(--border); padding: 1.5rem;
  display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 1rem;
  max-width: 760px; margin: 0 auto;
}
.doc-footer p { font-size: .78rem; color: var(--muted); }
.doc-footer a { font-size: .78rem; color: var(--primary); text-decoration: none; }
.doc-footer a:hover { text-decoration: underline; }

@media (max-width: 600px) {
  .doc-hero, .doc-body { padding-left: 1.25rem; padding-right: 1.25rem; }
  .data-table { font-size: .8rem; }
}
