/* ============================================
   STYLES POUR LA SECTION SOCIO-ÉCONOMIQUE PAPs
   À ajouter dans styles.css
   ============================================ */

/* Sous-section */
.subsection {
    margin-bottom: 30px;
}

.subsection-title {
    font-size: 1.5em;
    color: #2c3e50;
    margin-bottom: 25px;
    padding-bottom: 10px;
    border-bottom: 3px solid #3498db;
}

/* Sections du formulaire */
.form-section {
    background: #ffffff;
    padding: 25px;
    margin-bottom: 25px;
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.section-title {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    padding-bottom: 12px;
    border-bottom: 2px solid #ecf0f1;
}

.section-title-left {
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 1.1em;
    font-weight: 600;
    color: #34495e;
}

.section-icon {
    font-size: 1.5em;
}

/* Groupes radio */
.radio-group {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 15px;
}

.radio-item {
    display: flex;
    align-items: center;
    padding: 12px 15px;
    background: #f8f9fa;
    border: 2px solid #e9ecef;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.radio-item:hover {
    background: #e9ecef;
    border-color: #3498db;
    transform: translateY(-2px);
}

.radio-item input[type="radio"] {
    margin-right: 10px;
    cursor: pointer;
    width: 18px;
    height: 18px;
}

.radio-item input[type="radio"]:checked + label {
    color: #3498db;
    font-weight: 600;
}

.radio-item label {
    cursor: pointer;
    flex: 1;
    margin: 0;
    font-size: 0.95em;
}

/* Groupes checkbox */
.checkbox-group {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 15px;
}

.checkbox-item {
    display: flex;
    align-items: center;
    padding: 12px 15px;
    background: #f8f9fa;
    border: 2px solid #e9ecef;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.checkbox-item:hover {
    background: #e9ecef;
    border-color: #3498db;
    transform: translateY(-2px);
}

.checkbox-item input[type="checkbox"] {
    margin-right: 10px;
    cursor: pointer;
    width: 18px;
    height: 18px;
}

.checkbox-item input[type="checkbox"]:checked + label {
    color: #3498db;
    font-weight: 600;
}

.checkbox-item label {
    cursor: pointer;
    flex: 1;
    margin: 0;
    font-size: 0.95em;
}

/* Champ "Autre" */
.other-input {
    width: 100%;
    padding: 12px;
    margin-top: 15px;
    border: 2px solid #e9ecef;
    border-radius: 8px;
    font-size: 0.95em;
    transition: border-color 0.3s ease;
}

.other-input:focus {
    outline: none;
    border-color: #3498db;
}

/* Conteneur de tableau */
.table-container {
    overflow-x: auto;
    margin-top: 15px;
}

/* Tableau des biens */
#papsBiensTable {
    width: 100%;
    border-collapse: collapse;
    background: white;
}

#papsBiensTable thead {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
}

#papsBiensTable th {
    padding: 15px 10px;
    text-align: left;
    font-weight: 600;
    font-size: 0.95em;
}

#papsBiensTable td {
    padding: 12px 10px;
    border-bottom: 1px solid #e9ecef;
}

#papsBiensTable tbody tr {
    transition: background-color 0.3s ease;
}

#papsBiensTable tbody tr:hover {
    background-color: #f8f9fa;
}

/* Contrôles de formulaire dans le tableau */
#papsBiensTable .form-control {
    width: 100%;
    padding: 8px;
    border: 1px solid #dee2e6;
    border-radius: 6px;
    font-size: 0.9em;
    transition: border-color 0.3s ease;
}

#papsBiensTable .form-control:focus {
    outline: none;
    border-color: #3498db;
    box-shadow: 0 0 0 3px rgba(52, 152, 219, 0.1);
}

/* Bouton ajouter ligne */
.btn-add-row {
    padding: 10px 20px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-size: 0.9em;
    font-weight: 600;
    transition: all 0.3s ease;
}

.btn-add-row:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.4);
}

/* Bouton supprimer */
.btn-delete {
    padding: 8px 12px;
    background: #e74c3c;
    color: white;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    font-size: 1.2em;
    transition: all 0.3s ease;
}

.btn-delete:hover {
    background: #c0392b;
    transform: scale(1.1);
}

/* État vide du tableau */
.empty-state {
    text-align: center;
    padding: 40px;
    color: #95a5a6;
    font-style: italic;
    background: #f8f9fa;
    border-radius: 8px;
    margin-top: 15px;
}

/* Groupe de formulaire */
.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    color: #34495e;
    font-size: 0.95em;
}

.form-group textarea {
    width: 100%;
    padding: 12px;
    border: 2px solid #e9ecef;
    border-radius: 8px;
    font-size: 0.95em;
    font-family: inherit;
    resize: vertical;
    transition: border-color 0.3s ease;
}

.form-group textarea:focus {
    outline: none;
    border-color: #3498db;
    box-shadow: 0 0 0 3px rgba(52, 152, 219, 0.1);
}

/* Boutons d'action */
.btn {
    padding: 12px 24px;
    border: none;
    border-radius: 8px;
    font-size: 1em;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

.btn-success {
    background: linear-gradient(135deg, #11998e 0%, #38ef7d 100%);
    color: white;
}

.btn-success:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(17, 153, 142, 0.4);
}

/* Message de succès */
.alert {
    padding: 15px 20px;
    border-radius: 8px;
    font-weight: 500;
}

.alert-success {
    background: linear-gradient(135deg, #11998e 0%, #38ef7d 100%);
    color: white;
    border-left: 4px solid #0d7f72;
    animation: slideIn 0.3s ease;
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Responsive design */
@media (max-width: 768px) {
    .radio-group,
    .checkbox-group {
        grid-template-columns: 1fr;
    }
    
    .section-title {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
    }
    
    #papsBiensTable {
        font-size: 0.85em;
    }
    
    #papsBiensTable th,
    #papsBiensTable td {
        padding: 8px 5px;
    }
}