    /* Estilos del buscador unificado estilo mapas */
    .map-search-wrapper {
        position: relative;
        display: inline-flex;
        align-items: center;
        width: 100%;
    }

    .map-search-input {
        width: 100%;
        padding: 12px 75px 12px 20px;
        border-radius: 50px !important;
        border: 1px solid #ced4da;
        outline: none;
        box-shadow: 0 4px 15px rgba(0, 0, 0, 0.08);
        font-size: 15px;
        height: 50px;
        transition: all 0.3s ease;
        background: #fff;
    }

    .map-search-input:focus {
        border-color: #E35205 !important;
        box-shadow: 0 4px 20px rgba(227, 82, 5, 0.25) !important;
    }

    .map-search-clear {
        position: absolute;
        right: 18px;
        color: #aaa;
        cursor: pointer;
        font-size: 14px;
        font-weight: 600;
        transition: color 0.2s ease;
        user-select: none;
        z-index: 10;
    }

    .map-search-clear:hover {
        color: #E35205;
    }

    /* Estilos para el autocomplete nativo (Select2 eliminado) */

    #sugerencias-sector {
        position: absolute;
        left: 0;
        top: 100%;
        width: 100%;
        background: #fff;
        border: 1px solid #e0e0e0;
        border-top: none;
        border-radius: 0 0 8px 8px;
        z-index: 2000;
        box-shadow: 0 6px 20px rgba(0, 0, 0, 0.12);
        max-height: 280px;
        overflow-y: auto;
        scrollbar-width: thin;
        display: none;
    }

    #sugerencias-sector.activo {
        display: block;
    }

    .sugerencia-item {
        padding: 10px 14px;
        cursor: pointer;
        border-bottom: 1px solid #f0f0f0;
        transition: background-color 0.15s ease;
        display: flex;
        align-items: center;
        gap: 8px;
    }

    .sugerencia-item:last-child {
        border-bottom: none;
    }

    .sugerencia-item:hover,
    .sugerencia-item.activa {
        background: #f7f7f7;
    }

    .sugerencia-item .sector-nombre {
        font-weight: 600;
        color: #333;
        font-size: 0.9rem;
    }

    .sugerencia-item .sector-ubicacion {
        font-size: 0.75rem;
        color: #333;
        background: #f0f0f0;
        padding: 2px 8px;
        border-radius: 12px;
        white-space: nowrap;
    }

    .sugerencia-item .sector-icono {
        color: #e35205;
        font-size: 0.85rem;
        flex-shrink: 0;
    }

    .sugerencia-sin-resultado {
        padding: 14px;
        text-align: center;
        color: #999;
        font-size: 0.85rem;
    }

    #buscar_precio_sector:focus {
        box-shadow: 0 0 0 3px rgba(227, 82, 5, 0.15);
        border-color: #e35205;
    }

    .search-container-premium {
        background: #fff;
        border-radius: 16px;
        padding: 30px;
        box-shadow: 0 10px 40px rgba(0, 0, 0, 0.08);
        border-bottom: 3px solid transparent;
        transition: border-color 0.4s ease;
    }

    #recaptcha-row-container {
        max-width: 0;
        overflow: hidden;
        opacity: 0;
        transition: all 0.4s ease;
        display: flex;
        justify-content: center;
        align-items: center;
    }

    #recaptcha-row-container.visible {
        max-width: 320px;
        opacity: 1;
        padding-left: 10px;
        padding-right: 10px;
    }

    .g-recaptcha {
        display: block;
    }

    .btn-search-premium {
        border-radius: 8px !important;
        font-weight: 600;
        padding: 10px 20px !important;
        transition: all 0.3s ease;
        background-color: #e35205 !important;
        border-color: #e35205 !important;
        color: white !important;
        white-space: nowrap;
    }

    .btn-search-premium:disabled {
        background-color: #f0f0f0 !important;
        border-color: #e0e0e0 !important;
        color: #999 !important;
        cursor: not-allowed;
    }

    .btn-ready {
        animation: pulse-border 2s infinite;
        transform: scale(1.05);
    }

    @keyframes pulse-border {
        0% {
            box-shadow: 0 0 0 0 rgba(227, 82, 5, 0.4);
        }

        70% {
            box-shadow: 0 0 0 10px rgba(227, 82, 5, 0);
        }

        100% {
            box-shadow: 0 0 0 0 rgba(227, 82, 5, 0);
        }
    }

    .captcha-hint {
        color: #e35205;
        font-weight: 500;
        font-size: 0.85rem;
        margin-bottom: 10px;
        display: none;
        animation: fadeInUp 0.4s ease;
    }

    @keyframes fadeInUp {
        from {
            opacity: 0;
            transform: translateY(10px);
        }

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

    /* Pyramid Styles */
    .pyramid-container {
        width: 100%;
        background: #fff;
        border-radius: 20px;
        box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
        overflow: hidden;
        transition: transform 0.3s ease;
        margin-top: 20px;
    }

    .pyramid-container:hover {
        transform: translateY(-5px);
    }

    .pyramid-header {
        background: #e35205;
        color: white;
        padding: 12px 20px;
        text-align: center;
    }

    .pyramid-header h2 {
        font-size: 16px;
        margin-bottom: 2px;
        margin-top: 0;
        font-weight: 600;
        color: white;
    }

    .pyramid-header p {
        font-size: 10px;
        opacity: 0.95;
        margin-bottom: 0;
    }

    .pyramid-labels {
        display: flex;
        justify-content: space-between;
        align-items: flex-start;
        width: 100%;
        padding: 15px 30px;
        margin-bottom: -20px;
    }

    .pyramid-label-box {
        width: 110px;
        height: 70px;
        background: #f8fcf9;
        border: 1.5px solid #2F8F5F;
        border-radius: 10px;
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        font-weight: 700;
        color: #2F8F5F;
        font-size: 9px;
        line-height: 1.2;
        padding: 4px;
        box-shadow: 0 4px 12px rgba(47, 143, 95, 0.08);
        text-align: center;
        transition: all 0.3s ease;
    }

    .pyramid-label-box-premium {
        background: #ffffff;
        color: #1a5c3d;
        border: 1.5px solid #1a5c3d;
        width: 110px;
        height: 70px;
        border-radius: 10px;
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        font-weight: 700;
        font-size: 9px;
        line-height: 1.2;
        padding: 4px;
        box-shadow: 0 4px 12px rgba(26, 92, 61, 0.08);
        text-align: center;
        transition: all 0.3s ease;
    }

    .pyramid-label-amc {
        background: linear-gradient(135deg, #E35205, #ff7a35);
        color: #ffffff;
        border: none;
        border-radius: 10px;
        padding: 6px 14px;
        font-weight: 800;
        font-size: 11px;
        box-shadow: 0 6px 20px rgba(227, 82, 5, 0.25);
        text-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        line-height: 1.1;
        transition: all 0.3s ease;
    }

    .pyramid-label-amc i,
    .pyramid-label-box i,
    .pyramid-label-box-premium i {
        font-size: 1rem;
        margin-bottom: 3px;
    }

    .pyramid-label-amc small,
    .pyramid-label-box small,
    .pyramid-label-box-premium small {
        font-size: 7.5px;
        text-transform: uppercase;
        letter-spacing: 0.5px;
        opacity: 0.9;
    }

    .pyramid {
        padding: 30px;
        background: #ffffff;
    }

    .pyramid-level {
        position: relative;
        margin-bottom: 8px;
        cursor: pointer;
        transition: all 0.3s ease;
        animation: slideInPyramid 0.5s ease forwards;
        opacity: 0;
    }

    .html2canvas-capturing .pyramid-level {
        animation: none !important;
        opacity: 1 !important;
        transform: none !important;
    }

    .pyramid-level:hover {
        transform: scale(1.01);
    }

    .level-bar {
        height: 54px;
        display: flex;
        align-items: center;
        justify-content: space-between;
        gap: 12px;
        padding: 0 20px;
        color: white;
        font-weight: bold;
        border-radius: 8px;
        transition: all 0.3s ease;
        position: relative;
        overflow: hidden;
        box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
    }

    .level-bar::before {
        content: '';
        position: absolute;
        top: 0;
        left: -100%;
        width: 100%;
        height: 100%;
        background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
        transition: left 0.5s ease;
    }

    .pyramid-level:hover .level-bar::before {
        left: 100%;
    }

    .level-price {
        font-size: 13px;
        font-weight: bold;
        text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.3);
        z-index: 1;
        background: rgba(0, 0, 0, 0.3);
        padding: 3px 10px;
        border-radius: 6px;
    }

    .level-percentage {
        font-size: 13px;
        font-weight: 700;
        z-index: 1;
        background: #fff;
        color: #1e6642;
        border: 2px solid #030303;
        padding: 2px 8px;
        border-radius: 6px;
        letter-spacing: 0.5px;
    }

    .level-fecha {
        font-size: 11px;
        font-weight: 600;
        color: #2F8F5F;
        background: #e8f5ee;
        border: 1px solid #2F8F5F;
        border-radius: 6px;
        padding: 3px 8px;
        box-shadow: 0 1px 4px rgba(47, 143, 95, 0.15);
        display: inline-block;
    }

    .level-90 {
        background: linear-gradient(90deg, #1e6642 0%, #2F8F5F 100%);
        width: 100%;
        margin-left: 0;
    }

    .level-70 {
        background: linear-gradient(90deg, #237550 0%, #35a06c 100%);
        width: 88%;
        margin-left: 6%;
    }

    .level-50 {
        background: linear-gradient(90deg, #28855c 0%, #3ab278 100%);
        width: 76%;
        margin-left: 12%;
    }

    .level-30 {
        background: linear-gradient(90deg, #2e9467 0%, #40c486 100%);
        width: 64%;
        margin-left: 18%;
    }

    .level-10 {
        background: linear-gradient(90deg, #35a474 0%, #50d898 100%);
        width: 55%;
        margin-left: 22.5%;
    }

    .pyramid-info-section {
        padding: 20px 30px;
        background: #fff;
        border-top: 1px solid #eee;
    }

    .pyramid-stats-grid {
        display: grid;
        grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
        gap: 15px;
        margin-bottom: 20px;
    }

    .pyramid-stat-card {
        background: linear-gradient(135deg, #2F8F5F 0%, #1e6642 100%);
        padding: 12px;
        border-radius: 12px;
        text-align: center;
        color: white;
    }

    .pyramid-stat-label {
        font-size: 9px;
        text-transform: uppercase;
        letter-spacing: 1px;
        opacity: 0.9;
        margin-bottom: 5px;
    }

    .pyramid-stat-value {
        font-size: 14px;
        font-weight: bold;
    }

    .pyramid-price-tag {
        text-align: center;
        background: linear-gradient(135deg, #2F8F5F 0%, #1e6642 100%);
        padding: 15px;
        border-radius: 12px;
        color: white;
    }

    .pyramid-price-label {
        font-size: 9px;
        text-transform: uppercase;
        letter-spacing: 1px;
        margin-bottom: 5px;
    }

    .pyramid-price-amount {
        font-size: 20px;
        font-weight: bold;
    }

    .pyramid-price-amount::before {
        content: '$';
        font-size: 18px;
        margin-right: 4px;
    }

    .pyramid-tooltip {
        position: absolute;
        right: -25px;
        top: 50%;
        transform: translateY(-50%);
        background: #ffffff;
        color: #030303;
        width: 18px;
        height: 18px;
        border-radius: 50%;
        display: flex;
        align-items: center;
        justify-content: center;
        font-size: 11px;
        font-weight: 900;
        cursor: help;
        z-index: 10;
        border: 2px solid #030303;
        box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
    }

    /* Tooltip aparece al pasar el ratón por toda la barra */
    .pyramid-level:hover .pyramid-tooltip::after {
        content: attr(data-info);
        position: absolute;
        bottom: 125%;
        right: 0;
        background: #333;
        color: #fff;
        padding: 8px 12px;
        border-radius: 8px;
        font-size: 11px;
        width: 200px;
        white-space: normal;
        box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
        z-index: 100;
        text-align: left;
        line-height: 1.4;
        font-weight: normal;
    }

    /* Flechita del tooltip al pasar por la barra */
    .pyramid-level:hover .pyramid-tooltip::before {
        content: '';
        position: absolute;
        bottom: 115%;
        right: 5px;
        border: 6px solid transparent;
        border-top-color: #333;
        z-index: 100;
    }

    @media (max-width: 640px) {
        .pyramid-tooltip {
            right: 0px;
            /* En móvil lo pegamos más */
            width: 16px;
            height: 16px;
            font-size: 10px;
        }
    }

    @keyframes slideInPyramid {
        from {
            opacity: 0;
            transform: translateX(-20px);
        }

        to {
            opacity: 1;
            transform: translateX(0);
        }
    }

    .pyramid-level:nth-child(1) {
        animation-delay: 0.1s;
    }

    .pyramid-level:nth-child(2) {
        animation-delay: 0.2s;
    }

    .pyramid-level:nth-child(3) {
        animation-delay: 0.3s;
    }

    .pyramid-level:nth-child(4) {
        animation-delay: 0.4s;
    }

    .pyramid-level:nth-child(5) {
        animation-delay: 0.5s;
    }

    /* ===== Compact overrides for capture area ===== */
    .capture-prices-area .pyramid-container {
        margin-top: 8px !important;
        border-radius: 12px !important;
        box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08) !important;
    }

    .capture-prices-area .pyramid-header {
        padding: 7px 14px !important;
    }

    .capture-prices-area .pyramid-header h2 {
        font-size: 14px !important;
        margin-bottom: 0 !important;
    }

    .capture-prices-area .pyramid-header p {
        font-size: 9.5px !important;
        margin-bottom: 0 !important;
    }

    .capture-prices-area .pyramid-labels {
        padding: 8px 16px !important;
        margin-bottom: -14px !important;
        gap: 4px !important;
    }

    .capture-prices-area .pyramid-label-box,
    .capture-prices-area .pyramid-label-box-premium {
        width: 90px !important;
        height: 54px !important;
        font-size: 7.5px !important;
        padding: 3px !important;
    }

    .capture-prices-area .pyramid-label-amc {
        padding: 3px 6px !important;
        font-size: 7.5px !important;
    }

    .capture-prices-area .pyramid {
        padding: 16px 34px 16px 6px !important;
    }

    .capture-prices-area .pyramid-level {
        margin-bottom: 5px !important;
    }

    .capture-prices-area .level-bar {
        height: 42px !important;
        padding: 0 12px !important;
        gap: 7px !important;
    }

    .capture-prices-area .level-price {
        font-size: 12px !important;
        padding: 2px 8px !important;
    }

    .capture-prices-area .level-percentage {
        font-size: 12px !important;
        padding: 2px 7px !important;
    }

    .capture-prices-area .level-fecha {
        font-size: 10.5px !important;
        padding: 2px 6px !important;
    }

    .capture-prices-area .pyramid-tooltip {
        width: 14px !important;
        height: 14px !important;
        font-size: 9px !important;
        right: -20px !important;
    }

    /* Price cards (Venta / Alquiler) */
    .capture-prices-area .alert {
        padding: 6px 10px !important;
        font-size: 0.82rem !important;
        margin-bottom: 8px !important;
    }

    .capture-prices-area .card-header {
        padding: 5px 12px !important;
    }

    .capture-prices-area .card-header h6 {
        font-size: 0.9rem !important;
        margin-bottom: 0 !important;
    }

    .capture-prices-area .card-body {
        padding: 8px 12px !important;
        font-size: 1rem !important;
    }

    .capture-prices-area .row.mb-1 {
        margin-bottom: 4px !important;
    }

    /* ===== END compact overrides ===== */

    @media (max-width: 768px) {
        .pyramid-container {
            border-radius: 12px;
            margin-top: 5px;
        }


        .pyramid-header {
            padding: 6px 10px;
        }

        .pyramid-header h2 {
            font-size: 12px;
        }

        .pyramid-header p {
            font-size: 8px;
        }

        .pyramid-labels {
            padding: 8px 4px;
            margin-bottom: -12px;
            gap: 3px;
            justify-content: space-between;
        }

        .pyramid-label-box,
        .pyramid-label-box-premium {
            width: 31%;
            min-width: 65px;
            height: 50px;
            font-size: 7px;
            padding: 2px;
        }

        .pyramid-label-amc {
            width: 31%;
            min-width: 65px;
            padding: 3px 4px;
            font-size: 8.5px;
            box-shadow: 0 3px 6px rgba(227, 82, 5, 0.15);
        }

        .pyramid-label-amc i,
        .pyramid-label-box i,
        .pyramid-label-box-premium i {
            font-size: 11px;
            margin-bottom: 2px;
        }

        .pyramid-label-amc small,
        .pyramid-label-box small,
        .pyramid-label-box-premium small {
            font-size: 6px;
        }

        .pyramid {
            padding: 12px 4px;
        }

        .pyramid-level {
            margin-bottom: 4px;
        }

        .level-bar {
            height: 36px;
            padding: 0 5px;
            gap: 3px;
            width: 100% !important;
            margin-left: 0 !important;
        }

        .level-price {
            font-size: 9px;
            padding: 1px 4px;
        }

        .level-percentage {
            font-size: 9px;
            padding: 1px 3px;
        }

        .level-fecha {
            font-size: 8px;
            padding: 1px 3px;
        }

        .pyramid-tooltip {
            right: -1px;
            width: 11px;
            height: 11px;
            font-size: 7px;
        }

        /* Ajustes para volver a pestañas a la IZQUIERDA en móviles - MÁXIMA COMPACTACIÓN */
        .modal-body .d-flex.align-items-start {
            flex-direction: row !important;
            flex-wrap: nowrap !important;
        }

        .modal-body .nav-pills {
            width: 75px !important;
            /* Más estrecho */
            flex-direction: column !important;
            flex-shrink: 0 !important;
            margin-right: 5px !important;
            padding-right: 2px !important;
            border-right: 1px solid #f0f0f0 !important;
            border-bottom: none !important;
            overflow-y: auto !important;
            overflow-x: hidden !important;
            max-height: 80vh !important;
            display: flex !important;
        }

        .modal-body .nav-pills .nav-link {
            display: flex !important;
            flex-direction: column !important;
            align-items: center !important;
            padding: 4px 1px !important;
            /* Padding mínimo */
            margin-bottom: 2px !important;
            /* Espacio mínimo entre botones */
            white-space: normal !important;
            text-align: center !important;
            font-size: 7.5px !important;
            /* Fuente muy pequeña */
            line-height: 1 !important;
            border-radius: 6px !important;
        }

        .modal-body .nav-pills .nav-link i {
            font-size: 13px !important;
            /* Icono pequeño */
            margin-right: 0 !important;
            margin-bottom: 2px !important;
        }

        .modal-body .tab-content {
            flex-grow: 1 !important;
            width: calc(100% - 80px) !important;
            overflow-x: hidden !important;
        }
    }