:root {
  --primary: #1a365d;
  --primary-light: #2d4a7c;
  --accent: #D4AF37;
  --bg: #f4f6f8;
  --surface: #fff;
  --text: #1c140d;
  --text-muted: #4b5563;
  --footer-bg: #0d1b3e;
  --radius: 20px;
  --shadow: 0 4px 14px rgba(26, 54, 93, 0.08);
}

* { box-sizing: border-box; margin: 0; padding: 0; }

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }

body {
  font-family: 'Manrope', system-ui, sans-serif;
  background: var(--bg);
  color: var(--text);
  min-height: 100vh;
  line-height: 1.6;
  font-size: 15px;
}

a { color: var(--primary); font-weight: 600; text-decoration: none; }
a:hover { text-decoration: underline; }

.site-header {
  background: var(--surface);
  border-bottom: 1px solid rgba(26, 54, 93, 0.08);
  position: sticky;
  top: 0;
  z-index: 10;
}

.site-header-inner {
  max-width: 1080px;
  margin: 0 auto;
  padding: 14px 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 800;
  font-size: 1.25rem;
  color: var(--primary);
  text-decoration: none;
}

.brand:hover { text-decoration: none; }

.brand-name-delivery {
  font-weight: 700;
  color: var(--accent);
}

.hero-tagline {
  font-size: clamp(1.05rem, 2vw, 1.25rem);
  opacity: 0.92;
  margin-bottom: 14px;
}

.brand-mark {
  width: 38px;
  height: 38px;
  border-radius: 10px;
  background: url('/icons/Icon-512.png') center / cover no-repeat;
  /* Oculta la "Z" del HTML: ahora se muestra el logo real de la app */
  color: transparent;
  font-size: 0;
  overflow: hidden;
  flex-shrink: 0;
}

.nav-links {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 20px;
  align-items: center;
}

.nav-links a {
  color: var(--text-muted);
  font-weight: 600;
  font-size: 0.92rem;
}

.nav-links a:hover,
.nav-links a.active {
  color: var(--primary);
  text-decoration: none;
}

/* Los botones dentro del nav conservan su color propio (evita que .nav-links a los pise) */
.nav-links a.btn-primary,
.nav-links a.btn-primary:hover { color: #fff; }
.nav-links a.btn-outline,
.nav-links a.btn-outline:hover { color: var(--primary); }

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 22px;
  border-radius: 14px;
  font-family: inherit;
  font-weight: 700;
  font-size: 0.95rem;
  border: none;
  cursor: pointer;
  text-decoration: none;
  transition: transform 0.12s ease, box-shadow 0.12s ease;
}

.btn:hover { text-decoration: none; transform: translateY(-1px); }

.btn-primary {
  background: var(--primary);
  color: #fff;
  box-shadow: 0 4px 14px rgba(26, 54, 93, 0.22);
}

.btn-outline {
  background: var(--surface);
  color: var(--primary);
  border: 2px solid rgba(26, 54, 93, 0.15);
}

.hero {
  background: linear-gradient(135deg, var(--primary) 0%, #0d2847 100%);
  color: #fff;
  padding: 56px 20px 64px;
}

.hero-inner {
  max-width: 1080px;
  margin: 0 auto;
}

.hero-badge {
  display: inline-block;
  background: rgba(240, 200, 75, 0.18);
  color: #f5d372;
  border: 1px solid rgba(240, 200, 75, 0.45);
  padding: 6px 14px;
  border-radius: 999px;
  font-size: 0.8rem;
  font-weight: 800;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  margin-bottom: 16px;
}

.hero h1 {
  font-size: clamp(1.85rem, 4vw, 2.75rem);
  font-weight: 800;
  line-height: 1.15;
  margin-bottom: 14px;
  max-width: 720px;
}

.hero p {
  font-size: 1.05rem;
  color: rgba(255, 255, 255, 0.88);
  max-width: 640px;
  line-height: 1.55;
}

.wrap {
  max-width: 1080px;
  margin: 0 auto;
  padding: 40px 20px 56px;
}

.section {
  background: var(--surface);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 28px 24px;
  margin-bottom: 18px;
}

.section h2 {
  font-size: 1.2rem;
  font-weight: 800;
  color: var(--primary);
  margin-bottom: 12px;
}

.section p,
.section li {
  margin-bottom: 10px;
  color: var(--text);
}

.section ul { padding-left: 1.25rem; }

.muted { color: var(--text-muted); font-size: 0.92rem; }

.grid-2 {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 18px;
}

.card {
  background: var(--surface);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 24px;
  border: 1px solid rgba(26, 54, 93, 0.06);
}

.card h3 {
  font-size: 1.05rem;
  font-weight: 800;
  color: var(--primary);
  margin-bottom: 8px;
}

.card p { color: var(--text-muted); margin-bottom: 16px; font-size: 0.95rem; }

.stat-row {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 14px;
  margin-top: 8px;
}

.stat {
  background: rgba(26, 54, 93, 0.06);
  border-radius: 16px;
  padding: 18px 16px;
  text-align: center;
}

.stat strong {
  display: block;
  font-size: 1.5rem;
  color: var(--primary);
  font-weight: 800;
}

.stat span {
  font-size: 0.85rem;
  color: var(--text-muted);
}

.blog-card {
  display: flex;
  flex-direction: column;
  height: 100%;
}

.blog-meta {
  font-size: 0.8rem;
  color: var(--text-muted);
  margin-bottom: 8px;
}

.blog-tag {
  display: inline-block;
  background: rgba(26, 54, 93, 0.08);
  color: var(--primary);
  padding: 4px 10px;
  border-radius: 999px;
  font-size: 0.75rem;
  font-weight: 700;
  margin-bottom: 10px;
}

.site-footer {
  background: var(--footer-bg);
  color: rgba(255, 255, 255, 0.75);
  padding: 40px 20px 28px;
  margin-top: 24px;
}

.site-footer-inner {
  max-width: 1080px;
  margin: 0 auto;
}

.site-footer a { color: rgba(255, 255, 255, 0.85); }

.footer-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 28px;
  margin-bottom: 28px;
}

.footer-grid h4 {
  color: #fff;
  font-size: 0.95rem;
  margin-bottom: 12px;
}

.footer-grid ul { list-style: none; }

.footer-grid li { margin-bottom: 8px; }

.footer-grid a {
  font-weight: 500;
  font-size: 0.9rem;
  color: rgba(255, 255, 255, 0.65);
  text-decoration: none;
}

.footer-grid a:hover { color: #fff; text-decoration: none; }

.footer-copy {
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  padding-top: 20px;
  font-size: 0.85rem;
  text-align: center;
}

/* ===== Documentos legales (versión web) ===== */
.doc-layout {
  display: grid;
  grid-template-columns: 240px 1fr;
  gap: 28px;
  align-items: start;
}

.doc-toc {
  position: sticky;
  top: 84px;
  background: var(--surface);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 18px 16px;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.doc-toc h4 {
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--text-muted);
  margin-bottom: 8px;
}

.doc-toc a {
  color: var(--text-muted);
  font-weight: 600;
  font-size: 0.9rem;
  padding: 6px 10px;
  border-radius: 8px;
  line-height: 1.3;
}

.doc-toc a:hover { background: rgba(26, 54, 93, 0.06); color: var(--primary); text-decoration: none; }

#doc-intro { margin-bottom: 8px; }

@media (max-width: 860px) {
  .doc-layout { grid-template-columns: 1fr; }
  .doc-toc { position: static; }
}

@media (max-width: 640px) {
  .nav-links .hide-mobile { display: none; }
  .hero { padding: 40px 20px 48px; }
}
