/* ==========================================
   RESET & VARIABLES
   ========================================== */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

:root {
  --primary-green: #10b981;
  --primary-green-hover: #059669;
  --overlay-color: rgba(10, 45, 42, 0.72);
  --text-white: #ffffff;
  --font-serif: 'Playfair Display', serif;
  --font-sans: 'Montserrat', sans-serif;
}

body {
  font-family: var(--font-sans);
  color: var(--text-white);
  overflow-x: hidden;
}

/* ==========================================
   HERO SECTION & BACKGROUND
   ========================================== */
.hero {
  position: relative;
  width: 100%;
  min-height: 100vh;
  background: url('https://images.unsplash.com/photo-1600596542815-ffad4c1539a9?q=80&w=2075&auto=format&fit=crop') center/cover no-repeat;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
}

.hero-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: var(--overlay-color);
  z-index: 1;
}

.hero-content {
  position: relative;
  z-index: 2;
  width: 100%;
  height: 100vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
}

/* ==========================================
   NAVBAR & LOGO (FIXED SCROLL)
   ========================================== */
.navbar {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 1000;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1.2rem 5%;
  transition: background-color 0.3s ease, padding 0.3s ease, box-shadow 0.3s ease;
}

/* ==========================================
   NAVBAR & LOGOS (CONTROL DE MOSTRAR / OCULTAR)
   ========================================== */
.logo-img {
  height: 160px;
  width: auto;
  object-fit: contain;
  transition: height 0.3s ease;
}

/* Por defecto (arriba en el Hero) */
.logo-white {
  display: block;
}

.logo-green {
  display: none; /* Oculto inicialmente */
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 2.5rem;
  list-style: none;
}

.nav-links a {
  color: var(--text-white);
  text-decoration: none;
  font-size: 0.95rem;
  font-weight: 500;
  transition: color 0.3s ease, opacity 0.3s ease;
}

.nav-links a:hover {
  opacity: 0.8;
}

.btn-nav {
  background-color: var(--primary-green);
  color: var(--text-white);
  padding: 0.7rem 1.6rem;
  border-radius: 50px;
  font-weight: 500;
  transition: background-color 0.3s ease;
}

.btn-nav:hover {
  background-color: var(--primary-green-hover);
}

/* ==========================================
   ESTADO AL HACER SCROLL (HEADER BLANCO)
   ========================================== */
.navbar.navbar-scrolled {
  background-color: #ffffff;
  padding: 0.8rem 5%;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
}

/* Intercambio de logos al bajar */
.navbar.navbar-scrolled .logo-white {
  display: none; /* Oculta el logo blanco */
}

.navbar.navbar-scrolled .logo-green {
  display: block; /* Muestra el logo verde original */
  height: 100px;   /* Tamaño compacto opcional al bajar */
  filter: none;   /* Sin filtros para mantener sus colores puros */
}

/* Textos y botones en verde #004D40 */
.navbar.navbar-scrolled .nav-links a {
  color: #004D40;
}

.navbar.navbar-scrolled .nav-links a:hover {
  color: var(--primary-green);
}

.navbar.navbar-scrolled .btn-nav {
  background-color: #004D40;
  color: #ffffff !important;
}

.navbar.navbar-scrolled .btn-nav:hover {
  background-color: var(--primary-green-hover);
}

/* ==========================================
   HERO MAIN TEXT & BUTTONS
   ========================================== */
.hero-center {
  text-align: center;
  max-width: 900px;
  margin: 0 auto;
  padding: 0 20px;
}

.hero-title {
  font-family: var(--font-serif);
  font-size: 3.8rem;
  font-weight: 500;
  line-height: 1.2;
  margin-bottom: 1.2rem;
  letter-spacing: 0.5px;
}

.hero-subtitle {
  font-size: 1.1rem;
  font-weight: 300;
  margin-bottom: 2.5rem;
  opacity: 0.95;
}

.cta-container {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 1.2rem;
}

.btn-primary {
  background-color: var(--primary-green);
  color: var(--text-white);
  border: none;
  padding: 0.9rem 2rem;
  border-radius: 12px;
  font-size: 1rem;
  font-weight: 500;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  text-decoration: none;
  transition: background-color 0.3s ease, transform 0.2s ease;
}

.btn-primary:hover {
  background-color: var(--primary-green-hover);
  transform: translateY(-2px);
}

.btn-secondary {
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.3);
  color: var(--text-white);
  padding: 0.9rem 2rem;
  border-radius: 12px;
  font-size: 1rem;
  font-weight: 400;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  backdrop-filter: blur(4px);
  transition: background-color 0.3s ease, border-color 0.3s ease;
}

.btn-secondary:hover {
  background: rgba(255, 255, 255, 0.18);
  border-color: rgba(255, 255, 255, 0.6);
}

/* ==========================================
   SCROLL INDICATOR
   ========================================== */
.scroll-indicator {
  position: absolute;
  bottom: 2rem;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  justify-content: center;
}

.mouse-icon {
  width: 26px;
  height: 42px;
  border: 2px solid rgba(255, 255, 255, 0.7);
  border-radius: 20px;
  display: flex;
  justify-content: center;
  padding-top: 8px;
  cursor: pointer;
}

.wheel {
  width: 4px;
  height: 8px;
  background-color: white;
  border-radius: 2px;
  animation: scroll 1.8s infinite;
}

@keyframes scroll {
  0% { opacity: 1; transform: translateY(0); }
  100% { opacity: 0; transform: translateY(12px); }
}

/* ==========================================
   FLOATING CHAT BUTTON (WhatsApp)
   ========================================== */
.floating-chat {
  position: fixed;
  bottom: 30px;
  right: 30px;
  width: 56px;
  height: 56px;
  background-color: #25d366;
  border-radius: 50%;
  display: flex;
  justify-content: center;
  align-items: center;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
  cursor: pointer;
  z-index: 999;
  transition: transform 0.3s ease;
}

.floating-chat:hover {
  transform: scale(1.1);
}

/* ==========================================
   CATEGORIES SECTION
   ========================================== */
.categories-section {
  background-color: #f1f8f5; /* Fondo verde muy claro tenue */
  padding: 5rem 5%;
  color: #0d2822;
}

.categories-header {
  text-align: center;
  margin-bottom: 3.5rem;
}

.categories-header h2 {
  font-family: var(--font-serif);
  font-size: 2.5rem;
  color: #0c382e;
  margin-bottom: 0.8rem;
  font-weight: 600;
}

.categories-header p {
  color: #527067;
  font-size: 1rem;
  font-weight: 400;
}

/* Grid layout */
.categories-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2rem;
  max-width: 1200px;
  margin: 0 auto;
}

/* Card Individual */
.category-card {
  position: relative;
  height: 380px;
  border-radius: 20px;
  overflow: hidden;
  background-size: cover;
  background-position: center;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.08);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.category-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 15px 30px rgba(0, 0, 0, 0.15);
}

/* Overlay degradado verdoso en la tarjeta */
.card-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(
    to top,
    rgba(10, 48, 40, 0.95) 0%,
    rgba(10, 48, 40, 0.4) 50%,
    rgba(0, 0, 0, 0.1) 100%
  );
  z-index: 1;
}

/* Contenido interno de la tarjeta */
.card-content {
  position: relative;
  z-index: 2;
  padding: 2rem;
  color: var(--text-white);
}

/* Icono dentro del botón verde redondeado */
.icon-wrapper {
  width: 44px;
  height: 44px;
  background-color: var(--primary-green);
  border-radius: 12px;
  display: flex;
  justify-content: center;
  align-items: center;
  margin-bottom: 1rem;
  color: var(--text-white);
}

.card-content h3 {
  font-family: var(--font-serif);
  font-size: 1.6rem;
  font-weight: 500;
  margin-bottom: 0.5rem;
}

.card-content p {
  font-size: 0.88rem;
  font-weight: 300;
  opacity: 0.9;
  margin-bottom: 1.2rem;
  line-height: 1.4;
}

.card-link {
  color: var(--text-white);
  text-decoration: none;
  font-size: 0.9rem;
  font-weight: 500;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  transition: gap 0.2s ease;
}

.category-card:hover .card-link {
  gap: 10px;
}

/* Responsivo para móviles y tablets */
@media (max-width: 992px) {
  .categories-grid {
    grid-template-columns: repeat(1, 1fr);
  }

  .category-card {
    height: 320px;
  }
}

/* ==========================================
   FEATURED PROPERTIES SECTION
   ========================================== */
.featured-properties-section {
  padding: 5rem 5%;
  background-color: #ffffff;
}

.featured-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  max-width: 1200px;
  margin: 0 auto 3rem auto;
}

.header-text h2 {
  font-family: var(--font-serif);
  font-size: 2.3rem;
  color: #0c382e;
  font-weight: 600;
  margin-bottom: 0.5rem;
}

.header-text p {
  color: #64748b;
  font-size: 0.95rem;
}

.see-all-link {
  color: var(--primary-green);
  text-decoration: none;
  font-weight: 600;
  font-size: 0.95rem;
  display: flex;
  align-items: center;
  gap: 6px;
  transition: opacity 0.2s ease;
}

.see-all-link:hover {
  opacity: 0.8;
}

/* Grid Layout */
.properties-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2rem;
  max-width: 1200px;
  margin: 0 auto;
}

/* Property Card */
.property-card {
  border-radius: 16px;
  overflow: hidden;
  background-color: #ffffff;
  border: 1px solid #e2e8f0;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.03);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  display: flex;
  flex-direction: column;
}

.property-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 25px rgba(0, 0, 0, 0.08);
}

/* Image & Badges Wrapper */
.card-image-wrapper {
  position: relative;
  width: 100%;
  height: 220px;
  overflow: hidden;
}

.property-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.badges-top-left {
  position: absolute;
  top: 12px;
  left: 12px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.badge {
  padding: 4px 12px;
  border-radius: 20px;
  font-size: 0.75rem;
  font-weight: 600;
  color: #ffffff;
  display: inline-block;
}

.badge-type {
  background-color: #064e3b; /* Verde oscuro */
}

.badge-sale {
  background-color: #3b82f6; /* Azul brillante */
}

.badge-featured {
  position: absolute;
  top: 12px;
  right: 12px;
  background-color: var(--primary-green);
}

/* Card Body */
.card-body {
  padding: 1.5rem;
  display: flex;
  flex-direction: column;
  flex-grow: 1;
}

.location {
  display: flex;
  align-items: center;
  gap: 6px;
  color: #64748b;
  font-size: 0.8rem;
  margin-bottom: 0.6rem;
}

.property-title {
  font-family: var(--font-serif);
  font-size: 1.25rem;
  color: #0c382e;
  font-weight: 600;
  margin-bottom: 0.8rem;
  line-height: 1.3;
}

.price {
  font-family: var(--font-sans);
  font-size: 1.4rem;
  font-weight: 700;
  color: var(--primary-green);
  margin-bottom: 1.2rem;
}

/* Features Icons Row */
.features-row {
  display: flex;
  align-items: center;
  gap: 1.2rem;
  padding-bottom: 1.2rem;
  border-bottom: 1px solid #f1f5f9;
  margin-bottom: 1.2rem;
}

.feature-item {
  display: flex;
  align-items: center;
  gap: 6px;
  color: #64748b;
  font-size: 0.85rem;
}

/* Actions Buttons */
.card-actions {
  display: flex;
  align-items: center;
  gap: 0.8rem;
  margin-top: auto;
}

.btn-more {
  flex: 1;
  background-color: #064e3b; /* Verde oscuro */
  color: #ffffff;
  text-decoration: none;
  padding: 0.7rem 1rem;
  border-radius: 20px;
  font-size: 0.9rem;
  font-weight: 500;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  transition: background-color 0.2s ease;
}

.btn-more:hover {
  background-color: #04382a;
}

.btn-whatsapp-icon {
  width: 40px;
  height: 40px;
  background-color: #25d366;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  transition: transform 0.2s ease, background-color 0.2s ease;
}

.btn-whatsapp-icon:hover {
  transform: scale(1.05);
}

/* Responsivo */
@media (max-width: 992px) {
  .properties-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 640px) {
  .properties-grid {
    grid-template-columns: 1fr;
  }
  .featured-header {
    flex-direction: column;
    align-items: flex-start;
    gap: 1rem;
  }
}

/* ==========================================
   SELLER BANNER
   ========================================== */
.seller-banner {
  background-color: #064e3b; /* Verde oscuro primario */
  position: relative;
  overflow: hidden;
  padding: 3.5rem 5%;
  color: #ffffff;
}

/* Efectos de círculos decorativos sutiles en las esquinas */
.seller-banner::before,
.seller-banner::after {
  content: '';
  position: absolute;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.04);
  pointer-events: none;
}

.seller-banner::before {
  width: 250px;
  height: 250px;
  top: -100px;
  left: -80px;
}

.seller-banner::after {
  width: 300px;
  height: 300px;
  bottom: -150px;
  right: -80px;
}

.seller-container {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  justify-content: space-between;
  align-items: center;
  position: relative;
  z-index: 2;
}

.seller-text h2 {
  font-family: var(--font-serif);
  font-size: 2.2rem;
  font-weight: 600;
  margin-bottom: 0.6rem;
}

.seller-text p {
  font-size: 0.95rem;
  font-weight: 300;
  opacity: 0.9;
  max-width: 650px;
  line-height: 1.4;
}

.btn-seller-whatsapp {
  background-color: #ffffff;
  color: #064e3b;
  font-family: var(--font-sans);
  font-weight: 700;
  font-size: 0.95rem;
  padding: 0.85rem 1.8rem;
  border-radius: 12px;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  white-space: nowrap;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.btn-seller-whatsapp:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.15);
}

/* ==========================================
   INSTAGRAM SECTION
   ========================================== */
.instagram-section {
  background-color: #f1f8f5; /* Fondo claro tenue */
  padding: 4.5rem 5%;
  text-align: center;
}

.instagram-header {
  display: flex;
  flex-direction: column;
  align-items: center;
  margin-bottom: 2.5rem;
}

.instagram-title-row {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 0.4rem;
}

.instagram-title-row h2 {
  font-family: var(--font-serif);
  font-size: 2.3rem;
  color: #0c382e;
  font-weight: 600;
}

.instagram-handle {
  color: #64748b;
  font-size: 1rem;
  font-weight: 400;
  margin-bottom: 1.2rem;
}

.btn-instagram {
  background-color: #064e3b;
  color: #ffffff;
  font-family: var(--font-sans);
  font-weight: 600;
  font-size: 0.88rem;
  padding: 0.6rem 1.5rem;
  border-radius: 20px;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  transition: background-color 0.2s ease;
}

.btn-instagram:hover {
  background-color: #04382a;
}

/* Grid de publicaciones */
.instagram-grid {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 1.2rem;
  max-width: 1200px;
  margin: 0 auto;
}

.insta-item {
  position: relative;
  aspect-ratio: 1 / 1;
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
  display: block;
}

.insta-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.3s ease;
}

.insta-item:hover img {
  transform: scale(1.06);
}

/* Overlay para videos/reels */
.play-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.25);
  display: flex;
  justify-content: center;
  align-items: center;
}

/* ==========================================
   RESPONSIVE DESIGN
   ========================================== */
@media (max-width: 992px) {
  .seller-container {
    flex-direction: column;
    text-align: center;
    gap: 1.8rem;
  }
  .instagram-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

@media (max-width: 576px) {
  .seller-text h2 {
    font-size: 1.8rem;
  }
  .instagram-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

/* ==========================================
   MAIN FOOTER
   ========================================== */
.main-footer {
  background-color: #04382a; /* Verde muy oscuro elegante */
  color: #e2e8f0;
  padding-top: 4.5rem;
  font-family: var(--font-sans);
}

.footer-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 5% 4rem 5%;
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1.6fr;
  gap: 2.5rem;
}

/* Columna Marca & Logo */
.footer-logo-img {
  height: 160px;
  width: auto;
  object-fit: contain;
  margin-bottom: 1.2rem;
}

.footer-description {
  font-size: 0.88rem;
  line-height: 1.6;
  color: rgba(255, 255, 255, 0.8);
  margin-bottom: 1.5rem;
  font-weight: 300;
}

.social-circle-icon {
  width: 38px;
  height: 38px;
  background: rgba(255, 255, 255, 0.1);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #ffffff;
  text-decoration: none;
  transition: background-color 0.2s ease, transform 0.2s ease;
}

.social-circle-icon:hover {
  background: var(--primary-green);
  transform: translateY(-2px);
}

/* Títulos de las Columnas */
.footer-col h3 {
  font-family: var(--font-serif);
  font-size: 1.15rem;
  color: #ffffff;
  font-weight: 600;
  margin-bottom: 1.5rem;
}

/* Enlaces */
.footer-links {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.8rem;
}

.footer-links a {
  color: rgba(255, 255, 255, 0.8);
  text-decoration: none;
  font-size: 0.9rem;
  font-weight: 300;
  transition: color 0.2s ease, padding-left 0.2s ease;
}

.footer-links a:hover {
  color: var(--primary-green);
  padding-left: 4px;
}

/* Columna de Contacto */
.contact-item {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 1.2rem;
  font-size: 0.88rem;
  color: rgba(255, 255, 255, 0.85);
  line-height: 1.4;
}

.contact-item.align-top {
  align-items: flex-start;
}

.contact-icon {
  color: var(--primary-green);
  flex-shrink: 0;
  margin-top: 2px;
}

.phones-list p {
  margin-bottom: 0.4rem;
  font-size: 0.88rem;
  color: rgba(255, 255, 255, 0.85);
}

.phones-list a, .email-link {
  color: rgba(255, 255, 255, 0.85);
  text-decoration: none;
  transition: color 0.2s ease;
}

.phones-list a:hover, .email-link:hover {
  color: var(--primary-green);
}

/* Footer Bottom / Copyright */
.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  padding: 1.5rem 0;
}

.bottom-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 5%;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.8rem;
  color: rgba(255, 255, 255, 0.6);
}

.legal-links {
  display: flex;
  gap: 1.5rem;
}

.legal-links a {
  color: rgba(255, 255, 255, 0.6);
  text-decoration: none;
  transition: color 0.2s ease;
}

.legal-links a:hover {
  color: #ffffff;
}

/* Responsivo */
@media (max-width: 992px) {
  .footer-container {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 576px) {
  .footer-container {
    grid-template-columns: 1fr;
    gap: 2rem;
  }
  
  .bottom-container {
    flex-direction: column;
    gap: 1rem;
    text-align: center;
  }
}

/* ==========================================
   RESPONSIVE DESIGN
   ========================================== */
@media (max-width: 768px) {
  .nav-links {
    display: none;
  }
  .hero-title {
    font-size: 2.3rem;
  }
  .hero-subtitle {
    font-size: 0.95rem;
  }
  .cta-container {
    flex-direction: column;
    width: 100%;
  }
  .btn-primary, .btn-secondary {
    width: 100%;
    justify-content: center;
  }
}


/* ==========================================
   NAVBAR BLANCO ESTÁTICO (Para la página Propiedades)
   ========================================== */
.navbar.navbar-static-white {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 1000;
  background-color: #004D40;
  padding: 0.8rem 5%;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
}

.navbar.navbar-static-white .logo-img {
  height: 90px;
}

.navbar.navbar-static-white .nav-links a {
  color: #ffff;
  font-weight: 300;
}

.navbar.navbar-static-white .nav-links a:hover,
.navbar.navbar-static-white .nav-links a.active {
  color: var(--primary-green);
  font-weight: 700;
  font: bold;
}

.navbar.navbar-static-white .btn-nav {
  background-color: #ffffff;
  color: #004D40 !important;
}

.navbar.navbar-static-white .btn-nav:hover {
  background-color: var(--primary-green-hover);
}

/* ==========================================
   PROPERTIES PAGE SPECIFIC STYLES
   ========================================== */
.properties-hero-section {
  background-color: #f1f8f5;
  padding: 8rem 5% 4rem 5%; /* Espacio superior para compensar el navbar fijo */
  margin-top: 50px;
}

.properties-header-container {
  max-width: 1200px;
  margin: 0 auto;
  text-align: center; /* Centra el título y el subtítulo */
}

.properties-header-container h1 {
  font-family: var(--font-serif);
  font-size: 2.8rem;
  color: #0c382e;
  margin-bottom: 0.5rem;
}

.properties-header-container p {
  color: #64748b;
  font-size: 1rem;
  margin-bottom: 2.5rem;
}
/* BARRA DE FILTROS */
.filter-bar {
  background-color: #ffffff;
  padding: 1.5rem 2rem;
  border-radius: 16px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.05);
  display: grid;
  grid-template-columns: repeat(3, 1fr) auto;
  gap: 1.5rem;
  align-items: end;
}

.filter-group {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.filter-group label {
  font-size: 0.82rem;
  font-weight: 600;
  color: #0c382e;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.filter-select {
  padding: 0.8rem 1rem;
  border: 1px solid #cbd5e1;
  border-radius: 10px;
  font-family: var(--font-sans);
  font-size: 0.95rem;
  color: #1e293b;
  outline: none;
  background-color: #f8fafc;
  transition: border-color 0.2s ease;
}

.filter-select:focus {
  border-color: #004D40;
}

.btn-search-filter {
  background-color: #004D40;
  color: #ffffff;
  border: none;
  padding: 0.85rem 2rem;
  border-radius: 10px;
  font-family: var(--font-sans);
  font-weight: 600;
  font-size: 0.95rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 8px;
  transition: background-color 0.2s ease;
  height: 48px;
}

.btn-search-filter:hover {
  background-color: #059669;
}

.badge-rent {
  background-color: #8b5cf6; /* Color Púrpura para alquileres */
}

/* SECCIÓN DEL CATÁLOGO */
.properties-catalog-section {
  padding: 4rem 5%;
  background-color: #ffffff;
}

.catalog-container {
  max-width: 1200px;
  margin: 0 auto;
}

.results-info {
  margin-bottom: 2rem;
  font-size: 0.95rem;
  color: #64748b;
}

/* FILTROS RESPONSIVE */
@media (max-width: 992px) {
  .filter-bar {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 640px) {
  .filter-bar {
    grid-template-columns: 1fr;
  }
}

/* ==========================================
   ABOUT PAGE SPECIFIC STYLES
   ========================================== */
.about-hero-section {
  background-color: #f1f8f5;
  padding: 8rem 5% 3.5rem 5%;
  text-align: center;
  margin-top: 40px;
}

.about-hero-container h1 {
  font-family: var(--font-serif);
  font-size: 2.8rem;
  color: #0c382e;
  margin-bottom: 0.5rem;
}

.about-hero-container p {
  color: #64748b;
  font-size: 1.05rem;
  max-width: 650px;
  margin: 0 auto;

}

/* HISTORIA / PRESENTACIÓN */
.about-story-section {
  padding: 5rem 5%;
  background-color: #ffffff;
}

.story-container {
  max-width: 1200px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr 1.1fr;
  gap: 4rem;
  align-items: center;
}

.story-image-wrapper {
  position: relative;
  border-radius: 20px;
  overflow: hidden;
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.08);
}

.story-img {
  width: 100%;
  height: 100%;
  max-height: 480px;
  object-fit: cover;
  display: block;
}

.experience-badge {
  position: absolute;
  bottom: 25px;
  right: 25px;
  background-color: #004D40;
  color: #ffffff;
  padding: 1.2rem 1.8rem;
  border-radius: 16px;
  display: flex;
  flex-direction: column;
  align-items: center;
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.15);
}

.exp-number {
  font-size: 2rem;
  font-weight: 700;
  line-height: 1;
}

.exp-text {
  font-size: 0.8rem;
  opacity: 0.9;
  margin-top: 4px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.story-content h2 {
  font-family: var(--font-serif);
  font-size: 2.2rem;
  color: #0c382e;
  margin-bottom: 1.2rem;
  line-height: 1.3;
}

.lead-text {
  font-size: 1.1rem;
  font-weight: 500;
  color: #334155;
  margin-bottom: 1rem;
  line-height: 1.6;
}

.story-content p {
  color: #64748b;
  line-height: 1.7;
  margin-bottom: 2rem;
  font-size: 0.95rem;
}

.stats-row {
  display: flex;
  gap: 3rem;
  border-top: 1px solid #e2e8f0;
  padding-top: 1.8rem;
}

.stat-item h3 {
  font-size: 2rem;
  color: var(--primary-green);
  font-weight: 700;
  margin-bottom: 0.2rem;
}

.stat-item p {
  margin-bottom: 0;
  font-size: 0.85rem;
  color: #64748b;
  font-weight: 500;
}

/* VALORES */
.values-section {
  background-color: #f8fafc;
  padding: 5rem 5%;
}

.values-container {
  max-width: 1200px;
  margin: 0 auto;
}

.section-title-center {
  text-align: center;
  margin-bottom: 3.5rem;
}

.section-title-center h2 {
  font-family: var(--font-serif);
  font-size: 2.3rem;
  color: #0c382e;
  margin-bottom: 0.5rem;
}

.section-title-center p {
  color: #64748b;
  font-size: 0.95rem;
}

.values-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2rem;
}

.value-card {
  background-color: #ffffff;
  padding: 2.5rem 2rem;
  border-radius: 16px;
  border: 1px solid #e2e8f0;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.03);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.value-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 12px 25px rgba(0, 0, 0, 0.08);
}

.value-icon {
  width: 50px;
  height: 50px;
  background-color: #e6f4f1;
  color: #004D40;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 1.5rem;
}

.value-card h3 {
  font-family: var(--font-serif);
  font-size: 1.3rem;
  color: #0c382e;
  margin-bottom: 0.8rem;
}

.value-card p {
  color: #64748b;
  font-size: 0.9rem;
  line-height: 1.6;
}

/* RESPONSIVE NOSOTROS */
@media (max-width: 992px) {
  .story-container {
    grid-template-columns: 1fr;
    gap: 2.5rem;
  }

  .values-grid {
    grid-template-columns: repeat(1, 1fr);
  }
}


/* ==========================================
   CONTACT PAGE SPECIFIC STYLES
   ========================================== */
.contact-hero-section {
  background-color: #f1f8f5;
  padding: 8rem 5% 3.5rem 5%;
  text-align: center;
  margin-top: 40px;
}

.contact-hero-container h1 {
  font-family: var(--font-serif);
  font-size: 2.8rem;
  color: #0c382e;
  margin-bottom: 0.5rem;
}

.contact-hero-container p {
  color: #64748b;
  font-size: 1.05rem;
  max-width: 650px;
  margin: 0 auto;
}

.contact-main-section {
  padding: 5rem 5%;
  background-color: #ffffff;
}

.contact-grid-container {
  max-width: 1200px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr 1.2fr;
  gap: 4rem;
}

/* COLUMNA IZQUIERDA: INFORMACIÓN */
.contact-info-column h2 {
  font-family: var(--font-serif);
  font-size: 2rem;
  color: #0c382e;
  margin-bottom: 0.5rem;
}

.contact-subtitle {
  color: #64748b;
  font-size: 0.95rem;
  margin-bottom: 2rem;
}

.info-card {
  display: flex;
  gap: 1.2rem;
  background-color: #f8fafc;
  padding: 1.5rem;
  border-radius: 16px;
  border: 1px solid #e2e8f0;
  margin-bottom: 1.2rem;
}

.info-icon {
  width: 48px;
  height: 48px;
  background-color: #e6f4f1;
  color: #004D40;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.info-text h3 {
  font-size: 1.1rem;
  color: #0c382e;
  margin-bottom: 0.4rem;
  font-family: var(--font-serif);
}

.info-text p {
  font-size: 0.9rem;
  color: #475569;
  line-height: 1.5;
  margin-bottom: 0.2rem;
}

.info-text a {
  color: #004D40;
  text-decoration: none;
  font-weight: 600;
}

.info-text a:hover {
  color: var(--primary-green);
}

/* COLUMNA DERECHA: FORMULARIO */
.contact-form-column {
  background-color: #ffffff;
  padding: 2.5rem;
  border-radius: 20px;
  border: 1px solid #e2e8f0;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.04);
}

.contact-form h2 {
  font-family: var(--font-serif);
  font-size: 1.8rem;
  color: #0c382e;
  margin-bottom: 0.4rem;
}

.contact-form p {
  color: #64748b;
  font-size: 0.9rem;
  margin-bottom: 1.8rem;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-bottom: 1.2rem;
}

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
}

.form-group label {
  font-size: 0.85rem;
  font-weight: 600;
  color: #0c382e;
}

.form-group input,
.form-group select,
.form-group textarea {
  padding: 0.8rem 1rem;
  border: 1px solid #cbd5e1;
  border-radius: 10px;
  font-family: var(--font-sans);
  font-size: 0.95rem;
  color: #1e293b;
  background-color: #f8fafc;
  outline: none;
  transition: border-color 0.2s ease;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
  border-color: #004D40;
  background-color: #ffffff;
}

.btn-submit {
  background-color: #004D40;
  color: #ffffff;
  border: none;
  padding: 1rem 2rem;
  border-radius: 12px;
  font-family: var(--font-sans);
  font-weight: 600;
  font-size: 1rem;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  width: 100%;
  transition: background-color 0.2s ease;
  margin-top: 0.5rem;
}

.btn-submit:hover {
  background-color: #059669;
}

/* MAPA */
.map-section {
  width: 100%;
  line-height: 0;
}

/* RESPONSIVE CONTACTO */
@media (max-width: 992px) {
  .contact-grid-container {
    grid-template-columns: 1fr;
    gap: 3rem;
  }
}

@media (max-width: 576px) {
  .form-row {
    grid-template-columns: 1fr;
  }
}


/* ==========================================
   MODAL / TARJETA DETALLADA DE PROPIEDAD
   ========================================== */
.modal-card {
  display: grid;
  grid-template-columns: 1fr 1.1fr;
  background: #ffffff;
  border-radius: 24px;
  overflow: hidden;
  max-width: 900px;
  width: 100%;
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.15);
  font-family: var(--font-sans);
  position: relative;
}

/* Columna de Imagen */
.modal-image-col {
  position: relative;
  width: 100%;
  height: 100%;
  min-height: 400px;
}

.modal-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.modal-image-col .badge-type {
  position: absolute;
  top: 18px;
  left: 18px;
  background-color: #0c382e;
  color: #ffffff;
  padding: 6px 16px;
  border-radius: 20px;
  font-size: 0.82rem;
  font-weight: 600;
}

/* Columna de Información */
.modal-info-col {
  padding: 2.2rem;
  display: flex;
  flex-direction: column;
  position: relative;
}

.btn-close-modal {
  position: absolute;
  top: 15px;
  right: 15px;
  background: #f1f5f9;
  border: none;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  font-size: 1.2rem;
  color: #64748b;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
}

.modal-location {
  display: flex;
  align-items: center;
  gap: 6px;
  color: #64748b;
  font-size: 0.85rem;
  margin-bottom: 0.6rem;
}

.modal-title {
  font-family: var(--font-serif);
  font-size: 1.8rem;
  color: #0c382e;
  font-weight: 600;
  margin-bottom: 0.8rem;
}

.modal-price {
  font-size: 1.8rem;
  font-weight: 700;
  color: #10b981;
  margin-bottom: 1.5rem;
}

/* Cajas Verdes Claras de Características */
.modal-features-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
  margin-bottom: 1.5rem;
}

.feature-box {
  background-color: #d1fae5; /* Verde claro suave idéntico a la imagen */
  border-radius: 16px;
  padding: 1rem 0.5rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
}

.feature-value {
  font-size: 1.2rem;
  font-weight: 700;
  color: #0c382e;
  margin: 4px 0 2px 0;
}

.feature-label {
  font-size: 0.75rem;
  color: #0c382e;
  font-weight: 500;
}

/* Descripción */
.modal-description h3 {
  font-family: var(--font-serif);
  font-size: 1.05rem;
  color: #0c382e;
  margin-bottom: 0.4rem;
}

.modal-description p {
  font-size: 0.88rem;
  color: #475569;
  line-height: 1.5;
  margin-bottom: 1.8rem;
}

/* Botón de WhatsApp */
.btn-whatsapp-modal {
  background-color: #25d366;
  color: #ffffff;
  text-decoration: none;
  font-weight: 600;
  font-size: 1rem;
  padding: 0.9rem 1.5rem;
  border-radius: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  transition: background-color 0.2s ease, transform 0.2s ease;
  margin-top: auto;
}

.btn-whatsapp-modal:hover {
  background-color: #1eb956;
  transform: translateY(-2px);
}

/* Responsive para pantallas chicas */
@media (max-width: 768px) {
  .modal-card {
    grid-template-columns: 1fr;
  }
  .modal-image-col {
    min-height: 250px;
  }
}

/* OVERLAY Y MODAL FLOTANTE */
.property-modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background-color: rgba(0, 0, 0, 0.65);
  backdrop-filter: blur(4px);
  z-index: 2000;
  display: none;
  justify-content: center;
  align-items: center;
  padding: 20px;
}

.property-modal-overlay .modal-card {
  margin: 0;
  animation: modalFadeIn 0.25s ease-out;
}

@keyframes modalFadeIn {
  from {
    opacity: 0;
    transform: scale(0.95);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}

/* ==========================================
   GRILLA DE PROPIEDADES (3 COLUMNAS / RESPONSIVE)
   ========================================== */
#propertiesGrid, .properties-grid {
  display: grid !important;
  grid-template-columns: repeat(3, 1fr) !important; /* 3 tarjetas por fila en PC */
  gap: 1.8rem !important;
  max-width: 1200px;
  margin: 0 auto;
}

/* TARJETA COMPACTA */
.property-card {
  width: 100% !important;
  max-width: 100% !important;
  background-color: #ffffff;
  border-radius: 18px;
  overflow: hidden;
  border: 1px solid #e2e8f0;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.04);
  display: flex;
  flex-direction: column;
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.property-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 25px rgba(0, 0, 0, 0.08);
}

.card-image-wrapper {
  position: relative;
  width: 100%;
  height: 200px; /* Altura contenida para que se vean compactas */
  background-color: #f1f5f9;
  overflow: hidden;
}

.property-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.badges-top-left {
  position: absolute;
  top: 12px;
  left: 12px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  z-index: 2;
}

.badge {
  padding: 4px 12px;
  border-radius: 20px;
  font-size: 0.75rem;
  font-weight: 600;
  color: #ffffff;
}

.badge-type { background-color: #0c382e; }
.badge-sale { background-color: #2563eb; }
.badge-rent { background-color: #7c3aed; }

.badge-featured {
  position: absolute;
  top: 12px;
  right: 12px;
  background-color: #10b981;
  z-index: 2;
}

.card-body {
  padding: 1.2rem;
  display: flex;
  flex-direction: column;
  flex-grow: 1;
}

.location {
  display: flex;
  align-items: center;
  gap: 5px;
  color: #64748b;
  font-size: 0.8rem;
  margin-bottom: 0.5rem;
}

.property-title {
  font-family: var(--font-serif, 'Playfair Display', serif);
  font-size: 1.15rem;
  color: #0c382e;
  font-weight: 600;
  margin-bottom: 0.6rem;
  line-height: 1.3;
}

.price {
  font-size: 1.3rem;
  font-weight: 700;
  color: #10b981;
  margin-bottom: 0.8rem;
}

.features-row {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding-bottom: 0.8rem;
  border-bottom: 1px solid #f1f5f9;
  margin-bottom: 0.8rem;
  font-size: 0.82rem;
  color: #64748b;
}

.feature-item {
  display: flex;
  align-items: center;
  gap: 5px;
}

.card-actions {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  margin-top: auto;
}

.btn-more {
  flex: 1;
  background-color: #004D40;
  color: #ffffff;
  border: none;
  padding: 0.65rem 1rem;
  border-radius: 25px;
  font-size: 0.88rem;
  font-weight: 500;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  transition: background-color 0.2s ease;
}

.btn-more:hover {
  background-color: #059669;
}

.btn-whatsapp-icon {
  width: 38px;
  height: 38px;
  background-color: #25d366;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  flex-shrink: 0;
  transition: transform 0.2s ease;
}

.btn-whatsapp-icon:hover {
  transform: scale(1.06);
}

/* ==========================================
   RESPONSIVE DESIGN (2 EN TABLETS / 1 EN CELULAR)
   ========================================== */
@media (max-width: 992px) {
  #propertiesGrid, .properties-grid {
    grid-template-columns: repeat(2, 1fr) !important; /* 2 por ancho en tablets/responsive */
    gap: 1.2rem !important;
  }
}

@media (max-width: 600px) {
  #propertiesGrid, .properties-grid {
    grid-template-columns: 1fr !important; /* 1 columna en teléfonos */
  }
}

/* Botón de cierre (X) dentro del Modal */
.btn-close-modal {
  position: absolute;
  top: 15px;
  right: 15px;
  background-color: #f1f5f9;
  border: none;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  font-size: 1.5rem;
  line-height: 1;
  color: #475569;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 100; /* Asegura que no lo tape la columna o imagen */
  transition: background-color 0.2s ease, color 0.2s ease;
}

.btn-close-modal:hover {
  background-color: #e2e8f0;
  color: #0f172a;
}

/* ==========================================
   GRILLA DE CATÁLOGO (3 POR FILA)
   ========================================== */
#propertiesContainer, 
#propertiesGrid {
  display: grid !important;
  grid-template-columns: repeat(3, 1fr) !important; /* 3 columnas exactas */
  gap: 1.5rem !important;
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  box-sizing: border-box;
}

/* TARJETA COMPACTA DE LA GRILLA */
.property-card {
  display: flex !important;
  flex-direction: column !important;
  width: 100% !important;
  max-width: 100% !important;
  background-color: #ffffff;
  border-radius: 16px;
  overflow: hidden;
  border: 1px solid #e2e8f0;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.04);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.property-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 25px rgba(0, 0, 0, 0.08);
}

/* CONTENEDOR DE IMAGEN COMPACTO */
.property-card .card-image-wrapper {
  position: relative;
  width: 100%;
  height: 190px !important; /* Altura compacta */
  background-color: #f1f5f9;
  overflow: hidden;
}

.property-card .property-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* CUERPO Y BOTONES DE TARJETA */
.property-card .card-body {
  padding: 1.2rem;
  display: flex;
  flex-direction: column;
  flex-grow: 1;
}

.property-card .location {
  display: flex;
  align-items: center;
  gap: 5px;
  color: #64748b;
  font-size: 0.8rem;
  margin-bottom: 0.4rem;
}

.property-card .property-title {
  font-family: var(--font-serif, 'Playfair Display', serif);
  font-size: 1.1rem;
  color: #0c382e;
  font-weight: 600;
  margin-bottom: 0.5rem;
  line-height: 1.3;
}

.property-card .price {
  font-size: 1.3rem;
  font-weight: 700;
  color: #10b981;
  margin-bottom: 0.8rem;
}

.property-card .features-row {
  display: flex;
  align-items: center;
  gap: 0.8rem;
  padding-bottom: 0.8rem;
  border-bottom: 1px solid #f1f5f9;
  margin-bottom: 0.8rem;
  font-size: 0.8rem;
  color: #64748b;
}

.property-card .card-actions {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  margin-top: auto;
}

.property-card .btn-more {
  flex: 1;
  background-color: #004D40;
  color: #ffffff;
  border: none;
  padding: 0.6rem 1rem;
  border-radius: 25px;
  font-size: 0.85rem;
  font-weight: 500;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  transition: background-color 0.2s ease;
}

.property-card .btn-more:hover {
  background-color: #059669;
}

/* ==========================================
   RESPONSIVE (2 EN TABLETS Y 1 EN CELULARES)
   ========================================== */
@media (max-width: 992px) {
  #propertiesContainer, 
  #propertiesGrid {
    grid-template-columns: repeat(2, 1fr) !important; /* 2 por fila en tablet */
    gap: 1.2rem !important;
  }
}

@media (max-width: 600px) {
  #propertiesContainer, 
  #propertiesGrid {
    grid-template-columns: 1fr !important; /* 1 por fila en celular */
  }
}

/* GALERÍA DE IMÁGENES DENTRO DEL MODAL */
.modal-image-col {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.main-image-container {
  position: relative;
  width: 100%;
  height: 320px;
  border-radius: 12px;
  overflow: hidden;
  background-color: #f1f5f9;
}

.main-image-container .modal-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* TIRA DE MINIATURAS (THUMBNAILS) */
.modal-thumbnails-wrapper {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  padding-bottom: 6px;
  scrollbar-width: thin; /* Para navegadores Firefox */
}

.modal-thumbnails-wrapper::-webkit-scrollbar {
  height: 6px;
}

.modal-thumbnails-wrapper::-webkit-scrollbar-thumb {
  background-color: #cbd5e1;
  border-radius: 4px;
}

.modal-thumb {
  width: 65px;
  height: 55px;
  object-fit: cover;
  border-radius: 8px;
  cursor: pointer;
  opacity: 0.6;
  border: 2px solid transparent;
  transition: all 0.2s ease;
  flex-shrink: 0;
}

.modal-thumb:hover {
  opacity: 0.9;
}

.modal-thumb.active {
  opacity: 1;
  border-color: #004D40; /* Verde institucional */
  transform: scale(1.03);
}


/* ==========================================
   ESTILOS Y FLECHAS DEL MODAL (RESPONSIVE)
   ========================================== */

/* Fondo oscuro overlay */
.property-modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background-color: rgba(0, 0, 0, 0.75);
  backdrop-filter: blur(5px);
  z-index: 2000;
  display: none;
  justify-content: center;
  align-items: center;
  padding: 15px;
  box-sizing: border-box;
}

/* Tarjeta principal del modal */
.property-modal-overlay .modal-card {
  position: relative;
  background: #ffffff;
  width: 100%;
  max-width: 920px;
  max-height: 90vh;
  border-radius: 20px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
  padding: 24px;
  overflow-y: auto;
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.2);
  box-sizing: border-box;
}

/* Contenedor de la foto principal */
.modal-image-col {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.main-image-container {
  position: relative;
  width: 100%;
  height: 380px;
  border-radius: 14px;
  overflow: hidden;
  background-color: #f1f5f9;
}

.main-image-container .modal-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* Flechas flotantes en la imagen */
.slider-arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background-color: rgba(0, 0, 0, 0.45);
  color: #ffffff;
  border: none;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  font-size: 1.1rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 10;
  transition: background-color 0.2s ease, transform 0.2s ease;
}

.slider-arrow:hover {
  background-color: rgba(0, 0, 0, 0.8);
  transform: translateY(-50%) scale(1.08);
}

.arrow-prev { left: 10px; }
.arrow-next { right: 10px; }

/* Tira de miniaturas */
.modal-thumbnails-wrapper {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  padding-bottom: 4px;
}

.modal-thumb {
  width: 65px;
  height: 55px;
  object-fit: cover;
  border-radius: 8px;
  cursor: pointer;
  opacity: 0.6;
  border: 2px solid transparent;
  transition: all 0.2s ease;
  flex-shrink: 0;
}

.modal-thumb:hover {
  opacity: 0.85;
}

.modal-thumb.active {
  opacity: 1;
  border-color: #004D40;
}

/* Botón cerrar modal (X) */
.btn-close-modal {
  position: absolute;
  top: 15px;
  right: 15px;
  background-color: #f1f5f9;
  border: none;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  font-size: 1.4rem;
  line-height: 1;
  color: #475569;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 20;
}

.btn-close-modal:hover {
  background-color: #e2e8f0;
  color: #0f172a;
}

/* ==========================================
   RESPONSIVE DEL MODAL (CELULARES Y TABLETS)
   ========================================== */
@media (max-width: 768px) {
  .property-modal-overlay .modal-card {
    grid-template-columns: 1fr; /* Una sola columna en celular */
    max-height: 95vh;
    padding: 16px;
    gap: 16px;
  }

  .main-image-container {
    height: 250px; /* Altura más cómoda para celulares */
  }

  .slider-arrow {
    width: 32px;
    height: 32px;
    font-size: 0.9rem;
  }
}

/* ==========================================
   CARTEL / BANNER DE PROPIEDAD VENDIDA O ALQUILADA
   ========================================== */

.card-image-wrapper {
  position: relative;
  overflow: hidden; /* Corta el cartel sobrante fuera de la tarjeta */
}

/* Estilo base del cartel */
.status-banner {
  position: absolute;
  top: 22px;
  right: -35px;
  transform: rotate(45deg);
  width: 150px;
  padding: 6px 0;
  text-align: center;
  font-size: 0.75rem;
  font-weight: 800;
  letter-spacing: 1px;
  color: #ffffff;
  text-transform: uppercase;
  box-shadow: 0 3px 10px rgba(0, 0, 0, 0.25);
  z-index: 10;
}

/* Cartel ALQUILADA (Color Rojo o Naranja) */
.banner-alquilada {
  background-color: #e11d48;
}

/* Cartel VENDIDA (Color Rojo Oscuro) */
.banner-vendida {
  background-color: #b91c1c;
}

/* Opcional: Opacidad sutil en la foto si ya está vendida o alquilada */
.property-card.status-alquilada .property-img,
.property-card.status-vendida .property-img {
  filter: grayscale(20%);
}

/* ==========================================
   CARTEL EN ANCHO COMPLETO SOBRE LA IMAGEN
   ========================================== */
.card-image-wrapper {
  position: relative;
  overflow: hidden;
}

/* Franja que ocupa todo el ancho */
.status-banner {
  position: absolute;
  top: 50%;
  left: 0;
  transform: translateY(-50%); /* Centrado vertical sobre la foto */
  width: 100%;
  padding: 8px 0;
  text-align: center;
  font-size: 0.9rem;
  font-weight: 800;
  letter-spacing: 2px;
  color: #ffffff;
  text-transform: uppercase;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
  z-index: 10;
}

/* Color para VENDIDA */
.banner-vendida {
  background-color: rgba(185, 28, 28, 0.92); /* Rojo institucional con ligera transparencia */
}

/* Color para ALQUILADA */
.banner-alquilada {
  background-color: rgba(225, 29, 72, 0.92);
}

.banner-alquilado {
  background-color: rgba(225, 29, 72, 0.92);
}

.banner-vendido {
  background-color: rgba(225, 29, 72, 0.92);
}

/* Oscurecer un poco la imagen de fondo para destacar la franja */
.property-card.status-vendida .property-img,
.property-card.status-alquilada .property-img {
  filter: brightness(0.85);
}


/* ==========================================
   ESTILOS GRILLA DE 3 REELS GRANDES
   ========================================== */
.instagram-section {
  padding: 4rem 1.5rem;
  background-color: #f8fafc;
}

.reels-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr); /* 3 Reels grandes por fila */
  gap: 2rem;
  max-width: 1200px;
  margin: 2rem auto 0 auto;
  align-items: start;
}

.reel-item {
  background: #ffffff;
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.05);
  display: flex;
  justify-content: center;
  min-height: 450px; /* Tamaño grande garantizado */
}

/* Forzar renderizado ancho del widget oficial de Instagram */
.reel-item .instagram-media {
  min-width: 100% !important;
  margin: 0 !important;
  border-radius: 16px !important;
  border: none !important;
}

/* RESPONSIVE */
@media (max-width: 992px) {
  .reels-grid {
    grid-template-columns: repeat(2, 1fr); /* 2 en tablets */
    gap: 1.5rem;
  }
}

@media (max-width: 640px) {
  .reels-grid {
    grid-template-columns: 1fr; /* 1 por fila en celulares */
  }
}


/* ==========================================
   BOTÓN Y MENÚ HAMBURGUESA (RESPONSIVE)
   ========================================== */

/* Escondido por defecto en PC/Escritorio */
.hamburger-btn {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 8px;
  flex-direction: column;
  justify-content: space-between;
  width: 38px;
  height: 28px;
  z-index: 1001;
}

.hamburger-btn .bar {
  display: block;
  width: 100%;
  height: 3px;
  background-color: #0c382e; /* Verde institucional */
  border-radius: 3px;
  transition: all 0.3s ease-in-out;
}

/* Animación del botón a 'X' cuando está activo */
.hamburger-btn.active .bar:nth-child(1) {
  transform: translateY(9px) rotate(45deg);
}

.hamburger-btn.active .bar:nth-child(2) {
  opacity: 0;
}

.hamburger-btn.active .bar:nth-child(3) {
  transform: translateY(-11px) rotate(-45deg);
}

/* MEDIA QUERY PARA CELULARES Y TABLETS */
@media (max-width: 768px) {
  .hamburger-btn {
    display: flex; /* Mostrar botón hamburguesa */
  }

  .nav-menu {
    position: fixed;
    top: 0;
    right: -100%; /* Oculto fuera de la pantalla */
    width: 75%;
    max-width: 300px;
    height: 100vh;
    background-color: #ffffff;
    box-shadow: -5px 0 20px rgba(0, 0, 0, 0.15);
    padding: 80px 24px 32px 24px;
    transition: right 0.35s ease-in-out;
    z-index: 1000;
  }

  /* Estado desplegado/abierto */
  .nav-menu.active {
    right: 0;
  }

  .nav-list {
    flex-direction: column;
    gap: 20px;
    align-items: flex-start;
  }

  .nav-link {
    font-size: 1.1rem;
    font-weight: 600;
    color: #0c382e;
  }
}

/* ==========================================
   FOOTER ADMIN LINK
   ========================================== */
.footer-admin-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: #a7f3d0 !important;
  font-weight: 500;
  transition: all 0.25s ease;
  margin-top: 4px;
}

.footer-admin-link:hover {
  color: #ffffff !important;
  transform: translateX(3px);
}

.footer-admin-link svg {
  color: var(--primary-green);
}

.legal-admin-link {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  color: #94a3b8;
  font-size: 0.85rem;
  transition: color 0.2s ease;
  text-decoration: none;
}

.legal-admin-link:hover {
  color: var(--primary-green);
}

/* ==========================================
   ESTILOS DE LA PÁGINA DE LOGIN
   ========================================== */
.login-page-body {
  min-height: 100vh;
  background: #081c15 url('https://images.unsplash.com/photo-1600596542815-ffad4c1539a9?q=80&w=2075&auto=format&fit=crop') center/cover no-repeat fixed;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  font-family: var(--font-sans);
  color: #0f172a;
}

.login-background-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: radial-gradient(circle at center, rgba(8, 28, 21, 0.78) 0%, rgba(4, 15, 11, 0.94) 100%);
  z-index: 1;
}

.login-wrapper {
  position: relative;
  z-index: 2;
  width: 100%;
  max-width: 460px;
  padding: 24px;
  margin: auto;
}

.login-card {
  background: rgba(255, 255, 255, 0.97);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-radius: 20px;
  padding: 40px 36px;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.35), 0 0 0 1px rgba(255, 255, 255, 0.2);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.login-brand-header {
  text-align: center;
  margin-bottom: 28px;
}

.login-logo-link {
  display: inline-block;
  margin-bottom: 12px;
  transition: transform 0.3s ease;
}

.login-logo-link:hover {
  transform: scale(1.04);
}

.login-logo-img {
  height: 95px;
  width: auto;
  object-fit: contain;
  filter: drop-shadow(0 4px 10px rgba(0, 0, 0, 0.08));
}

.login-title {
  font-family: var(--font-serif);
  font-size: 1.8rem;
  font-weight: 600;
  color: #064e3b;
  margin-bottom: 6px;
  letter-spacing: -0.01em;
}

.login-subtitle {
  font-size: 0.88rem;
  color: #64748b;
  line-height: 1.45;
  font-weight: 400;
}

.login-alert {
  padding: 12px 16px;
  border-radius: 12px;
  font-size: 0.88rem;
  font-weight: 500;
  margin-bottom: 20px;
  line-height: 1.4;
  animation: fadeIn 0.3s ease;
}

.alert-error {
  background-color: #fef2f2;
  color: #991b1b;
  border: 1px solid #fecaca;
}

.alert-success {
  background-color: #ecfdf5;
  color: #065f46;
  border: 1px solid #a7f3d0;
}

.login-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: 600;
  color: #1e293b;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.input-icon-wrapper {
  position: relative;
  display: flex;
  align-items: center;
}

.input-icon {
  position: absolute;
  left: 14px;
  color: #94a3b8;
  pointer-events: none;
  transition: color 0.2s ease;
}

.form-input {
  width: 100%;
  padding: 13px 16px 13px 44px;
  background-color: #f8fafc;
  border: 1.5px solid #e2e8f0;
  border-radius: 12px;
  font-size: 0.95rem;
  color: #0f172a;
  font-family: inherit;
  transition: all 0.2s ease;
}

.form-input:focus {
  outline: none;
  background-color: #ffffff;
  border-color: #10b981;
  box-shadow: 0 0 0 4px rgba(16, 185, 129, 0.15);
}

.form-input:focus + .input-icon,
.input-icon-wrapper:focus-within .input-icon {
  color: #10b981;
}

.toggle-password-btn {
  position: absolute;
  right: 12px;
  background: none;
  border: none;
  color: #94a3b8;
  cursor: pointer;
  padding: 6px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 8px;
  transition: color 0.2s ease;
}

.toggle-password-btn:hover {
  color: #0f172a;
}

.btn-login-submit {
  width: 100%;
  padding: 14px 20px;
  background: linear-gradient(135deg, #10b981 0%, #059669 100%);
  color: #ffffff;
  border: none;
  border-radius: 12px;
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  box-shadow: 0 4px 14px rgba(16, 185, 129, 0.35);
  transition: all 0.25s ease;
  margin-top: 6px;
}

.btn-login-submit:hover:not(:disabled) {
  background: linear-gradient(135deg, #059669 0%, #047857 100%);
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(16, 185, 129, 0.45);
}

.btn-login-submit:active:not(:disabled) {
  transform: translateY(0);
}

.btn-login-submit:disabled {
  opacity: 0.75;
  cursor: not-allowed;
}

.btn-arrow-icon {
  transition: transform 0.2s ease;
}

.btn-login-submit:hover:not(:disabled) .btn-arrow-icon {
  transform: translateX(4px);
}

/* Spinner Loader */
.spinner {
  width: 18px;
  height: 18px;
  border: 2px solid rgba(255, 255, 255, 0.3);
  border-radius: 50%;
  border-top-color: #ffffff;
  animation: spin 0.8s linear infinite;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

.login-card-footer {
  margin-top: 28px;
  padding-top: 20px;
  border-top: 1px solid #f1f5f9;
  text-align: center;
}

.back-to-site-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: #64748b;
  font-size: 0.88rem;
  font-weight: 500;
  text-decoration: none;
  transition: color 0.2s ease, transform 0.2s ease;
}

.back-to-site-link:hover {
  color: #064e3b;
  transform: translateX(-3px);
}

@media (max-width: 480px) {
  .login-card {
    padding: 30px 22px;
  }
  .login-title {
    font-size: 1.5rem;
  }
  .login-logo-img {
    height: 80px;
  }
}

/* ==========================================
   ESTILOS PARA MODO ADMINISTRADOR GLOBAL
   ========================================== */
body.has-admin-bar {
  padding-top: 48px !important;
}

.global-admin-bar {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 48px;
  background: #064e3b;
  color: #ffffff;
  z-index: 10000;
  display: flex;
  align-items: center;
  padding: 0 20px;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
  font-family: var(--font-sans);
  font-size: 0.85rem;
  box-sizing: border-box;
}

.admin-bar-content {
  max-width: 1300px;
  width: 100%;
  margin: 0 auto;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.admin-bar-user {
  display: flex;
  align-items: center;
  gap: 10px;
}

.admin-dot-live {
  width: 9px;
  height: 9px;
  background-color: #10b981;
  border-radius: 50%;
  box-shadow: 0 0 8px #10b981;
  animation: pulse-dot 1.8s infinite;
}

@keyframes pulse-dot {
  0% { transform: scale(0.95); opacity: 0.8; }
  50% { transform: scale(1.2); opacity: 1; }
  100% { transform: scale(0.95); opacity: 0.8; }
}

.admin-bar-actions {
  display: flex;
  align-items: center;
  gap: 10px;
}

.btn-admin-bar {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px 12px;
  border-radius: 6px;
  font-size: 0.8rem;
  font-weight: 600;
  cursor: pointer;
  text-decoration: none;
  transition: all 0.2s ease;
  border: none;
  color: #ffffff;
}

.btn-admin-bar.btn-add {
  background-color: #10b981;
}

.btn-admin-bar.btn-add:hover {
  background-color: #059669;
  transform: translateY(-1px);
}

.btn-admin-bar.btn-edit-content {
  background-color: rgba(255, 255, 255, 0.15);
  border: 1px solid rgba(255, 255, 255, 0.25);
}

.btn-admin-bar.btn-edit-content:hover {
  background-color: rgba(255, 255, 255, 0.25);
}

.btn-admin-bar.btn-panel {
  background-color: rgba(255, 255, 255, 0.1);
}

.btn-admin-bar.btn-panel:hover {
  background-color: rgba(255, 255, 255, 0.2);
}

.btn-admin-bar.btn-logout {
  background-color: #ef4444;
}

.btn-admin-bar.btn-logout:hover {
  background-color: #dc2626;
}

/* BANNER ADMIN EN LA SECCIÓN PROPIEDADES */
.admin-properties-banner {
  background: linear-gradient(135deg, #064e3b 0%, #0f5132 100%);
  border-radius: 12px;
  padding: 16px 24px;
  margin-bottom: 24px;
  color: white;
  display: flex;
  justify-content: space-between;
  align-items: center;
  box-shadow: 0 4px 15px rgba(6, 78, 59, 0.2);
}

.admin-banner-left {
  display: flex;
  align-items: center;
  gap: 12px;
}

.admin-badge-pulse {
  background-color: #10b981;
  color: #064e3b;
  font-weight: 700;
  font-size: 0.75rem;
  padding: 4px 10px;
  border-radius: 20px;
  letter-spacing: 0.5px;
}

.admin-email-text {
  font-size: 0.9rem;
}

.btn-admin-add-prop {
  background-color: #10b981;
  color: #ffffff;
  border: none;
  padding: 10px 20px;
  border-radius: 8px;
  font-weight: 700;
  font-size: 0.9rem;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
  transition: all 0.2s ease;
}

.btn-admin-add-prop:hover {
  background-color: #059669;
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

/* BOTONES ADMIN DENTRO DE LAS TARJETAS */
.card-admin-controls {
  margin-top: 14px;
  padding-top: 10px;
  border-top: 1px dashed #cbd5e1;
  display: flex;
  gap: 8px;
}

.btn-card-admin-edit {
  flex: 1;
  background-color: #e2e8f0;
  color: #0f172a;
  border: 1px solid #cbd5e1;
  padding: 8px 12px;
  border-radius: 6px;
  font-weight: 600;
  font-size: 0.8rem;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  transition: background 0.2s ease;
}

.btn-card-admin-edit:hover {
  background-color: #cbd5e1;
}

.btn-card-admin-delete {
  background-color: #fee2e2;
  color: #991b1b;
  border: 1px solid #fca5a5;
  padding: 8px 12px;
  border-radius: 6px;
  font-weight: 600;
  font-size: 0.8rem;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  transition: background 0.2s ease;
}

.btn-card-admin-delete:hover {
  background-color: #fecaca;
}

/* FORMULARIO MODAL GRID RESPONSIVO */
.prop-form-modal-card {
  max-width: 750px !important;
  width: 92% !important;
  max-height: 90vh;
  overflow-y: auto;
  padding: 30px !important;
}

.form-modal-header {
  margin-bottom: 20px;
  border-bottom: 1px solid #e2e8f0;
  padding-bottom: 12px;
}

.form-modal-header h2 {
  font-family: var(--font-serif);
  color: #064e3b;
  margin: 0 0 6px 0;
  font-size: 1.5rem;
}

.form-modal-header p {
  color: #64748b;
  font-size: 0.88rem;
  margin: 0;
}

.admin-modal-grid-form {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

.admin-modal-grid-form .grid-col-2 {
  grid-column: span 2;
}

.form-actions-row {
  display: flex;
  justify-content: flex-end;
  gap: 12px;
  margin-top: 10px;
}

.btn-cancel-modal {
  background-color: #94a3b8;
  color: white;
  border: none;
  padding: 10px 20px;
  border-radius: 6px;
  font-weight: 600;
  cursor: pointer;
}

.btn-cancel-modal:hover {
  background-color: #64748b;
}

.btn-submit-modal {
  background-color: #10b981;
  color: white;
  border: none;
  padding: 10px 24px;
  border-radius: 6px;
  font-weight: 700;
  cursor: pointer;
}

.btn-submit-modal:hover:not(:disabled) {
  background-color: #059669;
}

.btn-submit-modal:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

@media (max-width: 768px) {
  .global-admin-bar {
    height: auto;
    padding: 8px 12px;
  }

  .admin-bar-content {
    flex-direction: column;
    gap: 8px;
    align-items: flex-start;
  }

  .admin-bar-actions {
    width: 100%;
    flex-wrap: wrap;
  }

  .admin-properties-banner {
    flex-direction: column;
    gap: 12px;
    align-items: flex-start;
  }

  .admin-modal-grid-form {
    grid-template-columns: 1fr;
  }

  .admin-modal-grid-form .grid-col-2 {
    grid-column: span 1;
  }
}

/* ==========================================
   BARRA DE ANUNCIO SUPERIOR
   ========================================== */
.site-announcement-bar {
  text-align: center;
  padding: 8px 16px;
  font-size: 0.85rem;
  font-weight: 600;
  letter-spacing: 0.3px;
  box-shadow: 0 1px 4px rgba(0,0,0,0.1);
  position: relative;
  z-index: 999;
}

/* BOTÓN TIENDANUBE EN BARRA ADMIN */
.btn-admin-bar.btn-tiendanube {
  background: linear-gradient(135deg, #2563eb 0%, #1d4ed8 100%);
  color: #ffffff;
  border: none;
  font-weight: 700;
  box-shadow: 0 2px 6px rgba(37, 99, 235, 0.4);
}

.btn-admin-bar.btn-tiendanube:hover {
  background: linear-gradient(135deg, #1d4ed8 0%, #1e40af 100%);
  transform: translateY(-1px);
}

/* ==========================================
   DRAWER LATERAL DRAWER ESTILO TIENDANUBE
   ========================================== */
.tiendanube-drawer-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background: rgba(15, 23, 42, 0.6);
  backdrop-filter: blur(4px);
  z-index: 20000;
  display: flex;
  justify-content: flex-end;
  animation: fadeInOverlay 0.25s ease;
}

@keyframes fadeInOverlay {
  from { opacity: 0; }
  to { opacity: 1; }
}

.tiendanube-drawer-card {
  width: 520px;
  max-width: 95vw;
  height: 100vh;
  background: #ffffff;
  box-shadow: -10px 0 30px rgba(0, 0, 0, 0.25);
  display: flex;
  flex-direction: column;
  animation: slideInDrawer 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes slideInDrawer {
  from { transform: translateX(100%); }
  to { transform: translateX(0); }
}

.tn-drawer-header {
  padding: 20px 24px;
  background: #0f172a;
  color: #ffffff;
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
}

.tn-drawer-header h3 {
  margin: 0 0 4px 0;
  font-size: 1.15rem;
  font-family: var(--font-sans);
  color: #38bdf8;
}

.tn-drawer-header p {
  margin: 0;
  font-size: 0.8rem;
  color: #94a3b8;
}

.btn-close-drawer {
  background: rgba(255,255,255,0.1);
  border: none;
  color: white;
  font-size: 1.5rem;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
}

.btn-close-drawer:hover {
  background: rgba(255,255,255,0.2);
}

.tn-drawer-tabs {
  display: flex;
  background: #1e293b;
  border-bottom: 1px solid #334155;
  padding: 0 12px;
  overflow-x: auto;
}

.tn-tab-btn {
  background: none;
  border: none;
  color: #94a3b8;
  padding: 12px 16px;
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
  white-space: nowrap;
  border-bottom: 3px solid transparent;
  transition: all 0.2s ease;
}

.tn-tab-btn.active {
  color: #38bdf8;
  border-bottom-color: #38bdf8;
}

.tn-drawer-body {
  flex: 1;
  overflow-y: auto;
  padding: 24px;
  background: #f8fafc;
}

.tn-tab-content {
  display: none;
}

.tn-tab-content.active {
  display: block;
}

.tn-group-box {
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  padding: 16px;
  box-shadow: 0 2px 6px rgba(0,0,0,0.03);
}

.tn-group-box h4 {
  margin: 0 0 10px 0;
  font-size: 0.95rem;
  color: #0f172a;
}

.tn-toggle-label {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 0.88rem;
  font-weight: 600;
  color: #334155;
  cursor: pointer;
}

.tn-toggle-label input[type="checkbox"] {
  width: 18px;
  height: 18px;
  accent-color: #10b981;
}

.tn-custom-sec-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.tn-sec-item-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 10px 12px;
  background: #f1f5f9;
  border-radius: 8px;
  font-size: 0.85rem;
  border: 1px solid #e2e8f0;
}

.btn-tn-add {
  background: #10b981;
  color: white;
  border: none;
  padding: 6px 12px;
  border-radius: 6px;
  font-size: 0.8rem;
  font-weight: 700;
  cursor: pointer;
}

.btn-tn-add:hover {
  background: #059669;
}

.btn-sm-tn {
  background: #ffffff;
  border: 1px solid #cbd5e1;
  padding: 4px 8px;
  border-radius: 4px;
  font-size: 0.75rem;
  cursor: pointer;
}

.btn-sm-tn:hover {
  background: #e2e8f0;
}

.tn-drawer-footer {
  padding: 16px 24px;
  background: #ffffff;
  border-top: 1px solid #e2e8f0;
  box-shadow: 0 -4px 12px rgba(0,0,0,0.05);
}

.btn-save-tn {
  width: 100%;
  background: #10b981;
  color: white;
  border: none;
  padding: 14px;
  border-radius: 8px;
  font-size: 0.95rem;
  font-weight: 700;
  cursor: pointer;
  box-shadow: 0 4px 12px rgba(16, 185, 129, 0.3);
  transition: all 0.2s ease;
}

.btn-save-tn:hover:not(:disabled) {
  background: #059669;
  transform: translateY(-1px);
}

/* ==========================================
   ESTILOS DE SECCIONES DINÁMICAS CUSTOM
   ========================================== */
.custom-section-wrapper {
  position: relative;
  margin: 30px 0;
}

.custom-sec-admin-badge {
  background: #0f172a;
  color: #38bdf8;
  padding: 8px 16px;
  border-radius: 8px 8px 0 0;
  font-size: 0.8rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  max-width: 1200px;
  margin: 0 auto;
  box-shadow: 0 -2px 10px rgba(0,0,0,0.1);
}

.custom-sec-admin-btns {
  display: flex;
  gap: 6px;
}

.btn-sec-admin {
  background: rgba(255,255,255,0.15);
  color: white;
  border: none;
  padding: 3px 8px;
  border-radius: 4px;
  font-size: 0.75rem;
  cursor: pointer;
}

.btn-sec-admin:hover:not(:disabled) {
  background: rgba(255,255,255,0.3);
}

.btn-sec-admin:disabled {
  opacity: 0.4;
  cursor: not-allowed;
}

/* Banner Promocional */
.custom-sec-banner {
  padding: 50px 20px;
  text-align: center;
  border-radius: 12px;
  max-width: 1200px;
  margin: 0 auto;
}

.custom-banner-container {
  max-width: 800px;
  margin: 0 auto;
}

.custom-banner-container h2 {
  font-family: var(--font-serif);
  font-size: 2rem;
  margin-bottom: 12px;
}

.custom-banner-sub {
  font-size: 1.1rem;
  opacity: 0.9;
  margin-bottom: 24px;
}

.btn-custom-banner {
  display: inline-block;
  background: #10b981;
  color: white;
  padding: 12px 28px;
  border-radius: 8px;
  font-weight: 700;
  text-decoration: none;
  box-shadow: 0 4px 12px rgba(0,0,0,0.2);
}

/* Texto + Imagen */
.custom-sec-text-image {
  max-width: 1200px;
  margin: 0 auto;
  padding: 40px 20px;
}

.custom-text-img-container {
  display: flex;
  align-items: center;
  gap: 40px;
  background: #ffffff;
  border-radius: 16px;
  padding: 32px;
  box-shadow: 0 4px 20px rgba(0,0,0,0.06);
}

.custom-sec-text-image.reverse-layout .custom-text-img-container {
  flex-direction: row-reverse;
}

.custom-ti-img-col {
  flex: 1;
}

.custom-ti-img-col img {
  width: 100%;
  height: 320px;
  object-fit: cover;
  border-radius: 12px;
}

.custom-ti-text-col {
  flex: 1;
}

.custom-ti-badge {
  background: #e0e7ff;
  color: #4338ca;
  font-weight: 700;
  font-size: 0.75rem;
  padding: 4px 10px;
  border-radius: 12px;
  display: inline-block;
  margin-bottom: 12px;
}

.custom-ti-text-col h2 {
  font-family: var(--font-serif);
  font-size: 1.8rem;
  color: #0f172a;
  margin-bottom: 12px;
}

.custom-ti-text-col p {
  color: #475569;
  line-height: 1.6;
}

/* Servicios / Beneficios */
.custom-sec-features {
  max-width: 1200px;
  margin: 0 auto;
  padding: 50px 20px;
  text-align: center;
}

.custom-features-header h2 {
  font-family: var(--font-serif);
  font-size: 2rem;
  color: #064e3b;
  margin-bottom: 8px;
}

.custom-features-header p {
  color: #64748b;
  margin-bottom: 32px;
}

.custom-features-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 24px;
}

.custom-feature-card {
  background: #ffffff;
  border-radius: 12px;
  padding: 28px 20px;
  border: 1px solid #e2e8f0;
  box-shadow: 0 4px 15px rgba(0,0,0,0.03);
  transition: transform 0.2s ease;
}

.custom-feature-card:hover {
  transform: translateY(-4px);
}

.feature-icon-wrapper {
  font-size: 2rem;
  margin-bottom: 12px;
}

.custom-feature-card h3 {
  font-size: 1.15rem;
  color: #0f172a;
  margin-bottom: 8px;
}

.custom-feature-card p {
  color: #64748b;
  font-size: 0.9rem;
  line-height: 1.5;
}

/* FAQ Accordion */
.custom-sec-faq {
  max-width: 900px;
  margin: 0 auto;
  padding: 40px 20px;
}

.custom-faq-container h2 {
  text-align: center;
  font-family: var(--font-serif);
  color: #064e3b;
  font-size: 1.8rem;
  margin-bottom: 24px;
}

.faq-accordion {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.faq-item {
  background: #ffffff;
  border: 1px solid #cbd5e1;
  border-radius: 8px;
  padding: 16px 20px;
}

.faq-question {
  font-weight: 700;
  color: #0f172a;
  cursor: pointer;
  font-size: 1rem;
}

.faq-answer {
  margin-top: 10px;
  color: #475569;
  font-size: 0.9rem;
  line-height: 1.5;
}

/* Testimonios */
.custom-sec-testimonials {
  max-width: 1200px;
  margin: 0 auto;
  padding: 50px 20px;
}

.custom-testim-container h2 {
  text-align: center;
  font-family: var(--font-serif);
  color: #064e3b;
  margin-bottom: 32px;
  font-size: 1.8rem;
}

.testimonials-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 24px;
}

.testimonial-card {
  background: #ffffff;
  padding: 24px;
  border-radius: 12px;
  border: 1px solid #e2e8f0;
  box-shadow: 0 4px 15px rgba(0,0,0,0.04);
}

.testimonial-card .stars {
  color: #f59e0b;
  margin-bottom: 12px;
  font-size: 1.1rem;
}

.testim-text {
  font-style: italic;
  color: #334155;
  margin-bottom: 16px;
  font-size: 0.95rem;
}

.testim-author strong {
  display: block;
  color: #0f172a;
}

.testim-author span {
  font-size: 0.8rem;
  color: #64748b;
}

/* Toast & Confirmation Modal */
.app-global-toast {
  position: fixed;
  bottom: 24px;
  right: 24px;
  background: #0f172a;
  color: #ffffff;
  padding: 12px 20px;
  border-radius: 8px;
  font-size: 0.9rem;
  font-weight: 600;
  box-shadow: 0 10px 25px rgba(0,0,0,0.2);
  z-index: 30000;
  opacity: 0;
  transform: translateY(20px);
  transition: all 0.3s ease;
  pointer-events: none;
}
.app-global-toast.show {
  opacity: 1;
  transform: translateY(0);
}
.app-global-toast.toast-success {
  border-left: 4px solid #10b981;
}
.app-global-toast.toast-error {
  border-left: 4px solid #ef4444;
}

.confirm-modal-card {
  max-width: 420px !important;
  padding: 24px !important;
  border-radius: 12px !important;
  background: #ffffff !important;
  box-shadow: 0 20px 40px rgba(0,0,0,0.2) !important;
}



