/* ===========================================================
   Pliego Files — Landing page
   Estética: oscura, moderna, azul Pliego (#2E6BE6 / #598FFA)
   =========================================================== */

:root {
  --brand: #3b82f6;
  --brand-2: #598ffa;
  --cyan: #22d3ee;
  --violet: #7c3aed;

  --bg: #070b16;
  --bg-2: #0b1120;
  --card: rgba(255, 255, 255, 0.045);
  --card-brd: rgba(255, 255, 255, 0.09);
  --card-brd-hi: rgba(255, 255, 255, 0.18);

  --text: #eef2fb;
  --muted: #9aa7c2;
  --dim: #6b7794;

  --grad: linear-gradient(135deg, var(--brand) 0%, var(--cyan) 100%);
  --radius: 20px;
  --maxw: 1180px;
  --ease: cubic-bezier(.22, 1, .36, 1);
}

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

html { scroll-behavior: smooth; }

body {
  font-family: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

.container { width: 100%; max-width: var(--maxw); margin: 0 auto; padding: 0 24px; }

a { color: inherit; text-decoration: none; }

.grad-text {
  background: linear-gradient(120deg, var(--brand-2), var(--cyan));
  -webkit-background-clip: text; background-clip: text;
  -webkit-text-fill-color: transparent;
}

/* ---------- Fondo aurora animado ---------- */
.bg-aurora {
  position: fixed; inset: 0; z-index: -1; overflow: hidden;
  background:
    radial-gradient(1200px 800px at 80% -10%, rgba(34, 211, 238, .10), transparent 60%),
    radial-gradient(1000px 700px at 10% 10%, rgba(59, 130, 246, .14), transparent 55%),
    var(--bg);
}
.blob {
  position: absolute; border-radius: 50%; filter: blur(80px); opacity: .5;
  animation: float 22s var(--ease) infinite;
}
.blob-1 { width: 520px; height: 520px; top: -120px; left: -80px;
  background: radial-gradient(circle, #2563eb, transparent 70%); }
.blob-2 { width: 600px; height: 600px; top: 30%; right: -160px;
  background: radial-gradient(circle, #06b6d4, transparent 70%); animation-delay: -7s; }
.blob-3 { width: 460px; height: 460px; bottom: -120px; left: 30%;
  background: radial-gradient(circle, #7c3aed, transparent 70%); animation-delay: -14s; opacity: .35; }
@keyframes float {
  0%, 100% { transform: translate(0, 0) scale(1); }
  33% { transform: translate(60px, 40px) scale(1.1); }
  66% { transform: translate(-40px, 20px) scale(.95); }
}
.grid-overlay {
  position: absolute; inset: 0;
  background-image:
    linear-gradient(rgba(255, 255, 255, .025) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, .025) 1px, transparent 1px);
  background-size: 54px 54px;
  mask-image: radial-gradient(circle at 50% 30%, black, transparent 75%);
}

/* ---------- Navegación ---------- */
.nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 100;
  transition: background .4s var(--ease), box-shadow .4s var(--ease), backdrop-filter .4s;
}
.nav.scrolled {
  background: rgba(8, 12, 22, .72);
  backdrop-filter: saturate(150%) blur(18px);
  box-shadow: 0 1px 0 rgba(255, 255, 255, .06);
}
.nav-inner { display: flex; align-items: center; justify-content: space-between; height: 70px; }
.brand { display: flex; align-items: center; gap: 10px; font-weight: 700; }
.brand-logo { display: grid; place-items: center; filter: drop-shadow(0 4px 12px rgba(59, 130, 246, .5)); }
.brand-name { font-size: 18px; letter-spacing: -.02em; }
.brand-name b { font-weight: 800; }

.nav-links { display: flex; align-items: center; gap: 30px; }
.nav-links a { color: var(--muted); font-size: 15px; font-weight: 500; transition: color .2s; }
.nav-links a:hover { color: var(--text); }
.nav-cta {
  background: var(--grad); color: #fff !important; padding: 9px 18px; border-radius: 999px;
  font-weight: 600 !important; box-shadow: 0 6px 20px rgba(59, 130, 246, .35);
  transition: transform .2s var(--ease), box-shadow .2s;
}
.nav-cta:hover { transform: translateY(-2px); box-shadow: 0 10px 28px rgba(59, 130, 246, .5); }

/* Selector de idioma */
.lang { display: inline-flex; border: 1px solid var(--card-brd); border-radius: 999px; overflow: hidden; }
.lang a { padding: 6px 12px; font-size: 13px; font-weight: 700; color: var(--muted); transition: background .2s, color .2s; }
.lang a:hover { color: var(--text); }
.lang a.active { background: rgba(59, 130, 246, .2); color: #fff; }

.footer-lang { margin-top: 6px; }
.footer-lang a { color: var(--brand-2); font-size: 14px; font-weight: 600; }
.footer-lang a:hover { text-decoration: underline; }

.nav-toggle { display: none; flex-direction: column; gap: 5px; background: none; border: 0; cursor: pointer; padding: 8px; }
.nav-toggle span { width: 24px; height: 2px; background: var(--text); border-radius: 2px; transition: .3s var(--ease); }
.nav-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.nav-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ---------- Hero ---------- */
.hero { padding: 150px 0 80px; }
.hero-grid { display: grid; grid-template-columns: 1.05fr .95fr; gap: 48px; align-items: center; }
.hero-copy h1 {
  font-size: clamp(40px, 6vw, 72px); line-height: 1.04; font-weight: 900;
  letter-spacing: -.035em; margin: 22px 0 20px;
}
.lead { font-size: clamp(16px, 2vw, 19px); color: var(--muted); max-width: 540px; }
.lead b { color: var(--text); font-weight: 600; }

.pill {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 7px 15px; border-radius: 999px; font-size: 13px; font-weight: 600;
  background: rgba(59, 130, 246, .12); border: 1px solid rgba(59, 130, 246, .3); color: #bcd4ff;
}
.pill .dot { width: 8px; height: 8px; border-radius: 50%; background: #34d399; box-shadow: 0 0 0 0 rgba(52, 211, 153, .6); animation: pulse 2s infinite; }
@keyframes pulse { 0% { box-shadow: 0 0 0 0 rgba(52, 211, 153, .5); } 70% { box-shadow: 0 0 0 9px rgba(52, 211, 153, 0); } 100% { box-shadow: 0 0 0 0 rgba(52, 211, 153, 0); } }

.hero-actions { display: flex; flex-wrap: wrap; gap: 14px; margin: 30px 0 22px; }
.btn {
  display: inline-flex; align-items: center; gap: 10px; padding: 14px 26px;
  border-radius: 14px; font-weight: 600; font-size: 16px; cursor: pointer;
  transition: transform .2s var(--ease), box-shadow .2s, background .2s; border: 1px solid transparent;
}
.btn-primary { background: var(--grad); color: #fff; box-shadow: 0 10px 30px rgba(59, 130, 246, .4); }
.btn-primary:hover { transform: translateY(-3px); box-shadow: 0 16px 40px rgba(59, 130, 246, .55); }
.btn-ghost { background: rgba(255, 255, 255, .05); border-color: var(--card-brd); color: var(--text); }
.btn-ghost:hover { background: rgba(255, 255, 255, .1); transform: translateY(-3px); }
.btn-lg { padding: 17px 34px; font-size: 17px; }

.trust { display: flex; flex-wrap: wrap; gap: 18px; color: var(--dim); font-size: 14px; font-weight: 500; }

/* ---------- Maqueta de teléfono ---------- */
.hero-visual { position: relative; display: grid; place-items: center; }
.phone {
  position: relative; width: 290px; height: 590px; border-radius: 46px;
  background: linear-gradient(160deg, #1a2236, #0c1120);
  border: 1px solid rgba(255, 255, 255, .12);
  box-shadow: 0 40px 90px rgba(0, 0, 0, .55), inset 0 0 0 6px #05080f;
  padding: 14px; animation: phoneFloat 6s ease-in-out infinite;
}
@keyframes phoneFloat { 0%, 100% { transform: translateY(0) rotate(-1deg); } 50% { transform: translateY(-16px) rotate(1deg); } }
.phone-notch { position: absolute; top: 16px; left: 50%; transform: translateX(-50%); width: 120px; height: 26px; background: #05080f; border-radius: 0 0 16px 16px; z-index: 3; }
.phone-screen {
  height: 100%; border-radius: 34px; overflow: hidden; position: relative;
  background: linear-gradient(180deg, #0d1424, #0a0f1d); padding: 40px 16px 16px;
}
.app-bar { display: flex; justify-content: space-between; align-items: center; margin-bottom: 14px; }
.app-title { font-size: 19px; font-weight: 800; letter-spacing: -.02em; }
.app-dots { color: var(--brand-2); font-weight: 800; }
.app-search { background: rgba(255, 255, 255, .06); border-radius: 11px; padding: 9px 12px; font-size: 12px; color: var(--dim); margin-bottom: 14px; }
.app-list { list-style: none; display: flex; flex-direction: column; gap: 9px; }
.app-list li { display: flex; align-items: center; gap: 11px; background: rgba(255, 255, 255, .04); border: 1px solid rgba(255, 255, 255, .05); padding: 10px 11px; border-radius: 13px; animation: rowIn .6s var(--ease) backwards; }
.app-list li:nth-child(1) { animation-delay: .2s; } .app-list li:nth-child(2) { animation-delay: .32s; }
.app-list li:nth-child(3) { animation-delay: .44s; } .app-list li:nth-child(4) { animation-delay: .56s; }
.app-list li:nth-child(5) { animation-delay: .68s; }
@keyframes rowIn { from { opacity: 0; transform: translateX(14px); } to { opacity: 1; transform: none; } }
.app-list i { width: 38px; height: 38px; border-radius: 10px; display: grid; place-items: center; font-size: 18px; font-style: normal; background: color-mix(in srgb, var(--c) 26%, transparent); }
.app-list b { display: block; font-size: 14px; }
.app-list small { color: var(--dim); font-size: 11px; }
.app-fab { position: absolute; right: 18px; bottom: 18px; width: 50px; height: 50px; border-radius: 50%; background: var(--grad); display: grid; place-items: center; font-size: 26px; color: #fff; box-shadow: 0 10px 26px rgba(59, 130, 246, .5); }

.float-card {
  position: absolute; padding: 11px 16px; border-radius: 14px; font-weight: 700; font-size: 14px;
  background: rgba(15, 22, 40, .8); backdrop-filter: blur(12px);
  border: 1px solid var(--card-brd-hi); box-shadow: 0 16px 40px rgba(0, 0, 0, .4);
  animation: cardFloat 5s ease-in-out infinite;
}
.fc-1 { top: 12%; left: -8%; animation-delay: 0s; }
.fc-2 { top: 46%; right: -10%; animation-delay: -1.6s; }
.fc-3 { bottom: 10%; left: -6%; animation-delay: -3.2s; }
@keyframes cardFloat { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-14px); } }

/* ---------- Stats ---------- */
.stats { padding: 30px 0 10px; }
.stats-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 18px; }
.stat { text-align: center; padding: 26px 12px; background: var(--card); border: 1px solid var(--card-brd); border-radius: var(--radius); }
.stat b { display: block; font-size: clamp(30px, 4vw, 46px); font-weight: 900; letter-spacing: -.03em;
  background: linear-gradient(120deg, var(--brand-2), var(--cyan)); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; }
.stat span { color: var(--muted); font-size: 14px; }

/* ---------- Secciones ---------- */
.section { padding: 90px 0; }
.section-head { text-align: center; max-width: 680px; margin: 0 auto 56px; }
.eyebrow { color: var(--brand-2); font-weight: 700; font-size: 14px; letter-spacing: .08em; text-transform: uppercase; }
.section-head h2 { font-size: clamp(30px, 4.4vw, 46px); font-weight: 900; letter-spacing: -.03em; margin: 12px 0 14px; line-height: 1.1; }
.section-head p { color: var(--muted); font-size: 17px; }

/* ---------- Cards de características ---------- */
.cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; }
.card {
  position: relative; background: var(--card); border: 1px solid var(--card-brd);
  border-radius: var(--radius); padding: 30px 26px; overflow: hidden;
  transition: transform .35s var(--ease), border-color .35s, background .35s;
}
.card::before {
  content: ""; position: absolute; inset: 0; padding: 1px; border-radius: inherit;
  background: linear-gradient(135deg, var(--g)); -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor; mask-composite: exclude; opacity: 0; transition: opacity .35s;
}
.card:hover { transform: translateY(-8px); background: rgba(255, 255, 255, .07); border-color: transparent; }
.card:hover::before { opacity: 1; }
.card-ico {
  width: 56px; height: 56px; border-radius: 16px; display: grid; place-items: center; font-size: 28px;
  background: linear-gradient(135deg, var(--g)); margin-bottom: 18px;
  box-shadow: 0 10px 26px color-mix(in srgb, var(--g) 50%, transparent);
}
.card h3 { font-size: 21px; font-weight: 800; letter-spacing: -.02em; margin-bottom: 8px; }
.card p { color: var(--muted); font-size: 15px; }
.card p b { color: var(--text); }
.feat-vault { background: linear-gradient(180deg, rgba(124, 58, 237, .12), var(--card)); }

/* ---------- Privacidad ---------- */
.privacy { position: relative; }
.privacy-grid { display: grid; grid-template-columns: 1.1fr .9fr; gap: 50px; align-items: center; }
.privacy-copy h2 { font-size: clamp(30px, 4.4vw, 48px); font-weight: 900; letter-spacing: -.03em; margin: 12px 0 16px; line-height: 1.08; }
.check-list { list-style: none; margin-top: 26px; display: flex; flex-direction: column; gap: 14px; }
.check-list li { position: relative; padding-left: 36px; color: var(--muted); font-size: 16px; }
.check-list li b { color: var(--text); }
.check-list li::before {
  content: "✓"; position: absolute; left: 0; top: 1px; width: 24px; height: 24px; border-radius: 7px;
  background: rgba(34, 211, 238, .15); color: var(--cyan); font-weight: 800; display: grid; place-items: center; font-size: 13px;
}
.privacy-visual { display: grid; place-items: center; }
.shield { position: relative; display: grid; place-items: center; }
.shield svg { position: relative; z-index: 2; filter: drop-shadow(0 12px 40px rgba(34, 211, 238, .35)); animation: cardFloat 6s ease-in-out infinite; }
.ring { position: absolute; border-radius: 50%; border: 1px solid rgba(34, 211, 238, .25); }
.ring-1 { width: 260px; height: 260px; animation: spin 18s linear infinite; }
.ring-2 { width: 340px; height: 340px; border-style: dashed; border-color: rgba(59, 130, 246, .2); animation: spin 28s linear infinite reverse; }
@keyframes spin { to { transform: rotate(360deg); } }

/* ---------- Protocolos ---------- */
.proto-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; }
.proto {
  background: var(--card); border: 1px solid var(--card-brd); border-radius: 16px; padding: 22px 20px;
  transition: transform .3s var(--ease), border-color .3s, background .3s;
}
.proto:hover { transform: translateY(-5px); border-color: var(--card-brd-hi); background: rgba(255, 255, 255, .06); }
.proto b { display: block; font-size: 19px; font-weight: 800; letter-spacing: -.02em; background: linear-gradient(120deg, var(--brand-2), var(--cyan)); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; }
.proto span { color: var(--dim); font-size: 13px; }

/* ---------- Herramientas ---------- */
.tools .tool-grid { display: flex; flex-wrap: wrap; gap: 14px; justify-content: center; }
.tool {
  padding: 13px 22px; border-radius: 999px; background: var(--card); border: 1px solid var(--card-brd);
  font-weight: 600; font-size: 15px; color: var(--text); transition: transform .25s var(--ease), border-color .25s, background .25s;
}
.tool:hover { transform: translateY(-4px) scale(1.04); border-color: var(--brand); background: rgba(59, 130, 246, .12); }

/* ---------- Descarga / CTA ---------- */
.download { padding-bottom: 110px; }
.cta {
  position: relative; text-align: center; padding: 70px 40px; border-radius: 32px; overflow: hidden;
  background: linear-gradient(160deg, rgba(59, 130, 246, .14), rgba(34, 211, 238, .06));
  border: 1px solid rgba(59, 130, 246, .25);
}
.cta-glow { position: absolute; top: -50%; left: 50%; transform: translateX(-50%); width: 600px; height: 600px; background: radial-gradient(circle, rgba(59, 130, 246, .35), transparent 60%); filter: blur(30px); z-index: 0; }
.cta > * { position: relative; z-index: 1; }
.cta h2 { font-size: clamp(30px, 5vw, 50px); font-weight: 900; letter-spacing: -.03em; margin: 18px 0 12px; }
.cta p { color: var(--muted); font-size: 18px; max-width: 540px; margin: 0 auto 30px; }
.cta .btn-primary[aria-disabled="true"] { opacity: .96; cursor: default; }
.cta-note { display: block; margin-top: 18px; color: var(--dim); font-size: 14px; }

/* ---------- Footer ---------- */
.footer { border-top: 1px solid var(--card-brd); padding: 50px 0; }
.footer-inner { text-align: center; display: flex; flex-direction: column; gap: 8px; align-items: center; }
.footer .brand-name { font-size: 20px; }
.footer-tag { color: var(--brand-2); font-weight: 600; }
.footer-legal { color: var(--dim); font-size: 14px; }

/* ---------- Animaciones de aparición ---------- */
.reveal { opacity: 0; transform: translateY(28px); transition: opacity .7s var(--ease), transform .7s var(--ease); }
.reveal.visible { opacity: 1; transform: none; }

/* ---------- Responsive ---------- */
@media (max-width: 980px) {
  .hero-grid, .privacy-grid { grid-template-columns: 1fr; }
  .hero { padding-top: 120px; text-align: center; }
  .lead { margin-inline: auto; }
  .hero-actions, .trust { justify-content: center; }
  .hero-visual { margin-top: 30px; }
  .cards { grid-template-columns: repeat(2, 1fr); }
  .stats-grid, .proto-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 640px) {
  .nav-links {
    position: fixed; inset: 70px 0 auto 0; flex-direction: column; gap: 0;
    background: rgba(8, 12, 22, .96); backdrop-filter: blur(20px); padding: 10px 0;
    border-bottom: 1px solid var(--card-brd); transform: translateY(-130%); transition: transform .35s var(--ease);
  }
  .nav-links.open { transform: translateY(0); }
  .nav-links a { padding: 14px 24px; width: 100%; }
  .nav-links .lang { margin: 10px 24px; align-self: flex-start; }
  .nav-links .lang a { width: auto; padding: 8px 16px; }
  .nav-cta { margin: 8px 24px; text-align: center; }
  .nav-toggle { display: flex; }
  .cards { grid-template-columns: 1fr; }
  .float-card { display: none; }
  .cta { padding: 50px 22px; }
}

/* ---------- Accesibilidad: respeta "reducir movimiento" ---------- */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
  .reveal { opacity: 1; transform: none; }
}
