/* ═══════════════════════════════════════════
   ALPES360 — Premium Product Studio
   ═══════════════════════════════════════════ */

:root,
html[data-theme="dark"] {
  --bg: #0a0a0b;
  --bg-elevated: #111113;
  --bg-soft: #161618;
  --fg: #f5f5f7;
  --fg-muted: rgba(245, 245, 247, 0.58);
  --fg-dim: rgba(245, 245, 247, 0.32);
  --line: rgba(245, 245, 247, 0.1);
  --accent: #c8d6e5;
  --accent-soft: rgba(200, 214, 229, 0.14);
  --nav-bg: rgba(10, 10, 11, 0.72);
  --preloader-bg: #050506;
  --menu-bg: rgba(5, 5, 6, 0.97);
  --card-hover-border: rgba(245, 245, 247, 0.22);
  --btn-ghost-bg: rgba(255, 255, 255, 0.08);
  --btn-ghost-border: rgba(255, 255, 255, 0.14);
  --btn-ghost-hover: rgba(255, 255, 255, 0.14);
  --cta-on-photo: #f5f5f7;
  --cta-on-photo-muted: rgba(245, 245, 247, 0.58);
  --noise-opacity: 0.035;
  --cursor-view-label: "Ver";
  --serif: "Instrument Serif", Georgia, serif; /* default ES */
  --sans: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
  --ease-in-out: cubic-bezier(0.65, 0, 0.35, 1);
  --nav-h: 72px;
  --container: min(92vw, 1280px);
  --radius: 20px;
  color-scheme: dark;
}

html[data-theme="light"] {
  --bg: #f5f5f7;
  --bg-elevated: #ffffff;
  --bg-soft: #ececf0;
  --fg: #1d1d1f;
  --fg-muted: rgba(29, 29, 31, 0.62);
  --fg-dim: rgba(29, 29, 31, 0.38);
  --line: rgba(29, 29, 31, 0.1);
  --accent: #3d5a73;
  --accent-soft: rgba(61, 90, 115, 0.1);
  --nav-bg: rgba(245, 245, 247, 0.78);
  --preloader-bg: #f0f0f2;
  --menu-bg: rgba(245, 245, 247, 0.98);
  --card-hover-border: rgba(29, 29, 31, 0.18);
  --btn-ghost-bg: rgba(29, 29, 31, 0.06);
  --btn-ghost-border: rgba(29, 29, 31, 0.12);
  --btn-ghost-hover: rgba(29, 29, 31, 0.1);
  --cta-on-photo: #f5f5f7;
  --cta-on-photo-muted: rgba(245, 245, 247, 0.65);
  --noise-opacity: 0.028;
  color-scheme: light;
}

html[data-lang="en"] {
  --cursor-view-label: "View";
}

html[data-lang="es"] {
  --cursor-view-label: "Ver";
}

html {
  transition: background-color 0.45s var(--ease-out), color 0.45s var(--ease-out);
}

*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
}

html.lenis,
html.lenis body {
  height: auto;
}

.lenis.lenis-smooth {
  scroll-behavior: auto !important;
}

body {
  font-family: var(--sans);
  font-weight: 400;
  font-size: 16px;
  line-height: 1.5;
  color: var(--fg);
  background: var(--bg);
  overflow-x: hidden;
  cursor: none;
  transition: background-color 0.45s var(--ease-out), color 0.45s var(--ease-out);
}

@media (hover: none), (pointer: coarse) {
  body {
    cursor: auto;
  }
  .cursor {
    display: none !important;
  }
}

img {
  display: block;
  max-width: 100%;
  height: auto;
  user-select: none;
}

a {
  color: inherit;
  text-decoration: none;
}

button {
  font: inherit;
  color: inherit;
  background: none;
  border: none;
  cursor: none;
}

ul,
ol {
  list-style: none;
}

em {
  font-family: var(--serif);
  font-style: italic;
  font-weight: 400;
}

::selection {
  background: var(--accent);
  color: var(--bg);
}

.container {
  width: var(--container);
  margin-inline: auto;
}

/* ── Noise ── */
.noise {
  position: fixed;
  inset: 0;
  z-index: 9990;
  pointer-events: none;
  opacity: var(--noise-opacity);
  mix-blend-mode: overlay;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

/* ── Scroll progress ── */
.scroll-progress {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 2px;
  z-index: 10000;
  background: transparent;
}

.scroll-progress__bar {
  height: 100%;
  width: 0%;
  background: linear-gradient(90deg, #8fa4b8, var(--accent));
  transform-origin: left;
}

/* ── Cursor ── */
.cursor {
  position: fixed;
  top: 0;
  left: 0;
  z-index: 10001;
  pointer-events: none;
  mix-blend-mode: difference;
}

.cursor__dot {
  position: fixed;
  width: 6px;
  height: 6px;
  margin: -3px 0 0 -3px;
  border-radius: 50%;
  background: #fff;
  will-change: transform;
}

.cursor__ring {
  position: fixed;
  width: 40px;
  height: 40px;
  margin: -20px 0 0 -20px;
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, 0.55);
  will-change: transform;
  transition: width 0.35s var(--ease-out), height 0.35s var(--ease-out),
    margin 0.35s var(--ease-out), background 0.35s, border-color 0.35s;
}

.cursor.is-hover .cursor__ring {
  width: 72px;
  height: 72px;
  margin: -36px 0 0 -36px;
  background: rgba(255, 255, 255, 0.08);
  border-color: transparent;
}

.cursor.is-view .cursor__ring {
  width: 88px;
  height: 88px;
  margin: -44px 0 0 -44px;
  background: rgba(255, 255, 255, 0.12);
  border-color: transparent;
}

.cursor.is-view .cursor__ring::after {
  content: var(--cursor-view-label);
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: #fff;
}

/* ── Preloader ── */
.preloader {
  position: fixed;
  inset: 0;
  z-index: 10002;
  background: var(--preloader-bg);
  display: grid;
  place-items: center;
}

.preloader__inner {
  width: min(320px, 70vw);
  text-align: center;
}

.preloader__logo {
  display: grid;
  place-items: center;
}

.preloader__logo-img {
  width: 88px;
  height: 88px;
  object-fit: contain;
  border-radius: 50%;
}

html[data-theme="dark"] .preloader__logo-img {
  filter: invert(1) brightness(1.15);
}

.preloader__mark {
  font-family: var(--sans);
  font-weight: 500;
  font-size: 13px;
  letter-spacing: 0.42em;
  text-transform: uppercase;
  color: var(--fg);
}

.preloader__track {
  margin: 36px 0 20px;
  height: 1px;
  background: rgba(255, 255, 255, 0.08);
  overflow: hidden;
}

.preloader__fill {
  height: 100%;
  width: 0%;
  background: var(--fg);
}

.preloader__meta {
  display: flex;
  justify-content: space-between;
  font-size: 11px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--fg-muted);
}

.preloader__count::after {
  content: "%";
}

/* ── Nav ── */
.nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 900;
  height: var(--nav-h);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 max(4vw, calc((100vw - 1280px) / 2));
  transition: background 0.4s, backdrop-filter 0.4s, border-color 0.4s;
  border-bottom: 1px solid transparent;
}

.nav.is-scrolled {
  background: var(--nav-bg);
  backdrop-filter: blur(18px) saturate(140%);
  -webkit-backdrop-filter: blur(18px) saturate(140%);
  border-bottom-color: var(--line);
}

.nav__end {
  display: flex;
  align-items: center;
  gap: 8px;
  z-index: 2;
}

.nav__controls {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-right: 4px;
}

.lang-switch {
  display: inline-flex;
  align-items: center;
  padding: 3px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: var(--bg-elevated);
}

.lang-switch__btn {
  min-width: 36px;
  height: 30px;
  padding: 0 10px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.06em;
  color: var(--fg-muted);
  transition: background 0.3s, color 0.3s;
}

.lang-switch__btn.is-active {
  background: var(--fg);
  color: var(--bg);
}

.lang-switch__btn:hover:not(.is-active) {
  color: var(--fg);
}

.theme-toggle {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  border: 1px solid var(--line);
  display: grid;
  place-items: center;
  background: var(--bg-elevated);
  transition: background 0.3s, border-color 0.3s, transform 0.35s var(--ease-out);
  position: relative;
}

.theme-toggle:hover {
  border-color: var(--card-hover-border);
}

.theme-toggle svg {
  width: 16px;
  height: 16px;
  position: absolute;
  transition: opacity 0.35s, transform 0.45s var(--ease-out);
}

.theme-toggle__sun {
  opacity: 0;
  transform: rotate(-45deg) scale(0.6);
}

.theme-toggle__moon {
  opacity: 1;
  transform: rotate(0) scale(1);
}

html[data-theme="light"] .theme-toggle__sun {
  opacity: 1;
  transform: rotate(0) scale(1);
}

html[data-theme="light"] .theme-toggle__moon {
  opacity: 0;
  transform: rotate(45deg) scale(0.6);
}

.nav__logo {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 17px;
  font-weight: 500;
  letter-spacing: -0.03em;
  z-index: 2;
  min-width: 0;
  max-width: min(70vw, 280px);
  line-height: 1;
}

.nav__logo-img {
  width: 36px;
  height: 36px;
  object-fit: contain;
  border-radius: 50%;
  flex-shrink: 0;
  display: block;
}

html[data-theme="dark"] .nav__logo-img,
html[data-theme="dark"] .footer__logo-img,
html[data-theme="dark"] .mobile-menu__logo-img {
  filter: invert(1) brightness(1.15);
}

.nav__logo-text {
  display: inline-flex;
  align-items: baseline;
  white-space: nowrap;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  line-height: 1.05;
}

.nav__logo-mark {
  color: var(--fg);
}

.nav__logo-accent {
  color: var(--fg-muted);
  font-weight: 400;
}

.nav__links {
  display: flex;
  align-items: center;
  gap: 2px;
}

.nav__link {
  position: relative;
  padding: 10px 16px;
  font-size: 13px;
  font-weight: 400;
  color: var(--fg-muted);
  transition: color 0.3s;
}

.nav__link span {
  position: relative;
}

.nav__link span::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -4px;
  width: 100%;
  height: 1px;
  background: var(--fg);
  transform: scaleX(0);
  transform-origin: right;
  transition: transform 0.4s var(--ease-out);
}

.nav__link:hover {
  color: var(--fg);
}

.nav__link:hover span::after {
  transform: scaleX(1);
  transform-origin: left;
}

.nav__link--cta {
  margin-left: 8px;
  color: var(--bg);
  background: var(--fg);
  border-radius: 999px;
  padding: 10px 20px;
  font-weight: 500;
}

.nav__link--cta span::after {
  display: none;
}

.nav__link--cta:hover {
  color: var(--bg);
  background: #fff;
}

.nav__burger {
  display: none;
  width: 40px;
  height: 40px;
  position: relative;
  z-index: 2;
  flex-shrink: 0;
  -webkit-tap-highlight-color: transparent;
}

.nav__burger span {
  position: absolute;
  left: 10px;
  right: 10px;
  height: 1px;
  background: var(--fg);
  transition: transform 0.4s var(--ease-out), top 0.4s, opacity 0.3s;
}

.nav__burger span:first-child {
  top: 16px;
}

.nav__burger span:last-child {
  top: 23px;
}

.nav__burger.is-open span:first-child {
  top: 19.5px;
  transform: rotate(45deg);
}

.nav__burger.is-open span:last-child {
  top: 19.5px;
  transform: rotate(-45deg);
}

.mobile-menu {
  position: fixed;
  inset: 0;
  z-index: 850;
  background: var(--menu-bg);
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 6px;
  padding: calc(var(--nav-h) + 16px) 24px 40px;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.45s, visibility 0.45s, background 0.45s;
}

.mobile-menu__brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 28px;
  font-size: 20px;
  font-weight: 500;
  letter-spacing: -0.03em;
  line-height: 1;
}

.mobile-menu__logo-img {
  width: 48px;
  height: 48px;
  object-fit: contain;
  border-radius: 50%;
  display: block;
  flex-shrink: 0;
}

.mobile-menu__controls {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 32px;
}

.mobile-menu.is-open {
  opacity: 1;
  visibility: visible;
}

.mobile-menu__link {
  font-size: clamp(32px, 8vw, 48px);
  font-weight: 300;
  letter-spacing: -0.03em;
  padding: 8px 0;
  color: var(--fg-muted);
  transition: color 0.3s;
}

.mobile-menu__link:hover {
  color: var(--fg);
}

/* ── Buttons ── */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 16px 28px;
  border-radius: 999px;
  font-size: 14px;
  font-weight: 500;
  letter-spacing: -0.01em;
  transition: transform 0.4s var(--ease-out), background 0.3s, color 0.3s,
    border-color 0.3s;
}

.btn--ghost {
  background: var(--btn-ghost-bg);
  border: 1px solid var(--btn-ghost-border);
  color: var(--fg);
  backdrop-filter: blur(12px);
}

.btn--ghost:hover {
  background: var(--btn-ghost-hover);
}

/* Hero/CTA stay photo-based: force light text on imagery */
.hero .btn--ghost {
  background: rgba(255, 255, 255, 0.1);
  border-color: rgba(255, 255, 255, 0.2);
  color: #f5f5f7;
}

.hero .btn--ghost:hover {
  background: rgba(255, 255, 255, 0.18);
}

.btn--light {
  background: var(--fg);
  color: var(--bg);
}

.btn--light:hover {
  background: #fff;
}

.btn--outline-light {
  border: 1px solid rgba(255, 255, 255, 0.28);
  color: var(--fg);
}

.btn--outline-light:hover {
  background: rgba(255, 255, 255, 0.08);
}

/* ── Section label ── */
.section-label {
  display: inline-flex;
  align-items: center;
  gap: 14px;
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--fg-muted);
  margin-bottom: 28px;
}

.section-label__num {
  color: var(--fg-dim);
  font-variant-numeric: tabular-nums;
}

.section-label--light {
  color: rgba(255, 255, 255, 0.55);
}

.section-label--light .section-label__num {
  color: rgba(255, 255, 255, 0.3);
}

/* ── HERO ── */
.hero {
  position: relative;
  min-height: 100svh;
  display: flex;
  align-items: flex-end;
  padding: calc(var(--nav-h) + 40px) 0 80px;
  overflow: hidden;
}

.hero__bg {
  position: absolute;
  inset: 0;
  z-index: 0;
}

.hero__img {
  width: 100%;
  height: 120%;
  object-fit: cover;
  object-position: center 40%;
  will-change: transform;
  filter: saturate(0.85) brightness(0.72);
}

.hero__veil {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(180deg, rgba(10, 10, 11, 0.35) 0%, rgba(10, 10, 11, 0.15) 40%, rgba(10, 10, 11, 0.92) 100%),
    radial-gradient(ellipse 80% 60% at 50% 20%, transparent 0%, rgba(10, 10, 11, 0.5) 100%);
}

.hero__content {
  position: relative;
  z-index: 1;
  width: var(--container);
  margin-inline: auto;
}

.hero__eyebrow {
  font-size: 12px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--fg-muted);
  margin-bottom: 28px;
  overflow: hidden;
}

.hero__eyebrow span {
  display: inline-block;
}

.hero__title {
  font-weight: 400;
  font-size: clamp(48px, 9.5vw, 118px);
  line-height: 0.92;
  letter-spacing: -0.045em;
}

.hero__line {
  display: block;
  overflow: hidden;
  padding-bottom: 0.06em;
}

.hero__word {
  display: inline-block;
  will-change: transform;
}

.hero__line--serif .hero__word {
  font-family: var(--serif);
  font-style: italic;
  font-weight: 400;
  color: #c8d6e5;
}

.hero__bottom {
  margin-top: 48px;
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 28px;
  max-width: 920px;
}

.hero__lead {
  max-width: 380px;
  font-size: 16px;
  line-height: 1.6;
  color: var(--fg-muted);
  font-weight: 300;
}

.hero__scroll {
  position: absolute;
  right: max(4vw, calc((100vw - 1280px) / 2));
  bottom: 40px;
  z-index: 2;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  font-size: 10px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--fg-dim);
}

.hero__scroll-line {
  width: 1px;
  height: 56px;
  background: linear-gradient(to bottom, var(--fg-muted), transparent);
  transform-origin: top;
  animation: scrollPulse 2.2s var(--ease-in-out) infinite;
}

@keyframes scrollPulse {
  0%,
  100% {
    transform: scaleY(0.35);
    opacity: 0.4;
  }
  50% {
    transform: scaleY(1);
    opacity: 1;
  }
}

/* ── Marquee ── */
.marquee {
  border-block: 1px solid var(--line);
  background: var(--bg);
  overflow: hidden;
  padding: 22px 0;
  position: relative;
  z-index: 2;
}

.marquee__track {
  display: flex;
  gap: 28px;
  width: max-content;
  animation: marquee 42s linear infinite;
  font-size: 13px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--fg-dim);
  font-weight: 400;
}

.marquee__track i {
  font-style: normal;
  color: var(--fg-dim);
  opacity: 0.5;
}

.marquee:hover .marquee__track {
  animation-play-state: paused;
}

@keyframes marquee {
  to {
    transform: translateX(-50%);
  }
}

/* ── Estudio ── */
.estudio {
  padding: 160px 0 100px;
  background: var(--bg);
}

.estudio__grid {
  display: grid;
  grid-template-columns: 1fr 1.1fr;
  gap: 80px;
  align-items: start;
}

.estudio__sticky {
  position: sticky;
  top: 120px;
}

.estudio__title {
  font-size: clamp(36px, 4.5vw, 56px);
  font-weight: 400;
  line-height: 1.1;
  letter-spacing: -0.035em;
}

.estudio__title em {
  display: block;
  color: var(--accent);
}

.estudio__text {
  font-size: 18px;
  line-height: 1.7;
  color: var(--fg-muted);
  font-weight: 300;
  margin-bottom: 24px;
  max-width: 52ch;
}

.stats {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1px;
  margin-top: 56px;
  background: var(--line);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
}

.stat {
  background: var(--bg-elevated);
  padding: 32px 28px;
  position: relative;
}

.stat__num {
  font-size: clamp(40px, 5vw, 56px);
  font-weight: 300;
  letter-spacing: -0.04em;
  font-variant-numeric: tabular-nums;
  line-height: 1;
}

.stat__plus {
  font-size: 28px;
  font-weight: 300;
  color: var(--fg-muted);
  margin-left: 2px;
}

.stat__label {
  display: block;
  margin-top: 12px;
  font-size: 13px;
  color: var(--fg-muted);
  letter-spacing: 0.01em;
}

/* ── Manifesto ── */
.manifesto {
  position: relative;
  background: var(--bg);
}

.manifesto__pin {
  height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

.manifesto__inner {
  width: var(--container);
  text-align: center;
}

.manifesto__line {
  font-size: clamp(32px, 6.2vw, 80px);
  font-weight: 300;
  letter-spacing: -0.035em;
  line-height: 1.15;
  color: var(--fg-dim);
  overflow: hidden;
}

.manifesto__line .char {
  display: inline-block;
  will-change: transform, color, opacity;
}

.manifesto__line--accent {
  font-family: var(--serif);
  font-style: italic;
}

/* ── Servicios ── */
.servicios {
  padding-top: 120px;
  background: var(--bg);
  overflow: hidden;
}

.servicios__head {
  margin-bottom: 48px;
}

.servicios__title {
  font-size: clamp(36px, 4.5vw, 56px);
  font-weight: 400;
  letter-spacing: -0.035em;
  line-height: 1.1;
}

.servicios__pin {
  overflow: hidden;
  padding-bottom: 80px;
}

.servicios__track {
  display: flex;
  gap: 28px;
  width: max-content;
  padding-left: max(4vw, calc((100vw - 1280px) / 2));
  padding-right: 8vw;
  will-change: transform;
}

.service-card {
  flex: 0 0 min(72vw, 520px);
  background: var(--bg-elevated);
  border: 1px solid var(--line);
  border-radius: 24px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: border-color 0.4s, transform 0.5s var(--ease-out);
}

.service-card:hover {
  border-color: var(--card-hover-border);
}

.service-card__media {
  aspect-ratio: 16 / 10;
  overflow: hidden;
  background: var(--bg-soft);
}

.service-card__media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 1.2s var(--ease-out);
  filter: saturate(0.9);
}

.service-card:hover .service-card__media img {
  transform: scale(1.06);
}

.service-card__body {
  padding: 32px 32px 36px;
  display: flex;
  flex-direction: column;
  flex: 1;
}

.service-card__idx {
  font-size: 12px;
  letter-spacing: 0.12em;
  color: var(--fg-dim);
  margin-bottom: 16px;
}

.service-card h3 {
  font-size: 26px;
  font-weight: 400;
  letter-spacing: -0.03em;
  margin-bottom: 12px;
}

.service-card p {
  font-size: 15px;
  line-height: 1.6;
  color: var(--fg-muted);
  font-weight: 300;
  margin-bottom: 24px;
}

.service-card ul {
  margin-top: auto;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.service-card li {
  font-size: 12px;
  padding: 7px 12px;
  border-radius: 999px;
  border: 1px solid var(--line);
  color: var(--fg-muted);
}

/* ── Trabajo (índice compacto + preview) ── */
.trabajo {
  padding: 100px 0 80px;
  background: var(--bg);
}

.trabajo__head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 32px;
  margin-bottom: 40px;
}

.trabajo__title {
  font-size: clamp(32px, 4vw, 48px);
  font-weight: 400;
  letter-spacing: -0.035em;
  line-height: 1.1;
  max-width: 14ch;
}

.trabajo__title em {
  color: var(--accent);
}

.trabajo__count {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 2px;
  font-size: 12px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--fg-dim);
  padding-bottom: 6px;
}

.trabajo__count span:first-child {
  font-size: 28px;
  font-weight: 300;
  letter-spacing: -0.04em;
  color: var(--fg-muted);
  font-variant-numeric: tabular-nums;
}

.work-board {
  display: grid;
  grid-template-columns: minmax(0, 0.95fr) minmax(0, 1.15fr);
  gap: 28px;
  align-items: stretch;
  border: 1px solid var(--line);
  border-radius: 24px;
  overflow: hidden;
  background: var(--bg-elevated);
}

.work-board__preview {
  position: relative;
  min-height: 100%;
  background: var(--bg-soft);
  border-right: 1px solid var(--line);
}

.work-board__frame {
  position: absolute;
  inset: 0;
  overflow: hidden;
}

.work-board__img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0;
  transform: scale(1.06);
  transition: opacity 0.55s var(--ease-out), transform 0.9s var(--ease-out);
  filter: saturate(0.92);
}

.work-board__img.is-active {
  opacity: 1;
  transform: scale(1);
}

.work-board__caption {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 2;
  display: flex;
  align-items: baseline;
  gap: 14px;
  padding: 48px 24px 22px;
  background: linear-gradient(to top, rgba(0, 0, 0, 0.72), transparent);
  color: #f5f5f7;
  pointer-events: none;
}

.work-board__caption-idx {
  font-size: 12px;
  letter-spacing: 0.14em;
  color: rgba(245, 245, 247, 0.5);
  font-variant-numeric: tabular-nums;
}

.work-board__caption-name {
  font-size: 16px;
  font-weight: 400;
  letter-spacing: -0.02em;
}

.work-board__list {
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.work-row {
  display: grid;
  grid-template-columns: 48px minmax(0, 1fr) 36px;
  gap: 8px 12px;
  align-items: center;
  padding: 18px 22px;
  border-bottom: 1px solid var(--line);
  transition: background 0.35s var(--ease-out);
  position: relative;
  min-height: 92px;
}

.work-row:last-child {
  border-bottom: none;
}

.work-row:hover,
.work-row.is-active {
  background: var(--accent-soft);
}

.work-row__num {
  font-size: 12px;
  letter-spacing: 0.1em;
  color: var(--fg-dim);
  font-variant-numeric: tabular-nums;
  transition: color 0.3s;
}

.work-row.is-active .work-row__num,
.work-row:hover .work-row__num {
  color: var(--fg);
}

.work-row__body {
  min-width: 0;
}

.work-row__top {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 4px;
}

.work-row__top h3 {
  font-size: 17px;
  font-weight: 500;
  letter-spacing: -0.025em;
  line-height: 1.2;
}

.work-row__year {
  font-size: 12px;
  color: var(--fg-dim);
  font-variant-numeric: tabular-nums;
  flex-shrink: 0;
}

.work-row__body > p {
  font-size: 13px;
  line-height: 1.45;
  color: var(--fg-muted);
  font-weight: 300;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  margin-bottom: 8px;
}

.work-row__tags {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
}

.work-row__tags span {
  font-size: 10px;
  letter-spacing: 0.04em;
  color: var(--fg-dim);
  border: 1px solid var(--line);
  padding: 3px 8px;
  border-radius: 999px;
  white-space: nowrap;
}

.work-row__go {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  border: 1px solid var(--line);
  display: grid;
  place-items: center;
  color: var(--fg-dim);
  transition: transform 0.4s var(--ease-out), background 0.3s, color 0.3s,
    border-color 0.3s;
  justify-self: end;
}

.work-row:hover .work-row__go,
.work-row.is-active .work-row__go {
  transform: translateX(2px);
  color: var(--fg);
  border-color: var(--card-hover-border);
  background: var(--bg);
}

/* Mobile thumbs — hidden on desktop */
.work-row__thumb {
  display: none;
}

/* ── Clientes ── */
.clientes {
  padding: 80px 0;
  border-block: 1px solid var(--line);
}

.clientes__label {
  text-align: center;
  font-size: 11px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--fg-dim);
  margin-bottom: 36px;
}

.clientes__row {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: 20px 48px;
}

.clientes__row span {
  font-size: clamp(18px, 2.2vw, 24px);
  font-weight: 300;
  letter-spacing: -0.02em;
  color: var(--fg-dim);
  transition: color 0.35s;
}

.clientes__row span:hover {
  color: var(--fg);
}

/* ── Equipo ── */
.equipo {
  padding: 140px 0;
}

.equipo__head {
  margin-bottom: 64px;
  max-width: 560px;
}

.equipo__title {
  font-size: clamp(36px, 4.5vw, 56px);
  font-weight: 400;
  letter-spacing: -0.035em;
  line-height: 1.1;
}

.equipo__title em {
  display: block;
  color: var(--accent);
}

.team-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
}

.team-grid--three {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: stretch;
  max-width: 900px;
  margin-inline: auto;
  width: 100%;
  gap: 24px;
}

.team-grid--three .team-card {
  flex: 0 1 260px;
  width: min(260px, 100%);
  max-width: 280px;
}

.team-card {
  border-radius: 18px;
  overflow: hidden;
  background: var(--bg-elevated);
  border: 1px solid var(--line);
  transition: border-color 0.4s, transform 0.5s var(--ease-out);
  transform-style: preserve-3d;
  will-change: transform;
}

.team-card__photo {
  aspect-ratio: 3 / 4;
  overflow: hidden;
  background: var(--bg-soft);
}

.team-card__photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center top;
  filter: grayscale(0.15) contrast(1.05);
  transition: transform 0.9s var(--ease-out), filter 0.5s;
}

.team-card:hover .team-card__photo img {
  transform: scale(1.06);
  filter: grayscale(0) contrast(1.05);
}

.team-card__photo--empty {
  display: grid;
  place-items: center;
  background:
    linear-gradient(145deg, var(--bg-soft) 0%, var(--bg-elevated) 55%, var(--accent-soft) 100%);
  border-bottom: 1px solid var(--line);
}

.team-card__photo--empty::before {
  content: attr(data-initials);
  font-size: clamp(28px, 3.5vw, 40px);
  font-weight: 300;
  letter-spacing: 0.08em;
  color: var(--fg-dim);
}

.team-card__info {
  padding: 18px 16px 20px;
}

.team-card__meta {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.team-card__info h3 {
  font-size: 16px;
  font-weight: 500;
  letter-spacing: -0.02em;
  margin-bottom: 4px;
}

.team-card__info p {
  font-size: 12px;
  color: var(--fg-muted);
  font-weight: 300;
  line-height: 1.35;
}

.team-card__linkedin {
  flex-shrink: 0;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  border: 1px solid var(--line);
  display: grid;
  place-items: center;
  color: var(--fg-muted);
  background: var(--bg);
  transition: color 0.3s, border-color 0.3s, background 0.3s, transform 0.35s var(--ease-out);
}

.team-card__linkedin:hover {
  color: var(--fg);
  border-color: var(--card-hover-border);
  background: var(--bg-elevated);
}

.team-card__linkedin.is-disabled {
  opacity: 0.35;
  pointer-events: none;
}

.team-card__linkedin svg {
  display: block;
}

/* ── Process ── */
.process {
  padding: 100px 0 140px;
  border-top: 1px solid var(--line);
}

.process__grid {
  display: grid;
  grid-template-columns: 0.9fr 1.2fr;
  gap: 80px;
  align-items: start;
}

.process__title {
  font-size: clamp(32px, 4vw, 48px);
  font-weight: 400;
  letter-spacing: -0.035em;
  line-height: 1.15;
}

.process__list {
  display: flex;
  flex-direction: column;
}

.process__item {
  display: grid;
  grid-template-columns: 72px 1fr;
  gap: 20px;
  padding: 32px 0;
  border-bottom: 1px solid var(--line);
  transition: background 0.35s;
}

.process__item:first-child {
  border-top: 1px solid var(--line);
}

.process__num {
  font-size: 13px;
  letter-spacing: 0.1em;
  color: var(--fg-dim);
  padding-top: 6px;
}

.process__item h3 {
  font-size: 22px;
  font-weight: 400;
  letter-spacing: -0.025em;
  margin-bottom: 8px;
}

.process__item p {
  font-size: 15px;
  line-height: 1.6;
  color: var(--fg-muted);
  font-weight: 300;
  max-width: 48ch;
}

/* ── CTA ── */
.cta {
  position: relative;
  min-height: 90svh;
  display: flex;
  align-items: center;
  padding: 120px 0;
  overflow: hidden;
}

.cta__bg {
  position: absolute;
  inset: 0;
}

.cta__bg img {
  width: 100%;
  height: 120%;
  object-fit: cover;
  filter: saturate(0.8) brightness(0.55);
  will-change: transform;
}

.cta__veil {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(180deg, rgba(10, 10, 11, 0.7) 0%, rgba(10, 10, 11, 0.45) 50%, rgba(10, 10, 11, 0.85) 100%);
}

.cta__content {
  position: relative;
  z-index: 1;
  max-width: 820px;
}

.cta__title {
  font-size: clamp(44px, 7vw, 88px);
  font-weight: 400;
  letter-spacing: -0.04em;
  line-height: 1.02;
  margin-bottom: 24px;
}

.cta__title em {
  color: var(--accent);
}

.cta__lead {
  font-size: 17px;
  color: var(--fg-muted);
  font-weight: 300;
  max-width: 42ch;
  margin-bottom: 40px;
}

.cta__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin-bottom: 72px;
}

.cta__offices {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 28px;
  padding-top: 36px;
  border-top: 1px solid rgba(255, 255, 255, 0.12);
}

.cta__offices strong {
  display: block;
  font-size: 14px;
  font-weight: 500;
  margin-bottom: 6px;
}

.cta__offices span {
  font-size: 13px;
  color: var(--fg-muted);
  font-weight: 300;
}

/* ── Footer ── */
.footer {
  padding: 48px 0 40px;
  border-top: 1px solid var(--line);
  background: var(--bg);
}

.footer__inner {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 40px;
  flex-wrap: wrap;
}

.footer__logo {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
  max-width: 100%;
  line-height: 1;
}

.footer__logo-img {
  width: 40px;
  height: 40px;
  object-fit: contain;
  border-radius: 50%;
  flex-shrink: 0;
  display: block;
}

.footer__brand .nav__logo-mark,
.footer__brand .nav__logo-accent {
  font-size: 17px;
}

.footer__brand p {
  margin-top: 12px;
  font-size: 12px;
  color: var(--fg-dim);
  max-width: 28ch;
  line-height: 1.45;
}

.footer__cols {
  display: flex;
  gap: 64px;
}

.footer__cols > div {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.footer__col-title {
  font-size: 11px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--fg-dim);
  margin-bottom: 4px;
}

.footer__cols a {
  font-size: 14px;
  color: var(--fg-muted);
  transition: color 0.3s;
}

.footer__cols a:hover {
  color: var(--fg);
}

.footer__top {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  border: 1px solid var(--line);
  display: grid;
  place-items: center;
  transition: background 0.3s, border-color 0.3s;
}

.footer__top:hover {
  background: var(--bg-elevated);
  border-color: var(--card-hover-border);
}

/* CTA text always light over photo */
.cta,
.cta .section-label--light,
.cta .section-label--light .section-label__num,
.cta__title,
.cta__title em,
.cta__lead,
.cta__offices strong,
.cta__offices span {
  color: var(--cta-on-photo);
}

.cta__lead,
.cta__offices span {
  color: var(--cta-on-photo-muted);
}

.cta__title em {
  color: var(--accent);
}

html[data-theme="light"] .cta__title em {
  color: #c8d6e5;
}

/* Hero text always light over photo */
.hero__eyebrow,
.hero__title,
.hero__lead,
.hero__scroll {
  color: #f5f5f7;
}

.hero__eyebrow,
.hero__lead {
  color: rgba(245, 245, 247, 0.68);
}

html[data-theme="light"] .hero__veil {
  background:
    linear-gradient(180deg, rgba(10, 10, 11, 0.28) 0%, rgba(10, 10, 11, 0.12) 40%, rgba(10, 10, 11, 0.78) 100%),
    radial-gradient(ellipse 80% 60% at 50% 20%, transparent 0%, rgba(10, 10, 11, 0.4) 100%);
}

html[data-theme="light"] .hero {
  background: var(--bg);
}

html[data-theme="light"] .nav__link--cta {
  background: var(--fg);
  color: var(--bg);
}

/* ── Reveal helpers ── */
.reveal-line span,
.reveal-fade {
  opacity: 0;
}

/* ── Responsive ── */
@media (max-width: 1024px) {
  .estudio__grid,
  .process__grid {
    grid-template-columns: 1fr;
    gap: 48px;
  }

  .estudio__sticky {
    position: static;
  }

  .team-grid {
    grid-template-columns: repeat(2, 1fr);
    max-width: none;
  }

  .team-grid--three {
    max-width: 100%;
  }

  .work-board {
    grid-template-columns: 1fr;
  }

  .work-board__preview {
    min-height: 240px;
    border-right: none;
    border-bottom: 1px solid var(--line);
  }

  .cta__offices {
    grid-template-columns: 1fr;
    gap: 20px;
  }
}

@media (max-width: 768px) {
  :root {
    --nav-h: 60px;
    --container: min(92vw, 1280px);
  }

  body {
    cursor: auto;
  }

  .nav {
    padding: 0 16px;
    gap: 12px;
  }

  .nav__links {
    display: none;
  }

  .nav__controls {
    display: none;
  }

  .nav__burger {
    display: block;
    width: 44px;
    height: 44px;
    flex-shrink: 0;
  }

  .nav__end {
    gap: 4px;
    flex-shrink: 0;
  }

  /* Logo + wordmark: compact, balanced, no overflow */
  .nav__logo {
    gap: 8px;
    font-size: 15px;
    max-width: calc(100vw - 88px);
    flex: 1 1 auto;
  }

  .nav__logo-img {
    width: 32px;
    height: 32px;
  }

  .nav__logo-text {
    font-size: 15px;
    letter-spacing: -0.035em;
  }

  .footer__logo {
    gap: 8px;
  }

  .footer__logo-img {
    width: 34px;
    height: 34px;
  }

  .footer__brand .nav__logo-mark,
  .footer__brand .nav__logo-accent {
    font-size: 15px;
  }

  .mobile-menu .nav__controls,
  .mobile-menu__controls {
    display: flex;
  }

  .mobile-menu__link {
    font-size: clamp(28px, 8vw, 40px);
    padding: 10px 0;
  }

  .hero {
    min-height: 100svh;
    padding: calc(var(--nav-h) + 28px) 0 72px;
  }

  .hero__title {
    font-size: clamp(40px, 11vw, 64px);
  }

  .hero__eyebrow {
    font-size: 11px;
    letter-spacing: 0.12em;
    margin-bottom: 20px;
  }

  .hero__bottom {
    flex-direction: column;
    align-items: flex-start;
    margin-top: 32px;
    gap: 20px;
  }

  .hero__lead {
    font-size: 15px;
    max-width: 100%;
  }

  .hero__scroll {
    display: none;
  }

  .btn {
    padding: 14px 22px;
    font-size: 13px;
  }

  .estudio,
  .trabajo,
  .equipo {
    padding-top: 88px;
    padding-bottom: 72px;
  }

  .process {
    padding: 72px 0 96px;
  }

  .estudio__title,
  .servicios__title,
  .trabajo__title,
  .equipo__title,
  .process__title {
    font-size: clamp(30px, 8vw, 40px);
  }

  .estudio__text {
    font-size: 16px;
  }

  .section-label {
    margin-bottom: 18px;
  }

  .manifesto__line {
    font-size: clamp(26px, 7.5vw, 40px);
  }

  .trabajo__head {
    flex-direction: column;
    align-items: flex-start;
    margin-bottom: 28px;
  }

  .trabajo__count {
    flex-direction: row;
    gap: 10px;
    align-items: baseline;
  }

  .work-board {
    border-radius: 16px;
  }

  .work-board__preview {
    display: none;
  }

  .work-row {
    grid-template-columns: 32px 56px minmax(0, 1fr) 28px;
    gap: 8px 10px;
    padding: 14px 12px;
    min-height: 0;
  }

  .work-row__num {
    order: 1;
    font-size: 11px;
  }

  .work-row__thumb {
    display: block;
    order: 2;
    width: 56px;
    height: 56px;
    border-radius: 10px;
    object-fit: cover;
    border: 1px solid var(--line);
  }

  .work-row__body {
    order: 3;
    min-width: 0;
  }

  .work-row__go {
    order: 4;
    width: 28px;
    height: 28px;
  }

  .work-row__top h3 {
    font-size: 15px;
  }

  .work-row__body > p {
    white-space: normal;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    font-size: 12px;
    margin-bottom: 0;
  }

  .work-row__tags {
    display: none;
  }

  .servicios {
    padding-top: 80px;
  }

  .servicios__track {
    gap: 16px;
    padding-left: 16px;
    padding-right: 16px;
  }

  .service-card {
    flex-basis: min(86vw, 360px);
    border-radius: 18px;
  }

  .service-card__body {
    padding: 22px 20px 24px;
  }

  .service-card h3 {
    font-size: 22px;
  }

  .stats {
    grid-template-columns: 1fr 1fr;
  }

  .stat {
    padding: 22px 18px;
  }

  .stat__num {
    font-size: clamp(28px, 8vw, 36px);
  }

  .clientes {
    padding: 56px 0;
  }

  .clientes__row {
    gap: 14px 24px;
  }

  .team-card__info {
    padding: 16px 14px 18px;
  }

  .team-card__linkedin {
    width: 34px;
    height: 34px;
  }

  .cta {
    min-height: auto;
    padding: 88px 0 72px;
  }

  .cta__title {
    font-size: clamp(36px, 10vw, 52px);
  }

  .cta__actions {
    margin-bottom: 48px;
  }

  .cta__offices {
    gap: 18px;
  }

  .footer {
    padding: 36px 0 32px;
  }

  .footer__inner {
    flex-direction: column;
    align-items: flex-start;
    gap: 28px;
  }

  .footer__cols {
    gap: 36px;
    width: 100%;
  }

  .footer__top {
    align-self: flex-end;
  }

  .preloader__logo-img {
    width: 72px;
    height: 72px;
  }

  .preloader__inner {
    width: min(280px, 78vw);
  }
}

@media (max-width: 480px) {
  .nav {
    padding: 0 12px;
  }

  .nav__logo {
    gap: 7px;
    font-size: 14px;
    max-width: calc(100vw - 76px);
  }

  .nav__logo-img {
    width: 30px;
    height: 30px;
  }

  .nav__logo-text {
    font-size: 14px;
    letter-spacing: -0.04em;
  }

  .footer__logo {
    gap: 8px;
  }

  .footer__logo-img {
    width: 32px;
    height: 32px;
  }

  .footer__brand .nav__logo-mark,
  .footer__brand .nav__logo-accent {
    font-size: 14px;
  }

  .mobile-menu {
    padding-left: 20px;
    padding-right: 20px;
  }

  .mobile-menu__brand {
    gap: 10px;
    font-size: 18px;
    margin-bottom: 22px;
  }

  .mobile-menu__logo-img {
    width: 42px;
    height: 42px;
  }

  .hero__title {
    font-size: clamp(36px, 10.5vw, 48px);
  }

  .stats {
    grid-template-columns: 1fr;
  }

  .team-grid {
    grid-template-columns: minmax(0, 300px);
    justify-content: center;
    max-width: 320px;
  }

  .team-grid--three .team-card {
    flex: 1 1 100%;
    width: 100%;
    max-width: 320px;
  }

  .work-row {
    grid-template-columns: 28px 52px minmax(0, 1fr) 24px;
    padding: 12px 10px;
  }

  .work-row__thumb {
    width: 52px;
    height: 52px;
  }

  .cta__actions {
    flex-direction: column;
    align-items: stretch;
  }

  .btn {
    justify-content: center;
    width: 100%;
  }

  .btn--ghost {
    width: auto;
  }
}

/* Extra-small phones */
@media (max-width: 360px) {
  .nav__logo {
    gap: 6px;
  }

  .nav__logo-img {
    width: 28px;
    height: 28px;
  }

  .nav__logo-text {
    font-size: 13px;
  }

  .footer__logo-img {
    width: 28px;
    height: 28px;
  }

  .footer__brand .nav__logo-mark,
  .footer__brand .nav__logo-accent {
    font-size: 13px;
  }
}

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }

  .marquee__track {
    animation: none;
  }

  html {
    scroll-behavior: auto;
  }
}
