/**
 * Stili per il form di valutazione immobile
 */

/* Stili per la modale personalizzata */
.nestup-custom-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 9999;
}

.nestup-custom-modal.active {
    display: block;
}

.nestup-custom-modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    z-index: 10000;
}

.nestup-custom-modal-container {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    max-width: 800px;
    width: 90%;
    max-height: 90vh;
    background-color: white;
    border-radius: 5px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
    z-index: 10001;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.nestup-custom-modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 20px;
    border-bottom: 1px solid #e9ecef;
}

.nestup-custom-modal-header h3 {
    margin: 0;
    font-size: 18px;
    font-weight: 600;
}

.nestup-custom-modal-close {
    background: none;
    border: none;
    font-size: 24px;
    font-weight: bold;
    color: #666;
    cursor: pointer;
    padding: 0;
    margin: 0;
    line-height: 1;
}

.nestup-custom-modal-close:hover {
    color: #333;
}

.nestup-custom-modal-body {
    padding: 20px;
    overflow-y: auto;
    max-height: calc(90vh - 60px);
}

/* Prevenire lo scroll del body quando la modale è aperta */
body.nestup-modal-open {
    overflow: hidden;
}

/* Pulsante per aprire la modale */
.nestup-modal-trigger {
    display: inline-block;
    padding: 10px 20px;
    background-color: #007bff;
    color: white;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 16px;
    transition: background-color 0.3s;
}

.nestup-modal-trigger:hover {
    background-color: #0056b3;
}

/**
 * Stili esistenti per il form di valutazione
 */
.nestup-valutazione-container {
    max-width: 800px;
    margin: 20px auto;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif;
}

.nestup-valutazione-form {
    background-color: #fff;
    padding: 25px;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

/* Indicatore di step */
.nestup-steps-indicator {
    display: flex;
    justify-content: center;
    align-items: center;
    margin: 0 auto 30px;
    position: relative;
    max-width: 300px;
}

.nestup-steps-indicator .nestup-step-indicator {
    display: flex;
    justify-content: center;
    align-items: center;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background-color: #f8f9fa;
    border: 2px solid #dee2e6;
    color: #6c757d;
    font-weight: bold;
    position: relative;
    z-index: 2;
    transition: all 0.3s ease;
}

.nestup-steps-indicator .nestup-step-indicator.active {
    background-color: #0d6efd;
    border-color: #0d6efd;
    color: white;
}

.nestup-steps-indicator .nestup-step-line {
    flex-grow: 1;
    height: 2px;
    background-color: #dee2e6;
    position: relative;
    z-index: 1;
}

.nestup-steps-indicator .nestup-step-indicator:not(:first-child) {
    margin-left: 10px;
}

.nestup-steps-indicator .nestup-step-indicator:not(:last-child) {
    margin-right: 10px;
}

/* Stili per l'intestazione dei passi della modale */
.nestup-steps-header {
    display: flex;
    justify-content: space-between;
    margin-bottom: 20px;
}

.nestup-steps-header .nestup-step-indicator {
    padding: 8px 15px;
    background-color: #f8f9fa;
    border-radius: 4px;
    transition: background-color 0.3s;
}

.nestup-steps-header .nestup-step-indicator.active {
    background-color: #007bff;
    color: white;
}

/* Form step */
.nestup-form-step {
    margin-bottom: 20px;
}

/* Conferma indirizzo */
.nestup-address-display {
    background-color: #f8f9fa;
    border-left: 4px solid #2271b1;
    padding: 12px 15px;
    margin-bottom: 20px;
    border-radius: 4px;
}

.nestup-address-display p {
    margin: 0;
    color: #333;
}

/* Form fields */
.nestup-form-field {
    margin-bottom: 20px;
}

.nestup-form-field label {
    display: block;
    margin-bottom: 8px;
    font-weight: 500;
    color: #333;
}

.nestup-error-message {
    color: #dc3545;
    font-size: 13px;
    margin-top: 5px;
}

/* Messaggi di successo/errore */
.nestup-form-message {
    display: none;
    padding: 20px;
    margin-top: 20px;
    border-radius: 5px;
}

.nestup-success {
    background-color: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
}

.nestup-error {
    background-color: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
}

/* Form iniziale con campo indirizzo */
.nestup-initial-form {
    max-width: 600px;
    margin: 0 auto;
    padding: 20px;
    background-color: #f8f9fa;
    border-radius: 5px;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
}

/* Responsive */
@media (max-width: 768px) {
    .nestup-custom-modal-container {
        width: 95%;
        max-height: 95vh;
    }
    
    .nestup-steps-header {
        flex-direction: column;
        gap: 10px;
    }
    
    .nestup-step-indicator {
        text-align: center;
    }
}

/* Stili specifici per la versione compatta del form */
.nestup-form-compact .row {
    display: flex;
    flex-wrap: wrap;
}

.nestup-form-compact .row > [class*="col-"] {
    float: none;
    display: flex;
    flex-direction: column;
}

/* Per garantire che tutti i campi abbiano la stessa altezza */
.nestup-form-compact .form-control,
.nestup-form-compact .form-select {
    height: calc(1.5em + 0.75rem + 2px);
}

/* Per i checkbox che hanno un layout diverso */
.nestup-form-compact .form-check {
    display: flex;
    align-items: center;
    height: 100%;
}

/* Stili per campi con checkbox */
.campo-con-checkbox {
    display: flex;
    flex-direction: column;
}

.campo-con-checkbox .form-check {
    margin-bottom: 6px;
}

.campo-con-checkbox .form-check-input {
    cursor: pointer;
}

.campo-con-checkbox .form-check-label {
    font-weight: 600;
    cursor: pointer;
}

.campo-superficie {
    margin-top: 2px;
}

.campo-superficie label {
    font-size: 0.9em;
    margin-bottom: 4px;
    color: #666;
}

/* Per la modalità compatta */
.nestup-form-compact .campo-con-checkbox {
    height: 100%;
}

.nestup-form-compact .campo-con-checkbox .form-check {
    margin-bottom: 4px;
}

/* Stile per i campi di input disabilitati */
input:disabled,
select:disabled,
textarea:disabled,
.form-control:disabled {
    background-color: #d5d5d5 !important;
    color: #6c757d;
    cursor: not-allowed;
} 