/* Styles pour le frontend du plugin Elipte Recherche - Compatible Divi */

.elipte-recherche-container {
    margin: 20px 0;
    font-family: inherit;
}

.elipte-recherche-ville {
    margin-bottom: 15px;
    overflow: hidden;
    background: #fff;
}

.elipte-recherche-ville-title {
    padding: 15px 20px;
    margin: 0;
    cursor: pointer;
    font-size: 18px;
    font-weight: 600;
    color: #333;
    border-bottom: 1px solid #E0E0E0;
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: background-color 0.3s ease;
    user-select: none;
}

.elipte-recherche-ville-title:hover {
    background: #e9ecef;
}

.elipte-recherche-ville-title.active {
    background: #1f3b46;
    color: #fff;
}

.elipte-recherche-toggle {
    font-size: 20px;
    font-weight: bold;
    transition: transform 0.3s ease;
    min-width: 20px;
    text-align: center;
}

.elipte-recherche-ville-title.active .elipte-recherche-toggle {
    transform: rotate(180deg);
}

.elipte-recherche-biens {
    padding: 0;
    background: #fff;
    border-top: 1px solid #e0e0e0;
    animation: slideDown 0.3s ease-out;
}

@keyframes slideDown {
    from {
        opacity: 0;
        max-height: 0;
    }
    to {
        opacity: 1;
        max-height: 1000px;
    }
}

.elipte-recherche-bien {
    padding: 20px;
    border-bottom: 1px solid #f0f0f0;
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 20px;
}

.elipte-recherche-bien:last-child {
    border-bottom: none;
}

.elipte-recherche-bien:hover {
    background: #fafafa;
}

.elipte-recherche-bien-content {
    flex: 1;
}

.elipte-recherche-bien-content h4 {
    margin: 0 0 10px 0;
    color: #1f3b46;
    font-size: 16px;
    font-weight: 600;
}

.elipte-recherche-bien-content p {
    margin: 8px 0;
    line-height: 1.6;
    color: #666;
}

.elipte-recherche-bien-content p:first-of-type {
    color: #333;
    font-size: 14px;
}

.elipte-recherche-bien-action {
    flex-shrink: 0;
    display: flex;
    align-items: center;
}

.elipte-recherche-btn {
    background: #1f3b46;
    color: #fff !important;
    padding: 10px 20px;
    text-decoration: none !important;
    font-weight: 600;
    font-size: 14px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    transition: all 0.3s ease;
    border: none;
    cursor: pointer;
    display: inline-block;
    text-align: center;
    min-width: 180px;
}

.elipte-recherche-btn:hover {
    background: #005a87;
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(0, 124, 186, 0.3);
    color: #fff !important;
}

.elipte-recherche-btn:active {
    transform: translateY(0);
    box-shadow: 0 2px 4px rgba(0, 124, 186, 0.3);
}

/* Responsive Design */
@media (max-width: 768px) {
    .elipte-recherche-ville-title {
        padding: 12px 15px;
    }
    
    .elipte-recherche-bien {
        flex-direction: column;
        padding: 15px;
        gap: 15px;
    }
    
    .elipte-recherche-bien-action {
        align-self: stretch;
    }
    
    .elipte-recherche-btn {
        width: 100%;
        padding: 12px 20px;
        min-width: auto;
    }
}

@media (max-width: 480px) {
    .elipte-recherche-container {
        margin: 15px 0;
    }
    
    .elipte-recherche-ville-title {
        padding: 10px 12px;
    }
    
    .elipte-recherche-bien {
        padding: 12px;
    }
    
    .elipte-recherche-btn {
        padding: 10px 15px;
    }
}

/* Compatibilité avec les thèmes populaires */
.et_pb_module .elipte-recherche-container,
.et_pb_row .elipte-recherche-container {
    font-family: inherit;
}

/* Éviter les conflits avec les styles de thème */
.elipte-recherche-container * {
    box-sizing: border-box;
}

.elipte-recherche-container h4 {
    font-family: inherit;
}

.elipte-recherche-container p {
    font-family: inherit;
}

/* États vides */
.elipte-recherche-empty {
    text-align: center;
    padding: 40px 20px;
    color: #666;
    font-style: italic;
}

/* Animation pour l'ouverture/fermeture */
.elipte-recherche-biens {
    overflow: hidden;
    transition: all 0.3s ease;
}

/* Focus et accessibilité */
.elipte-recherche-ville-title:focus {
    outline: 2px solid #1f3b46;
    outline-offset: 2px;
}

.elipte-recherche-btn:focus {
    outline: 2px solid #005a87;
    outline-offset: 2px;
}

/* ================================
   STYLES POUR LE WIDGET BIEN DETAILS
   ================================ */

.elipte-bien-header {
    padding-bottom: 15px;
    margin-bottom: 25px;
    border-bottom: 1px solid #e0e0e0;
}

.elipte-bien-header h2 {
    font-size: 40px;
    margin: 0;
    line-height: 1;
}

.elipte-bien-content {
    line-height: 1.6;
}

.elipte-bien-info {
    background: #f8f9fa;
    padding: 20px;
    margin-bottom: 25px;
    border-left: 4px solid #1f3b46;
}

.elipte-bien-row {
    display: flex;
    margin-bottom: 12px;
    align-items: flex-start;
}

.elipte-bien-row:last-child {
    margin-bottom: 0;
}

.elipte-bien-label {
    font-weight: 600;
    color: #333;
    min-width: 120px;
    flex-shrink: 0;
}

.elipte-bien-value {
    color: #666;
    flex: 1;
}

.elipte-bien-description {
    margin-bottom: 15px;
}

.elipte-bien-description h3 {
    color: #333;
    font-size: 18px;
    font-weight: 600;
    margin: 0 0 15px 0;
    border-bottom: 1px solid #e0e0e0;
    padding-bottom: 8px;
}

.elipte-bien-desc-content {
    background: #fff;
    padding: 20px;
    border: 1px solid #e0e0e0;
    color: #333;
    line-height: 1.7;
    font-size: 15px;
}

.elipte-bien-meta {
    color: #999;
    font-size: 13px;
    margin-bottom: 40px;
}

.elipte-bien-contact {
    background: #e7f3ff;
    border: 1px solid #b8daff;
    padding: 20px;
    margin-top: 25px;
}

.elipte-bien-contact p {
    margin: 0 0 10px 0;
    color: #0c4a6e;
}

.elipte-bien-contact p:last-child {
    margin-bottom: 0;
}

.elipte-bien-contact strong {
    color: #1e40af;
}

/* Responsive pour le widget bien details */
@media (max-width: 768px) {
    .elipte-bien-details {
        padding: 20px;
        margin: 15px 0;
    }
    
    .elipte-bien-header h2 {
        font-size: 20px;
    }
    
    .elipte-bien-info {
        padding: 15px;
    }
    
    .elipte-bien-row {
        flex-direction: column;
        margin-bottom: 15px;
    }
    
    .elipte-bien-label {
        min-width: auto;
        margin-bottom: 5px;
        font-size: 14px;
    }
    
    .elipte-bien-value {
        font-size: 15px;
    }
    
    .elipte-bien-desc-content {
        padding: 15px;
    }
}

@media (max-width: 480px) {
    .elipte-bien-details {
        padding: 15px;
        border-radius: 6px;
    }
    
    .elipte-bien-header {
        padding-bottom: 12px;
        margin-bottom: 20px;
    }
    
    .elipte-bien-header h2 {
        font-size: 18px;
    }
    
    .elipte-bien-description h3 {
        font-size: 16px;
    }
    
    .elipte-bien-desc-content {
        padding: 12px;
        font-size: 14px;
    }
    
    .elipte-bien-contact {
        padding: 15px;
    }
}

/* Compatibilité avec Divi et autres thèmes */
.et_pb_module .elipte-bien-details,
.et_pb_row .elipte-bien-details {
    font-family: inherit;
}

.elipte-bien-details * {
    box-sizing: border-box;
}

.elipte-bien-details h2,
.elipte-bien-details h3 {
    font-family: inherit;
}

.elipte-bien-details p {
    font-family: inherit;
}