@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800&family=JetBrains+Mono:wght@400;500;600;700&display=swap');

/* ==========================================================================
   Legal & Privacy Hub — Vercel Geist Legal Theme
   ========================================================================== */

:root {
  color-scheme: light;

  /* Typography */
  --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  --font-mono: 'JetBrains Mono', ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;

  /* Vercel Light Theme Palette */
  --bg: #ffffff;
  --bg-subtle: #fafafa;
  --bg-raised: #ffffff;
  --bg-glass: rgba(255, 255, 255, 0.9);

  --ink: #000000;
  --soft: #666666;
  --subtle: #888888;
  --line: #eaeaea;
  --line-strong: #999999;

  --accent: #000000;
  --accent-hover: #333333;
  --accent-light: #f5f5f5;
  --accent-border: #000000;

  /* Radius */
  --radius-sm: 6px;
  --radius-md: 8px;
  --radius-lg: 12px;
  --radius-pill: 9999px;

  /* Shadows */
  --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.04);
  --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.08);
}

/* ==========================================================================
   Base Reset
   ========================================================================== */

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background-color: var(--bg);
  color: var(--ink);
  font-family: var(--font-sans);
  font-size: 0.9375rem;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

::selection {
  background: var(--ink);
  color: var(--bg);
}

a {
  color: var(--ink);
  text-decoration: underline;
  text-underline-offset: 3px;
  text-decoration-color: var(--line-strong);
  transition: all 0.15s ease;
}

a:hover {
  text-decoration-color: var(--ink);
}

h1,
h2,
h3,
h4,
h5,
h6 {
  color: var(--ink);
  letter-spacing: -0.02em;
  font-weight: 700;
}

.wrap {
  max-width: 66rem;
  margin: 0 auto;
  padding: 0 1.5rem;
}

/* Custom Scrollbar */
::-webkit-scrollbar {
  width: 6px;
  height: 6px;
}

::-webkit-scrollbar-track {
  background: var(--bg);
}

::-webkit-scrollbar-thumb {
  background: var(--line-strong);
  border-radius: 3px;
}

/* ==========================================================================
   Header & Vercel Navigation
   ========================================================================== */

.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--bg-glass);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--line);
  padding: 0.85rem 0;
}

.site-header .wrap {
  display: flex;
  align-items: center;
  gap: 2rem;
}

.brand {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  text-decoration: none;
  color: var(--ink);
  font-weight: 700;
  font-size: 1.05rem;
  letter-spacing: -0.02em;
  margin-right: auto;
}

.brand img {
  width: 40px;
  height: 40px;
}

.site-nav {
  display: flex;
  align-items: center;
  gap: 1.25rem;
  font-size: 0.875rem;
  font-weight: 500;
}

.site-nav a {
  color: var(--soft);
  text-decoration: none;
  padding: 0.3rem 0.6rem;
  border-radius: var(--radius-sm);
  transition: all 0.15s ease;
}

.site-nav a:hover {
  color: var(--ink);
  background: var(--bg-subtle);
}

.site-nav a[aria-current="page"] {
  color: var(--ink);
  font-weight: 600;
  background: var(--accent-light);
}

/* Language Switcher Pill (Geist Mono style) */
.lang-switch {
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
  background: var(--bg-subtle);
  border: 1px solid var(--line);
  padding: 0.2rem;
  border-radius: var(--radius-pill);
  margin: 0 0 2rem;
  font-family: var(--font-mono);
}

.lang-switch a {
  color: var(--soft);
  text-decoration: none;
  padding: 0.3rem 0.75rem;
  border-radius: var(--radius-pill);
  font-size: 0.75rem;
  font-weight: 500;
  transition: all 0.15s ease;
}

.lang-switch a:hover {
  color: var(--ink);
}

.lang-switch a.active {
  color: var(--bg);
  background: var(--ink);
  font-weight: 600;
}

/* ==========================================================================
   Hero & Cards Grid (Home Page)
   ========================================================================== */

.hero {
  /* Ojo: NO usar el shorthand "padding" acá. Este elemento tambien lleva
     .wrap, que define "padding: 0 1.5rem"; el shorthand lo pisaría y el hero
     quedaría pegado al borde, desalineado del header y de las cards. */
  padding-top: 3.5rem;
  padding-bottom: 2.5rem;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: var(--soft);
  background: var(--bg-subtle);
  border: 1px solid var(--line);
  padding: 0.3rem 0.75rem;
  border-radius: var(--radius-pill);
  margin-bottom: 1.5rem;
}

.status-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #10b981;
  box-shadow: 0 0 8px #10b981;
}

.hero-brand-header {
  display: flex;
  align-items: center;
  gap: 1.25rem;
  margin-bottom: 1.25rem;
}

.hero-brand-header img {
  width: 80px;
  height: 80px;
  flex-shrink: 0;
}

.hero h1 {
  font-size: 2.75rem;
  line-height: 1.1;
  letter-spacing: -0.04em;
  margin: 0 0 1rem;
}

/* El h1 del hero arrastra margin-bottom: 1rem; dentro de esta fila flex ese
   margen entra en la caja que align-items centra y empuja el texto hacia
   arriba respecto del logo. Lo anulamos acá: el espacio inferior ya lo pone
   el margin-bottom de .hero-brand-header. */
.hero-brand-header h1 {
  margin: 0;
}

.hero p {
  color: var(--soft);
  font-size: 1.15rem;
  max-width: 38rem;
  margin: 0 0 2rem;
  line-height: 1.6;
}

.quick-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-bottom: 2.5rem;
}

.quick-pills a {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: var(--soft);
  background: var(--bg-subtle);
  border: 1px solid var(--line);
  padding: 0.35rem 0.75rem;
  border-radius: var(--radius-sm);
  text-decoration: none;
  transition: all 0.15s ease;
}

.quick-pills a:hover {
  color: var(--ink);
  border-color: var(--line-strong);
}

.card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(18rem, 1fr));
  gap: 1.25rem;
  margin: 0 auto 4rem;
}

.link-card {
  display: flex;
  flex-direction: column;
  background: var(--bg-raised);
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  padding: 1.75rem;
  text-decoration: none;
  color: var(--ink);
  transition: all 0.15s ease;
}

.link-card:hover {
  border-color: var(--line-strong);
  background: var(--bg-subtle);
}

.link-card .eyebrow {
  display: inline-block;
  font-family: var(--font-mono);
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--soft);
  margin-bottom: 0.75rem;
}

.link-card h2 {
  font-size: 1.25rem;
  margin: 0 0 0.5rem;
}

.link-card p {
  color: var(--soft);
  font-size: 0.9rem;
  line-height: 1.6;
  margin: 0 0 1.5rem;
}

.card-footer {
  margin-top: auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: var(--ink);
  font-weight: 500;
  border-top: 1px solid var(--line);
  padding-top: 1rem;
}

.card-footer .arrow {
  transition: transform 0.15s ease;
}

.link-card:hover .card-footer .arrow {
  transform: translateX(4px);
}

/* Trust & Principles Grid */
.trust-section {
  border-top: 1px solid var(--line);
  /* Mismo caso que .hero: solo padding vertical, el lateral lo pone .wrap. */
  padding-top: 4rem;
  padding-bottom: 4rem;
}

.trust-section h3 {
  font-size: 1.25rem;
  margin: 0 0 0.5rem;
}

.trust-section p.sub {
  color: var(--soft);
  font-size: 0.95rem;
  margin: 0 0 2rem;
}

.trust-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(16rem, 1fr));
  gap: 1.25rem;
}

.trust-card {
  background: var(--bg-subtle);
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  padding: 1.5rem;
}

.trust-card .icon {
  font-size: 1.25rem;
  margin-bottom: 0.75rem;
}

.trust-card h4 {
  margin: 0 0 0.5rem;
  font-size: 1rem;
  font-weight: 600;
}

.trust-card p {
  margin: 0;
  font-size: 0.875rem;
  color: var(--soft);
  line-height: 1.6;
}

/* ==========================================================================
   Vercel Legal Policy Layout
   ========================================================================== */

.legal {
  /* Mismo caso que .hero: <main class="wrap legal"> hereda el padding
     lateral de .wrap y acá solo tocamos el vertical. */
  padding-top: 3.5rem;
  padding-bottom: 6rem;
}

.legal h1 {
  font-size: 2.5rem;
  line-height: 1.15;
  letter-spacing: -0.03em;
  margin: 0 0 0.5rem;
}

.updated {
  font-family: var(--font-mono);
  color: var(--soft);
  font-size: 0.8rem;
  margin-bottom: 2rem;
}

.intro {
  font-size: 1.1rem;
  color: var(--soft);
  line-height: 1.65;
}

.callout {
  border-left: 2px solid var(--ink);
  background: var(--bg-subtle);
  padding: 1.25rem 1.5rem;
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  font-size: 0.9375rem;
  color: var(--ink);
  margin: 2rem 0;
}

.callout p {
  margin: 0;
}

/* 2-Column Vercel Policy Layout */
.policy-layout {
  display: grid;
  grid-template-columns: 16rem 1fr;
  gap: 4rem;
  align-items: start;
  margin-top: 3rem;
}

/* Vercel Sticky Sidebar TOC */
.policy-sidebar {
  position: sticky;
  top: 5rem;
  background: var(--bg);
  border-right: 1px solid var(--line);
  padding: 0 1.5rem 0 0;
  max-height: calc(100vh - 7rem);
  overflow-y: auto;
}

.policy-sidebar p {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  font-weight: 600;
  color: var(--subtle);
  margin: 0 0 1rem;
}

.policy-sidebar ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.policy-sidebar li {
  margin-bottom: 0.25rem;
}

.policy-sidebar a {
  display: block;
  font-size: 0.85rem;
  color: var(--soft);
  text-decoration: none;
  padding: 0.35rem 0.6rem;
  border-radius: var(--radius-sm);
  font-weight: 400;
  transition: all 0.15s ease;
}

.policy-sidebar a:hover {
  color: var(--ink);
  background: var(--bg-subtle);
}

/* Policy Main Content */
.policy-main {
  min-width: 0;
}

section.legal-section {
  margin-bottom: 3.5rem;
  scroll-margin-top: 5.5rem;
}

section.legal-section h2 {
  font-size: 1.35rem;
  font-weight: 700;
  margin: 0 0 1.25rem;
  padding-bottom: 0.5rem;
  border-bottom: 1px solid var(--line);
  color: var(--ink);
}

section.legal-section h3 {
  font-size: 1.1rem;
  margin: 1.75rem 0 0.75rem;
}

section.legal-section p {
  margin: 0 0 1.25rem;
  color: var(--ink);
}

section.legal-section ul,
section.legal-section ol {
  margin: 0 0 1.5rem;
  padding-left: 1.25rem;
}

section.legal-section li {
  margin-bottom: 0.5rem;
  color: var(--ink);
}

/* Custom Cards & Exhibits */
.custom-card {
  background: var(--bg-raised);
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  padding: 1.25rem 1.5rem;
  margin-bottom: 1rem;
  transition: border-color 0.15s ease;
}

.custom-card:hover {
  border-color: var(--line-strong);
}

.custom-card h4 {
  margin: 0 0 0.4rem;
  font-size: 1rem;
  font-weight: 600;
  color: var(--ink);
}

.custom-card p {
  margin: 0;
  font-size: 0.9rem;
  color: var(--soft);
  line-height: 1.6;
}

.badge {
  display: inline-block;
  font-family: var(--font-mono);
  font-size: 0.68rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  padding: 0.2rem 0.5rem;
  border-radius: var(--radius-sm);
  background: var(--bg-subtle);
  border: 1px solid var(--line);
  color: var(--ink);
  margin-bottom: 0.6rem;
}

.optout-box {
  border-left: 2px solid var(--ink);
  background: var(--bg-subtle);
  padding: 1.25rem 1.5rem;
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  margin: 2rem 0;
}

.optout-box h4 {
  margin: 0 0 0.4rem;
  font-size: 1rem;
  color: var(--ink);
}

.optout-box p {
  margin: 0 0 0.5rem;
  font-size: 0.9rem;
}

.optout-box p:last-child {
  margin-bottom: 0;
}

/* Data Table Component */
.table-scroll {
  overflow-x: auto;
  margin: 2rem 0;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
}

table.data-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.875rem;
  min-width: 36rem;
}

table.data-table th,
table.data-table td {
  text-align: left;
  padding: 0.85rem 1.15rem;
  border-bottom: 1px solid var(--line);
  vertical-align: top;
}

table.data-table th {
  background: var(--bg-subtle);
  color: var(--ink);
  font-family: var(--font-mono);
  font-weight: 600;
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

table.data-table td {
  color: var(--soft);
}

table.data-table td:first-child {
  color: var(--ink);
  font-weight: 500;
}

table.data-table tr:last-child td {
  border-bottom: none;
}

table.data-table tr:hover td {
  background: var(--bg-subtle);
}

/* ==========================================================================
   Footer
   ========================================================================== */

.site-footer {
  border-top: 1px solid var(--line);
  padding: 3rem 0;
  color: var(--soft);
  font-size: 0.85rem;
}

.site-footer .wrap {
  display: flex;
  flex-wrap: wrap;
  gap: 1.5rem;
  align-items: center;
  justify-content: space-between;
}

.site-footer nav {
  display: flex;
  gap: 1.5rem;
  font-weight: 500;
}

.site-footer a {
  color: var(--soft);
  text-decoration: none;
}

.site-footer a:hover {
  color: var(--ink);
}

/* ==========================================================================
   Responsive Breakpoints
   ========================================================================== */

@media (max-width: 58rem) {
  .policy-layout {
    grid-template-columns: 1fr;
    gap: 2rem;
  }

  .policy-sidebar {
    position: static;
    border-right: none;
    border-bottom: 1px solid var(--line);
    padding: 0 0 1.5rem 0;
    max-height: none;
  }
}

@media (max-width: 38rem) {
  .hero h1 {
    font-size: 2.1rem;
  }

  .hero-brand-header {
    gap: 0.9rem;
  }

  .hero-brand-header img {
    width: 56px;
    height: 56px;
  }

  .legal h1 {
    font-size: 1.85rem;
  }

  .site-header .wrap {
    flex-wrap: wrap;
    gap: 0.75rem;
  }

  .site-nav {
    gap: 0.5rem;
    font-size: 0.8rem;
  }

  .card-grid {
    grid-template-columns: 1fr;
  }
}

/* ==========================================================================
   Print Stylesheet
   ========================================================================== */

@media print {

  .site-header,
  .site-footer,
  .lang-switch,
  .policy-sidebar {
    display: none !important;
  }

  body {
    background: #ffffff !important;
    color: #000000 !important;
    font-size: 11pt;
  }

  .wrap {
    max-width: 100% !important;
    padding: 0 !important;
  }

  .policy-layout {
    display: block !important;
  }
}