@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@300;400;500;600;700;800&family=Plus+Jakarta+Sans:ital,wght@0,300;0,400;0,500;0,600;0,700;0,800;1,400&display=swap');

/* ==========================================================================
   VARIABLES & DESIGN SYSTEM
   ========================================================================== */
:root {
  /* Colors */
  --primary-dark: #0B2545;
  --primary-medium: #134074;
  --accent-blue: #00B4D8;
  --accent-light: #8DA9C4;
  --accent-sand: #E07A5F;
  --accent-gold: #D4A373;
  --bg-light: #F8F9FA;
  --bg-dark: #061121;
  --text-dark: #1E293B;
  --text-light: #F8FAFC;
  --text-muted: #64748B;
  --glass-bg: rgba(255, 255, 255, 0.75);
  --glass-border: rgba(255, 255, 255, 0.2);
  --glass-shadow: rgba(0, 0, 0, 0.06);

  /* Fonts */
  --font-headings: 'Outfit', sans-serif;
  --font-body: 'Plus Jakarta Sans', sans-serif;

  /* Layout & Transitions */
  --max-width: 1200px;
  --header-height: 90px;
  --header-height-shrunk: 70px;
  --border-radius-sm: 8px;
  --border-radius-md: 16px;
  --border-radius-lg: 24px;
  --transition-smooth: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
  --transition-fast: all 0.2s ease;
  
  /* Fallback scroll progress (updated by JS) */
  --scroll-progress: 0;
}

/* Dark theme elements */
[data-theme="dark"] {
  --text-dark: #F8FAFC;
  --bg-light: #061121;
  --glass-bg: rgba(6, 17, 33, 0.75);
  --glass-border: rgba(255, 255, 255, 0.08);
}

/* ==========================================================================
   RESETS & GLOBAL STYLES
   ========================================================================== */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  font-size: 16px;
  background-color: var(--bg-light);
  color: var(--text-dark);
}

body {
  font-family: var(--font-body);
  line-height: 1.6;
  overflow-x: hidden;
  color: var(--text-dark);
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-headings);
  font-weight: 700;
  line-height: 1.2;
}

a {
  text-decoration: none;
  color: inherit;
  transition: var(--transition-fast);
}

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

ul {
  list-style: none;
}

button {
  cursor: pointer;
  border: none;
  background: none;
  font-family: inherit;
}

/* Custom Scrollbar */
::-webkit-scrollbar {
  width: 10px;
}
::-webkit-scrollbar-track {
  background: var(--bg-light);
}
::-webkit-scrollbar-thumb {
  background: var(--accent-light);
  border-radius: 5px;
  border: 2px solid var(--bg-light);
}
::-webkit-scrollbar-thumb:hover {
  background: var(--primary-medium);
}

/* Common Components & Helpers */
.container {
  width: 100%;
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 24px;
}

.section-padding {
  padding: 100px 0;
}

.text-gradient {
  background: linear-gradient(135deg, var(--primary-dark) 20%, var(--accent-blue) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 14px 28px;
  border-radius: var(--border-radius-sm);
  font-weight: 600;
  transition: var(--transition-smooth);
  gap: 8px;
}

.btn-primary {
  background: linear-gradient(135deg, var(--primary-medium) 0%, var(--primary-dark) 100%);
  color: var(--text-light);
  box-shadow: 0 4px 15px rgba(11, 37, 69, 0.2);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 25px rgba(11, 37, 69, 0.3);
  background: linear-gradient(135deg, var(--accent-blue) 0%, var(--primary-medium) 100%);
}

.btn-secondary {
  background: transparent;
  color: var(--primary-dark);
  border: 2px solid var(--primary-dark);
}

.btn-secondary:hover {
  background: var(--primary-dark);
  color: var(--text-light);
}

.btn-whatsapp {
  background-color: #25D366;
  color: white;
  box-shadow: 0 4px 12px rgba(37, 211, 102, 0.3);
}

.btn-whatsapp:hover {
  background-color: #20BA5A;
  transform: translateY(-2px);
  box-shadow: 0 6px 18px rgba(37, 211, 102, 0.4);
}

/* Botón "Próximamente": recorrido virtual aún no disponible */
.btn-soon {
  background: transparent;
  color: var(--text-muted);
  border: 2px dashed var(--accent-light);
  cursor: not-allowed;
  opacity: 0.85;
}
.btn-soon:hover {
  transform: none;
  box-shadow: none;
}

/* ==========================================================================
   HEADER / NAVIGATION
   ========================================================================== */
.header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: var(--header-height);
  z-index: 1000;
  background: var(--glass-bg);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--glass-border);
  box-shadow: 0 2px 20px var(--glass-shadow);
  transition: var(--transition-smooth);
  display: flex;
  align-items: center;
}

.header--shrunk {
  height: var(--header-height-shrunk);
  box-shadow: 0 4px 30px rgba(0, 0, 0, 0.08);
}

.header .container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  width: 100%;
}

.logo-container {
  display: flex;
  align-items: center;
  gap: 12px;
}

.logo-img {
  height: 48px;
  width: auto;
  object-fit: contain;
  transition: var(--transition-smooth);
}

.header--shrunk .logo-img {
  height: 38px;
}

.logo-text {
  font-family: var(--font-headings);
  font-weight: 800;
  font-size: 1.4rem;
  color: var(--primary-dark);
  letter-spacing: -0.5px;
}

.nav-menu {
  display: flex;
  align-items: center;
  gap: 32px;
}

.nav-link {
  font-family: var(--font-headings);
  font-weight: 500;
  font-size: 0.95rem;
  color: var(--text-dark);
  position: relative;
  padding: 4px 0;
}

.nav-link::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0;
  height: 2px;
  background-color: var(--accent-blue);
  transition: var(--transition-fast);
}

.nav-link:hover::after {
  width: 100%;
}

/* Navigation Dropdown Menu */
.nav-item-dropdown {
  position: relative;
  display: inline-block;
}

.nav-chevron {
  font-size: 0.75rem;
  margin-left: 4px;
  transition: transform 0.3s ease;
}

.nav-item-dropdown:hover .nav-chevron {
  transform: rotate(180deg);
}

.dropdown-menu {
  position: absolute;
  top: 100%;
  left: 50%;
  transform: translateX(-50%) translateY(10px);
  background: white;
  border: 1px solid rgba(0, 0, 0, 0.05);
  border-radius: var(--border-radius-sm);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.08);
  width: max-content;
  min-width: 200px;
  opacity: 0;
  visibility: hidden;
  transition: var(--transition-smooth);
  padding: 12px 0;
  margin-top: 12px;
  z-index: 1000;
}

/* Puente invisible: cubre el espacio entre el enlace y el menú
   para que el hover no se pierda al bajar el cursor */
.dropdown-menu::after {
  content: '';
  position: absolute;
  top: -12px;
  left: 0;
  right: 0;
  height: 12px;
}

.dropdown-menu::before {
  content: '';
  position: absolute;
  top: -6px;
  left: 50%;
  transform: translateX(-50%) rotate(45deg);
  width: 12px;
  height: 12px;
  background: white;
  border-left: 1px solid rgba(0, 0, 0, 0.05);
  border-top: 1px solid rgba(0, 0, 0, 0.05);
}

.nav-item-dropdown:hover .dropdown-menu {
  opacity: 1;
  visibility: visible;
  transform: translateX(-50%) translateY(0);
}

.dropdown-menu li {
  width: 100%;
}

.dropdown-menu li a {
  display: block;
  padding: 10px 24px;
  font-family: var(--font-headings);
  font-weight: 500;
  font-size: 0.9rem;
  color: var(--text-dark);
  text-align: left;
  white-space: nowrap;
  cursor: pointer;
  transition: var(--transition-fast);
}

.dropdown-menu li a:hover {
  background-color: rgba(0, 180, 216, 0.05);
  color: var(--accent-blue);
  padding-left: 30px;
}

/* ==========================================================================
   HERO SECTION
   ========================================================================== */
.hero {
  position: relative;
  height: 100vh;
  min-height: 700px;
  display: flex;
  align-items: center;
  background: radial-gradient(circle at 90% 10%, rgba(0, 180, 216, 0.08) 0%, rgba(248, 249, 250, 0) 60%),
              radial-gradient(circle at 10% 90%, rgba(212, 163, 115, 0.08) 0%, rgba(248, 249, 250, 0) 60%);
  padding-top: var(--header-height);
  overflow: hidden;
}

.hero::before {
  content: '';
  position: absolute;
  top: 0;
  right: 0;
  bottom: 0;
  left: 0;
  background-image: radial-gradient(var(--accent-light) 0.8px, transparent 0.8px);
  background-size: 24px 24px;
  opacity: 0.15;
  pointer-events: none;
}

.hero-grid {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  align-items: center;
  gap: 48px;
  width: 100%;
}

.hero-tag {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 16px;
  background-color: rgba(0, 180, 216, 0.08);
  border: 1px solid rgba(0, 180, 216, 0.15);
  border-radius: 50px;
  font-family: var(--font-headings);
  font-weight: 600;
  font-size: 0.85rem;
  color: var(--primary-medium);
  margin-bottom: 24px;
}

.hero-title {
  font-size: 3.5rem;
  font-weight: 800;
  color: var(--primary-dark);
  line-height: 1.1;
  margin-bottom: 24px;
  letter-spacing: -1px;
}

.hero-desc {
  font-size: 1.15rem;
  color: var(--text-muted);
  margin-bottom: 40px;
  max-width: 550px;
}

.hero-ctas {
  display: flex;
  gap: 16px;
  align-items: center;
}

.hero-right {
  position: relative;
  display: flex;
  justify-content: center;
}

.hero-badge-container {
  position: relative;
  width: 100%;
  max-width: 450px;
  aspect-ratio: 1;
}

.hero-circle-bg {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 100%;
  height: 100%;
  background: linear-gradient(135deg, var(--accent-light) 0%, rgba(255, 255, 255, 0) 70%);
  border-radius: 50%;
  opacity: 0.15;
  filter: blur(40px);
}

.hero-card {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 90%;
  border-radius: var(--border-radius-lg);
  overflow: hidden;
  box-shadow: 0 20px 40px rgba(11, 37, 69, 0.15);
  border: 1px solid rgba(255, 255, 255, 0.2);
  background: var(--glass-bg);
  backdrop-filter: blur(8px);
}

.hero-card-img {
  width: 100%;
  height: 250px;
  object-fit: cover;
}

.hero-card-info {
  padding: 24px;
}

.hero-card-title {
  font-size: 1.3rem;
  color: var(--primary-dark);
  margin-bottom: 8px;
}

.hero-card-specs {
  display: flex;
  gap: 16px;
  font-size: 0.85rem;
  color: var(--text-muted);
}

.hero-scroll-indicator {
  position: absolute;
  bottom: 40px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  font-family: var(--font-headings);
  font-size: 0.8rem;
  font-weight: 500;
  color: var(--text-muted);
}

.scroll-mouse {
  width: 24px;
  height: 38px;
  border: 2px solid var(--accent-light);
  border-radius: 12px;
  position: relative;
}

.scroll-wheel {
  width: 4px;
  height: 8px;
  background-color: var(--accent-blue);
  border-radius: 2px;
  position: absolute;
  top: 6px;
  left: 50%;
  transform: translateX(-50%);
  animation: scrollMouse 1.8s infinite;
}

@keyframes scrollMouse {
  0% { transform: translate(-50%, 0); opacity: 1; }
  100% { transform: translate(-50%, 12px); opacity: 0; }
}

/* ==========================================================================
   CONSTRUCTION SECTION (SCROLL INTERACTIVE)
   ========================================================================== */
.construction-section {
  position: relative;
  height: 350vh; /* Determines the scroll speed/depth of the build */
  background-color: var(--primary-dark);
  color: var(--text-light);
  overflow: visible;
}

.construction-container {
  position: sticky;
  top: 0;
  height: 100vh;
  display: grid;
  grid-template-columns: 0.95fr 1.05fr;
  align-items: center;
  gap: 40px;
  overflow: hidden;
  padding: 0 40px;
}

.construction-text-area {
  padding: 40px;
  z-index: 10;
  display: flex;
  flex-direction: column;
  justify-content: center;
  height: 100%;
}

.construction-title {
  font-size: 3rem;
  margin-bottom: 24px;
  color: var(--text-light);
  line-height: 1.1;
}

.construction-steps {
  position: relative;
  height: 250px;
}

.construction-step-card {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.5s ease, transform 0.5s ease;
  pointer-events: none;
}

/* Control step cards based on scroll progress custom variable */
.construction-container {
  --p: var(--scroll-progress);
}

/* Step 1: Blueprint & Cimientos (0% - 25%) */
.construction-step-card:nth-child(1) {
  opacity: calc(clamp(0, (0.25 - var(--scroll-progress)) * 4, 1) * clamp(0, var(--scroll-progress) * 10, 1));
  transform: translateY(calc((1 - clamp(0, var(--scroll-progress) * 10, 1)) * 20px));
}

/* Step 2: Paredes y Puertas (25% - 60%) */
.construction-step-card:nth-child(2) {
  opacity: calc(clamp(0, (0.60 - var(--scroll-progress)) * 3.3, 1) * clamp(0, (var(--scroll-progress) - 0.25) * 6, 1));
  transform: translateY(calc((1 - clamp(0, (var(--scroll-progress) - 0.25) * 6, 1)) * 20px));
}

/* Step 3: Segundo Piso y Techo (60% - 85%) */
.construction-step-card:nth-child(3) {
  opacity: calc(clamp(0, (0.85 - var(--scroll-progress)) * 4, 1) * clamp(0, (var(--scroll-progress) - 0.60) * 6.6, 1));
  transform: translateY(calc((1 - clamp(0, (var(--scroll-progress) - 0.60) * 6.6, 1)) * 20px));
}

/* Step 4: Acabados y Jardín (85% - 100%) */
.construction-step-card:nth-child(4) {
  opacity: clamp(0, (var(--scroll-progress) - 0.85) * 6.6, 1);
  transform: translateY(calc((1 - clamp(0, (var(--scroll-progress) - 0.85) * 6.6, 1)) * 20px));
}

.construction-step-num {
  font-family: var(--font-headings);
  font-size: 4rem;
  font-weight: 800;
  color: var(--accent-blue);
  line-height: 1;
  margin-bottom: 8px;
  opacity: 0.5;
}

.construction-step-title {
  font-size: 1.8rem;
  margin-bottom: 12px;
  color: var(--text-light);
}

.construction-step-desc {
  font-size: 1.05rem;
  color: var(--accent-light);
  max-width: 480px;
}

.construction-visual-area {
  display: flex;
  justify-content: center;
  align-items: center;
  height: 100vh;
  position: relative;
}

.svg-wrapper {
  width: 90%;
  max-width: 650px;
  aspect-ratio: 4/3;
  background-color: rgba(255, 255, 255, 0.02);
  border: 1px solid rgba(255, 255, 255, 0.05);
  border-radius: var(--border-radius-lg);
  padding: 24px;
  box-shadow: inset 0 0 30px rgba(0, 0, 0, 0.2);
  display: flex;
  align-items: center;
  justify-content: center;
}

#house-svg {
  width: 100%;
  height: 100%;
}

/* SVG Styling & Layers (Default State) */
#house-svg .l-blueprint {
  stroke: var(--accent-blue);
  stroke-width: 1.5px;
  fill: none;
  opacity: 1;
}

#house-svg .l-ground,
#house-svg .l-foundation,
#house-svg .l-walls-1,
#house-svg .l-doors-windows-1,
#house-svg .l-ceiling-1,
#house-svg .l-walls-2,
#house-svg .l-doors-windows-2,
#house-svg .l-roof,
#house-svg .l-details {
  opacity: 0; /* Animated dynamically on scroll */
  transition: transform 0.1s linear, opacity 0.1s linear;
}

/* Native CSS Scroll-driven animations if supported */
@supports (animation-timeline: scroll()) {
  @keyframes drawBlueprint {
    0% { stroke-dashoffset: 100%; opacity: 1; }
    30% { stroke-dashoffset: 0; opacity: 1; }
    60% { opacity: 0.3; }
    100% { opacity: 0; }
  }
  
  @keyframes fadeInUp {
    to { transform: translateY(0); opacity: 1; }
  }

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

  #house-svg {
    /* Define a view timeline or bind to document scroll */
    view-timeline-name: --construction-timeline;
    view-timeline-axis: block;
  }

  /* Set timelines */
  #house-svg .l-blueprint path {
    animation: drawBlueprint linear both;
    animation-timeline: --construction-timeline;
    animation-range: entry 0% exit 30%;
  }

  #house-svg .l-ground {
    transform: translateY(30px);
    animation: fadeInUp linear both;
    animation-timeline: --construction-timeline;
    animation-range: entry 5% exit 25%;
  }

  #house-svg .l-foundation {
    transform: translateY(30px);
    animation: fadeInUp linear both;
    animation-timeline: --construction-timeline;
    animation-range: entry 15% exit 35%;
  }

  #house-svg .l-walls-1 {
    transform: translateY(50px);
    animation: fadeInUp linear both;
    animation-timeline: --construction-timeline;
    animation-range: entry 30% exit 55%;
  }

  #house-svg .l-doors-windows-1 {
    transform: translateY(20px);
    animation: fadeInUp linear both;
    animation-timeline: --construction-timeline;
    animation-range: entry 45% exit 65%;
  }

  #house-svg .l-ceiling-1 {
    transform: translateY(40px);
    animation: fadeInUp linear both;
    animation-timeline: --construction-timeline;
    animation-range: entry 55% exit 75%;
  }

  #house-svg .l-walls-2 {
    transform: translateY(50px);
    animation: fadeInUp linear both;
    animation-timeline: --construction-timeline;
    animation-range: entry 65% exit 85%;
  }

  #house-svg .l-doors-windows-2 {
    transform: translateY(20px);
    animation: fadeInUp linear both;
    animation-timeline: --construction-timeline;
    animation-range: entry 75% exit 90%;
  }

  #house-svg .l-roof {
    transform: translateY(-40px);
    animation: fadeInDown linear both;
    animation-timeline: --construction-timeline;
    animation-range: entry 80% exit 95%;
  }

  #house-svg .l-details {
    transform: translateY(15px);
    animation: fadeInUp linear both;
    animation-timeline: --construction-timeline;
    animation-range: entry 88% exit 100%;
  }
}

/* ==========================================================================
   MODELS SECTION
   ========================================================================== */
.models-section {
  background-color: var(--bg-light);
}

.models-header {
  text-align: center;
  margin-bottom: 60px;
}

.models-header h2 {
  font-size: 2.8rem;
  color: var(--primary-dark);
  margin-bottom: 16px;
}

.models-header p {
  color: var(--text-muted);
  font-size: 1.1rem;
  max-width: 600px;
  margin: 0 auto;
}

.models-tabs {
  display: flex;
  justify-content: center;
  gap: 12px;
  margin-bottom: 48px;
  flex-wrap: wrap;
}

.model-tab-btn {
  padding: 12px 24px;
  border-radius: 50px;
  font-family: var(--font-headings);
  font-weight: 600;
  font-size: 1rem;
  background-color: white;
  color: var(--text-dark);
  border: 1px solid rgba(0, 0, 0, 0.08);
  box-shadow: 0 2px 8px rgba(0,0,0,0.02);
  transition: var(--transition-smooth);
}

.model-tab-btn:hover {
  background-color: rgba(19, 64, 116, 0.05);
  transform: translateY(-1px);
}

.model-tab-btn.active {
  background-color: var(--primary-medium);
  color: var(--text-light);
  border-color: var(--primary-medium);
  box-shadow: 0 4px 12px rgba(19, 64, 116, 0.15);
}

.model-display {
  position: relative;
  min-height: 550px;
}

.model-card {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 48px;
  background-color: white;
  border-radius: var(--border-radius-lg);
  overflow: hidden;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.04);
  border: 1px solid rgba(0, 0, 0, 0.03);
  opacity: 0;
  transform: scale(0.98) translateY(10px);
  visibility: hidden;
  transition: opacity 0.5s cubic-bezier(0.16, 1, 0.3, 1), 
              transform 0.5s cubic-bezier(0.16, 1, 0.3, 1),
              visibility 0.5s;
  pointer-events: none;
}

.model-card.active {
  position: relative;
  opacity: 1;
  transform: scale(1) translateY(0);
  visibility: visible;
  pointer-events: all;
}

.model-gallery {
  display: flex;
  flex-direction: column;
  height: 480px;
  background-color: var(--bg-light);
}

.gallery-main {
  position: relative;
  flex-grow: 1;
  overflow: hidden;
  height: 380px;
}

.gallery-main-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: opacity 0.3s ease, transform 0.5s ease;
}

.gallery-nav-btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 44px;
  height: 44px;
  background-color: rgba(255, 255, 255, 0.9);
  color: var(--primary-dark);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--transition-smooth);
  opacity: 0;
  pointer-events: none;
  z-index: 5;
  border: 1px solid rgba(0,0,0,0.05);
  box-shadow: 0 4px 10px rgba(0,0,0,0.05);
}

.gallery-main:hover .gallery-nav-btn {
  opacity: 1;
  pointer-events: all;
}

.gallery-nav-btn:hover {
  background-color: var(--primary-medium);
  color: white;
  transform: translateY(-50%) scale(1.08);
}

.prev-btn { left: 16px; }
.next-btn { right: 16px; }

.model-card.active .gallery-main-img {
  transform: scale(1.02);
}

.gallery-thumbs {
  display: flex;
  gap: 12px;
  padding: 12px 24px;
  background-color: #f8fafc;
  border-top: 1px solid rgba(0, 0, 0, 0.04);
  height: 100px;
  align-items: center;
}

.gallery-thumb {
  width: 90px;
  height: 60px;
  object-fit: cover;
  border-radius: var(--border-radius-sm);
  cursor: pointer;
  border: 2px solid transparent;
  transition: var(--transition-smooth);
  opacity: 0.6;
}

.gallery-thumb:hover {
  opacity: 0.9;
  transform: translateY(-2px);
}

.gallery-thumb.active {
  border-color: var(--accent-blue);
  opacity: 1;
  box-shadow: 0 4px 10px rgba(0, 180, 216, 0.15);
}

.model-ctas {
  display: flex;
  gap: 12px;
  margin-top: auto;
  align-items: center;
}

.btn-matterport {
  background-color: var(--primary-medium);
  color: white;
  box-shadow: 0 4px 12px rgba(19, 64, 116, 0.15);
}

.btn-matterport:hover {
  background-color: var(--accent-blue);
  transform: translateY(-2px);
  box-shadow: 0 6px 18px rgba(0, 180, 216, 0.25);
}

/* Matterport Modal */
.modal {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 2000;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.modal.active {
  opacity: 1;
  pointer-events: all;
}

.modal-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(6, 17, 33, 0.85);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}

.modal-content {
  position: relative;
  width: 90%;
  max-width: 960px;
  aspect-ratio: 16/9;
  background-color: var(--bg-dark);
  border-radius: var(--border-radius-lg);
  overflow: hidden;
  box-shadow: 0 25px 50px rgba(0, 0, 0, 0.5);
  border: 1px solid rgba(255, 255, 255, 0.1);
  z-index: 2001;
  transform: scale(0.95);
  transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.modal.active .modal-content {
  transform: scale(1);
}

.modal-close {
  position: absolute;
  top: 16px;
  right: 16px;
  width: 36px;
  height: 36px;
  background-color: rgba(255, 255, 255, 0.1);
  color: white;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  border: none;
  cursor: pointer;
  z-index: 2002;
  transition: var(--transition-fast);
}

.modal-close:hover {
  background-color: rgba(255, 255, 255, 0.25);
  transform: scale(1.05);
}

.iframe-container {
  width: 100%;
  height: 100%;
}

.iframe-container iframe {
  width: 100%;
  height: 100%;
  border: none;
}

.model-badge {
  position: absolute;
  top: 24px;
  left: 24px;
  padding: 8px 16px;
  background-color: var(--primary-dark);
  color: var(--text-light);
  font-family: var(--font-headings);
  font-weight: 600;
  font-size: 0.85rem;
  border-radius: 4px;
  box-shadow: 0 4px 10px rgba(0,0,0,0.1);
}

.model-info {
  padding: 48px;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.model-title {
  font-size: 2.2rem;
  color: var(--primary-dark);
  margin-bottom: 12px;
}

.model-area {
  font-family: var(--font-headings);
  font-size: 1.15rem;
  font-weight: 600;
  color: var(--accent-blue);
  margin-bottom: 24px;
  display: flex;
  align-items: center;
  gap: 6px;
}

.model-desc {
  color: var(--text-muted);
  margin-bottom: 32px;
}

.model-specs-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 12px;
  margin-bottom: 36px;
  border-top: 1px solid rgba(0,0,0,0.06);
  border-bottom: 1px solid rgba(0,0,0,0.06);
  padding: 20px 0;
}

.spec-item {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.spec-label {
  font-size: 0.75rem;
  text-transform: uppercase;
  color: var(--text-muted);
  font-weight: 600;
  letter-spacing: 0.5px;
}

.spec-val {
  font-family: var(--font-headings);
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--primary-dark);
}

/* ==========================================================================
   AMENITIES SECTION
   ========================================================================== */
.amenities-section {
  background-color: white;
}

.amenities-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 32px;
  margin-top: 60px;
}

.amenity-card {
  padding: 40px 32px;
  background-color: var(--bg-light);
  border-radius: var(--border-radius-md);
  border: 1px solid rgba(0, 0, 0, 0.03);
  box-shadow: 0 4px 20px rgba(0,0,0,0.01);
  transition: var(--transition-smooth);
}

.amenity-card:hover {
  transform: translateY(-8px);
  box-shadow: 0 12px 30px rgba(19, 64, 116, 0.08);
  background-color: white;
  border-color: rgba(19, 64, 116, 0.08);
}

.amenity-icon {
  width: 56px;
  height: 56px;
  background-color: rgba(0, 180, 216, 0.08);
  border-radius: var(--border-radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 24px;
  color: var(--accent-blue);
  transition: var(--transition-smooth);
}

.amenity-card:hover .amenity-icon {
  background-color: var(--accent-blue);
  color: white;
  transform: scale(1.05);
}

/* ==========================================================================
   BENEFICIOS
   ========================================================================== */
.benefits-section { background-color: var(--bg-light); }

.benefits-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
  margin-top: 60px;
}

.benefit-card {
  padding: 32px 28px;
  background-color: white;
  border-radius: var(--border-radius-md);
  border: 1px solid rgba(0, 0, 0, 0.04);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.02);
  transition: var(--transition-smooth);
}

.benefit-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 14px 34px rgba(19, 64, 116, 0.1);
  border-color: rgba(19, 64, 116, 0.08);
}

.benefit-icon {
  width: 54px;
  height: 54px;
  background-color: rgba(0, 180, 216, 0.08);
  border-radius: var(--border-radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 20px;
  color: var(--accent-blue);
  transition: var(--transition-smooth);
}

.benefit-card:hover .benefit-icon {
  background-color: var(--accent-blue);
  color: white;
  transform: scale(1.05);
}

.benefit-card h3 {
  font-family: var(--font-headings);
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--primary-dark);
  margin-bottom: 10px;
}

.benefit-card p {
  font-size: 0.92rem;
  line-height: 1.6;
  color: var(--text-muted);
}

/* Última tarjeta: banner destacado a todo el ancho */
.benefit-card--wide {
  grid-column: 1 / -1;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  background: linear-gradient(135deg, var(--primary-dark) 0%, var(--accent-blue) 100%);
  border: none;
}
.benefit-card--wide .benefit-icon {
  background-color: rgba(255, 255, 255, 0.15);
  color: var(--accent-gold);
  margin-bottom: 16px;
}
.benefit-card--wide:hover { transform: translateY(-6px); }
.benefit-card--wide:hover .benefit-icon {
  background-color: rgba(255, 255, 255, 0.2);
  color: var(--accent-gold);
}
.benefit-card--wide h3 { color: #fff; font-size: 1.4rem; }
.benefit-card--wide p { color: rgba(255, 255, 255, 0.9); font-size: 1rem; max-width: 60ch; }

@media (max-width: 900px) {
  .benefits-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 560px) {
  .benefits-grid { grid-template-columns: 1fr; }
}

/* Beneficio con foto al pasar el cursor (flip, como amenidades) */
.benefit-card--flip {
  background: transparent; border: none; box-shadow: none; padding: 0;
  overflow: visible; perspective: 1200px; cursor: pointer;
}
.benefit-card--flip:hover { transform: none; box-shadow: none; }
.benefit-card--flip .flip {
  position: relative; width: 100%; height: 300px;
  transform-style: preserve-3d;
  transition: transform 0.7s cubic-bezier(0.2, 1, 0.3, 1);
}
.benefit-card--flip:hover .flip,
.benefit-card--flip.is-flipped .flip { transform: rotateY(180deg); }
.benefit-card--flip .flip__front {
  background: #fff; justify-content: flex-start;
}
.benefit-card--flip:hover .benefit-icon {
  background-color: rgba(0, 180, 216, 0.08); color: var(--accent-blue); transform: none;
}

/* Beneficio sin foto: mismo tamaño que las tarjetas flip */
.benefit-card--plain {
  display: flex; flex-direction: column; justify-content: center; min-height: 300px;
}

@media (max-width: 768px) {
  .benefit-card--flip .flip { height: 270px; }
  .benefit-card--plain { min-height: 270px; }
}

.amenity-card h3 {
  font-size: 1.3rem;
  color: var(--primary-dark);
  margin-bottom: 12px;
}

.amenity-card p {
  color: var(--text-muted);
  font-size: 0.9rem;
}

/* ==========================================================================
   CALL TO ACTION & CONTACT SECTION
   ========================================================================== */
.contact-section {
  background: linear-gradient(135deg, var(--primary-dark) 0%, #061121 100%);
  color: var(--text-light);
  position: relative;
  overflow: hidden;
}

.contact-section::before {
  content: '';
  position: absolute;
  top: 0;
  right: 0;
  width: 40%;
  height: 100%;
  background: radial-gradient(circle at 70% 30%, rgba(0, 180, 216, 0.15) 0%, rgba(0,0,0,0) 70%);
  pointer-events: none;
}

.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 60px;
  align-items: center;
}

.contact-info h2 {
  font-size: 2.8rem;
  margin-bottom: 16px;
}

.contact-info p {
  color: var(--accent-light);
  font-size: 1.1rem;
  margin-bottom: 40px;
}

.contact-methods {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.contact-item {
  display: flex;
  align-items: flex-start;
  gap: 16px;
}

.contact-item-icon {
  color: var(--accent-blue);
  margin-top: 4px;
}

.contact-item-title {
  font-weight: 600;
  font-size: 1rem;
  margin-bottom: 4px;
}

.contact-item-desc {
  color: var(--accent-light);
  font-size: 0.9rem;
}

.contact-form-wrapper {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.08);
  padding: 48px;
  border-radius: var(--border-radius-lg);
  backdrop-filter: blur(8px);
}

.contact-form {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.form-label {
  font-size: 0.85rem;
  font-weight: 500;
  color: var(--accent-light);
}

.form-input {
  padding: 14px;
  background-color: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: var(--border-radius-sm);
  color: white;
  font-family: inherit;
  font-size: 0.95rem;
  transition: var(--transition-fast);
}

.form-input:focus {
  outline: none;
  border-color: var(--accent-blue);
  background-color: rgba(255, 255, 255, 0.08);
}

/* User-valid CSS validation marker helper */
.form-input:user-valid {
  border-color: #25D366;
}

/* Mensaje de estado del formulario (envío al CRM) */
.form-status {
  margin-top: 12px;
  font-size: 0.9rem;
  font-weight: 600;
  text-align: center;
  min-height: 1.2em;
}
.form-status--ok  { color: #25D366; }
.form-status--err { color: #ffd0c4; }

/* ==========================================================================
   FLOATING WHATSAPP BUTTON & FOOTER
   ========================================================================== */
.footer {
  background-color: #030a14;
  color: var(--accent-light);
  border-top: 1px solid rgba(255,255,255,0.05);
  padding: 40px 0;
  text-align: center;
  font-size: 0.9rem;
}

.footer-nav {
  display: flex;
  justify-content: center;
  gap: 24px;
  margin-bottom: 24px;
}

.footer-link:hover {
  color: white;
}

.whatsapp-float {
  position: fixed;
  bottom: 32px;
  right: 32px;
  width: 60px;
  height: 60px;
  background-color: #25D366;
  color: white;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 15px rgba(37, 211, 102, 0.4);
  z-index: 999;
  transition: var(--transition-smooth);
}

.whatsapp-float:hover {
  transform: scale(1.08) rotate(8deg);
  background-color: #20BA5A;
  box-shadow: 0 6px 20px rgba(37, 211, 102, 0.5);
}

.whatsapp-float-pulse {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  border-radius: 50%;
  background-color: #25D366;
  opacity: 0.4;
  z-index: -1;
  animation: floatPulse 2s infinite;
}

@keyframes floatPulse {
  0% { transform: scale(1); opacity: 0.4; }
  100% { transform: scale(1.5); opacity: 0; }
}

/* ==========================================================================
   SCROLL REVEAL UTILITIES
   ========================================================================== */
.reveal {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.8s ease, transform 0.8s ease;
}

.reveal.active {
  opacity: 1;
  transform: translateY(0);
}

/* ==========================================================================
   RESPONSIVE DESIGN (MEDIA QUERIES)
   ========================================================================== */
@media (max-width: 1024px) {
  .hero-title {
    font-size: 2.8rem;
  }
  
  .construction-container {
    grid-template-columns: 1fr;
    grid-template-rows: auto 1fr;
    height: 100vh;
    padding: 24px;
    gap: 16px;
  }
  
  .construction-text-area {
    padding: 0;
    height: auto;
    text-align: center;
  }

  .construction-steps {
    height: 120px;
    margin-top: 10px;
  }

  .construction-step-card {
    text-align: center;
  }

  .construction-step-num {
    font-size: 2.5rem;
    margin-bottom: 0;
  }

  .construction-step-title {
    font-size: 1.4rem;
    margin-bottom: 4px;
  }

  .construction-step-desc {
    font-size: 0.95rem;
    margin: 0 auto;
  }

  .construction-visual-area {
    height: auto;
    padding-bottom: 24px;
  }

  .svg-wrapper {
    max-width: 500px;
  }
  
  .model-card {
    grid-template-columns: 1fr;
  }

  .model-gallery {
    height: 420px;
  }
  .gallery-main {
    height: 320px;
  }

  .model-info {
    padding: 32px;
  }
  
  .amenities-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 768px) {
  .nav-menu {
    display: none; /* In a real project, a mobile menu would trigger here */
  }

  .hero-grid {
    grid-template-columns: 1fr;
    text-align: center;
    gap: 32px;
  }

  .hero-desc {
    margin: 0 auto 32px auto;
  }

  .hero-ctas {
    justify-content: center;
  }

  .hero-right {
    display: none;
  }
  
  .contact-grid {
    grid-template-columns: 1fr;
    gap: 40px;
  }

  .contact-form-wrapper {
    padding: 32px;
  }

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

/* Interactive Hotspots Banner */
.hotspots-section {
  background-color: white;
}

.hotspots-banner {
  position: relative;
  width: 100%;
  border-radius: var(--border-radius-lg);
  overflow: hidden;
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.06);
  border: 1px solid rgba(0, 0, 0, 0.03);
}

.hotspots-bg-img {
  width: 100%;
  height: 520px;
  object-fit: cover;
  display: block;
  filter: brightness(0.92) contrast(1.02);
}

.hotspot-dot {
  position: absolute;
  width: 26px;
  height: 26px;
  background-color: var(--accent-blue);
  border-radius: 50%;
  cursor: pointer;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 3px solid white;
  box-shadow: 0 4px 15px rgba(0, 180, 216, 0.4);
  transition: transform 0.3s ease;
}

.hotspot-dot:hover {
  transform: scale(1.15);
  background-color: var(--accent-sand);
}

.hotspot-pulse {
  position: absolute;
  top: -10px;
  left: -10px;
  right: -10px;
  bottom: -10px;
  border-radius: 50%;
  border: 2px solid var(--accent-blue);
  animation: hotspotPulse 2s infinite;
  pointer-events: none;
}

.hotspot-dot:hover .hotspot-pulse {
  border-color: var(--accent-sand);
}

@keyframes hotspotPulse {
  0% { transform: scale(0.6); opacity: 0.8; }
  100% { transform: scale(1.6); opacity: 0; }
}

.hotspot-tooltip {
  position: absolute;
  bottom: 40px;
  left: 50%;
  transform: translateX(-50%) translateY(10px);
  width: 280px;
  background: var(--glass-bg);
  border: 1px solid var(--glass-border);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-radius: var(--border-radius-md);
  padding: 20px;
  color: var(--text-dark);
  box-shadow: 0 15px 35px rgba(11, 37, 69, 0.15);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.4s cubic-bezier(0.16, 1, 0.3, 1), 
              transform 0.4s cubic-bezier(0.16, 1, 0.3, 1);
  z-index: 100;
}

.hotspot-tooltip::after {
  content: '';
  position: absolute;
  bottom: -6px;
  left: 50%;
  transform: translateX(-50%) rotate(45deg);
  width: 12px;
  height: 12px;
  background: var(--glass-bg);
  border-right: 1px solid var(--glass-border);
  border-bottom: 1px solid var(--glass-border);
}

.hotspot-dot:hover .hotspot-tooltip,
.hotspot-dot.active .hotspot-tooltip {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
  pointer-events: all;
}

.hotspot-tooltip h4 {
  font-size: 1.05rem;
  font-family: var(--font-headings);
  font-weight: 700;
  color: var(--primary-dark);
  margin-bottom: 6px;
}

.hotspot-tooltip p {
  font-size: 0.85rem;
  color: var(--text-muted);
  line-height: 1.4;
}

/* Location Section ("Cerca de todo") */
.location-section {
  background-color: var(--bg-light);
}

.location-grid {
  display: grid;
  grid-template-columns: 0.9fr 1.1fr;
  gap: 60px;
  align-items: center;
}

.location-info h2 {
  font-size: 2.8rem;
  color: var(--primary-dark);
  margin-bottom: 20px;
}

.location-info p {
  color: var(--text-muted);
  font-size: 1.1rem;
  margin-bottom: 40px;
}

.location-landmarks {
  display: grid;
  grid-template-columns: 1fr;
  gap: 24px;
}

.landmark-item {
  display: flex;
  align-items: flex-start;
  gap: 16px;
  background-color: white;
  padding: 20px;
  border-radius: var(--border-radius-md);
  border: 1px solid rgba(0,0,0,0.02);
  box-shadow: 0 4px 15px rgba(0,0,0,0.01);
  transition: var(--transition-smooth);
}

.landmark-item:hover {
  transform: translateX(5px);
  box-shadow: 0 8px 25px rgba(19, 64, 116, 0.05);
}

.landmark-icon {
  width: 44px;
  height: 44px;
  border-radius: var(--border-radius-sm);
  background-color: rgba(0, 180, 216, 0.08);
  color: var(--accent-blue);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.1rem;
  flex-shrink: 0;
}

.landmark-title {
  font-family: var(--font-headings);
  font-weight: 600;
  font-size: 1.05rem;
  color: var(--primary-dark);
  margin-bottom: 4px;
}

.landmark-desc {
  font-size: 0.9rem;
  color: var(--text-muted);
}

.location-map {
  position: relative;
}

.map-frame {
  position: relative;
  width: 100%;
  border-radius: var(--border-radius-lg);
  overflow: hidden;
  border: 1px solid rgba(0,0,0,0.05);
  box-shadow: 0 20px 40px rgba(0,0,0,0.05);
  aspect-ratio: 4/3;
}

.map-placeholder-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: contrast(1.05) brightness(0.9);
}

.map-overlay-blueprint {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(11, 37, 69, 0.25);
  pointer-events: none;
  z-index: 2;
}

.map-tag {
  position: absolute;
  padding: 8px 16px;
  border-radius: 50px;
  font-family: var(--font-headings);
  font-weight: 600;
  font-size: 0.85rem;
  box-shadow: 0 8px 20px rgba(0,0,0,0.15);
  display: flex;
  align-items: center;
  gap: 8px;
  pointer-events: all;
  cursor: pointer;
  transition: var(--transition-smooth);
}

.map-tag:hover {
  transform: scale(1.05);
}

.tag-residential {
  top: 48%;
  left: 45%;
  background-color: var(--primary-medium);
  color: white;
  border: 2px solid var(--accent-blue);
  z-index: 5;
  animation: pulseMarker 2s infinite;
}

@keyframes pulseMarker {
  0% { box-shadow: 0 0 0 0 rgba(0, 180, 216, 0.7); }
  70% { box-shadow: 0 0 0 15px rgba(0, 180, 216, 0); }
  100% { box-shadow: 0 0 0 0 rgba(0, 180, 216, 0); }
}

.tag-landmark {
  background-color: white;
  color: var(--text-dark);
  border: 1px solid rgba(0,0,0,0.05);
  font-size: 0.75rem;
}

.tag-landmark i {
  color: var(--accent-blue);
}

/* Adjustments for smaller devices */
@media (max-width: 1024px) {
  .location-grid {
    grid-template-columns: 1fr;
    gap: 40px;
  }
}

/* ==========================================================================
   AÑADIDOS GEB — Galería multimedia, plano de lotes, menú móvil
   ========================================================================== */

/* ---- Galería: escenario que aloja imagen / video / iframe ---- */
.gallery-stage {
  position: absolute;
  inset: 0;
  transition: opacity 0.3s ease;
}
.gallery-stage > * { width: 100%; height: 100%; }
.gallery-main-img { object-fit: cover; }
.gallery-main-video { object-fit: cover; background: #000; }
.gallery-main-iframe { border: none; }

/* Miniaturas como botones con fondo (soportan overlay de play) */
.gallery-thumb {
  position: relative;
  width: 90px;
  height: 60px;
  border-radius: var(--border-radius-sm);
  cursor: pointer;
  border: 2px solid transparent;
  transition: var(--transition-smooth);
  opacity: 0.6;
  background-size: cover;
  background-position: center;
  flex-shrink: 0;
  padding: 0;
}
.gallery-thumb:hover { opacity: 0.95; transform: translateY(-2px); }
.gallery-thumb.active {
  border-color: var(--accent-blue);
  opacity: 1;
  box-shadow: 0 4px 10px rgba(0, 180, 216, 0.18);
}
.thumb-play {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(11, 37, 69, 0.35);
  border-radius: inherit;
  color: #fff;
  font-size: 0.85rem;
}
.thumb-play i { transform: translateX(1px); }

.model-price {
  font-family: var(--font-headings);
  font-size: 1rem;
  color: var(--text-muted);
  margin-bottom: 24px;
}
.model-price b { font-size: 1.6rem; color: var(--primary-dark); font-weight: 800; }
.model-price small { font-weight: 500; font-size: 0.8rem; }

/* ==========================================================================
   PLANO INTERACTIVO DE LOTES
   ========================================================================== */
.plano-section { background-color: var(--bg-light); }
.plano-grid {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 32px;
  align-items: start;
}
.plano-map {
  background: #fff;
  border: 1px solid rgba(0, 0, 0, 0.05);
  border-radius: var(--border-radius-lg);
  padding: 12px;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.04);
}

/* Visor del plano real: mismo tamaño de ventana + zoom/arrastre */
.plano-viewport {
  position: relative;
  width: 100%;
  aspect-ratio: 2752 / 1536;
  overflow: hidden;
  border-radius: var(--border-radius-sm);
  background: #eef2f6;
  touch-action: none;
  cursor: grab;
}
.plano-viewport.is-zoomed { cursor: grab; }
.plano-viewport:active { cursor: grabbing; }
.plano-svg2 {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  display: block;
  touch-action: none;
}
.plano-svg2 image { image-rendering: auto; }

/* Números de lote (vectoriales → nítidos a cualquier zoom) */
.lot-badge {
  fill: rgba(255, 255, 255, 0.88);
  stroke: rgba(11, 37, 69, 0.25);
  stroke-width: 0.6;
  transition: fill 0.12s ease, stroke 0.12s ease;
}
.lot-num {
  font-family: var(--font-headings);
  font-size: 8px;
  font-weight: 700;
  fill: var(--primary-dark);
  pointer-events: none;
  transition: fill 0.12s ease;
}
.lot-hit { fill: transparent; cursor: pointer; }
/* Lotes NO disponibles: atenuados (hover/selección los sobreescriben) */
.lot-g.na .lot-badge { fill: rgba(226, 232, 240, 0.92); stroke: rgba(148, 163, 184, 0.9); }
.lot-g.na .lot-num { fill: #94a3b8; }
.lot-g:hover .lot-badge { fill: var(--accent-blue); stroke: var(--accent-blue); }
.lot-g:hover .lot-num { fill: #fff; }
.lot-g.sel .lot-badge { fill: var(--accent-sand); stroke: var(--accent-sand); }
.lot-g.sel .lot-num { fill: #fff; }

/* Controles de zoom */
.plano-zoom {
  position: absolute;
  right: 12px;
  bottom: 12px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  z-index: 3;
}
.plano-zoom button {
  width: 40px;
  height: 40px;
  border: 1px solid rgba(0, 0, 0, 0.08);
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.95);
  color: var(--primary-dark);
  font-size: 20px;
  font-weight: 700;
  line-height: 1;
  cursor: pointer;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.12);
  display: grid;
  place-items: center;
  transition: background 0.15s, transform 0.08s;
}
.plano-zoom button:hover { background: var(--accent-blue); color: #fff; }
.plano-zoom button:active { transform: scale(0.94); }
.plano-zoom button i { font-size: 15px; }

.plano-hint {
  position: absolute;
  left: 12px;
  bottom: 12px;
  z-index: 3;
  background: rgba(11, 37, 69, 0.72);
  color: #fff;
  font-size: 0.72rem;
  font-weight: 500;
  padding: 6px 11px;
  border-radius: 20px;
  backdrop-filter: blur(4px);
  pointer-events: none;
}
.plano-viewport.is-zoomed .plano-hint { opacity: 0; transition: opacity 0.3s; }

.plano-panel {
  position: sticky;
  top: 110px;
  background: #fff;
  border: 1px solid rgba(0, 0, 0, 0.05);
  border-radius: var(--border-radius-lg);
  padding: 28px;
  min-height: 380px;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.04);
}
.panel-empty { text-align: center; padding-top: 24px; }
.panel-empty__icon {
  width: 56px; height: 56px; margin: 0 auto 16px;
  display: flex; align-items: center; justify-content: center;
  background: rgba(0, 180, 216, 0.1); color: var(--accent-blue);
  border-radius: 50%; font-size: 1.3rem;
}
.panel-empty h3 { font-size: 1.4rem; color: var(--primary-dark); }
.panel-empty p { color: var(--text-muted); font-size: 0.92rem; margin-top: 10px; max-width: 32ch; margin-inline: auto; }

.panel-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 14px; }
.panel-eyebrow { font-size: 0.72rem; letter-spacing: 0.1em; text-transform: uppercase; color: var(--accent-blue); font-weight: 700; font-family: var(--font-headings); }
.panel-head h3 { font-size: 1.9rem; color: var(--primary-dark); margin-top: 4px; }
.badge { font-size: 0.72rem; font-weight: 700; padding: 5px 12px; border-radius: 50px; white-space: nowrap; font-family: var(--font-headings); }
.badge--disp { background: #def4e5; color: #1f8a4c; }
.badge--res { background: #fbe7d6; color: #a6772f; }
.badge--vend { background: #e8edf2; color: #64748b; }
.badge--tramite { background: #fef3c7; color: #92400e; }
.badge--aprob { background: #dbeafe; color: #1e40af; }
.badge--modelo { background: #ede9fe; color: #6d28d9; }
.calc-row small { color: var(--text-muted); font-size: 0.76rem; font-weight: 500; }
.estado-legend { display: flex; flex-wrap: wrap; gap: 8px; justify-content: center; margin: 18px 0 6px; }
.estado-legend .badge { font-style: normal; }

.panel-dims { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; margin-top: 22px; }
.panel-dims > div { background: var(--bg-light); border-radius: var(--border-radius-sm); padding: 16px; }
.panel-dims b { display: block; font-family: var(--font-headings); font-size: 1.5rem; color: var(--primary-dark); font-weight: 800; }
.panel-dims span { font-size: 0.76rem; color: var(--text-muted); }

.panel-sep { height: 1px; background: rgba(0, 0, 0, 0.07); margin: 24px 0; }
.panel-label { display: block; font-size: 0.8rem; font-weight: 600; color: var(--primary-dark); margin-bottom: 10px; font-family: var(--font-headings); }
.panel-select {
  width: 100%; padding: 13px 14px; border: 1px solid rgba(0, 0, 0, 0.12);
  border-radius: var(--border-radius-sm); background: #fff; font-family: inherit;
  font-size: 0.92rem; color: var(--primary-dark); cursor: pointer; appearance: none;
  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 fill='none' stroke='%230B2545' stroke-width='1.6' d='M1 1l5 5 5-5'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right 16px center;
}
.panel-select:focus { outline: none; border-color: var(--accent-blue); }

.panel-calc { margin-top: 18px; background: var(--bg-light); border-radius: var(--border-radius-md); padding: 6px 16px; }
.calc-row { display: flex; justify-content: space-between; align-items: center; padding: 12px 0; border-bottom: 1px solid rgba(0, 0, 0, 0.06); font-size: 0.9rem; color: var(--text-dark); }
.calc-row b { color: var(--primary-dark); font-weight: 600; }
.calc-row--total { border-bottom: none; }
.calc-row--total span { font-weight: 700; color: var(--primary-dark); }
.calc-row--total b { font-family: var(--font-headings); font-size: 1.4rem; font-weight: 800; color: var(--primary-medium); }
.panel-note { font-size: 0.74rem; color: var(--text-muted); margin-top: 10px; }

.btn-wa {
  display: flex; align-items: center; justify-content: center; gap: 10px;
  width: 100%; margin-top: 18px; padding: 14px; border-radius: 50px;
  background: #25D366; color: #fff; font-weight: 600; font-size: 0.95rem;
  font-family: var(--font-headings); transition: var(--transition-smooth);
}
.btn-wa:hover { background: #20BA5A; transform: translateY(-2px); box-shadow: 0 8px 20px rgba(37, 211, 102, 0.35); }

.legend { display: flex; gap: 18px; margin-top: 26px; justify-content: center; flex-wrap: wrap; font-size: 0.82rem; color: var(--text-muted); }
.legend i.sw { width: 14px; height: 14px; border-radius: 3px; display: inline-block; margin-right: 7px; vertical-align: -2px; border: 1px solid rgba(0, 0, 0, 0.1); }
.sw--disp { background: #fff; border-color: var(--accent-blue); }
.sw--res { background: #fbe7d6; border-color: var(--accent-gold); }
.sw--vend { background: #e2e8f0; }

/* ==========================================================================
   MENÚ MÓVIL (hamburguesa)
   ========================================================================== */
.nav-burger { display: none; flex-direction: column; gap: 5px; padding: 6px; }
.nav-burger span { width: 24px; height: 2px; background: var(--primary-dark); border-radius: 2px; transition: var(--transition-fast); }
.nav-burger.active span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-burger.active span:nth-child(2) { opacity: 0; }
.nav-burger.active span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

@media (max-width: 1024px) {
  .plano-grid { grid-template-columns: 1fr; }
  .plano-panel { position: static; }
}

@media (max-width: 768px) {
  .nav-burger { display: flex; }
  #nav-cta { display: none; }
  .nav-menu {
    position: fixed; top: var(--header-height); left: 0; right: 0;
    flex-direction: column; gap: 0; background: #fff;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
    max-height: 0; overflow: hidden; padding: 0;
    transition: max-height 0.4s ease, padding 0.4s ease;
  }
  .nav-menu.open { max-height: 80vh; padding: 16px 0; display: flex; }
  .nav-menu .nav-link { padding: 14px 24px; width: 100%; font-size: 1.05rem; }
  .nav-item-dropdown { width: 100%; }
  .dropdown-menu { position: static; opacity: 1; visibility: visible; transform: none; box-shadow: none; width: 100%; margin: 0; padding: 0 0 8px; }
  .dropdown-menu::before { display: none; }
  .panel-dims { grid-template-columns: 1fr 1fr; }
}

.model-badge { z-index: 6; }

/* ==========================================================================
   AMENIDADES — imagen al pasar el mouse
   ========================================================================== */
.amenity-card { position: relative; overflow: hidden; min-height: 260px; }
.amenity-content { position: relative; z-index: 2; transition: color 0.4s ease; }
.amenity-media {
  position: absolute; inset: 0; z-index: 1;
  background-size: cover; background-position: center;
  background-color: var(--primary-dark);
  display: flex; align-items: center; justify-content: center;
  opacity: 0; transform: scale(1.06);
  transition: opacity 0.5s ease, transform 0.6s ease;
}
.amenity-media::after {
  content: ''; position: absolute; inset: 0;
  background: linear-gradient(to top, rgba(11, 37, 69, 0.88), rgba(11, 37, 69, 0.4));
}
.amenity-card:hover .amenity-media { opacity: 1; transform: scale(1); }
.amenity-media-soon {
  position: relative; z-index: 1; color: rgba(255, 255, 255, 0.85);
  font-family: var(--font-headings); font-size: 0.85rem; font-weight: 600;
  display: flex; align-items: center; gap: 8px;
}
.amenity-card:hover h3, .amenity-card:hover p { color: #fff !important; }
.amenity-card:hover .amenity-icon { background: rgba(255, 255, 255, 0.18); color: #fff; transform: scale(1.05); }

/* ==========================================================================
   LIGHTBOX — zoom de fotos al hacer clic
   ========================================================================== */
.gallery-main-img { cursor: zoom-in; }
.lightbox {
  position: fixed; inset: 0; z-index: 3000;
  display: flex; align-items: center; justify-content: center;
  background: rgba(6, 17, 33, 0.92);
  backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px);
  opacity: 0; pointer-events: none; transition: opacity 0.3s ease;
}
.lightbox.active { opacity: 1; pointer-events: all; }
.lightbox-img {
  max-width: 90vw; max-height: 85vh; object-fit: contain;
  border-radius: var(--border-radius-md);
  box-shadow: 0 25px 60px rgba(0, 0, 0, 0.5);
}
.lightbox-close {
  position: absolute; top: 24px; right: 28px;
  width: 44px; height: 44px; border-radius: 50%;
  background: rgba(255, 255, 255, 0.12); color: #fff; font-size: 1.8rem;
  display: flex; align-items: center; justify-content: center; transition: var(--transition-fast);
}
.lightbox-close:hover { background: rgba(255, 255, 255, 0.25); transform: scale(1.05); }
.lightbox-nav {
  position: absolute; top: 50%; transform: translateY(-50%);
  width: 52px; height: 52px; border-radius: 50%;
  background: rgba(255, 255, 255, 0.12); color: #fff; font-size: 1.3rem;
  display: flex; align-items: center; justify-content: center; transition: var(--transition-fast);
}
.lightbox-nav:hover { background: rgba(255, 255, 255, 0.25); }
.lb-prev { left: 24px; } .lb-next { right: 24px; }
@media (max-width: 768px) {
  .lightbox-nav { width: 42px; height: 42px; }
  .lb-prev { left: 10px; } .lb-next { right: 10px; }
}

/* ==========================================================================
   Ajustes finales — logos reales y galería con muchas fotos
   ========================================================================== */
.logo-img { height: 52px; }
.header--shrunk .logo-img { height: 42px; }

/* Miniaturas: scroll horizontal cuando hay muchas fotos */
.gallery-thumbs { overflow-x: auto; scrollbar-width: thin; }
.gallery-thumbs::-webkit-scrollbar { height: 6px; }
.gallery-thumbs::-webkit-scrollbar-thumb { background: var(--accent-light); border-radius: 3px; }

/* Logo blanco del footer (fondo oscuro) */
.footer-logo {
  height: 46px; width: auto; margin: 0 auto 24px; display: block;
  opacity: 0.95;
}

/* ==========================================================================
   CARRUSEL DE MODELOS — flechas, deslizamiento y seguridad de imágenes
   ========================================================================== */
.model-display { position: relative; }

/* Flechas para deslizar entre modelos */
.model-arrow {
  position: absolute; top: 190px; transform: translateY(-50%);
  width: 54px; height: 54px; border-radius: 50%;
  background: #fff; color: var(--primary-dark);
  border: 1px solid rgba(0, 0, 0, 0.05);
  box-shadow: 0 10px 28px rgba(11, 37, 69, 0.18);
  display: flex; align-items: center; justify-content: center;
  font-size: 1.15rem; z-index: 20; transition: var(--transition-smooth);
}
.model-arrow:hover { background: var(--primary-medium); color: #fff; transform: translateY(-50%) scale(1.08); }
.model-arrow--prev { left: -26px; }
.model-arrow--next { right: -26px; }

/* Animación de entrada al deslizar */
@keyframes cardInRight {
  from { opacity: 0; transform: translateX(48px) scale(0.99); }
  to   { opacity: 1; transform: translateX(0) scale(1); }
}
@keyframes cardInLeft {
  from { opacity: 0; transform: translateX(-48px) scale(0.99); }
  to   { opacity: 1; transform: translateX(0) scale(1); }
}

/* Las imágenes/medios nunca exceden su contenedor (no rompen el diseño) */
.gallery-stage > *, .gallery-main-img, .gallery-main-video, .gallery-main-iframe {
  width: 100%; height: 100%; max-width: 100%; object-fit: cover;
}

/* En pantallas chicas: flechas centradas abajo + swipe táctil */
@media (max-width: 1024px) {
  .model-arrow { top: auto; bottom: -22px; transform: none; width: 48px; height: 48px; }
  .model-arrow:hover { transform: scale(1.08); }
  .model-arrow--prev { left: calc(50% - 60px); }
  .model-arrow--next { right: calc(50% - 60px); }
  .model-display { padding-bottom: 40px; }
}

/* ==========================================================================
   MODELOS — cuadrícula minimalista (rediseño)
   ========================================================================== */
.mgrid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 28px; }
@media (max-width: 1024px) { .mgrid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 600px)  { .mgrid { grid-template-columns: 1fr; } }

.mcard {
  position: relative;
  background: #fff; border: 1px solid rgba(11, 37, 69, 0.07);
  border-radius: var(--border-radius-lg); overflow: hidden;
  display: flex; flex-direction: column;
  box-shadow: 0 6px 24px rgba(11, 37, 69, 0.05);
  transition: var(--transition-smooth);
}
/* Línea de acento superior que se dibuja al pasar el cursor */
.mcard::before {
  content: ""; position: absolute; top: 0; left: 0; right: 0; height: 3px; z-index: 4;
  background: linear-gradient(90deg, var(--accent-blue), var(--accent-gold));
  transform: scaleX(0); transform-origin: left;
  transition: transform 0.45s cubic-bezier(0.16, 1, 0.3, 1);
}
.mcard:hover { transform: translateY(-6px); box-shadow: 0 22px 50px rgba(11, 37, 69, 0.14); border-color: rgba(11, 37, 69, 0.04); }
.mcard:hover::before { transform: scaleX(1); }

.mcard__media {
  position: relative; width: 100%; aspect-ratio: 4 / 3; overflow: hidden;
  cursor: zoom-in; padding: 0; display: block; background: var(--bg-light);
}
.mcard__media img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.6s cubic-bezier(0.16,1,0.3,1); }
.mcard:hover .mcard__media img { transform: scale(1.06); }
/* Velo degradado inferior para dar profundidad y legibilidad al contador */
.mcard__media::after {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background: linear-gradient(to top, rgba(11, 37, 69, 0.35), transparent 45%);
}
/* Contenedor de etiquetas (apiladas) sobre la foto */
.mcard__badges {
  position: absolute; top: 14px; left: 14px; z-index: 2;
  display: flex; flex-direction: column; gap: 7px; align-items: flex-start;
}
.mcard__badge {
  background: linear-gradient(135deg, var(--primary-medium), var(--primary-dark)); color: #fff;
  font-family: var(--font-headings); font-weight: 600; font-size: 0.72rem;
  padding: 6px 13px; border-radius: 50px; letter-spacing: 0.02em;
  box-shadow: 0 4px 12px rgba(11, 37, 69, 0.28);
}
/* Cintillo de precio promocional (coral) */
.mcard__badge--promo { background: linear-gradient(135deg, #E9836B, #D8593A); }
.mcard__badge--promo i { margin-right: 4px; font-size: 0.66rem; }
.mcard__count {
  position: absolute; bottom: 14px; left: 14px; z-index: 2;
  background: rgba(11, 37, 69, 0.72); color: #fff; font-size: 0.74rem; font-weight: 500;
  padding: 5px 11px; border-radius: 50px; display: flex; align-items: center; gap: 6px;
  backdrop-filter: blur(4px);
}
.mcard__zoom {
  position: absolute; top: 14px; right: 14px; z-index: 2; width: 34px; height: 34px; border-radius: 50%;
  background: rgba(255, 255, 255, 0.92); color: var(--primary-dark);
  display: flex; align-items: center; justify-content: center;
  opacity: 0; transform: scale(0.9); transition: var(--transition-smooth);
}
.mcard:hover .mcard__zoom { opacity: 1; transform: scale(1); }

.mcard__body { padding: 22px 22px 22px; display: flex; flex-direction: column; flex: 1; }
.mcard__title { font-size: 1.35rem; font-weight: 700; color: var(--primary-dark); margin-bottom: 16px; }

/* Franja de specs: 3 columnas iguales con divisores → look equilibrado */
.mcard__specs {
  list-style: none; margin: 0 0 18px; padding: 14px 6px;
  display: grid; grid-template-columns: repeat(3, 1fr);
  background: var(--bg-light);
  border: 1px solid rgba(11, 37, 69, 0.06);
  border-radius: var(--border-radius-md);
}
.mcard__specs li {
  position: relative; display: flex; flex-direction: column; align-items: center; gap: 2px;
  padding: 0 4px; text-align: center;
}
.mcard__specs li + li::before {
  content: ""; position: absolute; left: 0; top: 50%; transform: translateY(-50%);
  width: 1px; height: 36px; background: rgba(11, 37, 69, 0.10);
}
.mcard__specs i { color: var(--accent-blue); font-size: 0.95rem; margin-bottom: 3px; }
.mcard__specs b { font-family: var(--font-headings); font-size: 1.18rem; font-weight: 700; color: var(--primary-dark); line-height: 1; }
.mcard__specs span { font-size: 0.68rem; font-weight: 600; color: var(--text-muted); letter-spacing: 0.01em; }

/* Precio: "Desde" pequeño + monto grande, alineados a la base */
.mcard__price { display: flex; align-items: baseline; gap: 8px; margin: 0 0 20px; flex-wrap: wrap; }
.mcard__price-label { font-size: 0.82rem; font-weight: 600; color: var(--text-muted); }
.mcard__price b { font-family: var(--font-headings); font-size: 1.5rem; font-weight: 800; color: var(--primary-dark); line-height: 1; }
/* Precio anterior tachado (promo) */
.mcard__price-old { font-size: 1rem; font-weight: 600; color: var(--text-muted); text-decoration: line-through; text-decoration-color: rgba(216, 89, 58, 0.85); }
.mcard__price--promo b { color: #D8593A; }
/* Leyenda pequeña de la promo (ej. "*Precio válido para las primeras 100 viviendas") */
.mcard__promo-note { margin: -12px 0 16px; font-size: 0.72rem; font-style: italic; color: var(--text-muted); line-height: 1.35; }

.mcard__actions { margin-top: auto; display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.mcard__btn { padding: 12px 10px; font-size: 0.84rem; border-radius: var(--border-radius-sm); }

/* ==========================================================================
   LIGHTBOX de galería (fotos + video)
   ========================================================================== */
.lightbox-stage { display: flex; align-items: center; justify-content: center; max-width: 92vw; max-height: 86vh; }
.lightbox-media { max-width: 92vw; max-height: 86vh; border-radius: var(--border-radius-md); box-shadow: 0 25px 60px rgba(0, 0, 0, 0.5); }
img.lightbox-media { object-fit: contain; }
video.lightbox-media { width: auto; background: #000; }
.lightbox-media--iframe { width: 90vw; max-width: 1100px; aspect-ratio: 16 / 9; height: auto; max-height: 86vh; border: 0; }
.lightbox-counter {
  position: absolute; bottom: 22px; left: 50%; transform: translateX(-50%);
  color: #fff; font-size: 0.82rem; font-family: var(--font-headings);
  background: rgba(255, 255, 255, 0.12); padding: 6px 14px; border-radius: 50px;
}

/* ==========================================================================
   UBICACIÓN — mapa real (iframe) y footer minimalista
   ========================================================================== */
.map-frame iframe { width: 100%; height: 100%; border: 0; display: block; }

.footer-address { margin-bottom: 18px; color: var(--accent-light); }
.footer-address i { color: var(--accent-blue); margin-right: 6px; }
.footer-wa { display: inline-flex; margin-bottom: 26px; }
.footer-copy { font-size: 0.8rem; opacity: 0.65; }

/* ==========================================================================
   DETALLE AMPLIADO DEL MODELO (modal)
   ========================================================================== */
.mdetail {
  position: fixed; inset: 0; z-index: 1800;
  display: flex; align-items: center; justify-content: center; padding: 24px;
  opacity: 0; pointer-events: none; transition: opacity 0.35s ease;
}
.mdetail.active { opacity: 1; pointer-events: all; }
.mdetail__overlay { position: absolute; inset: 0; background: rgba(6, 17, 33, 0.78); backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px); }
.mdetail__panel {
  position: relative; z-index: 2; width: 100%; max-width: 980px; max-height: 90vh; overflow: auto;
  background: #fff; border-radius: var(--border-radius-lg);
  display: grid; grid-template-columns: 1.05fr 0.95fr;
  box-shadow: 0 30px 70px rgba(0, 0, 0, 0.4);
  transform: scale(0.97); transition: transform 0.35s cubic-bezier(0.16, 1, 0.3, 1);
}
.mdetail.active .mdetail__panel { transform: scale(1); }
.mdetail__close {
  position: absolute; top: 14px; right: 14px; z-index: 6;
  width: 38px; height: 38px; border-radius: 50%;
  background: rgba(255, 255, 255, 0.92); color: var(--primary-dark); font-size: 1.5rem;
  display: flex; align-items: center; justify-content: center; box-shadow: 0 4px 12px rgba(0, 0, 0, 0.12);
}
.mdetail__close:hover { background: #fff; transform: scale(1.05); }

.mdetail__gallery { background: var(--bg-light); display: flex; flex-direction: column; }
.mdetail__main { height: 340px; }
.mdetail__info { padding: 26px 32px; display: flex; flex-direction: column; }
.mdetail__title { font-size: 1.9rem; color: var(--primary-dark); margin-bottom: 6px; }
.mdetail__desc { color: var(--text-muted); margin: 12px 0 14px; font-size: 0.98rem; }
.mdetail__features { display: grid; grid-template-columns: 1fr 1fr; gap: 8px 18px; margin-bottom: 14px; }
.mdetail__features li { display: flex; align-items: center; gap: 8px; font-size: 0.9rem; color: var(--text-dark); }
.mdetail__features i { color: var(--accent-blue); font-size: 0.78rem; }
.mdetail__price { font-family: var(--font-headings); color: var(--text-muted); margin-bottom: 14px; }
.mdetail__price b { font-size: 1.7rem; color: var(--primary-dark); font-weight: 800; }
.mdetail__promo-tag { display: inline-flex; align-items: center; gap: 6px; background: linear-gradient(135deg, #E9836B, #D8593A); color: #fff; font-weight: 700; font-size: 0.72rem; letter-spacing: 0.03em; text-transform: uppercase; padding: 5px 12px; border-radius: 50px; margin-bottom: 8px; }
.mdetail__price-line { display: block; }
.mdetail__price-line s { font-size: 1.15rem; font-weight: 600; color: var(--text-muted); text-decoration: line-through; text-decoration-color: rgba(216, 89, 58, 0.85); margin: 0 4px; }
.mdetail__price-line b { color: #D8593A; }
.mdetail__promo-note { display: block; margin-top: 6px; font-size: 0.78rem; font-style: italic; font-weight: 400; color: var(--text-muted); font-family: var(--font-body); }
.mdetail__ctas { margin-top: auto; display: flex; gap: 12px; flex-wrap: wrap; }
.mdetail__ctas .btn { flex: 1; min-width: 170px; }

@media (max-width: 780px) {
  .mdetail { padding: 0; }
  .mdetail__panel { grid-template-columns: 1fr; max-height: 100vh; border-radius: 0; }
  .mdetail__main { height: 250px; }
  .mdetail__info { padding: 24px; }
  .mdetail__features { grid-template-columns: 1fr; }
}

/* ==========================================================================
   Tarjetas de modelos uniformes + tope de resolución al ampliar
   ========================================================================== */
/* Título en una sola línea → todas las tarjetas con la misma altura */
.mcard__title { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.mcard__specs span { white-space: nowrap; }

/* Foto de previsualización un poco más contenida */
.mcard__media { aspect-ratio: 16 / 11; }

/* Galería del detalle un poco más pequeña */
.mdetail__main { height: 300px; }

/* Al ampliar (lightbox): resolución máxima 1080 x 1920 */
.lightbox-media { max-width: min(92vw, 1080px); max-height: min(86vh, 1920px); }
img.lightbox-media { width: auto; height: auto; }

/* ==========================================================================
   Detalle del modelo: SIEMPRE idéntico (no importa cuántas fotos tenga)
   ========================================================================== */
/* Evita que la fila de miniaturas ensanche la columna de la galería */
.mdetail__gallery { min-width: 0; }
.mdetail__thumbs { min-width: 0; flex-wrap: nowrap; }
.mdetail__thumbs .gallery-thumb { flex: 0 0 auto; } /* mantienen tamaño y se deslizan */

/* Altura uniforme del modal en escritorio → todos se ven igual */
@media (min-width: 781px) {
  .mdetail__panel { height: min(600px, 90vh); }
  .mdetail__main { flex: 1 1 auto; height: auto; }
}

/* ==========================================================================
   UBICACIÓN — puntos de interés clicables que cambian el mapa
   ========================================================================== */
.location-hint { color: var(--text-muted); font-size: 0.86rem; margin-bottom: 16px; }
.location-hint i { color: var(--accent-blue); margin-right: 6px; }

.landmark-item {
  width: 100%; text-align: left; font: inherit; cursor: pointer;
  align-items: center;
}
.landmark-item .landmark-go {
  margin-left: auto; color: var(--accent-light); font-size: 0.85rem;
  transition: var(--transition-fast); flex-shrink: 0;
}
.landmark-item:hover .landmark-go { color: var(--accent-blue); transform: translateX(3px); }
.landmark-item.active {
  border-color: var(--accent-blue);
  box-shadow: 0 8px 25px rgba(0, 180, 216, 0.14);
}
.landmark-item.active .landmark-icon { background: var(--accent-blue); color: #fff; }
.landmark-item.active .landmark-go { color: var(--accent-blue); }

/* Botón "Cómo llegar en Google Maps" bajo el mapa */
.map-cta {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  width: 100%; margin-top: 14px; padding: 14px;
  border-radius: var(--border-radius-sm);
  background: var(--primary-medium); color: #fff;
  font-family: var(--font-headings); font-weight: 600; font-size: 0.92rem;
  transition: var(--transition-smooth);
}
.map-cta:hover { background: var(--accent-blue); transform: translateY(-2px); box-shadow: 0 8px 20px rgba(0, 180, 216, 0.25); }
.map-cta__ext { font-size: 0.76rem; opacity: 0.85; }

/* Imagen de ruta (reemplaza al mapa embebido) */
.location-map .map-frame { aspect-ratio: 41 / 26; }
.route-img { width: 100%; height: 100%; object-fit: cover; display: block; background: #eef3f8; }

/* ==========================================================================
   Mapa de ubicación (OpenStreetMap) para orientarse + selects del form
   ========================================================================== */
.location-fullmap { margin-top: clamp(32px, 5vw, 56px); }
.location-fullmap__head { display: flex; align-items: center; justify-content: space-between; gap: 16px; margin-bottom: 18px; flex-wrap: wrap; }
.location-fullmap__head h3 { font-size: 1.25rem; color: var(--primary-dark); display: flex; align-items: center; gap: 10px; }
.location-fullmap__head h3 i { color: var(--accent-blue); }
.locmap-link { font-family: var(--font-headings); font-weight: 600; font-size: 0.9rem; color: var(--primary-medium); display: inline-flex; align-items: center; gap: 8px; }
.locmap-link:hover { color: var(--accent-blue); }
.locmap-osm { width: 100%; height: 440px; border: 1px solid rgba(0,0,0,0.08); border-radius: var(--border-radius-lg); display: block; box-shadow: 0 12px 30px rgba(11,37,69,0.06); }
@media (max-width: 768px) { .locmap-osm { height: 340px; } }

/* Selects del formulario de contacto (tema oscuro) */
.contact-form select.form-input { color: #fff; cursor: pointer; appearance: none;
  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 fill='none' stroke='%238DA9C4' stroke-width='1.6' d='M1 1l5 5 5-5'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right 16px center; }
.contact-form select.form-input option { color: #000; }
.contact-form select.form-input:invalid { color: var(--accent-light); }

/* ==========================================================================
   MAPA DE RUTA (Leaflet + OpenStreetMap)
   ========================================================================== */
.route-map {
  width: 100%; height: 460px; z-index: 1;
  border-radius: var(--border-radius-lg);
  border: 1px solid rgba(0, 0, 0, 0.08);
  box-shadow: 0 12px 30px rgba(11, 37, 69, 0.06);
  background: #eef3f8;
}
@media (max-width: 768px) { .route-map { height: 360px; } }

.route-pin span {
  display: block; width: 16px; height: 16px; border-radius: 50%;
  border: 3px solid #fff; box-shadow: 0 2px 6px rgba(11, 37, 69, 0.45);
}
.route-badge {
  background: var(--primary-dark); color: #fff;
  font-family: var(--font-headings); font-weight: 700; font-size: 0.82rem;
  padding: 8px 14px; border-radius: 50px; box-shadow: 0 4px 12px rgba(0, 0, 0, 0.22);
}
.route-badge i { color: #00E0A4; margin-right: 6px; }
.leaflet-container { font-family: var(--font-body); }

/* ==========================================================================
   AMENIDADES — tarjetas con efecto flip (foto al pasar el cursor)
   ========================================================================== */
.amenity-card { background: transparent; border: none; box-shadow: none; padding: 0; min-height: 0; overflow: visible; perspective: 1200px; cursor: pointer; }
.amenity-card:hover { transform: none; box-shadow: none; background: transparent; }
.amenity-card .flip { position: relative; width: 100%; height: 300px; transform-style: preserve-3d; transition: transform 0.7s cubic-bezier(0.2, 1, 0.3, 1); }
.amenity-card:hover .flip,
.amenity-card.is-flipped .flip { transform: rotateY(180deg); }

.flip__front, .flip__back {
  position: absolute; inset: 0; -webkit-backface-visibility: hidden; backface-visibility: hidden;
  border-radius: var(--border-radius-md); overflow: hidden;
}
.flip__front {
  background: var(--bg-light); border: 1px solid rgba(0, 0, 0, 0.05);
  display: flex; flex-direction: column; justify-content: center; padding: 32px 28px;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.02);
}
.amenity-card:hover .amenity-icon { background: rgba(0, 180, 216, 0.08); color: var(--accent-blue); transform: none; }
.amenity-card:hover h3, .amenity-card:hover p { color: inherit !important; }
.flip__hint { margin-top: 18px; font-size: 0.75rem; font-weight: 600; color: var(--accent-blue); display: inline-flex; align-items: center; gap: 7px; }

.flip__back { transform: rotateY(180deg); background-size: cover; background-position: center; background-color: var(--primary-dark); }
.flip__back::after { content: ''; position: absolute; inset: 0; background: linear-gradient(to top, rgba(11, 37, 69, 0.9) 0%, rgba(11, 37, 69, 0.15) 55%, rgba(11, 37, 69, 0) 100%); }
.flip__back-title { position: absolute; left: 22px; bottom: 18px; z-index: 2; color: #fff; font-family: var(--font-headings); font-weight: 700; font-size: 1.2rem; }
@media (max-width: 768px) { .amenity-card .flip { height: 270px; } }

/* Etiqueta permanente del pin de origen en el mapa */
.leaflet-tooltip.pin-home-label {
  background: var(--primary-dark); color: #fff; border: none;
  font-family: var(--font-headings); font-weight: 700; font-size: 0.8rem;
  padding: 5px 12px; border-radius: 50px; box-shadow: 0 3px 10px rgba(0, 0, 0, 0.3);
}
.leaflet-tooltip.pin-home-label::before { border-top-color: var(--primary-dark); }

/* ==========================================================================
   HERO BANNER — slideshow de amenidades, degradado y texto animado
   ========================================================================== */
.hero { position: relative; height: 100vh; min-height: 620px; display: flex; align-items: center; overflow: hidden; background: var(--bg-dark); padding-top: var(--header-height); }
.hero::before { display: none !important; }

.hero-slides { position: absolute; inset: 0; z-index: 0; }
.hero-slide {
  position: absolute; inset: 0; background-size: cover; background-position: center;
  opacity: 0; transform: scale(1.06); transition: opacity 1.4s ease; will-change: opacity, transform;
}
.hero-slide.is-active { opacity: 1; animation: heroKenburns 8s ease forwards; }
@keyframes heroKenburns { from { transform: scale(1.06); } to { transform: scale(1.15); } }

.hero-overlay {
  position: absolute; inset: 0; z-index: 1; pointer-events: none;
  background:
    linear-gradient(95deg, rgba(6,17,33,0.92) 0%, rgba(6,17,33,0.72) 36%, rgba(6,17,33,0.28) 68%, rgba(6,17,33,0.08) 100%),
    linear-gradient(0deg, rgba(6,17,33,0.7) 0%, rgba(6,17,33,0) 45%);
}

.hero-content { position: relative; z-index: 2; width: 100%; }
.hero-content .hero-tag { display: inline-flex; background: rgba(255,255,255,0.12); border: 1px solid rgba(255,255,255,0.22); color: #fff; backdrop-filter: blur(4px); }
.hero-content .hero-tag i { color: var(--accent-blue); }
.hero-title { color: #fff; font-size: clamp(2.4rem, 6vw, 4.7rem); line-height: 1.02; letter-spacing: -1.5px; margin-bottom: 16px; text-shadow: 0 6px 34px rgba(0,0,0,0.35); }
.hero-accent { background: linear-gradient(100deg, var(--accent-blue), #9cecff); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; }
.hero-hook { font-family: var(--font-headings); font-weight: 600; font-size: clamp(1.05rem, 2.1vw, 1.5rem); color: #fff; margin-bottom: 14px; max-width: 620px; min-height: 1.5em; transition: opacity .5s ease, transform .5s ease; }
.hero-desc { color: rgba(255,255,255,0.82); font-size: 1.08rem; margin-bottom: 34px; max-width: 540px; }
.hero-desc strong { color: #fff; }
.hero-ctas { display: flex; gap: 14px; align-items: center; flex-wrap: wrap; }
.btn-hero-ghost { background: rgba(255,255,255,0.08); border: 1.5px solid rgba(255,255,255,0.55); color: #fff; backdrop-filter: blur(4px); }
.btn-hero-ghost:hover { background: #fff; color: var(--primary-dark); transform: translateY(-2px); }

.hero-dots { display: flex; gap: 10px; margin-top: 38px; }
.hero-dot { width: 30px; height: 4px; border-radius: 4px; background: rgba(255,255,255,0.32); transition: all .45s cubic-bezier(0.16,1,0.3,1); cursor: pointer; padding: 0; }
.hero-dot:hover { background: rgba(255,255,255,0.6); }
.hero-dot.is-active { background: var(--accent-blue); width: 46px; }

.hero-scroll-indicator { color: rgba(255,255,255,0.78); z-index: 2; }
.hero-scroll-indicator .scroll-mouse { border-color: rgba(255,255,255,0.55); }

/* Entrada del texto (efecto minimalista escalonado) */
.hero-content .hero-tag,
.hero-content .hero-title,
.hero-content .hero-desc,
.hero-content .hero-ctas,
.hero-content .hero-dots { opacity: 0; transform: translateY(24px); animation: heroUp 0.9s cubic-bezier(0.16,1,0.3,1) forwards; }
.hero-content .hero-tag { animation-delay: 0.15s; }
.hero-content .hero-title { animation-delay: 0.32s; }
.hero-content .hero-desc { animation-delay: 0.6s; }
.hero-content .hero-ctas { animation-delay: 0.74s; }
.hero-content .hero-dots { animation-delay: 0.88s; }
.hero-hook { animation: heroUp 0.9s cubic-bezier(0.16,1,0.3,1) 0.46s both; }
@keyframes heroUp { to { opacity: 1; transform: none; } }

@media (max-width: 768px) {
  .hero-overlay { background: linear-gradient(0deg, rgba(6,17,33,0.94) 0%, rgba(6,17,33,0.5) 50%, rgba(6,17,33,0.62) 100%); }
  .hero-desc { font-size: 1rem; }
  .hero-dots { margin-top: 28px; }
}
@media (prefers-reduced-motion: reduce) {
  .hero-slide.is-active { animation: none; }
  .hero-content > * { animation: none !important; opacity: 1 !important; transform: none !important; }
}

/* Respaldo Grupo EconoBlock en el footer */
.footer-backed { font-size: 0.72rem; letter-spacing: 0.14em; text-transform: uppercase; color: rgba(141, 169, 196, 0.7); margin-bottom: 14px; }
.footer-backed strong { color: rgba(255, 255, 255, 0.88); font-weight: 700; letter-spacing: 0.08em; }

/* Logo Grupo EconoBlock en el footer (más pequeño que el de Villa Marina's) */
.footer-geb-wrap { margin-bottom: 18px; }
.footer-geb { height: 22px; width: auto; max-width: 170px; margin: 0 auto; display: block; opacity: 0.85; }
.footer-geb-wrap .footer-backed { margin-bottom: 9px; }
