/* Styles pour l'espace Habitudes */

.habits-list {
    display: grid;
    gap: 15px;
}

.habit-card {
    background: white;
    border-radius: 10px;
    padding: 20px;
    display: flex;
    align-items: center;
    gap: 15px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    transition: all 0.3s;
}

.habit-card:hover {
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.12);
    transform: translateY(-2px);
}

.habit-card.inactive {
    opacity: 0.6;
}

.habit-color {
    width: 6px;
    height: 60px;
    border-radius: 3px;
    flex-shrink: 0;
}

.habit-content {
    flex: 1;
    min-width: 0;
}

.habit-name {
    font-size: 18px;
    font-weight: 600;
    color: #2c3e50;
    margin-bottom: 5px;
}

.habit-description {
    font-size: 14px;
    color: #7f8c8d;
    margin-bottom: 8px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.habit-meta {
    display: flex;
    gap: 15px;
    font-size: 13px;
}

.habit-points {
    color: #667eea;
    font-weight: 600;
}

.habit-status {
    padding: 2px 8px;
    border-radius: 12px;
    font-size: 12px;
    font-weight: 600;
}

.habit-status.active {
    background: #d4edda;
    color: #155724;
}

.habit-status.inactive {
    background: #f8d7da;
    color: #721c24;
}

.habit-actions {
    display: flex;
    gap: 5px;
    flex-shrink: 0;
}

/* Badge bonus sur les cartes d'habitude */
.habit-bonus {
    color: #f39c12;
    font-weight: 600;
    font-size: 12px;
    background: #fff8e6;
    padding: 2px 8px;
    border-radius: 12px;
}

/* Section bonus dans le formulaire */
.bonus-section {
    margin: 20px 0 10px 0;
    padding-top: 15px;
    border-top: 1px solid #eee;
}

.section-toggle {
    display: flex;
    align-items: center;
    gap: 10px;
    cursor: pointer;
    font-weight: 500;
    color: #2c3e50;
}

.section-toggle input[type="checkbox"] {
    width: 18px;
    height: 18px;
    cursor: pointer;
}

.bonus-fields {
    background: #f8f9fa;
    padding: 15px;
    border-radius: 8px;
    margin-top: 10px;
}

.bonus-fields.hidden {
    display: none;
}

.form-hint {
    display: block;
    color: #6c757d;
    font-size: 11px;
    margin-top: 4px;
}

/* Badge bonus quotidien sur les cartes d'habitude */
.habit-daily-bonus {
    color: #27ae60;
    font-weight: 600;
    font-size: 12px;
    background: #e8f5e9;
    padding: 2px 8px;
    border-radius: 12px;
}

/* Section bonus quotidien dans le formulaire */
.daily-bonus-section {
    margin: 15px 0 10px 0;
    padding-top: 15px;
    border-top: 1px solid #eee;
}

.daily-bonus-fields {
    background: #f0f7f0;
    padding: 15px;
    border-radius: 8px;
    margin-top: 10px;
}

.daily-bonus-fields.hidden {
    display: none;
}

.daily-bonus-help {
    margin-bottom: 12px;
    color: #6c757d;
}

.daily-bonus-options-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-bottom: 12px;
}

.daily-bonus-option-row {
    display: flex;
    gap: 10px;
    align-items: center;
}

.daily-bonus-label-input {
    flex: 2;
    padding: 8px 12px;
    border: 1px solid #ddd;
    border-radius: 5px;
    font-size: 14px;
}

.daily-bonus-points-input {
    width: 70px;
    padding: 8px 12px;
    border: 1px solid #ddd;
    border-radius: 5px;
    font-size: 14px;
    text-align: center;
}

.btn-remove-option {
    width: 32px;
    height: 32px;
    padding: 0;
    font-size: 18px;
    line-height: 1;
    border-radius: 50%;
}

.btn-small {
    padding: 6px 12px;
    font-size: 13px;
}

/* Responsive */
@media (max-width: 600px) {
    .habit-card {
        flex-direction: column;
        align-items: flex-start;
    }

    .habit-color {
        width: 100%;
        height: 6px;
    }

    .habit-actions {
        width: 100%;
        justify-content: flex-end;
    }

    .habit-description {
        white-space: normal;
    }
}
