/* ==========================================================================
   ATTDIV LLC - ARCHITECTURAL LUXURY DESIGN SYSTEM
   Template: Inspired by Constructora García (Ultra-Modern, Dark Luxury, Precision)
   Brand Palette: Walnut Bronze, Travertine Beige, Stone Taupe, Deep Obsidian
   Typography: Bebas Neue, Barlow Condensed, Barlow, JetBrains Mono
   Refined Balanced Scale: Editorial Luxury on Desktop & Rock-Solid on Mobile
   ========================================================================== */

/* --------------------------------------------------------------------------
   1. GOOGLE FONTS IMPORT
   -------------------------------------------------------------------------- */
@import url('https://fonts.googleapis.com/css2?family=Barlow+Condensed:ital,wght@0,300;0,400;0,500;0,600;0,700;1,400&family=Barlow:ital,wght@0,300;0,400;0,500;0,600;1,300&family=Bebas+Neue&family=JetBrains+Mono:wght@400;500;600&display=swap');

/* --------------------------------------------------------------------------
   2. CSS TOKENS & ATTDIV COLOR PALETTE
   -------------------------------------------------------------------------- */
:root {
  /* Constructora Luxury Obsidian Canvas */
  --black:     #080808;
  --dark:      #0e0e0e;
  --dark2:     #151515;
  --dark3:     #1e1e1e;
  --dark-card: #121212;

  /* Typography / Light Tokens */
  --white:     #f5f2ed;
  --white-pure:#ffffff;
  --sand-lt:   #e8ded2;
  --sand:      #c7b199;
  --sand-dark: #a8947d;
  --taupe:     #736356;
  --gray-lt:   #b0aba4;
  --gray:      #6e6b67;
  --gray-dk:   #2a2826;

  /* Brand Walnut & Bronze Accents */
  --bronze:    #af6525;
  --bronze-dk: #8a4f1d;
  --walnut:    #603814;
  --bronze-glow: rgba(175, 101, 37, 0.28);

  /* Lines & Borders */
  --border-subtle: rgba(255, 255, 255, 0.07);
  --border-medium: rgba(255, 255, 255, 0.14);
  --border-bright: rgba(255, 255, 255, 0.28);
  --border-bronze: rgba(175, 101, 37, 0.35);

  /* Structure & Motion */
  --ease: cubic-bezier(.16, 1, .3, 1);
  --nav-h: 64px;
}

/* --------------------------------------------------------------------------
   3. STRICT RESET & ZERO HORIZONTAL OVERFLOW
   -------------------------------------------------------------------------- */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  font-size: 16px;
  overflow-x: hidden !important;
  width: 100%;
  max-width: 100vw;
}

body {
  background-color: var(--black);
  color: var(--white);
  font-family: 'Barlow', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  font-weight: 300;
  line-height: 1.65;
  overflow-x: hidden !important;
  width: 100%;
  max-width: 100vw;
  position: relative;
  cursor: none; /* Replaced by dual custom cursor on pointer devices */
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* Subtle architectural noise texture */
body::before {
  content: '';
  position: fixed;
  inset: 0;
  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='.85' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  opacity: .018;
  pointer-events: none;
  z-index: 9998;
}

::selection {
  background: var(--bronze);
  color: var(--white-pure);
}

img, picture, video, canvas, svg {
  display: block;
  max-width: 100%;
}

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

button, input, select, textarea {
  font: inherit;
}

/* Centralized Max-Width Container for Desktop Balance */
.hcont, .ab-grid, .sv-hd, .sv-grid, .sim-hd, .sim-viewport, .pr-grid, .pj-hd, .pj-grid, .vm-grid, .ct-grid, .ft-grid, .ft-bot {
  max-width: 1200px;
  margin-left: auto;
  margin-right: auto;
  width: 100%;
}

/* --------------------------------------------------------------------------
   4. CONSTRUCTORA GARCÍA DUAL MOUSE CURSOR
   -------------------------------------------------------------------------- */
#cur {
  width: 7px;
  height: 7px;
  background: var(--sand);
  border-radius: 50%;
  position: fixed;
  top: 0;
  left: 0;
  pointer-events: none;
  z-index: 9999;
  transform: translate(-100px, -100px);
}

#cring {
  width: 30px;
  height: 30px;
  border: 1px solid rgba(199, 177, 153, 0.6);
  border-radius: 50%;
  position: fixed;
  top: 0;
  left: 0;
  pointer-events: none;
  z-index: 9997;
  opacity: .6;
  transition: opacity .25s ease, transform .08s linear, border-color .25s ease;
  transform: translate(-100px, -100px);
}

#cring.hov {
  opacity: .2;
  transform: scale(1.5);
  border-color: var(--sand-lt);
}

@media (hover: none) or (pointer: coarse) {
  #cur, #cring { display: none !important; }
  body { cursor: auto !important; }
}

/* --------------------------------------------------------------------------
   5. NAVIGATION (Fixed Dark Glass Header)
   -------------------------------------------------------------------------- */
#nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: var(--nav-h);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 5vw;
  background: rgba(8, 8, 8, 0.92);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--border-subtle);
  z-index: 1000;
  transition: background .3s ease, box-shadow .3s ease, border-color .3s ease;
}

#nav.sc {
  background: rgba(8, 8, 8, 0.98);
  box-shadow: 0 4px 24px rgba(0, 0, 0, 0.45);
  border-bottom-color: var(--border-medium);
}

#nav .logo {
  display: flex;
  align-items: center;
  text-decoration: none;
  flex-shrink: 0;
}

#nav .logo img {
  height: 32px;
  width: auto;
  display: block;
  transition: opacity .3s ease;
}

#nav .logo:hover img {
  opacity: .75;
}

#nav ul {
  display: flex;
  gap: 28px;
  list-style: none;
}

#nav ul a {
  font-family: 'Barlow Condensed', sans-serif;
  font-size: 12.5px;
  font-weight: 600;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--gray-lt);
  text-decoration: none;
  position: relative;
  transition: color .3s ease;
}

#nav ul a::after {
  content: '';
  position: absolute;
  bottom: -4px;
  left: 0;
  width: 0;
  height: 1px;
  background: var(--sand);
  transition: width .3s ease;
}

#nav ul a:hover {
  color: var(--white);
}

#nav ul a:hover::after {
  width: 100%;
}

#nav .nav-actions {
  display: flex;
  align-items: center;
  gap: 14px;
}

#nav .cta {
  font-family: 'Barlow Condensed', sans-serif;
  font-size: 11.5px;
  font-weight: 700;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--black);
  background: var(--sand);
  padding: 8px 18px;
  text-decoration: none;
  white-space: nowrap;
  transition: background .3s ease, transform .3s ease;
}

#nav .cta:hover {
  background: var(--white);
  transform: translateY(-1px);
}

/* Hamburger button */
#hbg {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 6px;
}

#hbg span {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--white);
  transition: all .3s ease;
}

@media (max-width: 960px) {
  #nav ul, #nav .cta { display: none; }
  #hbg { display: flex; }
}

/* Fullscreen Mobile Overlay Menu */
#mob {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(8, 8, 8, 0.98);
  backdrop-filter: blur(20px);
  z-index: 1100;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 26px;
  padding: 40px 20px;
}

#mob.open {
  display: flex;
}

#mob a {
  font-family: 'Bebas Neue', sans-serif;
  font-size: clamp(32px, 8vw, 48px);
  color: var(--white);
  text-decoration: none;
  letter-spacing: .04em;
  transition: color .3s ease, opacity .3s ease;
}

#mob a:hover {
  color: var(--sand);
}

#mob .mx {
  position: absolute;
  top: 22px;
  right: 5vw;
  font-size: 34px;
  color: var(--gray-lt);
  background: none;
  border: none;
  cursor: pointer;
  line-height: 1;
}

#mob .mob-meta {
  margin-top: 24px;
  text-align: center;
  font-size: 12.5px;
  color: var(--gray);
  font-family: 'Barlow Condensed', sans-serif;
  letter-spacing: .12em;
  text-transform: uppercase;
}

/* --------------------------------------------------------------------------
   6. HERO SECTION (Refined Proportions on Desktop - NO Cintillo)
   -------------------------------------------------------------------------- */
#hero {
  position: relative;
  min-height: 100svh;
  display: flex;
  align-items: flex-end;
  overflow: hidden;
  padding-top: var(--nav-h);
  padding-bottom: 0;
}

.hbg-img {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(to bottom, rgba(8,8,8,.2) 0%, rgba(8,8,8,.5) 55%, rgba(8,8,8,.98) 100%),
    url('../img/3d-rendering-house-model.jpg') center 35% / cover no-repeat;
  transform: scale(1.05);
  transition: transform 12s linear;
  z-index: 0;
}

#hero.go .hbg-img {
  transform: scale(1);
}

.hline {
  position: absolute;
  top: 0;
  left: 14%;
  width: 1px;
  height: 0;
  background: linear-gradient(to bottom, transparent, rgba(199, 177, 153, 0.4), transparent);
  animation: hla 2s .7s var(--ease) forwards;
  z-index: 1;
}

@keyframes hla {
  to { height: 100%; }
}

.hcont {
  position: relative;
  z-index: 2;
  padding: 0 5vw 7.5vh;
}

.htag {
  font-family: 'Barlow Condensed', sans-serif;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: .3em;
  text-transform: uppercase;
  color: var(--sand);
  margin-bottom: 14px;
  display: flex;
  align-items: center;
  gap: 10px;
  opacity: 0;
  animation: fu .8s .4s forwards;
}

.htag::before {
  content: '';
  display: block;
  width: 22px;
  height: 1px;
  background: var(--sand);
}

/* Scaled for refined architectural elegance (not oversized on desktop) */
.htitle {
  font-family: 'Bebas Neue', sans-serif;
  font-size: clamp(40px, 5.2vw, 84px);
  line-height: .92;
  letter-spacing: -.01em;
  color: var(--white);
  margin-bottom: 20px;
  overflow: hidden;
}

.htitle span {
  display: block;
  opacity: 0;
  transform: translateY(105%);
}

.htitle span:nth-child(1) { animation: su .9s .25s var(--ease) forwards; }
.htitle span:nth-child(2) { animation: su .9s .42s var(--ease) forwards; color: var(--sand); }
.htitle span:nth-child(3) { animation: su .9s .59s var(--ease) forwards; }

@keyframes su {
  to { opacity: 1; transform: translateY(0); }
}

@keyframes fu {
  to { opacity: 1; transform: translateY(0); }
}

.hsub {
  font-size: 14.5px;
  font-weight: 300;
  color: var(--gray-lt);
  max-width: 440px;
  line-height: 1.7;
  opacity: 0;
  animation: fu .8s .9s forwards;
}

.hbtns {
  display: flex;
  gap: 12px;
  margin-top: 26px;
  flex-wrap: wrap;
  opacity: 0;
  animation: fu .8s 1.1s forwards;
}

/* Buttons */
.btn-w {
  font-family: 'Barlow Condensed', sans-serif;
  font-size: 11.5px;
  font-weight: 700;
  letter-spacing: .15em;
  text-transform: uppercase;
  color: var(--black);
  background: var(--sand);
  padding: 12px 28px;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  transition: opacity .3s ease, transform .3s ease, background .3s ease;
}

.btn-w:hover {
  background: var(--white);
  transform: translateY(-2px);
}

.btn-g {
  font-family: 'Barlow Condensed', sans-serif;
  font-size: 11.5px;
  font-weight: 700;
  letter-spacing: .15em;
  text-transform: uppercase;
  color: var(--white);
  border: 1px solid var(--border-bright);
  padding: 12px 28px;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  transition: all .3s ease;
}

.btn-g:hover {
  border-color: var(--sand);
  color: var(--sand);
  transform: translateY(-2px);
}

/* Floating Hero Stats Box */
.hstats {
  position: absolute;
  bottom: 0;
  right: 0;
  display: flex;
  opacity: 0;
  animation: fu .8s 1.4s forwards;
  z-index: 2;
}

.hstat {
  padding: 16px 24px;
  min-width: 100px;
  text-align: center;
  background: rgba(8, 8, 8, 0.72);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-top: 1px solid var(--border-medium);
  border-left: 1px solid var(--border-subtle);
}

.hstat-n {
  font-family: 'Bebas Neue', sans-serif;
  font-size: 30px;
  color: var(--sand);
  display: block;
  line-height: 1;
}

.hstat-l {
  font-family: 'Barlow Condensed', sans-serif;
  font-size: 9px;
  letter-spacing: .18em;
  text-transform: uppercase;
  color: var(--gray-lt);
  display: block;
  margin-top: 3px;
}

/* Hero Scroll Indicator */
.scri {
  position: absolute;
  bottom: 22px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  opacity: 0;
  animation: fu 1s 1.8s forwards;
  z-index: 2;
}

.scri span {
  font-family: 'Barlow Condensed', sans-serif;
  font-size: 8.5px;
  letter-spacing: .26em;
  text-transform: uppercase;
  color: var(--gray);
}

.scrln {
  width: 1px;
  height: 36px;
  background: linear-gradient(to bottom, var(--sand), transparent);
  animation: scp 2s ease-in-out infinite;
}

@keyframes scp {
  0%, 100% { opacity: .3; transform: scaleY(.7); }
  50% { opacity: 1; transform: scaleY(1); }
}

@media (max-width: 768px) {
  .hstats { display: none; }
  .scri { display: none; }
  .hline { left: 8%; }
  .hcont { padding: 0 6vw 7vh; }
  .hbtns { flex-direction: column; gap: 10px; width: 100%; }
  .btn-w, .btn-g { width: 100%; justify-content: center; text-align: center; }
}

/* --------------------------------------------------------------------------
   7. MARQUEE TICKER (Repositioned Online & USA Service Strip)
   -------------------------------------------------------------------------- */
.marquee {
  background: var(--dark2);
  border-top: 1px solid var(--border-subtle);
  border-bottom: 1px solid var(--border-subtle);
  padding: 13px 0;
  overflow: hidden;
  white-space: nowrap;
  position: relative;
  z-index: 10;
}

.marquee-inner {
  display: inline-flex;
  animation: mq 28s linear infinite;
}

.marquee-inner span {
  font-family: 'Bebas Neue', sans-serif;
  font-size: 15px;
  letter-spacing: .12em;
  color: rgba(245, 242, 237, 0.6);
  padding: 0 28px;
  display: inline-flex;
  align-items: center;
  gap: 28px;
}

.mdot {
  display: inline-block;
  width: 4px;
  height: 4px;
  background: var(--bronze);
  border-radius: 50%;
}

@keyframes mq {
  from { transform: translateX(0); }
  to { transform: translateX(-50%); }
}

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

/* --------------------------------------------------------------------------
   8. SHARED SECTION STYLES & SCROLL REVEAL
   -------------------------------------------------------------------------- */
section {
  padding: clamp(56px, 7vw, 96px) 5vw;
  position: relative;
}

.stag {
  font-family: 'Barlow Condensed', sans-serif;
  font-size: 10.5px;
  font-weight: 600;
  letter-spacing: .32em;
  text-transform: uppercase;
  color: var(--sand);
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 14px;
}

.stag::before {
  content: '';
  display: block;
  width: 22px;
  height: 1px;
  background: var(--sand);
}

/* Proportionate Section Headings */
.stitle {
  font-family: 'Bebas Neue', sans-serif;
  font-size: clamp(30px, 3.8vw, 56px);
  line-height: .95;
  letter-spacing: -.01em;
  color: var(--white);
}

.stitle span.accent {
  color: var(--sand);
}

/* Scroll reveal classes */
.rv {
  opacity: 0;
  transform: translateY(32px);
  transition: opacity .85s var(--ease), transform .85s var(--ease);
}

.rv.v {
  opacity: 1;
  transform: translateY(0);
}

.d1 { transition-delay: .1s; }
.d2 { transition-delay: .2s; }
.d3 { transition-delay: .32s; }
.d4 { transition-delay: .44s; }

/* --------------------------------------------------------------------------
   9. NOSOTROS SECTION (Refined Watermark & Proportions)
   -------------------------------------------------------------------------- */
#nosotros {
  background: var(--dark);
  position: relative;
  overflow: hidden;
}

#nosotros::before {
  content: 'ATTDIV';
  position: absolute;
  right: 1%;
  bottom: -4%;
  font-family: 'Bebas Neue', sans-serif;
  font-size: clamp(70px, 12vw, 170px);
  color: rgba(255, 255, 255, 0.015);
  white-space: nowrap;
  pointer-events: none;
  user-select: none;
  line-height: 1;
}

.ab-grid {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: clamp(36px, 5vw, 64px);
  align-items: center;
}

.ab-body {
  font-size: 14.5px;
  color: var(--gray-lt);
  line-height: 1.8;
  max-width: 480px;
  margin-top: 20px;
}

.ab-body p + p {
  margin-top: 12px;
}

.ab-vals {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2px;
  margin-top: 32px;
}

.val {
  padding: 15px 18px;
  background: var(--dark2);
  border-top: 1px solid var(--border-subtle);
  transition: border-color .3s, background .3s;
}

.val:hover {
  background: var(--dark3);
  border-color: var(--sand);
}

.val-ic {
  font-size: 18px;
  margin-bottom: 6px;
  display: block;
}

.val-tt {
  font-family: 'Barlow Condensed', sans-serif;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--white);
}

.val-ds {
  font-size: 11.5px;
  color: var(--gray);
  margin-top: 3px;
  line-height: 1.45;
}

/* Image column with Constructora offset frame */
.ab-imgcol {
  position: relative;
}

.ab-imgwrap {
  position: relative;
  overflow: hidden;
  aspect-ratio: 4 / 4.8;
  background: var(--dark2);
}

.ab-imgwrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center top;
  filter: grayscale(15%);
  transition: transform .8s var(--ease), filter .8s var(--ease);
}

.ab-imgwrap:hover img {
  transform: scale(1.04);
  filter: grayscale(0%);
}

.ab-imggrad {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 40%;
  background: linear-gradient(to top, rgba(8, 8, 8, 0.7), transparent);
}

.ab-frame {
  position: absolute;
  top: -14px;
  right: -14px;
  width: 48%;
  height: 36%;
  border: 1px solid var(--border-medium);
  pointer-events: none;
}

.ab-badge {
  position: absolute;
  bottom: 20px;
  left: -18px;
  background: var(--sand);
  color: var(--black);
  padding: 14px 18px;
  font-family: 'Barlow Condensed', sans-serif;
  font-size: 10.5px;
  text-transform: uppercase;
  letter-spacing: .1em;
  line-height: 1.35;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.4);
}

.ab-badge strong {
  display: block;
  font-family: 'Bebas Neue', sans-serif;
  font-size: 34px;
  line-height: 1;
}

@media (max-width: 860px) {
  .ab-grid { grid-template-columns: 1fr; gap: 40px; }
  .ab-frame { display: none; }
  .ab-badge { left: 0; bottom: -14px; }
}

/* --------------------------------------------------------------------------
   10. SERVICIOS 3D (Refined Proportions)
   -------------------------------------------------------------------------- */
#servicios {
  background: var(--black);
}

.sv-hd {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  margin-bottom: 42px;
  gap: 24px;
  flex-wrap: wrap;
}

.sv-sub {
  font-size: 13.5px;
  color: var(--gray-lt);
  max-width: 360px;
  line-height: 1.68;
}

.sv-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(290px, 1fr));
  gap: 2px;
  background: var(--border-subtle);
}

.sv {
  position: relative;
  padding: 36px 28px 32px;
  background: var(--dark);
  overflow: hidden;
  transition: background .4s ease;
  cursor: default;
  display: flex;
  flex-direction: column;
}

.sv::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0;
  height: 2px;
  background: var(--sand);
  transition: width .5s var(--ease);
}

.sv:hover {
  background: var(--dark2);
}

.sv:hover::after {
  width: 100%;
}

.sv-num {
  font-family: 'Bebas Neue', sans-serif;
  font-size: 50px;
  color: rgba(255, 255, 255, 0.05);
  position: absolute;
  top: 10px;
  right: 18px;
  line-height: 1;
  transition: color .4s ease, transform .4s ease;
  pointer-events: none;
}

.sv:hover .sv-num {
  color: rgba(199, 177, 153, 0.16);
  transform: translateY(-2px);
}

.sv-ic {
  margin-bottom: 18px;
}

.sv-ic svg {
  width: 32px;
  height: 32px;
  stroke: var(--sand);
  fill: none;
  stroke-width: 1.4;
  stroke-linecap: round;
  stroke-linejoin: round;
  transition: transform .4s ease, stroke .3s ease;
}

.sv:hover .sv-ic svg {
  transform: scale(1.08);
  stroke: var(--white);
}

.sv-tt {
  font-family: 'Barlow Condensed', sans-serif;
  font-size: 19px;
  font-weight: 700;
  letter-spacing: .04em;
  text-transform: uppercase;
  margin-bottom: 10px;
  color: var(--white);
}

.sv-ds {
  font-size: 13px;
  color: var(--gray-lt);
  line-height: 1.68;
  margin-bottom: 16px;
}

.sv-items {
  list-style: none;
  margin-top: auto;
  padding-top: 14px;
  border-top: 1px solid var(--border-subtle);
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.sv-items li {
  font-size: 12px;
  color: var(--gray-lt);
  display: flex;
  align-items: flex-start;
  gap: 9px;
  line-height: 1.45;
}

.sv-items li svg {
  width: 13px;
  height: 13px;
  stroke: var(--sand);
  fill: none;
  stroke-width: 2;
  flex-shrink: 0;
  margin-top: 2px;
}

.sv-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
  margin-top: 18px;
}

.sv-tag {
  font-family: 'Barlow Condensed', sans-serif;
  font-size: 9.5px;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--sand-lt);
  border: 1px solid var(--border-medium);
  padding: 2.5px 7px;
  background: rgba(255, 255, 255, 0.02);
}

/* --------------------------------------------------------------------------
   11. SIMULADOR INTERACTIVO 3D (CAD VS RENDER 3D - Zero Shift & Touch Safe)
   -------------------------------------------------------------------------- */
#simulador {
  background: var(--dark);
  position: relative;
}

.sim-hd {
  text-align: center;
  max-width: 640px;
  margin: 0 auto 38px;
}

.sim-hd .stag {
  justify-content: center;
}

.sim-hd .stag::before {
  display: none;
}

.sim-sub {
  font-size: 13.5px;
  color: var(--gray-lt);
  margin-top: 10px;
  line-height: 1.68;
}

/* Control Pills */
.sim-controls {
  display: flex;
  justify-content: center;
  gap: 8px;
  margin-bottom: 20px;
  flex-wrap: wrap;
}

.sim-btn {
  font-family: 'Barlow Condensed', sans-serif;
  font-size: 10.5px;
  font-weight: 600;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--gray-lt);
  background: var(--dark2);
  border: 1px solid var(--border-subtle);
  padding: 7px 16px;
  cursor: pointer;
  transition: all .3s ease;
}

.sim-btn.active, .sim-btn:hover {
  background: var(--sand);
  color: var(--black);
  border-color: var(--sand);
}

/* The interactive comparison viewer box */
.sim-viewport {
  position: relative;
  width: 100%;
  max-width: 960px;
  margin: 0 auto;
  aspect-ratio: 16 / 9;
  border-radius: 4px;
  overflow: hidden;
  border: 1px solid var(--border-medium);
  box-shadow: 0 16px 48px rgba(0, 0, 0, 0.6);
  user-select: none;
  -webkit-user-select: none;
  background: #000;
}

/* Layer 1: Render 3D (Bottom Image) */
.sim-img-render {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  pointer-events: none;
}

/* Layer 2: CAD Blueprint (Top Image with clip-path) */
.sim-img-cad {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  clip-path: inset(0 calc(100% - var(--sim-pos, 50%)) 0 0);
  -webkit-clip-path: inset(0 calc(100% - var(--sim-pos, 50%)) 0 0);
  pointer-events: none;
}

/* Vertical Divider & Draggable Handle */
.sim-handle {
  position: absolute;
  top: 0;
  bottom: 0;
  left: var(--sim-pos, 50%);
  width: 2.5px;
  background: var(--white);
  transform: translateX(-50%);
  cursor: ew-resize;
  touch-action: none;
  z-index: 10;
}

.sim-knob {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 38px;
  height: 38px;
  background: var(--sand);
  border: 2px solid var(--white-pure);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.6);
  transition: transform .2s ease;
}

.sim-handle:active .sim-knob {
  transform: translate(-50%, -50%) scale(1.1);
}

.sim-knob svg {
  width: 15px;
  height: 15px;
  fill: var(--black);
}

/* Corner Labels inside simulator */
.sim-label {
  position: absolute;
  bottom: 14px;
  font-family: 'Barlow Condensed', sans-serif;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: .14em;
  text-transform: uppercase;
  padding: 5px 12px;
  background: rgba(8, 8, 8, 0.75);
  backdrop-filter: blur(8px);
  color: var(--white);
  pointer-events: none;
  z-index: 5;
  border: 1px solid var(--border-subtle);
}

.sim-label-cad { left: 14px; border-left: 2px solid var(--sand); }
.sim-label-render { right: 14px; border-right: 2px solid var(--bronze); }

@media (max-width: 640px) {
  .sim-viewport { aspect-ratio: 4 / 3; }
  .sim-knob { width: 34px; height: 34px; }
  .sim-label { font-size: 8.5px; padding: 4px 9px; bottom: 8px; }
  .sim-label-cad { left: 8px; }
  .sim-label-render { right: 8px; }
}

/* --------------------------------------------------------------------------
   12. METODOLOGÍA / PROCESO (Step Sequence Refined)
   -------------------------------------------------------------------------- */
#proceso {
  background: var(--black);
}

.pr-grid {
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: clamp(36px, 5vw, 64px);
  align-items: start;
  margin-top: 42px;
}

.pr-step {
  display: flex;
  gap: 18px;
  padding: 18px 0;
  border-bottom: 1px solid var(--border-subtle);
  transition: border-color .3s ease;
}

.pr-step:first-child {
  padding-top: 0;
}

.pr-step:hover {
  border-color: var(--border-bright);
}

.pr-n {
  font-family: 'Bebas Neue', sans-serif;
  font-size: 34px;
  color: rgba(255, 255, 255, 0.16);
  flex-shrink: 0;
  width: 38px;
  line-height: 1;
  transition: color .3s ease;
}

.pr-step:hover .pr-n {
  color: var(--sand);
}

.pr-tt {
  font-family: 'Barlow Condensed', sans-serif;
  font-size: 16.5px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .04em;
  margin-bottom: 5px;
  color: var(--white);
}

.pr-ds {
  font-size: 13px;
  color: var(--gray-lt);
  line-height: 1.68;
}

/* Highlight Column with Image */
.pr-imgcol {
  position: sticky;
  top: 90px;
}

.pr-imgwrap {
  aspect-ratio: 4 / 4.8;
  max-height: 480px;
  overflow: hidden;
  position: relative;
  background: var(--dark2);
  border: 1px solid var(--border-subtle);
}

.pr-imgwrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: grayscale(12%);
  transition: transform .7s var(--ease);
}

.pr-imgwrap:hover img {
  transform: scale(1.05);
}

.pr-imgbadge {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 18px;
  background: linear-gradient(to top, rgba(8,8,8,.92) 0%, transparent 100%);
}

.pr-imgbadge span {
  font-family: 'Barlow Condensed', sans-serif;
  font-size: 10px;
  letter-spacing: .18em;
  text-transform: uppercase;
  color: var(--sand);
  display: block;
}

.pr-imgbadge strong {
  font-family: 'Bebas Neue', sans-serif;
  font-size: 22px;
  color: var(--white);
  display: block;
  line-height: 1.1;
  margin-top: 3px;
}

@media (max-width: 860px) {
  .pr-grid { grid-template-columns: 1fr; gap: 36px; }
  .pr-imgcol { position: relative; top: 0; }
}

/* --------------------------------------------------------------------------
   13. PORTAFOLIO DE PROYECTOS (Refined Grid Height)
   -------------------------------------------------------------------------- */
#proyectos {
  background: var(--dark);
}

.pj-hd {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  margin-bottom: 40px;
  gap: 20px;
  flex-wrap: wrap;
}

.pj-grid {
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  grid-template-rows: 320px 230px;
  gap: 4px;
}

.pj {
  position: relative;
  overflow: hidden;
  cursor: pointer;
  background: var(--dark2);
}

/* Row 1: large left + portrait right */
.pj:nth-child(1) { grid-column: 1 / 8;  grid-row: 1; }
.pj:nth-child(2) { grid-column: 8 / 13; grid-row: 1; }

/* Row 2: three equal columns */
.pj:nth-child(3) { grid-column: 1 / 5;  grid-row: 2; }
.pj:nth-child(4) { grid-column: 5 / 9;  grid-row: 2; }
.pj:nth-child(5) { grid-column: 9 / 13; grid-row: 2; }

.pj img {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: grayscale(18%);
  transition: transform .75s var(--ease), filter .6s ease;
}

.pj:hover img {
  transform: scale(1.06);
  filter: grayscale(0%);
}

.pj-ov {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(8, 8, 8, 0.92) 0%, rgba(8, 8, 8, 0.2) 60%, transparent 100%);
  opacity: 0;
  transition: opacity .35s ease;
  display: flex;
  align-items: flex-end;
  padding: 20px;
}

.pj:hover .pj-ov {
  opacity: 1;
}

.pj-cat {
  font-family: 'Barlow Condensed', sans-serif;
  font-size: 10px;
  letter-spacing: .2em;
  text-transform: uppercase;
  color: var(--sand);
  display: block;
  margin-bottom: 3px;
}

.pj-nm {
  font-family: 'Barlow Condensed', sans-serif;
  font-size: 18px;
  font-weight: 700;
  text-transform: uppercase;
  color: var(--white);
  line-height: 1.2;
}

@media (max-width: 900px) {
  .pj-grid {
    grid-template-columns: 1fr 1fr;
    grid-template-rows: 280px 220px 220px;
  }
  .pj:nth-child(1) { grid-column: 1 / -1; grid-row: 1; }
  .pj:nth-child(2) { grid-column: 1 / 2;  grid-row: 2; }
  .pj:nth-child(3) { grid-column: 2 / 3;  grid-row: 2; }
  .pj:nth-child(4) { grid-column: 1 / 2;  grid-row: 3; }
  .pj:nth-child(5) { grid-column: 2 / 3;  grid-row: 3; }
}

@media (max-width: 560px) {
  .pj-grid {
    grid-template-columns: 1fr;
    grid-template-rows: repeat(5, 220px);
  }
  .pj:nth-child(n) { grid-column: 1; }
  .pj:nth-child(1) { grid-row: 1; }
  .pj:nth-child(2) { grid-row: 2; }
  .pj:nth-child(3) { grid-row: 3; }
  .pj:nth-child(4) { grid-row: 4; }
  .pj:nth-child(5) { grid-row: 5; }
  .pj-ov { opacity: 1; background: linear-gradient(to top, rgba(8, 8, 8, 0.85) 0%, transparent 70%); }
}

/* --------------------------------------------------------------------------
   14. VISIÓN & GARANTÍA TÉCNICA
   -------------------------------------------------------------------------- */
#mision {
  padding: clamp(68px, 9vw, 112px) 5vw;
  position: relative;
  overflow: hidden;
}

#mision::before {
  content: '';
  position: absolute;
  inset: 0;
  background: url('../img/port-canada.jpg') center / cover no-repeat;
  filter: brightness(.12) saturate(.25);
  z-index: 0;
}

#mision > * {
  position: relative;
  z-index: 1;
}

.vm-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4px;
  margin-top: 34px;
}

.vm {
  padding: 34px 30px;
  background: rgba(14, 14, 14, 0.72);
  border: 1px solid var(--border-medium);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
}

.vm-lb {
  font-family: 'Barlow Condensed', sans-serif;
  font-size: 10px;
  letter-spacing: .26em;
  text-transform: uppercase;
  color: var(--sand);
  margin-bottom: 10px;
  display: block;
}

.vm-tx {
  font-family: 'Barlow Condensed', sans-serif;
  font-size: clamp(16px, 1.8vw, 21px);
  font-weight: 400;
  line-height: 1.45;
  color: var(--white);
}

@media (max-width: 640px) {
  .vm-grid { grid-template-columns: 1fr; }
  .vm { padding: 26px 20px; }
}

/* --------------------------------------------------------------------------
   15. CONTACTO & FORMULARIO DIRECTO
   -------------------------------------------------------------------------- */
#contacto {
  background: var(--dark);
}

.ct-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(36px, 5vw, 64px);
  align-items: start;
  margin-top: 42px;
}

.ct-info {
  display: flex;
  flex-direction: column;
}

.ct-item {
  display: flex;
  gap: 16px;
  padding: 18px 0;
  border-bottom: 1px solid var(--border-subtle);
}

.ct-item:last-child {
  border-bottom: none;
}

.ct-icon {
  width: 38px;
  height: 38px;
  border: 1px solid var(--border-medium);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  background: var(--dark2);
}

.ct-icon svg {
  width: 16px;
  height: 16px;
  stroke: var(--sand);
  fill: none;
  stroke-width: 1.5;
}

.ct-lb {
  font-family: 'Barlow Condensed', sans-serif;
  font-size: 10px;
  letter-spacing: .2em;
  text-transform: uppercase;
  color: var(--gray);
  display: block;
  margin-bottom: 3px;
}

.ct-vl {
  font-size: 13.5px;
  color: var(--white);
  line-height: 1.55;
}

.ct-vl a {
  color: var(--white);
  transition: color .3s ease;
}

.ct-vl a:hover {
  color: var(--sand);
}

/* Form */
.ct-form {
  background: var(--dark2);
  padding: clamp(24px, 3.5vw, 36px);
  border: 1px solid var(--border-subtle);
}

.fg {
  margin-bottom: 12px;
}

.fg label {
  font-family: 'Barlow Condensed', sans-serif;
  font-size: 10.5px;
  letter-spacing: .18em;
  text-transform: uppercase;
  color: var(--gray-lt);
  display: block;
  margin-bottom: 5px;
}

.fg input, .fg textarea, .fg select {
  width: 100%;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--border-subtle);
  border-bottom: 1px solid var(--border-medium);
  color: var(--white);
  font-family: 'Barlow', sans-serif;
  font-size: 13.5px;
  font-weight: 300;
  padding: 10px 12px;
  outline: none;
  -webkit-appearance: none;
  transition: border-color .3s ease, background .3s ease;
  box-sizing: border-box;
}

.fg input:focus, .fg textarea:focus, .fg select:focus {
  border-color: var(--sand);
  background: rgba(255, 255, 255, 0.06);
}

.fg input::placeholder, .fg textarea::placeholder {
  color: var(--gray);
}

.fg textarea {
  resize: vertical;
  min-height: 90px;
}

.fg select option {
  background: var(--dark);
  color: var(--white);
}

.fg-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.btn-sub {
  font-family: 'Barlow Condensed', sans-serif;
  font-size: 11.5px;
  font-weight: 700;
  letter-spacing: .15em;
  text-transform: uppercase;
  color: var(--black);
  background: var(--sand);
  padding: 13px 30px;
  border: none;
  cursor: pointer;
  transition: opacity .3s ease, transform .3s ease, background .3s ease;
  width: 100%;
  margin-top: 8px;
}

.btn-sub:hover {
  background: var(--white);
  transform: translateY(-2px);
}

.f-note {
  font-size: 11.5px;
  color: var(--gray);
  margin-top: 10px;
  text-align: center;
}

@media (max-width: 860px) {
  .ct-grid { grid-template-columns: 1fr; gap: 36px; }
  .fg-row { grid-template-columns: 1fr; }
}

/* --------------------------------------------------------------------------
   16. FOOTER
   -------------------------------------------------------------------------- */
footer {
  background: #050505;
  padding: 60px 5vw 32px;
  border-top: 1px solid var(--border-subtle);
}

.ft-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 36px;
  margin-bottom: 44px;
}

.ft-logo {
  display: inline-block;
  margin-bottom: 14px;
}

.ft-logo img {
  height: 30px;
  width: auto;
  display: block;
}

.ft-tg {
  font-size: 13px;
  color: var(--gray-lt);
  line-height: 1.68;
  max-width: 270px;
}

.ft-col h4 {
  font-family: 'Barlow Condensed', sans-serif;
  font-size: 10.5px;
  letter-spacing: .24em;
  text-transform: uppercase;
  color: var(--sand);
  margin-bottom: 14px;
}

.ft-col ul {
  list-style: none;
}

.ft-col li {
  margin-bottom: 7px;
}

.ft-col a {
  font-size: 12.5px;
  color: var(--gray-lt);
  text-decoration: none;
  transition: color .3s ease;
}

.ft-col a:hover {
  color: var(--white);
}

.ft-bot {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: 22px;
  border-top: 1px solid rgba(255, 255, 255, 0.04);
  flex-wrap: wrap;
  gap: 12px;
}

.ft-cp {
  font-size: 11.5px;
  color: var(--gray);
}

.ft-leg {
  display: flex;
  gap: 18px;
}

.ft-leg a {
  font-size: 11.5px;
  color: var(--gray);
  text-decoration: none;
  transition: color .3s ease;
}

.ft-leg a:hover {
  color: var(--white);
}

@media (max-width: 900px) {
  .ft-grid { grid-template-columns: 1fr 1fr; gap: 32px; }
}

@media (max-width: 540px) {
  .ft-grid { grid-template-columns: 1fr; gap: 28px; }
}

/* --------------------------------------------------------------------------
   17. MOBILE FLOATING ACTION BAR (Fixed & Padding Protection)
   -------------------------------------------------------------------------- */
.mob-bar {
  display: none;
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  height: 60px;
  background: rgba(8, 8, 8, 0.96);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-top: 1px solid var(--border-medium);
  z-index: 950;
  padding: 0 14px;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  box-shadow: 0 -4px 20px rgba(0, 0, 0, 0.5);
}

.mob-bar-btn {
  flex: 1;
  height: 40px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  font-family: 'Barlow Condensed', sans-serif;
  font-size: 11.5px;
  font-weight: 700;
  letter-spacing: .12em;
  text-transform: uppercase;
  text-decoration: none;
  padding: 0 10px;
  white-space: nowrap;
}

.mob-bar-mail {
  background: var(--dark3);
  color: var(--white);
  border: 1px solid var(--border-medium);
}

.mob-bar-cta {
  background: var(--sand);
  color: var(--black);
}

@media (max-width: 768px) {
  body {
    /* Critical: Ensures bottom bar NEVER covers content or footer text */
    padding-bottom: 74px !important;
  }
  .mob-bar {
    display: flex;
  }
  section {
    padding: 56px 6vw;
  }
  footer {
    padding: 50px 6vw 28px;
  }
}
