/* ============================================================
   Defensas Digitales — Sistema de diseño
   Base clara y legible (confianza) + acentos oscuros (seguridad tech)
   + grilla de productos (marketplace)
   ============================================================ */

:root {
  /* Marca */
  --navy: #0b2a4a;        /* autoridad / seguridad */
  --navy-700: #103759;
  --navy-900: #071c33;
  --teal: #14b8a6;        /* acento tech */
  --teal-600: #0d9488;
  --green: #16a34a;       /* seguro / comprar / confianza */
  --green-600: #15803d;
  --amber: #f59e0b;       /* ofertas / destacados */

  /* Neutros */
  --bg: #f6f8fb;
  --surface: #ffffff;
  --line: #e4e9f0;
  --ink: #0f172a;
  --ink-soft: #475569;
  --ink-mute: #94a3b8;

  /* Sistema */
  --radius: 16px;
  --radius-sm: 10px;
  --shadow: 0 1px 2px rgba(16,24,40,.06), 0 6px 20px rgba(16,24,40,.08);
  --shadow-lg: 0 10px 40px rgba(11,42,74,.16);
  --maxw: 1180px;
  --font: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--font);
  color: var(--ink);
  background: var(--bg);
  font-size: 17px;            /* legible para público mayor */
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
.container { max-width: var(--maxw); margin: 0 auto; padding: 0 20px; }
.center { text-align: center; }

/* ---------- Botones ---------- */
.btn {
  display: inline-flex; align-items: center; gap: 8px;
  font-family: inherit; font-size: 1.02rem; font-weight: 700;
  border: 0; border-radius: 999px; padding: 14px 26px;
  cursor: pointer; transition: transform .12s ease, box-shadow .12s ease, background .15s;
  white-space: nowrap;
}
.btn:active { transform: translateY(1px); }
.btn-primary { background: var(--green); color: #fff; box-shadow: 0 6px 16px rgba(22,163,74,.32); }
.btn-primary:hover { background: var(--green-600); }
.btn-teal { background: var(--teal); color: #04231f; box-shadow: 0 6px 16px rgba(20,184,166,.3); }
.btn-teal:hover { background: var(--teal-600); color:#fff; }
.btn-ghost { background: transparent; color: var(--navy); border: 2px solid var(--line); }
.btn-ghost:hover { border-color: var(--teal); color: var(--teal-600); }
.btn-block { width: 100%; justify-content: center; }
.btn-lg { padding: 17px 34px; font-size: 1.1rem; }

/* ---------- Header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(255,255,255,.92); backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
}
.nav { display: flex; align-items: center; justify-content: space-between; height: 72px; gap: 18px; }
.brand { display: flex; align-items: center; gap: 11px; font-weight: 800; font-size: 1.2rem; color: var(--navy); letter-spacing: -.01em; }
.brand svg { width: 34px; height: 34px; flex: none; }
.brand small { display:block; font-weight:600; font-size:.62rem; letter-spacing:.14em; color: var(--teal-600); text-transform: uppercase; margin-top:-2px;}
.nav-links { display: flex; align-items: center; gap: 26px; }
.nav-links a { font-weight: 600; color: var(--ink-soft); font-size: .98rem; }
.nav-links a:hover { color: var(--navy); }
.cart-btn {
  position: relative; display: inline-flex; align-items: center; gap: 8px;
  background: var(--navy); color: #fff; border: 0; border-radius: 999px;
  padding: 10px 18px; font-weight: 700; font-family: inherit; cursor: pointer; font-size:.95rem;
}
.cart-btn:hover { background: var(--navy-700); }
.cart-count {
  position: absolute; top: -7px; right: -7px; min-width: 21px; height: 21px;
  background: var(--amber); color: #3a2500; border-radius: 999px;
  font-size: .72rem; font-weight: 800; display: grid; place-items: center; padding: 0 5px;
}
.nav-toggle { display:none; background:none; border:0; cursor:pointer; }

/* ---------- Hero (oscuro, tech) ---------- */
.hero {
  background:
    radial-gradient(1000px 500px at 82% -10%, rgba(20,184,166,.22), transparent 60%),
    radial-gradient(700px 400px at 5% 110%, rgba(22,163,74,.16), transparent 55%),
    linear-gradient(160deg, var(--navy-900), var(--navy) 60%, var(--navy-700));
  color: #eaf2fb; position: relative; overflow: hidden;
}
.hero::after{
  content:""; position:absolute; inset:0; opacity:.5;
  background-image: radial-gradient(rgba(255,255,255,.05) 1px, transparent 1px);
  background-size: 22px 22px; pointer-events:none;
}
.hero-inner { position: relative; display: grid; grid-template-columns: 1.15fr .85fr; gap: 40px; align-items: center; padding: 68px 20px 76px; }
.hero .eyebrow {
  display:inline-flex; align-items:center; gap:8px;
  background: rgba(20,184,166,.14); border: 1px solid rgba(20,184,166,.35);
  color: #7de9db; font-weight: 700; font-size: .8rem; letter-spacing:.03em;
  padding: 7px 15px; border-radius: 999px; margin-bottom: 20px;
}
.hero h1 { font-size: clamp(2.1rem, 4.6vw, 3.35rem); line-height: 1.08; margin: 0 0 18px; letter-spacing: -.02em; font-weight: 800; }
.hero h1 .hl { color: var(--teal); }
.hero p.lead { font-size: 1.18rem; color: #b9cbe0; max-width: 560px; margin: 0 0 30px; }
.hero-cta { display: flex; gap: 14px; flex-wrap: wrap; }
.hero-trust { display:flex; gap: 22px; margin-top: 30px; flex-wrap: wrap; }
.hero-trust div { display:flex; align-items:center; gap:9px; font-size:.92rem; color:#cdddf0; font-weight:600; }
.hero-trust svg{ width:20px;height:20px;color:var(--teal);flex:none;}
.hero-art { display:grid; place-items:center; }
.hero-shield { width: min(340px, 80%); filter: drop-shadow(0 20px 50px rgba(0,0,0,.4)); }

/* ---------- Franja de confianza ---------- */
.trust-bar { background: var(--surface); border-bottom: 1px solid var(--line); }
.trust-bar .container { display: flex; justify-content: center; flex-wrap: wrap; gap: 34px; padding: 18px 20px; }
.trust-item { display:flex; align-items:center; gap:10px; color: var(--ink-soft); font-weight:600; font-size:.95rem; }
.trust-item svg { width: 22px; height:22px; color: var(--green); flex:none; }

/* ---------- Secciones ---------- */
section { padding: 62px 0; }
.section-head { max-width: 680px; margin: 0 auto 40px; text-align: center; }
.section-head .kicker { color: var(--teal-600); font-weight: 800; letter-spacing:.06em; text-transform: uppercase; font-size:.82rem; }
.section-head h2 { font-size: clamp(1.7rem, 3.2vw, 2.35rem); margin: 10px 0 12px; letter-spacing: -.02em; }
.section-head p { color: var(--ink-soft); font-size: 1.1rem; margin: 0; }

/* ---------- Filtros de categoría ---------- */
.filters { display:flex; gap:10px; justify-content:center; flex-wrap:wrap; margin-bottom: 34px; }
.chip {
  background: var(--surface); border: 1.5px solid var(--line); color: var(--ink-soft);
  padding: 9px 18px; border-radius: 999px; font-weight: 700; font-size:.92rem; cursor: pointer;
  font-family: inherit; transition: all .15s;
}
.chip:hover { border-color: var(--teal); color: var(--teal-600); }
.chip.active { background: var(--navy); border-color: var(--navy); color: #fff; }

/* ---------- Grilla de productos (marketplace) ---------- */
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(268px, 1fr)); gap: 24px; }
.card {
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
  overflow: hidden; display: flex; flex-direction: column;
  transition: transform .15s ease, box-shadow .15s ease, border-color .15s;
}
.card:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); border-color: #d3e6e2; }
.card-media { position: relative; aspect-ratio: 16/10; background: linear-gradient(135deg,#eef4fb,#e7f6f3); }
.card-media img { width:100%; height:100%; object-fit: cover; }
.card-badge {
  position:absolute; top:12px; left:12px; background: var(--amber); color:#3a2500;
  font-weight:800; font-size:.72rem; padding:5px 11px; border-radius:999px; letter-spacing:.02em;
}
.card-app {
  position:absolute; top:12px; right:12px; background: rgba(11,42,74,.9); color:#a7f3ea;
  font-weight:700; font-size:.68rem; padding:5px 10px; border-radius:999px; backdrop-filter: blur(4px);
}
.card-body { padding: 18px 18px 20px; display:flex; flex-direction:column; flex:1; }
.card-cat { color: var(--teal-600); font-weight:800; font-size:.74rem; text-transform:uppercase; letter-spacing:.05em; margin-bottom:7px; }
.card h3 { font-size: 1.12rem; margin: 0 0 8px; line-height:1.28; letter-spacing:-.01em; }
.card p { color: var(--ink-soft); font-size:.94rem; margin: 0 0 16px; flex:1; }
.card-price { display:flex; align-items:baseline; gap:10px; margin-bottom:14px; }
.card-price .now { font-size: 1.5rem; font-weight: 800; color: var(--navy); }
.card-price .was { font-size:.95rem; color: var(--ink-mute); text-decoration: line-through; }
.card-price .off { font-size:.75rem; font-weight:800; color: var(--green); background: #e7f7ee; padding:3px 8px; border-radius:999px; }
.card-actions { display:flex; gap:9px; }
.card-actions .btn { flex:1; padding: 12px 14px; font-size:.95rem; }

/* ---------- Página de producto ---------- */
.pd { display:grid; grid-template-columns: 1fr 1fr; gap: 46px; padding-top: 40px; }
.pd-media { border-radius: var(--radius); overflow:hidden; border:1px solid var(--line); background:linear-gradient(135deg,#eef4fb,#e7f6f3); align-self:start; position:sticky; top:92px; }
.pd-info h1 { font-size: clamp(1.6rem,3vw,2.2rem); margin:8px 0 14px; letter-spacing:-.02em; }
.pd-cat { color: var(--teal-600); font-weight:800; font-size:.8rem; text-transform:uppercase; letter-spacing:.05em; }
.pd-lead { font-size: 1.12rem; color: var(--ink-soft); margin: 0 0 22px; }
.pd-price { display:flex; align-items:baseline; gap:12px; margin: 18px 0; }
.pd-price .now { font-size: 2.2rem; font-weight: 800; color: var(--navy); }
.pd-price .was { font-size:1.1rem; color: var(--ink-mute); text-decoration: line-through; }
.pd-price .off { font-size:.85rem; font-weight:800; color:#fff; background: var(--green); padding:4px 11px; border-radius:999px; }
.pd-buy { display:flex; gap:12px; margin: 22px 0; flex-wrap:wrap; }
.pd-buy .btn { flex:1; min-width:180px; }
.pd-section { margin-top: 30px; padding-top: 26px; border-top:1px solid var(--line); }
.pd-section h3 { font-size:1.2rem; margin:0 0 14px; }
.pd-list { list-style:none; padding:0; margin:0; display:grid; gap:11px; }
.pd-list li { display:flex; align-items:flex-start; gap:11px; color: var(--ink-soft); }
.pd-list li svg { width:22px; height:22px; color: var(--green); flex:none; margin-top:1px; }
.pd-format { display:inline-flex; align-items:center; gap:9px; background:#eef7f5; color: var(--teal-600); font-weight:700; padding:10px 16px; border-radius: var(--radius-sm); font-size:.92rem; }
.pd-app-note { background: var(--navy); color:#cdeee9; border-radius: var(--radius); padding:18px 20px; margin-top:22px; display:flex; gap:14px; align-items:center; }
.pd-app-note svg{width:34px;height:34px;color:var(--teal);flex:none;}
.pd-app-note strong{color:#fff;}

/* ---------- Carrito (drawer) ---------- */
.drawer-overlay { position: fixed; inset:0; background: rgba(7,28,51,.5); opacity:0; visibility:hidden; transition: .2s; z-index: 90; }
.drawer-overlay.open { opacity:1; visibility:visible; }
.drawer {
  position: fixed; top:0; right:0; height:100%; width: min(420px, 100%);
  background: var(--surface); z-index: 91; transform: translateX(100%); transition: transform .25s ease;
  display:flex; flex-direction:column; box-shadow: -10px 0 40px rgba(7,28,51,.2);
}
.drawer.open { transform: translateX(0); }
.drawer-head { display:flex; align-items:center; justify-content:space-between; padding: 20px; border-bottom:1px solid var(--line); }
.drawer-head h3 { margin:0; font-size:1.2rem; }
.drawer-close { background:none; border:0; cursor:pointer; color: var(--ink-soft); font-size:1.5rem; line-height:1; }
.drawer-body { flex:1; overflow-y:auto; padding: 12px 20px; }
.cart-line { display:flex; gap:12px; padding: 14px 0; border-bottom:1px solid var(--line); }
.cart-line img { width:64px; height:64px; border-radius:10px; object-fit:cover; flex:none; border:1px solid var(--line); }
.cart-line .cl-info { flex:1; }
.cart-line h4 { margin:0 0 4px; font-size:.98rem; }
.cart-line .cl-price { font-weight:800; color: var(--navy); }
.cart-line .cl-remove { background:none;border:0;color:var(--ink-mute);cursor:pointer;font-size:.85rem;text-decoration:underline; padding:0; margin-top:6px;}
.cart-empty { text-align:center; color: var(--ink-mute); padding: 50px 20px; }
.drawer-foot { padding: 20px; border-top:1px solid var(--line); }
.drawer-total { display:flex; justify-content:space-between; font-size:1.25rem; font-weight:800; margin-bottom:16px; color: var(--navy); }

/* ---------- Checkout ---------- */
.checkout { display:grid; grid-template-columns: 1.2fr .8fr; gap:36px; padding-top:36px; align-items:start; }
.co-card { background:var(--surface); border:1px solid var(--line); border-radius:var(--radius); padding:26px; }
.co-card h3 { margin:0 0 18px; font-size:1.2rem; }
.field { margin-bottom:16px; }
.field label { display:block; font-weight:700; font-size:.9rem; margin-bottom:6px; color: var(--ink); }
.field input {
  width:100%; padding:13px 15px; border:1.5px solid var(--line); border-radius: var(--radius-sm);
  font-family:inherit; font-size:1rem; transition: border .15s;
}
.field input:focus { outline:none; border-color: var(--teal); box-shadow:0 0 0 3px rgba(20,184,166,.15); }
.field .hint { font-size:.82rem; color: var(--ink-mute); margin-top:5px; }
.summary-line { display:flex; justify-content:space-between; padding:10px 0; border-bottom:1px dashed var(--line); font-size:.96rem; }
.summary-total { display:flex; justify-content:space-between; padding-top:16px; font-size:1.35rem; font-weight:800; color:var(--navy); }
.co-secure { display:flex; align-items:center; gap:10px; margin-top:18px; color:var(--ink-soft); font-size:.86rem; }
.co-secure svg{width:20px;height:20px;color:var(--green);flex:none;}
.mp-note { display:flex; align-items:center; gap:10px; background:#eef6ff; border:1px solid #d3e6fb; border-radius:var(--radius-sm); padding:13px 15px; font-size:.9rem; color:#1d4e6b; margin-top:16px; }

/* ---------- Páginas de resultado ---------- */
.result { max-width:600px; margin:0 auto; text-align:center; padding: 70px 20px; }
.result-icon { width:88px; height:88px; margin:0 auto 24px; border-radius:50%; display:grid; place-items:center; }
.result-icon svg { width:46px; height:46px; }
.result-icon.ok { background:#e7f7ee; color: var(--green); }
.result-icon.pending { background:#fff4e0; color: var(--amber); }
.result-icon.err { background:#fdeaea; color:#dc2626; }
.result h1 { font-size:1.9rem; margin:0 0 12px; }
.result p { color:var(--ink-soft); font-size:1.1rem; margin:0 0 26px; }

/* ---------- ¿Por qué? / valor ---------- */
.value-grid { display:grid; grid-template-columns: repeat(auto-fit,minmax(260px,1fr)); gap:22px; }
.value-card { background:var(--surface); border:1px solid var(--line); border-radius:var(--radius); padding:26px; }
.value-card .vi { width:52px; height:52px; border-radius:14px; background:linear-gradient(135deg,var(--navy),var(--navy-700)); display:grid; place-items:center; margin-bottom:16px; }
.value-card .vi svg{ width:26px;height:26px;color:var(--teal); }
.value-card h3 { margin:0 0 8px; font-size:1.15rem; }
.value-card p { margin:0; color:var(--ink-soft); font-size:.96rem; }

/* ---------- CTA final ---------- */
.cta-band { background: linear-gradient(160deg,var(--navy-900),var(--navy)); color:#eaf2fb; border-radius: 24px; padding: 50px 40px; text-align:center; margin: 20px 0; }
.cta-band h2 { font-size: clamp(1.6rem,3vw,2.2rem); margin:0 0 12px; }
.cta-band p { color:#b9cbe0; font-size:1.1rem; margin:0 0 26px; }

/* ---------- Footer ---------- */
.site-footer { background: var(--navy-900); color:#9db4ce; padding: 50px 0 30px; margin-top: 40px; }
.footer-grid { display:grid; grid-template-columns: 1.5fr 1fr 1fr; gap:30px; margin-bottom:34px; }
.site-footer .brand { color:#fff; margin-bottom:14px; }
.site-footer h4 { color:#fff; font-size:.95rem; margin:0 0 14px; }
.site-footer a { display:block; color:#9db4ce; padding:5px 0; font-size:.93rem; }
.site-footer a:hover { color: var(--teal); }
.footer-bottom { border-top:1px solid rgba(255,255,255,.1); padding-top:22px; display:flex; justify-content:space-between; flex-wrap:wrap; gap:12px; font-size:.85rem; color:#6b829d; }

/* ---------- Toast ---------- */
.toast {
  position: fixed; bottom: 26px; left: 50%; transform: translateX(-50%) translateY(20px);
  background: var(--navy); color:#fff; padding:14px 22px; border-radius: 999px; font-weight:700;
  box-shadow: var(--shadow-lg); opacity:0; visibility:hidden; transition:.25s; z-index:100; display:flex; align-items:center; gap:10px;
}
.toast.show { opacity:1; visibility:visible; transform: translateX(-50%) translateY(0); }
.toast svg{width:20px;height:20px;color:var(--teal);}

/* ---------- Responsive ---------- */
@media (max-width: 860px) {
  .hero-inner { grid-template-columns: 1fr; text-align:center; padding: 48px 20px 56px; }
  .hero-art { order:-1; }
  .hero-shield { width: 200px; }
  .hero-cta, .hero-trust { justify-content:center; }
  .hero p.lead { margin-left:auto; margin-right:auto; }
  .pd { grid-template-columns: 1fr; gap:30px; }
  .pd-media { position:static; }
  .checkout { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 620px) {
  body { font-size: 16px; }
  .nav-links { display:none; }
  .footer-grid { grid-template-columns: 1fr; }
}
