/* B1 Networks EMEA · sistema visual v1 (manual de marca B1N EMEA) */
:root {
  --blue: #0000cc;
  --blue-cta: #1548e1;
  --green: #4cdf69;
  --ink: #372244;
  --dim: #6b5f78;
  --bg-1: #ecf0ff;
  --bg-2: #f3f5fe;
  --surface: #ffffff;
  --line: rgba(55, 34, 68, 0.12);
  --radius: 12px;
  --shadow: 0 6px 24px rgba(21, 72, 225, 0.08);
  --ease: cubic-bezier(0.32, 0.72, 0, 1);
}
* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }
[id] { scroll-margin-top: 96px; }
body {
  font-family: "Plus Jakarta Sans", system-ui, -apple-system, "Segoe UI", sans-serif;
  color: var(--ink);
  background: var(--surface);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}
/* Grano fílmico global: fijo, sin interacción, opacidad mínima */
body::after {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 80;
  pointer-events: none;
  opacity: 0.026;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='160' height='160' filter='url(%23n)'/%3E%3C/svg%3E");
}
/* Tramas de marca reutilizables */
.textured { position: relative; }
.textured > * { position: relative; z-index: 1; }
.textured::before {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 0;
}
/* Retícula fina difuminada (hero, contacto) */
.tx-grid::before {
  background-image:
    radial-gradient(ellipse 75% 55% at 80% -5%, rgba(0, 219, 104, 0.055), transparent 62%),
    linear-gradient(rgba(0, 0, 204, 0.045) 1px, transparent 1px),
    linear-gradient(90deg, rgba(0, 0, 204, 0.045) 1px, transparent 1px);
  background-size: auto, 64px 64px, 64px 64px;
  -webkit-mask-image: radial-gradient(ellipse 110% 95% at 50% 0%, black 25%, transparent 88%);
  mask-image: radial-gradient(ellipse 110% 95% at 50% 0%, black 25%, transparent 88%);
}
/* Punteado microscópico (bandas lavanda) */
.tx-dots::before {
  background-image: radial-gradient(rgba(0, 0, 204, 0.07) 1px, transparent 1.5px);
  background-size: 22px 22px;
  -webkit-mask-image: linear-gradient(180deg, black 55%, transparent 100%);
  mask-image: linear-gradient(180deg, black 55%, transparent 100%);
}
img { max-width: 100%; display: block; }
.wrap { max-width: 1200px; margin: 0 auto; padding: 0 clamp(1.25rem, 4vw, 2.5rem); }

/* ---------- Nav ---------- */
.nav-outer { position: sticky; top: 0.9rem; z-index: 50; padding: 0; }
nav.main { display: flex; align-items: center; gap: 1.6rem; background: rgba(255,255,255,0.86); backdrop-filter: blur(14px); border: 1px solid var(--line); border-radius: 16px; padding: 0.65rem 0.7rem 0.65rem 1.5rem; box-shadow: 0 12px 32px rgba(21, 72, 225, 0.10); }
nav.main .logo img { height: 34px; width: auto; }
nav.main ul a { text-decoration: none; color: var(--ink); font-size: 0.92rem; font-weight: 500; }
nav.main ul a:hover { color: var(--blue-cta); }
.lang { font-size: 0.85rem; font-weight: 600; color: var(--dim); text-decoration: none; border: 1px solid var(--line); border-radius: 999px; padding: 0.3rem 0.8rem; }
.lang:hover { color: var(--blue-cta); border-color: var(--blue-cta); }
.btn { display: inline-block; background: var(--blue-cta); color: #fff; text-decoration: none; font-weight: 600; font-size: 0.95rem; padding: 0.8rem 1.6rem; border-radius: 8px; border: none; cursor: pointer; transition: background 0.45s var(--ease), transform 0.3s var(--ease); }
.btn:hover { background: var(--blue); }
.btn:active { transform: scale(0.98); }
.btn:focus-visible { outline: 3px solid var(--green); outline-offset: 2px; }
.btn.small { padding: 0.55rem 1.2rem; font-size: 0.88rem; }

/* ---------- Desplegables ---------- */
.nav-links { display: flex; gap: 1.5rem; list-style: none; margin-left: auto; align-items: center; }
.dd { position: relative; }
.dd-btn { font: inherit; font-size: 0.92rem; font-weight: 500; color: var(--ink); background: none; border: none; cursor: pointer; display: inline-flex; align-items: center; gap: 0.4rem; padding: 0.2rem 0; }
.dd-btn:hover { color: var(--blue-cta); }
.dd-btn .chev { width: 8px; height: 8px; border-right: 1.5px solid currentColor; border-bottom: 1.5px solid currentColor; transform: rotate(45deg) translateY(-2px); transition: transform 0.3s var(--ease); }
.dd.open .dd-btn .chev { transform: rotate(225deg) translateY(-2px); }
.dd-menu { display: block; position: absolute; top: calc(100% + 12px); left: -0.75rem; min-width: 240px; background: #fff; border: 1px solid var(--line); border-radius: 12px; box-shadow: 0 16px 40px rgba(21, 72, 225, 0.13); padding: 0.5rem; list-style: none; opacity: 0; visibility: hidden; transform: translateY(6px); transition: opacity 0.3s var(--ease), transform 0.3s var(--ease), visibility 0.3s; z-index: 60; }
.dd:hover .dd-menu, .dd:focus-within .dd-menu, .dd.open .dd-menu { opacity: 1; visibility: visible; transform: translateY(0); }
.dd-menu a { display: block; padding: 0.55rem 0.8rem; border-radius: 8px; font-size: 0.9rem; }
.dd-menu a:hover { background: var(--bg-2); }
.burger { display: none; font: inherit; background: none; border: none; cursor: pointer; width: 40px; height: 40px; border-radius: 10px; position: relative; margin-left: auto; }
.burger span { position: absolute; left: 10px; right: 10px; height: 2px; background: var(--ink); border-radius: 2px; transition: transform 0.4s var(--ease), opacity 0.3s var(--ease); }
.burger span:nth-child(1) { top: 15px; }
.burger span:nth-child(2) { top: 23px; }
.burger.x span:nth-child(1) { transform: translateY(4px) rotate(45deg); }
.burger.x span:nth-child(2) { transform: translateY(-4px) rotate(-45deg); }
@media (max-width: 900px) {
  .burger { display: block; }
  .nav-links { display: none; }
  nav.main.open .nav-links { display: flex; flex-direction: column; align-items: stretch; gap: 0.25rem; position: absolute; top: calc(100% + 8px); left: 0; right: 0; background: #fff; border: 1px solid var(--line); border-radius: 16px; box-shadow: 0 16px 40px rgba(21, 72, 225, 0.13); padding: 0.75rem; z-index: 60; }
  nav.main { position: relative; }
  .dd-menu { position: static; opacity: 1; visibility: visible; transform: none; box-shadow: none; border: none; padding: 0 0 0 0.9rem; display: none; min-width: 0; }
  .dd.open .dd-menu { display: block; }
  .dd:hover .dd-menu { display: none; }
  .dd.open:hover .dd-menu { display: block; }
  .dd-btn { width: 100%; justify-content: space-between; padding: 0.55rem 0.5rem; }
  .nav-links > li > a { display: block; padding: 0.55rem 0.5rem; }
}

/* Franja resumen "Por qué B1" en la home */
.b1-strip { text-align: center; }
.b1-strip h2 { font-size: clamp(1.6rem, 3.2vw, 2.2rem); font-weight: 600; letter-spacing: -0.02em; line-height: 1.2; margin-bottom: 0.8rem; }
.b1-strip p { color: var(--dim); max-width: 56ch; margin: 0 auto 1.4rem; }

/* ---------- Hero ---------- */
.hero { padding: clamp(3.5rem, 8vw, 6.5rem) 0 clamp(3.5rem, 7vw, 6rem); background: linear-gradient(180deg, #ffffff 0%, var(--bg-1) 100%); }
.hero .grid { display: grid; grid-template-columns: 1.15fr 1fr; gap: clamp(2rem, 5vw, 4.5rem); align-items: center; }
.badge { display: inline-flex; align-items: center; gap: 0.5rem; background: var(--surface); border: 1px solid var(--line); border-radius: 999px; padding: 0.4rem 0.95rem; font-size: 0.82rem; font-weight: 600; color: var(--dim); margin-bottom: 1.5rem; }
.badge .dot { width: 8px; height: 8px; border-radius: 2px; background: var(--green); }
.hero h1 { font-size: clamp(2.3rem, 5vw, 3.6rem); font-weight: 600; letter-spacing: -0.025em; line-height: 1.08; margin-bottom: 1.1rem; }
.hero h1 .accent { color: var(--blue-cta); }
.hero p.sub { font-size: clamp(1rem, 2vw, 1.18rem); color: var(--dim); max-width: 48ch; margin-bottom: 1.9rem; }
.hero .actions { display: flex; gap: 1rem; align-items: center; flex-wrap: wrap; }
.link-quiet { color: var(--ink); font-weight: 600; font-size: 0.95rem; text-decoration: none; border-bottom: 2px solid var(--green); padding-bottom: 2px; }
.link-quiet:hover { color: var(--blue-cta); }

/* Panel de métricas del hero (datos reales de Glean, no UI simulada) */
.metric-panel { background: radial-gradient(120% 140% at 85% 0%, #2a52d8 0%, var(--blue) 55%, #000f8a 100%); border-radius: 20px; padding: clamp(1.5rem, 3vw, 2.5rem); color: #fff; box-shadow: 0 24px 60px rgba(0, 0, 204, 0.25); position: relative; overflow: hidden; }
.metric-panel::after { content: ""; position: absolute; inset: 0; background: radial-gradient(60% 60% at 10% 100%, rgba(0, 219, 104, 0.35), transparent 70%); pointer-events: none; }
.metric-panel .kicker { font-size: 0.8rem; font-weight: 600; letter-spacing: 0.08em; text-transform: uppercase; color: rgba(255,255,255,0.75); margin-bottom: 1.4rem; }
.metric { padding: 1.1rem 0; border-top: 1px solid rgba(255,255,255,0.18); position: relative; z-index: 1; }
.metric:first-of-type { border-top: none; padding-top: 0; }
.metric b { display: block; font-size: clamp(1.9rem, 3.5vw, 2.6rem); font-weight: 700; letter-spacing: -0.02em; line-height: 1.1; }
.metric b .u { color: var(--green); }
.metric span { font-size: 0.9rem; color: rgba(255,255,255,0.82); }
.metric-panel .src { position: relative; z-index: 1; font-size: 0.75rem; color: rgba(255,255,255,0.6); margin-top: 1.2rem; }
@media (max-width: 900px) { .hero .grid { grid-template-columns: 1fr; } }

/* ---------- Secciones ---------- */
section { padding: clamp(4.5rem, 9vw, 8rem) 0; }
.sec-head { max-width: 720px; margin-bottom: clamp(2rem, 4vw, 3rem); }
.sec-head h2 { font-size: clamp(1.7rem, 3.5vw, 2.4rem); font-weight: 600; letter-spacing: -0.02em; line-height: 1.15; margin-bottom: 0.9rem; }
.sec-head p { color: var(--dim); font-size: 1.02rem; }
.rule { display: flex; align-items: center; max-width: 300px; margin-top: 1.1rem; }
.rule::before { content: ""; flex: 1; height: 1px; background: var(--line); }
.rule::after { content: ""; width: 30px; height: 8px; background: var(--green); }

/* Prueba social: casos Glean */
.cases { background: var(--bg-2); }
.case-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.25rem; }
.case { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 1.75rem; box-shadow: var(--shadow); }
.case h3 { font-size: 1.15rem; font-weight: 700; margin-bottom: 0.3rem; }
.case .role { font-size: 0.82rem; color: var(--dim); margin-bottom: 1.1rem; }
.case .figures { display: flex; flex-direction: column; gap: 0.55rem; }
.case .figures div b { color: var(--blue-cta); font-weight: 700; }
.case .figures div { font-size: 0.95rem; }
.cases .src { font-size: 0.8rem; color: var(--dim); margin-top: 1.5rem; }
@media (max-width: 900px) { .case-grid { grid-template-columns: 1fr; } }

/* Problema: filas con hairline */
.pains { }
.pain { display: grid; grid-template-columns: 64px 1fr 1.4fr; gap: 1.5rem; align-items: baseline; padding: 1.6rem 0; border-top: 1px solid var(--line); }
.pain:last-of-type { border-bottom: 1px solid var(--line); }
.pain .n { font-weight: 700; color: var(--green); font-size: 1.1rem; }
.pain h3 { font-size: 1.15rem; font-weight: 600; letter-spacing: -0.01em; }
.pain p { color: var(--dim); font-size: 0.98rem; }
@media (max-width: 800px) { .pain { grid-template-columns: 40px 1fr; } .pain p { grid-column: 2; } }

/* Glean: split con chips de conectores */
.glean { background: linear-gradient(180deg, var(--bg-1), #ffffff); }
.glean .grid { display: grid; grid-template-columns: 1fr 1.1fr; gap: clamp(2rem, 5vw, 4.5rem); align-items: center; }
.chips { display: flex; flex-wrap: wrap; gap: 0.6rem; }
.chip { background: var(--surface); border: 1px solid var(--line); border-radius: 999px; padding: 0.45rem 1rem; font-size: 0.88rem; font-weight: 500; box-shadow: var(--shadow); }
.chip.more { color: var(--dim); border-style: dashed; box-shadow: none; }
.glean-points { margin-top: 1.6rem; display: flex; flex-direction: column; gap: 1rem; }
.gp { display: grid; grid-template-columns: 26px 1fr; gap: 0.75rem; }
.gp .tick { width: 20px; height: 20px; border-radius: 6px; background: var(--green); position: relative; top: 3px; }
.gp .tick::after { content: ""; position: absolute; left: 6px; top: 3px; width: 5px; height: 9px; border: solid #fff; border-width: 0 2.5px 2.5px 0; transform: rotate(45deg); }
.gp p { font-size: 0.98rem; }
.gp p b { font-weight: 600; }
.glean .stats-inline { margin-top: 1.8rem; font-size: 0.9rem; color: var(--dim); }
@media (max-width: 900px) { .glean .grid { grid-template-columns: 1fr; } }

/* Proceso 4 pasos */
.steps { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1.25rem; }
.step { border-top: 3px solid var(--green); background: var(--surface); border-radius: 0 0 var(--radius) var(--radius); padding: 1.4rem 1.2rem 1.5rem; border-left: 1px solid var(--line); border-right: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.step h3 { font-size: 1.02rem; font-weight: 700; margin-bottom: 0.5rem; }
.step p { font-size: 0.9rem; color: var(--dim); }
@media (max-width: 900px) { .steps { grid-template-columns: 1fr 1fr; } }
@media (max-width: 560px) { .steps { grid-template-columns: 1fr; } }

/* Banda de imagen entre secciones: aire simétrico */
.img-band { padding-top: clamp(2rem, 4.5vw, 4rem); padding-bottom: clamp(2rem, 4.5vw, 4rem); }

/* Seguridad */
.security { background: var(--bg-2); }
.sec-badges { display: flex; flex-wrap: wrap; gap: 0.75rem; margin-top: 1.75rem; }
.sec-badge { background: var(--surface); border: 1px solid var(--line); border-radius: 10px; padding: 0.7rem 1.3rem; font-weight: 700; font-size: 0.92rem; letter-spacing: 0.01em; }
.security .note { margin-top: 1.25rem; font-size: 0.9rem; color: var(--dim); max-width: 62ch; }

/* Pilares: bento 2x2 con fondos variados */
.pillars-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 1.25rem; }
.pillar { border-radius: var(--radius); padding: 1.9rem; border: 1px solid var(--line); }
.pillar.tint-a { background: var(--bg-1); }
.pillar.tint-b { background: var(--surface); box-shadow: var(--shadow); }
.pillar.tint-c { background: linear-gradient(135deg, var(--bg-2), #e6f9ee); }
.pillar.tint-d { background: linear-gradient(135deg, var(--bg-2), var(--bg-1)); }
.pillar h3 { font-size: 1.12rem; font-weight: 700; margin-bottom: 0.5rem; }
.pillar p { font-size: 0.95rem; color: var(--dim); }
.pillar .tag { display: inline-block; font-size: 0.72rem; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; color: var(--blue-cta); margin-bottom: 0.8rem; }
@media (max-width: 800px) { .pillars-grid { grid-template-columns: 1fr; } }

/* Contacto */
.contact { background: linear-gradient(180deg, #ffffff, var(--bg-1)); }
.contact .grid { display: grid; grid-template-columns: 1fr 1.1fr; gap: clamp(2rem, 5vw, 4rem); align-items: start; }
form.demo { background: var(--surface); border: 1px solid var(--line); border-radius: 16px; padding: clamp(1.5rem, 3vw, 2.25rem); box-shadow: var(--shadow); display: flex; flex-direction: column; gap: 1.1rem; }
form.demo label { font-size: 0.88rem; font-weight: 600; display: flex; flex-direction: column; gap: 0.4rem; }
form.demo input, form.demo select, form.demo textarea { font: inherit; font-size: 0.95rem; padding: 0.7rem 0.9rem; border: 1px solid var(--line); border-radius: 8px; background: #fff; color: var(--ink); }
form.demo input:focus-visible, form.demo select:focus-visible, form.demo textarea:focus-visible { outline: 2px solid var(--blue-cta); outline-offset: 1px; }
form.demo .consent { display: grid; grid-template-columns: 20px 1fr; gap: 0.6rem; font-size: 0.82rem; font-weight: 400; color: var(--dim); align-items: start; }
form.demo .consent input { width: 16px; height: 16px; margin-top: 2px; }
form.demo .consent a { color: var(--blue-cta); }
.hp { position: absolute; left: -9999px; opacity: 0; height: 0; overflow: hidden; }

/* Footer */
footer.site { background: var(--blue); color: rgba(255,255,255,0.85); padding: 3rem 0 2rem; }
footer.site .cols { display: grid; grid-template-columns: 1.4fr 1fr 1fr; gap: 2rem; margin-bottom: 2.25rem; }
footer.site img { height: 40px; width: auto; margin-bottom: 1rem; }
footer.site p { font-size: 0.9rem; }
footer.site h4 { font-size: 0.8rem; text-transform: uppercase; letter-spacing: 0.08em; color: rgba(255,255,255,0.6); margin-bottom: 0.8rem; }
footer.site a { color: rgba(255,255,255,0.85); text-decoration: none; font-size: 0.9rem; }
footer.site a:hover { color: var(--green); }
footer.site li { list-style: none; margin-bottom: 0.45rem; }
footer.site .bottom { border-top: 1px solid rgba(255,255,255,0.18); padding-top: 1.5rem; font-size: 0.82rem; color: rgba(255,255,255,0.6); display: flex; justify-content: space-between; gap: 1rem; flex-wrap: wrap; }
@media (max-width: 800px) { footer.site .cols { grid-template-columns: 1fr; } }

/* Animación de entrada, respetando reduced motion */
@media (prefers-reduced-motion: no-preference) {
  .rise { opacity: 0; transform: translateY(16px); animation: rise 0.7s cubic-bezier(0.16, 1, 0.3, 1) forwards; }
  .rise:nth-child(2) { animation-delay: 0.08s; }
  .rise:nth-child(3) { animation-delay: 0.16s; }
  @keyframes rise { to { opacity: 1; transform: translateY(0); } }
}


/* ---------- Double-bezel: pieza dentro de bandeja ---------- */
.bezel { background: rgba(0, 0, 204, 0.05); border: 1px solid rgba(0, 0, 204, 0.09); border-radius: 27px; padding: 7px; }
.bezel > .metric-panel { border-radius: 20px; }
.bezel > img { border-radius: 20px !important; display: block; }
.bezel > form.demo { border-radius: 20px; }
.bezel-img { border-radius: 20px; overflow: hidden; }

/* ---------- CTA con flecha anidada ---------- */
.btn-ico { display: inline-flex; align-items: center; gap: 0.7rem; padding-right: 0.55rem; }
.btn-ico .ico { width: 30px; height: 30px; border-radius: 50%; background: rgba(255,255,255,0.18); display: inline-flex; align-items: center; justify-content: center; font-size: 0.95rem; transition: transform 0.5s var(--ease), background 0.5s var(--ease); }
.btn-ico:hover .ico { transform: translate(3px, -1px); background: rgba(255,255,255,0.28); }

/* ---------- Scroll-reveal (activado por JS, sin JS no oculta nada) ---------- */
@media (prefers-reduced-motion: no-preference) {
  .reveal { opacity: 0; transform: translateY(22px); transition: opacity 0.9s var(--ease), transform 0.9s var(--ease); transition-delay: var(--d, 0s); }
  .reveal.in { opacity: 1; transform: none; }
}
