/* ATTRIM — Sistema de diseño */
:root {
  --navy: #0B294C;
  --navy-2: #133865;
  --navy-3: #1a4480;
  --blue: #1578FA;
  --blue-soft: #C4DAFE;
  --green: #80BC00;
  --green-soft: #d6ec99;
  --gray: #BDBFC8;
  --gray-soft: #E5E7EC;
  --paper: #F7F8FA;
  --paper-2: #ffffff;
  --ink: #0B294C;
  --ink-2: #3a4a64;
  --ink-3: #6b7a90;

  --container: 1320px;
  --pad-x: clamp(20px, 4vw, 56px);

  --font-ui: "Poppins", system-ui, -apple-system, sans-serif;
  --font-serif: "IBM Plex Mono", ui-monospace, monospace;
  --font-mono: "JetBrains Mono", ui-monospace, "SF Mono", monospace;

  --r-sm: 8px;
  --r-md: 14px;
  --r-lg: 22px;
  --r-xl: 32px;
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  font-family: var(--font-ui);
  color: var(--ink);
  background: var(--paper);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  font-feature-settings: "ss01", "cv11";
  font-size: 16px;
  line-height: 1.5;
  overflow-x: hidden;
}

a { color: inherit; text-decoration: none; }
button { font-family: inherit; cursor: pointer; }
img { max-width: 100%; display: block; }

/* Type system */
.serif { font-family: var(--font-serif); font-weight: 300; letter-spacing: -0.01em; }
.mono { font-family: var(--font-mono); }
.eyebrow {
  font-family: var(--font-mono);
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--ink-3);
  display: inline-flex;
  align-items: center;
  gap: 10px;
}
.eyebrow::before {
  content: "";
  width: 18px;
  height: 1px;
  background: currentColor;
  opacity: .6;
}
.dark .eyebrow { color: rgba(255,255,255,.7); }

h1, h2, h3, h4 { margin: 0; font-weight: 500; letter-spacing: -0.02em; line-height: 1.05; }
.h-display { font-family: var(--font-serif); font-size: clamp(44px, 5.5vw, 90px); line-height: 1.1; letter-spacing: -0.01em; font-weight: 300; padding-bottom: 0.08em; }
.h-display em { font-style: normal; color: var(--blue); font-weight: 400; }
.h-section { font-family: var(--font-serif); font-size: clamp(32px, 4vw, 64px); line-height: 1.12; letter-spacing: -0.01em; font-weight: 300; padding-bottom: 0.06em; }
.h-section em { font-style: normal; font-weight: 400; }
.h-lg { font-size: clamp(28px, 3vw, 44px); line-height: 1.1; font-weight: 500; letter-spacing: -0.015em; }
.h-md { font-size: clamp(20px, 1.6vw, 26px); line-height: 1.2; font-weight: 500; letter-spacing: -0.01em; }

p { margin: 0; }
.lede {
  font-size: clamp(18px, 1.4vw, 22px);
  line-height: 1.5;
  color: var(--ink-2);
  max-width: 640px;
}
.dark .lede { color: rgba(255,255,255,.72); }

/* Container */
.container {
  width: 100%;
  max-width: var(--container);
  margin: 0 auto;
  padding-left: var(--pad-x);
  padding-right: var(--pad-x);
}

/* Sections */
section { position: relative; }
.section-pad { padding: clamp(64px, 8vw, 120px) 0; }
.section-pad-sm { padding: clamp(48px, 6vw, 80px) 0; }

.dark { background: var(--navy); color: #fff; }
.dark a { color: #fff; }
.ice { background: linear-gradient(180deg, rgba(196,218,254,.45), rgba(196,218,254,.15)); }

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 14px 22px;
  border-radius: 999px;
  font-size: 14px;
  font-weight: 500;
  letter-spacing: -0.005em;
  border: 1px solid transparent;
  transition: all .25s ease;
  white-space: nowrap;
}
.btn-primary { background: var(--blue); color: #fff; }
.btn-primary:hover { background: #0a63d8; transform: translateY(-1px); }
.btn-ghost { background: transparent; border-color: rgba(11,41,76,.18); color: var(--ink); }
.btn-ghost:hover { border-color: var(--ink); }
.dark .btn-ghost { border-color: rgba(255,255,255,.22); color: #fff; }
.dark .btn-ghost:hover { border-color: #fff; background: rgba(255,255,255,.06); }
.btn-light { background: #fff; color: var(--navy); }
.btn-light:hover { background: var(--blue-soft); }
.btn .arr {
  display: inline-block;
  transition: transform .25s ease;
}
.btn:hover .arr { transform: translateX(3px); }
.btn:active { transform: scale(0.97) !important; }

/* Pills */
.pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 12px;
  border-radius: 999px;
  background: rgba(11,41,76,.06);
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--ink-2);
}
.dark .pill { background: rgba(255,255,255,.08); color: rgba(255,255,255,.8); }
.pill .dot { width: 6px; height: 6px; border-radius: 50%; background: var(--green); }

/* Cards */
.card {
  border-radius: var(--r-lg);
  background: #fff;
  border: 1px solid var(--gray-soft);
  padding: 32px;
  transition: transform .35s ease, border-color .25s ease, box-shadow .35s ease;
}
.card:hover { transform: translateY(-3px); border-color: rgba(11,41,76,.18); box-shadow: 0 14px 40px -20px rgba(11,41,76,.18); }

/* Reveal on scroll */
.reveal { opacity: 0; transform: translateY(28px); transition: opacity .9s ease, transform .9s cubic-bezier(.2,.7,.2,1); }
.reveal.in { opacity: 1; transform: none; }
.reveal.d1 { transition-delay: .08s; }
.reveal.d2 { transition-delay: .16s; }
.reveal.d3 { transition-delay: .24s; }
.reveal.d4 { transition-delay: .32s; }
body.no-anim .reveal { opacity: 1; transform: none; transition: none; }

/* Cursor halo */
.cursor-halo {
  position: fixed;
  width: 340px;
  height: 340px;
  pointer-events: none;
  border-radius: 50%;
  z-index: 1;
  transform: translate(-50%, -50%);
  background: radial-gradient(closest-side, rgba(21,120,250,.18), rgba(21,120,250,0) 70%);
  mix-blend-mode: normal;
  transition: opacity .4s ease;
  opacity: 0;
}
body.cursor-on .cursor-halo { opacity: 1; }
.dark .cursor-halo { background: radial-gradient(closest-side, rgba(128,188,0,.16), rgba(128,188,0,0) 70%); }

/* Marquee */
.marquee {
  overflow: hidden;
  white-space: nowrap;
  --speed: 50s;
}
.marquee-track {
  display: inline-flex;
  gap: 64px;
  animation: marquee var(--speed) linear infinite;
  padding-right: 64px;
}
@keyframes marquee {
  from { transform: translateX(0); }
  to { transform: translateX(-50%); }
}

/* Grid lines for hero */
.grid-bg {
  position: absolute;
  inset: 0;
  pointer-events: none;
  background-image:
    linear-gradient(rgba(255,255,255,.05) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,.05) 1px, transparent 1px);
  background-size: 80px 80px;
  mask-image: radial-gradient(ellipse at 50% 30%, rgba(0,0,0,1), rgba(0,0,0,0) 70%);
}

/* Nav */
.nav {
  position: fixed;
  top: 18px;
  left: 0; right: 0;
  z-index: 100;
  display: flex;
  justify-content: center;
  pointer-events: none;
}
.nav-inner {
  pointer-events: auto;
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 10px 14px 10px 22px;
  background: rgba(255,255,255,.78);
  backdrop-filter: blur(18px) saturate(1.4);
  -webkit-backdrop-filter: blur(18px) saturate(1.4);
  border: 1px solid rgba(11,41,76,.08);
  border-radius: 999px;
  box-shadow: 0 10px 40px -20px rgba(11,41,76,.18);
}
.nav.dark-mode .nav-inner {
  background: rgba(11,41,76,.78);
  border-color: rgba(255,255,255,.1);
  color: #fff;
}
.nav-logo {
  font-family: var(--font-ui);
  font-weight: 600;
  font-size: 16px;
  letter-spacing: -0.01em;
  display: inline-flex;
  align-items: center;
  gap: 8px;
}
.nav-logo .dot {
  width: 9px; height: 9px; border-radius: 50%;
  background: var(--green);
  box-shadow: 0 0 0 4px rgba(128,188,0,.18);
}
.nav-links {
  display: flex;
  gap: 4px;
}
.nav-link {
  padding: 8px 14px;
  border-radius: 999px;
  font-size: 13.5px;
  font-weight: 500;
  color: inherit;
  opacity: .8;
  transition: all .2s ease;
}
.nav-link:hover { opacity: 1; background: rgba(11,41,76,.05); }
.nav.dark-mode .nav-link:hover { background: rgba(255,255,255,.08); }
.nav-link.active { opacity: 1; background: rgba(11,41,76,.07); }
.nav.dark-mode .nav-link.active { background: rgba(255,255,255,.1); }

/* Footer */
footer {
  background: var(--navy);
  color: #fff;
  padding: 96px 0 32px;
}
footer .foot-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 64px;
  gap: 48px;
  align-items: start;
  padding-bottom: 64px;
  border-bottom: 1px solid rgba(255,255,255,.1);
}
footer .foot-links {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 48px;
}
footer h4 {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: rgba(255,255,255,.5);
  font-weight: 500;
  margin-bottom: 18px;
}
footer ul { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 10px; }
footer ul a { font-size: 14px; opacity: .85; }
footer ul a:hover { opacity: 1; color: var(--green-soft); }
.foot-bottom {
  padding-top: 24px;
  display: flex;
  justify-content: space-between;
  font-family: var(--font-mono);
  font-size: 11px;
  color: rgba(255,255,255,.45);
  letter-spacing: 0.06em;
}

/* Page transitions */
.page { animation: pageIn .55s cubic-bezier(.2,.7,.2,1); }
@keyframes pageIn {
  from { opacity: 0; transform: translateY(14px); }
  to { opacity: 1; transform: none; }
}

/* Stat */
.stat-num {
  font-family: var(--font-serif);
  font-size: clamp(64px, 8vw, 128px);
  line-height: 1.02;
  letter-spacing: -0.03em;
  font-weight: 400;
}
.stat-num .pct { font-size: 0.5em; vertical-align: 0.45em; color: var(--green); margin-left: 4px; font-style: italic; }

/* Dashed border accent */
.divider {
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--gray) 30%, var(--gray) 70%, transparent);
}
.dark .divider { background: linear-gradient(90deg, transparent, rgba(255,255,255,.18) 30%, rgba(255,255,255,.18) 70%, transparent); }

/* Page intro animation block */
.intro-stripe {
  position: fixed;
  inset: 0;
  background: var(--navy);
  z-index: 200;
  pointer-events: none;
  transform-origin: top;
  animation: stripeOut .9s cubic-bezier(.7,0,.2,1) forwards;
}
@keyframes stripeOut {
  0% { transform: scaleY(1); }
  100% { transform: scaleY(0); }
}

/* Image placeholder */
.imgph {
  position: relative;
  border-radius: var(--r-lg);
  overflow: hidden;
  background:
    repeating-linear-gradient(135deg, rgba(11,41,76,.04) 0 6px, rgba(11,41,76,.08) 6px 12px);
  border: 1px solid var(--gray-soft);
  display: flex;
  align-items: end;
  padding: 18px;
}
.imgph .label {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--ink-2);
  background: rgba(255,255,255,.7);
  padding: 4px 10px;
  border-radius: 6px;
}
.dark .imgph {
  background:
    repeating-linear-gradient(135deg, rgba(255,255,255,.04) 0 6px, rgba(255,255,255,.08) 6px 12px);
  border-color: rgba(255,255,255,.1);
}
.dark .imgph .label { background: rgba(255,255,255,.1); color: rgba(255,255,255,.85); }

/* Logo bar */
.logo-bar {
  display: flex; gap: 56px; align-items: center; flex-wrap: wrap;
  opacity: .85;
}
.logo-bar .lg-mark {
  font-family: var(--font-serif);
  font-style: italic;
  font-size: 28px;
  color: var(--ink-2);
  letter-spacing: -0.01em;
}
.dark .logo-bar .lg-mark { color: rgba(255,255,255,.8); }

/* Sky theme (claro) — base de la home */
.sky {
  background:
    radial-gradient(1200px 600px at 88% -8%, rgba(196,218,254,.55), transparent 60%),
    radial-gradient(900px 500px at -5% 110%, rgba(128,188,0,.10), transparent 60%),
    linear-gradient(180deg, #ffffff 0%, #F4F8FF 100%);
  color: var(--ink);
}
.sky-grid {
  position: absolute;
  inset: 0;
  pointer-events: none;
  background-image:
    linear-gradient(rgba(11,41,76,.05) 1px, transparent 1px),
    linear-gradient(90deg, rgba(11,41,76,.05) 1px, transparent 1px);
  background-size: 80px 80px;
  mask-image: radial-gradient(ellipse at 70% 30%, rgba(0,0,0,.9), rgba(0,0,0,0) 70%);
}
.soft-blue {
  background: linear-gradient(180deg, rgba(196,218,254,.35) 0%, rgba(255,255,255,.5) 100%);
}
.soft-blue-strong {
  background: linear-gradient(180deg, rgba(196,218,254,.7) 0%, rgba(255,255,255,.6) 100%);
}

/* DATAIE product screenshots */
.dataie-shot {
  border-radius: 14px;
  overflow: hidden;
  background: #fff;
  box-shadow: 0 50px 100px -40px rgba(0,0,0,.6), 0 10px 30px -10px rgba(0,0,0,.3);
  border: 1px solid rgba(255,255,255,.1);
  width: 100%;
  position: relative;
}
.dataie-shot.light {
  border: 1px solid rgba(11,41,76,.10);
  box-shadow: 0 50px 100px -30px rgba(11,41,76,.30), 0 10px 24px -10px rgba(11,41,76,.18);
}
.dataie-shot img { display: block; width: 100%; height: auto; }
.dataie-shot-2 {
  position: absolute !important;
  right: -3%;
  bottom: -10%;
  width: 64% !important;
  z-index: 2;
}

/* Mockup composition (hero stack + module tiles) */
.mockup-stack { position: relative; min-height: 460px; }
.mockup-frame {
  border-radius: 16px;
  background: #fff;
  border: 1px solid rgba(11,41,76,.10);
  box-shadow: 0 50px 100px -30px rgba(11,41,76,.30), 0 10px 24px -10px rgba(11,41,76,.18);
  overflow: hidden;
}
.mockup-tilt-l { transform: rotate(-1.2deg); position: relative; z-index: 1; }
.mockup-overlay {
  position: absolute;
  right: -4%;
  bottom: -8%;
  width: 62%;
  z-index: 2;
  transform: rotate(2deg);
  padding: 14px;
}

/* Scaled tile: child renders at 200% width then scales 0.5 to fit */
.mockup-tile { transition: transform .3s ease, box-shadow .3s ease; }
.mockup-tile:hover { transform: translateY(-3px); box-shadow: 0 30px 60px -28px rgba(11,41,76,.35); }
.mockup-scale {
  position: absolute;
  inset: 0;
  overflow: hidden;
}
.mockup-scale > * {
  width: 200%;
  transform: scale(0.5);
  transform-origin: top left;
}

/* Pillars composition (Nuestra propuesta) */
.pillars {
  display: flex;
  flex-direction: column;
  gap: 0;
  position: relative;
}
.pillar-row {
  display: grid;
  grid-template-columns: 60px 1fr 24px;
  gap: 24px;
  align-items: center;
  padding: 26px 0;
  border-top: 1px solid rgba(11,41,76,.10);
  position: relative;
}
.pillar-row:last-of-type { border-bottom: 1px solid rgba(11,41,76,.10); }
.pillar-num {
  font-family: var(--font-mono);
  font-size: 13px;
  letter-spacing: 0.1em;
  color: var(--ink-3);
}
.pillar-name {
  font-family: var(--font-serif);
  font-size: clamp(28px, 2.6vw, 40px);
  line-height: 1.05;
  letter-spacing: -0.015em;
  color: var(--ink);
}
.pillar-brief {
  margin-top: 6px;
  color: var(--ink-2);
  font-size: 14.5px;
}
.pillar-dot {
  width: 14px;
  height: 14px;
  border-radius: 999px;
  background: var(--accent, var(--blue));
  box-shadow: 0 0 0 4px color-mix(in oklab, var(--accent, var(--blue)) 22%, transparent);
}
.pillar-output {
  margin-top: 32px;
  padding: 24px 28px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  background: linear-gradient(135deg, #0B294C 0%, #163e74 100%);
  color: #fff;
  border-radius: 18px;
  position: relative;
  overflow: hidden;
}
.pillar-output::before {
  content: "";
  position: absolute;
  right: -40px; top: -40px;
  width: 180px; height: 180px;
  border-radius: 50%;
  background: radial-gradient(closest-side, rgba(21,120,250,.35), transparent 70%);
}
.pillar-arrow {
  font-family: var(--font-mono);
  font-size: 26px;
  width: 44px; height: 44px;
  border-radius: 50%;
  background: rgba(255,255,255,.12);
  border: 1px solid rgba(255,255,255,.22);
  display: flex; align-items: center; justify-content: center;
  flex: 0 0 auto;
  color: #fff;
}
.pillar-output-label {
  font-family: var(--font-serif);
  font-style: italic;
  font-size: clamp(26px, 2.6vw, 36px);
  letter-spacing: -0.015em;
  position: relative;
}

/* DATAIE demo: scale embedded mockup content to fill the aspect-ratio box */
.demo-content {
  position: absolute;
  inset: 0;
  overflow: hidden;
}
.demo-content > * {
  width: 100%;
  height: 100%;
  border-radius: 0;
  border: none;
  display: block;
}

/* Logo strip helper */
.brand-strip {
  display: flex; gap: 56px; align-items: center; flex-wrap: wrap;
}
.brand-strip img { height: 28px; width: auto; opacity: .85; }

/* Tag list */
.tag-list { display: flex; flex-wrap: wrap; gap: 8px; }
.tag {
  font-family: var(--font-mono);
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.09em;
  padding: 6px 10px;
  border-radius: 6px;
  background: rgba(11,41,76,.05);
  color: var(--ink-2);
}
.dark .tag { background: rgba(255,255,255,.08); color: rgba(255,255,255,.78); }

/* Hamburger button */
.nav-hamburger {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 8px;
  border-radius: 8px;
  transition: background .15s;
  margin-left: 4px;
}
.nav-hamburger:hover { background: rgba(11,41,76,.06); }
.nav.dark-mode .nav-hamburger:hover { background: rgba(255,255,255,.08); }
.ham-bar {
  display: block;
  width: 20px;
  height: 2px;
  background: var(--ink);
  border-radius: 2px;
  transition: transform .22s ease, opacity .22s ease;
}
.nav.dark-mode .ham-bar { background: rgba(255,255,255,.9); }
.ham-bar.ham-open:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.ham-bar.ham-open:nth-child(2) { opacity: 0; transform: scaleX(0); }
.ham-bar.ham-open:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* Mobile dropdown */
.nav-dropdown {
  position: absolute;
  top: calc(100% + 10px);
  left: 50%;
  transform: translateX(-50%);
  pointer-events: auto;
  min-width: 260px;
  background: rgba(255,255,255,.97);
  backdrop-filter: blur(18px) saturate(1.4);
  -webkit-backdrop-filter: blur(18px) saturate(1.4);
  border: 1px solid rgba(11,41,76,.09);
  border-radius: 20px;
  box-shadow: 0 20px 60px -20px rgba(11,41,76,.28);
  padding: 8px;
  display: flex;
  flex-direction: column;
  z-index: 200;
}
.nav-dropdown.dark-mode {
  background: rgba(11,41,76,.97);
  border-color: rgba(255,255,255,.12);
}
.nav-dd-link {
  padding: 11px 16px;
  border-radius: 12px;
  color: var(--ink);
  font-family: var(--font-ui);
  font-size: 15px;
  font-weight: 500;
  text-decoration: none;
  transition: background .15s;
  display: block;
}
.nav-dd-link:hover { background: rgba(11,41,76,.05); }
.nav-dd-link.active { background: rgba(11,41,76,.07); }
.nav-dropdown.dark-mode .nav-dd-link { color: rgba(255,255,255,.9); }
.nav-dropdown.dark-mode .nav-dd-link:hover { background: rgba(255,255,255,.08); }
.nav-dropdown.dark-mode .nav-dd-link.active { background: rgba(255,255,255,.1); }

/* Responsive */
/* ─── Logo ticker ─── */
.logo-ticker-wrap {
  overflow: hidden;
  mask-image: linear-gradient(90deg, transparent, #000 12%, #000 88%, transparent);
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 12%, #000 88%, transparent);
}
.logo-ticker-track {
  display: flex;
  align-items: center;
  width: max-content;
  animation: tickerScroll 28s linear infinite;
}
.logo-ticker-track:hover { animation-play-state: paused; }
@keyframes tickerScroll {
  from { transform: translateX(0); }
  to   { transform: translateX(-50%); }
}
.logo-ticker-item {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 40px;
  flex-shrink: 0;
}

@media (max-width: 900px) {
  footer .foot-grid { grid-template-columns: 1fr; gap: 48px; }
  footer .foot-links { gap: 32px; }
  .nav-links { display: none; }
  .nav-cta { display: none; }
  .nav-hamburger { display: flex; }
  .sec01-header { grid-template-columns: 1fr !important; gap: 24px !important; }
  .propuesta-flow-row { flex-wrap: wrap !important; gap: 8px !important; }
  .propuesta-flow-row .connector { display: none !important; }
  .propuesta-flow-row > button { flex: 1 1 calc(50% - 8px) !important; min-width: 140px !important; }
  .propuesta-result { flex: 1 1 100% !important; }
  .context-tabs { flex-wrap: wrap !important; }
  .context-detail { grid-template-columns: 1fr !important; }
  .sec03-header { flex-direction: column !important; align-items: flex-start !important; }
  .pillars-grid { grid-template-columns: 1fr !important; }
  .dataie-grid { grid-template-columns: 1fr !important; gap: 40px !important; }
}
@media (max-width: 600px) {
  footer .foot-grid { grid-template-columns: 1fr; gap: 32px; }
  footer .foot-links { grid-template-columns: 1fr; gap: 28px; }
  .foot-bottom { flex-direction: column; gap: 12px; }
  .context-tabs button { flex: 1 1 40% !important; }
}
