/* ============================================================
   JMSYSTEMS — ESTILOS (v2, tema claro)
   Paleta clara tomada directamente del logo: fondo casi blanco,
   azul y cian como acentos, para que el logo se integre sin caja
   de color detrás.
   Tipografía: Space Grotesk (títulos) + Inter (texto) + JetBrains Mono (datos)
   Elemento de firma: traza de circuito (PCB trace) que recorre la página.
   ============================================================ */

:root{
  --bg: #f6f9fd;
  --bg-alt: #eef3fa;
  --panel: #ffffff;
  --panel-border: #dde6f2;
  --panel-hover: #f2f6fc;

  --text: #10192e;
  --text-dim: #4c5972;
  --text-faint: #8492ab;

  --cyan: #17ABE3;
  --cyan-soft: #0e93c7;
  --cyan-tint: #e6f7fd;
  --blue: #145DA0;
  --blue-deep: #0d3e73;

  --success: #1fa972;

  --radius-lg: 18px;
  --radius-md: 12px;
  --radius-sm: 8px;

  --font-display: 'Space Grotesk', sans-serif;
  --font-body: 'Inter', sans-serif;
  --font-mono: 'JetBrains Mono', monospace;

  --maxw: 1180px;
  --shadow-card: 0 1px 2px rgba(16,25,46,0.04), 0 10px 24px -14px rgba(16,25,46,0.12);
  --shadow-card-hover: 0 4px 10px rgba(16,25,46,0.06), 0 18px 34px -16px rgba(23,171,227,0.28);
}

@media (prefers-reduced-motion: reduce){
  *{ animation-duration: 0.001ms !important; animation-iteration-count: 1 !important; transition-duration: 0.001ms !important; scroll-behavior: auto !important; }
}

*, *::before, *::after{ box-sizing: border-box; }
html{ scroll-behavior: smooth; }
body{
  margin:0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
}
img{ max-width:100%; display:block; }
a{ color: inherit; text-decoration: none; }
ul{ margin:0; padding:0; list-style:none; }
h1,h2,h3,h4{ font-family: var(--font-display); margin:0; font-weight:600; letter-spacing:-0.01em; }
p{ margin:0; }
button{ font-family: inherit; cursor:pointer; }

.container{ max-width: var(--maxw); margin: 0 auto; padding: 0 24px; }
.eyebrow{
  font-family: var(--font-mono);
  font-size: 12.5px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--cyan-soft);
  display:flex; align-items:center; gap:10px;
}
.eyebrow::before{
  content:"";
  width:22px; height:1px; background: var(--cyan);
  display:inline-block;
}
.section{ position: relative; padding: 100px 0; }
.section-head{ max-width: 640px; margin-bottom: 52px; }
.section-head h2{ font-size: clamp(28px, 3.4vw, 40px); margin-top:14px; }
.section-head p{ color: var(--text-dim); margin-top:14px; font-size: 16.5px; }

a:focus-visible, button:focus-visible, .cat-tab:focus-visible{
  outline: 2px solid var(--cyan);
  outline-offset: 3px;
  border-radius: 4px;
}

/* ============================================================
   CIRCUIT SPINE — signature element
   ============================================================ */
.circuit-spine{
  position: fixed; left: 0; top: 0; bottom: 0; width: 46px;
  pointer-events: none; z-index: 5; display: none;
}
@media (min-width: 1040px){ .circuit-spine{ display:block; } }
.circuit-spine svg{ height: 100%; width: 100%; }
.circuit-spine .trace{ fill:none; stroke: var(--panel-border); stroke-width: 2; }
.circuit-spine .trace-fill{
  fill:none; stroke: var(--cyan); stroke-width: 2;
  stroke-dasharray: 1; stroke-dashoffset: 1; pathLength: 1;
  transition: stroke-dashoffset 0.25s linear;
}
.circuit-spine .via{
  fill: var(--bg); stroke: var(--panel-border); stroke-width: 2;
  transition: stroke 0.3s ease, fill 0.3s ease;
}
.circuit-spine .via.active{ fill: var(--cyan); stroke: var(--cyan); }

/* ============================================================
   NAV
   ============================================================ */
.nav{
  position: sticky; top:0; z-index: 40;
  background: rgba(246,249,253,0.88);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--panel-border);
}
.nav .container{ display:flex; align-items:center; justify-content:space-between; height:86px; }
.brand{ display:flex; align-items:center; gap:10px; }
.brand img{ height: 52px; width:auto; }

.nav-links{ display:none; align-items:center; gap:32px; }
@media (min-width: 900px){ .nav-links{ display:flex; } }
.nav-links a{ font-size:14.5px; color: var(--text-dim); font-weight:500; transition: color .2s ease; }
.nav-links a:hover{ color: var(--blue); }

.nav-cta{
  display:none; align-items:center; gap:8px;
  background: var(--blue); color:#ffffff; font-weight:600; font-size:14px;
  padding: 10px 18px; border-radius: 100px; border:none;
}
@media (min-width: 640px){ .nav-cta{ display:inline-flex; } }
.nav-cta:hover{ background: var(--blue-deep); }

.nav-toggle{
  display:inline-flex; background:none; border:1px solid var(--panel-border);
  border-radius:8px; padding:8px; color: var(--text);
}
@media (min-width: 900px){ .nav-toggle{ display:none; } }

.mobile-menu{ display:none; border-bottom:1px solid var(--panel-border); background: var(--panel); }
.mobile-menu.open{ display:block; }
.mobile-menu .container{ padding-top:16px; padding-bottom:20px; display:flex; flex-direction:column; gap:4px;}
.mobile-menu a{ padding:12px 4px; color: var(--text-dim); border-bottom:1px solid var(--panel-border); font-size:15px; }
.mobile-menu a:last-child{ border-bottom:none; }
.mobile-menu .nav-cta{ display:inline-flex; margin-top:12px; align-self:flex-start; }

/* ============================================================
   HERO
   ============================================================ */
.hero{ position:relative; padding: 84px 0 96px; overflow:hidden; border-bottom: 1px solid var(--panel-border); }
.hero::before{
  content:""; position:absolute; inset:0;
  background:
    radial-gradient(680px 420px at 84% -8%, rgba(23,171,227,0.14), transparent 60%),
    radial-gradient(520px 360px at -4% 100%, rgba(20,93,160,0.10), transparent 60%);
  pointer-events:none;
}
.hero-grid{ position:relative; display:grid; grid-template-columns: 1fr; gap:52px; align-items:center; }
@media (min-width: 980px){ .hero-grid{ grid-template-columns: 1.05fr 0.95fr; } }

.hero-copy h1{ font-size: clamp(34px, 5vw, 54px); line-height:1.08; margin-top:18px; color: var(--text); }
.hero-copy h1 .accent{ color: var(--blue); }
.hero-copy .lede{ margin-top:20px; font-size:17.5px; color: var(--text-dim); max-width: 46ch; }
.hero-actions{ display:flex; flex-wrap:wrap; gap:14px; margin-top:34px; }
.btn{
  display:inline-flex; align-items:center; gap:10px;
  padding: 14px 24px; border-radius: 100px; font-weight:600; font-size:15px;
  border:1px solid transparent;
  transition: transform .18s ease, filter .18s ease, background .18s ease, border-color .18s ease;
}
.btn:active{ transform: translateY(1px); }
.btn-primary{ background: var(--blue); color: #ffffff; }
.btn-primary:hover{ background: var(--blue-deep); }
.btn-outline{ border-color: var(--panel-border); color: var(--text); background: #ffffff; }
.btn-outline:hover{ border-color: var(--cyan); color: var(--cyan-soft); }
.btn-wa{ background: #25D366; color:#ffffff; }
.btn-wa:hover{ filter: brightness(0.95); }

.hero-meta{ display:flex; flex-wrap:wrap; gap:22px; margin-top:44px; font-family: var(--font-mono); font-size:12.5px; color: var(--text-faint); }
.hero-meta span{ color: var(--blue); }

.hero-visual{ position:relative; max-width: 560px; margin: 0 auto; }
.hero-photo{
  position:relative; aspect-ratio: 4/3; border-radius: 22px; overflow:hidden;
  border:1px solid var(--panel-border);
  box-shadow: 0 24px 50px -22px rgba(13,62,115,0.38);
}
.hero-photo img{ width:100%; height:100%; object-fit:cover; filter: saturate(0.92) contrast(1.03); }
.hero-photo-tint{
  position:absolute; inset:0; pointer-events:none;
  background: linear-gradient(155deg, rgba(13,62,115,0.28) 0%, rgba(23,171,227,0.05) 55%, rgba(13,62,115,0.18) 100%);
  mix-blend-mode: multiply;
}
.hero-badge{
  position:absolute; left:20px; bottom:-22px;
  display:flex; align-items:center; gap:10px;
  background: #ffffff; border:1px solid var(--panel-border); border-radius: 100px;
  padding: 10px 18px 10px 10px;
  box-shadow: 0 12px 28px -10px rgba(13,62,115,0.28);
  font-size: 13px; font-weight:600; color: var(--text);
  max-width: calc(100% - 40px);
}
.hero-badge-icon{
  width:30px; height:30px; border-radius:50%; flex-shrink:0;
  background: var(--cyan-tint); color: var(--blue);
  display:flex; align-items:center; justify-content:center;
}
.hero-badge-icon svg{ width:16px; height:16px; }

/* ============================================================
   STRIP
   ============================================================ */
.strip{ border-bottom: 1px solid var(--panel-border); background: var(--panel); }
.strip .container{ display:flex; flex-wrap:wrap; gap:14px 34px; padding: 20px 24px; justify-content:space-between; align-items:center; }
.strip-item{ display:flex; align-items:center; gap:10px; font-size:13.5px; color: var(--text-dim); }
.strip-item svg{ width:18px; height:18px; color: var(--cyan-soft); flex-shrink:0; }

/* ============================================================
   FILTROS (servicios y catálogo)
   ============================================================ */
.cat-tabs{ display:flex; gap:10px; flex-wrap:wrap; margin-bottom:36px; }
.cat-tab{
  font-family: var(--font-mono); font-size:12.5px;
  padding:9px 16px; border-radius:100px;
  border:1px solid var(--panel-border); background: #ffffff; color: var(--text-dim);
  transition: all .18s ease;
}
.cat-tab:hover{ color: var(--text); border-color: var(--cyan); }
.cat-tab.active{ background: var(--blue); border-color: var(--blue); color:#fff; font-weight:600; }

/* ============================================================
   TARJETAS DE ÍCONO (imagen de referencia reutilizable)
   ============================================================ */
.ref-media{
  aspect-ratio: 4/3;
  background:
    radial-gradient(220px 140px at 22% 0%, rgba(23,171,227,0.14), transparent 65%),
    var(--cyan-tint);
  display:flex; align-items:center; justify-content:center;
  border-bottom:1px solid var(--panel-border);
  position:relative;
}
.ref-media img{ width:100%; height:100%; object-fit:cover; filter: saturate(0.92) contrast(1.03); }
.ref-media .ref-tint{ position:absolute; inset:0; pointer-events:none;
  background: linear-gradient(155deg, rgba(13,62,115,0.28) 0%, rgba(23,171,227,0.06) 55%, rgba(13,62,115,0.16) 100%);
  mix-blend-mode: multiply;
}
.ref-media svg{ width:48px; height:48px; color: var(--blue); opacity:0.9; }
.ref-media svg.scene{ width:88%; height:88%; max-width:230px; opacity:1; }
.ref-tag{
  position:absolute; top:12px; left:12px;
  font-family: var(--font-mono); font-size:10.5px; letter-spacing:0.05em; text-transform:uppercase;
  background: rgba(255,255,255,0.9); color: var(--blue);
  padding:5px 10px; border-radius:100px; border:1px solid var(--panel-border);
}

/* ============================================================
   SERVICIOS — tarjetas individuales
   ============================================================ */
.services-grid{ display:grid; grid-template-columns: 1fr; gap:22px; }
@media (min-width: 620px){ .services-grid{ grid-template-columns: 1fr 1fr; } }
@media (min-width: 1000px){ .services-grid{ grid-template-columns: 1fr 1fr 1fr; } }

.service-card{
  background: var(--panel); border:1px solid var(--panel-border); border-radius: var(--radius-lg);
  overflow:hidden; display:flex; flex-direction:column;
  box-shadow: var(--shadow-card);
  transition: box-shadow .2s ease, transform .2s ease, border-color .2s ease;
}
.service-card:hover{ box-shadow: var(--shadow-card-hover); transform: translateY(-2px); border-color: rgba(23,171,227,0.4); }
.service-body{ padding:22px 22px 24px; display:flex; flex-direction:column; gap:12px; flex:1; }
.service-body h3{ font-size:17px; line-height:1.3; }
.service-body .desc{ font-size:13.5px; color: var(--text-dim); flex:1; }

.service-wa-btn{
  margin-top:6px;
  display:inline-flex; align-items:center; justify-content:center; gap:8px;
  background: #25D366; color:#fff; font-weight:600; font-size:13.5px;
  padding:11px 16px; border-radius:100px;
  transition: filter .18s ease, transform .18s ease;
}
.service-wa-btn:hover{ filter:brightness(0.95); }
.service-wa-btn svg{ width:16px; height:16px; }

/* ============================================================
   CATALOGO — nivel 1: categorías
   ============================================================ */
.categories-grid{ display:grid; grid-template-columns: 1fr; gap:20px; }
@media (min-width: 640px){ .categories-grid{ grid-template-columns: 1fr 1fr; } }
@media (min-width: 1000px){ .categories-grid{ grid-template-columns: 1fr 1fr 1fr; } }

.category-card{
  background: var(--panel); border: 1px solid var(--panel-border); border-radius: var(--radius-lg);
  overflow:hidden; display:flex; flex-direction:column;
  box-shadow: var(--shadow-card);
  transition: box-shadow .2s ease, transform .2s ease, border-color .2s ease;
  text-align:left; width:100%;
}
.category-card:hover{ box-shadow: var(--shadow-card-hover); transform: translateY(-2px); border-color: rgba(23,171,227,0.4); }
.category-body{ padding:20px 22px 22px; display:flex; flex-direction:column; gap:10px; flex:1; }
.category-body h3{ font-size:18px; }
.category-body .subtitle{ font-size:13px; color: var(--text-faint); }
.category-cta{
  margin-top:auto; padding-top:8px;
  display:inline-flex; align-items:center; gap:8px;
  font-size:13.5px; font-weight:600; color: var(--blue);
}
.category-cta svg{ width:16px; height:16px; transition: transform .18s ease; }
.category-card:hover .category-cta svg{ transform: translateX(3px); }
.category-count{ font-family: var(--font-mono); font-size:11.5px; color: var(--text-faint); }

/* ============================================================
   CATALOGO — nivel 2: productos de una categoría
   ============================================================ */
.catalog-breadcrumb{
  display:flex; align-items:center; gap:10px; margin-bottom: 30px;
  font-size:13.5px; color: var(--text-dim);
}
.catalog-breadcrumb button{
  display:inline-flex; align-items:center; gap:6px;
  background:none; border:none; color: var(--blue); font-weight:600; font-size:13.5px; padding:0;
}
.catalog-breadcrumb button svg{ width:15px; height:15px; }
.catalog-breadcrumb .sep{ color: var(--text-faint); }

.products-grid{ display:grid; grid-template-columns: 1fr; gap:20px; }
@media (min-width: 640px){ .products-grid{ grid-template-columns: 1fr 1fr; } }
@media (min-width: 1000px){ .products-grid{ grid-template-columns: 1fr 1fr 1fr; } }

.product-card{
  background: var(--panel); border: 1px solid var(--panel-border); border-radius: var(--radius-lg);
  overflow:hidden; display:flex; flex-direction:column;
  box-shadow: var(--shadow-card);
  transition: box-shadow .2s ease, transform .2s ease, border-color .2s ease;
}
.product-card:hover{ box-shadow: var(--shadow-card-hover); transform: translateY(-2px); border-color: rgba(23,171,227,0.4); }
.product-body{ padding:18px 20px 20px; display:flex; flex-direction:column; gap:10px; flex:1; }
.product-body h4{ font-family: var(--font-display); font-size:15.5px; font-weight:600; line-height:1.35; }
.product-note{ font-size:12.5px; color: var(--text-faint); }
.product-price-row{ display:flex; align-items:center; justify-content:space-between; margin-top:auto; padding-top:10px; }
.product-price{ font-family: var(--font-mono); font-weight:600; font-size:16px; color: var(--blue-deep); }
.product-price.consult{ font-size:12.5px; color: var(--text-faint); }
.product-wa-btn{
  display:inline-flex; align-items:center; gap:6px;
  background: #25D366; color:#fff; font-weight:600; font-size:12.5px;
  padding:9px 13px; border-radius:100px;
  transition: filter .18s ease;
}
.product-wa-btn:hover{ filter:brightness(0.95); }
.product-wa-btn svg{ width:14px; height:14px; }

.catalog-note{
  margin-top:40px; display:flex; gap:14px; align-items:flex-start;
  background: var(--cyan-tint); border:1px dashed var(--panel-border);
  border-radius: var(--radius-md); padding:18px 20px;
  color: var(--text-dim); font-size:13.5px;
}
.catalog-note svg{ width:20px; height:20px; color: var(--cyan-soft); flex-shrink:0; margin-top:1px; }

/* ============================================================
   POR QUÉ ELEGIRNOS
   ============================================================ */
.why-grid{ display:grid; grid-template-columns: 1fr; gap:1px; background: var(--panel-border); border:1px solid var(--panel-border); border-radius: var(--radius-lg); overflow:hidden; }
@media (min-width: 760px){ .why-grid{ grid-template-columns: repeat(3, 1fr); } }
.why-item{ background: var(--panel); padding:32px 28px; }
.why-item .num{ font-family: var(--font-mono); color: var(--cyan-soft); font-size:13px; }
.why-item h3{ margin-top:14px; font-size:18px; }
.why-item p{ margin-top:10px; color: var(--text-dim); font-size:14.5px; }

/* ============================================================
   CONTACTO
   ============================================================ */
.contact-wrap{ display:grid; grid-template-columns: 1fr; gap:28px; }
@media (min-width: 900px){ .contact-wrap{ grid-template-columns: 1.1fr 0.9fr; } }

.contact-card{ background: var(--panel); border:1px solid var(--panel-border); border-radius: var(--radius-lg); padding:40px; box-shadow: var(--shadow-card); }
.contact-card h3{ font-size:22px; }
.contact-card p{ color: var(--text-dim); margin-top:12px; font-size:15px; max-width:44ch; }
.contact-methods{ margin-top:28px; display:flex; flex-direction:column; gap:16px; }
.contact-method{ display:flex; align-items:center; gap:14px; padding:14px 16px; border:1px solid var(--panel-border); border-radius: var(--radius-md); transition: border-color .2s ease, background .2s ease; }
.contact-method:hover{ border-color: var(--cyan); background: var(--cyan-tint); }
.contact-method .ic{ width:38px; height:38px; border-radius:9px; flex-shrink:0; background: var(--cyan-tint); color: var(--blue); display:flex; align-items:center; justify-content:center; }
.contact-method .ic svg{ width:19px; height:19px; }
.contact-method .label{ font-size:12px; color: var(--text-faint); font-family: var(--font-mono); }
.contact-method .value{ font-size:14.5px; font-weight:600; margin-top:2px; }

.coverage-card{ background: linear-gradient(160deg, #eaf6fc, #f6f9fd); border:1px solid var(--panel-border); border-radius: var(--radius-lg); padding:40px; display:flex; flex-direction:column; }
.coverage-card h3{ font-size:20px; }
.coverage-card p{ color: var(--text-dim); margin-top:12px; font-size:14.5px; }
.coverage-map{ margin-top:26px; flex:1; display:flex; align-items:center; justify-content:center; }
.coverage-map img{ width:100%; max-width:190px; height:auto; object-fit:contain; mix-blend-mode: multiply; }
.coverage-badge{ margin-top:20px; align-self:flex-start; font-family: var(--font-mono); font-size:12px; color: var(--success); display:flex; align-items:center; gap:8px; }
.coverage-badge::before{ content:""; width:7px; height:7px; border-radius:50%; background: var(--success); box-shadow: 0 0 0 4px rgba(31,169,114,0.16); }

/* ============================================================
   CTA FINAL
   ============================================================ */
.cta-band{ border-top:1px solid var(--panel-border); border-bottom:1px solid var(--panel-border); background: var(--panel); }
.cta-band .container{ padding: 60px 24px; display:flex; flex-direction:column; align-items:flex-start; gap:22px; }
@media (min-width: 760px){ .cta-band .container{ flex-direction:row; align-items:center; justify-content:space-between; } }
.cta-band h2{ font-size: clamp(24px, 3vw, 32px); max-width:22ch; }

/* ============================================================
   FOOTER
   ============================================================ */
footer{ padding: 56px 0 32px; background: var(--panel); border-top:1px solid var(--panel-border); }
.footer-top{ display:flex; flex-direction:column; gap:32px; padding-bottom:32px; border-bottom:1px solid var(--panel-border); }
@media (min-width:760px){ .footer-top{ flex-direction:row; justify-content:space-between; } }
.footer-brand .brand{ margin-bottom:14px; }
.footer-brand p{ color: var(--text-dim); font-size:14px; max-width:34ch; }
.footer-social{ display:flex; gap:12px; margin-top:18px; }
.footer-social a{ width:38px; height:38px; border-radius:9px; border:1px solid var(--panel-border); display:flex; align-items:center; justify-content:center; color: var(--text-dim); transition: all .18s ease; }
.footer-social a:hover{ color: var(--blue); border-color: var(--cyan); }
.footer-social svg{ width:17px; height:17px; }
.footer-cols{ display:flex; gap:60px; flex-wrap:wrap; }
.footer-col h4{ font-family: var(--font-mono); font-size:12px; color: var(--text-faint); text-transform:uppercase; letter-spacing:0.08em; }
.footer-col ul{ margin-top:16px; display:flex; flex-direction:column; gap:10px; }
.footer-col a{ font-size:14px; color: var(--text-dim); }
.footer-col a:hover{ color: var(--blue); }
.footer-bottom{ padding-top:26px; display:flex; flex-direction:column; gap:10px; font-size:12.5px; color: var(--text-faint); }
@media (min-width:760px){ .footer-bottom{ flex-direction:row; justify-content:space-between; } }

/* ============================================================
   FLOATING WHATSAPP BUTTON
   ============================================================ */
.float-wa{
  position:fixed; right:20px; bottom:20px; z-index:50;
  width:58px; height:58px; border-radius:50%;
  background: #25D366; color:#ffffff;
  display:flex; align-items:center; justify-content:center;
  box-shadow: 0 10px 26px rgba(37,211,102,0.4);
  transition: transform .2s ease;
}
.float-wa:hover{ transform: scale(1.06); }
.float-wa svg{ width:28px; height:28px; }

.reveal{ opacity:0; transform: translateY(16px); transition: opacity .55s ease, transform .55s ease; }
.reveal.in{ opacity:1; transform:none; }

[hidden]{ display:none !important; }
