:root {
  --bg: #fcfcfc;
  --ink: #3a3f4a;
  --muted: #707783;
  --light: #b8c0d0;
  --blue: #2b78c5;
  --line: rgba(58, 63, 74, 0.09);
  --white: #fff;
  --radius: 24px;
  --shadow: 0 18px 60px rgba(58, 63, 74, 0.07);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: Inter, "SF Pro Display", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  -webkit-font-smoothing: antialiased;
}
body.menu-open { overflow: hidden; }
img { display: block; max-width: 100%; height: auto; }
a { color: inherit; text-decoration: none; }
button, input { font: inherit; }
button { cursor: pointer; }
:focus-visible { outline: 2px solid var(--blue); outline-offset: 3px; }
.icon-sprite { position: absolute; width: 0; height: 0; overflow: hidden; }
.icon { width: 1.15rem; height: 1.15rem; fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
.icon-inline { width: 1rem; height: 1rem; }
.icon-tiny { width: .72rem; height: .72rem; }
.shell { width: min(calc(100% - 3rem), 1280px); margin-inline: auto; }
.skip-link { position: fixed; left: 1rem; top: -4rem; z-index: 100; background: var(--ink); color: white; padding: .75rem 1rem; border-radius: 8px; }
.skip-link:focus { top: 1rem; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0, 0, 0, 0); }

.site-header { position: fixed; inset: 0 0 auto; z-index: 50; padding-top: 1rem; }
.nav {
  height: 68px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 2rem;
  padding: 0 1.25rem;
  border: 1px solid var(--line);
  border-radius: 22px;
  background: rgba(255,255,255,.82);
  box-shadow: var(--shadow);
  backdrop-filter: blur(22px);
}
.brand img, footer img { width: 148px; height: auto; }
.nav-links { display: flex; align-items: center; gap: 1.5rem; margin-left: auto; }
.nav-links a { font-size: .76rem; color: rgba(58,63,74,.62); }
.nav-links a:hover { color: var(--blue); }
.mobile-languages { display: none; }
.nav-actions, .language-switcher { display: flex; align-items: center; gap: .4rem; }
.language-switcher { border: 1px solid var(--line); border-radius: 999px; padding: 2px; }
.language-switcher button { border: 0; border-radius: 999px; background: transparent; color: var(--muted); padding: .3rem .45rem; font-size: .62rem; font-weight: 700; }
.language-switcher button[aria-pressed="true"] { background: var(--ink); color: white; }
.menu-button { display: none; width: 42px; height: 42px; border: 1px solid var(--line); border-radius: 50%; background: white; padding: 11px; }
.menu-button span { display: block; height: 1px; background: var(--ink); margin: 4px 0; }

.hero { min-height: 720px; display: grid; place-items: center; position: relative; overflow: hidden; border-bottom: 1px solid var(--line); padding: 8rem 0 4rem; }
.network { position: absolute; inset: 0; background: radial-gradient(circle at 50% 46%, rgba(43,120,197,.1), transparent 35%), linear-gradient(rgba(58,63,74,.028) 1px, transparent 1px), linear-gradient(90deg,rgba(58,63,74,.028) 1px, transparent 1px); background-size: auto, 44px 44px, 44px 44px; mask-image: linear-gradient(to bottom, #000 55%, transparent); }
.network::after { content: ""; position: absolute; left: 50%; top: 50%; width: 820px; height: 620px; max-width: 80vw; transform: translate(-50%,-50%); border-radius: 50%; background: rgba(43,120,197,.045); filter: blur(90px); animation: breathe 5s ease-in-out infinite; }
.hero-content { position: relative; display: grid; grid-template-areas: "message title"; grid-template-columns: minmax(0, 3fr) minmax(0, 2fr); align-items: center; gap: 3rem; }
.hero-title { grid-area: title; text-align: center; }
.hero-wordmark { margin: 0; font-size: clamp(6.075rem, 9.855vw, 9.45rem); font-weight: 700; line-height: .8; letter-spacing: -.085em; }
.hero-wordmark .muted { color: var(--light); }
.hero-message { grid-area: message; }
.hero-heading { margin: 1.6rem 0 0; font-size: clamp(2.15rem, 4.5vw, 4rem); line-height: .98; letter-spacing: -.05em; }
.hero-subtitle { margin: 1.5rem 0 0; color: var(--muted); font-size: clamp(1.4rem, 3vw, 2.2rem); font-weight: 600; letter-spacing: -.04em; }
.hero-copy { margin: 1rem 0 0; max-width: 720px; color: var(--muted); font-size: 1.05rem; line-height: 1.55; }
.eyebrow { margin: 0; color: var(--blue); font-size: .66rem; font-weight: 700; letter-spacing: .2em; text-transform: uppercase; }
.button-row { display: flex; justify-content: flex-start; gap: .75rem; margin-top: 1.8rem; }
.button { display: inline-flex; align-items: center; justify-content: center; gap: .5rem; border: 1px solid var(--blue); border-radius: 999px; background: var(--blue); color: white; padding: .85rem 1.3rem; font-weight: 600; font-size: .88rem; box-shadow: 0 12px 30px rgba(43,120,197,.16); transition: transform .2s, box-shadow .2s; }
.button:hover { transform: translateY(-2px); box-shadow: 0 15px 34px rgba(43,120,197,.22); }
.button-secondary { border-color: var(--line); background: rgba(255,255,255,.75); color: var(--ink); box-shadow: none; }
.button-small { padding: .55rem .9rem; font-size: .72rem; }

.section { padding: 5rem 0; }
.section[id] { scroll-margin-top: 2rem; }
.section-alt { border-block: 1px solid var(--line); background: white; }
.section h2 { max-width: 820px; margin: .75rem 0 1rem; font-size: clamp(2.15rem, 4.5vw, 4rem); line-height: .98; letter-spacing: -.05em; text-wrap: balance; }
.section h3 { margin: 0; font-size: 1.22rem; letter-spacing: -.025em; }
.section p { color: rgba(58,63,74,.58); line-height: 1.65; }
.section p.eyebrow { color: var(--blue); }
.section .lead { max-width: 820px; font-size: 1.05rem; line-height: 1.55; }
.section-heading { max-width: 820px; }
.split { display: grid; grid-template-columns: .88fr 1.12fr; align-items: center; gap: 2rem; }
.feature-image { aspect-ratio: 16/10; width: 100%; object-fit: cover; border: 1px solid rgba(58,63,74,.07); border-radius: 28px; box-shadow: 0 20px 65px rgba(58,63,74,.07); }
.process-layout { display: grid; grid-template-columns: 820px minmax(0, 1fr); align-items: start; gap: 2rem; margin-top: 2rem; }
.process-image { width: 100%; aspect-ratio: 4/3; object-fit: cover; border: 1px solid rgba(58,63,74,.07); border-radius: 28px; background: white; }
.steps { margin: 0; padding: 0; list-style: none; display: grid; gap: .6rem; }
.steps li { display: flex; gap: 1rem; padding: 1rem; border: 1px solid rgba(58,63,74,.07); border-radius: 22px; background: white; }
.steps li > span { position: relative; z-index: 1; display: grid; flex: 0 0 40px; height: 40px; place-items: center; border-radius: 12px; background: var(--blue); color: white; }
.steps p { margin: .25rem 0 0; font-size: .875rem; line-height: 1.25rem; }
.client-marquee { width: 100%; margin-top: 2rem; overflow: hidden; mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent); }
.client-marquee-track { display: flex; width: max-content; animation: client-marquee 32s linear infinite; }
.client-marquee-group { display: flex; flex: 0 0 auto; align-items: center; gap: clamp(2.5rem, 5vw, 5rem); padding-right: clamp(2.5rem, 5vw, 5rem); }
.client-marquee img { width: auto; max-width: 170px; height: clamp(34px, 4vw, 52px); object-fit: contain; filter: grayscale(1); opacity: .58; transition: filter .25s, opacity .25s; }
.client-marquee img:hover { filter: grayscale(0); opacity: 1; }
@keyframes client-marquee { to { transform: translateX(-50%); } }
.project-grid { display: grid; grid-auto-flow: column; grid-auto-columns: calc((100% - 1.5rem) / 3); grid-template-rows: 1fr; gap: .75rem; margin-top: 2rem; overflow-x: auto; overscroll-behavior-inline: contain; scroll-snap-type: inline mandatory; scrollbar-width: none; }
.project-grid::-webkit-scrollbar { display: none; }
.project-dots { display: flex; justify-content: center; gap: .55rem; margin-top: 1.25rem; }
.project-dots button { width: 9px; height: 9px; padding: 0; border: 0; border-radius: 50%; background: var(--light); transition: background .2s, transform .2s; }
.project-dots button[aria-pressed="true"] { background: var(--ink); transform: scale(1.15); }
.project { display: flex; min-height: 100%; flex-direction: column; overflow: hidden; border: 1px solid rgba(58,63,74,.07); border-radius: 24px; background: var(--bg); scroll-snap-align: start; transition: transform .5s, box-shadow .5s, border-color .5s; }
.project:hover { transform: translateY(-3px); box-shadow: var(--shadow); }
.project > img { width: 100%; aspect-ratio: 16/10; object-fit: contain; background: white; padding: 1.75rem; border-bottom: 1px solid rgba(58,63,74,.06); transition: transform .7s; }
.project:hover > img { transform: scale(1.02); }
.project:nth-child(1) > img { padding: 1rem; }
.project:nth-child(2) > img { object-fit: cover; padding: 0; }
.project:nth-child(3) > img { object-position: bottom; padding: 1rem 1.75rem 0; }
.project:nth-child(4) > img,
.project:nth-child(5) > img { object-fit: contain; padding: 1.75rem; }
.project div { position: relative; display: flex; flex: 1; flex-direction: column; padding: 1.25rem; }
.project span { color: var(--blue); font-size: .62rem; font-weight: 700; letter-spacing: .15em; text-transform: uppercase; }
.project h3 { margin-top: .4rem; }
.project p { font-size: .875rem; line-height: 1.5rem; }
.about-quote { position: relative; margin: 0; padding-left: 2rem; border-left: 2px solid rgba(43,120,197,.35); }
.about-quote::before { content: "“"; position: absolute; left: .55rem; top: -.4rem; color: var(--blue); font-size: 2rem; line-height: 1; }
.quote-attribution { display: flex; flex-direction: column; gap: .2rem; margin-top: 1.5rem; font-style: normal; }
.quote-attribution span { color: var(--muted); font-size: .8rem; }
.leadership-list { display: grid; gap: .75rem; margin-block: 1rem; padding-left: 1.5rem; color: rgba(58,63,74,.58); }
.leadership-list li { padding-left: .35rem; line-height: 1.55; }
#about .split { grid-template-columns: .85fr 1.15fr; align-items: start; }
.cta-section { padding: 4.5rem 1rem; }
.cta { display: flex; max-width: 1180px; align-items: end; justify-content: space-between; gap: 1.5rem; padding: 2.5rem; border: 1px solid rgba(43,120,197,.1); border-radius: 30px; background: linear-gradient(120deg,#fff 10%,#f4f8fc 100%); box-shadow: 0 24px 80px rgba(43,120,197,.07); }
.cta h2 { margin-bottom: 0; }
.cta .button { flex: 0 0 auto; }
@keyframes breathe { 0%,100% { opacity: .7; transform: translate(-50%,-50%) scale(.96); } 50% { opacity: 1; transform: translate(-50%,-50%) scale(1.04); } }

footer { border-top: 1px solid var(--line); background: white; }
.footer-content { display: flex; align-items: end; justify-content: space-between; gap: 2rem; padding-block: 2.5rem; }
.footer-content p { margin: .8rem 0 0; color: var(--muted); font-size: .85rem; }
.footer-links { display: flex; flex-wrap: wrap; gap: 1.2rem; font-size: .78rem; color: var(--muted); }
.link-button { border: 0; padding: 0; background: transparent; color: var(--blue); }
.copyright { margin: 0; padding: 1rem; border-top: 1px solid var(--line); text-align: center; color: var(--light); font-size: .62rem; letter-spacing: .12em; text-transform: uppercase; }

.chat { position: fixed; right: 1.25rem; bottom: 1.25rem; z-index: 70; }
.chat-launcher { display: flex; align-items: center; gap: .7rem; border: 1px solid var(--line); border-radius: 999px; background: rgba(255,255,255,.94); padding: .35rem 1rem .35rem .35rem; box-shadow: 0 12px 40px rgba(58,63,74,.16); }
.chat-launcher img { width: 58px; height: 58px; object-fit: contain; object-position: bottom; border-radius: 50%; background: #f0f1f3; }
.chat-launcher span { display: flex; flex-direction: column; align-items: start; }
.chat-launcher strong { font-size: .78rem; }
.chat-launcher small { display: flex; align-items: center; gap: .25rem; margin-top: .15rem; color: var(--muted); font-size: .65rem; }
.chat-panel { display: none; width: min(420px, calc(100vw - 1.5rem)); height: min(680px, calc(100vh - 7rem)); margin-bottom: .7rem; overflow: hidden; border: 1px solid var(--line); border-radius: 26px; background: white; box-shadow: 0 20px 70px rgba(58,63,74,.18); }
.chat-panel.open { display: flex; flex-direction: column; }
.chat-panel header { display: flex; align-items: center; gap: .7rem; padding: .8rem 1rem; border-bottom: 1px solid var(--line); }
.chat-panel header img { width: 44px; height: 44px; object-fit: contain; border-radius: 14px; background: #f0f1f3; }
.chat-panel header div { display: flex; flex-direction: column; }
.chat-panel header span { color: var(--muted); font-size: .68rem; }
.chat-close { margin-left: auto; border: 0; background: transparent; color: var(--muted); font-size: 1.5rem; }
.messages { flex: 1; overflow-y: auto; padding: 1rem; }
.message { max-width: 86%; margin: 0 0 .65rem; padding: .7rem .85rem; border-radius: 16px 16px 16px 5px; background: rgba(58,63,74,.06); color: var(--ink); font-size: .8rem; line-height: 1.5; }
.message.user { margin-left: auto; border-radius: 16px 16px 5px; background: var(--blue); color: white; }
.contact-form { display: grid; gap: .7rem; margin-top: .9rem; padding: 1rem; border: 1px solid var(--line); border-radius: 20px; background: var(--bg); }
.contact-field { display: grid; gap: .3rem; }
.contact-field label { color: var(--muted); font-size: .68rem; font-weight: 600; }
.contact-field input { width: 100%; border: 1px solid var(--line); border-radius: 12px; background: white; padding: .7rem .8rem; color: var(--ink); font-size: .8rem; line-height: 1.5; outline: none; }
.contact-field input:focus { border-color: var(--blue); }
.contact-field input:user-invalid { border-color: #bd4b4b; }
.contact-submit { width: 100%; margin-top: .2rem; }
.contact-submit:disabled { cursor: wait; opacity: .65; }
.contact-status { min-height: 1.2em; margin: 0; color: #a23d3d; font-size: .72rem; line-height: 1.4; }
.contact-trap { position: absolute; left: -10000px; width: 1px; height: 1px; overflow: hidden; }

.legal-page main { padding: 7rem 0 5rem; }
.legal-header { display: flex; align-items: center; justify-content: space-between; margin-bottom: 4rem; }
.legal-header img { width: 150px; }
.legal-header a { border: 1px solid var(--line); border-radius: 999px; padding: .65rem 1rem; font-size: .75rem; }
.legal-header > a:first-child { border: 0; padding: 0; }
.legal-actions { display: flex; align-items: center; gap: .75rem; }
.legal-intro { margin-bottom: 3rem; }
.legal-intro h1 { margin: .8rem 0; font-size: clamp(2.8rem, 6vw, 5.5rem); line-height: .95; letter-spacing: -.06em; }
.legal-intro .spanish-title { color: var(--light); font-size: clamp(1.7rem, 3vw, 2.6rem); font-weight: 600; }
.legal-sections { display: grid; gap: .8rem; }
.legal-section { display: grid; grid-template-columns: 1fr 1fr; gap: 3rem; padding: 2rem; border: 1px solid var(--line); border-radius: var(--radius); background: white; }
.legal-section > div + div { border-left: 1px solid var(--line); padding-left: 3rem; }
.legal-section h2 { margin: 0; font-size: 1.2rem; }
.legal-section p { color: var(--muted); font-size: .88rem; line-height: 1.75; }
html[data-lang="en"] .legal-section [lang="es"],
html[data-lang="es"] .legal-section [lang="en"] { display: none; }
html[data-lang="en"] .legal-section,
html[data-lang="es"] .legal-section { grid-template-columns: minmax(0, 760px); }
html[data-lang="en"] .legal-section > div + div,
html[data-lang="es"] .legal-section > div + div { border: 0; padding: 0; }

@media (max-width: 1199px) {
  .nav-links { position: fixed; inset: 5.8rem 1rem auto; display: none; flex-direction: column; align-items: stretch; gap: 0; padding: .7rem; border: 1px solid var(--line); border-radius: 20px; background: white; box-shadow: var(--shadow); }
  .nav-links.open { display: flex; }
  .nav-links a { padding: .9rem; border-radius: 12px; font-size: .9rem; }
  .mobile-languages { display: flex; gap: .5rem; padding: .8rem; border-top: 1px solid var(--line); }
  .mobile-languages button { flex: 1; border: 1px solid var(--line); border-radius: 999px; background: white; padding: .6rem; color: var(--muted); }
  .mobile-languages button[aria-pressed="true"] { border-color: var(--ink); background: var(--ink); color: white; }
  .menu-button { display: block; }
  .nav-actions > .button { display: none; }
  .process-layout { grid-template-columns: 1fr; }
  .process-image { max-width: 820px; }
}

@media (max-width: 1023px) {
  .hero { min-height: 640px; padding-top: 8rem; }
  .hero-content { grid-template-areas: "title" "message"; grid-template-columns: 1fr; gap: 1rem; text-align: center; }
  .hero-wordmark { font-size: clamp(5rem, 14vw, 9rem); }
  .hero-message { display: flex; flex-direction: column; align-items: center; }
  .hero-subtitle { margin-top: 1rem; }
  .hero-copy { margin-inline: auto; }
  .button-row { justify-content: center; }
  .section { padding: 3rem 0; }
  .split, #about .split, .legal-section { grid-template-columns: 1fr; }
  .project-grid { grid-auto-columns: calc((100% - .75rem) / 2); }
  .process-image { max-height: 560px; }
  .legal-section > div + div { border-left: 0; border-top: 1px solid var(--line); padding: 2rem 0 0; }
}

@media (max-width: 767px) {
  .project-grid { grid-auto-columns: 100%; }
}

@media (max-width: 639px) {
  .shell { width: min(calc(100% - 1.5rem), 1280px); }
  .site-header { padding-top: .65rem; }
  .nav { height: 62px; padding-inline: .8rem; }
  .brand img { width: 128px; }
  .nav-actions > .language-switcher { display: none; }
  .hero { min-height: 600px; padding-block: 7rem 3.5rem; }
  .hero-wordmark { font-size: clamp(4rem, 23vw, 7rem); }
  .hero-copy { font-size: .95rem; }
  .button-row { flex-direction: column; align-items: stretch; }
  .section { padding: 2.5rem 0; }
  .process-layout { margin-top: 1.5rem; }
  .cta-section { padding: 2.5rem .25rem; }
  .cta { padding: 1.5rem; }
  .cta, .footer-content { align-items: stretch; flex-direction: column; }
  .cta .button { width: 100%; }
  .chat { right: .75rem; bottom: .75rem; }
  .chat-launcher span { display: none; }
  .chat-launcher { padding: .3rem; }
  .chat-launcher img { width: 54px; height: 54px; }
  .legal-page main { padding-top: 2rem; }
  .legal-header { margin-bottom: 3rem; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition: none !important; }
  .client-marquee { overflow-x: auto; mask-image: none; }
  .client-marquee-track { animation: none; }
  .client-marquee-group:last-child { display: none; }
}
