/* =========================
   Variables base
   ========================= */
:root {
    --color-bg: #f3f4f6;
    --color-bg-card: #ffffff;
    --color-primary: #2563eb;
    --color-primary-dark: #1d4ed8;
    --color-header: #111827;
    --color-text: #111827;
    --color-text-muted: #6b7280;
    --radius-card: 0.75rem;
    --shadow-card: 0 2px 4px rgba(0, 0, 0, 0.06);
}


.site-header, .header-inner, .main-nav { overflow: visible !important; }

/* Reset sencillo */
* {
    box-sizing: border-box;
}

/* =========================
   Tipografía global
   ========================= */

/* Fuente general del sitio (elegante pero moderna) */
body {
    margin: 0;
    font-family: "Inter", sans-serif;
    background-color: var(--color-bg);
    color: var(--color-text);
    font-size: 16px;
    line-height: 1.5;
}

/* Títulos elegantes con Playfair Display */
h1,
h2,
h3,
.hero-title,

.section-title {
    font-family: "Playfair Display", serif;
    font-weight: 700;
    letter-spacing: 0.5px;
}

.section-pill-title {
    font-family: "Inter", sans-serif;
    font-size: 30px;
    margin: 0 0 0.5rem 0;
    font-weight: 700;
}

.section-pill-wrapper {
    display: flex;
    justify-content: center;
    margin-top: 3rem;
}


/* =========================
   Layout general
   ========================= */

.container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 1.5rem;
}

/* =========================
   Header y navegación
   ========================= */

.site-header {
    top: 0;
    left: 0;
    right: 0;
    color: white;
    z-index: 50;
    transition: background-color 0.3s ease, padding 0.3s ease, box-shadow 0.3s ease;
}

/* Estado inicial: sobre el hero, transparente y absoluto */
.site-header.overlay-header {
    position: absolute;
    background-color: transparent;
    box-shadow: none;
    padding-top: 1rem;
    padding-bottom: 1rem;
}

/* Estado al hacer scroll: fijo con fondo sólido */
.site-header.header-solid {
    position: fixed;
    background-color: var(--color-header);
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.4);
    padding-top: 0.5rem;
    padding-bottom: 0.5rem;
}

/* Para que el contenido bajo el header fijo no quede tapado */
main.container {
    padding-top: 5rem;
}

.header-inner {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1.5rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1.5rem;
}

.logo {
    font-weight: bold;
    font-size: 1.25rem;
}

.logo a {
    color: #ffffff;
    text-decoration: none;
}

.logo a:hover,
.logo a:focus {
    text-decoration: none;
}



.main-nav ul {
    list-style: none;
    display: flex;
    gap: 1rem;
    margin: 0;
    padding: 0;
}

.main-nav a {
    color: #ffffff;
    text-decoration: none;
    font-size: 0.95rem;
}

.main-nav a:hover {
    text-decoration: underline;
}


/* ======================
   HERO
   ====================== */

.hero {
    position: relative;
    width: 100%;
    height: 100vh;
    padding: 0 !important;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    color: #fff;
}

/* Hero más pequeño SOLO para contacto */
.hero.hero-contacto{
  height: 60vh;
  min-height: 60vh;
}

/* Ajuste extra para mobile */
@media (max-width: 900px){
  .hero.hero-contacto{
    height: 50vh;
    min-height: 50vh;
  }
}


.hero .hero-content {
    margin-top: 0;
    transform: translateY(-10%);
}


@media (max-width: 768px) {
    .hero .hero-content {
        transform: translateY(-5%);
    }
}

@media (max-width: 768px) {
  .hero-video {
    display: none;
  }

  .hero {
    background: url("/static/img/hero.cd50b2b2de73.webp") center/cover no-repeat;
  }
}



/* Título principal */
.hero-title {
    font-family: "Playfair Display", serif;
    font-size: 4rem; /* más grande */
    font-weight: 600;
    margin: 0 0 1rem;
    line-height: 1.1;
}

/* Subtítulo */
.hero-subtitle {
    font-size: 1.3rem;
    letter-spacing: 0.25rem;
    text-transform: uppercase;
    opacity: 0.9;
    margin-top: 0.5rem;
}


/* Hero full-width y alto */
.hero-full {
    width: 100%;
    height: 85vh;
    min-height: 500px;
    position: relative;
    overflow: hidden;
}

/* Video ocupa todo el hero */
.hero-video {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    z-index: 0;
}

/* Overlay encima del video */
.hero-overlay {
    position: relative;
    z-index: 1;
    background: linear-gradient(to bottom, rgba(0, 0, 0, 0.45), rgba(0, 0, 0, 0.8));
    width: 100%;
    height: 100%;
    padding: 3rem 2rem;
    display: flex;
    align-items: flex-end;
    justify-content: center;
    padding-bottom: 6rem;
}

/* Texto del hero centrado y blanco */
.hero-text-center {
    text-align: center;
    max-width: 700px;
    min-height: 220px;
}

.hero-title {
    font-size: 3.2rem;
    font-weight: 800;
    color: white;
    text-shadow: 0 4px 12px rgba(0, 0, 0, 0.55);
}

.hero-subtitle {
    font-size: 1.2rem;
    font-weight: 300;
    font-family: "Inter", sans-serif;
    color: #e5e7eb;
}

/* Hero responsive */
@media (max-width: 900px) {
    .hero-overlay {
        padding: 2.5rem 1.5rem;
        padding-bottom: 4rem;
    }

    .hero-text-center {
        min-height: 160px;
    }

    .hero-title {
        font-size: 2.1rem;
    }
}

/* =========================
   Títulos de secciones
   ========================= */

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

/* =========================
   Tarjetas genéricas
   ========================= */

.card {
    background-color: var(--color-bg-card);
    border-radius: var(--radius-card);
    box-shadow: var(--shadow-card);
    overflow: hidden;
    border: 1px solid #e5e7eb;
}

.card-body {
    padding: 1rem;
}

.card-title {
    margin: 0 0 0.5rem 0;
    font-size: 1.05rem;
}

.card-subtitle {
    margin: 0;
    color: var(--color-text-muted);
    font-size: 0.9rem;
}

.card-meta {
    margin: 0.25rem 0;
    font-size: 0.9rem;
}

.card-price {
    margin: 0.25rem 0;
    font-weight: bold;
}

.card-actions {
    margin-top: 0.5rem;
}

/* Imágenes de tarjetas */
.card-image {
    width: 100%;
    height: 200px;
    object-fit: cover;
    display: block;
}

/* =========================
   Botones
   ========================= */

/* Base del botón */
.btn {
    display: inline-block;
    text-decoration: none;
    border-radius: 999px;
    padding: 0.55rem 1.6rem;
    font-size: 1rem;
    border: none;
    cursor: pointer;
    font-family: "Inter", sans-serif;
    font-weight: 500;
    transition: all 0.25s ease;
}

/* Botón primario elegante */
.btn-primary {
    background-color: #0F172A;
    color: #FFFFFF;
    box-shadow: 0 4px 20px rgba(15, 23, 42, 0.3);
}

/* Hover premium */
.btn-primary:hover {
    background-color: #1E293B;
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(30, 41, 59, 0.4);
}

/* Al presionar */
.btn-primary:active {
    transform: scale(0.97);
}

/* Botón de búsqueda: versión más grande */
.btn-search {
    padding-left: 2.2rem;
    padding-right: 2.2rem;
    font-size: 1.05rem;
}

/* =========================
   Grids
   ========================= */

/* Grid genérico */
.grid {
    display: grid;
    gap: 1.5rem;
}

/* 3 columnas fijas en escritorio, responsive abajo */
.grid-3 {
    grid-template-columns: repeat(3, minmax(0, 1fr));
}

/* En pantallas medianas: 2 columnas */
@media (max-width: 900px) {
    .grid-3 {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

/* En móviles: 1 columna */
@media (max-width: 600px) {
    .grid-3 {
        grid-template-columns: 1fr;
    }
}


.grid-item {
    width: 100%;
}

/* =========================
   Sección de búsqueda (Home)
   ========================= */

/* SECCIÓN BUSCADOR */

.search-section {
    background: #e5e7eb;
    margin-top: -3.5rem;
    padding: 4rem 0 3rem;
}

.search-card {
    position: relative;
    max-width: 1150px;
    margin: 0 auto;
    padding: 2.5rem 3rem 2.25rem;
    background: #e5e7eb;
    border-radius: 0 0 0.75rem 0.75rem;
    box-shadow: 0 10px 20px rgba(15, 23, 42, 0.08);
}

/* “Pestaña” naranja BÚSQUEDA DE PROPIEDADES */
.search-card__title {
    position: absolute;
    top: 0;
    left: 50%;
    transform: translate(-50%, -100%);
    padding: 0.9rem 3rem 0.85rem;
    background: var(--color-primary, #2563eb);
    color: #ffffff;
    font-weight: 700;
    font-size: 0.9rem;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    border-radius: 0.75rem 0.75rem 0 0;
    text-align: center;
    white-space: nowrap;
}


/* Layout de los campos */
.search-form {
    display: block;
}

.search-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    column-gap: 1.5rem;
    row-gap: 1.25rem;
}

/* Cada campo */
.search-field label {
    display: block;
    margin-bottom: 0.35rem;
    font-size: 0.7rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.12em;
    color: var(--color-text-muted, #6b7280);
}

.search-field select,
.search-field input {
    width: 100%;
    height: 2.8rem;
    border-radius: 0.4rem;
    border: 1px solid #d1d5db;
    padding: 0 0.75rem;
    font-size: 0.9rem;
    outline: none;
    background: #ffffff;
}

.search-field select:focus,
.search-field input:focus {
    border-color: #2563eb;
    box-shadow: 0 0 0 1px rgba(37, 99, 235, 0.25);
}

/* Botón Buscar */
.search-actions {
    display: flex;
    justify-content: flex-end;
    align-items: flex-end;
}

@media (max-width: 1024px) {
    .search-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

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


.btn-search {
    border: none;
    padding: 0.9rem 2.5rem;
    border-radius: 0.4rem;
    background: #1f2933;
    color: #ffffff;
    font-weight: 600;
    font-size: 0.95rem;
    cursor: pointer;
    transition: background 0.2s ease, transform 0.1s ease;
}

.btn-search:hover {
    background: #111827;
    transform: translateY(-1px);
}

/* RESPONSIVE */
@media (max-width: 1024px) {
    .search-grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
}

@media (max-width: 768px) {
    .search-card {
        padding: 2rem 1.5rem 2rem;
    }

    .search-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .search-actions {
        width: 100%;
        justify-content: flex-end;
        margin-top: 1rem;
    }
}

@media (max-width: 520px) {
    .search-grid {
        grid-template-columns: 1fr;
    }

    .search-card__title {
        padding-inline: 1.5rem;
        font-size: 0.8rem;
    }
}


/* Form centrado */
.search-form {
    max-width: 900px;
    margin: 0 auto;
}

/* Grid de campos centrado */
.search-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem 1.5rem;
    justify-content: center;
}

.search-field {
    min-width: 200px;
    flex: 1 1 200px;
}

/* Etiquetas y controles */
.search-field label {
    font-size: 0.85rem;
    display: block;
    margin-bottom: 0.25rem;
}

.search-field input,
.search-field select {
    width: 100%;
    padding: 0.4rem 0.5rem;
    border-radius: 0.5rem;
    border: 1px solid #d1d5db;
    font-size: 0.95rem;
}

/* Contenedor del botón */
.search-actions {
    margin-top: 1.2rem;
    text-align: center;
}

/* ===========================
   Sección de Ubicaciones
   =========================== */

.locations-section {
    max-width: 1200px;
    margin: 4rem auto;
    padding: 0 1.5rem;
}

.locations-section .section-title {
    text-align: center;
    font-size: 1.9rem;
    margin-bottom: 2rem;
}

/* Grid de 3 columnas responisva */
.grid.grid-3 {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 1.5rem;
}

/* Tarjeta de ubicación */
.location-link {
    text-decoration: none;
    color: inherit;
}

.location-card {
    position: relative;
    min-height: 210px;
    border-radius: 0.75rem;
    overflow: hidden;
    background-color: #e5e7eb;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.08);
    display: flex;
}

.location-card-with-image {
    background-size: cover;
    background-position: center;
}

/* Capa oscura para que el texto se lea bien sobre la imagen */
.location-card-overlay {
    background: linear-gradient(
        to bottom,
        rgba(0, 0, 0, 0.25),
        rgba(0, 0, 0, 0.55)
    );
    width: 100%;
    padding: 1.5rem;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    color: #ffffff;
}

/* Texto más grande y centrado */
.location-card-overlay h3 {
    font-size: 1.4rem;
    margin: 0 0 0.35rem;
}

.location-card-overlay p {
    margin: 0.1rem 0;
    font-size: 0.98rem;
    opacity: 0.9;
}

/* Hover suave */
.location-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 16px rgba(15, 23, 42, 0.18);
    transition: transform 0.18s ease, box-shadow 0.18s ease;
}

.location-card:hover .location-card-overlay {
    background: rgba(0, 0, 0, 0.35);
}



/* =========================
   Carrusel (propiedades destacadas)
   ========================= */

.carousel {
    position: relative;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 2rem;
}

.carousel-track {
    overflow-x: auto;
    overflow-y: hidden;
    flex: 1;
    display: flex;
    gap: 1.5rem;
    scroll-behavior: smooth;
}

.carousel-track::-webkit-scrollbar {
    height: 6px;
}

.carousel-track::-webkit-scrollbar-thumb {
    background-color: #d1d5db;
    border-radius: 999px;
}

.carousel-item {
    min-width: 280px;
    max-width: 320px;
    flex: 0 0 auto;
}

.carousel-btn {
    background-color: var(--color-bg-card);
    border-radius: 999px;
    border: 1px solid #d1d5db;
    width: 2rem;
    height: 2rem;
    cursor: pointer;
    font-size: 1.5rem;
    line-height: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--color-text-muted);
}

.carousel-btn:hover {
    background-color: #e5e7eb;
}

/* =========================
   Resultados de búsqueda
   ========================= */

.results-section {
    margin-top: 2rem;
}

.no-results {
    text-align: center;
    color: var(--color-text-muted);
    margin-top: 1rem;
    font-size: 0.95rem;
}

/* Contenedor cuando hay solo un resultado */
.results-single {
    display: flex;
    justify-content: center;
    margin-top: 2rem;
}

/* La tarjeta única no debe ocupar todo el ancho */
.results-single .card {
    max-width: 380px;
    width: 100%;
}


/* =========================
   Detalle de propiedad
   ========================= */

.breadcrumb {
    color: var(--color-text-muted);
    font-size: 0.9rem;
    margin-bottom: 0.5rem;
}

.breadcrumb a {
    color: var(--color-primary);
    text-decoration: none;
}

.breadcrumb a:hover {
    text-decoration: underline;
}

.detail-header {
    margin-bottom: 1.5rem;
}

.detail-title {
    margin: 0 0 0.5rem 0;
}

.detail-location {
    margin: 0;
    color: var(--color-text-muted);
}

.detail-layout {
    display: grid;
    grid-template-columns: minmax(0, 2fr) minmax(0, 1fr);
    gap: 2rem;
    margin-bottom: 2rem;
}

.detail-main-image {
    border-radius: var(--radius-card);
    overflow: hidden;
    max-height: 450px;
}

.detail-main-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.detail-summary {
    display: flex;
    flex-wrap: wrap;
    gap: 1.5rem;
    margin: 1.5rem 0;
}

.detail-summary-item {
    font-size: 0.9rem;
}

.detail-summary-label {
    font-size: 0.8rem;
    color: var(--color-text-muted);
}

.detail-summary-value {
    font-weight: bold;
}

.detail-section {
    margin-bottom: 2rem;
}

.detail-section h2 {
    margin-bottom: 0.5rem;
}

.detail-specs-table {
    width: 100%;
    border-collapse: collapse;
}

.detail-specs-table td {
    border-bottom: 1px solid #e5e7eb;
    padding: 0.5rem;
}

.chip-list {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    list-style: none;
    padding: 0;
    margin: 0;
}

.chip {
    background-color: #f3f4f6;
    padding: 0.4rem 0.8rem;
    border-radius: 9999px;
    font-size: 0.85rem;
}

.gallery-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
}

.gallery-item {
    width: 180px;
    height: 120px;
    overflow: hidden;
    border-radius: 0.5rem;
    border: 1px solid #e5e7eb;
}

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

/* Aside detalle */

.detail-aside-card {
    background-color: var(--color-bg-card);
    border-radius: var(--radius-card);
    padding: 1rem;
    border: 1px solid #e5e7eb;
    margin-bottom: 1.5rem;
}

.detail-aside-card h2 {
    margin-top: 0;
}

.detail-form input,
.detail-form textarea {
    width: 100%;
    padding: 0.4rem;
    border-radius: 0.375rem;
    border: 1px solid #d1d5db;
}

/* Sección otras propiedades */

.related-section {
    margin-top: 2rem;
}

/* =========================
   Responsive general
   ========================= */


@media (max-width: 600px) {
    .container {
        padding: 1rem;
    }

    .grid-item {
        max-width: 100%;
    }
}

/* Placeholder gris en selects */
.select-placeholder option[value=""] {
    color: #9ca3af;
}

/* Cuando el usuario NO ha seleccionado nada */
.select-placeholder {
    color: #9ca3af;
}

/* Cuando sí selecciona una opción válida */
.select-placeholder:not(:invalid) {
    color: #111827;
}

/* Quitar el borde azul feo en focus */
select:focus {
    outline: none;
    box-shadow: 0 0 0 2px rgba(37, 99, 235, 0.3);
}

/* === Tarjetas de resultados de búsqueda === */

/* Link que envuelve la tarjeta: toda la card es clickeable */
.property-card-link {
    display: block;
    text-decoration: none;
    color: inherit;
}

/* Tarjeta tipo portal */
.property-card {
    background: #ffffff;
    border-radius: 0.9rem;
    overflow: hidden;
    box-shadow: 0 12px 24px rgba(15, 23, 42, 0.12);
    display: flex;
    flex-direction: column;
    transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.property-card-link:hover .property-card {
    transform: translateY(-4px);
    box-shadow: 0 18px 36px rgba(15, 23, 42, 0.18);
}

/* Single */
.results-single {
    display: flex;
    justify-content: center;
    margin-top: 2rem;
}
.results-single .property-card {
    max-width: 380px;
    width: 100%;
}

/* Imagen */
.property-image-wrapper {
    position: relative;
    height: 220px;
    overflow: hidden;
}
.property-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

/* Badge operación */
.property-badge {
    position: absolute;
    top: 0.85rem;
    left: 0.85rem;
    padding: 0.25rem 0.75rem;
    border-radius: 999px;
    font-size: 0.7rem;
    font-weight: 700;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: #ffffff;
}
.property-badge--venta {
    background: #22c55e;
}
.property-badge--arriendo {
    background: #ef4444;
}

/* Barra inferior con precio solamente */
.property-image-bottom {
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0.9rem;
    display: flex;
    justify-content: flex-end;
    padding: 0 0.9rem;
}

.property-price-tag {
    padding: 0.3rem 0.9rem;
    border-radius: 999px;
    background: rgba(15, 23, 42, 0.92);
    color: #ffffff;
    font-weight: 700;
    font-size: 0.95rem;
}

/* Contenido */
.property-content {
    background: #f9fafb;
    padding: 1.1rem 1.35rem 1.35rem;
    font-family: "Inter", system-ui, -apple-system, BlinkMacSystemFont, sans-serif;
}

.property-title {
    font-size: 1.05rem;
    font-weight: 700;
    margin: 0 0 0.3rem 0;
}

.property-location {
    margin: 0 0 0.9rem 0;
    font-size: 0.9rem;
    color: #6b7280;
}

/* Filas de meta */
.property-meta-row {
    display: flex;
    flex-wrap: wrap;
    gap: 1.7rem;
    font-size: 0.9rem;
    margin-bottom: 0.4rem;
}

.property-meta-row span {
    color: #4b5563;
}

.property-meta-row span strong {
    font-weight: 600;
}

.property-meta-row--secondary span {
    color: #6b7280;
}

/* === CONFIGURACIÓN DE GRILLA PARA RESULTADOS === */

.results-grid {
    display: grid;
    gap: 2rem;
}

/* 1 resultado → centrar y tamaño más controlado */
.results-count-1 {
    grid-template-columns: 1fr;
    max-width: 480px;
    margin: 0 auto;
}

/* 2 resultados → 2 columnas uniformes */
.results-count-2 {
    grid-template-columns: repeat(2, minmax(350px, 1fr));
    justify-content: center;
}

/* 3 o más → 3 columnas estilo catálogo */
.results-count-3,
.results-count-4,
.results-count-5,
.results-count-6,
.results-count-7,
.results-count-8,
.results-count-9 {
    grid-template-columns: repeat(3, minmax(350px, 1fr));
}

/* --- Título de la tarjeta --- */
.property-title {
    font-family: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    font-size: 22px;
    font-weight: 600;
    color: #1e293b;
    line-height: 1.25;
    margin-bottom: 6px;
    letter-spacing: -0.2px;
}

/* tamaño especial en carrusel */
.carousel-item {
    min-width: 360px !important;
    max-width: 420px !important;

}

/* ====== TARJETAS RESPONSIVE ====== */

.property-card-link {
    text-decoration: none;
    color: inherit;
    display: block;
}

.property-card {
    background: #fff;
    border-radius: 14px;
    overflow: hidden;
    box-shadow: 0 4px 12px rgba(0,0,0,0.08);
    transition: transform .25s ease, box-shadow .25s ease;
}

.property-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 18px rgba(0,0,0,0.12);
}

/* Responsive grid */
.results-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 32px;
}

/* 2 tarjetas cuando son solo 2 resultados */
.results-grid.results-count-2 {
    grid-template-columns: repeat(2, 1fr);
}

/* ====== RESPONSIVE BREAKPOINTS ====== */

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

/* Móvil */
@media (max-width: 640px) {
    .results-grid {
        grid-template-columns: repeat(1, 1fr);
    }

    .property-card {
        margin: 0 auto;
        width: 92%;
    }
}

/* ===== CAROUSEL RESPONSIVE ===== */

.carousel-track {
    display: flex;
    gap: 24px;
    scroll-snap-type: x mandatory;
    overflow-x: auto;
    padding-bottom: 20px;
}

.carousel-item {
    flex: 0 0 340px;
    scroll-snap-align: start;
}

@media (max-width: 768px) {
    .carousel-item {
        flex: 0 0 90%;
    }
}

.messages-wrapper {
    max-width: 1200px;
    margin: 1rem auto;
    padding: 0 1.5rem;
}

.message {
    padding: 0.75rem 1rem;
    border-radius: 0.5rem;
    font-size: 0.95rem;
    margin-bottom: 0.5rem;
}

.message-success {
    background: #ecfdf3;
    color: #166534;
    border: 1px solid #bbf7d0;
}

/* Toast notifications (Django messages) */
.toast-stack{
  position: fixed;
  left: 50%;
  bottom: 24px;
  transform: translateX(-50%);
  z-index: 9999;
  display: grid;
  gap: 10px;
  width: min(520px, calc(100vw - 24px));
  pointer-events: none;
}

.toast{
  pointer-events: auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;

  padding: 12px 14px;
  border-radius: 12px;

  background: rgba(17, 24, 39, 0.92);
  color: #fff;

  box-shadow: 0 10px 30px rgba(0,0,0,0.25);
  backdrop-filter: blur(8px);

  opacity: 0;
  transform: translateY(10px);
  transition: opacity .25s ease, transform .25s ease;
}

.toast.is-visible{
  opacity: 1;
  transform: translateY(0);
}

.toast.is-hiding{
  opacity: 0;
  transform: translateY(10px);
}

.toast-text{
  font-size: .95rem;
  line-height: 1.2;
}

.toast-close{
  background: transparent;
  border: 0;
  color: rgba(255,255,255,.9);
  font-size: 20px;
  line-height: 1;
  cursor: pointer;
  padding: 0 4px;
}

.toast-success{
  background: rgba(16, 185, 129, 0.92);
}

.toast-error{
  background: rgba(239, 68, 68, 0.92);
}

.toast-warning{
  background: rgba(245, 158, 11, 0.92);
}

.toast-info{
  background: rgba(59, 130, 246, 0.92);
}

/* ===== FIX DEFINITIVO DROPDOWN ===== */

/* tu nav horizontal */
.main-nav ul{
  display:flex;
  align-items:center;
  gap:22px;
}

/* importante: el LI debe ser el contenedor relativo */
.main-nav ul li.nav-dropdown{
  position: relative !important;
}

/* el trigger debe verse como cualquier link */
.nav-dropdown-trigger{
  color: rgba(255,255,255,.9) !important;
  text-decoration: none !important;
  font-weight: 700 !important;
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

/* menú flotante (no debe ocupar espacio) */
.nav-dropdown-menu{
  position: absolute !important;
  top: calc(100% + 12px) !important;
  left: 0 !important;
  min-width: 280px;

  background: #2c3d4a;
  border-radius: 12px;
  padding: 10px;
  box-shadow: 0 16px 40px rgba(0,0,0,0.28);
  z-index: 9999;

  /* cerrado por defecto */
  opacity: 0;
  visibility: hidden;
  transform: translateY(8px);
  pointer-events: none;
  transition: opacity .18s ease, transform .18s ease, visibility .18s ease;
}

/* items */
.nav-dropdown-menu a{
  display:block;
  padding: 12px 12px;
  border-radius: 10px;
  color: rgba(255,255,255,0.92) !important;
  font-weight: 800;
  letter-spacing: .4px;
  text-transform: uppercase;
  font-size: .78rem;
  text-decoration:none;
}

.nav-dropdown-menu a:hover{
  background: rgba(255,255,255,0.10);
}

/* hover abre */
.main-nav ul li.nav-dropdown:hover .nav-dropdown-menu{
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
  pointer-events: auto;
}

/* evita que el link # haga salto */
.nav-dropdown-trigger{ cursor: pointer; }

/* Mantener header en UNA sola fila (evita que el nav se vaya abajo) */
@media (max-width: 900px) {
  .header-inner{
    flex-direction: row !important;
    align-items: center !important;
  }

  .main-nav ul{
    flex-wrap: nowrap !important;
    white-space: nowrap;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
  }

  .main-nav ul::-webkit-scrollbar{
    height: 6px;
  }
}

/* Evita que se cierre al mover el mouse hacia el menú */
.nav-dropdown{
  position: relative;
}

/* puente invisible para cubrir el espacio entre el link y el menú */
.nav-dropdown::after{
  content: "";
  position: absolute;
  left: 0;
  top: 100%;
  width: 100%;
  height: 18px; /* ajusta 12-22px según tu gap */
}

/* Que el menú se mantenga abierto si el mouse está dentro del menú */
.nav-dropdown:hover .nav-dropdown-menu,
.nav-dropdown:focus-within .nav-dropdown-menu{
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
  pointer-events: auto;
}

.whatsapp-float {
    position: fixed;
    bottom: 20px;
    right: 20px;
    width: 58px;
    height: 58px;
    background-color: #25D366;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 6px 15px rgba(0, 0, 0, 0.25);
    z-index: 9999;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.whatsapp-float:hover {
    transform: scale(1.1);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.35);
}

.whatsapp-icon {
    width: 32px;
    height: 32px;
}

/* ===== Contacto ===== */
.contacto-page{
  padding: 2.5rem 0;
  display: flex;
  justify-content: center;
}

.contacto-card{
  width: min(920px, 100%);
  background: rgba(255,255,255,0.85);
  border: 1px solid rgba(0,0,0,0.08);
  border-radius: 18px;
  padding: 2rem;
  box-shadow: 0 16px 45px rgba(0,0,0,0.10);
  backdrop-filter: blur(8px);
}

.contacto-title{
  margin: 0 0 0.5rem 0;
  font-family: "Inter", system-ui, -apple-system, Segoe UI, Roboto, Arial, sans-serif;
  font-weight: 600;
  letter-spacing: -0.01em;
}

.contacto-subtitle{
  margin: 0 0 1.5rem 0;
  color: rgba(0,0,0,0.6);
}

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

.form-field{
  display: flex;
  flex-direction: column;
  gap: 0.45rem;
}

.form-field-full{
  grid-column: 1 / -1;
}

.form-field label{
  font-weight: 600;
  font-size: 0.95rem;
  color: rgba(0,0,0,0.75);
}

.form-field input,
.form-field textarea{
  width: 100%;
  border: 1px solid rgba(0,0,0,0.14);
  border-radius: 12px;
  padding: 0.85rem 0.9rem;
  font-size: 1rem;
  outline: none;
  background: white;
  transition: box-shadow .2s ease, border-color .2s ease, transform .05s ease;
}

.form-field textarea{
  resize: vertical;
  min-height: 150px;
}

.form-field input:focus,
.form-field textarea:focus{
  border-color: rgba(37,99,235,0.55);
  box-shadow: 0 0 0 4px rgba(37,99,235,0.16);
}

.field-error{
  margin: 0;
  color: #b91c1c;
  font-size: 0.9rem;
}

.form-actions{
  display: flex;
  gap: 0.75rem;
  margin-top: 1.2rem;
  align-items: center;
  flex-wrap: wrap;
}

.btn-primary{
  border: none;
  border-radius: 12px;
  padding: 0.85rem 1.2rem;
  font-weight: 700;
  cursor: pointer;
  background: #111827;
  color: white;
  transition: transform .15s ease, opacity .15s ease;
}

.btn-primary:hover{ opacity: 0.92; transform: translateY(-1px); }
.btn-primary:active{ transform: translateY(0px); }

.btn-secondary{
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 12px;
  padding: 0.85rem 1.2rem;
  font-weight: 700;
  text-decoration: none;
  border: 1px solid rgba(0,0,0,0.14);
  color: rgba(0,0,0,0.85);
  background: rgba(255,255,255,0.9);
}

.btn-secondary:hover{
  box-shadow: 0 10px 25px rgba(0,0,0,0.10);
}

/* Responsive */
@media (max-width: 900px){
  .form-grid{ grid-template-columns: 1fr; }
}
/* ===== Mobile Offcanvas Nav ===== */
.nav-toggle{
  display: none;
  border: 0;
  background: transparent;
  color: #fff;
  font-size: 1.6rem;
  cursor: pointer;
}

.nav-overlay{
  display: none;
}

@media (max-width: 900px){
  /* muestra botón */
  .nav-toggle{
    display: inline-flex;
    align-items: center;
    justify-content: center;
  }

  /* evita que el nav quede horizontal */
  .main-nav{
    position: fixed;
    top: 0;
    right: 0;
    height: 100vh;
    width: min(320px, 88vw);
    background: rgba(17, 24, 39, 0.98);
    transform: translateX(100%);
    transition: transform .25s ease;
    z-index: 10001;
    padding: 90px 18px 18px; /* deja espacio por el header */
  }

  .main-nav ul{
    display: flex;
    flex-direction: column;
    gap: 12px;
  }

  .main-nav a{
    display: block;
    padding: 10px 12px;
    border-radius: 10px;
  }

  /* dropdown dentro del offcanvas: que no “flote” */
  .nav-dropdown-menu{
    position: static !important;
    width: 100%;
    margin-top: 6px;
  }

  /* overlay */
  .nav-overlay{
    display: block;
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.45);
    opacity: 0;
    pointer-events: none;
    transition: opacity .25s ease;
    z-index: 10000;
  }

  /* estado abierto */
  body.nav-open .main-nav{
    transform: translateX(0);
  }
  body.nav-open .nav-overlay{
    opacity: 1;
    pointer-events: auto;
  }

  /* opcional: ocultar CTA si se ve muy grande (o déjalo) */
  /* .nav-cta { margin-top: 8px; } */
}

/* Por defecto (desktop): oculto */
.nav-close{
  display: none;
}

@media (max-width: 900px){

  .nav-close{
    display: inline-flex;
    position: absolute;
    top: 18px;
    right: 16px;
    border: 0;
    background: transparent;
    color: #fff;
    font-size: 2rem;
    cursor: pointer;
    line-height: 1;
  }

  /* Acordeón animado */
  .nav-dropdown-menu{
    display: block;            /* ojo: ahora NO lo ocultamos con display */
    max-height: 0;             /* cerrado */
    overflow: hidden;
    opacity: 0;
    transform: translateY(-4px);
    transition: max-height .28s ease, opacity .2s ease, transform .2s ease;
    padding-top: 0;
  }

  body.nav-open .nav-dropdown.is-open .nav-dropdown-menu{
    max-height: 320px;         /* suficiente para tus 5 links */
    opacity: 1;
    transform: translateY(0);
    padding-top: 8px;
  }

  body.nav-open .nav-dropdown.is-open .nav-caret{
    transform: rotate(180deg);
  }
  body.nav-open{
  overflow: hidden;
}

}

/* ======================
   ACERCA DE NOSOTROS
   ====================== */

.acerca-section {
  padding: clamp(3.5rem, 6vw, 5.5rem) 1.25rem 2rem;
  background:
    radial-gradient(900px 450px at 10% 20%, rgba(37, 99, 235, 0.10), transparent 60%),
    radial-gradient(900px 450px at 90% 80%, rgba(16, 185, 129, 0.10), transparent 60%),
    #f8fafc;
  font-family: "Inter", system-ui, -apple-system, Segoe UI, Roboto, Arial, sans-serif;
}

.acerca-container {
  max-width: 1180px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: clamp(1.5rem, 3vw, 3rem);
  align-items: center;
}

/* Card del texto */
.acerca-texto {
  position: relative;
  background: rgba(255, 255, 255, 0.85);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(15, 23, 42, 0.08);
  border-radius: 22px;
  padding: clamp(1.5rem, 3vw, 2.25rem);
  box-shadow:
    0 20px 60px rgba(15, 23, 42, 0.08),
    0 2px 10px rgba(15, 23, 42, 0.05);
  overflow: hidden;
}

.acerca-texto::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(600px 200px at 0% 0%, rgba(37, 99, 235, 0.12), transparent 55%),
    radial-gradient(600px 200px at 100% 100%, rgba(16, 185, 129, 0.12), transparent 55%);
  pointer-events: none;
}

/* Badge superior */
.acerca-texto .acerca-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.45rem 0.75rem;
  border-radius: 999px;
  font-size: 0.85rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  color: #0f172a;
  background: rgba(37, 99, 235, 0.10);
  border: 1px solid rgba(37, 99, 235, 0.18);
  margin-bottom: 1rem;
  font-family: "Inter", system-ui, -apple-system, Segoe UI, Roboto, Arial, sans-serif;
}

/* Títulos */
.acerca-texto h2,
.acerca-texto h3 {
  font-family: "Inter", system-ui, -apple-system, Segoe UI, Roboto, Arial, sans-serif;
  color: #0f172a;
  margin: 0;
  position: relative;
  z-index: 1;
}

.acerca-texto h2 {
  font-size: clamp(1.6rem, 2.6vw, 2.2rem);
  font-weight: 800;
  letter-spacing: -0.02em;
  line-height: 1.15;
  margin-bottom: 0.75rem;
}

.acerca-texto h3 {
  font-size: 1.05rem;
  font-weight: 800;
  margin-top: 1.35rem;
  margin-bottom: 0.55rem;
  letter-spacing: -0.01em;
}

/* Línea decorativa bajo H3 */
.acerca-texto h3::after {
  content: "";
  display: block;
  width: 48px;
  height: 3px;
  border-radius: 999px;
  margin-top: 0.55rem;
  background: linear-gradient(90deg, rgba(37,99,235,0.9), rgba(16,185,129,0.9));
  opacity: 0.9;
}

/* Texto */
.acerca-texto p {
  font-family: "Inter", system-ui, -apple-system, Segoe UI, Roboto, Arial, sans-serif;
  color: #334155;
  line-height: 1.75;
  font-size: 1rem;
  margin: 0 0 0.95rem 0;
  position: relative;
  z-index: 1;
}

.acerca-texto p:last-child {
  margin-bottom: 0;
}

/* Lista de puntos (por si quieres usarla luego) */
.acerca-texto ul {
  margin: 0.75rem 0 0;
  padding-left: 1.1rem;
  color: #334155;
  line-height: 1.7;
  position: relative;
  z-index: 1;
  font-family: "Inter", system-ui, -apple-system, Segoe UI, Roboto, Arial, sans-serif;
}

.acerca-texto li {
  margin: 0.4rem 0;
}

/* Columna imagen */
.acerca-imagen {
  position: relative;
  border-radius: 22px;
  overflow: hidden;
  border: 1px solid rgba(15, 23, 42, 0.10);
  box-shadow:
    0 22px 60px rgba(15, 23, 42, 0.10),
    0 2px 10px rgba(15, 23, 42, 0.06);
  background: #fff;
}

.acerca-imagen::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(
    180deg,
    rgba(2, 6, 23, 0.05) 0%,
    rgba(2, 6, 23, 0.15) 70%,
    rgba(2, 6, 23, 0.20) 100%
  );
  pointer-events: none;
  z-index: 1;
}

.acerca-imagen img {
  width: 100%;
  height: clamp(320px, 38vw, 520px);
  object-fit: cover;
  display: block;
  transform: scale(1.02);
  transition: transform 0.6s ease;
}

.acerca-imagen:hover img {
  transform: scale(1.06);
}

/* Etiqueta sobre la imagen */
.acerca-imagen .acerca-etiqueta {
  position: absolute;
  left: 16px;
  bottom: 16px;
  z-index: 2;
  padding: 0.55rem 0.8rem;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.90);
  border: 1px solid rgba(15, 23, 42, 0.10);
  color: #0f172a;
  font-weight: 700;
  font-size: 0.95rem;
  letter-spacing: -0.01em;
  font-family: "Inter", system-ui, -apple-system, Segoe UI, Roboto, Arial, sans-serif;
  box-shadow: 0 8px 18px rgba(15, 23, 42, 0.10);
}

/* Responsive */
@media (max-width: 960px) {
  .acerca-container {
    grid-template-columns: 1fr;
  }

  .acerca-imagen {
    order: -1;
  }

  .acerca-imagen img {
    height: 360px;
  }
}

/* ======================
    FOOTER
   ====================== */

.site-footer {
  background: linear-gradient(
    180deg,
    #020617 0%,
    #020617 70%,
    #010409 100%
  );
  color: #e5e7eb;
  font-family: "Inter", system-ui, -apple-system, Segoe UI, Roboto, Arial, sans-serif;

  /* ↓ MENOS ALTURA */
  padding: 1.6rem 1.25rem;
}

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

  /* MEJOR ALINEACIÓN */
  display: grid;
  grid-template-columns: 1.3fr 0.7fr;
  align-items: center;
  gap: 1.5rem;
}

/* Marca */
.footer-brand h4 {
  font-size: 1.15rem;
  font-weight: 700; /* ↓ más ancho */
  letter-spacing: 0.01em;
  margin-bottom: 0.4rem;
  color: #ffffff;
}

.footer-brand p {
  font-size: 0.95rem;
  font-weight: 500; /* ↓ texto más “firme” */
  line-height: 1.6;
  color: #cbd5f5;
  max-width: 520px;
  margin-bottom: 0.45rem;
}

.footer-link {
  display: inline-block;
  font-weight: 600;
  letter-spacing: 0.02em;
  color: #60a5fa;
  text-decoration: none;
}

.footer-link:hover {
  color: #93c5fd;
}

/* Lado derecho */
.footer-info {
  text-align: right;
}

.footer-info p {
  margin: 0.2rem 0;
  font-size: 0.85rem;
  font-weight: 500; /* ↓ más ancho */
  letter-spacing: 0.015em;
  color: #9ca3af;
}

.footer-dev {
  margin-top: 0.35rem;
  font-size: 0.8rem;
}

.footer-dev span {
  color: #22d3ee;
  font-weight: 700;
  letter-spacing: 0.03em;
}

/* Responsive */
@media (max-width: 900px) {
  .site-footer {
    padding: 1.5rem 1rem;
  }

  .footer-container {
    grid-template-columns: 1fr;
    text-align: center;
    gap: 1rem;
  }

  .footer-info {
    text-align: center;
  }
}
/* ======================
   FOOTER SOCIAL
   ====================== */

.footer-social {
  display: flex;
  gap: 0.6rem;
  margin-top: 0.6rem;
}

/* Base */
.social-btn {
  width: 36px;
  height: 36px;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.12);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: all 0.25s ease;
}

.social-btn svg {
  width: 18px;
  height: 18px;
  transition: transform 0.25s ease;
}

/* Instagram */
.social-btn[aria-label="Instagram"] svg {
  fill: url(#instagram-gradient);
}

/* Facebook */
.social-btn[aria-label="Facebook"] svg {
  fill: #1877f2;
}

/* Hover */
.social-btn:hover {
  transform: translateY(-2px);
  background: rgba(255, 255, 255, 0.12);
}

.social-btn:hover svg {
  transform: scale(1.08);
}

/* Responsive */
@media (max-width: 900px) {
  .footer-social {
    justify-content: center;
  }
}
