/* ==========================================================================
   ESTUDIO EPL - CATÁLOGO INMOBILIARIO & GESTOR DE ARRIENDOS
   Diseño de Alta Gama: Inspirado en la Interfaz D-019 Gestor de Arriendos
   ========================================================================== */

:root {
    --bg-catalog-main: #070B11;
    --bg-catalog-surface: #0E1626;
    --bg-catalog-card: #131E33;
    --bg-catalog-subcard: #0A111F;
    --border-catalog: #1E2E4A;
    --border-catalog-hover: #14B8A6;
    --teal-primary: #14B8A6;
    --teal-light: #2DD4BF;
    --emerald-primary: #10B981;
    --emerald-hover: #059669;
    --amber-primary: #F59E0B;
}

body[data-theme="propiedades"] {
    background-color: var(--bg-catalog-main);
    color: #F1F5F9;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
}

/* ==========================================================================
   1. BANNER & PESTAÑAS MAESTRAS DE SINCRONIZACIÓN
   ========================================================================== */
.catalog-sync-banner {
    background: linear-gradient(135deg, rgba(19, 78, 74, 0.45) 0%, rgba(15, 23, 42, 0.9) 50%, rgba(6, 78, 59, 0.35) 100%);
    border: 1px solid rgba(20, 184, 166, 0.35);
    border-radius: 16px;
    padding: 24px 28px;
    box-shadow: 0 20px 40px -15px rgba(0, 0, 0, 0.6);
    margin-bottom: 28px;
}

.sync-banner-kicker {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-size: 0.72rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.15em;
    color: var(--teal-light);
    margin-bottom: 6px;
}

.sync-banner-title {
    font-family: 'Outfit', sans-serif;
    font-size: 1.6rem;
    font-weight: 700;
    color: #FFFFFF;
    margin: 0;
}

.sync-banner-desc {
    font-size: 0.85rem;
    color: #94A3B8;
    line-height: 1.6;
    margin-top: 6px;
    max-width: 820px;
}

/* Tabs de Operación estilo D-019 */
.catalog-tabs-bar {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    background: rgba(15, 23, 42, 0.7);
    border: 1px solid var(--border-catalog);
    border-radius: 14px;
    padding: 12px 16px;
    margin-bottom: 24px;
}

.tabs-group {
    display: flex;
    align-items: center;
    gap: 8px;
}

.tab-pill-btn {
    padding: 8px 18px;
    border-radius: 10px;
    font-size: 0.8rem;
    font-weight: 700;
    letter-spacing: 0.04em;
    background: #1E293B;
    color: #94A3B8;
    border: 1px solid transparent;
    cursor: pointer;
    transition: all 0.2s ease;
}

.tab-pill-btn:hover {
    background: #334155;
    color: #FFFFFF;
}

.tab-pill-btn.active {
    background: var(--teal-primary);
    color: #042F2E;
    border-color: var(--teal-light);
    box-shadow: 0 4px 14px rgba(20, 184, 166, 0.4);
}

.tab-pill-btn[data-op="arriendo"].active {
    background: #10B981;
    color: #022C22;
    border-color: #34D399;
    box-shadow: 0 4px 14px rgba(16, 185, 129, 0.4);
}

.tab-pill-btn[data-op="venta"].active {
    background: #F59E0B;
    color: #451A03;
    border-color: #FBBF24;
    box-shadow: 0 4px 14px rgba(245, 158, 11, 0.4);
}

.tabs-counter-label {
    font-size: 0.8rem;
    color: #94A3B8;
    font-weight: 500;
}

/* ==========================================================================
   2. BARRA DE FILTROS FLOTANTE
   ========================================================================== */
.filter-card-d019 {
    background: rgba(14, 22, 38, 0.85);
    backdrop-filter: blur(12px);
    border: 1px solid var(--border-catalog);
    border-radius: 16px;
    padding: 20px;
    margin-bottom: 32px;
}

.filter-grid-layout {
    display: grid;
    grid-template-columns: 2fr 1.3fr 1.3fr 1.3fr 90px;
    gap: 14px;
    align-items: flex-end;
}

.input-field-wrap {
    position: relative;
}

.input-field-wrap svg {
    position: absolute;
    left: 14px;
    top: 50%;
    transform: translateY(-50%);
    width: 16px;
    height: 16px;
    color: #64748B;
    pointer-events: none;
}

.field-label {
    font-size: 0.7rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    font-weight: 700;
    color: #64748B;
    margin-bottom: 6px;
    display: block;
}

.field-input {
    width: 100%;
    height: 44px;
    padding: 10px 14px;
    background: #0A111F;
    border: 1px solid var(--border-catalog);
    border-radius: 10px;
    color: #F8FAFC;
    font-size: 0.875rem;
    outline: none;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.input-field-wrap .field-input {
    padding-left: 40px;
}

.field-input:focus {
    border-color: var(--teal-primary);
    box-shadow: 0 0 0 2px rgba(20, 184, 166, 0.2);
}

select.field-input {
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='14' viewBox='0 0 24 24' fill='none' stroke='%2364748B' stroke-width='2'%3E%3Cpolyline points='6 9 12 15 18 9'%3E%3C/polyline%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 14px center;
    padding-right: 36px;
}

.btn-clean-filters {
    height: 44px;
    width: 100%;
    background: #1E293B;
    border: 1px solid var(--border-catalog);
    border-radius: 10px;
    color: #94A3B8;
    font-size: 0.8rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
}

.btn-clean-filters:hover {
    background: #334155;
    color: #FFFFFF;
}

/* Chips rápidos */
.chips-row {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 14px;
    padding-top: 14px;
    border-top: 1px solid rgba(30, 46, 74, 0.6);
}

.quick-chip {
    background: #0F172A;
    border: 1px solid var(--border-catalog);
    color: #94A3B8;
    padding: 5px 12px;
    border-radius: 8px;
    font-size: 0.72rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
}

.quick-chip:hover, .quick-chip.active {
    background: var(--teal-primary);
    color: #042F2E;
    border-color: var(--teal-light);
    font-weight: 700;
}

/* ==========================================================================
   3. TARJETA DE PROPIEDAD ESTILO GESTOR DE ARRIENDOS D-019
   ========================================================================== */
.card-property-d019 {
    background: var(--bg-catalog-card);
    border: 1px solid var(--border-catalog);
    border-radius: 18px;
    overflow: hidden;
    box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.5);
    display: flex;
    flex-direction: column;
    cursor: pointer;
    transition: transform 0.25s cubic-bezier(0.16, 1, 0.3, 1), 
                border-color 0.25s ease, 
                box-shadow 0.25s ease;
}

.card-property-d019:hover {
    transform: translateY(-5px);
    border-color: rgba(20, 184, 166, 0.6);
    box-shadow: 0 20px 35px -10px rgba(4, 47, 46, 0.6);
}

/* Contenedor de Fotografía */
.card-media-viewport {
    position: relative;
    aspect-ratio: 16 / 10;
    background: #05080E;
    overflow: hidden;
}

.card-img-element {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1);
    display: block;
}

.card-property-d019:hover .card-img-element {
    transform: scale(1.06);
}

/* Overlay al pasar el mouse */
.card-hover-overlay {
    position: absolute;
    inset: 0;
    background: rgba(7, 11, 17, 0.35);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.2s ease;
    pointer-events: none;
}

.card-property-d019:hover .card-hover-overlay {
    opacity: 1;
}

.hover-overlay-pill {
    background: rgba(7, 11, 17, 0.9);
    backdrop-filter: blur(8px);
    border: 1px solid rgba(20, 184, 166, 0.5);
    color: var(--teal-light);
    font-size: 0.75rem;
    font-weight: 700;
    padding: 6px 14px;
    border-radius: 999px;
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.7);
    display: flex;
    align-items: center;
    gap: 6px;
}

/* Badges Superiores Flotantes */
.badge-top-left {
    position: absolute;
    top: 12px;
    left: 12px;
    display: flex;
    align-items: center;
    gap: 6px;
    z-index: 2;
}

.badge-operation-pill {
    padding: 4px 10px;
    border-radius: 999px;
    font-size: 0.65rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.4);
}

.badge-arriendo {
    background: #14B8A6;
    color: #042F2E;
}

.badge-venta {
    background: #F59E0B;
    color: #451A03;
}

.badge-code-pill {
    background: rgba(7, 11, 17, 0.85);
    backdrop-filter: blur(6px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: #FFFFFF;
    font-size: 0.65rem;
    font-weight: 700;
    padding: 3px 8px;
    border-radius: 999px;
}

.badge-photo-count {
    position: absolute;
    top: 12px;
    right: 12px;
    background: rgba(7, 11, 17, 0.85);
    backdrop-filter: blur(6px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: #E2E8F0;
    font-size: 0.65rem;
    font-weight: 700;
    padding: 3px 8px;
    border-radius: 999px;
    z-index: 2;
}

/* Badge Inferior de Precio */
.badge-price-floating {
    position: absolute;
    bottom: 12px;
    left: 12px;
    background: rgba(7, 11, 17, 0.92);
    backdrop-filter: blur(8px);
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 12px;
    padding: 6px 12px;
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.6);
    z-index: 2;
}

.price-main-bold {
    font-family: 'Outfit', sans-serif;
    font-size: 1.15rem;
    font-weight: 800;
    color: #FFFFFF;
    line-height: 1.1;
}

.price-sub-caption {
    font-size: 0.65rem;
    color: #94A3B8;
    margin-top: 2px;
}

/* Cuerpo de la Tarjeta */
.card-content-wrap {
    padding: 20px;
    display: flex;
    flex-direction: column;
    flex-grow: 1;
    justify-content: space-between;
}

.card-location-row {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 0.72rem;
    color: var(--teal-light);
    font-weight: 600;
    margin-bottom: 6px;
}

.card-title-bold {
    font-family: 'Outfit', sans-serif;
    font-size: 1.05rem;
    font-weight: 700;
    color: #FFFFFF;
    line-height: 1.35;
    margin-bottom: 8px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    transition: color 0.2s ease;
}

.card-property-d019:hover .card-title-bold {
    color: var(--teal-light);
}

.card-description-clamp {
    font-size: 0.75rem;
    color: #94A3B8;
    line-height: 1.5;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    margin-bottom: 16px;
}

/* Grilla de 4 Métricas (Sub-boxes) */
.specs-4-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 6px;
    padding: 12px 0;
    border-top: 1px solid rgba(30, 46, 74, 0.8);
    border-bottom: 1px solid rgba(30, 46, 74, 0.8);
    margin-bottom: 16px;
    text-align: center;
}

.spec-mini-box {
    background: var(--bg-catalog-subcard);
    border: 1px solid rgba(30, 46, 74, 0.6);
    border-radius: 10px;
    padding: 6px 2px;
}

.spec-mini-value {
    font-size: 0.85rem;
    font-weight: 800;
    color: #FFFFFF;
    display: block;
    line-height: 1.1;
}

.spec-mini-label {
    font-size: 0.62rem;
    color: #64748B;
    text-transform: capitalize;
    margin-top: 2px;
    display: block;
}

/* Fila de Botones de Acción */
.card-actions-row {
    display: flex;
    align-items: center;
    gap: 8px;
}

.btn-card-details {
    flex: 1;
    height: 38px;
    background: #1E293B;
    border: 1px solid #334155;
    border-radius: 10px;
    color: #E2E8F0;
    font-size: 0.75rem;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.btn-card-details:hover {
    background: #334155;
    color: #FFFFFF;
}

.btn-card-whatsapp {
    flex: 1;
    height: 38px;
    background: #059669;
    border: 1px solid #10B981;
    border-radius: 10px;
    color: #FFFFFF;
    font-size: 0.75rem;
    font-weight: 800;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    cursor: pointer;
    text-decoration: none;
    box-shadow: 0 4px 12px rgba(5, 150, 105, 0.35);
    transition: all 0.2s ease;
}

.btn-card-whatsapp:hover {
    background: #10B981;
    box-shadow: 0 6px 18px rgba(16, 185, 129, 0.5);
    color: #FFFFFF;
}

/* ==========================================================================
   4. MODAL DETALLADO ESTILO MODALFICHA PROPIEDAD (IMAGEN 2)
   ========================================================================== */
.modal-d019-backdrop {
    position: fixed;
    inset: 0;
    background: rgba(3, 7, 18, 0.88);
    backdrop-filter: blur(14px);
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 16px;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.25s ease;
}

.modal-d019-backdrop.open {
    opacity: 1;
    pointer-events: all;
}

.modal-d019-container {
    width: 100%;
    max-width: 980px;
    max-height: 94vh;
    background: #0F172A;
    border: 1px solid #334155;
    border-radius: 24px;
    box-shadow: 0 25px 60px -15px rgba(0, 0, 0, 0.95);
    overflow: hidden;
    display: flex;
    flex-direction: column;
    position: relative;
}

/* Botones flotantes superiores */
.modal-top-actions {
    position: absolute;
    top: 16px;
    right: 16px;
    z-index: 30;
    display: flex;
    align-items: center;
    gap: 8px;
}

.modal-top-btn {
    padding: 8px 14px;
    border-radius: 12px;
    background: rgba(15, 23, 42, 0.9);
    backdrop-filter: blur(8px);
    border: 1px solid rgba(255, 255, 255, 0.15);
    color: #E2E8F0;
    font-size: 0.75rem;
    font-weight: 700;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 6px;
    transition: all 0.2s ease;
}

.modal-top-btn:hover {
    background: #1E293B;
    color: #FFFFFF;
}

.modal-top-close {
    width: 36px;
    height: 36px;
    border-radius: 12px;
    background: rgba(15, 23, 42, 0.9);
    border: 1px solid rgba(255, 255, 255, 0.15);
    color: #E2E8F0;
    font-size: 1.1rem;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.2s ease;
}

.modal-top-close:hover {
    background: #E11D48;
    color: #FFFFFF;
}

.modal-scroll-body {
    overflow-y: auto;
    flex: 1;
}

/* Visor de Galería en Modal */
.modal-gallery-viewport {
    position: relative;
    aspect-ratio: 16 / 10;
    max-height: 480px;
    background: #000000;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    user-select: none;
}

.modal-gallery-main-img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.gallery-nav-arrow {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: rgba(15, 23, 42, 0.75);
    backdrop-filter: blur(8px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: #FFFFFF;
    font-size: 1.2rem;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.2s ease;
    z-index: 10;
}

.gallery-nav-arrow:hover {
    background: rgba(15, 23, 42, 0.95);
    transform: translateY(-50%) scale(1.08);
}

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

.gallery-counter-badge {
    position: absolute;
    bottom: 16px;
    right: 16px;
    background: rgba(15, 23, 42, 0.85);
    backdrop-filter: blur(8px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: #FFFFFF;
    font-size: 0.72rem;
    font-weight: 700;
    padding: 4px 10px;
    border-radius: 999px;
}

/* Carrusel de Miniaturas */
.modal-thumbnails-strip {
    display: flex;
    gap: 8px;
    padding: 12px 16px;
    background: #020617;
    overflow-x: auto;
    border-bottom: 1px solid #1E293B;
}

.thumb-item-btn {
    width: 72px;
    height: 50px;
    border-radius: 8px;
    overflow: hidden;
    flex-shrink: 0;
    border: 2px solid transparent;
    opacity: 0.55;
    cursor: pointer;
    transition: all 0.2s ease;
    position: relative;
    padding: 0;
    background: #0A111F;
}

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

.thumb-item-btn:hover { opacity: 0.85; }

.thumb-item-btn.active {
    opacity: 1;
    border-color: var(--teal-light);
    box-shadow: 0 0 10px rgba(45, 212, 191, 0.5);
}

.thumb-tag-comun {
    position: absolute;
    bottom: 2px;
    left: 2px;
    right: 2px;
    background: rgba(2, 6, 23, 0.85);
    color: #94A3B8;
    font-size: 0.55rem;
    text-align: center;
    border-radius: 4px;
}

/* Información Detallada en Modal */
.modal-info-section {
    padding: 28px;
}

.modal-header-split {
    display: grid;
    grid-template-columns: 1fr 300px;
    gap: 24px;
    align-items: flex-start;
    margin-bottom: 24px;
}

.modal-location-text {
    font-size: 0.8rem;
    color: var(--teal-light);
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 6px;
    margin-bottom: 6px;
}

.modal-prop-title {
    font-family: 'Outfit', sans-serif;
    font-size: 1.5rem;
    font-weight: 800;
    color: #FFFFFF;
    line-height: 1.3;
    margin: 0;
}

.modal-prop-code {
    font-size: 0.75rem;
    color: #94A3B8;
    margin-top: 6px;
}

/* Caja de Precios y Condiciones en Modal */
.modal-price-box {
    background: #0A111F;
    border: 1px solid #1E293B;
    border-radius: 16px;
    padding: 16px 20px;
}

.price-box-label {
    font-size: 0.65rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: #64748B;
    display: block;
    margin-bottom: 4px;
}

.price-box-amount {
    font-family: 'Outfit', sans-serif;
    font-size: 1.7rem;
    font-weight: 800;
    color: #34D399;
    line-height: 1;
}

.price-box-detail {
    font-size: 0.75rem;
    color: #94A3B8;
    margin-top: 8px;
    line-height: 1.4;
}

/* Fila de 6 Métricas Principales en Modal */
.modal-metrics-6-grid {
    display: grid;
    grid-template-columns: repeat(6, 1fr);
    gap: 10px;
    margin-bottom: 24px;
}

.modal-metric-card {
    background: #0A111F;
    border: 1px solid #1E293B;
    border-radius: 14px;
    padding: 12px 8px;
    text-align: center;
}

.metric-card-icon {
    font-size: 1.2rem;
    color: var(--teal-light);
    margin-bottom: 4px;
    display: block;
}

.metric-card-val {
    font-size: 0.95rem;
    font-weight: 800;
    color: #FFFFFF;
    display: block;
}

.metric-card-lbl {
    font-size: 0.6rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: #64748B;
    margin-top: 2px;
    display: block;
}

/* Cajas de Texto y Razón de Arquitecto */
.modal-text-block {
    background: rgba(10, 17, 31, 0.6);
    border: 1px solid #1E293B;
    border-radius: 14px;
    padding: 18px 20px;
    margin-bottom: 20px;
}

.modal-text-block-title {
    font-size: 0.72rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.12em;
    color: var(--teal-light);
    margin-bottom: 8px;
    display: flex;
    align-items: center;
    gap: 6px;
}

.modal-text-block-p {
    font-size: 0.85rem;
    color: #CBD5E1;
    line-height: 1.6;
    margin: 0;
}

/* Barra Inferior de Contacto */
.modal-bottom-cta-bar {
    display: flex;
    gap: 12px;
    justify-content: flex-end;
    margin-top: 24px;
    padding-top: 20px;
    border-top: 1px solid #1E293B;
}

.btn-modal-whatsapp {
    padding: 12px 24px;
    background: #059669;
    border: 1px solid #10B981;
    border-radius: 12px;
    color: #FFFFFF;
    font-size: 0.85rem;
    font-weight: 800;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    text-decoration: none;
    box-shadow: 0 4px 16px rgba(5, 150, 105, 0.4);
    cursor: pointer;
    transition: all 0.2s ease;
}

.btn-modal-whatsapp:hover {
    background: #10B981;
    box-shadow: 0 6px 20px rgba(16, 185, 129, 0.5);
    color: #FFFFFF;
}

/* ==========================================================================
   TABLET (641px a 1024px: iPad, Android Tablets)
   - Grilla de 2 columnas equilibrada
   - Filtros organizados en 2 columnas
   - Modal flotante contenido con medidas ergonómicas
   - Carrusel y fotos optimizadas para pantalla táctil mediana
   ========================================================================== */
@media (min-width: 641px) and (max-width: 1024px) {
    .catalog-sync-banner {
        padding: 20px 24px;
        margin-bottom: 22px;
    }
    .sync-banner-title { font-size: 1.4rem; }

    .catalog-tabs-bar {
        padding: 10px 14px;
        gap: 10px;
    }
    .tab-pill-btn {
        padding: 8px 14px;
        font-size: 0.78rem;
    }

    .filter-card-d019 {
        padding: 18px;
    }
    .filter-grid-layout {
        grid-template-columns: 1fr 1fr;
        gap: 12px;
    }
    .input-field-wrap {
        grid-column: 1 / -1;
    }

    .modal-d019-container {
        max-width: 760px;
        max-height: 90vh;
        border-radius: 20px;
    }
    .modal-gallery-viewport {
        max-height: 380px;
    }
    .modal-header-split {
        grid-template-columns: 1fr 260px;
        gap: 18px;
    }
    .modal-metrics-6-grid {
        grid-template-columns: repeat(3, 1fr);
        gap: 10px;
    }
    .specs-4-grid {
        grid-template-columns: repeat(4, 1fr);
        gap: 6px;
    }
}

/* ==========================================================================
   CELULAR / SMARTPHONE (<= 640px)
   - 1 Columna vertical limpia
   - Pestañas con desplazamiento horizontal táctil
   - Filtros a 1 columna completa con campos de toque de 48px
   - Modal a pantalla completa tipo aplicación nativa
   - Botón de cierre superior de fácil alcance y CTA WhatsApp amplio
   ========================================================================== */
@media (max-width: 640px) {
    .catalog-sync-banner {
        padding: 16px 18px;
        border-radius: 12px;
        margin-bottom: 20px;
    }
    .sync-banner-title { font-size: 1.25rem; }
    .sync-banner-desc { font-size: 0.8rem; }

    /* Barra de Pestañas Swipeable */
    .catalog-tabs-bar {
        flex-direction: column;
        align-items: stretch;
        gap: 10px;
        padding: 10px 12px;
        border-radius: 12px;
    }
    .tabs-group {
        display: flex;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: none;
        gap: 6px;
        padding-bottom: 2px;
        width: 100%;
    }
    .tabs-group::-webkit-scrollbar { display: none; }
    .tab-pill-btn {
        flex: 1 0 auto;
        white-space: nowrap;
        text-align: center;
        padding: 9px 14px;
        font-size: 0.75rem;
    }
    .tabs-counter-label {
        text-align: center;
        font-size: 0.72rem;
    }

    /* Filtros Táctiles */
    .filter-card-d019 {
        padding: 16px 14px;
        border-radius: 14px;
        margin-bottom: 24px;
    }
    .filter-grid-layout {
        grid-template-columns: 1fr;
        gap: 12px;
    }
    .field-input {
        height: 48px;
    }
    .btn-clean-filters {
        height: 46px;
    }
    .chips-row {
        overflow-x: auto;
        flex-wrap: nowrap;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: none;
        padding-bottom: 4px;
        gap: 6px;
    }
    .chips-row::-webkit-scrollbar { display: none; }
    .quick-chip {
        white-space: nowrap;
        flex-shrink: 0;
        padding: 7px 12px;
        font-size: 0.72rem;
    }

    /* Tarjetas de Propiedad */
    .card-content-wrap {
        padding: 16px;
    }
    .card-title-bold {
        font-size: 1rem;
    }
    .specs-4-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 6px;
        padding: 10px 0;
    }
    .spec-mini-box {
        padding: 8px 4px;
    }
    .btn-card-details {
        height: 44px;
        font-size: 0.78rem;
    }

    /* Modal Ficha Completa para Celular (Experiencia App Nativa) */
    .modal-d019-backdrop {
        padding: 0;
    }
    .modal-d019-container {
        width: 100%;
        height: 100%;
        max-height: 100vh;
        border-radius: 0;
        border: none;
    }
    .modal-top-actions {
        top: 10px;
        right: 10px;
        gap: 6px;
    }
    .modal-top-close {
        width: 44px;
        height: 44px;
        font-size: 1.3rem;
    }
    .modal-gallery-viewport {
        max-height: 260px;
        aspect-ratio: 4 / 3;
    }
    .gallery-nav-arrow {
        width: 38px;
        height: 38px;
        font-size: 1rem;
    }
    .modal-thumbnails-strip {
        padding: 8px 10px;
        gap: 6px;
    }
    .thumb-item-btn {
        width: 58px;
        height: 40px;
    }
    .modal-info-section {
        padding: 18px 14px 28px;
    }
    .modal-header-split {
        grid-template-columns: 1fr;
        gap: 14px;
        margin-bottom: 18px;
    }
    .modal-prop-title {
        font-size: 1.25rem;
    }
    .modal-price-box {
        padding: 14px 16px;
        border-radius: 12px;
    }
    .price-box-amount {
        font-size: 1.45rem;
    }
    .modal-metrics-6-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 8px;
        margin-bottom: 18px;
    }
    .modal-text-block {
        padding: 14px 16px;
        border-radius: 12px;
    }
    .modal-bottom-cta-bar {
        flex-direction: column;
        width: 100%;
        padding-top: 16px;
        gap: 10px;
    }
    .btn-modal-whatsapp {
        width: 100%;
        justify-content: center;
        height: 48px;
        font-size: 0.9rem;
    }
}

