/* =========================================================
   HONCE · Arquitectura + Construcción
   Hoja de estilos principal
   ---------------------------------------------------------
   Paleta: crema + verde olivo (por defecto)
   Versión blanco y negro: agrega ?tema=bn a la URL
   ========================================================= */

/* ---------- Fuentes (alojadas localmente) ---------- */
@font-face {
  font-family: "Cormorant Garamond";
  src: url("../assets/fonts/cormorant.woff2") format("woff2");
  font-weight: 300 600; font-style: normal; font-display: swap;
}
@font-face {
  font-family: "Cormorant Garamond";
  src: url("../assets/fonts/cormorant-italic.woff2") format("woff2");
  font-weight: 300 600; font-style: italic; font-display: swap;
}
@font-face {
  font-family: "Montserrat";
  src: url("../assets/fonts/montserrat.woff2") format("woff2");
  font-weight: 300 700; font-style: normal; font-display: swap;
}
@font-face {
  font-family: "Inter";
  src: url("../assets/fonts/inter-bold.woff2") format("woff2");
  font-weight: 700 900; font-style: normal; font-display: swap;
}

/* ---------- Variables de diseño ---------- */
:root {
  --bg: #F3EFE8;          /* crema */
  --bg-2: #E9E3D8;        /* arena */
  --paper: #F8F5F0;
  --ink: #181818;         /* carbón del logo */
  --ink-2: #4B4840;
  --muted: #6B665C;
  --line: #D8CFC1;
  --line-strong: #BDB3A3;
  --accent: #5F5E44;      /* verde olivo */
  --accent-hover: #4C4B35;
  --accent-ink: #F3EFE8;
  --accent-soft: #C9C6A6; /* olivo claro (sobre fondos oscuros) */
  --dark: #1B1B16;

  --serif: "Cormorant Garamond", "Times New Roman", Georgia, serif;
  --sans: "Montserrat", system-ui, -apple-system, "Segoe UI", sans-serif;
  --display: "Inter", "Helvetica Neue", Arial, sans-serif;

  --ease: cubic-bezier(.22, 1, .36, 1);
  --pad: clamp(20px, 4.6vw, 64px);
  --maxw: 1400px;
  --header-h: 84px;
}

/* Versión blanco y negro (para comparar): ?tema=bn */
[data-tema="bn"] {
  --bg: #FFFFFF;
  --bg-2: #F1F1F1;
  --paper: #FAFAFA;
  --ink: #111111;
  --ink-2: #474747;
  --muted: #6B6B6B;
  --line: #DEDEDE;
  --line-strong: #BDBDBD;
  --accent: #141414;
  --accent-hover: #3A3A3A;
  --accent-ink: #FFFFFF;
  --accent-soft: #D6D6D6;
  --dark: #0E0E0E;
}

/* ---------- Base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
html.lenis, html.lenis body { height: auto; }
html.lenis { scroll-behavior: auto; }
.lenis.lenis-stopped { overflow: hidden; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 15px;
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  overflow-x: clip;
}
img, svg { display: block; max-width: 100%; }
img { height: auto; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: 0; padding: 0; cursor: pointer; }
h1, h2, h3, p, ul, ol, figure { margin: 0; }
ul, ol { padding: 0; list-style: none; }
::selection { background: var(--accent); color: var(--accent-ink); }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }

.skip {
  position: fixed; left: 16px; top: -60px; z-index: 1000;
  background: var(--ink); color: var(--bg); padding: 10px 16px; font-size: 13px;
}
.skip:focus { top: 16px; }

.container { width: 100%; max-width: var(--maxw); margin-inline: auto; padding-inline: var(--pad); }
.section { position: relative; padding-block: clamp(84px, 9.5vw, 140px); }

/* ---------- Tipografía ---------- */
.eyebrow {
  display: flex; align-items: center; gap: 16px;
  font-size: 11px; font-weight: 500; letter-spacing: .26em; text-transform: uppercase;
  color: var(--ink-2); margin-bottom: 26px;
}
.eyebrow::before { content: ""; width: 40px; height: 1px; background: currentColor; flex: none; }
.eyebrow--light { color: rgba(255, 255, 255, .78); }

.h2 {
  font-family: var(--serif); font-weight: 400;
  font-size: clamp(40px, 4.8vw, 72px); line-height: 1.02; letter-spacing: -.012em;
}
.h2 em, .hero__title em { font-style: italic; color: var(--accent); }
.lead { font-size: 15.5px; color: var(--ink-2); max-width: 54ch; }

/* Palabras divididas para animar */
.split-w { display: inline-block; overflow: hidden; vertical-align: top; padding: .14em .06em .1em 0; margin: -.14em -.06em -.1em 0; }
.split-w > span { display: inline-block; will-change: transform; }

/* ---------- Botones ---------- */
.btn {
  --h: 54px;
  display: inline-flex; align-items: center; justify-content: center; gap: 16px;
  height: var(--h); padding: 0 30px;
  font-size: 11px; font-weight: 600; letter-spacing: .22em; text-transform: uppercase;
  transition: background .45s var(--ease), color .45s var(--ease), border-color .45s var(--ease);
  white-space: nowrap;
}
.btn--sm { --h: 44px; padding: 0 22px; }
.btn--primary { background: var(--accent); color: var(--accent-ink); }
.btn--primary:hover { background: var(--ink); }
.btn--outline { border: 1px solid var(--ink); color: var(--ink); }
.btn--outline:hover { background: var(--ink); color: var(--bg); }
.btn--link { padding: 0 4px; position: relative; color: var(--ink); }
.btn--link::after {
  content: ""; position: absolute; left: 4px; right: 4px; bottom: 14px; height: 1px;
  background: currentColor; transform-origin: right; transition: transform .5s var(--ease);
}
.btn--link:hover::after { transform: scaleX(0); }

.arrow { width: 28px; height: 10px; fill: none; stroke: currentColor; stroke-width: 1.2; flex: none; transition: transform .5s var(--ease); }
a:hover .arrow, button:hover .arrow { transform: translateX(5px); }

/* =========================================================
   PRELOADER
   ========================================================= */
.preloader { display: none; }
.js .preloader {
  position: fixed; inset: 0; z-index: 500;
  display: grid; place-items: center;
  background: var(--bg);
}
.reduced .preloader { display: none; }
/* Respaldo: si el JavaScript falla, la pantalla de carga se quita sola a los 6 s */
.js .preloader { animation: preloaderRespaldo .5s ease 6s forwards; }
@keyframes preloaderRespaldo { to { opacity: 0; visibility: hidden; } }
.preloader__inner { display: grid; justify-items: center; gap: 22px; }
/* Espacio que ocupa la firma (el cubo vive en .signature para poder volar sobre la portada) */
.preloader__logo { width: clamp(140px, 38vw, 200px); aspect-ratio: 860 / 664; }
.preloader__word { display: flex; gap: .12em; font-family: var(--sans); font-weight: 700; font-size: clamp(22px, 6vw, 30px); letter-spacing: .14em; overflow: hidden; }
.preloader__word span { display: inline-block; }
.preloader__bar { width: 160px; height: 1px; background: var(--line); overflow: hidden; }
.preloader__bar span { display: block; height: 100%; background: var(--accent); transform: scaleX(0); transform-origin: left; }

/* =========================================================
   CUBO DE HONCE (firma)
   ========================================================= */
.cubo { display: block; width: 100%; height: auto; overflow: visible; }
.cubo__p { fill: currentColor; stroke: currentColor; stroke-width: 4; stroke-linejoin: miter; }

/* La firma solo existe con JS y con movimiento; si algo falla, se quita sola a los 6 s */
.signature { display: none; }
.js:not(.reduced) .signature {
  display: block; position: fixed; left: 50%; top: 40%; z-index: 501; width: 160px;
  color: var(--ink); pointer-events: none; transform-origin: 0 0;
  animation: preloaderRespaldo .5s ease 6s forwards;
}

/* Donde aterriza: junto a "Cotiza tu proyecto" */
.hero__quote { display: inline-flex; align-items: center; gap: 14px; min-height: 54px; color: var(--ink);
  font-size: 11px; font-weight: 600; letter-spacing: .22em; text-transform: uppercase; white-space: nowrap; }
.hero__cube { display: block; width: 34px; flex: none; color: var(--accent); }
.hero__quote-text { position: relative; display: inline-block; padding: 6px 0; }
.hero__quote-text::after {
  content: ""; position: absolute; left: 0; right: .22em; bottom: 2px; height: 1px; background: currentColor;
  transform-origin: right; transition: transform .5s var(--ease);
}
.hero__quote:hover .hero__quote-text::after { transform: scaleX(0); }
@media (hover: hover) {
  .hero__cube .cubo__p { transition: transform .6s var(--ease); }
  .hero__quote:hover .cubo__p[data-p="barra"]  { transform: translate(80px, -46px); }
  .hero__quote:hover .cubo__p[data-p="bloque"] { transform: translate(0, 90px); transition-delay: .04s; }
  .hero__quote:hover .cubo__p[data-p="cubo"]   { transform: translate(-80px, -46px); transition-delay: .08s; }
  .hero__quote:hover .cubo__p[data-p="muro"]   { transform: translate(-80px, 46px); transition-delay: .12s; }
  .hero__quote:hover .cubo__p[data-p="remate"] { transform: translate(0, -90px); transition-delay: .16s; }
}

/* Sin JavaScript no hay cubo: que no quede el hueco */
.hero__cube:empty, .contact__cube:empty { display: none; }

/* La firma reaparece en contacto y al enviar el formulario */
.contact__cube { display: block; width: 46px; color: var(--accent); margin-bottom: 28px; }
.form__cube { display: inline-block; width: 22px; margin-right: 10px; vertical-align: -3px; color: var(--accent); }

/* =========================================================
   HEADER
   ========================================================= */
.header {
  position: fixed; inset: 0 0 auto 0; z-index: 100;
  height: var(--header-h);
  transition: transform .6s var(--ease), background-color .4s ease, box-shadow .4s ease;
}
.header::after {
  content: ""; position: absolute; inset: auto 0 0 0; height: 1px; background: var(--line);
  opacity: 0; transition: opacity .4s ease;
}
.header.is-scrolled {
  background: color-mix(in srgb, var(--bg) 86%, transparent);
  -webkit-backdrop-filter: blur(14px); backdrop-filter: blur(14px);
}
.header.is-scrolled::after { opacity: 1; }
.header.is-hidden { transform: translateY(-100%); }

.header__inner {
  height: 100%; max-width: var(--maxw); margin-inline: auto; padding-inline: var(--pad);
  display: flex; align-items: center; gap: 40px;
}
.header__logo { position: relative; display: block; width: 150px; flex: none; }
.header__logo img { width: 100%; transition: opacity .4s ease; }
.header__logo .logo-light { position: absolute; inset: 0; opacity: 0; }
.menu-open .header__logo .logo-dark { opacity: 0; }
.menu-open .header__logo .logo-light { opacity: 1; }

.nav { display: flex; gap: clamp(22px, 2.8vw, 44px); margin-left: auto; }
.nav a {
  position: relative; font-size: 11px; font-weight: 500; letter-spacing: .22em; text-transform: uppercase;
  padding: 6px 0; transition: color .3s ease;
}
.nav a::after {
  content: ""; position: absolute; left: 0; right: .22em; bottom: 0; height: 1px; background: currentColor;
  transform: scaleX(0); transform-origin: right; transition: transform .5s var(--ease);
}
.nav a:hover::after, .nav a.is-active::after { transform: scaleX(1); transform-origin: left; }
.nav a.is-active { color: var(--accent); }

.burger { display: none; width: 44px; height: 44px; position: relative; margin-left: auto; }
.burger span {
  position: absolute; left: 10px; right: 10px; height: 1.5px; background: var(--ink);
  transition: transform .5s var(--ease), background-color .3s ease;
}
.burger span:first-child { top: 17px; }
.burger span:last-child { top: 25px; }
.menu-open .burger span { background: var(--accent-ink); }
.menu-open .burger span:first-child { transform: translateY(4px) rotate(45deg); }
.menu-open .burger span:last-child { transform: translateY(-4px) rotate(-45deg); }

/* Menú móvil */
.menu {
  position: fixed; inset: 0; z-index: 90;
  background: var(--accent); color: var(--accent-ink);
  display: flex; flex-direction: column; justify-content: space-between;
  padding: calc(var(--header-h) + 32px) var(--pad) 40px;
  clip-path: inset(0 0 100% 0); visibility: hidden;
  transition: clip-path .8s var(--ease), visibility 0s linear .8s;
}
.menu-open .menu { clip-path: inset(0 0 0 0); visibility: visible; transition: clip-path .8s var(--ease), visibility 0s; }
.menu-open .header { background: transparent; -webkit-backdrop-filter: none; backdrop-filter: none; }
.menu-open .header::after { opacity: 0; }
.menu__nav { display: flex; flex-direction: column; gap: 6px; }
.menu__nav a {
  display: flex; align-items: baseline; gap: 18px;
  font-family: var(--serif); font-size: clamp(40px, 11vw, 64px); line-height: 1.15;
  opacity: 0; transform: translateY(30px);
  transition: opacity .6s var(--ease), transform .8s var(--ease);
}
.menu__nav small { font-family: var(--sans); font-size: 11px; letter-spacing: .2em; opacity: .6; }
.menu-open .menu__nav a { opacity: 1; transform: none; }
.menu-open .menu__nav a:nth-child(1) { transition-delay: .2s; }
.menu-open .menu__nav a:nth-child(2) { transition-delay: .26s; }
.menu-open .menu__nav a:nth-child(3) { transition-delay: .32s; }
.menu-open .menu__nav a:nth-child(4) { transition-delay: .38s; }
.menu-open .menu__nav a:nth-child(5) { transition-delay: .44s; }
.menu__foot { display: grid; gap: 6px; font-size: 13px; letter-spacing: .06em; opacity: .85; }

/* =========================================================
   HERO
   ========================================================= */
.hero {
  position: relative; min-height: 100vh; min-height: 100svh;
  display: flex; align-items: center;
  padding-top: var(--header-h);
  overflow: hidden;
}
.hero__topo {
  position: absolute; left: -12%; bottom: -18%; width: min(1100px, 80vw);
  opacity: .55; pointer-events: none; user-select: none;
}
.hero__grid { position: relative; z-index: 2; }
.hero__content { max-width: min(580px, 44vw); padding-block: 64px 96px; }
.hero__title {
  font-family: var(--serif); font-weight: 400;
  font-size: clamp(54px, 6.5vw, 112px); line-height: .96; letter-spacing: -.018em;
  margin-bottom: 34px;
}
.hero__text { font-size: 15px; color: var(--ink-2); max-width: 44ch; margin-bottom: 40px; }
.hero__actions { display: flex; flex-wrap: wrap; align-items: center; gap: 18px 30px; }

.hero__media {
  position: absolute; top: var(--header-h); right: 0; bottom: 0; width: 57%;
  clip-path: polygon(36% 0, 100% 0, 100% 100%, 0 100%);
  background: var(--bg-2);
  cursor: pointer;
}
.hero__slides, .hero__slide { position: absolute; inset: 0; }
.hero__slide { opacity: 0; }
.hero__slide.is-active { opacity: 1; }
.hero__slide img { width: 100%; height: 100%; object-fit: cover; }
.hero__media::after {
  content: ""; position: absolute; inset: auto 0 0 0; height: 40%;
  background: linear-gradient(to top, rgba(20, 20, 14, .55), transparent);
  pointer-events: none;
}
.hero__caption {
  position: absolute; right: var(--pad); bottom: 36px; z-index: 2;
  display: flex; align-items: center; gap: 18px;
  color: #fff; font-size: 11px; letter-spacing: .22em; text-transform: uppercase;
}
.hero__count b { font-weight: 600; }
.hero__progress { position: relative; width: 90px; height: 1px; background: rgba(255, 255, 255, .35); overflow: hidden; }
.hero__progress i { position: absolute; inset: 0; background: #fff; transform: scaleX(0); transform-origin: left; }

.hero__scroll {
  position: absolute; left: var(--pad); bottom: 30px; z-index: 2;
  display: flex; align-items: center; gap: 14px;
  font-size: 10px; letter-spacing: .3em; text-transform: uppercase; color: var(--ink-2);
}
.hero__scroll i { position: relative; width: 1px; height: 46px; background: var(--line); overflow: hidden; }
.hero__scroll i::after {
  content: ""; position: absolute; left: 0; top: 0; width: 100%; height: 40%; background: var(--ink);
  animation: scrollLine 2.2s var(--ease) infinite;
}
@keyframes scrollLine { 0% { transform: translateY(-100%); } 100% { transform: translateY(260%); } }

/* =========================================================
   MARQUEE
   ========================================================= */
.marquee { background: var(--accent); color: var(--accent-ink); overflow: hidden; padding: 26px 0; position: relative; z-index: 2; }
.marquee__track { display: flex; width: max-content; will-change: transform; }
.marquee__group { display: flex; align-items: center; gap: 44px; padding-right: 44px; flex: none; }
.marquee__group span { font-family: var(--serif); font-style: italic; font-size: clamp(26px, 2.8vw, 40px); line-height: 1; white-space: nowrap; }
.marquee__group img { width: 30px; opacity: .85; }

/* =========================================================
   CABECERA DE SECCIÓN
   ========================================================= */
.section-head {
  display: flex; align-items: flex-end; justify-content: space-between; gap: 32px 60px;
  flex-wrap: wrap; margin-bottom: clamp(48px, 6vw, 80px);
}
.section-head__text { max-width: 42ch; color: var(--ink-2); }

/* =========================================================
   PROYECTOS
   ========================================================= */
.filters { display: flex; gap: 8px; flex-wrap: wrap; }
.filter {
  height: 44px; padding: 0 20px; border: 1px solid var(--line-strong);
  font-size: 10.5px; font-weight: 600; letter-spacing: .2em; text-transform: uppercase;
  transition: background .4s var(--ease), color .4s var(--ease), border-color .4s var(--ease);
}
.filter:hover { border-color: var(--ink); }
.filter.is-active { background: var(--ink); border-color: var(--ink); color: var(--bg); }

.projects__grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: clamp(16px, 2vw, 28px); }
.card.is-hidden { display: none; }
.card__link { display: block; height: 100%; background: var(--paper); border: 1px solid var(--line); transition: border-color .5s var(--ease); }
.card__link:hover { border-color: var(--line-strong); }
.card__media { position: relative; aspect-ratio: 4 / 3; overflow: hidden; background: var(--bg-2); }
.card__media img { width: 100%; height: 100%; object-fit: cover; transition: transform 1.2s var(--ease); }
.card__link:hover .card__media img { transform: scale(1.06); }
.card__count {
  position: absolute; left: 16px; top: 16px;
  background: color-mix(in srgb, var(--bg) 90%, transparent); color: var(--ink);
  font-size: 9.5px; font-weight: 600; letter-spacing: .2em; text-transform: uppercase;
  padding: 7px 11px;
}
.card__info { padding: 20px 22px 18px; display: grid; gap: 10px; }
.card__row { display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.card__title { font-family: var(--sans); font-size: 12.5px; font-weight: 600; letter-spacing: .18em; text-transform: uppercase; }
.card__tag { font-size: 9.5px; font-weight: 600; letter-spacing: .2em; text-transform: uppercase; color: var(--accent); }
.card__desc { font-size: 13px; color: var(--muted); }

/* =========================================================
   ESTUDIO
   ========================================================= */
.studio__planwrap { position: absolute; inset: 0; overflow: hidden; pointer-events: none; }
.studio__plan {
  position: absolute; right: -6%; top: 6%; width: min(900px, 58vw);
  opacity: .1; pointer-events: none; user-select: none;
}
.studio__grid { position: relative; display: grid; grid-template-columns: 1.05fr 1fr; gap: clamp(48px, 7vw, 120px); align-items: start; }
.studio__media { position: sticky; top: calc(var(--header-h) + 24px); padding-bottom: 14%; }
.studio__img { overflow: hidden; background: var(--bg-2); }
.studio__img img { width: 100%; height: 100%; object-fit: cover; }
.studio__img--main { aspect-ratio: 4 / 3.6; }
.studio__img--main img { height: 116%; margin-top: -8%; }
.studio__img--sub {
  position: absolute; right: -8%; bottom: 0; width: 48%; aspect-ratio: 1 / 1;
  border: 10px solid var(--bg);
}
.studio__content .h2 { margin-bottom: 30px; }
.studio__content .lead { margin-bottom: 40px; }

.founders { display: grid; gap: 0; margin-bottom: 44px; border-top: 1px solid var(--line); }
.founder { display: grid; grid-template-columns: 64px 1fr; gap: 22px; padding: 26px 0; border-bottom: 1px solid var(--line); }
.founder__mono {
  width: 64px; height: 64px; border-radius: 50%; border: 1px solid var(--line-strong);
  display: grid; place-items: center;
  font-family: var(--serif); font-style: italic; font-size: 24px; color: var(--accent);
}
.founder__name { font-family: var(--serif); font-weight: 500; font-size: 25px; line-height: 1.15; margin-bottom: 4px; }
.founder__role { font-size: 10.5px; font-weight: 600; letter-spacing: .2em; text-transform: uppercase; color: var(--accent); margin-bottom: 10px; }
.founder__text { font-size: 14px; color: var(--ink-2); margin-bottom: 8px; }
.founder__years { font-size: 12px; letter-spacing: .08em; color: var(--muted); }
.founder__years b { font-variant-numeric: lining-nums; font-family: var(--serif); font-size: 20px; font-weight: 500; color: var(--ink); margin-right: 2px; }

/* =========================================================
   CIFRAS
   ========================================================= */
.stats { background: var(--bg-2); border-block: 1px solid var(--line); padding-block: clamp(56px, 7vw, 92px); }
.stats__grid { display: grid; grid-template-columns: repeat(4, 1fr); }
.stat { text-align: center; padding: 8px 20px; position: relative; }
.stat + .stat::before { content: ""; position: absolute; left: 0; top: 18%; bottom: 18%; width: 1px; background: var(--line-strong); }
.stat__num {
  font-variant-numeric: lining-nums;
  font-family: var(--serif); font-weight: 300; font-size: clamp(56px, 6.4vw, 96px); line-height: 1;
  display: inline-flex; align-items: flex-start; gap: 4px; margin-bottom: 14px;
}
.stat__num sup { font-size: .32em; line-height: 1.4; color: var(--accent); }
.stat__label { font-size: 10.5px; font-weight: 500; letter-spacing: .22em; text-transform: uppercase; color: var(--ink-2); max-width: 22ch; margin-inline: auto; }

/* =========================================================
   MÁS QUE CONSTRUIR (banner)
   ========================================================= */
.statement {
  position: relative; min-height: 100vh; min-height: 100svh;
  display: flex; align-items: center; overflow: hidden; color: #fff;
  background: #3f6a96;
}
.statement__bg { position: absolute; inset: -12% 0; }
.statement__bg img { width: 100%; height: 100%; object-fit: cover; object-position: 30% 50%; }
.statement__shade {
  position: absolute; inset: 0;
  background: linear-gradient(90deg, rgba(14, 26, 42, .55) 0%, rgba(14, 26, 42, .2) 50%, rgba(14, 26, 42, 0) 75%);
}
.statement__inner { position: relative; z-index: 1; padding-block: 120px; }
.statement__top { display: grid; gap: 4px; margin-bottom: clamp(48px, 9vh, 110px); font-size: 12px; letter-spacing: .2em; text-transform: uppercase; }
.statement__top span { font-weight: 300; }
.statement__top b { font-weight: 700; }
.statement__title {
  font-family: var(--display); font-weight: 800; text-transform: uppercase;
  font-size: clamp(60px, 11.5vw, 196px); line-height: .86; letter-spacing: -.04em;
  margin-bottom: 36px;
}
.statement__line { display: block; overflow: hidden; padding: .16em 0 .04em; margin-top: -.16em; }
.statement__line > span { display: inline-block; }
.statement__sub { font-size: clamp(17px, 1.6vw, 24px); font-weight: 400; line-height: 1.4; max-width: 30ch; }
.statement__list {
  position: absolute; right: var(--pad); bottom: 120px;
  display: grid; gap: 10px; text-align: right;
  font-size: clamp(13px, 1.1vw, 16px); letter-spacing: .14em; text-transform: uppercase;
}

/* =========================================================
   SERVICIOS
   ========================================================= */
.services__grid {
  display: grid; grid-template-columns: repeat(4, 1fr);
  border-top: 1px solid var(--line); border-left: 1px solid var(--line);
}
.service {
  position: relative; padding: 40px 32px 34px;
  border-right: 1px solid var(--line); border-bottom: 1px solid var(--line);
  display: flex; flex-direction: column;
  transition: background-color .6s var(--ease);
}
.service:hover { background: var(--paper); }
.service__icon { width: 46px; height: 46px; fill: none; stroke: var(--ink); stroke-width: 1.2; stroke-linecap: round; stroke-linejoin: round; transition: stroke .4s ease; }
.service:hover .service__icon { stroke: var(--accent); }
.service h3 { font-size: 12.5px; font-weight: 600; letter-spacing: .18em; text-transform: uppercase; margin: 28px 0 12px; }
.service p { font-size: 14px; color: var(--ink-2); margin-bottom: 26px; }
.service__link {
  margin-top: auto; display: inline-flex; align-items: center; gap: 12px; padding: 13px 0; margin-bottom: -13px; align-self: flex-start;
  font-size: 10.5px; font-weight: 600; letter-spacing: .22em; text-transform: uppercase; color: var(--ink);
}
.service__link:hover { color: var(--accent); }

/* =========================================================
   DETRÁS DE LA OBRA / PROCESO
   ========================================================= */
.process { position: relative; overflow: hidden; color: #fff; background: #12171a; }
.process__bg { position: absolute; inset: -10% 0; }
.process__bg img { width: 100%; height: 100%; object-fit: cover; object-position: 50% 20%; }
.process__shade {
  position: absolute; inset: 0;
  background:
    linear-gradient(180deg, rgba(16, 22, 28, .55) 0%, rgba(16, 22, 28, .25) 30%, rgba(14, 19, 22, .75) 62%, #101417 92%),
    linear-gradient(90deg, rgba(16, 22, 28, .5), transparent 60%);
}
.process__inner { position: relative; z-index: 1; padding-block: clamp(110px, 14vw, 180px) clamp(80px, 9vw, 120px); }
.process__head { max-width: 760px; margin-bottom: clamp(120px, 26vh, 300px); }
.process__title {
  font-family: var(--display); font-weight: 800; text-transform: uppercase;
  line-height: .84; letter-spacing: -.04em; margin-bottom: 34px;
  display: flex; flex-direction: column;
}
.process__title > span { display: block; overflow: hidden; padding: .16em 0 .03em; margin-top: -.16em; }
.process__title > span > span { display: inline-block; }
.process__l1 { font-size: clamp(64px, 10.5vw, 176px); }
.process__l2 { font-size: clamp(32px, 5vw, 84px); letter-spacing: -.03em; }
.process__l3 { font-size: clamp(76px, 12.5vw, 210px); }
.process__text { font-size: 16px; max-width: 46ch; color: rgba(255, 255, 255, .82); }

.steps { position: relative; }
.steps__line { position: absolute; left: 0; right: 0; top: 0; height: 1px; background: rgba(255, 255, 255, .2); }
.steps__line span { position: absolute; inset: 0; background: var(--accent-soft); transform: scaleX(0); transform-origin: left; }
.steps__list { display: grid; grid-template-columns: repeat(4, 1fr); gap: 40px; counter-reset: s; }
.step { position: relative; padding-top: 40px; }
.step__dot {
  position: absolute; left: 0; top: -5px; width: 11px; height: 11px; border-radius: 50%;
  background: #101417; border: 1px solid rgba(255, 255, 255, .5);
  transition: background-color .4s ease, border-color .4s ease;
}
.step.is-on .step__dot { background: var(--accent-soft); border-color: var(--accent-soft); }
.step__num { font-variant-numeric: lining-nums; display: block; font-family: var(--serif); font-style: italic; font-size: 44px; line-height: 1; color: var(--accent-soft); margin-bottom: 18px; }
.step h3 { font-size: 13px; font-weight: 600; letter-spacing: .2em; text-transform: uppercase; margin-bottom: 12px; }
.step p { font-size: 14px; color: rgba(255, 255, 255, .7); }

/* =========================================================
   CONTACTO
   ========================================================= */
.contact { border-top: 1px solid var(--line); }
.contact__grid { display: grid; grid-template-columns: 1fr 1.25fr .95fr; max-width: 1600px; margin-inline: auto; }
.contact__grid > * { padding: clamp(64px, 8vw, 110px) clamp(24px, 4vw, 64px); }
.contact__intro .h2 { font-size: clamp(40px, 4vw, 60px); margin-bottom: 30px; }
.contact__intro p { color: var(--ink-2); max-width: 30ch; }
.rule { display: block; width: 40px; height: 1px; background: var(--ink); margin-bottom: 26px; }

.form { border-left: 1px solid var(--line); border-right: 1px solid var(--line); display: grid; gap: 30px; align-content: start; }
.field { display: grid; gap: 4px; }
.field label { font-size: 10px; font-weight: 600; letter-spacing: .22em; text-transform: uppercase; color: var(--ink-2); }
.field input, .field select, .field textarea {
  width: 100%; border: 0; border-bottom: 1px solid var(--line-strong); border-radius: 0;
  background: transparent; color: var(--ink);
  font: inherit; font-size: 15px; padding: 10px 0 12px;
  transition: border-color .3s ease;
  -webkit-appearance: none; appearance: none;
}
.field textarea { resize: vertical; min-height: 96px; }
.field input:focus, .field select:focus, .field textarea:focus { outline: none; border-color: var(--accent); }
.field.is-error input { border-color: #A2412F; }
.field--select select {
  cursor: pointer; padding-right: 28px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1l5 5 5-5' fill='none' stroke='%234B4840' stroke-width='1.2'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right 4px center;
}
.form__actions { display: flex; flex-wrap: wrap; align-items: center; gap: 16px 24px; padding-top: 6px; }
.form__note { font-size: 13px; color: var(--accent); min-height: 1em; }
.form__note.is-error { color: #A2412F; }
.form__note a { font-weight: 600; text-decoration: underline; text-underline-offset: 3px; }

.contact__card { background: var(--bg-2); display: flex; flex-direction: column; }
.contact__logo { width: 118px; margin-bottom: 40px; }
.contact__list { display: grid; gap: 18px; margin-bottom: 36px; font-size: 14px; }
.contact__list li { display: grid; grid-template-columns: 20px 1fr; gap: 14px; align-items: start; }
.contact__list svg { width: 18px; height: 18px; margin-top: 3px; fill: none; stroke: var(--ink-2); stroke-width: 1.3; stroke-linecap: round; stroke-linejoin: round; }
.contact__list a { display: inline-block; padding: 10px 0; margin: -10px 0; border-bottom: 1px solid transparent; transition: border-color .3s ease; }
.contact__list a:hover { border-color: currentColor; }

/* =========================================================
   FOOTER
   ========================================================= */
.footer { background: var(--accent); color: var(--accent-ink); }
.footer__top { display: flex; align-items: center; gap: 32px 56px; flex-wrap: wrap; padding-block: 56px 44px; }
.footer__logo { width: 168px; }
.footer__nav { display: flex; flex-wrap: wrap; gap: 14px 32px; margin-left: auto; }
.footer__nav a, .footer__side a { display: inline-block; padding: 12px 0; font-size: 11px; font-weight: 500; letter-spacing: .22em; text-transform: uppercase; opacity: .85; transition: opacity .3s ease; }
.footer__nav a:hover, .footer__side a:hover { opacity: 1; }
.footer__side { display: flex; gap: 32px; }
.footer__bottom::before { content: ""; position: absolute; top: 0; left: var(--pad); right: var(--pad); height: 1px; background: color-mix(in srgb, var(--accent-ink) 22%, transparent); }
.footer__bottom {
  display: flex; justify-content: space-between; gap: 12px 32px; flex-wrap: wrap;
  position: relative; padding-block: 22px;
  font-size: 10.5px; letter-spacing: .16em; text-transform: uppercase; opacity: .9;
}

/* =========================================================
   WHATSAPP FLOTANTE
   ========================================================= */
.wa {
  position: fixed; right: clamp(16px, 2.4vw, 32px); bottom: clamp(16px, 2.4vw, 32px); z-index: 80;
  width: 60px; height: 60px; border-radius: 50%;
  display: grid; place-items: center;
  background: var(--accent); color: var(--accent-ink);
  box-shadow: 0 14px 34px -12px rgba(24, 24, 16, .5);
  transform: scale(0); transition: transform .6s var(--ease), background-color .4s ease;
}
.wa.is-visible { transform: scale(1); }
.wa:hover { background: var(--ink); }
.wa svg { width: 28px; height: 28px; fill: currentColor; }
.wa__tip {
  position: absolute; right: calc(100% + 14px); top: 50%; white-space: nowrap;
  background: var(--ink); color: var(--bg);
  font-size: 11px; font-weight: 500; letter-spacing: .08em; padding: 10px 14px;
  opacity: 0; transform: translate(8px, -50%); pointer-events: none;
  transition: opacity .5s var(--ease), transform .5s var(--ease);
}
.wa:hover .wa__tip, .wa.show-tip .wa__tip { opacity: 1; transform: translate(0, -50%); }

/* =========================================================
   GALERÍA (LIGHTBOX)
   ========================================================= */
.lightbox {
  position: fixed; inset: 0; z-index: 400;
  display: grid; grid-template-rows: auto 1fr auto;
  background: rgba(22, 22, 17, .97); color: #F3EFE8;
}
[data-tema="bn"] .lightbox { background: rgba(10, 10, 10, .97); }
.lightbox[hidden] { display: none; }
.lightbox__top { display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 20px; padding: 22px clamp(16px, 3vw, 40px); }
.lightbox__title { font-size: 13px; font-weight: 600; letter-spacing: .2em; text-transform: uppercase; }
.lightbox__meta { font-size: 11px; letter-spacing: .14em; text-transform: uppercase; opacity: .6; margin-top: 2px; }
.lightbox__count { font-variant-numeric: lining-nums; font-family: var(--serif); font-size: 22px; letter-spacing: .04em; }
.lightbox__close { justify-self: end; width: 48px; height: 48px; border-radius: 50%; border: 1px solid rgba(255, 255, 255, .25); display: grid; place-items: center; transition: background-color .3s ease, transform .5s var(--ease); }
.lightbox__close:hover { background: rgba(255, 255, 255, .1); transform: rotate(90deg); }
.lightbox__close svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.3; }

.lightbox__stage { position: relative; display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 20px; padding: 0 clamp(16px, 3vw, 40px); min-height: 0; }
.lightbox__figure { position: relative; height: 100%; min-height: 0; display: grid; place-items: center; grid-template-rows: 1fr auto; gap: 14px; }
.lightbox__img { max-width: 100%; max-height: calc(100vh - 250px); max-height: calc(100svh - 250px); width: auto; height: auto; object-fit: contain; user-select: none; -webkit-user-drag: none; }
.lightbox__caption { font-size: 12px; letter-spacing: .1em; opacity: .7; text-align: center; }
.lightbox__nav {
  width: 56px; height: 56px; border-radius: 50%; border: 1px solid rgba(255, 255, 255, .25);
  display: grid; place-items: center; transition: background-color .3s ease, border-color .3s ease;
}
.lightbox__nav:hover { background: #F3EFE8; color: var(--dark); border-color: #F3EFE8; }
.lightbox__nav svg { width: 24px; height: 10px; fill: none; stroke: currentColor; stroke-width: 1.3; }
.lightbox__nav[disabled] { opacity: 0; pointer-events: none; }

.lightbox__thumbs { display: flex; justify-content: center; gap: 8px; padding: 18px clamp(16px, 3vw, 40px) 24px; overflow-x: auto; scrollbar-width: none; }
.lightbox__thumbs::-webkit-scrollbar { display: none; }
.lightbox__thumb { flex: none; width: 86px; height: 58px; opacity: .4; outline: 1px solid transparent; outline-offset: 3px; transition: opacity .3s ease, outline-color .3s ease; }
.lightbox__thumb img { width: 100%; height: 100%; object-fit: cover; }
.lightbox__thumb:hover { opacity: .8; }
.lightbox__thumb.is-active { opacity: 1; outline-color: #F3EFE8; }

/* =========================================================
   CURSOR "VER"
   ========================================================= */
.cursor { display: none; }
@media (hover: hover) and (pointer: fine) {
  .cursor { display: block; position: fixed; left: 0; top: 0; width: 0; height: 0; z-index: 300; pointer-events: none; }
  .cursor span {
    position: absolute; left: -46px; top: -46px; width: 92px; height: 92px; border-radius: 50%;
    display: grid; place-items: center;
    background: var(--accent); color: var(--accent-ink);
    font-size: 10.5px; font-weight: 600; letter-spacing: .24em; text-transform: uppercase; padding-left: .24em;
    transform: scale(0); transition: transform .5s var(--ease);
  }
  .cursor.is-visible span { transform: scale(1); }
}

/* Bloqueo de scroll con menú o galería abiertos */
.menu-open body, .lb-open body { overflow: hidden; }
.lb-open .wa { opacity: 0; pointer-events: none; }

/* =========================================================
   RESPONSIVO
   ========================================================= */
@media (max-width: 1200px) {
  .services__grid { grid-template-columns: repeat(2, 1fr); }
  .contact__grid { grid-template-columns: 1fr 1.2fr; }
  .contact__card { grid-column: 1 / -1; display: grid; grid-template-columns: auto 1fr; gap: 0 56px; align-items: start; }
  .contact__card .contact__logo { grid-row: span 2; }
  .form { border-right: 0; }
  .contact__card { border-top: 1px solid var(--line); }
}

@media (max-width: 1024px) {
  :root { --header-h: 72px; }
  .nav, .header__cta { display: none; }
  .burger { display: block; }
  .header { background: color-mix(in srgb, var(--bg) 92%, transparent); -webkit-backdrop-filter: blur(12px); backdrop-filter: blur(12px); }
  .header__logo { width: 132px; }

  .hero { flex-direction: column; align-items: stretch; min-height: 0; }
  .hero__content { max-width: 640px; padding-block: 48px 48px; }
  .hero__media { position: relative; width: 100%; height: 62vh; min-height: 380px; clip-path: polygon(0 14%, 100% 0, 100% 100%, 0 100%); }
  .hero__scroll { display: none; }
  .hero__topo { left: -30%; bottom: auto; top: 8%; width: 140vw; }

  .projects__grid { grid-template-columns: repeat(2, 1fr); }
  .studio__grid { grid-template-columns: 1fr; }
  .studio__media { max-width: 760px; position: relative; top: 0; }
  .studio__img--sub { right: 0; }
  .studio__plan { width: 110vw; top: auto; bottom: 0; right: -30%; }

  .stats__grid { grid-template-columns: repeat(2, 1fr); row-gap: 40px; }
  .stat:nth-child(3)::before { display: none; }

  .steps__list { grid-template-columns: repeat(2, 1fr); row-gap: 56px; }
  .statement__list { position: static; text-align: left; margin-top: 48px; grid-auto-flow: column; justify-content: start; gap: 28px; }
}

@media (max-width: 720px) {
  body { font-size: 14.5px; }
  .hero__title { font-size: clamp(46px, 13vw, 64px); }
  .hero__media { height: 52vh; min-height: 320px; }
  .hero__caption { bottom: 20px; }
  .btn { --h: 50px; padding: 0 24px; }

  .projects__grid { grid-template-columns: 1fr; }
  .filters { width: 100%; }
  .filter { flex: 1; padding: 0 10px; }

  .studio__img--sub { width: 52%; border-width: 6px; }
  .founder { grid-template-columns: 52px 1fr; gap: 16px; }
  .founder__mono { width: 52px; height: 52px; font-size: 20px; }

  .stats__grid { grid-template-columns: 1fr 1fr; }
  .stat { padding: 8px 10px; }

  .statement__bg img { object-position: 36% 50%; }
  .statement__shade { background: linear-gradient(180deg, rgba(14, 26, 42, .55), rgba(14, 26, 42, .45) 50%, rgba(14, 26, 42, .62)); }
  /* El título se ajusta al ancho del teléfono: "CONSTRUIR" (la palabra más larga) siempre cabe */
  .statement__title { font-size: calc((100vw - 2 * var(--pad)) / 5.9); }
  /* Resplandor oscuro detrás de las letras para que se lean sobre el muro blanco */
  .statement__title, .statement__sub, .statement__list, .statement__top { text-shadow: 0 2px 22px rgba(8, 16, 28, .45); }
  .statement__list { grid-auto-flow: row; gap: 8px; }

  .services__grid { grid-template-columns: 1fr; }
  .service { padding: 32px 24px 28px; }

  .process__head { margin-bottom: 90px; }
  .steps__line { left: 5px; right: auto; top: 0; bottom: 0; width: 1px; height: auto; }
  .steps__line span { transform: scaleY(0); transform-origin: top; }
  .steps__list { grid-template-columns: 1fr; gap: 44px; padding-left: 40px; }
  .step { padding-top: 0; }
  .step__dot { left: -40px; top: 6px; }

  .contact__grid { grid-template-columns: 1fr; }
  .form { border-left: 0; border-top: 1px solid var(--line); }
  .contact__card { display: flex; }

  .footer__top { flex-direction: column; align-items: flex-start; }
  .footer__nav { margin-left: 0; }

  .lightbox__top { grid-template-columns: 1fr auto; }
  .lightbox__count { grid-row: 2; grid-column: 1 / -1; font-size: 18px; }
  .lightbox__stage { grid-template-columns: 1fr; padding: 0 12px; }
  .lightbox__nav { position: absolute; bottom: -2px; z-index: 2; width: 46px; height: 46px; background: rgba(22, 22, 17, .6); }
  .lightbox__nav--prev { left: 12px; }
  .lightbox__nav--next { right: 12px; }
  .lightbox__caption { padding-inline: 60px; }
  .lightbox__img { max-height: calc(100svh - 260px); }
  .lightbox__thumb { width: 64px; height: 44px; }
  .lightbox__thumbs { justify-content: flex-start; }
}

/* ---------- Movimiento reducido ---------- */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; scroll-behavior: auto !important; }
}

/* Versión B/N: contorno al botón de WhatsApp para que no se pierda sobre fondos negros */
[data-tema="bn"] .wa { box-shadow: 0 0 0 1px rgba(255, 255, 255, .35), 0 14px 34px -12px rgba(0, 0, 0, .5); }
