/* css/style.css */

/* ROOT VARIABLES */
:root {
  /* Colors based on screenshots */
  --primary: #c3d600; /* Yellowish-green corporate color */
  --primary-dark: #a1b000;
  --text-dark: #2c2c2c;
  --text-gray: #666666;
  --bg-light: #f5f5f5;
  --white: #ffffff;
  --border-color: #e5e5e5;
  --black: #000000;
  
  /* Typography */
  --font-main: 'Outfit', 'Inter', system-ui, -apple-system, sans-serif;
  
  /* Layout constraints */
  --max-width: 1600px;
  --header-height: 90px;
  
  /* Spacing */
  --space-1: 0.5rem;
  --space-2: 1rem;
  --space-3: 1.5rem;
  --space-4: 2rem;
  --space-5: 3rem;
  --space-6: 4rem;
  --space-8: 6rem;
  
  /* Border Radius */
  --radius-sm: 4px;
  --radius-md: 8px;
  --radius-pill: 50px;
  
  /* Shadows */
  --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.05);
  --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.08);
}

/* RESET */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  font-family: var(--font-main);
  color: var(--text-dark);
  background-color: var(--white);
  line-height: 1.6;
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
}

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

a {
  text-decoration: none;
  color: inherit;
  transition: color 0.2s ease, background-color 0.2s ease;
}

ul, ol {
  list-style: none;
}

button, input, select, textarea {
  font-family: inherit;
  font-size: 100%;
}

/* GLOBAL LAYOUT CLASSES */
.container {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 5%;
  width: 100%;
}

.section {
  padding: var(--space-8) 0;
}

.section-bg-light {
  background-color: var(--bg-light);
}

.section-title {
  font-size: 2.25rem;
  font-weight: 500;
  text-align: center;
  margin-bottom: var(--space-6);
  color: var(--text-dark);
}

/* TOUCH TARGETS & ACCESSIBILITY */
button, 
.btn, 
input[type="submit"], 
input[type="button"], 
select, 
a.nav-link,
a.footer-link {
  min-height: 44px; /* Minimum touch target size */
  min-width: 44px;
}

/* COMPONENT: BUTTONS */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 2rem;
  border-radius: var(--radius-pill);
  font-weight: 500;
  cursor: pointer;
  border: 1px solid var(--text-dark);
  background-color: transparent;
  color: var(--text-dark);
  height: 48px;
}

.btn:hover, .btn:active, .btn:focus {
  background-color: var(--text-dark);
  color: var(--white);
  outline: none;
}

.btn-primary {
  background-color: var(--black);
  color: var(--white);
  border-color: var(--black);
}

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

/* COMPONENT: FORM CONTROLS (SELECTS) */
.form-control {
  width: 100%;
  height: 48px;
  padding: 0 2.5rem 0 1rem;
  border: 1px solid var(--border-color);
  border-radius: 0;
  background-color: var(--white);
  color: var(--text-dark);
  appearance: none;
  -webkit-appearance: none;
  background-image: url("data:image/svg+xml;charset=UTF-8,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%232c2c2c' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3e%3cpolyline points='6 9 12 15 18 9'%3e%3c/polyline%3e%3c/svg%3e");
  background-repeat: no-repeat;
  background-position: right 1rem center;
  background-size: 1rem;
  cursor: pointer;
  font-size: 0.95rem;
}

.form-control:focus {
  outline: none;
  border-color: var(--text-dark);
}

/* HEADER */
.site-header {
  position: sticky;
  top: 0;
  background-color: var(--white);
  box-shadow: var(--shadow-sm);
  z-index: 1000;
  height: var(--header-height);
  display: flex;
  align-items: center;
}

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

.site-logo {
  flex-shrink: 0;
  display: flex;
  align-items: center;
}

.site-logo img {
  height: 50px;
  width: auto;
  max-width: none;
  object-fit: contain;
}

/* HEADER NAV (right side) */
.header-nav {
  display: flex;
  align-items: center;
  gap: 1.25rem;
}

.header-socials {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.header-social-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background-color: var(--primary);
  color: var(--black);
  flex-shrink: 0;
  transition: opacity 0.2s ease;
}

.header-social-icon:hover {
  opacity: 0.8;
}

.header-email {
  font-size: 0.9rem;
  color: var(--text-dark);
  font-weight: 400;
  white-space: nowrap;
  display: none; /* Ocultar en móvil pequeño */
}

.header-phone {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.95rem;
  font-weight: 500;
  color: var(--text-dark);
  white-space: nowrap;
}

.header-phone svg {
  flex-shrink: 0;
}

.btn-contactar {
  white-space: nowrap;
  background-color: var(--primary);
  color: var(--black);
  border-color: var(--primary);
  font-weight: 700;
  font-size: 0.9rem;
  letter-spacing: 0.5px;
  padding: 0 1.5rem;
  height: 44px;
}

.btn-contactar:hover, .btn-contactar:focus {
  background-color: var(--black);
  border-color: var(--black);
  color: var(--white);
}

@media (min-width: 992px) {
  .header-email {
    display: inline; /* Mostrar email en escritorio */
  }
}

@media (max-width: 991px) {
  /* Ocultar botones de redes sociales en responsive / tablet */
  .header-socials {
    display: none;
  }
}

/* En móvil muy pequeño, ocultar teléfono para que no rompa */
@media (max-width: 480px) {
  .header-phone {
    display: none;
  }
  .btn-contactar {
    padding: 0 1rem;
    font-size: 0.85rem;
  }
}

/* SCROLLBAR REFINEMENT (Optional polish) */
::-webkit-scrollbar {
  width: 8px;
}
::-webkit-scrollbar-track {
  background: var(--bg-light);
}
::-webkit-scrollbar-thumb {
  background: #ccc;
  border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
  background: var(--text-gray);
}

/* COMPONENT: BADGES */
.availability-badge {
  display: inline-flex;
  align-items: center;
  background-color: var(--primary);
  color: var(--black);
  font-weight: 600;
  padding: 0.25rem 0.75rem;
  font-size: 0.9rem;
  margin: var(--space-3) 0;
  border-radius: 2px;
}

.availability-badge .badge-number {
  background-color: rgba(255,255,255,0.4);
  padding: 0 0.5rem;
  margin-right: 0.5rem;
  border-radius: 2px;
}

.availability-badge.no-count .badge-text {
  margin: 0;
}

/* ================================
   SECTION: SPACE TYPES — PREMIUM REDESIGN
   ================================ */

.space-types-section {
  background: linear-gradient(160deg, #1a1a1a 0%, #2c2c2c 60%, #1f1f1f 100%);
  position: relative;
  overflow: hidden;
}

/* Decoración de fondo: círculo sutil */
.space-types-section::before {
  content: '';
  position: absolute;
  top: -200px;
  right: -150px;
  width: 600px;
  height: 600px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(195,214,0,0.08) 0%, transparent 70%);
  pointer-events: none;
  z-index: 0;
}
.space-types-section::after {
  content: '';
  position: absolute;
  bottom: -200px;
  left: -100px;
  width: 500px;
  height: 500px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(195,214,0,0.05) 0%, transparent 70%);
  pointer-events: none;
  z-index: 0;
}

/* Container relativo al z-index del fondo */
.space-types-section .container {
  position: relative;
  z-index: 1;
}

/* Header de la sección */
.space-section-header {
  text-align: center;
  margin-bottom: 3.5rem;
}

.space-section-badge {
  display: inline-block;
  background: rgba(195, 214, 0, 0.15);
  color: var(--primary);
  font-size: 0.8rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 2px;
  padding: 0.35rem 1.2rem;
  border-radius: var(--radius-pill);
  border: 1px solid rgba(195, 214, 0, 0.3);
  margin-bottom: 1.2rem;
}

.space-section-title {
  color: #ffffff !important;
  font-size: 2.5rem;
  margin-bottom: 1rem;
}

@media (min-width: 768px) {
  .space-section-title {
    font-size: 3rem;
  }
}

.space-section-subtitle {
  color: rgba(255,255,255,0.5);
  font-size: 1.05rem;
  max-width: 560px;
  margin: 0 auto;
  line-height: 1.7;
}

/* Grid */
.space-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.5rem;
}

@media (min-width: 600px) {
  .space-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 1100px) {
  .space-grid {
    grid-template-columns: repeat(4, 1fr);
  }
}

/* Card */
.space-card {
  border-radius: 16px;
  position: relative;
  overflow: hidden;
  transition: transform 0.35s cubic-bezier(0.25, 0.8, 0.25, 1),
              box-shadow 0.35s ease;
  cursor: pointer;
  background: #ffffff0d;
  border: 1px solid rgba(255,255,255,0.1);
  -webkit-tap-highlight-color: transparent;
}

.space-card:hover {
  transform: translateY(-8px);
  box-shadow: 0 24px 60px rgba(0,0,0,0.5);
  border-color: rgba(255,255,255,0.2);
}

/* Acento de color en el borde superior según tipo */
.space-card--coworking  { --card-accent: #c3d600; }
.space-card--office     { --card-accent: #5bc8f5; }
.space-card--storage    { --card-accent: #f5a623; }
.space-card--virtual    { --card-accent: #b388ff; }

.space-card::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 3px;
  background: var(--card-accent);
  border-radius: 16px 16px 0 0;
  opacity: 0.9;
  transition: opacity 0.3s ease;
}

.space-card:hover::before {
  opacity: 1;
}

/* Overlap glow hover */
.space-card::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(255,255,255,0.04) 0%, transparent 60%);
  opacity: 0;
  transition: opacity 0.35s ease;
  pointer-events: none;
  border-radius: 16px;
}
.space-card:hover::after {
  opacity: 1;
}

/* Inner padding */
.space-card-inner {
  padding: 2rem 1.75rem 1.75rem;
  display: flex;
  flex-direction: column;
  height: 100%;
  position: relative;
}

/* Watermark SVG de fondo */
.space-card-bg-icon {
  position: absolute;
  bottom: -10px;
  right: -15px;
  width: 160px;
  height: 160px;
  color: var(--card-accent);
  opacity: 0.06;
  pointer-events: none;
  transition: opacity 0.35s ease, transform 0.35s ease;
}
.space-card:hover .space-card-bg-icon {
  opacity: 0.1;
  transform: scale(1.08) rotate(-5deg);
}
.space-card-bg-icon svg {
  width: 100%;
  height: 100%;
}

/* Row: icono + badge disponibilidad */
.space-card-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  margin-bottom: 1.4rem;
}

/* Círculo icono */
.space-icon-wrap {
  width: 60px;
  height: 60px;
  border-radius: 14px;
  background: linear-gradient(135deg, rgba(255,255,255,0.12) 0%, rgba(255,255,255,0.04) 100%);
  border: 1px solid rgba(255,255,255,0.15);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  transition: background 0.3s ease, border-color 0.3s ease;
}

.space-card:hover .space-icon-wrap {
  background: linear-gradient(135deg, color-mix(in srgb, var(--card-accent) 25%, transparent), color-mix(in srgb, var(--card-accent) 8%, transparent));
  border-color: color-mix(in srgb, var(--card-accent) 50%, transparent);
}

.space-icon-wrap svg {
  width: 30px;
  height: 30px;
  color: #ffffff;
  transition: color 0.3s ease;
}

.space-card:hover .space-icon-wrap svg {
  color: var(--card-accent);
}

/* Pill de disponibilidad */
.space-avail-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  background: rgba(255,255,255,0.08);
  border: 1px solid rgba(255,255,255,0.15);
  color: rgba(255,255,255,0.75);
  font-size: 0.78rem;
  font-weight: 600;
  padding: 0.3rem 0.75rem;
  border-radius: var(--radius-pill);
  white-space: nowrap;
  letter-spacing: 0.3px;
}

.space-avail-pill--always {
  background: rgba(195, 214, 0, 0.12);
  border-color: rgba(195, 214, 0, 0.3);
  color: var(--primary);
}

.space-avail-dot {
  display: inline-block;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #4ade80;
  box-shadow: 0 0 0 2px rgba(74, 222, 128, 0.25);
  flex-shrink: 0;
  animation: pulse-dot 2s ease infinite;
}

.space-avail-pill--always .space-avail-dot {
  background: var(--primary);
  box-shadow: 0 0 0 2px rgba(195,214,0,0.25);
}

@keyframes pulse-dot {
  0%, 100% { box-shadow: 0 0 0 2px rgba(74, 222, 128, 0.25); }
  50%       { box-shadow: 0 0 0 5px rgba(74, 222, 128, 0.0); }
}

/* Título de la card */
.space-card-title {
  font-size: 1.4rem;
  font-weight: 600;
  color: #ffffff;
  margin-bottom: 0.6rem;
  line-height: 1.2;
}

/* Descripción */
.space-card-desc {
  font-size: 0.92rem;
  color: rgba(255,255,255,0.5);
  line-height: 1.65;
  margin-bottom: 1.2rem;
}

/* Lista de features */
.space-card-features {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  margin-bottom: 1.75rem;
  flex-grow: 1;
}

.space-card-features li {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  font-size: 0.88rem;
  color: rgba(255,255,255,0.65);
  line-height: 1.4;
}

.scf-check {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: color-mix(in srgb, var(--card-accent) 20%, transparent);
  color: var(--card-accent);
  font-size: 0.7rem;
  font-weight: 800;
  flex-shrink: 0;
}

/* Botón CTA de la card */
.space-card-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  width: 100%;
  padding: 0.85rem 1.25rem;
  min-height: 48px;
  border-radius: 10px;
  background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.15);
  color: rgba(255,255,255,0.85);
  font-size: 0.9rem;
  font-weight: 600;
  letter-spacing: 0.3px;
  transition: background 0.25s ease, border-color 0.25s ease, color 0.25s ease, transform 0.2s ease;
  text-align: center;
  margin-top: auto;
}

.space-card-btn:hover, .space-card-btn:active {
  background: var(--card-accent);
  border-color: var(--card-accent);
  color: #1a1a1a;
  transform: translateY(-1px);
}

.space-card-btn span {
  transition: transform 0.2s ease;
}
.space-card-btn:hover span {
  transform: translateX(3px);
}

/* Mantener btn-outline para uso en otras secciones */
.btn-outline {
  border: 1px solid var(--text-gray);
  color: var(--text-gray);
  background: white;
  border-radius: var(--radius-pill);
  padding: 0 1.5rem;
}

.btn-outline:hover {
  border-color: var(--black);
  color: var(--white);
  background: var(--black);
}


/* ================================
   SEARCH AND RESULTS SECTION (PREMIUM)
   ================================ */
.search-results-section {
  padding-top: var(--space-4);
  padding-bottom: var(--space-8);
  background-color: #f8f9fa; /* Fondo más limpio */
}

/* Premium Filter Wrapper */
.search-filter-wrapper {
  background: var(--white);
  border-radius: var(--radius-pill);
  padding: 0.5rem;
  box-shadow: 0 10px 30px rgba(0,0,0,0.06);
  margin-bottom: var(--space-6);
  transform: translateY(-50%); /* Superponer ligeramente a la sección anterior */
  margin-top: -3rem; 
  position: relative;
  z-index: 10;
  max-width: 1200px;
  margin-inline: auto;
}
@media (max-width: 991px) {
  .search-filter-wrapper {
    border-radius: 20px;
    padding: 1.5rem;
    margin-top: -2rem;
    transform: none;
  }
}

.search-filter-form {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
}
@media (max-width: 991px) {
  .search-filter-form {
    flex-direction: column;
    align-items: stretch;
    gap: 1rem;
  }
}

.search-field-group {
  display: flex;
  align-items: center;
  flex: 1;
  padding: 0.5rem 1rem;
  position: relative;
  border-radius: var(--radius-pill);
  transition: background 0.3s ease;
}
.search-field-group:hover, .search-field-group:focus-within {
  background: rgba(0,0,0,0.02);
}
@media (max-width: 991px) {
  .search-field-group {
    padding: 0.75rem 1rem;
    background: rgba(0,0,0,0.02);
  }
}

.sf-icon {
  width: 20px;
  height: 20px;
  color: var(--primary-dark);
  margin-right: 0.75rem;
  flex-shrink: 0;
}
.sf-icon svg {
  width: 100%;
  height: 100%;
}

/* Active State for Filter Group */
.search-field-group.sf-active {
  background: rgba(195, 214, 0, 0.12) !important;
  box-shadow: inset 0 0 0 1px rgba(195, 214, 0, 0.4);
}
.search-field-group.sf-active .sf-icon {
  color: var(--text-dark);
  transform: scale(1.1);
}
.search-field-group.sf-active .sf-control {
  color: var(--black);
  font-weight: 700;
}

.sf-control {
  width: 100%;
  border: none;
  background: transparent;
  font-size: 0.95rem;
  font-weight: 500;
  color: var(--text-dark);
  outline: none;
  cursor: pointer;
  -webkit-appearance: none;
  appearance: none;
  padding: 0.5rem;
  margin-left: -0.5rem;
}
.sf-control:focus {
  outline: none;
}
.sf-control option {
  padding: 0.5rem 1rem;
}

.sf-divider {
  width: 1px;
  height: 30px;
  background-color: var(--border-color);
}
@media (max-width: 991px) {
  .sf-divider {
    display: none;
  }
}

.sf-submit-btn {
  background: var(--text-dark);
  color: var(--white);
  border: none;
  border-radius: var(--radius-pill);
  height: 54px;
  padding: 0 2rem;
  font-weight: 600;
  font-size: 1rem;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  cursor: pointer;
  transition: all 0.3s ease;
  flex-shrink: 0;
}
.sf-submit-btn:hover {
  background: var(--primary);
  color: var(--text-dark);
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(195, 214, 0, 0.3);
}
.sf-submit-btn svg {
  width: 18px;
  height: 18px;
  transition: transform 0.3s ease;
}
.sf-submit-btn:hover svg {
  transform: scale(1.1) rotate(5deg);
}

/* PREMIUM RESULTS GRID */
.premium-results-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 2rem;
}
@media (min-width: 768px) {
  .premium-results-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}
@media (min-width: 1200px) {
  .premium-results-grid {
    grid-template-columns: repeat(4, 1fr);
  }
}

/* Premium Card */
.premium-card {
  background: var(--white);
  border-radius: 20px;
  overflow: hidden;
  box-shadow: 0 4px 15px rgba(0,0,0,0.03);
  border: 1px solid rgba(0,0,0,0.04);
  transition: all 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);
  display: flex;
  flex-direction: column;
  position: relative;
  height: 100%;
}
.premium-card:hover {
  transform: translateY(-8px);
  box-shadow: 0 20px 40px rgba(0,0,0,0.08);
  border-color: rgba(0,0,0,0.08);
}

.pc-image-wrapper {
  position: relative;
  width: 100%;
  aspect-ratio: 4/3;
  overflow: hidden;
}
.pc-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.6s cubic-bezier(0.165, 0.84, 0.44, 1);
}
.premium-card:hover .pc-image {
  transform: scale(1.08);
}

.pc-badge-type {
  position: absolute;
  top: 1rem;
  left: 1rem;
  background: rgba(255,255,255,0.9);
  backdrop-filter: blur(4px);
  color: var(--text-dark);
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
  padding: 0.4rem 0.8rem;
  border-radius: 8px;
  box-shadow: 0 4px 10px rgba(0,0,0,0.1);
}

.pc-badge-featured {
  position: absolute;
  top: 4.2rem;
  left: 1rem;
  background: #FFD700;
  color: #000;
  font-size: 0.7rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 1px;
  padding: 0.35rem 0.75rem;
  border-radius: 8px;
  box-shadow: 0 4px 12px rgba(255, 215, 0, 0.3);
  display: flex;
  align-items: center;
  gap: 0.4rem;
  z-index: 5;
  animation: pulse-featured 2s ease infinite;
}

@keyframes pulse-featured {
  0%, 100% { transform: scale(1); box-shadow: 0 4px 12px rgba(255, 215, 0, 0.3); }
  50% { transform: scale(1.05); box-shadow: 0 6px 18px rgba(255, 215, 0, 0.5); }
}

.card-featured {
  border: 2px solid #FFD700 !important;
}


.pc-status-badge {
  position: absolute;
  top: 1rem;
  right: 1rem;
  font-size: 0.8rem;
  font-weight: 600;
  padding: 0.4rem 0.8rem;
  border-radius: var(--radius-pill);
  display: flex;
  align-items: center;
  gap: 0.4rem;
  box-shadow: 0 4px 10px rgba(0,0,0,0.1);
}
.pc-status-in {
  background: var(--white);
  color: var(--text-dark);
}
.pc-dot {
  width: 8px;
  height: 8px;
  background: #4ade80;
  border-radius: 50%;
  display: inline-block;
  box-shadow: 0 0 0 2px rgba(74, 222, 128, 0.2);
}
.pc-status-out {
  background: #ff4757;
  color: var(--white);
}

/* Out of stock state */
.card-unavailable .pc-image {
  filter: grayscale(100%) opacity(0.8);
}
.card-unavailable .pc-content {
  opacity: 0.8;
}

.pc-content {
  padding: 1.5rem;
  display: flex;
  flex-direction: column;
  flex-grow: 1;
}

.pc-title {
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--text-dark);
  margin-bottom: 1rem;
  line-height: 1.3;
}

.pc-features {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.75rem;
  margin-bottom: 1.5rem;
}
.pc-feature {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.85rem;
  color: var(--text-gray);
}
.pc-feature svg {
  width: 16px;
  height: 16px;
  color: #a0a0a0;
}

.pc-footer {
  margin-top: auto;
  padding-top: 1.5rem;
  border-top: 1px solid rgba(0,0,0,0.06);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.pc-price-wrap {
  display: flex;
  flex-direction: column;
}
.pc-price {
  font-size: 1.6rem;
  font-weight: 700;
  color: var(--text-dark);
  line-height: 1;
}
.pc-period {
  font-size: 0.75rem;
  color: var(--text-gray);
  margin-top: 0.2rem;
}

.pc-btn {
  background: var(--bg-light);
  color: var(--text-dark);
  font-size: 0.85rem;
  font-weight: 600;
  padding: 0.6rem 1rem;
  border-radius: 10px;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  transition: all 0.3s ease;
  white-space: nowrap;
}
.pc-btn svg {
  width: 16px;
  height: 16px;
  transition: transform 0.3s ease;
}
.premium-card:hover .pc-btn {
  background: var(--primary);
}
.premium-card:hover .pc-btn svg {
  transform: translateX(3px);
}

/* ================================
   JOIN SECTION - REDISEÑO
   ================================ */
.join-section {
  background-color: var(--white);
  position: relative;
  overflow: hidden;
}

/* Decoración de fondo */
.join-section::before {
  content: '';
  position: absolute;
  top: -150px;
  right: -100px;
  width: 400px;
  height: 400px;
  background-color: var(--primary);
  opacity: 0.05;
  border-radius: 50%;
  z-index: 0;
}

.container-join {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-6);
  align-items: center;
}

@media (min-width: 992px) {
  .container-join {
    grid-template-columns: 1.1fr 0.9fr;
    gap: var(--space-8);
  }
}

/* NO RESULTS STATE */
.no-results-container {
  grid-column: 1 / -1; /* Ocupa todo el ancho del grid */
  background: var(--white);
  border-radius: 20px;
  padding: 3rem 2rem;
  text-align: center;
  box-shadow: 0 10px 30px rgba(0,0,0,0.04);
  border: 1px dashed var(--border-color);
  max-width: 800px;
  margin: 2rem auto;
}

.no-results-icon {
  width: 80px;
  height: 80px;
  margin: 0 auto 1.5rem;
  color: var(--primary-dark);
}

.no-results-content h3 {
  font-size: 1.75rem;
  color: var(--text-dark);
  margin-bottom: 1rem;
}

.no-results-content p {
  color: var(--text-gray);
  margin-bottom: 2.5rem;
}

/* No Results Form */
.no-results-form {
  text-align: left;
  border-top: 1px solid var(--border-color);
  padding-top: 2.5rem;
}

.nrf-grid {
  display: grid;
  grid-template-columns: repeat(1, 1fr);
  gap: 1.5rem;
  margin-bottom: 2rem;
}

@media (min-width: 600px) {
  .nrf-grid {
    grid-template-columns: repeat(3, 1fr);
  }
  .full-width {
    grid-column: 1 / -1;
  }
}

.nrf-field {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.nrf-field label {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-dark);
}

.nrf-field input, .nrf-field textarea {
  padding: 0.75rem 1rem;
  border: 1px solid var(--border-color);
  border-radius: 10px;
  font-size: 0.95rem;
  background: var(--bg-light);
  transition: border-color 0.3s ease;
}

.nrf-field input:focus, .nrf-field textarea:focus {
  outline: none;
  border-color: var(--primary);
  background: var(--white);
}

.nrf-submit {
  width: 100%;
  margin-top: 1rem; /* Añadimos un pequeño extra */
}

.nrf-privacy {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-top: 1rem;
  margin-bottom: 2.5rem;
  font-size: 0.95rem; /* Un pelo más grande para legibilidad */
  color: var(--text-gray);
}

.nrf-privacy input[type="checkbox"] {
  width: 18px;
  height: 18px;
  cursor: pointer;
  accent-color: var(--primary);
}

.nrf-privacy label {
  cursor: pointer;
}

.nrf-privacy label a {
  color: var(--primary-dark);
  font-weight: 500;
  text-decoration: underline;
}

.nrf-footer {
  text-align: center;
  font-size: 0.85rem;
  margin-top: 1rem !important;
  color: var(--text-gray);
}

/* Hidden class for filtering */
.hidden-card {
  display: none !important;
}

/* REFINEMENT: Ensure grid doesn't break when cards are hidden */

.join-content {
  display: flex;
  flex-direction: column;
}

.join-badge-wrap {
  margin-bottom: var(--space-3);
}

.join-badge {
  display: inline-block;
  background-color: rgba(195, 214, 0, 0.2);
  color: var(--primary-dark);
  font-size: 0.85rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
  padding: 0.4rem 1.2rem;
  border-radius: var(--radius-pill);
}

.join-main-title {
  font-size: 2.2rem;
  line-height: 1.2;
  font-weight: 500;
  margin-bottom: var(--space-4);
  color: var(--text-dark);
}

@media (min-width: 768px) {
  .join-main-title {
    font-size: 3rem;
  }
}

.title-highlight {
  color: var(--primary-dark);
  position: relative;
  display: inline-block;
}

.title-highlight::after {
  content: '';
  position: absolute;
  bottom: 6px;
  left: 0;
  width: 100%;
  height: 10px;
  background-color: var(--primary);
  z-index: -1;
  opacity: 0.5;
}

.join-lead {
  font-size: 1.15rem;
  color: var(--text-dark);
  margin-bottom: var(--space-3);
  line-height: 1.6;
}

.join-desc {
  font-size: 1.05rem;
  color: var(--text-gray);
  margin-bottom: var(--space-4);
  line-height: 1.7;
}

/* Lista de características */
.join-features-list {
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
  margin-bottom: var(--space-5);
}

.join-features-list li {
  display: flex;
  align-items: center;
  gap: 1rem;
  font-size: 1.05rem;
  color: var(--text-dark);
  font-weight: 500;
}

.feature-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  background-color: var(--primary);
  color: var(--black);
  border-radius: 50%;
  flex-shrink: 0;
}

.feature-icon svg {
  width: 20px;
  height: 20px;
}

/* Botón CTA */
.join-action {
  margin-top: var(--space-2);
}

.join-btn {
  display: inline-flex;
  gap: 0.5rem;
  padding: 0 2.5rem;
  height: 54px;
  font-size: 1.05rem;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.join-btn:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

.join-btn svg {
  width: 20px;
  height: 20px;
  transition: transform 0.2s ease;
}

.join-btn:hover svg {
  transform: translateX(4px);
}

/* Columna de Ubicaciones */
.join-locations {
  display: flex;
  flex-direction: column;
  gap: var(--space-4);
}

.location-box {
  background-color: var(--white);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-sm);
  overflow: hidden;
  border: 1px solid var(--border-color);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.location-box:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-md);
}

.location-box-header {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 1.25rem 1.5rem;
  border-bottom: 1px solid var(--border-color);
  background-color: var(--white);
}

.location-box-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 48px;
  height: 48px;
  background-color: var(--bg-light);
  color: var(--text-dark);
  border-radius: 50%;
  flex-shrink: 0;
  transition: background-color 0.3s ease, color 0.3s ease;
}

.location-box:hover .location-box-icon {
  background-color: var(--primary);
  color: var(--black);
}

.location-box-icon svg {
  width: 24px;
  height: 24px;
}

.location-box-title {
  font-size: 1.2rem;
  font-weight: 600;
  color: var(--text-dark);
  margin-bottom: 0.2rem;
}

.location-box-address {
  font-size: 0.9rem;
  color: var(--text-gray);
  line-height: 1.4;
}

.location-map {
  width: 100%;
  height: 250px;
  background-color: var(--bg-light);
  position: relative;
}

.location-map iframe {
  width: 100%;
  height: 100%;
  display: block;
}

/* ================================
   PRE-FOOTER CTA
   ================================ */
.pre-footer-cta {
  background-color: var(--primary);
  padding: var(--space-5) 0;
  position: relative;
  z-index: 5;
}

.pf-container {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: var(--space-4);
}

@media (min-width: 768px) {
  .pf-container {
    flex-direction: row;
    justify-content: space-between;
    text-align: left;
  }
}

.pf-text h3 {
  font-size: 1.75rem;
  font-weight: 700;
  color: var(--black);
  margin-bottom: 0.5rem;
}

.pf-text p {
  color: rgba(0,0,0,0.7);
  font-size: 1.1rem;
}

.pf-btn {
  background-color: var(--black);
  color: var(--white);
  border-color: var(--black);
  height: 56px;
  padding: 0 2.5rem;
  gap: 0.75rem;
}

.pf-btn:hover {
  background-color: var(--white);
  color: var(--black);
  border-color: var(--white);
  transform: translateY(-3px);
  box-shadow: 0 10px 20px rgba(0,0,0,0.1);
}

.pf-btn svg {
  transition: transform 0.3s ease;
}

.pf-btn:hover svg {
  transform: translateX(5px);
}

/* ================================
   SITE FOOTER (DARK PREMIUM)
   ================================ */
.site-footer {
  background: linear-gradient(160deg, #1a1a1a 0%, #2c2c2c 60%, #1f1f1f 100%);
  color: rgba(255,255,255,0.7);
  padding: var(--space-6) 0 0; /* No bottom padding here, bottom bar handles it */
  position: relative;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-5);
  margin-bottom: var(--space-6);
}

@media (min-width: 768px) {
  .footer-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 1024px) {
  .footer-grid {
    grid-template-columns: 1.5fr 1fr 1fr 1.2fr;
    gap: var(--space-4);
  }
}

.footer-logo {
  height: 45px;
  width: auto;
  margin-bottom: 1.5rem;
  filter: brightness(0) invert(1); /* Logo en blanco */
}

.footer-brand-desc {
  font-size: 0.95rem;
  line-height: 1.6;
  margin-bottom: 2rem;
  max-width: 320px;
}

.footer-heading {
  color: var(--white);
  font-size: 1.1rem;
  font-weight: 600;
  margin-bottom: 1.75rem;
  position: relative;
}

.footer-heading::after {
  content: '';
  position: absolute;
  bottom: -8px;
  left: 0;
  width: 30px;
  height: 2px;
  background-color: var(--primary);
}

.footer-text {
  font-size: 0.95rem;
  line-height: 1.8;
  margin-bottom: 1.25rem;
}

.footer-map-link {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  color: var(--primary);
  font-weight: 600;
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  transition: color 0.3s ease, transform 0.3s ease;
}

.footer-map-link:hover {
  color: var(--white);
  transform: translateX(5px);
}

/* Contact items in footer */
.footer-contact-items {
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
  margin-bottom: 2.5rem;
}

.footer-contact-item {
  display: flex;
  align-items: center;
  gap: 1rem;
  color: rgba(255,255,255,0.8);
  transition: color 0.3s ease;
}

.fci-icon {
  width: 36px;
  height: 36px;
  background-color: rgba(255,255,255,0.05);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--primary);
  transition: background-color 0.3s ease, color 0.3s ease;
}

.footer-contact-item:hover {
  color: var(--white);
}

.footer-contact-item:hover .fci-icon {
  background-color: var(--primary);
  color: var(--black);
}

/* Social icons footer */
.social-links {
  display: flex;
  gap: 0.75rem;
}

.social-icon {
  width: 42px;
  height: 42px;
  background-color: rgba(255,255,255,0.05);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--white);
  transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.social-icon:hover {
  background-color: var(--primary);
  color: var(--black);
  transform: translateY(-5px) rotate(8deg);
}

/* EU Footer Block Redesign */
.footer-eu-img {
  width: 100%;
  max-width: 250px;
  height: auto;
  display: block;
  margin-top: 2rem;
}

/* FOOTER BOTTOM BAR */
.footer-bottom {
  margin-top: var(--space-4);
  padding: 1.5rem 0;
  border-top: 1px solid rgba(255,255,255,0.05);
  background: transparent;
}

.fb-container {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1rem;
  text-align: center;
}

@media (min-width: 768px) {
  .fb-container {
    flex-direction: row;
    justify-content: space-between;
    text-align: left;
  }
}

.fb-copy {
  font-size: 0.85rem;
  color: rgba(255,255,255,0.4);
}

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

.fb-links a {
  font-size: 0.85rem;
  color: rgba(255,255,255,0.4);
  transition: color 0.3s ease;
}

.fb-links a:hover {
  color: var(--primary);
}


/* ================================
   PARTNERS / EMPRESAS SOCIAS
   ================================ */

.partners-section {
  background-color: var(--white);
}

.title-highlight {
  color: var(--primary-dark);
}

.partners-subtitle {
  text-align: center;
  color: var(--text-gray);
  font-size: 1rem;
  margin-top: -2rem;
  margin-bottom: var(--space-5);
}

/* Carrusel Infinito (Marquee) */
.partners-marquee-wrapper {
  overflow: hidden;
  white-space: nowrap;
  position: relative;
  display: flex;
  gap: 1.5rem;
  padding: 1.5rem 0; /* Espacio para que la sombra hover no se corte */
  margin-top: 1rem;
  /* Efecto de difuminado suave en los bordes */
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 5%, #000 95%, transparent);
  mask-image: linear-gradient(90deg, transparent, #000 5%, #000 95%, transparent);
}

.partners-marquee-wrapper:hover .partners-marquee-track {
  animation-play-state: paused;
}

.partners-marquee-track {
  display: flex;
  gap: 1.5rem;
  animation: scroll-marquee 40s linear infinite;
  min-width: 100%;
  flex-shrink: 0; /* Evita que el wrapper comprima el track y los logos se monten */
}

@media (max-width: 768px) {
  /* En móviles quitamos la máscara suavizada para mejor rendimiento y feedback visual puro */
  .partners-marquee-wrapper {
    -webkit-mask-image: none;
    mask-image: none;
  }
}

@keyframes scroll-marquee {
  0% { transform: translateX(0); }
  100% { transform: translateX(calc(-100% - 1.5rem)); } 
}

/* Tarjeta individual (Optimizada para carrusel) */
.partner-card {
  background-color: rgba(255, 255, 255, 0.6); /* Efecto Glassmorphism */
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  border: 1px solid rgba(0, 0, 0, 0.05);
  border-radius: var(--radius-md);
  padding: 1.5rem 1rem;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 120px;
  width: 250px; /* Ancho fijo para mantener la consistencia en el slider */
  flex-shrink: 0; /* Impide que las tarjetas se encojan en la fila */
  cursor: pointer;
  white-space: normal; /* Restaura el wrap del texto dentro de la tarjeta */
  transition: box-shadow 0.3s ease, border-color 0.3s ease, background-color 0.3s ease, transform 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.partner-card:hover {
  background-color: var(--white);
  box-shadow: 0 15px 35px rgba(0,0,0,0.06); /* Sombra premium */
  transform: translateY(-8px);
  border-color: var(--primary);
  z-index: 2;
}

.partner-logo-wrap {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
}

/* Cuando haya imagen real */
.partner-logo-wrap img {
  max-height: 60px;
  max-width: 100%;
  object-fit: contain;
  filter: grayscale(100%);
  opacity: 0.65;
  transition: filter 0.2s ease, opacity 0.2s ease;
}

.partner-card:hover .partner-logo-wrap img {
  filter: grayscale(0%);
  opacity: 1;
}

/* TEXT-LOGO base (fallback mientras no hay imágenes) */
.partner-text-logo {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  flex-direction: column;
  text-align: center;
  line-height: 1.2;
}

.ptl-info {
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
}

.ptl-info strong {
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--text-dark);
}

.ptl-info small,
.ptl-tagline {
  font-size: 0.65rem;
  color: var(--text-gray);
  text-transform: none;
  letter-spacing: 0.3px;
}

/* PG badge */
.ptl-badge {
  background-color: #f0a500; /* brand amber */
  color: white;
  font-weight: 800;
  font-size: 1rem;
  padding: 0.3rem 0.5rem;
  border-radius: 4px;
  letter-spacing: 1px;
}

/* MásPUBLICIDAD */
.ptl-name--bold {
  font-size: 1rem;
  font-weight: 800;
  letter-spacing: -0.5px;
  color: var(--text-dark);
}

.ptl-name--thin {
  font-weight: 300;
}

/* esferic */
.ptl-circle-icon {
  font-size: 1.8rem;
  color: #999;
  line-height: 1;
}

.ptl-name--light {
  font-size: 1rem;
  font-weight: 300;
  letter-spacing: 1px;
  color: var(--text-dark);
}

/* NOS comunicamos */
.ptl-circle-badge {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 0.85rem;
  color: white;
}

.ptl-circle-badge--orange {
  background-color: #e8602d;
}

/* Happy Swallow */
.ptl-name--script {
  font-size: 1.1rem;
  font-family: Georgia, serif;
  font-style: italic;
  color: var(--text-dark);
}

/* Activa-T */
.ptl-chat-icon {
  width: 44px;
  height: 44px;
  border-radius: 8px;
  border: 2.5px solid #e8602d;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 1rem;
  color: #e8602d;
}

.ptl-name--accent {
  font-weight: 700;
  color: #e8602d;
  font-size: 0.85rem;
}

/* maminat */
.ptl-leaf {
  font-size: 1.5rem;
}

/* GMartz */
.ptl-bulb {
  font-size: 1.5rem;
}

/* Aislamientos marsan */
.ptl-name--marsan {
  font-size: 0.85rem;
  color: var(--text-dark);
}

.ptl-name--marsan em {
  font-style: italic;
  color: var(--text-gray);
}

/* INVOICEGREEN */
.ptl-name--green {
  color: #2e7d32;
  font-size: 0.75rem;
  display: block;
  text-align: center;
}

/* ================================
   TESTIMONIALS / TESTIMONIOS
   ================================ */

.testimonials-section {
  background-color: var(--white);
  padding-top: var(--space-5);
  padding-bottom: 110px; /* Generoso espacio inferior para dar "aire" a los testimonios */
}

.testimonials-slider-wrapper {
  position: relative;
  max-width: 100%;
  margin: 0 auto;
  padding: 0 10px;
}

.testimonials-slider {
  display: flex;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scroll-behavior: smooth;
  gap: var(--space-4);
  padding: 20px 0 40px;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none; /* Firefox */
}

.testimonials-slider::-webkit-scrollbar {
  display: none; /* Chrome, Safari, Opera */
}

.testimonial-card {
  flex: 0 0 calc(100% - 20px); /* 1 card on mobile */
  scroll-snap-align: center;
  background-color: var(--white);
  border: none;
  border-radius: var(--radius-md);
  padding: 2.5rem 2rem;
  display: flex;
  flex-direction: column;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  min-height: 480px; /* Altura mínima consistente */
  box-shadow: 0 10px 40px rgba(0,0,0,0.05);
  position: relative;
  overflow: hidden;
  border-top: 4px solid var(--primary);
}

@media (min-width: 768px) {
  .testimonial-card {
    flex: 0 0 calc(50% - (var(--space-4) / 2)); /* 2 cards */
  }
}

@media (min-width: 1024px) {
  .testimonial-card {
    flex: 0 0 calc(33.333% - (var(--space-4) * 2 / 3)); /* 3 cards */
  }
}

@media (min-width: 1400px) {
  .testimonial-card {
    flex: 0 0 calc(25% - (var(--space-4) * 3 / 4)); /* 4 cards */
  }
}

/* Slider Buttons */
.slider-nav-btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 50px;
  height: 50px;
  border-radius: 50%;
  background: var(--white);
  border: 1px solid var(--border-color);
  box-shadow: 0 4px 12px rgba(0,0,0,0.1);
  cursor: pointer;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.3s ease;
  color: var(--text-dark);
}

.slider-nav-btn:hover {
  background: var(--primary);
  border-color: var(--primary);
  transform: translateY(-50%) scale(1.1);
}

.slider-prev { left: -25px; }
.slider-next { right: -25px; }

@media (max-width: 1100px) {
  .slider-nav-btn { display: none; } /* On mobile/tablet we use touch scroll */
  .testimonials-slider-wrapper { padding: 0; }
}

/* Dots */
.slider-dots {
  display: flex;
  justify-content: center;
  gap: 10px;
  margin-top: 10px;
}

.dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--border-color);
  border: none;
  cursor: pointer;
  padding: 0;
  transition: all 0.3s ease;
}

.dot.active {
  background: var(--primary);
  transform: scale(1.3);
}

.testimonial-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 15px 50px rgba(0,0,0,0.08);
}

.quote-watermark {
  position: absolute;
  top: -15px;
  right: -15px;
  width: 120px;
  height: 120px;
  fill: var(--primary);
  opacity: 0.08; /* Muy sutil en el fondo */
  transform: rotate(-10deg);
  z-index: 0;
  pointer-events: none;
}

.testimonial-stars {
  color: #fbbf24; /* Color oro cálido */
  font-size: 1.2rem;
  letter-spacing: 2px;
  margin-bottom: var(--space-4);
  position: relative;
  z-index: 1;
}

.testimonial-quote {
  flex-grow: 1; 
  display: flex;
  flex-direction: column;
  justify-content: center; /* ¡LA MAGIA! Centra verticalmente los textos cortos */
  position: relative;
  margin-bottom: var(--space-4);
  z-index: 1; /* Por encima de la marca de agua */
}

.testimonial-quote p {
  color: var(--text-dark);
  font-size: 1.05rem;
  line-height: 1.8;
  font-style: italic;
  font-weight: 300; /* Texto más fino y elegante */
}

.testimonial-author {
  border-top: 1px solid var(--border-color);
  padding-top: var(--space-4);
  margin-top: auto; /* Fuerza que el bloque de autor siempre esté pegado abajo si no se llena el espacio */
  display: flex;
  align-items: center;
  gap: 1rem;
  position: relative;
  z-index: 1;
}

.author-avatar {
  width: 46px;
  height: 46px;
  background-color: var(--primary);
  color: var(--text-dark);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 1.2rem;
  flex-shrink: 0;
}

.author-info h4 {
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--text-dark);
  margin-bottom: 0.1rem;
}

.author-info span {
  font-size: 0.75rem;
  color: var(--text-gray);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  display: block;
}


/* ================================
   GRANTS SECTION / AYUDAS (Minimalista)
   ================================ */

.grants-section {
  padding: var(--space-6) 0;
  background-color: var(--bg-light);
  border-top: 1px solid var(--border-color);
}

.grants-card {
  max-width: 900px;
  margin: 0 auto;
  text-align: center;
  background: var(--white);
  padding: var(--space-6) var(--space-5);
  border-radius: var(--radius-md);
  box-shadow: 0 10px 40px rgba(0,0,0,0.05);
  border-top: 4px solid var(--primary); /* Coherencia con cards de testimonios */
}

.grants-intro {
  font-size: 1.25rem;
  color: var(--text-dark);
  margin-bottom: var(--space-5);
  line-height: 1.6;
  font-weight: 600;
  font-style: italic;
}

.grants-body {
  font-size: 1.05rem;
  color: var(--text-gray);
  line-height: 1.8;
}

.grants-body p {
  margin-bottom: var(--space-3);
}

.grants-body strong {
  color: var(--text-dark);
}

.grants-image {
  margin-top: var(--space-6);
  display: flex;
  justify-content: center;
}

.grants-image img {
  max-width: 100%;
  height: auto;
  border-radius: var(--radius-sm);
}

@media (max-width: 768px) {
  .grants-section {
    padding: var(--space-5) 0;
  }
  .grants-card {
    padding: var(--space-4) var(--space-3);
    margin: 0 var(--space-2);
  }
  .grants-intro {
    font-size: 1.1rem;
  }
}

/* ================================
   MODAL OVERLAY & CONTAINER
   ================================ */
.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.6);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 2000;
  opacity: 0;
  visibility: hidden;
  transition: all 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);
  padding: 1.5rem;
}

.modal-overlay.active {
  opacity: 1;
  visibility: visible;
}

.modal-container {
  background: var(--white);
  width: 100%;
  max-width: 750px;
  border-radius: 28px;
  box-shadow: 0 30px 60px -12px rgba(0, 0, 0, 0.3);
  position: relative;
  overflow: hidden;
  transform: translateY(30px) scale(0.95);
  transition: all 0.5s cubic-bezier(0.34, 1.56, 0.64, 1);
  border-bottom: 6px solid var(--primary); /* Línea de bajo perfectamente alineada */
}

.modal-overlay.active .modal-container {
  transform: translateY(0) scale(1);
}

.modal-close {
  position: absolute;
  top: 1.5rem;
  right: 1.5rem;
  background: var(--bg-light);
  border: none;
  width: 42px;
  height: 42px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  color: var(--text-dark);
  transition: all 0.3s ease;
  z-index: 100;
  box-shadow: 0 4px 10px rgba(0,0,0,0.05);
}

.modal-close:hover {
  background: var(--primary);
  transform: rotate(90deg);
  color: var(--black);
}

.modal-content {
  padding: 3.5rem 3rem;
  max-height: 90vh;
  overflow-y: auto;
  scrollbar-width: thin;
  scrollbar-color: var(--primary) transparent;
}

/* Ajustes finos formulario en modal */
.modal-content .no-results-content {
  text-align: left;
}

.modal-content .no-results-form {
  border-top: none;
  padding-top: 0.5rem;
  margin-top: 1.5rem;
}

.modal-content .no-results-icon {
  margin: 0 0 1.5rem 0;
  width: 60px;
  height: 60px;
  color: var(--primary-dark);
  background: rgba(195, 214, 0, 0.1);
  padding: 12px;
  border-radius: 16px;
}

/* Forzar que el grid no se salga en el modal y sea más elástico */
.modal-content .nrf-grid {
  grid-template-columns: 1fr;
  width: 100%;
  max-width: 100%;
}

@media (min-width: 600px) {
  .modal-content .nrf-grid {
    grid-template-columns: repeat(2, 1fr); /* 2 columnas es más seguro para evitar desbordamientos */
  }
}

@media (min-width: 800px) {
  .modal-content .nrf-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

.modal-content .nrf-field input, 
.modal-content .nrf-field textarea {
  width: 100%;
  max-width: 100%;
}

.modal-content h3 {
  font-size: 1.8rem;
  margin-bottom: 0.75rem;
  font-weight: 700;
}

.modal-content p {
  font-size: 1.05rem;
  color: var(--text-gray);
  margin-bottom: 2rem;
  line-height: 1.6;
}

/* Responsive Modal */
@media (max-width: 767px) {
  .modal-overlay {
    padding: 1rem;
  }
  .modal-container {
    border-radius: 20px;
  }
  .modal-content {
    padding: 2.5rem 1.5rem;
  }
  .modal-content h3 {
    font-size: 1.5rem;
  }
}

/* ================================
   SINGLE OFFICE PAGE (PREMIUM UX)
   ================================ */

/* Hero Section */
.single-office-hero {
  padding-top: var(--space-4);
  padding-bottom: var(--space-4);
  background-color: var(--white);
}

.office-breadcrumb {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.85rem;
  color: var(--text-gray);
  margin-bottom: var(--space-4);
}

.office-breadcrumb a {
  font-weight: 500;
  transition: color 0.2s;
}

.office-breadcrumb a:hover {
  color: var(--primary-dark);
}

.office-breadcrumb svg {
  color: var(--border-color);
}

.soh-header-text {
  margin-bottom: var(--space-4);
  position: relative;
}

.pos-relative-badge {
  position: relative;
  top: 0;
  right: 0;
  display: inline-flex;
  margin-bottom: 1rem;
  border: 1px solid var(--border-color);
}

.soh-title {
  font-size: 2.5rem;
  font-weight: 600;
  line-height: 1.2;
  margin-bottom: 0.5rem;
  color: var(--black);
}

.soh-title .title-highlight {
  font-weight: 700;
}

.soh-location {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  color: var(--text-gray);
  font-size: 1.05rem;
}

@media (max-width: 767px) {
  .soh-title {
    font-size: 2rem;
  }
}

/* Gallery Grid (Airbnb Style) */
.soh-gallery-grid {
  display: grid;
  grid-template-columns: 2fr 1fr;
  grid-template-rows: 1fr 1fr;
  gap: 1rem;
  height: 500px;
  border-radius: 24px;
  overflow: hidden;
  background-color: #ffffff; /* Evita que el fondo oscuro de la sección se vea por los bordes */
  position: relative;
  border: 1px solid rgba(0,0,0,0.02); /* Borde casi invisible que suaviza la transición */
  transform: translateZ(0); /* Forzado de aceleración GPU para suavizar bordes curvos */
}

.gallery-main {
  grid-column: 1 / 2;
  grid-row: 1 / 3;
  position: relative;
}

.gallery-main img, .gallery-side img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.6s cubic-bezier(0.165, 0.84, 0.44, 1);
  border-radius: inherit; /* Las imágenes heredan la curvatura para evitar bordes dentados */
  display: block;
  backface-visibility: hidden;
  transform: translateZ(0); /* Mejora el suavizado de los píxeles en los bordes */
}

.gallery-main:hover img, .gallery-side:hover img {
  transform: scale(1.03);
}

.gallery-side {
  position: relative;
  overflow: hidden;
}

.gallery-side-top {
  grid-column: 2 / 3;
  grid-row: 1 / 2;
}

.gallery-side-bottom {
  grid-column: 2 / 3;
  grid-row: 2 / 3;
}

.btn-gallery-more {
  position: absolute;
  bottom: 1rem;
  right: 1rem;
  background: var(--white);
  border: none;
  padding: 0.6rem 1rem;
  border-radius: 12px;
  font-weight: 600;
  font-size: 0.9rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  box-shadow: 0 4px 12px rgba(0,0,0,0.1);
  transition: all 0.3s ease;
}

.btn-gallery-more:hover {
  background: var(--bg-light);
  transform: translateY(-2px);
}

@media (max-width: 991px) {
  .soh-gallery-grid {
    grid-template-columns: 1fr;
    grid-template-rows: auto;
    height: auto;
    border-radius: 16px;
  }
  .gallery-main {
    grid-column: 1 / -1;
    grid-row: 1 / 2;
    aspect-ratio: 4/3;
    position: relative;
  }
  .gallery-side-top {
    display: none; /* Simplificamos en móvil */
  }
  .gallery-side-bottom {
    display: none;
  }
  .btn-gallery-more {
    display: flex !important; /* Forzamos visibilidad */
    bottom: 1rem;
    right: 1rem;
    padding: 0.6rem 1rem;
    font-size: 0.85rem;
  }
}

/* Content Layout */
.single-office-content {
  padding-top: var(--space-5);
  padding-bottom: var(--space-6);
}

.container-office-layout {
  display: flex;
  gap: var(--space-6);
  align-items: flex-start;
}

.sol-main {
  flex: 1;
  min-width: 0;
}

.sol-sidebar {
  width: 380px;
  flex-shrink: 0;
  position: sticky;
  top: 120px; /* Offset del header */
}

@media (max-width: 1024px) {
  .container-office-layout {
    flex-direction: column;
  }
  .sol-sidebar {
    width: 100%;
    position: relative;
    top: 0;
  }
}

/* Highlights */
.soc-highlights {
  display: flex;
  flex-wrap: wrap;
  gap: 1.5rem;
  margin-bottom: var(--space-5);
}

.soc-chip {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.soc-chip svg {
  color: var(--primary-dark);
  flex-shrink: 0;
}

.soc-chip span {
  font-size: 1rem;
  color: var(--text-dark);
}

.soc-chip strong {
  display: block;
  font-size: 1.1rem;
}

.soc-divider {
  border: none;
  height: 1px;
  background-color: var(--border-color);
  margin: var(--space-5) 0;
}

.soc-section {
  margin-bottom: var(--space-5);
}

.soc-title {
  font-size: 1.5rem;
  font-weight: 600;
  margin-bottom: 1.5rem;
}

.soc-text p {
  margin-bottom: 1rem;
  font-size: 1.05rem;
  color: var(--text-gray);
  line-height: 1.7;
}

/* Amenities Grid */
.soc-amenities-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 1.5rem;
}

.amenity-item {
  display: flex;
  align-items: center;
  gap: 1.25rem;
}

.amenity-icon {
  width: 52px;
  height: 52px;
  background: var(--white);
  border-radius: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--primary-dark);
  box-shadow: 0 4px 10px rgba(0,0,0,0.06);
  flex-shrink: 0;
}

.amenity-icon svg {
  width: 24px;
  height: 24px;
  stroke-width: 2.2px;
}

.amenity-item span {
  font-size: 1.1rem;
  font-weight: 500;
  color: var(--text-dark);
}

/* Extras */
.soc-list-extra li {
  display: flex;
  align-items: flex-start;
  gap: 1rem;
  margin-bottom: 1rem;
  font-size: 1.05rem;
  color: var(--text-gray);
}

.plus-icon {
  font-weight: 700;
  color: var(--primary-dark);
}

/* Sticky Booking Card */
.sticky-booking-card {
  background: var(--white);
  border-radius: 20px;
  padding: 2rem;
  box-shadow: 0 10px 40px -10px rgba(0,0,0,0.1);
  border: 1px solid rgba(0,0,0,0.03);
}

.sbc-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 2rem;
}

.sbc-price {
  font-size: 2.2rem;
  font-weight: 700;
  line-height: 1;
}

.sbc-period {
  color: var(--text-gray);
  font-size: 0.9rem;
  margin-top: 0.2rem;
}

.sbc-features {
  border-top: 1px solid var(--border-color);
  border-bottom: 1px solid var(--border-color);
  padding: 1.5rem 0;
  margin-bottom: 1.5rem;
}

.sbc-feat-row {
  display: flex;
  justify-content: space-between;
  margin-bottom: 0.75rem;
  font-size: 0.95rem;
}

.sbc-feat-row:last-child {
  margin-bottom: 0;
}

.sbc-feat-label {
  color: var(--text-gray);
}

.sbc-feat-val {
  font-weight: 600;
  color: var(--text-dark);
}

.sbc-feat-val.highlight {
  color: #10b981;
}

.sbc-actions {
  text-align: center;
  margin-bottom: 1.5rem;
}

.sbc-btn {
  width: 100%;
  height: 56px;
  font-size: 1.1rem;
  margin-bottom: 1rem;
  background: var(--black);
  color: var(--white);
  transition: all 0.3s ease;
}

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

.sbc-microcopy {
  font-size: 0.8rem;
  color: var(--text-gray);
}

.sbc-footer {
  text-align: center;
}

.sbc-phone {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-weight: 600;
  color: var(--text-dark);
  font-size: 1.05rem;
}

.sbc-phone:hover {
  text-decoration: underline;
  color: var(--primary-dark);
}

/* Office Map Section */
.office-map-section {
  padding-bottom: var(--space-8);
  background: var(--bg-light);
}

.om-container {
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  gap: 3rem;
  align-items: center;
}

@media (max-width: 991px) {
  .om-container {
    grid-template-columns: 1fr;
  }
}

.om-text h2 {
  font-size: 2rem;
  margin-bottom: 1rem;
  color: var(--black);
}

.om-text p {
  color: var(--text-gray);
  margin-bottom: 2rem;
  font-size: 1.1rem;
}

.om-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
}

.om-badge {
  background: var(--white);
  padding: 0.5rem 1rem;
  border-radius: var(--radius-pill);
  font-size: 0.9rem;
  font-weight: 600;
  box-shadow: 0 2px 10px rgba(0,0,0,0.05);
}

/* ================================
   ERROR 404 PAGE STYLES
   ================================ */
.error-404-section {
  min-height: calc(100vh - var(--header-height));
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(160deg, #1a1a1a 0%, #2c2c2c 60%, #1f1f1f 100%);
  padding: var(--space-6) 0;
  overflow: hidden;
  position: relative;
}

/* Decoración de fondo (esferas de luz sutiles) */
.error-404-section::before {
  content: '';
  position: absolute;
  top: -10%;
  right: -5%;
  width: 500px;
  height: 500px;
  background: radial-gradient(circle, rgba(195, 214, 0, 0.05) 0%, transparent 70%);
  z-index: 0;
}

.error-404-content {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-8);
  flex-wrap: wrap;
  position: relative;
  z-index: 1;
}

.error-404-text {
  flex: 1;
  min-width: 300px;
  max-width: 500px;
  z-index: 2;
}

.error-badge {
  display: inline-block;
  background: rgba(195, 214, 0, 0.15);
  color: var(--primary);
  font-size: 0.85rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 2px;
  padding: 0.35rem 1.2rem;
  border-radius: var(--radius-pill);
  border: 1px solid rgba(195, 214, 0, 0.3);
  margin-bottom: 1.5rem;
}

.error-heading {
  font-size: 3.5rem;
  font-weight: 800;
  line-height: 1.1;
  color: var(--white);
  margin-bottom: 1.5rem;
}

.error-desc {
  font-size: 1.15rem;
  color: var(--white);
  line-height: 1.6;
  margin-bottom: 2.5rem;
}

.error-actions .btn-primary {
  background-color: var(--primary);
  color: var(--black);
  border-color: var(--primary);
}

.error-actions .btn-primary:hover {
  background-color: var(--white);
  border-color: var(--white);
  color: var(--black);
}

.error-404-image {
  flex: 1.2;
  min-width: 300px;
  position: relative;
  z-index: 1;
  display: flex;
  justify-content: center;
}

.error-404-image img {
  width: 100%;
  max-width: 600px;
  height: auto;
  filter: drop-shadow(0 20px 50px rgba(0,0,0,0.3));
}

.floating-image {
  animation: float 6s ease-in-out infinite;
}

@keyframes float {
  0% { transform: translateY(0px); }
  50% { transform: translateY(-20px); }
  100% { transform: translateY(0px); }
}

/* Responsive 404 */
@media (max-width: 991px) {
  .error-404-content {
    flex-direction: column-reverse;
    text-align: center;
    gap: var(--space-4);
  }
  
  .error-404-text {
    max-width: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
  }
  
  .error-heading {
    font-size: 2.5rem;
  }
}

/* ================================
   LIGHTBOX GALERÍA
   ================================ */
.lightbox-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.95);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  z-index: 3000;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  visibility: hidden;
  transition: all 0.4s ease;
}

.lightbox-overlay.active {
  opacity: 1;
  visibility: visible;
}

.lightbox-content {
  width: 90%;
  max-width: 1200px;
  max-height: 85vh;
  display: flex;
  align-items: center;
  justify-content: center;
  transform: scale(0.9);
  transition: transform 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
}

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

#lightbox-img {
  max-width: 100%;
  max-height: 85vh;
  object-fit: contain;
  border-radius: 4px;
  box-shadow: none; /* Eliminado el borde oscuro pesado */
  opacity: 1;
  transition: opacity 0.3s ease;
}

/* Botones Navegación */
.lightbox-close, .lightbox-prev, .lightbox-next {
  position: absolute;
  background: none;
  border: none;
  color: white;
  font-size: 2.5rem;
  cursor: pointer;
  transition: all 0.2s ease;
  z-index: 10;
  padding: 1rem;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0.7;
}

.lightbox-close:hover, .lightbox-prev:hover, .lightbox-next:hover {
  opacity: 1;
  color: var(--primary);
}

.lightbox-close {
  top: 1.5rem;
  right: 1.5rem;
  font-size: 3rem;
}

.lightbox-prev {
  left: 2rem;
  top: 50%;
  transform: translateY(-50%);
}

.lightbox-next {
  right: 2rem;
  top: 50%;
  transform: translateY(-50%);
}

@media (max-width: 767px) {
  .lightbox-prev, .lightbox-next {
    top: auto;
    bottom: 2rem;
    transform: none;
    font-size: 2rem;
    background: rgba(255,255,255,0.1);
    border-radius: 50%;
    width: 60px;
    height: 60px;
  }
  .lightbox-prev { left: 20%; }
  .lightbox-next { right: 20%; }
}

/* ================================
   OFICINA VIRTUAL TEMPLATE SPECIFICS
   ================================ */

.soh-gallery-grid--virtual {
    grid-template-columns: 1fr 1fr !important;
    grid-template-rows: 1fr !important;
    height: 450px !important;
}

.gallery-item-v {
    position: relative;
    overflow: hidden;
}

.gallery-item-v img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s cubic-bezier(0.165, 0.84, 0.44, 1);
}

.gallery-item-v:hover img {
    transform: scale(1.05);
}

@media (max-width: 768px) {
    .soh-gallery-grid--virtual {
        grid-template-columns: 1fr !important;
        grid-template-rows: repeat(2, 250px) !important;
        height: auto !important;
    }
}

.office-map-section--virtual {
    padding: 0 !important;
    background: #fff;
}

.om-container--virtual {
    max-width: 100% !important;
    padding: 0 !important;
    display: block !important;
}

.om-map-wrapper--virtual {
    width: 100% !important;
}

.om-map-wrapper--virtual iframe {
    border-radius: 0 !important;
    box-shadow: none !important;
    display: block;
}

