/* ============================================================
   DECOPANAS — Taller de carpintería artesanal
   ============================================================ */

:root {
  --bg:        #f4efe6;
  --bg-deep:   #ece4d6;
  --bg-card:   #efe8db;
  --bg-elev:   #e6dccb;
  --line:      rgba(54,42,30,.16);
  --line-soft: rgba(54,42,30,.09);

  --fg:        #2c2620;
  --fg-mut:    #6c6155;
  --fg-dim:    #9a8e7e;

  --gold:      #9c7426;
  --gold-soft: #b08a3c;
  --gold-deep: #c2a572;

  --brand:     #1f8aa3;
  --wa:        #1eb858;
  --cz-head:   #3a3128;

  --serif: "Cormorant Garamond", Georgia, serif;
  --sans:  "Jost", "Helvetica Neue", Arial, sans-serif;
  --mono:  "Space Mono", ui-monospace, "SFMono-Regular", Menlo, monospace;

  --maxw: 1280px;
  --gut:  clamp(20px, 5vw, 64px);
  --ease: cubic-bezier(.22,.61,.36,1);
  --nav-bg: rgba(244,239,230,.88);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--fg);
  font-family: var(--sans);
  font-weight: 400;
  font-size: 17px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}

img { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button { font-family: inherit; cursor: pointer; }

::selection { background: var(--gold); color: #fff; }

.wrap { max-width: var(--maxw); margin: 0 auto; padding-inline: var(--gut); }

.eyebrow {
  font-family: var(--sans);
  font-weight: 400;
  font-size: 12px;
  letter-spacing: .42em;
  text-transform: uppercase;
  color: var(--gold);
  margin: 0 0 22px;
  display: inline-flex;
  align-items: center;
  gap: 14px;
}
.eyebrow::before {
  content: "";
  width: 34px; height: 1px;
  background: var(--gold);
  opacity: .7;
}
.eyebrow.center { justify-content: center; }
.eyebrow.center::after {
  content: "";
  width: 34px; height: 1px;
  background: var(--gold);
  opacity: .7;
}

.section-title {
  font-family: var(--serif);
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: .015em;
  line-height: 1.02;
  font-size: clamp(34px, 5vw, 62px);
  margin: 0;
}
.section-title .g { color: var(--gold); }

.lead {
  color: var(--fg-mut);
  font-size: clamp(16px, 1.4vw, 19px);
  line-height: 1.7;
  font-weight: 300;
  max-width: 56ch;
}

.section { padding-block: clamp(80px, 11vw, 150px); }
.section--tight { padding-block: clamp(60px, 8vw, 110px); }

/* ---------- buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 14px;
  font-family: var(--sans);
  font-size: 12.5px;
  font-weight: 400;
  letter-spacing: .3em;
  text-transform: uppercase;
  padding: 17px 34px;
  border: 1px solid var(--gold);
  color: var(--gold-soft);
  background: transparent;
  transition: background .45s var(--ease), color .45s var(--ease), border-color .45s var(--ease);
}
.btn:hover { background: var(--gold); color: #fff; border-color: var(--gold); }
.btn--light { border-color: rgba(255,255,255,.55); color: #fff; }
.btn--light:hover { background: #fff; color: #2c2620; border-color: #fff; }
.btn--block { width: 100%; justify-content: center; }
.btn .arr { transition: transform .45s var(--ease); }
.btn:hover .arr { transform: translateX(5px); }

/* ---------- placeholders ---------- */
.ph {
  position: relative;
  background:
    repeating-linear-gradient(135deg, rgba(54,42,30,.035) 0 2px, transparent 2px 11px),
    linear-gradient(160deg, #d8ccb7 0%, #cdbfa6 55%, #c0af92 100%);
  display: grid;
  place-items: center;
  overflow: hidden;
  isolation: isolate;
  width: 100%;
  height: 100%;
}
.ph::before,
.ph::after {
  content: "";
  position: absolute;
  width: 16px; height: 16px;
  border: 1px solid rgba(120,90,30,.5);
  z-index: 2;
}
.ph::before { top: 14px; left: 14px; border-right: 0; border-bottom: 0; }
.ph::after  { bottom: 14px; right: 14px; border-left: 0; border-top: 0; }
.ph__tag {
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: #8a7c66;
  text-align: center;
  padding: 0 24px;
  line-height: 1.7;
  z-index: 2;
}
.ph__tag b { color: var(--gold); font-weight: 400; display: block; letter-spacing: .2em; }
.ph__img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; z-index: 1; }
.ph--filled { background: var(--bg-deep); }
.ph--filled::before, .ph--filled::after { display: none; }

/* ============================================================
   NAVBAR
   ============================================================ */
.nav {
  position: fixed; inset: 0 0 auto 0;
  z-index: 90;
  display: flex; align-items: center; justify-content: space-between;
  gap: 30px;
  padding: 22px var(--gut);
  transition: background .5s var(--ease), padding .5s var(--ease), border-color .5s var(--ease);
  border-bottom: 1px solid transparent;
}
.nav--solid {
  background: var(--nav-bg);
  -webkit-backdrop-filter: blur(14px);
  backdrop-filter: blur(14px);
  border-bottom-color: var(--line-soft);
  padding-block: 15px;
  box-shadow: 0 1px 22px rgba(54,42,30,.07);
}
.nav__brand { display: flex; align-items: center; gap: 13px; }
.nav__brand img {
  width: 58px; height: 58px;
  filter: brightness(0) invert(1);
  transition: filter .5s var(--ease);
}
.nav--solid .nav__brand img { filter: brightness(0) invert(.08); }
.nav__brand .word {
  font-family: var(--serif);
  font-weight: 600;
  font-size: 21px;
  letter-spacing: .26em;
  text-transform: uppercase;
  line-height: 1;
  color: #fff;
  transition: color .5s var(--ease);
}
.nav--solid .nav__brand .word { color: var(--fg); }
.nav__brand .sub {
  display: block;
  font-family: var(--sans);
  font-size: 8.5px;
  letter-spacing: .34em;
  color: rgba(255,255,255,.5);
  margin-top: 4px;
  transition: color .5s var(--ease);
}
.nav--solid .nav__brand .sub { color: var(--fg-dim); }

.nav__links {
  display: flex; align-items: center; gap: clamp(20px, 2.4vw, 40px);
  list-style: none; margin: 0; padding: 0;
}
.nav__links a {
  font-size: 12px;
  letter-spacing: .2em;
  text-transform: uppercase;
  color: rgba(255,255,255,.8);
  position: relative;
  padding: 6px 0;
  transition: color .3s var(--ease);
}
.nav--solid .nav__links a { color: var(--fg-mut); }
.nav__links a::after {
  content: "";
  position: absolute; left: 0; bottom: 0;
  width: 0; height: 1px; background: var(--gold);
  transition: width .35s var(--ease);
}
.nav__links a:hover { color: #fff; }
.nav--solid .nav__links a:hover { color: var(--fg); }
.nav__links a:hover::after { width: 100%; }

.nav__right { display: flex; align-items: center; gap: 18px; }
.wa-circle {
  display: grid; place-items: center; flex: none;
  width: 42px; height: 42px;
  border-radius: 50%;
  background: var(--wa);
  color: #fff;
  transition: transform .35s var(--ease), box-shadow .35s var(--ease);
}
.wa-circle:hover { transform: translateY(-2px); box-shadow: 0 8px 22px rgba(37,211,102,.4); }
.wa-circle svg { width: 22px; height: 22px; }

.nav__burger {
  display: none;
  flex-direction: column; gap: 5px;
  background: none; border: 0; padding: 8px;
}
.nav__burger span { width: 24px; height: 1.5px; background: #fff; transition: .35s var(--ease); }
.nav--solid .nav__burger span { background: var(--fg); }
.nav--solid .btn--light { border-color: var(--line); color: var(--fg); }
.nav--solid .btn--light:hover { background: var(--gold); border-color: var(--gold); color: #fff; }

/* ============================================================
   HERO
   ============================================================ */
.hero {
  position: relative;
  min-height: 100svh;
  display: flex; align-items: center;
  padding-top: 90px;
  padding-bottom: 64px;
  overflow: hidden;
}
.hero__bg {
  position: absolute; inset: 0; z-index: 0;
  background:
    repeating-linear-gradient(135deg, rgba(255,255,255,.02) 0 2px, transparent 2px 13px),
    radial-gradient(120% 90% at 70% 25%, #3a322a 0%, #241f1b 45%, #141210 100%);
}
.hero__bg .hero__video {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  object-fit: cover;
  z-index: 0;
}
.hero__scrim {
  position: absolute; inset: 0; z-index: 1;
  background:
    linear-gradient(180deg, rgba(15,13,12,.55) 0%, rgba(15,13,12,.25) 35%, rgba(15,13,12,.65) 100%),
    linear-gradient(90deg, rgba(15,13,12,.7) 0%, rgba(15,13,12,.15) 60%);
}
.hero .wrap { position: relative; z-index: 2; width: 100%; }
.hero__inner { max-width: 760px; }
.hero h1 {
  font-family: var(--serif);
  font-weight: 500;
  text-transform: uppercase;
  font-size: clamp(44px, 7.2vw, 96px);
  line-height: .98;
  letter-spacing: .01em;
  margin: 18px 0 26px;
  color: #f3eee6;
}
.hero h1 .g { color: var(--gold); }
.hero .lead { margin-bottom: 40px; color: #d6d0c6; }
.hero__cta { display: flex; flex-wrap: wrap; gap: 16px; }
.hero .btn { border-color: var(--gold-deep); color: #ecd6a6; }
.hero .btn:hover { background: var(--gold-deep); border-color: var(--gold-deep); color: #2c2620; }

.scroll-ind {
  position: absolute; left: 50%; bottom: 30px;
  transform: translateX(-50%);
  z-index: 3;
  display: flex; flex-direction: column; align-items: center; gap: 12px;
  color: rgba(255,255,255,.65);
}
.scroll-ind span {
  font-family: var(--sans); font-size: 10px;
  letter-spacing: .35em; text-transform: uppercase;
}
.scroll-ind .line { width: 1px; height: 46px; background: linear-gradient(var(--gold), transparent); position: relative; overflow: hidden; }
.scroll-ind .line::after {
  content: ""; position: absolute; top: -50%; left: 0; width: 100%; height: 50%;
  background: #fff; animation: scroll-dot 2.2s var(--ease) infinite;
}
@keyframes scroll-dot { 0% { top: -50%; } 100% { top: 100%; } }

/* ============================================================
   PROCESO
   ============================================================ */
.proceso { background: var(--bg-deep); }
.proceso__head { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 28px; margin-bottom: 70px; }
.steps {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 0;
}
.step {
  position: relative;
  padding: 34px 26px 34px 0;
  border-top: 1px solid var(--line);
}
.step + .step { padding-left: 26px; border-left: 1px solid var(--line-soft); }
.step__no {
  font-family: var(--serif);
  font-size: 58px; font-weight: 500; line-height: 1;
  color: transparent;
  -webkit-text-stroke: 1px var(--gold-deep);
  transition: color .5s var(--ease), -webkit-text-stroke-color .5s var(--ease);
  margin-bottom: 24px;
}
.step:hover .step__no { color: var(--gold); -webkit-text-stroke-color: var(--gold); }
.step__dot { position: absolute; top: -4.5px; left: 0; width: 8px; height: 8px; border-radius: 50%; background: var(--gold); }
.step + .step .step__dot { left: 26px; }
.step h3 {
  font-family: var(--sans); font-weight: 500; font-size: 16px;
  letter-spacing: .04em; text-transform: uppercase; margin: 0 0 10px;
}
.step p { color: var(--fg-mut); font-size: 14.5px; font-weight: 300; line-height: 1.6; margin: 0; }

/* ============================================================
   NOSOTROS
   ============================================================ */
.nosotros__grid {
  display: grid;
  grid-template-columns: 1.05fr 1fr;
  gap: clamp(36px, 6vw, 90px);
  align-items: center;
}
.nosotros__media { position: relative; }
.nosotros__media .ph { aspect-ratio: 4/5; }
.nosotros__media .stat {
  position: absolute; right: -1px; bottom: -1px;
  background: var(--gold); color: #fff;
  padding: 22px 28px;
  z-index: 5;
}
.nosotros__media .stat b { font-family: var(--serif); font-size: 40px; font-weight: 600; line-height: 1; display: block; }
.nosotros__media .stat span { font-family: var(--sans); font-size: 11px; letter-spacing: .18em; text-transform: uppercase; }

.quad {
  display: grid; grid-template-columns: 1fr 1fr;
  margin-top: 44px;
  border-top: 1px solid var(--line);
  border-left: 1px solid var(--line);
}
.quad__cell {
  padding: 28px 26px;
  border-right: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}
.quad__cell .n { font-family: var(--mono); font-size: 11px; color: var(--gold); letter-spacing: .2em; }
.quad__cell h4 { font-family: var(--sans); font-weight: 500; font-size: 15px; text-transform: uppercase; letter-spacing: .05em; margin: 14px 0 8px; }
.quad__cell p { color: var(--fg-mut); font-size: 13.5px; font-weight: 300; margin: 0; line-height: 1.55; }

/* ============================================================
   TESTIMONIOS
   ============================================================ */
.testimonios { background: var(--bg-deep); overflow: hidden; }
.testimonios__head { text-align: center; display: flex; flex-direction: column; align-items: center; }
.testimonios__head .eyebrow::before,
.testimonios__head .eyebrow::after { content: ""; width: 34px; height: 1px; background: var(--gold); opacity: .7; }
.testimonios__head .lead { max-width: 640px; margin-top: 22px; }

.marquee {
  position: relative;
  margin-top: clamp(40px, 5vw, 64px);
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 9%, #000 91%, transparent);
  mask-image: linear-gradient(90deg, transparent, #000 9%, #000 91%, transparent);
}
.marquee__track {
  display: flex;
  width: max-content;
  gap: 26px;
  padding-inline: 13px;
  animation: testiScroll 60s linear infinite;
  will-change: transform;
}
.marquee:hover .marquee__track { animation-play-state: paused; }
@keyframes testiScroll {
  from { transform: translateX(0); }
  to   { transform: translateX(-50%); }
}
@media (prefers-reduced-motion: reduce) {
  .marquee__track { animation: none; }
  .marquee { -webkit-mask-image: none; mask-image: none; overflow-x: auto; }
}

.testi {
  flex: 0 0 clamp(320px, 30vw, 420px);
  background: var(--bg);
  border: 1px solid var(--line-soft);
  padding: 38px 36px 32px;
  margin: 0;
  display: flex;
  flex-direction: column;
  position: relative;
  transition: border-color .4s var(--ease), transform .4s var(--ease), box-shadow .4s var(--ease);
}
.testi:hover {
  border-color: var(--gold-deep);
  transform: translateY(-4px);
  box-shadow: 0 22px 50px rgba(54,42,30,.1);
}
.testi__mark {
  font-family: var(--serif);
  font-size: 72px; line-height: .6; font-weight: 600;
  color: var(--gold); opacity: .28;
  height: 30px;
}
.testi blockquote {
  font-family: var(--serif);
  font-weight: 500;
  font-size: clamp(19px, 1.7vw, 22px);
  line-height: 1.4;
  color: var(--fg);
  margin: 14px 0 28px;
  text-wrap: pretty;
}
.testi figcaption {
  display: flex; align-items: center; gap: 14px;
  margin-top: auto;
  padding-top: 22px;
  border-top: 1px solid var(--line-soft);
}
.testi__avatar {
  flex: 0 0 auto;
  width: 44px; height: 44px;
  display: grid; place-items: center;
  border-radius: 50%;
  background: var(--gold); color: #fff;
  font-family: var(--sans); font-size: 13px; font-weight: 500; letter-spacing: .06em;
}
.testi__who { display: flex; flex-direction: column; line-height: 1.3; }
.testi__name { font-family: var(--sans); font-weight: 500; font-size: 14.5px; letter-spacing: .03em; color: var(--fg); }
.testi__meta { font-family: var(--mono); font-size: 10.5px; letter-spacing: .12em; text-transform: uppercase; color: var(--fg-mut); margin-top: 3px; }

@media (max-width: 640px) {
  .testi { flex-basis: 80vw; padding: 32px 28px 28px; }
}

/* ============================================================
   PROYECTOS — directorio de categorías (home)
   ============================================================ */
.proyectos { background: var(--bg); }
.cat-grid {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 16px;
  margin-top: 48px;
}
.cat-card {
  position: relative;
  display: block;
  flex: 0 1 calc((100% - 32px) / 3);
  max-width: 100%;
  aspect-ratio: 1/1;
  overflow: hidden;
  border: 1px solid var(--line-soft);
}
.cat-card--wide { flex-basis: calc((100% - 32px) / 3); aspect-ratio: 1/1; }
.cat-card .ph { position: absolute; inset: 0; transition: transform 1.2s var(--ease); }
.cat-card:hover .ph { transform: scale(1.06); }
.cat-card__veil {
  position: absolute; inset: 0; z-index: 3; pointer-events: none;
  background: linear-gradient(180deg, rgba(28,22,16,.05) 30%, rgba(24,18,12,.82) 100%);
}
.cat-card__body {
  position: absolute; left: 0; bottom: 0; z-index: 4;
  width: 100%; padding: 30px;
  display: flex; flex-direction: column; gap: 8px;
}
.cat-card__n {
  font-family: var(--mono); font-size: 11px; letter-spacing: .26em;
  color: var(--gold-deep);
}
.cat-card__body h3 {
  font-family: var(--serif); font-weight: 500; font-size: clamp(22px, 2.2vw, 30px);
  text-transform: uppercase; letter-spacing: .02em; line-height: 1.05;
  color: #f4efe6; margin: 0;
}
.cat-card__meta {
  display: inline-flex; align-items: center; gap: 10px;
  font-family: var(--sans); font-size: 11px; letter-spacing: .2em; text-transform: uppercase;
  color: rgba(244,239,230,.72); margin-top: 4px;
}
.cat-card__meta .arr { color: var(--gold-deep); transition: transform .4s var(--ease); }
.cat-card:hover .cat-card__meta .arr { transform: translateX(6px); }

/* ============================================================
   PROYECTOS — página de detalle
   ============================================================ */
.proj-hero {
  padding: clamp(120px, 16vh, 180px) 0 clamp(40px, 6vw, 70px);
  border-bottom: 1px solid var(--line);
}
.crumb {
  display: flex; flex-wrap: wrap; align-items: center; gap: 10px;
  font-family: var(--sans); font-size: 11px; letter-spacing: .2em; text-transform: uppercase;
  color: var(--fg-dim); margin-bottom: 26px;
}
.crumb a { color: var(--fg-mut); transition: color .3s var(--ease); }
.crumb a:hover { color: var(--gold); }
.crumb .sep { color: var(--gold-deep); }
.crumb .cur { color: var(--gold); white-space: nowrap; }
.proj-hero h1 {
  font-family: var(--serif); font-weight: 500; text-transform: uppercase;
  font-size: clamp(40px, 6vw, 78px); line-height: 1; letter-spacing: .01em;
  margin: 0 0 22px; color: var(--fg);
}
.proj-hero .lead { margin: 0; }

.cat-switch { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 38px; }
.cat-switch a {
  font-family: var(--sans); font-size: 11.5px; letter-spacing: .2em; text-transform: uppercase;
  padding: 11px 22px; border: 1px solid var(--line); color: var(--fg-mut);
  transition: .35s var(--ease);
}
.cat-switch a:hover { color: var(--fg); border-color: rgba(54,42,30,.32); }
.cat-switch a.is-active { background: var(--gold); border-color: var(--gold); color: #fff; }

.proj-grid {
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px 18px;
  align-items: start;
  padding-block: clamp(50px, 7vw, 80px);
}
.pcard { display: flex; flex-direction: column; }
.pcard__img {
  position: relative; overflow: hidden;
  aspect-ratio: 1/1; border: 1px solid var(--line-soft);
}
.pcard__img .ph { position: absolute; inset: 0; transition: transform 1.1s var(--ease); }
.pcard:hover .pcard__img .ph { transform: scale(1.05); }
.pcard__tag {
  position: absolute; left: 14px; top: 14px; z-index: 4;
  font-family: var(--mono); font-size: 10px; letter-spacing: .2em; text-transform: uppercase;
  color: #2c2620; background: rgba(244,239,230,.9);
  padding: 6px 12px;
}
.pcard__body { padding: 20px 2px 0; }
.pcard__body .place { font-family: var(--sans); font-size: 10.5px; letter-spacing: .22em; text-transform: uppercase; color: var(--gold); }
.pcard__body h3 { font-family: var(--serif); font-weight: 500; font-size: 24px; text-transform: uppercase; letter-spacing: .01em; margin: 9px 0 8px; line-height: 1.05; color: var(--fg); }
.pcard__body p { color: var(--fg-mut); font-weight: 300; font-size: 14.5px; line-height: 1.55; margin: 0; max-width: 42ch; display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 3; line-clamp: 3; overflow: hidden; }

.pcard { appearance: none; border: 0; background: none; padding: 0; margin: 0; font: inherit; color: inherit; text-align: left; cursor: pointer; width: 100%; }
.pcard__zoom {
  position: absolute; right: 14px; bottom: 14px; z-index: 4;
  display: inline-flex; align-items: center; gap: 7px;
  font-family: var(--mono); font-size: 10px; letter-spacing: .14em; text-transform: uppercase;
  color: #fff; background: rgba(44,38,32,.62); -webkit-backdrop-filter: blur(2px); backdrop-filter: blur(2px);
  padding: 7px 11px; border-radius: 2px;
  opacity: 0; transform: translateY(6px); transition: opacity .35s var(--ease), transform .35s var(--ease);
}
.pcard__zoom svg { width: 14px; height: 14px; }
.pcard:hover .pcard__zoom, .pcard:focus-visible .pcard__zoom { opacity: 1; transform: none; }
.pcard:focus-visible { outline: 2px solid var(--gold); outline-offset: 4px; }

/* ============================================================
   LIGHTBOX
   ============================================================ */
.lightbox { position: fixed; inset: 0; z-index: 1000; display: none; }
.lightbox.is-open { display: block; }
.lightbox__backdrop { position: absolute; inset: 0; background: rgba(28,23,18,.72); -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px); animation: lbFade .3s var(--ease); }
.lightbox__dialog {
  position: absolute; inset: 0; margin: auto;
  width: min(1180px, calc(100vw - 40px)); height: min(760px, calc(100dvh - 40px));
  display: grid; grid-template-columns: 1fr 320px; grid-template-rows: 1fr auto;
  grid-template-areas: "stage side" "rail side";
  background: var(--bg); border: 1px solid var(--line);
  box-shadow: 0 40px 100px rgba(28,23,18,.45);
  overflow: hidden; animation: lbRise .4s var(--ease);
}
@keyframes lbFade { from { opacity: 0; } }
@keyframes lbRise { from { opacity: 0; transform: translateY(18px); } }
.lightbox__close {
  position: absolute; top: max(12px, env(safe-area-inset-top)); right: max(12px, env(safe-area-inset-right)); z-index: 6;
  width: 38px; height: 38px; border: 0; cursor: pointer; border-radius: 50%;
  background: rgba(244,239,230,.9); color: var(--fg); font-size: 24px; line-height: 1;
  display: grid; place-items: center; transition: background .25s, transform .25s;
}
.lightbox__close:hover { background: #fff; transform: rotate(90deg); }

.lightbox__stage { grid-area: stage; position: relative; background: var(--bg-deep); overflow: hidden; }
.lightbox__photo { position: absolute; inset: 0; }
.lightbox__slide { position: absolute; inset: 0; opacity: 0; pointer-events: none; transition: opacity .3s var(--ease); }
.lightbox__slide.is-active { opacity: 1; pointer-events: auto; }
.lightbox__photo .ph { position: absolute; inset: 0; }
.lightbox__count {
  position: absolute; left: 18px; top: 18px; z-index: 4;
  font-family: var(--mono); font-size: 11px; letter-spacing: .2em; color: var(--fg-mut);
  background: rgba(244,239,230,.82); padding: 5px 10px;
}
.lightbox__caption {
  position: absolute; left: 18px; bottom: 18px; z-index: 4; max-width: 70%;
  font-family: var(--mono); font-size: 11px; letter-spacing: .12em; text-transform: uppercase; color: #fff;
  background: rgba(44,38,32,.62); padding: 8px 13px;
}
.lb-nav {
  position: absolute; top: 50%; transform: translateY(-50%); z-index: 5;
  width: 46px; height: 46px; border: 1px solid var(--line); cursor: pointer; border-radius: 50%;
  background: rgba(244,239,230,.9); color: var(--fg);
  display: grid; place-items: center; transition: background .25s, color .25s;
}
.lb-nav svg { width: 22px; height: 22px; }
.lb-nav:hover { background: var(--fg); color: var(--bg); }
.lb-nav--prev { left: 16px; }
.lb-nav--next { right: 16px; }

.lightbox__rail { grid-area: rail; display: flex; gap: 10px; padding: 14px 16px; background: var(--bg-card); border-top: 1px solid var(--line-soft); overflow-x: auto; }
.lb-thumb { flex: 0 0 110px; height: 74px; position: relative; border: 1px solid var(--line-soft); background: none; padding: 0; cursor: pointer; overflow: hidden; transition: border-color .25s; }
.lb-thumb .ph { position: absolute; inset: 0; }
.lb-thumb .ph__tag { font-size: 8px; padding: 0 6px; }
.lb-thumb .ph::before, .lb-thumb .ph::after { display: none; }
.lb-thumb.is-active { border-color: var(--gold); box-shadow: inset 0 0 0 1px var(--gold); }

.lightbox__side { grid-area: side; padding: 40px 32px; border-left: 1px solid var(--line-soft); display: flex; flex-direction: column; overflow-y: auto; }
.lightbox__tag { font-family: var(--mono); font-size: 10px; letter-spacing: .2em; text-transform: uppercase; color: #fff; background: var(--gold); align-self: flex-start; padding: 5px 11px; }
.lightbox__place { font-family: var(--sans); font-size: 10.5px; letter-spacing: .22em; text-transform: uppercase; color: var(--gold); margin-top: 22px; }
.lightbox__side h3 { font-family: var(--serif); font-weight: 500; font-size: 30px; text-transform: uppercase; letter-spacing: .01em; line-height: 1.05; margin: 10px 0 16px; color: var(--fg); }
.lightbox__side p { color: var(--fg-mut); font-weight: 300; font-size: 15px; line-height: 1.6; margin: 0 0 28px; }
.lightbox__wa {
  margin-top: auto; display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  background: var(--wa); color: #fff; text-decoration: none;
  font-family: var(--sans); font-size: 13.5px; letter-spacing: .04em; font-weight: 400;
  padding: 14px 18px; border-radius: 14px; transition: filter .25s;
}
.lightbox__wa:hover { filter: brightness(1.06); }
.lightbox__wa svg { width: 18px; height: 18px; }

@media (max-width: 860px) {
  .lightbox__dialog {
    display: flex; flex-direction: column;
    inset: 0 auto auto 0; margin: 0;
    width: 100vw; height: 100dvh; border: 0;
    overflow-y: auto; -webkit-overflow-scrolling: touch;
  }
  .lightbox__stage { flex: 0 0 auto; height: 56dvh; min-height: 240px; }
  .lightbox__rail { flex: 0 0 auto; }
  .lightbox__side { flex: 0 0 auto; overflow: visible; padding: 22px 22px max(26px, env(safe-area-inset-bottom)); border-left: 0; border-top: 1px solid var(--line-soft); }
  .lightbox__side h3 { font-size: 24px; }
  .lightbox__place { margin-top: 14px; }
  .lightbox__close { position: fixed; }
}

.proj-cta {
  border-top: 1px solid var(--line);
  padding-block: clamp(60px, 9vw, 100px);
  text-align: center;
}
.proj-cta h2 { font-family: var(--serif); font-weight: 500; font-size: clamp(30px, 4vw, 50px); text-transform: uppercase; letter-spacing: .015em; margin: 0 0 16px; }
.proj-cta h2 .g { color: var(--gold); }
.proj-cta p { color: var(--fg-mut); font-weight: 300; margin: 0 auto 34px; max-width: 48ch; }
.proj-cta__btns { display: flex; flex-wrap: wrap; gap: 16px; justify-content: center; }
.btn-wa-inline {
  display: inline-flex; align-items: center; gap: 12px;
  background: var(--wa); color: #fff;
  font-family: var(--sans); font-size: 12.5px; font-weight: 500; letter-spacing: .2em; text-transform: uppercase;
  padding: 17px 30px;
  transition: background .35s var(--ease), transform .35s var(--ease), box-shadow .35s var(--ease);
}
.btn-wa-inline svg { width: 20px; height: 20px; }
.btn-wa-inline:hover { background: #1aa34e; transform: translateY(-2px); box-shadow: 0 12px 28px rgba(37,211,102,.25); }

/* ============================================================
   CONTACTO
   ============================================================ */
.contacto__head { margin-bottom: 56px; }
.contacto { background: var(--bg-deep); }
.contacto__grid {
  display: grid;
  grid-template-columns: 0.82fr 1.18fr;
  gap: 22px;
  align-items: stretch;
}

.contacto__info {
  border: 1px solid var(--line);
  background: var(--bg-card);
  padding: clamp(28px, 3vw, 42px);
  display: flex;
  flex-direction: column;
}
.info-block { margin-bottom: 30px; }
.info-block .k {
  font-family: var(--sans); font-size: 10.5px; letter-spacing: .26em;
  text-transform: uppercase; color: var(--fg-dim); margin-bottom: 14px;
}
.info-addr {
  font-family: var(--serif); font-weight: 500; font-size: clamp(20px, 1.9vw, 26px);
  line-height: 1.25; color: var(--fg); margin: 0;
}
.info-line { font-size: 15.5px; color: var(--fg-mut); font-weight: 300; margin: 0 0 6px; }
.info-line:last-child { margin-bottom: 0; }
.info-contact {
  display: flex; align-items: center; gap: 14px;
  font-size: 16px; color: var(--fg); padding: 7px 0;
  transition: color .3s var(--ease);
}
.info-contact:hover { color: var(--gold); }
.info-contact span:last-child { white-space: nowrap; }
.info-contact .ic { color: var(--gold); flex: none; display: grid; place-items: center; }
.info-contact .ic svg { width: 18px; height: 18px; }

.info-divider { height: 1px; background: var(--line); margin: 6px 0 26px; }

.contacto__cta { margin-top: auto; }
.contacto__cta h3 {
  font-family: var(--sans); font-weight: 500; font-size: 16px;
  letter-spacing: .04em; text-transform: uppercase; margin: 0 0 8px; color: var(--fg);
}
.contacto__cta > p { color: var(--fg-mut); font-weight: 300; font-size: 14.5px; margin: 0 0 22px; line-height: 1.55; }
.btn-wa {
  display: flex; align-items: center; justify-content: center; gap: 13px;
  width: 100%;
  background: var(--wa); color: #fff;
  font-family: var(--sans); font-size: 13px; font-weight: 500;
  letter-spacing: .14em; text-transform: uppercase;
  padding: 19px 24px;
  border-radius: 14px;
  transition: background .35s var(--ease), transform .35s var(--ease), box-shadow .35s var(--ease);
}
.btn-wa svg { width: 22px; height: 22px; flex: none; }
.btn-wa:hover { background: #1fbb59; transform: translateY(-2px); box-shadow: 0 12px 28px rgba(37,211,102,.28); }

.contacto__map {
  position: relative;
  border: 1px solid var(--line);
  overflow: hidden;
  min-height: 480px;
}
.contacto__map iframe {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  border: 0;
  filter: grayscale(.12) sepia(.12) saturate(.96) contrast(1.02);
}

/* ============================================================
   FOOTER
   ============================================================ */
.footer { background: var(--bg-deep); border-top: 1px solid var(--line-soft); padding-block: clamp(56px, 8vw, 90px) 34px; }
.footer__top { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1fr; gap: 40px; }
.footer__brand img { width: 46px; height: 46px; margin-bottom: 20px; }
.footer__brand .word { font-family: var(--serif); font-weight: 600; font-size: 22px; letter-spacing: .26em; text-transform: uppercase; }
.footer__brand .sub { font-family: var(--sans); font-size: 9px; letter-spacing: .32em; color: var(--fg-dim); margin-top: 5px; }
.footer__brand p { color: var(--fg-mut); font-weight: 300; font-size: 14px; max-width: 30ch; margin: 22px 0 0; }
.footer__col h5 { font-family: var(--sans); font-size: 11px; letter-spacing: .26em; text-transform: uppercase; color: var(--gold); margin: 0 0 20px; }
.footer__col ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 12px; }
.footer__col a, .footer__col li { color: var(--fg-mut); font-size: 14px; font-weight: 300; transition: color .3s var(--ease); }
.footer__col a:hover { color: var(--gold); }
.footer__social { display: flex; gap: 12px; margin-top: 6px; }
.footer__social a {
  width: 40px; height: 40px; border: 1px solid var(--line); border-radius: 50%;
  display: grid; place-items: center; color: var(--fg-mut); transition: .35s var(--ease);
}
.footer__social a:hover { border-color: var(--gold); color: var(--gold); transform: translateY(-2px); }
.footer__social svg { width: 18px; height: 18px; }
.footer__bottom {
  margin-top: 56px; padding-top: 26px; border-top: 1px solid var(--line-soft);
  display: flex; flex-wrap: wrap; gap: 14px; justify-content: space-between;
  font-family: var(--mono); font-size: 11px; letter-spacing: .06em; color: var(--fg-dim);
}

/* ============================================================
   FLOATING WHATSAPP
   ============================================================ */
.wa-float {
  position: fixed; right: 22px; bottom: 22px; z-index: 80;
  display: flex; align-items: center; gap: 0;
  background: var(--wa); color: #fff;
  border-radius: 40px;
  padding: 14px;
  box-shadow: 0 10px 30px rgba(0,0,0,.4), 0 4px 14px rgba(37,211,102,.35);
  transition: transform .4s var(--ease), padding .4s var(--ease);
  overflow: hidden;
  border: 0;
  text-decoration: none;
}
.wa-float svg { width: 28px; height: 28px; flex: none; }
.wa-float .lbl {
  max-width: 0; opacity: 0; white-space: nowrap;
  font-family: var(--sans); font-size: 12px; letter-spacing: .14em; text-transform: uppercase;
  transition: max-width .45s var(--ease), opacity .45s var(--ease), margin .45s var(--ease);
}
.wa-float:hover { transform: translateY(-2px); }
.wa-float:hover .lbl { max-width: 200px; opacity: 1; margin: 0 10px 0 12px; }
@media (hover: none) { .wa-float .lbl { display: none; } }

/* ============================================================
   SCROLL REVEAL
   ============================================================ */
.reveal { opacity: 0; transform: translateY(26px); transition: opacity .9s var(--ease), transform .9s var(--ease); }
.reveal.in { opacity: 1; transform: none; }
.reveal[data-d="1"] { transition-delay: .08s; }
.reveal[data-d="2"] { transition-delay: .16s; }
.reveal[data-d="3"] { transition-delay: .24s; }
.reveal[data-d="4"] { transition-delay: .32s; }
@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; transition: none; }
  html { scroll-behavior: auto; }
}

/* ============================================================
   MOBILE MENU
   ============================================================ */
.mobile-menu {
  position: fixed; inset: 0; z-index: 95;
  background: rgba(244,239,230,.97);
  -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px);
  display: flex; flex-direction: column; justify-content: center; align-items: center; gap: 6px;
  opacity: 0; pointer-events: none; transition: opacity .4s var(--ease);
}
.mobile-menu.open { opacity: 1; pointer-events: auto; }
.mobile-menu a {
  font-family: var(--serif); font-size: 30px; text-transform: uppercase; letter-spacing: .04em;
  color: var(--fg); padding: 12px;
}
.mobile-menu a .g { color: var(--gold); }
.mobile-menu .close { position: absolute; top: 26px; right: 26px; background: none; border: 0; color: var(--fg); font-size: 30px; cursor: pointer; }

/* ============================================================
   COTIZADOR
   ============================================================ */
.cz { position: fixed; inset: 0; z-index: 1200; display: none; }
.cz.is-open { display: block; }
.cz__backdrop { position: absolute; inset: 0; background: rgba(28,23,18,.6); -webkit-backdrop-filter: blur(5px); backdrop-filter: blur(5px); animation: czFade .3s var(--ease); }
@keyframes czFade { from { opacity: 0; } }
.cz__panel {
  position: absolute; right: 22px; bottom: 22px;
  width: min(400px, calc(100vw - 32px));
  height: min(640px, calc(100vh - 44px));
  display: flex; flex-direction: column;
  background: var(--bg); border: 1px solid var(--line);
  box-shadow: 0 30px 80px rgba(28,23,18,.4);
  border-radius: 20px;
  overflow: hidden; animation: czRise .4s var(--ease);
}
@keyframes czRise { from { opacity: 0; transform: translateY(24px) scale(.98); } }
@media (max-width: 520px) {
  .cz__panel { inset: 0; width: 100%; height: 100%; right: 0; bottom: 0; border-radius: 0; }
}

.cz__head { display: flex; align-items: center; gap: 12px; padding: 16px 18px; background: var(--cz-head); color: #fff; flex: none; }
.cz__avatar { width: 40px; height: 40px; border-radius: 50%; background: rgba(255,255,255,.16); display: grid; place-items: center; flex: none; }
.cz__avatar img { width: 24px; height: 24px; object-fit: contain; filter: brightness(0) invert(1); border-radius: 0; }
.cz__id { display: flex; flex-direction: column; line-height: 1.25; margin-right: auto; }
.cz__id b { font-family: var(--sans); font-weight: 600; font-size: 14.5px; letter-spacing: .02em; }
.cz__id span { font-size: 11.5px; opacity: .85; display: flex; align-items: center; gap: 6px; }
.cz__id span::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: #b9f6ca; box-shadow: 0 0 0 0 rgba(185,246,202,.7); animation: czPulse 2s infinite; }
@keyframes czPulse { 0% { box-shadow: 0 0 0 0 rgba(185,246,202,.6); } 70% { box-shadow: 0 0 0 6px rgba(185,246,202,0); } 100% { box-shadow: 0 0 0 0 rgba(185,246,202,0); } }
.cz__close { width: 32px; height: 32px; border: 0; background: rgba(255,255,255,.16); color: #fff; border-radius: 50%; cursor: pointer; font-size: 20px; line-height: 1; display: grid; place-items: center; transition: background .25s; }
.cz__close:hover { background: rgba(255,255,255,.3); }
.cz__restart-top { width: 32px; height: 32px; border: 0; background: rgba(255,255,255,.16); color: #fff; border-radius: 50%; cursor: pointer; display: grid; place-items: center; transition: background .25s; }
.cz__restart-top svg { width: 16px; height: 16px; transition: transform .6s var(--ease); }
.cz__restart-top:hover { background: rgba(255,255,255,.3); }
.cz__restart-top:hover svg { transform: rotate(-360deg); }

.cz__body {
  flex: 1; overflow-y: auto; padding: 20px 16px;
  display: flex; flex-direction: column; gap: 10px;
  background-color: #ece4d6;
  background-image: radial-gradient(rgba(54,42,30,.05) 1px, transparent 1px);
  background-size: 18px 18px;
}
.cz__msg { max-width: 80%; padding: 10px 14px; font-size: 14px; line-height: 1.5; position: relative; animation: czPop .3s var(--ease); }
@keyframes czPop { from { opacity: 0; transform: translateY(8px); } }
.cz__msg--bot { align-self: flex-start; background: #fff; color: var(--fg); border-radius: 2px 14px 14px 14px; box-shadow: 0 1px 2px rgba(28,23,18,.08); }
.cz__msg--me { align-self: flex-end; background: #d6f3c4; color: #1f3d18; border-radius: 14px 2px 14px 14px; }
.cz__msg--summary { background: #fff; max-width: 90%; border-radius: 2px 14px 14px 14px; box-shadow: 0 1px 2px rgba(28,23,18,.08); padding: 16px 16px 14px; align-self: flex-start; }
.cz__msg--summary h4 { font-family: var(--sans); font-size: 12px; letter-spacing: .12em; text-transform: uppercase; color: var(--gold-deep); margin: 0 0 10px; }
.cz__sumrow { display: flex; gap: 8px; font-size: 13.5px; line-height: 1.4; padding: 5px 0; border-top: 1px solid var(--line-soft); }
.cz__sumrow:first-of-type { border-top: 0; }
.cz__sumrow .k { color: var(--fg-mut); flex: 0 0 86px; }
.cz__sumrow .v { color: var(--fg); font-weight: 500; }

.cz__typing { align-self: flex-start; background: #fff; border-radius: 2px 14px 14px 14px; padding: 12px 16px; display: inline-flex; gap: 4px; box-shadow: 0 1px 2px rgba(28,23,18,.08); }
.cz__typing span { width: 7px; height: 7px; border-radius: 50%; background: var(--fg-mut); opacity: .5; animation: czBounce 1.2s infinite; }
.cz__typing span:nth-child(2) { animation-delay: .2s; }
.cz__typing span:nth-child(3) { animation-delay: .4s; }
@keyframes czBounce { 0%, 60%, 100% { transform: translateY(0); opacity: .4; } 30% { transform: translateY(-5px); opacity: 1; } }

.cz__foot { flex: none; padding: 12px; border-top: 1px solid var(--line-soft); background: var(--bg); }
.cz__chips { display: flex; flex-wrap: wrap; gap: 8px; }
.cz__chip {
  appearance: none; border: 1px solid var(--gold); background: transparent; color: var(--gold-deep);
  font-family: var(--sans); font-size: 13px; font-weight: 500; letter-spacing: .01em;
  padding: 9px 14px; border-radius: 30px; cursor: pointer;
  transition: background .2s var(--ease), color .2s var(--ease), transform .15s var(--ease);
}
.cz__chip:hover { background: var(--gold); color: #fff; transform: translateY(-1px); }
.cz__inputrow { display: flex; gap: 8px; align-items: flex-end; }
.cz__inputrow textarea {
  flex: 1; resize: none; border: 1px solid var(--line); background: #fff; color: var(--fg);
  font-family: var(--sans); font-size: 14px; line-height: 1.4; padding: 11px 13px; border-radius: 20px;
  max-height: 110px; min-height: 42px; outline: none; transition: border-color .25s;
}
.cz__inputrow textarea:focus { border-color: var(--gold); }
.cz__send {
  flex: none; width: 42px; height: 42px; border: 0; border-radius: 50%; background: var(--wa); color: #fff;
  cursor: pointer; display: grid; place-items: center; transition: filter .2s, transform .15s;
}
.cz__send:hover { filter: brightness(1.07); transform: translateY(-1px); }
.cz__send:disabled { opacity: .4; cursor: default; transform: none; }
.cz__send svg { width: 20px; height: 20px; }

.cz__final { display: flex; flex-direction: column; gap: 9px; }
.cz__wa {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  background: var(--wa); color: #fff; text-decoration: none;
  font-family: var(--sans); font-size: 14.5px; font-weight: 500; letter-spacing: .02em;
  padding: 13px 18px; border-radius: 26px; transition: filter .2s, transform .15s;
}
.cz__wa:hover { filter: brightness(1.07); transform: translateY(-1px); }
.cz__wa svg { width: 19px; height: 19px; }
.cz__restart {
  appearance: none; border: 0; background: transparent; color: var(--fg-mut);
  font-family: var(--sans); font-size: 12.5px; letter-spacing: .02em; cursor: pointer; padding: 6px 4px;
  display: inline-flex; align-items: center; justify-content: center; gap: 7px;
}
.cz__restart svg { width: 15px; height: 15px; transition: transform .6s var(--ease); }
.cz__restart:hover { color: var(--fg); }
.cz__restart:hover svg { transform: rotate(-360deg); }

/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (max-width: 1080px) {
  .steps { grid-template-columns: repeat(2, 1fr); }
  .step:nth-child(odd) { border-left: 0; padding-left: 0; }
  .step:nth-child(even) .step__dot { left: 26px; }
}
@media (max-height: 720px) {
  .scroll-ind { display: none; }
}
@media (max-width: 1024px) {
  .nav__links, .nav__right .btn { display: none; }
  .nav__burger { display: flex; }
  .nosotros__grid { grid-template-columns: 1fr; }
  .contacto__grid { grid-template-columns: 1fr; }
  .contacto__map { min-height: 400px; order: -1; }
  .nosotros__media { max-width: 460px; }
  .footer__top { grid-template-columns: 1fr 1fr; gap: 36px; }
  .footer__brand { grid-column: 1 / -1; }
  .cat-grid { gap: 16px; }
  .cat-card { flex-basis: calc((100% - 16px) / 2); }
  .proj-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 640px) {
  body { font-size: 16px; }
  .nav__right { gap: 12px; }
  .wa-circle { width: 38px; height: 38px; }
  .wa-circle svg { width: 19px; height: 19px; }
  .steps { grid-template-columns: 1fr; }
  .step { border-left: 0 !important; padding-left: 0 !important; }
  .step .step__dot { left: 0 !important; }
  .quad { grid-template-columns: 1fr; }
  .cat-grid { gap: 14px; }
  .cat-card { flex-basis: 100%; aspect-ratio: 16/10; }
  .proj-grid { grid-template-columns: 1fr; }
  .footer__top { grid-template-columns: 1fr; }
  .footer__bottom { flex-direction: column; }
  .proceso__head { gap: 18px; }
}
