:root {
  --navy: #0B1F3A;
  --blue: #2F6FED;
  --sky: #8CCBFF;
  --gray: #5A6B82;
  --paper: #F3F1EC;
  --line: rgba(11, 31, 58, .14);
  --ease: cubic-bezier(.2, .7, .1, 1);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: "Inter", system-ui, sans-serif;
  color: var(--navy);
  background: var(--paper);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
/* grano sutil para quitar el aspecto "plano digital" */
body::after {
  content: ""; position: fixed; inset: 0; pointer-events: none; z-index: 100; opacity: .05;
  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='.9' numOctaves='3'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}
a { color: inherit; }
h1, h2, h3 { font-family: "Sora", sans-serif; letter-spacing: -.035em; margin: 0; }
h2 { font-size: clamp(2.2rem, 6vw, 4.6rem); font-weight: 800; line-height: .98; }
h3 { font-size: 1.3rem; font-weight: 700; letter-spacing: -.02em; }
.wrap { width: min(1280px, 100% - 2.5rem); margin-inline: auto; }
.blue { color: var(--blue); }

/* ---------- Logo ---------- */
.logo { display: inline-flex; align-items: stretch; gap: .3em; font-family: "Sora", sans-serif; font-weight: 800; font-size: 1.4rem; line-height: .86; letter-spacing: -.025em; color: var(--navy); text-decoration: none; }
.logo__bar { width: .16em; background: var(--blue); border-radius: 1px; }
.logo__words { display: flex; flex-direction: column; gap: .08em; padding: .04em 0; }
.logo__dot { display: inline-block; width: .17em; height: .17em; background: var(--blue); margin-left: .1em; }

/* ---------- Cabecera ---------- */
.topbar { position: sticky; top: 0; z-index: 50; background: rgba(243, 241, 236, .85); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); transition: box-shadow .3s; }
.topbar.is-scrolled { box-shadow: 0 1px 0 var(--line); }
.topbar__inner { display: flex; align-items: center; justify-content: space-between; padding: 1rem 0; }
.nav { display: flex; align-items: center; gap: 2rem; font-weight: 500; font-size: .95rem; }
.nav a { text-decoration: none; position: relative; }
.nav a:not(.pill)::after { content: ""; position: absolute; left: 0; right: 0; bottom: -4px; height: 2px; background: var(--blue); transform: scaleX(0); transform-origin: right; transition: transform .35s var(--ease); }
.nav a:not(.pill):hover::after { transform: scaleX(1); transform-origin: left; }
.pill { background: var(--navy); color: #fff; padding: .6rem 1.1rem; border-radius: 999px; transition: background .25s; }
.pill:hover { background: var(--blue); }

/* ---------- Botones ---------- */
.btn { display: inline-flex; align-items: center; gap: .6rem; padding: 1rem 1.6rem; border-radius: 999px; font-weight: 600; text-decoration: none; transition: background .25s, color .25s, transform .25s var(--ease); }
.btn .arrow { transition: transform .3s var(--ease); }
.btn:hover .arrow { transform: translateX(5px); }
.btn--solid { background: var(--blue); color: #fff; }
.btn--solid:hover { background: var(--navy); }
.btn--line { border: 1.5px solid var(--navy); }
.btn--line:hover { background: var(--navy); color: #fff; }

/* ---------- Hero ---------- */
.hero { padding: clamp(3rem, 9vw, 7rem) 0 clamp(3rem, 6vw, 5rem); }
.kicker { display: flex; align-items: center; gap: .7rem; font-weight: 600; font-size: .9rem; text-transform: uppercase; letter-spacing: .14em; color: var(--gray); margin: 0 0 2rem; }
.sq { width: 10px; height: 10px; background: var(--blue); display: inline-block; }
.hero__title { font-size: clamp(3rem, 10.5vw, 9.5rem); font-weight: 800; line-height: .92; letter-spacing: -.05em; }
.line { display: block; overflow: hidden; padding-bottom: .06em; }
.line .word { display: inline-block; transition: transform 1s var(--ease); }
.js .line .word { transform: translateY(105%); }
.js .is-loaded .line .word { transform: none; }
.line:nth-child(2) .word { transition-delay: .1s; }
.line:nth-child(3) .word { transition-delay: .2s; }
.muted { color: rgba(11, 31, 58, .35); }
.line--rotate { display: flex; flex-wrap: wrap; }
.rotator { position: relative; display: inline-grid; color: var(--blue); }
.rotator__item { grid-area: 1 / 1; transform: translateY(105%); opacity: 0; transition: transform .7s var(--ease), opacity .7s var(--ease); white-space: nowrap; }
.rotator__item b { color: var(--navy); }
.rotator__item.is-active { transform: none; opacity: 1; }
.rotator__item.is-out { transform: translateY(-105%); opacity: 0; }
.hero__foot { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: flex-end; gap: 2rem; margin-top: clamp(2.5rem, 6vw, 4.5rem); padding-top: 2rem; border-top: 1px solid var(--line); }
.hero__lead { max-width: 30rem; font-size: 1.15rem; margin: 0; }
.hero__actions { display: flex; gap: .8rem; flex-wrap: wrap; }

/* ---------- Marquee ---------- */
.marquee { background: var(--navy); color: #fff; overflow: hidden; padding: 1.3rem 0; transform: rotate(-1.5deg); margin: 1rem -1rem; }
.marquee__track { display: flex; align-items: center; gap: 2.2rem; width: max-content; animation: marquee 32s linear infinite; font-family: "Sora", sans-serif; font-weight: 700; font-size: clamp(1.3rem, 2.6vw, 2rem); letter-spacing: -.02em; }
.marquee__track i { width: .45em; height: .45em; background: var(--blue); flex: none; }
@keyframes marquee { to { transform: translateX(-50%); } }

/* ---------- Secciones ---------- */
.section { padding: clamp(5rem, 11vw, 9rem) 0; }
.label { font-size: .9rem; font-weight: 600; color: var(--gray); margin: 0 0 1.5rem; letter-spacing: .02em; }
.label--light { color: rgba(255,255,255,.6); }
.section__head { display: grid; gap: .5rem; margin-bottom: clamp(2.5rem, 6vw, 4.5rem); }

/* Nosotros */
.about { display: grid; grid-template-columns: 1fr 3fr; gap: 2rem; }
.about__big { font-family: "Sora", sans-serif; font-size: clamp(1.7rem, 3.6vw, 3rem); font-weight: 600; line-height: 1.12; letter-spacing: -.03em; margin: 0 0 3rem; }
.about__big em { font-style: normal; color: var(--blue); }
.about__cols { display: grid; grid-template-columns: 1fr 1fr; gap: 2rem; color: #33445C; }
.about__cols p { margin: 0; }
.signature { display: flex; align-items: center; gap: 1rem; margin-top: 2.5rem; font-weight: 600; }
.signature__line { width: 48px; height: 2px; background: var(--blue); }

/* Servicios */
.section--ink { background: var(--navy); color: #fff; border-radius: clamp(1.5rem, 4vw, 3rem); margin: 0 .75rem; }
.section--ink .label { color: rgba(255,255,255,.55); }
.services { list-style: none; margin: 0; padding: 0; border-top: 1px solid rgba(255,255,255,.18); }
.service { position: relative; display: grid; grid-template-columns: 4rem 1.3fr 1fr 2rem; align-items: center; gap: 1.5rem; padding: 1.8rem .5rem; border-bottom: 1px solid rgba(255,255,255,.18); overflow: hidden; isolation: isolate; cursor: default; }
.service::before { content: ""; position: absolute; inset: 0; background: var(--blue); transform: scaleY(0); transform-origin: bottom; transition: transform .45s var(--ease); z-index: -1; }
.service:hover::before { transform: scaleY(1); }
.service__n { font-family: "Sora", sans-serif; font-size: .95rem; color: rgba(255,255,255,.5); }
.service__t { font-family: "Sora", sans-serif; font-weight: 700; font-size: clamp(1.5rem, 3.4vw, 2.6rem); letter-spacing: -.03em; line-height: 1.05; transition: transform .45s var(--ease); }
.service:hover .service__t { transform: translateX(10px); }
.service__d { color: rgba(255,255,255,.7); }
.service__a { font-size: 1.5rem; transform: rotate(-45deg); transition: transform .45s var(--ease); justify-self: end; }
.service:hover .service__a { transform: rotate(0); }

/* Proceso */
.steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1rem; }
.step { background: #fff; border-radius: 1.5rem; padding: 2rem; min-height: 320px; display: flex; flex-direction: column; justify-content: space-between; transition: transform .4s var(--ease); }
.step:hover { transform: translateY(-6px) rotate(-.6deg); }
.step__n { font-family: "Sora", sans-serif; font-weight: 800; font-size: 5rem; line-height: 1; color: var(--blue); }
.step h3 { margin: 2rem 0 .6rem; }
.step p { margin: 0; color: #33445C; }
.step--blue { background: var(--blue); color: #fff; }
.step--blue .step__n { color: var(--navy); }
.step--blue p { color: rgba(255,255,255,.85); }

/* Compromiso: texto que se "enciende" con el scroll */
.commit { background: var(--blue); color: #fff; }
.commit__text { font-family: "Sora", sans-serif; font-weight: 700; font-size: clamp(1.8rem, 4.6vw, 4rem); line-height: 1.1; letter-spacing: -.035em; margin: 0; max-width: 22ch; }
.commit__text .w { opacity: .22; transition: opacity .25s linear; }
.commit__text .w.on { opacity: 1; }

/* Contacto */
.contact__title { font-size: clamp(4rem, 17vw, 15rem); line-height: .85; letter-spacing: -.06em; }
.contact__lead { font-size: 1.2rem; max-width: 32rem; margin: 1.5rem 0 3rem; }
.contact__links { border-top: 1px solid var(--line); }
.contact__link { display: grid; grid-template-columns: 1fr 2fr auto; gap: 1rem; align-items: center; padding: 1.5rem .25rem; border-bottom: 1px solid var(--line); text-decoration: none; font-family: "Sora", sans-serif; font-size: clamp(1.05rem, 2vw, 1.5rem); font-weight: 600; transition: padding .35s var(--ease), color .25s; }
.contact__link span:first-child { color: var(--gray); font-weight: 400; font-size: .9em; }
.contact__link .arrow { transition: transform .35s var(--ease); }
.contact__link:hover { padding-left: 1rem; color: var(--blue); }
.contact__link:hover .arrow { transform: translate(4px, -4px); }

/* Pie */
.footer { background: var(--navy); color: #fff; padding: 4rem 0 2rem; overflow: hidden; }
.footer__mark { font-family: "Sora", sans-serif; font-weight: 800; font-size: clamp(3rem, 14.5vw, 13.5rem); letter-spacing: -.06em; line-height: .8; white-space: nowrap; display: flex; align-items: flex-end; }
.footer__mark i { display: inline-block; width: .17em; height: .17em; background: var(--blue); margin-left: .08em; margin-bottom: .02em; flex: none; }
.footer__row { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 1rem; margin-top: 2.5rem; padding-top: 1.5rem; border-top: 1px solid rgba(255,255,255,.15); font-size: .9rem; color: rgba(255,255,255,.65); }
.footer__row a { text-decoration: none; }
.footer__row a:hover { color: #fff; }

/* ---------- Animaciones de entrada ---------- */
.js .reveal { opacity: 0; transform: translateY(28px); transition: opacity .9s var(--ease), transform .9s var(--ease); }
.js .reveal.in { opacity: 1; transform: none; }

/* ---------- Móvil ---------- */
@media (max-width: 820px) {
  .nav a:not(.pill) { display: none; }
  .hero__title { font-size: 11vw; }
  .about { grid-template-columns: 1fr; }
  .about__cols { grid-template-columns: 1fr; }
  .service { grid-template-columns: 2.5rem 1fr 1.5rem; padding: 1.4rem .25rem; gap: .4rem 1rem; }
  .service__d { grid-column: 2 / 3; grid-row: 2; font-size: .95rem; }
  .service__a { grid-column: 3; grid-row: 1; }
  .steps { grid-template-columns: 1fr; }
  .step { min-height: 0; }
  .step h3 { margin-top: 1.2rem; }
  .contact__link { grid-template-columns: 1fr auto; }
  .contact__link span:first-child { grid-column: 1 / -1; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
  .js .reveal, .js .line .word { opacity: 1; transform: none; }
  .commit__text .w { opacity: 1; }
}
