/* Propiedades Buscador - Estilos Horizontal Dark */
.propiedades-buscador {
    max-width: 100%;
    margin: 0 auto;
    padding: 30px 10px 1px 10px;
}

/* Tabs */
.propiedades-tabs {
    display: flex;
    justify-content: center;
    gap: 0;
    margin-bottom: 20px;
    border-bottom: 1px solid #fff;
    padding-bottom: 20px;
}

.propiedades-tab {
    padding: 1px 40px;
    background: rgba(255, 255, 255, 0.1);
    border: none;
    cursor: pointer;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.7);
    transition: all 0.3s ease;
    font-size: 13px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    border-radius: 50px;
    margin: 0 5px;
}

.propiedades-tab:hover {
    background: rgba(255, 255, 255, 0.15);
    color: #fff;
}

.propiedades-tab.active {
    background: #FF2124;
    color: #fff;
    box-shadow: 0 4px 15px rgba(255, 33, 36, 0.4);
}

/* Formularios */
.propiedades-form {
    display: none;
    animation: fadeIn 0.3s;
}

.propiedades-form.active {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    align-items: flex-end;
    justify-content: center;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(-10px); }
    to { opacity: 1; transform: translateY(0); }
}

.form-group {
    margin-bottom: 0;
    flex: 0;
    min-width: 180px;
    max-width: 250px;
}

#form-codigo .form-group {
    min-width: 300px;
    max-width: 400px;
}

.form-group label {
    display: none;
    margin-bottom: 8px;
    font-weight: 600;
    color: #fff;
    font-size: 14px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.form-group select,
.form-group input[type="text"] {
    width: 100%;
    padding: 2px 18px;
    border: none;
    border-radius: 50px;
    font-size: 15px;
    box-sizing: border-box;
    color: #fff !important;
    transition: all 0.3s ease;
    font-weight: 300;
    box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.1);
    background-color: hsla(0, 0%, 100%, .2) !important;
    border-color: hsla(0, 0%, 100%, .09);
}

.form-group select:hover,
.form-group input[type="text"]:hover {
    background-color: rgba(68, 97, 142, 0.7);
}

.form-group select option {
    background-color: #e4e4e4;
    color: #ffffff;
    padding: 10px;
}

.form-group input[type="text"] {
    background-color: rgba(68, 97, 142, 0.5);
    color: #ffffff !important;
}

.form-group input[type="text"]::placeholder {
    color: rgba(255, 255, 255, 0.7);
}

.form-group select:focus,
.form-group input[type="text"]:focus {
    outline: none;
    border-color: #FF2124;
    background: #fff;
    box-shadow: 0 0 0 3px rgba(255, 33, 36, 0.1);
}

.form-group select.error,
.form-group input.error {
    border-color: #ff6b6b;
    background: #fff5f5;
}

.propiedades-submit {
    background: #FF2124;
    color: white;
    border: none;
    padding: 2px 40px;
    font-size: 16px;
    border-radius: 50px;
    cursor: pointer;
    transition: all 0.3s ease;
    margin-top: 0;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    box-shadow: 0 4px 15px rgba(255, 33, 36, 0.3);
    align-self: flex-end;
}

.propiedades-submit:hover {
    background: #d91d20;
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(255, 33, 36, 0.4);
}

.propiedades-submit:active {
    transform: translateY(0);
}

/* Mensajes */
.propiedades-mensaje {
    padding: 20px;
    background-color: #f8f9fa;
    border: 1px solid #dee2e6;
    border-radius: 8px;
    text-align: center;
    margin: 20px 0;
    font-size: 16px;
    color: #495057;
}

.propiedades-mensaje.error {
    background-color: #fff3cd;
    border-color: #ffeaa7;
    color: #856404;
}

/* Resultados */
.propiedades-resultados {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
}

.resultados-header {
    margin-bottom: 30px;
    padding-bottom: 15px;
    border-bottom: 2px solid #FF2124;
}

.resultados-header h2 {
    color: #FF2124;
    margin-bottom: 10px;
}

.resultados-filtros {
    background-color: #f8f9fa;
    padding: 15px;
    border-radius: 4px;
    margin-bottom: 10px;
}

.resultados-filtros p {
    margin: 5px 0;
}

.resultados-count {
    font-weight: bold;
    color: #FF2124;
    margin-top: 15px;
}

/* Tablas */
.tablafull {
    width: 100%;
    border: 1px dotted #ccc;
    padding: 10px;
    margin-bottom: 20px;
    border-collapse: collapse;
    display: table;
}

.tablaresponsive {
    display: none;
    width: 100%;
    border: 1px dotted #ccc;
    padding: 10px;
    margin-bottom: 20px;
    border-collapse: collapse;
}

.tablafull td,
.tablaresponsive td {
    padding: 10px;
    vertical-align: top;
}

.botonvermas {
    font-size: 14px;
    padding: 5px 16px;
    border-radius: 500px;
    color: #fff;
    text-decoration: none;
    display: inline-block;
    margin-left: 10px;
    border: none;
    cursor: pointer;
}

/* Detalle */
.propiedades-detalle {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
    font-family: 'Roboto', sans-serif;
}

/* SLIDER 4:3 */
.slider-detalle {
    position: relative;
    max-width: 800px;
    margin: 0 auto 20px;
    background-color: #000;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
}

.slider-container {
    position: relative;
    width: 100%;
    padding-bottom: 75%;
    overflow: hidden;
    background-color: #000;
}

.slider-image {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
    display: none;
    opacity: 0;
}

.slider-image:first-child {
    display: block;
    opacity: 1;
}

.slider-arrow {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(0, 0, 0, 0.6);
    color: white;
    border: none;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10;
    transition: all 0.3s ease;
}

.slider-arrow:hover {
    background: rgba(255, 33, 36, 0.9);
    transform: translateY(-50%) scale(1.1);
}

.slider-prev {
    left: 15px;
}

.slider-next {
    right: 15px;
}

.slider-arrow svg {
    width: 24px;
    height: 24px;
    stroke-width: 3;
}

.slider-counter {
    position: absolute;
    bottom: 15px;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(0, 0, 0, 0.7);
    color: white;
    padding: 8px 16px;
    border-radius: 20px;
    font-size: 14px;
    font-weight: 600;
    z-index: 10;
}

.current-slide {
    color: #FF2124;
    font-weight: 700;
}

.slider-controls {
    display: none;
}

.slider-expand {
    position: absolute;
    top: 15px;
    right: 15px;
    background: rgba(0, 0, 0, 0.6);
    color: white;
    border: none;
    padding: 10px 16px;
    border-radius: 25px;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 8px;
    z-index: 10;
    transition: all 0.3s ease;
    font-size: 14px;
    font-weight: 600;
}

.slider-expand:hover {
    background: rgba(255, 33, 36, 0.9);
    transform: scale(1.05);
}

.slider-expand svg {
    width: 20px;
    height: 20px;
}

/* LIGHTBOX */

.lightbox-content {
    background-color:transparent !important;
    }


.lightbox-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.95);
    z-index: 999999;
    display: none;
    align-items: center;
    justify-content: center;
}

.lightbox-container {
    position: relative;
    width: 100%;
    height: 90vh;
    display: flex;
    align-items: center;
    justify-content: center;
}

.lightbox-content {
    position: relative;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.lightbox-image {
    max-width: 90%;
    max-height: 90vh;
    width: auto;
    height: auto;
    object-fit: contain;
    position: absolute;
    top: 55%;
    left: 50%;
    transform: translate(-50%, -50%);
    display: none;
    opacity: 0;
}

.lightbox-image:first-child {
    display: block;
    opacity: 1;
}

.lightbox-close {
    position: fixed;
    top: 130px;
    right: 20px;
    width: 70px;
    height: 70px;
    background: #FF2124;
    border: 4px solid #FFFFFF;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 99999999;
    transition: all 0.3s ease;
    box-shadow: 0 0 30px rgba(255, 33, 36, 1);
}

.lightbox-close:hover {
    background: #FFFFFF;
    border-color: #FF2124;
    transform: rotate(90deg) scale(1.2);
}

.lightbox-close:hover svg {
    stroke: #FF2124;
}

.lightbox-close svg {
    width: 32px;
    height: 32px;
    stroke: #FFFFFF;
    stroke-width: 4;
}

.lightbox-arrow {
    position: fixed;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(255, 255, 255, 0.2);
    color: white;
    border: none;
    width: 60px;
    height: 60px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 99999999;
    transition: all 0.3s ease;
}

.lightbox-arrow:hover {
    background: rgba(255, 33, 36, 0.9);
    transform: translateY(-50%) scale(1.15);
}

.lightbox-prev {
    left: 30px;
}

.lightbox-next {
    right: 30px;
}

.lightbox-arrow svg {
    width: 30px;
    height: 30px;
    stroke-width: 3;
}

.lightbox-counter {
    position: fixed;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(255, 255, 255, 0.2);
    color: white;
    padding: 12px 24px;
    border-radius: 30px;
    font-size: 16px;
    font-weight: 700;
    z-index: 99999999;
}

.lightbox-current-slide {
    color: #FF2124;
    font-size: 18px;
}

.boton-volver {
    background-color: #0073aa;
    color: white;
    border: none;
    padding: 10px 20px;
    cursor: pointer;
    border-radius: 4px;
    font-size: 16px;
    margin-top: 20px;
}

/* Responsive */
@media (max-width: 992px) {
    .propiedades-form.active {
        flex-direction: column;
        align-items: stretch;
    }
    
    .form-group {
        max-width: 100%;
        min-width: 100%;
    }
    
    #form-codigo .form-group {
        min-width: 100%;
        max-width: 100%;
    }
    
    .propiedades-submit {
        align-self: stretch;
        width: 100%;
    }
}

@media (max-width: 768px) {
    .propiedades-buscador {
        padding: 15px;
        border-radius: 8px;
    }
    
    .propiedades-tabs {
        flex-direction: column;
        gap: 10px;
    }
    
    .propiedades-tab {
        text-align: center;
        padding: 12px 20px;
        margin: 0;
        width: 100%;
    }
    
    .tablafull {
        display: none;
    }
    
    .tablaresponsive {
        display: table;
    }
    
    .botonvermas {
        margin: 5px;
        float: none;
    }
    
    .slider-arrow {
        width: 40px;
        height: 40px;
    }
    
    .slider-prev {
        left: 10px;
    }
    
    .slider-next {
        right: 10px;
    }
    
    .slider-expand span {
        display: none;
    }
    
    .lightbox-close {
        top: 80px;
        right: 15px;
        width: 60px;
        height: 60px;
    }
    
    .lightbox-arrow {
        width: 50px;
        height: 50px;
    }
    
    .lightbox-prev {
        left: 15px;
    }
    
    .lightbox-next {
        right: 15px;
    }


    .lightbox-image {
    max-width: 90%;
    max-height: 90vh;
    width: auto;
    height: auto;
    object-fit: contain;
    position: absolute;
    top: 45%;
    left: 50%;
    }
}

@media print {
    .propiedades-buscador,
    .propiedades-tabs,
    .propiedades-submit,
    .boton-volver,
    .slider-controls,
    .slider-expand,
    .lightbox-close,
    .lightbox-arrow {
        display: none !important;
    }
}