/* =============================================================
   1. Tokens
   ============================================================= */
:root {
  --ink:    #1E1E1B;          /* cálido casi-negro, sin frío azulado */
  --ink2:   #171714;          /* más profundo, cálido */
  --sand:   #E8D9BB;          /* arena más dorada */
  --terra:  #C04C2A;          /* terracota un toque más vivo */
  --terra2: #8C3318;          /* terracota oscuro para CTAs y bandas */
  --paper:  #F5F0E6;
  --muted:  #706B64;
  --cream:  #EEEAE0;
  --line:   rgba(30, 30, 27, 0.12);
  --line-s: rgba(30, 30, 27, 0.06);

  --display:        'Barlow Condensed', 'Arial Narrow', sans-serif;
  --display-accent: 'Instrument Serif', Georgia, serif;
  --sans:           'Manrope', system-ui, sans-serif;
  --mono:           'JetBrains Mono', 'Courier New', monospace;

  --ease-out:    cubic-bezier(0.16, 1, 0.3, 1);
  --ease-soft:   cubic-bezier(0.25, 0.46, 0.45, 0.94);
  --ease-bounce: cubic-bezier(0.34, 1.56, 0.64, 1);

  --gutter: clamp(1.25rem, 4vw, 4rem);
  --max-w:  1280px;
  --nav-h:  72px;
}

/* =============================================================
   2. View Transitions
   ============================================================= */
@view-transition { navigation: auto; }
::view-transition-old(root),
::view-transition-new(root) {
  animation-duration: 0.45s;
  animation-timing-function: var(--ease-out);
}
::view-transition-old(root) { animation-name: fadeOutUp; }
::view-transition-new(root) { animation-name: fadeInUp; }
@keyframes fadeOutUp { to   { opacity: 0; transform: translateY(-10px); } }
@keyframes fadeInUp  { from { opacity: 0; transform: translateY(10px);  } }

/* =============================================================
   3. Reset & base
   ============================================================= */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
  overflow-x: clip;
}
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

body {
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.6;
  color: var(--ink);
  background: var(--paper);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: clip;
  overscroll-behavior-y: none;
}
img, svg, video { display: block; max-width: 100%; }
img { height: auto; }
button { font: inherit; color: inherit; cursor: pointer; border: 0; background: none; }
a { color: inherit; text-decoration: none; }
p { text-wrap: pretty; }
h1, h2, h3 { text-wrap: balance; }
ul { list-style: none; }
::selection { background: var(--terra); color: var(--paper); }
:focus-visible {
  outline: 2px solid var(--terra);
  outline-offset: 3px;
  border-radius: 3px;
}
.skip-link {
  position: fixed; top: -100px; left: 1rem;
  padding: .5rem 1rem; background: var(--ink); color: var(--paper);
  z-index: 9999; border-radius: 4px; font-weight: 500; font-size: .875rem;
  transition: top .2s;
}
.skip-link:focus { top: 1rem; }

/* =============================================================
   4. Container
   ============================================================= */
.container {
  width: 100%;
  max-width: var(--max-w);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

/* =============================================================
   5. Wordmark system
   ============================================================= */
.wordmark {
  display: flex;
  flex-direction: column;
  line-height: 1;
  gap: .45em;
}
.wordmark--inline {
  flex-direction: row;
  align-items: baseline;
  gap: .55em;
}
.wordmark--center { align-items: center; }
.wm-a {
  font-family: var(--display);
  font-weight: 800;
  letter-spacing: .03em;
  text-transform: uppercase;
  line-height: 1;
}
.wm-b {
  font-family: var(--sans);
  font-weight: 500;
  font-size: .42em;
  letter-spacing: 0.42em;
  text-transform: uppercase;
  line-height: 1;
}

/* =============================================================
   6. Typography
   ============================================================= */
.eyebrow {
  font-family: var(--mono);
  font-size: clamp(.65rem, 1.2vw, .75rem);
  letter-spacing: .18em;
  text-transform: uppercase;
  color: var(--muted);
}
.eyebrow--terra { color: var(--terra); }

h1, .h1 {
  font-family: var(--display);
  font-size: clamp(3.75rem, 10.5vw, 9.5rem);
  line-height: .82;
  letter-spacing: .04em;
  font-weight: 800;
  text-transform: uppercase;
}
/* Italic accent in h1: switch to elegant serif �?" stays lowercase */
h1 em, .h1 em {
  font-family: var(--display-accent);
  font-style: italic;
  font-weight: 400;
  color: var(--terra);
  letter-spacing: -.025em;
  font-size: .88em;
  display: inline-block;
  text-transform: none;
}

h2, .h2 {
  font-family: var(--display);
  font-size: clamp(2.625rem, 6.5vw, 5.75rem);
  line-height: .86;
  letter-spacing: .04em;
  font-weight: 800;
  text-transform: uppercase;
}
h2 em, .h2 em {
  font-family: var(--display-accent);
  font-style: italic;
  font-weight: 400;
  color: var(--terra);
  font-size: .88em;
  text-transform: none;
  letter-spacing: -.02em;
}

h3, .h3 {
  font-family: var(--sans);
  font-size: clamp(1.125rem, 2.1vw, 1.5rem);
  font-weight: 700;
  line-height: 1.2;
}

.lead {
  font-size: clamp(1rem, 1.9vw, 1.25rem);
  line-height: 1.7;
  color: var(--muted);
  max-width: 52ch;
  font-weight: 400;
}

.tiny {
  font-family: var(--mono);
  font-size: .7rem;
  letter-spacing: .08em;
  color: var(--muted);
}

/* =============================================================
   7. Buttons
   ============================================================= */
.btn {
  display: inline-flex;
  align-items: center;
  gap: .5rem;
  font-family: var(--sans);
  font-size: .9375rem;
  font-weight: 600;
  letter-spacing: .01em;
  padding: .875rem 1.75rem;
  border-radius: 3px;
  transition: transform .22s var(--ease-out), box-shadow .22s var(--ease-out), background .22s var(--ease-out);
  white-space: nowrap;
}
.btn--primary {
  background: var(--terra);
  color: var(--paper);
}
.btn--primary:hover {
  background: #9e3d22;
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(184, 72, 42, .32);
}
.btn--ghost {
  background: transparent;
  color: var(--ink);
  box-shadow: inset 0 0 0 1.5px var(--ink);
}
.btn--ghost:hover {
  background: var(--ink);
  color: var(--paper);
  transform: translateY(-2px);
}
.btn--tech {
  background: var(--terra2);
  color: var(--paper);
}
.btn--tech:hover {
  background: #6e270e;
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(192, 76, 42, .3);
}
.btn--full { width: 100%; justify-content: center; }

/* =============================================================
   8. Navigation  �?" always dark on scroll; transparent on hero
   ============================================================= */
.nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  height: var(--nav-h);
  display: flex;
  align-items: center;
  transition: background .35s var(--ease-out), box-shadow .35s var(--ease-out);
}

/* Transparent state (only on home hero �?" dark background beneath) */
.nav[data-dark-hero]:not(.is-solid) .nav__links a {
  color: rgba(245, 240, 230, .75);
}
.nav[data-dark-hero]:not(.is-solid) .nav__links a:hover,
.nav[data-dark-hero]:not(.is-solid) .nav__links a.is-active {
  color: var(--paper);
}
.nav[data-dark-hero]:not(.is-solid) .nav__brand .wm-a { color: var(--paper); }
.nav[data-dark-hero]:not(.is-solid) .nav__brand .wm-b { color: rgba(245,240,230,.55); }
.nav[data-dark-hero]:not(.is-solid) .nav__toggle span { background: var(--paper); }

/* Solid state �?" always dark ink */
.nav.is-solid {
  background: rgba(26, 30, 36, .93);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
  box-shadow: 0 1px 0 rgba(245, 240, 230, .07);
}
.nav.is-solid .nav__links a { color: rgba(245, 240, 230, .65); }
.nav.is-solid .nav__links a:hover,
.nav.is-solid .nav__links a.is-active { color: var(--paper); }
.nav.is-solid .nav__brand .wm-a { color: var(--paper); }
.nav.is-solid .nav__brand .wm-b { color: rgba(245, 240, 230, .5); }
.nav.is-solid .nav__toggle span { background: rgba(245, 240, 230, .85); }
.nav.is-solid .nav__links a::after { background: var(--terra); }

.nav__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 2rem;
  width: 100%;
  max-width: var(--max-w);
  margin-inline: auto;
  padding-inline: var(--gutter);
}
.nav__brand {
  display: flex;
  align-items: baseline;
  gap: .5rem;
  text-decoration: none;
  flex-shrink: 0;
}
/* Bigger logo */
.nav__brand .wm-a { font-size: 1.875rem; color: var(--ink); }
.nav__brand .wm-b { font-size: .5rem; letter-spacing: .38em; }

.nav__links {
  display: flex;
  align-items: center;
  gap: 1.75rem;
}
.nav__links a {
  font-size: .875rem;
  font-weight: 500;
  color: var(--muted);
  position: relative;
  transition: color .2s;
}
.nav__links a::after {
  content: '';
  position: absolute;
  bottom: -3px; left: 0;
  width: 0; height: 1.5px;
  background: var(--terra);
  transition: width .3s var(--ease-out);
}
.nav__links a:hover,
.nav__links a.is-active { color: var(--ink); }
.nav__links a:hover::after,
.nav__links a.is-active::after { width: 100%; }

.nav__cta {
  font-size: .8125rem;
  padding: .6rem 1.15rem;
}

.nav__toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  width: 28px;
  cursor: pointer;
  padding: 4px;
}
.nav__toggle span {
  display: block;
  height: 1.5px;
  background: var(--ink);
  border-radius: 2px;
  transition: transform .3s var(--ease-out), opacity .2s;
}

/* Mobile nav */
@media (max-width: 1023px) {
  .nav__links,
  .nav__cta { display: none; }
  .nav__toggle { display: flex; }
  .nav.is-open .nav__links {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 1.5rem;
    position: fixed;
    top: var(--nav-h); left: 0; right: 0;
    padding: 2rem var(--gutter);
    background: var(--ink2);
    border-top: 1px solid rgba(245, 240, 230, .08);
    box-shadow: 0 12px 40px rgba(0, 0, 0, .35);
  }
  .nav.is-open .nav__links a { font-size: 1.125rem; color: rgba(245,240,230,.8); }
  .nav.is-open .nav__cta {
    display: inline-flex;
    margin-top: .5rem;
  }
  .nav.is-open .nav__toggle span:nth-child(1) { transform: translateY(6.5px) rotate(45deg); }
  .nav.is-open .nav__toggle span:nth-child(2) { opacity: 0; }
  .nav.is-open .nav__toggle span:nth-child(3) { transform: translateY(-6.5px) rotate(-45deg); }
}

/* =============================================================
   9. Page header (shared across inner pages)
   ============================================================= */
.page-header {
  padding-top: calc(var(--nav-h) + 4.5rem);
  padding-bottom: 4.5rem;
  background: linear-gradient(160deg, #1E2530 0%, #252C36 55%, #1C2028 100%);
  border-bottom: 1px solid rgba(245, 240, 230, .06);
  position: relative;
  overflow: hidden;
}
/* Subtle warm accent glow (top-right) */
.page-header::before {
  content: '';
  position: absolute;
  top: -20%;
  right: -5%;
  width: 55%;
  height: 160%;
  background: radial-gradient(ellipse at center, rgba(184, 72, 42, .07) 0%, transparent 65%);
  pointer-events: none;
}
/* Very faint grid texture */
.page-header::after {
  content: '';
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(245,240,230,.025) 1px, transparent 1px),
    linear-gradient(90deg, rgba(245,240,230,.025) 1px, transparent 1px);
  background-size: 48px 48px;
  pointer-events: none;
}
.page-header .container { position: relative; z-index: 1; }
.page-header .eyebrow { margin-bottom: 1rem; color: rgba(245,240,230,.38); }
.page-header h1 { margin-bottom: 1.5rem; color: var(--paper); }
.page-header h1 em { color: var(--terra); }
.page-header .lead { max-width: 55ch; color: rgba(245,240,230,.6); }

/* =============================================================
   10. Hero �?" Home (full-bleed auto-sliding background)
   ============================================================= */
.hero-home {
  min-height: 100svh;
  padding-top: var(--nav-h);
  position: relative;
  display: flex;
  align-items: center;
  overflow: hidden;
  background: #0e1116; /* fallback while images load */
}

/* �"?�"? Slider layer �"?�"? */
.hero-slider {
  position: absolute;
  inset: 0;
  z-index: 0;
}
.hero-slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  transition: opacity 1.4s ease-in-out;
  background-size: cover;
  background-position: center 40%;
  will-change: opacity, transform;
}
.hero-slide.is-active { opacity: 1; }

/* Ken Burns �?" each slide gets a different subtle motion */
@keyframes kb1 { from { transform: scale(1)    translate3d(0,0,0);         } to { transform: scale(1.09) translate3d(-1%,-.5%,0); } }
@keyframes kb2 { from { transform: scale(1.05) translate3d(-1.5%,0,0);     } to { transform: scale(1)    translate3d(1.5%,.5%,0);  } }
@keyframes kb3 { from { transform: scale(1)    translate3d(1%,.5%,0);      } to { transform: scale(1.08) translate3d(-1%,-.5%,0); } }
@keyframes kb4 { from { transform: scale(1.06) translate3d(0,-1%,0);       } to { transform: scale(1)    translate3d(.5%,1%,0);   } }
.hero-slide:nth-child(1).is-active { animation: kb1 8s ease-in-out forwards; }
.hero-slide:nth-child(2).is-active { animation: kb2 8s ease-in-out forwards; }
.hero-slide:nth-child(3).is-active { animation: kb3 8s ease-in-out forwards; }
.hero-slide:nth-child(4).is-active { animation: kb4 8s ease-in-out forwards; }
@media (prefers-reduced-motion: reduce) {
  .hero-slide { animation: none !important; transition: opacity .5s; }
}

/* �"?�"? Gradient overlay for text legibility �"?�"? */
.hero-home::after {
  content: '';
  position: absolute;
  inset: 0;
  background:
    linear-gradient(to right,  rgba(10,13,18,.92) 0%, rgba(10,13,18,.58) 45%, rgba(10,13,18,.15) 100%),
    linear-gradient(to bottom, rgba(10,13,18,.45) 0%, transparent 20%,  transparent 72%, rgba(10,13,18,.65) 100%);
  z-index: 1;
  pointer-events: none;
}

/* �"?�"? Content �"?�"? */
.hero-home > .container {
  position: relative;
  z-index: 2;
  width: 100%;
}
/* �"?�"? Hero content �?" una sola columna, texto impactante �"?�"? */
.hero-home__content {
  display: flex;
  flex-direction: column;
  gap: 2rem;
  padding-block: 8rem 5.5rem;
  max-width: 900px;
}
.hero-home__content .eyebrow { margin-bottom: -.5rem; color: rgba(245,240,230,.4); }
.hero-home__content h1 { margin: 0; color: var(--paper); }
.hero-home__content h1 em { color: var(--terra); }
.hero-home__content .lead { max-width: 54ch; color: rgba(245,240,230,.7); }

.hero-home__ctas { display: flex; gap: 1rem; flex-wrap: wrap; }
.hero-home__ctas .btn--ghost {
  color: var(--paper);
  box-shadow: inset 0 0 0 1.5px rgba(245,240,230,.35);
}
.hero-home__ctas .btn--ghost:hover {
  background: rgba(245,240,230,.1);
  color: var(--paper);
}

/* Chips de datos �?" tira horizontal discreta sobre los botones */
.hero-chips {
  display: flex;
  align-items: center;
  gap: 1.5rem;
  flex-wrap: wrap;
}
.hero-chip {
  display: flex;
  align-items: center;
  gap: .5rem;
  font-family: var(--mono);
  font-size: .68rem;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: rgba(245,240,230,.5);
}
.hero-chip strong {
  font-family: var(--display);
  font-size: 1.2rem;
  font-weight: 700;
  letter-spacing: .02em;
  color: rgba(245,240,230,.85);
  line-height: 1;
}

/* �"?�"? Dot indicators �"?�"? */
.hero-dots {
  position: absolute;
  bottom: 2.25rem;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: .625rem;
  z-index: 10;
}
.hero-dot {
  width: 7px; height: 7px;
  border-radius: 50%;
  background: rgba(245,240,230,.35);
  border: 0;
  cursor: pointer;
  padding: 0;
  transition: background .3s, transform .3s var(--ease-out);
}
.hero-dot.is-active {
  background: var(--terra);
  transform: scale(1.4);
}

/* �"?�"? Progress bar �"?�"? */
.hero-progress {
  position: absolute;
  bottom: 0; left: 0;
  height: 2px;
  background: var(--terra);
  width: 0;
  z-index: 10;
  opacity: .85;
}
.hero-progress.is-running {
  animation: heroProgress 6s linear forwards;
}
@keyframes heroProgress { from { width: 0; } to { width: 100%; } }
@media (prefers-reduced-motion: reduce) {
  .hero-progress { display: none; }
}

@media (max-width: 767px) {
  .hero-home__content {
    padding-block: 5.5rem 4rem;
  }
  .hero-home::after {
    background: linear-gradient(to bottom, rgba(10,13,18,.55) 0%, rgba(10,13,18,.78) 100%);
  }
}

/* =============================================================
   11. Marquee strip
   ============================================================= */
.marquee-strip {
  background: var(--terra);
  color: var(--paper);
  padding-block: 1.1rem;
  overflow: hidden;
  white-space: nowrap;
}
.marquee-strip__track {
  display: inline-flex;
  gap: 3rem;
  animation: marqueeTick 28s linear infinite;
}
.marquee-strip__track span {
  font-family: var(--display);
  font-size: clamp(1.1rem, 2.5vw, 1.5rem);
  font-style: italic;
  flex-shrink: 0;
}
.marquee-strip__track em {
  font-style: normal;
  font-family: var(--mono);
  font-size: .75em;
  letter-spacing: .15em;
  opacity: .7;
}
@keyframes marqueeTick { from { transform: translateX(0); } to { transform: translateX(-50%); } }
@media (prefers-reduced-motion: reduce) { .marquee-strip__track { animation: none; } }

/* =============================================================
   12. Services preview cards
   ============================================================= */
.services-preview { padding-block: 6rem; background: var(--paper); }
.services-preview__head { margin-bottom: 4rem; display: flex; align-items: flex-end; justify-content: space-between; gap: 2rem; flex-wrap: wrap; }
.services-preview__head .eyebrow { margin-bottom: .75rem; }

.services-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5px;
  background: var(--line);
  border: 1px solid var(--line);
  border-radius: 4px;
  overflow: hidden;
}
.service-card {
  background: var(--cream);
  padding: 2.5rem;
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
  transition: background .3s var(--ease-out);
  cursor: default;
}
.service-card:hover { background: var(--sand); }
.service-card__num {
  font-family: var(--mono);
  font-size: .75rem;
  letter-spacing: .18em;
  color: var(--terra);
}
.service-card__title {
  font-family: var(--display);
  font-size: clamp(1.5rem, 2.5vw, 1.875rem);
  font-weight: 800;
  line-height: 1.05;
  letter-spacing: .025em;
  text-transform: uppercase;
}
.service-card__desc { font-size: .9375rem; color: var(--muted); line-height: 1.6; flex: 1; }
.service-card__link {
  display: inline-flex;
  align-items: center;
  gap: .4rem;
  font-size: .875rem;
  font-weight: 600;
  color: var(--terra);
  transition: gap .2s var(--ease-out);
}
.service-card:hover .service-card__link { gap: .7rem; }

@media (max-width: 959px) {
  .services-grid { grid-template-columns: 1fr; }
}

/* =============================================================
   13. Stats section
   ============================================================= */
.stats-section {
  padding-block: 6rem;
  background: linear-gradient(180deg, #1D2129 0%, #222730 100%);
  color: var(--paper);
  border-top: 1px solid rgba(245,240,230,.06);
  border-bottom: 1px solid rgba(245,240,230,.06);
}
.stats-section .eyebrow { color: rgba(245, 240, 230, .45); margin-bottom: 3rem; }
.stats-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0;
  border: 1px solid rgba(245, 240, 230, .1);
  border-radius: 4px;
  overflow: hidden;
}
.stat-item {
  padding: 2.5rem 2rem;
  border-right: 1px solid rgba(245, 240, 230, .1);
  display: flex;
  flex-direction: column;
  gap: .5rem;
}
.stat-item:last-child { border-right: 0; }
.stat-item__value {
  font-family: var(--display);
  font-size: clamp(2.5rem, 5vw, 4rem);
  line-height: 1;
  color: var(--sand);
}
.stat-item__value em {
  font-style: normal;
  font-size: .6em;
  color: var(--terra);
}
.stat-item__label {
  font-size: .875rem;
  color: rgba(245, 240, 230, .55);
  line-height: 1.4;
}

@media (max-width: 719px) {
  .stats-grid { grid-template-columns: repeat(2, 1fr); }
  .stat-item:nth-child(2) { border-right: 0; }
  .stat-item:nth-child(1),
  .stat-item:nth-child(2) { border-bottom: 1px solid rgba(245, 240, 230, .1); }
}

/* =============================================================
   14. About teaser
   ============================================================= */
.about-teaser {
  padding-block: 7rem;
  background: var(--sand);
}
.about-teaser__inner {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(3rem, 6vw, 6rem);
  align-items: center;
}
.about-teaser__label {
  font-family: var(--mono);
  font-size: .7rem;
  letter-spacing: .2em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 1.5rem;
}
.about-teaser h2 { margin-bottom: 1.75rem; }
.about-teaser .lead { margin-bottom: 2.25rem; }
.about-teaser__media img {
  width: 100%;
  height: clamp(300px, 45vh, 520px);
  object-fit: cover;
  border-radius: 4px;
}
.about-teaser__flags {
  display: flex;
  gap: 1.25rem;
  margin-bottom: 2rem;
  flex-wrap: wrap;
}
.flag-chip {
  display: flex;
  align-items: center;
  gap: .5rem;
  padding: .5rem 1rem;
  background: rgba(27, 30, 34, .08);
  border-radius: 100px;
  font-size: .8rem;
  font-weight: 600;
  color: var(--ink);
}

@media (max-width: 719px) {
  .about-teaser__inner { grid-template-columns: 1fr; }
}

/* =============================================================
   15. CTA band �?" terracota oscuro cálido (sin azul)
   ============================================================= */
.cta-band {
  padding-block: 6rem;
  background: linear-gradient(160deg, #1A1209 0%, #231710 55%, #1A1209 100%);
  color: var(--paper);
  text-align: center;
  border-top: 3px solid var(--terra);
}
.cta-band h2 { color: var(--paper); margin-bottom: 1.25rem; }
.cta-band h2 em { color: var(--terra); }
.cta-band .lead { color: rgba(245, 240, 230, .65); margin: 0 auto 2.5rem; }
.cta-band__actions { display: flex; gap: 1rem; justify-content: center; flex-wrap: wrap; }

/* =============================================================
   16. Footer
   ============================================================= */
.footer {
  background: linear-gradient(180deg, #1C2028 0%, #191D23 100%);
  color: var(--paper);
  padding-block: 5rem 3rem;
}
.footer__inner {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr;
  gap: 4rem;
  padding-bottom: 3rem;
  border-bottom: 1px solid rgba(245, 240, 230, .08);
  margin-bottom: 2rem;
}
.footer__brand .wordmark { margin-bottom: 1.25rem; }
.footer__brand .wm-a { font-size: 2rem; color: var(--paper); }
.footer__brand .wm-b { color: rgba(245, 240, 230, .45); }
.footer__brand p { color: rgba(245, 240, 230, .45); font-size: .9375rem; font-style: italic; font-family: var(--display); }

.footer__nav h4 {
  font-size: .7rem;
  letter-spacing: .18em;
  text-transform: uppercase;
  font-family: var(--mono);
  color: rgba(245, 240, 230, .35);
  margin-bottom: 1.25rem;
}
.footer__nav ul { display: flex; flex-direction: column; gap: .875rem; }
.footer__nav a {
  color: rgba(245, 240, 230, .65);
  font-size: .9375rem;
  transition: color .2s;
}
.footer__nav a:hover { color: var(--paper); }

.footer__contact h4 {
  font-size: .7rem;
  letter-spacing: .18em;
  text-transform: uppercase;
  font-family: var(--mono);
  color: rgba(245, 240, 230, .35);
  margin-bottom: 1.25rem;
}
.footer__contact p {
  color: rgba(245, 240, 230, .65);
  font-size: .875rem;
  line-height: 1.85;
}
.footer__contact a { color: rgba(245, 240, 230, .65); transition: color .2s; }
.footer__contact a:hover { color: var(--sand); }

.footer__legal {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  flex-wrap: wrap;
}
.footer__legal p {
  font-size: .75rem;
  color: rgba(245, 240, 230, .28);
  font-family: var(--mono);
}

@media (max-width: 959px) {
  .footer__inner { grid-template-columns: 1fr 1fr; }
  .footer__brand { grid-column: 1 / -1; }
}
@media (max-width: 539px) {
  .footer__inner { grid-template-columns: 1fr; gap: 2.5rem; }
}

/* =============================================================
   17. Services page �?" full sections
   ============================================================= */
.service-section {
  padding-block: 7rem;
  border-bottom: 1px solid var(--line);
}
.service-section:nth-child(even) { background: var(--cream); }
.service-section__inner {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(3rem, 6vw, 6rem);
  align-items: center;
}
.service-section:nth-child(even) .service-section__inner { direction: rtl; }
.service-section:nth-child(even) .service-section__inner > * { direction: ltr; }

.service-section__num {
  font-family: var(--mono);
  font-size: .7rem;
  letter-spacing: .2em;
  color: var(--terra);
  margin-bottom: 1rem;
}
.service-section h2 { margin-bottom: 1.5rem; }
.service-section .lead { margin-bottom: 2rem; }

.service-section__list {
  display: flex;
  flex-direction: column;
  gap: .75rem;
  margin-bottom: 2.5rem;
}
.service-section__list li {
  display: flex;
  align-items: center;
  gap: .75rem;
  font-size: .9375rem;
  color: var(--muted);
}
.service-section__list li::before {
  content: '';
  display: block;
  width: 6px; height: 6px;
  border-radius: 50%;
  background: var(--terra);
  flex-shrink: 0;
}

.service-section__media img {
  width: 100%;
  height: clamp(300px, 45vh, 520px);
  object-fit: cover;
  border-radius: 4px;
}

@media (max-width: 719px) {
  .service-section__inner { grid-template-columns: 1fr; direction: ltr !important; }
  .service-section:nth-child(even) .service-section__inner > * { direction: ltr; }
}

/* =============================================================
   18. Team / Equipo page
   ============================================================= */
.team-intro {
  padding-block: 6rem;
  background: var(--paper);
}
.team-intro__inner {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(3rem, 6vw, 6rem);
  align-items: center;
}
@media (max-width: 719px) { .team-intro__inner { grid-template-columns: 1fr; } }

.team-intro__media img {
  width: 100%;
  height: clamp(300px, 42vh, 500px);
  object-fit: cover;
  border-radius: 4px;
}

.experience-section {
  padding-block: 6rem;
  background: var(--sand);
}
.experience-section h2 { margin-bottom: 1.75rem; }
.experience-section .lead { margin-bottom: 3rem; max-width: 60ch; }

.country-blocks {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.5px;
  background: rgba(27, 30, 34, .12);
  border: 1px solid rgba(27, 30, 34, .12);
  border-radius: 4px;
  overflow: hidden;
}
.country-block {
  background: var(--paper);
  padding: 2.5rem;
}
.country-block__flag {
  font-size: 2rem;
  margin-bottom: 1rem;
}
.country-block h3 { margin-bottom: 1rem; color: var(--ink); }
.country-block p { font-size: .9375rem; color: var(--muted); line-height: 1.65; }
.country-block ul { margin-top: 1rem; display: flex; flex-direction: column; gap: .5rem; }
.country-block li {
  font-size: .875rem;
  color: var(--muted);
  display: flex;
  align-items: flex-start;
  gap: .5rem;
}
.country-block li::before {
  content: '�?"';
  color: var(--terra);
  flex-shrink: 0;
}

@media (max-width: 719px) { .country-blocks { grid-template-columns: 1fr; } }

.values-section {
  padding-block: 6rem;
  background: linear-gradient(160deg, #1E2229 0%, #252B34 100%);
  color: var(--paper);
}
.values-section h2 { color: var(--paper); margin-bottom: 3rem; }
.values-section h2 em { color: var(--sand); }
.values-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5px;
  background: rgba(245, 240, 230, .08);
  border: 1px solid rgba(245, 240, 230, .08);
  border-radius: 4px;
  overflow: hidden;
}
.value-item {
  background: rgba(30, 34, 41, 0.85);
  padding: 2.5rem;
}
.value-item__num {
  font-family: var(--mono);
  font-size: .7rem;
  color: var(--terra);
  letter-spacing: .18em;
  margin-bottom: 1rem;
}
.value-item h3 { color: var(--sand); margin-bottom: .875rem; font-size: 1.25rem; }
.value-item p { font-size: .9375rem; color: rgba(245, 240, 230, .55); line-height: 1.65; }

@media (max-width: 719px) { .values-grid { grid-template-columns: 1fr; } }

/* =============================================================
   19. Gallery page
   ============================================================= */
.gallery-section { padding-block: 6rem; }
.gallery-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5px;
  background: var(--line);
  border: 1px solid var(--line);
  border-radius: 4px;
  overflow: hidden;
  margin-top: 3rem;
}
.gallery-item {
  position: relative;
  overflow: hidden;
  cursor: pointer;
}
.gallery-item img {
  width: 100%;
  height: 280px;
  object-fit: cover;
  transition: transform .5s var(--ease-out);
}
.gallery-item:hover img { transform: scale(1.06); }
.gallery-item__caption {
  position: absolute;
  bottom: 0; left: 0; right: 0;
  padding: 1.5rem 1.25rem .875rem;
  background: linear-gradient(to top, rgba(20, 22, 24, .9), transparent);
  color: var(--paper);
  font-size: .75rem;
  font-family: var(--mono);
  letter-spacing: .08em;
  transform: translateY(4px);
  opacity: 0;
  transition: opacity .3s var(--ease-out), transform .3s var(--ease-out);
}
.gallery-item:hover .gallery-item__caption { opacity: 1; transform: translateY(0); }

.gallery-item:nth-child(1) { grid-column: span 2; }
.gallery-item:nth-child(1) img { height: 380px; }

@media (max-width: 719px) {
  .gallery-grid { grid-template-columns: 1fr; }
  .gallery-item:nth-child(1) { grid-column: span 1; }
  .gallery-item:nth-child(1) img { height: 260px; }
  .gallery-item img { height: 220px; }
  .gallery-item__caption { opacity: 1; transform: none; }
}

/* =============================================================
   20. Contact page
   ============================================================= */
.contact-section { padding-block: 6rem; }
.contact-section__inner {
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  gap: clamp(3rem, 6vw, 6rem);
  align-items: start;
}

.contact-form { display: flex; flex-direction: column; gap: 1.25rem; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 1.25rem; }
.form-group { display: flex; flex-direction: column; gap: .5rem; }
.form-group label {
  font-size: .8125rem;
  font-weight: 600;
  color: var(--ink);
  letter-spacing: .02em;
}
.form-group input,
.form-group textarea,
.form-group select {
  font-family: var(--sans);
  font-size: .9375rem;
  color: var(--ink);
  background: var(--cream);
  border: 1.5px solid var(--line);
  border-radius: 3px;
  padding: .875rem 1rem;
  transition: border-color .2s, box-shadow .2s;
  width: 100%;
  appearance: none;
}
.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
  outline: none;
  border-color: var(--terra);
  box-shadow: 0 0 0 3px rgba(184, 72, 42, .12);
}
.form-group textarea { resize: vertical; min-height: 140px; }

.form-status {
  padding: 1rem 1.25rem;
  border-radius: 3px;
  font-size: .9375rem;
  display: none;
}
.form-status.is-success {
  display: block;
  background: rgba(30, 25, 10, .06);
  border: 1.5px solid var(--terra2);
  color: var(--terra2);
}
.form-status.is-error {
  display: block;
  background: rgba(184, 72, 42, .08);
  border: 1.5px solid var(--terra);
  color: var(--terra);
}

.contact-info { display: flex; flex-direction: column; gap: 2.5rem; }
.contact-info__item h3 {
  font-size: .7rem;
  letter-spacing: .2em;
  text-transform: uppercase;
  font-family: var(--mono);
  color: var(--muted);
  margin-bottom: .75rem;
}
.contact-info__item p, .contact-info__item a {
  font-size: 1rem;
  color: var(--ink);
  line-height: 1.7;
  display: block;
}
.contact-info__item a:hover { color: var(--terra); }

.contact-card {
  background: var(--ink2);
  color: var(--paper);
  padding: 2.5rem;
  border-radius: 4px;
}
.contact-card .wordmark { margin-bottom: 1.5rem; }
.contact-card .wm-a { font-size: 1.75rem; color: var(--paper); }
.contact-card .wm-b { color: rgba(245, 240, 230, .45); }
.contact-card__tagline {
  font-family: var(--display);
  font-style: italic;
  font-size: 1.125rem;
  color: var(--sand);
  margin-bottom: 1.75rem;
}
.contact-card__detail {
  font-size: .8125rem;
  color: rgba(245, 240, 230, .45);
  font-family: var(--mono);
  letter-spacing: .06em;
  border-top: 1px solid rgba(245, 240, 230, .08);
  padding-top: 1.25rem;
  line-height: 1.85;
}

@media (max-width: 959px) {
  .contact-section__inner { grid-template-columns: 1fr; }
  .form-row { grid-template-columns: 1fr; }
}

/* =============================================================
   21. Proyectos page
   ============================================================= */
.proyectos-section {
  padding-block: 6rem;
  border-bottom: 1px solid var(--line);
}
.proyectos-section--privados {
  background: var(--cream);
}
.proyectos-section__header {
  margin-bottom: 3.5rem;
}
.proyectos-section__header .eyebrow { margin-bottom: 1rem; }
.proyectos-section__header h2 { margin-bottom: 1.25rem; }
.proyectos-section__header .lead { max-width: 58ch; }

.proyectos-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 1.5px;
  background: var(--line);
  border: 1px solid var(--line);
  border-radius: 4px;
  overflow: hidden;
}

.proyecto-card {
  background: var(--paper);
  padding: 2.5rem;
  display: flex;
  flex-direction: column;
  gap: .875rem;
  position: relative;
}
.proyectos-section--privados .proyecto-card { background: var(--cream); }
.proyectos-section--privados .proyecto-card:hover { background: var(--sand); }
.proyecto-card { transition: background .3s var(--ease-out); }
.proyecto-card:hover { background: var(--sand); }

.proyecto-card__status {
  display: inline-flex;
  align-items: center;
  gap: .45rem;
  font-family: var(--mono);
  font-size: .6rem;
  letter-spacing: .18em;
  text-transform: uppercase;
  padding: .3rem .75rem;
  border-radius: 100px;
  font-weight: 600;
  align-self: flex-start;
}
.proyecto-card__status--done {
  background: rgba(30, 20, 8, .07);
  color: var(--terra2);
  border: 1px solid rgba(140, 51, 24, .25);
}
.proyecto-card__status--pending {
  background: rgba(184, 72, 42, .1);
  color: var(--terra);
  border: 1px solid rgba(184, 72, 42, .25);
}
.proyecto-card__status--done::before { content: '\2713\00a0'; }
.proyecto-card__status--pending::before { content: '\25CB\00a0'; }

.proyecto-card__num {
  font-family: var(--mono);
  font-size: .65rem;
  color: var(--terra);
  letter-spacing: .18em;
}
.proyecto-card h3 {
  font-size: 1.0625rem;
  font-weight: 700;
  line-height: 1.35;
  color: var(--ink);
}
.proyecto-card__meta {
  font-family: var(--mono);
  font-size: .68rem;
  color: var(--muted);
  letter-spacing: .08em;
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
}
.proyecto-card p {
  font-size: .9rem;
  color: var(--muted);
  line-height: 1.65;
  flex: 1;
  border-top: 1px solid var(--line);
  padding-top: .875rem;
  margin-top: .25rem;
}

/* Dark band for public projects header */
.proyectos-section--publicos {
  background: var(--paper);
}

@media (max-width: 719px) {
  .proyectos-grid { grid-template-columns: 1fr; }
}

/* =============================================================
   22. Reveal animations
   ============================================================= */
.reveal {
  opacity: 0;
  transform: translateY(32px);
  transition: opacity .65s var(--ease-out), transform .65s var(--ease-out);
}
.reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
}
/* Mandatory defensive rule: prevent invisible text on split elements */
.reveal[data-split] { opacity: 1; transform: none; }

.reveal--left {
  opacity: 0;
  transform: translateX(-32px);
  transition: opacity .65s var(--ease-out), transform .65s var(--ease-out);
}
.reveal--left.is-visible { opacity: 1; transform: translateX(0); }

.reveal--right {
  opacity: 0;
  transform: translateX(32px);
  transition: opacity .65s var(--ease-out), transform .65s var(--ease-out);
}
.reveal--right.is-visible { opacity: 1; transform: translateX(0); }

.reveal-delay-1 { transition-delay: .1s; }
.reveal-delay-2 { transition-delay: .2s; }
.reveal-delay-3 { transition-delay: .3s; }
.reveal-delay-4 { transition-delay: .4s; }

/* =============================================================
   23. Tilt effect
   ============================================================= */
.tilt {
  transform-style: preserve-3d;
  transition: transform .15s var(--ease-out);
  will-change: transform;
}

/* =============================================================
   24. Grain overlay
   ============================================================= */
.grain {
  position: fixed; inset: 0;
  pointer-events: none;
  z-index: 999;
  opacity: .025;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noise'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noise)'/%3E%3C/svg%3E");
  background-size: 200px 200px;
}

/* =============================================================
   25. Reduced motion
   ============================================================= */
@media (prefers-reduced-motion: reduce) {
  .reveal, .reveal--left, .reveal--right {
    opacity: 1;
    transform: none;
    transition: none;
  }
  .marquee-strip__track { animation-duration: 80s; }
}

